@almadar/ui 2.31.0 → 2.33.2
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 +1049 -1086
- package/dist/avl/index.d.cts +352 -78
- package/dist/avl/index.d.ts +18 -3
- package/dist/avl/index.js +1029 -1086
- package/dist/components/atoms/index.d.ts +0 -1
- package/dist/components/index.cjs +1146 -1847
- package/dist/components/index.js +266 -952
- package/dist/components/molecules/avl/AvlBackwardEdge.d.ts +8 -0
- package/dist/components/molecules/avl/AvlBindingEdge.d.ts +9 -0
- package/dist/components/molecules/avl/AvlEventWireEdge.d.ts +14 -0
- package/dist/components/molecules/avl/AvlOrbitalNode.d.ts +12 -0
- package/dist/components/molecules/avl/AvlPageEdge.d.ts +8 -0
- package/dist/components/molecules/avl/AvlTransitionEdge.d.ts +16 -0
- package/dist/components/molecules/avl/BehaviorView.d.ts +12 -0
- package/dist/components/molecules/avl/DetailView.d.ts +13 -0
- package/dist/components/molecules/avl/MiniStateMachine.d.ts +14 -0
- package/dist/components/molecules/avl/ModuleCard.d.ts +14 -0
- package/dist/components/molecules/avl/SystemNode.d.ts +12 -0
- package/dist/components/molecules/avl/avl-canvas-types.d.ts +36 -0
- package/dist/components/molecules/avl/avl-elk-layout.d.ts +55 -0
- package/dist/components/molecules/avl/avl-flow-converter.d.ts +17 -0
- package/dist/components/molecules/avl/avl-story-schemas.d.ts +34 -0
- package/dist/components/molecules/avl/avl-zoom-band.d.ts +19 -0
- package/dist/components/molecules/avl/index.d.ts +15 -0
- package/dist/components/molecules/index.d.ts +0 -1
- package/dist/components/organisms/avl/AvlCosmicZoom.d.ts +10 -7
- package/dist/components/organisms/avl/FlowCanvas.d.ts +32 -0
- package/dist/components/organisms/avl/ZoomBreadcrumb.d.ts +16 -0
- package/dist/components/organisms/avl/ZoomLegend.d.ts +10 -0
- package/dist/components/organisms/avl/index.d.ts +5 -2
- package/dist/hooks/useUISlots.d.ts +2 -0
- package/dist/providers/index.cjs +148 -149
- package/dist/providers/index.js +39 -40
- package/dist/runtime/index.cjs +1045 -1020
- package/dist/runtime/index.js +260 -235
- package/package.json +2 -6
- package/dist/components/atoms/flow/FlowLabel.d.ts +0 -23
- package/dist/components/atoms/flow/FlowMinimap.d.ts +0 -28
- package/dist/components/atoms/flow/FlowNodeShell.d.ts +0 -25
- package/dist/components/atoms/flow/FlowPort.d.ts +0 -26
- package/dist/components/atoms/flow/FlowWire.d.ts +0 -39
- package/dist/components/atoms/flow/index.d.ts +0 -13
- package/dist/components/molecules/flow/BehaviorNode.d.ts +0 -28
- package/dist/components/molecules/flow/EffectNode.d.ts +0 -26
- package/dist/components/molecules/flow/EventWireEdge.d.ts +0 -23
- package/dist/components/molecules/flow/ExprNode.d.ts +0 -27
- package/dist/components/molecules/flow/FlowStateNode.d.ts +0 -18
- package/dist/components/molecules/flow/NodePalette.d.ts +0 -36
- package/dist/components/molecules/flow/OrbitalNode.d.ts +0 -31
- package/dist/components/molecules/flow/TransitionEdge.d.ts +0 -26
- package/dist/components/molecules/flow/index.d.ts +0 -8
- package/dist/components/molecules/svg/AIGenerates.d.ts +0 -7
- package/dist/components/molecules/svg/ClosedCircuit.d.ts +0 -7
- package/dist/components/molecules/svg/CommunityOwnership.d.ts +0 -7
- package/dist/components/molecules/svg/CompileAnywhere.d.ts +0 -7
- package/dist/components/molecules/svg/ComposableModels.d.ts +0 -7
- package/dist/components/molecules/svg/DescribeProveDeploy.d.ts +0 -7
- package/dist/components/molecules/svg/DomainGrid.d.ts +0 -7
- package/dist/components/molecules/svg/EventBus.d.ts +0 -7
- package/dist/components/molecules/svg/OrbitalUnit.d.ts +0 -7
- package/dist/components/molecules/svg/PlanVerifyRemember.d.ts +0 -7
- package/dist/components/molecules/svg/ProveCorrect.d.ts +0 -7
- package/dist/components/molecules/svg/ServiceLayers.d.ts +0 -7
- package/dist/components/molecules/svg/SharedReality.d.ts +0 -7
- package/dist/components/molecules/svg/StandardLibrary.d.ts +0 -7
- package/dist/components/molecules/svg/StateMachine.d.ts +0 -7
- package/dist/components/molecules/svg/WorldModel.d.ts +0 -7
- package/dist/components/molecules/svg/index.d.ts +0 -16
- package/dist/components/organisms/avl/AvlApplicationScene.d.ts +0 -17
- package/dist/components/organisms/avl/AvlOrbitalScene.d.ts +0 -21
- package/dist/flow/index.cjs +0 -3832
- package/dist/flow/index.d.cts +0 -367
- package/dist/flow/index.d.ts +0 -10
- package/dist/flow/index.js +0 -3793
- package/dist/illustrations/index.cjs +0 -7651
- package/dist/illustrations/index.d.cts +0 -544
- package/dist/illustrations/index.d.ts +0 -59
- package/dist/illustrations/index.js +0 -7594
package/dist/components/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import * as
|
|
2
|
-
import
|
|
1
|
+
import * as React90 from 'react';
|
|
2
|
+
import React90__default, { useCallback, createContext, useState, useRef, useEffect, useLayoutEffect, lazy, useContext, useMemo, useId, Suspense, useSyncExternalStore } from 'react';
|
|
3
3
|
import { clsx } from 'clsx';
|
|
4
4
|
import { twMerge } from 'tailwind-merge';
|
|
5
5
|
import * as LucideIcons from 'lucide-react';
|
|
@@ -17,7 +17,6 @@ import dark from 'react-syntax-highlighter/dist/esm/styles/prism/vsc-dark-plus';
|
|
|
17
17
|
import { MapContainer, TileLayer, Marker, Popup, useMap } from 'react-leaflet';
|
|
18
18
|
import L from 'leaflet';
|
|
19
19
|
import 'leaflet/dist/leaflet.css';
|
|
20
|
-
import { Handle, Position, getBezierPath, BaseEdge, EdgeLabelRenderer } from '@xyflow/react';
|
|
21
20
|
import { useUISlots } from '@almadar/ui/context';
|
|
22
21
|
import { getComponentForPattern as getComponentForPattern$1 } from '@almadar/patterns';
|
|
23
22
|
import { Link, Outlet, useLocation } from 'react-router-dom';
|
|
@@ -270,7 +269,7 @@ function resolveIconProp(value, sizeClass) {
|
|
|
270
269
|
const IconComp = value;
|
|
271
270
|
return /* @__PURE__ */ jsx(IconComp, { className: sizeClass });
|
|
272
271
|
}
|
|
273
|
-
if (
|
|
272
|
+
if (React90__default.isValidElement(value)) {
|
|
274
273
|
return value;
|
|
275
274
|
}
|
|
276
275
|
if (typeof value === "object" && value !== null && "render" in value) {
|
|
@@ -279,7 +278,7 @@ function resolveIconProp(value, sizeClass) {
|
|
|
279
278
|
}
|
|
280
279
|
return value;
|
|
281
280
|
}
|
|
282
|
-
var Button =
|
|
281
|
+
var Button = React90__default.forwardRef(
|
|
283
282
|
({
|
|
284
283
|
className,
|
|
285
284
|
variant = "primary",
|
|
@@ -338,7 +337,7 @@ var Button = React91__default.forwardRef(
|
|
|
338
337
|
}
|
|
339
338
|
);
|
|
340
339
|
Button.displayName = "Button";
|
|
341
|
-
var Input =
|
|
340
|
+
var Input = React90__default.forwardRef(
|
|
342
341
|
({
|
|
343
342
|
className,
|
|
344
343
|
inputType,
|
|
@@ -450,7 +449,7 @@ var Input = React91__default.forwardRef(
|
|
|
450
449
|
}
|
|
451
450
|
);
|
|
452
451
|
Input.displayName = "Input";
|
|
453
|
-
var Label =
|
|
452
|
+
var Label = React90__default.forwardRef(
|
|
454
453
|
({ className, required, children, ...props }, ref) => {
|
|
455
454
|
return /* @__PURE__ */ jsxs(
|
|
456
455
|
"label",
|
|
@@ -470,7 +469,7 @@ var Label = React91__default.forwardRef(
|
|
|
470
469
|
}
|
|
471
470
|
);
|
|
472
471
|
Label.displayName = "Label";
|
|
473
|
-
var Textarea =
|
|
472
|
+
var Textarea = React90__default.forwardRef(
|
|
474
473
|
({ className, error, ...props }, ref) => {
|
|
475
474
|
return /* @__PURE__ */ jsx(
|
|
476
475
|
"textarea",
|
|
@@ -493,7 +492,7 @@ var Textarea = React91__default.forwardRef(
|
|
|
493
492
|
}
|
|
494
493
|
);
|
|
495
494
|
Textarea.displayName = "Textarea";
|
|
496
|
-
var Select =
|
|
495
|
+
var Select = React90__default.forwardRef(
|
|
497
496
|
({ className, options, placeholder, error, ...props }, ref) => {
|
|
498
497
|
return /* @__PURE__ */ jsxs("div", { className: "relative", children: [
|
|
499
498
|
/* @__PURE__ */ jsxs(
|
|
@@ -529,7 +528,7 @@ var Select = React91__default.forwardRef(
|
|
|
529
528
|
}
|
|
530
529
|
);
|
|
531
530
|
Select.displayName = "Select";
|
|
532
|
-
var Checkbox =
|
|
531
|
+
var Checkbox = React90__default.forwardRef(
|
|
533
532
|
({ className, label, id, ...props }, ref) => {
|
|
534
533
|
const inputId = id || `checkbox-${Math.random().toString(36).substr(2, 9)}`;
|
|
535
534
|
return /* @__PURE__ */ jsxs("div", { className: "flex items-center", children: [
|
|
@@ -605,7 +604,7 @@ var shadowStyles = {
|
|
|
605
604
|
md: "shadow",
|
|
606
605
|
lg: "shadow-lg"
|
|
607
606
|
};
|
|
608
|
-
var Card =
|
|
607
|
+
var Card = React90__default.forwardRef(
|
|
609
608
|
({
|
|
610
609
|
className,
|
|
611
610
|
variant = "bordered",
|
|
@@ -641,9 +640,9 @@ var Card = React91__default.forwardRef(
|
|
|
641
640
|
}
|
|
642
641
|
);
|
|
643
642
|
Card.displayName = "Card";
|
|
644
|
-
var CardHeader =
|
|
643
|
+
var CardHeader = React90__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("mb-4", className), ...props }));
|
|
645
644
|
CardHeader.displayName = "CardHeader";
|
|
646
|
-
var CardTitle =
|
|
645
|
+
var CardTitle = React90__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
647
646
|
"h3",
|
|
648
647
|
{
|
|
649
648
|
ref,
|
|
@@ -656,11 +655,11 @@ var CardTitle = React91__default.forwardRef(({ className, ...props }, ref) => /*
|
|
|
656
655
|
}
|
|
657
656
|
));
|
|
658
657
|
CardTitle.displayName = "CardTitle";
|
|
659
|
-
var CardContent =
|
|
658
|
+
var CardContent = React90__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("", className), ...props }));
|
|
660
659
|
CardContent.displayName = "CardContent";
|
|
661
660
|
var CardBody = CardContent;
|
|
662
661
|
CardBody.displayName = "CardBody";
|
|
663
|
-
var CardFooter =
|
|
662
|
+
var CardFooter = React90__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
664
663
|
"div",
|
|
665
664
|
{
|
|
666
665
|
ref,
|
|
@@ -706,7 +705,7 @@ var sizeStyles2 = {
|
|
|
706
705
|
md: "px-2.5 py-1 text-sm",
|
|
707
706
|
lg: "px-3 py-1.5 text-base"
|
|
708
707
|
};
|
|
709
|
-
var Badge =
|
|
708
|
+
var Badge = React90__default.forwardRef(
|
|
710
709
|
({ className, variant = "default", size = "sm", amount, label, icon, children, ...props }, ref) => {
|
|
711
710
|
const iconSizes2 = { sm: "w-3 h-3", md: "w-3.5 h-3.5", lg: "w-4 h-4" };
|
|
712
711
|
const resolvedIcon = typeof icon === "string" ? (() => {
|
|
@@ -739,7 +738,7 @@ var sizeStyles3 = {
|
|
|
739
738
|
md: "h-6 w-6",
|
|
740
739
|
lg: "h-8 w-8"
|
|
741
740
|
};
|
|
742
|
-
var Spinner =
|
|
741
|
+
var Spinner = React90__default.forwardRef(
|
|
743
742
|
({ className, size = "md", ...props }, ref) => {
|
|
744
743
|
return /* @__PURE__ */ jsx(
|
|
745
744
|
"div",
|
|
@@ -1004,7 +1003,7 @@ var positionStyles = {
|
|
|
1004
1003
|
fixed: "fixed",
|
|
1005
1004
|
sticky: "sticky"
|
|
1006
1005
|
};
|
|
1007
|
-
var Box =
|
|
1006
|
+
var Box = React90__default.forwardRef(
|
|
1008
1007
|
({
|
|
1009
1008
|
padding,
|
|
1010
1009
|
paddingX,
|
|
@@ -1351,7 +1350,7 @@ var ProgressBar = ({
|
|
|
1351
1350
|
return null;
|
|
1352
1351
|
};
|
|
1353
1352
|
ProgressBar.displayName = "ProgressBar";
|
|
1354
|
-
var Radio =
|
|
1353
|
+
var Radio = React90__default.forwardRef(
|
|
1355
1354
|
({
|
|
1356
1355
|
label,
|
|
1357
1356
|
helperText,
|
|
@@ -1455,7 +1454,7 @@ var Radio = React91__default.forwardRef(
|
|
|
1455
1454
|
}
|
|
1456
1455
|
);
|
|
1457
1456
|
Radio.displayName = "Radio";
|
|
1458
|
-
var Switch =
|
|
1457
|
+
var Switch = React90.forwardRef(
|
|
1459
1458
|
({
|
|
1460
1459
|
checked,
|
|
1461
1460
|
defaultChecked = false,
|
|
@@ -1466,10 +1465,10 @@ var Switch = React91.forwardRef(
|
|
|
1466
1465
|
name,
|
|
1467
1466
|
className
|
|
1468
1467
|
}, ref) => {
|
|
1469
|
-
const [isChecked, setIsChecked] =
|
|
1468
|
+
const [isChecked, setIsChecked] = React90.useState(
|
|
1470
1469
|
checked !== void 0 ? checked : defaultChecked
|
|
1471
1470
|
);
|
|
1472
|
-
|
|
1471
|
+
React90.useEffect(() => {
|
|
1473
1472
|
if (checked !== void 0) {
|
|
1474
1473
|
setIsChecked(checked);
|
|
1475
1474
|
}
|
|
@@ -1775,7 +1774,7 @@ var Typography = ({
|
|
|
1775
1774
|
align,
|
|
1776
1775
|
weight,
|
|
1777
1776
|
size,
|
|
1778
|
-
truncate
|
|
1777
|
+
truncate = false,
|
|
1779
1778
|
overflow,
|
|
1780
1779
|
as,
|
|
1781
1780
|
id,
|
|
@@ -1797,7 +1796,7 @@ var Typography = ({
|
|
|
1797
1796
|
weight && weightStyles[weight],
|
|
1798
1797
|
size && typographySizeStyles[size],
|
|
1799
1798
|
align && `text-${align}`,
|
|
1800
|
-
|
|
1799
|
+
truncate && "truncate overflow-hidden text-ellipsis",
|
|
1801
1800
|
overflow && overflowStyles2[overflow],
|
|
1802
1801
|
className
|
|
1803
1802
|
),
|
|
@@ -2171,10 +2170,11 @@ var Overlay = ({
|
|
|
2171
2170
|
"div",
|
|
2172
2171
|
{
|
|
2173
2172
|
className: cn(
|
|
2174
|
-
"fixed inset-0 z-40
|
|
2173
|
+
"fixed inset-0 z-40",
|
|
2175
2174
|
blur && "backdrop-blur-sm",
|
|
2176
2175
|
className
|
|
2177
2176
|
),
|
|
2177
|
+
style: { backgroundColor: "rgba(0, 0, 0, 0.6)" },
|
|
2178
2178
|
onClick: action || onClick ? handleClick : void 0,
|
|
2179
2179
|
"aria-hidden": "true"
|
|
2180
2180
|
}
|
|
@@ -2263,8 +2263,8 @@ var LawReferenceTooltip = ({
|
|
|
2263
2263
|
position = "top",
|
|
2264
2264
|
className
|
|
2265
2265
|
}) => {
|
|
2266
|
-
const [isVisible, setIsVisible] =
|
|
2267
|
-
const timeoutRef =
|
|
2266
|
+
const [isVisible, setIsVisible] = React90__default.useState(false);
|
|
2267
|
+
const timeoutRef = React90__default.useRef(null);
|
|
2268
2268
|
const handleMouseEnter = () => {
|
|
2269
2269
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
2270
2270
|
timeoutRef.current = setTimeout(() => setIsVisible(true), 200);
|
|
@@ -2273,7 +2273,7 @@ var LawReferenceTooltip = ({
|
|
|
2273
2273
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
2274
2274
|
setIsVisible(false);
|
|
2275
2275
|
};
|
|
2276
|
-
|
|
2276
|
+
React90__default.useEffect(() => {
|
|
2277
2277
|
return () => {
|
|
2278
2278
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
2279
2279
|
};
|
|
@@ -2461,7 +2461,7 @@ var sizeStyles5 = {
|
|
|
2461
2461
|
md: "w-2.5 h-2.5",
|
|
2462
2462
|
lg: "w-3 h-3"
|
|
2463
2463
|
};
|
|
2464
|
-
var StatusDot =
|
|
2464
|
+
var StatusDot = React90__default.forwardRef(
|
|
2465
2465
|
({ className, status = "offline", pulse = false, size = "md", label, ...props }, ref) => {
|
|
2466
2466
|
return /* @__PURE__ */ jsx(
|
|
2467
2467
|
"span",
|
|
@@ -2508,7 +2508,7 @@ var iconMap = {
|
|
|
2508
2508
|
down: TrendingDown,
|
|
2509
2509
|
flat: ArrowRight
|
|
2510
2510
|
};
|
|
2511
|
-
var TrendIndicator =
|
|
2511
|
+
var TrendIndicator = React90__default.forwardRef(
|
|
2512
2512
|
({
|
|
2513
2513
|
className,
|
|
2514
2514
|
value,
|
|
@@ -2567,7 +2567,7 @@ var thumbSizes = {
|
|
|
2567
2567
|
md: "w-4 h-4",
|
|
2568
2568
|
lg: "w-5 h-5"
|
|
2569
2569
|
};
|
|
2570
|
-
var RangeSlider =
|
|
2570
|
+
var RangeSlider = React90__default.forwardRef(
|
|
2571
2571
|
({
|
|
2572
2572
|
className,
|
|
2573
2573
|
min = 0,
|
|
@@ -3099,7 +3099,7 @@ var paddingClasses = {
|
|
|
3099
3099
|
md: "py-16",
|
|
3100
3100
|
lg: "py-24"
|
|
3101
3101
|
};
|
|
3102
|
-
var ContentSection =
|
|
3102
|
+
var ContentSection = React90__default.forwardRef(
|
|
3103
3103
|
({ children, background = "default", padding = "lg", id, className }, ref) => {
|
|
3104
3104
|
return /* @__PURE__ */ jsx(
|
|
3105
3105
|
Box,
|
|
@@ -3620,7 +3620,7 @@ var animatedStyles = {
|
|
|
3620
3620
|
"scale-up": { opacity: 1, transform: "scale(1) translateY(0)" },
|
|
3621
3621
|
"none": {}
|
|
3622
3622
|
};
|
|
3623
|
-
var AnimatedReveal =
|
|
3623
|
+
var AnimatedReveal = React90__default.forwardRef(
|
|
3624
3624
|
({
|
|
3625
3625
|
trigger = "scroll",
|
|
3626
3626
|
animation = "fade-up",
|
|
@@ -3773,7 +3773,7 @@ function applyMorphAnimation(container, animate, duration, delay, easing) {
|
|
|
3773
3773
|
el.style.opacity = animate ? "1" : "0";
|
|
3774
3774
|
});
|
|
3775
3775
|
}
|
|
3776
|
-
var AnimatedGraphic =
|
|
3776
|
+
var AnimatedGraphic = React90__default.forwardRef(
|
|
3777
3777
|
({
|
|
3778
3778
|
src,
|
|
3779
3779
|
svgContent,
|
|
@@ -3796,7 +3796,7 @@ var AnimatedGraphic = React91__default.forwardRef(
|
|
|
3796
3796
|
const fetchedSvg = useFetchedSvg(svgContent ? void 0 : src);
|
|
3797
3797
|
const resolvedSvg = svgContent ?? fetchedSvg;
|
|
3798
3798
|
const prevAnimateRef = useRef(animate);
|
|
3799
|
-
const setRef =
|
|
3799
|
+
const setRef = React90__default.useCallback(
|
|
3800
3800
|
(node) => {
|
|
3801
3801
|
containerRef.current = node;
|
|
3802
3802
|
if (typeof ref === "function") ref(node);
|
|
@@ -3967,9 +3967,9 @@ function ScoreDisplay({
|
|
|
3967
3967
|
...rest
|
|
3968
3968
|
}) {
|
|
3969
3969
|
const resolvedValue = typeof value === "number" && !Number.isNaN(value) ? value : typeof rest.score === "number" && !Number.isNaN(rest.score) ? rest.score : 0;
|
|
3970
|
-
const [displayValue, setDisplayValue] =
|
|
3971
|
-
const [isAnimating, setIsAnimating] =
|
|
3972
|
-
|
|
3970
|
+
const [displayValue, setDisplayValue] = React90.useState(resolvedValue);
|
|
3971
|
+
const [isAnimating, setIsAnimating] = React90.useState(false);
|
|
3972
|
+
React90.useEffect(() => {
|
|
3973
3973
|
if (!animated || displayValue === resolvedValue) {
|
|
3974
3974
|
setDisplayValue(resolvedValue);
|
|
3975
3975
|
return;
|
|
@@ -4042,9 +4042,9 @@ function ControlButton({
|
|
|
4042
4042
|
className
|
|
4043
4043
|
}) {
|
|
4044
4044
|
const eventBus = useEventBus();
|
|
4045
|
-
const [isPressed, setIsPressed] =
|
|
4045
|
+
const [isPressed, setIsPressed] = React90.useState(false);
|
|
4046
4046
|
const actualPressed = pressed ?? isPressed;
|
|
4047
|
-
const handlePointerDown =
|
|
4047
|
+
const handlePointerDown = React90.useCallback(
|
|
4048
4048
|
(e) => {
|
|
4049
4049
|
e.preventDefault();
|
|
4050
4050
|
if (disabled) return;
|
|
@@ -4054,7 +4054,7 @@ function ControlButton({
|
|
|
4054
4054
|
},
|
|
4055
4055
|
[disabled, pressEvent, eventBus, onPress]
|
|
4056
4056
|
);
|
|
4057
|
-
const handlePointerUp =
|
|
4057
|
+
const handlePointerUp = React90.useCallback(
|
|
4058
4058
|
(e) => {
|
|
4059
4059
|
e.preventDefault();
|
|
4060
4060
|
if (disabled) return;
|
|
@@ -4064,7 +4064,7 @@ function ControlButton({
|
|
|
4064
4064
|
},
|
|
4065
4065
|
[disabled, releaseEvent, eventBus, onRelease]
|
|
4066
4066
|
);
|
|
4067
|
-
const handlePointerLeave =
|
|
4067
|
+
const handlePointerLeave = React90.useCallback(
|
|
4068
4068
|
(e) => {
|
|
4069
4069
|
if (isPressed) {
|
|
4070
4070
|
setIsPressed(false);
|
|
@@ -4890,9 +4890,9 @@ function MiniMap({
|
|
|
4890
4890
|
viewportRect,
|
|
4891
4891
|
className
|
|
4892
4892
|
}) {
|
|
4893
|
-
const canvasRef =
|
|
4894
|
-
const frameRef =
|
|
4895
|
-
|
|
4893
|
+
const canvasRef = React90.useRef(null);
|
|
4894
|
+
const frameRef = React90.useRef(0);
|
|
4895
|
+
React90.useEffect(() => {
|
|
4896
4896
|
const canvas = canvasRef.current;
|
|
4897
4897
|
if (!canvas) return;
|
|
4898
4898
|
const ctx = canvas.getContext("2d");
|
|
@@ -4967,225 +4967,6 @@ function MiniMap({
|
|
|
4967
4967
|
);
|
|
4968
4968
|
}
|
|
4969
4969
|
MiniMap.displayName = "MiniMap";
|
|
4970
|
-
var FlowPort = ({
|
|
4971
|
-
direction,
|
|
4972
|
-
portType,
|
|
4973
|
-
label,
|
|
4974
|
-
connected = false,
|
|
4975
|
-
compatible = false,
|
|
4976
|
-
className
|
|
4977
|
-
}) => {
|
|
4978
|
-
const dot = /* @__PURE__ */ jsx(
|
|
4979
|
-
Box,
|
|
4980
|
-
{
|
|
4981
|
-
className: cn(
|
|
4982
|
-
"w-3 h-3 rounded-full shrink-0 transition-all duration-150",
|
|
4983
|
-
connected ? "bg-primary" : "bg-transparent border-[length:var(--border-width)] border-muted-foreground",
|
|
4984
|
-
compatible && "ring-2 ring-success ring-offset-1 ring-offset-background",
|
|
4985
|
-
className
|
|
4986
|
-
),
|
|
4987
|
-
role: "presentation",
|
|
4988
|
-
"aria-label": `${direction} port: ${portType}`
|
|
4989
|
-
}
|
|
4990
|
-
);
|
|
4991
|
-
if (!label) return dot;
|
|
4992
|
-
return /* @__PURE__ */ jsxs(HStack, { gap: "xs", align: "center", className: cn(direction === "in" ? "flex-row-reverse" : "flex-row"), children: [
|
|
4993
|
-
dot,
|
|
4994
|
-
/* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground select-none whitespace-nowrap", children: label })
|
|
4995
|
-
] });
|
|
4996
|
-
};
|
|
4997
|
-
FlowPort.displayName = "FlowPort";
|
|
4998
|
-
var FlowNodeShell = ({
|
|
4999
|
-
selected = false,
|
|
5000
|
-
warning = false,
|
|
5001
|
-
nodeType,
|
|
5002
|
-
headerColor = "var(--color-primary)",
|
|
5003
|
-
children,
|
|
5004
|
-
className
|
|
5005
|
-
}) => /* @__PURE__ */ jsxs(
|
|
5006
|
-
Box,
|
|
5007
|
-
{
|
|
5008
|
-
className: cn(
|
|
5009
|
-
"rounded-md overflow-hidden bg-card",
|
|
5010
|
-
"border-[length:var(--border-width)] border-border",
|
|
5011
|
-
"shadow-sm transition-shadow duration-150 min-w-[140px]",
|
|
5012
|
-
selected && "ring-2 ring-primary",
|
|
5013
|
-
warning && !selected && "ring-2 ring-dashed ring-warning",
|
|
5014
|
-
className
|
|
5015
|
-
),
|
|
5016
|
-
children: [
|
|
5017
|
-
/* @__PURE__ */ jsx(
|
|
5018
|
-
Box,
|
|
5019
|
-
{
|
|
5020
|
-
className: "flex items-center px-2",
|
|
5021
|
-
style: { backgroundColor: headerColor, height: 8 },
|
|
5022
|
-
children: nodeType && /* @__PURE__ */ jsx(
|
|
5023
|
-
Typography,
|
|
5024
|
-
{
|
|
5025
|
-
variant: "caption",
|
|
5026
|
-
className: "text-white/90 font-semibold select-none leading-none sr-only",
|
|
5027
|
-
children: nodeType
|
|
5028
|
-
}
|
|
5029
|
-
)
|
|
5030
|
-
}
|
|
5031
|
-
),
|
|
5032
|
-
nodeType && /* @__PURE__ */ jsx(Box, { className: "px-2 pt-1.5 pb-0.5", children: /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground font-semibold uppercase tracking-wider select-none", children: nodeType }) }),
|
|
5033
|
-
/* @__PURE__ */ jsx(Box, { className: "px-2 pb-2", children })
|
|
5034
|
-
]
|
|
5035
|
-
}
|
|
5036
|
-
);
|
|
5037
|
-
FlowNodeShell.displayName = "FlowNodeShell";
|
|
5038
|
-
var variantToBadge = {
|
|
5039
|
-
default: "neutral",
|
|
5040
|
-
primary: "primary",
|
|
5041
|
-
warning: "warning",
|
|
5042
|
-
error: "danger"
|
|
5043
|
-
};
|
|
5044
|
-
var FlowLabel = ({
|
|
5045
|
-
text,
|
|
5046
|
-
truncate: truncate2,
|
|
5047
|
-
variant = "default",
|
|
5048
|
-
className
|
|
5049
|
-
}) => {
|
|
5050
|
-
const isTruncated = truncate2 != null && text.length > truncate2;
|
|
5051
|
-
const display = isTruncated ? `${text.slice(0, truncate2)}...` : text;
|
|
5052
|
-
return /* @__PURE__ */ jsx(
|
|
5053
|
-
Badge,
|
|
5054
|
-
{
|
|
5055
|
-
variant: variantToBadge[variant],
|
|
5056
|
-
size: "sm",
|
|
5057
|
-
className: cn("max-w-[180px] cursor-default", className),
|
|
5058
|
-
title: isTruncated ? text : void 0,
|
|
5059
|
-
children: display
|
|
5060
|
-
}
|
|
5061
|
-
);
|
|
5062
|
-
};
|
|
5063
|
-
FlowLabel.displayName = "FlowLabel";
|
|
5064
|
-
|
|
5065
|
-
// components/atoms/avl/types.ts
|
|
5066
|
-
var AVL_OPERATOR_COLORS = {
|
|
5067
|
-
arithmetic: "#4A90D9",
|
|
5068
|
-
comparison: "#E8913A",
|
|
5069
|
-
logic: "#9B59B6",
|
|
5070
|
-
string: "#27AE60",
|
|
5071
|
-
collection: "#1ABC9C",
|
|
5072
|
-
time: "#F39C12",
|
|
5073
|
-
control: "#E74C3C",
|
|
5074
|
-
async: "#E91E8F"
|
|
5075
|
-
};
|
|
5076
|
-
var STATE_COLORS = {
|
|
5077
|
-
initial: { fill: "#22C55E1F", border: "#16A34A" },
|
|
5078
|
-
terminal: { fill: "#EF44441F", border: "#DC2626" },
|
|
5079
|
-
hub: { fill: "#3B82F61F", border: "#2563EB" },
|
|
5080
|
-
error: { fill: "#F59E0B1F", border: "#D97706" },
|
|
5081
|
-
default: { fill: "#6B72801F", border: "#4B5563" }
|
|
5082
|
-
};
|
|
5083
|
-
var EFFECT_CATEGORY_COLORS = {
|
|
5084
|
-
ui: { color: "#8B5CF6", bg: "#8B5CF614" },
|
|
5085
|
-
data: { color: "#3B82F6", bg: "#3B82F614" },
|
|
5086
|
-
communication: { color: "#F97316", bg: "#F9731614" },
|
|
5087
|
-
lifecycle: { color: "#10B981", bg: "#10B98114" },
|
|
5088
|
-
control: { color: "#6B7280", bg: "#6B728014" }
|
|
5089
|
-
};
|
|
5090
|
-
var EFFECT_TYPE_TO_CATEGORY = {
|
|
5091
|
-
"render-ui": "ui",
|
|
5092
|
-
"navigate": "ui",
|
|
5093
|
-
"set": "data",
|
|
5094
|
-
"persist": "data",
|
|
5095
|
-
"fetch": "data",
|
|
5096
|
-
"emit": "communication",
|
|
5097
|
-
"notify": "communication",
|
|
5098
|
-
"call-service": "communication",
|
|
5099
|
-
"spawn": "lifecycle",
|
|
5100
|
-
"despawn": "lifecycle",
|
|
5101
|
-
"do": "control",
|
|
5102
|
-
"if": "control",
|
|
5103
|
-
"log": "control"
|
|
5104
|
-
};
|
|
5105
|
-
var CONNECTION_COLORS = {
|
|
5106
|
-
forward: { color: "#1E293B", width: 2, dash: "none" },
|
|
5107
|
-
backward: { color: "#94A3B8", width: 1.5, dash: "6 3" },
|
|
5108
|
-
emitListen: { color: "#F97316", width: 1.5, dash: "4 3" }
|
|
5109
|
-
};
|
|
5110
|
-
var wireTypeToColor = {
|
|
5111
|
-
transition: CONNECTION_COLORS.forward.color,
|
|
5112
|
-
event: CONNECTION_COLORS.emitListen.color,
|
|
5113
|
-
data: "#3B82F6",
|
|
5114
|
-
guard: "#9B59B6"
|
|
5115
|
-
};
|
|
5116
|
-
var wireTypeToWidth = {
|
|
5117
|
-
transition: CONNECTION_COLORS.forward.width,
|
|
5118
|
-
event: CONNECTION_COLORS.emitListen.width,
|
|
5119
|
-
data: 1.5,
|
|
5120
|
-
guard: 1.5
|
|
5121
|
-
};
|
|
5122
|
-
var wireTypeToDash = {
|
|
5123
|
-
transition: void 0,
|
|
5124
|
-
event: CONNECTION_COLORS.emitListen.dash,
|
|
5125
|
-
data: "5 3",
|
|
5126
|
-
guard: "3 3"
|
|
5127
|
-
};
|
|
5128
|
-
function getFlowWireStyle(props) {
|
|
5129
|
-
const { wireType = "transition", status = "valid", animated = false } = props;
|
|
5130
|
-
let stroke = wireTypeToColor[wireType];
|
|
5131
|
-
if (status === "invalid") {
|
|
5132
|
-
stroke = "var(--color-destructive, #EF4444)";
|
|
5133
|
-
}
|
|
5134
|
-
const strokeWidth = wireTypeToWidth[wireType];
|
|
5135
|
-
let strokeDasharray = wireTypeToDash[wireType];
|
|
5136
|
-
if (status === "pending") {
|
|
5137
|
-
strokeDasharray = "6 4";
|
|
5138
|
-
}
|
|
5139
|
-
const animation = animated || status === "pending" ? "flow-wire-dash 1s linear infinite" : void 0;
|
|
5140
|
-
return { stroke, strokeWidth, strokeDasharray, animation };
|
|
5141
|
-
}
|
|
5142
|
-
var FlowWire = ({
|
|
5143
|
-
wireType = "transition",
|
|
5144
|
-
status = "valid",
|
|
5145
|
-
animated = false,
|
|
5146
|
-
d,
|
|
5147
|
-
className
|
|
5148
|
-
}) => {
|
|
5149
|
-
const style = getFlowWireStyle({ wireType, status, animated });
|
|
5150
|
-
return /* @__PURE__ */ jsx(
|
|
5151
|
-
"path",
|
|
5152
|
-
{
|
|
5153
|
-
d,
|
|
5154
|
-
fill: "none",
|
|
5155
|
-
stroke: style.stroke,
|
|
5156
|
-
strokeWidth: style.strokeWidth,
|
|
5157
|
-
strokeDasharray: style.strokeDasharray,
|
|
5158
|
-
className: cn(
|
|
5159
|
-
"transition-colors duration-150",
|
|
5160
|
-
(animated || status === "pending") && "animate-[flow-wire-dash_1s_linear_infinite]",
|
|
5161
|
-
className
|
|
5162
|
-
),
|
|
5163
|
-
style: style.animation ? { animation: style.animation } : void 0
|
|
5164
|
-
}
|
|
5165
|
-
);
|
|
5166
|
-
};
|
|
5167
|
-
FlowWire.displayName = "FlowWire";
|
|
5168
|
-
var MINIMAP_COLORS = {
|
|
5169
|
-
nodeColor: "var(--color-primary, #3B82F6)",
|
|
5170
|
-
maskColor: "var(--color-background, #ffffff80)",
|
|
5171
|
-
nodeStrokeColor: "var(--color-border, #E5E7EB)"
|
|
5172
|
-
};
|
|
5173
|
-
var FlowMinimap = ({
|
|
5174
|
-
className,
|
|
5175
|
-
children
|
|
5176
|
-
}) => /* @__PURE__ */ jsx(
|
|
5177
|
-
Box,
|
|
5178
|
-
{
|
|
5179
|
-
className: cn(
|
|
5180
|
-
"rounded-md overflow-hidden",
|
|
5181
|
-
"bg-card border-[length:var(--border-width)] border-border",
|
|
5182
|
-
"shadow-sm",
|
|
5183
|
-
className
|
|
5184
|
-
),
|
|
5185
|
-
children
|
|
5186
|
-
}
|
|
5187
|
-
);
|
|
5188
|
-
FlowMinimap.displayName = "FlowMinimap";
|
|
5189
4970
|
|
|
5190
4971
|
// locales/en.json
|
|
5191
4972
|
var en_default = {
|
|
@@ -5352,7 +5133,7 @@ var ErrorState = ({
|
|
|
5352
5133
|
);
|
|
5353
5134
|
};
|
|
5354
5135
|
ErrorState.displayName = "ErrorState";
|
|
5355
|
-
var ErrorBoundary = class extends
|
|
5136
|
+
var ErrorBoundary = class extends React90__default.Component {
|
|
5356
5137
|
constructor(props) {
|
|
5357
5138
|
super(props);
|
|
5358
5139
|
__publicField(this, "reset", () => {
|
|
@@ -7088,8 +6869,8 @@ var Menu = ({
|
|
|
7088
6869
|
"bottom-start": "top-full left-0 mt-2",
|
|
7089
6870
|
"bottom-end": "top-full right-0 mt-2"
|
|
7090
6871
|
};
|
|
7091
|
-
const triggerChild =
|
|
7092
|
-
const triggerElement =
|
|
6872
|
+
const triggerChild = React90__default.isValidElement(trigger) ? trigger : /* @__PURE__ */ jsx("span", { children: trigger });
|
|
6873
|
+
const triggerElement = React90__default.cloneElement(
|
|
7093
6874
|
triggerChild,
|
|
7094
6875
|
{
|
|
7095
6876
|
ref: triggerRef,
|
|
@@ -7188,11 +6969,18 @@ var Menu = ({
|
|
|
7188
6969
|
Menu.displayName = "Menu";
|
|
7189
6970
|
var sizeClasses5 = {
|
|
7190
6971
|
sm: "max-w-md",
|
|
7191
|
-
md: "max-w-
|
|
7192
|
-
lg: "max-w-
|
|
7193
|
-
xl: "max-w-
|
|
6972
|
+
md: "max-w-2xl",
|
|
6973
|
+
lg: "max-w-3xl",
|
|
6974
|
+
xl: "max-w-5xl",
|
|
7194
6975
|
full: "max-w-full mx-4"
|
|
7195
6976
|
};
|
|
6977
|
+
var minWidths = {
|
|
6978
|
+
sm: "400px",
|
|
6979
|
+
md: "520px",
|
|
6980
|
+
lg: "600px",
|
|
6981
|
+
xl: "700px",
|
|
6982
|
+
full: "0"
|
|
6983
|
+
};
|
|
7196
6984
|
var Modal = ({
|
|
7197
6985
|
isOpen = true,
|
|
7198
6986
|
onClose = () => {
|
|
@@ -7266,102 +7054,113 @@ var Modal = ({
|
|
|
7266
7054
|
className: "z-40"
|
|
7267
7055
|
}
|
|
7268
7056
|
),
|
|
7269
|
-
/* @__PURE__ */ jsx(
|
|
7270
|
-
"
|
|
7271
|
-
"flex items-center justify-center p-4",
|
|
7272
|
-
"max-sm:items-end max-sm:p-0"
|
|
7273
|
-
), children: /* @__PURE__ */ jsxs(
|
|
7274
|
-
Box,
|
|
7057
|
+
/* @__PURE__ */ jsx(
|
|
7058
|
+
"div",
|
|
7275
7059
|
{
|
|
7276
|
-
ref: modalRef,
|
|
7277
|
-
bg: "surface",
|
|
7278
|
-
border: true,
|
|
7279
|
-
shadow: "lg",
|
|
7280
|
-
rounded: "md",
|
|
7281
7060
|
className: cn(
|
|
7282
|
-
"
|
|
7283
|
-
|
|
7284
|
-
"max-sm:
|
|
7285
|
-
className
|
|
7061
|
+
"fixed inset-0 z-50 pointer-events-none",
|
|
7062
|
+
"flex items-start justify-center px-4 pb-4",
|
|
7063
|
+
"max-sm:items-end max-sm:p-0"
|
|
7286
7064
|
),
|
|
7287
|
-
style:
|
|
7288
|
-
|
|
7289
|
-
|
|
7290
|
-
|
|
7291
|
-
|
|
7292
|
-
|
|
7293
|
-
|
|
7294
|
-
|
|
7295
|
-
|
|
7296
|
-
|
|
7297
|
-
|
|
7298
|
-
|
|
7299
|
-
|
|
7300
|
-
|
|
7301
|
-
|
|
7302
|
-
|
|
7303
|
-
|
|
7304
|
-
|
|
7305
|
-
|
|
7306
|
-
|
|
7307
|
-
|
|
7308
|
-
|
|
7309
|
-
|
|
7310
|
-
|
|
7311
|
-
|
|
7312
|
-
|
|
7313
|
-
|
|
7314
|
-
|
|
7065
|
+
style: { paddingTop: "10vh" },
|
|
7066
|
+
children: /* @__PURE__ */ jsxs(
|
|
7067
|
+
Box,
|
|
7068
|
+
{
|
|
7069
|
+
ref: modalRef,
|
|
7070
|
+
bg: "surface",
|
|
7071
|
+
border: true,
|
|
7072
|
+
shadow: "lg",
|
|
7073
|
+
rounded: "md",
|
|
7074
|
+
className: cn(
|
|
7075
|
+
"pointer-events-auto w-full flex flex-col",
|
|
7076
|
+
sizeClasses5[size],
|
|
7077
|
+
"max-sm:max-w-full max-sm:rounded-b-none max-sm:rounded-t-2xl",
|
|
7078
|
+
className
|
|
7079
|
+
),
|
|
7080
|
+
style: {
|
|
7081
|
+
minWidth: minWidths[size],
|
|
7082
|
+
maxHeight: "80vh",
|
|
7083
|
+
...dragY > 0 && {
|
|
7084
|
+
transform: `translateY(${dragY}px)`,
|
|
7085
|
+
transition: isDragging.current ? "none" : "transform 200ms ease-out"
|
|
7086
|
+
}
|
|
7087
|
+
},
|
|
7088
|
+
role: "dialog",
|
|
7089
|
+
"aria-modal": "true",
|
|
7090
|
+
...title && { "aria-labelledby": "modal-title" },
|
|
7091
|
+
children: [
|
|
7092
|
+
/* @__PURE__ */ jsx(
|
|
7093
|
+
"div",
|
|
7094
|
+
{
|
|
7095
|
+
className: "hidden max-sm:flex justify-center py-2 cursor-grab active:cursor-grabbing touch-none",
|
|
7096
|
+
onPointerDown: (e) => {
|
|
7097
|
+
if (!swipeDownToClose) return;
|
|
7098
|
+
dragStartY.current = e.clientY;
|
|
7099
|
+
isDragging.current = true;
|
|
7100
|
+
e.target.setPointerCapture(e.pointerId);
|
|
7101
|
+
},
|
|
7102
|
+
onPointerMove: (e) => {
|
|
7103
|
+
if (!isDragging.current) return;
|
|
7104
|
+
const dy = Math.max(0, e.clientY - dragStartY.current);
|
|
7105
|
+
setDragY(dy);
|
|
7106
|
+
},
|
|
7107
|
+
onPointerUp: () => {
|
|
7108
|
+
if (!isDragging.current) return;
|
|
7109
|
+
isDragging.current = false;
|
|
7110
|
+
if (dragY > 100) {
|
|
7111
|
+
handleClose();
|
|
7112
|
+
}
|
|
7113
|
+
setDragY(0);
|
|
7114
|
+
},
|
|
7115
|
+
onPointerCancel: () => {
|
|
7116
|
+
isDragging.current = false;
|
|
7117
|
+
setDragY(0);
|
|
7118
|
+
},
|
|
7119
|
+
children: /* @__PURE__ */ jsx("div", { className: "w-10 h-1 rounded-full bg-border" })
|
|
7315
7120
|
}
|
|
7316
|
-
setDragY(0);
|
|
7317
|
-
},
|
|
7318
|
-
onPointerCancel: () => {
|
|
7319
|
-
isDragging.current = false;
|
|
7320
|
-
setDragY(0);
|
|
7321
|
-
},
|
|
7322
|
-
children: /* @__PURE__ */ jsx("div", { className: "w-10 h-1 rounded-full bg-border" })
|
|
7323
|
-
}
|
|
7324
|
-
),
|
|
7325
|
-
(title || showCloseButton) && /* @__PURE__ */ jsxs(
|
|
7326
|
-
"div",
|
|
7327
|
-
{
|
|
7328
|
-
className: cn(
|
|
7329
|
-
"px-6 py-4 flex items-center justify-between",
|
|
7330
|
-
"border-b-[length:var(--border-width)] border-border"
|
|
7331
7121
|
),
|
|
7332
|
-
|
|
7333
|
-
|
|
7334
|
-
|
|
7335
|
-
|
|
7336
|
-
|
|
7337
|
-
|
|
7338
|
-
|
|
7339
|
-
|
|
7340
|
-
|
|
7341
|
-
|
|
7342
|
-
"
|
|
7343
|
-
|
|
7344
|
-
|
|
7345
|
-
|
|
7346
|
-
|
|
7347
|
-
|
|
7348
|
-
|
|
7349
|
-
|
|
7350
|
-
|
|
7351
|
-
|
|
7352
|
-
|
|
7353
|
-
|
|
7354
|
-
|
|
7355
|
-
|
|
7356
|
-
|
|
7357
|
-
"border-t-[length:var(--border-width)] border-border"
|
|
7122
|
+
(title || showCloseButton) && /* @__PURE__ */ jsxs(
|
|
7123
|
+
"div",
|
|
7124
|
+
{
|
|
7125
|
+
className: cn(
|
|
7126
|
+
"px-6 py-4 flex items-center justify-between",
|
|
7127
|
+
"border-b-[length:var(--border-width)] border-border"
|
|
7128
|
+
),
|
|
7129
|
+
children: [
|
|
7130
|
+
title && /* @__PURE__ */ jsx(Typography, { variant: "h4", as: "h2", id: "modal-title", children: title }),
|
|
7131
|
+
showCloseButton && /* @__PURE__ */ jsx(
|
|
7132
|
+
"button",
|
|
7133
|
+
{
|
|
7134
|
+
type: "button",
|
|
7135
|
+
onClick: handleClose,
|
|
7136
|
+
"data-event": "CLOSE",
|
|
7137
|
+
className: cn(
|
|
7138
|
+
"p-1 transition-colors rounded-sm",
|
|
7139
|
+
"hover:bg-muted"
|
|
7140
|
+
),
|
|
7141
|
+
"aria-label": "Close modal",
|
|
7142
|
+
children: /* @__PURE__ */ jsx(Icon, { icon: X, size: "md" })
|
|
7143
|
+
}
|
|
7144
|
+
)
|
|
7145
|
+
]
|
|
7146
|
+
}
|
|
7358
7147
|
),
|
|
7359
|
-
|
|
7360
|
-
|
|
7361
|
-
|
|
7362
|
-
|
|
7148
|
+
/* @__PURE__ */ jsx("div", { className: "flex-1 overflow-y-auto p-6", children }),
|
|
7149
|
+
footer && /* @__PURE__ */ jsx(
|
|
7150
|
+
"div",
|
|
7151
|
+
{
|
|
7152
|
+
className: cn(
|
|
7153
|
+
"px-6 py-4 bg-muted",
|
|
7154
|
+
"border-t-[length:var(--border-width)] border-border"
|
|
7155
|
+
),
|
|
7156
|
+
children: footer
|
|
7157
|
+
}
|
|
7158
|
+
)
|
|
7159
|
+
]
|
|
7160
|
+
}
|
|
7161
|
+
)
|
|
7363
7162
|
}
|
|
7364
|
-
)
|
|
7163
|
+
)
|
|
7365
7164
|
] });
|
|
7366
7165
|
};
|
|
7367
7166
|
Modal.displayName = "Modal";
|
|
@@ -7594,8 +7393,8 @@ var Popover = ({
|
|
|
7594
7393
|
onMouseEnter: handleOpen,
|
|
7595
7394
|
onMouseLeave: handleClose
|
|
7596
7395
|
};
|
|
7597
|
-
const childElement =
|
|
7598
|
-
const triggerElement =
|
|
7396
|
+
const childElement = React90__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
|
|
7397
|
+
const triggerElement = React90__default.cloneElement(
|
|
7599
7398
|
childElement,
|
|
7600
7399
|
{
|
|
7601
7400
|
ref: triggerRef,
|
|
@@ -8350,8 +8149,8 @@ var Tooltip = ({
|
|
|
8350
8149
|
if (hideTimeoutRef.current) clearTimeout(hideTimeoutRef.current);
|
|
8351
8150
|
};
|
|
8352
8151
|
}, []);
|
|
8353
|
-
const triggerElement =
|
|
8354
|
-
const trigger =
|
|
8152
|
+
const triggerElement = React90__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
|
|
8153
|
+
const trigger = React90__default.cloneElement(triggerElement, {
|
|
8355
8154
|
ref: triggerRef,
|
|
8356
8155
|
onMouseEnter: handleMouseEnter,
|
|
8357
8156
|
onMouseLeave: handleMouseLeave,
|
|
@@ -8600,7 +8399,7 @@ var WizardProgress = ({
|
|
|
8600
8399
|
children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2", children: steps.map((step, index) => {
|
|
8601
8400
|
const isActive = index === currentStep;
|
|
8602
8401
|
const isCompleted = index < currentStep;
|
|
8603
|
-
return /* @__PURE__ */ jsxs(
|
|
8402
|
+
return /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
8604
8403
|
/* @__PURE__ */ jsx(
|
|
8605
8404
|
"button",
|
|
8606
8405
|
{
|
|
@@ -8730,7 +8529,7 @@ var WizardNavigation = ({
|
|
|
8730
8529
|
);
|
|
8731
8530
|
};
|
|
8732
8531
|
WizardNavigation.displayName = "WizardNavigation";
|
|
8733
|
-
var MarkdownContent =
|
|
8532
|
+
var MarkdownContent = React90__default.memo(
|
|
8734
8533
|
({ content, direction, className }) => {
|
|
8735
8534
|
const { t: _t } = useTranslate();
|
|
8736
8535
|
const safeContent = typeof content === "string" ? content : String(content ?? "");
|
|
@@ -8832,7 +8631,7 @@ var MarkdownContent = React91__default.memo(
|
|
|
8832
8631
|
(prev, next) => prev.content === next.content && prev.className === next.className && prev.direction === next.direction
|
|
8833
8632
|
);
|
|
8834
8633
|
MarkdownContent.displayName = "MarkdownContent";
|
|
8835
|
-
var CodeBlock =
|
|
8634
|
+
var CodeBlock = React90__default.memo(
|
|
8836
8635
|
({
|
|
8837
8636
|
code: rawCode,
|
|
8838
8637
|
language = "text",
|
|
@@ -9953,8 +9752,8 @@ function DPad({
|
|
|
9953
9752
|
}) {
|
|
9954
9753
|
const eventBus = useEventBus();
|
|
9955
9754
|
const sizes = sizeMap15[size];
|
|
9956
|
-
const [activeDirections, setActiveDirections] =
|
|
9957
|
-
const handlePress =
|
|
9755
|
+
const [activeDirections, setActiveDirections] = React90.useState(/* @__PURE__ */ new Set());
|
|
9756
|
+
const handlePress = React90.useCallback(
|
|
9958
9757
|
(direction) => {
|
|
9959
9758
|
setActiveDirections((prev) => new Set(prev).add(direction));
|
|
9960
9759
|
if (directionEvent) eventBus.emit(`UI:${directionEvent}`, { direction, pressed: true });
|
|
@@ -9962,7 +9761,7 @@ function DPad({
|
|
|
9962
9761
|
},
|
|
9963
9762
|
[directionEvent, eventBus, onDirection]
|
|
9964
9763
|
);
|
|
9965
|
-
const handleRelease =
|
|
9764
|
+
const handleRelease = React90.useCallback(
|
|
9966
9765
|
(direction) => {
|
|
9967
9766
|
setActiveDirections((prev) => {
|
|
9968
9767
|
const next = new Set(prev);
|
|
@@ -10020,8 +9819,8 @@ function ActionButtons({
|
|
|
10020
9819
|
disabled
|
|
10021
9820
|
}) {
|
|
10022
9821
|
const eventBus = useEventBus();
|
|
10023
|
-
const [activeButtons, setActiveButtons] =
|
|
10024
|
-
const handlePress =
|
|
9822
|
+
const [activeButtons, setActiveButtons] = React90.useState(/* @__PURE__ */ new Set());
|
|
9823
|
+
const handlePress = React90.useCallback(
|
|
10025
9824
|
(id) => {
|
|
10026
9825
|
setActiveButtons((prev) => new Set(prev).add(id));
|
|
10027
9826
|
if (actionEvent) eventBus.emit(`UI:${actionEvent}`, { id, pressed: true });
|
|
@@ -10029,7 +9828,7 @@ function ActionButtons({
|
|
|
10029
9828
|
},
|
|
10030
9829
|
[actionEvent, eventBus, onAction]
|
|
10031
9830
|
);
|
|
10032
|
-
const handleRelease =
|
|
9831
|
+
const handleRelease = React90.useCallback(
|
|
10033
9832
|
(id) => {
|
|
10034
9833
|
setActiveButtons((prev) => {
|
|
10035
9834
|
const next = new Set(prev);
|
|
@@ -10214,7 +10013,7 @@ function InventoryGrid({
|
|
|
10214
10013
|
const eventBus = useEventBus();
|
|
10215
10014
|
const slotCount = totalSlots ?? items.length;
|
|
10216
10015
|
const emptySlotCount = Math.max(0, slotCount - items.length);
|
|
10217
|
-
const handleSelect =
|
|
10016
|
+
const handleSelect = React90.useCallback(
|
|
10218
10017
|
(id) => {
|
|
10219
10018
|
onSelect?.(id);
|
|
10220
10019
|
if (selectEvent) {
|
|
@@ -10338,7 +10137,7 @@ function CraftingRecipe({
|
|
|
10338
10137
|
className
|
|
10339
10138
|
}) {
|
|
10340
10139
|
const eventBus = useEventBus();
|
|
10341
|
-
const handleCraft =
|
|
10140
|
+
const handleCraft = React90.useCallback(() => {
|
|
10342
10141
|
onCraft?.();
|
|
10343
10142
|
if (craftEvent) {
|
|
10344
10143
|
eventBus.emit(craftEvent, { output: output.label });
|
|
@@ -10355,7 +10154,7 @@ function CraftingRecipe({
|
|
|
10355
10154
|
children: [
|
|
10356
10155
|
/* @__PURE__ */ jsx(HStack, { gap: "xs", className: "flex-wrap items-center", children: inputs.map((ingredient, index) => {
|
|
10357
10156
|
const hasSufficient = ingredient.available >= ingredient.required;
|
|
10358
|
-
return /* @__PURE__ */ jsxs(
|
|
10157
|
+
return /* @__PURE__ */ jsxs(React90.Fragment, { children: [
|
|
10359
10158
|
/* @__PURE__ */ jsx(Box, { className: "relative", children: /* @__PURE__ */ jsx(
|
|
10360
10159
|
ItemSlot,
|
|
10361
10160
|
{
|
|
@@ -10457,15 +10256,15 @@ function GameCanvas2D({
|
|
|
10457
10256
|
fps = 60,
|
|
10458
10257
|
className
|
|
10459
10258
|
}) {
|
|
10460
|
-
const canvasRef =
|
|
10461
|
-
const rafRef =
|
|
10462
|
-
const frameRef =
|
|
10463
|
-
const lastTimeRef =
|
|
10464
|
-
const onDrawRef =
|
|
10259
|
+
const canvasRef = React90.useRef(null);
|
|
10260
|
+
const rafRef = React90.useRef(0);
|
|
10261
|
+
const frameRef = React90.useRef(0);
|
|
10262
|
+
const lastTimeRef = React90.useRef(0);
|
|
10263
|
+
const onDrawRef = React90.useRef(onDraw);
|
|
10465
10264
|
onDrawRef.current = onDraw;
|
|
10466
|
-
const onTickRef =
|
|
10265
|
+
const onTickRef = React90.useRef(onTick);
|
|
10467
10266
|
onTickRef.current = onTick;
|
|
10468
|
-
|
|
10267
|
+
React90.useEffect(() => {
|
|
10469
10268
|
const canvas = canvasRef.current;
|
|
10470
10269
|
if (!canvas) return;
|
|
10471
10270
|
const ctx = canvas.getContext("2d");
|
|
@@ -10718,7 +10517,7 @@ function TurnPanel({
|
|
|
10718
10517
|
className
|
|
10719
10518
|
}) {
|
|
10720
10519
|
const eventBus = useEventBus();
|
|
10721
|
-
const handleAction =
|
|
10520
|
+
const handleAction = React90.useCallback(
|
|
10722
10521
|
(event) => {
|
|
10723
10522
|
if (event) {
|
|
10724
10523
|
eventBus.emit(event, { turn: currentTurn, phase, activeTeam });
|
|
@@ -10843,7 +10642,7 @@ function UnitCommandBar({
|
|
|
10843
10642
|
className
|
|
10844
10643
|
}) {
|
|
10845
10644
|
const eventBus = useEventBus();
|
|
10846
|
-
const handleCommand =
|
|
10645
|
+
const handleCommand = React90.useCallback(
|
|
10847
10646
|
(event) => {
|
|
10848
10647
|
if (event) {
|
|
10849
10648
|
eventBus.emit(event, { unitId: selectedUnitId });
|
|
@@ -11382,7 +11181,7 @@ function GameMenu({
|
|
|
11382
11181
|
} catch {
|
|
11383
11182
|
}
|
|
11384
11183
|
const eventBus = eventBusProp || eventBusFromHook;
|
|
11385
|
-
const handleOptionClick =
|
|
11184
|
+
const handleOptionClick = React90.useCallback(
|
|
11386
11185
|
(option) => {
|
|
11387
11186
|
if (option.event && eventBus) {
|
|
11388
11187
|
eventBus.emit(`UI:${option.event}`, { option });
|
|
@@ -11505,7 +11304,7 @@ function GameOverScreen({
|
|
|
11505
11304
|
} catch {
|
|
11506
11305
|
}
|
|
11507
11306
|
const eventBus = eventBusProp || eventBusFromHook;
|
|
11508
|
-
const handleActionClick =
|
|
11307
|
+
const handleActionClick = React90.useCallback(
|
|
11509
11308
|
(action) => {
|
|
11510
11309
|
if (action.event && eventBus) {
|
|
11511
11310
|
eventBus.emit(`UI:${action.event}`, { action });
|
|
@@ -14321,7 +14120,7 @@ var DataList = ({
|
|
|
14321
14120
|
}) => {
|
|
14322
14121
|
const eventBus = useEventBus();
|
|
14323
14122
|
const { t } = useTranslate();
|
|
14324
|
-
const [visibleCount, setVisibleCount] =
|
|
14123
|
+
const [visibleCount, setVisibleCount] = React90__default.useState(pageSize || Infinity);
|
|
14325
14124
|
const fields = fieldsProp ?? columnsProp ?? [];
|
|
14326
14125
|
const allData = Array.isArray(entity) ? entity : entity ? [entity] : [];
|
|
14327
14126
|
const data = pageSize > 0 ? allData.slice(0, visibleCount) : allData;
|
|
@@ -14358,7 +14157,7 @@ var DataList = ({
|
|
|
14358
14157
|
const items2 = data.map((item) => item);
|
|
14359
14158
|
const groups2 = groupBy ? groupData(items2, groupBy) : [{ label: "", items: items2 }];
|
|
14360
14159
|
const contentField = titleField?.name ?? fields[0]?.name ?? "";
|
|
14361
|
-
return /* @__PURE__ */ jsx(VStack, { gap: "sm", className: cn("py-2", className), children: groups2.map((group, gi) => /* @__PURE__ */ jsxs(
|
|
14160
|
+
return /* @__PURE__ */ jsx(VStack, { gap: "sm", className: cn("py-2", className), children: groups2.map((group, gi) => /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
14362
14161
|
group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: "my-2" }),
|
|
14363
14162
|
group.items.map((itemData, index) => {
|
|
14364
14163
|
const id = itemData.id || `${gi}-${index}`;
|
|
@@ -14561,7 +14360,7 @@ var DataList = ({
|
|
|
14561
14360
|
className
|
|
14562
14361
|
),
|
|
14563
14362
|
children: [
|
|
14564
|
-
groups.map((group, gi) => /* @__PURE__ */ jsxs(
|
|
14363
|
+
groups.map((group, gi) => /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
14565
14364
|
group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: gi > 0 ? "mt-4" : "mt-0" }),
|
|
14566
14365
|
group.items.map(
|
|
14567
14366
|
(itemData, index) => renderItem(itemData, index, gi === groups.length - 1 && index === group.items.length - 1)
|
|
@@ -16293,7 +16092,7 @@ var StepFlow = ({
|
|
|
16293
16092
|
className
|
|
16294
16093
|
}) => {
|
|
16295
16094
|
if (orientation === "vertical") {
|
|
16296
|
-
return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(
|
|
16095
|
+
return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(React90__default.Fragment, { children: /* @__PURE__ */ jsxs(HStack, { gap: "md", align: "start", className: "w-full", children: [
|
|
16297
16096
|
/* @__PURE__ */ jsxs(VStack, { gap: "none", align: "center", children: [
|
|
16298
16097
|
/* @__PURE__ */ jsx(StepCircle, { step, index }),
|
|
16299
16098
|
showConnectors && index < steps.length - 1 && /* @__PURE__ */ jsx(Box, { className: "w-px h-8 bg-border" })
|
|
@@ -16304,7 +16103,7 @@ var StepFlow = ({
|
|
|
16304
16103
|
] })
|
|
16305
16104
|
] }) }, index)) });
|
|
16306
16105
|
}
|
|
16307
|
-
return /* @__PURE__ */ jsx(Box, { className: cn("w-full flex flex-col md:flex-row items-start gap-0", className), children: steps.map((step, index) => /* @__PURE__ */ jsxs(
|
|
16106
|
+
return /* @__PURE__ */ jsx(Box, { className: cn("w-full flex flex-col md:flex-row items-start gap-0", className), children: steps.map((step, index) => /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
16308
16107
|
/* @__PURE__ */ jsxs(VStack, { gap: "sm", align: "center", className: "flex-1 w-full md:w-auto", children: [
|
|
16309
16108
|
/* @__PURE__ */ jsx(StepCircle, { step, index }),
|
|
16310
16109
|
/* @__PURE__ */ jsx(Typography, { variant: "h4", className: "text-center", children: step.title }),
|
|
@@ -17035,498 +16834,6 @@ var EdgeDecoration = ({
|
|
|
17035
16834
|
)) });
|
|
17036
16835
|
};
|
|
17037
16836
|
EdgeDecoration.displayName = "EdgeDecoration";
|
|
17038
|
-
function resolveRole(data) {
|
|
17039
|
-
if (data.isInitial) return "initial";
|
|
17040
|
-
if (data.isTerminal) return "terminal";
|
|
17041
|
-
return "default";
|
|
17042
|
-
}
|
|
17043
|
-
var FlowStateNode = ({
|
|
17044
|
-
data,
|
|
17045
|
-
selected = false
|
|
17046
|
-
}) => {
|
|
17047
|
-
const role = resolveRole(data);
|
|
17048
|
-
const colors = STATE_COLORS[role];
|
|
17049
|
-
return /* @__PURE__ */ jsxs(
|
|
17050
|
-
FlowNodeShell,
|
|
17051
|
-
{
|
|
17052
|
-
selected,
|
|
17053
|
-
nodeType: "State",
|
|
17054
|
-
headerColor: colors.border,
|
|
17055
|
-
className: cn("min-w-[120px]"),
|
|
17056
|
-
children: [
|
|
17057
|
-
/* @__PURE__ */ jsx(
|
|
17058
|
-
Handle,
|
|
17059
|
-
{
|
|
17060
|
-
type: "target",
|
|
17061
|
-
position: Position.Top,
|
|
17062
|
-
className: "!bg-muted-foreground !w-2 !h-2"
|
|
17063
|
-
}
|
|
17064
|
-
),
|
|
17065
|
-
/* @__PURE__ */ jsx(Typography, { variant: "body", className: "font-semibold text-center select-none", children: data.name }),
|
|
17066
|
-
(data.isInitial || data.isTerminal) && /* @__PURE__ */ jsxs(HStack, { gap: "xs", justify: "center", className: "mt-1", children: [
|
|
17067
|
-
data.isInitial && /* @__PURE__ */ jsx(Badge, { variant: "success", size: "sm", children: "initial" }),
|
|
17068
|
-
data.isTerminal && /* @__PURE__ */ jsx(Badge, { variant: "danger", size: "sm", children: "terminal" })
|
|
17069
|
-
] }),
|
|
17070
|
-
/* @__PURE__ */ jsx(
|
|
17071
|
-
Handle,
|
|
17072
|
-
{
|
|
17073
|
-
type: "source",
|
|
17074
|
-
position: Position.Bottom,
|
|
17075
|
-
className: "!bg-muted-foreground !w-2 !h-2"
|
|
17076
|
-
}
|
|
17077
|
-
)
|
|
17078
|
-
]
|
|
17079
|
-
}
|
|
17080
|
-
);
|
|
17081
|
-
};
|
|
17082
|
-
FlowStateNode.displayName = "FlowStateNode";
|
|
17083
|
-
var OrbitalNode = ({
|
|
17084
|
-
data,
|
|
17085
|
-
selected = false
|
|
17086
|
-
}) => {
|
|
17087
|
-
const handleSpacing = 24;
|
|
17088
|
-
const maxPorts = Math.max(data.emits.length, data.listens.length, 1);
|
|
17089
|
-
const bodyHeight = maxPorts * handleSpacing + 24;
|
|
17090
|
-
return /* @__PURE__ */ jsxs(
|
|
17091
|
-
FlowNodeShell,
|
|
17092
|
-
{
|
|
17093
|
-
selected,
|
|
17094
|
-
nodeType: "Orbital",
|
|
17095
|
-
headerColor: "var(--color-primary)",
|
|
17096
|
-
className: cn("min-w-[180px]"),
|
|
17097
|
-
children: [
|
|
17098
|
-
data.listens.map((event, i) => /* @__PURE__ */ jsx(
|
|
17099
|
-
Handle,
|
|
17100
|
-
{
|
|
17101
|
-
type: "target",
|
|
17102
|
-
position: Position.Left,
|
|
17103
|
-
id: `listen-${event}`,
|
|
17104
|
-
className: "!bg-orange-500 !w-2 !h-2",
|
|
17105
|
-
style: { top: 48 + i * handleSpacing }
|
|
17106
|
-
},
|
|
17107
|
-
`listen-${event}`
|
|
17108
|
-
)),
|
|
17109
|
-
/* @__PURE__ */ jsxs(VStack, { gap: "xs", style: { minHeight: bodyHeight }, children: [
|
|
17110
|
-
/* @__PURE__ */ jsx(Typography, { variant: "body", className: "font-semibold select-none", children: data.name }),
|
|
17111
|
-
/* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground select-none", children: data.entityName }),
|
|
17112
|
-
/* @__PURE__ */ jsxs(Typography, { variant: "caption", className: "text-muted-foreground select-none", children: [
|
|
17113
|
-
data.traitCount,
|
|
17114
|
-
" traits, ",
|
|
17115
|
-
data.pageCount,
|
|
17116
|
-
" pages"
|
|
17117
|
-
] }),
|
|
17118
|
-
data.listens.length > 0 && /* @__PURE__ */ jsx(VStack, { gap: "none", className: "mt-1", children: data.listens.map((event) => /* @__PURE__ */ jsx(
|
|
17119
|
-
Typography,
|
|
17120
|
-
{
|
|
17121
|
-
variant: "caption",
|
|
17122
|
-
className: "text-orange-500 select-none text-left",
|
|
17123
|
-
children: event
|
|
17124
|
-
},
|
|
17125
|
-
event
|
|
17126
|
-
)) }),
|
|
17127
|
-
data.emits.length > 0 && /* @__PURE__ */ jsx(VStack, { gap: "none", className: "mt-1", children: data.emits.map((event) => /* @__PURE__ */ jsx(
|
|
17128
|
-
Typography,
|
|
17129
|
-
{
|
|
17130
|
-
variant: "caption",
|
|
17131
|
-
className: "text-orange-500 select-none text-right",
|
|
17132
|
-
children: event
|
|
17133
|
-
},
|
|
17134
|
-
event
|
|
17135
|
-
)) })
|
|
17136
|
-
] }),
|
|
17137
|
-
data.emits.map((event, i) => /* @__PURE__ */ jsx(
|
|
17138
|
-
Handle,
|
|
17139
|
-
{
|
|
17140
|
-
type: "source",
|
|
17141
|
-
position: Position.Right,
|
|
17142
|
-
id: `emit-${event}`,
|
|
17143
|
-
className: "!bg-orange-500 !w-2 !h-2",
|
|
17144
|
-
style: { top: 48 + i * handleSpacing }
|
|
17145
|
-
},
|
|
17146
|
-
`emit-${event}`
|
|
17147
|
-
))
|
|
17148
|
-
]
|
|
17149
|
-
}
|
|
17150
|
-
);
|
|
17151
|
-
};
|
|
17152
|
-
OrbitalNode.displayName = "OrbitalNode";
|
|
17153
|
-
var MAX_DESC = 60;
|
|
17154
|
-
function truncate(text, max) {
|
|
17155
|
-
if (!text) return "";
|
|
17156
|
-
return text.length > max ? `${text.slice(0, max)}...` : text;
|
|
17157
|
-
}
|
|
17158
|
-
var BehaviorNode = ({
|
|
17159
|
-
data,
|
|
17160
|
-
selected = false
|
|
17161
|
-
}) => {
|
|
17162
|
-
const handleSpacing = 24;
|
|
17163
|
-
const maxPorts = Math.max(data.emits.length, data.listens.length, 1);
|
|
17164
|
-
const bodyHeight = maxPorts * handleSpacing + 24;
|
|
17165
|
-
return /* @__PURE__ */ jsxs(
|
|
17166
|
-
FlowNodeShell,
|
|
17167
|
-
{
|
|
17168
|
-
selected,
|
|
17169
|
-
nodeType: "Behavior",
|
|
17170
|
-
headerColor: "#10B981",
|
|
17171
|
-
className: cn("min-w-[170px]"),
|
|
17172
|
-
children: [
|
|
17173
|
-
data.listens.map((event, i) => /* @__PURE__ */ jsx(
|
|
17174
|
-
Handle,
|
|
17175
|
-
{
|
|
17176
|
-
type: "target",
|
|
17177
|
-
position: Position.Left,
|
|
17178
|
-
id: `listen-${event}`,
|
|
17179
|
-
className: "!bg-orange-500 !w-2 !h-2",
|
|
17180
|
-
style: { top: 48 + i * handleSpacing }
|
|
17181
|
-
},
|
|
17182
|
-
`listen-${event}`
|
|
17183
|
-
)),
|
|
17184
|
-
/* @__PURE__ */ jsxs(VStack, { gap: "xs", style: { minHeight: bodyHeight }, children: [
|
|
17185
|
-
/* @__PURE__ */ jsx(Typography, { variant: "body", className: "font-semibold select-none", children: data.name }),
|
|
17186
|
-
data.description && /* @__PURE__ */ jsx(Box, { title: data.description.length > MAX_DESC ? data.description : void 0, children: /* @__PURE__ */ jsx(
|
|
17187
|
-
Typography,
|
|
17188
|
-
{
|
|
17189
|
-
variant: "caption",
|
|
17190
|
-
className: "text-muted-foreground select-none",
|
|
17191
|
-
children: truncate(data.description, MAX_DESC)
|
|
17192
|
-
}
|
|
17193
|
-
) }),
|
|
17194
|
-
/* @__PURE__ */ jsxs(Typography, { variant: "caption", className: "text-muted-foreground select-none", children: [
|
|
17195
|
-
data.stateCount,
|
|
17196
|
-
" states"
|
|
17197
|
-
] })
|
|
17198
|
-
] }),
|
|
17199
|
-
data.emits.map((event, i) => /* @__PURE__ */ jsx(
|
|
17200
|
-
Handle,
|
|
17201
|
-
{
|
|
17202
|
-
type: "source",
|
|
17203
|
-
position: Position.Right,
|
|
17204
|
-
id: `emit-${event}`,
|
|
17205
|
-
className: "!bg-orange-500 !w-2 !h-2",
|
|
17206
|
-
style: { top: 48 + i * handleSpacing }
|
|
17207
|
-
},
|
|
17208
|
-
`emit-${event}`
|
|
17209
|
-
))
|
|
17210
|
-
]
|
|
17211
|
-
}
|
|
17212
|
-
);
|
|
17213
|
-
};
|
|
17214
|
-
BehaviorNode.displayName = "BehaviorNode";
|
|
17215
|
-
var ExprNode = ({
|
|
17216
|
-
data,
|
|
17217
|
-
selected = false
|
|
17218
|
-
}) => {
|
|
17219
|
-
const ns = data.namespace ?? "arithmetic";
|
|
17220
|
-
const headerColor = AVL_OPERATOR_COLORS[ns];
|
|
17221
|
-
const handleSpacing = 22;
|
|
17222
|
-
const bodyHeight = Math.max(data.operandCount, 1) * handleSpacing + 12;
|
|
17223
|
-
return /* @__PURE__ */ jsxs(
|
|
17224
|
-
FlowNodeShell,
|
|
17225
|
-
{
|
|
17226
|
-
selected,
|
|
17227
|
-
nodeType: "Expr",
|
|
17228
|
-
headerColor,
|
|
17229
|
-
className: cn("min-w-[100px]"),
|
|
17230
|
-
children: [
|
|
17231
|
-
Array.from({ length: data.operandCount }, (_, i) => /* @__PURE__ */ jsx(
|
|
17232
|
-
Handle,
|
|
17233
|
-
{
|
|
17234
|
-
type: "target",
|
|
17235
|
-
position: Position.Left,
|
|
17236
|
-
id: `operand-${i}`,
|
|
17237
|
-
className: "!w-2 !h-2",
|
|
17238
|
-
style: {
|
|
17239
|
-
top: 40 + i * handleSpacing,
|
|
17240
|
-
backgroundColor: headerColor
|
|
17241
|
-
}
|
|
17242
|
-
},
|
|
17243
|
-
`op-${i}`
|
|
17244
|
-
)),
|
|
17245
|
-
/* @__PURE__ */ jsx(
|
|
17246
|
-
Typography,
|
|
17247
|
-
{
|
|
17248
|
-
variant: "body",
|
|
17249
|
-
className: "font-mono font-bold text-center select-none",
|
|
17250
|
-
style: { color: headerColor, minHeight: bodyHeight },
|
|
17251
|
-
children: data.operator
|
|
17252
|
-
}
|
|
17253
|
-
),
|
|
17254
|
-
/* @__PURE__ */ jsx(
|
|
17255
|
-
Handle,
|
|
17256
|
-
{
|
|
17257
|
-
type: "source",
|
|
17258
|
-
position: Position.Right,
|
|
17259
|
-
id: "result",
|
|
17260
|
-
className: "!w-2 !h-2",
|
|
17261
|
-
style: { backgroundColor: headerColor }
|
|
17262
|
-
}
|
|
17263
|
-
)
|
|
17264
|
-
]
|
|
17265
|
-
}
|
|
17266
|
-
);
|
|
17267
|
-
};
|
|
17268
|
-
ExprNode.displayName = "ExprNode";
|
|
17269
|
-
var EFFECT_ICONS = {
|
|
17270
|
-
"render-ui": "\u229E",
|
|
17271
|
-
// grid
|
|
17272
|
-
"set": "\u270E",
|
|
17273
|
-
// pencil
|
|
17274
|
-
"persist": "\u26C1",
|
|
17275
|
-
// cylinder
|
|
17276
|
-
"fetch": "\u21E3",
|
|
17277
|
-
// down arrow
|
|
17278
|
-
"emit": "\u{1F4E1}",
|
|
17279
|
-
// antenna
|
|
17280
|
-
"navigate": "\u21E2",
|
|
17281
|
-
// right arrow
|
|
17282
|
-
"notify": "\u{1F514}",
|
|
17283
|
-
// bell
|
|
17284
|
-
"call-service": "\u21C4",
|
|
17285
|
-
// bidirectional
|
|
17286
|
-
"spawn": "\u2295",
|
|
17287
|
-
// plus circle
|
|
17288
|
-
"despawn": "\u2296",
|
|
17289
|
-
// minus circle
|
|
17290
|
-
"do": "\u25B6",
|
|
17291
|
-
// play
|
|
17292
|
-
"if": "\u25C7",
|
|
17293
|
-
// diamond
|
|
17294
|
-
"log": "\xB6"
|
|
17295
|
-
// pilcrow
|
|
17296
|
-
};
|
|
17297
|
-
function resolveCategory(data) {
|
|
17298
|
-
if (data.category) return data.category;
|
|
17299
|
-
const mapped = EFFECT_TYPE_TO_CATEGORY[data.effectType];
|
|
17300
|
-
return mapped ?? "control";
|
|
17301
|
-
}
|
|
17302
|
-
var EffectNode = ({
|
|
17303
|
-
data,
|
|
17304
|
-
selected = false
|
|
17305
|
-
}) => {
|
|
17306
|
-
const category = resolveCategory(data);
|
|
17307
|
-
const colors = EFFECT_CATEGORY_COLORS[category];
|
|
17308
|
-
const icon = EFFECT_ICONS[data.effectType] ?? "\u2022";
|
|
17309
|
-
return /* @__PURE__ */ jsxs(
|
|
17310
|
-
FlowNodeShell,
|
|
17311
|
-
{
|
|
17312
|
-
selected,
|
|
17313
|
-
nodeType: "Effect",
|
|
17314
|
-
headerColor: colors.color,
|
|
17315
|
-
className: cn("min-w-[120px]"),
|
|
17316
|
-
children: [
|
|
17317
|
-
/* @__PURE__ */ jsx(
|
|
17318
|
-
Handle,
|
|
17319
|
-
{
|
|
17320
|
-
type: "target",
|
|
17321
|
-
position: Position.Left,
|
|
17322
|
-
className: "!w-2 !h-2",
|
|
17323
|
-
style: { backgroundColor: colors.color }
|
|
17324
|
-
}
|
|
17325
|
-
),
|
|
17326
|
-
/* @__PURE__ */ jsxs(HStack, { gap: "xs", align: "center", children: [
|
|
17327
|
-
/* @__PURE__ */ jsx(
|
|
17328
|
-
Typography,
|
|
17329
|
-
{
|
|
17330
|
-
variant: "body",
|
|
17331
|
-
className: "select-none",
|
|
17332
|
-
style: { color: colors.color },
|
|
17333
|
-
children: icon
|
|
17334
|
-
}
|
|
17335
|
-
),
|
|
17336
|
-
/* @__PURE__ */ jsx(Typography, { variant: "body", className: "font-semibold select-none", children: data.effectType })
|
|
17337
|
-
] }),
|
|
17338
|
-
data.args && /* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-muted-foreground select-none mt-0.5 truncate max-w-[160px]", children: data.args }),
|
|
17339
|
-
/* @__PURE__ */ jsx(
|
|
17340
|
-
Handle,
|
|
17341
|
-
{
|
|
17342
|
-
type: "source",
|
|
17343
|
-
position: Position.Right,
|
|
17344
|
-
className: "!w-2 !h-2",
|
|
17345
|
-
style: { backgroundColor: colors.color }
|
|
17346
|
-
}
|
|
17347
|
-
)
|
|
17348
|
-
]
|
|
17349
|
-
}
|
|
17350
|
-
);
|
|
17351
|
-
};
|
|
17352
|
-
EffectNode.displayName = "EffectNode";
|
|
17353
|
-
var TransitionEdge = ({
|
|
17354
|
-
id,
|
|
17355
|
-
sourceX,
|
|
17356
|
-
sourceY,
|
|
17357
|
-
targetX,
|
|
17358
|
-
targetY,
|
|
17359
|
-
sourcePosition,
|
|
17360
|
-
targetPosition,
|
|
17361
|
-
data,
|
|
17362
|
-
markerEnd,
|
|
17363
|
-
style
|
|
17364
|
-
}) => {
|
|
17365
|
-
const [edgePath, labelX, labelY] = getBezierPath({
|
|
17366
|
-
sourceX,
|
|
17367
|
-
sourceY,
|
|
17368
|
-
targetX,
|
|
17369
|
-
targetY,
|
|
17370
|
-
sourcePosition,
|
|
17371
|
-
targetPosition
|
|
17372
|
-
});
|
|
17373
|
-
const isBackward = targetX < sourceX;
|
|
17374
|
-
const connStyle = isBackward ? CONNECTION_COLORS.backward : CONNECTION_COLORS.forward;
|
|
17375
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
17376
|
-
/* @__PURE__ */ jsx(
|
|
17377
|
-
BaseEdge,
|
|
17378
|
-
{
|
|
17379
|
-
id,
|
|
17380
|
-
path: edgePath,
|
|
17381
|
-
markerEnd,
|
|
17382
|
-
style: {
|
|
17383
|
-
stroke: connStyle.color,
|
|
17384
|
-
strokeWidth: connStyle.width,
|
|
17385
|
-
strokeDasharray: connStyle.dash,
|
|
17386
|
-
...style
|
|
17387
|
-
}
|
|
17388
|
-
}
|
|
17389
|
-
),
|
|
17390
|
-
/* @__PURE__ */ jsx(EdgeLabelRenderer, { children: /* @__PURE__ */ jsxs(
|
|
17391
|
-
Box,
|
|
17392
|
-
{
|
|
17393
|
-
className: cn(
|
|
17394
|
-
"absolute pointer-events-all nodrag nopan",
|
|
17395
|
-
"flex items-center gap-1"
|
|
17396
|
-
),
|
|
17397
|
-
style: {
|
|
17398
|
-
transform: `translate(-50%, -50%) translate(${labelX}px, ${labelY}px)`
|
|
17399
|
-
},
|
|
17400
|
-
children: [
|
|
17401
|
-
data?.hasGuard && /* @__PURE__ */ jsx(
|
|
17402
|
-
Box,
|
|
17403
|
-
{
|
|
17404
|
-
className: "w-3 h-3 rotate-45 border border-amber-500 bg-amber-500/10 shrink-0",
|
|
17405
|
-
title: "Has guard"
|
|
17406
|
-
}
|
|
17407
|
-
),
|
|
17408
|
-
/* @__PURE__ */ jsx(
|
|
17409
|
-
FlowLabel,
|
|
17410
|
-
{
|
|
17411
|
-
text: data?.event ?? "",
|
|
17412
|
-
truncate: 20,
|
|
17413
|
-
variant: "default"
|
|
17414
|
-
}
|
|
17415
|
-
),
|
|
17416
|
-
data?.hasEffects && /* @__PURE__ */ jsx(
|
|
17417
|
-
Box,
|
|
17418
|
-
{
|
|
17419
|
-
className: "w-2.5 h-2.5 rounded-full bg-violet-500/80 shrink-0",
|
|
17420
|
-
title: "Has effects"
|
|
17421
|
-
}
|
|
17422
|
-
)
|
|
17423
|
-
]
|
|
17424
|
-
}
|
|
17425
|
-
) })
|
|
17426
|
-
] });
|
|
17427
|
-
};
|
|
17428
|
-
TransitionEdge.displayName = "TransitionEdge";
|
|
17429
|
-
var EventWireEdge = ({
|
|
17430
|
-
id,
|
|
17431
|
-
sourceX,
|
|
17432
|
-
sourceY,
|
|
17433
|
-
targetX,
|
|
17434
|
-
targetY,
|
|
17435
|
-
sourcePosition,
|
|
17436
|
-
targetPosition,
|
|
17437
|
-
data,
|
|
17438
|
-
markerEnd,
|
|
17439
|
-
style
|
|
17440
|
-
}) => {
|
|
17441
|
-
const [edgePath, labelX, labelY] = getBezierPath({
|
|
17442
|
-
sourceX,
|
|
17443
|
-
sourceY,
|
|
17444
|
-
targetX,
|
|
17445
|
-
targetY,
|
|
17446
|
-
sourcePosition,
|
|
17447
|
-
targetPosition
|
|
17448
|
-
});
|
|
17449
|
-
const isCompatible = data?.compatible !== false;
|
|
17450
|
-
const wireColor = isCompatible ? CONNECTION_COLORS.emitListen.color : "#EF4444";
|
|
17451
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
17452
|
-
/* @__PURE__ */ jsx(
|
|
17453
|
-
BaseEdge,
|
|
17454
|
-
{
|
|
17455
|
-
id,
|
|
17456
|
-
path: edgePath,
|
|
17457
|
-
markerEnd,
|
|
17458
|
-
style: {
|
|
17459
|
-
stroke: wireColor,
|
|
17460
|
-
strokeWidth: CONNECTION_COLORS.emitListen.width,
|
|
17461
|
-
strokeDasharray: CONNECTION_COLORS.emitListen.dash,
|
|
17462
|
-
...style
|
|
17463
|
-
}
|
|
17464
|
-
}
|
|
17465
|
-
),
|
|
17466
|
-
/* @__PURE__ */ jsx(EdgeLabelRenderer, { children: /* @__PURE__ */ jsx(
|
|
17467
|
-
Box,
|
|
17468
|
-
{
|
|
17469
|
-
className: cn(
|
|
17470
|
-
"absolute pointer-events-all nodrag nopan",
|
|
17471
|
-
"flex items-center"
|
|
17472
|
-
),
|
|
17473
|
-
style: {
|
|
17474
|
-
transform: `translate(-50%, -50%) translate(${labelX}px, ${labelY}px)`
|
|
17475
|
-
},
|
|
17476
|
-
children: /* @__PURE__ */ jsx(
|
|
17477
|
-
FlowLabel,
|
|
17478
|
-
{
|
|
17479
|
-
text: data?.event ?? "",
|
|
17480
|
-
truncate: 24,
|
|
17481
|
-
variant: isCompatible ? "primary" : "error"
|
|
17482
|
-
}
|
|
17483
|
-
)
|
|
17484
|
-
}
|
|
17485
|
-
) })
|
|
17486
|
-
] });
|
|
17487
|
-
};
|
|
17488
|
-
EventWireEdge.displayName = "EventWireEdge";
|
|
17489
|
-
var NodePalette = ({
|
|
17490
|
-
categories,
|
|
17491
|
-
className
|
|
17492
|
-
}) => {
|
|
17493
|
-
const handleDragStart = useCallback(
|
|
17494
|
-
(event, nodeType) => {
|
|
17495
|
-
event.dataTransfer.setData("application/reactflow", nodeType);
|
|
17496
|
-
event.dataTransfer.effectAllowed = "move";
|
|
17497
|
-
},
|
|
17498
|
-
[]
|
|
17499
|
-
);
|
|
17500
|
-
return /* @__PURE__ */ jsx(VStack, { gap: "md", className: cn("p-3 select-none", className), children: categories.map((cat) => /* @__PURE__ */ jsxs(VStack, { gap: "xs", children: [
|
|
17501
|
-
/* @__PURE__ */ jsx(
|
|
17502
|
-
Typography,
|
|
17503
|
-
{
|
|
17504
|
-
variant: "caption",
|
|
17505
|
-
className: "font-semibold uppercase tracking-wider text-muted-foreground",
|
|
17506
|
-
children: cat.name
|
|
17507
|
-
}
|
|
17508
|
-
),
|
|
17509
|
-
/* @__PURE__ */ jsx(Box, { className: "grid grid-cols-2 gap-1.5", children: cat.items.map((item) => /* @__PURE__ */ jsxs(
|
|
17510
|
-
Box,
|
|
17511
|
-
{
|
|
17512
|
-
draggable: true,
|
|
17513
|
-
onDragStart: (e) => handleDragStart(e, item.type),
|
|
17514
|
-
className: cn(
|
|
17515
|
-
"flex flex-col items-center gap-1 p-2 rounded-md cursor-grab",
|
|
17516
|
-
"border border-border bg-card hover:bg-accent/50",
|
|
17517
|
-
"transition-colors duration-100",
|
|
17518
|
-
"active:cursor-grabbing"
|
|
17519
|
-
),
|
|
17520
|
-
children: [
|
|
17521
|
-
/* @__PURE__ */ jsx(Icon, { name: item.icon, size: "sm" }),
|
|
17522
|
-
/* @__PURE__ */ jsx(Typography, { variant: "caption", className: "text-center leading-tight", children: item.label })
|
|
17523
|
-
]
|
|
17524
|
-
},
|
|
17525
|
-
item.type
|
|
17526
|
-
)) })
|
|
17527
|
-
] }, cat.name)) });
|
|
17528
|
-
};
|
|
17529
|
-
NodePalette.displayName = "NodePalette";
|
|
17530
16837
|
|
|
17531
16838
|
// components/organisms/types.ts
|
|
17532
16839
|
var EntityDisplayEvents = {
|
|
@@ -17963,7 +17270,7 @@ var StatCard = ({
|
|
|
17963
17270
|
const labelToUse = propLabel ?? propTitle;
|
|
17964
17271
|
const eventBus = useEventBus();
|
|
17965
17272
|
const { t } = useTranslate();
|
|
17966
|
-
const handleActionClick =
|
|
17273
|
+
const handleActionClick = React90__default.useCallback(() => {
|
|
17967
17274
|
if (action?.event) {
|
|
17968
17275
|
eventBus.emit(`UI:${action.event}`, {});
|
|
17969
17276
|
}
|
|
@@ -17974,7 +17281,7 @@ var StatCard = ({
|
|
|
17974
17281
|
const data = Array.isArray(entity) ? entity : entity ? [entity] : [];
|
|
17975
17282
|
const isLoading = externalLoading ?? false;
|
|
17976
17283
|
const error = externalError;
|
|
17977
|
-
const computeMetricValue =
|
|
17284
|
+
const computeMetricValue = React90__default.useCallback(
|
|
17978
17285
|
(metric, items) => {
|
|
17979
17286
|
if (metric.value !== void 0) {
|
|
17980
17287
|
return metric.value;
|
|
@@ -18013,7 +17320,7 @@ var StatCard = ({
|
|
|
18013
17320
|
},
|
|
18014
17321
|
[]
|
|
18015
17322
|
);
|
|
18016
|
-
const schemaStats =
|
|
17323
|
+
const schemaStats = React90__default.useMemo(() => {
|
|
18017
17324
|
if (!metrics || metrics.length === 0) return null;
|
|
18018
17325
|
return metrics.map((metric) => ({
|
|
18019
17326
|
label: metric.label,
|
|
@@ -18021,7 +17328,7 @@ var StatCard = ({
|
|
|
18021
17328
|
format: metric.format
|
|
18022
17329
|
}));
|
|
18023
17330
|
}, [metrics, data, computeMetricValue]);
|
|
18024
|
-
const calculatedTrend =
|
|
17331
|
+
const calculatedTrend = React90__default.useMemo(() => {
|
|
18025
17332
|
if (manualTrend !== void 0) return manualTrend;
|
|
18026
17333
|
if (previousValue === void 0 || currentValue === void 0)
|
|
18027
17334
|
return void 0;
|
|
@@ -18185,7 +17492,7 @@ var PageHeader = ({
|
|
|
18185
17492
|
info: "bg-info/10 text-info"
|
|
18186
17493
|
};
|
|
18187
17494
|
return /* @__PURE__ */ jsxs(Box, { className: cn("mb-6", className), children: [
|
|
18188
|
-
breadcrumbs && breadcrumbs.length > 0 && /* @__PURE__ */ jsx(Box, { as: "nav", className: "mb-4", children: /* @__PURE__ */ jsx(Box, { as: "ol", className: "flex items-center gap-2 text-sm", children: breadcrumbs.map((crumb, idx) => /* @__PURE__ */ jsxs(
|
|
17495
|
+
breadcrumbs && breadcrumbs.length > 0 && /* @__PURE__ */ jsx(Box, { as: "nav", className: "mb-4", children: /* @__PURE__ */ jsx(Box, { as: "ol", className: "flex items-center gap-2 text-sm", children: breadcrumbs.map((crumb, idx) => /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
18189
17496
|
idx > 0 && /* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: "/" }),
|
|
18190
17497
|
crumb.href ? /* @__PURE__ */ jsx(
|
|
18191
17498
|
"a",
|
|
@@ -18711,7 +18018,7 @@ var FormSection = ({
|
|
|
18711
18018
|
columns = 1,
|
|
18712
18019
|
className
|
|
18713
18020
|
}) => {
|
|
18714
|
-
const [collapsed, setCollapsed] =
|
|
18021
|
+
const [collapsed, setCollapsed] = React90__default.useState(defaultCollapsed);
|
|
18715
18022
|
const { t } = useTranslate();
|
|
18716
18023
|
const eventBus = useEventBus();
|
|
18717
18024
|
const gridClass = {
|
|
@@ -18719,7 +18026,7 @@ var FormSection = ({
|
|
|
18719
18026
|
2: "grid-cols-1 md:grid-cols-2",
|
|
18720
18027
|
3: "grid-cols-1 md:grid-cols-2 lg:grid-cols-3"
|
|
18721
18028
|
}[columns];
|
|
18722
|
-
|
|
18029
|
+
React90__default.useCallback(() => {
|
|
18723
18030
|
if (collapsible) {
|
|
18724
18031
|
setCollapsed((prev) => !prev);
|
|
18725
18032
|
eventBus.emit("UI:TOGGLE_COLLAPSE", { collapsed: !collapsed });
|
|
@@ -18931,7 +18238,7 @@ var Form = ({
|
|
|
18931
18238
|
const normalizedInitialData = initialData ?? {};
|
|
18932
18239
|
const resolvedEntity = entity && typeof entity === "object" && !Array.isArray(entity) ? entity : void 0;
|
|
18933
18240
|
const entityName = typeof entity === "string" ? entity : resolvedEntity?.name;
|
|
18934
|
-
const entityDerivedFields =
|
|
18241
|
+
const entityDerivedFields = React90__default.useMemo(() => {
|
|
18935
18242
|
if (fields && fields.length > 0) return void 0;
|
|
18936
18243
|
if (!resolvedEntity) return void 0;
|
|
18937
18244
|
return resolvedEntity.fields.map(
|
|
@@ -18950,14 +18257,14 @@ var Form = ({
|
|
|
18950
18257
|
const conditionalFields = typeof conditionalFieldsRaw === "boolean" ? {} : conditionalFieldsRaw;
|
|
18951
18258
|
const hiddenCalculations = typeof hiddenCalculationsRaw === "boolean" ? [] : hiddenCalculationsRaw;
|
|
18952
18259
|
const violationTriggers = typeof violationTriggersRaw === "boolean" ? [] : violationTriggersRaw;
|
|
18953
|
-
const [formData, setFormData] =
|
|
18260
|
+
const [formData, setFormData] = React90__default.useState(
|
|
18954
18261
|
normalizedInitialData
|
|
18955
18262
|
);
|
|
18956
|
-
const [collapsedSections, setCollapsedSections] =
|
|
18263
|
+
const [collapsedSections, setCollapsedSections] = React90__default.useState(
|
|
18957
18264
|
/* @__PURE__ */ new Set()
|
|
18958
18265
|
);
|
|
18959
18266
|
const shouldShowCancel = showCancel ?? (fields && fields.length > 0);
|
|
18960
|
-
const evalContext =
|
|
18267
|
+
const evalContext = React90__default.useMemo(
|
|
18961
18268
|
() => ({
|
|
18962
18269
|
formValues: formData,
|
|
18963
18270
|
globalVariables: externalContext?.globalVariables ?? {},
|
|
@@ -18966,13 +18273,13 @@ var Form = ({
|
|
|
18966
18273
|
}),
|
|
18967
18274
|
[formData, externalContext]
|
|
18968
18275
|
);
|
|
18969
|
-
|
|
18276
|
+
React90__default.useEffect(() => {
|
|
18970
18277
|
const data = initialData;
|
|
18971
18278
|
if (data && Object.keys(data).length > 0) {
|
|
18972
18279
|
setFormData(data);
|
|
18973
18280
|
}
|
|
18974
18281
|
}, [initialData]);
|
|
18975
|
-
const processCalculations =
|
|
18282
|
+
const processCalculations = React90__default.useCallback(
|
|
18976
18283
|
(changedFieldId, newFormData) => {
|
|
18977
18284
|
if (!hiddenCalculations.length) return;
|
|
18978
18285
|
const context = {
|
|
@@ -18997,7 +18304,7 @@ var Form = ({
|
|
|
18997
18304
|
},
|
|
18998
18305
|
[hiddenCalculations, externalContext, eventBus]
|
|
18999
18306
|
);
|
|
19000
|
-
const checkViolations =
|
|
18307
|
+
const checkViolations = React90__default.useCallback(
|
|
19001
18308
|
(changedFieldId, newFormData) => {
|
|
19002
18309
|
if (!violationTriggers.length) return;
|
|
19003
18310
|
const context = {
|
|
@@ -19034,7 +18341,7 @@ var Form = ({
|
|
|
19034
18341
|
processCalculations(name, newFormData);
|
|
19035
18342
|
checkViolations(name, newFormData);
|
|
19036
18343
|
};
|
|
19037
|
-
const isFieldVisible =
|
|
18344
|
+
const isFieldVisible = React90__default.useCallback(
|
|
19038
18345
|
(fieldName) => {
|
|
19039
18346
|
const condition = conditionalFields[fieldName];
|
|
19040
18347
|
if (!condition) return true;
|
|
@@ -19042,7 +18349,7 @@ var Form = ({
|
|
|
19042
18349
|
},
|
|
19043
18350
|
[conditionalFields, evalContext]
|
|
19044
18351
|
);
|
|
19045
|
-
const isSectionVisible =
|
|
18352
|
+
const isSectionVisible = React90__default.useCallback(
|
|
19046
18353
|
(section) => {
|
|
19047
18354
|
if (!section.condition) return true;
|
|
19048
18355
|
return Boolean(evaluateFormExpression(section.condition, evalContext));
|
|
@@ -19074,7 +18381,7 @@ var Form = ({
|
|
|
19074
18381
|
eventBus.emit(`UI:${onCancel}`);
|
|
19075
18382
|
}
|
|
19076
18383
|
};
|
|
19077
|
-
const renderField =
|
|
18384
|
+
const renderField = React90__default.useCallback(
|
|
19078
18385
|
(field) => {
|
|
19079
18386
|
const fieldName = field.name || field.field;
|
|
19080
18387
|
if (!fieldName) return null;
|
|
@@ -19095,7 +18402,7 @@ var Form = ({
|
|
|
19095
18402
|
[formData, isFieldVisible, relationsData, relationsLoading, isLoading]
|
|
19096
18403
|
);
|
|
19097
18404
|
const effectiveFields = entityDerivedFields ?? fields;
|
|
19098
|
-
const normalizedFields =
|
|
18405
|
+
const normalizedFields = React90__default.useMemo(() => {
|
|
19099
18406
|
if (!effectiveFields || effectiveFields.length === 0) return [];
|
|
19100
18407
|
return effectiveFields.map((field) => {
|
|
19101
18408
|
if (typeof field === "string") {
|
|
@@ -19117,7 +18424,7 @@ var Form = ({
|
|
|
19117
18424
|
return field;
|
|
19118
18425
|
});
|
|
19119
18426
|
}, [effectiveFields, resolvedEntity]);
|
|
19120
|
-
const schemaFields =
|
|
18427
|
+
const schemaFields = React90__default.useMemo(() => {
|
|
19121
18428
|
if (normalizedFields.length === 0) return null;
|
|
19122
18429
|
if (isDebugEnabled()) {
|
|
19123
18430
|
debugGroup(`Form: ${entityName || "unknown"}`);
|
|
@@ -19127,7 +18434,7 @@ var Form = ({
|
|
|
19127
18434
|
}
|
|
19128
18435
|
return normalizedFields.map(renderField).filter(Boolean);
|
|
19129
18436
|
}, [normalizedFields, renderField, entityName, conditionalFields]);
|
|
19130
|
-
const sectionElements =
|
|
18437
|
+
const sectionElements = React90__default.useMemo(() => {
|
|
19131
18438
|
if (!sections || sections.length === 0) return null;
|
|
19132
18439
|
return sections.map((section) => {
|
|
19133
18440
|
if (!isSectionVisible(section)) {
|
|
@@ -20252,7 +19559,7 @@ var List = ({
|
|
|
20252
19559
|
if (entity && typeof entity === "object" && "id" in entity) return [entity];
|
|
20253
19560
|
return [];
|
|
20254
19561
|
}, [entity]);
|
|
20255
|
-
const getItemActions =
|
|
19562
|
+
const getItemActions = React90__default.useCallback(
|
|
20256
19563
|
(item) => {
|
|
20257
19564
|
if (!itemActions) return [];
|
|
20258
19565
|
if (typeof itemActions === "function") {
|
|
@@ -21018,7 +20325,7 @@ var WizardContainer = ({
|
|
|
21018
20325
|
const isCompleted = index < currentStep;
|
|
21019
20326
|
const stepKey = step.id ?? step.tabId ?? `step-${index}`;
|
|
21020
20327
|
const stepTitle = step.title ?? step.name ?? `Step ${index + 1}`;
|
|
21021
|
-
return /* @__PURE__ */ jsxs(
|
|
20328
|
+
return /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
21022
20329
|
/* @__PURE__ */ jsx(
|
|
21023
20330
|
Button,
|
|
21024
20331
|
{
|
|
@@ -22242,7 +21549,7 @@ var StateMachineView = ({
|
|
|
22242
21549
|
style: { top: title ? 30 : 0 },
|
|
22243
21550
|
children: [
|
|
22244
21551
|
entity && /* @__PURE__ */ jsx(EntityBox, { entity, config }),
|
|
22245
|
-
states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(
|
|
21552
|
+
states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(React90__default.Fragment, { children: renderStateNode(state, config) }, state.id) : /* @__PURE__ */ jsx(
|
|
22246
21553
|
StateNode,
|
|
22247
21554
|
{
|
|
22248
21555
|
state,
|
|
@@ -26688,7 +25995,7 @@ function LinearView({
|
|
|
26688
25995
|
/* @__PURE__ */ jsx(HStack, { className: "flex-wrap items-center", gap: "xs", children: trait.states.map((state, i) => {
|
|
26689
25996
|
const isDone = i < currentIdx;
|
|
26690
25997
|
const isCurrent = i === currentIdx;
|
|
26691
|
-
return /* @__PURE__ */ jsxs(
|
|
25998
|
+
return /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
26692
25999
|
i > 0 && /* @__PURE__ */ jsx(
|
|
26693
26000
|
Typography,
|
|
26694
26001
|
{
|
|
@@ -27342,7 +26649,7 @@ function SequenceBar({
|
|
|
27342
26649
|
onSlotRemove(index);
|
|
27343
26650
|
}, [onSlotRemove, playing]);
|
|
27344
26651
|
const paddedSlots = Array.from({ length: maxSlots }, (_, i) => slots[i]);
|
|
27345
|
-
return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(
|
|
26652
|
+
return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(React90__default.Fragment, { children: [
|
|
27346
26653
|
i > 0 && /* @__PURE__ */ jsx(
|
|
27347
26654
|
Typography,
|
|
27348
26655
|
{
|
|
@@ -29641,7 +28948,7 @@ function subscribeToStore(listener) {
|
|
|
29641
28948
|
function useEntityRef(entityType) {
|
|
29642
28949
|
const versionRef = useRef(0);
|
|
29643
28950
|
const dataRef = useRef([]);
|
|
29644
|
-
const getSnapshotStable =
|
|
28951
|
+
const getSnapshotStable = React90__default.useCallback(() => {
|
|
29645
28952
|
const currentVersion = getVersion(entityType);
|
|
29646
28953
|
if (currentVersion !== versionRef.current) {
|
|
29647
28954
|
versionRef.current = currentVersion;
|
|
@@ -29879,7 +29186,7 @@ function InputPattern({
|
|
|
29879
29186
|
className
|
|
29880
29187
|
}) {
|
|
29881
29188
|
const { emit } = useEventBus();
|
|
29882
|
-
const [localValue, setLocalValue] =
|
|
29189
|
+
const [localValue, setLocalValue] = React90__default.useState(value);
|
|
29883
29190
|
const handleChange = (e) => {
|
|
29884
29191
|
setLocalValue(e.target.value);
|
|
29885
29192
|
if (onChange) {
|
|
@@ -29916,7 +29223,7 @@ function TextareaPattern({
|
|
|
29916
29223
|
className
|
|
29917
29224
|
}) {
|
|
29918
29225
|
const { emit } = useEventBus();
|
|
29919
|
-
const [localValue, setLocalValue] =
|
|
29226
|
+
const [localValue, setLocalValue] = React90__default.useState(value);
|
|
29920
29227
|
const handleChange = (e) => {
|
|
29921
29228
|
setLocalValue(e.target.value);
|
|
29922
29229
|
if (onChange) {
|
|
@@ -29947,7 +29254,7 @@ function SelectPattern({
|
|
|
29947
29254
|
className
|
|
29948
29255
|
}) {
|
|
29949
29256
|
const { emit } = useEventBus();
|
|
29950
|
-
const [localValue, setLocalValue] =
|
|
29257
|
+
const [localValue, setLocalValue] = React90__default.useState(value);
|
|
29951
29258
|
const handleChange = (e) => {
|
|
29952
29259
|
setLocalValue(e.target.value);
|
|
29953
29260
|
if (onChange) {
|
|
@@ -29976,7 +29283,7 @@ function CheckboxPattern({
|
|
|
29976
29283
|
className
|
|
29977
29284
|
}) {
|
|
29978
29285
|
const { emit } = useEventBus();
|
|
29979
|
-
const [localChecked, setLocalChecked] =
|
|
29286
|
+
const [localChecked, setLocalChecked] = React90__default.useState(checked);
|
|
29980
29287
|
const handleChange = (e) => {
|
|
29981
29288
|
setLocalChecked(e.target.checked);
|
|
29982
29289
|
if (onChange) {
|
|
@@ -31858,7 +31165,7 @@ var DocumentViewer = ({
|
|
|
31858
31165
|
};
|
|
31859
31166
|
DocumentViewer.displayName = "DocumentViewer";
|
|
31860
31167
|
function extractTitle(children) {
|
|
31861
|
-
if (!
|
|
31168
|
+
if (!React90__default.isValidElement(children)) return void 0;
|
|
31862
31169
|
const props = children.props;
|
|
31863
31170
|
if (typeof props.title === "string") {
|
|
31864
31171
|
return props.title;
|
|
@@ -32456,7 +31763,7 @@ var MediaGallery = ({
|
|
|
32456
31763
|
[selectable, selectedItems, selectionEvent, eventBus]
|
|
32457
31764
|
);
|
|
32458
31765
|
const entityData = Array.isArray(entity) ? entity : [];
|
|
32459
|
-
const items =
|
|
31766
|
+
const items = React90__default.useMemo(() => {
|
|
32460
31767
|
if (propItems) return propItems;
|
|
32461
31768
|
if (entityData.length === 0) return [];
|
|
32462
31769
|
return entityData.map((record, idx) => ({
|
|
@@ -32618,7 +31925,7 @@ var MediaGallery = ({
|
|
|
32618
31925
|
};
|
|
32619
31926
|
MediaGallery.displayName = "MediaGallery";
|
|
32620
31927
|
function extractTitle2(children) {
|
|
32621
|
-
if (!
|
|
31928
|
+
if (!React90__default.isValidElement(children)) return void 0;
|
|
32622
31929
|
const props = children.props;
|
|
32623
31930
|
if (typeof props.title === "string") {
|
|
32624
31931
|
return props.title;
|
|
@@ -32704,7 +32011,7 @@ function subscribeToDebugEvents(listener) {
|
|
|
32704
32011
|
|
|
32705
32012
|
// components/organisms/debug/hooks/useDebugData.ts
|
|
32706
32013
|
function useDebugData() {
|
|
32707
|
-
const [data, setData] =
|
|
32014
|
+
const [data, setData] = React90.useState(() => ({
|
|
32708
32015
|
traits: [],
|
|
32709
32016
|
ticks: [],
|
|
32710
32017
|
guards: [],
|
|
@@ -32718,7 +32025,7 @@ function useDebugData() {
|
|
|
32718
32025
|
},
|
|
32719
32026
|
lastUpdate: Date.now()
|
|
32720
32027
|
}));
|
|
32721
|
-
|
|
32028
|
+
React90.useEffect(() => {
|
|
32722
32029
|
const updateData = () => {
|
|
32723
32030
|
setData({
|
|
32724
32031
|
traits: getAllTraits(),
|
|
@@ -32987,15 +32294,15 @@ var TYPE_BADGES = {
|
|
|
32987
32294
|
state: { variant: "danger", icon: "\u{1F4CA}" }
|
|
32988
32295
|
};
|
|
32989
32296
|
function EventFlowTab({ events: events2 }) {
|
|
32990
|
-
const [filter, setFilter] =
|
|
32991
|
-
const containerRef =
|
|
32992
|
-
const [autoScroll, setAutoScroll] =
|
|
32993
|
-
|
|
32297
|
+
const [filter, setFilter] = React90.useState("all");
|
|
32298
|
+
const containerRef = React90.useRef(null);
|
|
32299
|
+
const [autoScroll, setAutoScroll] = React90.useState(true);
|
|
32300
|
+
React90.useEffect(() => {
|
|
32994
32301
|
if (autoScroll && containerRef.current) {
|
|
32995
32302
|
containerRef.current.scrollTop = containerRef.current.scrollHeight;
|
|
32996
32303
|
}
|
|
32997
32304
|
}, [events2.length, autoScroll]);
|
|
32998
|
-
const filteredEvents =
|
|
32305
|
+
const filteredEvents = React90.useMemo(() => {
|
|
32999
32306
|
if (filter === "all") return events2;
|
|
33000
32307
|
return events2.filter((e) => e.type === filter);
|
|
33001
32308
|
}, [events2, filter]);
|
|
@@ -33094,7 +32401,7 @@ function EventFlowTab({ events: events2 }) {
|
|
|
33094
32401
|
}
|
|
33095
32402
|
EventFlowTab.displayName = "EventFlowTab";
|
|
33096
32403
|
function GuardsPanel({ guards }) {
|
|
33097
|
-
const [filter, setFilter] =
|
|
32404
|
+
const [filter, setFilter] = React90.useState("all");
|
|
33098
32405
|
if (guards.length === 0) {
|
|
33099
32406
|
return /* @__PURE__ */ jsx(
|
|
33100
32407
|
EmptyState,
|
|
@@ -33107,7 +32414,7 @@ function GuardsPanel({ guards }) {
|
|
|
33107
32414
|
}
|
|
33108
32415
|
const passedCount = guards.filter((g) => g.result).length;
|
|
33109
32416
|
const failedCount = guards.length - passedCount;
|
|
33110
|
-
const filteredGuards =
|
|
32417
|
+
const filteredGuards = React90.useMemo(() => {
|
|
33111
32418
|
if (filter === "all") return guards;
|
|
33112
32419
|
if (filter === "passed") return guards.filter((g) => g.result);
|
|
33113
32420
|
return guards.filter((g) => !g.result);
|
|
@@ -33251,10 +32558,10 @@ function EffectBadge({ effect }) {
|
|
|
33251
32558
|
] });
|
|
33252
32559
|
}
|
|
33253
32560
|
function TransitionTimeline({ transitions }) {
|
|
33254
|
-
const containerRef =
|
|
33255
|
-
const [autoScroll, setAutoScroll] =
|
|
33256
|
-
const [expandedId, setExpandedId] =
|
|
33257
|
-
|
|
32561
|
+
const containerRef = React90.useRef(null);
|
|
32562
|
+
const [autoScroll, setAutoScroll] = React90.useState(true);
|
|
32563
|
+
const [expandedId, setExpandedId] = React90.useState(null);
|
|
32564
|
+
React90.useEffect(() => {
|
|
33258
32565
|
if (autoScroll && containerRef.current) {
|
|
33259
32566
|
containerRef.current.scrollTop = containerRef.current.scrollHeight;
|
|
33260
32567
|
}
|
|
@@ -33515,9 +32822,9 @@ function getAllEvents(traits2) {
|
|
|
33515
32822
|
}
|
|
33516
32823
|
function EventDispatcherTab({ traits: traits2, schema }) {
|
|
33517
32824
|
const eventBus = useEventBus();
|
|
33518
|
-
const [log, setLog] =
|
|
33519
|
-
const prevStatesRef =
|
|
33520
|
-
|
|
32825
|
+
const [log, setLog] = React90.useState([]);
|
|
32826
|
+
const prevStatesRef = React90.useRef(/* @__PURE__ */ new Map());
|
|
32827
|
+
React90.useEffect(() => {
|
|
33521
32828
|
for (const trait of traits2) {
|
|
33522
32829
|
const prev = prevStatesRef.current.get(trait.id);
|
|
33523
32830
|
if (prev && prev !== trait.currentState) {
|
|
@@ -33670,9 +32977,9 @@ function VerifyModePanel({
|
|
|
33670
32977
|
serverCount,
|
|
33671
32978
|
localCount
|
|
33672
32979
|
}) {
|
|
33673
|
-
const scrollRef =
|
|
33674
|
-
const prevCountRef =
|
|
33675
|
-
|
|
32980
|
+
const scrollRef = React90.useRef(null);
|
|
32981
|
+
const prevCountRef = React90.useRef(0);
|
|
32982
|
+
React90.useEffect(() => {
|
|
33676
32983
|
if (transitions.length > prevCountRef.current && scrollRef.current) {
|
|
33677
32984
|
scrollRef.current.scrollTop = scrollRef.current.scrollHeight;
|
|
33678
32985
|
}
|
|
@@ -33683,10 +32990,11 @@ function VerifyModePanel({
|
|
|
33683
32990
|
{
|
|
33684
32991
|
className: cn(
|
|
33685
32992
|
"runtime-debugger runtime-debugger--verify",
|
|
33686
|
-
"fixed bottom-0 left-0 right-0
|
|
32993
|
+
"fixed bottom-0 left-0 right-0 flex flex-col bg-gray-900 text-white border-t-2 border-cyan-500",
|
|
33687
32994
|
className
|
|
33688
32995
|
),
|
|
33689
32996
|
"data-testid": "debugger-verify",
|
|
32997
|
+
style: { zIndex: 30, height: "25vh" },
|
|
33690
32998
|
children: [
|
|
33691
32999
|
/* @__PURE__ */ jsxs("div", { className: "px-3 py-1.5 flex items-center gap-3 text-xs font-mono border-b border-gray-700 flex-shrink-0", children: [
|
|
33692
33000
|
/* @__PURE__ */ jsx(Badge, { variant: failedChecks > 0 ? "danger" : "success", size: "sm", children: failedChecks > 0 ? `${failedChecks} fail` : "OK" }),
|
|
@@ -33713,10 +33021,10 @@ function RuntimeDebugger({
|
|
|
33713
33021
|
defaultTab,
|
|
33714
33022
|
schema
|
|
33715
33023
|
}) {
|
|
33716
|
-
const [isCollapsed, setIsCollapsed] =
|
|
33717
|
-
const [isVisible, setIsVisible] =
|
|
33024
|
+
const [isCollapsed, setIsCollapsed] = React90.useState(mode === "verify" ? true : defaultCollapsed);
|
|
33025
|
+
const [isVisible, setIsVisible] = React90.useState(mode === "inline" || mode === "verify" || isDebugEnabled2());
|
|
33718
33026
|
const debugData = useDebugData();
|
|
33719
|
-
|
|
33027
|
+
React90.useEffect(() => {
|
|
33720
33028
|
if (mode === "inline") return;
|
|
33721
33029
|
return onDebugToggle((enabled) => {
|
|
33722
33030
|
setIsVisible(enabled);
|
|
@@ -33725,7 +33033,7 @@ function RuntimeDebugger({
|
|
|
33725
33033
|
}
|
|
33726
33034
|
});
|
|
33727
33035
|
}, [mode]);
|
|
33728
|
-
|
|
33036
|
+
React90.useEffect(() => {
|
|
33729
33037
|
if (mode === "inline") return;
|
|
33730
33038
|
const handleKeyDown = (e) => {
|
|
33731
33039
|
if (e.key === "`" && isVisible) {
|
|
@@ -33873,12 +33181,13 @@ function RuntimeDebugger({
|
|
|
33873
33181
|
{
|
|
33874
33182
|
className: cn(
|
|
33875
33183
|
"runtime-debugger",
|
|
33876
|
-
"fixed
|
|
33184
|
+
"fixed",
|
|
33877
33185
|
positionClasses3[position],
|
|
33878
33186
|
isCollapsed ? "runtime-debugger--collapsed" : "runtime-debugger--expanded",
|
|
33879
33187
|
className
|
|
33880
33188
|
),
|
|
33881
33189
|
"data-testid": isCollapsed ? "debugger-collapsed" : "debugger-expanded",
|
|
33190
|
+
style: { zIndex: 30 },
|
|
33882
33191
|
children: isCollapsed ? /* @__PURE__ */ jsx(
|
|
33883
33192
|
Button,
|
|
33884
33193
|
{
|
|
@@ -34138,7 +33447,7 @@ var Timeline = ({
|
|
|
34138
33447
|
}) => {
|
|
34139
33448
|
const { t } = useTranslate();
|
|
34140
33449
|
const entityData = Array.isArray(entity) ? entity : [];
|
|
34141
|
-
const items =
|
|
33450
|
+
const items = React90__default.useMemo(() => {
|
|
34142
33451
|
if (propItems) return propItems;
|
|
34143
33452
|
if (entityData.length === 0) return [];
|
|
34144
33453
|
return entityData.map((record, idx) => {
|
|
@@ -34240,7 +33549,7 @@ var Timeline = ({
|
|
|
34240
33549
|
};
|
|
34241
33550
|
Timeline.displayName = "Timeline";
|
|
34242
33551
|
function extractToastProps(children) {
|
|
34243
|
-
if (!
|
|
33552
|
+
if (!React90__default.isValidElement(children)) {
|
|
34244
33553
|
if (typeof children === "string") {
|
|
34245
33554
|
return { message: children };
|
|
34246
33555
|
}
|
|
@@ -34271,7 +33580,7 @@ var ToastSlot = ({
|
|
|
34271
33580
|
eventBus.emit("UI:CLOSE");
|
|
34272
33581
|
};
|
|
34273
33582
|
if (!isVisible) return null;
|
|
34274
|
-
const isCustomContent =
|
|
33583
|
+
const isCustomContent = React90__default.isValidElement(children) && !message;
|
|
34275
33584
|
return /* @__PURE__ */ jsx(Box, { className: "fixed bottom-4 right-4 z-50", children: isCustomContent ? children : /* @__PURE__ */ jsx(
|
|
34276
33585
|
Toast,
|
|
34277
33586
|
{
|
|
@@ -34313,12 +33622,12 @@ WorldMapTemplate.displayName = "WorldMapTemplate";
|
|
|
34313
33622
|
|
|
34314
33623
|
// components/organisms/component-registry.generated.ts
|
|
34315
33624
|
function lazyThree(name, loader) {
|
|
34316
|
-
const Lazy =
|
|
33625
|
+
const Lazy = React90__default.lazy(() => loader().then((m) => ({ default: m[name] })));
|
|
34317
33626
|
function ThreeWrapper(props) {
|
|
34318
|
-
return
|
|
34319
|
-
|
|
33627
|
+
return React90__default.createElement(
|
|
33628
|
+
React90__default.Suspense,
|
|
34320
33629
|
{ fallback: null },
|
|
34321
|
-
|
|
33630
|
+
React90__default.createElement(Lazy, props)
|
|
34322
33631
|
);
|
|
34323
33632
|
}
|
|
34324
33633
|
ThreeWrapper.displayName = `Lazy(${name})`;
|
|
@@ -34606,7 +33915,7 @@ function SuspenseConfigProvider({
|
|
|
34606
33915
|
config,
|
|
34607
33916
|
children
|
|
34608
33917
|
}) {
|
|
34609
|
-
return
|
|
33918
|
+
return React90__default.createElement(
|
|
34610
33919
|
SuspenseConfigContext.Provider,
|
|
34611
33920
|
{ value: config },
|
|
34612
33921
|
children
|
|
@@ -35015,7 +34324,8 @@ function renderPatternChildren(children, onDismiss, parentId = "root") {
|
|
|
35015
34324
|
id: childId,
|
|
35016
34325
|
pattern: child.type,
|
|
35017
34326
|
props: child.props ?? {},
|
|
35018
|
-
priority: 0
|
|
34327
|
+
priority: 0,
|
|
34328
|
+
nodeId: child._id
|
|
35019
34329
|
};
|
|
35020
34330
|
return /* @__PURE__ */ jsx(
|
|
35021
34331
|
SlotContentRenderer,
|
|
@@ -35084,6 +34394,8 @@ function SlotContentRenderer({
|
|
|
35084
34394
|
className: "slot-content",
|
|
35085
34395
|
"data-pattern": content.pattern,
|
|
35086
34396
|
"data-id": content.id,
|
|
34397
|
+
"data-node-id": content.nodeId,
|
|
34398
|
+
"data-source-trait": content.sourceTrait,
|
|
35087
34399
|
children: /* @__PURE__ */ jsx(PatternComponent, { ...finalProps, children: renderedChildren })
|
|
35088
34400
|
}
|
|
35089
34401
|
);
|
|
@@ -35094,6 +34406,8 @@ function SlotContentRenderer({
|
|
|
35094
34406
|
className: "slot-content",
|
|
35095
34407
|
"data-pattern": content.pattern,
|
|
35096
34408
|
"data-id": content.id,
|
|
34409
|
+
"data-node-id": content.nodeId,
|
|
34410
|
+
"data-source-trait": content.sourceTrait,
|
|
35097
34411
|
children: content.props.children ?? /* @__PURE__ */ jsxs(Box, { className: "p-4 text-sm text-muted-foreground border border-dashed border-border rounded", children: [
|
|
35098
34412
|
"Unknown pattern: ",
|
|
35099
34413
|
content.pattern,
|
|
@@ -37005,7 +36319,7 @@ function EntityDataProvider({
|
|
|
37005
36319
|
adapter,
|
|
37006
36320
|
children
|
|
37007
36321
|
}) {
|
|
37008
|
-
return
|
|
36322
|
+
return React90__default.createElement(
|
|
37009
36323
|
EntityDataContext.Provider,
|
|
37010
36324
|
{ value: adapter },
|
|
37011
36325
|
children
|
|
@@ -37831,4 +37145,4 @@ function useGitHubBranches(owner, repo, enabled = true) {
|
|
|
37831
37145
|
});
|
|
37832
37146
|
}
|
|
37833
37147
|
|
|
37834
|
-
export { ALL_PRESETS, AR_BOOK_FIELDS, AboutPageTemplate, Accordion, ActionButton, ActionButtons, Card2 as ActionCard, ActionPalette, ActionTile, Alert, AnimatedCounter, AnimatedGraphic, AnimatedReveal, ArticleSection, AuthLayout, Avatar, Badge, BattleBoard, BattleTemplate,
|
|
37148
|
+
export { ALL_PRESETS, AR_BOOK_FIELDS, AboutPageTemplate, Accordion, ActionButton, ActionButtons, Card2 as ActionCard, ActionPalette, ActionTile, Alert, AnimatedCounter, AnimatedGraphic, AnimatedReveal, ArticleSection, AuthLayout, Avatar, Badge, BattleBoard, BattleTemplate, BookChapterView, BookCoverPage, BookNavBar, BookTableOfContents, BookViewer, Box, Breadcrumb, BuilderBoard, Button, ButtonGroup, CTABanner, CalendarGrid, CanvasEffect, Card, CardBody, CardContent, CardFooter, CardGrid, CardHeader, CardTitle, Carousel, CaseStudyCard, CaseStudyOrganism, CastleBoard, CastleTemplate, Center, Chart, ChartLegend, Checkbox, ChoiceButton, ClassifierBoard, CodeBlock, CodeExample, CodeView, CodeViewer, CollapsibleSection, CombatLog, ComboCounter, CommunityLinks, ConditionalWrapper, ConfettiEffect, ConfirmDialog, Container, ContentRenderer, ContentSection, ControlButton, CounterTemplate, CraftingRecipe, DEFAULT_SLOTS, DIAMOND_TOP_Y, DPad, DamageNumber, DashboardGrid, DashboardLayout, DataGrid, DataList, DataTable, DateRangeSelector, DayCell, DebuggerBoard, DetailPanel, DialogueBox, DialogueBubble, Divider, DocumentViewer, StateMachineView as DomStateMachineVisualizer, Drawer, DrawerSlot, ENTITY_EVENTS, EdgeDecoration, EditorCheckbox, EditorSelect, EditorSlider, EditorTextInput, EditorToolbar, EmptyState, EnemyPlate, EntityDataProvider, EntityDisplayEvents, ErrorBoundary, ErrorState, EventHandlerBoard, EventLog, FEATURE_COLORS, FEATURE_TYPES, FLOOR_HEIGHT, FeatureCard, FeatureDetailPageTemplate, FeatureGrid, FeatureGridOrganism, FilterGroup, Flex, FlipCard, FlipContainer, FloatingActionButton, Form, FormActions, FormField, FormLayout, FormSection, FormSectionHeader, GameAudioContext, GameAudioProvider, GameAudioToggle, GameCanvas2D, GameHud, GameMenu, GameOverScreen, GameShell, GameTemplate, GenericAppTemplate, GeometricPattern, GraphCanvas, GraphView, Grid, HStack, Header, Heading, HealthBar, HealthPanel, HeroOrganism, HeroSection, I18nProvider, IDENTITY_BOOK_FIELDS, Icon, InfiniteScrollSentinel, Input, InputGroup, InstallBox, InventoryGrid, InventoryPanel, IsometricCanvas, ItemSlot, JazariStateMachine, Label, LandingPageTemplate, LawReferenceTooltip, Lightbox, LineChart, List, LoadingState, MapView, MarkdownContent, MarketingStatCard, MasterDetail, MediaGallery, Menu, Meter, MiniMap, Modal, ModalSlot, Navigation, NegotiatorBoard, NotifyListener, NumberStepper, ObjectRulePanel, StateMachineView as OrbitalStateMachineView, OrbitalVisualization, Overlay, PageHeader, Pagination, PatternTile, PhysicsManager, PlatformerCanvas, Popover, PowerupSlots, PricingCard, PricingGrid, PricingOrganism, PricingPageTemplate, ProgressBar, ProgressDots, PullToRefresh, QuestTracker, QuizBlock, Radio, RangeSlider, RelationSelect, RepeatableFormSection, ResourceBar, ResourceCounter, RuleEditor, RuntimeDebugger, SHEET_COLUMNS, SPRITE_SHEET_LAYOUT, ScaledDiagram, ScoreBoard, ScoreDisplay, SearchInput, Section, SectionHeader, Select, SequenceBar, SequencerBoard, ServiceCatalog, ShowcaseCard, ShowcaseOrganism, SidePanel, Sidebar, SignaturePad, SimpleGrid, SimulationCanvas, SimulationControls, SimulationGraph, SimulatorBoard, Skeleton, SlotContentRenderer, SocialProof, SortableList, Spacer, Spinner, Split, SplitPane, SplitSection, Sprite, Stack, StarRating, StatBadge, StatCard, StatDisplay, StateArchitectBoard, StateIndicator, StateMachineView, StateNode2 as StateNode, StatsGrid, StatsOrganism, StatusBar, StatusDot, StatusEffect, StepFlow, StepFlowOrganism, SwipeableRow, Switch, TERRAIN_COLORS, TILE_HEIGHT, TILE_WIDTH, TabbedContainer, Table, Tabs, TagCloud, TeamCard, TeamOrganism, TerrainPalette, Text, TextHighlight, Textarea, ThemeSelector, ThemeToggle, TimeSlotCell, Timeline, TimerDisplay, Toast, ToastSlot, Tooltip, TraitSlot, TraitStateViewer, TransitionArrow, TrendIndicator, TurnIndicator, TurnPanel, TypewriterText, Typography, UISlotComponent, UISlotRenderer, UncontrolledBattleBoard, UnitCommandBar, UploadDropZone, VStack, VariablePanel, ViolationAlert, WaypointMarker, WizardContainer, WizardNavigation, WizardProgress, WorldMapBoard, WorldMapTemplate, XPBar, applyTemporaryEffect, calculateAttackTargets, calculateDamage, calculateValidMoves, clearEntities, cn, combatAnimations, combatClasses, combatEffects, createInitialGameState, createTranslate, createUnitAnimationState, drawSprite, entityDataKeys, generateCombatMessage, getAllEntities, getByType, getCurrentFrame, getEntity, getSingleton, getTileDimensions, inferDirection, isoToScreen, mapBookData, parseQueryBinding, pendulum, projectileMotion, removeEntity, resolveFieldMap, resolveFrame, resolveSheetDirection, screenToIso, spawnEntity, springOscillator, tickAnimationState, transitionAnimation, updateEntity, updateSingleton, useAgentChat, useAuthContext, useBattleState, useCamera, useCompile, useConnectGitHub, useCreateEntity, useDeepAgentGeneration, useDeleteEntity, useDisconnectGitHub, useDragReorder, useEmitEvent, useEntities, useEntitiesByType, useEntity, useEntity2 as useEntityById, useEntityDataAdapter, useEntityDetail, useEntityList, useEntityListSuspense, useEntityMutations, useEntitySuspense, useEventBus, useEventListener, useExtensions, useFileEditor, useFileSystem, useGameAudio, useGameAudioContext, useGitHubBranches, useGitHubRepo, useGitHubRepos, useGitHubStatus, useImageCache, useInfiniteScroll, useInput, useLongPress, useOrbitalHistory, useOrbitalMutations, usePhysics, usePhysics2D, usePinchZoom, usePlayer, usePreview, usePullToRefresh, useQuerySingleton, useResolvedEntity, useSelectedEntity, useSendOrbitalEvent, useSingletonEntity, useSpriteAnimations, useSwipeGesture, useTranslate, useUIEvents, useUISlotManager, useUpdateEntity, useValidation };
|