Skip to content
daisyBlazor

Dock

A daisyUI dock: the bottom navigation bar of mobile apps, made of DockItem buttons or links with an icon and an optional label. It is fixed to the bottom of the viewport; add Class="relative" to keep it inside a container.
Navigation.dock
Cover · <Dock>

Northwind Traders

Enterprise plan · 42 seats

Examples

Active item

Active marks the selected DockItem; track it in your own state and set it from OnClick.

Current tab: Home

website/Examples/Navigation/DockBasicExample.razor Source

Sizes

Size maps to dock-xs through dock-xl; leave it null for daisyUI's default height.

website/Examples/Navigation/DockSizesExample.razor Source

API

<Dock>

DaisyBlazor

Parameters

  • Fixed bool
    = true

    When true (default) the dock is fixed to the viewport bottom; false places it inline (position: relative).

  • Size DockSize?
    = null

    Controls the dock height via daisyUI size modifiers (dock-xs … dock-xl). Null means no modifier (default daisyUI size).

  • Class string
    = null

    Extra CSS classes merged onto the .dock element.

  • Style string
    = null

    Inline CSS style applied to the .dock element.

Content

  • ChildContent RenderFragment

    Items to render inside the dock (use DockItem components).

<DockItem>

DaisyBlazor

Parameters

  • Active bool
    = false

    Marks this item as the currently active/selected dock entry (dock-active; aria-current="page" on links, "true" on buttons).

  • AriaLabel string
    = null

    Accessible name for an icon-only item. Used when no visible Label is set (a visible label already names the control). When both are empty no aria-label is emitted.

  • Href string
    = null

    When set the item renders as an <a> element pointing to this URL; otherwise a <button> is rendered.

  • Icon string
    = null

    Material Symbol ligature name (e.g. Icons.Material.Filled.Home). When set, renders an Icon child.

  • Label string
    = null

    Optional text label rendered below the icon via the daisyUI .dock-label class.

  • Class string
    = null

    Extra CSS classes merged onto the root <a> or <button> element.

  • Style string
    = null

    Inline CSS styles applied to the root <a> or <button> element.

Events

  • OnClick EventCallback

    Click handler used when the item is rendered as a <button> (ignored when Href is set).

Something went wrong while running the docs. Reload