@memberjunction/ng-flow-editor 6.3.0-edge.1 → 6.3.0-edge.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/agent-editor/agent-flow-transformer.service.d.ts.map +1 -1
- package/dist/lib/agent-editor/agent-flow-transformer.service.js +38 -0
- package/dist/lib/agent-editor/agent-flow-transformer.service.js.map +1 -1
- package/dist/lib/agent-editor/agent-properties-panel.component.d.ts +49 -0
- package/dist/lib/agent-editor/agent-properties-panel.component.d.ts.map +1 -1
- package/dist/lib/agent-editor/agent-properties-panel.component.js +1065 -347
- package/dist/lib/agent-editor/agent-properties-panel.component.js.map +1 -1
- package/dist/lib/agent-editor/agent-step-list.component.d.ts +10 -2
- package/dist/lib/agent-editor/agent-step-list.component.d.ts.map +1 -1
- package/dist/lib/agent-editor/agent-step-list.component.js +257 -199
- package/dist/lib/agent-editor/agent-step-list.component.js.map +1 -1
- package/dist/lib/agent-editor/flow-agent-editor.component.d.ts +16 -8
- package/dist/lib/agent-editor/flow-agent-editor.component.d.ts.map +1 -1
- package/dist/lib/agent-editor/flow-agent-editor.component.js +209 -117
- package/dist/lib/agent-editor/flow-agent-editor.component.js.map +1 -1
- package/dist/lib/agent-editor/waiting-step-config.d.ts +45 -0
- package/dist/lib/agent-editor/waiting-step-config.d.ts.map +1 -0
- package/dist/lib/agent-editor/waiting-step-config.js +117 -0
- package/dist/lib/agent-editor/waiting-step-config.js.map +1 -0
- package/dist/lib/components/flow-editor.component.d.ts +42 -5
- package/dist/lib/components/flow-editor.component.d.ts.map +1 -1
- package/dist/lib/components/flow-editor.component.js +299 -113
- package/dist/lib/components/flow-editor.component.js.map +1 -1
- package/dist/lib/components/flow-node.component.d.ts +25 -3
- package/dist/lib/components/flow-node.component.d.ts.map +1 -1
- package/dist/lib/components/flow-node.component.js +412 -125
- package/dist/lib/components/flow-node.component.js.map +1 -1
- package/dist/lib/components/flow-status-bar.component.d.ts +2 -1
- package/dist/lib/components/flow-status-bar.component.d.ts.map +1 -1
- package/dist/lib/components/flow-status-bar.component.js +12 -11
- package/dist/lib/components/flow-status-bar.component.js.map +1 -1
- package/dist/lib/components/flow-toolbar.component.d.ts +5 -2
- package/dist/lib/components/flow-toolbar.component.d.ts.map +1 -1
- package/dist/lib/components/flow-toolbar.component.js +42 -23
- package/dist/lib/components/flow-toolbar.component.js.map +1 -1
- package/dist/lib/interfaces/flow-types.d.ts +40 -0
- package/dist/lib/interfaces/flow-types.d.ts.map +1 -1
- package/dist/lib/interfaces/flow-types.js.map +1 -1
- package/dist/lib/services/flow-layout.service.d.ts +0 -1
- package/dist/lib/services/flow-layout.service.d.ts.map +1 -1
- package/dist/lib/services/flow-layout.service.js +5 -23
- package/dist/lib/services/flow-layout.service.js.map +1 -1
- package/dist/lib/services/flow-viewport.util.d.ts +58 -0
- package/dist/lib/services/flow-viewport.util.d.ts.map +1 -0
- package/dist/lib/services/flow-viewport.util.js +134 -0
- package/dist/lib/services/flow-viewport.util.js.map +1 -0
- package/dist/public-api.d.ts +1 -0
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +1 -0
- package/dist/public-api.js.map +1 -1
- package/package.json +10 -10
|
@@ -2,15 +2,23 @@ import { EventEmitter } from '@angular/core';
|
|
|
2
2
|
import { MJAIAgentStepEntity, MJAIAgentStepPathEntity } from '@memberjunction/core-entities';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
5
|
+
* Synchronized Playbook Outline view of workflow steps and outgoing paths.
|
|
6
|
+
* Renders as a numbered SOP document (Relay-style) with step squircles, loop indicators,
|
|
7
|
+
* and branch path pills — staying 1:1 synchronized with the spatial canvas.
|
|
7
8
|
*/
|
|
8
9
|
export declare class AgentStepListComponent {
|
|
9
10
|
Steps: MJAIAgentStepEntity[];
|
|
10
11
|
Paths: MJAIAgentStepPathEntity[];
|
|
11
12
|
SelectedStepID: string | null;
|
|
12
13
|
StepClicked: EventEmitter<MJAIAgentStepEntity>;
|
|
14
|
+
/** Steps ordered from StartingStep through connected paths (BFS) so the Playbook reads top-to-bottom. */
|
|
15
|
+
get OrderedSteps(): MJAIAgentStepEntity[];
|
|
13
16
|
IsStepSelected(step: MJAIAgentStepEntity): boolean;
|
|
17
|
+
GetOutgoingPaths(step: MJAIAgentStepEntity): MJAIAgentStepPathEntity[];
|
|
18
|
+
ResolveStepName(stepId: string, fallback?: string | null): string;
|
|
19
|
+
GetStepTypeLabel(step: MJAIAgentStepEntity): string;
|
|
20
|
+
GetStepIcon(step: MJAIAgentStepEntity): string;
|
|
21
|
+
GetStepColor(step: MJAIAgentStepEntity): string;
|
|
14
22
|
GetConfiguredItem(step: MJAIAgentStepEntity): string;
|
|
15
23
|
/** @deprecated Use {@link GetConfiguredItem}. */
|
|
16
24
|
getConfiguredItem(step: MJAIAgentStepEntity): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-step-list.component.d.ts","sourceRoot":"","sources":["../../../src/lib/agent-editor/agent-step-list.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,YAAY,EAA8C,MAAM,eAAe,CAAC;AACnH,OAAO,EAAE,mBAAmB,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;;
|
|
1
|
+
{"version":3,"file":"agent-step-list.component.d.ts","sourceRoot":"","sources":["../../../src/lib/agent-editor/agent-step-list.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAA4B,YAAY,EAA8C,MAAM,eAAe,CAAC;AACnH,OAAO,EAAE,mBAAmB,EAAE,uBAAuB,EAAE,MAAM,+BAA+B,CAAC;;AAK7F;;;;GAIG;AACH,qBA0Qa,sBAAsB;IACxB,KAAK,EAAE,mBAAmB,EAAE,CAAM;IAClC,KAAK,EAAE,uBAAuB,EAAE,CAAM;IACtC,cAAc,EAAE,MAAM,GAAG,IAAI,CAAQ;IAEpC,WAAW,oCAA2C;IAEhE,yGAAyG;IACzG,IAAW,YAAY,IAAI,mBAAmB,EAAE,CA6B/C;IAEM,cAAc,CAAC,IAAI,EAAE,mBAAmB,GAAG,OAAO;IAIlD,gBAAgB,CAAC,IAAI,EAAE,mBAAmB,GAAG,uBAAuB,EAAE;IAItE,eAAe,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM;IAKjE,gBAAgB,CAAC,IAAI,EAAE,mBAAmB,GAAG,MAAM;IASnD,WAAW,CAAC,IAAI,EAAE,mBAAmB,GAAG,MAAM;IAe9C,YAAY,CAAC,IAAI,EAAE,mBAAmB,GAAG,MAAM;IAe/C,iBAAiB,CAAC,IAAI,EAAE,mBAAmB,GAAG,MAAM;IAuB3D,iDAAiD;IACjD,iBAAiB,CAAC,IAAI,EAAE,mBAAmB,GAAG,MAAM;yCAnHzC,sBAAsB;2CAAtB,sBAAsB;CAsHlC"}
|
|
@@ -1,141 +1,234 @@
|
|
|
1
1
|
import { Component, Input, Output, EventEmitter, ViewEncapsulation, ChangeDetectionStrategy } from '@angular/core';
|
|
2
|
-
import { UUIDsEqual } from '@memberjunction/global';
|
|
2
|
+
import { GroupByUUID, IndexByUUID, UUIDSet, UUIDsEqual } from '@memberjunction/global';
|
|
3
3
|
import { ReadFlowDecisionStepConfiguration } from '@memberjunction/ai-core-plus';
|
|
4
|
+
import { WaitingStepSubtitle, IsWaitingStepType } from './waiting-step-config';
|
|
4
5
|
import * as i0 from "@angular/core";
|
|
5
|
-
import * as i1 from "@
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
i0.ɵɵelementStart(0, "tr", 10);
|
|
12
|
-
i0.ɵɵlistener("click", function AgentStepListComponent_Conditional_7_For_15_Template_tr_click_0_listener() { const step_r2 = i0.ɵɵrestoreView(_r1).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.StepClicked.emit(step_r2)); });
|
|
13
|
-
i0.ɵɵelementStart(1, "td", 11);
|
|
14
|
-
i0.ɵɵtext(2);
|
|
6
|
+
import * as i1 from "@angular/common";
|
|
7
|
+
import * as i2 from "@memberjunction/ng-ui-components";
|
|
8
|
+
const _forTrack0 = ($index, $item) => $item.ID;
|
|
9
|
+
function AgentStepListComponent_Conditional_8_For_2_Conditional_9_Template(rf, ctx) { if (rf & 1) {
|
|
10
|
+
i0.ɵɵelementStart(0, "span", 15);
|
|
11
|
+
i0.ɵɵtext(1, "Start");
|
|
15
12
|
i0.ɵɵelementEnd();
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
i0.ɵɵ
|
|
19
|
-
i0.ɵɵ
|
|
20
|
-
i0.ɵɵtext(8);
|
|
21
|
-
i0.ɵɵelementEnd()();
|
|
22
|
-
i0.ɵɵelementStart(9, "td");
|
|
23
|
-
i0.ɵɵconditionalCreate(10, AgentStepListComponent_Conditional_7_For_15_Conditional_10_Template, 1, 0, "i", 14);
|
|
13
|
+
} }
|
|
14
|
+
function AgentStepListComponent_Conditional_8_For_2_Conditional_12_Template(rf, ctx) { if (rf & 1) {
|
|
15
|
+
i0.ɵɵelementStart(0, "span", 17);
|
|
16
|
+
i0.ɵɵtext(1);
|
|
24
17
|
i0.ɵɵelementEnd();
|
|
25
|
-
i0.ɵɵelementStart(11, "td", 15);
|
|
26
|
-
i0.ɵɵtext(12);
|
|
27
|
-
i0.ɵɵelementEnd()();
|
|
28
18
|
} if (rf & 2) {
|
|
29
|
-
const step_r2 =
|
|
30
|
-
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
31
|
-
i0.ɵɵclassProp("mj-step-list-row--selected", ctx_r2.IsStepSelected(step_r2));
|
|
32
|
-
i0.ɵɵadvance(2);
|
|
33
|
-
i0.ɵɵtextInterpolate(step_r2.Name);
|
|
34
|
-
i0.ɵɵadvance(2);
|
|
35
|
-
i0.ɵɵattribute("data-type", step_r2.StepType);
|
|
36
|
-
i0.ɵɵadvance();
|
|
37
|
-
i0.ɵɵtextInterpolate1(" ", step_r2.StepType, " ");
|
|
38
|
-
i0.ɵɵadvance(2);
|
|
19
|
+
const step_r2 = i0.ɵɵnextContext().$implicit;
|
|
39
20
|
i0.ɵɵattribute("data-status", step_r2.Status);
|
|
40
21
|
i0.ɵɵadvance();
|
|
41
|
-
i0.ɵɵ
|
|
42
|
-
i0.ɵɵadvance(2);
|
|
43
|
-
i0.ɵɵconditional(step_r2.StartingStep ? 10 : -1);
|
|
44
|
-
i0.ɵɵadvance(2);
|
|
45
|
-
i0.ɵɵtextInterpolate(ctx_r2.getConfiguredItem(step_r2));
|
|
22
|
+
i0.ɵɵtextInterpolate(step_r2.Status);
|
|
46
23
|
} }
|
|
47
|
-
function
|
|
48
|
-
i0.ɵɵelementStart(0, "
|
|
49
|
-
i0.ɵɵtext(
|
|
50
|
-
i0.ɵɵelementEnd();
|
|
51
|
-
i0.ɵɵelementStart(5, "th");
|
|
52
|
-
i0.ɵɵtext(6, "Type");
|
|
24
|
+
function AgentStepListComponent_Conditional_8_For_2_Conditional_15_Template(rf, ctx) { if (rf & 1) {
|
|
25
|
+
i0.ɵɵelementStart(0, "div", 19);
|
|
26
|
+
i0.ɵɵtext(1);
|
|
53
27
|
i0.ɵɵelementEnd();
|
|
54
|
-
|
|
55
|
-
i0.ɵɵ
|
|
28
|
+
} if (rf & 2) {
|
|
29
|
+
const step_r2 = i0.ɵɵnextContext().$implicit;
|
|
30
|
+
i0.ɵɵadvance();
|
|
31
|
+
i0.ɵɵtextInterpolate(step_r2.Description);
|
|
32
|
+
} }
|
|
33
|
+
function AgentStepListComponent_Conditional_8_For_2_Conditional_17_For_2_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
34
|
+
i0.ɵɵelementStart(0, "span", 24);
|
|
35
|
+
i0.ɵɵtext(1);
|
|
56
36
|
i0.ɵɵelementEnd();
|
|
57
|
-
i0.ɵɵelementStart(
|
|
58
|
-
i0.ɵɵtext(
|
|
37
|
+
i0.ɵɵelementStart(2, "span");
|
|
38
|
+
i0.ɵɵtext(3, "\u2192");
|
|
59
39
|
i0.ɵɵelementEnd();
|
|
60
|
-
|
|
61
|
-
i0.ɵɵ
|
|
62
|
-
i0.ɵɵ
|
|
63
|
-
i0.ɵɵ
|
|
64
|
-
|
|
40
|
+
} if (rf & 2) {
|
|
41
|
+
const path_r4 = i0.ɵɵnextContext().$implicit;
|
|
42
|
+
i0.ɵɵadvance();
|
|
43
|
+
i0.ɵɵtextInterpolate(path_r4.Condition);
|
|
44
|
+
} }
|
|
45
|
+
function AgentStepListComponent_Conditional_8_For_2_Conditional_17_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
46
|
+
i0.ɵɵelementStart(0, "span", 22);
|
|
47
|
+
i0.ɵɵelement(1, "i", 23);
|
|
48
|
+
i0.ɵɵconditionalCreate(2, AgentStepListComponent_Conditional_8_For_2_Conditional_17_For_2_Conditional_2_Template, 4, 1);
|
|
49
|
+
i0.ɵɵelementStart(3, "span");
|
|
50
|
+
i0.ɵɵtext(4);
|
|
65
51
|
i0.ɵɵelementEnd()();
|
|
66
52
|
} if (rf & 2) {
|
|
67
|
-
const
|
|
68
|
-
i0.ɵɵ
|
|
69
|
-
i0.ɵɵ
|
|
53
|
+
const path_r4 = ctx.$implicit;
|
|
54
|
+
const ctx_r2 = i0.ɵɵnextContext(4);
|
|
55
|
+
i0.ɵɵclassProp("mj-playbook-branch--cond", !!(path_r4.Condition == null ? null : path_r4.Condition.trim()));
|
|
56
|
+
i0.ɵɵadvance();
|
|
57
|
+
i0.ɵɵclassProp("fa-code-branch", !!(path_r4.Condition == null ? null : path_r4.Condition.trim()))("fa-arrow-right", !(path_r4.Condition == null ? null : path_r4.Condition.trim()));
|
|
58
|
+
i0.ɵɵadvance();
|
|
59
|
+
i0.ɵɵconditional((path_r4.Condition == null ? null : path_r4.Condition.trim()) ? 2 : -1);
|
|
60
|
+
i0.ɵɵadvance(2);
|
|
61
|
+
i0.ɵɵtextInterpolate(ctx_r2.ResolveStepName(path_r4.DestinationStepID, path_r4.DestinationStep));
|
|
70
62
|
} }
|
|
71
|
-
function
|
|
72
|
-
i0.ɵɵ
|
|
63
|
+
function AgentStepListComponent_Conditional_8_For_2_Conditional_17_Template(rf, ctx) { if (rf & 1) {
|
|
64
|
+
i0.ɵɵelementStart(0, "div", 20);
|
|
65
|
+
i0.ɵɵrepeaterCreate(1, AgentStepListComponent_Conditional_8_For_2_Conditional_17_For_2_Template, 5, 8, "span", 21, _forTrack0);
|
|
66
|
+
i0.ɵɵelementEnd();
|
|
67
|
+
} if (rf & 2) {
|
|
68
|
+
i0.ɵɵnextContext();
|
|
69
|
+
const outPaths_r5 = i0.ɵɵreadContextLet(16);
|
|
70
|
+
i0.ɵɵadvance();
|
|
71
|
+
i0.ɵɵrepeater(outPaths_r5);
|
|
73
72
|
} }
|
|
74
|
-
function
|
|
75
|
-
i0.ɵɵ
|
|
73
|
+
function AgentStepListComponent_Conditional_8_For_2_Template(rf, ctx) { if (rf & 1) {
|
|
74
|
+
const _r1 = i0.ɵɵgetCurrentView();
|
|
75
|
+
i0.ɵɵelementStart(0, "div", 8);
|
|
76
|
+
i0.ɵɵlistener("click", function AgentStepListComponent_Conditional_8_For_2_Template_div_click_0_listener() { const step_r2 = i0.ɵɵrestoreView(_r1).$implicit; const ctx_r2 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r2.StepClicked.emit(step_r2)); });
|
|
77
|
+
i0.ɵɵelementStart(1, "div", 9);
|
|
76
78
|
i0.ɵɵtext(2);
|
|
77
79
|
i0.ɵɵelementEnd();
|
|
78
|
-
i0.ɵɵelementStart(3, "
|
|
79
|
-
i0.ɵɵ
|
|
80
|
-
i0.ɵɵelementEnd();
|
|
81
|
-
i0.ɵɵelementStart(5, "td", 16);
|
|
82
|
-
i0.ɵɵtext(6);
|
|
80
|
+
i0.ɵɵelementStart(3, "div", 10);
|
|
81
|
+
i0.ɵɵelement(4, "i", 11);
|
|
83
82
|
i0.ɵɵelementEnd();
|
|
84
|
-
i0.ɵɵelementStart(7, "
|
|
83
|
+
i0.ɵɵelementStart(5, "div", 12)(6, "div", 13)(7, "span", 14);
|
|
85
84
|
i0.ɵɵtext(8);
|
|
85
|
+
i0.ɵɵelementEnd();
|
|
86
|
+
i0.ɵɵconditionalCreate(9, AgentStepListComponent_Conditional_8_For_2_Conditional_9_Template, 2, 0, "span", 15);
|
|
87
|
+
i0.ɵɵelementStart(10, "span", 16);
|
|
88
|
+
i0.ɵɵtext(11);
|
|
89
|
+
i0.ɵɵelementEnd();
|
|
90
|
+
i0.ɵɵconditionalCreate(12, AgentStepListComponent_Conditional_8_For_2_Conditional_12_Template, 2, 2, "span", 17);
|
|
91
|
+
i0.ɵɵelementEnd();
|
|
92
|
+
i0.ɵɵelementStart(13, "div", 18);
|
|
93
|
+
i0.ɵɵtext(14);
|
|
94
|
+
i0.ɵɵelementEnd();
|
|
95
|
+
i0.ɵɵconditionalCreate(15, AgentStepListComponent_Conditional_8_For_2_Conditional_15_Template, 2, 1, "div", 19);
|
|
96
|
+
i0.ɵɵdeclareLet(16);
|
|
97
|
+
i0.ɵɵconditionalCreate(17, AgentStepListComponent_Conditional_8_For_2_Conditional_17_Template, 3, 0, "div", 20);
|
|
86
98
|
i0.ɵɵelementEnd()();
|
|
87
99
|
} if (rf & 2) {
|
|
88
|
-
const
|
|
89
|
-
|
|
90
|
-
i0.ɵɵ
|
|
91
|
-
i0.ɵɵ
|
|
92
|
-
i0.ɵɵtextInterpolate(path_r4.DestinationStep);
|
|
100
|
+
const step_r2 = ctx.$implicit;
|
|
101
|
+
const ɵ$index_18_r6 = ctx.$index;
|
|
102
|
+
const ctx_r2 = i0.ɵɵnextContext(2);
|
|
103
|
+
i0.ɵɵclassProp("mj-playbook-card--selected", ctx_r2.IsStepSelected(step_r2))("mj-playbook-card--loop", step_r2.StepType === "ForEach" || step_r2.StepType === "While")("mj-playbook-card--disabled", step_r2.Status === "Disabled");
|
|
93
104
|
i0.ɵɵadvance(2);
|
|
94
|
-
i0.ɵɵtextInterpolate(
|
|
105
|
+
i0.ɵɵtextInterpolate(ɵ$index_18_r6 + 1);
|
|
106
|
+
i0.ɵɵadvance();
|
|
107
|
+
i0.ɵɵstyleProp("color", ctx_r2.GetStepColor(step_r2))("background", "color-mix(in srgb, " + ctx_r2.GetStepColor(step_r2) + " 14%, transparent)");
|
|
108
|
+
i0.ɵɵadvance();
|
|
109
|
+
i0.ɵɵproperty("ngClass", ctx_r2.GetStepIcon(step_r2));
|
|
110
|
+
i0.ɵɵadvance(4);
|
|
111
|
+
i0.ɵɵtextInterpolate(step_r2.Name);
|
|
112
|
+
i0.ɵɵadvance();
|
|
113
|
+
i0.ɵɵconditional(step_r2.StartingStep ? 9 : -1);
|
|
114
|
+
i0.ɵɵadvance();
|
|
115
|
+
i0.ɵɵstyleProp("color", ctx_r2.GetStepColor(step_r2));
|
|
116
|
+
i0.ɵɵadvance();
|
|
117
|
+
i0.ɵɵtextInterpolate(ctx_r2.GetStepTypeLabel(step_r2));
|
|
118
|
+
i0.ɵɵadvance();
|
|
119
|
+
i0.ɵɵconditional(step_r2.Status !== "Active" ? 12 : -1);
|
|
95
120
|
i0.ɵɵadvance(2);
|
|
96
|
-
i0.ɵɵtextInterpolate(
|
|
121
|
+
i0.ɵɵtextInterpolate(ctx_r2.GetConfiguredItem(step_r2));
|
|
122
|
+
i0.ɵɵadvance();
|
|
123
|
+
i0.ɵɵconditional(step_r2.Description ? 15 : -1);
|
|
124
|
+
i0.ɵɵadvance();
|
|
125
|
+
const outPaths_r7 = i0.ɵɵstoreLet(ctx_r2.GetOutgoingPaths(step_r2));
|
|
126
|
+
i0.ɵɵadvance();
|
|
127
|
+
i0.ɵɵconditional(outPaths_r7.length > 0 ? 17 : -1);
|
|
97
128
|
} }
|
|
98
|
-
function
|
|
99
|
-
i0.ɵɵelementStart(0, "
|
|
100
|
-
i0.ɵɵ
|
|
101
|
-
i0.ɵɵelementEnd();
|
|
102
|
-
i0.ɵɵelementStart(5, "th");
|
|
103
|
-
i0.ɵɵtext(6, "To");
|
|
104
|
-
i0.ɵɵelementEnd();
|
|
105
|
-
i0.ɵɵelementStart(7, "th");
|
|
106
|
-
i0.ɵɵtext(8, "Condition");
|
|
129
|
+
function AgentStepListComponent_Conditional_8_Template(rf, ctx) { if (rf & 1) {
|
|
130
|
+
i0.ɵɵelementStart(0, "div", 5);
|
|
131
|
+
i0.ɵɵrepeaterCreate(1, AgentStepListComponent_Conditional_8_For_2_Template, 18, 22, "div", 7, _forTrack0);
|
|
107
132
|
i0.ɵɵelementEnd();
|
|
108
|
-
i0.ɵɵelementStart(9, "th");
|
|
109
|
-
i0.ɵɵtext(10, "Priority");
|
|
110
|
-
i0.ɵɵelementEnd()()();
|
|
111
|
-
i0.ɵɵelementStart(11, "tbody");
|
|
112
|
-
i0.ɵɵrepeaterCreate(12, AgentStepListComponent_Conditional_15_For_13_Template, 9, 4, "tr", null, i0.ɵɵrepeaterTrackByIdentity);
|
|
113
|
-
i0.ɵɵelementEnd()();
|
|
114
133
|
} if (rf & 2) {
|
|
115
134
|
const ctx_r2 = i0.ɵɵnextContext();
|
|
116
|
-
i0.ɵɵadvance(
|
|
117
|
-
i0.ɵɵrepeater(ctx_r2.
|
|
135
|
+
i0.ɵɵadvance();
|
|
136
|
+
i0.ɵɵrepeater(ctx_r2.OrderedSteps);
|
|
118
137
|
} }
|
|
119
|
-
function
|
|
120
|
-
i0.ɵɵelement(0, "mj-empty-state",
|
|
138
|
+
function AgentStepListComponent_Conditional_9_Template(rf, ctx) { if (rf & 1) {
|
|
139
|
+
i0.ɵɵelement(0, "mj-empty-state", 6);
|
|
121
140
|
} }
|
|
122
141
|
/**
|
|
123
|
-
*
|
|
124
|
-
*
|
|
142
|
+
* Synchronized Playbook Outline view of workflow steps and outgoing paths.
|
|
143
|
+
* Renders as a numbered SOP document (Relay-style) with step squircles, loop indicators,
|
|
144
|
+
* and branch path pills — staying 1:1 synchronized with the spatial canvas.
|
|
125
145
|
*/
|
|
126
146
|
export class AgentStepListComponent {
|
|
127
147
|
Steps = [];
|
|
128
148
|
Paths = [];
|
|
129
149
|
SelectedStepID = null;
|
|
130
150
|
StepClicked = new EventEmitter();
|
|
151
|
+
/** Steps ordered from StartingStep through connected paths (BFS) so the Playbook reads top-to-bottom. */
|
|
152
|
+
get OrderedSteps() {
|
|
153
|
+
if (this.Steps.length <= 1)
|
|
154
|
+
return this.Steps;
|
|
155
|
+
const stepsById = IndexByUUID(this.Steps);
|
|
156
|
+
const pathsByOrigin = GroupByUUID(this.Paths, p => p.OriginStepID);
|
|
157
|
+
const ordered = [];
|
|
158
|
+
const visited = new UUIDSet();
|
|
159
|
+
const roots = this.Steps.filter(s => s.StartingStep);
|
|
160
|
+
const queue = roots.length > 0 ? [...roots] : [this.Steps[0]];
|
|
161
|
+
while (queue.length > 0) {
|
|
162
|
+
const curr = queue.shift();
|
|
163
|
+
if (visited.Has(curr.ID))
|
|
164
|
+
continue;
|
|
165
|
+
visited.Add(curr.ID);
|
|
166
|
+
ordered.push(curr);
|
|
167
|
+
for (const path of pathsByOrigin.Get(curr.ID) ?? []) {
|
|
168
|
+
const dest = stepsById.Get(path.DestinationStepID);
|
|
169
|
+
if (dest && !visited.Has(dest.ID)) {
|
|
170
|
+
queue.push(dest);
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
for (const s of this.Steps) {
|
|
175
|
+
if (!visited.Has(s.ID)) {
|
|
176
|
+
ordered.push(s);
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
return ordered;
|
|
180
|
+
}
|
|
131
181
|
IsStepSelected(step) {
|
|
132
182
|
return UUIDsEqual(this.SelectedStepID, step.ID);
|
|
133
183
|
}
|
|
184
|
+
GetOutgoingPaths(step) {
|
|
185
|
+
return this.Paths.filter(p => UUIDsEqual(p.OriginStepID, step.ID));
|
|
186
|
+
}
|
|
187
|
+
ResolveStepName(stepId, fallback) {
|
|
188
|
+
const match = this.Steps.find(s => UUIDsEqual(s.ID, stepId));
|
|
189
|
+
return match?.Name ?? fallback ?? 'Next step';
|
|
190
|
+
}
|
|
191
|
+
GetStepTypeLabel(step) {
|
|
192
|
+
switch (step.StepType) {
|
|
193
|
+
case 'Human': return 'Person';
|
|
194
|
+
case 'ForEach': return 'For Each';
|
|
195
|
+
case 'External': return 'External';
|
|
196
|
+
default: return step.StepType;
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
GetStepIcon(step) {
|
|
200
|
+
switch (step.StepType) {
|
|
201
|
+
case 'Action': return 'fa-bolt';
|
|
202
|
+
case 'Prompt': return 'fa-comment-dots';
|
|
203
|
+
case 'Decision': return 'fa-scale-balanced';
|
|
204
|
+
case 'Sub-Agent': return 'fa-robot';
|
|
205
|
+
case 'Human': return 'fa-user-check';
|
|
206
|
+
case 'External': return 'fa-arrow-up-right-from-square';
|
|
207
|
+
case 'Wait': return 'fa-hourglass-half';
|
|
208
|
+
case 'ForEach': return 'fa-repeat';
|
|
209
|
+
case 'While': return 'fa-rotate';
|
|
210
|
+
default: return 'fa-circle-nodes';
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
GetStepColor(step) {
|
|
214
|
+
switch (step.StepType) {
|
|
215
|
+
case 'Action': return '#3B82F6';
|
|
216
|
+
case 'Prompt': return '#8B5CF6';
|
|
217
|
+
case 'Decision': return '#0891B2';
|
|
218
|
+
case 'Sub-Agent': return '#10B981';
|
|
219
|
+
case 'Human': return '#7B1FA2';
|
|
220
|
+
case 'External': return '#0891B2';
|
|
221
|
+
case 'Wait': return '#64748B';
|
|
222
|
+
case 'ForEach': return '#F59E0B';
|
|
223
|
+
case 'While': return '#F97316';
|
|
224
|
+
default: return '#64748B';
|
|
225
|
+
}
|
|
226
|
+
}
|
|
134
227
|
GetConfiguredItem(step) {
|
|
135
228
|
switch (step.StepType) {
|
|
136
|
-
case 'Action': return step.Action || '
|
|
137
|
-
case 'Prompt': return step.Prompt || '
|
|
138
|
-
case 'Sub-Agent': return step.SubAgent || '
|
|
229
|
+
case 'Action': return step.Action || 'No action selected';
|
|
230
|
+
case 'Prompt': return step.Prompt || 'No prompt selected';
|
|
231
|
+
case 'Sub-Agent': return step.SubAgent || 'No sub-agent selected';
|
|
139
232
|
case 'ForEach':
|
|
140
233
|
case 'While': return `${step.LoopBodyType ?? 'Action'} loop`;
|
|
141
234
|
case 'Decision': {
|
|
@@ -146,7 +239,11 @@ export class AgentStepListComponent {
|
|
|
146
239
|
}
|
|
147
240
|
return 'Unconfigured';
|
|
148
241
|
}
|
|
149
|
-
default:
|
|
242
|
+
default:
|
|
243
|
+
if (IsWaitingStepType(step.StepType)) {
|
|
244
|
+
return WaitingStepSubtitle(step.StepType, step.Configuration);
|
|
245
|
+
}
|
|
246
|
+
return '—';
|
|
150
247
|
}
|
|
151
248
|
}
|
|
152
249
|
/** @deprecated Use {@link GetConfiguredItem}. */
|
|
@@ -154,127 +251,88 @@ export class AgentStepListComponent {
|
|
|
154
251
|
return this.GetConfiguredItem(step);
|
|
155
252
|
}
|
|
156
253
|
static ɵfac = function AgentStepListComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || AgentStepListComponent)(); };
|
|
157
|
-
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: AgentStepListComponent, selectors: [["mj-agent-step-list"]], inputs: { Steps: "Steps", Paths: "Paths", SelectedStepID: "SelectedStepID" }, outputs: { StepClicked: "StepClicked" }, standalone: false, decls:
|
|
254
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: AgentStepListComponent, selectors: [["mj-agent-step-list"]], inputs: { Steps: "Steps", Paths: "Paths", SelectedStepID: "SelectedStepID" }, outputs: { StepClicked: "StepClicked" }, standalone: false, decls: 10, vars: 4, consts: [[1, "mj-step-list"], [1, "mj-step-list-section"], [1, "mj-step-list-section-header"], [1, "fa-solid", "fa-list-ol"], [1, "mj-step-list-summary"], [1, "mj-playbook-cards"], ["Size", "compact", "Icon", "fa-solid fa-list-ol", "Title", "No steps defined yet", 1, "mj-step-list-empty"], [1, "mj-playbook-card", 3, "mj-playbook-card--selected", "mj-playbook-card--loop", "mj-playbook-card--disabled"], [1, "mj-playbook-card", 3, "click"], [1, "mj-playbook-num"], [1, "mj-playbook-sq"], ["aria-hidden", "true", 1, "fa-solid", 3, "ngClass"], [1, "mj-playbook-main"], [1, "mj-playbook-title-row"], [1, "mj-playbook-name"], [1, "mj-playbook-pill", "mj-playbook-pill--start"], [1, "mj-playbook-pill"], [1, "mj-playbook-status"], [1, "mj-playbook-sub"], [1, "mj-playbook-desc"], [1, "mj-playbook-branches"], [1, "mj-playbook-branch", 3, "mj-playbook-branch--cond"], [1, "mj-playbook-branch"], ["aria-hidden", "true", 1, "fa-solid"], [1, "mj-playbook-branch-cond"]], template: function AgentStepListComponent_Template(rf, ctx) { if (rf & 1) {
|
|
158
255
|
i0.ɵɵelementStart(0, "div", 0)(1, "div", 1)(2, "div", 2)(3, "h4");
|
|
159
256
|
i0.ɵɵelement(4, "i", 3);
|
|
160
257
|
i0.ɵɵtext(5);
|
|
258
|
+
i0.ɵɵelementEnd();
|
|
259
|
+
i0.ɵɵelementStart(6, "span", 4);
|
|
260
|
+
i0.ɵɵtext(7);
|
|
161
261
|
i0.ɵɵelementEnd()();
|
|
162
|
-
i0.ɵɵ
|
|
163
|
-
i0.ɵɵconditionalCreate(7, AgentStepListComponent_Conditional_7_Template, 16, 0, "table", 5);
|
|
164
|
-
i0.ɵɵconditionalCreate(8, AgentStepListComponent_Conditional_8_Template, 1, 0, "mj-empty-state", 6);
|
|
262
|
+
i0.ɵɵconditionalCreate(8, AgentStepListComponent_Conditional_8_Template, 3, 0, "div", 5)(9, AgentStepListComponent_Conditional_9_Template, 1, 0, "mj-empty-state", 6);
|
|
165
263
|
i0.ɵɵelementEnd()();
|
|
166
|
-
i0.ɵɵelementStart(9, "div", 1)(10, "div", 2)(11, "h4");
|
|
167
|
-
i0.ɵɵelement(12, "i", 7);
|
|
168
|
-
i0.ɵɵtext(13);
|
|
169
|
-
i0.ɵɵelementEnd()();
|
|
170
|
-
i0.ɵɵelementStart(14, "div", 4);
|
|
171
|
-
i0.ɵɵconditionalCreate(15, AgentStepListComponent_Conditional_15_Template, 14, 0, "table", 5);
|
|
172
|
-
i0.ɵɵconditionalCreate(16, AgentStepListComponent_Conditional_16_Template, 1, 0, "mj-empty-state", 8);
|
|
173
|
-
i0.ɵɵelementEnd()()();
|
|
174
264
|
} if (rf & 2) {
|
|
175
265
|
i0.ɵɵadvance(5);
|
|
176
|
-
i0.ɵɵtextInterpolate1(" Steps (", ctx.Steps.length, ")");
|
|
266
|
+
i0.ɵɵtextInterpolate1(" Playbook Steps (", ctx.Steps.length, ")");
|
|
177
267
|
i0.ɵɵadvance(2);
|
|
178
|
-
i0.ɵɵ
|
|
268
|
+
i0.ɵɵtextInterpolate2("", ctx.Paths.length, " ", ctx.Paths.length === 1 ? "path" : "paths");
|
|
179
269
|
i0.ɵɵadvance();
|
|
180
|
-
i0.ɵɵconditional(ctx.
|
|
181
|
-
|
|
182
|
-
i0.ɵɵtextInterpolate1(" Paths (", ctx.Paths.length, ")");
|
|
183
|
-
i0.ɵɵadvance(2);
|
|
184
|
-
i0.ɵɵconditional(ctx.Paths.length > 0 ? 15 : -1);
|
|
185
|
-
i0.ɵɵadvance();
|
|
186
|
-
i0.ɵɵconditional(ctx.Paths.length === 0 ? 16 : -1);
|
|
187
|
-
} }, dependencies: [i1.MJEmptyStateComponent], styles: ["\n .mj-step-list {\n padding: 16px;\n overflow-y: auto;\n height: 100%;\n }\n\n .mj-step-list-section {\n margin-bottom: 24px;\n }\n\n .mj-step-list-section-header h4 {\n font-size: 14px;\n font-weight: 600;\n color: #334155;\n margin: 0 0 10px;\n display: flex;\n align-items: center;\n gap: 8px;\n i { font-size: 13px; color: #64748b; }\n }\n\n .mj-step-list-table-wrap {\n border: 1px solid #e2e8f0;\n border-radius: 8px;\n overflow: hidden;\n }\n\n .mj-step-list-table {\n width: 100%;\n border-collapse: collapse;\n font-size: 13px;\n\n th {\n background: #f8fafc;\n padding: 8px 12px;\n text-align: left;\n font-weight: 600;\n color: #64748b;\n font-size: 11px;\n text-transform: uppercase;\n letter-spacing: 0.3px;\n border-bottom: 1px solid #e2e8f0;\n }\n\n td {\n padding: 8px 12px;\n color: #334155;\n border-bottom: 1px solid #f1f5f9;\n }\n\n tbody tr {\n cursor: pointer;\n transition: background-color 0.1s ease;\n &:hover { background: #f8fafc; }\n &:last-child td { border-bottom: none; }\n }\n }\n\n .mj-step-list-row--selected {\n background: #eff6ff !important;\n }\n\n .mj-step-list-name { font-weight: 500; }\n\n .mj-step-list-type-badge {\n font-size: 11px;\n font-weight: 500;\n padding: 2px 8px;\n border-radius: 4px;\n background: #f1f5f9;\n color: #475569;\n }\n\n .mj-step-list-status {\n font-size: 11px;\n font-weight: 500;\n &[data-status=\"Active\"] { color: #10b981; }\n &[data-status=\"Disabled\"] { color: #94a3b8; }\n &[data-status=\"Pending\"] { color: #f59e0b; }\n }\n\n .mj-step-list-check { color: #10b981; font-size: 12px; }\n\n .mj-step-list-configured {\n color: #64748b;\n font-size: 12px;\n max-width: 200px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .mj-step-list-condition {\n font-family: 'SF Mono', monospace;\n font-size: 11px;\n color: #64748b;\n max-width: 200px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .mj-step-list-empty {\n padding: 24px;\n text-align: center;\n color: #94a3b8;\n font-size: 13px;\n }\n "], encapsulation: 2, changeDetection: 0 });
|
|
270
|
+
i0.ɵɵconditional(ctx.OrderedSteps.length > 0 ? 8 : 9);
|
|
271
|
+
} }, dependencies: [i1.NgClass, i2.MJEmptyStateComponent], styles: ["\n .mj-step-list {\n padding: var(--mj-space-3-5, 14px);\n overflow-y: auto;\n height: 100%;\n background: var(--mj-bg-surface);\n }\n\n .mj-step-list-section-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-bottom: var(--mj-space-3);\n }\n\n .mj-step-list-section-header h4 {\n font-size: var(--mj-text-xs);\n font-weight: var(--mj-font-bold);\n text-transform: uppercase;\n letter-spacing: 0.05em;\n color: var(--mj-text-muted);\n margin: 0;\n display: flex;\n align-items: center;\n gap: 6px;\n }\n\n .mj-step-list-summary {\n font-size: 11px;\n color: var(--mj-text-muted);\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-full);\n padding: 2px 8px;\n }\n\n .mj-playbook-cards {\n display: flex;\n flex-direction: column;\n gap: var(--mj-space-2);\n }\n\n .mj-playbook-card {\n display: flex;\n align-items: flex-start;\n gap: var(--mj-space-2-5);\n padding: 10px 12px;\n border-radius: var(--mj-radius-md);\n border: 1px solid var(--mj-border-default);\n background: var(--mj-bg-surface-card);\n cursor: pointer;\n transition: border-color var(--mj-transition-fast), background-color var(--mj-transition-fast), box-shadow var(--mj-transition-fast);\n }\n\n .mj-playbook-card:hover {\n border-color: var(--mj-brand-primary-light);\n background: var(--mj-bg-surface-hover);\n }\n\n .mj-playbook-card--selected {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n box-shadow: var(--mj-shadow-sm);\n }\n\n .mj-playbook-card--loop {\n border-left: 3px solid var(--mj-brand-tertiary);\n }\n\n .mj-playbook-card--disabled {\n opacity: 0.55;\n }\n\n .mj-playbook-num {\n width: 22px;\n height: 22px;\n border-radius: 6px;\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n color: var(--mj-text-secondary);\n font-family: var(--mj-font-family-mono);\n font-size: 11px;\n font-weight: var(--mj-font-bold);\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n margin-top: 2px;\n }\n\n .mj-playbook-sq {\n width: 28px;\n height: 28px;\n border-radius: var(--mj-radius-md);\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 12px;\n flex-shrink: 0;\n }\n\n .mj-playbook-main {\n flex: 1;\n min-width: 0;\n display: flex;\n flex-direction: column;\n gap: 3px;\n }\n\n .mj-playbook-title-row {\n display: flex;\n align-items: center;\n gap: 6px;\n flex-wrap: wrap;\n }\n\n .mj-playbook-name {\n font-size: var(--mj-text-xs);\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-primary);\n }\n\n .mj-playbook-pill {\n font-size: 10px;\n font-weight: var(--mj-font-semibold);\n padding: 1px 6px;\n border-radius: var(--mj-radius-sm);\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n }\n\n .mj-playbook-pill--start {\n background: var(--mj-status-success-bg);\n border-color: color-mix(in srgb, var(--mj-status-success-border) 45%, transparent);\n color: var(--mj-status-success-text);\n }\n\n .mj-playbook-status {\n font-size: 10px;\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-muted);\n }\n\n .mj-playbook-status[data-status=\"Pending\"] { color: var(--mj-status-warning-text); }\n\n .mj-playbook-sub {\n font-size: 11px;\n color: var(--mj-text-secondary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .mj-playbook-desc {\n font-size: 11px;\n color: var(--mj-text-muted);\n line-height: 1.4;\n }\n\n .mj-playbook-branches {\n display: flex;\n flex-wrap: wrap;\n gap: 4px;\n margin-top: 4px;\n }\n\n .mj-playbook-branch {\n display: inline-flex;\n align-items: center;\n gap: 4px;\n font-size: 10px;\n padding: 2px 6px;\n border-radius: var(--mj-radius-sm);\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n color: var(--mj-text-secondary);\n max-width: 100%;\n }\n\n .mj-playbook-branch--cond {\n border-style: dashed;\n border-color: var(--mj-status-warning-border);\n background: var(--mj-status-warning-bg);\n color: var(--mj-status-warning-text);\n }\n\n .mj-playbook-branch-cond {\n font-family: var(--mj-font-family-mono);\n max-width: 120px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .mj-step-list-empty {\n padding: 24px;\n text-align: center;\n }\n "], encapsulation: 2, changeDetection: 0 });
|
|
188
272
|
}
|
|
189
273
|
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AgentStepListComponent, [{
|
|
190
274
|
type: Component,
|
|
191
275
|
args: [{ standalone: false, selector: 'mj-agent-step-list', template: `
|
|
192
276
|
<div class="mj-step-list">
|
|
193
|
-
<!-- Steps Section -->
|
|
194
277
|
<div class="mj-step-list-section">
|
|
195
278
|
<div class="mj-step-list-section-header">
|
|
196
|
-
<h4><i class="fa-solid fa-
|
|
279
|
+
<h4><i class="fa-solid fa-list-ol"></i> Playbook Steps ({{ Steps.length }})</h4>
|
|
280
|
+
<span class="mj-step-list-summary">{{ Paths.length }} {{ Paths.length === 1 ? 'path' : 'paths' }}</span>
|
|
197
281
|
</div>
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
</
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
</
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
282
|
+
|
|
283
|
+
@if (OrderedSteps.length > 0) {
|
|
284
|
+
<div class="mj-playbook-cards">
|
|
285
|
+
@for (step of OrderedSteps; track step.ID; let i = $index) {
|
|
286
|
+
<div
|
|
287
|
+
class="mj-playbook-card"
|
|
288
|
+
[class.mj-playbook-card--selected]="IsStepSelected(step)"
|
|
289
|
+
[class.mj-playbook-card--loop]="step.StepType === 'ForEach' || step.StepType === 'While'"
|
|
290
|
+
[class.mj-playbook-card--disabled]="step.Status === 'Disabled'"
|
|
291
|
+
(click)="StepClicked.emit(step)">
|
|
292
|
+
<div class="mj-playbook-num">{{ i + 1 }}</div>
|
|
293
|
+
<div class="mj-playbook-sq" [style.color]="GetStepColor(step)" [style.background]="'color-mix(in srgb, ' + GetStepColor(step) + ' 14%, transparent)'">
|
|
294
|
+
<i class="fa-solid" [ngClass]="GetStepIcon(step)" aria-hidden="true"></i>
|
|
295
|
+
</div>
|
|
296
|
+
<div class="mj-playbook-main">
|
|
297
|
+
<div class="mj-playbook-title-row">
|
|
298
|
+
<span class="mj-playbook-name">{{ step.Name }}</span>
|
|
299
|
+
@if (step.StartingStep) {
|
|
300
|
+
<span class="mj-playbook-pill mj-playbook-pill--start">Start</span>
|
|
301
|
+
}
|
|
302
|
+
<span class="mj-playbook-pill" [style.color]="GetStepColor(step)">{{ GetStepTypeLabel(step) }}</span>
|
|
303
|
+
@if (step.Status !== 'Active') {
|
|
304
|
+
<span class="mj-playbook-status" [attr.data-status]="step.Status">{{ step.Status }}</span>
|
|
305
|
+
}
|
|
306
|
+
</div>
|
|
307
|
+
<div class="mj-playbook-sub">{{ GetConfiguredItem(step) }}</div>
|
|
308
|
+
@if (step.Description) {
|
|
309
|
+
<div class="mj-playbook-desc">{{ step.Description }}</div>
|
|
310
|
+
}
|
|
311
|
+
@let outPaths = GetOutgoingPaths(step);
|
|
312
|
+
@if (outPaths.length > 0) {
|
|
313
|
+
<div class="mj-playbook-branches">
|
|
314
|
+
@for (path of outPaths; track path.ID) {
|
|
315
|
+
<span class="mj-playbook-branch" [class.mj-playbook-branch--cond]="!!path.Condition?.trim()">
|
|
316
|
+
<i class="fa-solid" [class.fa-code-branch]="!!path.Condition?.trim()" [class.fa-arrow-right]="!path.Condition?.trim()" aria-hidden="true"></i>
|
|
317
|
+
@if (path.Condition?.trim()) {
|
|
318
|
+
<span class="mj-playbook-branch-cond">{{ path.Condition }}</span>
|
|
319
|
+
<span>→</span>
|
|
320
|
+
}
|
|
321
|
+
<span>{{ ResolveStepName(path.DestinationStepID, path.DestinationStep) }}</span>
|
|
322
|
+
</span>
|
|
229
323
|
}
|
|
230
|
-
</
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
}
|
|
240
|
-
</div>
|
|
241
|
-
</div>
|
|
242
|
-
|
|
243
|
-
<!-- Paths Section -->
|
|
244
|
-
<div class="mj-step-list-section">
|
|
245
|
-
<div class="mj-step-list-section-header">
|
|
246
|
-
<h4><i class="fa-solid fa-link"></i> Paths ({{ Paths.length }})</h4>
|
|
247
|
-
</div>
|
|
248
|
-
<div class="mj-step-list-table-wrap">
|
|
249
|
-
@if (Paths.length > 0) {
|
|
250
|
-
<table class="mj-step-list-table">
|
|
251
|
-
<thead>
|
|
252
|
-
<tr>
|
|
253
|
-
<th>From</th>
|
|
254
|
-
<th>To</th>
|
|
255
|
-
<th>Condition</th>
|
|
256
|
-
<th>Priority</th>
|
|
257
|
-
</tr>
|
|
258
|
-
</thead>
|
|
259
|
-
<tbody>
|
|
260
|
-
@for (path of Paths; track path) {
|
|
261
|
-
<tr>
|
|
262
|
-
<td>{{ path.OriginStep }}</td>
|
|
263
|
-
<td>{{ path.DestinationStep }}</td>
|
|
264
|
-
<td class="mj-step-list-condition">{{ path.Condition || '(always)' }}</td>
|
|
265
|
-
<td>{{ path.Priority }}</td>
|
|
266
|
-
</tr>
|
|
267
|
-
}
|
|
268
|
-
</tbody>
|
|
269
|
-
</table>
|
|
270
|
-
}
|
|
271
|
-
@if (Paths.length === 0) {
|
|
272
|
-
<mj-empty-state class="mj-step-list-empty" Size="compact" Icon="" Title="No paths defined" />
|
|
273
|
-
}
|
|
274
|
-
</div>
|
|
324
|
+
</div>
|
|
325
|
+
}
|
|
326
|
+
</div>
|
|
327
|
+
</div>
|
|
328
|
+
}
|
|
329
|
+
</div>
|
|
330
|
+
} @else {
|
|
331
|
+
<mj-empty-state class="mj-step-list-empty" Size="compact" Icon="fa-solid fa-list-ol" Title="No steps defined yet" />
|
|
332
|
+
}
|
|
275
333
|
</div>
|
|
276
334
|
</div>
|
|
277
|
-
`, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: ["\n .mj-step-list {\n padding:
|
|
335
|
+
`, encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: ["\n .mj-step-list {\n padding: var(--mj-space-3-5, 14px);\n overflow-y: auto;\n height: 100%;\n background: var(--mj-bg-surface);\n }\n\n .mj-step-list-section-header {\n display: flex;\n align-items: center;\n justify-content: space-between;\n margin-bottom: var(--mj-space-3);\n }\n\n .mj-step-list-section-header h4 {\n font-size: var(--mj-text-xs);\n font-weight: var(--mj-font-bold);\n text-transform: uppercase;\n letter-spacing: 0.05em;\n color: var(--mj-text-muted);\n margin: 0;\n display: flex;\n align-items: center;\n gap: 6px;\n }\n\n .mj-step-list-summary {\n font-size: 11px;\n color: var(--mj-text-muted);\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n border-radius: var(--mj-radius-full);\n padding: 2px 8px;\n }\n\n .mj-playbook-cards {\n display: flex;\n flex-direction: column;\n gap: var(--mj-space-2);\n }\n\n .mj-playbook-card {\n display: flex;\n align-items: flex-start;\n gap: var(--mj-space-2-5);\n padding: 10px 12px;\n border-radius: var(--mj-radius-md);\n border: 1px solid var(--mj-border-default);\n background: var(--mj-bg-surface-card);\n cursor: pointer;\n transition: border-color var(--mj-transition-fast), background-color var(--mj-transition-fast), box-shadow var(--mj-transition-fast);\n }\n\n .mj-playbook-card:hover {\n border-color: var(--mj-brand-primary-light);\n background: var(--mj-bg-surface-hover);\n }\n\n .mj-playbook-card--selected {\n border-color: var(--mj-brand-primary);\n background: color-mix(in srgb, var(--mj-brand-primary) 8%, var(--mj-bg-surface));\n box-shadow: var(--mj-shadow-sm);\n }\n\n .mj-playbook-card--loop {\n border-left: 3px solid var(--mj-brand-tertiary);\n }\n\n .mj-playbook-card--disabled {\n opacity: 0.55;\n }\n\n .mj-playbook-num {\n width: 22px;\n height: 22px;\n border-radius: 6px;\n background: var(--mj-bg-surface-sunken);\n border: 1px solid var(--mj-border-default);\n color: var(--mj-text-secondary);\n font-family: var(--mj-font-family-mono);\n font-size: 11px;\n font-weight: var(--mj-font-bold);\n display: flex;\n align-items: center;\n justify-content: center;\n flex-shrink: 0;\n margin-top: 2px;\n }\n\n .mj-playbook-sq {\n width: 28px;\n height: 28px;\n border-radius: var(--mj-radius-md);\n display: flex;\n align-items: center;\n justify-content: center;\n font-size: 12px;\n flex-shrink: 0;\n }\n\n .mj-playbook-main {\n flex: 1;\n min-width: 0;\n display: flex;\n flex-direction: column;\n gap: 3px;\n }\n\n .mj-playbook-title-row {\n display: flex;\n align-items: center;\n gap: 6px;\n flex-wrap: wrap;\n }\n\n .mj-playbook-name {\n font-size: var(--mj-text-xs);\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-primary);\n }\n\n .mj-playbook-pill {\n font-size: 10px;\n font-weight: var(--mj-font-semibold);\n padding: 1px 6px;\n border-radius: var(--mj-radius-sm);\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n }\n\n .mj-playbook-pill--start {\n background: var(--mj-status-success-bg);\n border-color: color-mix(in srgb, var(--mj-status-success-border) 45%, transparent);\n color: var(--mj-status-success-text);\n }\n\n .mj-playbook-status {\n font-size: 10px;\n font-weight: var(--mj-font-semibold);\n color: var(--mj-text-muted);\n }\n\n .mj-playbook-status[data-status=\"Pending\"] { color: var(--mj-status-warning-text); }\n\n .mj-playbook-sub {\n font-size: 11px;\n color: var(--mj-text-secondary);\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n }\n\n .mj-playbook-desc {\n font-size: 11px;\n color: var(--mj-text-muted);\n line-height: 1.4;\n }\n\n .mj-playbook-branches {\n display: flex;\n flex-wrap: wrap;\n gap: 4px;\n margin-top: 4px;\n }\n\n .mj-playbook-branch {\n display: inline-flex;\n align-items: center;\n gap: 4px;\n font-size: 10px;\n padding: 2px 6px;\n border-radius: var(--mj-radius-sm);\n background: var(--mj-bg-surface);\n border: 1px solid var(--mj-border-default);\n color: var(--mj-text-secondary);\n max-width: 100%;\n }\n\n .mj-playbook-branch--cond {\n border-style: dashed;\n border-color: var(--mj-status-warning-border);\n background: var(--mj-status-warning-bg);\n color: var(--mj-status-warning-text);\n }\n\n .mj-playbook-branch-cond {\n font-family: var(--mj-font-family-mono);\n max-width: 120px;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n\n .mj-step-list-empty {\n padding: 24px;\n text-align: center;\n }\n "] }]
|
|
278
336
|
}], null, { Steps: [{
|
|
279
337
|
type: Input
|
|
280
338
|
}], Paths: [{
|
|
@@ -284,5 +342,5 @@ export class AgentStepListComponent {
|
|
|
284
342
|
}], StepClicked: [{
|
|
285
343
|
type: Output
|
|
286
344
|
}] }); })();
|
|
287
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(AgentStepListComponent, { className: "AgentStepListComponent", filePath: "src/lib/agent-editor/agent-step-list.component.ts", lineNumber:
|
|
345
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(AgentStepListComponent, { className: "AgentStepListComponent", filePath: "src/lib/agent-editor/agent-step-list.component.ts", lineNumber: 278 }); })();
|
|
288
346
|
//# sourceMappingURL=agent-step-list.component.js.map
|