@memberjunction/ng-explorer-core 6.1.5 → 6.1.6
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/dist/lib/shell/components/tabs/tab-container.component.d.ts +14 -0
- package/dist/lib/shell/components/tabs/tab-container.component.d.ts.map +1 -1
- package/dist/lib/shell/components/tabs/tab-container.component.js +72 -12
- package/dist/lib/shell/components/tabs/tab-container.component.js.map +1 -1
- package/dist/lib/shell/shell.component.d.ts +31 -2
- package/dist/lib/shell/shell.component.d.ts.map +1 -1
- package/dist/lib/shell/shell.component.js +75 -4
- package/dist/lib/shell/shell.component.js.map +1 -1
- package/package.json +52 -52
|
@@ -47,6 +47,7 @@ export declare class TabContainerComponent extends BaseAngularComponent implemen
|
|
|
47
47
|
/** Pane-level origin crumbs, one per record pane (see RecordOriginCrumbComponent) */
|
|
48
48
|
private originCrumbRefs;
|
|
49
49
|
private tabsCurrentlyLoading;
|
|
50
|
+
private pendingRecordShows;
|
|
50
51
|
private cacheManager;
|
|
51
52
|
useSingleResourceMode: boolean;
|
|
52
53
|
private singleResourceComponentRef;
|
|
@@ -188,6 +189,19 @@ export declare class TabContainerComponent extends BaseAngularComponent implemen
|
|
|
188
189
|
* `ensureRecordOriginCrumb` once the incoming record attaches.
|
|
189
190
|
*/
|
|
190
191
|
private reloadRecordsTabIfResourceChanged;
|
|
192
|
+
/**
|
|
193
|
+
* Load a record tab's content into its GL container and mark it loaded —
|
|
194
|
+
* the second half of the TabShown handler, split out so a show parked
|
|
195
|
+
* while the region was hidden can be replayed on reveal.
|
|
196
|
+
*/
|
|
197
|
+
private loadShownRecordTab;
|
|
198
|
+
/**
|
|
199
|
+
* Replay the shows parked while the records region was hidden (see the
|
|
200
|
+
* TabShown handler). Always against the LIVE container: a breakpoint
|
|
201
|
+
* rebuild between park and reveal replaces the one GL handed us (and its
|
|
202
|
+
* Destroy fires TabClosed, which drops the stale entry anyway).
|
|
203
|
+
*/
|
|
204
|
+
private flushPendingRecordShows;
|
|
191
205
|
/** Focus a records-region tab without feeding back into SetActiveTab loops */
|
|
192
206
|
private focusRecordsTab;
|
|
193
207
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tab-container.component.d.ts","sourceRoot":"","sources":["../../../../../src/lib/shell/components/tabs/tab-container.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,MAAM,EACN,SAAS,EACT,aAAa,EAEb,UAAU,EACV,cAAc,EACd,mBAAmB,EAKnB,iBAAiB,EAGjB,YAAY,EAEb,MAAM,eAAe,CAAC;AAEvB,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,kBAAkB,EAMnB,MAAM,qCAAqC,CAAC;AAM7C,OAAO,EAAE,mBAAmB,EAAE,MAAM,gDAAgD,CAAC;AAGrF,OAAO,EAAyB,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAEvF,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;AAIrE;;;;;;;;;GASG;AACH,qBAOa,qBAAsB,SAAQ,oBAAqB,YAAW,MAAM,EAAE,SAAS,EAAE,aAAa;
|
|
1
|
+
{"version":3,"file":"tab-container.component.d.ts","sourceRoot":"","sources":["../../../../../src/lib/shell/components/tabs/tab-container.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,MAAM,EACN,SAAS,EACT,aAAa,EAEb,UAAU,EACV,cAAc,EACd,mBAAmB,EAKnB,iBAAiB,EAGjB,YAAY,EAEb,MAAM,eAAe,CAAC;AAEvB,OAAO,EACL,mBAAmB,EACnB,qBAAqB,EACrB,kBAAkB,EAMnB,MAAM,qCAAqC,CAAC;AAM7C,OAAO,EAAE,mBAAmB,EAAE,MAAM,gDAAgD,CAAC;AAGrF,OAAO,EAAyB,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAEvF,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;;AAIrE;;;;;;;;;GASG;AACH,qBAOa,qBAAs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,IAAI,kBAAkB,IAAI,OAAO,CAIhC;IAED,gFAAgF;IAChF,IAAI,yBAAyB,IAAI,OAAO,CAKvC;IAED,sEAAsE;IACtE,IAAI,uBAAuB,IAAI,OAAO,CAIrC;IAED;;;;;;;OAOG;IACH,wBAAwB,IAAI,IAAI;IAShC;;;;;;OAMG;IACH,sBAAsB,IAAI,IAAI;IAS9B;;;;;;OAMG;IACH,OAAO,CAAC,wBAAwB;IAShC;;OAEG;IACH,YAAY,IAAI,IAAI;IAOpB;;OAEG;IACH,cAAc,IAAI,IAAI;IAUtB;;OAEG;IACH,oBAAoB,IAAI,IAAI;IAO5B;;OAEG;IACH,qBAAqB,IAAI,IAAI;IAO7B;;OAEG;IACH,IAAI,wBAAwB,IAAI,OAAO,CAMtC;IAED;;OAEG;IACG,kBAAkB,IAAI,OAAO,CAAC,IAAI,CAAC;IAsDzC;;OAEG;IACH,OAAO,CAAC,mBAAmB;IAW3B;;OAEG;YACW,0BAA0B;IA2BxC;;;OAGG;IACU,sBAAsB,IAAI,OAAO,CAAC,MAAM,GAAG,SAAS,CAAC;IAiBlE;;;;OAIG;IACH,OAAO,CAAC,yBAAyB;IAIjC;;;;;;;;OAQG;IACH,OAAO,CAAC,0BAA0B;yCAvwFvB,qBAAqB;2CAArB,qBAAqB;CA8zFjC"}
|
|
@@ -188,6 +188,15 @@ export class TabContainerComponent extends BaseAngularComponent {
|
|
|
188
188
|
// When a tab's content changes while active, both the reload path (workspace config subscription)
|
|
189
189
|
// and onTabShown can race to call loadTabContent, resulting in duplicate component rendering.
|
|
190
190
|
tabsCurrentlyLoading = new Set();
|
|
191
|
+
// Record-tab shows GL fired while the records region was HIDDEN, by tab id.
|
|
192
|
+
// Their content loads are deferred until the region is the visible surface —
|
|
193
|
+
// see the TabShown handler in wireRecordsLayoutEvents.
|
|
194
|
+
//
|
|
195
|
+
// A SET, not a map of containers: the replay deliberately re-resolves the live
|
|
196
|
+
// container via GetContainer(tabId), so a parked one would never be read — and
|
|
197
|
+
// holding it would retain a GL container, and its possibly-detached DOM, for as
|
|
198
|
+
// long as the region stays hidden. The type says the id is all that is kept.
|
|
199
|
+
pendingRecordShows = new Set();
|
|
191
200
|
// NEW: Smart component cache for preserving state across tab switches
|
|
192
201
|
cacheManager;
|
|
193
202
|
// Single-resource mode: render component directly without Golden Layout
|
|
@@ -420,6 +429,9 @@ export class TabContainerComponent extends BaseAngularComponent {
|
|
|
420
429
|
// Flush NOW — the visibility class must land in this pass, not
|
|
421
430
|
// whenever the next unrelated emission happens to run CD.
|
|
422
431
|
this.flushRegionCd();
|
|
432
|
+
if (showing) {
|
|
433
|
+
this.flushPendingRecordShows();
|
|
434
|
+
}
|
|
423
435
|
}
|
|
424
436
|
if (showing && activeTab && this.recordsLayoutInitialized) {
|
|
425
437
|
this.focusRecordsTab(activeTab.id);
|
|
@@ -536,6 +548,46 @@ export class TabContainerComponent extends BaseAngularComponent {
|
|
|
536
548
|
}
|
|
537
549
|
return true;
|
|
538
550
|
}
|
|
551
|
+
/**
|
|
552
|
+
* Load a record tab's content into its GL container and mark it loaded —
|
|
553
|
+
* the second half of the TabShown handler, split out so a show parked
|
|
554
|
+
* while the region was hidden can be replayed on reveal.
|
|
555
|
+
*/
|
|
556
|
+
async loadShownRecordTab(tabId, container) {
|
|
557
|
+
await this.loadTabContent(tabId, container);
|
|
558
|
+
// Mark loaded ONLY when content actually attached to the LIVE
|
|
559
|
+
// container. During layout restore, GL can re-render item elements
|
|
560
|
+
// while an async load is in flight — the load appends into a
|
|
561
|
+
// detached element and the visible pane stays blank. Leaving the
|
|
562
|
+
// tab unmarked lets the next show retry, which hits the component
|
|
563
|
+
// cache and reattaches instantly into the live element.
|
|
564
|
+
const live = this.recordsLayoutManager.GetContainer(tabId);
|
|
565
|
+
if (live?.element && live.element.childElementCount > 0) {
|
|
566
|
+
this.recordsLayoutManager.MarkTabLoaded(tabId);
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
/**
|
|
570
|
+
* Replay the shows parked while the records region was hidden (see the
|
|
571
|
+
* TabShown handler). Always against the LIVE container: a breakpoint
|
|
572
|
+
* rebuild between park and reveal replaces the one GL handed us (and its
|
|
573
|
+
* Destroy fires TabClosed, which drops the stale entry anyway).
|
|
574
|
+
*/
|
|
575
|
+
flushPendingRecordShows() {
|
|
576
|
+
if (this.pendingRecordShows.size === 0) {
|
|
577
|
+
return;
|
|
578
|
+
}
|
|
579
|
+
const parked = [...this.pendingRecordShows];
|
|
580
|
+
this.pendingRecordShows.clear();
|
|
581
|
+
for (const tabId of parked) {
|
|
582
|
+
if (this.recordsLayoutManager.IsTabLoaded(tabId)) {
|
|
583
|
+
continue;
|
|
584
|
+
}
|
|
585
|
+
const live = this.recordsLayoutManager.GetContainer(tabId);
|
|
586
|
+
if (live) {
|
|
587
|
+
this.loadShownRecordTab(tabId, live).catch(e => LogError(`Deferred record tab load failed for ${tabId}: ${e}`));
|
|
588
|
+
}
|
|
589
|
+
}
|
|
590
|
+
}
|
|
539
591
|
/** Focus a records-region tab without feeding back into SetActiveTab loops */
|
|
540
592
|
focusRecordsTab(tabId) {
|
|
541
593
|
if (this.recordsRegionActiveTabId !== tabId) {
|
|
@@ -781,20 +833,28 @@ export class TabContainerComponent extends BaseAngularComponent {
|
|
|
781
833
|
*/
|
|
782
834
|
wireRecordsLayoutEvents() {
|
|
783
835
|
this.subscriptions.push(this.recordsLayoutManager.TabShown.subscribe(async (event) => {
|
|
784
|
-
if (event.isFirstShow) {
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
836
|
+
if (!event.isFirstShow) {
|
|
837
|
+
return;
|
|
838
|
+
}
|
|
839
|
+
// LAZY content. The records GL initializes EAGERLY (see
|
|
840
|
+
// ensureRecordsLayoutInitialized) so the strip and the pill never
|
|
841
|
+
// drift from the workspace — and as it builds, GL fires 'show' for
|
|
842
|
+
// every stack's active tab while the region is still
|
|
843
|
+
// visibility-hidden behind the main surface. Loading content on
|
|
844
|
+
// those shows means every restored record hydrates at BOOT: an open
|
|
845
|
+
// AI Agent Run pulls its whole run tree (every prompt run, action
|
|
846
|
+
// log, step) before the user has looked at it, and client-side
|
|
847
|
+
// RunView coalescing folds the ACTIVE tab's own reads into the same
|
|
848
|
+
// requests, so the surface the user is looking at waits for records
|
|
849
|
+
// they are not. Park the show; it is replayed when the region shows.
|
|
850
|
+
if (!this.ShowRecordsRegion) {
|
|
851
|
+
this.pendingRecordShows.add(event.tabId);
|
|
852
|
+
return;
|
|
796
853
|
}
|
|
854
|
+
this.pendingRecordShows.delete(event.tabId);
|
|
855
|
+
await this.loadShownRecordTab(event.tabId, event.container);
|
|
797
856
|
}), this.recordsLayoutManager.TabClosed.subscribe(async (tabId) => {
|
|
857
|
+
this.pendingRecordShows.delete(tabId);
|
|
798
858
|
this.cleanupTabComponent(tabId);
|
|
799
859
|
// REBUILD guard (breakpoint crossing): Destroy() fires TabClosed for
|
|
800
860
|
// every pane. The tabs are NOT closing — the layout is being rebuilt
|