@netless/window-manager 0.3.17 → 0.3.18

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@netless/window-manager",
3
- "version": "0.3.17",
3
+ "version": "0.3.18",
4
4
  "description": "",
5
5
  "main": "dist/index.es.js",
6
6
  "module": "dist/index.es.js",
package/src/AppManager.ts CHANGED
@@ -101,7 +101,9 @@ export class AppManager {
101
101
  if (minimized === true) {
102
102
  this.boxManager.blurAllBox();
103
103
  }
104
- this.boxManager.setMinimized(Boolean(minimized));
104
+ setTimeout(() => {
105
+ this.boxManager.setMinimized(Boolean(minimized));
106
+ }, 0);
105
107
  }
106
108
  });
107
109
  });
package/src/BoxManager.ts CHANGED
@@ -249,14 +249,16 @@ export class BoxManager {
249
249
  },
250
250
  true
251
251
  );
252
- if (state.maximized != null) {
253
- this.teleBoxManager.setMaximized(Boolean(state.maximized), true);
254
- this.teleBoxManager.setMinimized(Boolean(state.minimized), true);
255
- }
256
252
  setTimeout(() => {
257
253
  if (state.focus) {
258
254
  this.teleBoxManager.focusBox(box.id, true)
259
255
  }
256
+ if (state.maximized != null) {
257
+ this.teleBoxManager.setMaximized(Boolean(state.maximized), true);
258
+ }
259
+ if (state.minimized != null) {
260
+ this.teleBoxManager.setMinimized(Boolean(state.minimized), true);
261
+ }
260
262
  }, 50);
261
263
  callbacks.emit("boxStateChange", this.teleBoxManager.state);
262
264
  }
package/src/index.ts CHANGED
@@ -177,7 +177,7 @@ export class WindowManager extends InvisiblePlugin<WindowMangerAttributes> {
177
177
  public static containerSizeRatio = DEFAULT_CONTAINER_RATIO;
178
178
  private static isCreated = false;
179
179
 
180
- public version = "0.3.17";
180
+ public version = "0.3.18";
181
181
 
182
182
  public appListeners?: AppListeners;
183
183