import { default as React } from 'react';
/**
 * This custom hook allows to keep the focus inside a defined wrapper element.
 * This might be a dialog or a custom overlay.
 *
 * This hook can be used in two ways:
 * - When you have a external component that will be re-rendered after the overlay opens, you can use
 *   the built-in ref. This ref will be returned from this hook and can be set on the respective wrapper element.
 * - When you have an element that does not re-render, use a state setter function to set as the ref.
 *   This element can then be passed as a parameter to this hook and it will be used instead of the built-in ref.
 *
 * @param element Optional parameter to pass in the existing DOM reference. Use this instead of the built-in ref.
 * @returns
 */
declare const useFocusTrap: <T extends HTMLElement>(element?: HTMLDivElement | null) => React.RefObject<HTMLDivElement>;
export default useFocusTrap;
