@netless/window-manager 1.0.5 → 1.0.6-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -1068,6 +1068,31 @@ declare const BuiltinApps: {
1068
1068
  MediaPlayer: string;
1069
1069
  };
1070
1070
 
1071
+ interface ExtendContext {
1072
+ readonly manager: ExtendPluginManager;
1073
+ readonly windowManager: WindowManager;
1074
+ readonly internalEmitter: EmitterType;
1075
+ }
1076
+ declare abstract class ExtendPlugin extends Emittery {
1077
+ context: ExtendContext;
1078
+ abstract readonly kind: string;
1079
+ protected _inject(context: ExtendContext): void;
1080
+ abstract onCreate(): void;
1081
+ abstract onDestroy(): void;
1082
+ }
1083
+ type ExtendPluginInstance<T extends ExtendPlugin> = T;
1084
+ interface ExtendManagerOptions {
1085
+ readonly windowManager: WindowManager;
1086
+ readonly internalEmitter: EmitterType;
1087
+ }
1088
+ declare class ExtendPluginManager {
1089
+ private extends;
1090
+ private context;
1091
+ constructor(props: ExtendManagerOptions);
1092
+ use(extend: ExtendPluginInstance<any>): void;
1093
+ destroy(): void;
1094
+ }
1095
+
1071
1096
  type WindowMangerAttributes = {
1072
1097
  modelValue?: string;
1073
1098
  boxState: TELE_BOX_STATE;
@@ -1184,6 +1209,7 @@ declare class WindowManager extends InvisiblePlugin<WindowMangerAttributes, any>
1184
1209
  private static params?;
1185
1210
  private containerResizeObserver?;
1186
1211
  containerSizeRatio: number;
1212
+ private extendPluginManager?;
1187
1213
  constructor(context: InvisiblePluginContext);
1188
1214
  static onCreate(manager: WindowManager): void;
1189
1215
  static mount(params: MountParams): Promise<WindowManager>;
@@ -1340,4 +1366,4 @@ declare class WindowManager extends InvisiblePlugin<WindowMangerAttributes, any>
1340
1366
  getIframeBridge(): IframeBridge;
1341
1367
  }
1342
1368
 
1343
- export { type AddAppOptions, type AddAppParams, type AddPageParams, AppContext, AppCreateError, type AppEmitterEvent, type AppInitState, type AppListenerKeys, AppManagerNotInitError, AppNotRegisterError, type AppPayload, type AppSyncAttributes, type ApplianceIcons, type BaseInsertParams, BindContainerRoomPhaseInvalidError, BoxManagerNotFoundError, BoxNotCreatedError, BuiltinApps, type CursorMovePayload, type CursorOptions, DomEvents, IframeBridge, type IframeBridgeAttributes, type IframeBridgeEvents, IframeEvents, type IframeSize, type InsertOptions, InvalidScenePath, type MountParams, type NetlessApp, type OnCreateInsertOption, type PageController, type PageRemoveService, type PageState, ParamsInvalidError, type PublicEvent, type RegisterEventData, type RegisterEvents, type RegisterParams, Storage, type StorageStateChangedEvent, type StorageStateChangedListener, WhiteWebSDKInvalidError, WindowManager, type WindowMangerAttributes, type apps, calculateNextIndex, reconnectRefresher, type setAppOptions };
1369
+ export { type AddAppOptions, type AddAppParams, type AddPageParams, AppContext, AppCreateError, type AppEmitterEvent, type AppInitState, type AppListenerKeys, AppManagerNotInitError, AppNotRegisterError, type AppPayload, type AppSyncAttributes, type ApplianceIcons, type BaseInsertParams, BindContainerRoomPhaseInvalidError, BoxManagerNotFoundError, BoxNotCreatedError, BuiltinApps, type CursorMovePayload, type CursorOptions, DomEvents, type ExtendContext, type ExtendManagerOptions, ExtendPlugin, type ExtendPluginInstance, ExtendPluginManager, IframeBridge, type IframeBridgeAttributes, type IframeBridgeEvents, IframeEvents, type IframeSize, type InsertOptions, InvalidScenePath, type MountParams, type NetlessApp, type OnCreateInsertOption, type PageController, type PageRemoveService, type PageState, ParamsInvalidError, type PublicEvent, type RegisterEventData, type RegisterEvents, type RegisterParams, Storage, type StorageStateChangedEvent, type StorageStateChangedListener, WhiteWebSDKInvalidError, WindowManager, type WindowMangerAttributes, type apps, calculateNextIndex, reconnectRefresher, type setAppOptions };