Filigran

Switch example

Displays a switch that can be clicked.

How to use this accordion

Props :

NameTypeDefaultDescription
asChildbooleanfalseChange the default rendered element for the one passed as a child, merging their props and behavior.
checkedbooleanfalseWhen when checked is true, displays with the primary color and translate the thumb to the right.
onCheckedChange() => void_Function called on click.
disabledbooleanfalseWhen true, prevents the user from interacting with the accordion and all its items.

Playground

Import from @filigran/ui :

Import {Switch} from '@filigran/ui'