Radio cards
Selectable option cards with a sliding selection ring, price and description slots, and radio keyboard behavior.
A tactile toggle for settings that take effect immediately.
npx shadcn@latest add @silicon-ui/switchnpx shadcn@latest add @silicon-ui/switchInstall the dependencies.
npm install @radix-ui/react-switch motionCopy these files into your project. Shared files are skipped if you already have them.
components/silicon-ui/switch/switch.tsxcomponents/silicon-ui/switch/switch.module.cssInstall the foundation once per app for the design and motion tokens: npx shadcn@latest add @silicon-ui/silicon-foundation
| Prop | Type | Default |
|---|---|---|
label | string | — |
Also accepts the props of ComponentPropsWithoutRef<typeof SwitchPrimitive.Root>.