import { ComponentPublicInstance, Ref } from 'vue'; import { FluxMenuFlyoutCone, FluxMenuFlyoutInjection } from '../../data'; export type UseMenuFlyoutProviderOptions = { readonly debugCone: Ref; readonly onCloseAll?: () => void; }; export type UseMenuFlyoutOptions = { readonly triggerRef: Ref; readonly popupRef: Ref; readonly disabled?: Ref; }; export type UseMenuFlyoutReturn = { readonly context: FluxMenuFlyoutInjection | null; readonly cone: Ref; readonly isOpen: Ref; closeAll(): void; focusTrigger(): void; onPopupKeydown(evt: KeyboardEvent): void; onTriggerClick(evt: MouseEvent): void; onTriggerKeydown(evt: KeyboardEvent): void; }; /** * Creates and provides the shared menu-flyout context for an entire open menu tree. Used by the * outermost menu surface (FluxContextMenu, or a standalone root FluxMenu). Tracks the pointer, the * active prediction cone, the keyboard-trap stack and the set of teleported flyout popups so that * click-outside and close-all can reason about the whole tree. */ export declare function useMenuFlyoutProvider(options: UseMenuFlyoutProviderOptions): FluxMenuFlyoutInjection; /** * Returns the shared menu-flyout context, creating (and providing) a new root context when none * exists higher up the tree. Used by FluxMenu so that a standalone menu becomes the root while a * menu nested inside a FluxContextMenu or another flyout inherits the existing context. */ export declare function useMenuFlyoutContext(options: UseMenuFlyoutProviderOptions): FluxMenuFlyoutInjection; /** * Per-flyout open/close and prediction-cone behaviour for FluxMenuFlyout. Submenus open instantly on * hover. They stay open while the pointer is over the trigger/popup (or an open descendant), aiming at * the submenu through the forward cone (a safe triangle whose apex trails the pointer and whose base * widens with speed) or travelling back to the opener through the return corridor (briefly, after * leaving the popup). The instant any of those stops holding the submenu closes immediately — the * trailing anchor and speed-widened cone absorb overshoot, so there is no extra close delay. */ export default function useMenuFlyout(options: UseMenuFlyoutOptions): UseMenuFlyoutReturn;