Loading preview
Blur Text
Text animationsText whose words rise out of a blur one after another.
Fades, unblurs and lifts text into place word by word as it scrolls into view.
npx shadcn@latest add @venusui/text-revealRun this in a project set up with shadcn. If you haven’t set it up yet, run npx shadcn@latest init first.
Paths use the default shadcn aliases. The CLI follows the aliases in your components.json.
@/components/ui/text-reveal.tsxThe code behind the preview above.
text-reveal-demo.tsx
import { TextReveal } from "@/components/ui/text-reveal"
export default function TextRevealDemo() {
return (
<TextReveal
as="h2"
text="Every word arrives exactly when you expect it to."
className="max-w-md text-center text-3xl font-semibold tracking-tight text-balance"
/>
)
}
| Prop | Type | Default | Description |
|---|---|---|---|
| text | string | — | Text to reveal. Required. |
| as | "h1" | "h2" | "h3" | "p" | "span" | "p" | Element to render, so headings keep their meaning. |
| delay | number | 0 | Seconds before the first word starts. |
| stagger | number | 0.06 | Seconds between words. |
| repeat | boolean | false | Animate every time the text enters the viewport, not just the first time. |
| className | string | — | Classes for the element. |
Only the props above.
motion package. The CLI installs it.as="h1" for page titles so the heading structure stays correct.stagger={0.12}, or chain several with increasing delay.repeat or remove the component.Unknown registry "@venusui"npx shadcn@latest), install by URL, or register it with its address: npx shadcn@latest registry add @venusui=https://venusui.com/r/{name}.json.No components.json foundnpx shadcn@latest init in your project first.Text whose words rise out of a blur one after another.
Text filled with a slowly moving gradient: a subtle sheen by default, or your own colors.
Counts up to a number when it scrolls into view, with locale-aware formatting.