SwitchCard
Toggleable switch card
import SwitchCard from "@intility/bifrost-react/SwitchCard";SwitchCard
Go to top
For convenience, <SwitchCard> is provided as an alias for
<CheckboxCard type="switch">. Otherwise, it functions
exactly the same as <CheckboxCard>.
Basic usage
See <CheckboxCard> for more examples.
Inactive state
Use state="inactive" for a focusable, tooltip-friendly replacement for
disabled. The card chrome stays at full opacity; only the switch icon dims.
See <CheckboxCard> for the full pattern.
Controlled mode
You can bind a SwitchCard to a boolean state using the checked prop and update
your state every time the onChange event is triggered.