Switch
Switch Component
Playground
Enable notifications
Props
| Prop | Type | Default | Value |
|---|---|---|---|
| size | selectsm | md | lg | — | |
| checked | boolean | — | |
| disabled | boolean | — | |
| label | text | — |
Default
Enable notifications
Checked
Dark mode
Disabled
Disabled switch
Sizes
Small
Medium
Large
| PROP | TYPE | DEFAULT | DESCRIPTION |
|---|---|---|---|
checked | boolean | — | Checked state |
disabled | boolean | — | Disabled state |
label | text | — | Label text |
size | select | — | Switch size |
Using Switchtsx
import { Switch } from '@/components/Switch'
<Switch
size="..."
checked="..."
disabled="..."
label="..."
/>Tokens Used
No design tokens detected