Components
Navigation
Components for moving through a product and showing where you are.
Current location
The current item takes weight and a short bar, never solid blue. Side navigation uses an ink bar on a raised pill; tabs, pagination and rows use a brand bar, and rows and pages add a brand tint.
Page header
Breadcrumb, title, actions, facts and tabs at the top of a page. Actions that no longer fit beside the title move under it. Tabs for sections of the same object sit at the bottom.
Use
- An
<h1>for the title. - Up to three visible actions, primary last; the rest under More actions.
- Facts: status, identifier, owner, last change.
data-sg-tabsaround the header and panels when there are tabs.
Avoid
- A second page title inside the first panel.
- Section actions, like "Add document": put them in the section.
- Tabs that go to other pages: use the navigation.
Component tokens
Split view
Panes side by side in one raised frame, for a list and its open item. Each pane has an optional head and foot; its body scrolls. Below 64rem of frame width the details pane hides; below 40rem one pane shows at a time, with a back button, and focus follows. The split fills the height under the page header.
Use
data-sg-split-show="main"on items that open in the main pane.sg-split__backwithdata-sg-split-show="list"in the main pane's head.sg-split__main--canvaswhen the main pane holds raised items, like messages.- At most one primary button per pane.
- The details also elsewhere, like a drawer.
Avoid
- A split for a single table.
- Panels or cards inside a pane: use headings and hairlines.
- More than three panes.
Component tokens
Tabs
Switch between panels of one object. Tabs are one tab stop: Left and Right move, Home and End jump, and the panel follows. The selected tab is semibold with a 2px brand bar; its width is reserved. The new panel fades in.
Closable tabs
For workspaces with several tickets open. Close with the cross, Delete on the focused tab, or a middle click. Focus moves to the next tab. The product can refuse, such as for an unsent reply.
Use
- Two to six tabs with short noun labels.
- Sections of one record or view.
Avoid
- Tabs that go to other pages: use navigation links.
- Required steps hidden in tabs.
Accessibility: role="tablist", role="tab" with aria-selected and aria-controls, role="tabpanel" with aria-labelledby. Roving tabindex; arrow keys activate.
Component tokens
Tree view
A hierarchy such as departments or folders. It is one tab stop: the arrows move, Right opens or steps in, Left closes or steps out to the parent, Enter selects. Selection uses the brand tint and bar.
Use
- Hierarchies deeper than two levels.
sg:treeselectto show the selected branch beside the tree.- A toggle span in every row, leaves included.
Avoid
- A tree for two levels: use grouped navigation.
- Links or buttons inside rows.
Component tokens
Stepper
Progress through a task in steps. Done steps show a check and link back; the current step has the brand tint and ring; steps ahead are outlined. Steps stack when narrow.
Use
- Three to six steps, each a noun.
- A final review step before saving.
aria-current="step"on the current step.
Avoid
- Links to steps that are not ready.
- A stepper for two steps: use one page with two sections.
Component tokens
Accordion
Sections of a long record, opened one at a time. Built on native <details>; a shared name keeps one open. Use sg-accordion--flush inside a panel or drawer.
Use
- Summaries with a count, date or state.
- The first section open.
Avoid
- Required fields in a closed section.
- Nested accordions.
Component tokens
Pagination
Fixed pages of a stable size, with the range and total in words. Work queues never use infinite scroll.
Use page sizes of 25, 50 or 100, chosen by the person. Avoid "load more" on data people act on in order.
Component tokens
Command palette
Jump to a record or run an action by typing. Ctrl K (Cmd K on a Mac) opens it anywhere. Focus stays in the field; the arrows move through results and Enter runs one. Typed letters are underlined in each result.
Use
- Groups in a fixed order: records, actions, places.
data-hreffor options that navigate;sg:commandfor the rest.- The same actions on screen too.
Avoid
- Destructive actions without a confirm dialog.
- More than about 50 results: search on the server.
Component tokens
Skip link and landmarks
Every page starts with a skip link, hidden until focused. Each page has one <h1>, one <main> and a named landmark per navigation region.