Switch
A premium toggle switch with spring physics and tactile feedback animations.
Preview
Interactive Preview
Tactile Switches
Sizes
Installation
Usage
tsx
import { Switch } from "@/components/ui/switch"
export default function Demo() {
return (
<div className="flex flex-col gap-4">
<Switch label="Dark Mode" size="md" />
<Switch label="Notifications" size="lg" />
</div>
)
}Dependencies
framer-motion
Props
| Prop | Type | Default |
|---|---|---|
| label | string | - |
| size | "sm""md""lg" | md |
| disabled | boolean | false |