Using this Component
Switches should be used when allowing a user to toggle between two different states. The on/off state of the switch should correspond directly to the on/off state of what it is controlling. Do
All switches should have an adjacent label. To provide more context to the feature, the switch can be used beneath a UIHeader and/or include a descriptive text block beneath its label.
Switches are a directly interactive elements. Depending on the context they may be disabled to prevent interactivity.
Clicking anywhere on the switch, as well as anywhere on its label (when possible) should toggle the switch.
Component code details for this component are not currently available, but we're working on it!
Checkout this UIKit component's code and comments in the codebase for usage examples, props, and more.