/** * Menubar - a horizontal bar of menu buttons (like a desktop app's * File / Edit / View). Each `MenubarMenu` is a `DropdownMenu` instance, so the * dropdown surface, outside-click / `Escape` dismissal, and token-scoped * portalling are all inherited unchanged. Menubar adds the horizontal bar * container, `role="menubar"`, and roving focus between the top-level triggers: * `ArrowRight` / `ArrowLeft` move focus (and carry an open menu) across * triggers, `Home` / `End` jump to the ends. Only one menu is open at a time - * the bar owns that state. Skinned entirely with veryfront theme tokens. * * @example * ```tsx * import { * Menubar, * MenubarContent, * MenubarItem, * MenubarMenu, * MenubarSeparator, * MenubarTrigger, * } from "veryfront/ui"; * * function AppMenubar() { * return ( * * * File * * console.log("new")}>New * console.log("open")}>Open… * * console.log("save")}>Save * * * * Edit * * console.log("undo")}>Undo * console.log("redo")}>Redo * * * * ); * } * ``` * * @module react/components/ui/menubar */ import * as React from "react"; import { type DropdownMenuContentProps, type DropdownMenuItemProps } from "./dropdown-menu.js"; /** Props accepted by ``. */ export interface MenubarProps extends React.HTMLAttributes { /** The `MenubarMenu` children that make up the bar. */ children: React.ReactNode; /** React 19: ref is a regular prop - points at the bar's `role="menubar"` node. */ ref?: React.Ref; } /** Menubar root - the horizontal `role="menubar"` container that owns open + roving-focus state. */ export declare function Menubar({ children, className, ref, ...props }: MenubarProps): React.ReactElement; /** Props accepted by ``. */ export interface MenubarMenuProps { /** The `MenubarTrigger` and `MenubarContent` for this one menu. */ children: React.ReactNode; /** Stable identifier for this menu; auto-generated when omitted. */ value?: string; } /** One menu in the bar - a `DropdownMenu` whose open state the bar controls. */ export declare function MenubarMenu({ children, value }: MenubarMenuProps): React.ReactElement; /** Props accepted by ``. */ export interface MenubarTriggerProps extends React.ButtonHTMLAttributes { /** The trigger label (usually a word like "File" or "Edit"). */ children: React.ReactNode; /** React 19: ref is a regular prop - points at the trigger button. */ ref?: React.Ref; } /** Top-level menu button - `role="menuitem"` with `aria-haspopup`, part of the roving-focus group. */ export declare function MenubarTrigger({ children, className, disabled, onKeyDown, onFocus, ref, ...props }: MenubarTriggerProps): React.ReactElement; /** Props accepted by ``. */ export interface MenubarContentProps extends DropdownMenuContentProps { /** The `MenubarItem` / `MenubarSeparator` children of this menu's dropdown. */ children: React.ReactNode; } /** The dropdown surface for one menu - reuses the `DropdownMenuContent` machinery. */ export declare function MenubarContent({ children, onKeyDown, ...props }: MenubarContentProps): React.ReactElement | null; /** Props accepted by ``. */ export interface MenubarItemProps extends DropdownMenuItemProps { /** The item label / content. */ children: React.ReactNode; } /** A selectable item inside a menu - `role="menuitem"`; selecting it closes the menu. */ export declare function MenubarItem({ children, ...props }: MenubarItemProps): React.ReactElement; /** Props accepted by ``. */ export interface MenubarSeparatorProps { /** Extra classes merged onto the divider. */ className?: string; } /** A horizontal divider between groups of items inside a menu. */ export declare function MenubarSeparator({ className }: MenubarSeparatorProps): React.ReactElement; //# sourceMappingURL=menubar.d.ts.map