@uipath/apollo-react 3.54.1 → 3.55.0-pr354.db46463
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/canvas/components/AddNodePanel/AddNodePanel.cjs +1 -1
- package/dist/canvas/components/AddNodePanel/AddNodePanel.js +1 -1
- package/dist/canvas/components/AgentCanvas/AgentFlow.cjs +6 -1
- package/dist/canvas/components/AgentCanvas/AgentFlow.constants.cjs +5 -2
- package/dist/canvas/components/AgentCanvas/AgentFlow.constants.d.ts +2 -1
- package/dist/canvas/components/AgentCanvas/AgentFlow.constants.d.ts.map +1 -1
- package/dist/canvas/components/AgentCanvas/AgentFlow.constants.js +5 -2
- package/dist/canvas/components/AgentCanvas/AgentFlow.d.ts.map +1 -1
- package/dist/canvas/components/AgentCanvas/AgentFlow.js +6 -1
- package/dist/canvas/components/AgentCanvas/AgentFlow.stories.cjs +29 -0
- package/dist/canvas/components/AgentCanvas/AgentFlow.stories.d.ts.map +1 -1
- package/dist/canvas/components/AgentCanvas/AgentFlow.stories.js +29 -0
- package/dist/canvas/components/AgentCanvas/agent-flow.manifest.cjs +35 -1
- package/dist/canvas/components/AgentCanvas/agent-flow.manifest.d.ts +1 -0
- package/dist/canvas/components/AgentCanvas/agent-flow.manifest.d.ts.map +1 -1
- package/dist/canvas/components/AgentCanvas/agent-flow.manifest.js +33 -2
- package/dist/canvas/components/AgentCanvas/nodes/AgentNode.cjs +10 -4
- package/dist/canvas/components/AgentCanvas/nodes/AgentNode.d.ts +3 -1
- package/dist/canvas/components/AgentCanvas/nodes/AgentNode.d.ts.map +1 -1
- package/dist/canvas/components/AgentCanvas/nodes/AgentNode.js +10 -4
- package/dist/canvas/components/AgentCanvas/nodes/ResourceNode.cjs +10 -2
- package/dist/canvas/components/AgentCanvas/nodes/ResourceNode.d.ts.map +1 -1
- package/dist/canvas/components/AgentCanvas/nodes/ResourceNode.js +11 -3
- package/dist/canvas/components/Toolbox/ListView.cjs +54 -34
- package/dist/canvas/components/Toolbox/ListView.d.ts +12 -2
- package/dist/canvas/components/Toolbox/ListView.d.ts.map +1 -1
- package/dist/canvas/components/Toolbox/ListView.js +51 -34
- package/dist/canvas/components/Toolbox/ListView.styles.cjs +7 -1
- package/dist/canvas/components/Toolbox/ListView.styles.d.ts.map +1 -1
- package/dist/canvas/components/Toolbox/ListView.styles.js +7 -1
- package/dist/canvas/components/Toolbox/SearchBox.cjs +12 -4
- package/dist/canvas/components/Toolbox/SearchBox.d.ts +3 -0
- package/dist/canvas/components/Toolbox/SearchBox.d.ts.map +1 -1
- package/dist/canvas/components/Toolbox/SearchBox.js +12 -4
- package/dist/canvas/components/Toolbox/Toolbox.cjs +143 -4
- package/dist/canvas/components/Toolbox/Toolbox.d.ts.map +1 -1
- package/dist/canvas/components/Toolbox/Toolbox.js +143 -4
- package/dist/canvas/icons/A2aIcon.cjs +83 -0
- package/dist/canvas/icons/A2aIcon.d.ts +5 -0
- package/dist/canvas/icons/A2aIcon.d.ts.map +1 -0
- package/dist/canvas/icons/A2aIcon.js +49 -0
- package/dist/canvas/icons/index.cjs +6 -2
- package/dist/canvas/icons/index.d.ts +1 -0
- package/dist/canvas/icons/index.d.ts.map +1 -1
- package/dist/canvas/icons/index.js +2 -1
- package/dist/canvas/storybook-utils/mocks/resources.cjs +28 -0
- package/dist/canvas/storybook-utils/mocks/resources.d.ts +9 -1
- package/dist/canvas/storybook-utils/mocks/resources.d.ts.map +1 -1
- package/dist/canvas/storybook-utils/mocks/resources.js +26 -1
- package/dist/canvas/types.d.ts +21 -3
- package/dist/canvas/types.d.ts.map +1 -1
- package/dist/canvas/utils/auto-layout.cjs +4 -2
- package/dist/canvas/utils/auto-layout.d.ts.map +1 -1
- package/dist/canvas/utils/auto-layout.js +4 -2
- package/dist/canvas/utils/props-helpers.cjs +17 -2
- package/dist/canvas/utils/props-helpers.d.ts.map +1 -1
- package/dist/canvas/utils/props-helpers.js +17 -2
- package/dist/core/tokens/css/theme-variables.css +4 -4
- package/dist/core/tokens/scss/theme-variables.scss +4 -4
- package/package.json +3 -3
|
@@ -69,7 +69,7 @@ const AddNodePanel_AddNodePanel = /*#__PURE__*/ (0, external_react_namespaceObje
|
|
|
69
69
|
onNodeSelect
|
|
70
70
|
]);
|
|
71
71
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_Toolbox_index_cjs_namespaceObject.Toolbox, {
|
|
72
|
-
title: title ?? 'Add
|
|
72
|
+
title: title ?? 'Add node',
|
|
73
73
|
initialItems: nodeListOptions,
|
|
74
74
|
loading: loading,
|
|
75
75
|
onItemSelect: handleNodeListItemSelect,
|
|
@@ -41,7 +41,7 @@ const AddNodePanel_AddNodePanel = /*#__PURE__*/ memo(function({ onNodeSelect, on
|
|
|
41
41
|
onNodeSelect
|
|
42
42
|
]);
|
|
43
43
|
return /*#__PURE__*/ jsx(Toolbox, {
|
|
44
|
-
title: title ?? 'Add
|
|
44
|
+
title: title ?? 'Add node',
|
|
45
45
|
initialItems: nodeListOptions,
|
|
46
46
|
loading: loading,
|
|
47
47
|
onItemSelect: handleNodeListItemSelect,
|
|
@@ -103,6 +103,7 @@ const createAgentNodeWrapper = (handlers)=>(props)=>{
|
|
|
103
103
|
const hasTool = nodes.some((node)=>(0, external_types_cjs_namespaceObject.isAgentFlowResourceNode)(node) && 'tool' === node.data.type && node.data.parentNodeId === props.id);
|
|
104
104
|
const hasMcp = false !== handlers.enableMcpTools && nodes.some((node)=>(0, external_types_cjs_namespaceObject.isAgentFlowResourceNode)(node) && 'mcp' === node.data.type && node.data.parentNodeId === props.id);
|
|
105
105
|
const hasMemory = nodes.some((node)=>(0, external_types_cjs_namespaceObject.isAgentFlowResourceNode)(node) && 'memorySpace' === node.data.type && node.data.parentNodeId === props.id);
|
|
106
|
+
const hasA2a = true === handlers.enableA2a && nodes.some((node)=>(0, external_types_cjs_namespaceObject.isAgentFlowResourceNode)(node) && 'a2a' === node.data.type && node.data.parentNodeId === props.id);
|
|
106
107
|
const agentRunning = (0, props_helpers_cjs_namespaceObject.hasAgentRunning)(storeProps.spans);
|
|
107
108
|
const resourceRunning = nodes.some((node)=>(0, external_types_cjs_namespaceObject.isAgentFlowResourceNode)(node) && 'view' === storeProps.mode && node.data.parentNodeId === props.id && node.data.hasRunning);
|
|
108
109
|
const agentProcessing = props.data.isProcessing;
|
|
@@ -124,6 +125,8 @@ const createAgentNodeWrapper = (handlers)=>(props)=>{
|
|
|
124
125
|
hasTool: hasTool,
|
|
125
126
|
hasMcp: hasMcp,
|
|
126
127
|
hasMemory: hasMemory,
|
|
128
|
+
hasA2a: hasA2a,
|
|
129
|
+
a2aEnabled: true === handlers.enableA2a,
|
|
127
130
|
mcpEnabled: false !== handlers.enableMcpTools,
|
|
128
131
|
mode: storeProps.mode,
|
|
129
132
|
hasError: hasError,
|
|
@@ -163,7 +166,7 @@ const createResourceNodeWrapper = (opts)=>(props)=>{
|
|
|
163
166
|
suggestionGroupVersion: opts.suggestionGroupVersion
|
|
164
167
|
});
|
|
165
168
|
};
|
|
166
|
-
const AgentFlowInner = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(({ children, mode, spans, onEnable, onDisable, onAddBreakpoint, onRemoveBreakpoint, onAddGuardrail, onGoToSource, onErrorAction, onAddResource: _onAddResource, onSelectResource, setSpanForSelectedNode, getNodeFromSelectedSpan, onExpandResource, onCollapseResource, agentNodeTranslations, resourceNodeTranslations, stickyNoteNodeTranslations, canvasTranslations, enableTimelinePlayer, canvasRef, enableMcpTools, enableMemory, enableStickyNotes, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroup, onAgentNodePositionChange, onResourceNodePositionChange, onOrganize, onUpdateStickyNote, zoomLevel, onZoomLevelChange })=>{
|
|
169
|
+
const AgentFlowInner = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(({ children, mode, spans, onEnable, onDisable, onAddBreakpoint, onRemoveBreakpoint, onAddGuardrail, onGoToSource, onErrorAction, onAddResource: _onAddResource, onSelectResource, setSpanForSelectedNode, getNodeFromSelectedSpan, onExpandResource, onCollapseResource, agentNodeTranslations, resourceNodeTranslations, stickyNoteNodeTranslations, canvasTranslations, enableTimelinePlayer, canvasRef, enableMcpTools, enableMemory, enableA2a, enableStickyNotes, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroup, onAgentNodePositionChange, onResourceNodePositionChange, onOrganize, onUpdateStickyNote, zoomLevel, onZoomLevelChange })=>{
|
|
167
170
|
const { nodes, edges, onNodesChange, onEdgesChange, onConnect, autoArrange, setSelectedNodeId, selectedNodeId, setDragging, expandAgent, collapseAgent, createResourcePlaceholder, actOnSuggestionGroup, currentSuggestionIndex, navigateToNextSuggestion, navigateToPreviousSuggestion, addStickyNote, paneContextMenu, openPaneContextMenu, closePaneContextMenu } = (0, agent_flow_store_cjs_namespaceObject.useAgentFlowStore)();
|
|
168
171
|
const nodeTypesBase = (0, external_react_namespaceObject.useMemo)(()=>({
|
|
169
172
|
stickyNote: (props)=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_StickyNoteNode_index_cjs_namespaceObject.StickyNoteNode, {
|
|
@@ -222,6 +225,7 @@ const AgentFlowInner = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(({
|
|
|
222
225
|
suggestionTranslations,
|
|
223
226
|
enableMcpTools,
|
|
224
227
|
enableMemory,
|
|
228
|
+
enableA2a,
|
|
225
229
|
enableInstructions,
|
|
226
230
|
healthScore,
|
|
227
231
|
onHealthScoreClick,
|
|
@@ -405,6 +409,7 @@ const AgentFlowInner = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(({
|
|
|
405
409
|
if (!(0, external_types_cjs_namespaceObject.isAgentFlowResourceNode)(node)) return true;
|
|
406
410
|
if (node.data.isVirtual) return true;
|
|
407
411
|
if ('memorySpace' === node.data.type) return !!enableMemory;
|
|
412
|
+
if ('a2a' === node.data.type) return !!enableA2a;
|
|
408
413
|
return true;
|
|
409
414
|
});
|
|
410
415
|
const defaultViewport = (0, external_react_namespaceObject.useMemo)(()=>{
|
|
@@ -35,6 +35,7 @@ let AgentFlow_constants_ResourceNodeType = /*#__PURE__*/ function(ResourceNodeTy
|
|
|
35
35
|
ResourceNodeType["MCP"] = "mcp";
|
|
36
36
|
ResourceNodeType["Tool"] = "tool";
|
|
37
37
|
ResourceNodeType["MemorySpace"] = "memorySpace";
|
|
38
|
+
ResourceNodeType["A2A"] = "a2a";
|
|
38
39
|
return ResourceNodeType;
|
|
39
40
|
}({});
|
|
40
41
|
const ResourceNodeTypeToPosition = {
|
|
@@ -42,14 +43,16 @@ const ResourceNodeTypeToPosition = {
|
|
|
42
43
|
[AgentFlow_constants_ResourceNodeType.Escalation]: react_cjs_namespaceObject.Position.Top,
|
|
43
44
|
[AgentFlow_constants_ResourceNodeType.MCP]: react_cjs_namespaceObject.Position.Bottom,
|
|
44
45
|
[AgentFlow_constants_ResourceNodeType.Tool]: react_cjs_namespaceObject.Position.Bottom,
|
|
45
|
-
[AgentFlow_constants_ResourceNodeType.MemorySpace]: react_cjs_namespaceObject.Position.Top
|
|
46
|
+
[AgentFlow_constants_ResourceNodeType.MemorySpace]: react_cjs_namespaceObject.Position.Top,
|
|
47
|
+
[AgentFlow_constants_ResourceNodeType.A2A]: react_cjs_namespaceObject.Position.Bottom
|
|
46
48
|
};
|
|
47
49
|
const ResourceNodeTypeOrder = {
|
|
48
50
|
[AgentFlow_constants_ResourceNodeType.MemorySpace]: 0,
|
|
49
51
|
[AgentFlow_constants_ResourceNodeType.Escalation]: 1,
|
|
50
52
|
[AgentFlow_constants_ResourceNodeType.Context]: 2,
|
|
51
53
|
[AgentFlow_constants_ResourceNodeType.Tool]: 3,
|
|
52
|
-
[AgentFlow_constants_ResourceNodeType.MCP]: 4
|
|
54
|
+
[AgentFlow_constants_ResourceNodeType.MCP]: 4,
|
|
55
|
+
[AgentFlow_constants_ResourceNodeType.A2A]: 5
|
|
53
56
|
};
|
|
54
57
|
exports.ResourceNodeType = __webpack_exports__.ResourceNodeType;
|
|
55
58
|
exports.ResourceNodeTypeOrder = __webpack_exports__.ResourceNodeTypeOrder;
|
|
@@ -4,7 +4,8 @@ export declare enum ResourceNodeType {
|
|
|
4
4
|
Escalation = "escalation",
|
|
5
5
|
MCP = "mcp",
|
|
6
6
|
Tool = "tool",
|
|
7
|
-
MemorySpace = "memorySpace"
|
|
7
|
+
MemorySpace = "memorySpace",
|
|
8
|
+
A2A = "a2a"
|
|
8
9
|
}
|
|
9
10
|
export declare const ResourceNodeTypeToPosition: Record<ResourceNodeType, Position>;
|
|
10
11
|
export declare const ResourceNodeTypeOrder: Record<ResourceNodeType, number>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AgentFlow.constants.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/AgentFlow.constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,0CAA0C,CAAC;AAEpE,oBAAY,gBAAgB;IAC1B,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,GAAG,QAAQ;IACX,IAAI,SAAS;IACb,WAAW,gBAAgB;
|
|
1
|
+
{"version":3,"file":"AgentFlow.constants.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/AgentFlow.constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,0CAA0C,CAAC;AAEpE,oBAAY,gBAAgB;IAC1B,OAAO,YAAY;IACnB,UAAU,eAAe;IACzB,GAAG,QAAQ;IACX,IAAI,SAAS;IACb,WAAW,gBAAgB;IAC3B,GAAG,QAAQ;CACZ;AAED,eAAO,MAAM,0BAA0B,EAAE,MAAM,CAAC,gBAAgB,EAAE,QAAQ,CAOzE,CAAC;AAKF,eAAO,MAAM,qBAAqB,EAAE,MAAM,CAAC,gBAAgB,EAAE,MAAM,CAOlE,CAAC"}
|
|
@@ -5,6 +5,7 @@ let AgentFlow_constants_ResourceNodeType = /*#__PURE__*/ function(ResourceNodeTy
|
|
|
5
5
|
ResourceNodeType["MCP"] = "mcp";
|
|
6
6
|
ResourceNodeType["Tool"] = "tool";
|
|
7
7
|
ResourceNodeType["MemorySpace"] = "memorySpace";
|
|
8
|
+
ResourceNodeType["A2A"] = "a2a";
|
|
8
9
|
return ResourceNodeType;
|
|
9
10
|
}({});
|
|
10
11
|
const ResourceNodeTypeToPosition = {
|
|
@@ -12,13 +13,15 @@ const ResourceNodeTypeToPosition = {
|
|
|
12
13
|
[AgentFlow_constants_ResourceNodeType.Escalation]: Position.Top,
|
|
13
14
|
[AgentFlow_constants_ResourceNodeType.MCP]: Position.Bottom,
|
|
14
15
|
[AgentFlow_constants_ResourceNodeType.Tool]: Position.Bottom,
|
|
15
|
-
[AgentFlow_constants_ResourceNodeType.MemorySpace]: Position.Top
|
|
16
|
+
[AgentFlow_constants_ResourceNodeType.MemorySpace]: Position.Top,
|
|
17
|
+
[AgentFlow_constants_ResourceNodeType.A2A]: Position.Bottom
|
|
16
18
|
};
|
|
17
19
|
const ResourceNodeTypeOrder = {
|
|
18
20
|
[AgentFlow_constants_ResourceNodeType.MemorySpace]: 0,
|
|
19
21
|
[AgentFlow_constants_ResourceNodeType.Escalation]: 1,
|
|
20
22
|
[AgentFlow_constants_ResourceNodeType.Context]: 2,
|
|
21
23
|
[AgentFlow_constants_ResourceNodeType.Tool]: 3,
|
|
22
|
-
[AgentFlow_constants_ResourceNodeType.MCP]: 4
|
|
24
|
+
[AgentFlow_constants_ResourceNodeType.MCP]: 4,
|
|
25
|
+
[AgentFlow_constants_ResourceNodeType.A2A]: 5
|
|
23
26
|
};
|
|
24
27
|
export { AgentFlow_constants_ResourceNodeType as ResourceNodeType, ResourceNodeTypeOrder, ResourceNodeTypeToPosition };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AgentFlow.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/AgentFlow.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAI/C,OAAO,EAIL,KAAK,cAAc,EAcpB,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"AgentFlow.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/AgentFlow.tsx"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAI/C,OAAO,EAIL,KAAK,cAAc,EAcpB,MAAM,aAAa,CAAC;AAqsBrB,eAAO,MAAM,SAAS,GAAI,OAAO,iBAAiB,CAAC,cAAc,CAAC,4CAQjE,CAAC"}
|
|
@@ -65,6 +65,7 @@ const createAgentNodeWrapper = (handlers)=>(props)=>{
|
|
|
65
65
|
const hasTool = nodes.some((node)=>isAgentFlowResourceNode(node) && 'tool' === node.data.type && node.data.parentNodeId === props.id);
|
|
66
66
|
const hasMcp = false !== handlers.enableMcpTools && nodes.some((node)=>isAgentFlowResourceNode(node) && 'mcp' === node.data.type && node.data.parentNodeId === props.id);
|
|
67
67
|
const hasMemory = nodes.some((node)=>isAgentFlowResourceNode(node) && 'memorySpace' === node.data.type && node.data.parentNodeId === props.id);
|
|
68
|
+
const hasA2a = true === handlers.enableA2a && nodes.some((node)=>isAgentFlowResourceNode(node) && 'a2a' === node.data.type && node.data.parentNodeId === props.id);
|
|
68
69
|
const agentRunning = hasAgentRunning(storeProps.spans);
|
|
69
70
|
const resourceRunning = nodes.some((node)=>isAgentFlowResourceNode(node) && 'view' === storeProps.mode && node.data.parentNodeId === props.id && node.data.hasRunning);
|
|
70
71
|
const agentProcessing = props.data.isProcessing;
|
|
@@ -86,6 +87,8 @@ const createAgentNodeWrapper = (handlers)=>(props)=>{
|
|
|
86
87
|
hasTool: hasTool,
|
|
87
88
|
hasMcp: hasMcp,
|
|
88
89
|
hasMemory: hasMemory,
|
|
90
|
+
hasA2a: hasA2a,
|
|
91
|
+
a2aEnabled: true === handlers.enableA2a,
|
|
89
92
|
mcpEnabled: false !== handlers.enableMcpTools,
|
|
90
93
|
mode: storeProps.mode,
|
|
91
94
|
hasError: hasError,
|
|
@@ -125,7 +128,7 @@ const createResourceNodeWrapper = (opts)=>(props)=>{
|
|
|
125
128
|
suggestionGroupVersion: opts.suggestionGroupVersion
|
|
126
129
|
});
|
|
127
130
|
};
|
|
128
|
-
const AgentFlowInner = /*#__PURE__*/ memo(({ children, mode, spans, onEnable, onDisable, onAddBreakpoint, onRemoveBreakpoint, onAddGuardrail, onGoToSource, onErrorAction, onAddResource: _onAddResource, onSelectResource, setSpanForSelectedNode, getNodeFromSelectedSpan, onExpandResource, onCollapseResource, agentNodeTranslations, resourceNodeTranslations, stickyNoteNodeTranslations, canvasTranslations, enableTimelinePlayer, canvasRef, enableMcpTools, enableMemory, enableStickyNotes, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroup, onAgentNodePositionChange, onResourceNodePositionChange, onOrganize, onUpdateStickyNote, zoomLevel, onZoomLevelChange })=>{
|
|
131
|
+
const AgentFlowInner = /*#__PURE__*/ memo(({ children, mode, spans, onEnable, onDisable, onAddBreakpoint, onRemoveBreakpoint, onAddGuardrail, onGoToSource, onErrorAction, onAddResource: _onAddResource, onSelectResource, setSpanForSelectedNode, getNodeFromSelectedSpan, onExpandResource, onCollapseResource, agentNodeTranslations, resourceNodeTranslations, stickyNoteNodeTranslations, canvasTranslations, enableTimelinePlayer, canvasRef, enableMcpTools, enableMemory, enableA2a, enableStickyNotes, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroup, onAgentNodePositionChange, onResourceNodePositionChange, onOrganize, onUpdateStickyNote, zoomLevel, onZoomLevelChange })=>{
|
|
129
132
|
const { nodes, edges, onNodesChange, onEdgesChange, onConnect, autoArrange, setSelectedNodeId, selectedNodeId, setDragging, expandAgent, collapseAgent, createResourcePlaceholder, actOnSuggestionGroup, currentSuggestionIndex, navigateToNextSuggestion, navigateToPreviousSuggestion, addStickyNote, paneContextMenu, openPaneContextMenu, closePaneContextMenu } = useAgentFlowStore();
|
|
130
133
|
const nodeTypesBase = useMemo(()=>({
|
|
131
134
|
stickyNote: (props)=>/*#__PURE__*/ jsx(StickyNoteNode, {
|
|
@@ -184,6 +187,7 @@ const AgentFlowInner = /*#__PURE__*/ memo(({ children, mode, spans, onEnable, on
|
|
|
184
187
|
suggestionTranslations,
|
|
185
188
|
enableMcpTools,
|
|
186
189
|
enableMemory,
|
|
190
|
+
enableA2a,
|
|
187
191
|
enableInstructions,
|
|
188
192
|
healthScore,
|
|
189
193
|
onHealthScoreClick,
|
|
@@ -367,6 +371,7 @@ const AgentFlowInner = /*#__PURE__*/ memo(({ children, mode, spans, onEnable, on
|
|
|
367
371
|
if (!isAgentFlowResourceNode(node)) return true;
|
|
368
372
|
if (node.data.isVirtual) return true;
|
|
369
373
|
if ('memorySpace' === node.data.type) return !!enableMemory;
|
|
374
|
+
if ('a2a' === node.data.type) return !!enableA2a;
|
|
370
375
|
return true;
|
|
371
376
|
});
|
|
372
377
|
const defaultViewport = useMemo(()=>{
|
|
@@ -137,10 +137,21 @@ const sampleMcp = [
|
|
|
137
137
|
description: 'Using RPC to connect to a budget assistant server API'
|
|
138
138
|
}
|
|
139
139
|
];
|
|
140
|
+
const sampleA2aAgents = [
|
|
141
|
+
{
|
|
142
|
+
name: 'Billing Agent',
|
|
143
|
+
description: 'Handles billing inquiries via A2A'
|
|
144
|
+
},
|
|
145
|
+
{
|
|
146
|
+
name: 'Support Agent',
|
|
147
|
+
description: 'Customer support agent via A2A protocol'
|
|
148
|
+
}
|
|
149
|
+
];
|
|
140
150
|
let contextIndex = 0;
|
|
141
151
|
let toolIndex = 0;
|
|
142
152
|
let escalationIndex = 0;
|
|
143
153
|
let mcpIndex = 0;
|
|
154
|
+
let a2aIndex = 0;
|
|
144
155
|
const createSampleContext = ()=>{
|
|
145
156
|
const sample = sampleContexts[contextIndex % sampleContexts.length];
|
|
146
157
|
contextIndex++;
|
|
@@ -200,6 +211,18 @@ const createSampleMemorySpace = ()=>({
|
|
|
200
211
|
name: 'Agent Memory Space',
|
|
201
212
|
description: 'Memory space for the agent'
|
|
202
213
|
});
|
|
214
|
+
const createSampleA2a = ()=>{
|
|
215
|
+
const sample = sampleA2aAgents[a2aIndex % sampleA2aAgents.length];
|
|
216
|
+
a2aIndex++;
|
|
217
|
+
return {
|
|
218
|
+
id: generateResourceId(),
|
|
219
|
+
type: 'a2a',
|
|
220
|
+
name: sample.name,
|
|
221
|
+
description: sample.description,
|
|
222
|
+
hasBreakpoint: false,
|
|
223
|
+
hasGuardrails: false
|
|
224
|
+
};
|
|
225
|
+
};
|
|
203
226
|
const sampleResources = [
|
|
204
227
|
{
|
|
205
228
|
id: 'tool-slack',
|
|
@@ -419,6 +442,9 @@ const AgentFlowWrapper = ({ mode, initialResources = sampleResources, initialSti
|
|
|
419
442
|
case 'memorySpace':
|
|
420
443
|
newResource = createSampleMemorySpace();
|
|
421
444
|
break;
|
|
445
|
+
case 'a2a':
|
|
446
|
+
newResource = createSampleA2a();
|
|
447
|
+
break;
|
|
422
448
|
default:
|
|
423
449
|
return;
|
|
424
450
|
}
|
|
@@ -721,6 +747,9 @@ const DesignModePlayground = ()=>{
|
|
|
721
747
|
case 'memorySpace':
|
|
722
748
|
newResource = createSampleMemorySpace();
|
|
723
749
|
break;
|
|
750
|
+
case 'a2a':
|
|
751
|
+
newResource = createSampleA2a();
|
|
752
|
+
break;
|
|
724
753
|
default:
|
|
725
754
|
return;
|
|
726
755
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AgentFlow.stories.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/AgentFlow.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAkB5D,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,SAAS,CAkBhC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,SAAS,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"AgentFlow.stories.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/AgentFlow.stories.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,QAAQ,EAAE,MAAM,uBAAuB,CAAC;AAkB5D,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAExC,QAAA,MAAM,IAAI,EAAE,IAAI,CAAC,OAAO,SAAS,CAkBhC,CAAC;AACF,eAAe,IAAI,CAAC;AAEpB,KAAK,KAAK,GAAG,QAAQ,CAAC,OAAO,SAAS,CAAC,CAAC;AAiiDxC,eAAO,MAAM,UAAU,EAAE,KAoBxB,CAAC;AA8EF,eAAO,MAAM,QAAQ,EAAE,KAgBtB,CAAC;AAyFF,eAAO,MAAM,WAAW,EAAE,KAazB,CAAC;AAmDF,eAAO,MAAM,mBAAmB,EAAE,KAajC,CAAC;AA+HF,eAAO,MAAM,oBAAoB,EAAE,KAalC,CAAC"}
|
|
@@ -104,10 +104,21 @@ const sampleMcp = [
|
|
|
104
104
|
description: 'Using RPC to connect to a budget assistant server API'
|
|
105
105
|
}
|
|
106
106
|
];
|
|
107
|
+
const sampleA2aAgents = [
|
|
108
|
+
{
|
|
109
|
+
name: 'Billing Agent',
|
|
110
|
+
description: 'Handles billing inquiries via A2A'
|
|
111
|
+
},
|
|
112
|
+
{
|
|
113
|
+
name: 'Support Agent',
|
|
114
|
+
description: 'Customer support agent via A2A protocol'
|
|
115
|
+
}
|
|
116
|
+
];
|
|
107
117
|
let contextIndex = 0;
|
|
108
118
|
let toolIndex = 0;
|
|
109
119
|
let escalationIndex = 0;
|
|
110
120
|
let mcpIndex = 0;
|
|
121
|
+
let a2aIndex = 0;
|
|
111
122
|
const createSampleContext = ()=>{
|
|
112
123
|
const sample = sampleContexts[contextIndex % sampleContexts.length];
|
|
113
124
|
contextIndex++;
|
|
@@ -167,6 +178,18 @@ const createSampleMemorySpace = ()=>({
|
|
|
167
178
|
name: 'Agent Memory Space',
|
|
168
179
|
description: 'Memory space for the agent'
|
|
169
180
|
});
|
|
181
|
+
const createSampleA2a = ()=>{
|
|
182
|
+
const sample = sampleA2aAgents[a2aIndex % sampleA2aAgents.length];
|
|
183
|
+
a2aIndex++;
|
|
184
|
+
return {
|
|
185
|
+
id: generateResourceId(),
|
|
186
|
+
type: 'a2a',
|
|
187
|
+
name: sample.name,
|
|
188
|
+
description: sample.description,
|
|
189
|
+
hasBreakpoint: false,
|
|
190
|
+
hasGuardrails: false
|
|
191
|
+
};
|
|
192
|
+
};
|
|
170
193
|
const sampleResources = [
|
|
171
194
|
{
|
|
172
195
|
id: 'tool-slack',
|
|
@@ -386,6 +409,9 @@ const AgentFlowWrapper = ({ mode, initialResources = sampleResources, initialSti
|
|
|
386
409
|
case 'memorySpace':
|
|
387
410
|
newResource = createSampleMemorySpace();
|
|
388
411
|
break;
|
|
412
|
+
case 'a2a':
|
|
413
|
+
newResource = createSampleA2a();
|
|
414
|
+
break;
|
|
389
415
|
default:
|
|
390
416
|
return;
|
|
391
417
|
}
|
|
@@ -688,6 +714,9 @@ const DesignModePlayground = ()=>{
|
|
|
688
714
|
case 'memorySpace':
|
|
689
715
|
newResource = createSampleMemorySpace();
|
|
690
716
|
break;
|
|
717
|
+
case 'a2a':
|
|
718
|
+
newResource = createSampleA2a();
|
|
719
|
+
break;
|
|
691
720
|
default:
|
|
692
721
|
return;
|
|
693
722
|
}
|
|
@@ -24,6 +24,7 @@ var __webpack_require__ = {};
|
|
|
24
24
|
var __webpack_exports__ = {};
|
|
25
25
|
__webpack_require__.r(__webpack_exports__);
|
|
26
26
|
__webpack_require__.d(__webpack_exports__, {
|
|
27
|
+
a2aResourceManifest: ()=>a2aResourceManifest,
|
|
27
28
|
agentFlowCategories: ()=>agentFlowCategories,
|
|
28
29
|
agentFlowManifest: ()=>agentFlowManifest,
|
|
29
30
|
autonomousAgentManifest: ()=>autonomousAgentManifest,
|
|
@@ -321,6 +322,36 @@ const memoryResourceManifest = {
|
|
|
321
322
|
}
|
|
322
323
|
]
|
|
323
324
|
};
|
|
325
|
+
const a2aResourceManifest = {
|
|
326
|
+
nodeType: 'uipath.resource.a2a',
|
|
327
|
+
version: '1.0.0',
|
|
328
|
+
category: 'resource',
|
|
329
|
+
tags: [
|
|
330
|
+
'resource',
|
|
331
|
+
'a2a',
|
|
332
|
+
'agent-to-agent',
|
|
333
|
+
'protocol'
|
|
334
|
+
],
|
|
335
|
+
sortOrder: 6,
|
|
336
|
+
display: {
|
|
337
|
+
label: 'A2A Resource',
|
|
338
|
+
description: 'Agent-to-Agent Protocol resource',
|
|
339
|
+
icon: 'hub',
|
|
340
|
+
shape: 'circle'
|
|
341
|
+
},
|
|
342
|
+
handleConfiguration: [
|
|
343
|
+
{
|
|
344
|
+
position: 'top',
|
|
345
|
+
handles: [
|
|
346
|
+
{
|
|
347
|
+
id: 'input',
|
|
348
|
+
type: 'target',
|
|
349
|
+
handleType: 'artifact'
|
|
350
|
+
}
|
|
351
|
+
]
|
|
352
|
+
}
|
|
353
|
+
]
|
|
354
|
+
};
|
|
324
355
|
const agentFlowManifest = {
|
|
325
356
|
version: '1.0.0',
|
|
326
357
|
categories: agentFlowCategories,
|
|
@@ -331,9 +362,11 @@ const agentFlowManifest = {
|
|
|
331
362
|
toolResourceManifest,
|
|
332
363
|
mcpResourceManifest,
|
|
333
364
|
escalationResourceManifest,
|
|
334
|
-
memoryResourceManifest
|
|
365
|
+
memoryResourceManifest,
|
|
366
|
+
a2aResourceManifest
|
|
335
367
|
]
|
|
336
368
|
};
|
|
369
|
+
exports.a2aResourceManifest = __webpack_exports__.a2aResourceManifest;
|
|
337
370
|
exports.agentFlowCategories = __webpack_exports__.agentFlowCategories;
|
|
338
371
|
exports.agentFlowManifest = __webpack_exports__.agentFlowManifest;
|
|
339
372
|
exports.autonomousAgentManifest = __webpack_exports__.autonomousAgentManifest;
|
|
@@ -344,6 +377,7 @@ exports.mcpResourceManifest = __webpack_exports__.mcpResourceManifest;
|
|
|
344
377
|
exports.memoryResourceManifest = __webpack_exports__.memoryResourceManifest;
|
|
345
378
|
exports.toolResourceManifest = __webpack_exports__.toolResourceManifest;
|
|
346
379
|
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
380
|
+
"a2aResourceManifest",
|
|
347
381
|
"agentFlowCategories",
|
|
348
382
|
"agentFlowManifest",
|
|
349
383
|
"autonomousAgentManifest",
|
|
@@ -7,6 +7,7 @@ export declare const toolResourceManifest: NodeManifest;
|
|
|
7
7
|
export declare const mcpResourceManifest: NodeManifest;
|
|
8
8
|
export declare const escalationResourceManifest: NodeManifest;
|
|
9
9
|
export declare const memoryResourceManifest: NodeManifest;
|
|
10
|
+
export declare const a2aResourceManifest: NodeManifest;
|
|
10
11
|
export declare const agentFlowManifest: {
|
|
11
12
|
version: string;
|
|
12
13
|
categories: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"agent-flow.manifest.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/agent-flow.manifest.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAMnF,eAAO,MAAM,mBAAmB,EAAE,gBAAgB,EAmBjD,CAAC;AAMF,eAAO,MAAM,2BAA2B,EAAE,YAsDzC,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,YAqDrC,CAAC;AAMF,eAAO,MAAM,uBAAuB,EAAE,YAwBrC,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,YAwBlC,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,YAwBjC,CAAC;AAEF,eAAO,MAAM,0BAA0B,EAAE,YAwBxC,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,YAwBpC,CAAC;AAMF,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
|
1
|
+
{"version":3,"file":"agent-flow.manifest.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/AgentCanvas/agent-flow.manifest.ts"],"names":[],"mappings":"AAOA,OAAO,KAAK,EAAE,gBAAgB,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAC;AAMnF,eAAO,MAAM,mBAAmB,EAAE,gBAAgB,EAmBjD,CAAC;AAMF,eAAO,MAAM,2BAA2B,EAAE,YAsDzC,CAAC;AAEF,eAAO,MAAM,uBAAuB,EAAE,YAqDrC,CAAC;AAMF,eAAO,MAAM,uBAAuB,EAAE,YAwBrC,CAAC;AAEF,eAAO,MAAM,oBAAoB,EAAE,YAwBlC,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,YAwBjC,CAAC;AAEF,eAAO,MAAM,0BAA0B,EAAE,YAwBxC,CAAC;AAEF,eAAO,MAAM,sBAAsB,EAAE,YAwBpC,CAAC;AAEF,eAAO,MAAM,mBAAmB,EAAE,YAwBjC,CAAC;AAMF,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAa7B,CAAC"}
|
|
@@ -285,6 +285,36 @@ const memoryResourceManifest = {
|
|
|
285
285
|
}
|
|
286
286
|
]
|
|
287
287
|
};
|
|
288
|
+
const a2aResourceManifest = {
|
|
289
|
+
nodeType: 'uipath.resource.a2a',
|
|
290
|
+
version: '1.0.0',
|
|
291
|
+
category: 'resource',
|
|
292
|
+
tags: [
|
|
293
|
+
'resource',
|
|
294
|
+
'a2a',
|
|
295
|
+
'agent-to-agent',
|
|
296
|
+
'protocol'
|
|
297
|
+
],
|
|
298
|
+
sortOrder: 6,
|
|
299
|
+
display: {
|
|
300
|
+
label: 'A2A Resource',
|
|
301
|
+
description: 'Agent-to-Agent Protocol resource',
|
|
302
|
+
icon: 'hub',
|
|
303
|
+
shape: 'circle'
|
|
304
|
+
},
|
|
305
|
+
handleConfiguration: [
|
|
306
|
+
{
|
|
307
|
+
position: 'top',
|
|
308
|
+
handles: [
|
|
309
|
+
{
|
|
310
|
+
id: 'input',
|
|
311
|
+
type: 'target',
|
|
312
|
+
handleType: 'artifact'
|
|
313
|
+
}
|
|
314
|
+
]
|
|
315
|
+
}
|
|
316
|
+
]
|
|
317
|
+
};
|
|
288
318
|
const agentFlowManifest = {
|
|
289
319
|
version: '1.0.0',
|
|
290
320
|
categories: agentFlowCategories,
|
|
@@ -295,7 +325,8 @@ const agentFlowManifest = {
|
|
|
295
325
|
toolResourceManifest,
|
|
296
326
|
mcpResourceManifest,
|
|
297
327
|
escalationResourceManifest,
|
|
298
|
-
memoryResourceManifest
|
|
328
|
+
memoryResourceManifest,
|
|
329
|
+
a2aResourceManifest
|
|
299
330
|
]
|
|
300
331
|
};
|
|
301
|
-
export { agentFlowCategories, agentFlowManifest, autonomousAgentManifest, contextResourceManifest, conversationalAgentManifest, escalationResourceManifest, mcpResourceManifest, memoryResourceManifest, toolResourceManifest };
|
|
332
|
+
export { a2aResourceManifest, agentFlowCategories, agentFlowManifest, autonomousAgentManifest, contextResourceManifest, conversationalAgentManifest, escalationResourceManifest, mcpResourceManifest, memoryResourceManifest, toolResourceManifest };
|
|
@@ -42,7 +42,7 @@ const HOVER_DELAY_MS = 500;
|
|
|
42
42
|
const HOVER_HIDE_DELAY_MS = 300;
|
|
43
43
|
const alwaysShowNotches = ()=>true;
|
|
44
44
|
const AgentNodeComponent = /*#__PURE__*/ (0, external_react_namespaceObject.memo)((props)=>{
|
|
45
|
-
const { id, data, selected = false, mode = 'design', hasMemory = false, hasContext = false, hasEscalation = false, hasTool = false, hasMcp = false, mcpEnabled = true, hasError = false, hasSuccess = false, hasRunning = false, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions = false, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
45
|
+
const { id, data, selected = false, mode = 'design', hasMemory = false, hasContext = false, hasEscalation = false, hasTool = false, hasMcp = false, hasA2a = false, a2aEnabled = false, mcpEnabled = true, hasError = false, hasSuccess = false, hasRunning = false, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions = false, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
46
46
|
const { actOnSuggestion } = (0, agent_flow_store_cjs_namespaceObject.useAgentFlowStore)();
|
|
47
47
|
const [isNodeHovered, setIsNodeHovered] = (0, external_react_namespaceObject.useState)(false);
|
|
48
48
|
const [isPanelHovered, setIsPanelHovered] = (0, external_react_namespaceObject.useState)(false);
|
|
@@ -124,6 +124,8 @@ const AgentNodeComponent = /*#__PURE__*/ (0, external_react_namespaceObject.memo
|
|
|
124
124
|
const displayTool = 'design' === mode || 'view' === mode && hasTool;
|
|
125
125
|
const isMcpEnabled = false !== mcpEnabled;
|
|
126
126
|
const displayMcp = 'design' === mode && isMcpEnabled || 'view' === mode && !!hasMcp;
|
|
127
|
+
const isA2aEnabled = true === a2aEnabled;
|
|
128
|
+
const displayA2a = 'design' === mode && isA2aEnabled || 'view' === mode && !!hasA2a;
|
|
127
129
|
const handleConfigurations = (0, external_react_namespaceObject.useMemo)(()=>{
|
|
128
130
|
const configs = [];
|
|
129
131
|
const topHandles = [];
|
|
@@ -159,7 +161,7 @@ const AgentNodeComponent = /*#__PURE__*/ (0, external_react_namespaceObject.memo
|
|
|
159
161
|
handles: topHandles,
|
|
160
162
|
visible: true
|
|
161
163
|
});
|
|
162
|
-
if (displayContext || displayTool || displayMcp) {
|
|
164
|
+
if (displayContext || displayTool || displayMcp || displayA2a) {
|
|
163
165
|
bottomHandles.push({
|
|
164
166
|
id: external_AgentFlow_constants_cjs_namespaceObject.ResourceNodeType.Context,
|
|
165
167
|
type: 'source',
|
|
@@ -180,10 +182,11 @@ const AgentNodeComponent = /*#__PURE__*/ (0, external_react_namespaceObject.memo
|
|
|
180
182
|
showButton: 'design' === mode,
|
|
181
183
|
color: 'var(--uix-canvas-foreground-de-emp)',
|
|
182
184
|
labelBackgroundColor: 'var(--uix-canvas-background-secondary)',
|
|
183
|
-
visible: displayTool || displayMcp,
|
|
185
|
+
visible: displayTool || displayMcp || displayA2a,
|
|
184
186
|
onAction: (_e)=>{
|
|
185
187
|
if (displayTool) onAddResource?.('tool');
|
|
186
188
|
else if (displayMcp) onAddResource?.('mcp');
|
|
189
|
+
else if (displayA2a) onAddResource?.('a2a');
|
|
187
190
|
}
|
|
188
191
|
});
|
|
189
192
|
configs.push({
|
|
@@ -199,6 +202,7 @@ const AgentNodeComponent = /*#__PURE__*/ (0, external_react_namespaceObject.memo
|
|
|
199
202
|
displayMemory,
|
|
200
203
|
displayMcp,
|
|
201
204
|
displayTool,
|
|
205
|
+
displayA2a,
|
|
202
206
|
displayEscalation,
|
|
203
207
|
hasMemory,
|
|
204
208
|
onAddResource,
|
|
@@ -507,7 +511,7 @@ const AgentNodeComponent = /*#__PURE__*/ (0, external_react_namespaceObject.memo
|
|
|
507
511
|
});
|
|
508
512
|
AgentNodeComponent.displayName = 'AgentNodeComponent';
|
|
509
513
|
const AgentNodeWrapper = (props)=>{
|
|
510
|
-
const { data, mode, hasMemory, hasContext, hasEscalation, hasTool, hasMcp, mcpEnabled, hasError, hasSuccess, hasRunning, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
514
|
+
const { data, mode, hasMemory, hasContext, hasEscalation, hasTool, hasMcp, hasA2a, a2aEnabled, mcpEnabled, hasError, hasSuccess, hasRunning, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
511
515
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(AgentNodeComponent, {
|
|
512
516
|
...nodeProps,
|
|
513
517
|
data: data,
|
|
@@ -517,6 +521,8 @@ const AgentNodeWrapper = (props)=>{
|
|
|
517
521
|
hasEscalation: hasEscalation,
|
|
518
522
|
hasTool: hasTool,
|
|
519
523
|
hasMcp: hasMcp,
|
|
524
|
+
hasA2a: hasA2a,
|
|
525
|
+
a2aEnabled: a2aEnabled,
|
|
520
526
|
mcpEnabled: mcpEnabled,
|
|
521
527
|
hasError: hasError,
|
|
522
528
|
hasSuccess: hasSuccess,
|
|
@@ -24,11 +24,13 @@ interface AgentNodeProps {
|
|
|
24
24
|
hasEscalation?: boolean;
|
|
25
25
|
hasTool?: boolean;
|
|
26
26
|
hasMcp?: boolean;
|
|
27
|
+
hasA2a?: boolean;
|
|
28
|
+
a2aEnabled?: boolean;
|
|
27
29
|
mcpEnabled?: boolean;
|
|
28
30
|
hasError?: boolean;
|
|
29
31
|
hasSuccess?: boolean;
|
|
30
32
|
hasRunning?: boolean;
|
|
31
|
-
onAddResource?: (type: 'context' | 'escalation' | 'mcp' | 'tool' | 'memorySpace') => void;
|
|
33
|
+
onAddResource?: (type: 'context' | 'escalation' | 'mcp' | 'tool' | 'memorySpace' | 'a2a') => void;
|
|
32
34
|
onAddInstructions?: () => void;
|
|
33
35
|
translations: AgentNodeTranslations;
|
|
34
36
|
enableMemory?: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AgentNode.d.ts","sourceRoot":"","sources":["../../../../../src/canvas/components/AgentCanvas/nodes/AgentNode.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,0CAA0C,CAAC;AAKhF,OAAO,EACL,KAAK,qBAAqB,EAE1B,KAAK,sBAAsB,EAC3B,KAAK,cAAc,EACpB,MAAM,gBAAgB,CAAC;AAExB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AA8BlE,UAAU,aAAc,SAAQ,YAAY;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACpC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,YAAY,CAAC,EAAE;QACb,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,IAAI,CAAC,EAAE,MAAM,CAAC;KACf,CAAC;IAEF,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,cAAc,CAAC;CACjC;AAED,UAAU,cAAc;IACtB,IAAI,EAAE,aAAa,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,aAAa,CAAC,EAAE,CAAC,IAAI,EAAE,SAAS,GAAG,YAAY,GAAG,KAAK,GAAG,MAAM,GAAG,aAAa,KAAK,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"AgentNode.d.ts","sourceRoot":"","sources":["../../../../../src/canvas/components/AgentCanvas/nodes/AgentNode.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,0CAA0C,CAAC;AAKhF,OAAO,EACL,KAAK,qBAAqB,EAE1B,KAAK,sBAAsB,EAC3B,KAAK,cAAc,EACpB,MAAM,gBAAgB,CAAC;AAExB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AA8BlE,UAAU,aAAc,SAAQ,YAAY;IAC1C,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACpC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B,YAAY,CAAC,EAAE;QACb,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB,IAAI,CAAC,EAAE,MAAM,CAAC;KACf,CAAC;IAEF,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,cAAc,CAAC;CACjC;AAED,UAAU,cAAc;IACtB,IAAI,EAAE,aAAa,CAAC;IACpB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,IAAI,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,aAAa,CAAC,EAAE,CAAC,IAAI,EAAE,SAAS,GAAG,YAAY,GAAG,KAAK,GAAG,MAAM,GAAG,aAAa,GAAG,KAAK,KAAK,IAAI,CAAC;IAClG,iBAAiB,CAAC,EAAE,MAAM,IAAI,CAAC;IAC/B,YAAY,EAAE,qBAAqB,CAAC;IACpC,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,kBAAkB,CAAC,EAAE,MAAM,IAAI,CAAC;IAChC,sBAAsB,CAAC,EAAE,sBAAsB,CAAC;IAEhD,sBAAsB,CAAC,EAAE,MAAM,CAAC;CACjC;AA2jBD,eAAO,MAAM,gBAAgB,8CAxDI,SAAS,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,GAAG,cAAc,6CAwD1B,CAAC;AAEvD,YAAY,EAAE,aAAa,EAAE,cAAc,EAAE,CAAC"}
|
|
@@ -14,7 +14,7 @@ const HOVER_DELAY_MS = 500;
|
|
|
14
14
|
const HOVER_HIDE_DELAY_MS = 300;
|
|
15
15
|
const alwaysShowNotches = ()=>true;
|
|
16
16
|
const AgentNodeComponent = /*#__PURE__*/ memo((props)=>{
|
|
17
|
-
const { id, data, selected = false, mode = 'design', hasMemory = false, hasContext = false, hasEscalation = false, hasTool = false, hasMcp = false, mcpEnabled = true, hasError = false, hasSuccess = false, hasRunning = false, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions = false, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
17
|
+
const { id, data, selected = false, mode = 'design', hasMemory = false, hasContext = false, hasEscalation = false, hasTool = false, hasMcp = false, hasA2a = false, a2aEnabled = false, mcpEnabled = true, hasError = false, hasSuccess = false, hasRunning = false, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions = false, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
18
18
|
const { actOnSuggestion } = useAgentFlowStore();
|
|
19
19
|
const [isNodeHovered, setIsNodeHovered] = useState(false);
|
|
20
20
|
const [isPanelHovered, setIsPanelHovered] = useState(false);
|
|
@@ -96,6 +96,8 @@ const AgentNodeComponent = /*#__PURE__*/ memo((props)=>{
|
|
|
96
96
|
const displayTool = 'design' === mode || 'view' === mode && hasTool;
|
|
97
97
|
const isMcpEnabled = false !== mcpEnabled;
|
|
98
98
|
const displayMcp = 'design' === mode && isMcpEnabled || 'view' === mode && !!hasMcp;
|
|
99
|
+
const isA2aEnabled = true === a2aEnabled;
|
|
100
|
+
const displayA2a = 'design' === mode && isA2aEnabled || 'view' === mode && !!hasA2a;
|
|
99
101
|
const handleConfigurations = useMemo(()=>{
|
|
100
102
|
const configs = [];
|
|
101
103
|
const topHandles = [];
|
|
@@ -131,7 +133,7 @@ const AgentNodeComponent = /*#__PURE__*/ memo((props)=>{
|
|
|
131
133
|
handles: topHandles,
|
|
132
134
|
visible: true
|
|
133
135
|
});
|
|
134
|
-
if (displayContext || displayTool || displayMcp) {
|
|
136
|
+
if (displayContext || displayTool || displayMcp || displayA2a) {
|
|
135
137
|
bottomHandles.push({
|
|
136
138
|
id: ResourceNodeType.Context,
|
|
137
139
|
type: 'source',
|
|
@@ -152,10 +154,11 @@ const AgentNodeComponent = /*#__PURE__*/ memo((props)=>{
|
|
|
152
154
|
showButton: 'design' === mode,
|
|
153
155
|
color: 'var(--uix-canvas-foreground-de-emp)',
|
|
154
156
|
labelBackgroundColor: 'var(--uix-canvas-background-secondary)',
|
|
155
|
-
visible: displayTool || displayMcp,
|
|
157
|
+
visible: displayTool || displayMcp || displayA2a,
|
|
156
158
|
onAction: (_e)=>{
|
|
157
159
|
if (displayTool) onAddResource?.('tool');
|
|
158
160
|
else if (displayMcp) onAddResource?.('mcp');
|
|
161
|
+
else if (displayA2a) onAddResource?.('a2a');
|
|
159
162
|
}
|
|
160
163
|
});
|
|
161
164
|
configs.push({
|
|
@@ -171,6 +174,7 @@ const AgentNodeComponent = /*#__PURE__*/ memo((props)=>{
|
|
|
171
174
|
displayMemory,
|
|
172
175
|
displayMcp,
|
|
173
176
|
displayTool,
|
|
177
|
+
displayA2a,
|
|
174
178
|
displayEscalation,
|
|
175
179
|
hasMemory,
|
|
176
180
|
onAddResource,
|
|
@@ -479,7 +483,7 @@ const AgentNodeComponent = /*#__PURE__*/ memo((props)=>{
|
|
|
479
483
|
});
|
|
480
484
|
AgentNodeComponent.displayName = 'AgentNodeComponent';
|
|
481
485
|
const AgentNodeWrapper = (props)=>{
|
|
482
|
-
const { data, mode, hasMemory, hasContext, hasEscalation, hasTool, hasMcp, mcpEnabled, hasError, hasSuccess, hasRunning, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
486
|
+
const { data, mode, hasMemory, hasContext, hasEscalation, hasTool, hasMcp, hasA2a, a2aEnabled, mcpEnabled, hasError, hasSuccess, hasRunning, onAddResource, onAddInstructions, translations, enableMemory, enableInstructions, healthScore, onHealthScoreClick, suggestionTranslations, suggestionGroupVersion, ...nodeProps } = props;
|
|
483
487
|
return /*#__PURE__*/ jsx(AgentNodeComponent, {
|
|
484
488
|
...nodeProps,
|
|
485
489
|
data: data,
|
|
@@ -489,6 +493,8 @@ const AgentNodeWrapper = (props)=>{
|
|
|
489
493
|
hasEscalation: hasEscalation,
|
|
490
494
|
hasTool: hasTool,
|
|
491
495
|
hasMcp: hasMcp,
|
|
496
|
+
hasA2a: hasA2a,
|
|
497
|
+
a2aEnabled: a2aEnabled,
|
|
492
498
|
mcpEnabled: mcpEnabled,
|
|
493
499
|
hasError: hasError,
|
|
494
500
|
hasSuccess: hasSuccess,
|
|
@@ -158,6 +158,12 @@ const ResourceNode = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(({ d
|
|
|
158
158
|
h: 40
|
|
159
159
|
});
|
|
160
160
|
break;
|
|
161
|
+
case 'a2a':
|
|
162
|
+
icon = /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(index_cjs_namespaceObject.A2aIcon, {
|
|
163
|
+
w: 40,
|
|
164
|
+
h: 40
|
|
165
|
+
});
|
|
166
|
+
break;
|
|
161
167
|
case 'tool':
|
|
162
168
|
icon = /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(ToolResourceIcon_index_cjs_namespaceObject.ToolResourceIcon, {
|
|
163
169
|
size: 48,
|
|
@@ -411,13 +417,13 @@ const ResourceNode = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(({ d
|
|
|
411
417
|
{
|
|
412
418
|
position: react_cjs_namespaceObject.Position.Top,
|
|
413
419
|
handles: toolTopHandles,
|
|
414
|
-
visible: ('tool' === data.type || 'mcp' === data.type) && connectedHandlePosition === react_cjs_namespaceObject.Position.Top
|
|
420
|
+
visible: ('tool' === data.type || 'mcp' === data.type || 'a2a' === data.type) && connectedHandlePosition === react_cjs_namespaceObject.Position.Top
|
|
415
421
|
},
|
|
416
422
|
...data.isExpandable ? [
|
|
417
423
|
{
|
|
418
424
|
position: react_cjs_namespaceObject.Position.Bottom,
|
|
419
425
|
handles: toolBottomHandles,
|
|
420
|
-
visible: ('tool' === data.type || 'mcp' === data.type) && connectedHandlePosition === react_cjs_namespaceObject.Position.Bottom
|
|
426
|
+
visible: ('tool' === data.type || 'mcp' === data.type || 'a2a' === data.type) && connectedHandlePosition === react_cjs_namespaceObject.Position.Bottom
|
|
421
427
|
}
|
|
422
428
|
] : [],
|
|
423
429
|
{
|
|
@@ -457,6 +463,8 @@ const ResourceNode = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(({ d
|
|
|
457
463
|
return 'uipath.resource.escalation';
|
|
458
464
|
case 'memorySpace':
|
|
459
465
|
return 'uipath.resource.memory';
|
|
466
|
+
case 'a2a':
|
|
467
|
+
return 'uipath.resource.a2a';
|
|
460
468
|
default:
|
|
461
469
|
return 'uipath.resource.tool';
|
|
462
470
|
}
|