A list of titles where pointing at one brings up its image, which trails the pointer, leans as it moves and crossfades as you go.
pnpm dlx shadcn@latest add @latheui/cursor-galleryPart of Lathe Pro. Set up your project once with your license key: npx latheui init --key <key>. See Lathe Pro.
Cursor Gallery is part of Lathe Pro
The preview is live and free to try. The source, the install and every assembly come with Pro: $79 once, with lifetime updates.
Depends on
Also accepts native div attributes.
| Prop | Type | Default | Description |
|---|---|---|---|
| items* (required) | { title: string; meta?: string; image: string; href?: string }[] | — | The rows. With href a row is a link; without, a button. |
| label* (required) | string | — | Accessible name for the list. |
| onSelect | (item, index) => void | — | Called when a row without an href is chosen. |
| imageWidth | number | 280 | Width of the image that follows the pointer, in px. |
| aspect | number | 4 / 3 | Width divided by height. |
| lag | number | 0.45 | How far the image trails the pointer, from 0 (glued) to 1 (lazy). |
| tilt | number | 8 | Degrees the image leans with the pointer's speed. |
| radius | number | string | 12 | Corner radius of the image. |
| dimOthers | boolean | true | Fade the other rows while one is under the pointer. |
<CursorGallery label="Work" items={items} lag={0} tilt={0} />