@almadar/ui 5.84.0 → 5.85.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/avl/index.cjs +1263 -1671
- package/dist/avl/index.js +233 -641
- package/dist/components/game/2d/molecules/index.d.ts +0 -2
- package/dist/components/index.cjs +1352 -1764
- package/dist/components/index.js +309 -719
- package/dist/providers/index.cjs +1130 -1538
- package/dist/providers/index.js +209 -617
- package/dist/runtime/index.cjs +1124 -1532
- package/dist/runtime/index.js +213 -621
- package/package.json +1 -1
- package/dist/components/game/2d/organisms/CardBattlerBoard.d.ts +0 -45
- package/dist/components/game/2d/organisms/VisualNovelBoard.d.ts +0 -44
package/dist/components/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
2
|
-
import * as
|
|
3
|
-
import
|
|
2
|
+
import * as React74 from 'react';
|
|
3
|
+
import React74__default, { createContext, useContext, useMemo, useRef, useEffect, useCallback, useState, Suspense, lazy, useLayoutEffect, useId, useSyncExternalStore } from 'react';
|
|
4
4
|
import { clsx } from 'clsx';
|
|
5
5
|
import { twMerge } from 'tailwind-merge';
|
|
6
6
|
import { EventBusContext, useTraitScope, useCurrentPagePath, useEntitySchemaOptional, TraitScopeProvider } from '@almadar/ui/providers';
|
|
@@ -227,7 +227,7 @@ var init_SvgFlow = __esm({
|
|
|
227
227
|
width = 100,
|
|
228
228
|
height = 100
|
|
229
229
|
}) => {
|
|
230
|
-
const markerId =
|
|
230
|
+
const markerId = React74__default.useMemo(() => {
|
|
231
231
|
flowIdCounter += 1;
|
|
232
232
|
return `almadar-flow-arrow-${flowIdCounter}`;
|
|
233
233
|
}, []);
|
|
@@ -820,7 +820,7 @@ var init_SvgRing = __esm({
|
|
|
820
820
|
width = 100,
|
|
821
821
|
height = 100
|
|
822
822
|
}) => {
|
|
823
|
-
const gradientId =
|
|
823
|
+
const gradientId = React74__default.useMemo(() => {
|
|
824
824
|
ringIdCounter += 1;
|
|
825
825
|
return `almadar-ring-glow-${ringIdCounter}`;
|
|
826
826
|
}, []);
|
|
@@ -1232,7 +1232,7 @@ function loadLib(key, importer) {
|
|
|
1232
1232
|
return p2;
|
|
1233
1233
|
}
|
|
1234
1234
|
function lazyFamilyIcon(libKey, importer, pick, fallbackName, family) {
|
|
1235
|
-
const Lazy =
|
|
1235
|
+
const Lazy = React74__default.lazy(async () => {
|
|
1236
1236
|
const lib = await loadLib(libKey, importer);
|
|
1237
1237
|
const Comp = pick(lib);
|
|
1238
1238
|
if (!Comp) {
|
|
@@ -1242,7 +1242,7 @@ function lazyFamilyIcon(libKey, importer, pick, fallbackName, family) {
|
|
|
1242
1242
|
return { default: Comp };
|
|
1243
1243
|
});
|
|
1244
1244
|
const Wrapped = (props) => /* @__PURE__ */ jsx(
|
|
1245
|
-
|
|
1245
|
+
React74__default.Suspense,
|
|
1246
1246
|
{
|
|
1247
1247
|
fallback: /* @__PURE__ */ jsx(
|
|
1248
1248
|
"span",
|
|
@@ -1973,7 +1973,7 @@ var init_Icon = __esm({
|
|
|
1973
1973
|
const directIcon = typeof icon === "string" ? void 0 : icon;
|
|
1974
1974
|
const effectiveName = typeof icon === "string" ? icon : name;
|
|
1975
1975
|
const family = useIconFamily();
|
|
1976
|
-
const RenderedComponent =
|
|
1976
|
+
const RenderedComponent = React74__default.useMemo(() => {
|
|
1977
1977
|
if (directIcon) return null;
|
|
1978
1978
|
return effectiveName ? resolveIconForFamily(effectiveName, family) : null;
|
|
1979
1979
|
}, [directIcon, effectiveName, family]);
|
|
@@ -2035,7 +2035,7 @@ function resolveIconProp(value, sizeClass) {
|
|
|
2035
2035
|
const IconComp = value;
|
|
2036
2036
|
return /* @__PURE__ */ jsx(IconComp, { className: sizeClass });
|
|
2037
2037
|
}
|
|
2038
|
-
if (
|
|
2038
|
+
if (React74__default.isValidElement(value)) {
|
|
2039
2039
|
return value;
|
|
2040
2040
|
}
|
|
2041
2041
|
if (typeof value === "object" && value !== null && isIconLike(value)) {
|
|
@@ -2111,7 +2111,7 @@ var init_Button = __esm({
|
|
|
2111
2111
|
md: "h-icon-default w-icon-default",
|
|
2112
2112
|
lg: "h-icon-default w-icon-default"
|
|
2113
2113
|
};
|
|
2114
|
-
Button =
|
|
2114
|
+
Button = React74__default.forwardRef(
|
|
2115
2115
|
({
|
|
2116
2116
|
className,
|
|
2117
2117
|
variant = "primary",
|
|
@@ -2181,7 +2181,7 @@ var init_Input = __esm({
|
|
|
2181
2181
|
init_cn();
|
|
2182
2182
|
init_Icon();
|
|
2183
2183
|
init_useEventBus();
|
|
2184
|
-
Input =
|
|
2184
|
+
Input = React74__default.forwardRef(
|
|
2185
2185
|
({
|
|
2186
2186
|
className,
|
|
2187
2187
|
inputType,
|
|
@@ -2341,7 +2341,7 @@ var Label;
|
|
|
2341
2341
|
var init_Label = __esm({
|
|
2342
2342
|
"components/core/atoms/Label.tsx"() {
|
|
2343
2343
|
init_cn();
|
|
2344
|
-
Label =
|
|
2344
|
+
Label = React74__default.forwardRef(
|
|
2345
2345
|
({ className, required, children, ...props }, ref) => {
|
|
2346
2346
|
return /* @__PURE__ */ jsxs(
|
|
2347
2347
|
"label",
|
|
@@ -2368,7 +2368,7 @@ var init_Textarea = __esm({
|
|
|
2368
2368
|
"components/core/atoms/Textarea.tsx"() {
|
|
2369
2369
|
init_cn();
|
|
2370
2370
|
init_useEventBus();
|
|
2371
|
-
Textarea =
|
|
2371
|
+
Textarea = React74__default.forwardRef(
|
|
2372
2372
|
({ className, error, onChange, ...props }, ref) => {
|
|
2373
2373
|
const eventBus = useEventBus();
|
|
2374
2374
|
const handleChange = (e) => {
|
|
@@ -2607,7 +2607,7 @@ var init_Select = __esm({
|
|
|
2607
2607
|
init_cn();
|
|
2608
2608
|
init_Icon();
|
|
2609
2609
|
init_useEventBus();
|
|
2610
|
-
Select =
|
|
2610
|
+
Select = React74__default.forwardRef(
|
|
2611
2611
|
(props, _ref) => {
|
|
2612
2612
|
const { multiple, searchable, clearable } = props;
|
|
2613
2613
|
if (multiple || searchable || clearable) {
|
|
@@ -2624,7 +2624,7 @@ var init_Checkbox = __esm({
|
|
|
2624
2624
|
"components/core/atoms/Checkbox.tsx"() {
|
|
2625
2625
|
init_cn();
|
|
2626
2626
|
init_useEventBus();
|
|
2627
|
-
Checkbox =
|
|
2627
|
+
Checkbox = React74__default.forwardRef(
|
|
2628
2628
|
({ className, label, id, onChange, ...props }, ref) => {
|
|
2629
2629
|
const inputId = id || `checkbox-${Math.random().toString(36).substr(2, 9)}`;
|
|
2630
2630
|
const eventBus = useEventBus();
|
|
@@ -2678,7 +2678,7 @@ var init_Spinner = __esm({
|
|
|
2678
2678
|
md: "h-6 w-6",
|
|
2679
2679
|
lg: "h-8 w-8"
|
|
2680
2680
|
};
|
|
2681
|
-
Spinner =
|
|
2681
|
+
Spinner = React74__default.forwardRef(
|
|
2682
2682
|
({ className, size = "md", overlay, ...props }, ref) => {
|
|
2683
2683
|
if (overlay) {
|
|
2684
2684
|
return /* @__PURE__ */ jsx(
|
|
@@ -2768,7 +2768,7 @@ var init_Card = __esm({
|
|
|
2768
2768
|
chip: "shadow-none rounded-pill border-[length:var(--border-width)] border-border",
|
|
2769
2769
|
"tile-image-first": "p-0 overflow-hidden"
|
|
2770
2770
|
};
|
|
2771
|
-
Card =
|
|
2771
|
+
Card = React74__default.forwardRef(
|
|
2772
2772
|
({
|
|
2773
2773
|
className,
|
|
2774
2774
|
variant = "bordered",
|
|
@@ -2816,9 +2816,9 @@ var init_Card = __esm({
|
|
|
2816
2816
|
}
|
|
2817
2817
|
);
|
|
2818
2818
|
Card.displayName = "Card";
|
|
2819
|
-
CardHeader =
|
|
2819
|
+
CardHeader = React74__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("mb-4", className), ...props }));
|
|
2820
2820
|
CardHeader.displayName = "CardHeader";
|
|
2821
|
-
CardTitle =
|
|
2821
|
+
CardTitle = React74__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
2822
2822
|
"h3",
|
|
2823
2823
|
{
|
|
2824
2824
|
ref,
|
|
@@ -2831,11 +2831,11 @@ var init_Card = __esm({
|
|
|
2831
2831
|
}
|
|
2832
2832
|
));
|
|
2833
2833
|
CardTitle.displayName = "CardTitle";
|
|
2834
|
-
CardContent =
|
|
2834
|
+
CardContent = React74__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("", className), ...props }));
|
|
2835
2835
|
CardContent.displayName = "CardContent";
|
|
2836
2836
|
CardBody = CardContent;
|
|
2837
2837
|
CardBody.displayName = "CardBody";
|
|
2838
|
-
CardFooter =
|
|
2838
|
+
CardFooter = React74__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
|
|
2839
2839
|
"div",
|
|
2840
2840
|
{
|
|
2841
2841
|
ref,
|
|
@@ -2888,7 +2888,7 @@ var init_Badge = __esm({
|
|
|
2888
2888
|
md: "px-2.5 py-1 text-sm",
|
|
2889
2889
|
lg: "px-3 py-1.5 text-base"
|
|
2890
2890
|
};
|
|
2891
|
-
Badge =
|
|
2891
|
+
Badge = React74__default.forwardRef(
|
|
2892
2892
|
({ className, variant = "default", size = "sm", amount, label, icon, iconAsset, children, onRemove, removeLabel, ...props }, ref) => {
|
|
2893
2893
|
const iconSizes3 = {
|
|
2894
2894
|
sm: "h-icon-default w-icon-default",
|
|
@@ -2982,7 +2982,7 @@ var init_FilterPill = __esm({
|
|
|
2982
2982
|
md: "w-3.5 h-3.5",
|
|
2983
2983
|
lg: "w-4 h-4"
|
|
2984
2984
|
};
|
|
2985
|
-
FilterPill =
|
|
2985
|
+
FilterPill = React74__default.forwardRef(
|
|
2986
2986
|
({
|
|
2987
2987
|
className,
|
|
2988
2988
|
variant = "default",
|
|
@@ -3111,8 +3111,8 @@ var init_Avatar = __esm({
|
|
|
3111
3111
|
actionPayload
|
|
3112
3112
|
}) => {
|
|
3113
3113
|
const eventBus = useEventBus();
|
|
3114
|
-
const [imgFailed, setImgFailed] =
|
|
3115
|
-
|
|
3114
|
+
const [imgFailed, setImgFailed] = React74__default.useState(false);
|
|
3115
|
+
React74__default.useEffect(() => {
|
|
3116
3116
|
setImgFailed(false);
|
|
3117
3117
|
}, [src]);
|
|
3118
3118
|
const initials = providedInitials ?? (name ? generateInitials(name) : void 0);
|
|
@@ -3364,7 +3364,7 @@ var init_Box = __esm({
|
|
|
3364
3364
|
fixed: "fixed",
|
|
3365
3365
|
sticky: "sticky"
|
|
3366
3366
|
};
|
|
3367
|
-
Box =
|
|
3367
|
+
Box = React74__default.forwardRef(
|
|
3368
3368
|
({
|
|
3369
3369
|
padding,
|
|
3370
3370
|
paddingX,
|
|
@@ -3429,7 +3429,7 @@ var init_Box = __esm({
|
|
|
3429
3429
|
onPointerDown?.(e);
|
|
3430
3430
|
}, [hoverEvent, tapReveal, triggerProps, onPointerDown]);
|
|
3431
3431
|
const isClickable = action || onClick;
|
|
3432
|
-
return
|
|
3432
|
+
return React74__default.createElement(
|
|
3433
3433
|
Component,
|
|
3434
3434
|
{
|
|
3435
3435
|
ref,
|
|
@@ -3483,7 +3483,7 @@ var init_Center = __esm({
|
|
|
3483
3483
|
as: Component = "div"
|
|
3484
3484
|
}) => {
|
|
3485
3485
|
const mergedStyle = minHeight ? { minHeight, ...style } : style;
|
|
3486
|
-
return
|
|
3486
|
+
return React74__default.createElement(Component, {
|
|
3487
3487
|
className: cn(
|
|
3488
3488
|
inline ? "inline-flex" : "flex",
|
|
3489
3489
|
horizontal && "justify-center",
|
|
@@ -3751,7 +3751,7 @@ var init_Radio = __esm({
|
|
|
3751
3751
|
md: "w-2.5 h-2.5",
|
|
3752
3752
|
lg: "w-3 h-3"
|
|
3753
3753
|
};
|
|
3754
|
-
Radio =
|
|
3754
|
+
Radio = React74__default.forwardRef(
|
|
3755
3755
|
({
|
|
3756
3756
|
label,
|
|
3757
3757
|
helperText,
|
|
@@ -3768,12 +3768,12 @@ var init_Radio = __esm({
|
|
|
3768
3768
|
onChange,
|
|
3769
3769
|
...props
|
|
3770
3770
|
}, ref) => {
|
|
3771
|
-
const reactId =
|
|
3771
|
+
const reactId = React74__default.useId();
|
|
3772
3772
|
const baseId = id || `radio-${reactId}`;
|
|
3773
3773
|
const hasError = !!error;
|
|
3774
3774
|
const eventBus = useEventBus();
|
|
3775
|
-
const [selected, setSelected] =
|
|
3776
|
-
|
|
3775
|
+
const [selected, setSelected] = React74__default.useState(value);
|
|
3776
|
+
React74__default.useEffect(() => {
|
|
3777
3777
|
if (value !== void 0) setSelected(value);
|
|
3778
3778
|
}, [value]);
|
|
3779
3779
|
const pick = (next, e) => {
|
|
@@ -3955,7 +3955,7 @@ var init_Switch = __esm({
|
|
|
3955
3955
|
"components/core/atoms/Switch.tsx"() {
|
|
3956
3956
|
"use client";
|
|
3957
3957
|
init_cn();
|
|
3958
|
-
Switch =
|
|
3958
|
+
Switch = React74.forwardRef(
|
|
3959
3959
|
({
|
|
3960
3960
|
checked,
|
|
3961
3961
|
defaultChecked = false,
|
|
@@ -3966,10 +3966,10 @@ var init_Switch = __esm({
|
|
|
3966
3966
|
name,
|
|
3967
3967
|
className
|
|
3968
3968
|
}, ref) => {
|
|
3969
|
-
const [isChecked, setIsChecked] =
|
|
3969
|
+
const [isChecked, setIsChecked] = React74.useState(
|
|
3970
3970
|
checked !== void 0 ? checked : defaultChecked
|
|
3971
3971
|
);
|
|
3972
|
-
|
|
3972
|
+
React74.useEffect(() => {
|
|
3973
3973
|
if (checked !== void 0) {
|
|
3974
3974
|
setIsChecked(checked);
|
|
3975
3975
|
}
|
|
@@ -4132,7 +4132,7 @@ var init_Stack = __esm({
|
|
|
4132
4132
|
};
|
|
4133
4133
|
const isHorizontal = direction === "horizontal";
|
|
4134
4134
|
const directionClass = responsive && isHorizontal ? reverse ? "flex-col-reverse md:flex-row-reverse" : "flex-col md:flex-row" : isHorizontal ? reverse ? "flex-row-reverse" : "flex-row" : reverse ? "flex-col-reverse" : "flex-col";
|
|
4135
|
-
return
|
|
4135
|
+
return React74__default.createElement(
|
|
4136
4136
|
Component,
|
|
4137
4137
|
{
|
|
4138
4138
|
className: cn(
|
|
@@ -4328,7 +4328,7 @@ var init_Typography = __esm({
|
|
|
4328
4328
|
}) => {
|
|
4329
4329
|
const variant = variantProp ?? (level ? `h${level}` : "body1");
|
|
4330
4330
|
const Component = as || defaultElements[variant];
|
|
4331
|
-
return
|
|
4331
|
+
return React74__default.createElement(
|
|
4332
4332
|
Component,
|
|
4333
4333
|
{
|
|
4334
4334
|
id,
|
|
@@ -4487,7 +4487,7 @@ var Dialog;
|
|
|
4487
4487
|
var init_Dialog = __esm({
|
|
4488
4488
|
"components/core/atoms/Dialog.tsx"() {
|
|
4489
4489
|
init_cn();
|
|
4490
|
-
Dialog =
|
|
4490
|
+
Dialog = React74__default.forwardRef(
|
|
4491
4491
|
({
|
|
4492
4492
|
role = "dialog",
|
|
4493
4493
|
"aria-modal": ariaModal = true,
|
|
@@ -4513,7 +4513,7 @@ var Aside;
|
|
|
4513
4513
|
var init_Aside = __esm({
|
|
4514
4514
|
"components/core/atoms/Aside.tsx"() {
|
|
4515
4515
|
init_cn();
|
|
4516
|
-
Aside =
|
|
4516
|
+
Aside = React74__default.forwardRef(
|
|
4517
4517
|
({ className, children, ...rest }, ref) => /* @__PURE__ */ jsx("aside", { ref, className: cn(className), ...rest, children })
|
|
4518
4518
|
);
|
|
4519
4519
|
Aside.displayName = "Aside";
|
|
@@ -4592,9 +4592,9 @@ var init_LawReferenceTooltip = __esm({
|
|
|
4592
4592
|
className
|
|
4593
4593
|
}) => {
|
|
4594
4594
|
const { t } = useTranslate();
|
|
4595
|
-
const [isVisible, setIsVisible] =
|
|
4596
|
-
const timeoutRef =
|
|
4597
|
-
const triggerRef =
|
|
4595
|
+
const [isVisible, setIsVisible] = React74__default.useState(false);
|
|
4596
|
+
const timeoutRef = React74__default.useRef(null);
|
|
4597
|
+
const triggerRef = React74__default.useRef(null);
|
|
4598
4598
|
const handleMouseEnter = () => {
|
|
4599
4599
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
4600
4600
|
timeoutRef.current = setTimeout(() => setIsVisible(true), 200);
|
|
@@ -4605,7 +4605,7 @@ var init_LawReferenceTooltip = __esm({
|
|
|
4605
4605
|
};
|
|
4606
4606
|
const { revealed, triggerProps } = useTapReveal({ refs: [triggerRef] });
|
|
4607
4607
|
const open = isVisible || revealed;
|
|
4608
|
-
|
|
4608
|
+
React74__default.useEffect(() => {
|
|
4609
4609
|
return () => {
|
|
4610
4610
|
if (timeoutRef.current) clearTimeout(timeoutRef.current);
|
|
4611
4611
|
};
|
|
@@ -4815,7 +4815,7 @@ var init_StatusDot = __esm({
|
|
|
4815
4815
|
md: "w-2.5 h-2.5",
|
|
4816
4816
|
lg: "w-3 h-3"
|
|
4817
4817
|
};
|
|
4818
|
-
StatusDot =
|
|
4818
|
+
StatusDot = React74__default.forwardRef(
|
|
4819
4819
|
({ className, status = "offline", pulse = false, size = "md", label, ...props }, ref) => {
|
|
4820
4820
|
return /* @__PURE__ */ jsx(
|
|
4821
4821
|
"span",
|
|
@@ -4869,7 +4869,7 @@ var init_TrendIndicator = __esm({
|
|
|
4869
4869
|
down: "trending-down",
|
|
4870
4870
|
flat: "arrow-right"
|
|
4871
4871
|
};
|
|
4872
|
-
TrendIndicator =
|
|
4872
|
+
TrendIndicator = React74__default.forwardRef(
|
|
4873
4873
|
({
|
|
4874
4874
|
className,
|
|
4875
4875
|
value,
|
|
@@ -4936,7 +4936,7 @@ var init_RangeSlider = __esm({
|
|
|
4936
4936
|
md: "w-4 h-4",
|
|
4937
4937
|
lg: "w-5 h-5"
|
|
4938
4938
|
};
|
|
4939
|
-
RangeSlider =
|
|
4939
|
+
RangeSlider = React74__default.forwardRef(
|
|
4940
4940
|
({
|
|
4941
4941
|
className,
|
|
4942
4942
|
min = 0,
|
|
@@ -5530,7 +5530,7 @@ var init_ContentSection = __esm({
|
|
|
5530
5530
|
md: "py-16",
|
|
5531
5531
|
lg: "py-24"
|
|
5532
5532
|
};
|
|
5533
|
-
ContentSection =
|
|
5533
|
+
ContentSection = React74__default.forwardRef(
|
|
5534
5534
|
({ children, background = "default", padding = "lg", id, className }, ref) => {
|
|
5535
5535
|
return /* @__PURE__ */ jsx(
|
|
5536
5536
|
Box,
|
|
@@ -6064,7 +6064,7 @@ var init_AnimatedReveal = __esm({
|
|
|
6064
6064
|
"scale-up": { opacity: 1, transform: "scale(1) translateY(0)" },
|
|
6065
6065
|
"none": {}
|
|
6066
6066
|
};
|
|
6067
|
-
AnimatedReveal =
|
|
6067
|
+
AnimatedReveal = React74__default.forwardRef(
|
|
6068
6068
|
({
|
|
6069
6069
|
trigger = "scroll",
|
|
6070
6070
|
animation = "fade-up",
|
|
@@ -6224,7 +6224,7 @@ var init_AnimatedGraphic = __esm({
|
|
|
6224
6224
|
"components/marketing/atoms/AnimatedGraphic.tsx"() {
|
|
6225
6225
|
"use client";
|
|
6226
6226
|
init_cn();
|
|
6227
|
-
AnimatedGraphic =
|
|
6227
|
+
AnimatedGraphic = React74__default.forwardRef(
|
|
6228
6228
|
({
|
|
6229
6229
|
src,
|
|
6230
6230
|
svgContent,
|
|
@@ -6247,7 +6247,7 @@ var init_AnimatedGraphic = __esm({
|
|
|
6247
6247
|
const fetchedSvg = useFetchedSvg(svgContent ? void 0 : src);
|
|
6248
6248
|
const resolvedSvg = svgContent ?? fetchedSvg;
|
|
6249
6249
|
const prevAnimateRef = useRef(animate);
|
|
6250
|
-
const setRef =
|
|
6250
|
+
const setRef = React74__default.useCallback(
|
|
6251
6251
|
(node) => {
|
|
6252
6252
|
containerRef.current = node;
|
|
6253
6253
|
if (typeof ref === "function") ref(node);
|
|
@@ -6920,7 +6920,7 @@ var init_ErrorBoundary = __esm({
|
|
|
6920
6920
|
}
|
|
6921
6921
|
);
|
|
6922
6922
|
};
|
|
6923
|
-
ErrorBoundary = class extends
|
|
6923
|
+
ErrorBoundary = class extends React74__default.Component {
|
|
6924
6924
|
constructor(props) {
|
|
6925
6925
|
super(props);
|
|
6926
6926
|
__publicField(this, "reset", () => {
|
|
@@ -7216,7 +7216,7 @@ var init_Container = __esm({
|
|
|
7216
7216
|
as: Component = "div"
|
|
7217
7217
|
}) => {
|
|
7218
7218
|
const resolvedSize = maxWidth ?? size ?? "lg";
|
|
7219
|
-
return
|
|
7219
|
+
return React74__default.createElement(
|
|
7220
7220
|
Component,
|
|
7221
7221
|
{
|
|
7222
7222
|
className: cn(
|
|
@@ -10410,7 +10410,7 @@ var init_CodeBlock = __esm({
|
|
|
10410
10410
|
DIFF_STYLE_FALLBACK = { bg: "", prefix: " ", text: "text-foreground" };
|
|
10411
10411
|
LINE_PROPS_FN = (n) => ({ "data-line": String(n - 1) });
|
|
10412
10412
|
HIDDEN_LINE_NUMBERS = { display: "none" };
|
|
10413
|
-
CodeBlock =
|
|
10413
|
+
CodeBlock = React74__default.memo(
|
|
10414
10414
|
({
|
|
10415
10415
|
code: rawCode,
|
|
10416
10416
|
language = "text",
|
|
@@ -10997,7 +10997,7 @@ var init_MarkdownContent = __esm({
|
|
|
10997
10997
|
init_Box();
|
|
10998
10998
|
init_CodeBlock();
|
|
10999
10999
|
init_cn();
|
|
11000
|
-
MarkdownContent =
|
|
11000
|
+
MarkdownContent = React74__default.memo(
|
|
11001
11001
|
({ content, direction = "ltr", className }) => {
|
|
11002
11002
|
const { t: _t } = useTranslate();
|
|
11003
11003
|
const safeContent = typeof content === "string" ? content : String(content ?? "");
|
|
@@ -12324,7 +12324,7 @@ var init_StateMachineView = __esm({
|
|
|
12324
12324
|
style: { top: title ? 30 : 0 },
|
|
12325
12325
|
children: [
|
|
12326
12326
|
entity && /* @__PURE__ */ jsx(EntityBox, { entity, config }),
|
|
12327
|
-
states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(
|
|
12327
|
+
states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(React74__default.Fragment, { children: renderStateNode(state, config) }, state.id) : /* @__PURE__ */ jsx(
|
|
12328
12328
|
StateNode,
|
|
12329
12329
|
{
|
|
12330
12330
|
state,
|
|
@@ -14948,8 +14948,8 @@ function MiniMap({
|
|
|
14948
14948
|
tileAssets,
|
|
14949
14949
|
unitAssets
|
|
14950
14950
|
}) {
|
|
14951
|
-
const canvasRef =
|
|
14952
|
-
const imgCacheRef =
|
|
14951
|
+
const canvasRef = React74.useRef(null);
|
|
14952
|
+
const imgCacheRef = React74.useRef(/* @__PURE__ */ new Map());
|
|
14953
14953
|
function loadImg(url) {
|
|
14954
14954
|
const cached = imgCacheRef.current.get(url);
|
|
14955
14955
|
if (cached) return cached.complete ? cached : null;
|
|
@@ -14964,7 +14964,7 @@ function MiniMap({
|
|
|
14964
14964
|
imgCacheRef.current.set(url, img);
|
|
14965
14965
|
return null;
|
|
14966
14966
|
}
|
|
14967
|
-
|
|
14967
|
+
React74.useEffect(() => {
|
|
14968
14968
|
const canvas = canvasRef.current;
|
|
14969
14969
|
if (!canvas) return;
|
|
14970
14970
|
const ctx = canvas.getContext("2d");
|
|
@@ -18399,278 +18399,6 @@ var init_CanvasEffect = __esm({
|
|
|
18399
18399
|
CanvasEffect.displayName = "CanvasEffect";
|
|
18400
18400
|
}
|
|
18401
18401
|
});
|
|
18402
|
-
function GameCard({
|
|
18403
|
-
id,
|
|
18404
|
-
cost,
|
|
18405
|
-
art,
|
|
18406
|
-
frameAsset,
|
|
18407
|
-
attack,
|
|
18408
|
-
defense,
|
|
18409
|
-
name,
|
|
18410
|
-
selected = false,
|
|
18411
|
-
disabled = false,
|
|
18412
|
-
size = "md",
|
|
18413
|
-
onClick,
|
|
18414
|
-
clickEvent,
|
|
18415
|
-
className
|
|
18416
|
-
}) {
|
|
18417
|
-
const eventBus = useEventBus();
|
|
18418
|
-
const handleClick = React76.useCallback(() => {
|
|
18419
|
-
if (disabled) return;
|
|
18420
|
-
onClick?.(id);
|
|
18421
|
-
if (clickEvent) eventBus.emit(`UI:${clickEvent}`, { cardId: id });
|
|
18422
|
-
}, [disabled, id, onClick, clickEvent, eventBus]);
|
|
18423
|
-
const artPx = artPxMap[size];
|
|
18424
|
-
const frameStyle = frameAsset?.url ? { backgroundImage: `url(${frameAsset.url})`, backgroundSize: "100% 100%", backgroundRepeat: "no-repeat" } : {};
|
|
18425
|
-
return /* @__PURE__ */ jsxs(
|
|
18426
|
-
Button,
|
|
18427
|
-
{
|
|
18428
|
-
variant: "ghost",
|
|
18429
|
-
onClick: handleClick,
|
|
18430
|
-
disabled,
|
|
18431
|
-
title: name,
|
|
18432
|
-
style: frameStyle,
|
|
18433
|
-
className: cn(
|
|
18434
|
-
"relative flex flex-col items-center rounded-interactive",
|
|
18435
|
-
"bg-card/90 px-1.5 pt-1.5 pb-1 transition-all duration-150",
|
|
18436
|
-
frameAsset?.url ? "border-0" : "border-2",
|
|
18437
|
-
cardSizeMap[size],
|
|
18438
|
-
disabled ? "border-border opacity-50 cursor-not-allowed" : "border-accent hover:brightness-125 hover:-translate-y-1 cursor-pointer",
|
|
18439
|
-
selected && "ring-2 ring-foreground ring-offset-1 ring-offset-background -translate-y-1",
|
|
18440
|
-
className
|
|
18441
|
-
),
|
|
18442
|
-
children: [
|
|
18443
|
-
cost != null && /* @__PURE__ */ jsx(
|
|
18444
|
-
Typography,
|
|
18445
|
-
{
|
|
18446
|
-
as: "span",
|
|
18447
|
-
className: cn(
|
|
18448
|
-
"absolute -top-2 -left-2 flex items-center justify-center",
|
|
18449
|
-
"min-w-[22px] h-[22px] rounded-full px-1",
|
|
18450
|
-
"bg-info text-foreground text-xs font-bold border border-background"
|
|
18451
|
-
),
|
|
18452
|
-
children: cost
|
|
18453
|
-
}
|
|
18454
|
-
),
|
|
18455
|
-
/* @__PURE__ */ jsx(Box, { className: "flex-1 flex items-center justify-center w-full", children: art ? /* @__PURE__ */ jsx(GameIcon, { assetUrl: art, icon: "image", size: artPx, alt: name ?? id, className: "flex-shrink-0" }) : /* @__PURE__ */ jsx(Box, { className: "rounded bg-muted/40", style: { width: artPx, height: artPx } }) }),
|
|
18456
|
-
name != null && /* @__PURE__ */ jsx(
|
|
18457
|
-
Typography,
|
|
18458
|
-
{
|
|
18459
|
-
variant: "small",
|
|
18460
|
-
className: "w-full truncate text-center text-[10px] leading-tight font-semibold",
|
|
18461
|
-
children: name
|
|
18462
|
-
}
|
|
18463
|
-
),
|
|
18464
|
-
(attack != null || defense != null) && /* @__PURE__ */ jsxs(Box, { className: "flex w-full items-center justify-between px-0.5 text-[10px] font-bold leading-none", children: [
|
|
18465
|
-
/* @__PURE__ */ jsx(Typography, { as: "span", className: "text-error", children: attack != null ? `\u2694${attack}` : "" }),
|
|
18466
|
-
/* @__PURE__ */ jsx(Typography, { as: "span", className: "text-info", children: defense != null ? `\u{1F6E1}${defense}` : "" })
|
|
18467
|
-
] })
|
|
18468
|
-
]
|
|
18469
|
-
}
|
|
18470
|
-
);
|
|
18471
|
-
}
|
|
18472
|
-
var cardSizeMap, artPxMap;
|
|
18473
|
-
var init_GameCard = __esm({
|
|
18474
|
-
"components/game/2d/atoms/GameCard.tsx"() {
|
|
18475
|
-
"use client";
|
|
18476
|
-
init_cn();
|
|
18477
|
-
init_useEventBus();
|
|
18478
|
-
init_Box();
|
|
18479
|
-
init_Button();
|
|
18480
|
-
init_Typography();
|
|
18481
|
-
init_GameIcon();
|
|
18482
|
-
cardSizeMap = {
|
|
18483
|
-
sm: "w-16 h-24",
|
|
18484
|
-
md: "w-20 h-28",
|
|
18485
|
-
lg: "w-24 h-36"
|
|
18486
|
-
};
|
|
18487
|
-
artPxMap = { sm: 40, md: 52, lg: 64 };
|
|
18488
|
-
GameCard.displayName = "GameCard";
|
|
18489
|
-
}
|
|
18490
|
-
});
|
|
18491
|
-
function rowToCard(r) {
|
|
18492
|
-
return {
|
|
18493
|
-
id: str(r.id),
|
|
18494
|
-
iconKey: r.iconKey == null ? void 0 : str(r.iconKey),
|
|
18495
|
-
title: r.title == null ? void 0 : str(r.title),
|
|
18496
|
-
cost: r.cost == null ? void 0 : num(r.cost),
|
|
18497
|
-
attack: r.attack == null ? void 0 : num(r.attack),
|
|
18498
|
-
defense: r.defense == null ? void 0 : num(r.defense)
|
|
18499
|
-
};
|
|
18500
|
-
}
|
|
18501
|
-
function resolveCardArt(card, manifest) {
|
|
18502
|
-
const key = card.iconKey ?? card.id;
|
|
18503
|
-
return manifest?.cards?.[key];
|
|
18504
|
-
}
|
|
18505
|
-
function CardBattlerBoard({
|
|
18506
|
-
entity,
|
|
18507
|
-
deck: propDeck,
|
|
18508
|
-
hand: propHand,
|
|
18509
|
-
board: propBoard,
|
|
18510
|
-
mana: propMana,
|
|
18511
|
-
maxMana: propMaxMana,
|
|
18512
|
-
turn: propTurn,
|
|
18513
|
-
result: propResult,
|
|
18514
|
-
assetManifest: propAssetManifest,
|
|
18515
|
-
playCardEvent,
|
|
18516
|
-
endTurnEvent,
|
|
18517
|
-
playAgainEvent,
|
|
18518
|
-
gameEndEvent,
|
|
18519
|
-
className
|
|
18520
|
-
}) {
|
|
18521
|
-
const board = boardEntity(entity) ?? {};
|
|
18522
|
-
const eventBus = useEventBus();
|
|
18523
|
-
const { t } = useTranslate();
|
|
18524
|
-
const assetManifest = propAssetManifest ?? board.assetManifest;
|
|
18525
|
-
const entityHand = useMemo(() => rows(board.hand).map(rowToCard), [board.hand]);
|
|
18526
|
-
const rawHand = propHand ?? entityHand;
|
|
18527
|
-
const hand = rawHand.length > 0 ? rawHand : DEFAULT_HAND;
|
|
18528
|
-
const entityBoard = useMemo(() => rows(board.board).map(rowToCard), [board.board]);
|
|
18529
|
-
const playedCards = propBoard ?? entityBoard;
|
|
18530
|
-
const entityDeck = useMemo(() => rows(board.deck).map(rowToCard), [board.deck]);
|
|
18531
|
-
const deck = propDeck ?? entityDeck;
|
|
18532
|
-
const mana = propMana ?? num(board.mana, 3);
|
|
18533
|
-
const maxMana = propMaxMana ?? num(board.maxMana, 3);
|
|
18534
|
-
const turn = propTurn ?? num(board.turn, 1);
|
|
18535
|
-
const result = propResult ?? (str(board.result) || "none");
|
|
18536
|
-
const handCards = hand;
|
|
18537
|
-
const boardCards = playedCards;
|
|
18538
|
-
const emittedGameEnd = useRef(false);
|
|
18539
|
-
if (result !== "none" && !emittedGameEnd.current) {
|
|
18540
|
-
emittedGameEnd.current = true;
|
|
18541
|
-
if (gameEndEvent) {
|
|
18542
|
-
eventBus.emit(`UI:${gameEndEvent}`, { result });
|
|
18543
|
-
}
|
|
18544
|
-
}
|
|
18545
|
-
if (result === "none") {
|
|
18546
|
-
emittedGameEnd.current = false;
|
|
18547
|
-
}
|
|
18548
|
-
const handlePlayCard = useCallback((cardId) => {
|
|
18549
|
-
if (result !== "none") return;
|
|
18550
|
-
if (playCardEvent) {
|
|
18551
|
-
eventBus.emit(`UI:${playCardEvent}`, { cardId });
|
|
18552
|
-
}
|
|
18553
|
-
}, [result, playCardEvent, eventBus]);
|
|
18554
|
-
const handleEndTurn = useCallback(() => {
|
|
18555
|
-
if (result !== "none") return;
|
|
18556
|
-
if (endTurnEvent) {
|
|
18557
|
-
eventBus.emit(`UI:${endTurnEvent}`, {});
|
|
18558
|
-
}
|
|
18559
|
-
}, [result, endTurnEvent, eventBus]);
|
|
18560
|
-
const handlePlayAgain = useCallback(() => {
|
|
18561
|
-
if (playAgainEvent) {
|
|
18562
|
-
eventBus.emit(`UI:${playAgainEvent}`, {});
|
|
18563
|
-
}
|
|
18564
|
-
}, [playAgainEvent, eventBus]);
|
|
18565
|
-
return /* @__PURE__ */ jsxs(VStack, { className: cn("card-battler-board relative min-h-[600px] bg-background", className), gap: "none", children: [
|
|
18566
|
-
/* @__PURE__ */ jsxs(
|
|
18567
|
-
HStack,
|
|
18568
|
-
{
|
|
18569
|
-
className: "px-4 py-2 border-b border-border bg-surface",
|
|
18570
|
-
gap: "lg",
|
|
18571
|
-
align: "center",
|
|
18572
|
-
children: [
|
|
18573
|
-
/* @__PURE__ */ jsxs(HStack, { gap: "xs", align: "center", children: [
|
|
18574
|
-
/* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: t("cb.mana") ?? "Mana" }),
|
|
18575
|
-
/* @__PURE__ */ jsxs(Typography, { variant: "body2", weight: "bold", className: "text-info", children: [
|
|
18576
|
-
mana,
|
|
18577
|
-
" / ",
|
|
18578
|
-
maxMana
|
|
18579
|
-
] })
|
|
18580
|
-
] }),
|
|
18581
|
-
/* @__PURE__ */ jsxs(HStack, { gap: "xs", align: "center", children: [
|
|
18582
|
-
/* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: t("cb.turn") ?? "Turn" }),
|
|
18583
|
-
/* @__PURE__ */ jsx(Typography, { variant: "body2", weight: "bold", children: turn })
|
|
18584
|
-
] }),
|
|
18585
|
-
/* @__PURE__ */ jsxs(HStack, { gap: "xs", align: "center", children: [
|
|
18586
|
-
/* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: t("cb.deck") ?? "Deck" }),
|
|
18587
|
-
/* @__PURE__ */ jsx(Typography, { variant: "body2", weight: "bold", children: deck.length })
|
|
18588
|
-
] }),
|
|
18589
|
-
/* @__PURE__ */ jsx(Box, { className: "ml-auto", children: result === "none" && /* @__PURE__ */ jsx(Button, { variant: "primary", size: "sm", onClick: handleEndTurn, children: t("cb.endTurn") ?? "End Turn" }) })
|
|
18590
|
-
]
|
|
18591
|
-
}
|
|
18592
|
-
),
|
|
18593
|
-
/* @__PURE__ */ jsxs(Box, { className: "flex-1 relative p-4 overflow-auto", children: [
|
|
18594
|
-
/* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", className: "mb-2 uppercase tracking-wide", children: t("cb.battlefield") ?? "Battlefield" }),
|
|
18595
|
-
boardCards.length > 0 ? /* @__PURE__ */ jsx("div", { className: "flex flex-wrap gap-2 items-end justify-start", children: boardCards.map((card) => /* @__PURE__ */ jsx(
|
|
18596
|
-
GameCard,
|
|
18597
|
-
{
|
|
18598
|
-
id: card.id,
|
|
18599
|
-
cost: card.cost,
|
|
18600
|
-
art: resolveCardArt(card, assetManifest),
|
|
18601
|
-
attack: card.attack,
|
|
18602
|
-
defense: card.defense,
|
|
18603
|
-
name: card.title,
|
|
18604
|
-
disabled: card.cost != null && card.cost > mana,
|
|
18605
|
-
size: "md"
|
|
18606
|
-
},
|
|
18607
|
-
card.id
|
|
18608
|
-
)) }) : /* @__PURE__ */ jsx(Box, { className: "flex items-center justify-center h-32 rounded-interactive border-2 border-dashed border-border", children: /* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: t("cb.emptyBoard") ?? "Play a card to begin" }) })
|
|
18609
|
-
] }),
|
|
18610
|
-
/* @__PURE__ */ jsxs(Box, { className: "border-t border-border bg-surface px-4 py-3", children: [
|
|
18611
|
-
/* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", className: "mb-2 uppercase tracking-wide", children: t("cb.hand") ?? "Your Hand" }),
|
|
18612
|
-
handCards.length === 0 ? /* @__PURE__ */ jsx("div", { className: "flex items-center justify-center p-4", children: /* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: t("cb.emptyHand") ?? "No cards in hand" }) }) : /* @__PURE__ */ jsx("div", { className: "flex flex-wrap gap-2 items-end justify-center", children: handCards.map((card) => /* @__PURE__ */ jsx(
|
|
18613
|
-
GameCard,
|
|
18614
|
-
{
|
|
18615
|
-
id: card.id,
|
|
18616
|
-
cost: card.cost,
|
|
18617
|
-
art: resolveCardArt(card, assetManifest),
|
|
18618
|
-
attack: card.attack,
|
|
18619
|
-
defense: card.defense,
|
|
18620
|
-
name: card.title,
|
|
18621
|
-
disabled: card.cost != null && card.cost > mana,
|
|
18622
|
-
size: "lg",
|
|
18623
|
-
onClick: handlePlayCard
|
|
18624
|
-
},
|
|
18625
|
-
card.id
|
|
18626
|
-
)) })
|
|
18627
|
-
] }),
|
|
18628
|
-
result !== "none" && /* @__PURE__ */ jsx(Box, { className: "absolute inset-0 z-50 flex items-center justify-center bg-background/70 backdrop-blur-sm", children: /* @__PURE__ */ jsxs(VStack, { className: "text-center p-8", gap: "lg", children: [
|
|
18629
|
-
/* @__PURE__ */ jsx(
|
|
18630
|
-
Typography,
|
|
18631
|
-
{
|
|
18632
|
-
variant: "h2",
|
|
18633
|
-
className: cn(
|
|
18634
|
-
"text-4xl font-black tracking-widest uppercase",
|
|
18635
|
-
result === "won" ? "text-warning" : "text-error"
|
|
18636
|
-
),
|
|
18637
|
-
children: result === "won" ? t("cb.victory") ?? "Victory!" : t("cb.defeat") ?? "Defeat!"
|
|
18638
|
-
}
|
|
18639
|
-
),
|
|
18640
|
-
/* @__PURE__ */ jsx(
|
|
18641
|
-
Button,
|
|
18642
|
-
{
|
|
18643
|
-
variant: "primary",
|
|
18644
|
-
className: "px-8 py-3 font-semibold",
|
|
18645
|
-
onClick: handlePlayAgain,
|
|
18646
|
-
children: t("cb.playAgain") ?? "Play Again"
|
|
18647
|
-
}
|
|
18648
|
-
)
|
|
18649
|
-
] }) })
|
|
18650
|
-
] });
|
|
18651
|
-
}
|
|
18652
|
-
var DEFAULT_HAND;
|
|
18653
|
-
var init_CardBattlerBoard = __esm({
|
|
18654
|
-
"components/game/2d/organisms/CardBattlerBoard.tsx"() {
|
|
18655
|
-
"use client";
|
|
18656
|
-
init_cn();
|
|
18657
|
-
init_useEventBus();
|
|
18658
|
-
init_Box();
|
|
18659
|
-
init_Button();
|
|
18660
|
-
init_Typography();
|
|
18661
|
-
init_Stack();
|
|
18662
|
-
init_GameCard();
|
|
18663
|
-
init_boardEntity();
|
|
18664
|
-
DEFAULT_HAND = [
|
|
18665
|
-
{ id: "c1", iconKey: "bear", title: "Bear", cost: 3, attack: 5, defense: 4 },
|
|
18666
|
-
{ id: "c2", iconKey: "owl", title: "Owl", cost: 1, attack: 2, defense: 1 },
|
|
18667
|
-
{ id: "c3", iconKey: "gorilla", title: "Gorilla", cost: 4, attack: 6, defense: 5 },
|
|
18668
|
-
{ id: "c4", iconKey: "frog", title: "Frog", cost: 1, attack: 1, defense: 2 },
|
|
18669
|
-
{ id: "c5", iconKey: "snake", title: "Snake", cost: 2, attack: 4, defense: 1 }
|
|
18670
|
-
];
|
|
18671
|
-
CardBattlerBoard.displayName = "CardBattlerBoard";
|
|
18672
|
-
}
|
|
18673
|
-
});
|
|
18674
18402
|
|
|
18675
18403
|
// lib/getNestedValue.ts
|
|
18676
18404
|
function getNestedValue(obj, path) {
|
|
@@ -21187,9 +20915,9 @@ function ControlButton({
|
|
|
21187
20915
|
className
|
|
21188
20916
|
}) {
|
|
21189
20917
|
const eventBus = useEventBus();
|
|
21190
|
-
const [isPressed, setIsPressed] =
|
|
20918
|
+
const [isPressed, setIsPressed] = React74.useState(false);
|
|
21191
20919
|
const actualPressed = pressed ?? isPressed;
|
|
21192
|
-
const handlePointerDown =
|
|
20920
|
+
const handlePointerDown = React74.useCallback(
|
|
21193
20921
|
(e) => {
|
|
21194
20922
|
e.preventDefault();
|
|
21195
20923
|
if (disabled) return;
|
|
@@ -21199,7 +20927,7 @@ function ControlButton({
|
|
|
21199
20927
|
},
|
|
21200
20928
|
[disabled, pressEvent, eventBus, onPress]
|
|
21201
20929
|
);
|
|
21202
|
-
const handlePointerUp =
|
|
20930
|
+
const handlePointerUp = React74.useCallback(
|
|
21203
20931
|
(e) => {
|
|
21204
20932
|
e.preventDefault();
|
|
21205
20933
|
if (disabled) return;
|
|
@@ -21209,7 +20937,7 @@ function ControlButton({
|
|
|
21209
20937
|
},
|
|
21210
20938
|
[disabled, releaseEvent, eventBus, onRelease]
|
|
21211
20939
|
);
|
|
21212
|
-
const handlePointerLeave =
|
|
20940
|
+
const handlePointerLeave = React74.useCallback(
|
|
21213
20941
|
(e) => {
|
|
21214
20942
|
if (isPressed) {
|
|
21215
20943
|
setIsPressed(false);
|
|
@@ -21302,8 +21030,8 @@ function ControlGrid({
|
|
|
21302
21030
|
className
|
|
21303
21031
|
}) {
|
|
21304
21032
|
const eventBus = useEventBus();
|
|
21305
|
-
const [active, setActive] =
|
|
21306
|
-
const handlePress =
|
|
21033
|
+
const [active, setActive] = React74.useState(/* @__PURE__ */ new Set());
|
|
21034
|
+
const handlePress = React74.useCallback(
|
|
21307
21035
|
(id) => {
|
|
21308
21036
|
setActive((prev) => new Set(prev).add(id));
|
|
21309
21037
|
if (actionEvent) eventBus.emit(`UI:${actionEvent}`, { id, pressed: true });
|
|
@@ -21317,7 +21045,7 @@ function ControlGrid({
|
|
|
21317
21045
|
},
|
|
21318
21046
|
[kind, actionEvent, directionEvent, directionEvents, eventBus, onAction, onDirection]
|
|
21319
21047
|
);
|
|
21320
|
-
const handleRelease =
|
|
21048
|
+
const handleRelease = React74.useCallback(
|
|
21321
21049
|
(id) => {
|
|
21322
21050
|
setActive((prev) => {
|
|
21323
21051
|
const next = new Set(prev);
|
|
@@ -22583,8 +22311,8 @@ var init_Menu = __esm({
|
|
|
22583
22311
|
"bottom-end": "bottom-start"
|
|
22584
22312
|
};
|
|
22585
22313
|
const effectivePosition = direction === "rtl" ? rtlMirror[position] ?? position : position;
|
|
22586
|
-
const triggerChild =
|
|
22587
|
-
const triggerElement =
|
|
22314
|
+
const triggerChild = React74__default.isValidElement(trigger) ? trigger : /* @__PURE__ */ jsx(Typography, { variant: "small", as: "span", children: trigger });
|
|
22315
|
+
const triggerElement = React74__default.cloneElement(
|
|
22588
22316
|
triggerChild,
|
|
22589
22317
|
{
|
|
22590
22318
|
ref: triggerRef,
|
|
@@ -22679,14 +22407,14 @@ function useDataDnd(args) {
|
|
|
22679
22407
|
const isZone = Boolean(dragGroup || accepts || sortable);
|
|
22680
22408
|
const enabled = isZone || Boolean(dndRoot);
|
|
22681
22409
|
const eventBus = useEventBus();
|
|
22682
|
-
const parentRoot =
|
|
22410
|
+
const parentRoot = React74__default.useContext(RootCtx);
|
|
22683
22411
|
const isRoot = enabled && parentRoot === null;
|
|
22684
|
-
const zoneId =
|
|
22412
|
+
const zoneId = React74__default.useId();
|
|
22685
22413
|
const ownGroup = dragGroup ?? accepts ?? zoneId;
|
|
22686
|
-
const [optimisticOrders, setOptimisticOrders] =
|
|
22687
|
-
const optimisticOrdersRef =
|
|
22414
|
+
const [optimisticOrders, setOptimisticOrders] = React74__default.useState(() => /* @__PURE__ */ new Map());
|
|
22415
|
+
const optimisticOrdersRef = React74__default.useRef(optimisticOrders);
|
|
22688
22416
|
optimisticOrdersRef.current = optimisticOrders;
|
|
22689
|
-
const clearOptimisticOrder =
|
|
22417
|
+
const clearOptimisticOrder = React74__default.useCallback((group) => {
|
|
22690
22418
|
setOptimisticOrders((prev) => {
|
|
22691
22419
|
if (!prev.has(group)) return prev;
|
|
22692
22420
|
const next = new Map(prev);
|
|
@@ -22711,7 +22439,7 @@ function useDataDnd(args) {
|
|
|
22711
22439
|
const raw = it[dndItemIdField];
|
|
22712
22440
|
return raw != null ? String(raw) : `__idx_${idx}`;
|
|
22713
22441
|
}).join("|");
|
|
22714
|
-
const itemIds =
|
|
22442
|
+
const itemIds = React74__default.useMemo(
|
|
22715
22443
|
() => orderedItems.map((it, idx) => {
|
|
22716
22444
|
const raw = it[dndItemIdField];
|
|
22717
22445
|
return raw != null ? String(raw) : `__idx_${idx}`;
|
|
@@ -22722,7 +22450,7 @@ function useDataDnd(args) {
|
|
|
22722
22450
|
const raw = it[dndItemIdField];
|
|
22723
22451
|
return raw != null ? String(raw) : `__${idx}`;
|
|
22724
22452
|
}).join("|");
|
|
22725
|
-
|
|
22453
|
+
React74__default.useEffect(() => {
|
|
22726
22454
|
const root = isRoot ? null : parentRoot;
|
|
22727
22455
|
if (root) {
|
|
22728
22456
|
root.clearOptimisticOrder(ownGroup);
|
|
@@ -22730,20 +22458,20 @@ function useDataDnd(args) {
|
|
|
22730
22458
|
clearOptimisticOrder(ownGroup);
|
|
22731
22459
|
}
|
|
22732
22460
|
}, [itemsContentSig, ownGroup]);
|
|
22733
|
-
const zonesRef =
|
|
22734
|
-
const registerZone =
|
|
22461
|
+
const zonesRef = React74__default.useRef(/* @__PURE__ */ new Map());
|
|
22462
|
+
const registerZone = React74__default.useCallback((zoneId2, meta2) => {
|
|
22735
22463
|
zonesRef.current.set(zoneId2, meta2);
|
|
22736
22464
|
}, []);
|
|
22737
|
-
const unregisterZone =
|
|
22465
|
+
const unregisterZone = React74__default.useCallback((zoneId2) => {
|
|
22738
22466
|
zonesRef.current.delete(zoneId2);
|
|
22739
22467
|
}, []);
|
|
22740
|
-
const [activeDrag, setActiveDrag] =
|
|
22741
|
-
const [overZoneGroup, setOverZoneGroup] =
|
|
22742
|
-
const meta =
|
|
22468
|
+
const [activeDrag, setActiveDrag] = React74__default.useState(null);
|
|
22469
|
+
const [overZoneGroup, setOverZoneGroup] = React74__default.useState(null);
|
|
22470
|
+
const meta = React74__default.useMemo(
|
|
22743
22471
|
() => ({ group: ownGroup, dropEvent, reorderEvent, positionEvent, itemIds, rawItems: items, idField: dndItemIdField }),
|
|
22744
22472
|
[ownGroup, dropEvent, reorderEvent, positionEvent, itemIds, items, dndItemIdField]
|
|
22745
22473
|
);
|
|
22746
|
-
|
|
22474
|
+
React74__default.useEffect(() => {
|
|
22747
22475
|
const target = isRoot ? null : parentRoot;
|
|
22748
22476
|
if (!target) {
|
|
22749
22477
|
zonesRef.current.set(zoneId, meta);
|
|
@@ -22762,7 +22490,7 @@ function useDataDnd(args) {
|
|
|
22762
22490
|
}, [parentRoot, isRoot, zoneId, meta]);
|
|
22763
22491
|
const sensors = useAlmadarDndSensors(true);
|
|
22764
22492
|
const collisionDetection = almadarDndCollisionDetection;
|
|
22765
|
-
const findZoneByItem =
|
|
22493
|
+
const findZoneByItem = React74__default.useCallback(
|
|
22766
22494
|
(id) => {
|
|
22767
22495
|
for (const z of zonesRef.current.values()) {
|
|
22768
22496
|
if (z.itemIds.includes(id)) return z;
|
|
@@ -22771,7 +22499,7 @@ function useDataDnd(args) {
|
|
|
22771
22499
|
},
|
|
22772
22500
|
[]
|
|
22773
22501
|
);
|
|
22774
|
-
|
|
22502
|
+
React74__default.useCallback(
|
|
22775
22503
|
(group) => {
|
|
22776
22504
|
for (const z of zonesRef.current.values()) {
|
|
22777
22505
|
if (z.group === group) return z;
|
|
@@ -22780,7 +22508,7 @@ function useDataDnd(args) {
|
|
|
22780
22508
|
},
|
|
22781
22509
|
[]
|
|
22782
22510
|
);
|
|
22783
|
-
const handleDragEnd =
|
|
22511
|
+
const handleDragEnd = React74__default.useCallback(
|
|
22784
22512
|
(event) => {
|
|
22785
22513
|
const { active, over } = event;
|
|
22786
22514
|
const activeIdStr = String(active.id);
|
|
@@ -22871,8 +22599,8 @@ function useDataDnd(args) {
|
|
|
22871
22599
|
},
|
|
22872
22600
|
[eventBus]
|
|
22873
22601
|
);
|
|
22874
|
-
const sortableData =
|
|
22875
|
-
const SortableItem =
|
|
22602
|
+
const sortableData = React74__default.useMemo(() => ({ dndGroup: ownGroup }), [ownGroup]);
|
|
22603
|
+
const SortableItem = React74__default.useCallback(
|
|
22876
22604
|
({ id, children }) => {
|
|
22877
22605
|
const {
|
|
22878
22606
|
attributes,
|
|
@@ -22912,7 +22640,7 @@ function useDataDnd(args) {
|
|
|
22912
22640
|
id: droppableId,
|
|
22913
22641
|
data: sortableData
|
|
22914
22642
|
});
|
|
22915
|
-
const ctx =
|
|
22643
|
+
const ctx = React74__default.useContext(RootCtx);
|
|
22916
22644
|
const activeDrag2 = ctx?.activeDrag ?? null;
|
|
22917
22645
|
const overZoneGroup2 = ctx?.overZoneGroup ?? null;
|
|
22918
22646
|
const isThisZoneOver = overZoneGroup2 === ownGroup;
|
|
@@ -22927,7 +22655,7 @@ function useDataDnd(args) {
|
|
|
22927
22655
|
showForeignPlaceholder,
|
|
22928
22656
|
ctxAvailable: ctx != null
|
|
22929
22657
|
});
|
|
22930
|
-
|
|
22658
|
+
React74__default.useEffect(() => {
|
|
22931
22659
|
dndLog.info("dropzone:isOver:change", { droppableId, group: ownGroup, isOver, isThisZoneOver, showForeignPlaceholder, activeDragSourceGroup: activeDrag2?.sourceGroup ?? null });
|
|
22932
22660
|
}, [droppableId, isOver, isThisZoneOver, showForeignPlaceholder]);
|
|
22933
22661
|
return /* @__PURE__ */ jsx(
|
|
@@ -22941,11 +22669,11 @@ function useDataDnd(args) {
|
|
|
22941
22669
|
}
|
|
22942
22670
|
);
|
|
22943
22671
|
};
|
|
22944
|
-
const rootContextValue =
|
|
22672
|
+
const rootContextValue = React74__default.useMemo(
|
|
22945
22673
|
() => ({ registerZone, unregisterZone, activeDrag, overZoneGroup, optimisticOrders, clearOptimisticOrder }),
|
|
22946
22674
|
[registerZone, unregisterZone, activeDrag, overZoneGroup, optimisticOrders, clearOptimisticOrder]
|
|
22947
22675
|
);
|
|
22948
|
-
const handleDragStart =
|
|
22676
|
+
const handleDragStart = React74__default.useCallback((event) => {
|
|
22949
22677
|
const sourceZone = findZoneByItem(event.active.id);
|
|
22950
22678
|
const rect = event.active.rect.current.initial;
|
|
22951
22679
|
const height = rect?.height && rect.height > 0 ? rect.height : 64;
|
|
@@ -22964,7 +22692,7 @@ function useDataDnd(args) {
|
|
|
22964
22692
|
isRoot
|
|
22965
22693
|
});
|
|
22966
22694
|
}, [findZoneByItem, isRoot, zoneId]);
|
|
22967
|
-
const handleDragOver =
|
|
22695
|
+
const handleDragOver = React74__default.useCallback((event) => {
|
|
22968
22696
|
const { active, over } = event;
|
|
22969
22697
|
const overData = over?.data?.current;
|
|
22970
22698
|
const overGroup = overData?.dndGroup ?? null;
|
|
@@ -23034,7 +22762,7 @@ function useDataDnd(args) {
|
|
|
23034
22762
|
return next;
|
|
23035
22763
|
});
|
|
23036
22764
|
}, []);
|
|
23037
|
-
const handleDragCancel =
|
|
22765
|
+
const handleDragCancel = React74__default.useCallback((event) => {
|
|
23038
22766
|
setActiveDrag(null);
|
|
23039
22767
|
setOverZoneGroup(null);
|
|
23040
22768
|
dndLog.warn("dragCancel", {
|
|
@@ -23042,12 +22770,12 @@ function useDataDnd(args) {
|
|
|
23042
22770
|
reason: "dnd-kit cancelled the drag (escape key, pointer interrupted, or external)"
|
|
23043
22771
|
});
|
|
23044
22772
|
}, []);
|
|
23045
|
-
const handleDragEndWithCleanup =
|
|
22773
|
+
const handleDragEndWithCleanup = React74__default.useCallback((event) => {
|
|
23046
22774
|
handleDragEnd(event);
|
|
23047
22775
|
setActiveDrag(null);
|
|
23048
22776
|
setOverZoneGroup(null);
|
|
23049
22777
|
}, [handleDragEnd]);
|
|
23050
|
-
const wrapContainer =
|
|
22778
|
+
const wrapContainer = React74__default.useCallback(
|
|
23051
22779
|
(children) => {
|
|
23052
22780
|
if (!enabled) return children;
|
|
23053
22781
|
const strategy = layout === "grid" ? rectSortingStrategy : verticalListSortingStrategy;
|
|
@@ -23101,7 +22829,7 @@ var init_useDataDnd = __esm({
|
|
|
23101
22829
|
init_useAlmadarDndCollision();
|
|
23102
22830
|
init_Box();
|
|
23103
22831
|
dndLog = createLogger("almadar:ui:dnd");
|
|
23104
|
-
RootCtx =
|
|
22832
|
+
RootCtx = React74__default.createContext(null);
|
|
23105
22833
|
}
|
|
23106
22834
|
});
|
|
23107
22835
|
function renderIconInput(icon, props) {
|
|
@@ -23627,7 +23355,7 @@ function DataList({
|
|
|
23627
23355
|
}) {
|
|
23628
23356
|
const eventBus = useEventBus();
|
|
23629
23357
|
const { t } = useTranslate();
|
|
23630
|
-
const [visibleCount, setVisibleCount] =
|
|
23358
|
+
const [visibleCount, setVisibleCount] = React74__default.useState(pageSize || Infinity);
|
|
23631
23359
|
const fieldDefs = fields ?? columns ?? [];
|
|
23632
23360
|
const allDataRaw = Array.isArray(entity) ? entity : entity ? [entity] : [];
|
|
23633
23361
|
const dnd = useDataDnd({
|
|
@@ -23646,7 +23374,7 @@ function DataList({
|
|
|
23646
23374
|
const data = pageSize > 0 ? allData.slice(0, visibleCount) : allData;
|
|
23647
23375
|
const hasMoreLocal = pageSize > 0 && visibleCount < allData.length;
|
|
23648
23376
|
const hasRenderProp = typeof children === "function";
|
|
23649
|
-
|
|
23377
|
+
React74__default.useEffect(() => {
|
|
23650
23378
|
const renderItemTypeOf = typeof schemaRenderItem;
|
|
23651
23379
|
const childrenTypeOf = typeof children;
|
|
23652
23380
|
if (data.length > 0 && !hasRenderProp) {
|
|
@@ -23750,7 +23478,7 @@ function DataList({
|
|
|
23750
23478
|
const items2 = [...data];
|
|
23751
23479
|
const groups2 = groupBy ? groupData(items2, groupBy) : [{ label: "", items: items2 }];
|
|
23752
23480
|
const contentField = titleField?.name ?? fieldDefs[0]?.name ?? "";
|
|
23753
|
-
return /* @__PURE__ */ jsx(VStack, { gap: "sm", className: cn("py-2", className), children: groups2.map((group, gi) => /* @__PURE__ */ jsxs(
|
|
23481
|
+
return /* @__PURE__ */ jsx(VStack, { gap: "sm", className: cn("py-2", className), children: groups2.map((group, gi) => /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
23754
23482
|
group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: "my-2" }),
|
|
23755
23483
|
group.items.map((itemData, index) => {
|
|
23756
23484
|
const id = itemData.id || `${gi}-${index}`;
|
|
@@ -23891,7 +23619,7 @@ function DataList({
|
|
|
23891
23619
|
className
|
|
23892
23620
|
),
|
|
23893
23621
|
children: [
|
|
23894
|
-
groups.map((group, gi) => /* @__PURE__ */ jsxs(
|
|
23622
|
+
groups.map((group, gi) => /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
23895
23623
|
group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: gi > 0 ? "mt-4" : "mt-0" }),
|
|
23896
23624
|
group.items.map(
|
|
23897
23625
|
(itemData, index) => renderItem(itemData, index, gi === groups.length - 1 && index === group.items.length - 1)
|
|
@@ -23998,8 +23726,8 @@ function ScalarControl({
|
|
|
23998
23726
|
}
|
|
23999
23727
|
const numeric = typeof value === "number";
|
|
24000
23728
|
const initial = value === null ? "" : String(value);
|
|
24001
|
-
const [draft, setDraft] =
|
|
24002
|
-
|
|
23729
|
+
const [draft, setDraft] = React74__default.useState(initial);
|
|
23730
|
+
React74__default.useEffect(() => setDraft(initial), [initial]);
|
|
24003
23731
|
const commit = () => {
|
|
24004
23732
|
if (numeric) {
|
|
24005
23733
|
const n = draft.trim() === "" ? 0 : Number(draft);
|
|
@@ -24067,8 +23795,8 @@ function Row({
|
|
|
24067
23795
|
onRemove,
|
|
24068
23796
|
readonly
|
|
24069
23797
|
}) {
|
|
24070
|
-
const [keyDraft, setKeyDraft] =
|
|
24071
|
-
|
|
23798
|
+
const [keyDraft, setKeyDraft] = React74__default.useState(rowKey);
|
|
23799
|
+
React74__default.useEffect(() => setKeyDraft(rowKey), [rowKey]);
|
|
24072
23800
|
const container = isObj(value) || isArr(value);
|
|
24073
23801
|
return /* @__PURE__ */ jsxs(VStack, { gap: "none", className: "group w-max min-w-full", children: [
|
|
24074
23802
|
/* @__PURE__ */ jsxs(HStack, { gap: "xs", align: "center", className: "py-0.5 w-max", children: [
|
|
@@ -24111,7 +23839,7 @@ function ContainerNode({
|
|
|
24111
23839
|
depth,
|
|
24112
23840
|
readonly
|
|
24113
23841
|
}) {
|
|
24114
|
-
const [open, setOpen] =
|
|
23842
|
+
const [open, setOpen] = React74__default.useState(depth < 2);
|
|
24115
23843
|
const array = isArr(value);
|
|
24116
23844
|
const entries = array ? value.map((v, i) => [String(i), v]) : Object.entries(value);
|
|
24117
23845
|
const setObjValue = (key, next) => {
|
|
@@ -24253,7 +23981,7 @@ var init_FormSection = __esm({
|
|
|
24253
23981
|
columns = 1,
|
|
24254
23982
|
className
|
|
24255
23983
|
}) => {
|
|
24256
|
-
const [collapsed, setCollapsed] =
|
|
23984
|
+
const [collapsed, setCollapsed] = React74__default.useState(defaultCollapsed);
|
|
24257
23985
|
const { t } = useTranslate();
|
|
24258
23986
|
const eventBus = useEventBus();
|
|
24259
23987
|
const gridClass = {
|
|
@@ -24261,7 +23989,7 @@ var init_FormSection = __esm({
|
|
|
24261
23989
|
2: "grid-cols-1 md:grid-cols-2",
|
|
24262
23990
|
3: "grid-cols-1 md:grid-cols-2 lg:grid-cols-3"
|
|
24263
23991
|
}[columns];
|
|
24264
|
-
|
|
23992
|
+
React74__default.useCallback(() => {
|
|
24265
23993
|
if (collapsible) {
|
|
24266
23994
|
setCollapsed((prev) => !prev);
|
|
24267
23995
|
eventBus.emit("UI:TOGGLE_COLLAPSE", { collapsed: !collapsed });
|
|
@@ -24669,8 +24397,8 @@ function TextLikeControl({
|
|
|
24669
24397
|
onCommit
|
|
24670
24398
|
}) {
|
|
24671
24399
|
const initial = value === void 0 || value === null ? "" : String(value);
|
|
24672
|
-
const [draft, setDraft] =
|
|
24673
|
-
|
|
24400
|
+
const [draft, setDraft] = React74__default.useState(initial);
|
|
24401
|
+
React74__default.useEffect(() => setDraft(initial), [initial]);
|
|
24674
24402
|
const commit = () => {
|
|
24675
24403
|
if (numeric) {
|
|
24676
24404
|
const n = draft.trim() === "" ? 0 : Number(draft);
|
|
@@ -24855,14 +24583,14 @@ var init_NodeSlotEditor = __esm({
|
|
|
24855
24583
|
isObj2 = (v) => v !== null && v !== void 0 && typeof v === "object" && !Array.isArray(v);
|
|
24856
24584
|
NodeSlotEditor = ({ value, onChange, className }) => {
|
|
24857
24585
|
const { type, props, wasArray } = normalize(value);
|
|
24858
|
-
const patterns =
|
|
24586
|
+
const patterns = React74__default.useMemo(() => {
|
|
24859
24587
|
try {
|
|
24860
24588
|
return [...getKnownPatterns()].sort();
|
|
24861
24589
|
} catch {
|
|
24862
24590
|
return [];
|
|
24863
24591
|
}
|
|
24864
24592
|
}, []);
|
|
24865
|
-
const options =
|
|
24593
|
+
const options = React74__default.useMemo(
|
|
24866
24594
|
() => [{ value: "", label: "\u2014 none \u2014" }, ...patterns.map((p2) => ({ value: p2, label: p2 }))],
|
|
24867
24595
|
[patterns]
|
|
24868
24596
|
);
|
|
@@ -24874,7 +24602,7 @@ var init_NodeSlotEditor = __esm({
|
|
|
24874
24602
|
const pattern = { type: nextType, ...nextProps };
|
|
24875
24603
|
onChange(wasArray || value === void 0 ? [pattern] : pattern);
|
|
24876
24604
|
};
|
|
24877
|
-
const schemaEntries =
|
|
24605
|
+
const schemaEntries = React74__default.useMemo(() => {
|
|
24878
24606
|
if (!type) return [];
|
|
24879
24607
|
const def = getPatternDefinition(type);
|
|
24880
24608
|
if (!def?.propsSchema) return [];
|
|
@@ -25776,7 +25504,7 @@ var init_Flex = __esm({
|
|
|
25776
25504
|
flexStyle.flexBasis = typeof basis === "number" ? `${basis}px` : basis;
|
|
25777
25505
|
}
|
|
25778
25506
|
}
|
|
25779
|
-
return
|
|
25507
|
+
return React74__default.createElement(Component, {
|
|
25780
25508
|
className: cn(
|
|
25781
25509
|
inline ? "inline-flex" : "flex",
|
|
25782
25510
|
directionStyles[direction],
|
|
@@ -25895,7 +25623,7 @@ var init_Grid = __esm({
|
|
|
25895
25623
|
as: Component = "div"
|
|
25896
25624
|
}) => {
|
|
25897
25625
|
const mergedStyle = rows2 ? { gridTemplateRows: `repeat(${rows2}, minmax(0, 1fr))`, ...style } : style;
|
|
25898
|
-
return
|
|
25626
|
+
return React74__default.createElement(
|
|
25899
25627
|
Component,
|
|
25900
25628
|
{
|
|
25901
25629
|
className: cn(
|
|
@@ -26091,9 +25819,9 @@ var init_Popover = __esm({
|
|
|
26091
25819
|
onMouseLeave: handleClose,
|
|
26092
25820
|
onPointerDown: tapTriggerProps.onPointerDown
|
|
26093
25821
|
};
|
|
26094
|
-
const childElement =
|
|
25822
|
+
const childElement = React74__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
|
|
26095
25823
|
const childPointerDown = childElement.props.onPointerDown;
|
|
26096
|
-
const triggerElement =
|
|
25824
|
+
const triggerElement = React74__default.cloneElement(
|
|
26097
25825
|
childElement,
|
|
26098
25826
|
{
|
|
26099
25827
|
ref: triggerRef,
|
|
@@ -26945,9 +26673,9 @@ var init_Tooltip = __esm({
|
|
|
26945
26673
|
if (hideTimeoutRef.current) clearTimeout(hideTimeoutRef.current);
|
|
26946
26674
|
};
|
|
26947
26675
|
}, []);
|
|
26948
|
-
const triggerElement =
|
|
26676
|
+
const triggerElement = React74__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
|
|
26949
26677
|
const childPointerDown = triggerElement.props.onPointerDown;
|
|
26950
|
-
const trigger =
|
|
26678
|
+
const trigger = React74__default.cloneElement(triggerElement, {
|
|
26951
26679
|
ref: triggerRef,
|
|
26952
26680
|
onMouseEnter: handleMouseEnter,
|
|
26953
26681
|
onMouseLeave: handleMouseLeave,
|
|
@@ -27037,7 +26765,7 @@ var init_WizardProgress = __esm({
|
|
|
27037
26765
|
children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2", children: normalizedSteps.map((step, index) => {
|
|
27038
26766
|
const isActive = index === currentStep;
|
|
27039
26767
|
const isCompleted = index < currentStep;
|
|
27040
|
-
return /* @__PURE__ */ jsxs(
|
|
26768
|
+
return /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
27041
26769
|
/* @__PURE__ */ jsx(
|
|
27042
26770
|
"button",
|
|
27043
26771
|
{
|
|
@@ -28124,6 +27852,95 @@ var init_shared = __esm({
|
|
|
28124
27852
|
init_canvasEffects();
|
|
28125
27853
|
}
|
|
28126
27854
|
});
|
|
27855
|
+
function GameCard({
|
|
27856
|
+
id,
|
|
27857
|
+
cost,
|
|
27858
|
+
art,
|
|
27859
|
+
frameAsset,
|
|
27860
|
+
attack,
|
|
27861
|
+
defense,
|
|
27862
|
+
name,
|
|
27863
|
+
selected = false,
|
|
27864
|
+
disabled = false,
|
|
27865
|
+
size = "md",
|
|
27866
|
+
onClick,
|
|
27867
|
+
clickEvent,
|
|
27868
|
+
className
|
|
27869
|
+
}) {
|
|
27870
|
+
const eventBus = useEventBus();
|
|
27871
|
+
const handleClick = React74.useCallback(() => {
|
|
27872
|
+
if (disabled) return;
|
|
27873
|
+
onClick?.(id);
|
|
27874
|
+
if (clickEvent) eventBus.emit(`UI:${clickEvent}`, { cardId: id });
|
|
27875
|
+
}, [disabled, id, onClick, clickEvent, eventBus]);
|
|
27876
|
+
const artPx = artPxMap[size];
|
|
27877
|
+
const frameStyle = frameAsset?.url ? { backgroundImage: `url(${frameAsset.url})`, backgroundSize: "100% 100%", backgroundRepeat: "no-repeat" } : {};
|
|
27878
|
+
return /* @__PURE__ */ jsxs(
|
|
27879
|
+
Button,
|
|
27880
|
+
{
|
|
27881
|
+
variant: "ghost",
|
|
27882
|
+
onClick: handleClick,
|
|
27883
|
+
disabled,
|
|
27884
|
+
title: name,
|
|
27885
|
+
style: frameStyle,
|
|
27886
|
+
className: cn(
|
|
27887
|
+
"relative flex flex-col items-center rounded-interactive",
|
|
27888
|
+
"bg-card/90 px-1.5 pt-1.5 pb-1 transition-all duration-150",
|
|
27889
|
+
frameAsset?.url ? "border-0" : "border-2",
|
|
27890
|
+
cardSizeMap[size],
|
|
27891
|
+
disabled ? "border-border opacity-50 cursor-not-allowed" : "border-accent hover:brightness-125 hover:-translate-y-1 cursor-pointer",
|
|
27892
|
+
selected && "ring-2 ring-foreground ring-offset-1 ring-offset-background -translate-y-1",
|
|
27893
|
+
className
|
|
27894
|
+
),
|
|
27895
|
+
children: [
|
|
27896
|
+
cost != null && /* @__PURE__ */ jsx(
|
|
27897
|
+
Typography,
|
|
27898
|
+
{
|
|
27899
|
+
as: "span",
|
|
27900
|
+
className: cn(
|
|
27901
|
+
"absolute -top-2 -left-2 flex items-center justify-center",
|
|
27902
|
+
"min-w-[22px] h-[22px] rounded-full px-1",
|
|
27903
|
+
"bg-info text-foreground text-xs font-bold border border-background"
|
|
27904
|
+
),
|
|
27905
|
+
children: cost
|
|
27906
|
+
}
|
|
27907
|
+
),
|
|
27908
|
+
/* @__PURE__ */ jsx(Box, { className: "flex-1 flex items-center justify-center w-full", children: art ? /* @__PURE__ */ jsx(GameIcon, { assetUrl: art, icon: "image", size: artPx, alt: name ?? id, className: "flex-shrink-0" }) : /* @__PURE__ */ jsx(Box, { className: "rounded bg-muted/40", style: { width: artPx, height: artPx } }) }),
|
|
27909
|
+
name != null && /* @__PURE__ */ jsx(
|
|
27910
|
+
Typography,
|
|
27911
|
+
{
|
|
27912
|
+
variant: "small",
|
|
27913
|
+
className: "w-full truncate text-center text-[10px] leading-tight font-semibold",
|
|
27914
|
+
children: name
|
|
27915
|
+
}
|
|
27916
|
+
),
|
|
27917
|
+
(attack != null || defense != null) && /* @__PURE__ */ jsxs(Box, { className: "flex w-full items-center justify-between px-0.5 text-[10px] font-bold leading-none", children: [
|
|
27918
|
+
/* @__PURE__ */ jsx(Typography, { as: "span", className: "text-error", children: attack != null ? `\u2694${attack}` : "" }),
|
|
27919
|
+
/* @__PURE__ */ jsx(Typography, { as: "span", className: "text-info", children: defense != null ? `\u{1F6E1}${defense}` : "" })
|
|
27920
|
+
] })
|
|
27921
|
+
]
|
|
27922
|
+
}
|
|
27923
|
+
);
|
|
27924
|
+
}
|
|
27925
|
+
var cardSizeMap, artPxMap;
|
|
27926
|
+
var init_GameCard = __esm({
|
|
27927
|
+
"components/game/2d/atoms/GameCard.tsx"() {
|
|
27928
|
+
"use client";
|
|
27929
|
+
init_cn();
|
|
27930
|
+
init_useEventBus();
|
|
27931
|
+
init_Box();
|
|
27932
|
+
init_Button();
|
|
27933
|
+
init_Typography();
|
|
27934
|
+
init_GameIcon();
|
|
27935
|
+
cardSizeMap = {
|
|
27936
|
+
sm: "w-16 h-24",
|
|
27937
|
+
md: "w-20 h-28",
|
|
27938
|
+
lg: "w-24 h-36"
|
|
27939
|
+
};
|
|
27940
|
+
artPxMap = { sm: 40, md: 52, lg: 64 };
|
|
27941
|
+
GameCard.displayName = "GameCard";
|
|
27942
|
+
}
|
|
27943
|
+
});
|
|
28127
27944
|
function ScoreDisplay({
|
|
28128
27945
|
assetUrl = DEFAULT_ASSET_URL5,
|
|
28129
27946
|
value,
|
|
@@ -28943,7 +28760,7 @@ function InventoryGrid({
|
|
|
28943
28760
|
const eventBus = useEventBus();
|
|
28944
28761
|
const slotCount = totalSlots ?? items.length;
|
|
28945
28762
|
const emptySlotCount = Math.max(0, slotCount - items.length);
|
|
28946
|
-
const handleSelect =
|
|
28763
|
+
const handleSelect = React74.useCallback(
|
|
28947
28764
|
(id) => {
|
|
28948
28765
|
onSelect?.(id);
|
|
28949
28766
|
if (selectEvent) {
|
|
@@ -29160,7 +28977,7 @@ function GameMenu({
|
|
|
29160
28977
|
}) {
|
|
29161
28978
|
const resolvedOptions = options ?? menuItems ?? DEFAULT_MENU_OPTIONS;
|
|
29162
28979
|
const eventBus = useEventBus();
|
|
29163
|
-
const handleOptionClick =
|
|
28980
|
+
const handleOptionClick = React74.useCallback(
|
|
29164
28981
|
(option) => {
|
|
29165
28982
|
if (option.event) {
|
|
29166
28983
|
eventBus.emit(`UI:${option.event}`, { option });
|
|
@@ -29680,227 +29497,6 @@ var init_GameAudioToggle = __esm({
|
|
|
29680
29497
|
GameAudioToggle.displayName = "GameAudioToggle";
|
|
29681
29498
|
}
|
|
29682
29499
|
});
|
|
29683
|
-
function VisualNovelBoard({
|
|
29684
|
-
entity,
|
|
29685
|
-
nodes: propNodes,
|
|
29686
|
-
currentNodeId: propCurrentNodeId,
|
|
29687
|
-
assetManifest: propAssetManifest,
|
|
29688
|
-
typewriterSpeed = 30,
|
|
29689
|
-
portraitScale = 1,
|
|
29690
|
-
chooseEvent,
|
|
29691
|
-
advanceEvent,
|
|
29692
|
-
restartEvent,
|
|
29693
|
-
className
|
|
29694
|
-
}) {
|
|
29695
|
-
const board = boardEntity(entity) ?? {};
|
|
29696
|
-
const eventBus = useEventBus();
|
|
29697
|
-
const assetManifest = propAssetManifest ?? board.assetManifest;
|
|
29698
|
-
const entityNodes = useMemo(
|
|
29699
|
-
() => rows(board.nodes).map((r) => ({
|
|
29700
|
-
id: str(r.id),
|
|
29701
|
-
speaker: str(r.speaker),
|
|
29702
|
-
text: str(r.text),
|
|
29703
|
-
backgroundKey: r.backgroundKey == null ? void 0 : str(r.backgroundKey),
|
|
29704
|
-
portraitKey: r.portraitKey == null ? void 0 : str(r.portraitKey),
|
|
29705
|
-
choices: rows(r.choices).map((c) => ({
|
|
29706
|
-
label: str(c.label),
|
|
29707
|
-
nextId: str(c.nextId)
|
|
29708
|
-
}))
|
|
29709
|
-
})),
|
|
29710
|
-
[board.nodes]
|
|
29711
|
-
);
|
|
29712
|
-
const rawNodes = propNodes ?? entityNodes;
|
|
29713
|
-
const nodes = rawNodes.length > 0 ? rawNodes : DEFAULT_NODES;
|
|
29714
|
-
const currentNodeId = propCurrentNodeId ?? (str(board.currentNodeId) || nodes[0]?.id);
|
|
29715
|
-
const currentNode = nodes.find((n) => n.id === currentNodeId) ?? nodes[0];
|
|
29716
|
-
const backgroundImage = useMemo(
|
|
29717
|
-
() => assetManifest?.backgrounds?.[currentNode?.backgroundKey ?? ""],
|
|
29718
|
-
[assetManifest, currentNode?.backgroundKey]
|
|
29719
|
-
);
|
|
29720
|
-
const portraitAsset = useMemo(
|
|
29721
|
-
() => assetManifest?.portraits?.[currentNode?.portraitKey ?? ""],
|
|
29722
|
-
[assetManifest, currentNode?.portraitKey]
|
|
29723
|
-
);
|
|
29724
|
-
const [displayedText, setDisplayedText] = useState("");
|
|
29725
|
-
const [isTyping, setIsTyping] = useState(false);
|
|
29726
|
-
const textRef = useRef(currentNode?.text ?? "");
|
|
29727
|
-
const charIndexRef = useRef(0);
|
|
29728
|
-
useEffect(() => {
|
|
29729
|
-
const fullText = currentNode?.text ?? "";
|
|
29730
|
-
textRef.current = fullText;
|
|
29731
|
-
charIndexRef.current = 0;
|
|
29732
|
-
if (typewriterSpeed === 0) {
|
|
29733
|
-
setDisplayedText(fullText);
|
|
29734
|
-
setIsTyping(false);
|
|
29735
|
-
} else {
|
|
29736
|
-
setDisplayedText("");
|
|
29737
|
-
setIsTyping(true);
|
|
29738
|
-
}
|
|
29739
|
-
}, [currentNode?.id, typewriterSpeed]);
|
|
29740
|
-
useEffect(() => {
|
|
29741
|
-
if (!isTyping || typewriterSpeed === 0) return;
|
|
29742
|
-
const interval = setInterval(() => {
|
|
29743
|
-
if (charIndexRef.current < textRef.current.length) {
|
|
29744
|
-
charIndexRef.current++;
|
|
29745
|
-
setDisplayedText(textRef.current.slice(0, charIndexRef.current));
|
|
29746
|
-
} else {
|
|
29747
|
-
setIsTyping(false);
|
|
29748
|
-
clearInterval(interval);
|
|
29749
|
-
}
|
|
29750
|
-
}, typewriterSpeed);
|
|
29751
|
-
return () => clearInterval(interval);
|
|
29752
|
-
}, [isTyping, typewriterSpeed]);
|
|
29753
|
-
const skipTypewriter = useCallback(() => {
|
|
29754
|
-
if (isTyping) {
|
|
29755
|
-
charIndexRef.current = textRef.current.length;
|
|
29756
|
-
setDisplayedText(textRef.current);
|
|
29757
|
-
setIsTyping(false);
|
|
29758
|
-
}
|
|
29759
|
-
}, [isTyping]);
|
|
29760
|
-
const handleChoice = useCallback(
|
|
29761
|
-
(index) => {
|
|
29762
|
-
if (chooseEvent) {
|
|
29763
|
-
eventBus.emit(`UI:${chooseEvent}`, { choiceIndex: index });
|
|
29764
|
-
}
|
|
29765
|
-
},
|
|
29766
|
-
[chooseEvent, eventBus]
|
|
29767
|
-
);
|
|
29768
|
-
const handleAdvance = useCallback(() => {
|
|
29769
|
-
if (advanceEvent) {
|
|
29770
|
-
eventBus.emit(`UI:${advanceEvent}`, {});
|
|
29771
|
-
}
|
|
29772
|
-
}, [advanceEvent, eventBus]);
|
|
29773
|
-
const handleRestart = useCallback(() => {
|
|
29774
|
-
if (restartEvent) {
|
|
29775
|
-
eventBus.emit(`UI:${restartEvent}`, {});
|
|
29776
|
-
}
|
|
29777
|
-
}, [restartEvent, eventBus]);
|
|
29778
|
-
const handleContainerClick = useCallback(() => {
|
|
29779
|
-
if (isTyping) {
|
|
29780
|
-
skipTypewriter();
|
|
29781
|
-
} else if (!currentNode?.choices?.length) {
|
|
29782
|
-
handleAdvance();
|
|
29783
|
-
}
|
|
29784
|
-
}, [isTyping, skipTypewriter, currentNode?.choices, handleAdvance]);
|
|
29785
|
-
if (!currentNode) {
|
|
29786
|
-
return /* @__PURE__ */ jsxs(VStack, { className: cn("visual-novel-board relative min-h-[600px] bg-background items-center justify-center", className), gap: "lg", children: [
|
|
29787
|
-
/* @__PURE__ */ jsx(Typography, { variant: "h3", color: "muted", children: "No dialogue nodes" }),
|
|
29788
|
-
/* @__PURE__ */ jsx(Button, { variant: "primary", onClick: handleRestart, children: "Restart" })
|
|
29789
|
-
] });
|
|
29790
|
-
}
|
|
29791
|
-
return /* @__PURE__ */ jsxs(
|
|
29792
|
-
Box,
|
|
29793
|
-
{
|
|
29794
|
-
className: cn("visual-novel-board relative min-h-[600px] bg-background overflow-hidden", className),
|
|
29795
|
-
onClick: handleContainerClick,
|
|
29796
|
-
children: [
|
|
29797
|
-
backgroundImage && /* @__PURE__ */ jsx(
|
|
29798
|
-
"div",
|
|
29799
|
-
{
|
|
29800
|
-
className: "absolute inset-0 z-0 bg-center bg-cover bg-no-repeat",
|
|
29801
|
-
style: { backgroundImage: `url(${backgroundImage.url})` },
|
|
29802
|
-
"aria-hidden": "true"
|
|
29803
|
-
}
|
|
29804
|
-
),
|
|
29805
|
-
portraitAsset && /* @__PURE__ */ jsx(
|
|
29806
|
-
"div",
|
|
29807
|
-
{
|
|
29808
|
-
className: "absolute left-1/2 -translate-x-1/2 bottom-0 z-10 pointer-events-none flex items-end",
|
|
29809
|
-
style: { height: `${60 * portraitScale}vh` },
|
|
29810
|
-
children: /* @__PURE__ */ jsx(
|
|
29811
|
-
"img",
|
|
29812
|
-
{
|
|
29813
|
-
src: portraitAsset.url,
|
|
29814
|
-
alt: currentNode.speaker,
|
|
29815
|
-
className: "h-full w-auto object-contain drop-shadow-2xl"
|
|
29816
|
-
}
|
|
29817
|
-
)
|
|
29818
|
-
}
|
|
29819
|
-
),
|
|
29820
|
-
/* @__PURE__ */ jsx("div", { className: "absolute left-0 right-0 bottom-0 z-20 mx-4 mb-4", children: /* @__PURE__ */ jsxs("div", { className: cn(
|
|
29821
|
-
"rounded-container border-2 overflow-hidden",
|
|
29822
|
-
backgroundImage ? "bg-black/80 backdrop-blur-sm border-white/20" : "bg-card/95 border-border"
|
|
29823
|
-
), children: [
|
|
29824
|
-
/* @__PURE__ */ jsx(
|
|
29825
|
-
DialogueBubble,
|
|
29826
|
-
{
|
|
29827
|
-
speaker: currentNode.speaker,
|
|
29828
|
-
text: displayedText + (isTyping ? "\u258C" : ""),
|
|
29829
|
-
portrait: portraitAsset,
|
|
29830
|
-
position: "bottom",
|
|
29831
|
-
className: "border-0 rounded-none bg-transparent backdrop-blur-none"
|
|
29832
|
-
}
|
|
29833
|
-
),
|
|
29834
|
-
!isTyping && (currentNode.choices?.length ?? 0) > 0 && /* @__PURE__ */ jsx("div", { className: "px-4 pb-4 space-y-2", onClick: (e) => e.stopPropagation(), children: currentNode.choices.map((choice, index) => /* @__PURE__ */ jsx(
|
|
29835
|
-
ChoiceButton,
|
|
29836
|
-
{
|
|
29837
|
-
text: choice.label,
|
|
29838
|
-
index: index + 1,
|
|
29839
|
-
onClick: () => handleChoice(index)
|
|
29840
|
-
},
|
|
29841
|
-
choice.nextId
|
|
29842
|
-
)) }),
|
|
29843
|
-
!isTyping && !currentNode.choices?.length && /* @__PURE__ */ jsx("div", { className: "px-4 pb-3 text-muted-foreground text-sm animate-pulse", children: "Press click to continue..." })
|
|
29844
|
-
] }) })
|
|
29845
|
-
]
|
|
29846
|
-
}
|
|
29847
|
-
);
|
|
29848
|
-
}
|
|
29849
|
-
var DEFAULT_NODES;
|
|
29850
|
-
var init_VisualNovelBoard = __esm({
|
|
29851
|
-
"components/game/2d/organisms/VisualNovelBoard.tsx"() {
|
|
29852
|
-
"use client";
|
|
29853
|
-
init_cn();
|
|
29854
|
-
init_useEventBus();
|
|
29855
|
-
init_Box();
|
|
29856
|
-
init_Typography();
|
|
29857
|
-
init_Stack();
|
|
29858
|
-
init_Button();
|
|
29859
|
-
init_DialogueBubble();
|
|
29860
|
-
init_ChoiceButton();
|
|
29861
|
-
init_boardEntity();
|
|
29862
|
-
DEFAULT_NODES = [
|
|
29863
|
-
{
|
|
29864
|
-
id: "start",
|
|
29865
|
-
speaker: "Narrator",
|
|
29866
|
-
text: "The corridor stretches into shadow. A lone sentinel blocks your path.",
|
|
29867
|
-
backgroundKey: "corridor",
|
|
29868
|
-
portraitKey: "guide",
|
|
29869
|
-
choices: [
|
|
29870
|
-
{ label: "Approach the sentinel.", nextId: "meet" },
|
|
29871
|
-
{ label: "Turn back.", nextId: "retreat" }
|
|
29872
|
-
]
|
|
29873
|
-
},
|
|
29874
|
-
{
|
|
29875
|
-
id: "meet",
|
|
29876
|
-
speaker: "Sentinel",
|
|
29877
|
-
text: "You carry the old marks. Speak your purpose, traveler.",
|
|
29878
|
-
backgroundKey: "forge",
|
|
29879
|
-
portraitKey: "rival",
|
|
29880
|
-
choices: [
|
|
29881
|
-
{ label: "I seek the core.", nextId: "end" },
|
|
29882
|
-
{ label: "I am only passing through.", nextId: "retreat" }
|
|
29883
|
-
]
|
|
29884
|
-
},
|
|
29885
|
-
{
|
|
29886
|
-
id: "retreat",
|
|
29887
|
-
speaker: "Narrator",
|
|
29888
|
-
text: "You withdraw into the dark. The path will wait for braver feet.",
|
|
29889
|
-
backgroundKey: "corridor",
|
|
29890
|
-
choices: [{ label: "Begin again.", nextId: "start" }]
|
|
29891
|
-
},
|
|
29892
|
-
{
|
|
29893
|
-
id: "end",
|
|
29894
|
-
speaker: "Sentinel",
|
|
29895
|
-
text: "Then the way is open. Walk it well.",
|
|
29896
|
-
backgroundKey: "core",
|
|
29897
|
-
portraitKey: "rival",
|
|
29898
|
-
choices: [{ label: "Begin again.", nextId: "start" }]
|
|
29899
|
-
}
|
|
29900
|
-
];
|
|
29901
|
-
VisualNovelBoard.displayName = "VisualNovelBoard";
|
|
29902
|
-
}
|
|
29903
|
-
});
|
|
29904
29500
|
function LinearView({
|
|
29905
29501
|
trait,
|
|
29906
29502
|
size = "md",
|
|
@@ -29912,7 +29508,7 @@ function LinearView({
|
|
|
29912
29508
|
/* @__PURE__ */ jsx(HStack, { className: "flex-wrap items-center", gap: "xs", children: trait.states.map((state, i) => {
|
|
29913
29509
|
const isDone = i < currentIdx;
|
|
29914
29510
|
const isCurrent = i === currentIdx;
|
|
29915
|
-
return /* @__PURE__ */ jsxs(
|
|
29511
|
+
return /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
29916
29512
|
i > 0 && /* @__PURE__ */ jsx(
|
|
29917
29513
|
Typography,
|
|
29918
29514
|
{
|
|
@@ -30538,7 +30134,7 @@ function SequenceBar({
|
|
|
30538
30134
|
onSlotRemove(index);
|
|
30539
30135
|
}, [onSlotRemove, playing]);
|
|
30540
30136
|
const paddedSlots = Array.from({ length: maxSlots }, (_, i) => slots[i]);
|
|
30541
|
-
return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(
|
|
30137
|
+
return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
30542
30138
|
i > 0 && /* @__PURE__ */ jsx(
|
|
30543
30139
|
Typography,
|
|
30544
30140
|
{
|
|
@@ -33010,8 +32606,6 @@ var init_molecules = __esm({
|
|
|
33010
32606
|
init_GameAudioToggle();
|
|
33011
32607
|
init_useGameAudio();
|
|
33012
32608
|
init_useCamera();
|
|
33013
|
-
init_VisualNovelBoard();
|
|
33014
|
-
init_CardBattlerBoard();
|
|
33015
32609
|
init_TraitStateViewer();
|
|
33016
32610
|
init_TraitSlot();
|
|
33017
32611
|
init_editorUtils();
|
|
@@ -33641,13 +33235,13 @@ var init_MapView = __esm({
|
|
|
33641
33235
|
shadowSize: [41, 41]
|
|
33642
33236
|
});
|
|
33643
33237
|
L.Marker.prototype.options.icon = defaultIcon;
|
|
33644
|
-
const { useEffect:
|
|
33238
|
+
const { useEffect: useEffect72, useRef: useRef68, useCallback: useCallback116, useState: useState110 } = React74__default;
|
|
33645
33239
|
const { Typography: Typography2 } = await Promise.resolve().then(() => (init_Typography(), Typography_exports));
|
|
33646
33240
|
const { useEventBus: useEventBus2 } = await Promise.resolve().then(() => (init_useEventBus(), useEventBus_exports));
|
|
33647
33241
|
function MapUpdater({ centerLat, centerLng, zoom }) {
|
|
33648
33242
|
const map = useMap();
|
|
33649
|
-
const prevRef =
|
|
33650
|
-
|
|
33243
|
+
const prevRef = useRef68({ centerLat, centerLng, zoom });
|
|
33244
|
+
useEffect72(() => {
|
|
33651
33245
|
const prev = prevRef.current;
|
|
33652
33246
|
if (prev.centerLat !== centerLat || prev.centerLng !== centerLng || prev.zoom !== zoom) {
|
|
33653
33247
|
map.setView([centerLat, centerLng], zoom);
|
|
@@ -33658,7 +33252,7 @@ var init_MapView = __esm({
|
|
|
33658
33252
|
}
|
|
33659
33253
|
function MapClickHandler({ onMapClick }) {
|
|
33660
33254
|
const map = useMap();
|
|
33661
|
-
|
|
33255
|
+
useEffect72(() => {
|
|
33662
33256
|
if (!onMapClick) return;
|
|
33663
33257
|
const handler = (e) => {
|
|
33664
33258
|
onMapClick(e.latlng.lat, e.latlng.lng);
|
|
@@ -33686,8 +33280,8 @@ var init_MapView = __esm({
|
|
|
33686
33280
|
showAttribution = true
|
|
33687
33281
|
}) {
|
|
33688
33282
|
const eventBus = useEventBus2();
|
|
33689
|
-
const [clickedPosition, setClickedPosition] =
|
|
33690
|
-
const handleMapClick =
|
|
33283
|
+
const [clickedPosition, setClickedPosition] = useState110(null);
|
|
33284
|
+
const handleMapClick = useCallback116((lat, lng) => {
|
|
33691
33285
|
if (showClickedPin) {
|
|
33692
33286
|
setClickedPosition({ lat, lng });
|
|
33693
33287
|
}
|
|
@@ -33696,7 +33290,7 @@ var init_MapView = __esm({
|
|
|
33696
33290
|
eventBus.emit(`UI:${mapClickEvent}`, { latitude: lat, longitude: lng });
|
|
33697
33291
|
}
|
|
33698
33292
|
}, [onMapClick, mapClickEvent, eventBus, showClickedPin]);
|
|
33699
|
-
const handleMarkerClick =
|
|
33293
|
+
const handleMarkerClick = useCallback116((marker) => {
|
|
33700
33294
|
onMarkerClick?.(marker);
|
|
33701
33295
|
if (markerClickEvent) {
|
|
33702
33296
|
eventBus.emit(`UI:${markerClickEvent}`, { ...marker });
|
|
@@ -34556,8 +34150,8 @@ function TableView({
|
|
|
34556
34150
|
}) {
|
|
34557
34151
|
const eventBus = useEventBus();
|
|
34558
34152
|
const { t } = useTranslate();
|
|
34559
|
-
const [visibleCount, setVisibleCount] =
|
|
34560
|
-
const [localSelected, setLocalSelected] =
|
|
34153
|
+
const [visibleCount, setVisibleCount] = React74__default.useState(pageSize > 0 ? pageSize : Infinity);
|
|
34154
|
+
const [localSelected, setLocalSelected] = React74__default.useState(/* @__PURE__ */ new Set());
|
|
34561
34155
|
const colDefs = columns ?? fields ?? [];
|
|
34562
34156
|
const allDataRaw = Array.isArray(entity) ? entity : entity ? [entity] : [];
|
|
34563
34157
|
const dnd = useDataDnd({
|
|
@@ -34752,12 +34346,12 @@ function TableView({
|
|
|
34752
34346
|
]
|
|
34753
34347
|
}
|
|
34754
34348
|
);
|
|
34755
|
-
return dnd.isZone ? /* @__PURE__ */ jsx(dnd.SortableItem, { id: row[idField] ?? id, children: rowInner }, id) : /* @__PURE__ */ jsx(
|
|
34349
|
+
return dnd.isZone ? /* @__PURE__ */ jsx(dnd.SortableItem, { id: row[idField] ?? id, children: rowInner }, id) : /* @__PURE__ */ jsx(React74__default.Fragment, { children: rowInner }, id);
|
|
34756
34350
|
};
|
|
34757
34351
|
const items = Array.from(data);
|
|
34758
34352
|
const groups = groupBy ? groupData2(items, groupBy) : [{ label: "", items }];
|
|
34759
34353
|
let runningIndex = 0;
|
|
34760
|
-
const body = /* @__PURE__ */ jsx(Box, { role: "rowgroup", children: groups.map((group, gi) => /* @__PURE__ */ jsxs(
|
|
34354
|
+
const body = /* @__PURE__ */ jsx(Box, { role: "rowgroup", children: groups.map((group, gi) => /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
34761
34355
|
group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: gi > 0 ? "mt-3" : "mt-0" }),
|
|
34762
34356
|
group.items.map((row) => renderRow(row, runningIndex++))
|
|
34763
34357
|
] }, gi)) });
|
|
@@ -36114,7 +35708,7 @@ var init_StepFlow = __esm({
|
|
|
36114
35708
|
className
|
|
36115
35709
|
}) => {
|
|
36116
35710
|
if (orientation === "vertical") {
|
|
36117
|
-
return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(
|
|
35711
|
+
return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(React74__default.Fragment, { children: /* @__PURE__ */ jsxs(HStack, { gap: "md", align: "start", className: "w-full", children: [
|
|
36118
35712
|
/* @__PURE__ */ jsxs(VStack, { gap: "none", align: "center", children: [
|
|
36119
35713
|
/* @__PURE__ */ jsx(StepCircle, { step, index }),
|
|
36120
35714
|
showConnectors && index < steps.length - 1 && /* @__PURE__ */ jsx(Box, { className: "w-px h-8 bg-border" })
|
|
@@ -36125,7 +35719,7 @@ var init_StepFlow = __esm({
|
|
|
36125
35719
|
] })
|
|
36126
35720
|
] }) }, index)) });
|
|
36127
35721
|
}
|
|
36128
|
-
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(
|
|
35722
|
+
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(React74__default.Fragment, { children: [
|
|
36129
35723
|
/* @__PURE__ */ jsxs(VStack, { gap: "sm", align: "center", className: "flex-1 w-full md:w-auto", children: [
|
|
36130
35724
|
/* @__PURE__ */ jsx(StepCircle, { step, index }),
|
|
36131
35725
|
/* @__PURE__ */ jsx(Typography, { variant: "h4", className: "text-center", children: step.title }),
|
|
@@ -37110,7 +36704,7 @@ var init_LikertScale = __esm({
|
|
|
37110
36704
|
md: "text-base",
|
|
37111
36705
|
lg: "text-lg"
|
|
37112
36706
|
};
|
|
37113
|
-
LikertScale =
|
|
36707
|
+
LikertScale = React74__default.forwardRef(
|
|
37114
36708
|
({
|
|
37115
36709
|
question,
|
|
37116
36710
|
options = DEFAULT_LIKERT_OPTIONS,
|
|
@@ -37122,7 +36716,7 @@ var init_LikertScale = __esm({
|
|
|
37122
36716
|
variant = "radios",
|
|
37123
36717
|
className
|
|
37124
36718
|
}, ref) => {
|
|
37125
|
-
const groupId =
|
|
36719
|
+
const groupId = React74__default.useId();
|
|
37126
36720
|
const eventBus = useEventBus();
|
|
37127
36721
|
const handleSelect = useCallback(
|
|
37128
36722
|
(next) => {
|
|
@@ -39404,7 +38998,7 @@ var init_DocBreadcrumb = __esm({
|
|
|
39404
38998
|
"aria-label": t("aria.breadcrumb"),
|
|
39405
38999
|
children: /* @__PURE__ */ jsx(HStack, { gap: "xs", align: "center", wrap: true, children: items.map((item, idx) => {
|
|
39406
39000
|
const isLast = idx === items.length - 1;
|
|
39407
|
-
return /* @__PURE__ */ jsxs(
|
|
39001
|
+
return /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
39408
39002
|
idx > 0 && /* @__PURE__ */ jsx(
|
|
39409
39003
|
Icon,
|
|
39410
39004
|
{
|
|
@@ -40273,7 +39867,7 @@ var init_MiniStateMachine = __esm({
|
|
|
40273
39867
|
const x = 2 + i * (NODE_W + GAP2 + ARROW_W + GAP2);
|
|
40274
39868
|
const tc = transitionCounts[s.name] ?? 0;
|
|
40275
39869
|
const role = getStateRole(s.name, s.isInitial ?? void 0, s.isTerminal ?? void 0, tc, maxTC);
|
|
40276
|
-
return /* @__PURE__ */ jsxs(
|
|
39870
|
+
return /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
40277
39871
|
/* @__PURE__ */ jsx(
|
|
40278
39872
|
AvlState,
|
|
40279
39873
|
{
|
|
@@ -40477,7 +40071,7 @@ var init_PageHeader = __esm({
|
|
|
40477
40071
|
info: "bg-info/10 text-info"
|
|
40478
40072
|
};
|
|
40479
40073
|
return /* @__PURE__ */ jsxs(Box, { className: cn("mb-6", className), children: [
|
|
40480
|
-
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(
|
|
40074
|
+
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(React74__default.Fragment, { children: [
|
|
40481
40075
|
idx > 0 && /* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: "/" }),
|
|
40482
40076
|
crumb.href ? /* @__PURE__ */ jsx(
|
|
40483
40077
|
"a",
|
|
@@ -40835,7 +40429,7 @@ var init_Section = __esm({
|
|
|
40835
40429
|
as: Component = "section"
|
|
40836
40430
|
}) => {
|
|
40837
40431
|
const hasHeader = title || description || action;
|
|
40838
|
-
return
|
|
40432
|
+
return React74__default.createElement(
|
|
40839
40433
|
Component,
|
|
40840
40434
|
{
|
|
40841
40435
|
className: cn(
|
|
@@ -41209,7 +40803,7 @@ var init_WizardContainer = __esm({
|
|
|
41209
40803
|
const isCompleted = index < currentStep;
|
|
41210
40804
|
const stepKey = step.id ?? step.tabId ?? `step-${index}`;
|
|
41211
40805
|
const stepTitle = step.title ?? step.name ?? `Step ${index + 1}`;
|
|
41212
|
-
return /* @__PURE__ */ jsxs(
|
|
40806
|
+
return /* @__PURE__ */ jsxs(React74__default.Fragment, { children: [
|
|
41213
40807
|
/* @__PURE__ */ jsx(
|
|
41214
40808
|
Button,
|
|
41215
40809
|
{
|
|
@@ -43858,7 +43452,7 @@ var init_DetailPanel = __esm({
|
|
|
43858
43452
|
}
|
|
43859
43453
|
});
|
|
43860
43454
|
function extractTitle(children) {
|
|
43861
|
-
if (!
|
|
43455
|
+
if (!React74__default.isValidElement(children)) return void 0;
|
|
43862
43456
|
const props = children.props;
|
|
43863
43457
|
if (typeof props.title === "string") {
|
|
43864
43458
|
return props.title;
|
|
@@ -44208,12 +43802,12 @@ var init_Form = __esm({
|
|
|
44208
43802
|
const isSchemaEntity = isOrbitalEntitySchema(entity);
|
|
44209
43803
|
const resolvedEntity = isSchemaEntity ? entity : void 0;
|
|
44210
43804
|
const entityName = typeof entity === "string" ? entity : resolvedEntity?.name;
|
|
44211
|
-
const normalizedInitialData =
|
|
43805
|
+
const normalizedInitialData = React74__default.useMemo(() => {
|
|
44212
43806
|
const entityRowAsInitial = isPlainEntityRow(entity) ? entity : void 0;
|
|
44213
43807
|
const callerInitial = initialData !== null && typeof initialData === "object" && !Array.isArray(initialData) ? initialData : {};
|
|
44214
43808
|
return entityRowAsInitial !== void 0 ? { ...entityRowAsInitial, ...callerInitial } : callerInitial;
|
|
44215
43809
|
}, [entity, initialData]);
|
|
44216
|
-
const entityDerivedFields =
|
|
43810
|
+
const entityDerivedFields = React74__default.useMemo(() => {
|
|
44217
43811
|
if (fields && fields.length > 0) return void 0;
|
|
44218
43812
|
if (!resolvedEntity) return void 0;
|
|
44219
43813
|
return resolvedEntity.fields.map(
|
|
@@ -44234,16 +43828,16 @@ var init_Form = __esm({
|
|
|
44234
43828
|
const conditionalFields = typeof conditionalFieldsRaw === "boolean" ? {} : conditionalFieldsRaw;
|
|
44235
43829
|
const hiddenCalculations = typeof hiddenCalculationsRaw === "boolean" ? [] : hiddenCalculationsRaw;
|
|
44236
43830
|
const violationTriggers = typeof violationTriggersRaw === "boolean" ? [] : violationTriggersRaw;
|
|
44237
|
-
const [formData, setFormData] =
|
|
43831
|
+
const [formData, setFormData] = React74__default.useState(
|
|
44238
43832
|
normalizedInitialData
|
|
44239
43833
|
);
|
|
44240
|
-
const [collapsedSections, setCollapsedSections] =
|
|
43834
|
+
const [collapsedSections, setCollapsedSections] = React74__default.useState(
|
|
44241
43835
|
/* @__PURE__ */ new Set()
|
|
44242
43836
|
);
|
|
44243
|
-
const [submitError, setSubmitError] =
|
|
44244
|
-
const formRef =
|
|
43837
|
+
const [submitError, setSubmitError] = React74__default.useState(null);
|
|
43838
|
+
const formRef = React74__default.useRef(null);
|
|
44245
43839
|
const formMode = props.mode;
|
|
44246
|
-
const mountedRef =
|
|
43840
|
+
const mountedRef = React74__default.useRef(false);
|
|
44247
43841
|
if (!mountedRef.current) {
|
|
44248
43842
|
mountedRef.current = true;
|
|
44249
43843
|
debug("forms", "mount", {
|
|
@@ -44256,7 +43850,7 @@ var init_Form = __esm({
|
|
|
44256
43850
|
});
|
|
44257
43851
|
}
|
|
44258
43852
|
const shouldShowCancel = showCancel ?? (fields && fields.length > 0);
|
|
44259
|
-
const evalContext =
|
|
43853
|
+
const evalContext = React74__default.useMemo(
|
|
44260
43854
|
() => ({
|
|
44261
43855
|
formValues: formData,
|
|
44262
43856
|
globalVariables: externalContext?.globalVariables ?? {},
|
|
@@ -44265,7 +43859,7 @@ var init_Form = __esm({
|
|
|
44265
43859
|
}),
|
|
44266
43860
|
[formData, externalContext]
|
|
44267
43861
|
);
|
|
44268
|
-
|
|
43862
|
+
React74__default.useEffect(() => {
|
|
44269
43863
|
debug("forms", "initialData-sync", {
|
|
44270
43864
|
mode: formMode,
|
|
44271
43865
|
normalizedInitialData,
|
|
@@ -44276,7 +43870,7 @@ var init_Form = __esm({
|
|
|
44276
43870
|
setFormData(normalizedInitialData);
|
|
44277
43871
|
}
|
|
44278
43872
|
}, [normalizedInitialData]);
|
|
44279
|
-
const processCalculations =
|
|
43873
|
+
const processCalculations = React74__default.useCallback(
|
|
44280
43874
|
(changedFieldId, newFormData) => {
|
|
44281
43875
|
if (!hiddenCalculations.length) return;
|
|
44282
43876
|
const context = {
|
|
@@ -44301,7 +43895,7 @@ var init_Form = __esm({
|
|
|
44301
43895
|
},
|
|
44302
43896
|
[hiddenCalculations, externalContext, eventBus]
|
|
44303
43897
|
);
|
|
44304
|
-
const checkViolations =
|
|
43898
|
+
const checkViolations = React74__default.useCallback(
|
|
44305
43899
|
(changedFieldId, newFormData) => {
|
|
44306
43900
|
if (!violationTriggers.length) return;
|
|
44307
43901
|
const context = {
|
|
@@ -44339,7 +43933,7 @@ var init_Form = __esm({
|
|
|
44339
43933
|
processCalculations(name, newFormData);
|
|
44340
43934
|
checkViolations(name, newFormData);
|
|
44341
43935
|
};
|
|
44342
|
-
const isFieldVisible =
|
|
43936
|
+
const isFieldVisible = React74__default.useCallback(
|
|
44343
43937
|
(fieldName) => {
|
|
44344
43938
|
const condition = conditionalFields[fieldName];
|
|
44345
43939
|
if (!condition) return true;
|
|
@@ -44347,7 +43941,7 @@ var init_Form = __esm({
|
|
|
44347
43941
|
},
|
|
44348
43942
|
[conditionalFields, evalContext]
|
|
44349
43943
|
);
|
|
44350
|
-
const isSectionVisible =
|
|
43944
|
+
const isSectionVisible = React74__default.useCallback(
|
|
44351
43945
|
(section) => {
|
|
44352
43946
|
if (!section.condition) return true;
|
|
44353
43947
|
return Boolean(evaluateFormExpression(section.condition, evalContext));
|
|
@@ -44423,7 +44017,7 @@ var init_Form = __esm({
|
|
|
44423
44017
|
eventBus.emit(`UI:${onCancel}`);
|
|
44424
44018
|
}
|
|
44425
44019
|
};
|
|
44426
|
-
const renderField =
|
|
44020
|
+
const renderField = React74__default.useCallback(
|
|
44427
44021
|
(field) => {
|
|
44428
44022
|
const fieldName = field.name || field.field;
|
|
44429
44023
|
if (!fieldName) return null;
|
|
@@ -44444,7 +44038,7 @@ var init_Form = __esm({
|
|
|
44444
44038
|
[formData, isFieldVisible, relationsData, relationsLoading, isLoading]
|
|
44445
44039
|
);
|
|
44446
44040
|
const effectiveFields = entityDerivedFields ?? fields;
|
|
44447
|
-
const normalizedFields =
|
|
44041
|
+
const normalizedFields = React74__default.useMemo(() => {
|
|
44448
44042
|
if (!effectiveFields || effectiveFields.length === 0) return [];
|
|
44449
44043
|
return effectiveFields.map((field) => {
|
|
44450
44044
|
if (typeof field === "string") {
|
|
@@ -44468,7 +44062,7 @@ var init_Form = __esm({
|
|
|
44468
44062
|
return field;
|
|
44469
44063
|
});
|
|
44470
44064
|
}, [effectiveFields, resolvedEntity]);
|
|
44471
|
-
const schemaFields =
|
|
44065
|
+
const schemaFields = React74__default.useMemo(() => {
|
|
44472
44066
|
if (normalizedFields.length === 0) return null;
|
|
44473
44067
|
if (isDebugEnabled()) {
|
|
44474
44068
|
debugGroup(`Form: ${entityName || "unknown"}`);
|
|
@@ -44478,7 +44072,7 @@ var init_Form = __esm({
|
|
|
44478
44072
|
}
|
|
44479
44073
|
return normalizedFields.map(renderField).filter(Boolean);
|
|
44480
44074
|
}, [normalizedFields, renderField, entityName, conditionalFields]);
|
|
44481
|
-
const sectionElements =
|
|
44075
|
+
const sectionElements = React74__default.useMemo(() => {
|
|
44482
44076
|
if (!sections || sections.length === 0) return null;
|
|
44483
44077
|
return sections.map((section) => {
|
|
44484
44078
|
if (!isSectionVisible(section)) {
|
|
@@ -45203,7 +44797,7 @@ var init_List = __esm({
|
|
|
45203
44797
|
if (entity && typeof entity === "object" && "id" in entity) return [entity];
|
|
45204
44798
|
return [];
|
|
45205
44799
|
}, [entity]);
|
|
45206
|
-
const getItemActions =
|
|
44800
|
+
const getItemActions = React74__default.useCallback(
|
|
45207
44801
|
(item) => {
|
|
45208
44802
|
if (!itemActions) return [];
|
|
45209
44803
|
if (typeof itemActions === "function") {
|
|
@@ -45678,7 +45272,7 @@ var init_MediaGallery = __esm({
|
|
|
45678
45272
|
[selectable, selectedItems, selectionEvent, eventBus]
|
|
45679
45273
|
);
|
|
45680
45274
|
const entityData = Array.isArray(entity) ? entity : [];
|
|
45681
|
-
const items =
|
|
45275
|
+
const items = React74__default.useMemo(() => {
|
|
45682
45276
|
if (propItems) return propItems;
|
|
45683
45277
|
if (entityData.length === 0) return [];
|
|
45684
45278
|
return entityData.map((record, idx) => {
|
|
@@ -45841,7 +45435,7 @@ var init_MediaGallery = __esm({
|
|
|
45841
45435
|
}
|
|
45842
45436
|
});
|
|
45843
45437
|
function extractTitle2(children) {
|
|
45844
|
-
if (!
|
|
45438
|
+
if (!React74__default.isValidElement(children)) return void 0;
|
|
45845
45439
|
const props = children.props;
|
|
45846
45440
|
if (typeof props.title === "string") {
|
|
45847
45441
|
return props.title;
|
|
@@ -46096,7 +45690,7 @@ var init_debugRegistry = __esm({
|
|
|
46096
45690
|
}
|
|
46097
45691
|
});
|
|
46098
45692
|
function useDebugData() {
|
|
46099
|
-
const [data, setData] =
|
|
45693
|
+
const [data, setData] = React74.useState(() => ({
|
|
46100
45694
|
traits: [],
|
|
46101
45695
|
ticks: [],
|
|
46102
45696
|
guards: [],
|
|
@@ -46110,7 +45704,7 @@ function useDebugData() {
|
|
|
46110
45704
|
},
|
|
46111
45705
|
lastUpdate: Date.now()
|
|
46112
45706
|
}));
|
|
46113
|
-
|
|
45707
|
+
React74.useEffect(() => {
|
|
46114
45708
|
const updateData = () => {
|
|
46115
45709
|
setData({
|
|
46116
45710
|
traits: getAllTraits(),
|
|
@@ -46219,12 +45813,12 @@ function layoutGraph(states, transitions, initialState, width, height) {
|
|
|
46219
45813
|
return positions;
|
|
46220
45814
|
}
|
|
46221
45815
|
function WalkMinimap() {
|
|
46222
|
-
const [walkStep, setWalkStep] =
|
|
46223
|
-
const [traits2, setTraits] =
|
|
46224
|
-
const [coveredEdges, setCoveredEdges] =
|
|
46225
|
-
const [completedTraits, setCompletedTraits] =
|
|
46226
|
-
const prevTraitRef =
|
|
46227
|
-
|
|
45816
|
+
const [walkStep, setWalkStep] = React74.useState(null);
|
|
45817
|
+
const [traits2, setTraits] = React74.useState([]);
|
|
45818
|
+
const [coveredEdges, setCoveredEdges] = React74.useState([]);
|
|
45819
|
+
const [completedTraits, setCompletedTraits] = React74.useState(/* @__PURE__ */ new Set());
|
|
45820
|
+
const prevTraitRef = React74.useRef(null);
|
|
45821
|
+
React74.useEffect(() => {
|
|
46228
45822
|
const interval = setInterval(() => {
|
|
46229
45823
|
const w = window;
|
|
46230
45824
|
const step = w.__orbitalWalkStep;
|
|
@@ -46660,15 +46254,15 @@ var init_EntitiesTab = __esm({
|
|
|
46660
46254
|
});
|
|
46661
46255
|
function EventFlowTab({ events: events2 }) {
|
|
46662
46256
|
const { t } = useTranslate();
|
|
46663
|
-
const [filter, setFilter] =
|
|
46664
|
-
const containerRef =
|
|
46665
|
-
const [autoScroll, setAutoScroll] =
|
|
46666
|
-
|
|
46257
|
+
const [filter, setFilter] = React74.useState("all");
|
|
46258
|
+
const containerRef = React74.useRef(null);
|
|
46259
|
+
const [autoScroll, setAutoScroll] = React74.useState(true);
|
|
46260
|
+
React74.useEffect(() => {
|
|
46667
46261
|
if (autoScroll && containerRef.current) {
|
|
46668
46262
|
containerRef.current.scrollTop = containerRef.current.scrollHeight;
|
|
46669
46263
|
}
|
|
46670
46264
|
}, [events2.length, autoScroll]);
|
|
46671
|
-
const filteredEvents =
|
|
46265
|
+
const filteredEvents = React74.useMemo(() => {
|
|
46672
46266
|
if (filter === "all") return events2;
|
|
46673
46267
|
return events2.filter((e) => e.type === filter);
|
|
46674
46268
|
}, [events2, filter]);
|
|
@@ -46784,7 +46378,7 @@ var init_EventFlowTab = __esm({
|
|
|
46784
46378
|
});
|
|
46785
46379
|
function GuardsPanel({ guards }) {
|
|
46786
46380
|
const { t } = useTranslate();
|
|
46787
|
-
const [filter, setFilter] =
|
|
46381
|
+
const [filter, setFilter] = React74.useState("all");
|
|
46788
46382
|
if (guards.length === 0) {
|
|
46789
46383
|
return /* @__PURE__ */ jsx(
|
|
46790
46384
|
EmptyState,
|
|
@@ -46797,7 +46391,7 @@ function GuardsPanel({ guards }) {
|
|
|
46797
46391
|
}
|
|
46798
46392
|
const passedCount = guards.filter((g) => g.result).length;
|
|
46799
46393
|
const failedCount = guards.length - passedCount;
|
|
46800
|
-
const filteredGuards =
|
|
46394
|
+
const filteredGuards = React74.useMemo(() => {
|
|
46801
46395
|
if (filter === "all") return guards;
|
|
46802
46396
|
if (filter === "passed") return guards.filter((g) => g.result);
|
|
46803
46397
|
return guards.filter((g) => !g.result);
|
|
@@ -46960,10 +46554,10 @@ function EffectBadge({ effect }) {
|
|
|
46960
46554
|
}
|
|
46961
46555
|
function TransitionTimeline({ transitions }) {
|
|
46962
46556
|
const { t } = useTranslate();
|
|
46963
|
-
const containerRef =
|
|
46964
|
-
const [autoScroll, setAutoScroll] =
|
|
46965
|
-
const [expandedId, setExpandedId] =
|
|
46966
|
-
|
|
46557
|
+
const containerRef = React74.useRef(null);
|
|
46558
|
+
const [autoScroll, setAutoScroll] = React74.useState(true);
|
|
46559
|
+
const [expandedId, setExpandedId] = React74.useState(null);
|
|
46560
|
+
React74.useEffect(() => {
|
|
46967
46561
|
if (autoScroll && containerRef.current) {
|
|
46968
46562
|
containerRef.current.scrollTop = containerRef.current.scrollHeight;
|
|
46969
46563
|
}
|
|
@@ -47243,9 +46837,9 @@ function getAllEvents(traits2) {
|
|
|
47243
46837
|
function EventDispatcherTab({ traits: traits2, schema }) {
|
|
47244
46838
|
const eventBus = useEventBus();
|
|
47245
46839
|
const { t } = useTranslate();
|
|
47246
|
-
const [log18, setLog] =
|
|
47247
|
-
const prevStatesRef =
|
|
47248
|
-
|
|
46840
|
+
const [log18, setLog] = React74.useState([]);
|
|
46841
|
+
const prevStatesRef = React74.useRef(/* @__PURE__ */ new Map());
|
|
46842
|
+
React74.useEffect(() => {
|
|
47249
46843
|
for (const trait of traits2) {
|
|
47250
46844
|
const prev = prevStatesRef.current.get(trait.id);
|
|
47251
46845
|
if (prev && prev !== trait.currentState) {
|
|
@@ -47414,10 +47008,10 @@ function VerifyModePanel({
|
|
|
47414
47008
|
localCount
|
|
47415
47009
|
}) {
|
|
47416
47010
|
const { t } = useTranslate();
|
|
47417
|
-
const [expanded, setExpanded] =
|
|
47418
|
-
const scrollRef =
|
|
47419
|
-
const prevCountRef =
|
|
47420
|
-
|
|
47011
|
+
const [expanded, setExpanded] = React74.useState(true);
|
|
47012
|
+
const scrollRef = React74.useRef(null);
|
|
47013
|
+
const prevCountRef = React74.useRef(0);
|
|
47014
|
+
React74.useEffect(() => {
|
|
47421
47015
|
if (expanded && transitions.length > prevCountRef.current && scrollRef.current) {
|
|
47422
47016
|
scrollRef.current.scrollTop = scrollRef.current.scrollHeight;
|
|
47423
47017
|
}
|
|
@@ -47474,10 +47068,10 @@ function RuntimeDebugger({
|
|
|
47474
47068
|
schema
|
|
47475
47069
|
}) {
|
|
47476
47070
|
const { t } = useTranslate();
|
|
47477
|
-
const [isCollapsed, setIsCollapsed] =
|
|
47478
|
-
const [isVisible, setIsVisible] =
|
|
47071
|
+
const [isCollapsed, setIsCollapsed] = React74.useState(mode === "verify" ? true : defaultCollapsed);
|
|
47072
|
+
const [isVisible, setIsVisible] = React74.useState(mode === "inline" || mode === "verify" || isDebugEnabled2());
|
|
47479
47073
|
const debugData = useDebugData();
|
|
47480
|
-
|
|
47074
|
+
React74.useEffect(() => {
|
|
47481
47075
|
if (mode === "inline") return;
|
|
47482
47076
|
return onDebugToggle((enabled) => {
|
|
47483
47077
|
setIsVisible(enabled);
|
|
@@ -47486,7 +47080,7 @@ function RuntimeDebugger({
|
|
|
47486
47080
|
}
|
|
47487
47081
|
});
|
|
47488
47082
|
}, [mode]);
|
|
47489
|
-
|
|
47083
|
+
React74.useEffect(() => {
|
|
47490
47084
|
if (mode === "inline") return;
|
|
47491
47085
|
const handleKeyDown = (e) => {
|
|
47492
47086
|
if (e.key === "`" && isVisible) {
|
|
@@ -48006,7 +47600,7 @@ var init_StatCard = __esm({
|
|
|
48006
47600
|
const labelToUse = propLabel ?? propTitle;
|
|
48007
47601
|
const eventBus = useEventBus();
|
|
48008
47602
|
const { t } = useTranslate();
|
|
48009
|
-
const handleActionClick =
|
|
47603
|
+
const handleActionClick = React74__default.useCallback(() => {
|
|
48010
47604
|
if (action?.event) {
|
|
48011
47605
|
eventBus.emit(`UI:${action.event}`, {});
|
|
48012
47606
|
}
|
|
@@ -48017,7 +47611,7 @@ var init_StatCard = __esm({
|
|
|
48017
47611
|
const data = Array.isArray(entity) ? entity : entity ? [entity] : [];
|
|
48018
47612
|
const isLoading = externalLoading ?? false;
|
|
48019
47613
|
const error = externalError;
|
|
48020
|
-
const computeMetricValue =
|
|
47614
|
+
const computeMetricValue = React74__default.useCallback(
|
|
48021
47615
|
(metric, items) => {
|
|
48022
47616
|
if (metric.value !== void 0) {
|
|
48023
47617
|
return metric.value;
|
|
@@ -48056,7 +47650,7 @@ var init_StatCard = __esm({
|
|
|
48056
47650
|
},
|
|
48057
47651
|
[]
|
|
48058
47652
|
);
|
|
48059
|
-
const schemaStats =
|
|
47653
|
+
const schemaStats = React74__default.useMemo(() => {
|
|
48060
47654
|
if (!metrics || metrics.length === 0) return null;
|
|
48061
47655
|
return metrics.map((metric) => ({
|
|
48062
47656
|
label: metric.label,
|
|
@@ -48064,7 +47658,7 @@ var init_StatCard = __esm({
|
|
|
48064
47658
|
format: metric.format
|
|
48065
47659
|
}));
|
|
48066
47660
|
}, [metrics, data, computeMetricValue]);
|
|
48067
|
-
const calculatedTrend =
|
|
47661
|
+
const calculatedTrend = React74__default.useMemo(() => {
|
|
48068
47662
|
if (manualTrend !== void 0) return manualTrend;
|
|
48069
47663
|
if (previousValue === void 0 || currentValue2 === void 0)
|
|
48070
47664
|
return void 0;
|
|
@@ -48704,8 +48298,8 @@ var init_SubagentTracePanel = __esm({
|
|
|
48704
48298
|
] });
|
|
48705
48299
|
};
|
|
48706
48300
|
InlineActivityStream = ({ activities, autoScroll = true, className }) => {
|
|
48707
|
-
const endRef =
|
|
48708
|
-
|
|
48301
|
+
const endRef = React74__default.useRef(null);
|
|
48302
|
+
React74__default.useEffect(() => {
|
|
48709
48303
|
if (!autoScroll) return;
|
|
48710
48304
|
endRef.current?.scrollIntoView({ behavior: "smooth", block: "end" });
|
|
48711
48305
|
}, [activities.length, autoScroll]);
|
|
@@ -48799,7 +48393,7 @@ var init_SubagentTracePanel = __esm({
|
|
|
48799
48393
|
};
|
|
48800
48394
|
SubagentRichCard = ({ subagent }) => {
|
|
48801
48395
|
const { t } = useTranslate();
|
|
48802
|
-
const activities =
|
|
48396
|
+
const activities = React74__default.useMemo(
|
|
48803
48397
|
() => subagentMessagesToActivities(subagent.messages),
|
|
48804
48398
|
[subagent.messages]
|
|
48805
48399
|
);
|
|
@@ -48876,8 +48470,8 @@ var init_SubagentTracePanel = __esm({
|
|
|
48876
48470
|
] });
|
|
48877
48471
|
};
|
|
48878
48472
|
CoordinatorConversation = ({ messages, autoScroll = true, className }) => {
|
|
48879
|
-
const endRef =
|
|
48880
|
-
|
|
48473
|
+
const endRef = React74__default.useRef(null);
|
|
48474
|
+
React74__default.useEffect(() => {
|
|
48881
48475
|
if (!autoScroll) return;
|
|
48882
48476
|
endRef.current?.scrollIntoView({ behavior: "smooth", block: "end" });
|
|
48883
48477
|
}, [messages.length, autoScroll]);
|
|
@@ -49307,7 +48901,7 @@ var init_Timeline = __esm({
|
|
|
49307
48901
|
}) => {
|
|
49308
48902
|
const { t } = useTranslate();
|
|
49309
48903
|
const entityData = entity ?? [];
|
|
49310
|
-
const items =
|
|
48904
|
+
const items = React74__default.useMemo(() => {
|
|
49311
48905
|
if (propItems) return propItems;
|
|
49312
48906
|
if (entityData.length === 0) return [];
|
|
49313
48907
|
return entityData.map((record, idx) => {
|
|
@@ -49409,7 +49003,7 @@ var init_Timeline = __esm({
|
|
|
49409
49003
|
}
|
|
49410
49004
|
});
|
|
49411
49005
|
function extractToastProps(children) {
|
|
49412
|
-
if (!
|
|
49006
|
+
if (!React74__default.isValidElement(children)) {
|
|
49413
49007
|
if (typeof children === "string") {
|
|
49414
49008
|
return { message: children };
|
|
49415
49009
|
}
|
|
@@ -49451,7 +49045,7 @@ var init_ToastSlot = __esm({
|
|
|
49451
49045
|
eventBus.emit(`${prefix}CLOSE`);
|
|
49452
49046
|
};
|
|
49453
49047
|
if (!isVisible) return null;
|
|
49454
|
-
const isCustomContent =
|
|
49048
|
+
const isCustomContent = React74__default.isValidElement(children) && !message;
|
|
49455
49049
|
return /* @__PURE__ */ jsx(Box, { className: "fixed bottom-4 right-4 z-50", children: isCustomContent ? children : /* @__PURE__ */ jsx(
|
|
49456
49050
|
Toast,
|
|
49457
49051
|
{
|
|
@@ -49468,7 +49062,7 @@ var init_ToastSlot = __esm({
|
|
|
49468
49062
|
}
|
|
49469
49063
|
});
|
|
49470
49064
|
function lazyThree(name, loader) {
|
|
49471
|
-
const Lazy =
|
|
49065
|
+
const Lazy = React74__default.lazy(
|
|
49472
49066
|
() => loader().then((m) => {
|
|
49473
49067
|
const Resolved = m[name];
|
|
49474
49068
|
if (!Resolved) {
|
|
@@ -49480,13 +49074,13 @@ function lazyThree(name, loader) {
|
|
|
49480
49074
|
})
|
|
49481
49075
|
);
|
|
49482
49076
|
function ThreeWrapper(props) {
|
|
49483
|
-
return
|
|
49077
|
+
return React74__default.createElement(
|
|
49484
49078
|
ThreeBoundary,
|
|
49485
49079
|
{ name },
|
|
49486
|
-
|
|
49487
|
-
|
|
49080
|
+
React74__default.createElement(
|
|
49081
|
+
React74__default.Suspense,
|
|
49488
49082
|
{ fallback: null },
|
|
49489
|
-
|
|
49083
|
+
React74__default.createElement(Lazy, props)
|
|
49490
49084
|
)
|
|
49491
49085
|
);
|
|
49492
49086
|
}
|
|
@@ -49528,7 +49122,6 @@ var init_component_registry_generated = __esm({
|
|
|
49528
49122
|
init_Canvas2D();
|
|
49529
49123
|
init_CanvasEffect();
|
|
49530
49124
|
init_Card();
|
|
49531
|
-
init_CardBattlerBoard();
|
|
49532
49125
|
init_CardGrid();
|
|
49533
49126
|
init_Carousel();
|
|
49534
49127
|
init_CaseStudyCard();
|
|
@@ -49759,13 +49352,12 @@ var init_component_registry_generated = __esm({
|
|
|
49759
49352
|
init_UploadDropZone();
|
|
49760
49353
|
init_VersionDiff();
|
|
49761
49354
|
init_ViolationAlert();
|
|
49762
|
-
init_VisualNovelBoard();
|
|
49763
49355
|
init_VoteStack();
|
|
49764
49356
|
init_WaypointMarker();
|
|
49765
49357
|
init_WizardContainer();
|
|
49766
49358
|
init_WizardNavigation();
|
|
49767
49359
|
init_WizardProgress();
|
|
49768
|
-
ThreeBoundary = class extends
|
|
49360
|
+
ThreeBoundary = class extends React74__default.Component {
|
|
49769
49361
|
constructor() {
|
|
49770
49362
|
super(...arguments);
|
|
49771
49363
|
__publicField(this, "state", { failed: false });
|
|
@@ -49775,7 +49367,7 @@ var init_component_registry_generated = __esm({
|
|
|
49775
49367
|
}
|
|
49776
49368
|
render() {
|
|
49777
49369
|
if (this.state.failed) {
|
|
49778
|
-
return
|
|
49370
|
+
return React74__default.createElement(
|
|
49779
49371
|
"div",
|
|
49780
49372
|
{
|
|
49781
49373
|
"data-testid": "three-unavailable",
|
|
@@ -49829,7 +49421,6 @@ var init_component_registry_generated = __esm({
|
|
|
49829
49421
|
"Canvas2D": Canvas2D,
|
|
49830
49422
|
"CanvasEffect": CanvasEffect,
|
|
49831
49423
|
"Card": Card,
|
|
49832
|
-
"CardBattlerBoard": CardBattlerBoard,
|
|
49833
49424
|
"CardGrid": CardGrid,
|
|
49834
49425
|
"Carousel": Carousel,
|
|
49835
49426
|
"CaseStudyCard": CaseStudyCard,
|
|
@@ -50074,7 +49665,6 @@ var init_component_registry_generated = __esm({
|
|
|
50074
49665
|
"VStack": VStack,
|
|
50075
49666
|
"VersionDiff": VersionDiff,
|
|
50076
49667
|
"ViolationAlert": ViolationAlert,
|
|
50077
|
-
"VisualNovelBoard": VisualNovelBoard,
|
|
50078
49668
|
"VoteStack": VoteStack,
|
|
50079
49669
|
"WaypointMarker": WaypointMarker,
|
|
50080
49670
|
"WizardContainer": WizardContainer,
|
|
@@ -50098,7 +49688,7 @@ function SuspenseConfigProvider({
|
|
|
50098
49688
|
config,
|
|
50099
49689
|
children
|
|
50100
49690
|
}) {
|
|
50101
|
-
return
|
|
49691
|
+
return React74__default.createElement(
|
|
50102
49692
|
SuspenseConfigContext.Provider,
|
|
50103
49693
|
{ value: config },
|
|
50104
49694
|
children
|
|
@@ -50140,7 +49730,7 @@ function enrichFormFields(fields, entityDef) {
|
|
|
50140
49730
|
}
|
|
50141
49731
|
return { name: field, label: field.replace(/([a-z])([A-Z])/g, "$1 $2").replace(/\b\w/g, (c) => c.toUpperCase()) };
|
|
50142
49732
|
}
|
|
50143
|
-
if (field && typeof field === "object" && !Array.isArray(field) && !
|
|
49733
|
+
if (field && typeof field === "object" && !Array.isArray(field) && !React74__default.isValidElement(field) && !(field instanceof Date)) {
|
|
50144
49734
|
const obj = field;
|
|
50145
49735
|
const fieldName = typeof obj.name === "string" ? obj.name : typeof obj.field === "string" ? obj.field : void 0;
|
|
50146
49736
|
if (!fieldName) return field;
|
|
@@ -50593,7 +50183,7 @@ function renderPatternChildren(children, onDismiss, parentId = "root", parentPat
|
|
|
50593
50183
|
const key = `${parentId}-${index}-trait:${traitName}`;
|
|
50594
50184
|
return /* @__PURE__ */ jsx(TraitFrame, { traitName }, key);
|
|
50595
50185
|
}
|
|
50596
|
-
return /* @__PURE__ */ jsx(
|
|
50186
|
+
return /* @__PURE__ */ jsx(React74__default.Fragment, { children: child }, `${parentId}-${index}`);
|
|
50597
50187
|
}
|
|
50598
50188
|
if (!child || typeof child !== "object") return null;
|
|
50599
50189
|
const childId = `${parentId}-${index}`;
|
|
@@ -50633,14 +50223,14 @@ function isPatternConfig(value) {
|
|
|
50633
50223
|
if (value === null || value === void 0) return false;
|
|
50634
50224
|
if (typeof value !== "object") return false;
|
|
50635
50225
|
if (Array.isArray(value)) return false;
|
|
50636
|
-
if (
|
|
50226
|
+
if (React74__default.isValidElement(value)) return false;
|
|
50637
50227
|
if (value instanceof Date) return false;
|
|
50638
50228
|
if (typeof value === "function") return false;
|
|
50639
50229
|
const record = value;
|
|
50640
50230
|
return "type" in record && typeof record.type === "string" && getComponentForPattern$1(record.type) !== null;
|
|
50641
50231
|
}
|
|
50642
50232
|
function isPlainConfigObject(value) {
|
|
50643
|
-
if (
|
|
50233
|
+
if (React74__default.isValidElement(value)) return false;
|
|
50644
50234
|
if (value instanceof Date) return false;
|
|
50645
50235
|
const proto = Object.getPrototypeOf(value);
|
|
50646
50236
|
return proto === Object.prototype || proto === null;
|
|
@@ -50766,7 +50356,7 @@ function SlotContentRenderer({
|
|
|
50766
50356
|
for (const slotKey of CONTENT_NODE_SLOTS) {
|
|
50767
50357
|
const slotVal = restProps[slotKey];
|
|
50768
50358
|
if (slotVal === void 0 || slotVal === null) continue;
|
|
50769
|
-
if (
|
|
50359
|
+
if (React74__default.isValidElement(slotVal) || typeof slotVal === "string" || typeof slotVal === "number" || typeof slotVal === "boolean") continue;
|
|
50770
50360
|
if (Array.isArray(slotVal) || typeof slotVal === "object" && "type" in slotVal) {
|
|
50771
50361
|
nodeSlotOverrides[slotKey] = renderPatternChildren(
|
|
50772
50362
|
slotVal,
|
|
@@ -50815,7 +50405,7 @@ function SlotContentRenderer({
|
|
|
50815
50405
|
const resolvedItems = Array.isArray(entityVal) && entityVal[0] !== "fn" ? entityVal : null;
|
|
50816
50406
|
if (resolvedItems && resolvedItems.length > 0 && !finalProps.fields && !finalProps.columns) {
|
|
50817
50407
|
const sample = resolvedItems[0];
|
|
50818
|
-
if (sample && typeof sample === "object" && !Array.isArray(sample) && !
|
|
50408
|
+
if (sample && typeof sample === "object" && !Array.isArray(sample) && !React74__default.isValidElement(sample) && !(sample instanceof Date)) {
|
|
50819
50409
|
const keys = Object.keys(sample).filter((k) => k !== "id" && k !== "_id");
|
|
50820
50410
|
finalProps.fields = keys.map((k, i) => ({ name: k, variant: i === 0 ? "h4" : "body" }));
|
|
50821
50411
|
}
|
|
@@ -53115,7 +52705,7 @@ var I18nContext = createContext({
|
|
|
53115
52705
|
});
|
|
53116
52706
|
I18nContext.displayName = "I18nContext";
|
|
53117
52707
|
var I18nProvider = I18nContext.Provider;
|
|
53118
|
-
function
|
|
52708
|
+
function useTranslate127() {
|
|
53119
52709
|
return useContext(I18nContext);
|
|
53120
52710
|
}
|
|
53121
52711
|
function createTranslate(messages) {
|
|
@@ -53316,4 +52906,4 @@ function useGitHubBranches(owner, repo, enabled = true) {
|
|
|
53316
52906
|
});
|
|
53317
52907
|
}
|
|
53318
52908
|
|
|
53319
|
-
export { ALL_PRESETS, ALMADAR_DND_MIME, AR_BOOK_FIELDS, AboutPageTemplate, Accordion, ActionButton, Card2 as ActionCard, ActionPalette, ActionTile, ActivationBlock, Alert, AnimatedCounter, AnimatedGraphic, AnimatedReveal, ArticleSection, Aside, AssetPicker, AuthLayout, Avatar, Badge, BehaviorView, BiologyCanvas, BloomQuizBlock, BookChapterView, BookCoverPage, BookNavBar, BookTableOfContents, BookViewer, Box, BranchingLogicBuilder, Breadcrumb, BuilderBoard, Button, ButtonGroup, CTABanner, CalendarGrid, Canvas2D, CanvasEffect, Card,
|
|
52909
|
+
export { ALL_PRESETS, ALMADAR_DND_MIME, AR_BOOK_FIELDS, AboutPageTemplate, Accordion, ActionButton, Card2 as ActionCard, ActionPalette, ActionTile, ActivationBlock, Alert, AnimatedCounter, AnimatedGraphic, AnimatedReveal, ArticleSection, Aside, AssetPicker, AuthLayout, Avatar, Badge, BehaviorView, BiologyCanvas, BloomQuizBlock, BookChapterView, BookCoverPage, BookNavBar, BookTableOfContents, BookViewer, Box, BranchingLogicBuilder, Breadcrumb, BuilderBoard, Button, ButtonGroup, CTABanner, CalendarGrid, Canvas2D, CanvasEffect, Card, CardBody, CardContent, CardFooter, CardGrid, CardHeader, CardTitle, Carousel, CaseStudyCard, CaseStudyOrganism, Center, Chart, ChartLegend, ChatBar, Checkbox, ChemistryCanvas, ChoiceButton, ClassifierBoard, Coachmark, CodeBlock, CodeRunnerPanel, CollapsibleSection, ComboCounter, CommunityLinks, ConditionalWrapper, ConfettiEffect, ConfirmDialog, ConnectionBlock, Container, ContentRenderer, ContentSection, ControlButton, ControlGrid, CounterTemplate, DEFAULT_LIKERT_OPTIONS, DEFAULT_MATRIX_COLUMNS, DEFAULT_SLOTS, DIAMOND_TOP_Y, DamageNumber, DashboardGrid, DashboardLayout, DataGrid, DataList, DataTable, DateRangePicker, DateRangeSelector, DayCell, DebuggerBoard, DetailPanel, Dialog, DialogueBubble, Divider, DocBreadcrumb, DocPagination, DocSearch, DocSidebar, DocTOC, DocumentViewer, StateMachineView as DomStateMachineVisualizer, Drawer, DrawerSlot, ELEMENT_SELECTED_EVENT, EMPTY_EFFECT_STATE, EdgeDecoration, EditorCheckbox, EditorSelect, EditorSlider, EditorTextInput, EditorToolbar, EmptyState, EntityDisplayEvents, ErrorBoundary, ErrorState, EventHandlerBoard, EventLog, FEATURE_COLORS, FEATURE_TYPES, FLOOR_HEIGHT, FeatureCard, FeatureDetailPageTemplate, FeatureGrid, FeatureGridOrganism, FileTree, FilterGroup, FilterPill, Flex, FlipCard, FlipContainer, FloatingActionButton, Form, FormActions, FormField, FormLayout, FormSection, FormSectionHeader, GameAudioContext, GameAudioProvider, GameAudioToggle, GameCard, GameHud, GameIcon, GameMenu, GameShell, GameTemplate, GenericAppTemplate, GeometricPattern, GradientDivider, GraphCanvas, GraphView, Grid, GridPicker, HStack, Header, HealthBar, HeroOrganism, HeroSection, I18nProvider, IDENTITY_BOOK_FIELDS, Icon, IconPicker, InfiniteScrollSentinel, Input, InputGroup, InstallBox, InventoryGrid, ItemSlot, JazariStateMachine, JsonTreeEditor, Label, LandingPageTemplate, LawReferenceTooltip, LearningCanvas, Lightbox, LikertScale, LineChart2 as LineChart, List3 as List, LoadingState, MapView, MarkdownContent, MarketingFooter, MarketingStatCard, MasterDetail, MasterDetailLayout, MathCanvas, MatrixQuestion, MediaGallery, Menu, Meter, MiniMap, Modal, ModalSlot, ModuleCard, Navigation, NegotiatorBoard, NodeSlotEditor, NotifyListener, NumberStepper, ObjectRulePanel, OnboardingSpotlight, OptionConstraintGroup, StateMachineView as OrbitalStateMachineView, OrbitalVisualization, Overlay, PageHeader, Pagination, PatternTile, PhysicsCanvas, Popover, PositionedCanvas, PricingCard, PricingGrid, PricingOrganism, PricingPageTemplate, ProgressBar, ProgressDots, PropertyInspector, PullQuote, PullToRefresh, QrScanner, QuizBlock, Radio, RangeSlider, ReflectionBlock, RelationSelect, RepeatableFormSection, ReplyTree, ResourceBar, ResourceCounter, RichBlockEditor, RuleEditor, RuntimeDebugger, SHEET_COLUMNS, SPRITE_SHEET_LAYOUT, ScaledDiagram, ScoreDisplay, SearchInput, Section, SectionHeader, SegmentRenderer, Select, SequenceBar, SequencerBoard, ServiceCatalog, ShowcaseCard, ShowcaseOrganism, SidePanel, Sidebar, SignaturePad, SimpleGrid, SimulationCanvas, SimulationControls, SimulationGraph, SimulatorBoard, Skeleton, SlotContentRenderer, SocialProof, SortableList, Spacer, Sparkline, Spinner, Split, SplitPane, SplitSection, Sprite, Stack, StarRating, StatBadge, StatCard, StatDisplay, StateArchitectBoard, StateIndicator, StateJsonView, StateMachineView, StateNode2 as StateNode, StatsGrid, StatsOrganism, StatusBar, StatusDot, StatusEffect, StepFlow, StepFlowOrganism, SubagentTracePanel, SvgBranch, SvgConnection, SvgFlow, SvgGrid, SvgLobe, SvgMesh, SvgMorph, SvgNode, SvgPulse, SvgRing, SvgShield, SvgStack, SwipeableRow, Switch, TERRAIN_COLORS, TILE_HEIGHT, TILE_WIDTH, TabbedContainer, TableView, Tabs, TagCloud, TagInput, TeamCard, TeamOrganism, TerrainPalette, TextHighlight, Textarea, ThemeToggle, TimeSlotCell, Timeline, TimerDisplay, Toast, ToastSlot, Tooltip, TraitFrame, TraitSlot, TraitStateViewer, TransitionArrow, TrendIndicator, TurnIndicator, TypewriterText, Typography, UISlotComponent, UISlotRenderer, UploadDropZone, VStack, VariablePanel, VersionDiff, ViolationAlert, VoteStack, WaypointMarker, WizardContainer, WizardNavigation, WizardProgress, boardEntity, bool, calculateAttackTargets, calculateValidMoves, cn, createCombatPresets, createInitialGameState, createTranslate, createUnitAnimationState, drawEffectState, drawSprite, drawTintedImage, getAllEffectSpriteUrls, getCurrentFrame, getTileDimensions, hasActiveEffects, inferDirection, isoToScreen, makeAsset, makeAssetMap, mapBookData, num, objAvailableActions, objAvailableEvents, objCurrentState, objIcon, objId, objMaxRules, objName, objRules, objStates, parseEditFocus, parseLessonSegments, parseMarkdownWithCodeBlocks, parseQueryBinding, pendulum, projectileMotion, resolveFieldMap, resolveFrame, resolveSheetDirection, rows, screenToIso, spawnOverlay, spawnParticles, spawnSequence, springOscillator, str, tickAnimationState, toCodeLanguage, transitionAnimation, unitHealth, unitPosition, unitTeam, updateEffectState, useAgentChat, useAnchorRect, useAuthContext, useCamera, useCanvasEffects, useCanvasGestures, useCompile, useConnectGitHub, useDeepAgentGeneration, useDisconnectGitHub, useDragReorder, useDraggable, useDropZone, useEmitEvent, useEventBus, useEventListener, useExtensions, useFileEditor, useFileSystem, useGameAudio, useGameAudioContext, useGitHubBranches, useGitHubRepo, useGitHubRepos, useGitHubStatus, useImageCache, useInfiniteScroll, useLongPress, useOrbitalHistory, usePreview, usePullToRefresh, useQuerySingleton, useRenderInterpolation, useSwipeGesture, useTapReveal, useTraitListens, useTranslate127 as useTranslate, useUIEvents, useUISlotManager, useUnitSpriteAtlas, useValidation, vec2 };
|