Tabs
A set of layered sections of content that display one panel at a time.
Usage
The Tabs component provides a way to organize content into multiple sections, displaying one section at a time.
Tabs Props
Prop | Type | Default |
---|---|---|
defaultValue | string | - |
value | string | - |
onValueChange | (value: string) => void | - |
className | string | - |
Tabs.List Props
Prop | Type | Default |
---|---|---|
className | string | - |
Tabs.Trigger Props
Prop | Type | Default |
---|---|---|
value | string | - |
icon | ReactNode | - |
disabled | boolean | - |
className | string | - |
Tabs.Content Props
Prop | Type | Default |
---|---|---|
value | string | - |
className | string | - |
Examples
Basic Tabs
With Icons
Disabled Tab
Accessibility
Tabs follow the WAI-ARIA Tabs Pattern. They include the following accessibility features:
- Keyboard navigation between tabs using arrow keys
- Proper ARIA roles, states, and properties
- Focus management for tab panels