import { useEffect, type RefObject } from 'react';
/**
 * Determines the appropriate effect hook to use based on the environment. If
 * the code is running on the client-side (browser), it uses the
 * `useLayoutEffect` hook, otherwise, it uses the `useEffect` hook.
 */
export declare const useIsomorphicLayoutEffect: typeof useEffect;
export declare function useEventListener<K extends keyof MediaQueryListEventMap>(eventName: K, handler: (event: MediaQueryListEventMap[K]) => void, element: RefObject<MediaQueryList>, options?: AddEventListenerOptions | boolean): void;
export declare function useEventListener<K extends keyof WindowEventMap>(eventName: K, handler: (event: WindowEventMap[K]) => void, element?: undefined, options?: AddEventListenerOptions | boolean): void;
export declare function useEventListener<K extends keyof HTMLElementEventMap, T extends HTMLElement = HTMLDivElement>(eventName: K, handler: (event: HTMLElementEventMap[K]) => void, element: RefObject<T>, options?: AddEventListenerOptions | boolean): void;
export declare function useEventListener<K extends keyof DocumentEventMap>(eventName: K, handler: (event: DocumentEventMap[K]) => void, element: RefObject<Document>, options?: AddEventListenerOptions | boolean): void;
type Handler = (event: MouseEvent) => void;
/**
 * Attaches an event listener to detect clicks that occur outside a given
 * element.
 */
export declare const useOnClickOutside: <T extends HTMLElement = HTMLElement>(ref: RefObject<T | null>, handler?: Handler, mouseEvent?: "mousedown" | "mouseup") => void;
export {};
