import { Component, ReactElement, ReactInstance, RefObject, MutableRefObject, ContextType } from 'react';
declare const AutoClosableContext: import("react").Context<AutoClosable | null>;
export type AutoClosableProps = {
    /**
     * onClose handler
     * @since 0.0.42
     */
    onClose?: () => void;
    /**
     * Content of the AutoClosable
     * @since 0.0.42
     */
    children: ReactElement;
    /**
     * Optional function that returns an array of DOM nodes clicks on which should be ignored.
     * @ignore
     */
    ignoreNodes?: () => Array<ReactInstance | typeof Node | RefObject<HTMLElement> | Text | null | undefined>;
    /**
     * A React reference to the DOM element that needs tracking outside clicks.
     * @since 3.12.0
     */
    nodeRef?: RefObject<HTMLElement> | MutableRefObject<HTMLElement | undefined>;
};
/**
 * This is helper component for handling outside clicks.
 * @since 0.0.42
 */
declare class AutoClosable extends Component<AutoClosableProps> {
    componentDidMount(): void;
    componentWillUnmount(): void;
    context: ContextType<typeof AutoClosableContext>;
    children: AutoClosable[];
    addChild: (child: AutoClosable) => void;
    removeChild: (child: AutoClosable) => void;
    getIgnoreNodes: () => (Text | {
        new (): Node;
        prototype: Node;
        readonly ELEMENT_NODE: 1;
        readonly ATTRIBUTE_NODE: 2;
        readonly TEXT_NODE: 3;
        readonly CDATA_SECTION_NODE: 4;
        readonly ENTITY_REFERENCE_NODE: 5;
        readonly ENTITY_NODE: 6;
        readonly PROCESSING_INSTRUCTION_NODE: 7;
        readonly COMMENT_NODE: 8;
        readonly DOCUMENT_NODE: 9;
        readonly DOCUMENT_TYPE_NODE: 10;
        readonly DOCUMENT_FRAGMENT_NODE: 11;
        readonly NOTATION_NODE: 12;
        readonly DOCUMENT_POSITION_DISCONNECTED: 1;
        readonly DOCUMENT_POSITION_PRECEDING: 2;
        readonly DOCUMENT_POSITION_FOLLOWING: 4;
        readonly DOCUMENT_POSITION_CONTAINS: 8;
        readonly DOCUMENT_POSITION_CONTAINED_BY: 16;
        readonly DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: 32;
    } | ReactInstance | RefObject<HTMLElement> | null | undefined)[];
    onOutsideClick: (event: MouseEvent) => void;
    render(): import("react/jsx-runtime").JSX.Element;
}
export default AutoClosable;
