@flowuent-org/diagramming-core 1.2.0 → 1.2.1
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/package.json +1 -1
- package/packages/diagrams/src/lib/components/automation/AutomationApiNode.tsx +788 -794
- package/packages/diagrams/src/lib/components/automation/AutomationEndNode.tsx +600 -606
- package/packages/diagrams/src/lib/components/automation/AutomationFormattingNode.tsx +825 -831
- package/packages/diagrams/src/lib/components/automation/AutomationNoteNode.tsx +414 -420
- package/packages/diagrams/src/lib/components/automation/AutomationSheetsNode.tsx +1112 -1118
- package/packages/diagrams/src/lib/components/automation/AutomationStartNode.tsx +503 -509
- package/packages/diagrams/src/lib/components/automation/NodeActionButtons.tsx +145 -146
- package/packages/diagrams/src/lib/components/automation/index.ts +12 -20
- package/packages/diagrams/src/lib/components/automation/NodeAIAssistantPopup.tsx +0 -504
- package/packages/diagrams/src/lib/utils/nodeAIAssistantConfig.ts +0 -54
|
@@ -1,146 +1,145 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Box, IconButton, Tooltip } from '@mui/material';
|
|
3
|
-
import {
|
|
4
|
-
IconLayoutGrid,
|
|
5
|
-
IconMessage,
|
|
6
|
-
IconPlus,
|
|
7
|
-
IconCopy,
|
|
8
|
-
IconTrash,
|
|
9
|
-
} from '@tabler/icons-react';
|
|
10
|
-
|
|
11
|
-
interface NodeActionButtonsProps {
|
|
12
|
-
selected?: boolean;
|
|
13
|
-
onLayout?: () => void;
|
|
14
|
-
|
|
15
|
-
onAddToGroup?: () => void;
|
|
16
|
-
onDuplicate?: () => void;
|
|
17
|
-
onDelete?: () => void;
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
export const NodeActionButtons: React.FC<NodeActionButtonsProps> = ({
|
|
21
|
-
selected,
|
|
22
|
-
onLayout,
|
|
23
|
-
|
|
24
|
-
onAddToGroup,
|
|
25
|
-
onDuplicate,
|
|
26
|
-
onDelete,
|
|
27
|
-
}) => {
|
|
28
|
-
if (!selected) return null;
|
|
29
|
-
|
|
30
|
-
return (
|
|
31
|
-
<Box
|
|
32
|
-
sx={{
|
|
33
|
-
position: 'absolute',
|
|
34
|
-
left: '100%',
|
|
35
|
-
top: '50%',
|
|
36
|
-
transform: 'translateY(-50%)',
|
|
37
|
-
marginLeft: '12px',
|
|
38
|
-
display: 'flex',
|
|
39
|
-
flexDirection: 'column',
|
|
40
|
-
gap: 0.5,
|
|
41
|
-
backgroundColor: 'rgba(15, 15, 35, 0.95)',
|
|
42
|
-
borderRadius: '12px',
|
|
43
|
-
border: '1px solid rgba(255, 255, 255, 0.1)',
|
|
44
|
-
p: 0.5,
|
|
45
|
-
zIndex: 1000,
|
|
46
|
-
boxShadow: '0 4px 20px rgba(0, 0, 0, 0.3)',
|
|
47
|
-
}}
|
|
48
|
-
onClick={(e) => e.stopPropagation()}
|
|
49
|
-
>
|
|
50
|
-
<Tooltip title="Layout" placement="right">
|
|
51
|
-
<IconButton
|
|
52
|
-
size="small"
|
|
53
|
-
onClick={(e) => {
|
|
54
|
-
e.stopPropagation();
|
|
55
|
-
onLayout?.();
|
|
56
|
-
}}
|
|
57
|
-
sx={{
|
|
58
|
-
color: 'rgba(255, 255, 255, 0.6)',
|
|
59
|
-
'&:hover': {
|
|
60
|
-
backgroundColor: 'rgba(255, 255, 255, 0.1)',
|
|
61
|
-
color: '#fff',
|
|
62
|
-
},
|
|
63
|
-
}}
|
|
64
|
-
>
|
|
65
|
-
<IconLayoutGrid size={18} />
|
|
66
|
-
</IconButton>
|
|
67
|
-
</Tooltip>
|
|
68
|
-
<Tooltip title="
|
|
69
|
-
<IconButton
|
|
70
|
-
size="small"
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { Box, IconButton, Tooltip } from '@mui/material';
|
|
3
|
+
import {
|
|
4
|
+
IconLayoutGrid,
|
|
5
|
+
IconMessage,
|
|
6
|
+
IconPlus,
|
|
7
|
+
IconCopy,
|
|
8
|
+
IconTrash,
|
|
9
|
+
} from '@tabler/icons-react';
|
|
10
|
+
|
|
11
|
+
interface NodeActionButtonsProps {
|
|
12
|
+
selected?: boolean;
|
|
13
|
+
onLayout?: () => void;
|
|
14
|
+
onAddNote?: () => void;
|
|
15
|
+
onAddToGroup?: () => void;
|
|
16
|
+
onDuplicate?: () => void;
|
|
17
|
+
onDelete?: () => void;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export const NodeActionButtons: React.FC<NodeActionButtonsProps> = ({
|
|
21
|
+
selected,
|
|
22
|
+
onLayout,
|
|
23
|
+
onAddNote,
|
|
24
|
+
onAddToGroup,
|
|
25
|
+
onDuplicate,
|
|
26
|
+
onDelete,
|
|
27
|
+
}) => {
|
|
28
|
+
if (!selected) return null;
|
|
29
|
+
|
|
30
|
+
return (
|
|
31
|
+
<Box
|
|
32
|
+
sx={{
|
|
33
|
+
position: 'absolute',
|
|
34
|
+
left: '100%',
|
|
35
|
+
top: '50%',
|
|
36
|
+
transform: 'translateY(-50%)',
|
|
37
|
+
marginLeft: '12px',
|
|
38
|
+
display: 'flex',
|
|
39
|
+
flexDirection: 'column',
|
|
40
|
+
gap: 0.5,
|
|
41
|
+
backgroundColor: 'rgba(15, 15, 35, 0.95)',
|
|
42
|
+
borderRadius: '12px',
|
|
43
|
+
border: '1px solid rgba(255, 255, 255, 0.1)',
|
|
44
|
+
p: 0.5,
|
|
45
|
+
zIndex: 1000,
|
|
46
|
+
boxShadow: '0 4px 20px rgba(0, 0, 0, 0.3)',
|
|
47
|
+
}}
|
|
48
|
+
onClick={(e) => e.stopPropagation()}
|
|
49
|
+
>
|
|
50
|
+
<Tooltip title="Layout" placement="right">
|
|
51
|
+
<IconButton
|
|
52
|
+
size="small"
|
|
53
|
+
onClick={(e) => {
|
|
54
|
+
e.stopPropagation();
|
|
55
|
+
onLayout?.();
|
|
56
|
+
}}
|
|
57
|
+
sx={{
|
|
58
|
+
color: 'rgba(255, 255, 255, 0.6)',
|
|
59
|
+
'&:hover': {
|
|
60
|
+
backgroundColor: 'rgba(255, 255, 255, 0.1)',
|
|
61
|
+
color: '#fff',
|
|
62
|
+
},
|
|
63
|
+
}}
|
|
64
|
+
>
|
|
65
|
+
<IconLayoutGrid size={18} />
|
|
66
|
+
</IconButton>
|
|
67
|
+
</Tooltip>
|
|
68
|
+
<Tooltip title="Add Note" placement="right">
|
|
69
|
+
<IconButton
|
|
70
|
+
size="small"
|
|
71
|
+
onClick={(e) => {
|
|
72
|
+
e.stopPropagation();
|
|
73
|
+
onAddNote?.();
|
|
74
|
+
}}
|
|
75
|
+
sx={{
|
|
76
|
+
color: 'rgba(255, 255, 255, 0.6)',
|
|
77
|
+
'&:hover': {
|
|
78
|
+
backgroundColor: 'rgba(255, 255, 255, 0.1)',
|
|
79
|
+
color: '#fff',
|
|
80
|
+
},
|
|
81
|
+
}}
|
|
82
|
+
>
|
|
83
|
+
<IconMessage size={18} />
|
|
84
|
+
</IconButton>
|
|
85
|
+
</Tooltip>
|
|
86
|
+
<Tooltip title="Add to Group" placement="right">
|
|
87
|
+
<IconButton
|
|
88
|
+
size="small"
|
|
89
|
+
onClick={(e) => {
|
|
90
|
+
e.stopPropagation();
|
|
91
|
+
onAddToGroup?.();
|
|
92
|
+
}}
|
|
93
|
+
sx={{
|
|
94
|
+
color: 'rgba(255, 255, 255, 0.6)',
|
|
95
|
+
'&:hover': {
|
|
96
|
+
backgroundColor: 'rgba(255, 255, 255, 0.1)',
|
|
97
|
+
color: '#fff',
|
|
98
|
+
},
|
|
99
|
+
}}
|
|
100
|
+
>
|
|
101
|
+
<IconPlus size={18} />
|
|
102
|
+
</IconButton>
|
|
103
|
+
</Tooltip>
|
|
104
|
+
<Tooltip title="Duplicate" placement="right">
|
|
105
|
+
<IconButton
|
|
106
|
+
size="small"
|
|
107
|
+
onClick={(e) => {
|
|
108
|
+
e.stopPropagation();
|
|
109
|
+
onDuplicate?.();
|
|
110
|
+
}}
|
|
111
|
+
sx={{
|
|
112
|
+
color: 'rgba(255, 255, 255, 0.6)',
|
|
113
|
+
'&:hover': {
|
|
114
|
+
backgroundColor: 'rgba(255, 255, 255, 0.1)',
|
|
115
|
+
color: '#fff',
|
|
116
|
+
},
|
|
117
|
+
}}
|
|
118
|
+
>
|
|
119
|
+
<IconCopy size={18} />
|
|
120
|
+
</IconButton>
|
|
121
|
+
</Tooltip>
|
|
122
|
+
<Tooltip title="Delete" placement="right">
|
|
123
|
+
<IconButton
|
|
124
|
+
size="small"
|
|
125
|
+
onClick={(e) => {
|
|
126
|
+
e.stopPropagation();
|
|
127
|
+
onDelete?.();
|
|
128
|
+
}}
|
|
129
|
+
sx={{
|
|
130
|
+
color: 'rgba(255, 255, 255, 0.6)',
|
|
131
|
+
'&:hover': {
|
|
132
|
+
backgroundColor: 'rgba(239, 68, 68, 0.2)',
|
|
133
|
+
color: '#EF4444',
|
|
134
|
+
},
|
|
135
|
+
}}
|
|
136
|
+
>
|
|
137
|
+
<IconTrash size={18} />
|
|
138
|
+
</IconButton>
|
|
139
|
+
</Tooltip>
|
|
140
|
+
</Box>
|
|
141
|
+
);
|
|
142
|
+
};
|
|
143
|
+
|
|
144
|
+
export default NodeActionButtons;
|
|
145
|
+
|
|
@@ -1,20 +1,12 @@
|
|
|
1
|
-
export { AutomationStartNode } from './AutomationStartNode';
|
|
2
|
-
export { AutomationApiNode } from './AutomationApiNode';
|
|
3
|
-
export { AutomationFormattingNode } from './AutomationFormattingNode';
|
|
4
|
-
export { AutomationSheetsNode } from './AutomationSheetsNode';
|
|
5
|
-
export { AutomationEndNode } from './AutomationEndNode';
|
|
6
|
-
export { AutomationNoteNode } from './AutomationNoteNode';
|
|
7
|
-
export { AutomationExecutionPanel } from './AutomationExecutionPanel';
|
|
8
|
-
export { AutomationAISuggestionNode } from './AutomationAISuggestionNode';
|
|
9
|
-
export { AISuggestionsModal, showAISuggestionsModal } from './AISuggestionsModal';
|
|
10
|
-
export { AISuggestionsPanel } from './AISuggestionsPanel';
|
|
11
|
-
export { NodeActionButtons } from './NodeActionButtons';
|
|
12
|
-
export {
|
|
13
|
-
export type { AISuggestion } from './AISuggestionsModal';
|
|
14
|
-
export {
|
|
15
|
-
setNodeAIAssistantEndpoint,
|
|
16
|
-
setNodeAIAssistantHeaders,
|
|
17
|
-
getNodeAIAssistantEndpoint,
|
|
18
|
-
getNodeAIAssistantHeaders,
|
|
19
|
-
configureNodeAIAssistant,
|
|
20
|
-
} from '../../utils/nodeAIAssistantConfig';
|
|
1
|
+
export { AutomationStartNode } from './AutomationStartNode';
|
|
2
|
+
export { AutomationApiNode } from './AutomationApiNode';
|
|
3
|
+
export { AutomationFormattingNode } from './AutomationFormattingNode';
|
|
4
|
+
export { AutomationSheetsNode } from './AutomationSheetsNode';
|
|
5
|
+
export { AutomationEndNode } from './AutomationEndNode';
|
|
6
|
+
export { AutomationNoteNode } from './AutomationNoteNode';
|
|
7
|
+
export { AutomationExecutionPanel } from './AutomationExecutionPanel';
|
|
8
|
+
export { AutomationAISuggestionNode } from './AutomationAISuggestionNode';
|
|
9
|
+
export { AISuggestionsModal, showAISuggestionsModal } from './AISuggestionsModal';
|
|
10
|
+
export { AISuggestionsPanel } from './AISuggestionsPanel';
|
|
11
|
+
export { NodeActionButtons } from './NodeActionButtons';
|
|
12
|
+
export type { AISuggestion } from './AISuggestionsModal';
|