@netless/window-manager 1.0.6 → 1.0.7-beta.1
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.js +15 -15
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +13 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
- package/src/App/AppProxy.ts +8 -0
- package/src/AppManager.ts +15 -5
package/dist/index.mjs
CHANGED
@@ -721,7 +721,7 @@ const safeListenPropsUpdated = (getProps, callback, onDestroyed) => {
|
|
721
721
|
disposeReaction();
|
722
722
|
};
|
723
723
|
};
|
724
|
-
|
724
|
+
onObjectByEvent(UpdateEventKind.Removed);
|
725
725
|
onObjectByEvent(UpdateEventKind.Inserted);
|
726
726
|
class StorageEvent {
|
727
727
|
constructor() {
|
@@ -1568,6 +1568,10 @@ class AppProxy {
|
|
1568
1568
|
this.appEmitter.onAny(this.appListener);
|
1569
1569
|
this.appAttributesUpdateListener(appId);
|
1570
1570
|
this.setViewFocusScenePath();
|
1571
|
+
let currentMainViewScenePath;
|
1572
|
+
if (this.manager.isReplay) {
|
1573
|
+
currentMainViewScenePath = this.manager.mainView.scenePath;
|
1574
|
+
}
|
1571
1575
|
setTimeout(async () => {
|
1572
1576
|
console.log("setup app", app);
|
1573
1577
|
const result = await app.setup(context);
|
@@ -1575,6 +1579,9 @@ class AppProxy {
|
|
1575
1579
|
appRegister.notifyApp(this.kind, "created", { appId, result });
|
1576
1580
|
this.afterSetupApp(boxInitState);
|
1577
1581
|
this.fixMobileSize();
|
1582
|
+
if (currentMainViewScenePath) {
|
1583
|
+
this.manager.mainViewProxy.setFocusScenePath(currentMainViewScenePath);
|
1584
|
+
}
|
1578
1585
|
callbacks$1.emit("onAppSetup", appId);
|
1579
1586
|
}, SETUP_APP_DELAY);
|
1580
1587
|
});
|
@@ -2342,8 +2349,10 @@ class AppManager {
|
|
2342
2349
|
};
|
2343
2350
|
this.addAppCloseListener = () => {
|
2344
2351
|
this.refresher.add("appsClose", () => {
|
2345
|
-
return
|
2346
|
-
|
2352
|
+
return safeListenPropsUpdated(() => this.attributes.apps, (events2) => {
|
2353
|
+
if (events2.some((e2) => e2.kind === UpdateEventKind.Removed)) {
|
2354
|
+
this.onAppDelete(this.attributes.apps);
|
2355
|
+
}
|
2347
2356
|
});
|
2348
2357
|
});
|
2349
2358
|
};
|
@@ -17988,7 +17997,7 @@ const reconnectRefresher = new ReconnectRefresher({ emitter: internalEmitter });
|
|
17988
17997
|
const _WindowManager = class extends InvisiblePlugin {
|
17989
17998
|
constructor(context) {
|
17990
17999
|
super(context);
|
17991
|
-
this.version = "1.0.
|
18000
|
+
this.version = "1.0.7-beta.1";
|
17992
18001
|
this.dependencies = { "dependencies": { "@juggle/resize-observer": "^3.3.1", "@netless/telebox-insider": "^0.2.32", "emittery": "^0.9.2", "lodash": "^4.17.21", "p-retry": "^4.6.1", "uuid": "^7.0.3", "video.js": ">=7" }, "peerDependencies": { "jspdf": "2.5.1", "white-web-sdk": "^2.16.52" }, "devDependencies": { "@hyrious/dts": "^0.2.2", "@netless/app-docs-viewer": "^0.2.19", "@netless/app-media-player": "0.1.4", "@rollup/plugin-commonjs": "^20.0.0", "@rollup/plugin-node-resolve": "^13.0.4", "@rollup/plugin-url": "^6.1.0", "@sveltejs/vite-plugin-svelte": "^1.0.0-next.22", "@tsconfig/svelte": "^2.0.1", "@types/debug": "^4.1.7", "@types/lodash": "^4.14.182", "@types/lodash-es": "^4.17.4", "@types/uuid": "^8.3.1", "@typescript-eslint/eslint-plugin": "^4.30.0", "@typescript-eslint/parser": "^4.30.0", "@vitest/ui": "^0.14.1", "cypress": "^8.7.0", "dotenv": "^10.0.0", "eslint": "^7.32.0", "eslint-config-prettier": "^8.3.0", "eslint-plugin-svelte3": "^3.2.0", "jsdom": "^19.0.0", "jspdf": "^2.5.1", "less": "^4.1.1", "prettier": "^2.3.2", "prettier-plugin-svelte": "^2.4.0", "rollup-plugin-analyzer": "^4.0.0", "rollup-plugin-styles": "^3.14.1", "side-effect-manager": "0.1.5", "svelte": "^3.42.4", "typescript": "^4.5.5", "vite": "^2.9.9", "vitest": "^0.14.1", "white-web-sdk": "^2.16.52" } };
|
17993
18002
|
this.emitter = callbacks$1;
|
17994
18003
|
this.viewMode = ViewMode.Broadcaster;
|