Atelier UI

Search components…

Search components…

Magnetic Button

Magnetic button that follows the pointer nearby and springs back when it leaves.

Edit in sandbox

Copy a prompt for your AI coding tool with the source, dependencies and usage

Props

MagneticButtonProps

Also accepts all props of React.ComponentProps<"button">

PropTypeDefaultDescription
strengthnumber0.350-1, how far the button follows the cursor

Install

$ npx shadcn@latest add https://chromotion.dev/r/magnetic-button.json

More like this