Switch
A labeled on/off setting with native checkbox form behavior.
Preview
Use Switch
Switch is a named export of @flood-md/react. Connect the package once, then import what you use.
Design notes
- Switch uses a native checkbox with role="switch".
- checked/defaultChecked, name/value, reset and disabled remain native. The component does not persist settings.
- The control and visible label form one content-width unit with an 8px-at-16px-root internal gap. Use an explicit parent gap="4" (16px at that root) between units; the glyph keeps its token-defined size.
API reference
View TypeScript source