@genfeedai/workflow-ui 0.2.3 → 0.2.5
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.d.ts +22 -22
- package/dist/canvas.mjs +16 -16
- package/dist/{chunk-XPZAHIWY.mjs → chunk-2FUPL67V.mjs} +1592 -1044
- package/dist/{chunk-HWVTD2LC.mjs → chunk-53XDE62A.mjs} +818 -623
- package/dist/{chunk-PCIWWD37.mjs → chunk-7LV4UAUS.mjs} +19 -19
- package/dist/{chunk-7SKSRSS7.mjs → chunk-B4EAAKYF.mjs} +16 -16
- package/dist/{chunk-ZJD5WMR3.mjs → chunk-C6MQBJFC.mjs} +45 -13
- package/dist/{chunk-7H3WJJYS.mjs → chunk-ESVULCFY.mjs} +12 -6
- package/dist/{chunk-GWBGK3KL.mjs → chunk-FWJIAW2E.mjs} +82 -47
- package/dist/{chunk-R727OFBR.mjs → chunk-GPYIIWD5.mjs} +404 -350
- package/dist/{chunk-OQREHJXK.mjs → chunk-IYFWAJBB.mjs} +208 -203
- package/dist/{chunk-N5NJZTK4.mjs → chunk-MGLAKMDP.mjs} +23 -21
- package/dist/{chunk-LT3ZJJL6.mjs → chunk-OJWVEEMM.mjs} +497 -399
- package/dist/{chunk-ZD2BADZO.mjs → chunk-ORVDYXDP.mjs} +221 -175
- package/dist/{chunk-CV4M7CNU.mjs → chunk-QQVHGJ2G.mjs} +149 -142
- package/dist/{chunk-6PSJTBNV.mjs → chunk-U4QPE4CY.mjs} +387 -347
- package/dist/{chunk-EFXQT23N.mjs → chunk-VVQ4CH77.mjs} +5 -5
- package/dist/{chunk-VRN3UWE5.mjs → chunk-XRC3O5GK.mjs} +73 -73
- package/dist/{chunk-FT33LFII.mjs → chunk-YUIK4AHM.mjs} +1 -1
- package/dist/{chunk-FMJPFB6W.mjs → chunk-ZSITTZ4S.mjs} +630 -569
- package/dist/hooks.d.ts +37 -37
- package/dist/hooks.mjs +10 -10
- package/dist/index.d.ts +26 -11
- package/dist/index.mjs +105 -19
- package/dist/lib.d.ts +203 -203
- package/dist/lib.mjs +228 -198
- package/dist/nodes.d.ts +2 -2
- package/dist/nodes.mjs +12 -12
- package/dist/panels.d.ts +2 -3
- package/dist/panels.mjs +3 -3
- package/dist/provider.d.ts +2 -2
- package/dist/provider.mjs +2 -2
- package/dist/stores.d.ts +5 -5
- package/dist/stores.mjs +5 -5
- package/dist/toolbar.d.ts +42 -24
- package/dist/toolbar.mjs +4 -4
- package/dist/ui.d.ts +2 -2
- package/dist/ui.mjs +2 -2
- package/dist/{useCommentNavigation-BakbiiIc.d.ts → useRequiredInputs-ByoIS-fT.d.ts} +160 -160
- package/dist/{promptLibraryStore-Dl3Q3cP6.d.ts → workflowStore-Bsz0nd5c.d.ts} +368 -368
- package/dist/workflowStore-N2F7WIG3.mjs +2 -0
- package/package.json +77 -75
- package/src/styles/workflow-ui.css +56 -19
- package/dist/workflowStore-UAAKOOIK.mjs +0 -2
- package/dist/{types-IEKYuYhu.d.ts → types-CRXJnajq.d.ts} +1 -1
package/package.json
CHANGED
|
@@ -1,78 +1,4 @@
|
|
|
1
1
|
{
|
|
2
|
-
"name": "@genfeedai/workflow-ui",
|
|
3
|
-
"version": "0.2.3",
|
|
4
|
-
"type": "module",
|
|
5
|
-
"license": "AGPL-3.0",
|
|
6
|
-
"description": "Shared UI components for Genfeed workflow editor",
|
|
7
|
-
"repository": {
|
|
8
|
-
"type": "git",
|
|
9
|
-
"url": "git+https://github.com/genfeedai/packages.git",
|
|
10
|
-
"directory": "workflow-ui"
|
|
11
|
-
},
|
|
12
|
-
"publishConfig": {
|
|
13
|
-
"access": "public",
|
|
14
|
-
"registry": "https://registry.npmjs.org/"
|
|
15
|
-
},
|
|
16
|
-
"module": "./dist/index.mjs",
|
|
17
|
-
"types": "./dist/index.d.ts",
|
|
18
|
-
"exports": {
|
|
19
|
-
".": {
|
|
20
|
-
"types": "./dist/index.d.ts",
|
|
21
|
-
"import": "./dist/index.mjs"
|
|
22
|
-
},
|
|
23
|
-
"./canvas": {
|
|
24
|
-
"types": "./dist/canvas.d.ts",
|
|
25
|
-
"import": "./dist/canvas.mjs"
|
|
26
|
-
},
|
|
27
|
-
"./nodes": {
|
|
28
|
-
"types": "./dist/nodes.d.ts",
|
|
29
|
-
"import": "./dist/nodes.mjs"
|
|
30
|
-
},
|
|
31
|
-
"./panels": {
|
|
32
|
-
"types": "./dist/panels.d.ts",
|
|
33
|
-
"import": "./dist/panels.mjs"
|
|
34
|
-
},
|
|
35
|
-
"./toolbar": {
|
|
36
|
-
"types": "./dist/toolbar.d.ts",
|
|
37
|
-
"import": "./dist/toolbar.mjs"
|
|
38
|
-
},
|
|
39
|
-
"./hooks": {
|
|
40
|
-
"types": "./dist/hooks.d.ts",
|
|
41
|
-
"import": "./dist/hooks.mjs"
|
|
42
|
-
},
|
|
43
|
-
"./stores": {
|
|
44
|
-
"types": "./dist/stores.d.ts",
|
|
45
|
-
"import": "./dist/stores.mjs"
|
|
46
|
-
},
|
|
47
|
-
"./provider": {
|
|
48
|
-
"types": "./dist/provider.d.ts",
|
|
49
|
-
"import": "./dist/provider.mjs"
|
|
50
|
-
},
|
|
51
|
-
"./ui": {
|
|
52
|
-
"types": "./dist/ui.d.ts",
|
|
53
|
-
"import": "./dist/ui.mjs"
|
|
54
|
-
},
|
|
55
|
-
"./lib": {
|
|
56
|
-
"types": "./dist/lib.d.ts",
|
|
57
|
-
"import": "./dist/lib.mjs"
|
|
58
|
-
},
|
|
59
|
-
"./styles": "./src/styles/workflow-ui.css"
|
|
60
|
-
},
|
|
61
|
-
"files": [
|
|
62
|
-
"dist",
|
|
63
|
-
"src/styles"
|
|
64
|
-
],
|
|
65
|
-
"sideEffects": [
|
|
66
|
-
"**/*.css"
|
|
67
|
-
],
|
|
68
|
-
"peerDependencies": {
|
|
69
|
-
"@xyflow/react": ">=12.0.0",
|
|
70
|
-
"next": ">=14.0.0",
|
|
71
|
-
"react": ">=19.0.0",
|
|
72
|
-
"react-dom": ">=19.0.0",
|
|
73
|
-
"zustand": ">=5.0.0",
|
|
74
|
-
"zundo": ">=2.0.0"
|
|
75
|
-
},
|
|
76
2
|
"dependencies": {
|
|
77
3
|
"@dagrejs/dagre": "^2.0.4",
|
|
78
4
|
"@genfeedai/core": "^0.2.1",
|
|
@@ -88,6 +14,7 @@
|
|
|
88
14
|
"nanoid": "^5.1.6",
|
|
89
15
|
"tailwind-merge": "^3.4.0"
|
|
90
16
|
},
|
|
17
|
+
"description": "Shared UI components for Genfeed workflow editor",
|
|
91
18
|
"devDependencies": {
|
|
92
19
|
"@testing-library/jest-dom": "6.6.3",
|
|
93
20
|
"@testing-library/react": "16.2.0",
|
|
@@ -105,10 +32,85 @@
|
|
|
105
32
|
"zundo": "2.3.0",
|
|
106
33
|
"zustand": "5.0.3"
|
|
107
34
|
},
|
|
35
|
+
"exports": {
|
|
36
|
+
".": {
|
|
37
|
+
"import": "./dist/index.mjs",
|
|
38
|
+
"types": "./dist/index.d.ts"
|
|
39
|
+
},
|
|
40
|
+
"./canvas": {
|
|
41
|
+
"import": "./dist/canvas.mjs",
|
|
42
|
+
"types": "./dist/canvas.d.ts"
|
|
43
|
+
},
|
|
44
|
+
"./hooks": {
|
|
45
|
+
"import": "./dist/hooks.mjs",
|
|
46
|
+
"types": "./dist/hooks.d.ts"
|
|
47
|
+
},
|
|
48
|
+
"./lib": {
|
|
49
|
+
"import": "./dist/lib.mjs",
|
|
50
|
+
"types": "./dist/lib.d.ts"
|
|
51
|
+
},
|
|
52
|
+
"./nodes": {
|
|
53
|
+
"import": "./dist/nodes.mjs",
|
|
54
|
+
"types": "./dist/nodes.d.ts"
|
|
55
|
+
},
|
|
56
|
+
"./panels": {
|
|
57
|
+
"import": "./dist/panels.mjs",
|
|
58
|
+
"types": "./dist/panels.d.ts"
|
|
59
|
+
},
|
|
60
|
+
"./provider": {
|
|
61
|
+
"import": "./dist/provider.mjs",
|
|
62
|
+
"types": "./dist/provider.d.ts"
|
|
63
|
+
},
|
|
64
|
+
"./stores": {
|
|
65
|
+
"import": "./dist/stores.mjs",
|
|
66
|
+
"types": "./dist/stores.d.ts"
|
|
67
|
+
},
|
|
68
|
+
"./styles": "./src/styles/workflow-ui.css",
|
|
69
|
+
"./toolbar": {
|
|
70
|
+
"import": "./dist/toolbar.mjs",
|
|
71
|
+
"types": "./dist/toolbar.d.ts"
|
|
72
|
+
},
|
|
73
|
+
"./ui": {
|
|
74
|
+
"import": "./dist/ui.mjs",
|
|
75
|
+
"types": "./dist/ui.d.ts"
|
|
76
|
+
}
|
|
77
|
+
},
|
|
78
|
+
"files": [
|
|
79
|
+
"dist",
|
|
80
|
+
"src/styles"
|
|
81
|
+
],
|
|
82
|
+
"license": "AGPL-3.0",
|
|
83
|
+
"module": "./dist/index.mjs",
|
|
84
|
+
"name": "@genfeedai/workflow-ui",
|
|
85
|
+
"peerDependencies": {
|
|
86
|
+
"@xyflow/react": ">=12.0.0",
|
|
87
|
+
"next": ">=14.0.0",
|
|
88
|
+
"react": ">=19.0.0",
|
|
89
|
+
"react-dom": ">=19.0.0",
|
|
90
|
+
"zundo": ">=2.0.0",
|
|
91
|
+
"zustand": ">=5.0.0"
|
|
92
|
+
},
|
|
93
|
+
"publishConfig": {
|
|
94
|
+
"access": "public",
|
|
95
|
+
"registry": "https://registry.npmjs.org/"
|
|
96
|
+
},
|
|
97
|
+
"repository": {
|
|
98
|
+
"directory": "workflow-ui",
|
|
99
|
+
"type": "git",
|
|
100
|
+
"url": "git+https://github.com/genfeedai/packages.git"
|
|
101
|
+
},
|
|
108
102
|
"scripts": {
|
|
109
103
|
"build": "tsup",
|
|
110
104
|
"dev": "tsup --watch",
|
|
111
105
|
"prepublishOnly": "bun run build",
|
|
106
|
+
"publish": "PACKAGE_FILTER=workflow-ui PUBLISH_PROVENANCE=0 node ../scripts/publish-public-packages.mjs",
|
|
107
|
+
"publish:dry-run": "PACKAGE_FILTER=workflow-ui PUBLISH_DRY_RUN=1 PUBLISH_PROVENANCE=0 node ../scripts/publish-public-packages.mjs",
|
|
112
108
|
"test": "vitest run"
|
|
113
|
-
}
|
|
109
|
+
},
|
|
110
|
+
"sideEffects": [
|
|
111
|
+
"**/*.css"
|
|
112
|
+
],
|
|
113
|
+
"type": "module",
|
|
114
|
+
"types": "./dist/index.d.ts",
|
|
115
|
+
"version": "0.2.5"
|
|
114
116
|
}
|
|
@@ -50,10 +50,18 @@
|
|
|
50
50
|
border: 2px solid var(--background);
|
|
51
51
|
}
|
|
52
52
|
|
|
53
|
-
.react-flow__handle-left {
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
.react-flow__handle-
|
|
53
|
+
.react-flow__handle-left {
|
|
54
|
+
left: -5px;
|
|
55
|
+
}
|
|
56
|
+
.react-flow__handle-right {
|
|
57
|
+
right: -5px;
|
|
58
|
+
}
|
|
59
|
+
.react-flow__handle-top {
|
|
60
|
+
top: -5px;
|
|
61
|
+
}
|
|
62
|
+
.react-flow__handle-bottom {
|
|
63
|
+
bottom: -5px;
|
|
64
|
+
}
|
|
57
65
|
|
|
58
66
|
.react-flow__edge-path {
|
|
59
67
|
stroke: var(--muted-foreground);
|
|
@@ -61,17 +69,29 @@
|
|
|
61
69
|
}
|
|
62
70
|
|
|
63
71
|
/* Edge type colors (based on data type flowing through) */
|
|
64
|
-
.react-flow__edge.edge-image .react-flow__edge-path {
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
.react-flow__edge.edge-
|
|
68
|
-
|
|
72
|
+
.react-flow__edge.edge-image .react-flow__edge-path {
|
|
73
|
+
stroke: var(--handle-image);
|
|
74
|
+
}
|
|
75
|
+
.react-flow__edge.edge-video .react-flow__edge-path {
|
|
76
|
+
stroke: var(--handle-video);
|
|
77
|
+
}
|
|
78
|
+
.react-flow__edge.edge-text .react-flow__edge-path {
|
|
79
|
+
stroke: var(--handle-text);
|
|
80
|
+
}
|
|
81
|
+
.react-flow__edge.edge-number .react-flow__edge-path {
|
|
82
|
+
stroke: var(--handle-number);
|
|
83
|
+
}
|
|
84
|
+
.react-flow__edge.edge-audio .react-flow__edge-path {
|
|
85
|
+
stroke: var(--handle-audio);
|
|
86
|
+
}
|
|
69
87
|
|
|
70
88
|
/* Selected edge - highlight with glow (preserves type color) */
|
|
71
89
|
.react-flow__edge.selected .react-flow__edge-path {
|
|
72
90
|
stroke-width: 3px;
|
|
73
91
|
filter: drop-shadow(0 0 6px currentColor) brightness(1.3);
|
|
74
|
-
transition:
|
|
92
|
+
transition:
|
|
93
|
+
stroke-width 0.15s ease,
|
|
94
|
+
filter 0.15s ease;
|
|
75
95
|
}
|
|
76
96
|
|
|
77
97
|
/* Dimmed edges (not connected to selection) */
|
|
@@ -83,7 +103,9 @@
|
|
|
83
103
|
/* Highlighted edges (connected to selection) - brighten the type color */
|
|
84
104
|
.react-flow__edge.highlighted .react-flow__edge-path {
|
|
85
105
|
filter: drop-shadow(0 0 4px currentColor) brightness(1.2);
|
|
86
|
-
transition:
|
|
106
|
+
transition:
|
|
107
|
+
opacity 0.2s ease,
|
|
108
|
+
filter 0.2s ease;
|
|
87
109
|
}
|
|
88
110
|
|
|
89
111
|
/* Executing edges (during workflow execution) - pipe flow effect */
|
|
@@ -109,7 +131,9 @@
|
|
|
109
131
|
stroke-width: 1.5px;
|
|
110
132
|
stroke-dasharray: 5 5;
|
|
111
133
|
opacity: 0.3;
|
|
112
|
-
transition:
|
|
134
|
+
transition:
|
|
135
|
+
opacity 0.2s ease,
|
|
136
|
+
stroke 0.2s ease;
|
|
113
137
|
}
|
|
114
138
|
|
|
115
139
|
.react-flow__background {
|
|
@@ -150,12 +174,24 @@
|
|
|
150
174
|
Handle Type Color Classes
|
|
151
175
|
========================================================================== */
|
|
152
176
|
|
|
153
|
-
.handle-image {
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
.handle-
|
|
157
|
-
|
|
158
|
-
|
|
177
|
+
.handle-image {
|
|
178
|
+
background: var(--handle-image) !important;
|
|
179
|
+
}
|
|
180
|
+
.handle-video {
|
|
181
|
+
background: var(--handle-video) !important;
|
|
182
|
+
}
|
|
183
|
+
.handle-text {
|
|
184
|
+
background: var(--handle-text) !important;
|
|
185
|
+
}
|
|
186
|
+
.handle-number {
|
|
187
|
+
background: var(--handle-number) !important;
|
|
188
|
+
}
|
|
189
|
+
.handle-audio {
|
|
190
|
+
background: var(--handle-audio) !important;
|
|
191
|
+
}
|
|
192
|
+
.handle-output {
|
|
193
|
+
background: var(--handle-output) !important;
|
|
194
|
+
}
|
|
159
195
|
|
|
160
196
|
/* ==========================================================================
|
|
161
197
|
Animation Keyframes
|
|
@@ -163,7 +199,8 @@
|
|
|
163
199
|
|
|
164
200
|
/* Processing node glow animation */
|
|
165
201
|
@keyframes processing-glow {
|
|
166
|
-
0%,
|
|
202
|
+
0%,
|
|
203
|
+
100% {
|
|
167
204
|
box-shadow: 0 0 8px 2px var(--node-color, var(--primary));
|
|
168
205
|
}
|
|
169
206
|
50% {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ComponentType } from 'react';
|
|
2
1
|
import { ProviderModel, ModelCapability, IQueryPrompts, IPrompt, ICreatePrompt } from '@genfeedai/types';
|
|
2
|
+
import { ComponentType } from 'react';
|
|
3
3
|
|
|
4
4
|
interface FileUploadService {
|
|
5
5
|
uploadFile: (path: string, file: File) => Promise<{
|