@hpcc-js/phosphor 3.7.0 → 3.7.2

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": "@hpcc-js/phosphor",
3
- "version": "3.7.0",
3
+ "version": "3.7.2",
4
4
  "description": "hpcc-js - Viz Phosphor",
5
5
  "type": "module",
6
6
  "main": "./dist/index.umd.cjs",
@@ -21,7 +21,7 @@
21
21
  "types/*"
22
22
  ],
23
23
  "scripts": {
24
- "clean": "rimraf --glob lib* types dist *.tsbuildinfo .turbo",
24
+ "clean": "rimraf --glob lib* types types-3.4 dist *.tsbuildinfo .turbo",
25
25
  "bundle": "vite build",
26
26
  "bundle-watch": "vite build --watch",
27
27
  "bundle-serve": "vite --port 5516",
@@ -39,10 +39,10 @@
39
39
  "update-major": "npx --yes npm-check-updates -u"
40
40
  },
41
41
  "dependencies": {
42
- "@hpcc-js/common": "^3.8.0"
42
+ "@hpcc-js/common": "^3.8.1"
43
43
  },
44
44
  "devDependencies": {
45
- "@hpcc-js/esbuild-plugins": "^1.9.0",
45
+ "@hpcc-js/esbuild-plugins": "^1.9.1",
46
46
  "@lumino/algorithm": "2.0.4",
47
47
  "@lumino/commands": "2.3.3",
48
48
  "@lumino/messaging": "2.0.4",
@@ -59,5 +59,5 @@
59
59
  "url": "https://github.com/hpcc-systems/Visualization/issues"
60
60
  },
61
61
  "homepage": "https://github.com/hpcc-systems/Visualization",
62
- "gitHead": "b762adfab7d03d06ea8cfab59059456100ea757c"
62
+ "gitHead": "45e75c47b3ece2f32977ce678d295b07578e7694"
63
63
  }
package/src/DockPanel.ts CHANGED
@@ -100,8 +100,21 @@ export class DockPanel extends HTMLWidget implements IMessageHandler, IMessageHo
100
100
  }
101
101
 
102
102
  exit(domNode, element) {
103
+ if (this._dock.isAttached) {
104
+ if (this._dock.node.isConnected) {
105
+ // Proper Lumino detach — propagates AfterDetach to all children
106
+ // (TabBars etc.), clearing their isAttached flags before disposal.
107
+ PWidget.detach(this._dock);
108
+ } else {
109
+ // The DOM node has already been removed from the document by the
110
+ // parent framework (e.g. React unmount). We cannot call the
111
+ // static Widget.detach() because it guards against !isConnected,
112
+ // so manually broadcast AfterDetach so that Lumino's isAttached
113
+ // bookkeeping is consistent before we dispose child widgets.
114
+ MessageLoop.sendMessage(this._dock, PWidget.Msg.AfterDetach);
115
+ }
116
+ }
103
117
  [...this.widgets()].forEach(w => this.removeWidget(w));
104
- PWidget.detach(this._dock);
105
118
  super.exit(domNode, element);
106
119
  }
107
120