navigation
js/ui/components/navigation.ts
Host-neutral breadcrumbs, pagination, and step components. @internal
Interfaces
interface NavigationItem {
One labeled navigation destination.
Properties
key: string
label: string
interface BreadcrumbsProps extends StyleProps, FlexChildProps, Props {
Props accepted by {@link Breadcrumbs}.
Properties
items: readonly NavigationItem[]
onNavigate?: (key: string) => void
interface PaginationProps extends StyleProps, FlexChildProps, Props {
Props accepted by {@link Pagination}.
Properties
page: number
pages: number
onChange?: (page: number) => void
siblings?: number
Pages retained on each side of the current page; defaults to one.
interface StepsProps extends StyleProps, FlexChildProps, Props {
Props accepted by {@link Steps}.
Properties
steps: readonly NavigationItem[]
current: string
Functions
function Breadcrumbs(props: BreadcrumbsProps): VNode
Path row whose final item is the current location.
function Pagination(props: PaginationProps): VNode
Previous, numbered, and next page controls.
function paginationRange(
page: number,
pages: number,
siblings = 1,
): Array<number | 'ellipsis'>
Compute a compact page sequence containing the boundaries and a window around the current page.
function Steps(props: StepsProps): VNode
Ordered progress strip with done, current, and upcoming steps.