import { AriaOverlayProps, OverlayAria } from '@react-aria/overlays';
import { RefObject } from 'react';

interface UseAriaOverlayProps extends AriaOverlayProps {
    /**
     * When `true`, `click/focus` interactions will be disabled on elements outside
     * the `Overlay`. Users need to click twice on outside elements to interact with them:
     * once to close the overlay, and again to trigger the element.
     *
     * @default true
     */
    disableOutsideEvents?: boolean;
}
/**
 * Provides the behavior for overlays such as dialogs, popovers, and menus.
 * Hides the overlay when the user interacts outside it, when the Escape key is pressed,
 * or optionally, on blur. Only the top-most overlay will close at once.
 */
declare function useAriaOverlay(props: UseAriaOverlayProps, ref: RefObject<Element>): OverlayAria;

export { type UseAriaOverlayProps, useAriaOverlay };
