Skip to content

Navigation chrome ​

The fixed navigation around every page: the nav rail, the page header's breadcrumb and the record stepper.

navigation-navrail--closedOpen in Storybook ↗

When to use ​

  • The nav rail is on every page; its items come from the tenant's main menu.
  • The breadcrumb and record stepper sit in the page header and fill themselves from where people came from.

When not to use ​

Anatomy ​

Nav rail

  1. Top: the logo (--nav-rail-logo, links home), an environment chip outside production, and the mode button that keeps the menu open or collapses it.
  2. Items: an icon per item (--nav-rail-item-width by --nav-rail-item-height, --nav-rail-item-radius), an optional count badge, and the label once the menu is open. A group has sub-items.
  3. Account: the user as a circle with their initials (--nav-rail-avatar-size) and Log out; Log in when signed out.

Closed, the rail is --nav-rail-width wide. Kept open it is --nav-flyout-width wide and the page moves aside by the same width, so nothing is covered.

Page header

  1. Breadcrumb: grey pill capsules (--crumb-pad, --radius-pill) joined by a light ›. With more than one earlier page, a counted … capsule opens the list of earlier pages. The previous page is a link; the current page ends the trail, unlinked and never cut off, after its type badge when it has one.
  2. Record stepper: ‹ 3 of 128 › in one capsule (--stepper-pad), with ghost icon buttons (--stepper-button-size). It shows on a record opened from a list and steps through that list.
  3. Header extras: the language dropdown, the tenant dropdown where tenants are on, and the search.

Variants ​

VariantWhereBehaviour
Closed raildefault from 48rem upicons only; the label shows in a tooltip at once; a group opens a flyout beside its icon
Open railafter Keep menu openicons with labels; groups open inline under their row
Top bar and drawerbelow 48rema top bar (--mobile-top-bar-height) with a menu button, logo and search; the menu opens as a --nav-drawer-width drawer over a dimmed page
navigation-navrail--openOpen in Storybook ↗
navigation-navrail--mobile-drawerOpen in Storybook ↗

The mode is remembered per browser. In the drawer, the language and tenant dropdowns sit above the account rows, and a dot on the menu button shows when an item has a badge.

A group's flyout (--menu-padding, at least --menu-min-width) lists the group name as a small title and the sub-items below it. When the group has a page of its own, the title links to it. It closes on Escape, a click outside, picking a sub-item or navigating.

States ​

StateWhat you seeTrigger
Restingmuted icon and label—
Hover--color-accent-highlight fillpointer
Current--color-accent-light fill, --color-accent-inkthe current page; a group is current when one of its sub-items is
Group openchevron down (open rail) or flyout (closed rail)clicking the group
Badgecount after the label, or on the icon's corner when closed; 99+ above 99the item has new things
Stepper at an endthat arrow disabledfirst or last record of the list
Earlier pageslist of earlier pages under the … capsuleclicking the capsule
components-breadcrumb--history-openOpen in Storybook ↗

Only one group is open at a time. Clicking a group with a page of its own in the open rail also goes to that page.

Keyboard & accessibility ​

  • The rail is a <nav> named Main navigation. Items are links with aria-current="page" on the current one; items that open a form are buttons.
  • Groups are disclosure buttons with aria-expanded and aria-controls. The flyout holds plain links, so Tab moves through them in order. Escape closes it and returns focus to the group.
  • Closed, each item keeps its label as hidden text, so its name is the label plus the badge count.
  • The mode button is named after what it does: Keep menu open or Collapse menu.
  • In the drawer, focus moves to the close button on open and back to the menu button on close. Escape closes the drawer. The page behind it, and the closed drawer, are inert.
  • The breadcrumb is a <nav> named Breadcrumb; the current page has aria-current="page". The … capsule is a button with aria-expanded, named Earlier pages.
  • The stepper is a group named Position in the result list. Its arrows are named Open previous and Open next, and Alt + ← or → steps outside text fields. The position is role="status".

Content ​

  • Menu labels are short nouns for the destination: Library, Media.
  • The stepper reads {index} of {total}.
  • Translation keys: navigation.* and entity-navigation.*.

Tooltip · Dropdown · Overflow menu · Chip & badge · Accessibility

Powered by Elody - Open Source Semantic Data Platform