Skip to Content
DocumentationTabs

Tabs

A set of layered content panels, known as Tab Panels, displayed one at a time.

Examples

Standalone (Outside the Header)

Tabs with limited width, ideal for cards or content sections.

Conteúdo da Home

Header (Inside the Header)

Tabs that span the full width, ideal for primary page navigation.

Conteúdo da Visão Geral

With Icons

Tabs can include icons to improve visual identification.

Conteúdo da Home

With Badges

Tabs can include badges to indicate counts or status.

Mensagens recebidas

Sizes

Tabs are available in sizes md and lg.

Size: md

Size: lg

Customization

Each element can be customized individually through CSS classes.

Conteúdo customizado

Non-Responsive

Disable responsive behavior to keep a fixed size across all screens.

Conteúdo 1

With Disabled Tab

Tabs can be disabled to prevent user interaction.

Conteúdo das tarefas ativas

API

Tabs Structure

ComponentDescriptionUsage
TabsRoot component that manages tab stateContains all other tab components
TabsListContainer for the tab triggersGroups the tab navigation buttons
TabsTriggerClickable button for each tabActivates the corresponding content panel
TabsContentContent panel for each tabShown when the corresponding tab is active

Tabs

PropertyTypePossible ValuesDefaultDescription
defaultValuestringAny string-The tab value that should be active by default.
valuestringAny string-The controlled value of the active tab.
onValueChange(value: string) => void--Callback called when the tab value changes.
variant”header” | “standalone""header”, “standalone""standalone”Defines whether tabs take full width (header) or limited width (standalone).
size”md” | “lg""md”, “lg""md”Size of the tabs.
responsivebooleantrue, falsetrueEnables responsive behavior that adjusts size on mobile/tablet.
classNamestringAny CSS class-Additional CSS classes for customization.

TabsList

PropertyTypePossible ValuesDefaultDescription
classNamestringAny CSS class-Additional CSS classes for customization.

TabsTrigger

PropertyTypePossible ValuesDefaultDescription
valuestringAny string-Unique value that identifies the tab.
iconReact.ReactNodeAny React node-Icon displayed before the tab text.
badgeReact.ReactNodeAny React node-Badge displayed after the tab text.
disabledbooleantrue, falsefalseDisables interaction with the tab.
classNamestringAny CSS class-Additional CSS classes for customization.

TabsContent

PropertyTypePossible ValuesDefaultDescription
valuestringAny string-Unique value that links the content to its tab.
forceMountbooleantrue, falsefalseForces content to stay mounted even when inactive.
classNamestringAny CSS class-Additional CSS classes for customization.

Accessibility

The Tabs component follows the WAI-ARIA pattern for tabs:

  • Uses role="tablist", role="tab" and role="tabpanel" appropriately
  • Supports keyboard navigation (arrows, Tab, Enter, Space)
  • Manages aria-selected and aria-controls automatically
  • Inactive content is removed from the DOM by default (use forceMount if needed)
Last updated on