Text Animations
Marquee Text
A marquee that scrolls only when its text overflows the container.
Install
bun add clsx tailwind-mergeThen copy 3 files into your project:
- components/registry/marquee-text/marquee-text.tsx
- components/registry/marquee-text/auto-mask-horizontal.tsx
- lib/utils.ts
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| speed | number | 35 | Scroll speed (px/s). |
| gap | number | 40 | Gap between repetitions. |
| pause | number | 5 | Pause at the start before scrolling. |
What It Demonstrates
Related Components
Long Shadow
Text that casts a long shadow sweeping like a sundial through the hours.
Morphing Text
A gooey blur-morph that cross-dissolves between a list of words.
Specter
Spectral RGB-split echoes drift off the letters and dissolve into the dark.
Redact
Copy that arrives fully classified under solid bars, then declassifies word by word. Each bar clears its own word and leaves an amethyst edge behind as the only evidence it was ever there.
Split Flap
A Solari departure board. Every column walks the charset one flap at a time until it reaches its letter, so the word is never revealed. It is arrived at, with a real hinged half falling away as the next one seats behind it.
Teletype
A line of type arriving one character at a time, at a rate that varies and with a beat at every mark.