componentsSource CodeRadix UI
/components/ui/toggle-group.tsx
/components/ui/toggle-group.tsx
Toggle Group
A group of toggle buttons that can be used to select multiple options.
Installation
Usage
Imports
import { ToggleGroup, ToggleGroupItem } from "@/components/ui/toggle-group"Code
<ToggleGroup>
<ToggleGroupItem value="bold">Bold</ToggleGroupItem>
<ToggleGroupItem value="italic">Italic</ToggleGroupItem>
<ToggleGroupItem value="underline">Underline</ToggleGroupItem>
</ToggleGroup>Examples
Outline Variant
Ghost Variant
Custom Spacing
Vertical Toggle Group
Disabled State
Props
<ToggleGroup>
| Name | Default | Values |
|---|---|---|
| variant | outline | ghostoutline |
| size | 36 | 283236404448 |
| disabled | false | boolean |
| orientation | horizontal | horizontalvertical |
| spacing | 0 | integer |
| External Reference | - | - |