UNPKG

@leafygreen-ui/hooks

Version:
12 lines 566 B
/** * Returns the maximum space available above or below the source trigger * @param triggerRef The `ref` object attached to the source trigger * @param margin The space around the trigger * * Note: You may not need this hook. * Popovers now adjust their size automatically based on the available space using Floating UI * @see packages/popover/src/Popover/Popover.tsx */ declare const useAvailableSpace: (triggerRef?: React.RefObject<HTMLElement>, margin?: number) => number | undefined; export default useAvailableSpace; //# sourceMappingURL=index.d.ts.map