Toggle Group
Group of toggle buttons with shared styling.
Installation
npx popcn add toggle-groupBasic Usage
Single Selection
Multiple Selection
Variants
Default
Aurora
Glass
With Icons
Alignment
Props
| Prop | Type | Default | Description |
|---|---|---|---|
| type | "single" | "multiple" | - | Selection type |
| value | string | string[] | - | Controlled value(s) |
| onValueChange | (value: string | string[]) => void | - | Callback when value changes |
| variant | "default" | "outline" | "aurora" | "glass" | "default" | Toggle variant style |
| size | "default" | "sm" | "lg" | "icon" | "default" | Toggle size |
| disabled | boolean | false | Disable all toggles |