Breadcrumbs

DBreadcrumb renders the breadcrumbs container and DBreadcrumbItem a crumb — with a Href it becomes a link, without one it marks the current page.

Basic
<DBreadcrumb>
    <DBreadcrumbItem Href="components/buttons">Buttons</DBreadcrumbItem>
    <DBreadcrumbItem Href="components/badges">Badges</DBreadcrumbItem>
    <DBreadcrumbItem>DBreadcrumb</DBreadcrumbItem>
</DBreadcrumb>
With icons
<DBreadcrumb>
    <DBreadcrumbItem Href="/">
        <span class="flex items-center gap-1">
            <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" viewBox="0 0 24 24" fill="none"
                 stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                <path d="m3 9 9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z" />
            </svg>
            Home
        </span>
    </DBreadcrumbItem>
    <DBreadcrumbItem Href="components/cards">Cards</DBreadcrumbItem>
    <DBreadcrumbItem>Current</DBreadcrumbItem>
</DBreadcrumb>
Long trail
<DBreadcrumb Class="text-sm">
    @foreach (var name in new[] { "Docs", "Components", "Navigation", "Examples", "v2.1" })
    {
        <DBreadcrumbItem Href="@($"components/breadcrumbs#{name.ToLowerInvariant()}")">@name</DBreadcrumbItem>
    }
    <DBreadcrumbItem>Breadcrumbs</DBreadcrumbItem>
</DBreadcrumb>

API

DBreadcrumb

Parameters

Name Type Default Binding Description
ChildContent RenderFragment — — The breadcrumb trail items ( DBreadcrumbItem or raw li markup).
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
DBreadcrumbItem

Parameters

Name Type Default Binding Description
Href string — — Optional link target. When null the item renders as plain text (the conventional way to mark the current page).
ChildContent RenderFragment — — The item content (text and/or icon markup).
Class string — — Additional CSS classes appended to the component's computed daisyUI classes.
Style string — — Inline styles applied to the root element.
Connection lost — reconnecting…
Connection failed.
The server has stopped.