Originals
CreativeGravity Text
Each letter drops under gravity, bounces on an invisible floor with a little spin and rests at an angle, then they climb back into the word. For 404 pages, empty states and playful headings.
Install
Included with Creative: needs your API key. Initialize and log in once.
npx @galactrex/ui add gravity-textUsage
import { GravityText } from "@/components/galactrex/gravity-text";
<GravityText as="h1" text="Page not found" trigger="click" />Source
Installs to components/galactrex/gravity-text.tsx, with the shared motion primitives beside it.
Source for this component comes with its plan. Install it with the command above, or open your licensed copy here.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
text | string | — | The text. |
as | ElementType | "span" | Element to render. |
trigger | "click" | "hover" | "manual" | "click" | What lets the letters fall. |
fallen | boolean | — | Fall when true, for trigger="manual". |
drop | number | 140 | How far below the text the floor is. |
bounce | number | 0.42 | Floor bounciness, 0 to 0.8. |
rest | number | 1600 | Ms on the floor before climbing back; 0 stays down. |
className | string | — | Extra classes for the outer element. |
Variants
- 404. The page title falls on arrival with `trigger="manual"`.
- Hover gag. Letters tumble when the pointer arrives.
Accessibility
- Clickable version is a button with Enter and Space.
- The real text is read once; falling letters are aria-hidden.
Motion and reduced motion
- A tiny physics step per frame writes transforms straight to the letters; stops when everything rests.
- Reduced motion: letters stay put.