import { History, To } from 'history';
import { DefaultTheme } from 'styled-components';
import { IMicroAppHost, ResizeEventHandler, BreakpointChangeEventHandler, SubscriptionListener } from '@elliemae/pui-micro-frontend-base';
import { SSFHost } from '@elliemae/ssf-host';
import { BAEvent, ScriptingObjectTypes, Events } from '@elliemae/pui-scripting-object';
import type { ScriptingObjects, EventListeners, AddScriptingObjectParams, DispatchEventParam, EventOptions } from '@elliemae/microfe-common';
import { LogRocket } from '@elliemae/pui-logrocket';
import { Analytics } from '@elliemae/pui-analytics-so';
import { MicroFrontEndLogger } from '../types.js';
type HostOptions = {
    systemVersion: string;
    history: History;
    theme: DefaultTheme;
};
export type OnInitCallback = (options: HostOptions) => void;
type ConstructorParams = {
    logger?: MicroFrontEndLogger;
    logRocket?: typeof LogRocket;
    history?: History;
    version?: string;
    theme?: DefaultTheme;
    scriptingObjects?: Record<string, any>;
    onRenewSessionTimer?: () => void;
    onInit?: OnInitCallback;
    ssfHostRef?: SSFHost<ScriptingObjectTypes, Events> | null;
    analytics?: Analytics;
};
export declare class CMicroAppHost<AppObjects extends ScriptingObjects = Partial<ScriptingObjectTypes>, AppEvents extends EventListeners = Events> implements IMicroAppHost<AppObjects, AppEvents> {
    #private;
    private static instance;
    private readonly logger;
    private readonly appId;
    private props;
    activeGuests: Record<string, unknown>;
    private readonly onInit?;
    private readonly onRenewSessionTimer?;
    private readonly throttleRenewSessionTimer;
    scriptingObjects: Record<string, any>;
    private constructor();
    static getInstance<AppObjects extends ScriptingObjects = Partial<ScriptingObjectTypes>, AppEvents extends EventListeners = Events>(params?: ConstructorParams): CMicroAppHost<AppObjects, AppEvents>;
    static isInitialized(): boolean;
    getProps(): HostOptions;
    getLogger(): MicroFrontEndLogger;
    getItem(key: string): string | null;
    setItem(key: string, value: string): void;
    getGuests(): Record<string, unknown>;
    getGuest<T>(id: string): T | null;
    publish<Type>(message: string | symbol, data?: Type): boolean;
    subscribe<T>(message: string | symbol, func: SubscriptionListener<T>): string;
    unsubscribe(token: string): void;
    navigate(url: To, state?: any): void;
    openWaitMessage(): void;
    closeWaitMessage(): void;
    openErrorBanner(message: string): void;
    getAuthToken(): string;
    renewAuthToken(): string;
    logout(): void;
    renewSessionTimer(): Promise<void>;
    getBreakpoint(): keyof import("@elliemae/pui-theme").BreakPoints;
    getViewportSize(): {
        width: number;
        height: number;
    };
    onResizeEvent(eventHandler: ResizeEventHandler): string;
    onBreakpointChangeEvent(eventHandler: BreakpointChangeEventHandler): string;
    setSystemVersion(version?: string): void;
    sendBAEvent(data: BAEvent): void;
    getObject<T>(name: string): Promise<T>;
    /**
     * add scripting object for child microapp to use
     * @param so - The scripting object to be added.
     * @param params - Optional parameters for adding the scripting object.
     */
    addScriptingObject<SO extends AppObjects[keyof AppObjects]>(so: SO, params?: AddScriptingObjectParams): void;
    /**
     * dispatch event to child microapp
     * @param {DispatchEventParams<EventId, Params>} params - event parameters
     * @returns {Promise<any>} A promise that resolves with the combined results of dispatched events.
     */
    dispatchEvent<EventId extends Extract<keyof AppEvents, string>, Params extends Parameters<AppEvents[EventId]>[0]['eventParams'], Options extends EventOptions>(params: DispatchEventParam<EventId, Params, Options>): Promise<void | any[]>;
    /**
     * removes scripting object from child microapp use
     * @param objectId unique id of the scripting object
     */
    removeScriptingObject(objectId: Extract<keyof AppObjects, string>): void;
}
export {};
