/** @packageDocumentation
 * @module ChildWindowManager
 */
import "./InternalChildWindowManager.scss";
import * as React from "react";
import type { ChildWindowLocationProps, FrameworkChildWindows, OpenChildWindowInfo } from "../framework/FrameworkChildWindows";
/**
 * Simplification of non exported CreateRoot parameter, only to be used
 * in InternalChildWindowManager and ChildWindowManager
 * @internal
 */
export type CreateRoot = Parameters<FrameworkChildWindows["useCreateRoot"]>[0];
/** Supports opening a child browser window from the main application window. The child window is managed by the main application
 * and is running in the same security context. The application must deliver the html file iTwinPopup.html along side its index.html.
 * See also: [Child Window Manager]($docs/learning/ui/appui-react/ChildWindows.md)
 * @internal
 * */
export declare class InternalChildWindowManager implements FrameworkChildWindows {
    private _openChildWindows;
    private _createRoot?;
    private _roots;
    get openChildWindows(): OpenChildWindowInfo[];
    /**
     * When using React 18, the `createRoot` function must be provided in order to render Popout content with React 18.
     * Do not call if using React 17 or before.
     *
     * Note: The type of the function is intentionally simplified here.
     *
     * @param createRootFn Function imported from `import { createRoot } from "react-dom/client";`
     * @beta Will be removed once the transition to React 18 is complete.
     */
    useCreateRoot(createRootFn: CreateRoot): void;
    /**
     * Abstracts ReactDOM.render to use either the _createRoot method or the default ReactDOM.render.
     * @param element Element to render.
     * @param container Container to render to.
     */
    private render;
    /**
     * Returns the OpenChildWindowInfo for the related id.
     * @param childWindowId Id of the window to retrieve.
     * @returns undefined if not found.
     */
    find(childWindowId: string | undefined): OpenChildWindowInfo | undefined;
    /**
     * Return the childWindowId of the provided window.
     * @param contentWindow Window element to identify
     * @returns undefined if not found
     */
    findId(contentWindow: Window | undefined | null): string | undefined;
    private renderChildWindowContents;
    /** Close all child/pop-out windows. This typically is called when the frontstage is changed. */
    closeAll(): void;
    /**
     * Close a specific child window.
     * @param childWindowId Id of the window to close
     * @param processWindowClose should the `close` method be called on the closing window. (defaults to true)
     * @returns false if the window could not be found.
     */
    close: (childWindowId: string, processWindowClose?: boolean) => boolean;
    private adjustWidowLocation;
    /**
     * Open a new child window.
     * @param childWindowId Id to assign to the newly created window.
     * @param title Title to display on the window.
     * @param content ReactNode to be rendered in the window.
     * @param location Position and size information
     * @param useDefaultPopoutUrl use "/iTwinPopup.html" as the window Url, "" otherwise.
     * @returns true if the window is opened successfully.
     */
    open(childWindowId: string, title: string, content: React.ReactNode, location: ChildWindowLocationProps, useDefaultPopoutUrl?: boolean): boolean;
}
//# sourceMappingURL=InternalChildWindowManager.d.ts.map