Tabs
A component for toggling between related panels on the same page. There is no border. The selected tab rests on the wash, hover and focus shift that wash, and the indicator is the accent. Tabs are Regular and panels are Light.
Workspace stats and activity.
Milestones and deadlines.
Profile and preferences.
Anatomy
<UiTabsRoot default-value="overview">
<UiTabsList>
<UiTabsTab value="overview">Overview</UiTabsTab>
<UiTabsTab value="projects">Projects</UiTabsTab>
<UiTabsIndicator />
</UiTabsList>
<UiTabsPanel value="overview">Workspace stats and activity.</UiTabsPanel>
<UiTabsPanel value="projects">Milestones and deadlines.</UiTabsPanel>
</UiTabsRoot>
Parts
- Root — owns the active
value.orientationishorizontal(default) orvertical. - List —
role="tablist". - Tab —
role="tab". Arrow keys move and activate.data-selected. - Indicator — a CSS bar that follows the selected tab (
left/width, ortop/heightwhen vertical). - Panel —
role="tabpanel". Hidden when not selected.