Dev Design Library

Animated Switch

An iOS-quality animated toggle switch with a press-to-stretch knob, drag-to-toggle with flick support, and optional crossfading knob icons.

Animated Switch preview
Library
Spectrum UI
Framework
React
Type
component
License
Apache-2.0
Dependencies
framer-motion
Install
npx shadcn@latest add @spectrumui/animated-switch
Files
  • app/registry/animated-switch/animated-switch.tsx
  • lib/utils.ts
Source
https://github.com/arihantcodes/spectrum-ui

Categories

More from Spectrum UI