Stitch Frame Button
Web (React)
A paper button that pins four corners and stitches a dashed frame around itself on hover.
A card-coloured button with an italic serif label. On hover four round pins travel to the corners, a dashed frame is stitched around it one edge at a time, a dot grid fades in behind, and the button fills with the primary ink. Animations and transitions are turned off when the user prefers reduced motion.
Installation
CLI
npx @modus-ui/cli add stitch-frame-buttonManual
- Install
framer-motion. - Copy the code from the component tab.
- Create a file at
components/ui/stitch-frame-button.tsx. - Paste the code.
Usage
tsx
Props
| Prop | Type | Default | Description |
|---|---|---|---|
label | string | "Start sketching" | Button text. |
onClick | MouseEventHandler<HTMLButtonElement> | undefined | Click handler. |
Comments