dockview-react 4.10.0 → 4.12.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.
@@ -1,6 +1,6 @@
1
1
  /**
2
2
  * dockview-react
3
- * @version 4.10.0
3
+ * @version 4.12.0
4
4
  * @link https://github.com/mathuo/dockview
5
5
  * @license MIT
6
6
  */
@@ -3784,8 +3784,8 @@ class DockviewApi {
3784
3784
  /**
3785
3785
  * Create a component from a serialized object.
3786
3786
  */
3787
- fromJSON(data) {
3788
- this.component.fromJSON(data);
3787
+ fromJSON(data, options) {
3788
+ this.component.fromJSON(data, options);
3789
3789
  }
3790
3790
  /**
3791
3791
  * Create a serialized object of the current component.
@@ -5016,6 +5016,7 @@ class ContentContainer extends CompositeDisposable {
5016
5016
  }
5017
5017
  if (doRender) {
5018
5018
  const focusTracker = trackFocus(container);
5019
+ this.focusTracker = focusTracker;
5019
5020
  const disposable = new CompositeDisposable();
5020
5021
  disposable.addDisposables(focusTracker, focusTracker.onDidFocus(() => this._onDidFocus.fire()), focusTracker.onDidBlur(() => this._onDidBlur.fire()));
5021
5022
  this.disposable.value = disposable;
@@ -5043,6 +5044,16 @@ class ContentContainer extends CompositeDisposable {
5043
5044
  this.disposable.dispose();
5044
5045
  super.dispose();
5045
5046
  }
5047
+ /**
5048
+ * Refresh the focus tracker state to handle cases where focus state
5049
+ * gets out of sync due to programmatic panel activation
5050
+ */
5051
+ refreshFocusState() {
5052
+ var _a;
5053
+ if ((_a = this.focusTracker) === null || _a === void 0 ? void 0 : _a.refreshState) {
5054
+ this.focusTracker.refreshState();
5055
+ }
5056
+ }
5046
5057
  }
5047
5058
 
5048
5059
  function addGhostImage(dataTransfer, ghostElement, options) {
@@ -6369,8 +6380,11 @@ class DockviewGroupPanelModel extends CompositeDisposable {
6369
6380
  this._activePanel = panel;
6370
6381
  if (panel) {
6371
6382
  this.tabsContainer.setActivePanel(panel);
6383
+ this.contentContainer.openPanel(panel);
6372
6384
  panel.layout(this._width, this._height);
6373
6385
  this.updateMru(panel);
6386
+ // Refresh focus state to handle programmatic activation without DOM focus change
6387
+ this.contentContainer.refreshFocusState();
6374
6388
  this._onDidActivePanelChange.fire({
6375
6389
  panel,
6376
6390
  });
@@ -6794,11 +6808,16 @@ class DockviewGroupPanelApiImpl extends GridviewPanelApiImpl {
6794
6808
  }
6795
6809
  }
6796
6810
 
6811
+ // GridConstraintChangeEvent2 is not exported, so we'll type it manually
6797
6812
  const MINIMUM_DOCKVIEW_GROUP_PANEL_WIDTH = 100;
6798
6813
  const MINIMUM_DOCKVIEW_GROUP_PANEL_HEIGHT = 100;
6799
6814
  class DockviewGroupPanel extends GridviewPanel {
6800
6815
  get minimumWidth() {
6801
6816
  var _a;
6817
+ // Check for explicitly set group constraint first
6818
+ if (typeof this._explicitConstraints.minimumWidth === 'number') {
6819
+ return this._explicitConstraints.minimumWidth;
6820
+ }
6802
6821
  const activePanelMinimumWidth = (_a = this.activePanel) === null || _a === void 0 ? void 0 : _a.minimumWidth;
6803
6822
  if (typeof activePanelMinimumWidth === 'number') {
6804
6823
  return activePanelMinimumWidth;
@@ -6807,6 +6826,10 @@ class DockviewGroupPanel extends GridviewPanel {
6807
6826
  }
6808
6827
  get minimumHeight() {
6809
6828
  var _a;
6829
+ // Check for explicitly set group constraint first
6830
+ if (typeof this._explicitConstraints.minimumHeight === 'number') {
6831
+ return this._explicitConstraints.minimumHeight;
6832
+ }
6810
6833
  const activePanelMinimumHeight = (_a = this.activePanel) === null || _a === void 0 ? void 0 : _a.minimumHeight;
6811
6834
  if (typeof activePanelMinimumHeight === 'number') {
6812
6835
  return activePanelMinimumHeight;
@@ -6815,6 +6838,10 @@ class DockviewGroupPanel extends GridviewPanel {
6815
6838
  }
6816
6839
  get maximumWidth() {
6817
6840
  var _a;
6841
+ // Check for explicitly set group constraint first
6842
+ if (typeof this._explicitConstraints.maximumWidth === 'number') {
6843
+ return this._explicitConstraints.maximumWidth;
6844
+ }
6818
6845
  const activePanelMaximumWidth = (_a = this.activePanel) === null || _a === void 0 ? void 0 : _a.maximumWidth;
6819
6846
  if (typeof activePanelMaximumWidth === 'number') {
6820
6847
  return activePanelMaximumWidth;
@@ -6823,6 +6850,10 @@ class DockviewGroupPanel extends GridviewPanel {
6823
6850
  }
6824
6851
  get maximumHeight() {
6825
6852
  var _a;
6853
+ // Check for explicitly set group constraint first
6854
+ if (typeof this._explicitConstraints.maximumHeight === 'number') {
6855
+ return this._explicitConstraints.maximumHeight;
6856
+ }
6826
6857
  const activePanelMaximumHeight = (_a = this.activePanel) === null || _a === void 0 ? void 0 : _a.maximumHeight;
6827
6858
  if (typeof activePanelMaximumHeight === 'number') {
6828
6859
  return activePanelMaximumHeight;
@@ -6854,14 +6885,39 @@ class DockviewGroupPanel extends GridviewPanel {
6854
6885
  var _a, _b, _c, _d, _e, _f;
6855
6886
  super(id, 'groupview_default', {
6856
6887
  minimumHeight: (_b = (_a = options.constraints) === null || _a === void 0 ? void 0 : _a.minimumHeight) !== null && _b !== void 0 ? _b : MINIMUM_DOCKVIEW_GROUP_PANEL_HEIGHT,
6857
- minimumWidth: (_d = (_c = options.constraints) === null || _c === void 0 ? void 0 : _c.maximumHeight) !== null && _d !== void 0 ? _d : MINIMUM_DOCKVIEW_GROUP_PANEL_WIDTH,
6888
+ minimumWidth: (_d = (_c = options.constraints) === null || _c === void 0 ? void 0 : _c.minimumWidth) !== null && _d !== void 0 ? _d : MINIMUM_DOCKVIEW_GROUP_PANEL_WIDTH,
6858
6889
  maximumHeight: (_e = options.constraints) === null || _e === void 0 ? void 0 : _e.maximumHeight,
6859
6890
  maximumWidth: (_f = options.constraints) === null || _f === void 0 ? void 0 : _f.maximumWidth,
6860
6891
  }, new DockviewGroupPanelApiImpl(id, accessor));
6892
+ // Track explicitly set constraints to override panel constraints
6893
+ this._explicitConstraints = {};
6861
6894
  this.api.initialize(this); // cannot use 'this' after after 'super' call
6862
6895
  this._model = new DockviewGroupPanelModel(this.element, accessor, id, options, this);
6863
6896
  this.addDisposables(this.model.onDidActivePanelChange((event) => {
6864
6897
  this.api._onDidActivePanelChange.fire(event);
6898
+ }), this.api.onDidConstraintsChangeInternal((event) => {
6899
+ // Track explicitly set constraints to override panel constraints
6900
+ // Extract numeric values from functions or values
6901
+ if (event.minimumWidth !== undefined) {
6902
+ this._explicitConstraints.minimumWidth = typeof event.minimumWidth === 'function'
6903
+ ? event.minimumWidth()
6904
+ : event.minimumWidth;
6905
+ }
6906
+ if (event.minimumHeight !== undefined) {
6907
+ this._explicitConstraints.minimumHeight = typeof event.minimumHeight === 'function'
6908
+ ? event.minimumHeight()
6909
+ : event.minimumHeight;
6910
+ }
6911
+ if (event.maximumWidth !== undefined) {
6912
+ this._explicitConstraints.maximumWidth = typeof event.maximumWidth === 'function'
6913
+ ? event.maximumWidth()
6914
+ : event.maximumWidth;
6915
+ }
6916
+ if (event.maximumHeight !== undefined) {
6917
+ this._explicitConstraints.maximumHeight = typeof event.maximumHeight === 'function'
6918
+ ? event.maximumHeight()
6919
+ : event.maximumHeight;
6920
+ }
6865
6921
  }));
6866
6922
  }
6867
6923
  focus() {
@@ -7158,6 +7214,18 @@ class DockviewPanel extends CompositeDisposable {
7158
7214
  params: this._params,
7159
7215
  });
7160
7216
  }
7217
+ updateFromStateModel(state) {
7218
+ var _a, _b, _c;
7219
+ this._maximumHeight = state.maximumHeight;
7220
+ this._minimumHeight = state.minimumHeight;
7221
+ this._maximumWidth = state.maximumWidth;
7222
+ this._minimumWidth = state.minimumWidth;
7223
+ this.update({ params: (_a = state.params) !== null && _a !== void 0 ? _a : {} });
7224
+ this.setTitle((_b = state.title) !== null && _b !== void 0 ? _b : this.id);
7225
+ this.setRenderer((_c = state.renderer) !== null && _c !== void 0 ? _c : this.accessor.renderer);
7226
+ // state.contentComponent;
7227
+ // state.tabComponent;
7228
+ }
7161
7229
  updateParentGroup(group, options) {
7162
7230
  this._group = group;
7163
7231
  this.api.group = this._group;
@@ -8921,7 +8989,7 @@ class DockviewComponent extends BaseGrid {
8921
8989
  : (_e = (_d = this.options.floatingGroupBounds) === null || _d === void 0 ? void 0 : _d.minimumHeightWithinViewport) !== null && _e !== void 0 ? _e : DEFAULT_FLOATING_GROUP_OVERFLOW_SIZE }));
8922
8990
  const el = group.element.querySelector('.dv-void-container');
8923
8991
  if (!el) {
8924
- throw new Error('failed to find drag handle');
8992
+ throw new Error('dockview: failed to find drag handle');
8925
8993
  }
8926
8994
  overlay.setupDrag(el, {
8927
8995
  inDragMode: typeof (options === null || options === void 0 ? void 0 : options.inDragMode) === 'boolean'
@@ -8993,7 +9061,7 @@ class DockviewComponent extends BaseGrid {
8993
9061
  case 'right':
8994
9062
  return this.createGroupAtLocation([this.gridview.length], undefined, options); // insert into last position
8995
9063
  default:
8996
- throw new Error(`unsupported position ${position}`);
9064
+ throw new Error(`dockview: unsupported position ${position}`);
8997
9065
  }
8998
9066
  }
8999
9067
  updateOptions(options) {
@@ -9139,15 +9207,48 @@ class DockviewComponent extends BaseGrid {
9139
9207
  }
9140
9208
  return result;
9141
9209
  }
9142
- fromJSON(data) {
9210
+ fromJSON(data, options) {
9143
9211
  var _a, _b;
9212
+ const existingPanels = new Map();
9213
+ let tempGroup;
9214
+ if (options === null || options === void 0 ? void 0 : options.reuseExistingPanels) {
9215
+ /**
9216
+ * What are we doing here?
9217
+ *
9218
+ * 1. Create a temporary group to hold any panels that currently exist and that also exist in the new layout
9219
+ * 2. Remove that temporary group from the group mapping so that it doesn't get cleared when we clear the layout
9220
+ */
9221
+ tempGroup = this.createGroup();
9222
+ this._groups.delete(tempGroup.api.id);
9223
+ const newPanels = Object.keys(data.panels);
9224
+ for (const panel of this.panels) {
9225
+ if (newPanels.includes(panel.api.id)) {
9226
+ existingPanels.set(panel.api.id, panel);
9227
+ }
9228
+ }
9229
+ this.movingLock(() => {
9230
+ Array.from(existingPanels.values()).forEach((panel) => {
9231
+ this.moveGroupOrPanel({
9232
+ from: {
9233
+ groupId: panel.api.group.api.id,
9234
+ panelId: panel.api.id,
9235
+ },
9236
+ to: {
9237
+ group: tempGroup,
9238
+ position: 'center',
9239
+ },
9240
+ keepEmptyGroups: true,
9241
+ });
9242
+ });
9243
+ });
9244
+ }
9144
9245
  this.clear();
9145
9246
  if (typeof data !== 'object' || data === null) {
9146
- throw new Error('serialized layout must be a non-null object');
9247
+ throw new Error('dockview: serialized layout must be a non-null object');
9147
9248
  }
9148
9249
  const { grid, panels, activeGroup } = data;
9149
9250
  if (grid.root.type !== 'branch' || !Array.isArray(grid.root.data)) {
9150
- throw new Error('root must be of type branch');
9251
+ throw new Error('dockview: root must be of type branch');
9151
9252
  }
9152
9253
  try {
9153
9254
  // take note of the existing dimensions
@@ -9156,7 +9257,7 @@ class DockviewComponent extends BaseGrid {
9156
9257
  const createGroupFromSerializedState = (data) => {
9157
9258
  const { id, locked, hideHeader, views, activeView } = data;
9158
9259
  if (typeof id !== 'string') {
9159
- throw new Error('group id must be of type string');
9260
+ throw new Error('dockview: group id must be of type string');
9160
9261
  }
9161
9262
  const group = this.createGroup({
9162
9263
  id,
@@ -9171,17 +9272,38 @@ class DockviewComponent extends BaseGrid {
9171
9272
  * In running this section first we avoid firing lots of 'add' events in the event of a failure
9172
9273
  * due to a corruption of input data.
9173
9274
  */
9174
- const panel = this._deserializer.fromJSON(panels[child], group);
9175
- createdPanels.push(panel);
9275
+ const existingPanel = existingPanels.get(child);
9276
+ if (tempGroup && existingPanel) {
9277
+ this.movingLock(() => {
9278
+ tempGroup.model.removePanel(existingPanel);
9279
+ });
9280
+ createdPanels.push(existingPanel);
9281
+ existingPanel.updateFromStateModel(panels[child]);
9282
+ }
9283
+ else {
9284
+ const panel = this._deserializer.fromJSON(panels[child], group);
9285
+ createdPanels.push(panel);
9286
+ }
9176
9287
  }
9177
9288
  for (let i = 0; i < views.length; i++) {
9178
9289
  const panel = createdPanels[i];
9179
9290
  const isActive = typeof activeView === 'string' &&
9180
9291
  activeView === panel.id;
9181
- group.model.openPanel(panel, {
9182
- skipSetActive: !isActive,
9183
- skipSetGroupActive: true,
9184
- });
9292
+ const hasExisting = existingPanels.has(panel.api.id);
9293
+ if (hasExisting) {
9294
+ this.movingLock(() => {
9295
+ group.model.openPanel(panel, {
9296
+ skipSetActive: !isActive,
9297
+ skipSetGroupActive: true,
9298
+ });
9299
+ });
9300
+ }
9301
+ else {
9302
+ group.model.openPanel(panel, {
9303
+ skipSetActive: !isActive,
9304
+ skipSetGroupActive: true,
9305
+ });
9306
+ }
9185
9307
  }
9186
9308
  if (!group.activePanel && group.panels.length > 0) {
9187
9309
  group.model.openPanel(group.panels[group.panels.length - 1], {
@@ -9220,7 +9342,9 @@ class DockviewComponent extends BaseGrid {
9220
9342
  setTimeout(() => {
9221
9343
  this.addPopoutGroup(group, {
9222
9344
  position: position !== null && position !== void 0 ? position : undefined,
9223
- overridePopoutGroup: gridReferenceGroup ? group : undefined,
9345
+ overridePopoutGroup: gridReferenceGroup
9346
+ ? group
9347
+ : undefined,
9224
9348
  referenceGroup: gridReferenceGroup
9225
9349
  ? this.getPanel(gridReferenceGroup)
9226
9350
  : undefined,
@@ -9306,11 +9430,11 @@ class DockviewComponent extends BaseGrid {
9306
9430
  addPanel(options) {
9307
9431
  var _a, _b;
9308
9432
  if (this.panels.find((_) => _.id === options.id)) {
9309
- throw new Error(`panel with id ${options.id} already exists`);
9433
+ throw new Error(`dockview: panel with id ${options.id} already exists`);
9310
9434
  }
9311
9435
  let referenceGroup;
9312
9436
  if (options.position && options.floating) {
9313
- throw new Error('you can only provide one of: position, floating as arguments to .addPanel(...)');
9437
+ throw new Error('dockview: you can only provide one of: position, floating as arguments to .addPanel(...)');
9314
9438
  }
9315
9439
  const initial = {
9316
9440
  width: options.initialWidth,
@@ -9324,7 +9448,7 @@ class DockviewComponent extends BaseGrid {
9324
9448
  : options.position.referencePanel;
9325
9449
  index = options.position.index;
9326
9450
  if (!referencePanel) {
9327
- throw new Error(`referencePanel '${options.position.referencePanel}' does not exist`);
9451
+ throw new Error(`dockview: referencePanel '${options.position.referencePanel}' does not exist`);
9328
9452
  }
9329
9453
  referenceGroup = this.findGroup(referencePanel);
9330
9454
  }
@@ -9335,7 +9459,7 @@ class DockviewComponent extends BaseGrid {
9335
9459
  : options.position.referenceGroup;
9336
9460
  index = options.position.index;
9337
9461
  if (!referenceGroup) {
9338
- throw new Error(`referenceGroup '${options.position.referenceGroup}' does not exist`);
9462
+ throw new Error(`dockview: referenceGroup '${options.position.referenceGroup}' does not exist`);
9339
9463
  }
9340
9464
  }
9341
9465
  else {
@@ -9447,7 +9571,7 @@ class DockviewComponent extends BaseGrid {
9447
9571
  }) {
9448
9572
  const group = panel.group;
9449
9573
  if (!group) {
9450
- throw new Error(`cannot remove panel ${panel.id}. it's missing a group.`);
9574
+ throw new Error(`dockview: cannot remove panel ${panel.id}. it's missing a group.`);
9451
9575
  }
9452
9576
  group.model.removePanel(panel, {
9453
9577
  skipSetActiveGroup: options.skipSetActiveGroup,
@@ -9496,11 +9620,11 @@ class DockviewComponent extends BaseGrid {
9496
9620
  ? this.panels.find((panel) => panel.id === options.referencePanel)
9497
9621
  : options.referencePanel;
9498
9622
  if (!referencePanel) {
9499
- throw new Error(`reference panel ${options.referencePanel} does not exist`);
9623
+ throw new Error(`dockview: reference panel ${options.referencePanel} does not exist`);
9500
9624
  }
9501
9625
  referenceGroup = this.findGroup(referencePanel);
9502
9626
  if (!referenceGroup) {
9503
- throw new Error(`reference group for reference panel ${options.referencePanel} does not exist`);
9627
+ throw new Error(`dockview: reference group for reference panel ${options.referencePanel} does not exist`);
9504
9628
  }
9505
9629
  }
9506
9630
  else if (isGroupOptionsWithGroup(options)) {
@@ -9509,7 +9633,7 @@ class DockviewComponent extends BaseGrid {
9509
9633
  ? (_a = this._groups.get(options.referenceGroup)) === null || _a === void 0 ? void 0 : _a.value
9510
9634
  : options.referenceGroup;
9511
9635
  if (!referenceGroup) {
9512
- throw new Error(`reference group ${options.referenceGroup} does not exist`);
9636
+ throw new Error(`dockview: reference group ${options.referenceGroup} does not exist`);
9513
9637
  }
9514
9638
  }
9515
9639
  else {
@@ -9577,7 +9701,7 @@ class DockviewComponent extends BaseGrid {
9577
9701
  }
9578
9702
  return floatingGroup.group;
9579
9703
  }
9580
- throw new Error('failed to find floating group');
9704
+ throw new Error('dockview: failed to find floating group');
9581
9705
  }
9582
9706
  if (group.api.location.type === 'popout') {
9583
9707
  const selectedGroup = this._popoutGroups.find((_) => _.popoutGroup === group);
@@ -9608,7 +9732,7 @@ class DockviewComponent extends BaseGrid {
9608
9732
  this.updateWatermark();
9609
9733
  return selectedGroup.popoutGroup;
9610
9734
  }
9611
- throw new Error('failed to find popout group');
9735
+ throw new Error('dockview: failed to find popout group');
9612
9736
  }
9613
9737
  const re = super.doRemoveGroup(group, options);
9614
9738
  if (!(options === null || options === void 0 ? void 0 : options.skipActive)) {
@@ -9639,7 +9763,7 @@ class DockviewComponent extends BaseGrid {
9639
9763
  ? (_a = this._groups.get(sourceGroupId)) === null || _a === void 0 ? void 0 : _a.value
9640
9764
  : undefined;
9641
9765
  if (!sourceGroup) {
9642
- throw new Error(`Failed to find group id ${sourceGroupId}`);
9766
+ throw new Error(`dockview: Failed to find group id ${sourceGroupId}`);
9643
9767
  }
9644
9768
  if (sourceItemId === undefined) {
9645
9769
  /**
@@ -9664,9 +9788,9 @@ class DockviewComponent extends BaseGrid {
9664
9788
  skipSetActiveGroup: true,
9665
9789
  }));
9666
9790
  if (!removedPanel) {
9667
- throw new Error(`No panel with id ${sourceItemId}`);
9791
+ throw new Error(`dockview: No panel with id ${sourceItemId}`);
9668
9792
  }
9669
- if (sourceGroup.model.size === 0) {
9793
+ if (!options.keepEmptyGroups && sourceGroup.model.size === 0) {
9670
9794
  // remove the group and do not set a new group as active
9671
9795
  this.doRemoveGroup(sourceGroup, { skipActive: true });
9672
9796
  }
@@ -9676,7 +9800,8 @@ class DockviewComponent extends BaseGrid {
9676
9800
  var _a;
9677
9801
  return destinationGroup.model.openPanel(removedPanel, {
9678
9802
  index: destinationIndex,
9679
- skipSetActive: ((_a = options.skipSetActive) !== null && _a !== void 0 ? _a : false) && !isDestinationGroupEmpty,
9803
+ skipSetActive: ((_a = options.skipSetActive) !== null && _a !== void 0 ? _a : false) &&
9804
+ !isDestinationGroupEmpty,
9680
9805
  skipSetGroupActive: true,
9681
9806
  });
9682
9807
  });
@@ -9731,7 +9856,9 @@ class DockviewComponent extends BaseGrid {
9731
9856
  }));
9732
9857
  this.doRemoveGroup(sourceGroup, { skipActive: true });
9733
9858
  const newGroup = this.createGroupAtLocation(targetLocation);
9734
- this.movingLock(() => newGroup.model.openPanel(removedPanel));
9859
+ this.movingLock(() => newGroup.model.openPanel(removedPanel, {
9860
+ skipSetActive: true,
9861
+ }));
9735
9862
  this.doSetGroupAndPanelActive(newGroup);
9736
9863
  this._onDidMovePanel.fire({
9737
9864
  panel: this.getGroupPanel(sourceItemId),
@@ -9764,7 +9891,7 @@ class DockviewComponent extends BaseGrid {
9764
9891
  skipSetActiveGroup: true,
9765
9892
  }));
9766
9893
  if (!removedPanel) {
9767
- throw new Error(`No panel with id ${sourceItemId}`);
9894
+ throw new Error(`dockview: No panel with id ${sourceItemId}`);
9768
9895
  }
9769
9896
  const dropLocation = getRelativeLocation(this.gridview.orientation, referenceLocation, destinationTarget);
9770
9897
  const group = this.createGroupAtLocation(dropLocation);
@@ -9819,7 +9946,7 @@ class DockviewComponent extends BaseGrid {
9819
9946
  case 'floating': {
9820
9947
  const selectedFloatingGroup = this._floatingGroups.find((x) => x.group === from);
9821
9948
  if (!selectedFloatingGroup) {
9822
- throw new Error('failed to find floating group');
9949
+ throw new Error('dockview: failed to find floating group');
9823
9950
  }
9824
9951
  selectedFloatingGroup.dispose();
9825
9952
  break;
@@ -9827,7 +9954,7 @@ class DockviewComponent extends BaseGrid {
9827
9954
  case 'popout': {
9828
9955
  const selectedPopoutGroup = this._popoutGroups.find((x) => x.popoutGroup === from);
9829
9956
  if (!selectedPopoutGroup) {
9830
- throw new Error('failed to find popout group');
9957
+ throw new Error('dockview: failed to find popout group');
9831
9958
  }
9832
9959
  // Remove from popout groups list to prevent automatic restoration
9833
9960
  const index = this._popoutGroups.indexOf(selectedPopoutGroup);