dockview-react 2.1.2 → 2.1.4

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.
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * dockview-react
3
- * @version 2.1.2
3
+ * @version 2.1.4
4
4
  * @link https://github.com/mathuo/dockview
5
5
  * @license MIT
6
6
  */
@@ -7641,10 +7641,6 @@ class DockviewComponent extends BaseGrid {
7641
7641
  this._api = new DockviewApi(this);
7642
7642
  this.updateWatermark();
7643
7643
  }
7644
- dispose() {
7645
- this.clear(); // explicitly clear the layout before cleaning up
7646
- super.dispose();
7647
- }
7648
7644
  setVisible(panel, visible) {
7649
7645
  switch (panel.api.location.type) {
7650
7646
  case 'grid':
@@ -7828,30 +7824,29 @@ class DockviewComponent extends BaseGrid {
7828
7824
  }
7829
7825
  }
7830
7826
  else if (this.getPanel(group.id)) {
7831
- const removedGroup = group;
7827
+ group.model.renderContainer =
7828
+ this.overlayRenderContainer;
7829
+ returnedGroup = group;
7832
7830
  if (floatingBox) {
7833
- this.addFloatingGroup(removedGroup, {
7831
+ this.addFloatingGroup(group, {
7834
7832
  height: floatingBox.height,
7835
7833
  width: floatingBox.width,
7836
7834
  position: floatingBox,
7837
7835
  });
7838
7836
  }
7839
7837
  else {
7840
- this.doRemoveGroup(removedGroup, {
7838
+ this.doRemoveGroup(group, {
7841
7839
  skipDispose: true,
7842
7840
  skipActive: true,
7843
7841
  skipPopoutReturn: true,
7844
7842
  });
7845
- removedGroup.model.renderContainer =
7846
- this.overlayRenderContainer;
7847
- removedGroup.model.location = { type: 'grid' };
7848
- returnedGroup = removedGroup;
7843
+ group.model.location = { type: 'grid' };
7849
7844
  this.movingLock(() => {
7850
7845
  // suppress group add events since the group already exists
7851
- this.doAddGroup(removedGroup, [0]);
7846
+ this.doAddGroup(group, [0]);
7852
7847
  });
7853
7848
  }
7854
- this.doSetGroupAndPanelActive(removedGroup);
7849
+ this.doSetGroupAndPanelActive(group);
7855
7850
  }
7856
7851
  }));
7857
7852
  this._popoutGroups.push(value);
@@ -8742,9 +8737,7 @@ class DockviewComponent extends BaseGrid {
8742
8737
  }));
8743
8738
  this.doRemoveGroup(sourceGroup, { skipActive: true });
8744
8739
  const newGroup = this.createGroupAtLocation(targetLocation);
8745
- this.movingLock(() => newGroup.model.openPanel(removedPanel, {
8746
- skipSetActive: true,
8747
- }));
8740
+ this.movingLock(() => newGroup.model.openPanel(removedPanel));
8748
8741
  this.doSetGroupAndPanelActive(newGroup);
8749
8742
  this._onDidMovePanel.fire({
8750
8743
  panel: this.getGroupPanel(sourceItemId),