/** @packageDocumentation
 * @module Frontstage
 */
import { UiEvent } from "@itwin/appui-abstract";
import type { IModelConnection, Tool } from "@itwin/core-frontend";
import type { ToolInformation } from "../toolsettings/ToolInformation.js";
import type { TimeTracker } from "../configurableui/TimeTracker.js";
import { type ContentControlActivatedEvent } from "../content/ContentControl.js";
import type { ContentLayoutActivatedEvent } from "../content/ContentLayout.js";
import type { FrontstageDef } from "../frontstage/FrontstageDef.js";
import type { FrontstageProvider } from "../frontstage/FrontstageProvider.js";
import type { NavigationAidActivatedEvent } from "../navigationaids/NavigationAidControl.js";
import type { PanelPinnedChangedEventArgs, PanelStateChangedEvent } from "../stagepanels/StagePanelDef.js";
import type { WidgetDef, WidgetStateChangedEvent } from "../widgets/WidgetDef.js";
import type { WidgetState } from "../widgets/WidgetState.js";
import type { Frontstage } from "../frontstage/Frontstage.js";
/** Frontstage Activated Event Args interface.
 * @public
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface FrontstageActivatedEventArgs {
    deactivatedFrontstageDef?: FrontstageDef;
    activatedFrontstageDef: FrontstageDef;
}
/** Frontstage Activated Event class.
 * @public
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class FrontstageActivatedEvent extends UiEvent<FrontstageActivatedEventArgs> {
}
/** Frontstage Deactivated Event Args interface.
 * @public
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface FrontstageDeactivatedEventArgs {
    /** Frontstage being deactivated */
    deactivatedFrontstageDef: FrontstageDef;
    /** Frontstage being activated */
    activatedFrontstageDef?: FrontstageDef;
    /** Total time spent in frontstage */
    totalTime: number;
    /** Engagement time spent in frontstage */
    engagementTime: number;
    /** Idle time spent in frontstage */
    idleTime: number;
}
/** Frontstage Deactivated Event class.
 * @public
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class FrontstageDeactivatedEvent extends UiEvent<FrontstageDeactivatedEventArgs> {
}
/** Frontstage Ready Event Args interface.
 * @public
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface FrontstageReadyEventArgs {
    frontstageDef: FrontstageDef;
}
/** Frontstage Ready Event class.
 * @public
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class FrontstageReadyEvent extends UiEvent<FrontstageReadyEventArgs> {
}
/** Modal Frontstage Changed Event Args interface.
 * @public
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface ModalFrontstageChangedEventArgs {
    modalFrontstageCount: number;
}
/** Modal Frontstage Stack Changed Event class.
 * @public
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class ModalFrontstageChangedEvent extends UiEvent<ModalFrontstageChangedEventArgs> {
}
/** Modal Frontstage Closed Event Args interface.
 * @public
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface ModalFrontstageClosedEventArgs {
    /** Modal Frontstage being closed */
    modalFrontstage: ModalFrontstageInfo;
    /** Total time spent in frontstage */
    totalTime: number;
    /** Engagement time spent in frontstage */
    engagementTime: number;
    /** Idle time spent in frontstage */
    idleTime: number;
}
/** Modal Frontstage Requested Close Event class. Notifies the modal stage that the close button was
 * pressed and passes the function to actually close the modal stage. This allows stage to do any
 * saving of unsaved data prior to closing the stage. If the ModalFrontstageInfo sets notifyCloseRequest
 * to true it is up to the stage to register for this event and call the stageCloseFunc once it has saved
 * any unsaved data.
 * @alpha
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class ModalFrontstageRequestedCloseEvent extends UiEvent<ModalFrontstageRequestedCloseEventArgs> {
}
/** Modal Frontstage RequestedClose Event Args interface.
 * @alpha
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface ModalFrontstageRequestedCloseEventArgs {
    /** Modal Frontstage that is to be closed */
    modalFrontstage: ModalFrontstageInfo;
    /** Function to call to close the stage */
    stageCloseFunc: () => void;
}
/** Modal Frontstage Closed Event class.
 * @public
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class ModalFrontstageClosedEvent extends UiEvent<ModalFrontstageClosedEventArgs> {
}
/** Tool Activated Event Args interface.
 * @public
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface ToolActivatedEventArgs {
    toolId: string;
}
/** Tool Activated Event class.
 * @public
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class ToolActivatedEvent extends UiEvent<ToolActivatedEventArgs> {
}
/** Tool Icon Changed Event Args interface.
 * @public
 * @deprecated in 4.13.0. Event args are inferred from a listener. If explicit type is needed use a type helper.
 */
export interface ToolIconChangedEventArgs {
    iconSpec: string;
}
/** Tool Icon Changed Event class.
 * @public
 * @deprecated in 4.13.0. This class should not be used by applications to instantiate objects.
 */
export declare class ToolIconChangedEvent extends UiEvent<ToolIconChangedEventArgs> {
}
/** Modal Frontstage information interface.
 * @public
 */
export interface ModalFrontstageInfo {
    title: string;
    content: React.ReactNode;
    appBarRight?: React.ReactNode;
    /** Set notifyCloseRequest to true on stages that register to listen for `onCloseModalFrontstageRequestedEvent` so
     * that the stage can save unsaved data before closing. Used by the ModalSettingsStage.
     * @alpha */
    notifyCloseRequest?: boolean;
    /** If specified overrides the default back button. See {@link ModalFrontstageButton}. */
    backButton?: React.ReactNode;
}
/** Modal Frontstage array item interface.
 * @internal
 */
export interface ModalFrontstageItem {
    modalFrontstage: ModalFrontstageInfo;
    timeTracker: TimeTracker;
}
/** [[UiFramework.frontstages]] interface
 * @public
 */
export interface FrameworkFrontstages {
    /** Returns true if Frontstage is loading its controls. If false the Frontstage content and controls have been created. */
    readonly isLoading: boolean;
    /** Get Frontstage Deactivated event. */
    readonly onFrontstageDeactivatedEvent: FrontstageDeactivatedEvent;
    /** Get Frontstage Activated event. */
    readonly onFrontstageActivatedEvent: FrontstageActivatedEvent;
    /** Get Frontstage Activated event. */
    readonly onFrontstageReadyEvent: FrontstageReadyEvent;
    /** Get Modal Frontstage Changed event. */
    readonly onModalFrontstageChangedEvent: ModalFrontstageChangedEvent;
    /** Get Modal Frontstage Closed event. */
    readonly onModalFrontstageClosedEvent: ModalFrontstageClosedEvent;
    /** Get Modal Frontstage Requested Closed event.
     * @alpha
     */
    readonly onCloseModalFrontstageRequestedEvent: ModalFrontstageRequestedCloseEvent;
    /** Get Tool Activated event. */
    readonly onToolActivatedEvent: ToolActivatedEvent;
    /** Get ToolSetting Reload event. */
    readonly onToolSettingsReloadEvent: UiEvent<void>;
    /** Get Tool Icon Changed event. */
    readonly onToolIconChangedEvent: ToolIconChangedEvent;
    /** Get Content Layout Activated event. */
    readonly onContentLayoutActivatedEvent: ContentLayoutActivatedEvent;
    /** Get Content Control Activated event.
     * @deprecated in 4.16.0. Use {@link FrameworkContent.onActiveContentChangedEvent} instead.
     */
    readonly onContentControlActivatedEvent: ContentControlActivatedEvent;
    /** Get Navigation Aid Activated event. */
    readonly onNavigationAidActivatedEvent: NavigationAidActivatedEvent;
    /** Get Widget State Changed event. */
    readonly onWidgetStateChangedEvent: WidgetStateChangedEvent;
    /** Get panel state changed event.
     * @alpha
     */
    readonly onPanelStateChangedEvent: PanelStateChangedEvent;
    /** Get panel pinned changed event.
     * @alpha
     */
    readonly onPanelPinnedChangedEvent: UiEvent<PanelPinnedChangedEventArgs>;
    /** Clears the Frontstage map.
     */
    clearFrontstageDefs(): void;
    /** Clears the Frontstage Providers and the defs that may have been created from them.
     * @deprecated in 4.17.0. Use {@link FrameworkFrontstages.clearFrontstages} instead.
     */
    clearFrontstageProviders(): void;
    /** Clears the Frontstages. */
    clearFrontstages(): void;
    /** Adds a frontstage provider.
     * @param frontstageProvider  FrontstageProvider representing the Frontstage to add
     * @deprecated in 4.15.0. Use {@link FrameworkFrontstages.addFrontstage} instead.
     */
    addFrontstageProvider(frontstageProvider: FrontstageProvider): void;
    /** Adds a frontstage. */
    addFrontstage(frontstage: Frontstage): void;
    /** 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.
     */
    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.
     */
    readonly 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.
     */
    readonly activeFrontstageId: string;
    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.
     */
    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.
     */
    setActiveFrontstageDef(frontstageDef: FrontstageDef | undefined): Promise<void>;
    /** Deactivates the active FrontstageDef.
     */
    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.
     */
    readonly activeToolId: string;
    /** Sets the active tool id */
    setActiveToolId(toolId: string): void;
    /** Sets the active tool */
    setActiveTool(tool: Tool): void;
    /** Gets the active tool's [[ToolInformation]].
     * @deprecated in 4.16.0. Uses a deprecated class {@link ToolInformation}.
     */
    readonly activeToolInformation: ToolInformation | undefined;
    /** Opens a modal Frontstage. Modal Frontstages can be stacked.
     * @param modalFrontstage  Information about the modal Frontstage
     */
    openModalFrontstage(modalFrontstage: ModalFrontstageInfo): void;
    /** Closes the top-most modal Frontstage.
     */
    closeModalFrontstage(): void;
    /** Updates the top-most modal Frontstage.
     */
    updateModalFrontstage(): void;
    /** Gets the top-most modal Frontstage.
     * @returns Top-most modal Frontstage, or undefined if there is none.
     */
    readonly activeModalFrontstage: ModalFrontstageInfo | undefined;
    /** Gets the number of modal Frontstages.
     * @returns Modal Frontstage count
     */
    readonly 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
     */
    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.
     */
    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.
     */
    findWidget(widgetId: string): WidgetDef | undefined;
    /** Opens a nested Frontstage. Nested Frontstages can be stacked.
     * @param nestedFrontstage  Information about the nested Frontstage
     */
    openNestedFrontstage(nestedFrontstage: FrontstageDef): Promise<void>;
    /** Closes the top-most nested Frontstage.
     */
    closeNestedFrontstage(): Promise<void>;
    /** Gets the top-most nested Frontstage.
     * @returns Top-most nested Frontstage, or undefined if there is none.
     */
    readonly activeNestedFrontstage: FrontstageDef | undefined;
    /** Gets the number of nested Frontstages.
     * @returns Nested Frontstage count
     */
    readonly nestedFrontstageCount: number;
}
/** @alpha */
export declare class DefaultFrameworkFrontstages implements FrameworkFrontstages {
    get isLoading(): boolean;
    get onFrontstageDeactivatedEvent(): import("@itwin/core-bentley").BeUiEvent<FrontstageDeactivatedEventArgs>;
    get onFrontstageActivatedEvent(): import("@itwin/core-bentley").BeUiEvent<FrontstageActivatedEventArgs>;
    get onFrontstageReadyEvent(): import("@itwin/core-bentley").BeUiEvent<FrontstageReadyEventArgs>;
    get onModalFrontstageChangedEvent(): import("@itwin/core-bentley").BeUiEvent<ModalFrontstageChangedEventArgs>;
    get onModalFrontstageClosedEvent(): import("@itwin/core-bentley").BeUiEvent<ModalFrontstageClosedEventArgs>;
    get onCloseModalFrontstageRequestedEvent(): import("@itwin/core-bentley").BeUiEvent<ModalFrontstageRequestedCloseEventArgs>;
    get onToolActivatedEvent(): import("@itwin/core-bentley").BeUiEvent<ToolActivatedEventArgs>;
    get onToolSettingsReloadEvent(): import("@itwin/core-bentley").BeUiEvent<void>;
    get onToolIconChangedEvent(): import("@itwin/core-bentley").BeUiEvent<ToolIconChangedEventArgs>;
    get onContentLayoutActivatedEvent(): import("@itwin/core-bentley").BeUiEvent<import("../content/ContentLayout.js").ContentLayoutActivatedEventArgs>;
    get onContentControlActivatedEvent(): import("@itwin/core-bentley").BeUiEvent<import("../content/ContentControl.js").ContentControlActivatedEventArgs>;
    get onNavigationAidActivatedEvent(): import("@itwin/core-bentley").BeUiEvent<import("../navigationaids/NavigationAidControl.js").NavigationAidActivatedEventArgs>;
    get onWidgetStateChangedEvent(): import("@itwin/core-bentley").BeUiEvent<import("../widgets/WidgetDef.js").WidgetStateChangedEventArgs>;
    get onPanelStateChangedEvent(): import("@itwin/core-bentley").BeUiEvent<import("../stagepanels/StagePanelDef.js").PanelStateChangedEventArgs>;
    get onPanelPinnedChangedEvent(): import("@itwin/core-bentley").BeUiEvent<PanelPinnedChangedEventArgs>;
    get activeFrontstageDef(): FrontstageDef | undefined;
    get activeFrontstageId(): string;
    get activeToolId(): string;
    get activeToolInformation(): ToolInformation | undefined;
    get activeModalFrontstage(): ModalFrontstageInfo | undefined;
    get modalFrontstageCount(): number;
    get activeNestedFrontstage(): FrontstageDef | undefined;
    get nestedFrontstageCount(): number;
    clearFrontstageDefs(...args: Parameters<FrameworkFrontstages["clearFrontstageDefs"]>): void;
    clearFrontstageProviders(...args: Parameters<FrameworkFrontstages["clearFrontstageProviders"]>): void;
    clearFrontstages(...args: Parameters<FrameworkFrontstages["clearFrontstages"]>): void;
    addFrontstageProvider(...args: Parameters<FrameworkFrontstages["addFrontstageProvider"]>): void;
    addFrontstage(...args: Parameters<FrameworkFrontstages["addFrontstage"]>): void;
    getFrontstageDef(...args: Parameters<FrameworkFrontstages["getFrontstageDef"]>): Promise<FrontstageDef | undefined>;
    hasFrontstage(...args: Parameters<FrameworkFrontstages["hasFrontstage"]>): boolean;
    setActiveFrontstage(...args: Parameters<FrameworkFrontstages["setActiveFrontstage"]>): Promise<void>;
    setActiveFrontstageDef(...args: Parameters<FrameworkFrontstages["setActiveFrontstageDef"]>): Promise<void>;
    deactivateFrontstageDef(...args: Parameters<FrameworkFrontstages["deactivateFrontstageDef"]>): Promise<void>;
    setActiveToolId(...args: Parameters<FrameworkFrontstages["setActiveToolId"]>): void;
    setActiveTool(...args: Parameters<FrameworkFrontstages["setActiveTool"]>): void;
    openModalFrontstage(...args: Parameters<FrameworkFrontstages["openModalFrontstage"]>): void;
    closeModalFrontstage(...args: Parameters<FrameworkFrontstages["closeModalFrontstage"]>): void;
    updateModalFrontstage(...args: Parameters<FrameworkFrontstages["updateModalFrontstage"]>): void;
    setActiveNavigationAid(...args: Parameters<FrameworkFrontstages["setActiveNavigationAid"]>): void;
    setWidgetState(...args: Parameters<FrameworkFrontstages["setWidgetState"]>): boolean;
    findWidget(...args: Parameters<FrameworkFrontstages["findWidget"]>): WidgetDef | undefined;
    openNestedFrontstage(...args: Parameters<FrameworkFrontstages["openNestedFrontstage"]>): Promise<void>;
    closeNestedFrontstage(...args: Parameters<FrameworkFrontstages["closeNestedFrontstage"]>): Promise<void>;
}
//# sourceMappingURL=FrameworkFrontstages.d.ts.map