← All components
Inset Frame Reveal
ClipWindow settle — a uniform clip-path frame insets in from the edges, then opens.
window settle
opens on mount
Installation
One command drops the source into your repo — editable, with the provider and motion pulled in automatically.
npx shadcn add https://motion.asmitsah.dev/r/inset-frame-reveal.jsonPrerequisiteInstall the provider base first
This component imports from @/lib/motion and needs <MotionProvider> mounted in your root layout — install the base once, before copying this component.
npx shadcn add https://motion.asmitsah.dev/r/provider.jsonStep 1Install the runtime dependency
npm install motionStep 2Copy the source into
components/motion/inset-frame-reveal.tsxcomponents/motion/inset-frame-reveal.tsx
Usage
Basic
A uniform clip-path frame insets 15% from every edge, then opens the first time it's 30% in view.
Trigger on mount
Play immediately instead of waiting for scroll — for above-the-fold hero art.
With delay
Offset the open by a beat to sequence it after a title or sibling reveal.
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| children | ReactNode | — | Content the frame opens to reveal. |
| className | string | — | Passed straight through — InsetFrameReveal becomes your layout element. |
| style | CSSProperties | — | Inline style passthrough. |
| delay | number | 0 | Seconds before this instance animates. |
| trigger | "inView" | "mount" | "inView" | Animate on scroll-into-view (once) or immediately on mount. |