LLabanaat

Switch

Toggle for settings that take effect immediately — prefer over Checkbox when there's no separate save step.

<div className="ui-w-72">
<Switch
  label="Require two-factor authentication"
  description="All members must enable 2FA to sign in."
  defaultChecked
/>
</div>

Editable — change the code above and the preview updates live.

Installation

import { Switch } from "@labanaat/ui/switch";

Props

PropTypeDefaultDescription
labelReactNodeField label
descriptionstringHelper text
checked / defaultCheckedbooleanControlled / uncontrolled state
onCheckedChange(checked) => voidChange handler
disabledbooleanfalseDisables interaction