groove-dev 0.22.10 → 0.22.13

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.
@@ -5,12 +5,12 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1.0" />
6
6
  <link rel="icon" type="image/png" href="/favicon.png" />
7
7
  <title>Groove GUI</title>
8
- <script type="module" crossorigin src="/assets/index-CMvht38D.js"></script>
8
+ <script type="module" crossorigin src="/assets/index-BHRPxAO4.js"></script>
9
9
  <link rel="modulepreload" crossorigin href="/assets/vendor-C0HXlhrU.js">
10
10
  <link rel="modulepreload" crossorigin href="/assets/reactflow-BQPfi37R.js">
11
11
  <link rel="modulepreload" crossorigin href="/assets/codemirror-BBL3i_JW.js">
12
12
  <link rel="modulepreload" crossorigin href="/assets/xterm--7_ns2zW.js">
13
- <link rel="stylesheet" crossorigin href="/assets/index-CCGYUyEa.css">
13
+ <link rel="stylesheet" crossorigin href="/assets/index-B3U0Ree4.css">
14
14
  </head>
15
15
  <body>
16
16
  <div id="root"></div>
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@groove-dev/gui",
3
- "version": "0.18.2",
3
+ "version": "0.22.12",
4
4
  "description": "GROOVE GUI — visual agent control plane",
5
5
  "license": "FSL-1.1-Apache-2.0",
6
6
  "type": "module",
@@ -25,7 +25,7 @@
25
25
  --color-text-1: #bcc2cd;
26
26
  --color-text-2: #8b929e;
27
27
  --color-text-3: #6e7681;
28
- --color-text-4: #505862;
28
+ --color-text-4: #6b7280;
29
29
 
30
30
  /* Borders */
31
31
  --color-border: #3e4451;
@@ -168,3 +168,12 @@ html {
168
168
  }
169
169
 
170
170
  /* ── React Flow Overrides ─────────────────────────────────── */
171
+
172
+ /* Suppress node fly-in animation — nodes appear in position instantly */
173
+ .react-flow__node {
174
+ transition: none !important;
175
+ }
176
+ /* Re-enable transitions only for drag interactions */
177
+ .react-flow__node.dragging {
178
+ transition: none !important;
179
+ }
@@ -118,7 +118,15 @@ export const useGrooveStore = create((set, get) => ({
118
118
 
119
119
  case 'agent:output': {
120
120
  const { agentId, data } = msg;
121
- const text = typeof data.data === 'string' ? data.data : (Array.isArray(data.data) ? data.data.filter((b) => b.type === 'text').map((b) => b.text).join('\n') : '');
121
+ // Extract text from Claude Code content blocks or plain strings
122
+ let text = '';
123
+ if (typeof data.data === 'string') {
124
+ text = data.data;
125
+ } else if (Array.isArray(data.data)) {
126
+ const textParts = data.data.filter((b) => b.type === 'text').map((b) => b.text);
127
+ const toolParts = data.data.filter((b) => b.type === 'tool_use').map((b) => `[${b.name}] ${typeof b.input === 'string' ? b.input : JSON.stringify(b.input || '').slice(0, 100)}`);
128
+ text = [...textParts, ...toolParts].join('\n');
129
+ }
122
130
 
123
131
  // Update agent metrics in real-time (contextUsage, tokensUsed)
124
132
  if (data.contextUsage !== undefined || data.tokensUsed !== undefined) {
@@ -270,19 +270,40 @@ function AgentTreeInner() {
270
270
 
271
271
  const [nodes, setNodes, onNodesChange] = useNodesState(targetNodes);
272
272
  const [edges, setEdges, onEdgesChange] = useEdgesState(targetEdges);
273
- const mountedRef = useRef(false);
273
+ const prevAgentIds = useRef(new Set());
274
+
275
+ // Update node DATA without replacing positions (prevents fly-in)
276
+ useEffect(() => {
277
+ setNodes((current) => {
278
+ const currentMap = new Map(current.map((n) => [n.id, n]));
279
+ const newIds = new Set(targetNodes.map((n) => n.id));
280
+
281
+ return targetNodes.map((tn) => {
282
+ const existing = currentMap.get(tn.id);
283
+ if (existing) {
284
+ // Preserve existing position, update data only
285
+ return { ...existing, data: tn.data };
286
+ }
287
+ // New node — use calculated position
288
+ return tn;
289
+ });
290
+ });
291
+ }, [targetNodes, setNodes]);
274
292
 
275
- useEffect(() => { setNodes(targetNodes); }, [targetNodes, setNodes]);
276
293
  useEffect(() => { setEdges(targetEdges); }, [targetEdges, setEdges]);
277
294
 
278
295
  useEffect(() => {
279
- if (agents.length > 0) {
280
- const delay = mountedRef.current ? 200 : 50;
281
- setTimeout(() => fitView({ padding: 0.3, maxZoom: 1.2, duration: mountedRef.current ? 400 : 0 }), delay);
282
- mountedRef.current = true;
296
+ const currentIds = new Set(agents.map((a) => a.id));
297
+ const isNewAgent = agents.length > 0 && [...currentIds].some((id) => !prevAgentIds.current.has(id));
298
+ prevAgentIds.current = currentIds;
299
+
300
+ if (prevCount === 0 && agents.length > 0) {
301
+ setTimeout(() => fitView({ padding: 0.3, maxZoom: 1.2, duration: 0 }), 50);
302
+ } else if (isNewAgent) {
303
+ setTimeout(() => fitView({ padding: 0.3, maxZoom: 1.2, duration: 300 }), 100);
283
304
  }
284
305
  setPrevCount(agents.length);
285
- }, [agents.length, prevCount, fitView]);
306
+ }, [agents.length, agents, prevCount, fitView]);
286
307
 
287
308
  const onNodeClick = useCallback((_e, node) => {
288
309
  if (node.id === ROOT_ID) return;
@@ -326,13 +347,6 @@ function AgentTreeInner() {
326
347
  savePositions(saved);
327
348
  }, [agents]);
328
349
 
329
- // Suppress CSS transitions on initial render to prevent node fly-in
330
- const [ready, setReady] = useState(false);
331
- useEffect(() => {
332
- const timer = setTimeout(() => setReady(true), 300);
333
- return () => clearTimeout(timer);
334
- }, []);
335
-
336
350
  return (
337
351
  <ReactFlow
338
352
  nodes={nodes}
@@ -348,7 +362,7 @@ function AgentTreeInner() {
348
362
  proOptions={{ hideAttribution: true }}
349
363
  minZoom={0.2}
350
364
  maxZoom={1.5}
351
- className={cn('bg-surface-2', !ready && '[&_.react-flow__node]:!transition-none')}
365
+ className="bg-surface-2"
352
366
  >
353
367
  <Background color="rgba(97,175,239,0.03)" gap={24} size={1} />
354
368
  </ReactFlow>