Skip to main content

Breadcrumbs Ready

Breadcrumbs are used to visualize the path to the currently open resource. It is designed to be used with header or footer.

Examples #

Open in new window
<duet-breadcrumbs class="duet-example-without-padding">
<span><duet-breadcrumb href="/" icon="damage-home" accessible-label="Etusivu"></duet-breadcrumb></span>
<span><duet-breadcrumb href="/edut-ja-kampanjat">Edut ja kampanjat</duet-breadcrumb></span>
<span><duet-breadcrumb>LähiTapiola Pirkanmaa</duet-breadcrumb></span>
</duet-breadcrumbs>

<script>
const breadcrumb = document.querySelector("duet-breadcrumb")
breadcrumb.addEventListener("click", e => {
e.preventDefault()
console.log("Default prevented")
})
</script>

Properties #

Property Attribute Description Type Default
color color Custom color to be used for text, as a design token entered in camelCase or kebab-case. Example: "color-primary". string ""
theme theme Theme "" | "default" | "turva" ""
variation variation Variation "footer" | "header" | "plain" "header"

Usage #

This section includes guidelines for designers and developers about the usage of this component in different contexts.

When to use #

  • When you need to show a path to the currently open page.
  • When you want to to give an easy to way to navigate back to previous resources.
  • When you have deep navigation structures.

When not to use #

  • Don't replace heading or footer elements with breadcrumbs.

Accessibility #

This component has been validated to meet the WCAG 2.1 AA accessibility guidelines. You can find additional information regarding accessibility of this component below.

SSR #

Until it's fixed in the StencilJS framework every duet-breadcrumb component needs to be wrapped in a html element to render properly on the server side.
More details: https://github.com/ionic-team/stencil/issues/3413#issuecomment-1834616059


Integration

For integration, event and theming guidelines, please see Using Components. This documentation explains how to implement and use Duet’s components across different technologies like Angular, React or Vanilla JavaScript.

Integration guidelines


Tutorials

Follow these practical tutorials to learn how to build simple page layouts using Duet’s CSS Framework, Web Components and other features:

Tutorials

Building Layouts

Tutorials

Using CLI Tools

Tutorials

Creating Custom Patterns

Tutorials

Server Side Rendering

Tutorials

Sharing Prototypes

Tutorials

Usage With Markdown


Troubleshooting

If you experience any issues while using a component, please head over to the Support page for more guidelines and help.