/** @packageDocumentation
 * @module Frontstage
 */
import { BeUiEvent } from "@itwin/core-bentley";
import type { IModelConnection, Tool } from "@itwin/core-frontend";
import type { ContentControlActivatedEventArgs } from "../content/ContentControl.js";
import type { ContentGroup } from "../content/ContentGroup.js";
import type { ContentLayoutActivatedEventArgs, ContentLayoutDef } from "../content/ContentLayout.js";
import type { NavigationAidActivatedEventArgs } from "../navigationaids/NavigationAidControl.js";
import type { PanelPinnedChangedEventArgs, PanelSizeChangedEventArgs, PanelStateChangedEventArgs } from "../stagepanels/StagePanelDef.js";
import type { WidgetDef, WidgetStateChangedEventArgs } from "../widgets/WidgetDef.js";
import { ToolInformation } from "../toolsettings/ToolInformation.js";
import type { ToolUiProvider } from "../toolsettings/ToolUiProvider.js";
import { FrontstageDef } from "./FrontstageDef.js";
import { FrontstageProvider } from "./FrontstageProvider.js";
import type { WidgetState } from "../widgets/WidgetState.js";
import type { FrontstageActivatedEventArgs, FrontstageDeactivatedEventArgs, FrontstageReadyEventArgs, ModalFrontstageChangedEventArgs, ModalFrontstageClosedEventArgs, ModalFrontstageInfo, ModalFrontstageRequestedCloseEventArgs, ToolActivatedEventArgs, ToolIconChangedEventArgs } from "../framework/FrameworkFrontstages.js";
import type { Frontstage } from "./Frontstage.js";
import type { NineZoneState } from "../layout/state/NineZoneState.js";
/** Frontstage Manager class.
 * @internal
 */
export declare class InternalFrontstageManager {
    private static _initialized;
    private static _isLoading;
    private static _activeToolId;
    private static _activeFrontstageDef;
    private static _frontstageDefs;
    private static _modalFrontstages;
    private static _frontstageProviders;
    private static _frontstages;
    private static _nineZoneSize;
    private static _nestedFrontstages;
    private static _activePrimaryFrontstageDef;
    private static _toolInformationMap;
    /** This should only be called within InternalFrontstageManager and its tests.
     *  @internal
     */
    static ensureToolInformationIsSet(toolId: string): void;
    private static _handleSyncToolSettingsPropertiesEvent;
    private static _handleReloadToolSettingsEvent;
    /** Initializes the InternalFrontstageManager
     * @internal
     */
    static initialize(): void;
    /** Handles a Viewport change & sets the active view accordingly */
    private static _handleSelectedViewportChanged;
    /** @internal */
    static get isInitialized(): boolean;
    static set isInitialized(v: boolean);
    /** Returns true if Frontstage is loading its controls. If false the Frontstage content and controls have been created. */
    static get isLoading(): boolean;
    /** @internal */
    static get nineZoneSize(): import("@itwin/core-react").SizeProps | undefined;
    static set nineZoneSize(size: import("@itwin/core-react").SizeProps | undefined);
    /** @internal */
    static get frontstageDefs(): ReadonlyMap<string, FrontstageDef>;
    /** Get Frontstage Deactivated event. */
    static readonly onFrontstageDeactivatedEvent: BeUiEvent<FrontstageDeactivatedEventArgs>;
    /** Get Frontstage Activated event. */
    static readonly onFrontstageActivatedEvent: BeUiEvent<FrontstageActivatedEventArgs>;
    /** Get Frontstage Activated event. */
    static readonly onFrontstageReadyEvent: BeUiEvent<FrontstageReadyEventArgs>;
    /** Get Modal Frontstage Changed event. */
    static readonly onModalFrontstageChangedEvent: BeUiEvent<ModalFrontstageChangedEventArgs>;
    /** Get Modal Frontstage Closed event. */
    static readonly onModalFrontstageClosedEvent: BeUiEvent<ModalFrontstageClosedEventArgs>;
    /** Get Modal Frontstage Requested Closed event.
     * @alpha
     */
    static readonly onCloseModalFrontstageRequestedEvent: BeUiEvent<ModalFrontstageRequestedCloseEventArgs>;
    /** Get Tool Activated event. */
    static readonly onToolActivatedEvent: BeUiEvent<ToolActivatedEventArgs>;
    /** Get ToolSetting Reload event. */
    static readonly onToolSettingsReloadEvent: BeUiEvent<void>;
    /** Get Tool Panel Opened event.
     * @internal
     */
    static readonly onToolPanelOpenedEvent: BeUiEvent<void>;
    /** Get Tool Icon Changed event. */
    static readonly onToolIconChangedEvent: BeUiEvent<ToolIconChangedEventArgs>;
    /** Get Content Layout Activated event. */
    static readonly onContentLayoutActivatedEvent: BeUiEvent<ContentLayoutActivatedEventArgs>;
    /** Get Content Control Activated event. */
    static readonly onContentControlActivatedEvent: BeUiEvent<ContentControlActivatedEventArgs>;
    /** Get Navigation Aid Activated event. */
    static readonly onNavigationAidActivatedEvent: BeUiEvent<NavigationAidActivatedEventArgs>;
    /** Get Widget State Changed event. */
    static readonly onWidgetStateChangedEvent: BeUiEvent<WidgetStateChangedEventArgs>;
    /** @internal */
    static readonly onWidgetDefsUpdatedEvent: BeUiEvent<void>;
    /** @internal */
    static readonly onFrontstageNineZoneStateChangedEvent: BeUiEvent<{
        frontstageDef: FrontstageDef;
        state: NineZoneState | undefined;
    }>;
    /** @internal */
    static readonly onFrontstageRestoreLayoutEvent: BeUiEvent<{
        frontstageDef: FrontstageDef;
    }>;
    /** @internal */
    static readonly onFrontstageWidgetsChangedEvent: BeUiEvent<{
        frontstageDef: FrontstageDef;
    }>;
    /** Get panel state changed event.
     * @alpha
     */
    static readonly onPanelStateChangedEvent: BeUiEvent<PanelStateChangedEventArgs>;
    /** Get panel pinned changed event.
     * @alpha
     */
    static readonly onPanelPinnedChangedEvent: BeUiEvent<PanelPinnedChangedEventArgs>;
    /** @internal */
    static readonly onPanelSizeChangedEvent: BeUiEvent<PanelSizeChangedEventArgs>;
    /** Clears the Frontstage map.
     */
    static clearFrontstageDefs(): void;
    /** Clears the Frontstage Providers and the defs that may have been created from them.
     */
    static clearFrontstageProviders(): void;
    /** Clears the Frontstages, Frontstage Providers and the defs that may have been created from them. */
    static clearFrontstages(): void;
    private static getFrontstageKey;
    /** @internal */
    static clearFrontstageDefsForIModelId(iModelId: string | undefined): void;
    static addFrontstageProvider(frontstageProvider: FrontstageProvider): void;
    static addFrontstage(frontstage: Frontstage): void;
    /** Find a loaded Frontstage with a given id. If the id is not provided, the active Frontstage is returned.
     * If the FrontstageDef has not been cached by FrontstageDef then it will not be found. See async function
     * `getFrontstageDef` to get a FrontstageDef.
     * @param id  Id of the Frontstage to find
     * @returns  FrontstageDef with a given id if found, or undefined if not found.
     */
    private static findFrontstageDef;
    private static findFrontstageProvider;
    /** Find a loaded Frontstage with a given id. If the id is not provided, the active Frontstage is returned. If
     * no cached FrontstageDef is found but a FrontstageProvider is registered a FrontstageDef will be created, cached, and
     * returned.
     * @param id  Id of the Frontstage to find
     * @returns  FrontstageDef with a given id if found, or undefined if not found.
     */
    static getFrontstageDef(id?: string): Promise<FrontstageDef | undefined>;
    /** Gets the active FrontstageDef. If a Frontstage is not active, undefined is returned.
     * @return  Active FrontstageDef, or undefined if one is not active.
     */
    static get activeFrontstageDef(): FrontstageDef | undefined;
    /** Gets the Id of the active FrontstageDef. If a Frontstage is not active, blank is returned.
     * @return  Id of the active FrontstageDef, or blank if one is not active.
     */
    static get activeFrontstageId(): string;
    static hasFrontstage(frontstageId: string): boolean;
    /** Sets the active FrontstageDef give the stageId.
     * @param  frontstageId  Id of the Frontstage to set active.
     * @returns A Promise that is fulfilled when the Frontstage is ready.
     */
    static setActiveFrontstage(frontstageId: string): Promise<void>;
    /** Sets the active FrontstageDef.
     * @param  frontstageDef  FrontstageDef to set active.
     * @returns A Promise that is fulfilled when the [[FrontstageDef]] is ready.
     */
    static setActiveFrontstageDef(frontstageDef: FrontstageDef | undefined): Promise<void>;
    /** Deactivates the active FrontstageDef.
     */
    static deactivateFrontstageDef(): Promise<void>;
    /** Gets the Id of the active tool. If a tool is not active, blank is returned.
     * @return  Id of the active tool, or blank if one is not active.
     */
    static get activeToolId(): string;
    /** Sets the active tool id */
    static setActiveToolId(toolId: string): void;
    /** Sets the active tool */
    static setActiveTool(tool: Tool): void;
    /** Gets the active tool's [[ToolInformation]] */
    static get activeToolInformation(): ToolInformation | undefined;
    /** Gets the Tool Setting React node of the active tool.
     * @return  Tool Setting React node of the active tool, or undefined if there is no active tool or Tool Settings for the active tool.
     * @internal
     */
    static get activeToolSettingsProvider(): ToolUiProvider | undefined;
    /** Sets the active layout, content group and active content.
     * @param contentLayoutDef  Content layout to make active
     * @param contentGroup  Content Group to make active
     */
    static setActiveLayout(contentLayoutDef: ContentLayoutDef, contentGroup: ContentGroup): Promise<void>;
    /** Sets the active layout, content group and active content.
     * @param contentGroup  Content Group to make active
     */
    static setActiveContentGroup(contentGroup: ContentGroup): Promise<void>;
    /** Opens a modal Frontstage. Modal Frontstages can be stacked.
     * @param modalFrontstage  Information about the modal Frontstage
     */
    static openModalFrontstage(modalFrontstage: ModalFrontstageInfo): void;
    private static pushModalFrontstage;
    /** Closes the top-most modal Frontstage.
     */
    static closeModalFrontstage(): void;
    private static popModalFrontstage;
    private static emitModalFrontstageChangedEvent;
    /** Updates the top-most modal Frontstage.
     */
    static updateModalFrontstage(): void;
    /** Gets the top-most modal Frontstage.
     * @returns Top-most modal Frontstage, or undefined if there is none.
     */
    static get activeModalFrontstage(): ModalFrontstageInfo | undefined;
    /** Gets the number of modal Frontstages.
     * @returns Modal Frontstage count
     */
    static get modalFrontstageCount(): number;
    /** Sets the active Navigation Aid via its Id.
     * @param navigationAidId  Id of the Navigation Aid to set as active
     * @param iModelConnection IModelConnection to query for view data
     */
    static setActiveNavigationAid(navigationAidId: string, iModelConnection: IModelConnection): void;
    /** Sets the state of the widget with the given id
     * @param widgetId  Id of the Widget for which to set the state
     * @param state     New state of the widget
     * @returns true if the widget state was set successfully, or false if not.
     */
    static setWidgetState(widgetId: string, state: WidgetState): boolean;
    /** Finds a widget with the given id in the active frontstage
     * @param widgetId  Id of the Widget to find
     * @returns The WidgetDef with the given id, or undefined if not found.
     */
    static findWidget(widgetId: string): WidgetDef | undefined;
    /** Opens a nested Frontstage. Nested Frontstages can be stacked.
     * @param nestedFrontstage  Information about the nested Frontstage
     */
    static openNestedFrontstage(nestedFrontstage: FrontstageDef): Promise<void>;
    private static pushNestedFrontstage;
    /** Closes the top-most nested Frontstage.
     */
    static closeNestedFrontstage(): Promise<void>;
    private static popNestedFrontstage;
    /** Gets the top-most nested Frontstage.
     * @returns Top-most nested Frontstage, or undefined if there is none.
     */
    static get activeNestedFrontstage(): FrontstageDef | undefined;
    /** Gets the number of nested Frontstages.
     * @returns Nested Frontstage count
     */
    static get nestedFrontstageCount(): number;
}
//# sourceMappingURL=InternalFrontstageManager.d.ts.map