Components
Breadcrumb
Page heading that shows the current page as the title with its parent pages in front of it.
import { Breadcrumb } from "@openperf/deft";
<Breadcrumb.Root aria-label="Breadcrumb">
<Breadcrumb.Item href="/releases">Releases</Breadcrumb.Item>
<Breadcrumb.Separator />
<Breadcrumb.Current>2.4.0</Breadcrumb.Current>
</Breadcrumb.Root>;Anatomy
<Breadcrumb.Root>
<Breadcrumb.Text /> {/* parent without a page of its own */}
<Breadcrumb.Separator /> {/* not inserted automatically */}
<Breadcrumb.Item /> {/* link to a parent page */}
<Breadcrumb.Separator />
<Breadcrumb.Current /> {/* the page title */}
</Breadcrumb.Root>Breadcrumb.Root is an unlabeled navigation landmark, so pass aria-label. Breadcrumb.Current renders the <h1> of the page: add no other heading for the same title, and on a top-level page render it alone.
Overflow
Parents never wrap. The current page is cut with an ellipsis when it does not fit, so pass title to Breadcrumb.Current when the full text matters.
Router link
Breadcrumb.Item renders an <a>; pass a router link through render:
<Breadcrumb.Item render={<Link to="/releases" />}>Releases</Breadcrumb.Item>API
Breadcrumb.Item
Prop
Type
The other parts declare no props of their own; Breadcrumb.Separator takes none at all.