Tabs allow users to navigation between grouped content in different views while within the same page context.

Preview

Variants

Default

Borderless

Add a d-tablist--no-border to remove the bottom border of any tablist. Handy for small tablists and tablists serving as subtabs to a larger menu.

Inverted

Add d-tablist--inverted when you want to display tabs on inverted background.

Disabled

Sizes

Default

Small

Advanced Usages

Validation Before Changing Tabs

If you need to do some validation before changing tabs, you can use the before-change event. If the event handler is prevented, the tab change will be cancelled.

Vue API

Tab Group

Slots

Name
Description
default

Default slot for Panel

tabs

Slot for Tabs

Props

Name
Description
Default
borderless

If true, applies borderless styles to the tab group

Type: boolean
Values: truefalse
false
disabled

If true, disables the tab group

Type: boolean
Values: truefalse
false
inverted

If true, applies inverted styles to the tab group

Type: boolean
Values: truefalse
false
label

Identifies the tab group

Type: string
''
selected

The id of the selected tab panel which should be displayed

Type: string
''
size

If provided, applies size styles to the tab group

Type: string
Values: defaultsm
'default'
tabListChildProps

Pass through props, used to customize the tab list

Type: object
{}
tabListClass

Pass through classes, used to customize the tab list

Type: string|array|object
''

Events

Name
Description
before-change

Before change tab event with the event argument, useful to perform validations and prevent changing tabs if neccessary.

Type: Event
change

Change tab event with the arguments: selected id of the current tab and disabled value

Type: Object

Tab Panel

Slots

Name
Description
default

Default slot for Tab Panel

Props

Name
Description
Default
id
required

Id of the panel

Type: string
tabId
required

Id of the associated tab

Type: string
hidden

If true, hides the tab content

Type: boolean
Values: truefalse
false
tabPanelClass

Used to customize the tab element

Type: string|array|object
''

Tab

Slots

Name
Description
default

default slot, defaults contains dt-button

Props

Name
Description
Default
id
required

Id of the tab

Type: string
panelId
required

Id of the associated content panel

Type: string
disabled

If true, disables the tab

Type: boolean
Values: truefalse
false
label

Describes the tab

Type: string
''
selected

Controls the state of the tab

Type: boolean
Values: truefalse
false
tabClass

Used to customize the tab element

Type: string|array|object
''

Events

Name
Description
click

Native button click event

Type: PointerEvent | KeyboardEvent
focus

Native button focus in event

Type: FocusEvent

Classes

Class
Applies to
Description

Accessibility

To create accessible tabs, be sure to implement the proper keyboard navigation and utilize the following ARIA roles to properly declare element roles, content relationships, and current status:

Item
Applies to
Description
Tabs documentation last updated Thursday, June 11, 2026