CursorsProNew
Spotlight
A soft spot of light follows the cursor inside a card and lights up its border.
Customize
fromColor
viaColor
toColor
Based on Spotlight (MIT license) ยท Terms of use
Props
6 properties| Property | Type | Default | Description |
|---|---|---|---|
| size | number | 200 | Diameter of the light spot in pixels. |
| springOptions | SpringOptions | "{ bounce: 0 }" | Motion spring options: how the spot follows the cursor. |
| className | string | โ | Spot classes. Colours are set with fromColor, viaColor and toColor. |
| fromColor | string | "#fafafa" | Colour at the centre of the light. |
| viaColor | string | "#f4f4f5" | Colour halfway out. |
| toColor | string | "#e4e4e7" | Colour at the soft edge, before it fades out. |
Dependencies
3 required packages
npm install motion clsx tailwind-merge