Text reveal
Reveal a short piece of content with restrained motion.
Show ongoing work with a calm light across the words.
npx shadcn@latest add @silicon-ui/text-shimmernpx shadcn@latest add @silicon-ui/text-shimmerInstall the dependencies.
npm install motionCopy these files into your project. Shared files are skipped if you already have them.
components/silicon-ui/text-shimmer/text-shimmer.tsxcomponents/silicon-ui/text-shimmer/text-shimmer.module.cssInstall the foundation once per app for the design and motion tokens: npx shadcn@latest add @silicon-ui/silicon-foundation
| Prop | Type | Default |
|---|---|---|
children*The status text. Keep it to one short line. | string | — |
activeSweep while work is ongoing. Defaults to true. | boolean | true |
durationSeconds for one sweep across the text. Defaults to 1.8. | number | 1.8 |
as | "span" | "p" | "div" | "h2" | "h3" | "h4" | "span" |
className | string | — |
id | string | — |