import type { CookieComplianceMethod } from '../environment-info/types'; import { type ConfigurationType } from './configurations'; declare class Initialiser { #private; init(configObj: ConfigurationType): void; getBootstrapConfig: (restServerUrl: string, tokenInfo: { token_type: string; access_token: string; }) => Promise; initCoreContainers: (options?: { containerType?: string; }) => { props: { getPConnect: () => import("../interpreter/c11n-env").C11nEnv; }; }; importReactRoot: () => Promise[]>; importDesignSystemComponentMap: (appStaticContentServer: string, environmentId: string, alternateDesignSystemName: string) => Promise; buildSemanticUrl: (constellationPathInfo: string, queryParams: URLSearchParams, noPortal: string, restServer: string, viewName: string) => string; initCoreConfig: (config: ConfigurationType) => void; /** * This function helps to launch view by name for constellation * @function launchViewByName * @param targetDom property name whose data value need to set * @param viewName A boolean value. * @param portalName name of the portal for which view is defined * @param viewClass class of the view * @param additionalComponents additional componenets * @param portalTarget target where portal is launched * @param styleSheetTarget target where stylesheet is defined * @param containerTargetName target name of the container * * @example Example for .config property * getPConnect().getInitialiser().launchViewByName( targetDom, viewName, portalName, viewClass, additionalComponents, portalTarget, styleSheetTarget, containerTargetName); * */ launchViewByName: (targetDom: string, viewName: string, portalName: string, viewClass: string, additionalComponents: { [key: string]: any; }, portalTarget: string, styleSheetTarget: string, containerTargetName: string) => void; /** * Loads a view into a target DOM element. * @function launchView * @param targetDom - The target DOM element where the view will be loaded. * @param viewMetadata - Metadata for the view being loaded. * @param preLoadComponents - (Optional) List of pre-load components, this is used for pre loading react components. * @param runtimeParams - (Optional and Internal) Runtime parameters for the view. * @param portalTarget - (Optional) DOM element into which view will be loaded and used as cosmos portal target(usually a shadowdom element). * @param styleSheetTarget - (Optional) DOM element into which cosmos styles will be injected. Only applicable for react rendering. * @param containerTargetName - Name of the container that gets created in the redux store. Only applicable for react rendering. * @example In this example we are loading the "WorkList" view in the given targetDom * const targetDom = document.getElementById('viewContainer'); * const viewMetadata = { * name: "WorkList", * config: { * ... * } * } * const containerTargetName = 'hybrid'; * * PCore.getInitialiser().loadView(targetDom, viewMetadata, undefined, undefined, undefined, undefined, containerTargetName) * */ launchView: (targetDom: string, viewMetadata: { [key: string]: any; }, preLoadComponents: string[] | undefined, runtimeParams: { [key: string]: any; }, portalTarget: string, styleSheetTarget: string, containerTargetName: string) => void; /** * This function helps to launch portal in constellation * @function launchPortal * @param targetDom property name whose data value need to set * @param portalName name of the portal for which view is defined * @param containerTargetName target name of the container * @param preLoadComponents additional componenets * * @example Example for .config property * getPConnect().getInitialiser().launchPortal(targetDom, portalName, containerTargetName, preLoadComponents); * */ launchPortal: (targetDom: string, portalName: string, containerTargetName: string, preLoadComponents?: string[]) => void; /** * This function helps to launch mashup/embed for constellation * @function launchMashup * @param {String} targetDom property name whose data value need to set * @param {Boolean} usePegaMashupStyling A boolean value. * * @example Example for .config property * getPConnect().getInitialiser().launchMashup(targetDom, usePegaMashupStyling); * */ launchMashup: (targetDom: string, usePegaMashupStyling?: boolean) => void; /** * This function helps to initiate the bootstrapping of constellation * @function start * @param config property name whose data value need to set * @param callback A callback function to handle launching of either mashup or view or portal. * @returns A promise associated with the action. * * @example Example for .config property * getPConnect().getInitialiser().start(config, callback); * */ start: (config: any, callback: () => void) => Promise; /** * Registers for debug information and sets the application to preview mode. * @param {*} channel - The BroadcastChannel used to post debug information. */ registerForDebugInfo: (channel: { [key: string]: any; }) => void; /** * Toggles the tracer headers based on messages received through the channel. * @param {*} channel - The BroadcastChannel used to toggle tracer headers. */ toggleTracerHeaders: (channel: BroadcastChannel) => void; /** * Loads environment information based on the provided configuration. * @param config - Configuration object containing environment information. * @property config.theme - Theme information. * @property config.theme.definition - Definition of the theme in JSON format. * @property config.keyMapping - Key mapping information. */ loadEnvironmentInfo: (config: { theme: { definition: string; }; keyMapping: any; cookieComplianceMethod: CookieComplianceMethod; }) => Promise; } declare const _default: Initialiser; export default _default;