Skip to content

Breadcrumb

Navigation breadcrumb trail with configurable separators. Highlights the last item as the current/active page.

Import

tsx
import { Breadcrumb } from "silvery"

Props

PropTypeDefaultDescription
itemsBreadcrumbItem[]requiredBreadcrumb items (left to right)
separatorstring"/"Separator character between items
ts
interface BreadcrumbItem {
  label: string
}

Rendering

The last item is rendered in bold $fg as the current location. Preceding items are rendered in $muted.

Usage

tsx
<Breadcrumb items={[{ label: "Home" }, { label: "Settings" }, { label: "Profile" }]} separator=">" />
// Renders: Home > Settings > Profile

See Also

  • Tabs -- tabbed navigation

Released under the MIT License.