@spaced-out/ui-design-system
Version:
Sense UI components library
40 lines • 1.51 kB
TypeScript
import * as React from 'react';
import type { Flow } from 'flow-to-typescript-codemod';
import type { ClickAwayRefType } from '../../utils/click-away';
import type { ButtonProps } from '../Button';
import type { MenuOption, MenuProps } from '../Menu';
import type { BaseTooltipProps, ElevationType } from '../Tooltip';
export declare const ANCHOR_POSITION_TYPE: Readonly<{
top: "top";
topStart: "top-start";
topEnd: "top-end";
bottom: "bottom";
bottomStart: "bottom-start";
bottomEnd: "bottom-end";
}>;
export declare const STRATEGY_TYPE: Readonly<{
absolute: "absolute";
fixed: "fixed";
}>;
export type AnchorType = (typeof ANCHOR_POSITION_TYPE)[keyof typeof ANCHOR_POSITION_TYPE];
export type Strategy = (typeof STRATEGY_TYPE)[keyof typeof STRATEGY_TYPE];
type ClassNames = Readonly<{
buttonWrapper?: string;
dropdownContainer?: string;
buttonIcon?: string;
}>;
export type ButtonDropdownProps = ButtonProps & {
classNames?: ClassNames;
menu?: MenuProps;
positionStrategy?: Strategy;
anchorPosition?: AnchorType;
onOptionSelect?: (option: MenuOption, arg2?: React.SyntheticEvent<HTMLElement> | null | undefined) => unknown;
onMenuOpen?: () => unknown;
onMenuClose?: () => unknown;
tooltip?: BaseTooltipProps;
elevation?: ElevationType;
clickAwayRef?: ClickAwayRefType;
};
export declare const ButtonDropdown: Flow.AbstractComponent<ButtonDropdownProps, HTMLDivElement>;
export {};
//# sourceMappingURL=ButtonDropdown.d.ts.map