Toggle
A two-state button that can be either on or off.
Preview
Installation
bash
npx auralix-ui add toggleUsage
Toggle Button
tsx
import { Toggle } from "@/components/ui/Toggle";
<Toggle>Bold</Toggle>Props
| Name | Type | Default | Description |
|---|---|---|---|
pressed | boolean | false | The controlled state. |
onPressedChange | (pressed: boolean) => void | - | Callback when state changes. |
variant | "default" | "outline" | "default" | Visual variant. |
Variants
Variants
Sizes
On this page