@memberjunction/ng-task-graph-editor 6.1.0-edge.2 → 6.1.0-edge.3
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/LICENSE +180 -4
- package/README.md +197 -0
- package/dist/lib/debug-variables.d.ts +27 -0
- package/dist/lib/debug-variables.d.ts.map +1 -0
- package/dist/lib/debug-variables.js +96 -0
- package/dist/lib/debug-variables.js.map +1 -0
- package/dist/lib/pane-split.d.ts +11 -0
- package/dist/lib/pane-split.d.ts.map +1 -0
- package/dist/lib/pane-split.js +36 -0
- package/dist/lib/pane-split.js.map +1 -0
- package/dist/lib/task-graph-canvas-adapter.d.ts +41 -3
- package/dist/lib/task-graph-canvas-adapter.d.ts.map +1 -1
- package/dist/lib/task-graph-canvas-adapter.js +175 -36
- package/dist/lib/task-graph-canvas-adapter.js.map +1 -1
- package/dist/lib/task-graph-debug-toolbar.component.d.ts +27 -0
- package/dist/lib/task-graph-debug-toolbar.component.d.ts.map +1 -0
- package/dist/lib/task-graph-debug-toolbar.component.js +153 -0
- package/dist/lib/task-graph-debug-toolbar.component.js.map +1 -0
- package/dist/lib/task-graph-debugger.component.d.ts +96 -0
- package/dist/lib/task-graph-debugger.component.d.ts.map +1 -0
- package/dist/lib/task-graph-debugger.component.js +371 -0
- package/dist/lib/task-graph-debugger.component.js.map +1 -0
- package/dist/lib/task-graph-editor.component.d.ts +40 -3
- package/dist/lib/task-graph-editor.component.d.ts.map +1 -1
- package/dist/lib/task-graph-editor.component.js +83 -10
- package/dist/lib/task-graph-editor.component.js.map +1 -1
- package/dist/lib/task-graph-editor.module.d.ts +9 -5
- package/dist/lib/task-graph-editor.module.d.ts.map +1 -1
- package/dist/lib/task-graph-editor.module.js +52 -5
- package/dist/lib/task-graph-editor.module.js.map +1 -1
- package/dist/lib/task-graph-run-prefs.d.ts +34 -0
- package/dist/lib/task-graph-run-prefs.d.ts.map +1 -0
- package/dist/lib/task-graph-run-prefs.js +67 -0
- package/dist/lib/task-graph-run-prefs.js.map +1 -0
- package/dist/lib/task-graph-run-view.component.d.ts +180 -3
- package/dist/lib/task-graph-run-view.component.d.ts.map +1 -1
- package/dist/lib/task-graph-run-view.component.js +560 -23
- package/dist/lib/task-graph-run-view.component.js.map +1 -1
- package/dist/lib/task-graph-runtime-source.d.ts +7 -1
- package/dist/lib/task-graph-runtime-source.d.ts.map +1 -1
- package/dist/lib/task-graph-runtime-source.js +14 -2
- package/dist/lib/task-graph-runtime-source.js.map +1 -1
- package/dist/lib/task-graph-variables.component.d.ts +23 -0
- package/dist/lib/task-graph-variables.component.d.ts.map +1 -0
- package/dist/lib/task-graph-variables.component.js +192 -0
- package/dist/lib/task-graph-variables.component.js.map +1 -0
- package/dist/lib/workflow-debug-host.d.ts +23 -0
- package/dist/lib/workflow-debug-host.d.ts.map +1 -0
- package/dist/lib/workflow-debug-host.js +101 -0
- package/dist/lib/workflow-debug-host.js.map +1 -0
- package/dist/public-api.d.ts +7 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +7 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +11 -10
|
@@ -84,7 +84,7 @@ function TaskGraphEditorComponent_Conditional_2_Template(rf, ctx) { if (rf & 1)
|
|
|
84
84
|
i0.ɵɵconditionalCreate(0, TaskGraphEditorComponent_Conditional_2_Conditional_0_Template, 1, 1, "mj-alert", 2);
|
|
85
85
|
i0.ɵɵconditionalCreate(1, TaskGraphEditorComponent_Conditional_2_Conditional_1_Template, 6, 2, "mj-alert", 3);
|
|
86
86
|
i0.ɵɵelementStart(2, "div", 4)(3, "mj-flow-editor", 5);
|
|
87
|
-
i0.ɵɵlistener("NodeSelected", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeSelected_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeSelected($event)); })("NodeAdded", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeAdded_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeAdded($event)); })("NodeRemoved", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeRemoved_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeRemoved($event)); })("NodesChanged", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodesChanged_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodesChanged($event)); })("NodeMoved", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeMoved_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeMoved($event)); })("ConnectionCreated", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_ConnectionCreated_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnConnectionCreated($event)); })("ConnectionRemoved", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_ConnectionRemoved_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnConnectionRemoved($event)); });
|
|
87
|
+
i0.ɵɵlistener("NodeSelected", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeSelected_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeSelected($event)); })("NodeAdded", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeAdded_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeAdded($event)); })("NodeRemoved", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeRemoved_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeRemoved($event)); })("NodesChanged", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodesChanged_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodesChanged($event)); })("NodeMoved", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_NodeMoved_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnNodeMoved($event)); })("ConnectionCreated", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_ConnectionCreated_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnConnectionCreated($event)); })("ConnectionRemoved", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_ConnectionRemoved_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnConnectionRemoved($event)); })("ConnectionSelected", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_ConnectionSelected_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnConnectionSelected($event)); })("LegendToggled", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_LegendToggled_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.OnLegendToggled($event)); })("BeforeContextMenu", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_BeforeContextMenu_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.BeforeContextMenu.emit($event)); })("AfterContextMenuAction", function TaskGraphEditorComponent_Conditional_2_Template_mj_flow_editor_AfterContextMenuAction_3_listener($event) { i0.ɵɵrestoreView(_r2); const ctx_r0 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r0.AfterContextMenuAction.emit($event)); });
|
|
88
88
|
i0.ɵɵelementEnd();
|
|
89
89
|
i0.ɵɵconditionalCreate(4, TaskGraphEditorComponent_Conditional_2_Conditional_4_Template, 1, 5, "mj-task-graph-properties", 6);
|
|
90
90
|
i0.ɵɵelementEnd();
|
|
@@ -94,7 +94,7 @@ function TaskGraphEditorComponent_Conditional_2_Template(rf, ctx) { if (rf & 1)
|
|
|
94
94
|
i0.ɵɵadvance();
|
|
95
95
|
i0.ɵɵconditional(!ctx_r0.IsValid && ctx_r0.ValidationErrors.length > 0 ? 1 : -1);
|
|
96
96
|
i0.ɵɵadvance(2);
|
|
97
|
-
i0.ɵɵproperty("Nodes", ctx_r0.Nodes)("Connections", ctx_r0.Connections)("NodeTypes", ctx_r0.NodeTypes)("ReadOnly", ctx_r0.ReadOnly)("ShowToolbar", ctx_r0.ShowToolbar)("ShowPalette", ctx_r0.ShowPalette && !ctx_r0.ReadOnly)("ShowMinimap", ctx_r0.ShowMinimap)("ShowStatusBar", ctx_r0.ShowStatusBar)("AutoLayoutDirection", ctx_r0.AutoLayoutDirection);
|
|
97
|
+
i0.ɵɵproperty("Nodes", ctx_r0.Nodes)("Connections", ctx_r0.Connections)("NodeTypes", ctx_r0.NodeTypes)("ReadOnly", ctx_r0.ReadOnly)("ShowToolbar", ctx_r0.ShowToolbar)("ToolbarVisibility", ctx_r0.ToolbarVisibility)("ToolbarAlign", ctx_r0.ToolbarAlign)("ShowPalette", ctx_r0.ShowPalette && !ctx_r0.ReadOnly)("ShowMinimap", ctx_r0.ShowMinimap)("ShowLegend", ctx_r0.ShowLegend)("ShowStatusBar", ctx_r0.ShowStatusBar)("AutoLayoutDirection", ctx_r0.AutoLayoutDirection);
|
|
98
98
|
i0.ɵɵadvance();
|
|
99
99
|
i0.ɵɵconditional(ctx_r0.ShowProperties && !ctx_r0.ReadOnly ? 4 : -1);
|
|
100
100
|
} }
|
|
@@ -142,18 +142,37 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
142
142
|
set NodePositions(value) {
|
|
143
143
|
if (!value || value.size === 0)
|
|
144
144
|
return;
|
|
145
|
+
const key = [...value.keys()].sort().join(',');
|
|
146
|
+
const firstForThisGraph = this.fittedGeometryKey !== key;
|
|
145
147
|
for (const [id, position] of value)
|
|
146
148
|
this.knownPositions.set(id, { ...position });
|
|
147
149
|
// Real geometry means the one-time Dagre pass has nothing to rescue.
|
|
148
150
|
this.hasLaidOut = true;
|
|
149
151
|
this.project();
|
|
150
|
-
|
|
152
|
+
// Fit once per graph. Live status / poll re-supplies the same positions as a new Map,
|
|
153
|
+
// and fitting on every write snaps the viewport back while the person is zooming.
|
|
154
|
+
if (firstForThisGraph) {
|
|
155
|
+
this.fittedGeometryKey = key;
|
|
156
|
+
this.zoomToFitSoon();
|
|
157
|
+
}
|
|
151
158
|
}
|
|
152
159
|
/** Read-only mode. The same component is the viewer — there is no second, weaker renderer. */
|
|
153
160
|
ReadOnly = false;
|
|
154
161
|
ShowToolbar = true;
|
|
162
|
+
/** Full bar / chip / recover tab. Run views default this to minimized. */
|
|
163
|
+
ToolbarVisibility = 'shown';
|
|
164
|
+
ToolbarAlign = 'center';
|
|
155
165
|
ShowPalette = true;
|
|
156
166
|
ShowMinimap = true;
|
|
167
|
+
/**
|
|
168
|
+
* Whether the legend rides on the canvas.
|
|
169
|
+
*
|
|
170
|
+
* On for authoring, off for a run — and the difference is what the legend is FOR. It explains the
|
|
171
|
+
* authoring vocabulary (what a conditional edge means, what a duplicate default looks like),
|
|
172
|
+
* which is what someone drawing a graph needs. A run view is answering a different question —
|
|
173
|
+
* what happened — and the legend answers none of it while occluding a third of the canvas.
|
|
174
|
+
*/
|
|
175
|
+
ShowLegend = true;
|
|
157
176
|
ShowStatusBar = true;
|
|
158
177
|
AutoLayoutDirection = 'vertical';
|
|
159
178
|
/**
|
|
@@ -174,6 +193,19 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
174
193
|
AvailableActionNames = [];
|
|
175
194
|
/** Shown when there is nothing to draw yet. */
|
|
176
195
|
EmptyStateMessage = 'No steps yet. Add one to start building this workflow.';
|
|
196
|
+
/**
|
|
197
|
+
* Debug overlay for a run. Empty by default so an embed (agent-run timeline, test harness)
|
|
198
|
+
* never grows breakpoint badges or override styling it did not ask for.
|
|
199
|
+
*/
|
|
200
|
+
set DebugOverlay(value) {
|
|
201
|
+
if (this.debugOverlay === value)
|
|
202
|
+
return;
|
|
203
|
+
this.debugOverlay = value;
|
|
204
|
+
this.project();
|
|
205
|
+
}
|
|
206
|
+
get DebugOverlay() {
|
|
207
|
+
return this.debugOverlay;
|
|
208
|
+
}
|
|
177
209
|
// ── Outputs ──────────────────────────────────────────────────────────────
|
|
178
210
|
BeforeTaskAdded = new EventEmitter();
|
|
179
211
|
AfterTaskAdded = new EventEmitter();
|
|
@@ -186,12 +218,25 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
186
218
|
BeforeDependencyRemoved = new EventEmitter();
|
|
187
219
|
AfterDependencyRemoved = new EventEmitter();
|
|
188
220
|
/** Informational — no `Before` pair, because these report what already happened. */
|
|
221
|
+
/**
|
|
222
|
+
* The legend was shown or hidden from the canvas toolbar.
|
|
223
|
+
*
|
|
224
|
+
* Forwarded so a host can PERSIST the choice. Without it the toolbar's toggle mutates the
|
|
225
|
+
* canvas's own flag and nothing else, so the preference dies with the view — and a host that
|
|
226
|
+
* wanted it remembered would have to add a second control beside the one that already exists,
|
|
227
|
+
* which is how a surface ends up with two buttons doing the same thing and disagreeing.
|
|
228
|
+
*/
|
|
229
|
+
LegendToggled = new EventEmitter();
|
|
189
230
|
SpecChanged = new EventEmitter();
|
|
190
231
|
SelectionChanged = new EventEmitter();
|
|
191
232
|
ValidationChanged = new EventEmitter();
|
|
192
233
|
/** Intent-only — the host navigates; this widget has no Router and must not acquire one. */
|
|
193
234
|
AgentOpenRequested = new EventEmitter();
|
|
194
235
|
RecordOpenRequested = new EventEmitter();
|
|
236
|
+
/** A connection was clicked. Payload is the canvas connection, or null when cleared. */
|
|
237
|
+
ConnectionSelected = new EventEmitter();
|
|
238
|
+
BeforeContextMenu = new EventEmitter();
|
|
239
|
+
AfterContextMenuAction = new EventEmitter();
|
|
195
240
|
// ── Rendered state ───────────────────────────────────────────────────────
|
|
196
241
|
Nodes = [];
|
|
197
242
|
Connections = [];
|
|
@@ -202,6 +247,7 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
202
247
|
canvas;
|
|
203
248
|
currentSpec = null;
|
|
204
249
|
currentRuntime = null;
|
|
250
|
+
debugOverlay = null;
|
|
205
251
|
get IsEmpty() {
|
|
206
252
|
return (this.currentSpec?.tasks?.length ?? 0) === 0;
|
|
207
253
|
}
|
|
@@ -421,11 +467,12 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
421
467
|
this.ValidationErrors = [];
|
|
422
468
|
this.IsValid = true;
|
|
423
469
|
this.hasLaidOut = false;
|
|
470
|
+
this.fittedGeometryKey = null;
|
|
424
471
|
this.knownPositions.clear();
|
|
425
472
|
return;
|
|
426
473
|
}
|
|
427
|
-
this.Nodes = SpecToNodes(this.currentSpec, this.currentRuntime ?? undefined, this.knownPositions);
|
|
428
|
-
this.Connections = SpecToConnections(this.currentSpec);
|
|
474
|
+
this.Nodes = SpecToNodes(this.currentSpec, this.currentRuntime ?? undefined, this.knownPositions, this.debugOverlay ?? undefined);
|
|
475
|
+
this.Connections = SpecToConnections(this.currentSpec, this.currentRuntime ?? undefined, this.debugOverlay ?? undefined);
|
|
429
476
|
this.Validate();
|
|
430
477
|
this.arrangeIfNeverLaidOut();
|
|
431
478
|
}
|
|
@@ -492,6 +539,14 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
492
539
|
for (const n of nodes)
|
|
493
540
|
this.knownPositions.set(n.ID, { ...n.Position });
|
|
494
541
|
}
|
|
542
|
+
/** The canvas toolbar showed or hid the legend; tell whoever is remembering that choice. */
|
|
543
|
+
OnLegendToggled(show) {
|
|
544
|
+
this.ShowLegend = show;
|
|
545
|
+
this.LegendToggled.emit(show);
|
|
546
|
+
}
|
|
547
|
+
OnConnectionSelected(connection) {
|
|
548
|
+
this.ConnectionSelected.emit(connection);
|
|
549
|
+
}
|
|
495
550
|
/** A single node was dragged. Same authority, narrower event. */
|
|
496
551
|
OnNodeMoved(event) {
|
|
497
552
|
this.knownPositions.set(event.NodeID, { ...event.NewPosition });
|
|
@@ -514,6 +569,8 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
514
569
|
knownPositions = new Map();
|
|
515
570
|
/** Whether the one-time Dagre pass has run (or been made unnecessary by a hand-placed node). */
|
|
516
571
|
hasLaidOut = false;
|
|
572
|
+
/** Task-id set we last fitted. Same ids + a new Map must not re-fit. */
|
|
573
|
+
fittedGeometryKey = null;
|
|
517
574
|
pendingLayout = null;
|
|
518
575
|
static ɵfac = /*@__PURE__*/ (() => { let ɵTaskGraphEditorComponent_BaseFactory; return function TaskGraphEditorComponent_Factory(__ngFactoryType__) { return (ɵTaskGraphEditorComponent_BaseFactory || (ɵTaskGraphEditorComponent_BaseFactory = i0.ɵɵgetInheritedFactory(TaskGraphEditorComponent)))(__ngFactoryType__ || TaskGraphEditorComponent); }; })();
|
|
519
576
|
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: TaskGraphEditorComponent, selectors: [["mj-task-graph-editor"]], viewQuery: function TaskGraphEditorComponent_Query(rf, ctx) { if (rf & 1) {
|
|
@@ -521,18 +578,18 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
521
578
|
} if (rf & 2) {
|
|
522
579
|
let _t;
|
|
523
580
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.canvas = _t.first);
|
|
524
|
-
} }, inputs: { Spec: "Spec", RuntimeStatus: "RuntimeStatus", NodePositions: "NodePositions", ReadOnly: "ReadOnly", ShowToolbar: "ShowToolbar", ShowPalette: "ShowPalette", ShowMinimap: "ShowMinimap", ShowStatusBar: "ShowStatusBar", AutoLayoutDirection: "AutoLayoutDirection", ShowProperties: "ShowProperties", AvailableAgentNames: "AvailableAgentNames", AvailableActionNames: "AvailableActionNames", EmptyStateMessage: "EmptyStateMessage" }, outputs: { BeforeTaskAdded: "BeforeTaskAdded", AfterTaskAdded: "AfterTaskAdded", BeforeTaskRemoved: "BeforeTaskRemoved", AfterTaskRemoved: "AfterTaskRemoved", BeforeTaskUpdated: "BeforeTaskUpdated", AfterTaskUpdated: "AfterTaskUpdated", BeforeDependencyAdded: "BeforeDependencyAdded", AfterDependencyAdded: "AfterDependencyAdded", BeforeDependencyRemoved: "BeforeDependencyRemoved", AfterDependencyRemoved: "AfterDependencyRemoved", SpecChanged: "SpecChanged", SelectionChanged: "SelectionChanged", ValidationChanged: "ValidationChanged", AgentOpenRequested: "AgentOpenRequested", RecordOpenRequested: "RecordOpenRequested" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 3, vars: 1, consts: [[1, "mj-tge"], ["Icon", "fa-diagram-project", "Title", "Nothing here yet", 3, "Message"], ["Variant", "info", 1, "mj-tge__empty-hint", 3, "Message"], ["Variant", "warning", 1, "mj-tge__validation"], [1, "mj-tge__workspace"], [1, "mj-tge__canvas", 3, "NodeSelected", "NodeAdded", "NodeRemoved", "NodesChanged", "NodeMoved", "ConnectionCreated", "ConnectionRemoved", "Nodes", "Connections", "NodeTypes", "ReadOnly", "ShowToolbar", "ShowPalette", "ShowMinimap", "ShowStatusBar", "AutoLayoutDirection"], [1, "mj-tge__properties", 3, "Task", "Spec", "ReadOnly", "AvailableAgentNames", "AvailableActionNames"], [1, "mj-tge__validation-list"], [1, "mj-tge__properties", 3, "TaskPropertyChangeRequested", "DependencyConditionChangeRequested", "Task", "Spec", "ReadOnly", "AvailableAgentNames", "AvailableActionNames"]], template: function TaskGraphEditorComponent_Template(rf, ctx) { if (rf & 1) {
|
|
581
|
+
} }, inputs: { Spec: "Spec", RuntimeStatus: "RuntimeStatus", NodePositions: "NodePositions", ReadOnly: "ReadOnly", ShowToolbar: "ShowToolbar", ToolbarVisibility: "ToolbarVisibility", ToolbarAlign: "ToolbarAlign", ShowPalette: "ShowPalette", ShowMinimap: "ShowMinimap", ShowLegend: "ShowLegend", ShowStatusBar: "ShowStatusBar", AutoLayoutDirection: "AutoLayoutDirection", ShowProperties: "ShowProperties", AvailableAgentNames: "AvailableAgentNames", AvailableActionNames: "AvailableActionNames", EmptyStateMessage: "EmptyStateMessage", DebugOverlay: "DebugOverlay" }, outputs: { BeforeTaskAdded: "BeforeTaskAdded", AfterTaskAdded: "AfterTaskAdded", BeforeTaskRemoved: "BeforeTaskRemoved", AfterTaskRemoved: "AfterTaskRemoved", BeforeTaskUpdated: "BeforeTaskUpdated", AfterTaskUpdated: "AfterTaskUpdated", BeforeDependencyAdded: "BeforeDependencyAdded", AfterDependencyAdded: "AfterDependencyAdded", BeforeDependencyRemoved: "BeforeDependencyRemoved", AfterDependencyRemoved: "AfterDependencyRemoved", LegendToggled: "LegendToggled", SpecChanged: "SpecChanged", SelectionChanged: "SelectionChanged", ValidationChanged: "ValidationChanged", AgentOpenRequested: "AgentOpenRequested", RecordOpenRequested: "RecordOpenRequested", ConnectionSelected: "ConnectionSelected", BeforeContextMenu: "BeforeContextMenu", AfterContextMenuAction: "AfterContextMenuAction" }, standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 3, vars: 1, consts: [[1, "mj-tge"], ["Icon", "fa-diagram-project", "Title", "Nothing here yet", 3, "Message"], ["Variant", "info", 1, "mj-tge__empty-hint", 3, "Message"], ["Variant", "warning", 1, "mj-tge__validation"], [1, "mj-tge__workspace"], [1, "mj-tge__canvas", 3, "NodeSelected", "NodeAdded", "NodeRemoved", "NodesChanged", "NodeMoved", "ConnectionCreated", "ConnectionRemoved", "ConnectionSelected", "LegendToggled", "BeforeContextMenu", "AfterContextMenuAction", "Nodes", "Connections", "NodeTypes", "ReadOnly", "ShowToolbar", "ToolbarVisibility", "ToolbarAlign", "ShowPalette", "ShowMinimap", "ShowLegend", "ShowStatusBar", "AutoLayoutDirection"], [1, "mj-tge__properties", 3, "Task", "Spec", "ReadOnly", "AvailableAgentNames", "AvailableActionNames"], [1, "mj-tge__validation-list"], [1, "mj-tge__properties", 3, "TaskPropertyChangeRequested", "DependencyConditionChangeRequested", "Task", "Spec", "ReadOnly", "AvailableAgentNames", "AvailableActionNames"]], template: function TaskGraphEditorComponent_Template(rf, ctx) { if (rf & 1) {
|
|
525
582
|
i0.ɵɵelementStart(0, "div", 0);
|
|
526
|
-
i0.ɵɵconditionalCreate(1, TaskGraphEditorComponent_Conditional_1_Template, 1, 1, "mj-empty-state", 1)(2, TaskGraphEditorComponent_Conditional_2_Template, 5,
|
|
583
|
+
i0.ɵɵconditionalCreate(1, TaskGraphEditorComponent_Conditional_1_Template, 1, 1, "mj-empty-state", 1)(2, TaskGraphEditorComponent_Conditional_2_Template, 5, 15);
|
|
527
584
|
i0.ɵɵelementEnd();
|
|
528
585
|
} if (rf & 2) {
|
|
529
586
|
i0.ɵɵadvance();
|
|
530
587
|
i0.ɵɵconditional(ctx.IsEmpty && ctx.ReadOnly ? 1 : 2);
|
|
531
|
-
} }, dependencies: [i1.FlowEditorComponent, i2.MJEmptyStateComponent, i2.MJAlertComponent, i3.TaskGraphPropertiesPanelComponent], styles: ["\n\n.mj-tge[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n min-height: 0;\n background: var(--mj-bg-page);\n}\n\n.mj-tge__validation[_ngcontent-%COMP%] {\n flex: 0 0 auto;\n margin: var(--mj-space-sm, 0.5rem);\n}\n\n.mj-tge__validation-list[_ngcontent-%COMP%] {\n margin: var(--mj-space-xs, 0.25rem) 0 0;\n padding-inline-start: 1.25rem;\n}\n\n\n\n.mj-tge__workspace[_ngcontent-%COMP%] {\n display: flex;\n flex: 1 1 auto;\n min-height: 0;\n}\n\n\n\n.mj-tge__canvas[_ngcontent-%COMP%] {\n flex: 1 1 auto;\n min-width: 0;\n min-height: 0;\n}\n\n.mj-tge__properties[_ngcontent-%COMP%] {\n flex: 0 0 auto;\n width: 300px;\n min-height: 0;\n overflow-y: auto;\n border-left: 1px solid var(--mj-border-default);\n}\n\n@media (max-width: 900px) {\n \n\n .mj-tge__workspace[_ngcontent-%COMP%] {\n flex-direction: column;\n }\n\n .mj-tge__properties[_ngcontent-%COMP%] {\n width: 100%;\n max-height: 40%;\n border-left: 0;\n border-top: 1px solid var(--mj-border-default);\n }\n}\n\n\n\n.mj-tge__empty-hint[_ngcontent-%COMP%] {\n margin: var(--mj-space-2) var(--mj-space-3) 0;\n}"] });
|
|
588
|
+
} }, dependencies: [i1.FlowEditorComponent, i2.MJEmptyStateComponent, i2.MJAlertComponent, i3.TaskGraphPropertiesPanelComponent], styles: ["\n\n\n\n\n\n[_nghost-%COMP%] {\n display: block;\n height: 100%;\n min-height: 0;\n}\n\n.mj-tge[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n min-height: 0;\n background: var(--mj-bg-page);\n}\n\n.mj-tge__validation[_ngcontent-%COMP%] {\n flex: 0 0 auto;\n margin: var(--mj-space-sm, 0.5rem);\n}\n\n.mj-tge__validation-list[_ngcontent-%COMP%] {\n margin: var(--mj-space-xs, 0.25rem) 0 0;\n padding-inline-start: 1.25rem;\n}\n\n\n\n.mj-tge__workspace[_ngcontent-%COMP%] {\n display: flex;\n flex: 1 1 auto;\n min-height: 0;\n}\n\n\n\n.mj-tge__canvas[_ngcontent-%COMP%] {\n flex: 1 1 auto;\n min-width: 0;\n min-height: 0;\n}\n\n.mj-tge__properties[_ngcontent-%COMP%] {\n flex: 0 0 auto;\n width: 300px;\n min-height: 0;\n overflow-y: auto;\n border-left: 1px solid var(--mj-border-default);\n}\n\n@media (max-width: 900px) {\n \n\n .mj-tge__workspace[_ngcontent-%COMP%] {\n flex-direction: column;\n }\n\n .mj-tge__properties[_ngcontent-%COMP%] {\n width: 100%;\n max-height: 40%;\n border-left: 0;\n border-top: 1px solid var(--mj-border-default);\n }\n}\n\n\n\n.mj-tge__empty-hint[_ngcontent-%COMP%] {\n margin: var(--mj-space-2) var(--mj-space-3) 0;\n}"] });
|
|
532
589
|
}
|
|
533
590
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TaskGraphEditorComponent, [{
|
|
534
591
|
type: Component,
|
|
535
|
-
args: [{ standalone: false, selector: 'mj-task-graph-editor', template: "<div class=\"mj-tge\">\n <!-- An EDITABLE empty canvas must still render the editor, because the palette is the only way to\n add a step \u2014 showing a bare empty state instead made \"Add one to start building this workflow\"\n an instruction the user could not follow. The hint stays, as a banner above a usable canvas. -->\n @if (IsEmpty && ReadOnly) {\n <mj-empty-state\n Icon=\"fa-diagram-project\"\n Title=\"Nothing here yet\"\n [Message]=\"EmptyStateMessage\">\n </mj-empty-state>\n } @else {\n @if (IsEmpty) {\n <mj-alert Variant=\"info\" class=\"mj-tge__empty-hint\" [Message]=\"EmptyStateMessage\"></mj-alert>\n }\n @if (!IsValid && ValidationErrors.length > 0) {\n <!-- Author-time validation comes from the SAME function the engine runs at submission, so a\n graph that looks fine here cannot be rejected later for a reason the canvas never showed. -->\n <mj-alert Variant=\"warning\" class=\"mj-tge__validation\">\n <strong>{{ ValidationErrors.length }} problem{{ ValidationErrors.length === 1 ? '' : 's' }} to fix</strong>\n <ul class=\"mj-tge__validation-list\">\n @for (err of ValidationErrors; track err.Code + (err.TempId ?? '')) {\n <li>{{ err.Message }}</li>\n }\n </ul>\n </mj-alert>\n }\n\n <div class=\"mj-tge__workspace\">\n <mj-flow-editor\n class=\"mj-tge__canvas\"\n [Nodes]=\"Nodes\"\n [Connections]=\"Connections\"\n [NodeTypes]=\"NodeTypes\"\n [ReadOnly]=\"ReadOnly\"\n [ShowToolbar]=\"ShowToolbar\"\n [ShowPalette]=\"ShowPalette && !ReadOnly\"\n [ShowMinimap]=\"ShowMinimap\"\n [ShowStatusBar]=\"ShowStatusBar\"\n [AutoLayoutDirection]=\"AutoLayoutDirection\"\n (NodeSelected)=\"OnNodeSelected($event)\"\n (NodeAdded)=\"OnNodeAdded($event)\"\n (NodeRemoved)=\"OnNodeRemoved($event)\"\n (NodesChanged)=\"OnNodesChanged($event)\"\n (NodeMoved)=\"OnNodeMoved($event)\"\n (ConnectionCreated)=\"OnConnectionCreated($event)\"\n (ConnectionRemoved)=\"OnConnectionRemoved($event)\">\n </mj-flow-editor>\n\n <!-- The canvas draws structure; this supplies content. A step added from the palette arrives\n unnamed and (with nothing to default to) unassigned, so without this panel the author can\n create a step but never finish one. -->\n @if (ShowProperties && !ReadOnly) {\n <mj-task-graph-properties\n class=\"mj-tge__properties\"\n [Task]=\"SelectedTask\"\n [Spec]=\"Spec\"\n [ReadOnly]=\"ReadOnly\"\n [AvailableAgentNames]=\"AvailableAgentNames\"\n [AvailableActionNames]=\"AvailableActionNames\"\n (TaskPropertyChangeRequested)=\"OnTaskPropertyChangeRequested($event)\"\n (DependencyConditionChangeRequested)=\"OnDependencyConditionChangeRequested($event)\">\n </mj-task-graph-properties>\n }\n </div>\n }\n</div>\n", styles: ["/* Design tokens only \u2014 no hardcoded colors (see .claude/rules/design-tokens.md). */\n.mj-tge {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n min-height: 0;\n background: var(--mj-bg-page);\n}\n\n.mj-tge__validation {\n flex: 0 0 auto;\n margin: var(--mj-space-sm, 0.5rem);\n}\n\n.mj-tge__validation-list {\n margin: var(--mj-space-xs, 0.25rem) 0 0;\n padding-inline-start: 1.25rem;\n}\n\n/* Canvas + properties side by side; the row takes the remaining height. */\n.mj-tge__workspace {\n display: flex;\n flex: 1 1 auto;\n min-height: 0;\n}\n\n/* The canvas takes the remaining width; min-width:0 is what lets it actually shrink inside flex. */\n.mj-tge__canvas {\n flex: 1 1 auto;\n min-width: 0;\n min-height: 0;\n}\n\n.mj-tge__properties {\n flex: 0 0 auto;\n width: 300px;\n min-height: 0;\n overflow-y: auto;\n border-left: 1px solid var(--mj-border-default);\n}\n\n@media (max-width: 900px) {\n /* Below this the two side by side leave neither usable; the panel drops under the canvas. */\n .mj-tge__workspace {\n flex-direction: column;\n }\n\n .mj-tge__properties {\n width: 100%;\n max-height: 40%;\n border-left: 0;\n border-top: 1px solid var(--mj-border-default);\n }\n}\n\n/* Shown above a usable, empty canvas \u2014 the palette stays reachable so the hint's advice is followable. */\n.mj-tge__empty-hint {\n margin: var(--mj-space-2) var(--mj-space-3) 0;\n}\n"] }]
|
|
592
|
+
args: [{ standalone: false, selector: 'mj-task-graph-editor', template: "<div class=\"mj-tge\">\n <!-- An EDITABLE empty canvas must still render the editor, because the palette is the only way to\n add a step \u2014 showing a bare empty state instead made \"Add one to start building this workflow\"\n an instruction the user could not follow. The hint stays, as a banner above a usable canvas. -->\n @if (IsEmpty && ReadOnly) {\n <mj-empty-state\n Icon=\"fa-diagram-project\"\n Title=\"Nothing here yet\"\n [Message]=\"EmptyStateMessage\">\n </mj-empty-state>\n } @else {\n @if (IsEmpty) {\n <mj-alert Variant=\"info\" class=\"mj-tge__empty-hint\" [Message]=\"EmptyStateMessage\"></mj-alert>\n }\n @if (!IsValid && ValidationErrors.length > 0) {\n <!-- Author-time validation comes from the SAME function the engine runs at submission, so a\n graph that looks fine here cannot be rejected later for a reason the canvas never showed. -->\n <mj-alert Variant=\"warning\" class=\"mj-tge__validation\">\n <strong>{{ ValidationErrors.length }} problem{{ ValidationErrors.length === 1 ? '' : 's' }} to fix</strong>\n <ul class=\"mj-tge__validation-list\">\n @for (err of ValidationErrors; track err.Code + (err.TempId ?? '')) {\n <li>{{ err.Message }}</li>\n }\n </ul>\n </mj-alert>\n }\n\n <div class=\"mj-tge__workspace\">\n <mj-flow-editor\n class=\"mj-tge__canvas\"\n [Nodes]=\"Nodes\"\n [Connections]=\"Connections\"\n [NodeTypes]=\"NodeTypes\"\n [ReadOnly]=\"ReadOnly\"\n [ShowToolbar]=\"ShowToolbar\"\n [ToolbarVisibility]=\"ToolbarVisibility\"\n [ToolbarAlign]=\"ToolbarAlign\"\n [ShowPalette]=\"ShowPalette && !ReadOnly\"\n [ShowMinimap]=\"ShowMinimap\"\n [ShowLegend]=\"ShowLegend\"\n [ShowStatusBar]=\"ShowStatusBar\"\n [AutoLayoutDirection]=\"AutoLayoutDirection\"\n (NodeSelected)=\"OnNodeSelected($event)\"\n (NodeAdded)=\"OnNodeAdded($event)\"\n (NodeRemoved)=\"OnNodeRemoved($event)\"\n (NodesChanged)=\"OnNodesChanged($event)\"\n (NodeMoved)=\"OnNodeMoved($event)\"\n (ConnectionCreated)=\"OnConnectionCreated($event)\"\n (ConnectionRemoved)=\"OnConnectionRemoved($event)\"\n (ConnectionSelected)=\"OnConnectionSelected($event)\"\n (LegendToggled)=\"OnLegendToggled($event)\"\n (BeforeContextMenu)=\"BeforeContextMenu.emit($event)\"\n (AfterContextMenuAction)=\"AfterContextMenuAction.emit($event)\">\n </mj-flow-editor>\n\n <!-- The canvas draws structure; this supplies content. A step added from the palette arrives\n unnamed and (with nothing to default to) unassigned, so without this panel the author can\n create a step but never finish one. -->\n @if (ShowProperties && !ReadOnly) {\n <mj-task-graph-properties\n class=\"mj-tge__properties\"\n [Task]=\"SelectedTask\"\n [Spec]=\"Spec\"\n [ReadOnly]=\"ReadOnly\"\n [AvailableAgentNames]=\"AvailableAgentNames\"\n [AvailableActionNames]=\"AvailableActionNames\"\n (TaskPropertyChangeRequested)=\"OnTaskPropertyChangeRequested($event)\"\n (DependencyConditionChangeRequested)=\"OnDependencyConditionChangeRequested($event)\">\n </mj-task-graph-properties>\n }\n </div>\n }\n</div>\n", styles: ["/* Design tokens only \u2014 no hardcoded colors (see .claude/rules/design-tokens.md). */\n\n/* Same reason as the flow editor's host: a custom element is inline with auto height, so the\n `height: 100%` on `.mj-tge` below had nothing to resolve against. */\n:host {\n display: block;\n height: 100%;\n min-height: 0;\n}\n\n.mj-tge {\n display: flex;\n flex-direction: column;\n width: 100%;\n height: 100%;\n min-height: 0;\n background: var(--mj-bg-page);\n}\n\n.mj-tge__validation {\n flex: 0 0 auto;\n margin: var(--mj-space-sm, 0.5rem);\n}\n\n.mj-tge__validation-list {\n margin: var(--mj-space-xs, 0.25rem) 0 0;\n padding-inline-start: 1.25rem;\n}\n\n/* Canvas + properties side by side; the row takes the remaining height. */\n.mj-tge__workspace {\n display: flex;\n flex: 1 1 auto;\n min-height: 0;\n}\n\n/* The canvas takes the remaining width; min-width:0 is what lets it actually shrink inside flex. */\n.mj-tge__canvas {\n flex: 1 1 auto;\n min-width: 0;\n min-height: 0;\n}\n\n.mj-tge__properties {\n flex: 0 0 auto;\n width: 300px;\n min-height: 0;\n overflow-y: auto;\n border-left: 1px solid var(--mj-border-default);\n}\n\n@media (max-width: 900px) {\n /* Below this the two side by side leave neither usable; the panel drops under the canvas. */\n .mj-tge__workspace {\n flex-direction: column;\n }\n\n .mj-tge__properties {\n width: 100%;\n max-height: 40%;\n border-left: 0;\n border-top: 1px solid var(--mj-border-default);\n }\n}\n\n/* Shown above a usable, empty canvas \u2014 the palette stays reachable so the hint's advice is followable. */\n.mj-tge__empty-hint {\n margin: var(--mj-space-2) var(--mj-space-3) 0;\n}\n"] }]
|
|
536
593
|
}], null, { Spec: [{
|
|
537
594
|
type: Input
|
|
538
595
|
}], RuntimeStatus: [{
|
|
@@ -543,10 +600,16 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
543
600
|
type: Input
|
|
544
601
|
}], ShowToolbar: [{
|
|
545
602
|
type: Input
|
|
603
|
+
}], ToolbarVisibility: [{
|
|
604
|
+
type: Input
|
|
605
|
+
}], ToolbarAlign: [{
|
|
606
|
+
type: Input
|
|
546
607
|
}], ShowPalette: [{
|
|
547
608
|
type: Input
|
|
548
609
|
}], ShowMinimap: [{
|
|
549
610
|
type: Input
|
|
611
|
+
}], ShowLegend: [{
|
|
612
|
+
type: Input
|
|
550
613
|
}], ShowStatusBar: [{
|
|
551
614
|
type: Input
|
|
552
615
|
}], AutoLayoutDirection: [{
|
|
@@ -559,6 +622,8 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
559
622
|
type: Input
|
|
560
623
|
}], EmptyStateMessage: [{
|
|
561
624
|
type: Input
|
|
625
|
+
}], DebugOverlay: [{
|
|
626
|
+
type: Input
|
|
562
627
|
}], BeforeTaskAdded: [{
|
|
563
628
|
type: Output
|
|
564
629
|
}], AfterTaskAdded: [{
|
|
@@ -579,6 +644,8 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
579
644
|
type: Output
|
|
580
645
|
}], AfterDependencyRemoved: [{
|
|
581
646
|
type: Output
|
|
647
|
+
}], LegendToggled: [{
|
|
648
|
+
type: Output
|
|
582
649
|
}], SpecChanged: [{
|
|
583
650
|
type: Output
|
|
584
651
|
}], SelectionChanged: [{
|
|
@@ -589,9 +656,15 @@ export class TaskGraphEditorComponent extends BaseAngularComponent {
|
|
|
589
656
|
type: Output
|
|
590
657
|
}], RecordOpenRequested: [{
|
|
591
658
|
type: Output
|
|
659
|
+
}], ConnectionSelected: [{
|
|
660
|
+
type: Output
|
|
661
|
+
}], BeforeContextMenu: [{
|
|
662
|
+
type: Output
|
|
663
|
+
}], AfterContextMenuAction: [{
|
|
664
|
+
type: Output
|
|
592
665
|
}], canvas: [{
|
|
593
666
|
type: ViewChild,
|
|
594
667
|
args: [FlowEditorComponent]
|
|
595
668
|
}] }); })();
|
|
596
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(TaskGraphEditorComponent, { className: "TaskGraphEditorComponent", filePath: "src/lib/task-graph-editor.component.ts", lineNumber:
|
|
669
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(TaskGraphEditorComponent, { className: "TaskGraphEditorComponent", filePath: "src/lib/task-graph-editor.component.ts", lineNumber: 97 }); })();
|
|
597
670
|
//# sourceMappingURL=task-graph-editor.component.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"task-graph-editor.component.js","sourceRoot":"","sources":["../../src/lib/task-graph-editor.component.ts","../../src/lib/task-graph-editor.component.html"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAa,MAAM,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC7F,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EACH,QAAQ,EACR,qBAAqB,GAIxB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAWrE,OAAO,EACH,aAAa,EACb,OAAO,EACP,aAAa,EACb,iBAAiB,EACjB,oBAAoB,EACpB,mBAAmB,EACnB,UAAU,EACV,gBAAgB,EAChB,UAAU,EACV,iBAAiB,EACjB,WAAW,EACX,qBAAqB,EACrB,UAAU,EACV,gBAAgB,GAEnB,MAAM,6BAA6B,CAAC;AAKrC,OAAO,EACH,6BAA6B,EAC7B,+BAA+B,EAC/B,uBAAuB,EACvB,yBAAyB,EACzB,yBAAyB,EACzB,2BAA2B,EAC3B,8BAA8B,EAC9B,gCAAgC,EAChC,wBAAwB,EACxB,0BAA0B,EAC1B,0BAA0B,EAC1B,4BAA4B,EAC5B,kCAAkC,EAClC,6BAA6B,EAC7B,mCAAmC,GACtC,MAAM,4BAA4B,CAAC;;;;;oEC/DA,EAAE;;IAflC,oCAIiB;;;IADf,kDAA6B;;;IAI7B,8BAA6F;;;IAAzC,kDAA6B;;;IAS3E,0BAAI;IAAA,YAAiB;IAAA,i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,GAAG,IAAI,CAAC;QAC9B,CAAC;IACL,CAAC;IAED,2FAA2F;IAC3F;;;;;;;OAOG;IACc,cAAc,GAAG,IAAI,GAAG,EAAwB,CAAC;IAElE,gGAAgG;IACxF,UAAU,GAAY,KAAK,CAAC;IAC5B,aAAa,GAAyC,IAAI,CAAC;6QAzc1D,wBAAwB,yBAAxB,wBAAwB;6DAAxB,wBAAwB;2BAsHtB,mBAAmB;;;;;YCjNlC,8BAAoB;YAUhB,AANF,qGAA2B,2DAMlB;YAuDX,iBAAM;;YA7DJ,cA4DC;YA5DD,qDA4DC;;;iFD2BU,wBAAwB;cANpC,SAAS;6BACM,KAAK,YACP,sBAAsB;;kBAY/B,KAAK;;kBAcL,KAAK;;kBAwBL,KAAK;;kBAWL,KAAK;;kBAEL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBAUL,KAAK;;kBAML,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAIL,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBAGN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBAGN,MAAM;;kBACN,MAAM;;kBAWN,SAAS;mBAAC,mBAAmB;;kFAtHrB,wBAAwB","sourcesContent":["/**\n * @fileoverview View and edit a `TaskGraphSpec` on a canvas.\n *\n * **What makes this reusable is its subject.** It edits `TaskGraphSpec` — the one fully-qualified\n * graph contract every producer in the program already authors against (D16) — rather than any\n * particular persistence. A design-time flow, a graph an agent emitted at runtime, a stored workflow\n * definition and a graph a person is drawing from scratch are all the same type here, so one\n * component serves the Flow Agent editor, the Agent Run admin view, conversation plan cards, the\n * Tasks view, and anything downstream.\n *\n * The alternative — teaching the existing agent editor a second dialect — is precisely how the two\n * graph models drifted apart before Phase 4 pulled them onto one traversal engine.\n *\n * **Layer: `widgets` (L1/L2).** No `@angular/router`, no `@memberjunction/ng-shared`, no\n * `NavigationService`. Route-derived state arrives as `@Input()`; navigation *intent* leaves as an\n * `@Output()` the host acts on, because a widget cannot know whether it is inside Explorer, a\n * downstream app, or an embedded panel. See `guides/UI_LAYERING_GUIDE.md`.\n *\n * **Validation is the engine's.** Cycles, unknown dependency refs and assignment conflicts are\n * reported by calling `ValidateTaskGraphSpec` from `@memberjunction/ai-core-plus` — the same\n * function `LoopAgentType` and `TaskGraphService.Submit` call. A second implementation here would be\n * a second definition of \"valid\", and the graph that passes on the canvas would be free to fail at\n * submission.\n *\n * @module @memberjunction/ng-task-graph-editor\n */\nimport { Component, EventEmitter, Input, OnDestroy, Output, ViewChild } from '@angular/core';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport {\n ConfigOf,\n ValidateTaskGraphSpec,\n type TaskGraphSpec,\n type TaskGraphSpecNode,\n type TaskGraphValidationError,\n} from '@memberjunction/ai-core-plus';\nimport { FlowEditorComponent } from '@memberjunction/ng-flow-editor';\nimport type {\n FlowConnection,\n FlowConnectionCreatedEvent,\n FlowLayoutDirection,\n FlowNode,\n FlowNodeAddedEvent,\n FlowNodeMovedEvent,\n FlowNodeTypeConfig,\n FlowPosition,\n} from '@memberjunction/ng-flow-editor';\nimport {\n AddDependency,\n AddTask,\n GetDependents,\n GetNodeTypeConfig,\n IsAuthorableNodeType,\n NewTaskFromNodeType,\n NextTempId,\n RemoveDependency,\n RemoveTask,\n SpecToConnections,\n SpecToNodes,\n TASK_GRAPH_NODE_TYPES,\n UpdateTask,\n WouldCreateCycle,\n type TaskGraphRuntimeStatus,\n} from './task-graph-canvas-adapter';\nimport type {\n DependencyConditionChangeRequestedEventArgs,\n TaskPropertyChangeRequestedEventArgs,\n} from './task-graph-properties-panel.component';\nimport {\n AfterDependencyAddedEventArgs,\n AfterDependencyRemovedEventArgs,\n AfterTaskAddedEventArgs,\n AfterTaskRemovedEventArgs,\n AfterTaskUpdatedEventArgs,\n AgentOpenRequestedEventArgs,\n BeforeDependencyAddedEventArgs,\n BeforeDependencyRemovedEventArgs,\n BeforeTaskAddedEventArgs,\n BeforeTaskRemovedEventArgs,\n BeforeTaskUpdatedEventArgs,\n RecordOpenRequestedEventArgs,\n TaskGraphSelectionChangedEventArgs,\n TaskGraphSpecChangedEventArgs,\n TaskGraphValidationChangedEventArgs,\n} from './task-graph-editor-events';\n\n@Component({\n standalone: false,\n selector: 'mj-task-graph-editor',\n templateUrl: './task-graph-editor.component.html',\n styleUrls: ['./task-graph-editor.component.css'],\n})\nexport class TaskGraphEditorComponent extends BaseAngularComponent implements OnDestroy {\n // ── Inputs ───────────────────────────────────────────────────────────────\n\n /**\n * The graph to show. Setter-based rather than `ngOnChanges` (repo convention): the reaction is\n * explicit, runs only when this property changes, and costs nothing on other change-detection\n * passes.\n */\n @Input()\n public set Spec(value: TaskGraphSpec | null) {\n this.currentSpec = value;\n this.project();\n }\n public get Spec(): TaskGraphSpec | null {\n return this.currentSpec;\n }\n\n /**\n * Live per-task state, keyed by `tempId`. Supplying it turns the canvas into a runtime view of\n * the same graph — the convergence point the program was aiming at: one renderer for design time\n * and run time, rather than an editor and a separate Gantt that can disagree.\n */\n @Input()\n public set RuntimeStatus(value: TaskGraphRuntimeStatus | null) {\n this.currentRuntime = value;\n this.project();\n }\n public get RuntimeStatus(): TaskGraphRuntimeStatus | null {\n return this.currentRuntime;\n }\n\n /**\n * Geometry for the nodes, keyed by `tempId`. Supplying it places the graph instead of laying it\n * out.\n *\n * **Why a host must be able to supply this.** The spec has no layout field, so without it every\n * node projects to the origin — all of them, stacked in one place — and the canvas is left to\n * rescue the situation with a deferred Dagre pass. That pass is fine in the editor, where the\n * author is present and can rearrange. It was not fine in the RUN views, which held the real\n * geometry (a workflow's authored positions, or a computed layout) and had no way to hand it\n * over: every run rendered its steps piled on the origin, and the zoom-to-fit that followed\n * fitted a bounding box one node wide and blew the viewport up past 250%.\n *\n * Applied as the starting geometry only. Once the canvas reports positions of its own — a drag,\n * an arrange — those win, because the person moving a node is the authority on where it goes.\n */\n @Input()\n public set NodePositions(value: ReadonlyMap<string, FlowPosition> | null) {\n if (!value || value.size === 0) return;\n for (const [id, position] of value) this.knownPositions.set(id, { ...position });\n // Real geometry means the one-time Dagre pass has nothing to rescue.\n this.hasLaidOut = true;\n this.project();\n this.zoomToFitSoon();\n }\n\n /** Read-only mode. The same component is the viewer — there is no second, weaker renderer. */\n @Input() public ReadOnly: boolean = false;\n\n @Input() public ShowToolbar: boolean = true;\n @Input() public ShowPalette: boolean = true;\n @Input() public ShowMinimap: boolean = true;\n @Input() public ShowStatusBar: boolean = true;\n @Input() public AutoLayoutDirection: FlowLayoutDirection = 'vertical';\n\n /**\n * Whether the properties panel rides alongside the canvas.\n *\n * On by default, because without it a step added from the palette can never be named or\n * assigned — the canvas draws structure, the panel supplies content, and one without the other\n * is a graph the author can build but not finish. Hosts embedding the read-only viewer in a chat\n * card turn it off.\n */\n @Input() public ShowProperties: boolean = true;\n\n /**\n * Agent names offered when assigning a step. Supplied by the host, which owns data access —\n * this is a widgets-layer component and does not query.\n */\n @Input() public AvailableAgentNames: readonly string[] = [];\n\n /** Action names offered when assigning a step. Same ownership rule as `AvailableAgentNames`. */\n @Input() public AvailableActionNames: readonly string[] = [];\n\n /** Shown when there is nothing to draw yet. */\n @Input() public EmptyStateMessage: string = 'No steps yet. Add one to start building this workflow.';\n\n // ── Outputs ──────────────────────────────────────────────────────────────\n\n @Output() public BeforeTaskAdded = new EventEmitter<BeforeTaskAddedEventArgs>();\n @Output() public AfterTaskAdded = new EventEmitter<AfterTaskAddedEventArgs>();\n @Output() public BeforeTaskRemoved = new EventEmitter<BeforeTaskRemovedEventArgs>();\n @Output() public AfterTaskRemoved = new EventEmitter<AfterTaskRemovedEventArgs>();\n @Output() public BeforeTaskUpdated = new EventEmitter<BeforeTaskUpdatedEventArgs>();\n @Output() public AfterTaskUpdated = new EventEmitter<AfterTaskUpdatedEventArgs>();\n @Output() public BeforeDependencyAdded = new EventEmitter<BeforeDependencyAddedEventArgs>();\n @Output() public AfterDependencyAdded = new EventEmitter<AfterDependencyAddedEventArgs>();\n @Output() public BeforeDependencyRemoved = new EventEmitter<BeforeDependencyRemovedEventArgs>();\n @Output() public AfterDependencyRemoved = new EventEmitter<AfterDependencyRemovedEventArgs>();\n\n /** Informational — no `Before` pair, because these report what already happened. */\n @Output() public SpecChanged = new EventEmitter<TaskGraphSpecChangedEventArgs>();\n @Output() public SelectionChanged = new EventEmitter<TaskGraphSelectionChangedEventArgs>();\n @Output() public ValidationChanged = new EventEmitter<TaskGraphValidationChangedEventArgs>();\n\n /** Intent-only — the host navigates; this widget has no Router and must not acquire one. */\n @Output() public AgentOpenRequested = new EventEmitter<AgentOpenRequestedEventArgs>();\n @Output() public RecordOpenRequested = new EventEmitter<RecordOpenRequestedEventArgs>();\n\n // ── Rendered state ───────────────────────────────────────────────────────\n\n public Nodes: FlowNode[] = [];\n public Connections: FlowConnection[] = [];\n public NodeTypes: FlowNodeTypeConfig[] = [...TASK_GRAPH_NODE_TYPES];\n public SelectedTask: TaskGraphSpecNode | null = null;\n public ValidationErrors: readonly TaskGraphValidationError[] = [];\n public IsValid: boolean = true;\n\n @ViewChild(FlowEditorComponent) protected canvas: FlowEditorComponent | undefined;\n\n private currentSpec: TaskGraphSpec | null = null;\n private currentRuntime: TaskGraphRuntimeStatus | null = null;\n\n public get IsEmpty(): boolean {\n return (this.currentSpec?.tasks?.length ?? 0) === 0;\n }\n\n // ── Public methods ───────────────────────────────────────────────────────\n //\n // Imperative entry points exist for exactly the case the cancelable-event contract cannot serve:\n // a host that needs to `await` something (a confirm dialog) before the action proceeds. A\n // `Before*` handler cannot await — control returns to the emitter before the handler sets\n // `Cancel` — so the host awaits first and then calls one of these.\n\n /** Re-runs validation and emits the result. Idempotent. */\n public Validate(): TaskGraphValidationChangedEventArgs {\n const result = this.currentSpec\n ? ValidateTaskGraphSpec(this.currentSpec)\n : { Valid: true, Errors: [] as TaskGraphValidationError[] };\n\n this.IsValid = result.Valid;\n this.ValidationErrors = result.Errors;\n\n const args = new TaskGraphValidationChangedEventArgs(result.Valid, result.Errors);\n this.ValidationChanged.emit(args);\n return args;\n }\n\n /** Adds a task. Returns the new task, or null when a host vetoed it. */\n public AddTask(partial: Partial<TaskGraphSpecNode> = {}): TaskGraphSpecNode | null {\n if (this.ReadOnly || !this.currentSpec) return null;\n\n // Kind and configuration travel together — a partial that supplies one without the other\n // would be a node the engine cannot run, so an unspecified partial defaults to an unassigned\n // Agent step and the validator says so immediately.\n const task: TaskGraphSpecNode = {\n tempId: partial.tempId ?? NextTempId(this.currentSpec),\n name: partial.name ?? 'New step',\n description: partial.description ?? '',\n kind: partial.kind ?? 'Agent',\n configuration: partial.configuration ?? { agentName: '' },\n dependsOn: partial.dependsOn ?? [],\n policy: partial.policy,\n layout: partial.layout,\n inputPayload: partial.inputPayload,\n };\n\n const before = new BeforeTaskAddedEventArgs(task);\n this.BeforeTaskAdded.emit(before);\n if (before.Cancel) return null;\n\n this.commit(AddTask(this.currentSpec, task), 'TaskAdded');\n this.AfterTaskAdded.emit(new AfterTaskAddedEventArgs(task, this.currentSpec!));\n return task;\n }\n\n /** Removes a task and every edge into it. Returns false when a host vetoed it. */\n public RemoveTask(tempId: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n const task = this.findTask(tempId);\n if (!task) return false;\n\n // The blast radius travels with the event: a host deciding whether to veto needs to know\n // what else breaks, not merely which box was clicked.\n const before = new BeforeTaskRemovedEventArgs(task, GetDependents(this.currentSpec, tempId));\n this.BeforeTaskRemoved.emit(before);\n if (before.Cancel) return false;\n\n this.commit(RemoveTask(this.currentSpec, tempId), 'TaskRemoved');\n if (this.SelectedTask?.tempId === tempId) this.selectTask(null);\n this.AfterTaskRemoved.emit(new AfterTaskRemovedEventArgs(task, this.currentSpec!));\n return true;\n }\n\n /** Replaces a task's properties. Returns false when a host vetoed it. */\n public UpdateTask(tempId: string, next: TaskGraphSpecNode): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n const previous = this.findTask(tempId);\n if (!previous) return false;\n\n const before = new BeforeTaskUpdatedEventArgs(previous, next);\n this.BeforeTaskUpdated.emit(before);\n if (before.Cancel) return false;\n\n this.commit(UpdateTask(this.currentSpec, tempId, next), 'TaskUpdated');\n if (this.SelectedTask?.tempId === tempId) this.SelectedTask = next;\n this.AfterTaskUpdated.emit(new AfterTaskUpdatedEventArgs(next, this.currentSpec!));\n return true;\n }\n\n /**\n * Adds a dependency edge. Returns false when it was vetoed **or would create a cycle**.\n *\n * The cycle is refused unconditionally, not merely reported: a cyclic graph can never execute —\n * nothing would ever become eligible — so allowing the canvas to draw one would let a user build\n * something the engine must then reject. Better to refuse the stroke than to accept a graph that\n * cannot run.\n */\n public AddDependency(fromTempId: string, toTempId: string, condition?: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n\n const cycle = WouldCreateCycle(this.currentSpec, fromTempId, toTempId);\n const before = new BeforeDependencyAddedEventArgs(fromTempId, toTempId, cycle);\n this.BeforeDependencyAdded.emit(before);\n if (before.Cancel || cycle) return false;\n\n this.commit(AddDependency(this.currentSpec, fromTempId, toTempId, condition), 'DependencyAdded');\n this.AfterDependencyAdded.emit(new AfterDependencyAddedEventArgs(fromTempId, toTempId, this.currentSpec!));\n return true;\n }\n\n /** Removes a dependency edge. Returns false when a host vetoed it. */\n public RemoveDependency(fromTempId: string, toTempId: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n\n const before = new BeforeDependencyRemovedEventArgs(fromTempId, toTempId);\n this.BeforeDependencyRemoved.emit(before);\n if (before.Cancel) return false;\n\n this.commit(RemoveDependency(this.currentSpec, fromTempId, toTempId), 'DependencyRemoved');\n this.AfterDependencyRemoved.emit(new AfterDependencyRemovedEventArgs(fromTempId, toTempId, this.currentSpec!));\n return true;\n }\n\n /**\n * Sets — or with an empty string, clears — a dependency edge's condition.\n *\n * Implemented as remove-then-add so it travels the same `Before*`/`After*` path as any other\n * edge change. A separate silent mutation would be a second write path into the spec, and the\n * veto contract would then be right in one place and wrong in the other.\n */\n public SetDependencyCondition(fromTempId: string, toTempId: string, condition: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n if (!this.RemoveDependency(fromTempId, toTempId)) return false;\n return this.AddDependency(fromTempId, toTempId, condition.trim() || undefined);\n }\n\n /** Asks the host to open the agent behind a task. */\n public RequestAgentOpen(task: TaskGraphSpecNode): void {\n const agentName = ConfigOf(task, 'Agent')?.agentName;\n if (agentName) {\n this.AgentOpenRequested.emit(new AgentOpenRequestedEventArgs(agentName, task));\n }\n }\n\n /** Asks the host to open a record the graph references. */\n public RequestRecordOpen(entityName: string, recordID: string): void {\n this.RecordOpenRequested.emit(new RecordOpenRequestedEventArgs(entityName, recordID));\n }\n\n // ── Canvas handlers ──────────────────────────────────────────────────────\n\n public OnNodeSelected(node: FlowNode | null): void {\n this.selectTask(node ? this.findTask(node.ID) : null);\n }\n\n /**\n * A palette entry was clicked or dragged onto the canvas.\n *\n * **This binding is the bug.** The canvas has always emitted `NodeAdded` for a palette drop, and\n * this component simply never listened — so the node the canvas announced was thrown away, the\n * spec never gained a task, and the author was told \"a task graph must contain at least one\n * task\" no matter how many times they tried to add one. The canvas does not mutate its own\n * `Nodes` on purpose (the host owns the model); an unheard event is therefore a silent no-op\n * rather than a visible failure, which is why it survived.\n *\n * The new step is selected immediately: it lands unnamed and, for an agent or action step with\n * nothing available to default to, unassigned — so the properties panel is where the author has\n * to go next, and putting them there beats making them find it.\n */\n public OnNodeAdded(event: FlowNodeAddedEvent): void {\n if (this.ReadOnly || !this.currentSpec) return;\n const type = GetNodeTypeConfig(event.Node.Type)?.Type;\n // Only an authorable shape can be dropped from the palette. The render set is wider, and a\n // display-only kind arriving here would mean the palette offered something with no editor.\n if (!type || !IsAuthorableNodeType(type)) return;\n\n const added = this.AddTask(\n NewTaskFromNodeType(this.currentSpec, type, {\n agentName: this.AvailableAgentNames[0],\n actionName: this.AvailableActionNames[0],\n }),\n );\n if (!added) return;\n\n // Remember where the canvas put it BEFORE anything re-projects. The spec has no geometry\n // field, so this map is the only record that the author dropped (or clicked) it here — and\n // without it the node would snap back to the origin on the very next edit.\n this.knownPositions.set(added.tempId, { ...event.Node.Position });\n // A graph that has received a hand-placed node is laid out, by definition. Marking it here\n // stops the one-time Dagre pass from firing later and discarding that placement.\n this.hasLaidOut = true;\n this.selectTask(added);\n }\n\n /** Applies a properties-panel edit through the same vetoable path a canvas edit takes. */\n public OnTaskPropertyChangeRequested(args: TaskPropertyChangeRequestedEventArgs): void {\n this.UpdateTask(args.TempId, args.Next);\n }\n\n /** Applies a properties-panel edge-condition edit. */\n public OnDependencyConditionChangeRequested(args: DependencyConditionChangeRequestedEventArgs): void {\n this.SetDependencyCondition(args.FromTempId, args.ToTempId, args.Condition);\n }\n\n public OnConnectionCreated(event: FlowConnectionCreatedEvent): void {\n this.AddDependency(event.SourceNodeID, event.TargetNodeID);\n }\n\n public OnConnectionRemoved(connection: FlowConnection): void {\n this.RemoveDependency(connection.SourceNodeID, connection.TargetNodeID);\n }\n\n public OnNodeRemoved(node: FlowNode): void {\n this.RemoveTask(node.ID);\n }\n\n // ── Internals ────────────────────────────────────────────────────────────\n\n private findTask(tempId: string): TaskGraphSpecNode | null {\n return (this.currentSpec?.tasks ?? []).find((t) => t.tempId === tempId) ?? null;\n }\n\n private selectTask(task: TaskGraphSpecNode | null): void {\n this.SelectedTask = task;\n this.SelectionChanged.emit(new TaskGraphSelectionChangedEventArgs(task));\n }\n\n /** Applies a new spec, re-projects, re-validates, and tells the host — in that order. */\n private commit(spec: TaskGraphSpec, reason: TaskGraphSpecChangedEventArgs['Reason']): void {\n this.currentSpec = spec;\n this.project();\n this.SpecChanged.emit(new TaskGraphSpecChangedEventArgs(spec, reason));\n }\n\n /** Re-derives the canvas from the spec. Validation rides along so the two never disagree. */\n private project(): void {\n if (!this.currentSpec) {\n this.Nodes = [];\n this.Connections = [];\n this.ValidationErrors = [];\n this.IsValid = true;\n this.hasLaidOut = false;\n this.knownPositions.clear();\n return;\n }\n this.Nodes = SpecToNodes(this.currentSpec, this.currentRuntime ?? undefined, this.knownPositions);\n this.Connections = SpecToConnections(this.currentSpec);\n this.Validate();\n this.arrangeIfNeverLaidOut();\n }\n\n /**\n * Lays the graph out ONCE — when it arrives with no geometry of its own.\n *\n * A `TaskGraphSpec` carries no positions, so a spec opened for the first time projects with\n * every node at the origin and needs Dagre to make it readable. After that the author's layout\n * is the layout: `knownPositions` carries it across re-projections, and re-arranging again would\n * throw away the arrangement they just made.\n *\n * It must also not run on every edit, because `AutoArrange` ends in `ZoomToFit` — so arranging\n * per change meant the viewport snapped to fit after every added step and every drawn\n * connection, which on a one-node graph zooms to maximum. That is the behaviour being fixed\n * here; the rule mirrors the Flow Agent editor's (`flow-agent-editor.component.ts`), which has\n * always arranged only when every node sits at the origin.\n */\n private arrangeIfNeverLaidOut(): void {\n if (this.Nodes.length === 0) return;\n if (this.hasLaidOut) return;\n\n // Nothing to rescue a layout from: a spec whose nodes all sit at the origin has never been\n // arranged. One node at the origin is the legitimate starting case too.\n const allAtOrigin = this.Nodes.every((n) => n.Position.X === 0 && n.Position.Y === 0);\n if (!allAtOrigin) { this.hasLaidOut = true; return; }\n\n this.hasLaidOut = true;\n // Deferred one turn: the canvas has to render the nodes before Dagre can measure them.\n // Cleared on destroy so a pending layout cannot run against a torn-down view.\n if (this.pendingLayout !== null) clearTimeout(this.pendingLayout);\n this.pendingLayout = setTimeout(() => {\n this.pendingLayout = null;\n this.canvas?.AutoArrange(this.AutoLayoutDirection);\n });\n }\n\n /**\n * Fits the viewport to the graph, once the canvas has drawn it.\n *\n * Deferred for the same reason the layout pass is: `fitToScreen` measures the rendered nodes, so\n * calling it in the same turn as the projection fits whatever was on screen a moment ago. With\n * every node still at the origin that bounding box is a single node wide, and \"fit\" means zoom\n * to ~265% — the symptom that made a four-step workflow look like one enormous box.\n */\n private zoomToFitSoon(): void {\n if (this.pendingLayout !== null) clearTimeout(this.pendingLayout);\n this.pendingLayout = setTimeout(() => {\n this.pendingLayout = null;\n this.canvas?.ZoomToFit();\n });\n }\n\n /**\n * The canvas is the authority on geometry, so remember what it reports.\n *\n * Without this the spec — which has no geometry field — is the only survivor of a re-projection,\n * and every edit silently moved every node back to the origin. That is what forced a re-arrange\n * (and therefore a re-zoom) on each change.\n */\n public OnNodesChanged(nodes: FlowNode[]): void {\n for (const n of nodes) this.knownPositions.set(n.ID, { ...n.Position });\n }\n\n /** A single node was dragged. Same authority, narrower event. */\n public OnNodeMoved(event: FlowNodeMovedEvent): void {\n this.knownPositions.set(event.NodeID, { ...event.NewPosition });\n }\n\n public ngOnDestroy(): void {\n if (this.pendingLayout !== null) {\n clearTimeout(this.pendingLayout);\n this.pendingLayout = null;\n }\n }\n\n /** The topology the current layout was computed for; '' when nothing has been laid out. */\n /**\n * Node geometry, which the spec cannot hold.\n *\n * `TaskGraphSpec` is an execution contract with no layout field, so a re-projection would\n * otherwise return every node to the origin. Keyed by `tempId`; written from the canvas\n * (`NodesChanged` / `NodeMoved`) and from the drop position of a newly added node, and read back\n * by `SpecToNodes` on every projection.\n */\n private readonly knownPositions = new Map<string, FlowPosition>();\n\n /** Whether the one-time Dagre pass has run (or been made unnecessary by a hand-placed node). */\n private hasLaidOut: boolean = false;\n private pendingLayout: ReturnType<typeof setTimeout> | null = null;\n}\n","<div class=\"mj-tge\">\n <!-- An EDITABLE empty canvas must still render the editor, because the palette is the only way to\n add a step — showing a bare empty state instead made \"Add one to start building this workflow\"\n an instruction the user could not follow. The hint stays, as a banner above a usable canvas. -->\n @if (IsEmpty && ReadOnly) {\n <mj-empty-state\n Icon=\"fa-diagram-project\"\n Title=\"Nothing here yet\"\n [Message]=\"EmptyStateMessage\">\n </mj-empty-state>\n } @else {\n @if (IsEmpty) {\n <mj-alert Variant=\"info\" class=\"mj-tge__empty-hint\" [Message]=\"EmptyStateMessage\"></mj-alert>\n }\n @if (!IsValid && ValidationErrors.length > 0) {\n <!-- Author-time validation comes from the SAME function the engine runs at submission, so a\n graph that looks fine here cannot be rejected later for a reason the canvas never showed. -->\n <mj-alert Variant=\"warning\" class=\"mj-tge__validation\">\n <strong>{{ ValidationErrors.length }} problem{{ ValidationErrors.length === 1 ? '' : 's' }} to fix</strong>\n <ul class=\"mj-tge__validation-list\">\n @for (err of ValidationErrors; track err.Code + (err.TempId ?? '')) {\n <li>{{ err.Message }}</li>\n }\n </ul>\n </mj-alert>\n }\n\n <div class=\"mj-tge__workspace\">\n <mj-flow-editor\n class=\"mj-tge__canvas\"\n [Nodes]=\"Nodes\"\n [Connections]=\"Connections\"\n [NodeTypes]=\"NodeTypes\"\n [ReadOnly]=\"ReadOnly\"\n [ShowToolbar]=\"ShowToolbar\"\n [ShowPalette]=\"ShowPalette && !ReadOnly\"\n [ShowMinimap]=\"ShowMinimap\"\n [ShowStatusBar]=\"ShowStatusBar\"\n [AutoLayoutDirection]=\"AutoLayoutDirection\"\n (NodeSelected)=\"OnNodeSelected($event)\"\n (NodeAdded)=\"OnNodeAdded($event)\"\n (NodeRemoved)=\"OnNodeRemoved($event)\"\n (NodesChanged)=\"OnNodesChanged($event)\"\n (NodeMoved)=\"OnNodeMoved($event)\"\n (ConnectionCreated)=\"OnConnectionCreated($event)\"\n (ConnectionRemoved)=\"OnConnectionRemoved($event)\">\n </mj-flow-editor>\n\n <!-- The canvas draws structure; this supplies content. A step added from the palette arrives\n unnamed and (with nothing to default to) unassigned, so without this panel the author can\n create a step but never finish one. -->\n @if (ShowProperties && !ReadOnly) {\n <mj-task-graph-properties\n class=\"mj-tge__properties\"\n [Task]=\"SelectedTask\"\n [Spec]=\"Spec\"\n [ReadOnly]=\"ReadOnly\"\n [AvailableAgentNames]=\"AvailableAgentNames\"\n [AvailableActionNames]=\"AvailableActionNames\"\n (TaskPropertyChangeRequested)=\"OnTaskPropertyChangeRequested($event)\"\n (DependencyConditionChangeRequested)=\"OnDependencyConditionChangeRequested($event)\">\n </mj-task-graph-properties>\n }\n </div>\n }\n</div>\n"]}
|
|
1
|
+
{"version":3,"file":"task-graph-editor.component.js","sourceRoot":"","sources":["../../src/lib/task-graph-editor.component.ts","../../src/lib/task-graph-editor.component.html"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;GAyBG;AACH,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,KAAK,EAAa,MAAM,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAC7F,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAC;AACrE,OAAO,EACH,QAAQ,EACR,qBAAqB,GAIxB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAerE,OAAO,EACH,aAAa,EACb,OAAO,EACP,aAAa,EACb,iBAAiB,EACjB,oBAAoB,EACpB,mBAAmB,EACnB,UAAU,EACV,gBAAgB,EAChB,UAAU,EACV,iBAAiB,EACjB,WAAW,EACX,qBAAqB,EACrB,UAAU,EACV,gBAAgB,GAGnB,MAAM,6BAA6B,CAAC;AAKrC,OAAO,EACH,6BAA6B,EAC7B,+BAA+B,EAC/B,uBAAuB,EACvB,yBAAyB,EACzB,yBAAyB,EACzB,2BAA2B,EAC3B,8BAA8B,EAC9B,gCAAgC,EAChC,wBAAwB,EACxB,0BAA0B,EAC1B,0BAA0B,EAC1B,4BAA4B,EAC5B,kCAAkC,EAClC,6BAA6B,EAC7B,mCAAmC,GACtC,MAAM,4BAA4B,CAAC;;;;;oECpEA,EAAE;;IAflC,oCAIiB;;;IADf,kDAA6B;;;IAI7B,8BAA6F;;;IAAzC,kDAA6B;;;IAS3E,0BAAI;IAAA,YAAiB;IAAA,iBAAK;;;IAAtB,cAAiB;IAAjB,oCAAiB;;;IAHzB,AADF,mCAAuD,aAC7C;IAAA,YAA0F;IAAA,iBAAS;IAC3G,6BAAoC;IAClC,yHAEC;IAEL,AADE,iBAAK,EACI;;;IAND,eAA0F;IAA1F,iIAA0F;IAEhG,eAEC;IAFD,sCAEC;;;;IA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AC,aAAa,CAAC,CAAC;YACjC,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC;QAC9B,CAAC;IACL,CAAC;IAED,2FAA2F;IAC3F;;;;;;;OAOG;IACc,cAAc,GAAG,IAAI,GAAG,EAAwB,CAAC;IAElE,gGAAgG;IACxF,UAAU,GAAY,KAAK,CAAC;IACpC,wEAAwE;IAChE,iBAAiB,GAAkB,IAAI,CAAC;IACxC,aAAa,GAAyC,IAAI,CAAC;6QA/gB1D,wBAAwB,yBAAxB,wBAAwB;6DAAxB,wBAAwB;2BAqKtB,mBAAmB;;;;;YCrQlC,8BAAoB;YAUhB,AANF,qGAA2B,2DAMlB;YA8DX,iBAAM;;YApEJ,cAmEC;YAnED,qDAmEC;;;iFDyBU,wBAAwB;cANpC,SAAS;6BACM,KAAK,YACP,sBAAsB;;kBAY/B,KAAK;;kBAcL,KAAK;;kBAwBL,KAAK;;kBAkBL,KAAK;;kBAEL,KAAK;;kBAEL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBASL,KAAK;;kBACL,KAAK;;kBACL,KAAK;;kBAUL,KAAK;;kBAML,KAAK;;kBAGL,KAAK;;kBAGL,KAAK;;kBAML,KAAK;;kBAYL,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBAWN,MAAM;;kBAEN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBAGN,MAAM;;kBACN,MAAM;;kBAEN,MAAM;;kBACN,MAAM;;kBACN,MAAM;;kBAWN,SAAS;mBAAC,mBAAmB;;kFArKrB,wBAAwB","sourcesContent":["/**\n * @fileoverview View and edit a `TaskGraphSpec` on a canvas.\n *\n * **What makes this reusable is its subject.** It edits `TaskGraphSpec` — the one fully-qualified\n * graph contract every producer in the program already authors against (D16) — rather than any\n * particular persistence. A design-time flow, a graph an agent emitted at runtime, a stored workflow\n * definition and a graph a person is drawing from scratch are all the same type here, so one\n * component serves the Flow Agent editor, the Agent Run admin view, conversation plan cards, the\n * Tasks view, and anything downstream.\n *\n * The alternative — teaching the existing agent editor a second dialect — is precisely how the two\n * graph models drifted apart before Phase 4 pulled them onto one traversal engine.\n *\n * **Layer: `widgets` (L1/L2).** No `@angular/router`, no `@memberjunction/ng-shared`, no\n * `NavigationService`. Route-derived state arrives as `@Input()`; navigation *intent* leaves as an\n * `@Output()` the host acts on, because a widget cannot know whether it is inside Explorer, a\n * downstream app, or an embedded panel. See `guides/UI_LAYERING_GUIDE.md`.\n *\n * **Validation is the engine's.** Cycles, unknown dependency refs and assignment conflicts are\n * reported by calling `ValidateTaskGraphSpec` from `@memberjunction/ai-core-plus` — the same\n * function `LoopAgentType` and `TaskGraphService.Submit` call. A second implementation here would be\n * a second definition of \"valid\", and the graph that passes on the canvas would be free to fail at\n * submission.\n *\n * @module @memberjunction/ng-task-graph-editor\n */\nimport { Component, EventEmitter, Input, OnDestroy, Output, ViewChild } from '@angular/core';\nimport { BaseAngularComponent } from '@memberjunction/ng-base-types';\nimport {\n ConfigOf,\n ValidateTaskGraphSpec,\n type TaskGraphSpec,\n type TaskGraphSpecNode,\n type TaskGraphValidationError,\n} from '@memberjunction/ai-core-plus';\nimport { FlowEditorComponent } from '@memberjunction/ng-flow-editor';\nimport type {\n FlowAfterContextMenuActionEventArgs,\n FlowBeforeContextMenuEventArgs,\n FlowConnection,\n FlowConnectionCreatedEvent,\n FlowLayoutDirection,\n FlowNode,\n FlowNodeAddedEvent,\n FlowNodeMovedEvent,\n FlowNodeTypeConfig,\n FlowPosition,\n FlowToolbarAlign,\n FlowToolbarVisibility,\n} from '@memberjunction/ng-flow-editor';\nimport {\n AddDependency,\n AddTask,\n GetDependents,\n GetNodeTypeConfig,\n IsAuthorableNodeType,\n NewTaskFromNodeType,\n NextTempId,\n RemoveDependency,\n RemoveTask,\n SpecToConnections,\n SpecToNodes,\n TASK_GRAPH_NODE_TYPES,\n UpdateTask,\n WouldCreateCycle,\n type TaskGraphDebugOverlay,\n type TaskGraphRuntimeStatus,\n} from './task-graph-canvas-adapter';\nimport type {\n DependencyConditionChangeRequestedEventArgs,\n TaskPropertyChangeRequestedEventArgs,\n} from './task-graph-properties-panel.component';\nimport {\n AfterDependencyAddedEventArgs,\n AfterDependencyRemovedEventArgs,\n AfterTaskAddedEventArgs,\n AfterTaskRemovedEventArgs,\n AfterTaskUpdatedEventArgs,\n AgentOpenRequestedEventArgs,\n BeforeDependencyAddedEventArgs,\n BeforeDependencyRemovedEventArgs,\n BeforeTaskAddedEventArgs,\n BeforeTaskRemovedEventArgs,\n BeforeTaskUpdatedEventArgs,\n RecordOpenRequestedEventArgs,\n TaskGraphSelectionChangedEventArgs,\n TaskGraphSpecChangedEventArgs,\n TaskGraphValidationChangedEventArgs,\n} from './task-graph-editor-events';\n\n@Component({\n standalone: false,\n selector: 'mj-task-graph-editor',\n templateUrl: './task-graph-editor.component.html',\n styleUrls: ['./task-graph-editor.component.css'],\n})\nexport class TaskGraphEditorComponent extends BaseAngularComponent implements OnDestroy {\n // ── Inputs ───────────────────────────────────────────────────────────────\n\n /**\n * The graph to show. Setter-based rather than `ngOnChanges` (repo convention): the reaction is\n * explicit, runs only when this property changes, and costs nothing on other change-detection\n * passes.\n */\n @Input()\n public set Spec(value: TaskGraphSpec | null) {\n this.currentSpec = value;\n this.project();\n }\n public get Spec(): TaskGraphSpec | null {\n return this.currentSpec;\n }\n\n /**\n * Live per-task state, keyed by `tempId`. Supplying it turns the canvas into a runtime view of\n * the same graph — the convergence point the program was aiming at: one renderer for design time\n * and run time, rather than an editor and a separate Gantt that can disagree.\n */\n @Input()\n public set RuntimeStatus(value: TaskGraphRuntimeStatus | null) {\n this.currentRuntime = value;\n this.project();\n }\n public get RuntimeStatus(): TaskGraphRuntimeStatus | null {\n return this.currentRuntime;\n }\n\n /**\n * Geometry for the nodes, keyed by `tempId`. Supplying it places the graph instead of laying it\n * out.\n *\n * **Why a host must be able to supply this.** The spec has no layout field, so without it every\n * node projects to the origin — all of them, stacked in one place — and the canvas is left to\n * rescue the situation with a deferred Dagre pass. That pass is fine in the editor, where the\n * author is present and can rearrange. It was not fine in the RUN views, which held the real\n * geometry (a workflow's authored positions, or a computed layout) and had no way to hand it\n * over: every run rendered its steps piled on the origin, and the zoom-to-fit that followed\n * fitted a bounding box one node wide and blew the viewport up past 250%.\n *\n * Applied as the starting geometry only. Once the canvas reports positions of its own — a drag,\n * an arrange — those win, because the person moving a node is the authority on where it goes.\n */\n @Input()\n public set NodePositions(value: ReadonlyMap<string, FlowPosition> | null) {\n if (!value || value.size === 0) return;\n const key = [...value.keys()].sort().join(',');\n const firstForThisGraph = this.fittedGeometryKey !== key;\n for (const [id, position] of value) this.knownPositions.set(id, { ...position });\n // Real geometry means the one-time Dagre pass has nothing to rescue.\n this.hasLaidOut = true;\n this.project();\n // Fit once per graph. Live status / poll re-supplies the same positions as a new Map,\n // and fitting on every write snaps the viewport back while the person is zooming.\n if (firstForThisGraph) {\n this.fittedGeometryKey = key;\n this.zoomToFitSoon();\n }\n }\n\n /** Read-only mode. The same component is the viewer — there is no second, weaker renderer. */\n @Input() public ReadOnly: boolean = false;\n\n @Input() public ShowToolbar: boolean = true;\n /** Full bar / chip / recover tab. Run views default this to minimized. */\n @Input() public ToolbarVisibility: FlowToolbarVisibility = 'shown';\n @Input() public ToolbarAlign: FlowToolbarAlign = 'center';\n @Input() public ShowPalette: boolean = true;\n @Input() public ShowMinimap: boolean = true;\n /**\n * Whether the legend rides on the canvas.\n *\n * On for authoring, off for a run — and the difference is what the legend is FOR. It explains the\n * authoring vocabulary (what a conditional edge means, what a duplicate default looks like),\n * which is what someone drawing a graph needs. A run view is answering a different question —\n * what happened — and the legend answers none of it while occluding a third of the canvas.\n */\n @Input() public ShowLegend: boolean = true;\n @Input() public ShowStatusBar: boolean = true;\n @Input() public AutoLayoutDirection: FlowLayoutDirection = 'vertical';\n\n /**\n * Whether the properties panel rides alongside the canvas.\n *\n * On by default, because without it a step added from the palette can never be named or\n * assigned — the canvas draws structure, the panel supplies content, and one without the other\n * is a graph the author can build but not finish. Hosts embedding the read-only viewer in a chat\n * card turn it off.\n */\n @Input() public ShowProperties: boolean = true;\n\n /**\n * Agent names offered when assigning a step. Supplied by the host, which owns data access —\n * this is a widgets-layer component and does not query.\n */\n @Input() public AvailableAgentNames: readonly string[] = [];\n\n /** Action names offered when assigning a step. Same ownership rule as `AvailableAgentNames`. */\n @Input() public AvailableActionNames: readonly string[] = [];\n\n /** Shown when there is nothing to draw yet. */\n @Input() public EmptyStateMessage: string = 'No steps yet. Add one to start building this workflow.';\n\n /**\n * Debug overlay for a run. Empty by default so an embed (agent-run timeline, test harness)\n * never grows breakpoint badges or override styling it did not ask for.\n */\n @Input()\n public set DebugOverlay(value: TaskGraphDebugOverlay | null) {\n if (this.debugOverlay === value) return;\n this.debugOverlay = value;\n this.project();\n }\n public get DebugOverlay(): TaskGraphDebugOverlay | null {\n return this.debugOverlay;\n }\n\n // ── Outputs ──────────────────────────────────────────────────────────────\n\n @Output() public BeforeTaskAdded = new EventEmitter<BeforeTaskAddedEventArgs>();\n @Output() public AfterTaskAdded = new EventEmitter<AfterTaskAddedEventArgs>();\n @Output() public BeforeTaskRemoved = new EventEmitter<BeforeTaskRemovedEventArgs>();\n @Output() public AfterTaskRemoved = new EventEmitter<AfterTaskRemovedEventArgs>();\n @Output() public BeforeTaskUpdated = new EventEmitter<BeforeTaskUpdatedEventArgs>();\n @Output() public AfterTaskUpdated = new EventEmitter<AfterTaskUpdatedEventArgs>();\n @Output() public BeforeDependencyAdded = new EventEmitter<BeforeDependencyAddedEventArgs>();\n @Output() public AfterDependencyAdded = new EventEmitter<AfterDependencyAddedEventArgs>();\n @Output() public BeforeDependencyRemoved = new EventEmitter<BeforeDependencyRemovedEventArgs>();\n @Output() public AfterDependencyRemoved = new EventEmitter<AfterDependencyRemovedEventArgs>();\n\n /** Informational — no `Before` pair, because these report what already happened. */\n /**\n * The legend was shown or hidden from the canvas toolbar.\n *\n * Forwarded so a host can PERSIST the choice. Without it the toolbar's toggle mutates the\n * canvas's own flag and nothing else, so the preference dies with the view — and a host that\n * wanted it remembered would have to add a second control beside the one that already exists,\n * which is how a surface ends up with two buttons doing the same thing and disagreeing.\n */\n @Output() public LegendToggled = new EventEmitter<boolean>();\n\n @Output() public SpecChanged = new EventEmitter<TaskGraphSpecChangedEventArgs>();\n @Output() public SelectionChanged = new EventEmitter<TaskGraphSelectionChangedEventArgs>();\n @Output() public ValidationChanged = new EventEmitter<TaskGraphValidationChangedEventArgs>();\n\n /** Intent-only — the host navigates; this widget has no Router and must not acquire one. */\n @Output() public AgentOpenRequested = new EventEmitter<AgentOpenRequestedEventArgs>();\n @Output() public RecordOpenRequested = new EventEmitter<RecordOpenRequestedEventArgs>();\n /** A connection was clicked. Payload is the canvas connection, or null when cleared. */\n @Output() public ConnectionSelected = new EventEmitter<FlowConnection | null>();\n @Output() public BeforeContextMenu = new EventEmitter<FlowBeforeContextMenuEventArgs>();\n @Output() public AfterContextMenuAction = new EventEmitter<FlowAfterContextMenuActionEventArgs>();\n\n // ── Rendered state ───────────────────────────────────────────────────────\n\n public Nodes: FlowNode[] = [];\n public Connections: FlowConnection[] = [];\n public NodeTypes: FlowNodeTypeConfig[] = [...TASK_GRAPH_NODE_TYPES];\n public SelectedTask: TaskGraphSpecNode | null = null;\n public ValidationErrors: readonly TaskGraphValidationError[] = [];\n public IsValid: boolean = true;\n\n @ViewChild(FlowEditorComponent) protected canvas: FlowEditorComponent | undefined;\n\n private currentSpec: TaskGraphSpec | null = null;\n private currentRuntime: TaskGraphRuntimeStatus | null = null;\n private debugOverlay: TaskGraphDebugOverlay | null = null;\n\n public get IsEmpty(): boolean {\n return (this.currentSpec?.tasks?.length ?? 0) === 0;\n }\n\n // ── Public methods ───────────────────────────────────────────────────────\n //\n // Imperative entry points exist for exactly the case the cancelable-event contract cannot serve:\n // a host that needs to `await` something (a confirm dialog) before the action proceeds. A\n // `Before*` handler cannot await — control returns to the emitter before the handler sets\n // `Cancel` — so the host awaits first and then calls one of these.\n\n /** Re-runs validation and emits the result. Idempotent. */\n public Validate(): TaskGraphValidationChangedEventArgs {\n const result = this.currentSpec\n ? ValidateTaskGraphSpec(this.currentSpec)\n : { Valid: true, Errors: [] as TaskGraphValidationError[] };\n\n this.IsValid = result.Valid;\n this.ValidationErrors = result.Errors;\n\n const args = new TaskGraphValidationChangedEventArgs(result.Valid, result.Errors);\n this.ValidationChanged.emit(args);\n return args;\n }\n\n /** Adds a task. Returns the new task, or null when a host vetoed it. */\n public AddTask(partial: Partial<TaskGraphSpecNode> = {}): TaskGraphSpecNode | null {\n if (this.ReadOnly || !this.currentSpec) return null;\n\n // Kind and configuration travel together — a partial that supplies one without the other\n // would be a node the engine cannot run, so an unspecified partial defaults to an unassigned\n // Agent step and the validator says so immediately.\n const task: TaskGraphSpecNode = {\n tempId: partial.tempId ?? NextTempId(this.currentSpec),\n name: partial.name ?? 'New step',\n description: partial.description ?? '',\n kind: partial.kind ?? 'Agent',\n configuration: partial.configuration ?? { agentName: '' },\n dependsOn: partial.dependsOn ?? [],\n policy: partial.policy,\n layout: partial.layout,\n inputPayload: partial.inputPayload,\n };\n\n const before = new BeforeTaskAddedEventArgs(task);\n this.BeforeTaskAdded.emit(before);\n if (before.Cancel) return null;\n\n this.commit(AddTask(this.currentSpec, task), 'TaskAdded');\n this.AfterTaskAdded.emit(new AfterTaskAddedEventArgs(task, this.currentSpec!));\n return task;\n }\n\n /** Removes a task and every edge into it. Returns false when a host vetoed it. */\n public RemoveTask(tempId: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n const task = this.findTask(tempId);\n if (!task) return false;\n\n // The blast radius travels with the event: a host deciding whether to veto needs to know\n // what else breaks, not merely which box was clicked.\n const before = new BeforeTaskRemovedEventArgs(task, GetDependents(this.currentSpec, tempId));\n this.BeforeTaskRemoved.emit(before);\n if (before.Cancel) return false;\n\n this.commit(RemoveTask(this.currentSpec, tempId), 'TaskRemoved');\n if (this.SelectedTask?.tempId === tempId) this.selectTask(null);\n this.AfterTaskRemoved.emit(new AfterTaskRemovedEventArgs(task, this.currentSpec!));\n return true;\n }\n\n /** Replaces a task's properties. Returns false when a host vetoed it. */\n public UpdateTask(tempId: string, next: TaskGraphSpecNode): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n const previous = this.findTask(tempId);\n if (!previous) return false;\n\n const before = new BeforeTaskUpdatedEventArgs(previous, next);\n this.BeforeTaskUpdated.emit(before);\n if (before.Cancel) return false;\n\n this.commit(UpdateTask(this.currentSpec, tempId, next), 'TaskUpdated');\n if (this.SelectedTask?.tempId === tempId) this.SelectedTask = next;\n this.AfterTaskUpdated.emit(new AfterTaskUpdatedEventArgs(next, this.currentSpec!));\n return true;\n }\n\n /**\n * Adds a dependency edge. Returns false when it was vetoed **or would create a cycle**.\n *\n * The cycle is refused unconditionally, not merely reported: a cyclic graph can never execute —\n * nothing would ever become eligible — so allowing the canvas to draw one would let a user build\n * something the engine must then reject. Better to refuse the stroke than to accept a graph that\n * cannot run.\n */\n public AddDependency(fromTempId: string, toTempId: string, condition?: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n\n const cycle = WouldCreateCycle(this.currentSpec, fromTempId, toTempId);\n const before = new BeforeDependencyAddedEventArgs(fromTempId, toTempId, cycle);\n this.BeforeDependencyAdded.emit(before);\n if (before.Cancel || cycle) return false;\n\n this.commit(AddDependency(this.currentSpec, fromTempId, toTempId, condition), 'DependencyAdded');\n this.AfterDependencyAdded.emit(new AfterDependencyAddedEventArgs(fromTempId, toTempId, this.currentSpec!));\n return true;\n }\n\n /** Removes a dependency edge. Returns false when a host vetoed it. */\n public RemoveDependency(fromTempId: string, toTempId: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n\n const before = new BeforeDependencyRemovedEventArgs(fromTempId, toTempId);\n this.BeforeDependencyRemoved.emit(before);\n if (before.Cancel) return false;\n\n this.commit(RemoveDependency(this.currentSpec, fromTempId, toTempId), 'DependencyRemoved');\n this.AfterDependencyRemoved.emit(new AfterDependencyRemovedEventArgs(fromTempId, toTempId, this.currentSpec!));\n return true;\n }\n\n /**\n * Sets — or with an empty string, clears — a dependency edge's condition.\n *\n * Implemented as remove-then-add so it travels the same `Before*`/`After*` path as any other\n * edge change. A separate silent mutation would be a second write path into the spec, and the\n * veto contract would then be right in one place and wrong in the other.\n */\n public SetDependencyCondition(fromTempId: string, toTempId: string, condition: string): boolean {\n if (this.ReadOnly || !this.currentSpec) return false;\n if (!this.RemoveDependency(fromTempId, toTempId)) return false;\n return this.AddDependency(fromTempId, toTempId, condition.trim() || undefined);\n }\n\n /** Asks the host to open the agent behind a task. */\n public RequestAgentOpen(task: TaskGraphSpecNode): void {\n const agentName = ConfigOf(task, 'Agent')?.agentName;\n if (agentName) {\n this.AgentOpenRequested.emit(new AgentOpenRequestedEventArgs(agentName, task));\n }\n }\n\n /** Asks the host to open a record the graph references. */\n public RequestRecordOpen(entityName: string, recordID: string): void {\n this.RecordOpenRequested.emit(new RecordOpenRequestedEventArgs(entityName, recordID));\n }\n\n // ── Canvas handlers ──────────────────────────────────────────────────────\n\n public OnNodeSelected(node: FlowNode | null): void {\n this.selectTask(node ? this.findTask(node.ID) : null);\n }\n\n /**\n * A palette entry was clicked or dragged onto the canvas.\n *\n * **This binding is the bug.** The canvas has always emitted `NodeAdded` for a palette drop, and\n * this component simply never listened — so the node the canvas announced was thrown away, the\n * spec never gained a task, and the author was told \"a task graph must contain at least one\n * task\" no matter how many times they tried to add one. The canvas does not mutate its own\n * `Nodes` on purpose (the host owns the model); an unheard event is therefore a silent no-op\n * rather than a visible failure, which is why it survived.\n *\n * The new step is selected immediately: it lands unnamed and, for an agent or action step with\n * nothing available to default to, unassigned — so the properties panel is where the author has\n * to go next, and putting them there beats making them find it.\n */\n public OnNodeAdded(event: FlowNodeAddedEvent): void {\n if (this.ReadOnly || !this.currentSpec) return;\n const type = GetNodeTypeConfig(event.Node.Type)?.Type;\n // Only an authorable shape can be dropped from the palette. The render set is wider, and a\n // display-only kind arriving here would mean the palette offered something with no editor.\n if (!type || !IsAuthorableNodeType(type)) return;\n\n const added = this.AddTask(\n NewTaskFromNodeType(this.currentSpec, type, {\n agentName: this.AvailableAgentNames[0],\n actionName: this.AvailableActionNames[0],\n }),\n );\n if (!added) return;\n\n // Remember where the canvas put it BEFORE anything re-projects. The spec has no geometry\n // field, so this map is the only record that the author dropped (or clicked) it here — and\n // without it the node would snap back to the origin on the very next edit.\n this.knownPositions.set(added.tempId, { ...event.Node.Position });\n // A graph that has received a hand-placed node is laid out, by definition. Marking it here\n // stops the one-time Dagre pass from firing later and discarding that placement.\n this.hasLaidOut = true;\n this.selectTask(added);\n }\n\n /** Applies a properties-panel edit through the same vetoable path a canvas edit takes. */\n public OnTaskPropertyChangeRequested(args: TaskPropertyChangeRequestedEventArgs): void {\n this.UpdateTask(args.TempId, args.Next);\n }\n\n /** Applies a properties-panel edge-condition edit. */\n public OnDependencyConditionChangeRequested(args: DependencyConditionChangeRequestedEventArgs): void {\n this.SetDependencyCondition(args.FromTempId, args.ToTempId, args.Condition);\n }\n\n public OnConnectionCreated(event: FlowConnectionCreatedEvent): void {\n this.AddDependency(event.SourceNodeID, event.TargetNodeID);\n }\n\n public OnConnectionRemoved(connection: FlowConnection): void {\n this.RemoveDependency(connection.SourceNodeID, connection.TargetNodeID);\n }\n\n public OnNodeRemoved(node: FlowNode): void {\n this.RemoveTask(node.ID);\n }\n\n // ── Internals ────────────────────────────────────────────────────────────\n\n private findTask(tempId: string): TaskGraphSpecNode | null {\n return (this.currentSpec?.tasks ?? []).find((t) => t.tempId === tempId) ?? null;\n }\n\n private selectTask(task: TaskGraphSpecNode | null): void {\n this.SelectedTask = task;\n this.SelectionChanged.emit(new TaskGraphSelectionChangedEventArgs(task));\n }\n\n /** Applies a new spec, re-projects, re-validates, and tells the host — in that order. */\n private commit(spec: TaskGraphSpec, reason: TaskGraphSpecChangedEventArgs['Reason']): void {\n this.currentSpec = spec;\n this.project();\n this.SpecChanged.emit(new TaskGraphSpecChangedEventArgs(spec, reason));\n }\n\n /** Re-derives the canvas from the spec. Validation rides along so the two never disagree. */\n private project(): void {\n if (!this.currentSpec) {\n this.Nodes = [];\n this.Connections = [];\n this.ValidationErrors = [];\n this.IsValid = true;\n this.hasLaidOut = false;\n this.fittedGeometryKey = null;\n this.knownPositions.clear();\n return;\n }\n this.Nodes = SpecToNodes(\n this.currentSpec,\n this.currentRuntime ?? undefined,\n this.knownPositions,\n this.debugOverlay ?? undefined,\n );\n this.Connections = SpecToConnections(\n this.currentSpec,\n this.currentRuntime ?? undefined,\n this.debugOverlay ?? undefined,\n );\n this.Validate();\n this.arrangeIfNeverLaidOut();\n }\n\n /**\n * Lays the graph out ONCE — when it arrives with no geometry of its own.\n *\n * A `TaskGraphSpec` carries no positions, so a spec opened for the first time projects with\n * every node at the origin and needs Dagre to make it readable. After that the author's layout\n * is the layout: `knownPositions` carries it across re-projections, and re-arranging again would\n * throw away the arrangement they just made.\n *\n * It must also not run on every edit, because `AutoArrange` ends in `ZoomToFit` — so arranging\n * per change meant the viewport snapped to fit after every added step and every drawn\n * connection, which on a one-node graph zooms to maximum. That is the behaviour being fixed\n * here; the rule mirrors the Flow Agent editor's (`flow-agent-editor.component.ts`), which has\n * always arranged only when every node sits at the origin.\n */\n private arrangeIfNeverLaidOut(): void {\n if (this.Nodes.length === 0) return;\n if (this.hasLaidOut) return;\n\n // Nothing to rescue a layout from: a spec whose nodes all sit at the origin has never been\n // arranged. One node at the origin is the legitimate starting case too.\n const allAtOrigin = this.Nodes.every((n) => n.Position.X === 0 && n.Position.Y === 0);\n if (!allAtOrigin) { this.hasLaidOut = true; return; }\n\n this.hasLaidOut = true;\n // Deferred one turn: the canvas has to render the nodes before Dagre can measure them.\n // Cleared on destroy so a pending layout cannot run against a torn-down view.\n if (this.pendingLayout !== null) clearTimeout(this.pendingLayout);\n this.pendingLayout = setTimeout(() => {\n this.pendingLayout = null;\n this.canvas?.AutoArrange(this.AutoLayoutDirection);\n });\n }\n\n /**\n * Fits the viewport to the graph, once the canvas has drawn it.\n *\n * Deferred for the same reason the layout pass is: `fitToScreen` measures the rendered nodes, so\n * calling it in the same turn as the projection fits whatever was on screen a moment ago. With\n * every node still at the origin that bounding box is a single node wide, and \"fit\" means zoom\n * to ~265% — the symptom that made a four-step workflow look like one enormous box.\n */\n private zoomToFitSoon(): void {\n if (this.pendingLayout !== null) clearTimeout(this.pendingLayout);\n this.pendingLayout = setTimeout(() => {\n this.pendingLayout = null;\n this.canvas?.ZoomToFit();\n });\n }\n\n /**\n * The canvas is the authority on geometry, so remember what it reports.\n *\n * Without this the spec — which has no geometry field — is the only survivor of a re-projection,\n * and every edit silently moved every node back to the origin. That is what forced a re-arrange\n * (and therefore a re-zoom) on each change.\n */\n public OnNodesChanged(nodes: FlowNode[]): void {\n for (const n of nodes) this.knownPositions.set(n.ID, { ...n.Position });\n }\n\n /** The canvas toolbar showed or hid the legend; tell whoever is remembering that choice. */\n public OnLegendToggled(show: boolean): void {\n this.ShowLegend = show;\n this.LegendToggled.emit(show);\n }\n\n public OnConnectionSelected(connection: FlowConnection | null): void {\n this.ConnectionSelected.emit(connection);\n }\n\n /** A single node was dragged. Same authority, narrower event. */\n public OnNodeMoved(event: FlowNodeMovedEvent): void {\n this.knownPositions.set(event.NodeID, { ...event.NewPosition });\n }\n\n public ngOnDestroy(): void {\n if (this.pendingLayout !== null) {\n clearTimeout(this.pendingLayout);\n this.pendingLayout = null;\n }\n }\n\n /** The topology the current layout was computed for; '' when nothing has been laid out. */\n /**\n * Node geometry, which the spec cannot hold.\n *\n * `TaskGraphSpec` is an execution contract with no layout field, so a re-projection would\n * otherwise return every node to the origin. Keyed by `tempId`; written from the canvas\n * (`NodesChanged` / `NodeMoved`) and from the drop position of a newly added node, and read back\n * by `SpecToNodes` on every projection.\n */\n private readonly knownPositions = new Map<string, FlowPosition>();\n\n /** Whether the one-time Dagre pass has run (or been made unnecessary by a hand-placed node). */\n private hasLaidOut: boolean = false;\n /** Task-id set we last fitted. Same ids + a new Map must not re-fit. */\n private fittedGeometryKey: string | null = null;\n private pendingLayout: ReturnType<typeof setTimeout> | null = null;\n}\n","<div class=\"mj-tge\">\n <!-- An EDITABLE empty canvas must still render the editor, because the palette is the only way to\n add a step — showing a bare empty state instead made \"Add one to start building this workflow\"\n an instruction the user could not follow. The hint stays, as a banner above a usable canvas. -->\n @if (IsEmpty && ReadOnly) {\n <mj-empty-state\n Icon=\"fa-diagram-project\"\n Title=\"Nothing here yet\"\n [Message]=\"EmptyStateMessage\">\n </mj-empty-state>\n } @else {\n @if (IsEmpty) {\n <mj-alert Variant=\"info\" class=\"mj-tge__empty-hint\" [Message]=\"EmptyStateMessage\"></mj-alert>\n }\n @if (!IsValid && ValidationErrors.length > 0) {\n <!-- Author-time validation comes from the SAME function the engine runs at submission, so a\n graph that looks fine here cannot be rejected later for a reason the canvas never showed. -->\n <mj-alert Variant=\"warning\" class=\"mj-tge__validation\">\n <strong>{{ ValidationErrors.length }} problem{{ ValidationErrors.length === 1 ? '' : 's' }} to fix</strong>\n <ul class=\"mj-tge__validation-list\">\n @for (err of ValidationErrors; track err.Code + (err.TempId ?? '')) {\n <li>{{ err.Message }}</li>\n }\n </ul>\n </mj-alert>\n }\n\n <div class=\"mj-tge__workspace\">\n <mj-flow-editor\n class=\"mj-tge__canvas\"\n [Nodes]=\"Nodes\"\n [Connections]=\"Connections\"\n [NodeTypes]=\"NodeTypes\"\n [ReadOnly]=\"ReadOnly\"\n [ShowToolbar]=\"ShowToolbar\"\n [ToolbarVisibility]=\"ToolbarVisibility\"\n [ToolbarAlign]=\"ToolbarAlign\"\n [ShowPalette]=\"ShowPalette && !ReadOnly\"\n [ShowMinimap]=\"ShowMinimap\"\n [ShowLegend]=\"ShowLegend\"\n [ShowStatusBar]=\"ShowStatusBar\"\n [AutoLayoutDirection]=\"AutoLayoutDirection\"\n (NodeSelected)=\"OnNodeSelected($event)\"\n (NodeAdded)=\"OnNodeAdded($event)\"\n (NodeRemoved)=\"OnNodeRemoved($event)\"\n (NodesChanged)=\"OnNodesChanged($event)\"\n (NodeMoved)=\"OnNodeMoved($event)\"\n (ConnectionCreated)=\"OnConnectionCreated($event)\"\n (ConnectionRemoved)=\"OnConnectionRemoved($event)\"\n (ConnectionSelected)=\"OnConnectionSelected($event)\"\n (LegendToggled)=\"OnLegendToggled($event)\"\n (BeforeContextMenu)=\"BeforeContextMenu.emit($event)\"\n (AfterContextMenuAction)=\"AfterContextMenuAction.emit($event)\">\n </mj-flow-editor>\n\n <!-- The canvas draws structure; this supplies content. A step added from the palette arrives\n unnamed and (with nothing to default to) unassigned, so without this panel the author can\n create a step but never finish one. -->\n @if (ShowProperties && !ReadOnly) {\n <mj-task-graph-properties\n class=\"mj-tge__properties\"\n [Task]=\"SelectedTask\"\n [Spec]=\"Spec\"\n [ReadOnly]=\"ReadOnly\"\n [AvailableAgentNames]=\"AvailableAgentNames\"\n [AvailableActionNames]=\"AvailableActionNames\"\n (TaskPropertyChangeRequested)=\"OnTaskPropertyChangeRequested($event)\"\n (DependencyConditionChangeRequested)=\"OnDependencyConditionChangeRequested($event)\">\n </mj-task-graph-properties>\n }\n </div>\n }\n</div>\n"]}
|
|
@@ -2,13 +2,17 @@ import * as i0 from "@angular/core";
|
|
|
2
2
|
import * as i1 from "./task-graph-editor.component";
|
|
3
3
|
import * as i2 from "./task-graph-properties-panel.component";
|
|
4
4
|
import * as i3 from "./task-graph-run-view.component";
|
|
5
|
-
import * as i4 from "
|
|
6
|
-
import * as i5 from "@angular/
|
|
7
|
-
import * as i6 from "@
|
|
8
|
-
import * as i7 from "@memberjunction/ng-
|
|
5
|
+
import * as i4 from "./task-graph-debugger.component";
|
|
6
|
+
import * as i5 from "@angular/common";
|
|
7
|
+
import * as i6 from "@angular/forms";
|
|
8
|
+
import * as i7 from "@memberjunction/ng-flow-editor";
|
|
9
|
+
import * as i8 from "@memberjunction/ng-ui-components";
|
|
10
|
+
import * as i9 from "angular-split";
|
|
11
|
+
import * as i10 from "./task-graph-debug-toolbar.component";
|
|
12
|
+
import * as i11 from "./task-graph-variables.component";
|
|
9
13
|
export declare class TaskGraphEditorModule {
|
|
10
14
|
static ɵfac: i0.ɵɵFactoryDeclaration<TaskGraphEditorModule, never>;
|
|
11
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<TaskGraphEditorModule, [typeof i1.TaskGraphEditorComponent, typeof i2.TaskGraphPropertiesPanelComponent, typeof i3.TaskGraphRunViewComponent], [typeof
|
|
15
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<TaskGraphEditorModule, [typeof i1.TaskGraphEditorComponent, typeof i2.TaskGraphPropertiesPanelComponent, typeof i3.TaskGraphRunViewComponent, typeof i4.TaskGraphDebuggerComponent], [typeof i5.CommonModule, typeof i6.FormsModule, typeof i7.FlowEditorModule, typeof i8.MJEmptyStateComponent, typeof i8.MJAlertComponent, typeof i8.MJButtonDirective, typeof i9.AngularSplitModule, typeof i10.TaskGraphDebugToolbarComponent, typeof i11.TaskGraphVariablesComponent], [typeof i1.TaskGraphEditorComponent, typeof i2.TaskGraphPropertiesPanelComponent, typeof i3.TaskGraphRunViewComponent, typeof i10.TaskGraphDebugToolbarComponent, typeof i11.TaskGraphVariablesComponent, typeof i4.TaskGraphDebuggerComponent]>;
|
|
12
16
|
static ɵinj: i0.ɵɵInjectorDeclaration<TaskGraphEditorModule>;
|
|
13
17
|
}
|
|
14
18
|
//# sourceMappingURL=task-graph-editor.module.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"task-graph-editor.module.d.ts","sourceRoot":"","sources":["../../src/lib/task-graph-editor.module.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"task-graph-editor.module.d.ts","sourceRoot":"","sources":["../../src/lib/task-graph-editor.module.ts"],"names":[],"mappings":";;;;;;;;;;;;AAcA,qBA2Ba,qBAAqB;yCAArB,qBAAqB;0CAArB,qBAAqB;0CAArB,qBAAqB;CAAG"}
|
|
@@ -3,22 +3,69 @@ import { CommonModule } from '@angular/common';
|
|
|
3
3
|
import { FormsModule } from '@angular/forms';
|
|
4
4
|
import { FlowEditorModule } from '@memberjunction/ng-flow-editor';
|
|
5
5
|
import { MJEmptyStateComponent, MJAlertComponent, MJButtonDirective } from '@memberjunction/ng-ui-components';
|
|
6
|
+
import { AngularSplitModule } from 'angular-split';
|
|
6
7
|
import { TaskGraphEditorComponent } from './task-graph-editor.component';
|
|
7
8
|
import { TaskGraphPropertiesPanelComponent } from './task-graph-properties-panel.component';
|
|
8
9
|
import { TaskGraphRunViewComponent } from './task-graph-run-view.component';
|
|
10
|
+
import { TaskGraphDebugToolbarComponent } from './task-graph-debug-toolbar.component';
|
|
11
|
+
import { TaskGraphVariablesComponent } from './task-graph-variables.component';
|
|
12
|
+
import { TaskGraphDebuggerComponent } from './task-graph-debugger.component';
|
|
9
13
|
import * as i0 from "@angular/core";
|
|
10
14
|
export class TaskGraphEditorModule {
|
|
11
15
|
static ɵfac = function TaskGraphEditorModule_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || TaskGraphEditorModule)(); };
|
|
12
16
|
static ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: TaskGraphEditorModule });
|
|
13
|
-
static ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [CommonModule,
|
|
17
|
+
static ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [CommonModule,
|
|
18
|
+
FormsModule,
|
|
19
|
+
FlowEditorModule,
|
|
20
|
+
MJEmptyStateComponent,
|
|
21
|
+
MJAlertComponent,
|
|
22
|
+
AngularSplitModule] });
|
|
14
23
|
}
|
|
15
24
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(TaskGraphEditorModule, [{
|
|
16
25
|
type: NgModule,
|
|
17
26
|
args: [{
|
|
18
|
-
declarations: [
|
|
19
|
-
|
|
20
|
-
|
|
27
|
+
declarations: [
|
|
28
|
+
TaskGraphEditorComponent,
|
|
29
|
+
TaskGraphPropertiesPanelComponent,
|
|
30
|
+
TaskGraphRunViewComponent,
|
|
31
|
+
TaskGraphDebuggerComponent,
|
|
32
|
+
],
|
|
33
|
+
imports: [
|
|
34
|
+
CommonModule,
|
|
35
|
+
FormsModule,
|
|
36
|
+
FlowEditorModule,
|
|
37
|
+
MJEmptyStateComponent,
|
|
38
|
+
MJAlertComponent,
|
|
39
|
+
MJButtonDirective,
|
|
40
|
+
AngularSplitModule,
|
|
41
|
+
TaskGraphDebugToolbarComponent,
|
|
42
|
+
TaskGraphVariablesComponent,
|
|
43
|
+
],
|
|
44
|
+
exports: [
|
|
45
|
+
TaskGraphEditorComponent,
|
|
46
|
+
TaskGraphPropertiesPanelComponent,
|
|
47
|
+
TaskGraphRunViewComponent,
|
|
48
|
+
TaskGraphDebugToolbarComponent,
|
|
49
|
+
TaskGraphVariablesComponent,
|
|
50
|
+
TaskGraphDebuggerComponent,
|
|
51
|
+
],
|
|
21
52
|
}]
|
|
22
53
|
}], null, null); })();
|
|
23
|
-
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(TaskGraphEditorModule, { declarations: [TaskGraphEditorComponent,
|
|
54
|
+
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(TaskGraphEditorModule, { declarations: [TaskGraphEditorComponent,
|
|
55
|
+
TaskGraphPropertiesPanelComponent,
|
|
56
|
+
TaskGraphRunViewComponent,
|
|
57
|
+
TaskGraphDebuggerComponent], imports: [CommonModule,
|
|
58
|
+
FormsModule,
|
|
59
|
+
FlowEditorModule,
|
|
60
|
+
MJEmptyStateComponent,
|
|
61
|
+
MJAlertComponent,
|
|
62
|
+
MJButtonDirective,
|
|
63
|
+
AngularSplitModule,
|
|
64
|
+
TaskGraphDebugToolbarComponent,
|
|
65
|
+
TaskGraphVariablesComponent], exports: [TaskGraphEditorComponent,
|
|
66
|
+
TaskGraphPropertiesPanelComponent,
|
|
67
|
+
TaskGraphRunViewComponent,
|
|
68
|
+
TaskGraphDebugToolbarComponent,
|
|
69
|
+
TaskGraphVariablesComponent,
|
|
70
|
+
TaskGraphDebuggerComponent] }); })();
|
|
24
71
|
//# sourceMappingURL=task-graph-editor.module.js.map
|