ValyroUI English version

Navbar

Верхняя навигация. Бесплатно, MIT · Навигация и каркас › Каркас

Установка

npx valyro-cli@latest add navbar
npx shadcn@latest add https://valyro.xyz/r/navbar.json
npm install valyro-ui

import 'valyro-ui/styles.css';
import { Navbar } from 'valyro-ui';

Пропсы

PropTypeDefault
brandReactNodeLogo / product name on the left.
linksNavbarLink[][]Navigation links in the center; each renders as an anchor with href, else a button.
actionsReactNodeRight-side slot: buttons, avatar, search. Stays visible on narrow widths.
stickybooleanfalseStick to the top of the nearest scroll container.
labelstring'Main'Accessible name of the links navigation.
menuLabelstring'Menu'Accessible name of the button that opens the links on narrow widths.
menuOpenbooleanWhether the links sheet is open (narrow widths only; controlled).
defaultMenuOpenbooleanfalseInitial state of the links sheet when uncontrolled. Opening it this way does not move focus into it.
onMenuOpenChange(open: boolean) => voidCalled when the links sheet opens or closes.

Похожие компоненты

Назад: App Shell · Далее: Sidebar · Весь раздел «Навигация и каркас»