@almadar/ui 5.89.0 → 5.93.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.
- package/dist/avl/index.cjs +1350 -1562
- package/dist/avl/index.js +353 -565
- package/dist/components/game/2d/atoms/DialogueBubble.d.ts +9 -1
- package/dist/components/game/2d/atoms/GameCard.d.ts +7 -1
- package/dist/components/game/2d/molecules/Canvas2D.d.ts +9 -1
- package/dist/components/game/2d/{organisms → molecules}/ObjectRulePanel.d.ts +9 -4
- package/dist/components/game/2d/{organisms → molecules}/SequenceBar.d.ts +15 -5
- package/dist/components/game/2d/molecules/StateJsonView.d.ts +37 -0
- package/dist/components/game/2d/{organisms → molecules}/TraitSlot.d.ts +6 -3
- package/dist/components/game/2d/{organisms → molecules}/TraitStateViewer.d.ts +0 -2
- package/dist/components/game/2d/molecules/VariablePanel.d.ts +28 -0
- package/dist/components/game/2d/molecules/index.d.ts +12 -16
- package/dist/components/game/2d/organisms/EventHandlerBoard.d.ts +1 -1
- package/dist/components/game/shared/lib/puzzleObject.d.ts +1 -1
- package/dist/components/game/shared/spriteAnimationTypes.d.ts +10 -35
- package/dist/components/index.cjs +121 -420
- package/dist/components/index.js +123 -419
- package/dist/lib/verificationRegistry.d.ts +1 -1
- package/dist/providers/index.cjs +1214 -1398
- package/dist/providers/index.js +324 -508
- package/dist/runtime/index.cjs +1211 -1423
- package/dist/runtime/index.js +333 -545
- package/package.json +3 -3
- package/dist/components/game/2d/organisms/SimulationCanvas.d.ts +0 -27
- package/dist/components/game/2d/organisms/SimulationControls.d.ts +0 -51
- package/dist/components/game/2d/organisms/SimulationGraph.d.ts +0 -25
- package/dist/components/game/2d/organisms/StateJsonView.d.ts +0 -17
- package/dist/components/game/2d/organisms/VariablePanel.d.ts +0 -22
- /package/dist/components/game/2d/{organisms → molecules}/ActionPalette.d.ts +0 -0
- /package/dist/components/game/2d/{organisms → molecules}/ActionTile.d.ts +0 -0
- /package/dist/components/game/2d/{organisms → molecules}/EventLog.d.ts +0 -0
- /package/dist/components/game/2d/{organisms → molecules}/RuleEditor.d.ts +0 -0
- /package/dist/components/game/2d/{organisms → molecules}/StateNode.d.ts +0 -0
- /package/dist/components/game/2d/{organisms → molecules}/TransitionArrow.d.ts +0 -0
package/dist/components/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import { twMerge } from 'tailwind-merge';
|
|
|
6
6
|
import { EventBusContext, useTraitScope, useCurrentPagePath, useEntitySchemaOptional, TraitScopeProvider } from '@almadar/ui/providers';
|
|
7
7
|
import { createLogger, isLogLevelEnabled } from '@almadar/logger';
|
|
8
8
|
import * as LucideIcons2 from 'lucide-react';
|
|
9
|
-
import { X, List, Printer, ChevronRight, ChevronLeft, CheckCircle, XCircle, Wrench, RotateCcw, Send, Play, Terminal, ChevronDown, Bug, ArrowRight,
|
|
9
|
+
import { X, List, Printer, ChevronRight, ChevronLeft, CheckCircle, XCircle, Wrench, RotateCcw, Send, Play, Terminal, ChevronDown, Bug, ArrowRight, Search, ChevronUp, MoreHorizontal, Package, Calendar, Pencil, Eye, Image as Image$1, Upload, ZoomIn, TrendingUp, TrendingDown, Minus, AlertCircle, Circle, Clock, CheckCircle2, Loader2, Code, FileText, WrapText, Check, Copy, HelpCircle, Type, Heading1, Heading2, Heading3, ListOrdered, Quote, GitBranch, Plus, Trash, ArrowLeft, Menu as Menu$1, AlertTriangle, Trash2, Eraser, ZoomOut, Download, Lightbulb, PauseCircle, Link2, Tag, User, DollarSign } from 'lucide-react';
|
|
10
10
|
import { useTranslate } from '@almadar/ui/hooks';
|
|
11
11
|
import { useUISlots, useTheme } from '@almadar/ui/context';
|
|
12
12
|
import { evaluate, createMinimalContext } from '@almadar/evaluator';
|
|
@@ -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/
|
|
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/
|
|
8142
|
+
"components/game/2d/molecules/ActionPalette.tsx"() {
|
|
8143
8143
|
init_atoms();
|
|
8144
8144
|
init_cn();
|
|
8145
8145
|
init_ActionTile();
|
|
@@ -16302,6 +16302,7 @@ function Canvas2D({
|
|
|
16302
16302
|
unitScale = 1,
|
|
16303
16303
|
showMinimap = true,
|
|
16304
16304
|
animate,
|
|
16305
|
+
interpolateUnits = false,
|
|
16305
16306
|
// Tuning
|
|
16306
16307
|
debug: debug2 = false,
|
|
16307
16308
|
spriteHeightRatio = 1.5,
|
|
@@ -16336,6 +16337,8 @@ function Canvas2D({
|
|
|
16336
16337
|
const containerRef = useRef(null);
|
|
16337
16338
|
const lerpRafRef = useRef(0);
|
|
16338
16339
|
const animRafRef = useRef(0);
|
|
16340
|
+
const unitInterp = useRenderInterpolation();
|
|
16341
|
+
const interpolatedUnitPositionsRef = useRef(/* @__PURE__ */ new Map());
|
|
16339
16342
|
const [viewportSize, setViewportSize] = useState({ width: 800, height: 600 });
|
|
16340
16343
|
useEffect(() => {
|
|
16341
16344
|
const el = containerRef.current;
|
|
@@ -16650,7 +16653,8 @@ function Canvas2D({
|
|
|
16650
16653
|
return depthA !== depthB ? depthA - depthB : a.position.y - b.position.y;
|
|
16651
16654
|
});
|
|
16652
16655
|
for (const unit of sortedUnits) {
|
|
16653
|
-
const
|
|
16656
|
+
const interpolated = interpolateUnits ? interpolatedUnitPositionsRef.current.get(unit.id) : void 0;
|
|
16657
|
+
const pos = project(interpolated?.x ?? unit.position.x, interpolated?.y ?? unit.position.y, baseOffsetX);
|
|
16654
16658
|
if (pos.x + scaledTileWidth < visLeft || pos.x > visRight || pos.y + scaledTileHeight < visTop || pos.y > visBottom) {
|
|
16655
16659
|
continue;
|
|
16656
16660
|
}
|
|
@@ -16802,7 +16806,8 @@ function Canvas2D({
|
|
|
16802
16806
|
unitScale,
|
|
16803
16807
|
assetManifest,
|
|
16804
16808
|
spriteHeightRatio,
|
|
16805
|
-
spriteMaxWidthRatio
|
|
16809
|
+
spriteMaxWidthRatio,
|
|
16810
|
+
interpolateUnits
|
|
16806
16811
|
]);
|
|
16807
16812
|
useEffect(() => {
|
|
16808
16813
|
if (camera === "fixed") return;
|
|
@@ -16817,6 +16822,19 @@ function Canvas2D({
|
|
|
16817
16822
|
y: centerY - viewportSize.height / 2
|
|
16818
16823
|
};
|
|
16819
16824
|
}, [camera, selectedUnitId, units, project, baseOffsetX, scaledTileWidth, scaledDiamondTopY, scaledFloorHeight, viewportSize, targetCameraRef]);
|
|
16825
|
+
useEffect(() => {
|
|
16826
|
+
if (isSide || !interpolateUnits) return;
|
|
16827
|
+
unitInterp.onSnapshot(
|
|
16828
|
+
units.filter((u) => !!u.position).map((u) => ({ id: u.id, x: u.position.x, y: u.position.y }))
|
|
16829
|
+
);
|
|
16830
|
+
}, [isSide, interpolateUnits, units, unitInterp]);
|
|
16831
|
+
useEffect(() => {
|
|
16832
|
+
if (isSide || !interpolateUnits) return;
|
|
16833
|
+
return unitInterp.startLoop((positions) => {
|
|
16834
|
+
interpolatedUnitPositionsRef.current = positions;
|
|
16835
|
+
draw();
|
|
16836
|
+
});
|
|
16837
|
+
}, [isSide, interpolateUnits, unitInterp, draw]);
|
|
16820
16838
|
useEffect(() => {
|
|
16821
16839
|
if (isSide) return;
|
|
16822
16840
|
draw();
|
|
@@ -26601,6 +26619,7 @@ function GameCard({
|
|
|
26601
26619
|
selected = false,
|
|
26602
26620
|
disabled = false,
|
|
26603
26621
|
size = "md",
|
|
26622
|
+
animState = "idle",
|
|
26604
26623
|
onClick,
|
|
26605
26624
|
clickEvent,
|
|
26606
26625
|
className
|
|
@@ -26628,6 +26647,7 @@ function GameCard({
|
|
|
26628
26647
|
cardSizeMap[size],
|
|
26629
26648
|
disabled ? "border-border opacity-50 cursor-not-allowed" : "border-accent hover:brightness-125 hover:-translate-y-1 cursor-pointer",
|
|
26630
26649
|
selected && "ring-2 ring-foreground ring-offset-1 ring-offset-background -translate-y-1",
|
|
26650
|
+
ANIM_STATE_CLASS[animState],
|
|
26631
26651
|
className
|
|
26632
26652
|
),
|
|
26633
26653
|
children: [
|
|
@@ -26660,7 +26680,7 @@ function GameCard({
|
|
|
26660
26680
|
}
|
|
26661
26681
|
);
|
|
26662
26682
|
}
|
|
26663
|
-
var cardSizeMap, artPxMap;
|
|
26683
|
+
var cardSizeMap, artPxMap, ANIM_STATE_CLASS;
|
|
26664
26684
|
var init_GameCard = __esm({
|
|
26665
26685
|
"components/game/2d/atoms/GameCard.tsx"() {
|
|
26666
26686
|
"use client";
|
|
@@ -26676,6 +26696,12 @@ var init_GameCard = __esm({
|
|
|
26676
26696
|
lg: "w-24 h-36"
|
|
26677
26697
|
};
|
|
26678
26698
|
artPxMap = { sm: 40, md: 52, lg: 64 };
|
|
26699
|
+
ANIM_STATE_CLASS = {
|
|
26700
|
+
idle: "",
|
|
26701
|
+
drawn: "scale-105",
|
|
26702
|
+
played: "-translate-y-2 opacity-80",
|
|
26703
|
+
flipped: "scale-x-0"
|
|
26704
|
+
};
|
|
26679
26705
|
GameCard.displayName = "GameCard";
|
|
26680
26706
|
}
|
|
26681
26707
|
});
|
|
@@ -27366,8 +27392,11 @@ function DialogueBubble({
|
|
|
27366
27392
|
text = "The dungeon awaits. Choose your path wisely.",
|
|
27367
27393
|
portrait = DEFAULT_PORTRAIT,
|
|
27368
27394
|
position = "bottom",
|
|
27395
|
+
mood = "neutral",
|
|
27396
|
+
revealedChars,
|
|
27369
27397
|
className
|
|
27370
27398
|
}) {
|
|
27399
|
+
const visibleText = revealedChars === void 0 ? text : text.slice(0, revealedChars);
|
|
27371
27400
|
return /* @__PURE__ */ jsxs(
|
|
27372
27401
|
Box,
|
|
27373
27402
|
{
|
|
@@ -27377,16 +27406,16 @@ function DialogueBubble({
|
|
|
27377
27406
|
className
|
|
27378
27407
|
),
|
|
27379
27408
|
children: [
|
|
27380
|
-
portrait && /* @__PURE__ */ jsx(Box, { className: "flex-shrink-0 w-12 h-12 rounded-full overflow-hidden border-2
|
|
27409
|
+
portrait && /* @__PURE__ */ jsx(Box, { className: cn("flex-shrink-0 w-12 h-12 rounded-full overflow-hidden border-2 transition-colors duration-300", MOOD_RING_CLASS[mood]), children: /* @__PURE__ */ jsx(GameIcon, { assetUrl: portrait, icon: "image", size: 48, alt: speaker ?? "speaker", className: "w-full h-full object-cover" }) }),
|
|
27381
27410
|
/* @__PURE__ */ jsxs(Box, { className: "flex flex-col gap-1 min-w-0", children: [
|
|
27382
27411
|
speaker && /* @__PURE__ */ jsx(Typography, { as: "span", className: "text-sm font-bold text-warning", children: speaker }),
|
|
27383
|
-
/* @__PURE__ */ jsx(Typography, { as: "span", className: "text-sm text-foreground leading-relaxed", children:
|
|
27412
|
+
/* @__PURE__ */ jsx(Typography, { as: "span", className: "text-sm text-foreground leading-relaxed", children: visibleText })
|
|
27384
27413
|
] })
|
|
27385
27414
|
]
|
|
27386
27415
|
}
|
|
27387
27416
|
);
|
|
27388
27417
|
}
|
|
27389
|
-
var DEFAULT_PORTRAIT;
|
|
27418
|
+
var DEFAULT_PORTRAIT, MOOD_RING_CLASS;
|
|
27390
27419
|
var init_DialogueBubble = __esm({
|
|
27391
27420
|
"components/game/2d/atoms/DialogueBubble.tsx"() {
|
|
27392
27421
|
init_cn();
|
|
@@ -27398,6 +27427,12 @@ var init_DialogueBubble = __esm({
|
|
|
27398
27427
|
role: "effect",
|
|
27399
27428
|
category: "character"
|
|
27400
27429
|
};
|
|
27430
|
+
MOOD_RING_CLASS = {
|
|
27431
|
+
neutral: "border-warning/60",
|
|
27432
|
+
happy: "border-success/70",
|
|
27433
|
+
concerned: "border-info/70",
|
|
27434
|
+
angry: "border-error/70"
|
|
27435
|
+
};
|
|
27401
27436
|
DialogueBubble.displayName = "DialogueBubble";
|
|
27402
27437
|
}
|
|
27403
27438
|
});
|
|
@@ -27838,7 +27873,7 @@ function StateNode2({
|
|
|
27838
27873
|
);
|
|
27839
27874
|
}
|
|
27840
27875
|
var init_StateNode = __esm({
|
|
27841
|
-
"components/game/2d/
|
|
27876
|
+
"components/game/2d/molecules/StateNode.tsx"() {
|
|
27842
27877
|
init_atoms();
|
|
27843
27878
|
init_cn();
|
|
27844
27879
|
StateNode2.displayName = "StateNode";
|
|
@@ -27910,7 +27945,7 @@ function TransitionArrow({
|
|
|
27910
27945
|
}
|
|
27911
27946
|
var NODE_RADIUS;
|
|
27912
27947
|
var init_TransitionArrow = __esm({
|
|
27913
|
-
"components/game/2d/
|
|
27948
|
+
"components/game/2d/molecules/TransitionArrow.tsx"() {
|
|
27914
27949
|
init_cn();
|
|
27915
27950
|
NODE_RADIUS = 40;
|
|
27916
27951
|
TransitionArrow.displayName = "TransitionArrow";
|
|
@@ -28574,7 +28609,7 @@ function TraitStateViewer({
|
|
|
28574
28609
|
}
|
|
28575
28610
|
var SIZE_CONFIG2;
|
|
28576
28611
|
var init_TraitStateViewer = __esm({
|
|
28577
|
-
"components/game/2d/
|
|
28612
|
+
"components/game/2d/molecules/TraitStateViewer.tsx"() {
|
|
28578
28613
|
"use client";
|
|
28579
28614
|
init_cn();
|
|
28580
28615
|
init_Box();
|
|
@@ -28607,7 +28642,8 @@ function TraitSlot({
|
|
|
28607
28642
|
onClick,
|
|
28608
28643
|
onRemove,
|
|
28609
28644
|
clickEvent,
|
|
28610
|
-
removeEvent
|
|
28645
|
+
removeEvent,
|
|
28646
|
+
dropEvent
|
|
28611
28647
|
}) {
|
|
28612
28648
|
const { emit } = useEventBus();
|
|
28613
28649
|
const [isHovered, setIsHovered] = useState(false);
|
|
@@ -28639,29 +28675,30 @@ function TraitSlot({
|
|
|
28639
28675
|
onDragStart?.(equippedItem);
|
|
28640
28676
|
}, [equippedItem, draggable, onDragStart]);
|
|
28641
28677
|
const handleDragOver = useCallback((e) => {
|
|
28642
|
-
if (locked || !onItemDrop) return;
|
|
28678
|
+
if (locked || !onItemDrop && !dropEvent) return;
|
|
28643
28679
|
if (e.dataTransfer.types.includes(DRAG_MIME2)) {
|
|
28644
28680
|
e.preventDefault();
|
|
28645
28681
|
const allowed = e.dataTransfer.effectAllowed;
|
|
28646
28682
|
e.dataTransfer.dropEffect = allowed === "copy" ? "copy" : "move";
|
|
28647
28683
|
setIsDragOver(true);
|
|
28648
28684
|
}
|
|
28649
|
-
}, [locked, onItemDrop]);
|
|
28685
|
+
}, [locked, onItemDrop, dropEvent]);
|
|
28650
28686
|
const handleDragLeave = useCallback(() => {
|
|
28651
28687
|
setIsDragOver(false);
|
|
28652
28688
|
}, []);
|
|
28653
28689
|
const handleDrop = useCallback((e) => {
|
|
28654
28690
|
e.preventDefault();
|
|
28655
28691
|
setIsDragOver(false);
|
|
28656
|
-
if (locked || !onItemDrop) return;
|
|
28692
|
+
if (locked || !onItemDrop && !dropEvent) return;
|
|
28657
28693
|
const raw = e.dataTransfer.getData(DRAG_MIME2);
|
|
28658
28694
|
if (!raw) return;
|
|
28659
28695
|
try {
|
|
28660
28696
|
const item = JSON.parse(raw);
|
|
28661
|
-
|
|
28697
|
+
if (dropEvent) emit(`UI:${dropEvent}`, { slotNumber, itemId: item.id });
|
|
28698
|
+
else onItemDrop?.(item);
|
|
28662
28699
|
} catch {
|
|
28663
28700
|
}
|
|
28664
|
-
}, [locked, onItemDrop]);
|
|
28701
|
+
}, [locked, onItemDrop, dropEvent, emit, slotNumber]);
|
|
28665
28702
|
const getTooltipStyle = () => {
|
|
28666
28703
|
if (!slotRef.current) return {};
|
|
28667
28704
|
const rect = slotRef.current.getBoundingClientRect();
|
|
@@ -28781,7 +28818,7 @@ function TraitSlot({
|
|
|
28781
28818
|
}
|
|
28782
28819
|
var SIZE_CONFIG3, DRAG_MIME2;
|
|
28783
28820
|
var init_TraitSlot = __esm({
|
|
28784
|
-
"components/game/2d/
|
|
28821
|
+
"components/game/2d/molecules/TraitSlot.tsx"() {
|
|
28785
28822
|
"use client";
|
|
28786
28823
|
init_cn();
|
|
28787
28824
|
init_useEventBus();
|
|
@@ -28987,6 +29024,8 @@ function SequenceBar({
|
|
|
28987
29024
|
maxSlots,
|
|
28988
29025
|
onSlotDrop,
|
|
28989
29026
|
onSlotRemove,
|
|
29027
|
+
slotDropEvent,
|
|
29028
|
+
slotRemoveEvent,
|
|
28990
29029
|
playing = false,
|
|
28991
29030
|
currentStep = -1,
|
|
28992
29031
|
categoryColors,
|
|
@@ -28994,14 +29033,17 @@ function SequenceBar({
|
|
|
28994
29033
|
size = "lg",
|
|
28995
29034
|
className
|
|
28996
29035
|
}) {
|
|
29036
|
+
const { emit } = useEventBus();
|
|
28997
29037
|
const handleDrop = useCallback((index) => (item) => {
|
|
28998
29038
|
if (playing) return;
|
|
28999
|
-
|
|
29000
|
-
|
|
29039
|
+
if (slotDropEvent) emit(`UI:${slotDropEvent}`, { slotNumber: index, itemId: item.id });
|
|
29040
|
+
else onSlotDrop?.(index, item);
|
|
29041
|
+
}, [emit, slotDropEvent, onSlotDrop, playing]);
|
|
29001
29042
|
const handleRemove = useCallback((index) => () => {
|
|
29002
29043
|
if (playing) return;
|
|
29003
|
-
|
|
29004
|
-
|
|
29044
|
+
if (slotRemoveEvent) emit(`UI:${slotRemoveEvent}`, { slotNumber: index });
|
|
29045
|
+
else onSlotRemove?.(index);
|
|
29046
|
+
}, [emit, slotRemoveEvent, onSlotRemove, playing]);
|
|
29005
29047
|
const paddedSlots = Array.from({ length: maxSlots }, (_, i) => slots[i]);
|
|
29006
29048
|
return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
29007
29049
|
i > 0 && /* @__PURE__ */ jsx(
|
|
@@ -29033,9 +29075,10 @@ function SequenceBar({
|
|
|
29033
29075
|
] }, i)) });
|
|
29034
29076
|
}
|
|
29035
29077
|
var init_SequenceBar = __esm({
|
|
29036
|
-
"components/game/2d/
|
|
29078
|
+
"components/game/2d/molecules/SequenceBar.tsx"() {
|
|
29037
29079
|
init_atoms();
|
|
29038
29080
|
init_cn();
|
|
29081
|
+
init_useEventBus();
|
|
29039
29082
|
init_TraitSlot();
|
|
29040
29083
|
SequenceBar.displayName = "SequenceBar";
|
|
29041
29084
|
}
|
|
@@ -29351,7 +29394,7 @@ function RuleEditor({
|
|
|
29351
29394
|
] });
|
|
29352
29395
|
}
|
|
29353
29396
|
var init_RuleEditor = __esm({
|
|
29354
|
-
"components/game/2d/
|
|
29397
|
+
"components/game/2d/molecules/RuleEditor.tsx"() {
|
|
29355
29398
|
init_atoms();
|
|
29356
29399
|
init_cn();
|
|
29357
29400
|
RuleEditor.displayName = "RuleEditor";
|
|
@@ -29392,7 +29435,7 @@ function EventLog({
|
|
|
29392
29435
|
}
|
|
29393
29436
|
var STATUS_STYLES, STATUS_DOTS;
|
|
29394
29437
|
var init_EventLog = __esm({
|
|
29395
|
-
"components/game/2d/
|
|
29438
|
+
"components/game/2d/molecules/EventLog.tsx"() {
|
|
29396
29439
|
init_atoms();
|
|
29397
29440
|
init_cn();
|
|
29398
29441
|
STATUS_STYLES = {
|
|
@@ -29447,10 +29490,12 @@ var init_puzzleObject = __esm({
|
|
|
29447
29490
|
function ObjectRulePanel({
|
|
29448
29491
|
object,
|
|
29449
29492
|
onRulesChange,
|
|
29493
|
+
rulesChangeEvent,
|
|
29450
29494
|
disabled = false,
|
|
29451
29495
|
className
|
|
29452
29496
|
}) {
|
|
29453
29497
|
const { t } = useTranslate();
|
|
29498
|
+
const { emit } = useEventBus();
|
|
29454
29499
|
const id = objId(object);
|
|
29455
29500
|
const name = objName(object);
|
|
29456
29501
|
const icon = objIcon(object);
|
|
@@ -29461,15 +29506,19 @@ function ObjectRulePanel({
|
|
|
29461
29506
|
const rules = objRules(object);
|
|
29462
29507
|
const maxRules = objMaxRules(object);
|
|
29463
29508
|
const canAdd = rules.length < maxRules;
|
|
29509
|
+
const emitRules = useCallback((newRules) => {
|
|
29510
|
+
if (rulesChangeEvent) emit(`UI:${rulesChangeEvent}`, { objectId: id, rules: newRules });
|
|
29511
|
+
else onRulesChange?.(id, newRules);
|
|
29512
|
+
}, [rulesChangeEvent, emit, id, onRulesChange]);
|
|
29464
29513
|
const handleRuleChange = useCallback((index, updatedRule) => {
|
|
29465
29514
|
const newRules = [...rules];
|
|
29466
29515
|
newRules[index] = updatedRule;
|
|
29467
|
-
|
|
29468
|
-
}, [
|
|
29516
|
+
emitRules(newRules);
|
|
29517
|
+
}, [rules, emitRules]);
|
|
29469
29518
|
const handleRuleRemove = useCallback((index) => {
|
|
29470
29519
|
const newRules = rules.filter((_, i) => i !== index);
|
|
29471
|
-
|
|
29472
|
-
}, [
|
|
29520
|
+
emitRules(newRules);
|
|
29521
|
+
}, [rules, emitRules]);
|
|
29473
29522
|
const handleAddRule = useCallback(() => {
|
|
29474
29523
|
if (!canAdd || disabled) return;
|
|
29475
29524
|
const firstEvent = availableEvents[0]?.value || "";
|
|
@@ -29479,8 +29528,8 @@ function ObjectRulePanel({
|
|
|
29479
29528
|
whenEvent: firstEvent,
|
|
29480
29529
|
thenAction: firstAction
|
|
29481
29530
|
};
|
|
29482
|
-
|
|
29483
|
-
}, [canAdd, disabled,
|
|
29531
|
+
emitRules([...rules, newRule]);
|
|
29532
|
+
}, [canAdd, disabled, rules, availableEvents, availableActions, emitRules]);
|
|
29484
29533
|
const machine = {
|
|
29485
29534
|
name,
|
|
29486
29535
|
states,
|
|
@@ -29520,9 +29569,10 @@ function ObjectRulePanel({
|
|
|
29520
29569
|
}
|
|
29521
29570
|
var nextRuleId;
|
|
29522
29571
|
var init_ObjectRulePanel = __esm({
|
|
29523
|
-
"components/game/2d/
|
|
29572
|
+
"components/game/2d/molecules/ObjectRulePanel.tsx"() {
|
|
29524
29573
|
init_atoms();
|
|
29525
29574
|
init_cn();
|
|
29575
|
+
init_useEventBus();
|
|
29526
29576
|
init_TraitStateViewer();
|
|
29527
29577
|
init_RuleEditor();
|
|
29528
29578
|
init_puzzleObject();
|
|
@@ -29752,61 +29802,35 @@ function VariablePanel({
|
|
|
29752
29802
|
const { t } = useTranslate();
|
|
29753
29803
|
return /* @__PURE__ */ jsxs(VStack, { className: cn("p-3 rounded-lg bg-card border border-border", className), gap: "sm", children: [
|
|
29754
29804
|
/* @__PURE__ */ jsx(Typography, { variant: "body2", className: "text-muted-foreground font-medium", children: t("stateArchitect.variables", { name: entityName }) }),
|
|
29755
|
-
variables.map((v) => {
|
|
29756
|
-
|
|
29757
|
-
|
|
29758
|
-
|
|
29759
|
-
const min = numField(v.min, 0);
|
|
29760
|
-
const unit = v.unit == null ? "" : String(v.unit);
|
|
29761
|
-
const pct = Math.round((value - min) / (max - min) * 100);
|
|
29762
|
-
const isHigh = pct > 80;
|
|
29763
|
-
const isLow = pct < 20;
|
|
29764
|
-
return /* @__PURE__ */ jsxs(VStack, { gap: "none", children: [
|
|
29765
|
-
/* @__PURE__ */ jsxs(HStack, { className: "items-center justify-between", children: [
|
|
29766
|
-
/* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-foreground font-medium", children: name }),
|
|
29767
|
-
/* @__PURE__ */ jsxs(Typography, { variant: "caption", className: cn(
|
|
29768
|
-
isHigh ? "text-error" : isLow ? "text-warning" : "text-foreground"
|
|
29769
|
-
), children: [
|
|
29770
|
-
value,
|
|
29771
|
-
unit,
|
|
29772
|
-
" / ",
|
|
29773
|
-
max,
|
|
29774
|
-
unit
|
|
29775
|
-
] })
|
|
29776
|
-
] }),
|
|
29777
|
-
/* @__PURE__ */ jsx(
|
|
29778
|
-
ProgressBar,
|
|
29779
|
-
{
|
|
29780
|
-
value: pct,
|
|
29781
|
-
color: isHigh ? "danger" : isLow ? "warning" : "primary",
|
|
29782
|
-
size: "sm"
|
|
29783
|
-
}
|
|
29784
|
-
)
|
|
29785
|
-
] }, name);
|
|
29786
|
-
})
|
|
29805
|
+
(variables ?? []).map((v) => /* @__PURE__ */ jsxs(HStack, { className: "items-center justify-between", children: [
|
|
29806
|
+
/* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-foreground font-medium", children: v.name }),
|
|
29807
|
+
/* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-accent font-mono", children: v.value })
|
|
29808
|
+
] }, v.name))
|
|
29787
29809
|
] });
|
|
29788
29810
|
}
|
|
29789
|
-
var numField;
|
|
29790
29811
|
var init_VariablePanel = __esm({
|
|
29791
|
-
"components/game/2d/
|
|
29812
|
+
"components/game/2d/molecules/VariablePanel.tsx"() {
|
|
29792
29813
|
init_atoms();
|
|
29793
29814
|
init_cn();
|
|
29794
|
-
numField = (v, fallback = 0) => {
|
|
29795
|
-
const n = Number(v);
|
|
29796
|
-
return Number.isFinite(n) ? n : fallback;
|
|
29797
|
-
};
|
|
29798
29815
|
VariablePanel.displayName = "VariablePanel";
|
|
29799
29816
|
}
|
|
29800
29817
|
});
|
|
29801
29818
|
function StateJsonView({
|
|
29802
|
-
|
|
29819
|
+
name,
|
|
29820
|
+
initialState,
|
|
29821
|
+
states,
|
|
29822
|
+
transitions,
|
|
29803
29823
|
label,
|
|
29804
29824
|
defaultExpanded = false,
|
|
29805
29825
|
className
|
|
29806
29826
|
}) {
|
|
29807
29827
|
const { t } = useTranslate();
|
|
29808
29828
|
const [expanded, setExpanded] = useState(defaultExpanded);
|
|
29809
|
-
const jsonString = JSON.stringify(
|
|
29829
|
+
const jsonString = JSON.stringify(
|
|
29830
|
+
{ name, initialState, states: states ?? [], transitions: transitions ?? [] },
|
|
29831
|
+
null,
|
|
29832
|
+
2
|
|
29833
|
+
);
|
|
29810
29834
|
return /* @__PURE__ */ jsxs(VStack, { className: cn("rounded-lg border border-border overflow-hidden", className), gap: "none", children: [
|
|
29811
29835
|
/* @__PURE__ */ jsxs(HStack, { className: "items-center justify-between p-2 bg-muted", gap: "sm", children: [
|
|
29812
29836
|
/* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground font-medium", children: label ?? t("stateArchitect.viewCode") }),
|
|
@@ -29823,7 +29847,7 @@ function StateJsonView({
|
|
|
29823
29847
|
] });
|
|
29824
29848
|
}
|
|
29825
29849
|
var init_StateJsonView = __esm({
|
|
29826
|
-
"components/game/2d/
|
|
29850
|
+
"components/game/2d/molecules/StateJsonView.tsx"() {
|
|
29827
29851
|
init_atoms();
|
|
29828
29852
|
init_cn();
|
|
29829
29853
|
StateJsonView.displayName = "StateJsonView";
|
|
@@ -29992,7 +30016,7 @@ function StateArchitectBoard({
|
|
|
29992
30016
|
setAddingFrom(null);
|
|
29993
30017
|
if (playAgainEvent) emit(`UI:${playAgainEvent}`, {});
|
|
29994
30018
|
}, [initialState, entityVariables, playAgainEvent, emit]);
|
|
29995
|
-
|
|
30019
|
+
useMemo(() => ({
|
|
29996
30020
|
name: entityName,
|
|
29997
30021
|
states: entityStates,
|
|
29998
30022
|
initialState,
|
|
@@ -30127,7 +30151,7 @@ function StateArchitectBoard({
|
|
|
30127
30151
|
VariablePanel,
|
|
30128
30152
|
{
|
|
30129
30153
|
entityName,
|
|
30130
|
-
variables
|
|
30154
|
+
variables: variables.map((v) => ({ name: String(v.name ?? ""), value: String(v.value ?? "") }))
|
|
30131
30155
|
}
|
|
30132
30156
|
),
|
|
30133
30157
|
testResults.length > 0 && /* @__PURE__ */ jsxs(VStack, { className: "p-3 rounded-container bg-card border border-border", gap: "xs", children: [
|
|
@@ -30138,7 +30162,16 @@ function StateArchitectBoard({
|
|
|
30138
30162
|
!r.passed && /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-error", children: t("stateArchitect.gotState", { state: r.actualState }) })
|
|
30139
30163
|
] }, i))
|
|
30140
30164
|
] }),
|
|
30141
|
-
resolved.showCodeView !== false && /* @__PURE__ */ jsx(
|
|
30165
|
+
resolved.showCodeView !== false && /* @__PURE__ */ jsx(
|
|
30166
|
+
StateJsonView,
|
|
30167
|
+
{
|
|
30168
|
+
name: entityName,
|
|
30169
|
+
initialState,
|
|
30170
|
+
states: entityStates,
|
|
30171
|
+
transitions: transitions.map((tr) => ({ from: tr.from, to: tr.to, event: tr.event })),
|
|
30172
|
+
label: "View Code"
|
|
30173
|
+
}
|
|
30174
|
+
)
|
|
30142
30175
|
] })
|
|
30143
30176
|
] }),
|
|
30144
30177
|
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") }) }),
|
|
@@ -30779,336 +30812,6 @@ var init_physicsPresets = __esm({
|
|
|
30779
30812
|
];
|
|
30780
30813
|
}
|
|
30781
30814
|
});
|
|
30782
|
-
function resolvePreset(preset) {
|
|
30783
|
-
if (typeof preset !== "string") return preset;
|
|
30784
|
-
return PRESET_BY_ID[preset] ?? projectileMotion;
|
|
30785
|
-
}
|
|
30786
|
-
function SimulationCanvas({
|
|
30787
|
-
preset: presetProp,
|
|
30788
|
-
width = 600,
|
|
30789
|
-
height = 400,
|
|
30790
|
-
bodies: externalBodies,
|
|
30791
|
-
className
|
|
30792
|
-
}) {
|
|
30793
|
-
const preset = useMemo(() => resolvePreset(presetProp), [presetProp]);
|
|
30794
|
-
const canvasRef = useRef(null);
|
|
30795
|
-
const bodiesRef = useRef(structuredClone(preset.bodies));
|
|
30796
|
-
const interp = useRenderInterpolation();
|
|
30797
|
-
useEffect(() => {
|
|
30798
|
-
bodiesRef.current = structuredClone(preset.bodies);
|
|
30799
|
-
}, [preset]);
|
|
30800
|
-
const draw = useCallback(() => {
|
|
30801
|
-
const canvas = canvasRef.current;
|
|
30802
|
-
if (!canvas) return;
|
|
30803
|
-
const ctx = canvas.getContext("2d");
|
|
30804
|
-
if (!ctx) return;
|
|
30805
|
-
const bodies = bodiesRef.current;
|
|
30806
|
-
ctx.clearRect(0, 0, width, height);
|
|
30807
|
-
ctx.fillStyle = preset.backgroundColor ?? "#1a1a2e";
|
|
30808
|
-
ctx.fillRect(0, 0, width, height);
|
|
30809
|
-
if (preset.constraints) {
|
|
30810
|
-
for (const c of preset.constraints) {
|
|
30811
|
-
const a = bodies[c.bodyA];
|
|
30812
|
-
const b = bodies[c.bodyB];
|
|
30813
|
-
if (a && b) {
|
|
30814
|
-
ctx.beginPath();
|
|
30815
|
-
ctx.moveTo(a.x, a.y);
|
|
30816
|
-
ctx.lineTo(b.x, b.y);
|
|
30817
|
-
ctx.strokeStyle = "#533483";
|
|
30818
|
-
ctx.lineWidth = 1;
|
|
30819
|
-
ctx.setLineDash([4, 4]);
|
|
30820
|
-
ctx.stroke();
|
|
30821
|
-
ctx.setLineDash([]);
|
|
30822
|
-
}
|
|
30823
|
-
}
|
|
30824
|
-
}
|
|
30825
|
-
for (const body of bodies) {
|
|
30826
|
-
ctx.beginPath();
|
|
30827
|
-
ctx.arc(body.x, body.y, body.radius, 0, Math.PI * 2);
|
|
30828
|
-
ctx.fillStyle = body.color ?? "#e94560";
|
|
30829
|
-
ctx.fill();
|
|
30830
|
-
if (preset.showVelocity) {
|
|
30831
|
-
ctx.beginPath();
|
|
30832
|
-
ctx.moveTo(body.x, body.y);
|
|
30833
|
-
ctx.lineTo(body.x + body.vx * 0.1, body.y + body.vy * 0.1);
|
|
30834
|
-
ctx.strokeStyle = "#16213e";
|
|
30835
|
-
ctx.lineWidth = 2;
|
|
30836
|
-
ctx.stroke();
|
|
30837
|
-
}
|
|
30838
|
-
}
|
|
30839
|
-
}, [width, height, preset]);
|
|
30840
|
-
useEffect(() => {
|
|
30841
|
-
if (!externalBodies) return;
|
|
30842
|
-
interp.onSnapshot(externalBodies.map((b) => ({ id: b.id, x: b.x, y: b.y })));
|
|
30843
|
-
}, [externalBodies]);
|
|
30844
|
-
const presetRef = useRef(preset);
|
|
30845
|
-
presetRef.current = preset;
|
|
30846
|
-
const widthRef = useRef(width);
|
|
30847
|
-
widthRef.current = width;
|
|
30848
|
-
const heightRef = useRef(height);
|
|
30849
|
-
heightRef.current = height;
|
|
30850
|
-
useEffect(() => {
|
|
30851
|
-
if (!externalBodies) return;
|
|
30852
|
-
const drawInterpolated = (positions) => {
|
|
30853
|
-
const canvas = canvasRef.current;
|
|
30854
|
-
if (!canvas) return;
|
|
30855
|
-
const ctx = canvas.getContext("2d");
|
|
30856
|
-
if (!ctx) return;
|
|
30857
|
-
const bodies = bodiesRef.current;
|
|
30858
|
-
const p = presetRef.current;
|
|
30859
|
-
const w = widthRef.current;
|
|
30860
|
-
const h = heightRef.current;
|
|
30861
|
-
ctx.clearRect(0, 0, w, h);
|
|
30862
|
-
ctx.fillStyle = p.backgroundColor ?? "#1a1a2e";
|
|
30863
|
-
ctx.fillRect(0, 0, w, h);
|
|
30864
|
-
if (p.constraints) {
|
|
30865
|
-
for (const c of p.constraints) {
|
|
30866
|
-
const a = bodies[c.bodyA];
|
|
30867
|
-
const b = bodies[c.bodyB];
|
|
30868
|
-
if (a && b) {
|
|
30869
|
-
const aPos = positions.get(a.id) ?? a;
|
|
30870
|
-
const bPos = positions.get(b.id) ?? b;
|
|
30871
|
-
ctx.beginPath();
|
|
30872
|
-
ctx.moveTo(aPos.x, aPos.y);
|
|
30873
|
-
ctx.lineTo(bPos.x, bPos.y);
|
|
30874
|
-
ctx.strokeStyle = "#533483";
|
|
30875
|
-
ctx.lineWidth = 1;
|
|
30876
|
-
ctx.setLineDash([4, 4]);
|
|
30877
|
-
ctx.stroke();
|
|
30878
|
-
ctx.setLineDash([]);
|
|
30879
|
-
}
|
|
30880
|
-
}
|
|
30881
|
-
}
|
|
30882
|
-
for (const body of bodies) {
|
|
30883
|
-
const pos = positions.get(body.id) ?? body;
|
|
30884
|
-
ctx.beginPath();
|
|
30885
|
-
ctx.arc(pos.x, pos.y, body.radius, 0, Math.PI * 2);
|
|
30886
|
-
ctx.fillStyle = body.color ?? "#e94560";
|
|
30887
|
-
ctx.fill();
|
|
30888
|
-
if (p.showVelocity) {
|
|
30889
|
-
ctx.beginPath();
|
|
30890
|
-
ctx.moveTo(pos.x, pos.y);
|
|
30891
|
-
ctx.lineTo(pos.x + body.vx * 0.1, pos.y + body.vy * 0.1);
|
|
30892
|
-
ctx.strokeStyle = "#16213e";
|
|
30893
|
-
ctx.lineWidth = 2;
|
|
30894
|
-
ctx.stroke();
|
|
30895
|
-
}
|
|
30896
|
-
}
|
|
30897
|
-
};
|
|
30898
|
-
return interp.startLoop(drawInterpolated);
|
|
30899
|
-
}, [externalBodies !== void 0, interp.startLoop]);
|
|
30900
|
-
useEffect(() => {
|
|
30901
|
-
draw();
|
|
30902
|
-
}, [draw]);
|
|
30903
|
-
useEffect(() => {
|
|
30904
|
-
if (typeof window === "undefined") return;
|
|
30905
|
-
const canvas = canvasRef.current;
|
|
30906
|
-
if (!canvas) return;
|
|
30907
|
-
bindCanvasCapture(() => canvas.toDataURL("image/png"));
|
|
30908
|
-
return () => {
|
|
30909
|
-
bindCanvasCapture(() => null);
|
|
30910
|
-
};
|
|
30911
|
-
}, []);
|
|
30912
|
-
return /* @__PURE__ */ jsx(Box, { className: cn("flex justify-center", className), children: /* @__PURE__ */ jsx(
|
|
30913
|
-
"canvas",
|
|
30914
|
-
{
|
|
30915
|
-
ref: canvasRef,
|
|
30916
|
-
width,
|
|
30917
|
-
height,
|
|
30918
|
-
className: "rounded-container block max-w-full h-auto"
|
|
30919
|
-
}
|
|
30920
|
-
) });
|
|
30921
|
-
}
|
|
30922
|
-
var PRESET_BY_ID;
|
|
30923
|
-
var init_SimulationCanvas = __esm({
|
|
30924
|
-
"components/game/2d/organisms/SimulationCanvas.tsx"() {
|
|
30925
|
-
init_cn();
|
|
30926
|
-
init_atoms();
|
|
30927
|
-
init_verificationRegistry();
|
|
30928
|
-
init_physicsPresets();
|
|
30929
|
-
init_useRenderInterpolation();
|
|
30930
|
-
PRESET_BY_ID = {
|
|
30931
|
-
"mechanics-projectile": projectileMotion,
|
|
30932
|
-
"mechanics-pendulum": pendulum,
|
|
30933
|
-
"mechanics-spring": springOscillator
|
|
30934
|
-
};
|
|
30935
|
-
SimulationCanvas.displayName = "SimulationCanvas";
|
|
30936
|
-
}
|
|
30937
|
-
});
|
|
30938
|
-
function SimulationControls({
|
|
30939
|
-
running,
|
|
30940
|
-
speed,
|
|
30941
|
-
parameters,
|
|
30942
|
-
onPlay,
|
|
30943
|
-
onPause,
|
|
30944
|
-
onStep,
|
|
30945
|
-
onReset,
|
|
30946
|
-
onSpeedChange,
|
|
30947
|
-
onParameterChange,
|
|
30948
|
-
playEvent,
|
|
30949
|
-
pauseEvent,
|
|
30950
|
-
stepEvent,
|
|
30951
|
-
resetEvent,
|
|
30952
|
-
speedChangeEvent,
|
|
30953
|
-
parameterChangeEvent,
|
|
30954
|
-
assetManifest,
|
|
30955
|
-
className
|
|
30956
|
-
}) {
|
|
30957
|
-
const eventBus = useEventBus();
|
|
30958
|
-
const ui = assetManifest?.ui;
|
|
30959
|
-
const handlePlay = () => {
|
|
30960
|
-
if (playEvent) eventBus.emit(`UI:${playEvent}`, {});
|
|
30961
|
-
onPlay?.();
|
|
30962
|
-
};
|
|
30963
|
-
const handlePause = () => {
|
|
30964
|
-
if (pauseEvent) eventBus.emit(`UI:${pauseEvent}`, {});
|
|
30965
|
-
onPause?.();
|
|
30966
|
-
};
|
|
30967
|
-
const handleStep = () => {
|
|
30968
|
-
if (stepEvent) eventBus.emit(`UI:${stepEvent}`, {});
|
|
30969
|
-
onStep?.();
|
|
30970
|
-
};
|
|
30971
|
-
const handleReset = () => {
|
|
30972
|
-
if (resetEvent) eventBus.emit(`UI:${resetEvent}`, {});
|
|
30973
|
-
onReset?.();
|
|
30974
|
-
};
|
|
30975
|
-
const handleSpeedChange = (s) => {
|
|
30976
|
-
if (speedChangeEvent) eventBus.emit(`UI:${speedChangeEvent}`, { speed: s });
|
|
30977
|
-
onSpeedChange?.(s);
|
|
30978
|
-
};
|
|
30979
|
-
const handleParameterChange = (name, value) => {
|
|
30980
|
-
if (parameterChangeEvent) eventBus.emit(`UI:${parameterChangeEvent}`, { name, value });
|
|
30981
|
-
onParameterChange?.(name, value);
|
|
30982
|
-
};
|
|
30983
|
-
return /* @__PURE__ */ jsxs(VStack, { gap: "md", className, children: [
|
|
30984
|
-
/* @__PURE__ */ jsxs(HStack, { gap: "sm", align: "center", children: [
|
|
30985
|
-
running ? /* @__PURE__ */ jsxs(Button, { size: "sm", variant: "secondary", onClick: handlePause, children: [
|
|
30986
|
-
/* @__PURE__ */ jsx(GameIcon, { icon: Pause, assetUrl: ui?.["pause"], size: "sm" }),
|
|
30987
|
-
"Pause"
|
|
30988
|
-
] }) : /* @__PURE__ */ jsxs(Button, { size: "sm", variant: "primary", onClick: handlePlay, children: [
|
|
30989
|
-
/* @__PURE__ */ jsx(GameIcon, { icon: Play, assetUrl: ui?.["play"], size: "sm" }),
|
|
30990
|
-
"Play"
|
|
30991
|
-
] }),
|
|
30992
|
-
/* @__PURE__ */ jsxs(Button, { size: "sm", variant: "ghost", onClick: handleStep, disabled: running, children: [
|
|
30993
|
-
/* @__PURE__ */ jsx(GameIcon, { icon: SkipForward, assetUrl: ui?.["step"], size: "sm" }),
|
|
30994
|
-
"Step"
|
|
30995
|
-
] }),
|
|
30996
|
-
/* @__PURE__ */ jsxs(Button, { size: "sm", variant: "ghost", onClick: handleReset, children: [
|
|
30997
|
-
/* @__PURE__ */ jsx(GameIcon, { icon: RotateCcw, assetUrl: ui?.["reset"], size: "sm" }),
|
|
30998
|
-
"Reset"
|
|
30999
|
-
] })
|
|
31000
|
-
] }),
|
|
31001
|
-
/* @__PURE__ */ jsxs(VStack, { gap: "xs", children: [
|
|
31002
|
-
/* @__PURE__ */ jsxs(Typography, { variant: "caption", color: "muted", children: [
|
|
31003
|
-
"Speed: ",
|
|
31004
|
-
speed.toFixed(1),
|
|
31005
|
-
"x"
|
|
31006
|
-
] }),
|
|
31007
|
-
/* @__PURE__ */ jsx(
|
|
31008
|
-
"input",
|
|
31009
|
-
{
|
|
31010
|
-
type: "range",
|
|
31011
|
-
min: 0.1,
|
|
31012
|
-
max: 5,
|
|
31013
|
-
step: 0.1,
|
|
31014
|
-
value: speed,
|
|
31015
|
-
onChange: (e) => handleSpeedChange(parseFloat(e.target.value)),
|
|
31016
|
-
className: "w-full"
|
|
31017
|
-
}
|
|
31018
|
-
)
|
|
31019
|
-
] }),
|
|
31020
|
-
Object.entries(parameters).map(([name, param]) => /* @__PURE__ */ jsxs(VStack, { gap: "xs", children: [
|
|
31021
|
-
/* @__PURE__ */ jsxs(Typography, { variant: "caption", color: "muted", children: [
|
|
31022
|
-
param.label,
|
|
31023
|
-
": ",
|
|
31024
|
-
param.value.toFixed(2)
|
|
31025
|
-
] }),
|
|
31026
|
-
/* @__PURE__ */ jsx(
|
|
31027
|
-
"input",
|
|
31028
|
-
{
|
|
31029
|
-
type: "range",
|
|
31030
|
-
min: param.min,
|
|
31031
|
-
max: param.max,
|
|
31032
|
-
step: param.step,
|
|
31033
|
-
value: param.value,
|
|
31034
|
-
onChange: (e) => handleParameterChange(name, parseFloat(e.target.value)),
|
|
31035
|
-
className: "w-full"
|
|
31036
|
-
}
|
|
31037
|
-
)
|
|
31038
|
-
] }, name))
|
|
31039
|
-
] });
|
|
31040
|
-
}
|
|
31041
|
-
var init_SimulationControls = __esm({
|
|
31042
|
-
"components/game/2d/organisms/SimulationControls.tsx"() {
|
|
31043
|
-
init_useEventBus();
|
|
31044
|
-
init_atoms();
|
|
31045
|
-
init_GameIcon();
|
|
31046
|
-
SimulationControls.displayName = "SimulationControls";
|
|
31047
|
-
}
|
|
31048
|
-
});
|
|
31049
|
-
function SimulationGraph({
|
|
31050
|
-
label,
|
|
31051
|
-
unit,
|
|
31052
|
-
data,
|
|
31053
|
-
maxPoints = 200,
|
|
31054
|
-
width = 300,
|
|
31055
|
-
height = 120,
|
|
31056
|
-
color = "#e94560",
|
|
31057
|
-
className
|
|
31058
|
-
}) {
|
|
31059
|
-
const canvasRef = useRef(null);
|
|
31060
|
-
const visibleData = data.slice(-maxPoints);
|
|
31061
|
-
useEffect(() => {
|
|
31062
|
-
const canvas = canvasRef.current;
|
|
31063
|
-
if (!canvas || visibleData.length < 2) return;
|
|
31064
|
-
const ctx = canvas.getContext("2d");
|
|
31065
|
-
if (!ctx) return;
|
|
31066
|
-
ctx.clearRect(0, 0, width, height);
|
|
31067
|
-
ctx.fillStyle = "#0f0f23";
|
|
31068
|
-
ctx.fillRect(0, 0, width, height);
|
|
31069
|
-
ctx.strokeStyle = "#1a1a3e";
|
|
31070
|
-
ctx.lineWidth = 0.5;
|
|
31071
|
-
for (let i = 0; i < 5; i++) {
|
|
31072
|
-
const y = height / 5 * i;
|
|
31073
|
-
ctx.beginPath();
|
|
31074
|
-
ctx.moveTo(0, y);
|
|
31075
|
-
ctx.lineTo(width, y);
|
|
31076
|
-
ctx.stroke();
|
|
31077
|
-
}
|
|
31078
|
-
let minVal = Infinity;
|
|
31079
|
-
let maxVal = -Infinity;
|
|
31080
|
-
for (const pt of visibleData) {
|
|
31081
|
-
if (pt.value < minVal) minVal = pt.value;
|
|
31082
|
-
if (pt.value > maxVal) maxVal = pt.value;
|
|
31083
|
-
}
|
|
31084
|
-
const range = maxVal - minVal || 1;
|
|
31085
|
-
const pad = height * 0.1;
|
|
31086
|
-
ctx.beginPath();
|
|
31087
|
-
ctx.strokeStyle = color;
|
|
31088
|
-
ctx.lineWidth = 2;
|
|
31089
|
-
for (let i = 0; i < visibleData.length; i++) {
|
|
31090
|
-
const x = i / (maxPoints - 1) * width;
|
|
31091
|
-
const y = pad + (maxVal - visibleData[i].value) / range * (height - 2 * pad);
|
|
31092
|
-
if (i === 0) ctx.moveTo(x, y);
|
|
31093
|
-
else ctx.lineTo(x, y);
|
|
31094
|
-
}
|
|
31095
|
-
ctx.stroke();
|
|
31096
|
-
const last = visibleData[visibleData.length - 1];
|
|
31097
|
-
ctx.fillStyle = color;
|
|
31098
|
-
ctx.font = "12px monospace";
|
|
31099
|
-
ctx.fillText(`${last.value.toFixed(2)} ${unit}`, width - 80, 16);
|
|
31100
|
-
}, [visibleData, width, height, color, unit, maxPoints]);
|
|
31101
|
-
return /* @__PURE__ */ jsx(Card, { padding: "sm", className, children: /* @__PURE__ */ jsxs(VStack, { gap: "xs", children: [
|
|
31102
|
-
/* @__PURE__ */ jsx(Typography, { variant: "caption", weight: "bold", children: label }),
|
|
31103
|
-
/* @__PURE__ */ jsx("canvas", { ref: canvasRef, width, height, className: "rounded" })
|
|
31104
|
-
] }) });
|
|
31105
|
-
}
|
|
31106
|
-
var init_SimulationGraph = __esm({
|
|
31107
|
-
"components/game/2d/organisms/SimulationGraph.tsx"() {
|
|
31108
|
-
init_atoms();
|
|
31109
|
-
SimulationGraph.displayName = "SimulationGraph";
|
|
31110
|
-
}
|
|
31111
|
-
});
|
|
31112
30815
|
var GameTemplate;
|
|
31113
30816
|
var init_GameTemplate = __esm({
|
|
31114
30817
|
"components/game/2d/templates/GameTemplate.tsx"() {
|
|
@@ -31372,9 +31075,6 @@ var init_molecules = __esm({
|
|
|
31372
31075
|
init_BuilderBoard();
|
|
31373
31076
|
init_DebuggerBoard();
|
|
31374
31077
|
init_NegotiatorBoard();
|
|
31375
|
-
init_SimulationCanvas();
|
|
31376
|
-
init_SimulationControls();
|
|
31377
|
-
init_SimulationGraph();
|
|
31378
31078
|
init_physicsPresets();
|
|
31379
31079
|
init_GameTemplate();
|
|
31380
31080
|
init_GameShell();
|
|
@@ -31979,13 +31679,13 @@ var init_MapView = __esm({
|
|
|
31979
31679
|
shadowSize: [41, 41]
|
|
31980
31680
|
});
|
|
31981
31681
|
L.Marker.prototype.options.icon = defaultIcon;
|
|
31982
|
-
const { useEffect:
|
|
31682
|
+
const { useEffect: useEffect69, useRef: useRef64, useCallback: useCallback113, useState: useState108 } = React74__default;
|
|
31983
31683
|
const { Typography: Typography2 } = await Promise.resolve().then(() => (init_Typography(), Typography_exports));
|
|
31984
31684
|
const { useEventBus: useEventBus2 } = await Promise.resolve().then(() => (init_useEventBus(), useEventBus_exports));
|
|
31985
31685
|
function MapUpdater({ centerLat, centerLng, zoom }) {
|
|
31986
31686
|
const map = useMap();
|
|
31987
|
-
const prevRef =
|
|
31988
|
-
|
|
31687
|
+
const prevRef = useRef64({ centerLat, centerLng, zoom });
|
|
31688
|
+
useEffect69(() => {
|
|
31989
31689
|
const prev = prevRef.current;
|
|
31990
31690
|
if (prev.centerLat !== centerLat || prev.centerLng !== centerLng || prev.zoom !== zoom) {
|
|
31991
31691
|
map.setView([centerLat, centerLng], zoom);
|
|
@@ -31996,7 +31696,7 @@ var init_MapView = __esm({
|
|
|
31996
31696
|
}
|
|
31997
31697
|
function MapClickHandler({ onMapClick }) {
|
|
31998
31698
|
const map = useMap();
|
|
31999
|
-
|
|
31699
|
+
useEffect69(() => {
|
|
32000
31700
|
if (!onMapClick) return;
|
|
32001
31701
|
const handler = (e) => {
|
|
32002
31702
|
onMapClick(e.latlng.lat, e.latlng.lng);
|
|
@@ -32025,7 +31725,7 @@ var init_MapView = __esm({
|
|
|
32025
31725
|
}) {
|
|
32026
31726
|
const eventBus = useEventBus2();
|
|
32027
31727
|
const [clickedPosition, setClickedPosition] = useState108(null);
|
|
32028
|
-
const handleMapClick =
|
|
31728
|
+
const handleMapClick = useCallback113((lat, lng) => {
|
|
32029
31729
|
if (showClickedPin) {
|
|
32030
31730
|
setClickedPosition({ lat, lng });
|
|
32031
31731
|
}
|
|
@@ -32034,7 +31734,7 @@ var init_MapView = __esm({
|
|
|
32034
31734
|
eventBus.emit(`UI:${mapClickEvent}`, { latitude: lat, longitude: lng });
|
|
32035
31735
|
}
|
|
32036
31736
|
}, [onMapClick, mapClickEvent, eventBus, showClickedPin]);
|
|
32037
|
-
const handleMarkerClick =
|
|
31737
|
+
const handleMarkerClick = useCallback113((marker) => {
|
|
32038
31738
|
onMarkerClick?.(marker);
|
|
32039
31739
|
if (markerClickEvent) {
|
|
32040
31740
|
eventBus.emit(`UI:${markerClickEvent}`, { ...marker });
|
|
@@ -47985,6 +47685,7 @@ var init_component_registry_generated = __esm({
|
|
|
47985
47685
|
init_Navigation();
|
|
47986
47686
|
init_NegotiatorBoard();
|
|
47987
47687
|
init_NumberStepper();
|
|
47688
|
+
init_ObjectRulePanel();
|
|
47988
47689
|
init_OptionConstraintGroup();
|
|
47989
47690
|
init_OrbitalVisualization();
|
|
47990
47691
|
init_Overlay();
|
|
@@ -48030,7 +47731,6 @@ var init_component_registry_generated = __esm({
|
|
|
48030
47731
|
init_Sidebar();
|
|
48031
47732
|
init_SignaturePad();
|
|
48032
47733
|
init_SimpleGrid();
|
|
48033
|
-
init_SimulationCanvas();
|
|
48034
47734
|
init_SimulatorBoard();
|
|
48035
47735
|
init_Skeleton();
|
|
48036
47736
|
init_SocialProof();
|
|
@@ -48048,6 +47748,7 @@ var init_component_registry_generated = __esm({
|
|
|
48048
47748
|
init_StateArchitectBoard();
|
|
48049
47749
|
init_StateGraph();
|
|
48050
47750
|
init_StateIndicator();
|
|
47751
|
+
init_StateJsonView();
|
|
48051
47752
|
init_StateMachineView();
|
|
48052
47753
|
init_StatsGrid();
|
|
48053
47754
|
init_StatsOrganism();
|
|
@@ -48094,6 +47795,7 @@ var init_component_registry_generated = __esm({
|
|
|
48094
47795
|
init_Typography();
|
|
48095
47796
|
init_UISlotRenderer();
|
|
48096
47797
|
init_UploadDropZone();
|
|
47798
|
+
init_VariablePanel();
|
|
48097
47799
|
init_VersionDiff();
|
|
48098
47800
|
init_ViolationAlert();
|
|
48099
47801
|
init_VoteStack();
|
|
@@ -48294,6 +47996,7 @@ var init_component_registry_generated = __esm({
|
|
|
48294
47996
|
"Navigation": Navigation,
|
|
48295
47997
|
"NegotiatorBoard": NegotiatorBoard,
|
|
48296
47998
|
"NumberStepper": NumberStepper,
|
|
47999
|
+
"ObjectRulePanel": ObjectRulePanel,
|
|
48297
48000
|
"OptionConstraintGroup": OptionConstraintGroup,
|
|
48298
48001
|
"OrbitalVisualization": OrbitalVisualization,
|
|
48299
48002
|
"Overlay": Overlay,
|
|
@@ -48339,7 +48042,6 @@ var init_component_registry_generated = __esm({
|
|
|
48339
48042
|
"Sidebar": Sidebar,
|
|
48340
48043
|
"SignaturePad": SignaturePad,
|
|
48341
48044
|
"SimpleGrid": SimpleGrid,
|
|
48342
|
-
"SimulationCanvas": SimulationCanvas,
|
|
48343
48045
|
"SimulatorBoard": SimulatorBoard,
|
|
48344
48046
|
"Skeleton": Skeleton,
|
|
48345
48047
|
"SocialProof": SocialProof,
|
|
@@ -48360,6 +48062,7 @@ var init_component_registry_generated = __esm({
|
|
|
48360
48062
|
"StateArchitectBoard": StateArchitectBoard,
|
|
48361
48063
|
"StateGraph": StateGraph,
|
|
48362
48064
|
"StateIndicator": StateIndicator,
|
|
48065
|
+
"StateJsonView": StateJsonView,
|
|
48363
48066
|
"StateMachineView": StateMachineView,
|
|
48364
48067
|
"StatsGrid": StatsGrid,
|
|
48365
48068
|
"StatsOrganism": StatsOrganism,
|
|
@@ -48407,6 +48110,7 @@ var init_component_registry_generated = __esm({
|
|
|
48407
48110
|
"UISlotRenderer": UISlotRenderer,
|
|
48408
48111
|
"UploadDropZone": UploadDropZone,
|
|
48409
48112
|
"VStack": VStack,
|
|
48113
|
+
"VariablePanel": VariablePanel,
|
|
48410
48114
|
"VersionDiff": VersionDiff,
|
|
48411
48115
|
"ViolationAlert": ViolationAlert,
|
|
48412
48116
|
"VoteStack": VoteStack,
|
|
@@ -51650,4 +51354,4 @@ function useGitHubBranches(owner, repo, enabled = true) {
|
|
|
51650
51354
|
});
|
|
51651
51355
|
}
|
|
51652
51356
|
|
|
51653
|
-
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,
|
|
51357
|
+
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, 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 };
|