import React from 'react'; import type { WithStyleProps, ComponentStyle } from '@instructure/emotion'; import type { WithDeterministicIdProps } from '@instructure/ui-react-utils'; import type { OtherHTMLAttributes, ChildrenOfType } from '@instructure/shared-types'; import type { NewComponentTypes } from '@instructure/ui-themes'; import type { ItemChild, TopNavBarItemTooltipType } from '../TopNavBarItem/props'; import type { TopNavBarContextType } from '../TopNavBarContext'; import { TopNavBarActionItems } from './index'; type ActionItemsChild = React.ComponentElement; type TopNavBarActionItemsOwnProps = { /** * Children of type: ``. * * Items in small viewport mode are __required__ to have the `renderIcon` prop, * because only the icons are displayed due to the lack of space. */ children?: ChildrenOfType; /** * An 'aria-label' for the action items list. */ listLabel?: string; /** * In __smallViewport__ mode, a __required__ label for the trigger item * of the hidden list items menu, used as an accessible screen reader label. * (The list is not truncated in __desktop__ mode.) * * When there is not enough room to list all the action items, * they will be accessible via a dropdown menu at the end of the list. */ renderHiddenItemsMenuTriggerLabel: string | ((hiddenChildrenCount: number) => string); /** * In __smallViewport__ mode, an optional tooltip for the trigger item * of the hidden list items menu. * (The list is not truncated in __desktop__ mode.) * * When there is not enough room to list all the action items, * they will be accessible via a dropdown menu at the end of the list. */ renderHiddenItemsMenuTriggerTooltip?: TopNavBarItemTooltipType | ((hiddenChildrenCount: number) => TopNavBarItemTooltipType); /** * A function that returns a reference to root HTML element */ elementRef?: (el: HTMLUListElement | null) => void; }; type PropKeys = keyof TopNavBarActionItemsOwnProps; type AllowedPropKeys = Readonly>; type TopNavBarActionItemsProps = TopNavBarActionItemsOwnProps & WithStyleProps, TopNavBarActionItemsStyle> & OtherHTMLAttributes & WithDeterministicIdProps; type TopNavBarActionItemsStyle = ComponentStyle<'topNavBarActionItems' | 'listItem' | 'dropdownMenuOption' | 'dropdownMenuOptionActive'>; type TopNavBarActionItemsState = { key: number; visibleActionItemsCount?: number; }; type TopNavBarActionItemsStyleProps = { layout?: TopNavBarContextType['layout']; }; declare const allowedProps: AllowedPropKeys; export type { ActionItemsChild, TopNavBarActionItemsProps, TopNavBarActionItemsOwnProps, TopNavBarActionItemsState, TopNavBarActionItemsStyleProps, TopNavBarActionItemsStyle }; export { allowedProps }; //# sourceMappingURL=props.d.ts.map