Lean

No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/button-lean

About this component

A polished chrome pill that leans toward your pointer, its label leaning a little further and a blue reflection sliding across the metal. When the pointer leaves it springs back to centre.

Triggers

  • Hover
  • Mouse tracking
  • Spring
  • Ambient

Techniques

  • Mouse tracking
  • CSS variables
  • CSS transition
  • mix-blend-mode

Difficulty

Intermediate

Accessibility

Keyboard and screen readers

A native button named by its label; :focus-visible draws an outline.

Reduced motion

The lean is switched off (translate: none) and the sheen stops.

Use it in anything you build, commercial and client work included. Licence

More buttons

See all
LettersGet code
MemphisGet code
OathGet code
OrbitGet code