@ultrst-armada/floks 1.2.4 → 1.2.6

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.
Files changed (43) hide show
  1. package/README.md +10 -0
  2. package/package.json +13 -9
  3. package/packages/canvas-ui/dist/chunk-QRYNQ36L.js +123 -0
  4. package/packages/canvas-ui/dist/{chunk-OOTTFWXA.js → chunk-RH5NINIT.js} +1 -122
  5. package/packages/canvas-ui/dist/chunk-VESG3VP3.js +1522 -0
  6. package/packages/canvas-ui/dist/frnl-editable-node-graph/index.d.ts +110 -0
  7. package/packages/canvas-ui/dist/frnl-editable-node-graph/index.js +9 -0
  8. package/packages/canvas-ui/dist/index.d.ts +13 -2
  9. package/packages/canvas-ui/dist/index.js +63 -485
  10. package/packages/canvas-ui/dist/predictive/index.js +4 -2
  11. package/packages/canvas-ui/floks.manifest.json +25 -4
  12. package/packages/canvas-ui/package.json +11 -7
  13. package/packages/contracts/dist/index.js +2 -2
  14. package/packages/ui/dist/chunk-2SD6BIUX.js +0 -0
  15. package/packages/ui/dist/chunk-DGZBP3ND.js +832 -0
  16. package/packages/ui/dist/{chunk-2SFOC7KZ.js → chunk-KQAFKNQH.js} +77 -67
  17. package/packages/ui/dist/chunk-PH4NEHWR.js +99 -0
  18. package/packages/ui/dist/chunk-PRMOURNW.js +324 -0
  19. package/packages/ui/dist/{chunk-KYFSUQVT.js → chunk-SXRIBCJX.js} +124 -110
  20. package/packages/ui/dist/chunk-X4B3EBMY.js +22 -0
  21. package/packages/ui/dist/{chunk-DT6DZU63.js → chunk-X67KXI3H.js} +190 -152
  22. package/packages/ui/dist/chunk-YVWJ4SW7.js +394 -0
  23. package/packages/ui/dist/components/auth/index.d.ts +56 -14
  24. package/packages/ui/dist/components/auth/index.js +12 -3
  25. package/packages/ui/dist/components/graph/index.d.ts +29 -0
  26. package/packages/ui/dist/components/graph/index.js +10 -0
  27. package/packages/ui/dist/components/settings/index.js +2 -2
  28. package/packages/ui/dist/components/tiles/index.d.ts +83 -0
  29. package/packages/ui/dist/components/tiles/index.js +10 -0
  30. package/packages/ui/dist/components/workspace/index.d.ts +108 -33
  31. package/packages/ui/dist/components/workspace/index.js +15 -3
  32. package/packages/ui/dist/frnl/index.css +183 -0
  33. package/packages/ui/dist/frnl/index.d.ts +555 -0
  34. package/packages/ui/dist/frnl/index.js +48 -0
  35. package/packages/ui/dist/frnl/store.d.ts +29 -0
  36. package/packages/ui/dist/frnl/store.js +12 -0
  37. package/packages/ui/dist/hierarchy/index.d.ts +15 -51
  38. package/packages/ui/dist/hierarchy/index.js +6 -19
  39. package/packages/ui/dist/index.d.ts +9 -4
  40. package/packages/ui/dist/index.js +101 -46
  41. package/packages/ui/floks.manifest.json +99 -17
  42. package/packages/ui/package.json +24 -2
  43. package/packages/ui/dist/{chunk-ROILFUZW.js → chunk-ZPQC46RO.js} +3 -3
@@ -9,6 +9,20 @@ import {
9
9
  DockItem,
10
10
  useDock
11
11
  } from "./chunk-6VB74RCH.js";
12
+ import {
13
+ CanvasContextMenu,
14
+ CompatibleNodePicker,
15
+ FrnlEditableNodeGraph,
16
+ NodeSearchPalette,
17
+ frnlEditableNodeGraphDefinition,
18
+ menuCategory,
19
+ menuHidden
20
+ } from "./chunk-VESG3VP3.js";
21
+ import {
22
+ MonacoEditor,
23
+ skipoDarkTheme,
24
+ useMonaco
25
+ } from "./chunk-QTTWWBNN.js";
12
26
  import {
13
27
  BIOME_CONFIGS,
14
28
  COORD_SCALE,
@@ -25,23 +39,14 @@ import {
25
39
  useCanvas2DCoordinates,
26
40
  useCanvas2DMagnetic
27
41
  } from "./chunk-XVAHT5WE.js";
28
- import {
29
- MonacoEditor,
30
- skipoDarkTheme,
31
- useMonaco
32
- } from "./chunk-QTTWWBNN.js";
33
- import {
34
- Tile,
35
- TileCreateButton,
36
- TileGrid,
37
- useTileMenu
38
- } from "./chunk-SA3JADUG.js";
39
42
  import {
40
43
  PredictiveGhostNodeCard,
41
44
  PredictiveHudToolbar,
42
- PredictiveLayer2D,
45
+ PredictiveLayer2D
46
+ } from "./chunk-RH5NINIT.js";
47
+ import {
43
48
  usePredictiveGraph2D
44
- } from "./chunk-OOTTFWXA.js";
49
+ } from "./chunk-QRYNQ36L.js";
45
50
  import {
46
51
  NODE_CARD_WIDTH,
47
52
  Node2DBase,
@@ -52,6 +57,12 @@ import {
52
57
  getSocketScreenPosition,
53
58
  renderSpriteIcon
54
59
  } from "./chunk-U2SC3RMJ.js";
60
+ import {
61
+ Tile,
62
+ TileCreateButton,
63
+ TileGrid,
64
+ useTileMenu
65
+ } from "./chunk-SA3JADUG.js";
55
66
 
56
67
  // src/node-graph-ui/widgets/MidpointWidgets.tsx
57
68
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
@@ -194,445 +205,8 @@ function SolidifyWidget({ x, y, onSolidify }) {
194
205
  );
195
206
  }
196
207
 
197
- // src/node-graph-ui/widgets/CompatibleNodePicker.tsx
198
- import { useState, useMemo } from "react";
199
- import { ConnectionRuleStore } from "@ultrst-armada/kloks/state-graph";
200
- import { useSearchKeyboardNavigation, BaseButton, BaseInput } from "@ultrst-armada/floks/ui";
201
- import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
202
- function CompatibleNodePicker({
203
- x,
204
- y,
205
- sourceHandle,
206
- availableNodeTypes,
207
- onSelect,
208
- onClose
209
- }) {
210
- const [selectedTypes, setSelectedTypes] = useState(/* @__PURE__ */ new Set());
211
- const [searchTerm, setSearchTerm] = useState("");
212
- const compatibleNodes = useMemo(() => {
213
- const isOut = sourceHandle.direction === "output";
214
- return ConnectionRuleStore.getCompatibleNodeTypes(
215
- { dataType: sourceHandle.dataType || "ANY", direction: isOut ? "OUTPUT" : "INPUT", handleCategory: "DATA" },
216
- availableNodeTypes
217
- );
218
- }, [sourceHandle, availableNodeTypes]);
219
- const filteredNodes = useMemo(() => {
220
- if (!searchTerm.trim()) return compatibleNodes;
221
- const term = searchTerm.toLowerCase();
222
- return compatibleNodes.filter((n) => n.type.toLowerCase().includes(term) || n.label.toLowerCase().includes(term));
223
- }, [compatibleNodes, searchTerm]);
224
- const handleQuickSelect = (type) => onSelect([type]);
225
- const { highlightedIndex, setHighlightedIndex, handleKeyDown, listContainerRef } = useSearchKeyboardNavigation({
226
- items: filteredNodes,
227
- onSelect: (node) => handleQuickSelect(node.type),
228
- onClose
229
- });
230
- const toggleSelect = (type) => {
231
- setSelectedTypes((prev) => {
232
- const next = new Set(prev);
233
- if (next.has(type)) next.delete(type);
234
- else next.add(type);
235
- return next;
236
- });
237
- };
238
- return /* @__PURE__ */ jsxs2(
239
- "div",
240
- {
241
- style: {
242
- position: "absolute",
243
- left: x,
244
- top: y,
245
- transform: "translate(-50%, 0)",
246
- width: "270px",
247
- maxHeight: "360px",
248
- backgroundColor: "var(--skipo-surface)",
249
- border: "var(--skipo-border)",
250
- borderRadius: "var(--skipo-radius)",
251
- boxShadow: "var(--skipo-shadow)",
252
- color: "var(--skipo-text)",
253
- zIndex: 50,
254
- display: "flex",
255
- flexDirection: "column",
256
- overflow: "hidden",
257
- fontFamily: "var(--skipo-font)"
258
- },
259
- onClick: (e) => e.stopPropagation(),
260
- onMouseDown: (e) => e.stopPropagation(),
261
- children: [
262
- /* @__PURE__ */ jsxs2("div", { style: { padding: "8px 12px", borderBottom: "var(--skipo-border)", display: "flex", alignItems: "center", justifyContent: "space-between", backgroundColor: "var(--skipo-matte-bg)" }, children: [
263
- /* @__PURE__ */ jsxs2("div", { style: { display: "flex", flexDirection: "column" }, children: [
264
- /* @__PURE__ */ jsx3("span", { style: { fontSize: "11px", fontWeight: 600, color: "var(--skipo-accent)" }, children: "Compatible Nodes" }),
265
- /* @__PURE__ */ jsxs2("span", { style: { fontSize: "9px", color: "var(--skipo-text-muted)" }, children: [
266
- "For ",
267
- sourceHandle.dataType || "ANY",
268
- " (",
269
- sourceHandle.direction,
270
- ")"
271
- ] })
272
- ] }),
273
- /* @__PURE__ */ jsx3(BaseButton, { variant: "ghost", size: "sm", onClick: onClose, "aria-label": "Close picker", style: { padding: "2px 6px" }, children: "\u2715" })
274
- ] }),
275
- /* @__PURE__ */ jsx3("div", { style: { padding: "6px 8px", borderBottom: "var(--skipo-border)" }, children: /* @__PURE__ */ jsx3(BaseInput, { autoFocus: true, placeholder: "Filter nodes... (\u2191\u2193 navigate, \u21B5 spawn)", value: searchTerm, onChange: (e) => setSearchTerm(e.target.value), onKeyDown: handleKeyDown }) }),
276
- /* @__PURE__ */ jsx3("div", { ref: listContainerRef, style: { flex: 1, overflowY: "auto", maxHeight: "180px", padding: "4px" }, children: filteredNodes.length === 0 ? /* @__PURE__ */ jsx3("div", { style: { padding: "16px", textAlign: "center", fontSize: "11px", color: "var(--skipo-text-muted)" }, children: "No compatible nodes found" }) : filteredNodes.map((node, idx) => {
277
- const isSelected = selectedTypes.has(node.type);
278
- const isHighlighted = idx === highlightedIndex;
279
- return /* @__PURE__ */ jsxs2(
280
- "div",
281
- {
282
- onMouseEnter: () => setHighlightedIndex(idx),
283
- onClick: () => toggleSelect(node.type),
284
- onDoubleClick: () => handleQuickSelect(node.type),
285
- style: {
286
- display: "flex",
287
- alignItems: "center",
288
- gap: "8px",
289
- padding: "6px 8px",
290
- borderRadius: "var(--skipo-radius-sm)",
291
- cursor: "pointer",
292
- backgroundColor: isHighlighted ? "var(--skipo-surface-hover)" : isSelected ? "var(--skipo-matte-bg)" : "transparent",
293
- border: isHighlighted ? "var(--skipo-border)" : "1px solid transparent",
294
- marginBottom: "2px",
295
- transition: "background-color 0.1s ease"
296
- },
297
- children: [
298
- /* @__PURE__ */ jsx3("input", { type: "checkbox", checked: isSelected, onChange: () => toggleSelect(node.type), onClick: (e) => e.stopPropagation(), style: { cursor: "pointer" } }),
299
- /* @__PURE__ */ jsxs2("div", { style: { flex: 1, minWidth: 0 }, children: [
300
- /* @__PURE__ */ jsx3("div", { style: { fontSize: "11px", fontWeight: isHighlighted ? 600 : 500, overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", color: isHighlighted ? "var(--skipo-accent)" : "inherit" }, children: node.label || node.type }),
301
- node.description && /* @__PURE__ */ jsx3("div", { style: { fontSize: "9px", color: "var(--skipo-text-muted)", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" }, children: node.description })
302
- ] }),
303
- isHighlighted && /* @__PURE__ */ jsx3("span", { style: { fontSize: "8px", fontWeight: 600, color: "var(--skipo-accent)", padding: "1px 4px", borderRadius: "var(--skipo-radius-sm)", backgroundColor: "var(--skipo-matte-bg)", border: "var(--skipo-border)", whiteSpace: "nowrap" }, children: "\u21B5 Enter" })
304
- ]
305
- },
306
- node.type
307
- );
308
- }) }),
309
- /* @__PURE__ */ jsxs2("div", { style: { padding: "6px 8px", borderTop: "var(--skipo-border)", display: "flex", justifyContent: "space-between", alignItems: "center", backgroundColor: "var(--skipo-matte-bg)" }, children: [
310
- /* @__PURE__ */ jsx3("span", { style: { fontSize: "10px", color: "var(--skipo-text-muted)" }, children: selectedTypes.size > 0 ? `${selectedTypes.size} selected` : "\u21B5 Spawn top match" }),
311
- /* @__PURE__ */ jsxs2("div", { style: { display: "flex", gap: "6px" }, children: [
312
- /* @__PURE__ */ jsx3(BaseButton, { variant: "secondary", size: "sm", onClick: onClose, style: { padding: "2px 8px", fontSize: "10px" }, children: "Cancel" }),
313
- /* @__PURE__ */ jsx3(
314
- BaseButton,
315
- {
316
- variant: "accent",
317
- size: "sm",
318
- disabled: selectedTypes.size === 0 && filteredNodes.length === 0,
319
- onClick: () => {
320
- if (selectedTypes.size > 0) onSelect(Array.from(selectedTypes));
321
- else if (filteredNodes.length > 0) handleQuickSelect(filteredNodes[highlightedIndex >= 0 ? highlightedIndex : 0].type);
322
- },
323
- style: { padding: "2px 10px", fontSize: "10px" },
324
- children: "Spawn & Solidify"
325
- }
326
- )
327
- ] })
328
- ] })
329
- ]
330
- }
331
- );
332
- }
333
-
334
- // src/node-graph-ui/widgets/NodeSearchPalette.tsx
335
- import { useState as useState2, useMemo as useMemo2 } from "react";
336
- import { useSearchKeyboardNavigation as useSearchKeyboardNavigation2, BaseButton as BaseButton2, BaseInput as BaseInput2 } from "@ultrst-armada/floks/ui";
337
- import { jsx as jsx4, jsxs as jsxs3 } from "react/jsx-runtime";
338
- function NodeSearchPalette({
339
- x,
340
- y,
341
- availableNodeTypes = [],
342
- onSpawnNode,
343
- onClose
344
- }) {
345
- const [query, setQuery] = useState2("");
346
- const filteredNodes = useMemo2(() => {
347
- if (!availableNodeTypes || availableNodeTypes.length === 0) {
348
- return [{ type: "default", label: "Default Node", description: "Standard dual-port node" }];
349
- }
350
- if (!query.trim()) return availableNodeTypes;
351
- const q = query.toLowerCase();
352
- return availableNodeTypes.filter(
353
- (n) => n.type.toLowerCase().includes(q) || n.label.toLowerCase().includes(q) || n.description?.toLowerCase().includes(q)
354
- );
355
- }, [availableNodeTypes, query]);
356
- const {
357
- highlightedIndex,
358
- setHighlightedIndex,
359
- handleKeyDown,
360
- listContainerRef
361
- } = useSearchKeyboardNavigation2({
362
- items: filteredNodes,
363
- onSelect: (node) => {
364
- onSpawnNode(node.type);
365
- onClose();
366
- },
367
- onClose
368
- });
369
- return /* @__PURE__ */ jsxs3(
370
- "div",
371
- {
372
- style: {
373
- position: "absolute",
374
- left: x,
375
- top: y,
376
- transform: "translate(-50%, 0)",
377
- width: "290px",
378
- maxHeight: "380px",
379
- backgroundColor: "var(--skipo-surface)",
380
- border: "var(--skipo-border)",
381
- borderRadius: "var(--skipo-radius)",
382
- boxShadow: "var(--skipo-shadow)",
383
- color: "var(--skipo-text)",
384
- zIndex: 70,
385
- display: "flex",
386
- flexDirection: "column",
387
- overflow: "hidden",
388
- fontFamily: "var(--skipo-font)"
389
- },
390
- onClick: (e) => e.stopPropagation(),
391
- onMouseDown: (e) => e.stopPropagation(),
392
- children: [
393
- /* @__PURE__ */ jsxs3("div", { style: {
394
- padding: "10px 12px",
395
- borderBottom: "var(--skipo-border)",
396
- display: "flex",
397
- alignItems: "center",
398
- justifyContent: "space-between",
399
- backgroundColor: "var(--skipo-matte-bg)"
400
- }, children: [
401
- /* @__PURE__ */ jsxs3("div", { style: { display: "flex", alignItems: "center", gap: "6px" }, children: [
402
- /* @__PURE__ */ jsx4("span", { style: { fontSize: "11px", fontWeight: 600, color: "var(--skipo-accent)" }, children: "Spawn Node" }),
403
- /* @__PURE__ */ jsx4("span", { style: { fontSize: "9px", color: "var(--skipo-text-muted)", fontFamily: "var(--skipo-font-mono)", backgroundColor: "var(--skipo-surface)", padding: "1px 4px", borderRadius: "var(--skipo-radius-sm)" }, children: "hotkey [N]" })
404
- ] }),
405
- /* @__PURE__ */ jsx4(
406
- BaseButton2,
407
- {
408
- variant: "ghost",
409
- size: "sm",
410
- onClick: onClose,
411
- "aria-label": "Close search",
412
- style: { padding: "2px 6px", fontSize: "12px" },
413
- children: "\u2715"
414
- }
415
- )
416
- ] }),
417
- /* @__PURE__ */ jsx4("div", { style: { padding: "8px", borderBottom: "var(--skipo-border)" }, children: /* @__PURE__ */ jsx4(
418
- BaseInput2,
419
- {
420
- autoFocus: true,
421
- placeholder: "Search nodes... (\u2191\u2193 navigate, \u21B5 spawn)",
422
- value: query,
423
- onChange: (e) => setQuery(e.target.value),
424
- onKeyDown: handleKeyDown
425
- }
426
- ) }),
427
- /* @__PURE__ */ jsx4("div", { ref: listContainerRef, style: { flex: 1, overflowY: "auto", maxHeight: "220px", padding: "4px 6px" }, children: filteredNodes.length === 0 ? /* @__PURE__ */ jsx4("div", { style: { padding: "20px", textAlign: "center", fontSize: "11px", color: "var(--skipo-text-muted)" }, children: "No matching nodes" }) : filteredNodes.map((node, idx) => {
428
- const isHighlighted = idx === highlightedIndex;
429
- return /* @__PURE__ */ jsxs3(
430
- "div",
431
- {
432
- onMouseEnter: () => setHighlightedIndex(idx),
433
- onClick: () => {
434
- onSpawnNode(node.type);
435
- onClose();
436
- },
437
- style: {
438
- display: "flex",
439
- alignItems: "center",
440
- justifyContent: "space-between",
441
- padding: "7px 10px",
442
- borderRadius: "var(--skipo-radius-sm)",
443
- cursor: "pointer",
444
- backgroundColor: isHighlighted ? "var(--skipo-surface-hover)" : "transparent",
445
- border: isHighlighted ? "var(--skipo-border)" : "1px solid transparent",
446
- marginBottom: "2px",
447
- transition: "background-color 0.1s ease"
448
- },
449
- children: [
450
- /* @__PURE__ */ jsxs3("div", { style: { minWidth: 0, flex: 1 }, children: [
451
- /* @__PURE__ */ jsx4("div", { style: { fontSize: "11px", fontWeight: isHighlighted ? 600 : 500, color: isHighlighted ? "var(--skipo-accent)" : "inherit" }, children: node.label || node.type }),
452
- node.description && /* @__PURE__ */ jsx4("div", { style: { fontSize: "9px", color: "var(--skipo-text-muted)", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" }, children: node.description })
453
- ] }),
454
- isHighlighted && /* @__PURE__ */ jsx4("span", { style: { fontSize: "9px", fontWeight: 600, color: "var(--skipo-accent)", padding: "2px 5px", borderRadius: "var(--skipo-radius-sm)", backgroundColor: "var(--skipo-matte-bg)", border: "var(--skipo-border)", whiteSpace: "nowrap", marginLeft: "6px" }, children: "\u21B5 Spawn" })
455
- ]
456
- },
457
- node.type
458
- );
459
- }) }),
460
- /* @__PURE__ */ jsxs3("div", { style: {
461
- padding: "6px 10px",
462
- borderTop: "var(--skipo-border)",
463
- display: "flex",
464
- justifyContent: "space-between",
465
- alignItems: "center",
466
- backgroundColor: "var(--skipo-matte-bg)",
467
- fontSize: "9px",
468
- color: "var(--skipo-text-muted)"
469
- }, children: [
470
- /* @__PURE__ */ jsxs3("span", { children: [
471
- filteredNodes.length,
472
- " nodes available"
473
- ] }),
474
- /* @__PURE__ */ jsxs3("span", { children: [
475
- "Press ",
476
- /* @__PURE__ */ jsx4("strong", { children: "Enter \u21B5" }),
477
- " to spawn"
478
- ] })
479
- ] })
480
- ]
481
- }
482
- );
483
- }
484
-
485
- // src/node-graph-ui/widgets/CanvasContextMenu.tsx
486
- import { Fragment as Fragment2, jsx as jsx5, jsxs as jsxs4 } from "react/jsx-runtime";
487
- function CanvasContextMenu({
488
- x,
489
- y,
490
- availableNodeTypes,
491
- hasSelection,
492
- onSpawnNode,
493
- onOpenSpawnMenu,
494
- onSelectAll,
495
- onDeleteSelected,
496
- onClearSelection,
497
- onClose
498
- }) {
499
- const itemStyle = {
500
- padding: "6px 12px",
501
- fontSize: "11px",
502
- cursor: "pointer",
503
- display: "flex",
504
- alignItems: "center",
505
- justifyContent: "space-between",
506
- gap: "12px",
507
- color: "var(--skipo-text, #fff)",
508
- borderRadius: "4px",
509
- userSelect: "none"
510
- };
511
- const shortcutStyle = {
512
- fontSize: "9px",
513
- color: "var(--skipo-text-muted, #888)",
514
- fontFamily: "monospace"
515
- };
516
- return /* @__PURE__ */ jsxs4(
517
- "div",
518
- {
519
- style: {
520
- position: "absolute",
521
- left: x,
522
- top: y,
523
- minWidth: "180px",
524
- backgroundColor: "var(--skipo-surface, #1e1e1e)",
525
- border: "1px solid var(--skipo-border, #333)",
526
- borderRadius: "6px",
527
- boxShadow: "0 6px 20px rgba(0, 0, 0, 0.6)",
528
- padding: "4px",
529
- zIndex: 60,
530
- fontFamily: "Inter, system-ui, sans-serif"
531
- },
532
- onClick: (e) => e.stopPropagation(),
533
- onMouseDown: (e) => e.stopPropagation(),
534
- children: [
535
- onOpenSpawnMenu && /* @__PURE__ */ jsxs4(
536
- "div",
537
- {
538
- style: {
539
- ...itemStyle,
540
- fontWeight: 600,
541
- color: "var(--skipo-accent, #61afef)",
542
- backgroundColor: "rgba(97, 175, 239, 0.08)"
543
- },
544
- onMouseEnter: (e) => e.currentTarget.style.backgroundColor = "rgba(97, 175, 239, 0.16)",
545
- onMouseLeave: (e) => e.currentTarget.style.backgroundColor = "rgba(97, 175, 239, 0.08)",
546
- onClick: () => {
547
- onOpenSpawnMenu();
548
- onClose();
549
- },
550
- children: [
551
- /* @__PURE__ */ jsx5("span", { children: "Spawn Node Menu..." }),
552
- /* @__PURE__ */ jsx5("span", { style: shortcutStyle, children: "N" })
553
- ]
554
- }
555
- ),
556
- /* @__PURE__ */ jsx5("div", { style: { padding: "4px 8px", fontSize: "9px", textTransform: "uppercase", color: "var(--skipo-text-muted, #888)", fontWeight: 600 }, children: "Quick Spawn" }),
557
- /* @__PURE__ */ jsx5("div", { style: { maxHeight: "140px", overflowY: "auto" }, children: !availableNodeTypes || availableNodeTypes.length === 0 ? /* @__PURE__ */ jsx5(
558
- "div",
559
- {
560
- style: itemStyle,
561
- onClick: () => {
562
- onSpawnNode("default");
563
- onClose();
564
- },
565
- children: /* @__PURE__ */ jsx5("span", { children: "Default Node" })
566
- }
567
- ) : availableNodeTypes.map((def) => /* @__PURE__ */ jsx5(
568
- "div",
569
- {
570
- style: itemStyle,
571
- onMouseEnter: (e) => e.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.08)",
572
- onMouseLeave: (e) => e.currentTarget.style.backgroundColor = "transparent",
573
- onClick: () => {
574
- onSpawnNode(def.type);
575
- onClose();
576
- },
577
- children: /* @__PURE__ */ jsx5("span", { children: def.label || def.type })
578
- },
579
- def.type
580
- )) }),
581
- /* @__PURE__ */ jsx5("div", { style: { height: "1px", backgroundColor: "var(--skipo-border, #333)", margin: "4px 0" } }),
582
- /* @__PURE__ */ jsxs4(
583
- "div",
584
- {
585
- style: itemStyle,
586
- onMouseEnter: (e) => e.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.08)",
587
- onMouseLeave: (e) => e.currentTarget.style.backgroundColor = "transparent",
588
- onClick: () => {
589
- onSelectAll();
590
- onClose();
591
- },
592
- children: [
593
- /* @__PURE__ */ jsx5("span", { children: "Select All" }),
594
- /* @__PURE__ */ jsx5("span", { style: shortcutStyle, children: "\u2318A" })
595
- ]
596
- }
597
- ),
598
- hasSelection && /* @__PURE__ */ jsxs4(Fragment2, { children: [
599
- /* @__PURE__ */ jsxs4(
600
- "div",
601
- {
602
- style: { ...itemStyle, color: "#e06c75" },
603
- onMouseEnter: (e) => e.currentTarget.style.backgroundColor = "rgba(224, 108, 117, 0.15)",
604
- onMouseLeave: (e) => e.currentTarget.style.backgroundColor = "transparent",
605
- onClick: () => {
606
- onDeleteSelected();
607
- onClose();
608
- },
609
- children: [
610
- /* @__PURE__ */ jsx5("span", { children: "Delete Selected" }),
611
- /* @__PURE__ */ jsx5("span", { style: shortcutStyle, children: "Del" })
612
- ]
613
- }
614
- ),
615
- /* @__PURE__ */ jsx5(
616
- "div",
617
- {
618
- style: itemStyle,
619
- onMouseEnter: (e) => e.currentTarget.style.backgroundColor = "rgba(255, 255, 255, 0.08)",
620
- onMouseLeave: (e) => e.currentTarget.style.backgroundColor = "transparent",
621
- onClick: () => {
622
- onClearSelection();
623
- onClose();
624
- },
625
- children: /* @__PURE__ */ jsx5("span", { children: "Clear Selection" })
626
- }
627
- )
628
- ] })
629
- ]
630
- }
631
- );
632
- }
633
-
634
208
  // src/node-graph-ui/toolbar/GraphToolbar.tsx
635
- import { jsx as jsx6, jsxs as jsxs5 } from "react/jsx-runtime";
209
+ import { jsx as jsx3, jsxs as jsxs2 } from "react/jsx-runtime";
636
210
  function GraphToolbar({
637
211
  settings,
638
212
  onUpdateSettings,
@@ -654,7 +228,7 @@ function GraphToolbar({
654
228
  alignItems: "center",
655
229
  gap: "4px"
656
230
  });
657
- return /* @__PURE__ */ jsxs5(
231
+ return /* @__PURE__ */ jsxs2(
658
232
  "div",
659
233
  {
660
234
  className,
@@ -670,7 +244,7 @@ function GraphToolbar({
670
244
  zIndex: 25
671
245
  },
672
246
  children: [
673
- /* @__PURE__ */ jsxs5(
247
+ /* @__PURE__ */ jsxs2(
674
248
  "button",
675
249
  {
676
250
  type: "button",
@@ -682,7 +256,7 @@ function GraphToolbar({
682
256
  ]
683
257
  }
684
258
  ),
685
- /* @__PURE__ */ jsxs5(
259
+ /* @__PURE__ */ jsxs2(
686
260
  "button",
687
261
  {
688
262
  type: "button",
@@ -694,7 +268,7 @@ function GraphToolbar({
694
268
  ]
695
269
  }
696
270
  ),
697
- /* @__PURE__ */ jsx6(
271
+ /* @__PURE__ */ jsx3(
698
272
  "button",
699
273
  {
700
274
  type: "button",
@@ -703,7 +277,7 @@ function GraphToolbar({
703
277
  children: "Refresh Traces"
704
278
  }
705
279
  ),
706
- /* @__PURE__ */ jsxs5(
280
+ /* @__PURE__ */ jsxs2(
707
281
  "button",
708
282
  {
709
283
  type: "button",
@@ -715,7 +289,7 @@ function GraphToolbar({
715
289
  ]
716
290
  }
717
291
  ),
718
- /* @__PURE__ */ jsx6(
292
+ /* @__PURE__ */ jsx3(
719
293
  "button",
720
294
  {
721
295
  type: "button",
@@ -724,8 +298,8 @@ function GraphToolbar({
724
298
  children: "Lock All"
725
299
  }
726
300
  ),
727
- onSaveView && /* @__PURE__ */ jsx6("button", { type: "button", style: btnStyle(false), onClick: onSaveView, children: "Save View" }),
728
- onLoadView && /* @__PURE__ */ jsx6("button", { type: "button", style: btnStyle(false), onClick: onLoadView, children: "Load View" })
301
+ onSaveView && /* @__PURE__ */ jsx3("button", { type: "button", style: btnStyle(false), onClick: onSaveView, children: "Save View" }),
302
+ onLoadView && /* @__PURE__ */ jsx3("button", { type: "button", style: btnStyle(false), onClick: onLoadView, children: "Load View" })
729
303
  ]
730
304
  }
731
305
  );
@@ -837,9 +411,9 @@ var ReactFlowAdapter = class {
837
411
  };
838
412
 
839
413
  // src/Viewer2DNodes.tsx
840
- import { useState as useState3, useRef } from "react";
414
+ import { useState, useRef } from "react";
841
415
  import { getBeamPoints, calculateSocketCoordinates } from "@ultrst-armada/kloks/state-graph";
842
- import { jsx as jsx7, jsxs as jsxs6 } from "react/jsx-runtime";
416
+ import { jsx as jsx4, jsxs as jsxs3 } from "react/jsx-runtime";
843
417
  function Viewer2DNodes({
844
418
  node,
845
419
  selected,
@@ -852,7 +426,7 @@ function Viewer2DNodes({
852
426
  const headerHeight = 36;
853
427
  const socketSpacing = 36;
854
428
  const centerX = cardWidth / 2;
855
- return /* @__PURE__ */ jsxs6(
429
+ return /* @__PURE__ */ jsxs3(
856
430
  "div",
857
431
  {
858
432
  style: {
@@ -873,7 +447,7 @@ function Viewer2DNodes({
873
447
  onMouseDown: (e) => onMouseDown?.(e, node.id),
874
448
  onDoubleClick: () => onDoubleClick?.(node.id),
875
449
  children: [
876
- /* @__PURE__ */ jsxs6(
450
+ /* @__PURE__ */ jsxs3(
877
451
  "div",
878
452
  {
879
453
  style: {
@@ -888,8 +462,8 @@ function Viewer2DNodes({
888
462
  borderTopRightRadius: "8px"
889
463
  },
890
464
  children: [
891
- /* @__PURE__ */ jsx7("span", { style: { fontSize: "12px", fontWeight: 600, letterSpacing: "0.02em" }, children: node.label }),
892
- /* @__PURE__ */ jsx7(
465
+ /* @__PURE__ */ jsx4("span", { style: { fontSize: "12px", fontWeight: 600, letterSpacing: "0.02em" }, children: node.label }),
466
+ /* @__PURE__ */ jsx4(
893
467
  "span",
894
468
  {
895
469
  style: {
@@ -907,12 +481,12 @@ function Viewer2DNodes({
907
481
  ]
908
482
  }
909
483
  ),
910
- /* @__PURE__ */ jsx7("div", { style: { position: "relative", minHeight: "60px", padding: "12px 16px" }, children: node.data && /* @__PURE__ */ jsxs6("div", { style: { fontSize: "11px", color: "#94a3b8" }, children: [
484
+ /* @__PURE__ */ jsx4("div", { style: { position: "relative", minHeight: "60px", padding: "12px 16px" }, children: node.data && /* @__PURE__ */ jsxs3("div", { style: { fontSize: "11px", color: "#94a3b8" }, children: [
911
485
  Object.keys(node.data).length,
912
486
  " properties"
913
487
  ] }) }),
914
- /* @__PURE__ */ jsxs6("div", { style: { position: "absolute", top: headerHeight + 10, left: centerX, width: 0, height: 0 }, children: [
915
- node.inputs?.map((socket, idx) => /* @__PURE__ */ jsx7(
488
+ /* @__PURE__ */ jsxs3("div", { style: { position: "absolute", top: headerHeight + 10, left: centerX, width: 0, height: 0 }, children: [
489
+ node.inputs?.map((socket, idx) => /* @__PURE__ */ jsx4(
916
490
  MovableSocketHandle,
917
491
  {
918
492
  socket,
@@ -925,7 +499,7 @@ function Viewer2DNodes({
925
499
  },
926
500
  socket.id
927
501
  )),
928
- node.outputs?.map((socket, idx) => /* @__PURE__ */ jsx7(
502
+ node.outputs?.map((socket, idx) => /* @__PURE__ */ jsx4(
929
503
  MovableSocketHandle,
930
504
  {
931
505
  socket,
@@ -952,8 +526,8 @@ function MovableSocketHandle({
952
526
  onSocketMouseDown,
953
527
  onSocketNudgeChange
954
528
  }) {
955
- const [isHovered, setIsHovered] = useState3(false);
956
- const [localNudge, setLocalNudge] = useState3(
529
+ const [isHovered, setIsHovered] = useState(false);
530
+ const [localNudge, setLocalNudge] = useState(
957
531
  socket.offset ?? { x: 0, y: 0 }
958
532
  );
959
533
  const isDraggingGizmoRef = useRef(false);
@@ -1004,7 +578,7 @@ function MovableSocketHandle({
1004
578
  const beamShroudPoints = getBeamPoints(nudge, 8, 2.5);
1005
579
  const socketThemeColor = isOutput ? "#61afef" : "#98c379";
1006
580
  const gizmoOffsetX = isOutput ? 18 : -18;
1007
- return /* @__PURE__ */ jsxs6(
581
+ return /* @__PURE__ */ jsxs3(
1008
582
  "div",
1009
583
  {
1010
584
  style: {
@@ -1015,7 +589,7 @@ function MovableSocketHandle({
1015
589
  onMouseEnter: () => setIsHovered(true),
1016
590
  onMouseLeave: () => setIsHovered(false),
1017
591
  children: [
1018
- isDisplaced && /* @__PURE__ */ jsxs6(
592
+ isDisplaced && /* @__PURE__ */ jsxs3(
1019
593
  "svg",
1020
594
  {
1021
595
  style: {
@@ -1027,7 +601,7 @@ function MovableSocketHandle({
1027
601
  zIndex: 1
1028
602
  },
1029
603
  children: [
1030
- /* @__PURE__ */ jsx7(
604
+ /* @__PURE__ */ jsx4(
1031
605
  "polygon",
1032
606
  {
1033
607
  points: beamShroudPoints,
@@ -1035,7 +609,7 @@ function MovableSocketHandle({
1035
609
  opacity: 0.35
1036
610
  }
1037
611
  ),
1038
- /* @__PURE__ */ jsx7(
612
+ /* @__PURE__ */ jsx4(
1039
613
  "polygon",
1040
614
  {
1041
615
  points: beamCorePoints,
@@ -1046,7 +620,7 @@ function MovableSocketHandle({
1046
620
  ]
1047
621
  }
1048
622
  ),
1049
- /* @__PURE__ */ jsx7(
623
+ /* @__PURE__ */ jsx4(
1050
624
  "div",
1051
625
  {
1052
626
  style: {
@@ -1069,7 +643,7 @@ function MovableSocketHandle({
1069
643
  e.stopPropagation();
1070
644
  onSocketMouseDown?.(e, nodeId, socket.id, isOutput ? "output" : "input");
1071
645
  },
1072
- children: /* @__PURE__ */ jsx7(
646
+ children: /* @__PURE__ */ jsx4(
1073
647
  "div",
1074
648
  {
1075
649
  style: {
@@ -1083,7 +657,7 @@ function MovableSocketHandle({
1083
657
  )
1084
658
  }
1085
659
  ),
1086
- (isHovered || isDraggingGizmoRef.current) && /* @__PURE__ */ jsx7(
660
+ (isHovered || isDraggingGizmoRef.current) && /* @__PURE__ */ jsx4(
1087
661
  "div",
1088
662
  {
1089
663
  title: "Drag to displace socket handle",
@@ -1104,13 +678,13 @@ function MovableSocketHandle({
1104
678
  boxShadow: "0 2px 4px rgba(0,0,0,0.5)"
1105
679
  },
1106
680
  onMouseDown: handleGizmoMouseDown,
1107
- children: /* @__PURE__ */ jsxs6("svg", { width: "10", height: "10", viewBox: "0 0 24 24", fill: "none", stroke: "#d4af37", strokeWidth: "2.5", strokeLinecap: "round", strokeLinejoin: "round", children: [
1108
- /* @__PURE__ */ jsx7("polyline", { points: "5 9 2 12 5 15" }),
1109
- /* @__PURE__ */ jsx7("polyline", { points: "9 5 12 2 15 5" }),
1110
- /* @__PURE__ */ jsx7("polyline", { points: "15 19 12 22 9 19" }),
1111
- /* @__PURE__ */ jsx7("polyline", { points: "19 9 22 12 19 15" }),
1112
- /* @__PURE__ */ jsx7("line", { x1: "2", y1: "12", x2: "22", y2: "12" }),
1113
- /* @__PURE__ */ jsx7("line", { x1: "12", y1: "2", x2: "12", y2: "22" })
681
+ children: /* @__PURE__ */ jsxs3("svg", { width: "10", height: "10", viewBox: "0 0 24 24", fill: "none", stroke: "#d4af37", strokeWidth: "2.5", strokeLinecap: "round", strokeLinejoin: "round", children: [
682
+ /* @__PURE__ */ jsx4("polyline", { points: "5 9 2 12 5 15" }),
683
+ /* @__PURE__ */ jsx4("polyline", { points: "9 5 12 2 15 5" }),
684
+ /* @__PURE__ */ jsx4("polyline", { points: "15 19 12 22 9 19" }),
685
+ /* @__PURE__ */ jsx4("polyline", { points: "19 9 22 12 19 15" }),
686
+ /* @__PURE__ */ jsx4("line", { x1: "2", y1: "12", x2: "22", y2: "12" }),
687
+ /* @__PURE__ */ jsx4("line", { x1: "12", y1: "2", x2: "12", y2: "22" })
1114
688
  ] })
1115
689
  }
1116
690
  )
@@ -1130,6 +704,7 @@ export {
1130
704
  DockBar,
1131
705
  DockItem,
1132
706
  EffectNode2D,
707
+ FrnlEditableNodeGraph,
1133
708
  GraphToolbar,
1134
709
  InfiniteCanvas,
1135
710
  MagneticTraces2D,
@@ -1157,8 +732,11 @@ export {
1157
732
  TriggerNode2D,
1158
733
  Viewer2DNodes,
1159
734
  Wire2D,
735
+ frnlEditableNodeGraphDefinition,
1160
736
  getSocketLocalOffset,
1161
737
  getSocketScreenPosition,
738
+ menuCategory,
739
+ menuHidden,
1162
740
  renderSpriteIcon,
1163
741
  skipoDarkTheme,
1164
742
  useCanvas,