- Docs
- Components
- Console frame
Page header
The head of a console page: where it sits, its title and count, actions, key numbers and tabs, on a ruled band.
- Import
- @qeetrix/react/experimental
- Status
- ExperimentalSince 0.0.4
- Renders
<h1>Server-rendered- Tested
- WCAG 2.2 AAaxe on every pull request
01
Import
// Experimental: from the package's experimental entry, until it's stable.
import { PageHeader, PageHeaderBack, PageContent } from "@qeetrix/react/experimental";02
Props
And every native attribute of the element it renders.
| Prop | Type | Default | What it does |
|---|---|---|---|
title | ReactNode | required | The page title: the page's one <h1>. |
headingLevel | 1 | 2 | 3 | 4 | 5 | 6 | 1 | The title's level, inside another page: a preview, a docs example. It looks the same. |
leading | ReactNode | — | A record's logo or Avatar (decorative) before the title, outside the heading. |
breadcrumb | ReactNode | — | Where the page sits: a Breadcrumb. |
back | ReactNode | — | A PageHeaderBack, for a page one level down; instead of a breadcrumb. |
count | ReactNode | — | A number beside the title, formatted for the locale. |
status | ReactNode | — | A Badge beside the title. |
description | ReactNode | — | One line under the title. |
actions | ReactNode | — | Buttons at the end: the primary last. |
summary | ReactNode | — | A StatGroup, edge to edge under the title. |
tabs | ReactNode | — | A TabsList at the foot, its rule edge to edge. |
PageHeaderBack: href · render · children | … | "Back" | An arrow and the parent's name, read "Back to Users". |
PageContent: width | "full" | "narrow" | "full" | full for tables; narrow, 800px, for forms and records. |
03
Parts
Each part carries a data-slot, for tests and placement.
| data-slot | Element | What it is |
|---|---|---|
page-header | <div> | The ruled band. |
page-header-count | <span> | The count. |
page-header-description | <p> | The line under the title. |
page-header-actions | <div> | The actions. |
page-header-summary | <div> | The key numbers. |
page-content | <div> | The work surface: data-width. |
04
Inside another page
A preview in a drawer keeps the page's outline: headingLevel under the drawer's title.
<DrawerContent title="Preview">
<DrawerBody>
<PageHeader headingLevel={3} title="Webhooks" actions={<Button>Add endpoint</Button>} />
</DrawerBody>
</DrawerContent>