Tabs

Overview

Tabs are used to organize related content. They allow the user to navigate between groups of information that appear within the same context.

When to use:

  • Use tabs to group related information into different categories, helping to reduce cognitive load.
  • Tabs can be used to organize content such as forms, settings, and dashboards so a user does not have to navigate away from their workflow to complete their task.

When not to use:

  • Tabs should never be used for primary navigation. If tabs become too complex, consider using a standard navigation pattern.
  • Tabs should not be used to indicate progress. Use the progress indicator instead.
  • Tabs should not be used if the user is comparing information in two groups, as this would result in the user having to click back and forth to complete a task.

Demo

Props

PropertyDescriptionTypeValuesDefaultRequired
variantVariant for the tabsTabsVariant | undefined"underlined" | "filled""underlined"
tabItemsArray of tab itemsTabItem[]TabItem[]
layoutLayout for the tabs"aligned" | "spaced" | undefined"aligned" | "spaced" | undefined"aligned"
stackIconPlace the icon on top of the label or to the left of itboolean | undefinedboolean | undefined