@memberjunction/ng-ai-test-harness 6.1.0-edge.4 → 6.1.0-edge.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/agent-execution-monitor.component.js +17 -18
- package/dist/lib/agent-execution-monitor.component.js.map +1 -1
- package/dist/lib/agent-execution-node.component.js +1 -1
- package/dist/lib/ai-test-harness-dialog.component.js +1 -2
- package/dist/lib/ai-test-harness-dialog.component.js.map +1 -1
- package/dist/lib/ai-test-harness.component.js +1 -1
- package/dist/lib/test-harness-custom-window.component.js +15 -16
- package/dist/lib/test-harness-custom-window.component.js.map +1 -1
- package/dist/lib/window-dock.service.js +1 -1
- package/package.json +23 -23
|
@@ -21,21 +21,21 @@ function AgentExecutionMonitorComponent_Conditional_7_Template(rf, ctx) { if (rf
|
|
|
21
21
|
i0.ɵɵtext(4);
|
|
22
22
|
i0.ɵɵelementEnd()();
|
|
23
23
|
} if (rf & 2) {
|
|
24
|
-
const
|
|
24
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
25
25
|
i0.ɵɵadvance(4);
|
|
26
|
-
i0.ɵɵtextInterpolate(
|
|
26
|
+
i0.ɵɵtextInterpolate(ctx_r0.currentStep.StepName);
|
|
27
27
|
} }
|
|
28
28
|
function AgentExecutionMonitorComponent_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
29
|
-
const
|
|
29
|
+
const _r2 = i0.ɵɵgetCurrentView();
|
|
30
30
|
i0.ɵɵelementStart(0, "button", 22);
|
|
31
|
-
i0.ɵɵlistener("click", function AgentExecutionMonitorComponent_Conditional_8_Template_button_click_0_listener() { i0.ɵɵrestoreView(
|
|
31
|
+
i0.ɵɵlistener("click", function AgentExecutionMonitorComponent_Conditional_8_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.onViewRunClick()); });
|
|
32
32
|
i0.ɵɵelement(1, "i", 23);
|
|
33
33
|
i0.ɵɵtext(2);
|
|
34
34
|
i0.ɵɵelementEnd();
|
|
35
35
|
} if (rf & 2) {
|
|
36
|
-
const
|
|
36
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
37
37
|
i0.ɵɵadvance(2);
|
|
38
|
-
i0.ɵɵtextInterpolate1(" View ",
|
|
38
|
+
i0.ɵɵtextInterpolate1(" View ", ctx_r0.runType === "agent" ? "Agent" : "Prompt", " Run ");
|
|
39
39
|
} }
|
|
40
40
|
function AgentExecutionMonitorComponent_Conditional_13_Template(rf, ctx) { if (rf & 1) {
|
|
41
41
|
i0.ɵɵelement(0, "mj-empty-state", 11);
|
|
@@ -45,9 +45,9 @@ function AgentExecutionMonitorComponent_Conditional_21_Template(rf, ctx) { if (r
|
|
|
45
45
|
i0.ɵɵtext(1);
|
|
46
46
|
i0.ɵɵelementEnd();
|
|
47
47
|
} if (rf & 2) {
|
|
48
|
-
const
|
|
48
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
49
49
|
i0.ɵɵadvance();
|
|
50
|
-
i0.ɵɵtextInterpolate1("(",
|
|
50
|
+
i0.ɵɵtextInterpolate1("(", ctx_r0.stats.failedSteps, " failed)");
|
|
51
51
|
} }
|
|
52
52
|
function AgentExecutionMonitorComponent_Conditional_37_Template(rf, ctx) { if (rf & 1) {
|
|
53
53
|
i0.ɵɵelementStart(0, "div", 14)(1, "span", 15);
|
|
@@ -57,28 +57,28 @@ function AgentExecutionMonitorComponent_Conditional_37_Template(rf, ctx) { if (r
|
|
|
57
57
|
i0.ɵɵtext(4);
|
|
58
58
|
i0.ɵɵelementEnd()();
|
|
59
59
|
} if (rf & 2) {
|
|
60
|
-
const
|
|
60
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
61
61
|
i0.ɵɵadvance(4);
|
|
62
|
-
i0.ɵɵtextInterpolate(
|
|
62
|
+
i0.ɵɵtextInterpolate(ctx_r0.formatDuration(ctx_r0.stats.totalDuration));
|
|
63
63
|
} }
|
|
64
64
|
function AgentExecutionMonitorComponent_Conditional_38_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
65
65
|
i0.ɵɵelementStart(0, "span", 24);
|
|
66
66
|
i0.ɵɵtext(1);
|
|
67
67
|
i0.ɵɵelementEnd();
|
|
68
68
|
} if (rf & 2) {
|
|
69
|
-
const
|
|
70
|
-
const
|
|
69
|
+
const type_r3 = ctx.$implicit;
|
|
70
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
71
71
|
i0.ɵɵadvance();
|
|
72
|
-
i0.ɵɵtextInterpolate2(" ",
|
|
72
|
+
i0.ɵɵtextInterpolate2(" ", ctx_r0.stats.stepsByType[type_r3], " ", ctx_r0.pluralizeStepType(type_r3, ctx_r0.stats.stepsByType[type_r3]), " ");
|
|
73
73
|
} }
|
|
74
74
|
function AgentExecutionMonitorComponent_Conditional_38_Template(rf, ctx) { if (rf & 1) {
|
|
75
75
|
i0.ɵɵelementStart(0, "div", 18);
|
|
76
76
|
i0.ɵɵrepeaterCreate(1, AgentExecutionMonitorComponent_Conditional_38_For_2_Template, 2, 2, "span", 24, i0.ɵɵrepeaterTrackByIdentity);
|
|
77
77
|
i0.ɵɵelementEnd();
|
|
78
78
|
} if (rf & 2) {
|
|
79
|
-
const
|
|
79
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
80
80
|
i0.ɵɵadvance();
|
|
81
|
-
i0.ɵɵrepeater(
|
|
81
|
+
i0.ɵɵrepeater(ctx_r0.getStepTypes());
|
|
82
82
|
} }
|
|
83
83
|
/**
|
|
84
84
|
* AgentExecutionMonitor Component
|
|
@@ -973,7 +973,6 @@ export class AgentExecutionMonitorComponent {
|
|
|
973
973
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.executionTreeContainer = _t.first);
|
|
974
974
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.executionNodesContainer = _t.first);
|
|
975
975
|
} }, inputs: { mode: "mode", agentRun: "agentRun", liveSteps: "liveSteps", autoExpand: "autoExpand", runId: "runId", runType: "runType" }, outputs: { viewRunClick: "viewRunClick" }, standalone: false, features: [i0.ɵɵNgOnChangesFeature], decls: 39, vars: 16, consts: [["executionTreeContainer", ""], ["executionNodesContainer", ""], [1, "execution-monitor"], [1, "monitor-header"], [1, "header-title"], [1, "fa-solid", "fa-diagram-project"], [1, "live-indicator"], [1, "current-status"], [1, "view-run-btn"], [1, "execution-tree", 3, "scroll", "click"], [1, "nodes-container"], ["Icon", "fa-solid fa-hourglass-start", "Title", "Waiting for execution to begin...", "Size", "compact"], [1, "monitor-footer"], [1, "stats-grid"], [1, "stat-item"], [1, "stat-label"], [1, "stat-value"], [1, "failed-count"], [1, "step-types"], [1, "pulse"], [1, "status-label"], [1, "step-name"], [1, "view-run-btn", 3, "click"], [1, "fa-solid", "fa-external-link-alt"], [1, "type-badge"]], template: function AgentExecutionMonitorComponent_Template(rf, ctx) { if (rf & 1) {
|
|
976
|
-
const _r1 = i0.ɵɵgetCurrentView();
|
|
977
976
|
i0.ɵɵelementStart(0, "div", 2)(1, "div", 3)(2, "div", 4);
|
|
978
977
|
i0.ɵɵelement(3, "i", 5);
|
|
979
978
|
i0.ɵɵelementStart(4, "span");
|
|
@@ -985,7 +984,7 @@ export class AgentExecutionMonitorComponent {
|
|
|
985
984
|
i0.ɵɵconditionalCreate(8, AgentExecutionMonitorComponent_Conditional_8_Template, 3, 1, "button", 8);
|
|
986
985
|
i0.ɵɵelementEnd();
|
|
987
986
|
i0.ɵɵelementStart(9, "div", 9, 0);
|
|
988
|
-
i0.ɵɵlistener("scroll", function AgentExecutionMonitorComponent_Template_div_scroll_9_listener($event) {
|
|
987
|
+
i0.ɵɵlistener("scroll", function AgentExecutionMonitorComponent_Template_div_scroll_9_listener($event) { return ctx.onScroll($event); })("click", function AgentExecutionMonitorComponent_Template_div_click_9_listener() { return ctx.onUserInteraction(); });
|
|
989
988
|
i0.ɵɵelement(11, "div", 10, 1);
|
|
990
989
|
i0.ɵɵconditionalCreate(13, AgentExecutionMonitorComponent_Conditional_13_Template, 1, 0, "mj-empty-state", 11);
|
|
991
990
|
i0.ɵɵelementEnd();
|
|
@@ -1044,7 +1043,7 @@ export class AgentExecutionMonitorComponent {
|
|
|
1044
1043
|
i0.ɵɵconditional(ctx.stats.totalDuration ? 37 : -1);
|
|
1045
1044
|
i0.ɵɵadvance();
|
|
1046
1045
|
i0.ɵɵconditional(ctx.getStepTypes().length > 0 ? 38 : -1);
|
|
1047
|
-
} }, dependencies: [i1.MJEmptyStateComponent], styles: ["[_nghost-%COMP%] {\n display: flex;\n flex-direction: column;\n height: 100%;\n overflow: hidden;\n }\n \n .execution-monitor[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n flex: 1;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n overflow: hidden;\n }\n\n \n
|
|
1046
|
+
} }, dependencies: [i1.MJEmptyStateComponent], styles: ["[_nghost-%COMP%] {\n display: flex;\n flex-direction: column;\n height: 100%;\n overflow: hidden;\n }\n \n .execution-monitor[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n flex: 1;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n overflow: hidden;\n }\n\n \n .monitor-header[_ngcontent-%COMP%] {\n padding: 16px;\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .header-title[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n font-size: 16px;\n font-weight: 600;\n color: var(--mj-text-primary);\n margin-bottom: 8px;\n }\n\n .header-title[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n color: var(--mj-brand-primary);\n }\n\n .live-indicator[_ngcontent-%COMP%] {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 8px;\n background: var(--mj-status-error);\n color: var(--mj-text-inverse);\n border-radius: 4px;\n font-size: 11px;\n font-weight: 600;\n letter-spacing: 0.5px;\n }\n\n .pulse[_ngcontent-%COMP%] {\n display: inline-block;\n width: 8px;\n height: 8px;\n background: white;\n border-radius: 50%;\n animation: _ngcontent-%COMP%_pulse 2s infinite;\n }\n\n @keyframes _ngcontent-%COMP%_pulse {\n 0% { opacity: 1; transform: scale(1); }\n 50% { opacity: 0.5; transform: scale(0.8); }\n 100% { opacity: 1; transform: scale(1); }\n }\n\n .current-status[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n font-size: 13px;\n color: var(--mj-text-secondary);\n }\n\n .status-label[_ngcontent-%COMP%] {\n font-weight: 500;\n }\n\n .agent-path[_ngcontent-%COMP%] {\n color: var(--mj-text-muted);\n }\n\n .step-name[_ngcontent-%COMP%] {\n color: var(--mj-text-primary);\n font-weight: 500;\n }\n\n \n .execution-tree[_ngcontent-%COMP%] {\n flex: 1;\n overflow-y: auto;\n overflow-x: auto;\n padding: 16px;\n min-height: 0;\n }\n \n .nodes-container[_ngcontent-%COMP%] {\n \n }\n\n .execution-tree[_ngcontent-%COMP%] mj-empty-state[_ngcontent-%COMP%] {\n height: 100%;\n }\n\n \n .tree-node[_ngcontent-%COMP%] {\n margin-bottom: 4px;\n }\n\n \n .monitor-footer[_ngcontent-%COMP%] {\n padding: 16px;\n background: var(--mj-bg-surface-card);\n border-top: 1px solid var(--mj-border-default);\n }\n\n .stats-grid[_ngcontent-%COMP%] {\n display: grid;\n grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));\n gap: 16px;\n margin-bottom: 12px;\n }\n\n .stat-item[_ngcontent-%COMP%] {\n text-align: center;\n }\n\n .stat-label[_ngcontent-%COMP%] {\n display: block;\n font-size: 11px;\n color: var(--mj-text-secondary);\n text-transform: uppercase;\n letter-spacing: 0.5px;\n margin-bottom: 4px;\n }\n\n .stat-value[_ngcontent-%COMP%] {\n display: block;\n font-size: 16px;\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n\n .failed-count[_ngcontent-%COMP%] {\n color: var(--mj-status-error);\n font-size: 12px;\n font-weight: normal;\n }\n\n .step-types[_ngcontent-%COMP%] {\n display: flex;\n flex-wrap: wrap;\n gap: 8px;\n justify-content: center;\n }\n\n .type-badge[_ngcontent-%COMP%] {\n display: inline-block;\n padding: 4px 8px;\n background: color-mix(in srgb, var(--mj-brand-primary) 12%, var(--mj-bg-surface));\n color: var(--mj-brand-primary);\n border-radius: 4px;\n font-size: 12px;\n font-weight: 500;\n }\n\n \n .view-run-btn[_ngcontent-%COMP%] {\n background: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n border: none;\n padding: 6px 12px;\n border-radius: 4px;\n font-size: 13px;\n font-weight: 500;\n cursor: pointer;\n display: inline-flex;\n align-items: center;\n gap: 6px;\n transition: all 0.2s ease;\n margin-left: auto;\n }\n\n .view-run-btn[_ngcontent-%COMP%]:hover {\n background: var(--mj-brand-primary-hover);\n transform: translateY(-1px);\n box-shadow: 0 2px 4px rgba(0,0,0,0.2);\n }\n \n .view-run-btn[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n font-size: 12px;\n }\n\n \n @media (max-width: 768px) {\n .monitor-header[_ngcontent-%COMP%] {\n padding: 12px;\n }\n\n .execution-tree[_ngcontent-%COMP%] {\n padding: 12px;\n }\n }"], changeDetection: 0 }); }
|
|
1048
1047
|
}
|
|
1049
1048
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AgentExecutionMonitorComponent, [{
|
|
1050
1049
|
type: Component,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-execution-monitor.component.js","sourceRoot":"","sources":["../../src/lib/agent-execution-monitor.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAuC,SAAS,EAAgD,uBAAuB,EAAE,gBAAgB,EAAgB,MAAM,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC9N,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAgB,MAAM,MAAM,CAAC;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F,AADJ,gCAAuB,gBACM;YAAA,qBAAI;YAAA,iBAAO;YACpC,iCAAyB;YAAA,aAAkC;YAC/D,AAD+D,iBAAO,EAChE;YACN,mGAA2B;YAM/B,iBAAM;YACN,mGAAiC;YAUzC,AADI,iBAAM,EACJ;;YArFyB,gDAAmC;YAMtD,eAKC;YALD,8CAKC;YAEL,cAKC;YALD,iEAKC;YACD,cAKC;YALD,iGAKC;YAMA,cAAkC;YAAlC,+CAAkC;YAMnC,eAKC;YALD,uEAKC;YASW,eACA;YADA,oFACA;YAAA,cAEC;YAFD,qDAEC;YAKoB,eAAwB;YAAxB,4CAAwB;YAIxB,eAAwC;YAAxC,4DAAwC;YAIxC,eAAkC;YAAlC,0DAAkC;YAE/D,cAKC;YALD,mDAKC;YAEL,cAQC;YARD,yDAQC;;;iFAkNJ,8BAA8B;cA1S1C,SAAS;6BACI,KAAK,YACL,4BAA4B,mBACrB,uBAAuB,CAAC,MAAM,YACrC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAuFT;;kBAgNA,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBAEL,MAAM;;kBAEN,SAAS;mBAAC,wBAAwB;;kBAClC,SAAS;mBAAC,yBAAyB,EAAE,EAAE,IAAI,EAAE,gBAAgB,EAAE;;kFAXvD,8BAA8B","sourcesContent":["import { Component, Input, OnChanges, SimpleChanges, OnDestroy, ViewChild, ElementRef, AfterViewInit, ChangeDetectorRef, ChangeDetectionStrategy, ViewContainerRef, ComponentRef, Output, EventEmitter } from '@angular/core';\nimport { Subject, interval, Subscription } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\nimport { ExecutionNodeComponent } from './agent-execution-node.component';\nimport { MJAIAgentRunEntityExtended, MJAIAgentRunStepEntityExtended } from '@memberjunction/ai-core-plus';\nimport { UUIDsEqual } from '@memberjunction/global';\n\n/**\n * Progress message with display mode\n */\nexport interface ProgressMessage {\n id: string;\n message: string;\n timestamp: Date;\n displayMode: 'live' | 'historical' | 'both';\n metadata?: Record<string, unknown>;\n}\n\n/**\n * Mode for the execution monitor component\n */\nexport type ExecutionMonitorMode = 'live' | 'historical';\n\n/**\n * Execution statistics for display\n */\nexport interface ExecutionStats {\n totalSteps: number;\n completedSteps: number;\n failedSteps: number;\n totalTokens: number;\n totalCost: number;\n stepsByType: Record<string, number>;\n totalDuration?: number;\n totalPrompts: number;\n}\n\n/**\n * AgentExecutionMonitor Component\n * \n * A reusable component for visualizing AI agent execution flow in real-time or historically.\n * Displays a hierarchical tree of execution steps with status, timing, and preview information.\n * \n * Features:\n * - Real-time updates for live executions\n * - Historical playback for completed executions\n * - Collapsible tree structure\n * - Step status indicators with animations\n * - Execution statistics\n * - Token usage and cost tracking\n * - Error display\n * - Input/output preview\n */\n@Component({\n standalone: false,\n selector: 'mj-agent-execution-monitor',\n changeDetection: ChangeDetectionStrategy.OnPush,\n template: `\n <div class=\"execution-monitor\" [class.live-mode]=\"mode === 'live'\">\n <!-- Header -->\n <div class=\"monitor-header\">\n <div class=\"header-title\">\n <i class=\"fa-solid fa-diagram-project\"></i>\n <span>Execution Monitor</span>\n @if (mode === 'live') {\n <span class=\"live-indicator\">\n <span class=\"pulse\"></span>\n LIVE\n </span>\n }\n </div>\n @if (currentStep && mode === 'live') {\n <div class=\"current-status\">\n <span class=\"status-label\">Current:</span>\n <span class=\"step-name\">{{ currentStep.StepName }}</span>\n </div>\n }\n @if (mode === 'historical' && agentRun && isExecutionComplete()) {\n <button class=\"view-run-btn\" (click)=\"onViewRunClick()\">\n <i class=\"fa-solid fa-external-link-alt\"></i>\n View {{ runType === 'agent' ? 'Agent' : 'Prompt' }} Run\n </button>\n }\n </div>\n\n <!-- Execution Tree -->\n <div class=\"execution-tree\" \n #executionTreeContainer\n [class.has-content]=\"hasContent()\"\n (scroll)=\"onScroll($event)\"\n (click)=\"onUserInteraction()\">\n <!-- Always render the container, but show empty state when no data -->\n <div #executionNodesContainer class=\"nodes-container\">\n </div>\n @if (!agentRun && liveSteps.length === 0) {\n <mj-empty-state\n Icon=\"fa-solid fa-hourglass-start\"\n Title=\"Waiting for execution to begin...\"\n Size=\"compact\" />\n }\n </div>\n\n <!-- Statistics Footer -->\n <div class=\"monitor-footer\">\n <div class=\"stats-grid\">\n <div class=\"stat-item\">\n <span class=\"stat-label\">Steps</span>\n <span class=\"stat-value\">\n {{ stats.completedSteps }}/{{ stats.totalSteps }}\n @if (stats.failedSteps > 0) {\n <span class=\"failed-count\">({{ stats.failedSteps }} failed)</span>\n }\n </span>\n </div>\n <div class=\"stat-item\">\n <span class=\"stat-label\">Prompts</span>\n <span class=\"stat-value\">{{ stats.totalPrompts }}</span>\n </div>\n <div class=\"stat-item\">\n <span class=\"stat-label\">Tokens</span>\n <span class=\"stat-value\">{{ stats.totalTokens.toLocaleString() }}</span>\n </div>\n <div class=\"stat-item\">\n <span class=\"stat-label\">Cost</span>\n <span class=\"stat-value\">\\${{ stats.totalCost.toFixed(4) }}</span>\n </div>\n @if (stats.totalDuration) {\n <div class=\"stat-item\">\n <span class=\"stat-label\">Duration</span>\n <span class=\"stat-value\">{{ formatDuration(stats.totalDuration) }}</span>\n </div>\n }\n </div>\n @if (getStepTypes().length > 0) {\n <div class=\"step-types\">\n @for (type of getStepTypes(); track type) {\n <span class=\"type-badge\">\n {{ stats.stepsByType[type] }} {{ pluralizeStepType(type, stats.stepsByType[type]) }}\n </span>\n }\n </div>\n }\n </div>\n </div>\n `,\n styles: [`\n :host {\n display: flex;\n flex-direction: column;\n height: 100%;\n overflow: hidden;\n }\n \n .execution-monitor {\n display: flex;\n flex-direction: column;\n flex: 1;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n overflow: hidden;\n }\n\n /* Header */\n .monitor-header {\n padding: 16px;\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .header-title {\n display: flex;\n align-items: center;\n gap: 8px;\n font-size: 16px;\n font-weight: 600;\n color: var(--mj-text-primary);\n margin-bottom: 8px;\n }\n\n .header-title i {\n color: var(--mj-brand-primary);\n }\n\n .live-indicator {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 8px;\n background: var(--mj-status-error);\n color: var(--mj-text-inverse);\n border-radius: 4px;\n font-size: 11px;\n font-weight: 600;\n letter-spacing: 0.5px;\n }\n\n .pulse {\n display: inline-block;\n width: 8px;\n height: 8px;\n background: white;\n border-radius: 50%;\n animation: pulse 2s infinite;\n }\n\n @keyframes pulse {\n 0% { opacity: 1; transform: scale(1); }\n 50% { opacity: 0.5; transform: scale(0.8); }\n 100% { opacity: 1; transform: scale(1); }\n }\n\n .current-status {\n display: flex;\n align-items: center;\n gap: 8px;\n font-size: 13px;\n color: var(--mj-text-secondary);\n }\n\n .status-label {\n font-weight: 500;\n }\n\n .agent-path {\n color: var(--mj-text-muted);\n }\n\n .step-name {\n color: var(--mj-text-primary);\n font-weight: 500;\n }\n\n /* Execution Tree */\n .execution-tree {\n flex: 1;\n overflow-y: auto;\n overflow-x: auto;\n padding: 16px;\n min-height: 0;\n }\n \n .nodes-container {\n /* No extra padding needed, indentation handled by node margins */\n }\n\n .execution-tree mj-empty-state {\n height: 100%;\n }\n\n /* Tree Nodes - These styles are for reference only, actual rendering is done by ExecutionNodeComponent */\n .tree-node {\n margin-bottom: 4px;\n }\n\n /* Footer */\n .monitor-footer {\n padding: 16px;\n background: var(--mj-bg-surface-card);\n border-top: 1px solid var(--mj-border-default);\n }\n\n .stats-grid {\n display: grid;\n grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));\n gap: 16px;\n margin-bottom: 12px;\n }\n\n .stat-item {\n text-align: center;\n }\n\n .stat-label {\n display: block;\n font-size: 11px;\n color: var(--mj-text-secondary);\n text-transform: uppercase;\n letter-spacing: 0.5px;\n margin-bottom: 4px;\n }\n\n .stat-value {\n display: block;\n font-size: 16px;\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n\n .failed-count {\n color: var(--mj-status-error);\n font-size: 12px;\n font-weight: normal;\n }\n\n .step-types {\n display: flex;\n flex-wrap: wrap;\n gap: 8px;\n justify-content: center;\n }\n\n .type-badge {\n display: inline-block;\n padding: 4px 8px;\n background: color-mix(in srgb, var(--mj-brand-primary) 12%, var(--mj-bg-surface));\n color: var(--mj-brand-primary);\n border-radius: 4px;\n font-size: 12px;\n font-weight: 500;\n }\n\n /* View Run Button */\n .view-run-btn {\n background: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n border: none;\n padding: 6px 12px;\n border-radius: 4px;\n font-size: 13px;\n font-weight: 500;\n cursor: pointer;\n display: inline-flex;\n align-items: center;\n gap: 6px;\n transition: all 0.2s ease;\n margin-left: auto;\n }\n\n .view-run-btn:hover {\n background: var(--mj-brand-primary-hover);\n transform: translateY(-1px);\n box-shadow: 0 2px 4px rgba(0,0,0,0.2);\n }\n \n .view-run-btn i {\n font-size: 12px;\n }\n\n /* Responsive */\n @media (max-width: 768px) {\n .monitor-header {\n padding: 12px;\n }\n\n .execution-tree {\n padding: 12px;\n }\n }\n `]\n})\nexport class AgentExecutionMonitorComponent implements OnChanges, OnDestroy, AfterViewInit {\n @Input() mode: ExecutionMonitorMode = 'historical';\n @Input() agentRun: MJAIAgentRunEntityExtended | null = null; // For historical mode\n @Input() liveSteps: MJAIAgentRunStepEntityExtended[] = []; // For live mode streaming\n @Input() autoExpand: boolean = true; // Auto-expand nodes in live mode\n @Input() runId: string | null = null; // ID of the run (agent or prompt)\n @Input() runType: 'agent' | 'prompt' = 'agent'; // Type of run\n \n @Output() viewRunClick = new EventEmitter<{ runId: string; runType: 'agent' | 'prompt' }>();\n \n @ViewChild('executionTreeContainer') executionTreeContainer!: ElementRef<HTMLDivElement>;\n @ViewChild('executionNodesContainer', { read: ViewContainerRef }) executionNodesContainer!: ViewContainerRef;\n \n // Store the currently rendered steps for UI state management\n currentStep: MJAIAgentRunStepEntityExtended | null = null;\n \n // Track component references for dynamic components\n private nodeComponentMap = new Map<string, ComponentRef<ExecutionNodeComponent>>();\n \n // UI state management - track expanded states separately from entities\n private expandedStates = new Map<string, boolean>();\n private detailsExpandedStates = new Map<string, boolean>();\n stats: ExecutionStats = {\n totalSteps: 0,\n completedSteps: 0,\n failedSteps: 0,\n totalTokens: 0,\n totalCost: 0,\n stepsByType: {},\n totalPrompts: 0\n };\n \n // User interaction tracking\n private userHasInteracted = false;\n private userHasScrolled = false;\n private isAutoScrolling = false;\n private lastScrollPosition = 0;\n private scrollThreshold = 50; // pixels from bottom to consider \"at bottom\"\n \n // View initialization flag\n private viewInitialized = false;\n \n // Track processed step IDs to avoid duplication\n private processedStepIds = new Set<string>();\n \n // Track which nodes were added in the current update\n private newlyAddedNodeIds = new Set<string>();\n \n // Temporary storage for parsed metadata\n private lastParsedAgentData: any = null;\n private lastParsedActionData: any = null;\n \n private destroy$ = new Subject<void>();\n private updateSubscription?: Subscription;\n \n constructor(private cdr: ChangeDetectorRef) {}\n \n ngOnChanges(changes: SimpleChanges): void {\n console.log('🔄 Execution Monitor ngOnChanges:', {\n agentRunChanged: !!changes['agentRun'],\n liveStepsChanged: !!changes['liveSteps'],\n modeChanged: !!changes['mode'],\n hasAgentRun: !!this.agentRun,\n liveStepsCount: this.liveSteps?.length || 0\n });\n \n // Handle agent run changes (historical mode)\n if (changes['agentRun'] && this.mode === 'historical') {\n const oldRun = changes['agentRun'].previousValue;\n const newRun = changes['agentRun'].currentValue;\n \n console.log('📊 Agent run changed:', {\n oldRunExists: !!oldRun,\n newRunExists: !!newRun,\n oldRunId: oldRun?.ID,\n newRunId: newRun?.ID,\n stepsCount: newRun?.Steps?.length\n });\n \n // Only clear if it's actually a different execution (different ID)\n const isDifferentExecution = (!oldRun && newRun) || \n (oldRun && newRun && !UUIDsEqual(oldRun.ID, newRun.ID)) ||\n (oldRun && !newRun);\n \n if (isDifferentExecution) {\n console.log('🗑️ Clearing for different agent run');\n this.processedStepIds.clear();\n this.newlyAddedNodeIds.clear();\n this.expandedStates.clear();\n this.detailsExpandedStates.clear();\n this.clearNodeComponents();\n this.currentStep = null;\n }\n \n // Always process the agent run data (will handle updates to existing run)\n if (newRun) {\n this.processAgentRun();\n }\n }\n \n // Handle live steps changes (live mode)\n if (changes['liveSteps'] && this.mode === 'live') {\n const oldSteps = changes['liveSteps'].previousValue;\n const newSteps = changes['liveSteps'].currentValue;\n \n console.log('📊 Live steps changed:', {\n oldCount: oldSteps?.length || 0,\n newCount: newSteps?.length || 0\n });\n \n // Process live steps\n this.processLiveSteps();\n }\n \n // Handle mode changes\n if (changes['mode'] && !changes['mode'].firstChange) {\n const previousMode = changes['mode'].previousValue;\n const currentMode = changes['mode'].currentValue;\n \n console.log('🔄 Mode changed:', { previousMode, currentMode });\n \n // Clear everything when switching modes\n this.processedStepIds.clear();\n this.newlyAddedNodeIds.clear();\n this.expandedStates.clear();\n this.detailsExpandedStates.clear();\n this.clearNodeComponents();\n this.currentStep = null;\n \n // Stop live updates when switching away from live mode\n if (previousMode === 'live' && this.updateSubscription) {\n this.updateSubscription.unsubscribe();\n this.updateSubscription = undefined;\n }\n \n // Process data for the new mode\n if (currentMode === 'historical' && this.agentRun) {\n this.processAgentRun();\n } else if (currentMode === 'live') {\n this.setupLiveUpdates();\n }\n }\n }\n \n ngAfterViewInit(): void {\n this.viewInitialized = true;\n \n console.log('🎯 View initialized, checking for pending data:', {\n hasAgentRun: !!this.agentRun,\n hasLiveSteps: this.liveSteps?.length > 0,\n hasContainer: !!this.executionNodesContainer\n });\n \n // Initial setup for scroll behavior\n if (this.mode === 'live') {\n this.checkIfUserAtBottom();\n }\n \n // If we have data waiting to be rendered, render it now\n if (this.mode === 'historical' && this.agentRun && this.nodeComponentMap.size === 0) {\n console.log('⚡ Processing agent run after view init');\n this.processAgentRun();\n } else if (this.mode === 'live' && this.liveSteps?.length > 0) {\n console.log('⚡ Processing live steps after view init');\n this.processLiveSteps();\n }\n }\n \n ngOnDestroy(): void {\n this.destroy$.next();\n this.destroy$.complete();\n if (this.updateSubscription) {\n this.updateSubscription.unsubscribe();\n this.updateSubscription = undefined;\n }\n this.clearNodeComponents();\n }\n \n /**\n * Clear all dynamically created components\n */\n private clearNodeComponents(): void {\n this.nodeComponentMap.forEach(ref => ref.destroy());\n this.nodeComponentMap.clear();\n if (this.executionNodesContainer) {\n this.executionNodesContainer.clear();\n }\n }\n \n /**\n * Process agent run for historical mode\n */\n private processAgentRun(): void {\n console.log('⚙️ Processing agent run:', {\n hasAgentRun: !!this.agentRun,\n stepsCount: this.agentRun?.Steps?.length || 0,\n viewInitialized: this.viewInitialized,\n hasContainer: !!this.executionNodesContainer\n });\n \n if (!this.agentRun || !this.viewInitialized || !this.executionNodesContainer) {\n console.warn('⚠️ Cannot process agent run:', {\n agentRun: !this.agentRun ? 'missing' : 'present',\n viewInitialized: this.viewInitialized ? 'yes' : 'no',\n container: !this.executionNodesContainer ? 'missing' : 'present'\n });\n return;\n }\n \n // Clear existing components\n this.clearNodeComponents();\n \n // Render the agent run steps\n if (this.agentRun.Steps && this.agentRun.Steps.length > 0) {\n console.log('🎨 Rendering', this.agentRun.Steps.length, 'steps');\n this.renderSteps(this.agentRun.Steps, 0, []);\n console.log('✅ Finished rendering, container now has', this.executionNodesContainer.length, 'components');\n } else {\n console.warn('⚠️ No steps to render');\n }\n \n // Calculate statistics\n this.calculateStats();\n \n // Trigger change detection after rendering all components\n this.cdr.detectChanges();\n }\n \n /**\n * Process live steps for live mode\n */\n private processLiveSteps(): void {\n console.log('⚙️ Processing live steps:', {\n stepsCount: this.liveSteps?.length || 0,\n viewInitialized: this.viewInitialized,\n hasContainer: !!this.executionNodesContainer\n });\n \n if (!this.liveSteps || !this.viewInitialized || !this.executionNodesContainer) {\n return;\n }\n \n // Append new steps without clearing existing ones\n this.appendNewLiveSteps(this.liveSteps);\n \n // Trigger change detection after appending live steps\n this.cdr.detectChanges();\n \n // Set up live update monitoring if not already set up\n if (!this.updateSubscription) {\n this.setupLiveUpdates();\n }\n }\n \n /**\n * Render steps recursively with proper hierarchy\n */\n private renderSteps(steps: MJAIAgentRunStepEntityExtended[], depth: number, agentPath: string[]): void {\n console.log('🎨 Rendering steps:', {\n count: steps.length,\n depth,\n agentPath\n });\n \n // Sort steps by StepNumber to ensure proper ordering\n const sortedSteps = [...steps].sort((a, b) => (a.StepNumber || 0) - (b.StepNumber || 0));\n \n for (const step of sortedSteps) {\n // Skip if already processed in live mode\n if (this.processedStepIds.has(step.ID)) {\n continue;\n }\n \n // Create component for this step\n this.createStepComponent(step, depth, agentPath);\n \n // Mark as processed\n this.processedStepIds.add(step.ID);\n \n // Handle sub-agent recursion\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps) {\n const subAgentPath = [...agentPath, step.SubAgentRun.Agent || 'Sub-Agent'];\n this.renderSteps(step.SubAgentRun.Steps, depth + 1, subAgentPath);\n }\n }\n }\n \n /**\n * Create a component for a step\n */\n private createStepComponent(\n step: MJAIAgentRunStepEntityExtended, \n depth: number, \n agentPath: string[]\n ): ComponentRef<ExecutionNodeComponent> {\n // Ensure container exists\n if (!this.executionNodesContainer) {\n console.error('❌ executionNodesContainer not available');\n throw new Error('executionNodesContainer ViewContainerRef not initialized');\n }\n \n const componentRef = this.executionNodesContainer.createComponent(ExecutionNodeComponent);\n const instance = componentRef.instance;\n \n console.log('🔨 Creating component for step:', {\n stepId: step.ID,\n stepName: step.StepName,\n depth,\n containerLength: this.executionNodesContainer.length,\n hostElement: componentRef.location.nativeElement\n });\n \n // Pass the step data with UI state information\n instance.step = step;\n instance.depth = depth;\n instance.agentPath = agentPath;\n instance.expanded = this.expandedStates.get(step.ID) || false;\n instance.detailsExpanded = this.detailsExpandedStates.get(step.ID) || false;\n \n // Subscribe to outputs\n instance.toggleNode.subscribe(() => this.toggleStepExpansion(step));\n instance.toggleDetails.subscribe(() => this.toggleStepDetails(step));\n instance.userInteracted.subscribe(() => this.onUserInteraction());\n \n // Store reference\n this.nodeComponentMap.set(step.ID, componentRef);\n \n // Log the component state after setup\n console.log('✅ Component created and configured:', {\n stepId: step.ID,\n hasData: !!instance.step,\n isAttached: componentRef.hostView.destroyed === false\n });\n \n return componentRef;\n }\n \n /**\n * Toggle step expansion\n */\n private toggleStepExpansion(step: MJAIAgentRunStepEntityExtended): void {\n const currentState = this.expandedStates.get(step.ID) || false;\n this.expandedStates.set(step.ID, !currentState);\n this.userHasInteracted = true;\n \n // Update the component\n const componentRef = this.nodeComponentMap.get(step.ID);\n if (componentRef) {\n componentRef.instance.expanded = !currentState;\n componentRef.changeDetectorRef.detectChanges();\n }\n \n this.cdr.markForCheck();\n }\n \n /**\n * Toggle step details expansion\n */\n private toggleStepDetails(step: MJAIAgentRunStepEntityExtended): void {\n const currentState = this.detailsExpandedStates.get(step.ID) || false;\n this.detailsExpandedStates.set(step.ID, !currentState);\n \n // Update the component\n const componentRef = this.nodeComponentMap.get(step.ID);\n if (componentRef) {\n componentRef.instance.detailsExpanded = !currentState;\n componentRef.changeDetectorRef.detectChanges();\n }\n }\n \n \n /**\n * Get step type CSS class for styling\n */\n private getStepTypeClass(stepType: string): string {\n const typeMap: Record<string, string> = {\n 'Validation': 'validation',\n 'Prompt': 'prompt',\n 'Actions': 'action',\n 'Sub-Agent': 'sub-agent',\n 'Decision': 'decision',\n 'Chat': 'chat'\n };\n return typeMap[stepType] || 'prompt';\n }\n \n /**\n * Get status CSS class for styling\n */\n private getStatusClass(status: string): string {\n const statusMap: Record<string, string> = {\n 'Pending': 'pending',\n 'Running': 'running',\n 'Completed': 'completed',\n 'Failed': 'failed',\n 'Cancelled': 'failed',\n 'Paused': 'pending'\n };\n return statusMap[status] || 'pending';\n }\n \n /**\n * Helper function to safely convert a value to a preview string\n */\n private valueToPreviewString(value: any): string {\n if (value === null || value === undefined) {\n return '';\n }\n if (typeof value === 'object') {\n return JSON.stringify(value, null, 2);\n }\n return String(value);\n }\n\n /**\n * Create a preview string from data\n */\n private createPreview(data: any): string | undefined {\n if (!data) return undefined;\n \n try {\n const parsed = typeof data === 'string' ? JSON.parse(data) : data;\n \n // Extract meaningful preview and store metadata\n if (parsed.promptName) return `Prompt: ${parsed.promptName}`;\n if (parsed.actionName) {\n // Store action metadata if available\n this.lastParsedActionData = {\n actionName: parsed.actionName,\n actionId: parsed.actionId,\n actionIconClass: parsed.actionIconClass\n };\n return `Action: ${parsed.actionName}`;\n }\n if (parsed.subAgentName) {\n // Store agent metadata if available\n this.lastParsedAgentData = {\n agentName: parsed.subAgentName,\n agentId: parsed.subAgentId || parsed.agentId,\n agentIconClass: parsed.subAgentIconClass || parsed.agentIconClass,\n agentLogoURL: parsed.subAgentLogoURL || parsed.agentLogoURL\n };\n return `Sub-agent: ${parsed.subAgentName}`;\n }\n if (parsed.message) return this.valueToPreviewString(parsed.message);\n if (parsed.userMessage) return this.valueToPreviewString(parsed.userMessage);\n \n // Show action results clearly\n if (parsed.actionResult) {\n const result = parsed.actionResult;\n let preview = '';\n if (result.success !== undefined) {\n preview += `Success: ${result.success}\\n`;\n }\n if (result.resultCode) {\n preview += `Result Code: ${result.resultCode}\\n`;\n }\n if (result.message) {\n preview += `Message: ${this.valueToPreviewString(result.message)}\\n`;\n }\n if (result.result) {\n preview += `Result: ${typeof result.result === 'object' ? JSON.stringify(result.result, null, 2) : result.result}`;\n }\n return preview.trim();\n }\n \n // Legacy action result format\n if (parsed.result) {\n return this.valueToPreviewString(parsed.result);\n }\n \n // Show prompt results\n if (parsed.promptResult) {\n const result = parsed.promptResult;\n let preview = '';\n if (result.success !== undefined) {\n preview += `Success: ${result.success}\\n`;\n }\n if (result.content) {\n preview += `Content: ${this.valueToPreviewString(result.content)}`;\n }\n return preview;\n }\n \n // Fallback to stringified preview\n const str = JSON.stringify(parsed, null, 2);\n return str.length > 500 ? str.substring(0, 500) + '...' : str;\n } catch {\n return typeof data === 'string' ? data : JSON.stringify(data);\n }\n }\n \n /**\n * Extract token count from output data\n */\n private extractTokens(data: any): number | undefined {\n if (!data) return undefined;\n try {\n const parsed = typeof data === 'string' ? JSON.parse(data) : data;\n return parsed.promptResult?.tokensUsed || parsed.tokensUsed;\n } catch {\n return undefined;\n }\n }\n \n /**\n * Extract cost from output data\n */\n private extractCost(data: any): number | undefined {\n if (!data) return undefined;\n try {\n const parsed = typeof data === 'string' ? JSON.parse(data) : data;\n return parsed.promptResult?.totalCost || parsed.totalCost;\n } catch {\n return undefined;\n }\n }\n \n /**\n * Calculate duration from timestamps\n */\n private calculateDuration(start: any, end: any): number | undefined {\n if (!start || !end) return undefined;\n const startTime = new Date(start).getTime();\n const endTime = new Date(end).getTime();\n return endTime - startTime;\n }\n \n /**\n * Set up live updates for real-time execution\n */\n private setupLiveUpdates(): void {\n console.log('⚡ Setting up live updates');\n \n // Process initial live steps if any\n if (this.liveSteps && this.liveSteps.length > 0) {\n this.appendNewLiveSteps(this.liveSteps);\n }\n \n // Set up interval to check for updates (if not already set up)\n if (this.mode === 'live' && !this.updateSubscription) {\n this.updateSubscription = interval(500)\n .pipe(takeUntil(this.destroy$))\n .subscribe(() => {\n // Update current step indicator\n this.updateCurrentStep();\n \n // Recalculate stats periodically\n this.calculateStats();\n });\n }\n }\n \n /**\n * Update current step indicator\n */\n private updateCurrentStep(): void {\n // Find the first running step from all rendered components\n let runningStep: MJAIAgentRunStepEntityExtended | null = null;\n \n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step && step.Status === 'Running' && !runningStep) {\n runningStep = step;\n }\n });\n \n this.currentStep = runningStep;\n this.cdr.markForCheck();\n }\n \n /**\n * Mark previously new nodes as completed\n */\n private markPreviouslyNewNodesAsComplete(): void {\n // Mark ALL running steps as completed (not just previously new ones)\n // This ensures only the latest step shows as running\n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.Status === 'Running') {\n // Create a copy with updated status\n const updatedStep = Object.assign({}, step, { Status: 'Completed' });\n componentRef.instance.step = updatedStep;\n componentRef.changeDetectorRef.detectChanges();\n }\n });\n }\n \n /**\n * Ensure only the last step in the execution order shows as running\n */\n private ensureOnlyLastStepIsRunning(): void {\n // Find the last step by step number\n let lastRunningStep: { stepId: string; stepNumber: number; componentRef: ComponentRef<ExecutionNodeComponent> } | null = null;\n \n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.Status === 'Running') {\n const stepNumber = step.StepNumber || 0;\n if (!lastRunningStep || stepNumber > lastRunningStep.stepNumber) {\n lastRunningStep = { stepId, stepNumber, componentRef };\n }\n }\n });\n \n // Set override display status for all running steps\n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.Status === 'Running') {\n // Override display to show as completed, except for the last one\n if (lastRunningStep && stepId === lastRunningStep.stepId) {\n componentRef.instance.overrideDisplayStatus = 'Running';\n } else {\n componentRef.instance.overrideDisplayStatus = 'Completed';\n }\n componentRef.changeDetectorRef.detectChanges();\n }\n });\n }\n \n \n /**\n * Calculate execution statistics\n */\n private calculateStats(): void {\n this.stats = {\n totalSteps: 0,\n completedSteps: 0,\n failedSteps: 0,\n totalTokens: 0,\n totalCost: 0,\n stepsByType: {},\n totalDuration: 0,\n totalPrompts: 0\n };\n \n // Use token data from agent run if available\n if (this.agentRun) {\n this.stats.totalTokens = this.agentRun.TotalTokensUsed || 0;\n this.stats.totalCost = this.agentRun.TotalCost || 0;\n \n // Calculate duration\n if (this.agentRun.StartedAt && this.agentRun.CompletedAt) {\n this.stats.totalDuration = new Date(this.agentRun.CompletedAt).getTime() - \n new Date(this.agentRun.StartedAt).getTime();\n }\n \n // Count steps recursively\n if (this.agentRun.Steps) {\n this.countSteps(this.agentRun.Steps);\n }\n }\n \n console.log('📈 Stats calculated:', {\n totalSteps: this.stats.totalSteps,\n totalTokens: this.stats.totalTokens,\n totalCost: this.stats.totalCost\n });\n }\n \n /**\n * Count steps recursively\n */\n private countSteps(steps: MJAIAgentRunStepEntityExtended[]): void {\n for (const step of steps) {\n this.stats.totalSteps++;\n \n // Map to display types for consistency\n const displayType = this.getStepTypeClass(step.StepType);\n this.stats.stepsByType[displayType] = (this.stats.stepsByType[displayType] || 0) + 1;\n \n if (step.Status === 'Completed') this.stats.completedSteps++;\n if (step.Status === 'Failed' || step.Status === 'Cancelled') this.stats.failedSteps++;\n \n // Count prompts\n if (step.StepType === 'Prompt') {\n this.stats.totalPrompts++;\n }\n \n // Recurse for sub-agents\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps) {\n this.countSteps(step.SubAgentRun.Steps);\n }\n }\n }\n \n \n \n /**\n * Handle scroll events\n */\n onScroll(event: Event): void {\n if (this.isAutoScrolling) {\n // Ignore scroll events triggered by auto-scrolling\n return;\n }\n \n const element = event.target as HTMLDivElement;\n const isAtBottom = this.isScrolledToBottom(element);\n \n // If user scrolled up from bottom, mark as user interaction\n if (!isAtBottom && this.lastScrollPosition !== element.scrollTop) {\n this.userHasScrolled = true;\n this.userHasInteracted = true;\n }\n \n // If user scrolled back to bottom, reset interaction flags\n if (isAtBottom) {\n this.userHasScrolled = false;\n this.userHasInteracted = false;\n }\n \n this.lastScrollPosition = element.scrollTop;\n }\n \n /**\n * Handle user clicks (interaction detection)\n */\n onUserInteraction(): void {\n // This is called when user clicks anywhere in the execution tree\n // The toggleNode method will set userHasInteracted for specific interactions\n }\n \n /**\n * Check if scroll is at bottom\n */\n private isScrolledToBottom(element: HTMLElement): boolean {\n const threshold = this.scrollThreshold;\n return element.scrollHeight - element.scrollTop - element.clientHeight < threshold;\n }\n \n /**\n * Check if user is at bottom (for initial setup)\n */\n private checkIfUserAtBottom(): void {\n if (!this.executionTreeContainer) return;\n \n const element = this.executionTreeContainer.nativeElement;\n if (this.isScrolledToBottom(element)) {\n this.userHasScrolled = false;\n }\n }\n \n /**\n * Auto-scroll to bottom if user hasn't interacted\n */\n private autoScrollToBottom(): void {\n if (!this.executionTreeContainer || this.userHasInteracted || this.userHasScrolled) {\n return;\n }\n \n const element = this.executionTreeContainer.nativeElement;\n this.isAutoScrolling = true;\n \n // Use smooth scrolling for better UX\n element.scrollTo({\n top: element.scrollHeight,\n behavior: 'smooth'\n });\n \n // Reset auto-scrolling flag after animation\n setTimeout(() => {\n this.isAutoScrolling = false;\n }, 300);\n }\n \n /**\n * Format agent path for display\n */\n formatAgentPath(path: string[]): string {\n return path.join(' → ');\n }\n \n /**\n * Format duration for display\n */\n formatDuration(ms: number): string {\n if (ms < 1000) return `${ms}ms`;\n if (ms < 60000) return `${(ms / 1000).toFixed(1)}s`;\n const minutes = Math.floor(ms / 60000);\n const seconds = Math.floor((ms % 60000) / 1000);\n return `${minutes}m ${seconds}s`;\n }\n \n /**\n * Get step types for display\n */\n getStepTypes(): string[] {\n return Object.keys(this.stats.stepsByType).sort();\n }\n \n /**\n * Pluralize step type based on count\n */\n pluralizeStepType(type: string, count: number): string {\n if (count === 1) {\n return type;\n }\n \n // Handle special cases\n switch (type.toLowerCase()) {\n case 'analysis':\n return 'Analyses';\n case 'summary':\n return 'Summaries';\n default:\n // Default pluralization - just add 's'\n return type + 's';\n }\n }\n \n /**\n * Format markdown content for display\n */\n formatMarkdown(markdown: string): string {\n // Basic markdown formatting\n // This is a simple implementation - you might want to use a proper markdown library\n let html = markdown;\n \n // Headers\n html = html.replace(/^### (.*$)/gim, '<h4>$1</h4>');\n html = html.replace(/^## (.*$)/gim, '<h3>$1</h3>');\n html = html.replace(/^# (.*$)/gim, '<h2>$1</h2>');\n \n // Bold\n html = html.replace(/\\*\\*(.*)\\*\\*/g, '<strong>$1</strong>');\n \n // Italic\n html = html.replace(/\\*(.*)\\*/g, '<em>$1</em>');\n \n // Detect and linkify URLs\n // This regex matches URLs starting with http://, https://, or www.\n const urlRegex = /(?:https?:\\/\\/|www\\.)[^\\s<]+/gi;\n html = html.replace(urlRegex, (url) => {\n // Ensure the URL has a protocol\n const href = url.startsWith('http') ? url : `https://${url}`;\n // Truncate long URLs for display\n const displayUrl = url.length > 50 ? url.substring(0, 50) + '...' : url;\n return `<a href=\"${href}\" target=\"_blank\" rel=\"noopener noreferrer\" style=\"color: #2196f3; text-decoration: underline; font-size: inherit;\">${displayUrl}</a>`;\n });\n \n // Line breaks\n html = html.replace(/\\n/g, '<br>');\n \n // Lists\n html = html.replace(/^\\* (.+)$/gim, '<li>$1</li>');\n html = html.replace(/(<li>.*<\\/li>)/s, '<ul>$1</ul>');\n \n // Code blocks\n html = html.replace(/```(.*?)```/gs, '<pre><code>$1</code></pre>');\n \n // Inline code\n html = html.replace(/`([^`]+)`/g, '<code>$1</code>');\n \n return html;\n }\n \n /**\n * Append new live steps without re-rendering entire tree\n */\n private appendNewLiveSteps(newSteps: MJAIAgentRunStepEntityExtended[]): void {\n if (!newSteps || newSteps.length === 0 || !this.viewInitialized || !this.executionNodesContainer) {\n return;\n }\n \n console.log('📝 Appending', newSteps.length, 'live steps');\n \n // Sort steps by StepNumber\n const sortedSteps = [...newSteps].sort((a, b) => (a.StepNumber || 0) - (b.StepNumber || 0));\n \n // Mark previously new steps as completed\n if (this.newlyAddedNodeIds.size > 0) {\n this.markPreviouslyNewNodesAsComplete();\n this.newlyAddedNodeIds.clear();\n }\n \n let hasNewSteps = false;\n \n for (const step of sortedSteps) {\n // Skip if already processed\n if (this.processedStepIds.has(step.ID)) {\n // Update existing step if status changed\n const componentRef = this.nodeComponentMap.get(step.ID);\n if (componentRef && componentRef.instance.step.Status !== step.Status) {\n componentRef.instance.step = step;\n componentRef.changeDetectorRef.detectChanges();\n }\n continue;\n }\n \n // Mark as processed and newly added\n this.processedStepIds.add(step.ID);\n this.newlyAddedNodeIds.add(step.ID);\n hasNewSteps = true;\n \n // Determine depth based on parent hierarchy\n const depth = this.calculateStepDepth(step);\n const agentPath = this.buildAgentPath(step);\n \n // Create component for new step\n this.createStepComponent(step, depth, agentPath);\n \n // Handle sub-agent steps recursively\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps) {\n const subAgentPath = [...agentPath, step.SubAgentRun.Agent || 'Sub-Agent'];\n this.renderSteps(step.SubAgentRun.Steps, depth + 1, subAgentPath);\n }\n }\n \n if (hasNewSteps) {\n // After processing all new steps, ensure only the last one shows as running\n this.ensureOnlyLastStepIsRunning();\n \n this.updateCurrentStep();\n this.calculateStats();\n \n // Force change detection to ensure new components are rendered\n this.cdr.detectChanges();\n \n // Auto-scroll if user hasn't interacted\n setTimeout(() => {\n this.autoScrollToBottom();\n }, 100);\n }\n }\n \n /**\n * Calculate step depth based on parent hierarchy\n */\n private calculateStepDepth(step: MJAIAgentRunStepEntityExtended): number {\n // For now, return 0 for top-level steps\n // In live mode, depth information should come from the streaming data\n return 0;\n }\n \n /**\n * Build agent path for a step\n */\n private buildAgentPath(step: MJAIAgentRunStepEntityExtended): string[] {\n // In live mode, agent path should come from streaming data\n // For now, return empty array\n return [];\n }\n \n \n /**\n * Check if execution is complete\n */\n isExecutionComplete(): boolean {\n return this.stats.completedSteps > 0 && \n this.stats.completedSteps === this.stats.totalSteps - this.stats.failedSteps;\n }\n \n /**\n * Handle view run button click\n */\n onViewRunClick(): void {\n if (this.agentRun) {\n this.viewRunClick.emit({ runId: this.agentRun.ID, runType: 'agent' });\n }\n }\n \n \n /**\n * Expands all nodes that have sub-agent children\n */\n private expandAllNodes(): void {\n console.log('🔄 Auto-expanding nodes with sub-agents');\n \n // Expand all steps that have sub-agent runs\n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps?.length) {\n this.expandedStates.set(stepId, true);\n componentRef.instance.expanded = true;\n componentRef.changeDetectorRef.detectChanges();\n console.log(`Expanded sub-agent: ${step.StepName}`);\n }\n });\n \n // Trigger change detection\n this.cdr.markForCheck();\n this.cdr.detectChanges();\n \n // Scroll to top after expansion\n setTimeout(() => {\n this.scrollToTop();\n }, 100);\n }\n \n /**\n * Scroll the execution tree to the top\n */\n private scrollToTop(): void {\n if (this.executionTreeContainer) {\n const element = this.executionTreeContainer.nativeElement;\n element.scrollTo({\n top: 0,\n behavior: 'smooth'\n });\n }\n }\n \n /**\n * Check if there is content to display\n */\n hasContent(): boolean {\n return this.nodeComponentMap.size > 0;\n }\n}"]}
|
|
1
|
+
{"version":3,"file":"agent-execution-monitor.component.js","sourceRoot":"","sources":["../../src/lib/agent-execution-monitor.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,EAAuC,SAAS,EAAgD,uBAAuB,EAAE,gBAAgB,EAAgB,MAAM,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC9N,OAAO,EAAE,OAAO,EAAE,QAAQ,EAAgB,MAAM,MAAM,CAAC;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAC3C,OAAO,EAAE,sBAAsB,EAAE,MAAM,kCAAkC,CAAC;AAE1E,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;;;;;;IA4D5B,+BAA6B;IACzB,2BAA2B;IAC3B,sBACJ;IAAA,iBAAO;;;IAKP,AADJ,8BAA4B,eACG;IAAA,wBAAQ;IAAA,iBAAO;IAC1C,gCAAwB;IAAA,YAA0B;IACtD,AADsD,iBAAO,EACvD;;;IADsB,eAA0B;IAA1B,iDAA0B;;;;IAItD,kCAAwD;IAA3B,kMAAS,uBAAgB,KAAC;IACnD,wBAA6C;IAC7C,YACJ;IAAA,iBAAS;;;IADL,eACJ;IADI,yFACJ;;;IAcA,qCAGqB;;;IAYT,gCAA2B;IAAA,YAAgC;IAAA,iBAAO;;;IAAvC,cAAgC;IAAhC,gEAAgC;;;IAkB/D,AADJ,+BAAuB,eACM;IAAA,wBAAQ;IAAA,iBAAO;IACxC,gCAAyB;IAAA,YAAyC;IACtE,AADsE,iBAAO,EACvE;;;IADuB,eAAyC;IAAzC,uEAAyC;;;IAOlE,gCAAyB;IACrB,YACJ;IAAA,iBAAO;;;;IADH,cACJ;IADI,6IACJ;;;IAJR,+BAAwB;IACpB,oIAIC;IACL,iBAAM;;;IALF,cA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BAClC,SAAS;mBAAC,yBAAyB,EAAE,EAAE,IAAI,EAAE,gBAAgB,EAAE;;kFAXvD,8BAA8B","sourcesContent":["import { Component, Input, OnChanges, SimpleChanges, OnDestroy, ViewChild, ElementRef, AfterViewInit, ChangeDetectorRef, ChangeDetectionStrategy, ViewContainerRef, ComponentRef, Output, EventEmitter } from '@angular/core';\nimport { Subject, interval, Subscription } from 'rxjs';\nimport { takeUntil } from 'rxjs/operators';\nimport { ExecutionNodeComponent } from './agent-execution-node.component';\nimport { MJAIAgentRunEntityExtended, MJAIAgentRunStepEntityExtended } from '@memberjunction/ai-core-plus';\nimport { UUIDsEqual } from '@memberjunction/global';\n\n/**\n * Progress message with display mode\n */\nexport interface ProgressMessage {\n id: string;\n message: string;\n timestamp: Date;\n displayMode: 'live' | 'historical' | 'both';\n metadata?: Record<string, unknown>;\n}\n\n/**\n * Mode for the execution monitor component\n */\nexport type ExecutionMonitorMode = 'live' | 'historical';\n\n/**\n * Execution statistics for display\n */\nexport interface ExecutionStats {\n totalSteps: number;\n completedSteps: number;\n failedSteps: number;\n totalTokens: number;\n totalCost: number;\n stepsByType: Record<string, number>;\n totalDuration?: number;\n totalPrompts: number;\n}\n\n/**\n * AgentExecutionMonitor Component\n * \n * A reusable component for visualizing AI agent execution flow in real-time or historically.\n * Displays a hierarchical tree of execution steps with status, timing, and preview information.\n * \n * Features:\n * - Real-time updates for live executions\n * - Historical playback for completed executions\n * - Collapsible tree structure\n * - Step status indicators with animations\n * - Execution statistics\n * - Token usage and cost tracking\n * - Error display\n * - Input/output preview\n */\n@Component({\n standalone: false,\n selector: 'mj-agent-execution-monitor',\n changeDetection: ChangeDetectionStrategy.OnPush,\n template: `\n <div class=\"execution-monitor\" [class.live-mode]=\"mode === 'live'\">\n <!-- Header -->\n <div class=\"monitor-header\">\n <div class=\"header-title\">\n <i class=\"fa-solid fa-diagram-project\"></i>\n <span>Execution Monitor</span>\n @if (mode === 'live') {\n <span class=\"live-indicator\">\n <span class=\"pulse\"></span>\n LIVE\n </span>\n }\n </div>\n @if (currentStep && mode === 'live') {\n <div class=\"current-status\">\n <span class=\"status-label\">Current:</span>\n <span class=\"step-name\">{{ currentStep.StepName }}</span>\n </div>\n }\n @if (mode === 'historical' && agentRun && isExecutionComplete()) {\n <button class=\"view-run-btn\" (click)=\"onViewRunClick()\">\n <i class=\"fa-solid fa-external-link-alt\"></i>\n View {{ runType === 'agent' ? 'Agent' : 'Prompt' }} Run\n </button>\n }\n </div>\n\n <!-- Execution Tree -->\n <div class=\"execution-tree\" \n #executionTreeContainer\n [class.has-content]=\"hasContent()\"\n (scroll)=\"onScroll($event)\"\n (click)=\"onUserInteraction()\">\n <!-- Always render the container, but show empty state when no data -->\n <div #executionNodesContainer class=\"nodes-container\">\n </div>\n @if (!agentRun && liveSteps.length === 0) {\n <mj-empty-state\n Icon=\"fa-solid fa-hourglass-start\"\n Title=\"Waiting for execution to begin...\"\n Size=\"compact\" />\n }\n </div>\n\n <!-- Statistics Footer -->\n <div class=\"monitor-footer\">\n <div class=\"stats-grid\">\n <div class=\"stat-item\">\n <span class=\"stat-label\">Steps</span>\n <span class=\"stat-value\">\n {{ stats.completedSteps }}/{{ stats.totalSteps }}\n @if (stats.failedSteps > 0) {\n <span class=\"failed-count\">({{ stats.failedSteps }} failed)</span>\n }\n </span>\n </div>\n <div class=\"stat-item\">\n <span class=\"stat-label\">Prompts</span>\n <span class=\"stat-value\">{{ stats.totalPrompts }}</span>\n </div>\n <div class=\"stat-item\">\n <span class=\"stat-label\">Tokens</span>\n <span class=\"stat-value\">{{ stats.totalTokens.toLocaleString() }}</span>\n </div>\n <div class=\"stat-item\">\n <span class=\"stat-label\">Cost</span>\n <span class=\"stat-value\">\\${{ stats.totalCost.toFixed(4) }}</span>\n </div>\n @if (stats.totalDuration) {\n <div class=\"stat-item\">\n <span class=\"stat-label\">Duration</span>\n <span class=\"stat-value\">{{ formatDuration(stats.totalDuration) }}</span>\n </div>\n }\n </div>\n @if (getStepTypes().length > 0) {\n <div class=\"step-types\">\n @for (type of getStepTypes(); track type) {\n <span class=\"type-badge\">\n {{ stats.stepsByType[type] }} {{ pluralizeStepType(type, stats.stepsByType[type]) }}\n </span>\n }\n </div>\n }\n </div>\n </div>\n `,\n styles: [`\n :host {\n display: flex;\n flex-direction: column;\n height: 100%;\n overflow: hidden;\n }\n \n .execution-monitor {\n display: flex;\n flex-direction: column;\n flex: 1;\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n border-radius: 8px;\n overflow: hidden;\n }\n\n /* Header */\n .monitor-header {\n padding: 16px;\n background: var(--mj-bg-surface-card);\n border-bottom: 1px solid var(--mj-border-default);\n }\n\n .header-title {\n display: flex;\n align-items: center;\n gap: 8px;\n font-size: 16px;\n font-weight: 600;\n color: var(--mj-text-primary);\n margin-bottom: 8px;\n }\n\n .header-title i {\n color: var(--mj-brand-primary);\n }\n\n .live-indicator {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n padding: 4px 8px;\n background: var(--mj-status-error);\n color: var(--mj-text-inverse);\n border-radius: 4px;\n font-size: 11px;\n font-weight: 600;\n letter-spacing: 0.5px;\n }\n\n .pulse {\n display: inline-block;\n width: 8px;\n height: 8px;\n background: white;\n border-radius: 50%;\n animation: pulse 2s infinite;\n }\n\n @keyframes pulse {\n 0% { opacity: 1; transform: scale(1); }\n 50% { opacity: 0.5; transform: scale(0.8); }\n 100% { opacity: 1; transform: scale(1); }\n }\n\n .current-status {\n display: flex;\n align-items: center;\n gap: 8px;\n font-size: 13px;\n color: var(--mj-text-secondary);\n }\n\n .status-label {\n font-weight: 500;\n }\n\n .agent-path {\n color: var(--mj-text-muted);\n }\n\n .step-name {\n color: var(--mj-text-primary);\n font-weight: 500;\n }\n\n /* Execution Tree */\n .execution-tree {\n flex: 1;\n overflow-y: auto;\n overflow-x: auto;\n padding: 16px;\n min-height: 0;\n }\n \n .nodes-container {\n /* No extra padding needed, indentation handled by node margins */\n }\n\n .execution-tree mj-empty-state {\n height: 100%;\n }\n\n /* Tree Nodes - These styles are for reference only, actual rendering is done by ExecutionNodeComponent */\n .tree-node {\n margin-bottom: 4px;\n }\n\n /* Footer */\n .monitor-footer {\n padding: 16px;\n background: var(--mj-bg-surface-card);\n border-top: 1px solid var(--mj-border-default);\n }\n\n .stats-grid {\n display: grid;\n grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));\n gap: 16px;\n margin-bottom: 12px;\n }\n\n .stat-item {\n text-align: center;\n }\n\n .stat-label {\n display: block;\n font-size: 11px;\n color: var(--mj-text-secondary);\n text-transform: uppercase;\n letter-spacing: 0.5px;\n margin-bottom: 4px;\n }\n\n .stat-value {\n display: block;\n font-size: 16px;\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n\n .failed-count {\n color: var(--mj-status-error);\n font-size: 12px;\n font-weight: normal;\n }\n\n .step-types {\n display: flex;\n flex-wrap: wrap;\n gap: 8px;\n justify-content: center;\n }\n\n .type-badge {\n display: inline-block;\n padding: 4px 8px;\n background: color-mix(in srgb, var(--mj-brand-primary) 12%, var(--mj-bg-surface));\n color: var(--mj-brand-primary);\n border-radius: 4px;\n font-size: 12px;\n font-weight: 500;\n }\n\n /* View Run Button */\n .view-run-btn {\n background: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n border: none;\n padding: 6px 12px;\n border-radius: 4px;\n font-size: 13px;\n font-weight: 500;\n cursor: pointer;\n display: inline-flex;\n align-items: center;\n gap: 6px;\n transition: all 0.2s ease;\n margin-left: auto;\n }\n\n .view-run-btn:hover {\n background: var(--mj-brand-primary-hover);\n transform: translateY(-1px);\n box-shadow: 0 2px 4px rgba(0,0,0,0.2);\n }\n \n .view-run-btn i {\n font-size: 12px;\n }\n\n /* Responsive */\n @media (max-width: 768px) {\n .monitor-header {\n padding: 12px;\n }\n\n .execution-tree {\n padding: 12px;\n }\n }\n `]\n})\nexport class AgentExecutionMonitorComponent implements OnChanges, OnDestroy, AfterViewInit {\n @Input() mode: ExecutionMonitorMode = 'historical';\n @Input() agentRun: MJAIAgentRunEntityExtended | null = null; // For historical mode\n @Input() liveSteps: MJAIAgentRunStepEntityExtended[] = []; // For live mode streaming\n @Input() autoExpand: boolean = true; // Auto-expand nodes in live mode\n @Input() runId: string | null = null; // ID of the run (agent or prompt)\n @Input() runType: 'agent' | 'prompt' = 'agent'; // Type of run\n \n @Output() viewRunClick = new EventEmitter<{ runId: string; runType: 'agent' | 'prompt' }>();\n \n @ViewChild('executionTreeContainer') executionTreeContainer!: ElementRef<HTMLDivElement>;\n @ViewChild('executionNodesContainer', { read: ViewContainerRef }) executionNodesContainer!: ViewContainerRef;\n \n // Store the currently rendered steps for UI state management\n currentStep: MJAIAgentRunStepEntityExtended | null = null;\n \n // Track component references for dynamic components\n private nodeComponentMap = new Map<string, ComponentRef<ExecutionNodeComponent>>();\n \n // UI state management - track expanded states separately from entities\n private expandedStates = new Map<string, boolean>();\n private detailsExpandedStates = new Map<string, boolean>();\n stats: ExecutionStats = {\n totalSteps: 0,\n completedSteps: 0,\n failedSteps: 0,\n totalTokens: 0,\n totalCost: 0,\n stepsByType: {},\n totalPrompts: 0\n };\n \n // User interaction tracking\n private userHasInteracted = false;\n private userHasScrolled = false;\n private isAutoScrolling = false;\n private lastScrollPosition = 0;\n private scrollThreshold = 50; // pixels from bottom to consider \"at bottom\"\n \n // View initialization flag\n private viewInitialized = false;\n \n // Track processed step IDs to avoid duplication\n private processedStepIds = new Set<string>();\n \n // Track which nodes were added in the current update\n private newlyAddedNodeIds = new Set<string>();\n \n // Temporary storage for parsed metadata\n private lastParsedAgentData: any = null;\n private lastParsedActionData: any = null;\n \n private destroy$ = new Subject<void>();\n private updateSubscription?: Subscription;\n \n constructor(private cdr: ChangeDetectorRef) {}\n \n ngOnChanges(changes: SimpleChanges): void {\n console.log('🔄 Execution Monitor ngOnChanges:', {\n agentRunChanged: !!changes['agentRun'],\n liveStepsChanged: !!changes['liveSteps'],\n modeChanged: !!changes['mode'],\n hasAgentRun: !!this.agentRun,\n liveStepsCount: this.liveSteps?.length || 0\n });\n \n // Handle agent run changes (historical mode)\n if (changes['agentRun'] && this.mode === 'historical') {\n const oldRun = changes['agentRun'].previousValue;\n const newRun = changes['agentRun'].currentValue;\n \n console.log('📊 Agent run changed:', {\n oldRunExists: !!oldRun,\n newRunExists: !!newRun,\n oldRunId: oldRun?.ID,\n newRunId: newRun?.ID,\n stepsCount: newRun?.Steps?.length\n });\n \n // Only clear if it's actually a different execution (different ID)\n const isDifferentExecution = (!oldRun && newRun) || \n (oldRun && newRun && !UUIDsEqual(oldRun.ID, newRun.ID)) ||\n (oldRun && !newRun);\n \n if (isDifferentExecution) {\n console.log('🗑️ Clearing for different agent run');\n this.processedStepIds.clear();\n this.newlyAddedNodeIds.clear();\n this.expandedStates.clear();\n this.detailsExpandedStates.clear();\n this.clearNodeComponents();\n this.currentStep = null;\n }\n \n // Always process the agent run data (will handle updates to existing run)\n if (newRun) {\n this.processAgentRun();\n }\n }\n \n // Handle live steps changes (live mode)\n if (changes['liveSteps'] && this.mode === 'live') {\n const oldSteps = changes['liveSteps'].previousValue;\n const newSteps = changes['liveSteps'].currentValue;\n \n console.log('📊 Live steps changed:', {\n oldCount: oldSteps?.length || 0,\n newCount: newSteps?.length || 0\n });\n \n // Process live steps\n this.processLiveSteps();\n }\n \n // Handle mode changes\n if (changes['mode'] && !changes['mode'].firstChange) {\n const previousMode = changes['mode'].previousValue;\n const currentMode = changes['mode'].currentValue;\n \n console.log('🔄 Mode changed:', { previousMode, currentMode });\n \n // Clear everything when switching modes\n this.processedStepIds.clear();\n this.newlyAddedNodeIds.clear();\n this.expandedStates.clear();\n this.detailsExpandedStates.clear();\n this.clearNodeComponents();\n this.currentStep = null;\n \n // Stop live updates when switching away from live mode\n if (previousMode === 'live' && this.updateSubscription) {\n this.updateSubscription.unsubscribe();\n this.updateSubscription = undefined;\n }\n \n // Process data for the new mode\n if (currentMode === 'historical' && this.agentRun) {\n this.processAgentRun();\n } else if (currentMode === 'live') {\n this.setupLiveUpdates();\n }\n }\n }\n \n ngAfterViewInit(): void {\n this.viewInitialized = true;\n \n console.log('🎯 View initialized, checking for pending data:', {\n hasAgentRun: !!this.agentRun,\n hasLiveSteps: this.liveSteps?.length > 0,\n hasContainer: !!this.executionNodesContainer\n });\n \n // Initial setup for scroll behavior\n if (this.mode === 'live') {\n this.checkIfUserAtBottom();\n }\n \n // If we have data waiting to be rendered, render it now\n if (this.mode === 'historical' && this.agentRun && this.nodeComponentMap.size === 0) {\n console.log('⚡ Processing agent run after view init');\n this.processAgentRun();\n } else if (this.mode === 'live' && this.liveSteps?.length > 0) {\n console.log('⚡ Processing live steps after view init');\n this.processLiveSteps();\n }\n }\n \n ngOnDestroy(): void {\n this.destroy$.next();\n this.destroy$.complete();\n if (this.updateSubscription) {\n this.updateSubscription.unsubscribe();\n this.updateSubscription = undefined;\n }\n this.clearNodeComponents();\n }\n \n /**\n * Clear all dynamically created components\n */\n private clearNodeComponents(): void {\n this.nodeComponentMap.forEach(ref => ref.destroy());\n this.nodeComponentMap.clear();\n if (this.executionNodesContainer) {\n this.executionNodesContainer.clear();\n }\n }\n \n /**\n * Process agent run for historical mode\n */\n private processAgentRun(): void {\n console.log('⚙️ Processing agent run:', {\n hasAgentRun: !!this.agentRun,\n stepsCount: this.agentRun?.Steps?.length || 0,\n viewInitialized: this.viewInitialized,\n hasContainer: !!this.executionNodesContainer\n });\n \n if (!this.agentRun || !this.viewInitialized || !this.executionNodesContainer) {\n console.warn('⚠️ Cannot process agent run:', {\n agentRun: !this.agentRun ? 'missing' : 'present',\n viewInitialized: this.viewInitialized ? 'yes' : 'no',\n container: !this.executionNodesContainer ? 'missing' : 'present'\n });\n return;\n }\n \n // Clear existing components\n this.clearNodeComponents();\n \n // Render the agent run steps\n if (this.agentRun.Steps && this.agentRun.Steps.length > 0) {\n console.log('🎨 Rendering', this.agentRun.Steps.length, 'steps');\n this.renderSteps(this.agentRun.Steps, 0, []);\n console.log('✅ Finished rendering, container now has', this.executionNodesContainer.length, 'components');\n } else {\n console.warn('⚠️ No steps to render');\n }\n \n // Calculate statistics\n this.calculateStats();\n \n // Trigger change detection after rendering all components\n this.cdr.detectChanges();\n }\n \n /**\n * Process live steps for live mode\n */\n private processLiveSteps(): void {\n console.log('⚙️ Processing live steps:', {\n stepsCount: this.liveSteps?.length || 0,\n viewInitialized: this.viewInitialized,\n hasContainer: !!this.executionNodesContainer\n });\n \n if (!this.liveSteps || !this.viewInitialized || !this.executionNodesContainer) {\n return;\n }\n \n // Append new steps without clearing existing ones\n this.appendNewLiveSteps(this.liveSteps);\n \n // Trigger change detection after appending live steps\n this.cdr.detectChanges();\n \n // Set up live update monitoring if not already set up\n if (!this.updateSubscription) {\n this.setupLiveUpdates();\n }\n }\n \n /**\n * Render steps recursively with proper hierarchy\n */\n private renderSteps(steps: MJAIAgentRunStepEntityExtended[], depth: number, agentPath: string[]): void {\n console.log('🎨 Rendering steps:', {\n count: steps.length,\n depth,\n agentPath\n });\n \n // Sort steps by StepNumber to ensure proper ordering\n const sortedSteps = [...steps].sort((a, b) => (a.StepNumber || 0) - (b.StepNumber || 0));\n \n for (const step of sortedSteps) {\n // Skip if already processed in live mode\n if (this.processedStepIds.has(step.ID)) {\n continue;\n }\n \n // Create component for this step\n this.createStepComponent(step, depth, agentPath);\n \n // Mark as processed\n this.processedStepIds.add(step.ID);\n \n // Handle sub-agent recursion\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps) {\n const subAgentPath = [...agentPath, step.SubAgentRun.Agent || 'Sub-Agent'];\n this.renderSteps(step.SubAgentRun.Steps, depth + 1, subAgentPath);\n }\n }\n }\n \n /**\n * Create a component for a step\n */\n private createStepComponent(\n step: MJAIAgentRunStepEntityExtended, \n depth: number, \n agentPath: string[]\n ): ComponentRef<ExecutionNodeComponent> {\n // Ensure container exists\n if (!this.executionNodesContainer) {\n console.error('❌ executionNodesContainer not available');\n throw new Error('executionNodesContainer ViewContainerRef not initialized');\n }\n \n const componentRef = this.executionNodesContainer.createComponent(ExecutionNodeComponent);\n const instance = componentRef.instance;\n \n console.log('🔨 Creating component for step:', {\n stepId: step.ID,\n stepName: step.StepName,\n depth,\n containerLength: this.executionNodesContainer.length,\n hostElement: componentRef.location.nativeElement\n });\n \n // Pass the step data with UI state information\n instance.step = step;\n instance.depth = depth;\n instance.agentPath = agentPath;\n instance.expanded = this.expandedStates.get(step.ID) || false;\n instance.detailsExpanded = this.detailsExpandedStates.get(step.ID) || false;\n \n // Subscribe to outputs\n instance.toggleNode.subscribe(() => this.toggleStepExpansion(step));\n instance.toggleDetails.subscribe(() => this.toggleStepDetails(step));\n instance.userInteracted.subscribe(() => this.onUserInteraction());\n \n // Store reference\n this.nodeComponentMap.set(step.ID, componentRef);\n \n // Log the component state after setup\n console.log('✅ Component created and configured:', {\n stepId: step.ID,\n hasData: !!instance.step,\n isAttached: componentRef.hostView.destroyed === false\n });\n \n return componentRef;\n }\n \n /**\n * Toggle step expansion\n */\n private toggleStepExpansion(step: MJAIAgentRunStepEntityExtended): void {\n const currentState = this.expandedStates.get(step.ID) || false;\n this.expandedStates.set(step.ID, !currentState);\n this.userHasInteracted = true;\n \n // Update the component\n const componentRef = this.nodeComponentMap.get(step.ID);\n if (componentRef) {\n componentRef.instance.expanded = !currentState;\n componentRef.changeDetectorRef.detectChanges();\n }\n \n this.cdr.markForCheck();\n }\n \n /**\n * Toggle step details expansion\n */\n private toggleStepDetails(step: MJAIAgentRunStepEntityExtended): void {\n const currentState = this.detailsExpandedStates.get(step.ID) || false;\n this.detailsExpandedStates.set(step.ID, !currentState);\n \n // Update the component\n const componentRef = this.nodeComponentMap.get(step.ID);\n if (componentRef) {\n componentRef.instance.detailsExpanded = !currentState;\n componentRef.changeDetectorRef.detectChanges();\n }\n }\n \n \n /**\n * Get step type CSS class for styling\n */\n private getStepTypeClass(stepType: string): string {\n const typeMap: Record<string, string> = {\n 'Validation': 'validation',\n 'Prompt': 'prompt',\n 'Actions': 'action',\n 'Sub-Agent': 'sub-agent',\n 'Decision': 'decision',\n 'Chat': 'chat'\n };\n return typeMap[stepType] || 'prompt';\n }\n \n /**\n * Get status CSS class for styling\n */\n private getStatusClass(status: string): string {\n const statusMap: Record<string, string> = {\n 'Pending': 'pending',\n 'Running': 'running',\n 'Completed': 'completed',\n 'Failed': 'failed',\n 'Cancelled': 'failed',\n 'Paused': 'pending'\n };\n return statusMap[status] || 'pending';\n }\n \n /**\n * Helper function to safely convert a value to a preview string\n */\n private valueToPreviewString(value: any): string {\n if (value === null || value === undefined) {\n return '';\n }\n if (typeof value === 'object') {\n return JSON.stringify(value, null, 2);\n }\n return String(value);\n }\n\n /**\n * Create a preview string from data\n */\n private createPreview(data: any): string | undefined {\n if (!data) return undefined;\n \n try {\n const parsed = typeof data === 'string' ? JSON.parse(data) : data;\n \n // Extract meaningful preview and store metadata\n if (parsed.promptName) return `Prompt: ${parsed.promptName}`;\n if (parsed.actionName) {\n // Store action metadata if available\n this.lastParsedActionData = {\n actionName: parsed.actionName,\n actionId: parsed.actionId,\n actionIconClass: parsed.actionIconClass\n };\n return `Action: ${parsed.actionName}`;\n }\n if (parsed.subAgentName) {\n // Store agent metadata if available\n this.lastParsedAgentData = {\n agentName: parsed.subAgentName,\n agentId: parsed.subAgentId || parsed.agentId,\n agentIconClass: parsed.subAgentIconClass || parsed.agentIconClass,\n agentLogoURL: parsed.subAgentLogoURL || parsed.agentLogoURL\n };\n return `Sub-agent: ${parsed.subAgentName}`;\n }\n if (parsed.message) return this.valueToPreviewString(parsed.message);\n if (parsed.userMessage) return this.valueToPreviewString(parsed.userMessage);\n \n // Show action results clearly\n if (parsed.actionResult) {\n const result = parsed.actionResult;\n let preview = '';\n if (result.success !== undefined) {\n preview += `Success: ${result.success}\\n`;\n }\n if (result.resultCode) {\n preview += `Result Code: ${result.resultCode}\\n`;\n }\n if (result.message) {\n preview += `Message: ${this.valueToPreviewString(result.message)}\\n`;\n }\n if (result.result) {\n preview += `Result: ${typeof result.result === 'object' ? JSON.stringify(result.result, null, 2) : result.result}`;\n }\n return preview.trim();\n }\n \n // Legacy action result format\n if (parsed.result) {\n return this.valueToPreviewString(parsed.result);\n }\n \n // Show prompt results\n if (parsed.promptResult) {\n const result = parsed.promptResult;\n let preview = '';\n if (result.success !== undefined) {\n preview += `Success: ${result.success}\\n`;\n }\n if (result.content) {\n preview += `Content: ${this.valueToPreviewString(result.content)}`;\n }\n return preview;\n }\n \n // Fallback to stringified preview\n const str = JSON.stringify(parsed, null, 2);\n return str.length > 500 ? str.substring(0, 500) + '...' : str;\n } catch {\n return typeof data === 'string' ? data : JSON.stringify(data);\n }\n }\n \n /**\n * Extract token count from output data\n */\n private extractTokens(data: any): number | undefined {\n if (!data) return undefined;\n try {\n const parsed = typeof data === 'string' ? JSON.parse(data) : data;\n return parsed.promptResult?.tokensUsed || parsed.tokensUsed;\n } catch {\n return undefined;\n }\n }\n \n /**\n * Extract cost from output data\n */\n private extractCost(data: any): number | undefined {\n if (!data) return undefined;\n try {\n const parsed = typeof data === 'string' ? JSON.parse(data) : data;\n return parsed.promptResult?.totalCost || parsed.totalCost;\n } catch {\n return undefined;\n }\n }\n \n /**\n * Calculate duration from timestamps\n */\n private calculateDuration(start: any, end: any): number | undefined {\n if (!start || !end) return undefined;\n const startTime = new Date(start).getTime();\n const endTime = new Date(end).getTime();\n return endTime - startTime;\n }\n \n /**\n * Set up live updates for real-time execution\n */\n private setupLiveUpdates(): void {\n console.log('⚡ Setting up live updates');\n \n // Process initial live steps if any\n if (this.liveSteps && this.liveSteps.length > 0) {\n this.appendNewLiveSteps(this.liveSteps);\n }\n \n // Set up interval to check for updates (if not already set up)\n if (this.mode === 'live' && !this.updateSubscription) {\n this.updateSubscription = interval(500)\n .pipe(takeUntil(this.destroy$))\n .subscribe(() => {\n // Update current step indicator\n this.updateCurrentStep();\n \n // Recalculate stats periodically\n this.calculateStats();\n });\n }\n }\n \n /**\n * Update current step indicator\n */\n private updateCurrentStep(): void {\n // Find the first running step from all rendered components\n let runningStep: MJAIAgentRunStepEntityExtended | null = null;\n \n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step && step.Status === 'Running' && !runningStep) {\n runningStep = step;\n }\n });\n \n this.currentStep = runningStep;\n this.cdr.markForCheck();\n }\n \n /**\n * Mark previously new nodes as completed\n */\n private markPreviouslyNewNodesAsComplete(): void {\n // Mark ALL running steps as completed (not just previously new ones)\n // This ensures only the latest step shows as running\n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.Status === 'Running') {\n // Create a copy with updated status\n const updatedStep = Object.assign({}, step, { Status: 'Completed' });\n componentRef.instance.step = updatedStep;\n componentRef.changeDetectorRef.detectChanges();\n }\n });\n }\n \n /**\n * Ensure only the last step in the execution order shows as running\n */\n private ensureOnlyLastStepIsRunning(): void {\n // Find the last step by step number\n let lastRunningStep: { stepId: string; stepNumber: number; componentRef: ComponentRef<ExecutionNodeComponent> } | null = null;\n \n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.Status === 'Running') {\n const stepNumber = step.StepNumber || 0;\n if (!lastRunningStep || stepNumber > lastRunningStep.stepNumber) {\n lastRunningStep = { stepId, stepNumber, componentRef };\n }\n }\n });\n \n // Set override display status for all running steps\n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.Status === 'Running') {\n // Override display to show as completed, except for the last one\n if (lastRunningStep && stepId === lastRunningStep.stepId) {\n componentRef.instance.overrideDisplayStatus = 'Running';\n } else {\n componentRef.instance.overrideDisplayStatus = 'Completed';\n }\n componentRef.changeDetectorRef.detectChanges();\n }\n });\n }\n \n \n /**\n * Calculate execution statistics\n */\n private calculateStats(): void {\n this.stats = {\n totalSteps: 0,\n completedSteps: 0,\n failedSteps: 0,\n totalTokens: 0,\n totalCost: 0,\n stepsByType: {},\n totalDuration: 0,\n totalPrompts: 0\n };\n \n // Use token data from agent run if available\n if (this.agentRun) {\n this.stats.totalTokens = this.agentRun.TotalTokensUsed || 0;\n this.stats.totalCost = this.agentRun.TotalCost || 0;\n \n // Calculate duration\n if (this.agentRun.StartedAt && this.agentRun.CompletedAt) {\n this.stats.totalDuration = new Date(this.agentRun.CompletedAt).getTime() - \n new Date(this.agentRun.StartedAt).getTime();\n }\n \n // Count steps recursively\n if (this.agentRun.Steps) {\n this.countSteps(this.agentRun.Steps);\n }\n }\n \n console.log('📈 Stats calculated:', {\n totalSteps: this.stats.totalSteps,\n totalTokens: this.stats.totalTokens,\n totalCost: this.stats.totalCost\n });\n }\n \n /**\n * Count steps recursively\n */\n private countSteps(steps: MJAIAgentRunStepEntityExtended[]): void {\n for (const step of steps) {\n this.stats.totalSteps++;\n \n // Map to display types for consistency\n const displayType = this.getStepTypeClass(step.StepType);\n this.stats.stepsByType[displayType] = (this.stats.stepsByType[displayType] || 0) + 1;\n \n if (step.Status === 'Completed') this.stats.completedSteps++;\n if (step.Status === 'Failed' || step.Status === 'Cancelled') this.stats.failedSteps++;\n \n // Count prompts\n if (step.StepType === 'Prompt') {\n this.stats.totalPrompts++;\n }\n \n // Recurse for sub-agents\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps) {\n this.countSteps(step.SubAgentRun.Steps);\n }\n }\n }\n \n \n \n /**\n * Handle scroll events\n */\n onScroll(event: Event): void {\n if (this.isAutoScrolling) {\n // Ignore scroll events triggered by auto-scrolling\n return;\n }\n \n const element = event.target as HTMLDivElement;\n const isAtBottom = this.isScrolledToBottom(element);\n \n // If user scrolled up from bottom, mark as user interaction\n if (!isAtBottom && this.lastScrollPosition !== element.scrollTop) {\n this.userHasScrolled = true;\n this.userHasInteracted = true;\n }\n \n // If user scrolled back to bottom, reset interaction flags\n if (isAtBottom) {\n this.userHasScrolled = false;\n this.userHasInteracted = false;\n }\n \n this.lastScrollPosition = element.scrollTop;\n }\n \n /**\n * Handle user clicks (interaction detection)\n */\n onUserInteraction(): void {\n // This is called when user clicks anywhere in the execution tree\n // The toggleNode method will set userHasInteracted for specific interactions\n }\n \n /**\n * Check if scroll is at bottom\n */\n private isScrolledToBottom(element: HTMLElement): boolean {\n const threshold = this.scrollThreshold;\n return element.scrollHeight - element.scrollTop - element.clientHeight < threshold;\n }\n \n /**\n * Check if user is at bottom (for initial setup)\n */\n private checkIfUserAtBottom(): void {\n if (!this.executionTreeContainer) return;\n \n const element = this.executionTreeContainer.nativeElement;\n if (this.isScrolledToBottom(element)) {\n this.userHasScrolled = false;\n }\n }\n \n /**\n * Auto-scroll to bottom if user hasn't interacted\n */\n private autoScrollToBottom(): void {\n if (!this.executionTreeContainer || this.userHasInteracted || this.userHasScrolled) {\n return;\n }\n \n const element = this.executionTreeContainer.nativeElement;\n this.isAutoScrolling = true;\n \n // Use smooth scrolling for better UX\n element.scrollTo({\n top: element.scrollHeight,\n behavior: 'smooth'\n });\n \n // Reset auto-scrolling flag after animation\n setTimeout(() => {\n this.isAutoScrolling = false;\n }, 300);\n }\n \n /**\n * Format agent path for display\n */\n formatAgentPath(path: string[]): string {\n return path.join(' → ');\n }\n \n /**\n * Format duration for display\n */\n formatDuration(ms: number): string {\n if (ms < 1000) return `${ms}ms`;\n if (ms < 60000) return `${(ms / 1000).toFixed(1)}s`;\n const minutes = Math.floor(ms / 60000);\n const seconds = Math.floor((ms % 60000) / 1000);\n return `${minutes}m ${seconds}s`;\n }\n \n /**\n * Get step types for display\n */\n getStepTypes(): string[] {\n return Object.keys(this.stats.stepsByType).sort();\n }\n \n /**\n * Pluralize step type based on count\n */\n pluralizeStepType(type: string, count: number): string {\n if (count === 1) {\n return type;\n }\n \n // Handle special cases\n switch (type.toLowerCase()) {\n case 'analysis':\n return 'Analyses';\n case 'summary':\n return 'Summaries';\n default:\n // Default pluralization - just add 's'\n return type + 's';\n }\n }\n \n /**\n * Format markdown content for display\n */\n formatMarkdown(markdown: string): string {\n // Basic markdown formatting\n // This is a simple implementation - you might want to use a proper markdown library\n let html = markdown;\n \n // Headers\n html = html.replace(/^### (.*$)/gim, '<h4>$1</h4>');\n html = html.replace(/^## (.*$)/gim, '<h3>$1</h3>');\n html = html.replace(/^# (.*$)/gim, '<h2>$1</h2>');\n \n // Bold\n html = html.replace(/\\*\\*(.*)\\*\\*/g, '<strong>$1</strong>');\n \n // Italic\n html = html.replace(/\\*(.*)\\*/g, '<em>$1</em>');\n \n // Detect and linkify URLs\n // This regex matches URLs starting with http://, https://, or www.\n const urlRegex = /(?:https?:\\/\\/|www\\.)[^\\s<]+/gi;\n html = html.replace(urlRegex, (url) => {\n // Ensure the URL has a protocol\n const href = url.startsWith('http') ? url : `https://${url}`;\n // Truncate long URLs for display\n const displayUrl = url.length > 50 ? url.substring(0, 50) + '...' : url;\n return `<a href=\"${href}\" target=\"_blank\" rel=\"noopener noreferrer\" style=\"color: #2196f3; text-decoration: underline; font-size: inherit;\">${displayUrl}</a>`;\n });\n \n // Line breaks\n html = html.replace(/\\n/g, '<br>');\n \n // Lists\n html = html.replace(/^\\* (.+)$/gim, '<li>$1</li>');\n html = html.replace(/(<li>.*<\\/li>)/s, '<ul>$1</ul>');\n \n // Code blocks\n html = html.replace(/```(.*?)```/gs, '<pre><code>$1</code></pre>');\n \n // Inline code\n html = html.replace(/`([^`]+)`/g, '<code>$1</code>');\n \n return html;\n }\n \n /**\n * Append new live steps without re-rendering entire tree\n */\n private appendNewLiveSteps(newSteps: MJAIAgentRunStepEntityExtended[]): void {\n if (!newSteps || newSteps.length === 0 || !this.viewInitialized || !this.executionNodesContainer) {\n return;\n }\n \n console.log('📝 Appending', newSteps.length, 'live steps');\n \n // Sort steps by StepNumber\n const sortedSteps = [...newSteps].sort((a, b) => (a.StepNumber || 0) - (b.StepNumber || 0));\n \n // Mark previously new steps as completed\n if (this.newlyAddedNodeIds.size > 0) {\n this.markPreviouslyNewNodesAsComplete();\n this.newlyAddedNodeIds.clear();\n }\n \n let hasNewSteps = false;\n \n for (const step of sortedSteps) {\n // Skip if already processed\n if (this.processedStepIds.has(step.ID)) {\n // Update existing step if status changed\n const componentRef = this.nodeComponentMap.get(step.ID);\n if (componentRef && componentRef.instance.step.Status !== step.Status) {\n componentRef.instance.step = step;\n componentRef.changeDetectorRef.detectChanges();\n }\n continue;\n }\n \n // Mark as processed and newly added\n this.processedStepIds.add(step.ID);\n this.newlyAddedNodeIds.add(step.ID);\n hasNewSteps = true;\n \n // Determine depth based on parent hierarchy\n const depth = this.calculateStepDepth(step);\n const agentPath = this.buildAgentPath(step);\n \n // Create component for new step\n this.createStepComponent(step, depth, agentPath);\n \n // Handle sub-agent steps recursively\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps) {\n const subAgentPath = [...agentPath, step.SubAgentRun.Agent || 'Sub-Agent'];\n this.renderSteps(step.SubAgentRun.Steps, depth + 1, subAgentPath);\n }\n }\n \n if (hasNewSteps) {\n // After processing all new steps, ensure only the last one shows as running\n this.ensureOnlyLastStepIsRunning();\n \n this.updateCurrentStep();\n this.calculateStats();\n \n // Force change detection to ensure new components are rendered\n this.cdr.detectChanges();\n \n // Auto-scroll if user hasn't interacted\n setTimeout(() => {\n this.autoScrollToBottom();\n }, 100);\n }\n }\n \n /**\n * Calculate step depth based on parent hierarchy\n */\n private calculateStepDepth(step: MJAIAgentRunStepEntityExtended): number {\n // For now, return 0 for top-level steps\n // In live mode, depth information should come from the streaming data\n return 0;\n }\n \n /**\n * Build agent path for a step\n */\n private buildAgentPath(step: MJAIAgentRunStepEntityExtended): string[] {\n // In live mode, agent path should come from streaming data\n // For now, return empty array\n return [];\n }\n \n \n /**\n * Check if execution is complete\n */\n isExecutionComplete(): boolean {\n return this.stats.completedSteps > 0 && \n this.stats.completedSteps === this.stats.totalSteps - this.stats.failedSteps;\n }\n \n /**\n * Handle view run button click\n */\n onViewRunClick(): void {\n if (this.agentRun) {\n this.viewRunClick.emit({ runId: this.agentRun.ID, runType: 'agent' });\n }\n }\n \n \n /**\n * Expands all nodes that have sub-agent children\n */\n private expandAllNodes(): void {\n console.log('🔄 Auto-expanding nodes with sub-agents');\n \n // Expand all steps that have sub-agent runs\n this.nodeComponentMap.forEach((componentRef, stepId) => {\n const step = componentRef.instance.step;\n if (step.StepType === 'Sub-Agent' && step.SubAgentRun?.Steps?.length) {\n this.expandedStates.set(stepId, true);\n componentRef.instance.expanded = true;\n componentRef.changeDetectorRef.detectChanges();\n console.log(`Expanded sub-agent: ${step.StepName}`);\n }\n });\n \n // Trigger change detection\n this.cdr.markForCheck();\n this.cdr.detectChanges();\n \n // Scroll to top after expansion\n setTimeout(() => {\n this.scrollToTop();\n }, 100);\n }\n \n /**\n * Scroll the execution tree to the top\n */\n private scrollToTop(): void {\n if (this.executionTreeContainer) {\n const element = this.executionTreeContainer.nativeElement;\n element.scrollTo({\n top: 0,\n behavior: 'smooth'\n });\n }\n }\n \n /**\n * Check if there is content to display\n */\n hasContent(): boolean {\n return this.nodeComponentMap.size > 0;\n }\n}"]}
|
|
@@ -528,7 +528,7 @@ export class ExecutionNodeComponent {
|
|
|
528
528
|
i0.ɵɵconditional(ctx.hasNodeDetails() ? 20 : -1);
|
|
529
529
|
i0.ɵɵadvance();
|
|
530
530
|
i0.ɵɵconditional(ctx.detailsExpanded ? 21 : -1);
|
|
531
|
-
} }, styles: ["[_nghost-%COMP%] {\n display: block;\n width: 100%;\n }\n \n \n\n .tree-node[_ngcontent-%COMP%] {\n margin: 4px 0;\n position: relative;\n }\n \n \n\n .depth-0[_ngcontent-%COMP%] { \n margin-left: 0;\n position: relative;\n z-index: 2;\n }\n .depth-0[_ngcontent-%COMP%]::after {\n display: none;\n }\n .depth-0[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n border: 2px solid var(--mj-border-default);\n font-weight: 600;\n position: relative;\n z-index: 10;\n }\n\n \n\n .depth-1[_ngcontent-%COMP%] {\n margin-left: 24px;\n }\n .depth-1[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n border-color: var(--mj-border-default);\n }\n\n .depth-2[_ngcontent-%COMP%] {\n margin-left: 48px;\n }\n .depth-2[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-default);\n }\n\n .depth-3[_ngcontent-%COMP%] {\n margin-left: 72px;\n }\n .depth-3[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n .depth-4[_ngcontent-%COMP%] {\n margin-left: 96px;\n }\n .depth-4[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n .depth-5[_ngcontent-%COMP%] {\n margin-left: 120px;\n }\n .depth-5[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n .depth-6[_ngcontent-%COMP%] {\n margin-left: 144px;\n }\n .depth-6[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n \n\n .depth-0[_ngcontent-%COMP%] { \n position: relative;\n overflow: hidden;\n z-index: 2;\n }\n .depth-0[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n position: relative;\n z-index: 2;\n }\n\n \n\n .depth-0.has-children[_ngcontent-%COMP%]::before {\n content: '';\n position: absolute;\n left: 12px;\n top: 0;\n width: 2px;\n height: 100%;\n border-left: 2px dotted var(--mj-border-strong);\n z-index: 0; \n\n }\n\n \n\n .depth-1[_ngcontent-%COMP%] {\n margin-left: 30px;\n padding-left: 12px;\n position: relative;\n z-index: 1;\n }\n .depth-1[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n position: relative;\n z-index: 1;\n }\n\n \n\n .depth-1[_ngcontent-%COMP%]::after {\n content: '';\n position: absolute;\n left: -15px;\n top: 12px;\n width: 25px;\n height: 2px;\n border-bottom: 2px dotted var(--mj-border-strong);\n z-index: 1;\n }\n\n \n\n .tree-node.details-expanded[_ngcontent-%COMP%] > .node-header[_ngcontent-%COMP%] {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n border-bottom: 1px solid var(--mj-brand-primary);\n }\n\n .node-header[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 8px 12px;\n border: 1px solid var(--mj-border-default);\n border-radius: 6px;\n transition: all 0.2s ease;\n user-select: none;\n position: relative;\n z-index: 5;\n background: var(--mj-bg-surface);\n }\n\n .node-header[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n border-color: var(--mj-brand-primary) !important;\n }\n\n \n\n .tree-node.type-sub-agent[_ngcontent-%COMP%] > .node-header[_ngcontent-%COMP%] {\n border-left: 4px solid var(--mj-brand-primary);\n }\n\n \n\n .tree-node.type-action[_ngcontent-%COMP%] > .node-header[_ngcontent-%COMP%] {\n border-left: 4px solid var(--mj-status-success);\n }\n \n .expand-icon[_ngcontent-%COMP%] {\n width: 20px;\n height: 20px;\n display: flex;\n align-items: center;\n justify-content: center;\n text-align: center;\n color: var(--mj-text-secondary);\n font-size: 10px;\n cursor: pointer;\n border-radius: 3px;\n transition: all 0.2s ease;\n z-index: 10; \n\n position: relative;\n }\n\n .expand-icon[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n }\n\n .status-icon[_ngcontent-%COMP%] {\n width: 20px;\n text-align: center;\n font-size: 14px;\n }\n\n .status-pending[_ngcontent-%COMP%] { color: var(--mj-text-muted); }\n .status-running[_ngcontent-%COMP%] { color: var(--mj-brand-primary); }\n .status-completed[_ngcontent-%COMP%] { color: var(--mj-status-success); }\n .status-failed[_ngcontent-%COMP%] { color: var(--mj-status-error); }\n\n .type-icon[_ngcontent-%COMP%] {\n width: 20px;\n text-align: center;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 14px;\n color: var(--mj-text-secondary);\n }\n \n .agent-logo-icon[_ngcontent-%COMP%] {\n width: 16px;\n height: 16px;\n object-fit: cover;\n border-radius: 3px;\n }\n \n .node-name[_ngcontent-%COMP%] {\n flex: 1;\n font-size: 13px;\n font-weight: 500;\n color: var(--mj-text-primary);\n }\n\n\n .node-duration[_ngcontent-%COMP%] {\n font-size: 12px;\n color: var(--mj-text-secondary);\n font-weight: 500;\n }\n\n .node-metrics[_ngcontent-%COMP%] {\n display: flex;\n gap: 12px;\n font-size: 12px;\n }\n\n .tokens[_ngcontent-%COMP%] {\n color: var(--mj-text-secondary);\n }\n\n .cost[_ngcontent-%COMP%] {\n color: var(--mj-brand-primary);\n font-weight: 500;\n }\n\n \n\n .details-toggle-btn[_ngcontent-%COMP%] {\n width: 28px;\n height: 28px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: transparent;\n border: 1px solid var(--mj-border-default);\n border-radius: 4px;\n cursor: pointer;\n transition: all 0.2s ease;\n font-size: 12px;\n color: var(--mj-text-secondary);\n margin-left: 4px;\n }\n\n .details-toggle-btn[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n border-color: var(--mj-brand-primary);\n color: var(--mj-brand-primary);\n }\n\n .details-toggle-btn[_ngcontent-%COMP%]:active {\n background: color-mix(in srgb, var(--mj-brand-primary) 12%, var(--mj-bg-surface));\n }\n\n \n\n .tree-node.details-expanded[_ngcontent-%COMP%] .details-toggle-btn[_ngcontent-%COMP%] {\n background: var(--mj-brand-primary);\n border-color: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n }\n\n .tree-node.details-expanded[_ngcontent-%COMP%] .details-toggle-btn[_ngcontent-%COMP%]:hover {\n background: var(--mj-brand-primary-hover);\n border-color: var(--mj-brand-primary-hover);\n }\n\n .node-details[_ngcontent-%COMP%] {\n margin: 0 5px;\n padding: 16px;\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n border-top: none;\n border-radius: 0 0 6px 6px;\n font-size: 12px;\n position: relative;\n z-index: 4;\n }\n \n .detail-section[_ngcontent-%COMP%] {\n margin-bottom: 8px;\n }\n \n .detail-section[_ngcontent-%COMP%]:last-child {\n margin-bottom: 0;\n }\n \n .detail-section.error[_ngcontent-%COMP%] {\n color: var(--mj-status-error-text);\n }\n\n .detail-label[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n font-weight: 600;\n margin-bottom: 4px;\n color: var(--mj-text-secondary);\n }\n\n .detail-content[_ngcontent-%COMP%] {\n white-space: pre-wrap;\n word-break: break-word;\n color: var(--mj-text-primary);\n line-height: 1.4;\n }\n\n .markdown-details[_ngcontent-%COMP%] {\n padding: 16px 16px 0 16px;\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n border-bottom: none;\n border-top: none;\n margin: 0 5px;\n }\n\n .markdown[_ngcontent-%COMP%] h3[_ngcontent-%COMP%], .markdown[_ngcontent-%COMP%] h4[_ngcontent-%COMP%] {\n margin: 8px 0 4px 0;\n color: var(--mj-text-primary);\n }\n \n .markdown[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] {\n font-size: 14px;\n }\n \n .markdown[_ngcontent-%COMP%] h4[_ngcontent-%COMP%] {\n font-size: 13px;\n }\n \n .markdown[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] {\n margin: 4px 0;\n padding-left: 20px;\n }\n \n .markdown[_ngcontent-%COMP%] li[_ngcontent-%COMP%] {\n margin: 2px 0;\n }\n \n .markdown[_ngcontent-%COMP%] code[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-sunken);\n padding: 1px 4px;\n border-radius: 3px;\n font-size: 12px;\n }\n\n .markdown[_ngcontent-%COMP%] pre[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-sunken);\n padding: 8px;\n border-radius: 4px;\n overflow-x: auto;\n margin: 4px 0;\n }\n\n .markdown[_ngcontent-%COMP%] pre[_ngcontent-%COMP%] code[_ngcontent-%COMP%] {\n background: none;\n padding: 0;\n }\n\n .markdown[_ngcontent-%COMP%] strong[_ngcontent-%COMP%] {\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n\n .markdown[_ngcontent-%COMP%] em[_ngcontent-%COMP%] {\n font-style: italic;\n color: var(--mj-text-secondary);\n }\n\n .full-name[_ngcontent-%COMP%] {\n font-weight: 600;\n color: var(--mj-text-primary);\n padding-bottom: 8px;\n border-bottom: 1px solid var(--mj-border-default);\n word-wrap: break-word;\n }"], changeDetection: 0 }); }
|
|
531
|
+
} }, styles: ["[_nghost-%COMP%] {\n display: block;\n width: 100%;\n }\n \n \n .tree-node[_ngcontent-%COMP%] {\n margin: 4px 0;\n position: relative;\n }\n \n \n .depth-0[_ngcontent-%COMP%] { \n margin-left: 0;\n position: relative;\n z-index: 2;\n }\n .depth-0[_ngcontent-%COMP%]::after {\n display: none;\n }\n .depth-0[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n border: 2px solid var(--mj-border-default);\n font-weight: 600;\n position: relative;\n z-index: 10;\n }\n\n \n .depth-1[_ngcontent-%COMP%] {\n margin-left: 24px;\n }\n .depth-1[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n border-color: var(--mj-border-default);\n }\n\n .depth-2[_ngcontent-%COMP%] {\n margin-left: 48px;\n }\n .depth-2[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-default);\n }\n\n .depth-3[_ngcontent-%COMP%] {\n margin-left: 72px;\n }\n .depth-3[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n .depth-4[_ngcontent-%COMP%] {\n margin-left: 96px;\n }\n .depth-4[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n .depth-5[_ngcontent-%COMP%] {\n margin-left: 120px;\n }\n .depth-5[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n .depth-6[_ngcontent-%COMP%] {\n margin-left: 144px;\n }\n .depth-6[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface);\n border-color: var(--mj-border-strong);\n }\n\n \n .depth-0[_ngcontent-%COMP%] { \n position: relative;\n overflow: hidden;\n z-index: 2;\n }\n .depth-0[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n position: relative;\n z-index: 2;\n }\n\n \n .depth-0.has-children[_ngcontent-%COMP%]::before {\n content: '';\n position: absolute;\n left: 12px;\n top: 0;\n width: 2px;\n height: 100%;\n border-left: 2px dotted var(--mj-border-strong);\n z-index: 0; \n }\n\n \n .depth-1[_ngcontent-%COMP%] {\n margin-left: 30px;\n padding-left: 12px;\n position: relative;\n z-index: 1;\n }\n .depth-1[_ngcontent-%COMP%] .node-header[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-card);\n position: relative;\n z-index: 1;\n }\n\n \n .depth-1[_ngcontent-%COMP%]::after {\n content: '';\n position: absolute;\n left: -15px;\n top: 12px;\n width: 25px;\n height: 2px;\n border-bottom: 2px dotted var(--mj-border-strong);\n z-index: 1;\n }\n\n \n .tree-node.details-expanded[_ngcontent-%COMP%] > .node-header[_ngcontent-%COMP%] {\n border-bottom-left-radius: 0;\n border-bottom-right-radius: 0;\n border-bottom: 1px solid var(--mj-brand-primary);\n }\n\n .node-header[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 8px;\n padding: 8px 12px;\n border: 1px solid var(--mj-border-default);\n border-radius: 6px;\n transition: all 0.2s ease;\n user-select: none;\n position: relative;\n z-index: 5;\n background: var(--mj-bg-surface);\n }\n\n .node-header[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n border-color: var(--mj-brand-primary) !important;\n }\n\n \n .tree-node.type-sub-agent[_ngcontent-%COMP%] > .node-header[_ngcontent-%COMP%] {\n border-left: 4px solid var(--mj-brand-primary);\n }\n\n \n .tree-node.type-action[_ngcontent-%COMP%] > .node-header[_ngcontent-%COMP%] {\n border-left: 4px solid var(--mj-status-success);\n }\n \n .expand-icon[_ngcontent-%COMP%] {\n width: 20px;\n height: 20px;\n display: flex;\n align-items: center;\n justify-content: center;\n text-align: center;\n color: var(--mj-text-secondary);\n font-size: 10px;\n cursor: pointer;\n border-radius: 3px;\n transition: all 0.2s ease;\n z-index: 10; \n position: relative;\n }\n\n .expand-icon[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n color: var(--mj-text-primary);\n }\n\n .status-icon[_ngcontent-%COMP%] {\n width: 20px;\n text-align: center;\n font-size: 14px;\n }\n\n .status-pending[_ngcontent-%COMP%] { color: var(--mj-text-muted); }\n .status-running[_ngcontent-%COMP%] { color: var(--mj-brand-primary); }\n .status-completed[_ngcontent-%COMP%] { color: var(--mj-status-success); }\n .status-failed[_ngcontent-%COMP%] { color: var(--mj-status-error); }\n\n .type-icon[_ngcontent-%COMP%] {\n width: 20px;\n text-align: center;\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 14px;\n color: var(--mj-text-secondary);\n }\n \n .agent-logo-icon[_ngcontent-%COMP%] {\n width: 16px;\n height: 16px;\n object-fit: cover;\n border-radius: 3px;\n }\n \n .node-name[_ngcontent-%COMP%] {\n flex: 1;\n font-size: 13px;\n font-weight: 500;\n color: var(--mj-text-primary);\n }\n\n\n .node-duration[_ngcontent-%COMP%] {\n font-size: 12px;\n color: var(--mj-text-secondary);\n font-weight: 500;\n }\n\n .node-metrics[_ngcontent-%COMP%] {\n display: flex;\n gap: 12px;\n font-size: 12px;\n }\n\n .tokens[_ngcontent-%COMP%] {\n color: var(--mj-text-secondary);\n }\n\n .cost[_ngcontent-%COMP%] {\n color: var(--mj-brand-primary);\n font-weight: 500;\n }\n\n \n .details-toggle-btn[_ngcontent-%COMP%] {\n width: 28px;\n height: 28px;\n display: flex;\n align-items: center;\n justify-content: center;\n background: transparent;\n border: 1px solid var(--mj-border-default);\n border-radius: 4px;\n cursor: pointer;\n transition: all 0.2s ease;\n font-size: 12px;\n color: var(--mj-text-secondary);\n margin-left: 4px;\n }\n\n .details-toggle-btn[_ngcontent-%COMP%]:hover {\n background: var(--mj-bg-surface-hover);\n border-color: var(--mj-brand-primary);\n color: var(--mj-brand-primary);\n }\n\n .details-toggle-btn[_ngcontent-%COMP%]:active {\n background: color-mix(in srgb, var(--mj-brand-primary) 12%, var(--mj-bg-surface));\n }\n\n \n .tree-node.details-expanded[_ngcontent-%COMP%] .details-toggle-btn[_ngcontent-%COMP%] {\n background: var(--mj-brand-primary);\n border-color: var(--mj-brand-primary);\n color: var(--mj-text-inverse);\n }\n\n .tree-node.details-expanded[_ngcontent-%COMP%] .details-toggle-btn[_ngcontent-%COMP%]:hover {\n background: var(--mj-brand-primary-hover);\n border-color: var(--mj-brand-primary-hover);\n }\n\n .node-details[_ngcontent-%COMP%] {\n margin: 0 5px;\n padding: 16px;\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n border-top: none;\n border-radius: 0 0 6px 6px;\n font-size: 12px;\n position: relative;\n z-index: 4;\n }\n \n .detail-section[_ngcontent-%COMP%] {\n margin-bottom: 8px;\n }\n \n .detail-section[_ngcontent-%COMP%]:last-child {\n margin-bottom: 0;\n }\n \n .detail-section.error[_ngcontent-%COMP%] {\n color: var(--mj-status-error-text);\n }\n\n .detail-label[_ngcontent-%COMP%] {\n display: flex;\n align-items: center;\n gap: 6px;\n font-weight: 600;\n margin-bottom: 4px;\n color: var(--mj-text-secondary);\n }\n\n .detail-content[_ngcontent-%COMP%] {\n white-space: pre-wrap;\n word-break: break-word;\n color: var(--mj-text-primary);\n line-height: 1.4;\n }\n\n .markdown-details[_ngcontent-%COMP%] {\n padding: 16px 16px 0 16px;\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n border-bottom: none;\n border-top: none;\n margin: 0 5px;\n }\n\n .markdown[_ngcontent-%COMP%] h3[_ngcontent-%COMP%], .markdown[_ngcontent-%COMP%] h4[_ngcontent-%COMP%] {\n margin: 8px 0 4px 0;\n color: var(--mj-text-primary);\n }\n \n .markdown[_ngcontent-%COMP%] h3[_ngcontent-%COMP%] {\n font-size: 14px;\n }\n \n .markdown[_ngcontent-%COMP%] h4[_ngcontent-%COMP%] {\n font-size: 13px;\n }\n \n .markdown[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] {\n margin: 4px 0;\n padding-left: 20px;\n }\n \n .markdown[_ngcontent-%COMP%] li[_ngcontent-%COMP%] {\n margin: 2px 0;\n }\n \n .markdown[_ngcontent-%COMP%] code[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-sunken);\n padding: 1px 4px;\n border-radius: 3px;\n font-size: 12px;\n }\n\n .markdown[_ngcontent-%COMP%] pre[_ngcontent-%COMP%] {\n background: var(--mj-bg-surface-sunken);\n padding: 8px;\n border-radius: 4px;\n overflow-x: auto;\n margin: 4px 0;\n }\n\n .markdown[_ngcontent-%COMP%] pre[_ngcontent-%COMP%] code[_ngcontent-%COMP%] {\n background: none;\n padding: 0;\n }\n\n .markdown[_ngcontent-%COMP%] strong[_ngcontent-%COMP%] {\n font-weight: 600;\n color: var(--mj-text-primary);\n }\n\n .markdown[_ngcontent-%COMP%] em[_ngcontent-%COMP%] {\n font-style: italic;\n color: var(--mj-text-secondary);\n }\n\n .full-name[_ngcontent-%COMP%] {\n font-weight: 600;\n color: var(--mj-text-primary);\n padding-bottom: 8px;\n border-bottom: 1px solid var(--mj-border-default);\n word-wrap: break-word;\n }"], changeDetection: 0 }); }
|
|
532
532
|
}
|
|
533
533
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(ExecutionNodeComponent, [{
|
|
534
534
|
type: Component,
|
|
@@ -280,12 +280,11 @@ export class AITestHarnessDialogComponent extends BaseAngularComponent {
|
|
|
280
280
|
let _t;
|
|
281
281
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.testHarness = _t.first);
|
|
282
282
|
} }, inputs: { data: "data" }, outputs: { closeDialog: "closeDialog" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 9, vars: 4, consts: [["testHarness", ""], [1, "test-harness-dialog"], [1, "dialog-header"], [1, "close-button", 3, "click"], [1, "fa-solid", "fa-times"], [1, "dialog-content"], [3, "mode", "entity", "isVisible"]], template: function AITestHarnessDialogComponent_Template(rf, ctx) { if (rf & 1) {
|
|
283
|
-
const _r1 = i0.ɵɵgetCurrentView();
|
|
284
283
|
i0.ɵɵelementStart(0, "div", 1)(1, "div", 2)(2, "h2");
|
|
285
284
|
i0.ɵɵtext(3);
|
|
286
285
|
i0.ɵɵelementEnd();
|
|
287
286
|
i0.ɵɵelementStart(4, "button", 3);
|
|
288
|
-
i0.ɵɵlistener("click", function AITestHarnessDialogComponent_Template_button_click_4_listener() {
|
|
287
|
+
i0.ɵɵlistener("click", function AITestHarnessDialogComponent_Template_button_click_4_listener() { return ctx.close(); });
|
|
289
288
|
i0.ɵɵelement(5, "i", 4);
|
|
290
289
|
i0.ɵɵelementEnd()();
|
|
291
290
|
i0.ɵɵelementStart(6, "div", 5);
|