Switch
The Mozhi switch is the default binary control for persistent enabled and disabled state.
Purpose
Switch is the binary control for persistent on or off state.
Controlled and uncontrolled
Use checked with onCheckedChange when the surrounding feature owns state. Use defaultChecked for local uncontrolled behavior.
Styling behavior
The track and thumb both read from Mozhi theme tokens, so accent and grayscale changes stay consistent in light and dark mode.
Accessibility
Always provide an aria-label when there is no visible text label next to the control.