Menu

Navigationskomponenten, die eine reaktionsschnelle und flexible Struktur für die Navigation auf der obersten Ebene der App bieten, einschließlich Unterstützung für Dropdown-Untermenüs und verschiedene Layouts (Desktop oben, Seitenleiste, untere Registerkarte).

Wann verwenden

Das Navigationsmenü ist wichtig für eine Website, es hilft Benutzern, schnell von einem Bereich zum anderen zu springen. Meistens umfasst es eine obere Navigation und eine seitliche Navigation. Die obere Navigation bietet alle Kategorien und Funktionen der Website. Die seitliche Navigation bietet die mehrstufige Struktur der Website.

Desktop-Navigation oben

Eine klassische obere Navigationsleiste, die für Desktop-Layouts geeignet ist und die Variante `desktopTop` verwendet.

Seitenleisten-Navigation

Eine vertikale Navigationsstruktur, die typischerweise in Dashboards verwendet wird.

Mobile Navigation oben

Eine obere Navigationsleiste, die speziell für mobile Layouts entwickelt wurde.

Mobile Content

Untere Registerkarten-Navigation

Wird häufig in mobilen Anwendungen verwendet und platziert Navigationselemente am unteren Bildschirmrand.

API Reference

Eigenschaft
Beschreibung
Typ
Standard

variant

The layout variant of the navigation bar. 'bottomTab' | 'mobileTop' | 'desktopSide' | 'desktopTop' 'bottomTab'

class

Additional CSS classes to apply to the Menu. string -
Eigenschaft
Beschreibung
Typ
Standard

variant

The styling variant of the navigation item. 'sidebar' | 'sidebarActive' | 'bottomTab' | 'bottomTabActive' | 'desktopTop' | 'desktopTopActive' 'sidebar'

label

The text label for the navigation item. string -

href

The URL the item links to. string -

icon

The name of the Lucide icon to display. IconName -

showChevron

Whether to show a chevron icon when a submenu is present. boolean true

disabled

Whether the item is disabled. boolean false

nested

Whether this menu item is nested inside another menu item, adjusting its submenu placement. boolean false

class

Additional CSS classes to apply to the NavItem. string -