import * as _floating_ui_react_dom from '@floating-ui/react-dom'; import * as React from 'react'; import { VisibleState } from '../types/index.mjs'; type FloatingPlacement = 'end' | 'start'; type FloatingSide = 'top' | 'right' | 'bottom' | 'left'; type FloatingPosition = FloatingSide | `${FloatingSide}-${FloatingPlacement}`; interface UsePopover extends VisibleState { offset?: number; placement?: FloatingPosition; } /** * Generates a popover hook that manages the state of a popover component. * * @return {[boolean, CSSProperties, MutableRefObject[], { open: () => void, close: () => void, toggle: () => void }]} - An array containing the following elements: * - isOpen: A boolean indicating whether the popover is open or closed. * - floatingStyles: An object containing CSS styles for the floating popover. * - refs: An array of mutable ref objects for the popover components. * - actions: An object containing functions to open, close, and toggle the popover. */ declare const usePopover: ({ open: openProp, defaultOpen, onOpenChange, offset, placement, }: UsePopover) => { opened: boolean; floatingStyles: React.CSSProperties; refs: { reference: React.MutableRefObject<_floating_ui_react_dom.ReferenceType | null>; floating: React.MutableRefObject; setReference: (node: _floating_ui_react_dom.ReferenceType | null) => void; setFloating: (node: HTMLElement | null) => void; }; setOpen: React.Dispatch>; update: () => void; }; export { type FloatingPosition, usePopover };