/**
 * Copyright (c) Adaptavist, Inc.
 */
import { GenericProps } from '../../utilities';
import { ComponentPropsWithoutRef, ReactNode } from 'react';
export interface MenuOption {
    /**
     * Prop to declare the children elements to render inside the item.
     *
     * Default is `an empty object`.
     */
    children?: React.ReactNode;
    /**
     * Prop used to specify the currently selected item in navigation.
     *
     * If set to true, the current menu item will be set as selected.
     * If set to false, nothing will happen.
     *
     * Default is `false`.
     */
    current?: boolean;
    /**
     * Prop used to specify if an item is diabled or not.
     *
     * If set to true, the current item will be set as disabled.
     * If set to false, nothing will happen.
     *
     * Default is `false`.
     */
    disabled?: boolean;
    /**
     * Prop to control if the menu should allow multiple selections.
     *
     * If set to true, the menu will allow users to choose multiple options.
     * If set to false, the menu will only allow one option to be chosen.
     *
     * Default is `false`.
     */
    isMultipleSelection?: boolean;
    /**
     * Prop to choose the icon to display inside the item.
     *
     * Default is `an empty string`.
     */
    icon?: ReactNode;
    /**
     * Prop used to decide if the item should show an interactive effect.
     *
     * Use when the hover effect is not required and the item is not disabled.
     *
     * If set to true, the item will have an interactive effect.
     * If set to false, the item will not.
     *
     * Default is `false`.
     */
    interactive?: boolean;
    /**
     * Prop to set an item key for the MenuOption.
     *
     * If the item key is not provided, them temporary item key will be `item-(n-1)`.
     *
     * Default is `item-(n-1)`.
     */
    itemKey?: string;
    /**
     * Specifies if this item should be the selected item in the `Select` 'Option'.
     *
     * If set to true, the item will be denoted as 'selected'.
     * If set to false, the item will be treated as a regular item.
     *
     * Default is `false`.
     */
    selected?: boolean;
}
export interface IMenuChangeProps {
    /**
     * Prop to denote the children elements to render inside the item.
     *
     * Default is `an empty object`.
     */
    children?: React.ReactNode;
    /**
     * Prop used to specify if an item is diabled or not.
     *
     * If set to true, the current item will be set as disabled.
     * If set to false, nothing will happen.
     *
     * Default is `false`.
     */
    disabled?: boolean;
    /**
     * Prop to control if the menu should allow multiple selections.
     *
     * If set to true, the menu will allow users to choose multiple options.
     * If set to false, the menu will only allow one option to be chosen.
     *
     * Default is `false`.
     */
    isMultipleSelection?: boolean;
    /**
     * Prop used to decide if the item should show an interactive effect.
     *
     * Use when the hover effect is not required and the item is not disabled.
     *
     * If set to true, the item will have an interactive effect.
     * If set to false, the item will not.
     *
     * Default is `false`.
     */
    interactive?: boolean;
    /**
     * Prop to set an individual menu item's key.
     *
     * Default is `item-(n-1)`.
     */
    itemKey: string;
    /**
     * The function to run on selection / deselection of an item.
     *
     * Default is `an empty object`.
     */
    onChange?: (props: IMenuChangeProps | string[]) => void;
    /**
     * Prop to denote the currently selected item(s) in the menu.
     *
     * Default is `an empty object or string`.
     */
    selectedItem?: string | string[];
}
export type IMenu = Omit<ComponentPropsWithoutRef<'ul'>, 'onChange'> & GenericProps & {
    /**
     * Prop to denote the current item/s in the Menu.
     *
     * Default is `an empty string or object`.
     */
    currentItem?: string | string[];
    /**
     * Prop to set if the item key would have to be provided and correspond to
     * the `Menu Item`'s itemKey for that `Menu * Item` to be disabled.
     *
     * Default is `an empty string`.
     */
    disable?: string;
    /**
     * Prop to denote if the Menu should have a box shadow or not.
     *
     * If set to true, the Menu will have a box shadow.
     * If set to false, the Menu will not have a box shadow.
     *
     * Default is `false`.
     */
    hasBoxShadow?: boolean;
    /**
     * Prop to control if the menu should allow multiple selections.
     *
     * If set to true, the menu will allow users to choose multiple options.
     * If set to false, the menu will only allow one option to be chosen.
     *
     * Default is `false`.
     */
    isMultipleSelection?: boolean;
    /**
     * The function to run on selection / deselection of an item.
     *
     * Default is `an empty object`.
     */
    onChange?: (props: IMenuChangeProps | string[]) => void;
    /**
     * Prop to denote the selected item/s in the Menu.
     *
     * Default is `an empty string or object`.
     */
    selectedItem?: string | string[];
};
export type IMenuItem = Omit<ComponentPropsWithoutRef<'li'>, 'onChange'> & MenuOption & GenericProps;
export type IHandleMultipleMenuItem = Pick<IMenu, 'selectedItem' | 'onChange'> & {
    /**
     * Prop to set an individual menu item's key.
     *
     * Default is `an empty string`.
     */
    itemKey: string;
};
