import { type AnyOption, type Option } from "./Autocomplete.types"; export declare enum KeyboardAction { Previous = -1, Next = 1, Select = 0 } /** * Hook to handle custom keyboard navigation for the Autocomplete component. * Use this hook if you are using components in the menu that aren't MenuOption or BaseMenuOption. */ export declare function useCustomKeyboardNavigation({ onRequestHighlightChange, }: { onRequestHighlightChange?: (event: KeyboardEvent, direction: KeyboardAction) => void; }): void; /** * Hook to handle keyboard navigation for the Menu in the Autocomplete component. * If using components in the menu that aren't MenuOption or BaseMenuOption, you should use the `useCustomKeyboardNavigation` hook. */ export declare function useKeyboardNavigation({ options, onOptionSelect, menuRef, visible, }: { options: GenericOption[]; visible?: boolean; menuRef?: HTMLElement | null; onOptionSelect: (option?: GenericOptionValue) => void; }): { highlightedIndex: number; }; /** * Function to get the requested index change based on the current highlighted index and the direction of the keyboard action. * Accounts for groups in the options array. */ export declare function getRequestedIndexChange({ event, options, direction, highlightedIndex, }: { event: KeyboardEvent; direction: KeyboardAction; options: T[]; highlightedIndex: number; }): number;