Components/Navigation
Interactive docs page: https://wix-pages.com/design-system-documentation/#/component/tabs
Tabs enable users to navigate between different content sections on the same page, card, or a panel.
<Sidebar/>, <Breadcrumbs/> or links instead.<Stepper/> instead.Control tabs size with size prop:
small in dense layouts, like narrow panels.smallMedium in layouts that sit between dense and standard.medium (default) in all other layouts, like below <Page.Header/>.By default, tabs fill in the entire width of their parent container and have a minimum width of 628 px.
Set custom min width of tabs using the minWidth prop.
Control how tabs are positioned with type prop:
compact - each tab grows with its title. Side paddings are outside tabs.compactSide - each tab grows with its title. Side paddings are outside tabs. The first and the last tab has no left and right paddings respectively.uniformSide - each tab grows to the size defined in width prop. If tab content is longer than the width, it gets truncated by ellipsis. Side paddings are inside tabs.uniformFull - all tabs grow equally to fill in the whole container. Side paddings are inside tabs.Set disabled on an item to make that tab non-interactive and render it in a muted state.
Control text alignment inside tabs with alignment prop. It supports 3 options:
start (default) to align tab titles to to the left.center to align them to the middle.end to align them to the right.Control if the default bottom divider is shown with hasDivider prop.
Add any component to the end of tabs with sideContent prop.
For example, use it to store a filter or form actions like Save and Cancel.
When Tabs do not have enough space to be fully shown, a horizontal scroll will be enabled.
Use tabs to divide all page contents into shorter, digestible parts.
Divide content in a way that allows users completing their task under each tab independently.
Let users switch between parts of content in the same context of a <SidePanel/>.
Select to show either panel divider or a default tabs' divider to separate panel header from its main content.
If there are several tabs, that do not fit into a narrow layout, let users navigation between them with scroll.
| Name | Type | Default | Description |
|---|---|---|---|
activeId | string | number | — | A selected tab id. |
alignment | "center" | "end" | "start" | — | Control text alignment in tab item. |
dataHook | string | — | Applied as data-hook HTML attribute that can be used in the tests. |
hasDivider | boolean | — | Specifies whether to display a divider at the bottom of the tabs when showDivider isn't set. |
horizontalPadding | boolean | true | If true, adds horizontal padding to the tabs container. |
horizontalScrollProps | HorizontalScrollCommonProps | — | Allows to pass all common horizontal scroll props. |
items (required) | Item[] | — | An array of tabs. |
minWidth | string | number | — | A minimum width of the container. |
onClick | (item: Item) => void | — | Click event handler. |
scrollOnOverflow | boolean | false | Wraps overflowing content within a scrollable container. |
showDivider | boolean | — | If true, places a divider on bottom. |
sideContent | ReactNode | — | Can be either string or renderable node. |
size | "small" | "medium" | "smallMedium" | — | One of: medium, small, smallMedium. |
type | "compact" | "compactSide" | "uniformSide" | "uniformFull" | — | One of: '', compact, compactSide, uniformSide, uniformFull. |
width | string | number | — | A specific width of a tab (only for uniformSide type) |
Import the driver matching your test environment:
| Method | Description |
|---|---|
getTitles | Gets all titles text |
clickTabAt | Clicks the tab at index |
getActiveTabIndex | Gets active tab index |
isDefaultType | Checks whether tabs type is default |
getItemsContainerType | Gets tabs container type |
getDataHook | Gets the data-hook |
getItemsWidth | Gets a set of tabs widths |
hasDivider | Checks whether tabs has a divider |
sideContent | Gets the side content |
getSideContent | — |
getItemsMaxWidths | Gets tabs max widths |
getItemsMinWidths | Gets tabs min widths |
isTabDisabled | Checks whether the tab at index is disabled |
exists | Checks whether the component found with the given data hook. |
element | Gets the component root element. |
click | Clicks on the component root element. |
base | Returns UniDriver for the base element. |
disabled prop to Item — renders the tab in a visually muted state and prevents interaction while keeping it focusable. (#16744) — has visual changesLast updated: 22 October 2026