Zipper

No dependencies
Code format

Install with shadcn

Needs a free account token. Get a token

npx shadcn@latest add @movin/toggle-zipper

About this component

A zip as a switch. The pull slides along the track and the teeth interlock behind it as it goes; switching off runs it back and the two rows part again. Pure CSS on a native switch.

Triggers

  • Click
  • State change

Techniques

  • clip-path
  • Gradient
  • CSS transition

Difficulty

Intermediate

Accessibility

Keyboard and screen readers

Native checkbox with role="switch" inside a <label>. The visible label text names it. Focus ring on the visual via :focus-visible.

Reduced motion

The change is instant.

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

More toggles

See all
FlipGet code