@uipath/apollo-react 3.68.1 → 3.68.3-pr431.8e3b0c3
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/CanvasPerformance.stories.cjs +361 -0
- package/dist/canvas/components/CanvasPerformance.stories.d.ts +6 -0
- package/dist/canvas/components/CanvasPerformance.stories.d.ts.map +1 -0
- package/dist/canvas/components/CanvasPerformance.stories.js +324 -0
- package/dist/canvas/components/NodePropertiesPanel/hooks/index.cjs +4 -1
- package/dist/canvas/components/NodePropertiesPanel/hooks/index.d.ts +1 -1
- package/dist/canvas/components/NodePropertiesPanel/hooks/index.d.ts.map +1 -1
- package/dist/canvas/components/NodePropertiesPanel/hooks/index.js +2 -2
- package/dist/canvas/components/NodePropertiesPanel/hooks/useNodeSelection.cjs +27 -6
- package/dist/canvas/components/NodePropertiesPanel/hooks/useNodeSelection.d.ts +3 -0
- package/dist/canvas/components/NodePropertiesPanel/hooks/useNodeSelection.d.ts.map +1 -1
- package/dist/canvas/components/NodePropertiesPanel/hooks/useNodeSelection.js +23 -5
- package/dist/canvas/components/StageNode/AdhocTask.cjs +148 -0
- package/dist/canvas/components/StageNode/AdhocTask.d.ts +13 -0
- package/dist/canvas/components/StageNode/AdhocTask.d.ts.map +1 -0
- package/dist/canvas/components/StageNode/AdhocTask.js +104 -0
- package/dist/canvas/components/StageNode/DraggableTask.cjs +14 -5
- package/dist/canvas/components/StageNode/DraggableTask.d.ts +1 -1
- package/dist/canvas/components/StageNode/DraggableTask.d.ts.map +1 -1
- package/dist/canvas/components/StageNode/DraggableTask.js +14 -5
- package/dist/canvas/components/StageNode/DraggableTask.types.d.ts +3 -3
- package/dist/canvas/components/StageNode/DraggableTask.types.d.ts.map +1 -1
- package/dist/canvas/components/StageNode/StageEdge.cjs +34 -11
- package/dist/canvas/components/StageNode/StageEdge.d.ts +2 -1
- package/dist/canvas/components/StageNode/StageEdge.d.ts.map +1 -1
- package/dist/canvas/components/StageNode/StageEdge.js +35 -12
- package/dist/canvas/components/StageNode/StageNode.cjs +91 -122
- package/dist/canvas/components/StageNode/StageNode.d.ts +1 -1
- package/dist/canvas/components/StageNode/StageNode.d.ts.map +1 -1
- package/dist/canvas/components/StageNode/StageNode.js +98 -119
- package/dist/canvas/components/StageNode/StageNode.stories.cjs +123 -158
- package/dist/canvas/components/StageNode/StageNode.stories.d.ts.map +1 -1
- package/dist/canvas/components/StageNode/StageNode.stories.js +119 -154
- package/dist/canvas/components/StageNode/StageNode.stories.utils.cjs +42 -0
- package/dist/canvas/components/StageNode/StageNode.stories.utils.d.ts +3 -0
- package/dist/canvas/components/StageNode/StageNode.stories.utils.d.ts.map +1 -0
- package/dist/canvas/components/StageNode/StageNode.stories.utils.js +8 -0
- package/dist/canvas/components/StageNode/StageNode.styles.cjs +1 -1
- package/dist/canvas/components/StageNode/StageNode.styles.js +1 -1
- package/dist/canvas/components/StageNode/StageNode.types.d.ts +9 -1
- package/dist/canvas/components/StageNode/StageNode.types.d.ts.map +1 -1
- package/dist/canvas/components/StageNode/StageTaskDragOverlay.cjs +68 -0
- package/dist/canvas/components/StageNode/StageTaskDragOverlay.d.ts +3 -0
- package/dist/canvas/components/StageNode/StageTaskDragOverlay.d.ts.map +1 -0
- package/dist/canvas/components/StageNode/StageTaskDragOverlay.js +34 -0
- package/dist/canvas/components/StageNode/TaskMenu.cjs +13 -17
- package/dist/canvas/components/StageNode/TaskMenu.d.ts +1 -2
- package/dist/canvas/components/StageNode/TaskMenu.d.ts.map +1 -1
- package/dist/canvas/components/StageNode/TaskMenu.js +14 -18
- package/dist/canvas/components/StageNode/index.d.ts +1 -1
- package/dist/canvas/components/StageNode/index.d.ts.map +1 -1
- package/package.json +1 -1
|
@@ -1,14 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
var __webpack_require__ = {};
|
|
3
|
-
(()=>{
|
|
4
|
-
__webpack_require__.n = (module)=>{
|
|
5
|
-
var getter = module && module.__esModule ? ()=>module['default'] : ()=>module;
|
|
6
|
-
__webpack_require__.d(getter, {
|
|
7
|
-
a: getter
|
|
8
|
-
});
|
|
9
|
-
return getter;
|
|
10
|
-
};
|
|
11
|
-
})();
|
|
12
3
|
(()=>{
|
|
13
4
|
__webpack_require__.d = (exports1, definition)=>{
|
|
14
5
|
for(var key in definition)if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, {
|
|
@@ -42,11 +33,9 @@ const apollo_core_namespaceObject = require("@uipath/apollo-core");
|
|
|
42
33
|
const index_cjs_namespaceObject = require("../../layouts/index.cjs");
|
|
43
34
|
const react_cjs_namespaceObject = require("../../xyflow/react.cjs");
|
|
44
35
|
const external_material_index_cjs_namespaceObject = require("../../../material/index.cjs");
|
|
45
|
-
const external_debounce_namespaceObject = require("debounce");
|
|
46
|
-
var external_debounce_default = /*#__PURE__*/ __webpack_require__.n(external_debounce_namespaceObject);
|
|
47
36
|
const external_react_namespaceObject = require("react");
|
|
48
|
-
const external_react_dom_namespaceObject = require("react-dom");
|
|
49
37
|
const external_icons_index_cjs_namespaceObject = require("../../icons/index.cjs");
|
|
38
|
+
const GroupModificationUtils_cjs_namespaceObject = require("../../utils/GroupModificationUtils.cjs");
|
|
50
39
|
const ConnectedHandlesContext_cjs_namespaceObject = require("../BaseCanvas/ConnectedHandlesContext.cjs");
|
|
51
40
|
const useButtonHandles_cjs_namespaceObject = require("../ButtonHandle/useButtonHandles.cjs");
|
|
52
41
|
const external_ExecutionStatusIcon_index_cjs_namespaceObject = require("../ExecutionStatusIcon/index.cjs");
|
|
@@ -54,11 +43,13 @@ const external_FloatingCanvasPanel_index_cjs_namespaceObject = require("../Float
|
|
|
54
43
|
const external_NodeContextMenu_index_cjs_namespaceObject = require("../NodeContextMenu/index.cjs");
|
|
55
44
|
const hooks_index_cjs_namespaceObject = require("../NodePropertiesPanel/hooks/index.cjs");
|
|
56
45
|
const external_Toolbox_index_cjs_namespaceObject = require("../Toolbox/index.cjs");
|
|
46
|
+
const external_AdhocTask_cjs_namespaceObject = require("./AdhocTask.cjs");
|
|
57
47
|
const external_DraggableTask_cjs_namespaceObject = require("./DraggableTask.cjs");
|
|
58
48
|
const external_StageNode_styles_cjs_namespaceObject = require("./StageNode.styles.cjs");
|
|
59
49
|
const external_StageNode_types_cjs_namespaceObject = require("./StageNode.types.cjs");
|
|
60
50
|
const external_StageNode_utils_cjs_namespaceObject = require("./StageNode.utils.cjs");
|
|
61
51
|
const external_StageNodeTaskUtilities_cjs_namespaceObject = require("./StageNodeTaskUtilities.cjs");
|
|
52
|
+
const external_StageTaskDragOverlay_cjs_namespaceObject = require("./StageTaskDragOverlay.cjs");
|
|
62
53
|
const CHIP_ICONS = {
|
|
63
54
|
[external_StageNode_types_cjs_namespaceObject.StageHeaderChipType.Entry]: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_icons_index_cjs_namespaceObject.EntryConditionIcon, {
|
|
64
55
|
w: apollo_core_namespaceObject.Icon.IconXs,
|
|
@@ -81,54 +72,7 @@ const CHIP_ICONS = {
|
|
|
81
72
|
size: apollo_core_namespaceObject.Icon.IconXs
|
|
82
73
|
})
|
|
83
74
|
};
|
|
84
|
-
const
|
|
85
|
-
const [playLoading, setPlayLoading] = (0, external_react_namespaceObject.useState)(false);
|
|
86
|
-
const debouncedTaskPlay = (0, external_react_namespaceObject.useMemo)(()=>external_debounce_default()(async (id)=>{
|
|
87
|
-
setPlayLoading(true);
|
|
88
|
-
try {
|
|
89
|
-
await onTaskPlay(id);
|
|
90
|
-
} catch {} finally{
|
|
91
|
-
setPlayLoading(false);
|
|
92
|
-
}
|
|
93
|
-
}, 500, {
|
|
94
|
-
immediate: true
|
|
95
|
-
}), [
|
|
96
|
-
onTaskPlay
|
|
97
|
-
]);
|
|
98
|
-
const handlePlayClick = (0, external_react_namespaceObject.useCallback)((e)=>{
|
|
99
|
-
e.stopPropagation();
|
|
100
|
-
e.preventDefault();
|
|
101
|
-
debouncedTaskPlay(taskId);
|
|
102
|
-
}, [
|
|
103
|
-
debouncedTaskPlay,
|
|
104
|
-
taskId
|
|
105
|
-
]);
|
|
106
|
-
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_material_index_cjs_namespaceObject.ApTooltip, {
|
|
107
|
-
content: "Trigger task",
|
|
108
|
-
placement: "top",
|
|
109
|
-
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_material_index_cjs_namespaceObject.ApIconButton, {
|
|
110
|
-
"data-testid": `stage-task-play-${taskId}`,
|
|
111
|
-
onClick: handlePlayClick,
|
|
112
|
-
onMouseDown: (e)=>e.stopPropagation(),
|
|
113
|
-
onKeyDown: (e)=>e.stopPropagation(),
|
|
114
|
-
className: "task-menu-icon-button",
|
|
115
|
-
sx: {
|
|
116
|
-
color: 'var(--uix-canvas-primary) !important',
|
|
117
|
-
minWidth: 'unset !important',
|
|
118
|
-
width: `${apollo_core_namespaceObject.Spacing.SpacingL} !important`,
|
|
119
|
-
height: `${apollo_core_namespaceObject.Spacing.SpacingL} !important`,
|
|
120
|
-
padding: '0 !important'
|
|
121
|
-
},
|
|
122
|
-
children: playLoading ? /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_material_index_cjs_namespaceObject.ApCircularProgress, {
|
|
123
|
-
size: 20
|
|
124
|
-
}) : /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_icons_index_cjs_namespaceObject.PlayIcon, {
|
|
125
|
-
w: 20,
|
|
126
|
-
h: 20
|
|
127
|
-
})
|
|
128
|
-
})
|
|
129
|
-
});
|
|
130
|
-
});
|
|
131
|
-
const StageNodeComponent = (props)=>{
|
|
75
|
+
const StageNodeInner = (props)=>{
|
|
132
76
|
const { dragging, selected, id, width, execution, stageDetails, addTaskLabel = 'Add task', addTaskLoading = false, replaceTaskLabel = 'Replace task', taskOptions = [], menuItems, pendingReplaceTask, onStageClick, onTaskAdd, onAddTaskFromToolbox, onTaskToolboxSearch, onTaskClick, onTaskGroupModification, onStageTitleChange, onTaskReorder, onReplaceTaskFromToolbox, onTaskPlay, hideParallelOptions } = props;
|
|
133
77
|
const taskWidth = width ? width - external_StageNode_styles_cjs_namespaceObject.STAGE_CONTENT_INSET : void 0;
|
|
134
78
|
const allTasks = (0, external_react_namespaceObject.useMemo)(()=>stageDetails?.tasks || [], [
|
|
@@ -137,7 +81,11 @@ const StageNodeComponent = (props)=>{
|
|
|
137
81
|
const tasks = (0, external_react_namespaceObject.useMemo)(()=>allTasks.filter((group)=>group.some((t)=>!t.isAdhoc)), [
|
|
138
82
|
allTasks
|
|
139
83
|
]);
|
|
140
|
-
const adhocTasks = (0, external_react_namespaceObject.useMemo)(()=>allTasks.
|
|
84
|
+
const adhocTasks = (0, external_react_namespaceObject.useMemo)(()=>allTasks.flatMap((group, groupIndex)=>group.map((task, taskIndex)=>({
|
|
85
|
+
task,
|
|
86
|
+
groupIndex,
|
|
87
|
+
taskIndex
|
|
88
|
+
})).filter(({ task })=>task.isAdhoc)), [
|
|
141
89
|
allTasks
|
|
142
90
|
]);
|
|
143
91
|
const flatTasks = (0, external_react_namespaceObject.useMemo)(()=>tasks.flat(), [
|
|
@@ -154,9 +102,6 @@ const StageNodeComponent = (props)=>{
|
|
|
154
102
|
const status = execution?.stageStatus?.status;
|
|
155
103
|
const statusLabel = execution?.stageStatus?.label;
|
|
156
104
|
const stageDuration = execution?.stageStatus?.duration;
|
|
157
|
-
const reGroupTaskFunction = (0, external_react_namespaceObject.useMemo)(()=>onTaskGroupModification || (()=>{}), [
|
|
158
|
-
onTaskGroupModification
|
|
159
|
-
]);
|
|
160
105
|
const isStageTitleEditable = !!onStageTitleChange && !isReadOnly;
|
|
161
106
|
const [isHovered, setIsHovered] = (0, external_react_namespaceObject.useState)(false);
|
|
162
107
|
const [label, setLabel] = (0, external_react_namespaceObject.useState)(props.stageDetails.label);
|
|
@@ -173,6 +118,7 @@ const StageNodeComponent = (props)=>{
|
|
|
173
118
|
taskIndex: -1
|
|
174
119
|
});
|
|
175
120
|
const isConnecting = (0, react_cjs_namespaceObject.useStore)((state)=>!!state.connectionClickStartHandle);
|
|
121
|
+
const storeApi = (0, react_cjs_namespaceObject.useStoreApi)();
|
|
176
122
|
const connectedHandleIds = (0, ConnectedHandlesContext_cjs_namespaceObject.useConnectedHandles)(id);
|
|
177
123
|
const [isAddingTask, setIsAddingTask] = (0, external_react_namespaceObject.useState)(false);
|
|
178
124
|
const [isReplacingTask, setIsReplacingTask] = (0, external_react_namespaceObject.useState)(false);
|
|
@@ -212,7 +158,6 @@ const StageNodeComponent = (props)=>{
|
|
|
212
158
|
tasks,
|
|
213
159
|
activeDragId
|
|
214
160
|
]);
|
|
215
|
-
const { zoom } = (0, react_cjs_namespaceObject.useViewport)();
|
|
216
161
|
const projected = (0, external_react_namespaceObject.useMemo)(()=>{
|
|
217
162
|
if (!activeDragId || !overId) return null;
|
|
218
163
|
return (0, external_StageNode_utils_cjs_namespaceObject.getProjection)(tasks, activeDragId, overId, offsetLeft);
|
|
@@ -295,18 +240,26 @@ const StageNodeComponent = (props)=>{
|
|
|
295
240
|
handleStageTitleClickToSave,
|
|
296
241
|
isStageTitleEditing
|
|
297
242
|
]);
|
|
298
|
-
const
|
|
243
|
+
const hasContextMenu = !!(onReplaceTaskFromToolbox || onTaskGroupModification);
|
|
244
|
+
const buildContextMenuItems = (0, external_react_namespaceObject.useCallback)((groupIndex, taskIndex)=>{
|
|
245
|
+
const taskGroup = tasks[groupIndex] ?? [];
|
|
246
|
+
const isParallel = taskGroup.length > 1;
|
|
299
247
|
const items = [];
|
|
300
248
|
if (onReplaceTaskFromToolbox) {
|
|
301
249
|
items.push((0, external_StageNodeTaskUtilities_cjs_namespaceObject.getMenuItem)('replace-task', 'Replace task', ()=>{
|
|
302
|
-
|
|
250
|
+
taskStateReference.current = {
|
|
251
|
+
isParallel,
|
|
252
|
+
groupIndex,
|
|
253
|
+
taskIndex
|
|
254
|
+
};
|
|
255
|
+
const taskId = taskGroup[taskIndex]?.id;
|
|
303
256
|
if (taskId) onTaskClick?.(taskId);
|
|
304
257
|
setIsReplacingTask(true);
|
|
305
258
|
}));
|
|
306
259
|
items.push((0, external_StageNodeTaskUtilities_cjs_namespaceObject.getDivider)());
|
|
307
260
|
}
|
|
308
261
|
if (onTaskGroupModification) {
|
|
309
|
-
const reGroupOptions = (0, external_StageNodeTaskUtilities_cjs_namespaceObject.getContextMenuItems)(isParallel, groupIndex,
|
|
262
|
+
const reGroupOptions = (0, external_StageNodeTaskUtilities_cjs_namespaceObject.getContextMenuItems)(isParallel, groupIndex, tasks.length, taskIndex, taskGroup.length, (tasks[groupIndex - 1]?.length ?? 0) > 1, (tasks[groupIndex + 1]?.length ?? 0) > 1, onTaskGroupModification, hideParallelOptions);
|
|
310
263
|
return [
|
|
311
264
|
...items,
|
|
312
265
|
...reGroupOptions
|
|
@@ -317,11 +270,31 @@ const StageNodeComponent = (props)=>{
|
|
|
317
270
|
onReplaceTaskFromToolbox,
|
|
318
271
|
onTaskClick,
|
|
319
272
|
onTaskGroupModification,
|
|
320
|
-
reGroupTaskFunction,
|
|
321
273
|
tasks,
|
|
322
274
|
hideParallelOptions
|
|
323
275
|
]);
|
|
324
|
-
const
|
|
276
|
+
const getAdhocContextMenuItems = (0, external_react_namespaceObject.useCallback)((groupIndex, taskIndex, taskId)=>{
|
|
277
|
+
const items = [];
|
|
278
|
+
if (onReplaceTaskFromToolbox) items.push((0, external_StageNodeTaskUtilities_cjs_namespaceObject.getMenuItem)('replace-task', 'Replace task', ()=>{
|
|
279
|
+
taskStateReference.current = {
|
|
280
|
+
isParallel: false,
|
|
281
|
+
groupIndex,
|
|
282
|
+
taskIndex
|
|
283
|
+
};
|
|
284
|
+
onTaskClick?.(taskId);
|
|
285
|
+
setIsReplacingTask(true);
|
|
286
|
+
}));
|
|
287
|
+
if (onTaskGroupModification) {
|
|
288
|
+
if (items.length > 0) items.push((0, external_StageNodeTaskUtilities_cjs_namespaceObject.getDivider)());
|
|
289
|
+
items.push((0, external_StageNodeTaskUtilities_cjs_namespaceObject.getMenuItem)('remove-task', 'Delete task', ()=>onTaskGroupModification(GroupModificationUtils_cjs_namespaceObject.GroupModificationType.REMOVE_TASK, groupIndex, taskIndex)));
|
|
290
|
+
}
|
|
291
|
+
return items;
|
|
292
|
+
}, [
|
|
293
|
+
onReplaceTaskFromToolbox,
|
|
294
|
+
onTaskClick,
|
|
295
|
+
onTaskGroupModification
|
|
296
|
+
]);
|
|
297
|
+
const { setSelectedNodeId } = (0, hooks_index_cjs_namespaceObject.useSetNodeSelection)();
|
|
325
298
|
const handleStageClick = (0, external_react_namespaceObject.useCallback)(()=>{
|
|
326
299
|
onStageClick?.();
|
|
327
300
|
}, [
|
|
@@ -444,9 +417,9 @@ const StageNodeComponent = (props)=>{
|
|
|
444
417
|
setActiveDragId(event.active.id);
|
|
445
418
|
}, []);
|
|
446
419
|
const handleDragMove = (0, external_react_namespaceObject.useCallback)((event)=>{
|
|
447
|
-
setOffsetLeft(event.delta.x /
|
|
420
|
+
setOffsetLeft(event.delta.x / storeApi.getState().transform[2]);
|
|
448
421
|
}, [
|
|
449
|
-
|
|
422
|
+
storeApi
|
|
450
423
|
]);
|
|
451
424
|
const handleDragOver = (0, external_react_namespaceObject.useCallback)((event)=>{
|
|
452
425
|
setOverId(event.over?.id ?? null);
|
|
@@ -482,12 +455,6 @@ const StageNodeComponent = (props)=>{
|
|
|
482
455
|
} : void 0, [
|
|
483
456
|
taskWidth
|
|
484
457
|
]);
|
|
485
|
-
const dragOverlayStyle = (0, external_react_namespaceObject.useMemo)(()=>({
|
|
486
|
-
transform: `scale(${zoom})`,
|
|
487
|
-
transformOrigin: 'top left'
|
|
488
|
-
}), [
|
|
489
|
-
zoom
|
|
490
|
-
]);
|
|
491
458
|
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)("div", {
|
|
492
459
|
"data-testid": `stage-${id}`,
|
|
493
460
|
style: {
|
|
@@ -505,6 +472,7 @@ const StageNodeComponent = (props)=>{
|
|
|
505
472
|
children: [
|
|
506
473
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_StageNode_styles_cjs_namespaceObject.StageHeader, {
|
|
507
474
|
isException: isException,
|
|
475
|
+
"data-testid": `stage-header-${id}`,
|
|
508
476
|
children: [
|
|
509
477
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(index_cjs_namespaceObject.Row, {
|
|
510
478
|
gap: apollo_core_namespaceObject.Spacing.SpacingMicro,
|
|
@@ -669,19 +637,13 @@ const StageNodeComponent = (props)=>{
|
|
|
669
637
|
taskExecution: taskExecution,
|
|
670
638
|
isSelected: selectedTaskId === task.id,
|
|
671
639
|
isParallel: isParallel,
|
|
672
|
-
|
|
640
|
+
groupIndex: groupIndex,
|
|
641
|
+
taskIndex: taskIndex,
|
|
673
642
|
onTaskClick: handleTaskClick,
|
|
674
643
|
projectedDepth: task.id === activeDragId && projected ? projected.depth : void 0,
|
|
675
644
|
isDragDisabled: !onTaskReorder,
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
onMenuOpen: ()=>{
|
|
679
|
-
taskStateReference.current = {
|
|
680
|
-
isParallel,
|
|
681
|
-
groupIndex,
|
|
682
|
-
taskIndex
|
|
683
|
-
};
|
|
684
|
-
}
|
|
645
|
+
...hasContextMenu && {
|
|
646
|
+
getContextMenuItems: buildContextMenuItems
|
|
685
647
|
}
|
|
686
648
|
}, task.id);
|
|
687
649
|
})
|
|
@@ -692,23 +654,11 @@ const StageNodeComponent = (props)=>{
|
|
|
692
654
|
})
|
|
693
655
|
})
|
|
694
656
|
}),
|
|
695
|
-
/*#__PURE__*/ (0,
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
isParallel: isActiveTaskParallel,
|
|
701
|
-
style: {
|
|
702
|
-
cursor: 'grabbing',
|
|
703
|
-
...taskWidthStyle
|
|
704
|
-
},
|
|
705
|
-
children: /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_DraggableTask_cjs_namespaceObject.TaskContent, {
|
|
706
|
-
task: activeTask,
|
|
707
|
-
isDragging: true
|
|
708
|
-
})
|
|
709
|
-
})
|
|
710
|
-
}) : null
|
|
711
|
-
}), document.body)
|
|
657
|
+
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_StageTaskDragOverlay_cjs_namespaceObject.StageTaskDragOverlay, {
|
|
658
|
+
activeTask: activeTask,
|
|
659
|
+
isActiveTaskParallel: isActiveTaskParallel,
|
|
660
|
+
taskWidthStyle: taskWidthStyle
|
|
661
|
+
})
|
|
712
662
|
]
|
|
713
663
|
}),
|
|
714
664
|
adhocTasks.length > 0 && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsxs)(external_StageNode_styles_cjs_namespaceObject.StageAdhocSection, {
|
|
@@ -724,23 +674,17 @@ const StageNodeComponent = (props)=>{
|
|
|
724
674
|
})
|
|
725
675
|
}),
|
|
726
676
|
/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_StageNode_styles_cjs_namespaceObject.StageTaskList, {
|
|
727
|
-
children: adhocTasks.map((task)=>{
|
|
677
|
+
children: adhocTasks.map(({ task, groupIndex, taskIndex })=>{
|
|
728
678
|
const taskExecution = execution?.taskStatus?.[task.id];
|
|
729
|
-
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
}),
|
|
739
|
-
onTaskPlay && /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(AdhocTaskPlayButton, {
|
|
740
|
-
taskId: task.id,
|
|
741
|
-
onTaskPlay: onTaskPlay
|
|
742
|
-
})
|
|
743
|
-
]
|
|
679
|
+
return /*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(external_AdhocTask_cjs_namespaceObject.AdhocTaskItem, {
|
|
680
|
+
task: task,
|
|
681
|
+
taskExecution: taskExecution,
|
|
682
|
+
isSelected: selectedTaskId === task.id,
|
|
683
|
+
onTaskClick: handleTaskClick,
|
|
684
|
+
onTaskPlay: onTaskPlay,
|
|
685
|
+
...(onTaskGroupModification || onReplaceTaskFromToolbox) && {
|
|
686
|
+
getContextMenuItems: ()=>getAdhocContextMenuItems(groupIndex, taskIndex, task.id)
|
|
687
|
+
}
|
|
744
688
|
}, task.id);
|
|
745
689
|
})
|
|
746
690
|
})
|
|
@@ -784,7 +728,32 @@ const StageNodeComponent = (props)=>{
|
|
|
784
728
|
]
|
|
785
729
|
});
|
|
786
730
|
};
|
|
787
|
-
const
|
|
731
|
+
const StageNodeInnerMemo = /*#__PURE__*/ (0, external_react_namespaceObject.memo)(StageNodeInner);
|
|
732
|
+
const StageNode = ({ dragging, selected, id, width, execution, stageDetails, addTaskLabel, addTaskLoading, replaceTaskLabel, taskOptions, menuItems, pendingReplaceTask, onStageClick, onTaskAdd, onAddTaskFromToolbox, onTaskToolboxSearch, onTaskClick, onTaskGroupModification, onStageTitleChange, onTaskReorder, onReplaceTaskFromToolbox, onTaskPlay, hideParallelOptions })=>/*#__PURE__*/ (0, jsx_runtime_namespaceObject.jsx)(StageNodeInnerMemo, {
|
|
733
|
+
dragging: dragging,
|
|
734
|
+
selected: selected,
|
|
735
|
+
id: id,
|
|
736
|
+
width: width,
|
|
737
|
+
execution: execution,
|
|
738
|
+
stageDetails: stageDetails,
|
|
739
|
+
addTaskLabel: addTaskLabel,
|
|
740
|
+
addTaskLoading: addTaskLoading,
|
|
741
|
+
replaceTaskLabel: replaceTaskLabel,
|
|
742
|
+
taskOptions: taskOptions,
|
|
743
|
+
menuItems: menuItems,
|
|
744
|
+
pendingReplaceTask: pendingReplaceTask,
|
|
745
|
+
onStageClick: onStageClick,
|
|
746
|
+
onTaskAdd: onTaskAdd,
|
|
747
|
+
onAddTaskFromToolbox: onAddTaskFromToolbox,
|
|
748
|
+
onTaskToolboxSearch: onTaskToolboxSearch,
|
|
749
|
+
onTaskClick: onTaskClick,
|
|
750
|
+
onTaskGroupModification: onTaskGroupModification,
|
|
751
|
+
onStageTitleChange: onStageTitleChange,
|
|
752
|
+
onTaskReorder: onTaskReorder,
|
|
753
|
+
onReplaceTaskFromToolbox: onReplaceTaskFromToolbox,
|
|
754
|
+
onTaskPlay: onTaskPlay,
|
|
755
|
+
hideParallelOptions: hideParallelOptions
|
|
756
|
+
});
|
|
788
757
|
exports.StageNode = __webpack_exports__.StageNode;
|
|
789
758
|
for(var __rspack_i in __webpack_exports__)if (-1 === [
|
|
790
759
|
"StageNode"
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import type { StageNodeProps } from './StageNode.types';
|
|
2
|
-
export declare const StageNode:
|
|
2
|
+
export declare const StageNode: ({ dragging, selected, id, width, execution, stageDetails, addTaskLabel, addTaskLoading, replaceTaskLabel, taskOptions, menuItems, pendingReplaceTask, onStageClick, onTaskAdd, onAddTaskFromToolbox, onTaskToolboxSearch, onTaskClick, onTaskGroupModification, onStageTitleChange, onTaskReorder, onReplaceTaskFromToolbox, onTaskPlay, hideParallelOptions, }: StageNodeProps) => import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
//# sourceMappingURL=StageNode.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"StageNode.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/StageNode/StageNode.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"StageNode.d.ts","sourceRoot":"","sources":["../../../../src/canvas/components/StageNode/StageNode.tsx"],"names":[],"mappings":"AAyDA,OAAO,KAAK,EAAuB,cAAc,EAAE,MAAM,mBAAmB,CAAC;AA6vB7E,eAAO,MAAM,SAAS,GAAI,iWAwBvB,cAAc,4CA4BhB,CAAC"}
|