Breadcrumbs

The Breadcrumbs component provides a navigational hierarchy for users to track and traverse their location within an application.

Usage

Default

<Breadcrumbs items={[{ label: "Home", href: "/" }, { label: "Library", href: "/library" }, { label: "Data", href: "/library/data" }]} />

Truncated


<Breadcrumbs
  items={[
    { label: "Home", href: "/" },
    { label: "Category", href: "/category" },
    { label: "Subcategory", href: "/category/sub" },
    { label: "Details", href: "/category/sub/details" },
    { label: "Final Page" }
  ]}
  maxVisible={3}
/>

Props

Data table
TypeDescription
aria-describedbystringOptional ID of another element that describes this breadcrumb navigation.
aria-labelstringAccessible label for the breadcrumb navigation. Defaults to "Breadcrumbs".
aria-labelledbystringOptional ID of another element that labels this breadcrumb navigation. Prefer this when a visible heading already exists.
classNamestringAdditional class name for custom styling.
data-testidstringOptional test ID for testing frameworks.
disabledbooleanDisables interaction and styles as disabled.
itemsBreadcrumb[]An array of breadcrumb items.
maxVisiblenumberMaximum number of visible items before collapsing into an ellipsis.
outlinebooleanWhether to use the outline style.
roundingRoundingTypeRounding style to apply to the breadcrumbs ('none' | 'small' | 'medium' | 'large' | 'full').
separatorReactNodeOptional custom separator node between breadcrumb items. Defaults to a right chevron icon.
shadowShadowTypeShadow style to apply to the breadcrumbs ('none' | 'light' | 'medium' | 'strong' | 'intense').
sizeSizeTypeSize of the breadcrumbs ('xs' | 'small' | 'medium' | 'large' | 'xl').
stateStateTypeState of the breadcrumbs ('success' | 'error' | 'warning' | 'disabled' | ''). Used for visual feedback.
themeThemeTypeTheme style to apply to the breadcrumbs ('primary' | 'secondary' | 'tertiary' | 'quaternary' | 'clear').