Flip

No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/checkbox-flip

About this component

A checkbox that performs a full 360° Y-axis coin flip via CSS keyframes when toggled. The fill color and stroke-dashoffset check mark transition during the rotation.

Triggers

  • Click
  • State change

Techniques

  • Transform only
  • Keyframes

Difficulty

Beginner

Moves on

Its code uses this curve. Open one to see it plotted and tune it.

Accessibility

Keyboard and screen readers

Hidden native input.

Reduced motion

Flip keyframe skipped under prefers-reduced-motion via data attribute selector.

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

More checkboxes

See all
Ghost ThroughGet code
GlitchGet code
Gravity DropGet code
HeartbeatGet code