Skip to content

Tab ​

A Tab is one of the selectable items included within Tabs.

NameValue
Props
disabled
tabName
label
Slots
default
View
Reading direction

Overview ​

When to use Tab ​

Two or more Tab items are grouped to create a Tabs component. Tab items cannot be used individually. For example, different Tab items can represent the different sections of an article.

About Tab ​

Tab includes the following elements.

Label ​

Content ​

Tab content appears underneath the Tab when selected, and can include any type of content or components.

Technical implementations ​

Vue usage ​

This component can display arbitrary content, including markup, via its default slot. The provided content is wrapped in a <section> tag and given an HTML ID.

Must be used with Tabs component

This component is only meant to be used inside the default <slot> of the <Tabs> component. It cannot be used as a standalone component. See the Tabs documentation for more information.

Props ​

Prop nameDescriptionTypeDefault
name(required)String name of the tab, used for programmatic selection. Each Tab inside a layout must have a unique name. This prop will also be used as the tab label if no "label" prop is provided.string
labelLabel that corresponds to this Tab in the Tabs component's header. Lengthy labels will be truncated.string''
disabledWhether or not the tab is disabled. Disabled tabs cannot be accessed via label clicks or keyboard navigation.booleanfalse

Slots ​

NameDescriptionBindings
defaultTab content

CSS-only version ​

See the Tabs page to learn how to build a CSS-only tabbed layout.