Skip to content
Theme

Tabs

Views of one thing, one shown at a time.

Examples

Horizontal

What the concept claims and why it matters.

Vertical

Name and email.

Segmented, for a filter

Every run this week.

Props

Tabs

Views of one thing, one shown at a time. Arrow keys move between tabs; Tab moves into the panel.

PropTypeDefaultDescription
variant?Variant"line"line for the views of a record, segmented for a filter or a toggle between a few views.

Also takes 85 props it passes to the underlying React Aria component or element (events, ARIA attributes, state such as isDisabled), documented by React Aria.

TabList

Also takes 78 props it passes to the underlying React Aria component or element (events, ARIA attributes, state such as isDisabled), documented by React Aria.

Tab

PropTypeDefaultDescription
childrenReactNode—
count?number—How many items the view holds, shown quietly after the label.

Also takes 96 props it passes to the underlying React Aria component or element (events, ARIA attributes, state such as isDisabled), documented by React Aria.

TabPanel

Also takes 78 props it passes to the underlying React Aria component or element (events, ARIA attributes, state such as isDisabled), documented by React Aria.

Keyboard

KeyDoes
ArrowLeft or ArrowRightMove between tabs (ArrowUp and ArrowDown when vertical)
Home or EndGo to the first or last tab
TabMoves from the tab list into the panel

Accessibility

  • The tab list is one tab stop; arrow keys follow the reading direction in right-to-left text.