<cs-breadcrumb>
StableNavigationSince 0.1

Breadcrumbs display a trail of links that show users where they are in a site's hierarchy. They help users understand the current location and navigate back to parent pages.

Catalog Clothing Women's Shirts & Tops

Breadcrumbs are usually placed before a page’s main content with the current page shown last to indicate the user’s position in the navigation.

Examples

By default, breadcrumb items are rendered as buttons so you can use them to navigate single-page applications. In this case, you’ll need to add event listeners to handle clicks.

For websites, you’ll probably want to use links instead. You can make any breadcrumb item a link by applying an href attribute to it. Now, when the user activates it, they’ll be taken to the corresponding page — no event listeners required.

The last item represents the current page. Use href="" so it points at itself — <cs-breadcrumb> will mark it with aria-current="page" and style it as non-interactive for you.

Homepage Our Services Digital Media Web Design

Start & End Decorations

Use the start and end slots to add presentational elements like <cs-icon> next to any breadcrumb item.

Home Articles Traveling

Separator

Use the separator slot to change the separator that goes between breadcrumb items. Icons work well, but you can also use text or an image.

First Second Third
First Second Third
/ First Second Third

Colors

Breadcrumb labels match the color set on <cs-breadcrumb-item>. Content in the start, end, and separator slots can be styled using CSS parts.

Home Articles Traveling

Dropdown menus can be placed in the default slot to provide additional options.

Homepage Web Design Web Development Marketing Our Services Digital Media

API

Importing

If you're using the autoloader or a hosted project, components load on demand — no manual import needed. To cherry-pick this component, use one of the following snippets.

npm Self-Hosted React
import '@cruglobal/cornerstone-components/components/breadcrumb/breadcrumb.js';
import './cornerstone/components/breadcrumb/breadcrumb.js';
import CsBreadcrumb from '@cruglobal/cornerstone-components/react/breadcrumb/index.js';

Slots

Learn more about using slots.

NameDescription
(default)One or more breadcrumb items to display.
separatorThe separator to use between breadcrumb items. Works best with <cs-icon>.

Attributes & Properties

Learn more about attributes and properties.

PropertyAttributeDescriptionTypeDefaultReflects
labellabelThe label to use for the breadcrumb control. This will not be shown on the screen, but it will be announced by screen readers and other assistive devices to provide more context for users.string''

CSS Parts

Learn more about CSS parts.

NameDescriptionCSS selector
breadcrumbThe component's outer wrapper.::part(breadcrumb)

Dependencies

This component automatically imports the following elements. Sub-dependencies, if any exist, are included in this list.