export interface MenuOption { label: string; description?: string; badge?: string; badgeCustomClass?: string; /** @deprecated - Use MenuItem.acceleratorLabel to define the shortcut text to be shown */ accelerator?: string; acceleratorLabelTokens?: string[]; tokenDelimiter?: string; checked?: boolean; disabled?: boolean; action?: string; icon?: MenuOptionIcon; submenu?: MenuItem[]; type?: "normal"; visible?: boolean; } export interface MenuOptionIcon { src: string; /** If inlineSVG is true, menu-fisso will try to parse the src as an svg element. Please don't use it on untrusted input! */ inlineSVG?: boolean; height?: number; width?: number; crossOrigin?: "disabled" | "anonymous" | "use-credentials"; } interface MenuSeparator { type: "separator"; visible?: boolean; } export declare type MenuItem = (MenuOption | MenuSeparator) & { /** * Specify true for this item to be invisible to the callback. This means it won't have * a path and will not increment the path of any item after it. If it has a submenu, * non-virtual items in it will be treated as inline items in the parent menu. */ virtual?: boolean; }; /** * @deprecated - Use MenuItem.acceleratorLabel to define the shortcut text to be shown * TODO: Remove this when not used anymore * @param accelerator - Electron-notation accelerator string: https://electronjs.org/docs/api/accelerator * @returns platform-specific user-friendly label. E.g. `⇧⌘9` */ export declare function getAcceleratorLabelTokens(accelerator: string): string[]; export {};