@deephaven/golden-layout 1.18.1-iris-grid-16.0 → 1.18.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.
@@ -56,7 +56,7 @@ export default class Tab {
56
56
  /**
57
57
  * Callback when the contentItem is focused in
58
58
  */
59
- _onTabContentFocusIn(): void;
59
+ _onTabContentFocusIn(event?: JQuery.TriggeredEvent): void;
60
60
  /**
61
61
  * Callback when the contentItem is focused out
62
62
  *
@@ -92,5 +92,17 @@ export default class Tab {
92
92
  * @param event
93
93
  */
94
94
  _onCloseMousedown(event: Event): void;
95
+ /**
96
+ * Returns true if the given element is inside this content item's
97
+ * container but within a nested LayoutManager (i.e. a dashboard
98
+ * embedded inside this tab's component). Such focus belongs to the
99
+ * nested layout's tab, not this outer one.
100
+ */
101
+ private _isInNestedLayout;
102
+ /**
103
+ * Returns true if the document's active element is inside this tab's
104
+ * container directly (not inside a nested LayoutManager).
105
+ */
106
+ private _isFocusDirectlyInContainer;
95
107
  }
96
108
  //# sourceMappingURL=Tab.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"Tab.d.ts","sourceRoot":"","sources":["../../src/controls/Tab.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,UAAU,CAAC;AAKpD,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AAEnC;;;;;GAKG;AACH,MAAM,CAAC,OAAO,OAAO,GAAG;IACtB;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,SAAS,CAMb;IAEX,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,mBAAmB,CAAC;IACjC,OAAO,sBAAoB;IAC3B,YAAY,EAAE,MAAM,CAAC,WAAW,CAAC,CAAC;IAClC,YAAY,EAAE,MAAM,CAAC,WAAW,CAAC,CAAC;IAClC,QAAQ,UAAS;IAEjB,OAAO,CAAC,cAAc,CAAgB;IACtC,OAAO,CAAC,aAAa,CAAC,CAAe;gB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,mBAAmB;IA2D5D;;;;;OAKG;IACH,QAAQ,CAAC,KAAK,SAAK;IAMnB;;;;OAIG;IACH,cAAc,CAAC,cAAc,EAAE,mBAAmB;IA6BlD;;;;OAIG;IACH,SAAS,CAAC,QAAQ,EAAE,OAAO;IAa3B;;;;;OAKG;IACH,SAAS;IAoBT;;;;;OAKG;IACH,YAAY,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM;IAmBjC;;OAEG;IACH,oBAAoB,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,cAAc;IA2BlD;;;;;;;OAOG;IACH,qBAAqB;IAWrB;;;;OAIG;IACH,WAAW,CAAC,KAAK,CAAC,EAAE,MAAM,CAAC,cAAc;IAyCzC;;;;;OAKG;IACH,aAAa,CAAC,KAAK,EAAE,MAAM,CAAC,cAAc;IAS1C;;;;OAIG;IACH,UAAU,CAAC,KAAK,EAAE,MAAM,CAAC,cAAc;IAOvC;;;;;OAKG;IACH,iBAAiB,CAAC,KAAK,EAAE,KAAK;IAI9B;;;;;OAKG;IACH,OAAO,CAAC,iBAAiB;IAMzB;;;OAGG;IACH,OAAO,CAAC,2BAA2B;CAapC"}
@@ -128,7 +128,6 @@ export default class Tab {
128
128
  this.closeElement.off('click', this._onCloseClick);
129
129
  if (isComponent(this.contentItem)) {
130
130
  this.contentItem.container._contentElement.off();
131
- this.contentItem.container._contentElement[0].removeEventListener('click', this._onTabContentFocusIn, true);
132
131
  }
133
132
  if (this._dragListener) {
134
133
  this.contentItem.off('destroy', this._dragListener.destroy, this._dragListener);
@@ -158,7 +157,16 @@ export default class Tab {
158
157
  /**
159
158
  * Callback when the contentItem is focused in
160
159
  */
161
- _onTabContentFocusIn() {
160
+ _onTabContentFocusIn(event) {
161
+ // If the focus originated from inside a nested LayoutManager (a
162
+ // dashboard within a dashboard), let that nested layout's tab own
163
+ // the focus indicator instead of this outer tab. The focusin event
164
+ // bubbles, so without this check the outer tab would clear the
165
+ // nested tab's "lm_focusin" class and claim focus for itself.
166
+ if (isComponent(this.contentItem) && (event === null || event === void 0 ? void 0 : event.target) instanceof Element && this._isInNestedLayout(event.target)) {
167
+ return;
168
+ }
169
+
162
170
  // Ensure only one tab is marked as having focus at a time.
163
171
  // In Firefox, if the focused element is removed from the DOM,
164
172
  // the focusout event won't trigger. This can result in two tabs
@@ -195,9 +203,12 @@ export default class Tab {
195
203
  var activeContentItem = this.header.parent.getActiveContentItem();
196
204
  if (this.contentItem !== activeContentItem && isComponent(this.contentItem)) {
197
205
  this.header.parent.setActiveContentItem(this.contentItem);
198
- } else if (isComponent(this.contentItem) && !this.contentItem.container._contentElement[0].contains(document.activeElement)) {
206
+ } else if (isComponent(this.contentItem) && !this._isFocusDirectlyInContainer()) {
199
207
  // if no focus inside put focus onto the container
200
- // so focusin always fires for tabclicks
208
+ // so focusin always fires for tabclicks. Focus inside a nested
209
+ // LayoutManager is not considered "inside" this container so
210
+ // that clicking the outer tab transfers focus (and the
211
+ // lm_focusin indicator) to it.
201
212
  this.contentItem.container._contentElement.focus();
202
213
  }
203
214
  if (isComponent(this.contentItem)) {
@@ -256,6 +267,33 @@ export default class Tab {
256
267
  _onCloseMousedown(event) {
257
268
  event.stopPropagation();
258
269
  }
270
+
271
+ /**
272
+ * Returns true if the given element is inside this content item's
273
+ * container but within a nested LayoutManager (i.e. a dashboard
274
+ * embedded inside this tab's component). Such focus belongs to the
275
+ * nested layout's tab, not this outer one.
276
+ */
277
+ _isInNestedLayout(element) {
278
+ var nestedLayoutRoot = $(element).closest('.lm_goldenlayout')[0];
279
+ var ownLayoutRoot = this._layoutManager.root.element[0];
280
+ return nestedLayoutRoot != null && nestedLayoutRoot !== ownLayoutRoot;
281
+ }
282
+
283
+ /**
284
+ * Returns true if the document's active element is inside this tab's
285
+ * container directly (not inside a nested LayoutManager).
286
+ */
287
+ _isFocusDirectlyInContainer() {
288
+ if (!isComponent(this.contentItem)) {
289
+ return false;
290
+ }
291
+ var active = document.activeElement;
292
+ if (active == null || !this.contentItem.container._contentElement[0].contains(active)) {
293
+ return false;
294
+ }
295
+ return !this._isInNestedLayout(active);
296
+ }
259
297
  }
260
298
  /**
261
299
  * The tab's html template
@@ -1 +1 @@
1
- {"version":3,"file":"Tab.js","names":["$","isComponent","DragListener","DragProxy","Tab","constructor","header","contentItem","_this$_layoutManager$","_defineProperty","_template","titleElement","element","find","closeElement","config","isClosable","setTitle","title","on","_layoutManager","layoutManager","settings","reorderEnabled","_dragListener","root","_onDragStart","destroy","_onTabClick","bind","_onCloseClick","_onTabContentFocusIn","_onTabContentFocusOut","_onMouseUp","_onCloseMousedown","remove","tab","emit","container","_contentElement","arguments","length","undefined","text","setContentItem","newContentItem","oldContentItem","off","setActive","isActive","addClass","removeClass","_$destroy","removeEventListener","x","y","_this$contentItem$par","parent","isMaximised","toggleMaximise","contains","document","activeElement","event","button","_this$element$get","activeContentItem","getActiveContentItem","setActiveContentItem","focus","_hideAdditionalTabsDropdown","get","scrollIntoView","inline","stopPropagation","close","removeChild","preventDefault","join"],"sources":["../../src/controls/Tab.ts"],"sourcesContent":["import $ from 'jquery';\nimport type { AbstractContentItem } from '../items';\nimport { isComponent } from '../items';\nimport type LayoutManager from '../LayoutManager';\nimport { DragListener } from '../utils';\nimport DragProxy from './DragProxy';\nimport type Header from './Header';\n\n/**\n * Represents an individual tab within a Stack's header\n *\n * @param header\n * @param contentItem\n */\nexport default class Tab {\n /**\n * The tab's html template\n */\n private static _template = [\n '<li class=\"lm_tab\">',\n '<span class=\"lm_title_before\"></span>',\n '<span class=\"lm_title\"></span>',\n '<div class=\"lm_close_tab\" aria-label=\"Close tab\"></div>',\n '</li>',\n ].join('');\n\n header: Header;\n contentItem: AbstractContentItem;\n element = $(Tab._template);\n titleElement: JQuery<HTMLElement>;\n closeElement: JQuery<HTMLElement>;\n isActive = false;\n\n private _layoutManager: LayoutManager;\n private _dragListener?: DragListener;\n\n constructor(header: Header, contentItem: AbstractContentItem) {\n this.header = header;\n this.contentItem = contentItem;\n this.titleElement = this.element.find('.lm_title');\n this.closeElement = this.element.find('.lm_close_tab');\n this.closeElement[contentItem.config.isClosable ? 'show' : 'hide']();\n\n this.setTitle(contentItem.config.title);\n this.contentItem.on('titleChanged', this.setTitle, this);\n\n this._layoutManager = this.contentItem.layoutManager;\n\n if (\n this._layoutManager.config.settings?.reorderEnabled &&\n contentItem.config.reorderEnabled\n ) {\n this._dragListener = new DragListener(\n this.element,\n this._layoutManager.root\n );\n this._dragListener.on('dragStart', this._onDragStart, this);\n this.contentItem.on(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n }\n\n this._onTabClick = this._onTabClick.bind(this);\n this._onCloseClick = this._onCloseClick.bind(this);\n this._onTabContentFocusIn = this._onTabContentFocusIn.bind(this);\n this._onTabContentFocusOut = this._onTabContentFocusOut.bind(this);\n\n this.element.on('click', this._onTabClick);\n this.element.on('auxclick', this._onTabClick);\n this.element.on('mouseup', this._onMouseUp);\n\n if (this.contentItem.config.isClosable) {\n this.closeElement.on('click', this._onCloseClick);\n this.closeElement.on('mousedown', this._onCloseMousedown);\n } else {\n this.closeElement.remove();\n }\n\n this.contentItem.tab = this;\n this.contentItem.emit('tab', this);\n this.contentItem.layoutManager.emit('tabCreated', this);\n\n if (isComponent(this.contentItem)) {\n // add focus class to tab when content\n this.contentItem.container._contentElement\n .on('focusin', this._onTabContentFocusIn)\n .on('focusout', this._onTabContentFocusOut);\n\n this.contentItem.container.tab = this;\n this.contentItem.container.emit('tab', this);\n }\n }\n\n /**\n * Sets the tab's title to the provided string and sets\n * its title attribute to a pure text representation (without\n * html tags) of the same string.\n * @param title can contain html\n */\n setTitle(title = '') {\n // Disabling for illumon project, we want to manage our own tooltips\n // this.element.attr( 'title', lm.utils.stripTags( title ) );\n this.titleElement.text(title);\n }\n\n /**\n * Updates the content item this tab is associated with.\n * Properly transfers event listeners from the old content item to the new one.\n * @param newContentItem The new content item\n */\n setContentItem(newContentItem: AbstractContentItem) {\n const oldContentItem = this.contentItem;\n\n // Transfer the 'destroy' listener if dragListener exists\n if (this._dragListener) {\n oldContentItem.off(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n newContentItem.on(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n }\n\n // Transfer 'titleChanged' listener\n oldContentItem.off('titleChanged', this.setTitle, this);\n newContentItem.on('titleChanged', this.setTitle, this);\n\n // Update the reference\n this.contentItem = newContentItem;\n newContentItem.tab = this;\n\n // Update title\n this.setTitle(newContentItem.config.title);\n }\n\n /**\n * Sets this tab's active state. To programmatically\n * switch tabs, use header.setActiveContentItem( item ) instead.\n * @param isActive\n */\n setActive(isActive: boolean) {\n if (isActive === this.isActive) {\n return;\n }\n this.isActive = isActive;\n\n if (isActive) {\n this.element.addClass('lm_active');\n } else {\n this.element.removeClass('lm_active');\n }\n }\n\n /**\n * Destroys the tab\n *\n * @private\n * @returns {void}\n */\n _$destroy() {\n this.element.off('click', this._onTabClick);\n this.element.off('auxclick', this._onTabClick);\n this.element.off('mouseup', this._onMouseUp);\n this.closeElement.off('click', this._onCloseClick);\n if (isComponent(this.contentItem)) {\n this.contentItem.container._contentElement.off();\n this.contentItem.container._contentElement[0].removeEventListener(\n 'click',\n this._onTabContentFocusIn,\n true\n );\n }\n if (this._dragListener) {\n this.contentItem.off(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n this._dragListener.off('dragStart', this._onDragStart);\n this._dragListener = undefined;\n }\n this.element.remove();\n }\n\n /**\n * Callback for the DragListener\n *\n * @param x The tabs absolute x position\n * @param y The tabs absolute y position\n */\n _onDragStart(x: number, y: number) {\n if (this.contentItem.parent?.isMaximised) {\n this.contentItem.parent.toggleMaximise();\n }\n\n if (!this._dragListener) {\n return;\n }\n\n new DragProxy(\n x,\n y,\n this._dragListener,\n this._layoutManager,\n this.contentItem,\n this.header.parent\n );\n }\n\n /**\n * Callback when the contentItem is focused in\n */\n _onTabContentFocusIn() {\n // Ensure only one tab is marked as having focus at a time.\n // In Firefox, if the focused element is removed from the DOM,\n // the focusout event won't trigger. This can result in two tabs\n // being erroneously marked as focused if the user's DOM element\n // is removed and they click another tab. To prevent this, we\n // remove existing \"lm_focusin\" classes first.\n $('.lm_focusin', this._layoutManager.root.element).removeClass(\n 'lm_focusin'\n );\n\n this.element.addClass('lm_focusin');\n }\n\n /**\n * Callback when the contentItem is focused out\n *\n * @param {jQuery DOM event} event\n *\n * @private\n * @returns {void}\n */\n _onTabContentFocusOut() {\n if (\n isComponent(this.contentItem) &&\n !this.contentItem.container._contentElement[0].contains(\n document.activeElement\n )\n ) {\n this.element.removeClass('lm_focusin');\n }\n }\n\n /**\n * Callback when the tab is clicked\n *\n * @param event\n */\n _onTabClick(event?: JQuery.TriggeredEvent) {\n // left mouse button or tap\n if (!event || event.button === 0) {\n var activeContentItem = this.header.parent.getActiveContentItem();\n if (\n this.contentItem !== activeContentItem &&\n isComponent(this.contentItem)\n ) {\n this.header.parent.setActiveContentItem(this.contentItem);\n } else if (\n isComponent(this.contentItem) &&\n !this.contentItem.container._contentElement[0].contains(\n document.activeElement\n )\n ) {\n // if no focus inside put focus onto the container\n // so focusin always fires for tabclicks\n this.contentItem.container._contentElement.focus();\n }\n\n if (isComponent(this.contentItem)) {\n this.contentItem.container.emit('tabClicked', event);\n }\n\n // might have been called from the dropdown\n this.header._hideAdditionalTabsDropdown();\n\n // makes sure clicked tabs scrollintoview (either those partially offscreen or in dropdown)\n this.element.get(0)?.scrollIntoView({\n inline: 'nearest',\n // behaviour smooth is not possible here, as when a tab becomes active it may attempt to take focus\n // which interupts any scroll behaviour from completeting\n });\n\n // middle mouse button\n } else if (event.button === 1 && this.contentItem.config.isClosable) {\n this._onCloseClick(event);\n }\n }\n\n /**\n * Callback when the tab's close button is\n * clicked\n *\n * @param event\n */\n _onCloseClick(event: JQuery.TriggeredEvent) {\n event.stopPropagation();\n if (isComponent(this.contentItem)) {\n this.contentItem.container.close();\n } else {\n this.header.parent.removeChild(this.contentItem);\n }\n }\n\n /**\n * Callback to prevent paste into active input on Linux\n * when closing a tab via middle click.\n * @param event\n */\n _onMouseUp(event: JQuery.TriggeredEvent) {\n if (event.button === 1) {\n event.preventDefault(); // This seems to prevent the paste event from firing\n event.stopPropagation(); // Stop propagation just in case\n }\n }\n\n /**\n * Callback to capture tab close button mousedown\n * to prevent tab from activating.\n *\n * @param event\n */\n _onCloseMousedown(event: Event) {\n event.stopPropagation();\n }\n}\n"],"mappings":";;;AAAA,OAAOA,CAAC,MAAM,QAAQ;AAAC,SAEdC,WAAW;AAAA,SAEXC,YAAY;AAAA,OACdC,SAAS;AAGhB;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,MAAMC,GAAG,CAAC;EAsBvBC,WAAWA,CAACC,MAAc,EAAEC,WAAgC,EAAE;IAAA,IAAAC,qBAAA;IAAAC,eAAA;IAAAA,eAAA;IAAAA,eAAA,kBARpDT,CAAC,CAACI,GAAG,CAACM,SAAS,CAAC;IAAAD,eAAA;IAAAA,eAAA;IAAAA,eAAA,mBAGf,KAAK;IAAAA,eAAA;IAAAA,eAAA;IAMd,IAAI,CAACH,MAAM,GAAGA,MAAM;IACpB,IAAI,CAACC,WAAW,GAAGA,WAAW;IAC9B,IAAI,CAACI,YAAY,GAAG,IAAI,CAACC,OAAO,CAACC,IAAI,CAAC,WAAW,CAAC;IAClD,IAAI,CAACC,YAAY,GAAG,IAAI,CAACF,OAAO,CAACC,IAAI,CAAC,eAAe,CAAC;IACtD,IAAI,CAACC,YAAY,CAACP,WAAW,CAACQ,MAAM,CAACC,UAAU,GAAG,MAAM,GAAG,MAAM,CAAC,CAAC,CAAC;IAEpE,IAAI,CAACC,QAAQ,CAACV,WAAW,CAACQ,MAAM,CAACG,KAAK,CAAC;IACvC,IAAI,CAACX,WAAW,CAACY,EAAE,CAAC,cAAc,EAAE,IAAI,CAACF,QAAQ,EAAE,IAAI,CAAC;IAExD,IAAI,CAACG,cAAc,GAAG,IAAI,CAACb,WAAW,CAACc,aAAa;IAEpD,IACE,CAAAb,qBAAA,OAAI,C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L,iBAAA,OAAI,CAACrD,OAAO,CAAC2D,GAAG,CAAC,CAAC,CAAC,cAAAN,iBAAA,eAAnBA,iBAAA,CAAqBO,cAAc,CAAC;QAClCC,MAAM,EAAE;QACR;QACA;MACF,CAAC,CAAC;;MAEF;IACF,CAAC,MAAM,IAAIV,KAAK,CAACC,MAAM,KAAK,CAAC,IAAI,IAAI,CAACzD,WAAW,CAACQ,MAAM,CAACC,UAAU,EAAE;MACnE,IAAI,CAACc,aAAa,CAACiC,KAAK,CAAC;IAC3B;EACF;;EAEA;AACF;AACA;AACA;AACA;AACA;EACEjC,aAAaA,CAACiC,KAA4B,EAAE;IAC1CA,KAAK,CAACW,eAAe,CAAC,CAAC;IACvB,IAAIzE,WAAW,CAAC,IAAI,CAACM,WAAW,CAAC,EAAE;MACjC,IAAI,CAACA,WAAW,CAAC+B,SAAS,CAACqC,KAAK,CAAC,CAAC;IACpC,CAAC,MAAM;MACL,IAAI,CAACrE,MAAM,CAACmD,MAAM,CAACmB,WAAW,CAAC,IAAI,CAACrE,WAAW,CAAC;IAClD;EACF;;EAEA;AACF;AACA;AACA;AACA;EACE0B,UAAUA,CAAC8B,KAA4B,EAAE;IACvC,IAAIA,KAAK,CAACC,MAAM,KAAK,CAAC,EAAE;MACtBD,KAAK,CAACc,cAAc,CAAC,CAAC,CAAC,CAAC;MACxBd,KAAK,CAACW,eAAe,CAAC,CAAC,CAAC,CAAC;IAC3B;EACF;;EAEA;AACF;AACA;AACA;AACA;AACA;EACExC,iBAAiBA,CAAC6B,KAAY,EAAE;IAC9BA,KAAK,CAACW,eAAe,CAAC,CAAC;EACzB;AACF;AA7TE;AACF;AACA;AAFEjE,eAAA,CADmBL,GAAG,eAIK,CACzB,qBAAqB,EACrB,uCAAuC,EACvC,gCAAgC,EAChC,yDAAyD,EACzD,OAAO,CACR,CAAC0E,IAAI,CAAC,EAAE,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"Tab.js","names":["$","isComponent","DragListener","DragProxy","Tab","constructor","header","contentItem","_this$_layoutManager$","_defineProperty","_template","titleElement","element","find","closeElement","config","isClosable","setTitle","title","on","_layoutManager","layoutManager","settings","reorderEnabled","_dragListener","root","_onDragStart","destroy","_onTabClick","bind","_onCloseClick","_onTabContentFocusIn","_onTabContentFocusOut","_onMouseUp","_onCloseMousedown","remove","tab","emit","container","_contentElement","arguments","length","undefined","text","setContentItem","newContentItem","oldContentItem","off","setActive","isActive","addClass","removeClass","_$destroy","x","y","_this$contentItem$par","parent","isMaximised","toggleMaximise","event","target","Element","_isInNestedLayout","contains","document","activeElement","button","_this$element$get","activeContentItem","getActiveContentItem","setActiveContentItem","_isFocusDirectlyInContainer","focus","_hideAdditionalTabsDropdown","get","scrollIntoView","inline","stopPropagation","close","removeChild","preventDefault","nestedLayoutRoot","closest","ownLayoutRoot","active","join"],"sources":["../../src/controls/Tab.ts"],"sourcesContent":["import $ from 'jquery';\nimport type { AbstractContentItem } from '../items';\nimport { isComponent } from '../items';\nimport type LayoutManager from '../LayoutManager';\nimport { DragListener } from '../utils';\nimport DragProxy from './DragProxy';\nimport type Header from './Header';\n\n/**\n * Represents an individual tab within a Stack's header\n *\n * @param header\n * @param contentItem\n */\nexport default class Tab {\n /**\n * The tab's html template\n */\n private static _template = [\n '<li class=\"lm_tab\">',\n '<span class=\"lm_title_before\"></span>',\n '<span class=\"lm_title\"></span>',\n '<div class=\"lm_close_tab\" aria-label=\"Close tab\"></div>',\n '</li>',\n ].join('');\n\n header: Header;\n contentItem: AbstractContentItem;\n element = $(Tab._template);\n titleElement: JQuery<HTMLElement>;\n closeElement: JQuery<HTMLElement>;\n isActive = false;\n\n private _layoutManager: LayoutManager;\n private _dragListener?: DragListener;\n\n constructor(header: Header, contentItem: AbstractContentItem) {\n this.header = header;\n this.contentItem = contentItem;\n this.titleElement = this.element.find('.lm_title');\n this.closeElement = this.element.find('.lm_close_tab');\n this.closeElement[contentItem.config.isClosable ? 'show' : 'hide']();\n\n this.setTitle(contentItem.config.title);\n this.contentItem.on('titleChanged', this.setTitle, this);\n\n this._layoutManager = this.contentItem.layoutManager;\n\n if (\n this._layoutManager.config.settings?.reorderEnabled &&\n contentItem.config.reorderEnabled\n ) {\n this._dragListener = new DragListener(\n this.element,\n this._layoutManager.root\n );\n this._dragListener.on('dragStart', this._onDragStart, this);\n this.contentItem.on(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n }\n\n this._onTabClick = this._onTabClick.bind(this);\n this._onCloseClick = this._onCloseClick.bind(this);\n this._onTabContentFocusIn = this._onTabContentFocusIn.bind(this);\n this._onTabContentFocusOut = this._onTabContentFocusOut.bind(this);\n\n this.element.on('click', this._onTabClick);\n this.element.on('auxclick', this._onTabClick);\n this.element.on('mouseup', this._onMouseUp);\n\n if (this.contentItem.config.isClosable) {\n this.closeElement.on('click', this._onCloseClick);\n this.closeElement.on('mousedown', this._onCloseMousedown);\n } else {\n this.closeElement.remove();\n }\n\n this.contentItem.tab = this;\n this.contentItem.emit('tab', this);\n this.contentItem.layoutManager.emit('tabCreated', this);\n\n if (isComponent(this.contentItem)) {\n // add focus class to tab when content\n this.contentItem.container._contentElement\n .on('focusin', this._onTabContentFocusIn)\n .on('focusout', this._onTabContentFocusOut);\n\n this.contentItem.container.tab = this;\n this.contentItem.container.emit('tab', this);\n }\n }\n\n /**\n * Sets the tab's title to the provided string and sets\n * its title attribute to a pure text representation (without\n * html tags) of the same string.\n * @param title can contain html\n */\n setTitle(title = '') {\n // Disabling for illumon project, we want to manage our own tooltips\n // this.element.attr( 'title', lm.utils.stripTags( title ) );\n this.titleElement.text(title);\n }\n\n /**\n * Updates the content item this tab is associated with.\n * Properly transfers event listeners from the old content item to the new one.\n * @param newContentItem The new content item\n */\n setContentItem(newContentItem: AbstractContentItem) {\n const oldContentItem = this.contentItem;\n\n // Transfer the 'destroy' listener if dragListener exists\n if (this._dragListener) {\n oldContentItem.off(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n newContentItem.on(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n }\n\n // Transfer 'titleChanged' listener\n oldContentItem.off('titleChanged', this.setTitle, this);\n newContentItem.on('titleChanged', this.setTitle, this);\n\n // Update the reference\n this.contentItem = newContentItem;\n newContentItem.tab = this;\n\n // Update title\n this.setTitle(newContentItem.config.title);\n }\n\n /**\n * Sets this tab's active state. To programmatically\n * switch tabs, use header.setActiveContentItem( item ) instead.\n * @param isActive\n */\n setActive(isActive: boolean) {\n if (isActive === this.isActive) {\n return;\n }\n this.isActive = isActive;\n\n if (isActive) {\n this.element.addClass('lm_active');\n } else {\n this.element.removeClass('lm_active');\n }\n }\n\n /**\n * Destroys the tab\n *\n * @private\n * @returns {void}\n */\n _$destroy() {\n this.element.off('click', this._onTabClick);\n this.element.off('auxclick', this._onTabClick);\n this.element.off('mouseup', this._onMouseUp);\n this.closeElement.off('click', this._onCloseClick);\n if (isComponent(this.contentItem)) {\n this.contentItem.container._contentElement.off();\n }\n if (this._dragListener) {\n this.contentItem.off(\n 'destroy',\n this._dragListener.destroy,\n this._dragListener\n );\n this._dragListener.off('dragStart', this._onDragStart);\n this._dragListener = undefined;\n }\n this.element.remove();\n }\n\n /**\n * Callback for the DragListener\n *\n * @param x The tabs absolute x position\n * @param y The tabs absolute y position\n */\n _onDragStart(x: number, y: number) {\n if (this.contentItem.parent?.isMaximised) {\n this.contentItem.parent.toggleMaximise();\n }\n\n if (!this._dragListener) {\n return;\n }\n\n new DragProxy(\n x,\n y,\n this._dragListener,\n this._layoutManager,\n this.contentItem,\n this.header.parent\n );\n }\n\n /**\n * Callback when the contentItem is focused in\n */\n _onTabContentFocusIn(event?: JQuery.TriggeredEvent) {\n // If the focus originated from inside a nested LayoutManager (a\n // dashboard within a dashboard), let that nested layout's tab own\n // the focus indicator instead of this outer tab. The focusin event\n // bubbles, so without this check the outer tab would clear the\n // nested tab's \"lm_focusin\" class and claim focus for itself.\n if (\n isComponent(this.contentItem) &&\n event?.target instanceof Element &&\n this._isInNestedLayout(event.target)\n ) {\n return;\n }\n\n // Ensure only one tab is marked as having focus at a time.\n // In Firefox, if the focused element is removed from the DOM,\n // the focusout event won't trigger. This can result in two tabs\n // being erroneously marked as focused if the user's DOM element\n // is removed and they click another tab. To prevent this, we\n // remove existing \"lm_focusin\" classes first.\n $('.lm_focusin', this._layoutManager.root.element).removeClass(\n 'lm_focusin'\n );\n\n this.element.addClass('lm_focusin');\n }\n\n /**\n * Callback when the contentItem is focused out\n *\n * @param {jQuery DOM event} event\n *\n * @private\n * @returns {void}\n */\n _onTabContentFocusOut() {\n if (\n isComponent(this.contentItem) &&\n !this.contentItem.container._contentElement[0].contains(\n document.activeElement\n )\n ) {\n this.element.removeClass('lm_focusin');\n }\n }\n\n /**\n * Callback when the tab is clicked\n *\n * @param event\n */\n _onTabClick(event?: JQuery.TriggeredEvent) {\n // left mouse button or tap\n if (!event || event.button === 0) {\n var activeContentItem = this.header.parent.getActiveContentItem();\n if (\n this.contentItem !== activeContentItem &&\n isComponent(this.contentItem)\n ) {\n this.header.parent.setActiveContentItem(this.contentItem);\n } else if (\n isComponent(this.contentItem) &&\n !this._isFocusDirectlyInContainer()\n ) {\n // if no focus inside put focus onto the container\n // so focusin always fires for tabclicks. Focus inside a nested\n // LayoutManager is not considered \"inside\" this container so\n // that clicking the outer tab transfers focus (and the\n // lm_focusin indicator) to it.\n this.contentItem.container._contentElement.focus();\n }\n\n if (isComponent(this.contentItem)) {\n this.contentItem.container.emit('tabClicked', event);\n }\n\n // might have been called from the dropdown\n this.header._hideAdditionalTabsDropdown();\n\n // makes sure clicked tabs scrollintoview (either those partially offscreen or in dropdown)\n this.element.get(0)?.scrollIntoView({\n inline: 'nearest',\n // behaviour smooth is not possible here, as when a tab becomes active it may attempt to take focus\n // which interupts any scroll behaviour from completeting\n });\n\n // middle mouse button\n } else if (event.button === 1 && this.contentItem.config.isClosable) {\n this._onCloseClick(event);\n }\n }\n\n /**\n * Callback when the tab's close button is\n * clicked\n *\n * @param event\n */\n _onCloseClick(event: JQuery.TriggeredEvent) {\n event.stopPropagation();\n if (isComponent(this.contentItem)) {\n this.contentItem.container.close();\n } else {\n this.header.parent.removeChild(this.contentItem);\n }\n }\n\n /**\n * Callback to prevent paste into active input on Linux\n * when closing a tab via middle click.\n * @param event\n */\n _onMouseUp(event: JQuery.TriggeredEvent) {\n if (event.button === 1) {\n event.preventDefault(); // This seems to prevent the paste event from firing\n event.stopPropagation(); // Stop propagation just in case\n }\n }\n\n /**\n * Callback to capture tab close button mousedown\n * to prevent tab from activating.\n *\n * @param event\n */\n _onCloseMousedown(event: Event) {\n event.stopPropagation();\n }\n\n /**\n * Returns true if the given element is inside this content item's\n * container but within a nested LayoutManager (i.e. a dashboard\n * embedded inside this tab's component). Such focus belongs to the\n * nested layout's tab, not this outer one.\n */\n private _isInNestedLayout(element: Element): boolean {\n const nestedLayoutRoot = $(element).closest('.lm_goldenlayout')[0];\n const ownLayoutRoot = this._layoutManager.root.element[0];\n return nestedLayoutRoot != null && nestedLayoutRoot !== ownLayoutRoot;\n }\n\n /**\n * Returns true if the document's active element is inside this tab's\n * container directly (not inside a nested LayoutManager).\n */\n private _isFocusDirectlyInContainer(): boolean {\n if (!isComponent(this.contentItem)) {\n return false;\n }\n const active = document.activeElement;\n if (\n active == null ||\n !this.contentItem.container._contentElement[0].contains(active)\n ) {\n return false;\n }\n return !this._isInNestedLayout(active);\n }\n}\n"],"mappings":";;;AAAA,OAAOA,CAAC,MAAM,QAAQ;AAAC,SAEdC,WAAW;AAAA,SAEXC,YAAY;AAAA,OACdC,SAAS;AAGhB;AACA;AACA;AACA;AACA;AACA;AACA,eAAe,MAAMC,GAAG,CAAC;EAsBvBC,WAAWA,CAACC,MAAc,EAAEC,WAAgC,EAAE;IAAA,IAAAC,qBAAA;IAAAC,eAAA;IAAAA,eAAA;IAAAA,eAAA,kBARpDT,CAAC,CAACI,GAAG,CAACM,SAAS,CAAC;IAAAD,eAAA;IAAAA,eAAA;IAAAA,eAAA,mBAGf,KAAK;IAAAA,eAAA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qB,EACrB,uCAAuC,EACvC,gCAAgC,EAChC,yDAAyD,EACzD,OAAO,CACR,CAACiF,IAAI,CAAC,EAAE,CAAC","ignoreList":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@deephaven/golden-layout",
3
- "version": "1.18.1-iris-grid-16.0+d19001c",
3
+ "version": "1.18.1",
4
4
  "author": "Deephaven Data Labs LLC",
5
5
  "license": "Apache-2.0",
6
6
  "description": "A multi-screen javascript Layout manager",
@@ -10,7 +10,7 @@
10
10
  "source": "src/index.ts",
11
11
  "type": "module",
12
12
  "dependencies": {
13
- "@deephaven/components": "^1.18.1-iris-grid-16.0+d19001c",
13
+ "@deephaven/components": "^1.17.0",
14
14
  "jquery": "^3.6.0",
15
15
  "nanoid": "^5.0.7"
16
16
  },
@@ -46,5 +46,5 @@
46
46
  "publishConfig": {
47
47
  "access": "public"
48
48
  },
49
- "gitHead": "d19001cac08dc279784bb01db74e3aca0e8b6836"
49
+ "gitHead": "ce430c4d4bf89c95a6a9ade1d8bf3a88becad98d"
50
50
  }