Default
The heading is drawn on left to right as it comes into view, once, with a marker tip writing it (nib). Replay mounts it again; on a long page it waits until you scroll to it.
Holds its children back until they scroll into view, then draws them on: a wipe along the line, wet ink drying, a sheet dropped on the desk, a stamp, a toss. Direct children can arrive one after another. Without script, and with reduced motion, everything is simply there.
npx shadcn@latest add @wobko/revealFirst time here? Add the registry to components.json first. How to install
The heading is drawn on left to right as it comes into view, once, with a marker tip writing it (nib). Replay mounts it again; on a long page it waits until you scroll to it.
wipe, soak, drop, pop and toss, each one of the theme's keyframes. They play when they are on screen; scroll away and back with once turned off.
A real use: stagger makes direct children arrive one after another, each drying like wet ink. A group-data variant lets a tick inside key on the reveal.
A wrapper element. It arms itself after mounting (the server sends everything visible), hides its content with opacity, and plays one of the theme's own keyframes when an IntersectionObserver says enough of it is on screen. It leaves data-state="hidden|visible" on itself, so anything drawn inside can key on it with group-data-[state=visible]/reveal:…
| Prop | Type | Default | Description |
|---|---|---|---|
| effect | "wipe" | "soak" | "drop" | "pop" | "toss" | "wipe" | wipe draws it on along the line (ll-wipe), soak dries it like wet ink (ll-soak), drop lays a sheet down (ll-drop), pop stamps it (ll-pop), toss throws it in (ll-toss). |
| from | "start" | "end" | "start" | Which end a wipe starts from. The wipe follows the page direction by itself. |
| delay | number | 0 | Seconds to wait once it is in view. |
| stagger | number | - | Seconds between direct children (the first 16): they arrive one after another instead of as one block. |
| threshold | number | 0.25 | How much of it must be on screen, 0 to 1. |
| once | boolean | true | Play once, or every time it scrolls back into view. |
| onReveal | () => void | - | Called each time it is revealed. |
| nib / nibColor | boolean / PaintKey | false / "tomato" | A hand-drawn marker tip rides the leading edge of a wipe, as if it were writing the content (wipe without stagger only; a list, `as="ul"` or `"ol"`, has nowhere to put the tip and ignores it). The content is wrapped in one block (a span on a p or a span). |
| as | "div" | "section" | "article" | "aside" | "figure" | "ul" | "ol" | "li" | "span" | "p" | "div" | The element to render. |
The files the CLI copies into your project.
Loading the source