日本語

Navigation / Context & actions

Topbar

Bring breadcrumbs, theme controls, and the mobile navigation toggle into one document header.

Basic usage

Preview
HTML
<header class="topbar">
  <nav class="breadcrumbs" aria-label="Example breadcrumbs">
    <a href="../">Components</a><span class="breadcrumb-sep">/</span><span class="breadcrumb-current">Topbar</span>
  </nav>
  <div class="topbar-tools"><button class="btn" data-dd-theme-toggle data-dd-enhance hidden aria-label="Switch theme">◐</button></div>
</header>

Classes & attributes

Class / attributePurpose
.topbarThe sticky document header.
.breadcrumbs / .breadcrumb-sep / .breadcrumb-currentBreadcrumb links, separators, and current location.
.topbar-toolsA row of page actions.
.nav-toggle / data-dd-nav-toggleToggles the mobile sidebar. Place it inside doc.

Usage notes

Give separate breadcrumb navigations distinct aria-label values when a page contains more than one.

Examples follow your system color scheme. Use ◐ in the header to try automatic, light, and dark themes.