Skip to content
Eskais UI

Navigation

Topbar

The header of an application screen: full width and sticky, a bottom border instead of a shadow, leading (a SidebarTrigger or a breadcrumb), centre (search or a command trigger) and trailing slots, and an optional brand. The centre collapses to `centerCompact` on narrow screens. Glass gives it a translucent chrome fill.

Example

Installation

npx shadcn@latest add @eskais/topbar

Usage

Import
import { Topbar } from "@/components/ui/topbar"

API reference

Topbar

PropTypeDefault
brandA logo or product name, before `leading`.ReactNode–
leadingA SidebarTrigger or a Breadcrumb.ReactNode–
centerSearch or a command palette trigger, centred. Hidden on narrow screens when `centerCompact` is set, so put only triggers here: a dialog renders where it is placed, so render it beside the Topbar, bound by its controller.ReactNode–
centerCompactShown instead of `center` on narrow screens, usually an icon Button that opens the same dialog through its controller.ReactNode–
trailingNotifications, appearance and the user menu.ReactNode–

Also takes <header> attributes except children.

Other exports

type TopbarProps

Agent actions

Runs agent.snapshot() from @ui-sdk/react/agent on the live preview above.