@almadar/ui 5.87.0 → 5.91.0

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 (27) hide show
  1. package/dist/avl/index.cjs +1510 -1426
  2. package/dist/avl/index.js +500 -416
  3. package/dist/components/game/2d/{organisms → molecules}/ObjectRulePanel.d.ts +9 -4
  4. package/dist/components/game/2d/molecules/StateGraph.d.ts +38 -0
  5. package/dist/components/game/2d/molecules/StateJsonView.d.ts +37 -0
  6. package/dist/components/game/2d/{organisms → molecules}/TraitSlot.d.ts +6 -3
  7. package/dist/components/game/2d/{organisms → molecules}/TraitStateViewer.d.ts +0 -2
  8. package/dist/components/game/2d/molecules/VariablePanel.d.ts +28 -0
  9. package/dist/components/game/2d/molecules/index.d.ts +12 -11
  10. package/dist/components/game/2d/organisms/EventHandlerBoard.d.ts +1 -1
  11. package/dist/components/game/2d/organisms/SequenceBar.d.ts +1 -1
  12. package/dist/components/game/shared/lib/puzzleObject.d.ts +1 -1
  13. package/dist/components/index.cjs +275 -189
  14. package/dist/components/index.js +275 -190
  15. package/dist/providers/index.cjs +1377 -1293
  16. package/dist/providers/index.js +476 -392
  17. package/dist/runtime/index.cjs +1371 -1287
  18. package/dist/runtime/index.js +480 -396
  19. package/package.json +1 -1
  20. package/dist/components/game/2d/organisms/StateJsonView.d.ts +0 -17
  21. package/dist/components/game/2d/organisms/VariablePanel.d.ts +0 -22
  22. /package/dist/components/game/2d/{organisms → molecules}/ActionPalette.d.ts +0 -0
  23. /package/dist/components/game/2d/{organisms → molecules}/ActionTile.d.ts +0 -0
  24. /package/dist/components/game/2d/{organisms → molecules}/EventLog.d.ts +0 -0
  25. /package/dist/components/game/2d/{organisms → molecules}/RuleEditor.d.ts +0 -0
  26. /package/dist/components/game/2d/{organisms → molecules}/StateNode.d.ts +0 -0
  27. /package/dist/components/game/2d/{organisms → molecules}/TransitionArrow.d.ts +0 -0
@@ -8102,7 +8102,7 @@ function ActionTile({
8102
8102
  }
8103
8103
  var DRAG_MIME, SIZE_CONFIG;
8104
8104
  var init_ActionTile = __esm({
8105
- "components/game/2d/organisms/ActionTile.tsx"() {
8105
+ "components/game/2d/molecules/ActionTile.tsx"() {
8106
8106
  init_atoms();
8107
8107
  init_cn();
8108
8108
  DRAG_MIME = "application/x-almadar-slot-item";
@@ -8139,7 +8139,7 @@ function ActionPalette({
8139
8139
  ] });
8140
8140
  }
8141
8141
  var init_ActionPalette = __esm({
8142
- "components/game/2d/organisms/ActionPalette.tsx"() {
8142
+ "components/game/2d/molecules/ActionPalette.tsx"() {
8143
8143
  init_atoms();
8144
8144
  init_cn();
8145
8145
  init_ActionTile();
@@ -27792,6 +27792,214 @@ var init_GameMenu = __esm({
27792
27792
  GameMenu.displayName = "GameMenu";
27793
27793
  }
27794
27794
  });
27795
+ function StateNode2({
27796
+ name,
27797
+ isCurrent = false,
27798
+ isSelected = false,
27799
+ isInitial = false,
27800
+ position,
27801
+ onClick,
27802
+ className
27803
+ }) {
27804
+ return /* @__PURE__ */ jsx(
27805
+ Box,
27806
+ {
27807
+ position: "absolute",
27808
+ display: "flex",
27809
+ className: cn(
27810
+ "items-center justify-center rounded-pill border-3 transition-all cursor-pointer select-none",
27811
+ "min-w-[80px] h-[80px] px-3",
27812
+ isCurrent && "bg-primary/20 border-primary shadow-lg shadow-primary/30 scale-110",
27813
+ isSelected && !isCurrent && "bg-accent/20 border-accent ring-2 ring-accent/50",
27814
+ !isCurrent && !isSelected && "bg-card border-border hover:border-muted-foreground hover:scale-105",
27815
+ className
27816
+ ),
27817
+ style: {
27818
+ left: position.x,
27819
+ top: position.y,
27820
+ transform: "translate(-50%, -50%)"
27821
+ },
27822
+ onClick,
27823
+ children: /* @__PURE__ */ jsxs(Box, { className: "text-center", children: [
27824
+ isInitial && /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground text-xs block", children: "\u25B6 start" }),
27825
+ /* @__PURE__ */ jsx(
27826
+ Typography,
27827
+ {
27828
+ variant: "body2",
27829
+ className: cn(
27830
+ "font-bold whitespace-nowrap",
27831
+ isCurrent ? "text-primary" : "text-foreground"
27832
+ ),
27833
+ children: name
27834
+ }
27835
+ )
27836
+ ] })
27837
+ }
27838
+ );
27839
+ }
27840
+ var init_StateNode = __esm({
27841
+ "components/game/2d/molecules/StateNode.tsx"() {
27842
+ init_atoms();
27843
+ init_cn();
27844
+ StateNode2.displayName = "StateNode";
27845
+ }
27846
+ });
27847
+ function TransitionArrow({
27848
+ from,
27849
+ to,
27850
+ eventLabel,
27851
+ guardHint,
27852
+ isActive = false,
27853
+ onClick,
27854
+ className
27855
+ }) {
27856
+ const dx = to.x - from.x;
27857
+ const dy = to.y - from.y;
27858
+ const dist = Math.sqrt(dx * dx + dy * dy);
27859
+ if (dist === 0) return /* @__PURE__ */ jsx(Fragment, {});
27860
+ const nx = dx / dist;
27861
+ const ny = dy / dist;
27862
+ const startX = from.x + nx * NODE_RADIUS;
27863
+ const startY = from.y + ny * NODE_RADIUS;
27864
+ const endX = to.x - nx * NODE_RADIUS;
27865
+ const endY = to.y - ny * NODE_RADIUS;
27866
+ const midX = (startX + endX) / 2;
27867
+ const midY = (startY + endY) / 2;
27868
+ const perpX = -ny * 20;
27869
+ const perpY = nx * 20;
27870
+ const ctrlX = midX + perpX;
27871
+ const ctrlY = midY + perpY;
27872
+ const path = `M ${startX} ${startY} Q ${ctrlX} ${ctrlY} ${endX} ${endY}`;
27873
+ return /* @__PURE__ */ jsxs("g", { className: cn("cursor-pointer", className), onClick, children: [
27874
+ /* @__PURE__ */ jsx(
27875
+ "path",
27876
+ {
27877
+ d: path,
27878
+ fill: "none",
27879
+ stroke: isActive ? "var(--color-primary)" : "var(--color-border)",
27880
+ strokeWidth: isActive ? 3 : 2,
27881
+ markerEnd: isActive ? "url(#arrowhead-active)" : "url(#arrowhead)"
27882
+ }
27883
+ ),
27884
+ /* @__PURE__ */ jsx(
27885
+ "text",
27886
+ {
27887
+ x: ctrlX,
27888
+ y: ctrlY - 8,
27889
+ textAnchor: "middle",
27890
+ fill: isActive ? "var(--color-primary)" : "var(--color-foreground)",
27891
+ fontSize: 12,
27892
+ fontWeight: isActive ? "bold" : "normal",
27893
+ className: "select-none",
27894
+ children: eventLabel
27895
+ }
27896
+ ),
27897
+ guardHint && /* @__PURE__ */ jsx(
27898
+ "text",
27899
+ {
27900
+ x: ctrlX,
27901
+ y: ctrlY + 6,
27902
+ textAnchor: "middle",
27903
+ fill: "var(--color-warning)",
27904
+ fontSize: 10,
27905
+ className: "select-none",
27906
+ children: "\u26A0 " + guardHint
27907
+ }
27908
+ )
27909
+ ] });
27910
+ }
27911
+ var NODE_RADIUS;
27912
+ var init_TransitionArrow = __esm({
27913
+ "components/game/2d/molecules/TransitionArrow.tsx"() {
27914
+ init_cn();
27915
+ NODE_RADIUS = 40;
27916
+ TransitionArrow.displayName = "TransitionArrow";
27917
+ }
27918
+ });
27919
+ function layoutStates(states, width, height) {
27920
+ const cx = width / 2;
27921
+ const cy = height / 2;
27922
+ const radius = Math.min(cx, cy) - 60;
27923
+ const positions = {};
27924
+ states.forEach((state, i) => {
27925
+ const angle = 2 * Math.PI * i / Math.max(states.length, 1) - Math.PI / 2;
27926
+ positions[state] = { x: cx + radius * Math.cos(angle), y: cy + radius * Math.sin(angle) };
27927
+ });
27928
+ return positions;
27929
+ }
27930
+ function StateGraph({
27931
+ states,
27932
+ transitions = [],
27933
+ currentState,
27934
+ selectedState,
27935
+ addingFrom,
27936
+ initialState,
27937
+ width = 500,
27938
+ height = 400,
27939
+ nodeClickEvent,
27940
+ className
27941
+ }) {
27942
+ const eventBus = useEventBus();
27943
+ const nodes = states ?? [];
27944
+ const positions = React74.useMemo(() => layoutStates(nodes, width, height), [nodes, width, height]);
27945
+ return /* @__PURE__ */ jsxs(
27946
+ Box,
27947
+ {
27948
+ position: "relative",
27949
+ className: cn("rounded-container border border-border bg-background overflow-hidden", className),
27950
+ style: { width, height },
27951
+ children: [
27952
+ /* @__PURE__ */ jsxs("svg", { width, height, className: "absolute inset-0", style: { pointerEvents: "none" }, children: [
27953
+ /* @__PURE__ */ jsxs("defs", { children: [
27954
+ /* @__PURE__ */ jsx("marker", { id: "arrowhead", markerWidth: "10", markerHeight: "7", refX: "10", refY: "3.5", orient: "auto", children: /* @__PURE__ */ jsx("polygon", { points: "0 0, 10 3.5, 0 7", fill: "var(--color-border)" }) }),
27955
+ /* @__PURE__ */ jsx("marker", { id: "arrowhead-active", markerWidth: "10", markerHeight: "7", refX: "10", refY: "3.5", orient: "auto", children: /* @__PURE__ */ jsx("polygon", { points: "0 0, 10 3.5, 0 7", fill: "var(--color-primary)" }) })
27956
+ ] }),
27957
+ transitions.map((tr, i) => {
27958
+ const fromPos = positions[tr.from];
27959
+ const toPos = positions[tr.to];
27960
+ if (!fromPos || !toPos) return null;
27961
+ return /* @__PURE__ */ jsx(
27962
+ TransitionArrow,
27963
+ {
27964
+ from: fromPos,
27965
+ to: toPos,
27966
+ eventLabel: tr.event,
27967
+ guardHint: tr.guardHint,
27968
+ isActive: tr.from === currentState
27969
+ },
27970
+ `${tr.from}-${tr.event}-${tr.to}-${i}`
27971
+ );
27972
+ })
27973
+ ] }),
27974
+ nodes.map((state) => {
27975
+ const pos = positions[state];
27976
+ if (!pos) return null;
27977
+ return /* @__PURE__ */ jsx(
27978
+ StateNode2,
27979
+ {
27980
+ name: state,
27981
+ position: pos,
27982
+ isCurrent: state === currentState,
27983
+ isSelected: state === selectedState || state === addingFrom,
27984
+ isInitial: state === initialState,
27985
+ onClick: nodeClickEvent ? () => eventBus.emit(`UI:${nodeClickEvent}`, { stateId: state }) : void 0
27986
+ },
27987
+ state
27988
+ );
27989
+ })
27990
+ ]
27991
+ }
27992
+ );
27993
+ }
27994
+ var init_StateGraph = __esm({
27995
+ "components/game/2d/molecules/StateGraph.tsx"() {
27996
+ init_atoms();
27997
+ init_cn();
27998
+ init_useEventBus();
27999
+ init_StateNode();
28000
+ init_TransitionArrow();
28001
+ }
28002
+ });
27795
28003
  function pickPath(entry) {
27796
28004
  if (Array.isArray(entry.path)) {
27797
28005
  return entry.path[Math.floor(Math.random() * entry.path.length)];
@@ -28366,7 +28574,7 @@ function TraitStateViewer({
28366
28574
  }
28367
28575
  var SIZE_CONFIG2;
28368
28576
  var init_TraitStateViewer = __esm({
28369
- "components/game/2d/organisms/TraitStateViewer.tsx"() {
28577
+ "components/game/2d/molecules/TraitStateViewer.tsx"() {
28370
28578
  "use client";
28371
28579
  init_cn();
28372
28580
  init_Box();
@@ -28399,7 +28607,8 @@ function TraitSlot({
28399
28607
  onClick,
28400
28608
  onRemove,
28401
28609
  clickEvent,
28402
- removeEvent
28610
+ removeEvent,
28611
+ dropEvent
28403
28612
  }) {
28404
28613
  const { emit } = useEventBus();
28405
28614
  const [isHovered, setIsHovered] = useState(false);
@@ -28431,29 +28640,30 @@ function TraitSlot({
28431
28640
  onDragStart?.(equippedItem);
28432
28641
  }, [equippedItem, draggable, onDragStart]);
28433
28642
  const handleDragOver = useCallback((e) => {
28434
- if (locked || !onItemDrop) return;
28643
+ if (locked || !onItemDrop && !dropEvent) return;
28435
28644
  if (e.dataTransfer.types.includes(DRAG_MIME2)) {
28436
28645
  e.preventDefault();
28437
28646
  const allowed = e.dataTransfer.effectAllowed;
28438
28647
  e.dataTransfer.dropEffect = allowed === "copy" ? "copy" : "move";
28439
28648
  setIsDragOver(true);
28440
28649
  }
28441
- }, [locked, onItemDrop]);
28650
+ }, [locked, onItemDrop, dropEvent]);
28442
28651
  const handleDragLeave = useCallback(() => {
28443
28652
  setIsDragOver(false);
28444
28653
  }, []);
28445
28654
  const handleDrop = useCallback((e) => {
28446
28655
  e.preventDefault();
28447
28656
  setIsDragOver(false);
28448
- if (locked || !onItemDrop) return;
28657
+ if (locked || !onItemDrop && !dropEvent) return;
28449
28658
  const raw = e.dataTransfer.getData(DRAG_MIME2);
28450
28659
  if (!raw) return;
28451
28660
  try {
28452
28661
  const item = JSON.parse(raw);
28453
- onItemDrop(item);
28662
+ if (dropEvent) emit(`UI:${dropEvent}`, { slotNumber, itemId: item.id });
28663
+ else onItemDrop?.(item);
28454
28664
  } catch {
28455
28665
  }
28456
- }, [locked, onItemDrop]);
28666
+ }, [locked, onItemDrop, dropEvent, emit, slotNumber]);
28457
28667
  const getTooltipStyle = () => {
28458
28668
  if (!slotRef.current) return {};
28459
28669
  const rect = slotRef.current.getBoundingClientRect();
@@ -28573,7 +28783,7 @@ function TraitSlot({
28573
28783
  }
28574
28784
  var SIZE_CONFIG3, DRAG_MIME2;
28575
28785
  var init_TraitSlot = __esm({
28576
- "components/game/2d/organisms/TraitSlot.tsx"() {
28786
+ "components/game/2d/molecules/TraitSlot.tsx"() {
28577
28787
  "use client";
28578
28788
  init_cn();
28579
28789
  init_useEventBus();
@@ -29143,7 +29353,7 @@ function RuleEditor({
29143
29353
  ] });
29144
29354
  }
29145
29355
  var init_RuleEditor = __esm({
29146
- "components/game/2d/organisms/RuleEditor.tsx"() {
29356
+ "components/game/2d/molecules/RuleEditor.tsx"() {
29147
29357
  init_atoms();
29148
29358
  init_cn();
29149
29359
  RuleEditor.displayName = "RuleEditor";
@@ -29184,7 +29394,7 @@ function EventLog({
29184
29394
  }
29185
29395
  var STATUS_STYLES, STATUS_DOTS;
29186
29396
  var init_EventLog = __esm({
29187
- "components/game/2d/organisms/EventLog.tsx"() {
29397
+ "components/game/2d/molecules/EventLog.tsx"() {
29188
29398
  init_atoms();
29189
29399
  init_cn();
29190
29400
  STATUS_STYLES = {
@@ -29239,10 +29449,12 @@ var init_puzzleObject = __esm({
29239
29449
  function ObjectRulePanel({
29240
29450
  object,
29241
29451
  onRulesChange,
29452
+ rulesChangeEvent,
29242
29453
  disabled = false,
29243
29454
  className
29244
29455
  }) {
29245
29456
  const { t } = useTranslate();
29457
+ const { emit } = useEventBus();
29246
29458
  const id = objId(object);
29247
29459
  const name = objName(object);
29248
29460
  const icon = objIcon(object);
@@ -29253,15 +29465,19 @@ function ObjectRulePanel({
29253
29465
  const rules = objRules(object);
29254
29466
  const maxRules = objMaxRules(object);
29255
29467
  const canAdd = rules.length < maxRules;
29468
+ const emitRules = useCallback((newRules) => {
29469
+ if (rulesChangeEvent) emit(`UI:${rulesChangeEvent}`, { objectId: id, rules: newRules });
29470
+ else onRulesChange?.(id, newRules);
29471
+ }, [rulesChangeEvent, emit, id, onRulesChange]);
29256
29472
  const handleRuleChange = useCallback((index, updatedRule) => {
29257
29473
  const newRules = [...rules];
29258
29474
  newRules[index] = updatedRule;
29259
- onRulesChange(id, newRules);
29260
- }, [id, rules, onRulesChange]);
29475
+ emitRules(newRules);
29476
+ }, [rules, emitRules]);
29261
29477
  const handleRuleRemove = useCallback((index) => {
29262
29478
  const newRules = rules.filter((_, i) => i !== index);
29263
- onRulesChange(id, newRules);
29264
- }, [id, rules, onRulesChange]);
29479
+ emitRules(newRules);
29480
+ }, [rules, emitRules]);
29265
29481
  const handleAddRule = useCallback(() => {
29266
29482
  if (!canAdd || disabled) return;
29267
29483
  const firstEvent = availableEvents[0]?.value || "";
@@ -29271,8 +29487,8 @@ function ObjectRulePanel({
29271
29487
  whenEvent: firstEvent,
29272
29488
  thenAction: firstAction
29273
29489
  };
29274
- onRulesChange(id, [...rules, newRule]);
29275
- }, [canAdd, disabled, id, rules, availableEvents, availableActions, onRulesChange]);
29490
+ emitRules([...rules, newRule]);
29491
+ }, [canAdd, disabled, rules, availableEvents, availableActions, emitRules]);
29276
29492
  const machine = {
29277
29493
  name,
29278
29494
  states,
@@ -29312,9 +29528,10 @@ function ObjectRulePanel({
29312
29528
  }
29313
29529
  var nextRuleId;
29314
29530
  var init_ObjectRulePanel = __esm({
29315
- "components/game/2d/organisms/ObjectRulePanel.tsx"() {
29531
+ "components/game/2d/molecules/ObjectRulePanel.tsx"() {
29316
29532
  init_atoms();
29317
29533
  init_cn();
29534
+ init_useEventBus();
29318
29535
  init_TraitStateViewer();
29319
29536
  init_RuleEditor();
29320
29537
  init_puzzleObject();
@@ -29536,130 +29753,6 @@ var init_EventHandlerBoard = __esm({
29536
29753
  EventHandlerBoard.displayName = "EventHandlerBoard";
29537
29754
  }
29538
29755
  });
29539
- function StateNode2({
29540
- name,
29541
- isCurrent = false,
29542
- isSelected = false,
29543
- isInitial = false,
29544
- position,
29545
- onClick,
29546
- className
29547
- }) {
29548
- return /* @__PURE__ */ jsx(
29549
- Box,
29550
- {
29551
- position: "absolute",
29552
- display: "flex",
29553
- className: cn(
29554
- "items-center justify-center rounded-pill border-3 transition-all cursor-pointer select-none",
29555
- "min-w-[80px] h-[80px] px-3",
29556
- isCurrent && "bg-primary/20 border-primary shadow-lg shadow-primary/30 scale-110",
29557
- isSelected && !isCurrent && "bg-accent/20 border-accent ring-2 ring-accent/50",
29558
- !isCurrent && !isSelected && "bg-card border-border hover:border-muted-foreground hover:scale-105",
29559
- className
29560
- ),
29561
- style: {
29562
- left: position.x,
29563
- top: position.y,
29564
- transform: "translate(-50%, -50%)"
29565
- },
29566
- onClick,
29567
- children: /* @__PURE__ */ jsxs(Box, { className: "text-center", children: [
29568
- isInitial && /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground text-xs block", children: "\u25B6 start" }),
29569
- /* @__PURE__ */ jsx(
29570
- Typography,
29571
- {
29572
- variant: "body2",
29573
- className: cn(
29574
- "font-bold whitespace-nowrap",
29575
- isCurrent ? "text-primary" : "text-foreground"
29576
- ),
29577
- children: name
29578
- }
29579
- )
29580
- ] })
29581
- }
29582
- );
29583
- }
29584
- var init_StateNode = __esm({
29585
- "components/game/2d/organisms/StateNode.tsx"() {
29586
- init_atoms();
29587
- init_cn();
29588
- StateNode2.displayName = "StateNode";
29589
- }
29590
- });
29591
- function TransitionArrow({
29592
- from,
29593
- to,
29594
- eventLabel,
29595
- guardHint,
29596
- isActive = false,
29597
- onClick,
29598
- className
29599
- }) {
29600
- const dx = to.x - from.x;
29601
- const dy = to.y - from.y;
29602
- const dist = Math.sqrt(dx * dx + dy * dy);
29603
- if (dist === 0) return /* @__PURE__ */ jsx(Fragment, {});
29604
- const nx = dx / dist;
29605
- const ny = dy / dist;
29606
- const startX = from.x + nx * NODE_RADIUS;
29607
- const startY = from.y + ny * NODE_RADIUS;
29608
- const endX = to.x - nx * NODE_RADIUS;
29609
- const endY = to.y - ny * NODE_RADIUS;
29610
- const midX = (startX + endX) / 2;
29611
- const midY = (startY + endY) / 2;
29612
- const perpX = -ny * 20;
29613
- const perpY = nx * 20;
29614
- const ctrlX = midX + perpX;
29615
- const ctrlY = midY + perpY;
29616
- const path = `M ${startX} ${startY} Q ${ctrlX} ${ctrlY} ${endX} ${endY}`;
29617
- return /* @__PURE__ */ jsxs("g", { className: cn("cursor-pointer", className), onClick, children: [
29618
- /* @__PURE__ */ jsx(
29619
- "path",
29620
- {
29621
- d: path,
29622
- fill: "none",
29623
- stroke: isActive ? "var(--color-primary)" : "var(--color-border)",
29624
- strokeWidth: isActive ? 3 : 2,
29625
- markerEnd: isActive ? "url(#arrowhead-active)" : "url(#arrowhead)"
29626
- }
29627
- ),
29628
- /* @__PURE__ */ jsx(
29629
- "text",
29630
- {
29631
- x: ctrlX,
29632
- y: ctrlY - 8,
29633
- textAnchor: "middle",
29634
- fill: isActive ? "var(--color-primary)" : "var(--color-foreground)",
29635
- fontSize: 12,
29636
- fontWeight: isActive ? "bold" : "normal",
29637
- className: "select-none",
29638
- children: eventLabel
29639
- }
29640
- ),
29641
- guardHint && /* @__PURE__ */ jsx(
29642
- "text",
29643
- {
29644
- x: ctrlX,
29645
- y: ctrlY + 6,
29646
- textAnchor: "middle",
29647
- fill: "var(--color-warning)",
29648
- fontSize: 10,
29649
- className: "select-none",
29650
- children: "\u26A0 " + guardHint
29651
- }
29652
- )
29653
- ] });
29654
- }
29655
- var NODE_RADIUS;
29656
- var init_TransitionArrow = __esm({
29657
- "components/game/2d/organisms/TransitionArrow.tsx"() {
29658
- init_cn();
29659
- NODE_RADIUS = 40;
29660
- TransitionArrow.displayName = "TransitionArrow";
29661
- }
29662
- });
29663
29756
  function VariablePanel({
29664
29757
  entityName,
29665
29758
  variables,
@@ -29668,61 +29761,35 @@ function VariablePanel({
29668
29761
  const { t } = useTranslate();
29669
29762
  return /* @__PURE__ */ jsxs(VStack, { className: cn("p-3 rounded-lg bg-card border border-border", className), gap: "sm", children: [
29670
29763
  /* @__PURE__ */ jsx(Typography, { variant: "body2", className: "text-muted-foreground font-medium", children: t("stateArchitect.variables", { name: entityName }) }),
29671
- variables.map((v) => {
29672
- const name = v.name == null ? "" : String(v.name);
29673
- const value = numField(v.value);
29674
- const max = numField(v.max, 100);
29675
- const min = numField(v.min, 0);
29676
- const unit = v.unit == null ? "" : String(v.unit);
29677
- const pct = Math.round((value - min) / (max - min) * 100);
29678
- const isHigh = pct > 80;
29679
- const isLow = pct < 20;
29680
- return /* @__PURE__ */ jsxs(VStack, { gap: "none", children: [
29681
- /* @__PURE__ */ jsxs(HStack, { className: "items-center justify-between", children: [
29682
- /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-foreground font-medium", children: name }),
29683
- /* @__PURE__ */ jsxs(Typography, { variant: "caption", className: cn(
29684
- isHigh ? "text-error" : isLow ? "text-warning" : "text-foreground"
29685
- ), children: [
29686
- value,
29687
- unit,
29688
- " / ",
29689
- max,
29690
- unit
29691
- ] })
29692
- ] }),
29693
- /* @__PURE__ */ jsx(
29694
- ProgressBar,
29695
- {
29696
- value: pct,
29697
- color: isHigh ? "danger" : isLow ? "warning" : "primary",
29698
- size: "sm"
29699
- }
29700
- )
29701
- ] }, name);
29702
- })
29764
+ (variables ?? []).map((v) => /* @__PURE__ */ jsxs(HStack, { className: "items-center justify-between", children: [
29765
+ /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-foreground font-medium", children: v.name }),
29766
+ /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-accent font-mono", children: v.value })
29767
+ ] }, v.name))
29703
29768
  ] });
29704
29769
  }
29705
- var numField;
29706
29770
  var init_VariablePanel = __esm({
29707
- "components/game/2d/organisms/VariablePanel.tsx"() {
29771
+ "components/game/2d/molecules/VariablePanel.tsx"() {
29708
29772
  init_atoms();
29709
29773
  init_cn();
29710
- numField = (v, fallback = 0) => {
29711
- const n = Number(v);
29712
- return Number.isFinite(n) ? n : fallback;
29713
- };
29714
29774
  VariablePanel.displayName = "VariablePanel";
29715
29775
  }
29716
29776
  });
29717
29777
  function StateJsonView({
29718
- data,
29778
+ name,
29779
+ initialState,
29780
+ states,
29781
+ transitions,
29719
29782
  label,
29720
29783
  defaultExpanded = false,
29721
29784
  className
29722
29785
  }) {
29723
29786
  const { t } = useTranslate();
29724
29787
  const [expanded, setExpanded] = useState(defaultExpanded);
29725
- const jsonString = JSON.stringify(data, null, 2);
29788
+ const jsonString = JSON.stringify(
29789
+ { name, initialState, states: states ?? [], transitions: transitions ?? [] },
29790
+ null,
29791
+ 2
29792
+ );
29726
29793
  return /* @__PURE__ */ jsxs(VStack, { className: cn("rounded-lg border border-border overflow-hidden", className), gap: "none", children: [
29727
29794
  /* @__PURE__ */ jsxs(HStack, { className: "items-center justify-between p-2 bg-muted", gap: "sm", children: [
29728
29795
  /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground font-medium", children: label ?? t("stateArchitect.viewCode") }),
@@ -29739,13 +29806,13 @@ function StateJsonView({
29739
29806
  ] });
29740
29807
  }
29741
29808
  var init_StateJsonView = __esm({
29742
- "components/game/2d/organisms/StateJsonView.tsx"() {
29809
+ "components/game/2d/molecules/StateJsonView.tsx"() {
29743
29810
  init_atoms();
29744
29811
  init_cn();
29745
29812
  StateJsonView.displayName = "StateJsonView";
29746
29813
  }
29747
29814
  });
29748
- function layoutStates(states, width, height) {
29815
+ function layoutStates2(states, width, height) {
29749
29816
  const cx = width / 2;
29750
29817
  const cy = height / 2;
29751
29818
  const radius = Math.min(cx, cy) - 60;
@@ -29813,7 +29880,7 @@ function StateArchitectBoard({
29813
29880
  }, []);
29814
29881
  const GRAPH_W = 500;
29815
29882
  const GRAPH_H = 400;
29816
- const positions = useMemo(() => layoutStates(entityStates, GRAPH_W, GRAPH_H), [entityStates]);
29883
+ const positions = useMemo(() => layoutStates2(entityStates, GRAPH_W, GRAPH_H), [entityStates]);
29817
29884
  const handleStateClick = useCallback((state) => {
29818
29885
  if (isTesting) return;
29819
29886
  if (addingFrom) {
@@ -29908,7 +29975,7 @@ function StateArchitectBoard({
29908
29975
  setAddingFrom(null);
29909
29976
  if (playAgainEvent) emit(`UI:${playAgainEvent}`, {});
29910
29977
  }, [initialState, entityVariables, playAgainEvent, emit]);
29911
- const codeData = useMemo(() => ({
29978
+ useMemo(() => ({
29912
29979
  name: entityName,
29913
29980
  states: entityStates,
29914
29981
  initialState,
@@ -30043,7 +30110,7 @@ function StateArchitectBoard({
30043
30110
  VariablePanel,
30044
30111
  {
30045
30112
  entityName,
30046
- variables
30113
+ variables: variables.map((v) => ({ name: String(v.name ?? ""), value: String(v.value ?? "") }))
30047
30114
  }
30048
30115
  ),
30049
30116
  testResults.length > 0 && /* @__PURE__ */ jsxs(VStack, { className: "p-3 rounded-container bg-card border border-border", gap: "xs", children: [
@@ -30054,7 +30121,16 @@ function StateArchitectBoard({
30054
30121
  !r.passed && /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-error", children: t("stateArchitect.gotState", { state: r.actualState }) })
30055
30122
  ] }, i))
30056
30123
  ] }),
30057
- resolved.showCodeView !== false && /* @__PURE__ */ jsx(StateJsonView, { data: codeData, label: "View Code" })
30124
+ resolved.showCodeView !== false && /* @__PURE__ */ jsx(
30125
+ StateJsonView,
30126
+ {
30127
+ name: entityName,
30128
+ initialState,
30129
+ states: entityStates,
30130
+ transitions: transitions.map((tr) => ({ from: tr.from, to: tr.to, event: tr.event })),
30131
+ label: "View Code"
30132
+ }
30133
+ )
30058
30134
  ] })
30059
30135
  ] }),
30060
30136
  isSuccess && /* @__PURE__ */ jsx(Box, { className: "p-4 rounded-container bg-success/20 border border-success text-center", children: /* @__PURE__ */ jsx(Typography, { variant: "h5", className: "text-success", children: str(resolved.successMessage) || t("stateArchitect.allPassed") }) }),
@@ -31259,6 +31335,7 @@ var init_molecules = __esm({
31259
31335
  init_ResourceBar();
31260
31336
  init_GameHud();
31261
31337
  init_GameMenu();
31338
+ init_StateGraph();
31262
31339
  init_Canvas2D();
31263
31340
  init_useUnitSpriteAtlas();
31264
31341
  init_GameAudioProvider();
@@ -47900,6 +47977,7 @@ var init_component_registry_generated = __esm({
47900
47977
  init_Navigation();
47901
47978
  init_NegotiatorBoard();
47902
47979
  init_NumberStepper();
47980
+ init_ObjectRulePanel();
47903
47981
  init_OptionConstraintGroup();
47904
47982
  init_OrbitalVisualization();
47905
47983
  init_Overlay();
@@ -47961,7 +48039,9 @@ var init_component_registry_generated = __esm({
47961
48039
  init_StatCard();
47962
48040
  init_StatDisplay();
47963
48041
  init_StateArchitectBoard();
48042
+ init_StateGraph();
47964
48043
  init_StateIndicator();
48044
+ init_StateJsonView();
47965
48045
  init_StateMachineView();
47966
48046
  init_StatsGrid();
47967
48047
  init_StatsOrganism();
@@ -48008,6 +48088,7 @@ var init_component_registry_generated = __esm({
48008
48088
  init_Typography();
48009
48089
  init_UISlotRenderer();
48010
48090
  init_UploadDropZone();
48091
+ init_VariablePanel();
48011
48092
  init_VersionDiff();
48012
48093
  init_ViolationAlert();
48013
48094
  init_VoteStack();
@@ -48208,6 +48289,7 @@ var init_component_registry_generated = __esm({
48208
48289
  "Navigation": Navigation,
48209
48290
  "NegotiatorBoard": NegotiatorBoard,
48210
48291
  "NumberStepper": NumberStepper,
48292
+ "ObjectRulePanel": ObjectRulePanel,
48211
48293
  "OptionConstraintGroup": OptionConstraintGroup,
48212
48294
  "OrbitalVisualization": OrbitalVisualization,
48213
48295
  "Overlay": Overlay,
@@ -48272,7 +48354,9 @@ var init_component_registry_generated = __esm({
48272
48354
  "StatCard": StatCard,
48273
48355
  "StatDisplay": StatDisplay,
48274
48356
  "StateArchitectBoard": StateArchitectBoard,
48357
+ "StateGraph": StateGraph,
48275
48358
  "StateIndicator": StateIndicator,
48359
+ "StateJsonView": StateJsonView,
48276
48360
  "StateMachineView": StateMachineView,
48277
48361
  "StatsGrid": StatsGrid,
48278
48362
  "StatsOrganism": StatsOrganism,
@@ -48320,6 +48404,7 @@ var init_component_registry_generated = __esm({
48320
48404
  "UISlotRenderer": UISlotRenderer,
48321
48405
  "UploadDropZone": UploadDropZone,
48322
48406
  "VStack": VStack,
48407
+ "VariablePanel": VariablePanel,
48323
48408
  "VersionDiff": VersionDiff,
48324
48409
  "ViolationAlert": ViolationAlert,
48325
48410
  "VoteStack": VoteStack,
@@ -51563,4 +51648,4 @@ function useGitHubBranches(owner, repo, enabled = true) {
51563
51648
  });
51564
51649
  }
51565
51650
 
51566
- export { ALL_PRESETS, ALMADAR_DND_MIME, AR_BOOK_FIELDS, AboutPageTemplate, Accordion, ActionButton, Card2 as ActionCard, ActionPalette, ActionTile, ActivationBlock, Alert, AnimatedCounter, AnimatedGraphic, AnimatedReveal, ArticleSection, Aside, AssetPicker, AuthLayout, Avatar, Badge, BehaviorView, BiologyCanvas, BloomQuizBlock, BookChapterView, BookCoverPage, BookNavBar, BookTableOfContents, BookViewer, Box, BranchingLogicBuilder, Breadcrumb, BuilderBoard, Button, ButtonGroup, CTABanner, CalendarGrid, Canvas2D, Card, CardBody, CardContent, CardFooter, CardGrid, CardHeader, CardTitle, Carousel, CaseStudyCard, CaseStudyOrganism, Center, Chart, ChartLegend, ChatBar, Checkbox, ChemistryCanvas, ChoiceButton, ClassifierBoard, Coachmark, CodeBlock, CodeRunnerPanel, CollapsibleSection, ComboCounter, CommunityLinks, ConditionalWrapper, ConfettiEffect, ConfirmDialog, ConnectionBlock, Container, ContentRenderer, ContentSection, ControlButton, ControlGrid, CounterTemplate, DEFAULT_LIKERT_OPTIONS, DEFAULT_MATRIX_COLUMNS, DEFAULT_SLOTS, DIAMOND_TOP_Y, DamageNumber, DashboardGrid, DashboardLayout, DataGrid, DataList, DataTable, DateRangePicker, DateRangeSelector, DayCell, DebuggerBoard, DetailPanel, Dialog, DialogueBubble, Divider, DocBreadcrumb, DocPagination, DocSearch, DocSidebar, DocTOC, DocumentViewer, StateMachineView as DomStateMachineVisualizer, Drawer, DrawerSlot, ELEMENT_SELECTED_EVENT, EMPTY_EFFECT_STATE, EdgeDecoration, EditorCheckbox, EditorSelect, EditorSlider, EditorTextInput, EditorToolbar, EmptyState, EntityDisplayEvents, ErrorBoundary, ErrorState, EventHandlerBoard, EventLog, FEATURE_COLORS, FEATURE_TYPES, FLOOR_HEIGHT, FeatureCard, FeatureDetailPageTemplate, FeatureGrid, FeatureGridOrganism, FileTree, FilterGroup, FilterPill, Flex, FlipCard, FlipContainer, FloatingActionButton, Form, FormActions, FormField, FormLayout, FormSection, FormSectionHeader, GameAudioContext, GameAudioProvider, GameAudioToggle, GameCard, GameHud, GameIcon, GameMenu, GameShell, GameTemplate, GenericAppTemplate, GeometricPattern, GradientDivider, GraphCanvas, GraphView, Grid, GridPicker, HStack, Header, HealthBar, HeroOrganism, HeroSection, I18nProvider, IDENTITY_BOOK_FIELDS, Icon, IconPicker, InfiniteScrollSentinel, Input, InputGroup, InstallBox, InventoryGrid, ItemSlot, JazariStateMachine, JsonTreeEditor, Label, LandingPageTemplate, LawReferenceTooltip, LearningCanvas, Lightbox, LikertScale, LineChart2 as LineChart, List3 as List, LoadingState, MapView, MarkdownContent, MarketingFooter, MarketingStatCard, MasterDetail, MasterDetailLayout, MathCanvas, MatrixQuestion, MediaGallery, Menu, Meter, MiniMap, Modal, ModalSlot, ModuleCard, Navigation, NegotiatorBoard, NodeSlotEditor, NotifyListener, NumberStepper, ObjectRulePanel, OnboardingSpotlight, OptionConstraintGroup, StateMachineView as OrbitalStateMachineView, OrbitalVisualization, Overlay, PageHeader, Pagination, PatternTile, PhysicsCanvas, Popover, PositionedCanvas, PricingCard, PricingGrid, PricingOrganism, PricingPageTemplate, ProgressBar, ProgressDots, PropertyInspector, PullQuote, PullToRefresh, QrScanner, QuizBlock, Radio, RangeSlider, ReflectionBlock, RelationSelect, RepeatableFormSection, ReplyTree, ResourceBar, ResourceCounter, RichBlockEditor, RuleEditor, RuntimeDebugger, SHEET_COLUMNS, SPRITE_SHEET_LAYOUT, ScaledDiagram, ScoreDisplay, SearchInput, Section, SectionHeader, SegmentRenderer, Select, SequenceBar, SequencerBoard, ServiceCatalog, ShowcaseCard, ShowcaseOrganism, SidePanel, Sidebar, SignaturePad, SimpleGrid, SimulationCanvas, SimulationControls, SimulationGraph, SimulatorBoard, Skeleton, SlotContentRenderer, SocialProof, SortableList, Spacer, Sparkline, Spinner, Split, SplitPane, SplitSection, Sprite, Stack, StarRating, StatBadge, StatCard, StatDisplay, StateArchitectBoard, StateIndicator, StateJsonView, StateMachineView, StateNode2 as StateNode, StatsGrid, StatsOrganism, StatusBar, StatusDot, StatusEffect, StepFlow, StepFlowOrganism, SubagentTracePanel, SvgBranch, SvgConnection, SvgFlow, SvgGrid, SvgLobe, SvgMesh, SvgMorph, SvgNode, SvgPulse, SvgRing, SvgShield, SvgStack, SwipeableRow, Switch, TERRAIN_COLORS, TILE_HEIGHT, TILE_WIDTH, TabbedContainer, TableView, Tabs, TagCloud, TagInput, TeamCard, TeamOrganism, TerrainPalette, TextHighlight, Textarea, ThemeToggle, TimeSlotCell, Timeline, TimerDisplay, Toast, ToastSlot, Tooltip, TraitFrame, TraitSlot, TraitStateViewer, TransitionArrow, TrendIndicator, TurnIndicator, TypewriterText, Typography, UISlotComponent, UISlotRenderer, UploadDropZone, VStack, VariablePanel, VersionDiff, ViolationAlert, VoteStack, WaypointMarker, WizardContainer, WizardNavigation, WizardProgress, boardEntity, bool, calculateAttackTargets, calculateValidMoves, cn, createInitialGameState, createTranslate, createUnitAnimationState, drawSprite, getCurrentFrame, getTileDimensions, inferDirection, isoToScreen, makeAsset, makeAssetMap, mapBookData, num, objAvailableActions, objAvailableEvents, objCurrentState, objIcon, objId, objMaxRules, objName, objRules, objStates, parseEditFocus, parseLessonSegments, parseMarkdownWithCodeBlocks, parseQueryBinding, pendulum, projectileMotion, resolveFieldMap, resolveFrame, resolveSheetDirection, rows, screenToIso, springOscillator, str, tickAnimationState, toCodeLanguage, transitionAnimation, unitHealth, unitPosition, unitTeam, useAgentChat, useAnchorRect, useAuthContext, useCamera, useCanvasGestures, useCompile, useConnectGitHub, useDeepAgentGeneration, useDisconnectGitHub, useDragReorder, useDraggable, useDropZone, useEmitEvent, useEventBus, useEventListener, useExtensions, useFileEditor, useFileSystem, useGameAudio, useGameAudioContext, useGitHubBranches, useGitHubRepo, useGitHubRepos, useGitHubStatus, useImageCache, useInfiniteScroll, useLongPress, useOrbitalHistory, usePreview, usePullToRefresh, useQuerySingleton, useRenderInterpolation, useSwipeGesture, useTapReveal, useTraitListens, useTranslate127 as useTranslate, useUIEvents, useUISlotManager, useUnitSpriteAtlas, useValidation, vec2 };
51651
+ export { ALL_PRESETS, ALMADAR_DND_MIME, AR_BOOK_FIELDS, AboutPageTemplate, Accordion, ActionButton, Card2 as ActionCard, ActionPalette, ActionTile, ActivationBlock, Alert, AnimatedCounter, AnimatedGraphic, AnimatedReveal, ArticleSection, Aside, AssetPicker, AuthLayout, Avatar, Badge, BehaviorView, BiologyCanvas, BloomQuizBlock, BookChapterView, BookCoverPage, BookNavBar, BookTableOfContents, BookViewer, Box, BranchingLogicBuilder, Breadcrumb, BuilderBoard, Button, ButtonGroup, CTABanner, CalendarGrid, Canvas2D, Card, CardBody, CardContent, CardFooter, CardGrid, CardHeader, CardTitle, Carousel, CaseStudyCard, CaseStudyOrganism, Center, Chart, ChartLegend, ChatBar, Checkbox, ChemistryCanvas, ChoiceButton, ClassifierBoard, Coachmark, CodeBlock, CodeRunnerPanel, CollapsibleSection, ComboCounter, CommunityLinks, ConditionalWrapper, ConfettiEffect, ConfirmDialog, ConnectionBlock, Container, ContentRenderer, ContentSection, ControlButton, ControlGrid, CounterTemplate, DEFAULT_LIKERT_OPTIONS, DEFAULT_MATRIX_COLUMNS, DEFAULT_SLOTS, DIAMOND_TOP_Y, DamageNumber, DashboardGrid, DashboardLayout, DataGrid, DataList, DataTable, DateRangePicker, DateRangeSelector, DayCell, DebuggerBoard, DetailPanel, Dialog, DialogueBubble, Divider, DocBreadcrumb, DocPagination, DocSearch, DocSidebar, DocTOC, DocumentViewer, StateMachineView as DomStateMachineVisualizer, Drawer, DrawerSlot, ELEMENT_SELECTED_EVENT, EMPTY_EFFECT_STATE, EdgeDecoration, EditorCheckbox, EditorSelect, EditorSlider, EditorTextInput, EditorToolbar, EmptyState, EntityDisplayEvents, ErrorBoundary, ErrorState, EventHandlerBoard, EventLog, FEATURE_COLORS, FEATURE_TYPES, FLOOR_HEIGHT, FeatureCard, FeatureDetailPageTemplate, FeatureGrid, FeatureGridOrganism, FileTree, FilterGroup, FilterPill, Flex, FlipCard, FlipContainer, FloatingActionButton, Form, FormActions, FormField, FormLayout, FormSection, FormSectionHeader, GameAudioContext, GameAudioProvider, GameAudioToggle, GameCard, GameHud, GameIcon, GameMenu, GameShell, GameTemplate, GenericAppTemplate, GeometricPattern, GradientDivider, GraphCanvas, GraphView, Grid, GridPicker, HStack, Header, HealthBar, HeroOrganism, HeroSection, I18nProvider, IDENTITY_BOOK_FIELDS, Icon, IconPicker, InfiniteScrollSentinel, Input, InputGroup, InstallBox, InventoryGrid, ItemSlot, JazariStateMachine, JsonTreeEditor, Label, LandingPageTemplate, LawReferenceTooltip, LearningCanvas, Lightbox, LikertScale, LineChart2 as LineChart, List3 as List, LoadingState, MapView, MarkdownContent, MarketingFooter, MarketingStatCard, MasterDetail, MasterDetailLayout, MathCanvas, MatrixQuestion, MediaGallery, Menu, Meter, MiniMap, Modal, ModalSlot, ModuleCard, Navigation, NegotiatorBoard, NodeSlotEditor, NotifyListener, NumberStepper, ObjectRulePanel, OnboardingSpotlight, OptionConstraintGroup, StateMachineView as OrbitalStateMachineView, OrbitalVisualization, Overlay, PageHeader, Pagination, PatternTile, PhysicsCanvas, Popover, PositionedCanvas, PricingCard, PricingGrid, PricingOrganism, PricingPageTemplate, ProgressBar, ProgressDots, PropertyInspector, PullQuote, PullToRefresh, QrScanner, QuizBlock, Radio, RangeSlider, ReflectionBlock, RelationSelect, RepeatableFormSection, ReplyTree, ResourceBar, ResourceCounter, RichBlockEditor, RuleEditor, RuntimeDebugger, SHEET_COLUMNS, SPRITE_SHEET_LAYOUT, ScaledDiagram, ScoreDisplay, SearchInput, Section, SectionHeader, SegmentRenderer, Select, SequenceBar, SequencerBoard, ServiceCatalog, ShowcaseCard, ShowcaseOrganism, SidePanel, Sidebar, SignaturePad, SimpleGrid, SimulationCanvas, SimulationControls, SimulationGraph, SimulatorBoard, Skeleton, SlotContentRenderer, SocialProof, SortableList, Spacer, Sparkline, Spinner, Split, SplitPane, SplitSection, Sprite, Stack, StarRating, StatBadge, StatCard, StatDisplay, StateArchitectBoard, StateGraph, StateIndicator, StateJsonView, StateMachineView, StateNode2 as StateNode, StatsGrid, StatsOrganism, StatusBar, StatusDot, StatusEffect, StepFlow, StepFlowOrganism, SubagentTracePanel, SvgBranch, SvgConnection, SvgFlow, SvgGrid, SvgLobe, SvgMesh, SvgMorph, SvgNode, SvgPulse, SvgRing, SvgShield, SvgStack, SwipeableRow, Switch, TERRAIN_COLORS, TILE_HEIGHT, TILE_WIDTH, TabbedContainer, TableView, Tabs, TagCloud, TagInput, TeamCard, TeamOrganism, TerrainPalette, TextHighlight, Textarea, ThemeToggle, TimeSlotCell, Timeline, TimerDisplay, Toast, ToastSlot, Tooltip, TraitFrame, TraitSlot, TraitStateViewer, TransitionArrow, TrendIndicator, TurnIndicator, TypewriterText, Typography, UISlotComponent, UISlotRenderer, UploadDropZone, VStack, VariablePanel, VersionDiff, ViolationAlert, VoteStack, WaypointMarker, WizardContainer, WizardNavigation, WizardProgress, boardEntity, bool, calculateAttackTargets, calculateValidMoves, cn, createInitialGameState, createTranslate, createUnitAnimationState, drawSprite, getCurrentFrame, getTileDimensions, inferDirection, isoToScreen, makeAsset, makeAssetMap, mapBookData, num, objAvailableActions, objAvailableEvents, objCurrentState, objIcon, objId, objMaxRules, objName, objRules, objStates, parseEditFocus, parseLessonSegments, parseMarkdownWithCodeBlocks, parseQueryBinding, pendulum, projectileMotion, resolveFieldMap, resolveFrame, resolveSheetDirection, rows, screenToIso, springOscillator, str, tickAnimationState, toCodeLanguage, transitionAnimation, unitHealth, unitPosition, unitTeam, useAgentChat, useAnchorRect, useAuthContext, useCamera, useCanvasGestures, useCompile, useConnectGitHub, useDeepAgentGeneration, useDisconnectGitHub, useDragReorder, useDraggable, useDropZone, useEmitEvent, useEventBus, useEventListener, useExtensions, useFileEditor, useFileSystem, useGameAudio, useGameAudioContext, useGitHubBranches, useGitHubRepo, useGitHubRepos, useGitHubStatus, useImageCache, useInfiniteScroll, useLongPress, useOrbitalHistory, usePreview, usePullToRefresh, useQuerySingleton, useRenderInterpolation, useSwipeGesture, useTapReveal, useTraitListens, useTranslate127 as useTranslate, useUIEvents, useUISlotManager, useUnitSpriteAtlas, useValidation, vec2 };