Scratch

No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/checkbox-scratch

About this component

A diagonal clip-path wipe reveals the filled checked state from the bottom-right corner, like scratching a lottery card. Unchecking collapses the fill back.

Triggers

  • Click
  • State change

Techniques

  • clip-path

Difficulty

Intermediate

Moves on

Its code uses these curves. Open one to see it plotted and tune it.

Accessibility

Keyboard and screen readers

Hidden native input.

Reduced motion

Transitions removed under prefers-reduced-motion.

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

More checkboxes

See all
Shake LockGet code
ShutterGet code
Spark TrailGet code
StampGet code