Typography
CreativeRotating Text
We build [apps · games · tools]. The slot resizes smoothly to each word so the sentence never jumps.
Install
Included with Creative: needs your API key. Initialize and log in once.
npx @galactrex/ui add rotating-textUsage
import { RotatingText } from "@/components/galactrex/rotating-text";
We build <RotatingText words={["apps", "games", "tools"]} />Source
Installs to components/galactrex/rotating-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 |
|---|---|---|---|
words | string[] | — | The words. |
every | number | 2.2 | Seconds per word. |
mode | "flip" | "slide" | "flip" | Drum flip or slide. |
className | string | — | Extra classes for the outer element. |
Variants
- Inline. Inside a sentence.
Accessibility
- The word list is read once.
Motion and reduced motion
- Spring 3D flip with layout resize; pauses offscreen.
- Reduced motion: a fade.