@almadar/ui 5.121.4 → 5.122.1

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.
@@ -1,5 +1,5 @@
1
- import * as React81 from 'react';
2
- import React81__default, { createContext, useContext, useMemo, useRef, useEffect, useCallback, Suspense, useState, useSyncExternalStore, lazy, useLayoutEffect, useId } from 'react';
1
+ import * as React82 from 'react';
2
+ import React82__default, { createContext, useContext, useMemo, useRef, useEffect, useCallback, Suspense, useState, useSyncExternalStore, lazy, useLayoutEffect, useId } from 'react';
3
3
  import { EventBusContext, useTraitScopeChain, useEntitySchemaOptional, useEntitySchema, getAllPages, OrbitalProvider, TraitScopeProvider, ServerBridgeProvider, useCurrentPagePath, useGameAudioContextOptional, VerificationProvider, EntitySchemaProvider, OrbitalThemeProvider, useServerBridge } from '@almadar/ui/providers';
4
4
  export { EntitySchemaProvider, ServerBridgeProvider, TraitContext, TraitProvider, useEntitySchema, useEntitySchemaOptional, useServerBridge, useTrait, useTraitContext } from '@almadar/ui/providers';
5
5
  import { createLogger, setNamespaceLevel, isLogLevelEnabled } from '@almadar/logger';
@@ -878,7 +878,7 @@ var init_Box = __esm({
878
878
  fixed: "fixed",
879
879
  sticky: "sticky"
880
880
  };
881
- Box = React81__default.forwardRef(
881
+ Box = React82__default.forwardRef(
882
882
  ({
883
883
  padding,
884
884
  paddingX,
@@ -943,7 +943,7 @@ var init_Box = __esm({
943
943
  onPointerDown?.(e);
944
944
  }, [hoverEvent, tapReveal, triggerProps, onPointerDown]);
945
945
  const isClickable = action || onClick;
946
- return React81__default.createElement(
946
+ return React82__default.createElement(
947
947
  Component,
948
948
  {
949
949
  ref,
@@ -1160,7 +1160,7 @@ var init_Icon = __esm({
1160
1160
  const effectiveName = typeof icon === "string" && icon !== "" ? icon : name;
1161
1161
  const effectiveStrokeWidth = strokeWidth != null && strokeWidth > 0 ? strokeWidth : void 0;
1162
1162
  const family = useIconFamily();
1163
- const RenderedComponent = React81__default.useMemo(() => {
1163
+ const RenderedComponent = React82__default.useMemo(() => {
1164
1164
  if (directIcon) return null;
1165
1165
  return effectiveName ? resolveIconForFamily(effectiveName) : null;
1166
1166
  }, [directIcon, effectiveName, family]);
@@ -1280,7 +1280,7 @@ var init_atlasSlice = __esm({
1280
1280
  }
1281
1281
  });
1282
1282
  function useAtlasSliceDataUrl(asset) {
1283
- const [, bump] = React81.useReducer((x) => x + 1, 0);
1283
+ const [, bump] = React82.useReducer((x) => x + 1, 0);
1284
1284
  if (!isAtlasAsset(asset)) return void 0;
1285
1285
  const key = `${asset.atlas}#${asset.sprite}`;
1286
1286
  const cached = sliceDataUrlCache.get(key);
@@ -1343,13 +1343,13 @@ function AtlasImage({
1343
1343
  style,
1344
1344
  "aria-hidden": ariaHidden
1345
1345
  }) {
1346
- const [, bump] = React81.useReducer((x) => x + 1, 0);
1347
- const canvasRef = React81.useRef(null);
1346
+ const [, bump] = React82.useReducer((x) => x + 1, 0);
1347
+ const canvasRef = React82.useRef(null);
1348
1348
  const sliced = isAtlasAsset(asset);
1349
1349
  const atlas = sliced ? getAtlas(asset.atlas, bump) : void 0;
1350
1350
  const img = sliced && asset?.url ? getSheetImage(asset.url, bump) : null;
1351
1351
  const rect = sliced && atlas ? subRectFor(atlas, asset.sprite) : null;
1352
- React81.useEffect(() => {
1352
+ React82.useEffect(() => {
1353
1353
  const canvas = canvasRef.current;
1354
1354
  if (!canvas || !img || !rect) return;
1355
1355
  canvas.width = rect.sw;
@@ -1425,7 +1425,7 @@ function resolveIconProp(value, sizeClass) {
1425
1425
  const IconComp = value;
1426
1426
  return /* @__PURE__ */ jsx(IconComp, { className: sizeClass });
1427
1427
  }
1428
- if (React81__default.isValidElement(value)) {
1428
+ if (React82__default.isValidElement(value)) {
1429
1429
  return value;
1430
1430
  }
1431
1431
  if (typeof value === "object" && value !== null && isIconLike(value)) {
@@ -1502,7 +1502,7 @@ var init_Button = __esm({
1502
1502
  md: "h-icon-default w-icon-default",
1503
1503
  lg: "h-icon-default w-icon-default"
1504
1504
  };
1505
- Button = React81__default.forwardRef(
1505
+ Button = React82__default.forwardRef(
1506
1506
  ({
1507
1507
  className,
1508
1508
  variant = "primary",
@@ -1544,7 +1544,8 @@ var init_Button = __esm({
1544
1544
  "font-medium",
1545
1545
  "rounded-sm",
1546
1546
  "cursor-pointer",
1547
- "transition-all duration-[var(--transition-normal)]",
1547
+ "chrome-button",
1548
+ "transition-all duration-normal",
1548
1549
  "focus:outline-none focus:ring-[length:var(--focus-ring-width)] focus:ring-ring focus:ring-offset-[length:var(--focus-ring-offset)]",
1549
1550
  "disabled:opacity-50 disabled:cursor-not-allowed",
1550
1551
  variantStyles[variant],
@@ -1570,7 +1571,7 @@ var Dialog;
1570
1571
  var init_Dialog = __esm({
1571
1572
  "components/core/atoms/Dialog.tsx"() {
1572
1573
  init_cn();
1573
- Dialog = React81__default.forwardRef(
1574
+ Dialog = React82__default.forwardRef(
1574
1575
  ({
1575
1576
  role = "dialog",
1576
1577
  "aria-modal": ariaModal = true,
@@ -1688,7 +1689,7 @@ var init_Typography = __esm({
1688
1689
  }) => {
1689
1690
  const variant = variantProp ?? (level ? `h${level}` : "body1");
1690
1691
  const Component = as || defaultElements[variant];
1691
- return React81__default.createElement(
1692
+ return React82__default.createElement(
1692
1693
  Component,
1693
1694
  {
1694
1695
  id,
@@ -1744,6 +1745,7 @@ var init_Modal = __esm({
1744
1745
  isOpen = true,
1745
1746
  onClose = () => {
1746
1747
  },
1748
+ onExited,
1747
1749
  title,
1748
1750
  children = null,
1749
1751
  footer,
@@ -1770,7 +1772,10 @@ var init_Modal = __esm({
1770
1772
  wasOpenRef.current = isOpen;
1771
1773
  }, [isOpen]);
1772
1774
  const handleAnimEnd = (e) => {
1773
- if (closing && e.target === e.currentTarget) setClosing(false);
1775
+ if (closing && e.target === e.currentTarget) {
1776
+ setClosing(false);
1777
+ onExited?.();
1778
+ }
1774
1779
  };
1775
1780
  useEffect(() => {
1776
1781
  if (isOpen) {
@@ -1940,12 +1945,84 @@ var init_Modal = __esm({
1940
1945
  Modal.displayName = "Modal";
1941
1946
  }
1942
1947
  });
1948
+ function isMotionEnabled() {
1949
+ if (typeof document === "undefined") return true;
1950
+ if (motionEnabledCache !== null) return motionEnabledCache;
1951
+ const v = getComputedStyle(document.documentElement).getPropertyValue("--motion-enable").trim().toLowerCase();
1952
+ motionEnabledCache = v !== "off";
1953
+ return motionEnabledCache;
1954
+ }
1955
+ function usePresence(show, opts) {
1956
+ const { animation, animate = true, onExited } = opts;
1957
+ const [mounted, setMounted] = useState(show);
1958
+ const [exiting, setExiting] = useState(false);
1959
+ const prev = useRef(show);
1960
+ const onExitedRef = useRef(onExited);
1961
+ onExitedRef.current = onExited;
1962
+ const safeTimer = useRef(null);
1963
+ const clearSafe = useCallback(() => {
1964
+ if (safeTimer.current) {
1965
+ clearTimeout(safeTimer.current);
1966
+ safeTimer.current = null;
1967
+ }
1968
+ }, []);
1969
+ const finishExit = useCallback(() => {
1970
+ clearSafe();
1971
+ setExiting(false);
1972
+ setMounted(false);
1973
+ onExitedRef.current?.();
1974
+ }, [clearSafe]);
1975
+ useEffect(() => {
1976
+ const moving = animate && isMotionEnabled();
1977
+ if (show && !prev.current) {
1978
+ setExiting(false);
1979
+ setMounted(true);
1980
+ } else if (!show && prev.current) {
1981
+ if (moving) {
1982
+ setExiting(true);
1983
+ clearSafe();
1984
+ safeTimer.current = setTimeout(finishExit, SAFE_EXIT_MS);
1985
+ } else {
1986
+ setMounted(false);
1987
+ setExiting(false);
1988
+ }
1989
+ }
1990
+ prev.current = show;
1991
+ }, [show, animate, clearSafe, finishExit]);
1992
+ useEffect(() => () => clearSafe(), [clearSafe]);
1993
+ const disabled = !animate || !isMotionEnabled();
1994
+ const className = disabled ? "" : exiting ? `animate-${animation}-out` : `animate-${animation}-in`;
1995
+ const onAnimationEnd = useCallback(
1996
+ (e) => {
1997
+ if (e.target !== e.currentTarget) return;
1998
+ if (exiting) finishExit();
1999
+ },
2000
+ [exiting, finishExit]
2001
+ );
2002
+ return { mounted, exiting, className, onAnimationEnd };
2003
+ }
2004
+ var SAFE_EXIT_MS, motionEnabledCache, Presence;
2005
+ var init_Presence = __esm({
2006
+ "components/core/atoms/Presence.tsx"() {
2007
+ "use client";
2008
+ init_cn();
2009
+ SAFE_EXIT_MS = 1e3;
2010
+ motionEnabledCache = null;
2011
+ Presence = ({ show, className, children, ...opts }) => {
2012
+ const { mounted, className: animClass, onAnimationEnd } = usePresence(show, opts);
2013
+ if (!mounted) return null;
2014
+ return /* @__PURE__ */ jsx("div", { className: cn(animClass, className), onAnimationEnd, children });
2015
+ };
2016
+ Presence.displayName = "Presence";
2017
+ }
2018
+ });
1943
2019
  var Overlay;
1944
2020
  var init_Overlay = __esm({
1945
2021
  "components/core/atoms/Overlay.tsx"() {
1946
2022
  "use client";
1947
2023
  init_cn();
1948
2024
  init_useEventBus();
2025
+ init_Presence();
1949
2026
  Overlay = ({
1950
2027
  isVisible = true,
1951
2028
  onClick,
@@ -1954,7 +2031,8 @@ var init_Overlay = __esm({
1954
2031
  action
1955
2032
  }) => {
1956
2033
  const eventBus = useEventBus();
1957
- if (!isVisible) return null;
2034
+ const { mounted, className: animClass, onAnimationEnd } = usePresence(isVisible, { animation: "overlay" });
2035
+ if (!mounted) return null;
1958
2036
  const handleClick = (e) => {
1959
2037
  if (action) {
1960
2038
  eventBus.emit(`UI:${action}`, {});
@@ -1967,11 +2045,12 @@ var init_Overlay = __esm({
1967
2045
  className: cn(
1968
2046
  "fixed inset-0 z-40",
1969
2047
  blur && "backdrop-blur-sm",
1970
- "animate-overlay-in",
2048
+ animClass,
1971
2049
  className
1972
2050
  ),
1973
2051
  style: { backgroundColor: "rgba(0, 0, 0, 0.6)" },
1974
2052
  onClick: action || onClick ? handleClick : void 0,
2053
+ onAnimationEnd,
1975
2054
  "aria-hidden": "true"
1976
2055
  }
1977
2056
  );
@@ -1986,6 +2065,7 @@ var init_Drawer = __esm({
1986
2065
  init_Button();
1987
2066
  init_Typography();
1988
2067
  init_Overlay();
2068
+ init_Presence();
1989
2069
  init_cn();
1990
2070
  init_useEventBus();
1991
2071
  sizeWidths = {
@@ -2039,6 +2119,7 @@ var init_Drawer = __esm({
2039
2119
  document.addEventListener("keydown", handleEscape);
2040
2120
  return () => document.removeEventListener("keydown", handleEscape);
2041
2121
  }, [isOpen, closeOnEscape, onClose, closeEvent, eventBus]);
2122
+ const { mounted, className: drawerAnim, onAnimationEnd } = usePresence(isOpen, { animation: "drawer" });
2042
2123
  useEffect(() => {
2043
2124
  if (isOpen) {
2044
2125
  document.body.style.overflow = "hidden";
@@ -2049,7 +2130,7 @@ var init_Drawer = __esm({
2049
2130
  document.body.style.overflow = "";
2050
2131
  };
2051
2132
  }, [isOpen]);
2052
- if (!isOpen) return null;
2133
+ if (!mounted) return null;
2053
2134
  const handleClose = () => {
2054
2135
  if (closeEvent) eventBus.emit(`UI:${closeEvent}`, {});
2055
2136
  onClose();
@@ -2062,7 +2143,7 @@ var init_Drawer = __esm({
2062
2143
  const widthClass = width in sizeWidths ? sizeWidths[width] : "";
2063
2144
  const widthStyle = width in sizeWidths ? void 0 : { width };
2064
2145
  const positionClasses = position === "right" ? "right-0 border-l" : "left-0 border-r";
2065
- const animationClasses2 = position === "right" ? "animate-slide-in-right" : "animate-slide-in-left";
2146
+ const drawerSign = position === "right" ? 1 : -1;
2066
2147
  return /* @__PURE__ */ jsxs(Fragment, { children: [
2067
2148
  /* @__PURE__ */ jsx(
2068
2149
  Overlay,
@@ -2084,12 +2165,13 @@ var init_Drawer = __esm({
2084
2165
  "flex flex-col max-h-screen",
2085
2166
  positionClasses,
2086
2167
  widthClass,
2087
- animationClasses2,
2168
+ drawerAnim,
2088
2169
  className
2089
2170
  ),
2090
- style: widthStyle,
2171
+ style: { ...widthStyle, "--motion-drawer-sign": drawerSign },
2091
2172
  role: "dialog",
2092
2173
  "aria-modal": "true",
2174
+ onAnimationEnd,
2093
2175
  ...title && { "aria-labelledby": "drawer-title" },
2094
2176
  children: [
2095
2177
  (title || showCloseButton) && /* @__PURE__ */ jsxs(
@@ -2128,31 +2210,7 @@ var init_Drawer = __esm({
2128
2210
  )
2129
2211
  ]
2130
2212
  }
2131
- ),
2132
- /* @__PURE__ */ jsx("style", { children: `
2133
- @keyframes slide-in-right {
2134
- from {
2135
- transform: translateX(100%);
2136
- }
2137
- to {
2138
- transform: translateX(0);
2139
- }
2140
- }
2141
- @keyframes slide-in-left {
2142
- from {
2143
- transform: translateX(-100%);
2144
- }
2145
- to {
2146
- transform: translateX(0);
2147
- }
2148
- }
2149
- .animate-slide-in-right {
2150
- animation: slide-in-right 0.3s ease-out;
2151
- }
2152
- .animate-slide-in-left {
2153
- animation: slide-in-left 0.3s ease-out;
2154
- }
2155
- ` })
2213
+ )
2156
2214
  ] });
2157
2215
  };
2158
2216
  Drawer.displayName = "Drawer";
@@ -2201,7 +2259,7 @@ var init_Badge = __esm({
2201
2259
  md: "px-2.5 py-1 text-sm",
2202
2260
  lg: "px-3 py-1.5 text-base"
2203
2261
  };
2204
- Badge = React81__default.forwardRef(
2262
+ Badge = React82__default.forwardRef(
2205
2263
  ({ className, variant = "default", size = "sm", amount, label, icon, iconAsset, children, onRemove, removeLabel, ...props }, ref) => {
2206
2264
  const iconSizes3 = {
2207
2265
  sm: "h-icon-default w-icon-default",
@@ -2296,14 +2354,23 @@ var init_Toast = __esm({
2296
2354
  }) => {
2297
2355
  const eventBus = useEventBus();
2298
2356
  const { t } = useTranslate();
2299
- const handleDismiss = () => {
2357
+ const [leaving, setLeaving] = useState(false);
2358
+ const doRealDismiss = () => {
2300
2359
  if (dismissEvent) eventBus.emit(`UI:${dismissEvent}`, {});
2301
2360
  onDismiss?.();
2302
2361
  };
2362
+ const handleDismiss = () => {
2363
+ if (leaving) return;
2364
+ setLeaving(true);
2365
+ };
2303
2366
  const handleAction = () => {
2304
2367
  if (actionEvent) eventBus.emit(`UI:${actionEvent}`, {});
2305
2368
  onAction?.();
2306
2369
  };
2370
+ const handleAnimEnd = (e) => {
2371
+ if (e.target !== e.currentTarget) return;
2372
+ if (leaving) doRealDismiss();
2373
+ };
2307
2374
  useEffect(() => {
2308
2375
  if (duration <= 0 || !onDismiss && !dismissEvent) {
2309
2376
  return;
@@ -2322,10 +2389,12 @@ var init_Toast = __esm({
2322
2389
  // edge. `max-w-[calc(100vw-2rem)]` clamps to viewport too.
2323
2390
  "border-l-4 p-4 shadow-elevation-toast min-w-0 sm:min-w-[300px] max-w-md max-w-[calc(100vw-2rem)]",
2324
2391
  "rounded-sm",
2392
+ leaving ? "animate-toast-out" : "animate-toast-in",
2325
2393
  variantClasses[variant],
2326
2394
  className
2327
2395
  ),
2328
2396
  role: "alert",
2397
+ onAnimationEnd: handleAnimEnd,
2329
2398
  children: /* @__PURE__ */ jsxs(Box, { className: "flex items-start gap-3", children: [
2330
2399
  /* @__PURE__ */ jsx(Box, { className: "flex-shrink-0 mt-0.5", children: /* @__PURE__ */ jsx(
2331
2400
  Icon,
@@ -2538,7 +2607,7 @@ var init_SvgFlow = __esm({
2538
2607
  width = 100,
2539
2608
  height = 100
2540
2609
  }) => {
2541
- const markerId = React81__default.useMemo(() => {
2610
+ const markerId = React82__default.useMemo(() => {
2542
2611
  flowIdCounter += 1;
2543
2612
  return `almadar-flow-arrow-${flowIdCounter}`;
2544
2613
  }, []);
@@ -3131,7 +3200,7 @@ var init_SvgRing = __esm({
3131
3200
  width = 100,
3132
3201
  height = 100
3133
3202
  }) => {
3134
- const gradientId = React81__default.useMemo(() => {
3203
+ const gradientId = React82__default.useMemo(() => {
3135
3204
  ringIdCounter += 1;
3136
3205
  return `almadar-ring-glow-${ringIdCounter}`;
3137
3206
  }, []);
@@ -3312,7 +3381,7 @@ var init_Input = __esm({
3312
3381
  init_cn();
3313
3382
  init_Icon();
3314
3383
  init_useEventBus();
3315
- Input = React81__default.forwardRef(
3384
+ Input = React82__default.forwardRef(
3316
3385
  ({
3317
3386
  className,
3318
3387
  inputType,
@@ -3347,7 +3416,7 @@ var init_Input = __esm({
3347
3416
  const showClearButton = clearable && value && String(value).length > 0;
3348
3417
  const isMultiline = type === "textarea";
3349
3418
  const baseClassName = cn(
3350
- "block w-full rounded-sm transition-all duration-[var(--transition-fast)]",
3419
+ "block w-full rounded-sm transition-all duration-fast",
3351
3420
  "border-[length:var(--border-width-thin)] border-border",
3352
3421
  isMultiline ? "px-3 py-2 text-sm" : "h-input-md px-3 text-sm",
3353
3422
  "bg-card hover:bg-muted focus:bg-card",
@@ -3480,7 +3549,7 @@ var Label;
3480
3549
  var init_Label = __esm({
3481
3550
  "components/core/atoms/Label.tsx"() {
3482
3551
  init_cn();
3483
- Label = React81__default.forwardRef(
3552
+ Label = React82__default.forwardRef(
3484
3553
  ({ className, required, children, ...props }, ref) => {
3485
3554
  return /* @__PURE__ */ jsxs(
3486
3555
  "label",
@@ -3507,7 +3576,7 @@ var init_Textarea = __esm({
3507
3576
  "components/core/atoms/Textarea.tsx"() {
3508
3577
  init_cn();
3509
3578
  init_useEventBus();
3510
- Textarea = React81__default.forwardRef(
3579
+ Textarea = React82__default.forwardRef(
3511
3580
  ({ className, error, onChange, ...props }, ref) => {
3512
3581
  const eventBus = useEventBus();
3513
3582
  const handleChange = (e) => {
@@ -3746,7 +3815,7 @@ var init_Select = __esm({
3746
3815
  init_cn();
3747
3816
  init_Icon();
3748
3817
  init_useEventBus();
3749
- Select = React81__default.forwardRef(
3818
+ Select = React82__default.forwardRef(
3750
3819
  (props, _ref) => {
3751
3820
  const { multiple, searchable, clearable } = props;
3752
3821
  if (multiple || searchable || clearable) {
@@ -3763,7 +3832,7 @@ var init_Checkbox = __esm({
3763
3832
  "components/core/atoms/Checkbox.tsx"() {
3764
3833
  init_cn();
3765
3834
  init_useEventBus();
3766
- Checkbox = React81__default.forwardRef(
3835
+ Checkbox = React82__default.forwardRef(
3767
3836
  ({ className, label, id, onChange, ...props }, ref) => {
3768
3837
  const inputId = id || `checkbox-${Math.random().toString(36).substr(2, 9)}`;
3769
3838
  const eventBus = useEventBus();
@@ -3817,7 +3886,7 @@ var init_Spinner = __esm({
3817
3886
  md: "h-6 w-6",
3818
3887
  lg: "h-8 w-8"
3819
3888
  };
3820
- Spinner = React81__default.forwardRef(
3889
+ Spinner = React82__default.forwardRef(
3821
3890
  ({ className, size = "md", overlay, ...props }, ref) => {
3822
3891
  if (overlay) {
3823
3892
  return /* @__PURE__ */ jsx(
@@ -3859,21 +3928,21 @@ var init_Card = __esm({
3859
3928
  "bg-card",
3860
3929
  "border-[length:var(--border-width)] border-border",
3861
3930
  "shadow-elevation-card",
3862
- "transition-all duration-[var(--transition-normal)]",
3931
+ "transition-all duration-normal",
3863
3932
  "hover:shadow-elevation-dialog hover:translate-y-[var(--hover-translate-y)]"
3864
3933
  ].join(" "),
3865
3934
  bordered: [
3866
3935
  "bg-card",
3867
3936
  "border-[length:var(--border-width)] border-border",
3868
3937
  "shadow-elevation-card",
3869
- "transition-all duration-[var(--transition-normal)]",
3938
+ "transition-all duration-normal",
3870
3939
  "hover:shadow-elevation-dialog hover:translate-y-[var(--hover-translate-y)]"
3871
3940
  ].join(" "),
3872
3941
  elevated: [
3873
3942
  "bg-card",
3874
3943
  "border-[length:var(--border-width)] border-border",
3875
3944
  "shadow",
3876
- "transition-all duration-[var(--transition-normal)]",
3945
+ "transition-all duration-normal",
3877
3946
  "hover:shadow-elevation-dialog hover:translate-y-[var(--hover-translate-y)]"
3878
3947
  ].join(" "),
3879
3948
  // Interactive variant with theme-specific hover effects
@@ -3882,7 +3951,7 @@ var init_Card = __esm({
3882
3951
  "border-[length:var(--border-width)] border-border",
3883
3952
  "shadow",
3884
3953
  "cursor-pointer",
3885
- "transition-all duration-[var(--transition-normal)]",
3954
+ "transition-all duration-normal",
3886
3955
  "hover:shadow-elevation-dialog"
3887
3956
  ].join(" ")
3888
3957
  };
@@ -3907,7 +3976,7 @@ var init_Card = __esm({
3907
3976
  chip: "shadow-none rounded-pill border-[length:var(--border-width)] border-border",
3908
3977
  "tile-image-first": "p-0 overflow-hidden"
3909
3978
  };
3910
- Card = React81__default.forwardRef(
3979
+ Card = React82__default.forwardRef(
3911
3980
  ({
3912
3981
  className,
3913
3982
  variant = "bordered",
@@ -3933,7 +4002,8 @@ var init_Card = __esm({
3933
4002
  ref,
3934
4003
  className: cn(
3935
4004
  "rounded-container relative",
3936
- "transition-all duration-[var(--transition-normal)]",
4005
+ "transition-all duration-normal",
4006
+ "chrome-panel",
3937
4007
  variantStyles4[variant],
3938
4008
  paddingStyles2[padding],
3939
4009
  lookStyles2[look],
@@ -3955,9 +4025,9 @@ var init_Card = __esm({
3955
4025
  }
3956
4026
  );
3957
4027
  Card.displayName = "Card";
3958
- CardHeader = React81__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("mb-4", className), ...props }));
4028
+ CardHeader = React82__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("mb-4", className), ...props }));
3959
4029
  CardHeader.displayName = "CardHeader";
3960
- CardTitle = React81__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
4030
+ CardTitle = React82__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
3961
4031
  "h3",
3962
4032
  {
3963
4033
  ref,
@@ -3970,11 +4040,11 @@ var init_Card = __esm({
3970
4040
  }
3971
4041
  ));
3972
4042
  CardTitle.displayName = "CardTitle";
3973
- CardContent = React81__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("", className), ...props }));
4043
+ CardContent = React82__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("", className), ...props }));
3974
4044
  CardContent.displayName = "CardContent";
3975
4045
  CardBody = CardContent;
3976
4046
  CardBody.displayName = "CardBody";
3977
- CardFooter = React81__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
4047
+ CardFooter = React82__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
3978
4048
  "div",
3979
4049
  {
3980
4050
  ref,
@@ -4061,7 +4131,7 @@ var init_FilterPill = __esm({
4061
4131
  md: "w-3.5 h-3.5",
4062
4132
  lg: "w-4 h-4"
4063
4133
  };
4064
- FilterPill = React81__default.forwardRef(
4134
+ FilterPill = React82__default.forwardRef(
4065
4135
  ({
4066
4136
  className,
4067
4137
  variant = "default",
@@ -4190,8 +4260,8 @@ var init_Avatar = __esm({
4190
4260
  actionPayload
4191
4261
  }) => {
4192
4262
  const eventBus = useEventBus();
4193
- const [imgFailed, setImgFailed] = React81__default.useState(false);
4194
- React81__default.useEffect(() => {
4263
+ const [imgFailed, setImgFailed] = React82__default.useState(false);
4264
+ React82__default.useEffect(() => {
4195
4265
  setImgFailed(false);
4196
4266
  }, [src]);
4197
4267
  const initials = providedInitials ?? (name ? generateInitials(name) : void 0);
@@ -4304,7 +4374,7 @@ var init_Center = __esm({
4304
4374
  as: Component = "div"
4305
4375
  }) => {
4306
4376
  const mergedStyle = minHeight ? { minHeight, ...style } : style;
4307
- return React81__default.createElement(Component, {
4377
+ return React82__default.createElement(Component, {
4308
4378
  className: cn(
4309
4379
  inline ? "inline-flex" : "flex",
4310
4380
  horizontal && "justify-center",
@@ -4572,7 +4642,7 @@ var init_Radio = __esm({
4572
4642
  md: "w-2.5 h-2.5",
4573
4643
  lg: "w-3 h-3"
4574
4644
  };
4575
- Radio = React81__default.forwardRef(
4645
+ Radio = React82__default.forwardRef(
4576
4646
  ({
4577
4647
  label,
4578
4648
  helperText,
@@ -4589,12 +4659,12 @@ var init_Radio = __esm({
4589
4659
  onChange,
4590
4660
  ...props
4591
4661
  }, ref) => {
4592
- const reactId = React81__default.useId();
4662
+ const reactId = React82__default.useId();
4593
4663
  const baseId = id || `radio-${reactId}`;
4594
4664
  const hasError = !!error;
4595
4665
  const eventBus = useEventBus();
4596
- const [selected, setSelected] = React81__default.useState(value);
4597
- React81__default.useEffect(() => {
4666
+ const [selected, setSelected] = React82__default.useState(value);
4667
+ React82__default.useEffect(() => {
4598
4668
  if (value !== void 0) setSelected(value);
4599
4669
  }, [value]);
4600
4670
  const pick = (next, e) => {
@@ -4776,7 +4846,7 @@ var init_Switch = __esm({
4776
4846
  "components/core/atoms/Switch.tsx"() {
4777
4847
  "use client";
4778
4848
  init_cn();
4779
- Switch = React81.forwardRef(
4849
+ Switch = React82.forwardRef(
4780
4850
  ({
4781
4851
  checked,
4782
4852
  defaultChecked = false,
@@ -4787,10 +4857,10 @@ var init_Switch = __esm({
4787
4857
  name,
4788
4858
  className
4789
4859
  }, ref) => {
4790
- const [isChecked, setIsChecked] = React81.useState(
4860
+ const [isChecked, setIsChecked] = React82.useState(
4791
4861
  checked !== void 0 ? checked : defaultChecked
4792
4862
  );
4793
- React81.useEffect(() => {
4863
+ React82.useEffect(() => {
4794
4864
  if (checked !== void 0) {
4795
4865
  setIsChecked(checked);
4796
4866
  }
@@ -4821,7 +4891,7 @@ var init_Switch = __esm({
4821
4891
  // redefine --space-11 to 68px, which makes w-11 enormous and leaves
4822
4892
  // the thumb stuck near the left edge. The switch geometry must stay
4823
4893
  // proportional regardless of a theme's density scale.
4824
- "relative inline-flex h-[1.5rem] w-[2.75rem] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors",
4894
+ "relative inline-flex h-[1.5rem] w-[2.75rem] shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors duration-fast",
4825
4895
  "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background",
4826
4896
  isChecked ? "bg-primary" : "bg-muted",
4827
4897
  disabled && "cursor-not-allowed opacity-50"
@@ -4830,7 +4900,7 @@ var init_Switch = __esm({
4830
4900
  "span",
4831
4901
  {
4832
4902
  className: cn(
4833
- "pointer-events-none block h-[1.25rem] w-[1.25rem] rounded-full bg-background shadow-lg ring-0 transition-transform",
4903
+ "pointer-events-none block h-[1.25rem] w-[1.25rem] rounded-full bg-background shadow-lg ring-0 transition-transform duration-fast",
4834
4904
  isChecked ? "translate-x-[1.25rem]" : "translate-x-0"
4835
4905
  )
4836
4906
  }
@@ -4953,7 +5023,7 @@ var init_Stack = __esm({
4953
5023
  };
4954
5024
  const isHorizontal = direction === "horizontal";
4955
5025
  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";
4956
- return React81__default.createElement(
5026
+ return React82__default.createElement(
4957
5027
  Component,
4958
5028
  {
4959
5029
  className: cn(
@@ -4998,7 +5068,7 @@ var init_TextHighlight = __esm({
4998
5068
  hoverEvent
4999
5069
  }) => {
5000
5070
  const eventBus = useEventBus();
5001
- const baseStyles = "cursor-pointer transition-all duration-150";
5071
+ const baseStyles = "cursor-pointer transition-all duration-fast";
5002
5072
  const typeStyles = {
5003
5073
  question: cn(
5004
5074
  // Blue border for questions
@@ -5153,7 +5223,7 @@ var Aside;
5153
5223
  var init_Aside = __esm({
5154
5224
  "components/core/atoms/Aside.tsx"() {
5155
5225
  init_cn();
5156
- Aside = React81__default.forwardRef(
5226
+ Aside = React82__default.forwardRef(
5157
5227
  ({ className, children, ...rest }, ref) => /* @__PURE__ */ jsx("aside", { ref, className: cn(className), ...rest, children })
5158
5228
  );
5159
5229
  Aside.displayName = "Aside";
@@ -5232,9 +5302,9 @@ var init_LawReferenceTooltip = __esm({
5232
5302
  className
5233
5303
  }) => {
5234
5304
  const { t } = useTranslate();
5235
- const [isVisible, setIsVisible] = React81__default.useState(false);
5236
- const timeoutRef = React81__default.useRef(null);
5237
- const triggerRef = React81__default.useRef(null);
5305
+ const [isVisible, setIsVisible] = React82__default.useState(false);
5306
+ const timeoutRef = React82__default.useRef(null);
5307
+ const triggerRef = React82__default.useRef(null);
5238
5308
  const handleMouseEnter = () => {
5239
5309
  if (timeoutRef.current) clearTimeout(timeoutRef.current);
5240
5310
  timeoutRef.current = setTimeout(() => setIsVisible(true), 200);
@@ -5245,7 +5315,7 @@ var init_LawReferenceTooltip = __esm({
5245
5315
  };
5246
5316
  const { revealed, triggerProps } = useTapReveal({ refs: [triggerRef] });
5247
5317
  const open = isVisible || revealed;
5248
- React81__default.useEffect(() => {
5318
+ React82__default.useEffect(() => {
5249
5319
  return () => {
5250
5320
  if (timeoutRef.current) clearTimeout(timeoutRef.current);
5251
5321
  };
@@ -5455,7 +5525,7 @@ var init_StatusDot = __esm({
5455
5525
  md: "w-2.5 h-2.5",
5456
5526
  lg: "w-3 h-3"
5457
5527
  };
5458
- StatusDot = React81__default.forwardRef(
5528
+ StatusDot = React82__default.forwardRef(
5459
5529
  ({ className, status = "offline", pulse = false, size = "md", label, ...props }, ref) => {
5460
5530
  return /* @__PURE__ */ jsx(
5461
5531
  "span",
@@ -5509,7 +5579,7 @@ var init_TrendIndicator = __esm({
5509
5579
  down: "trending-down",
5510
5580
  flat: "arrow-right"
5511
5581
  };
5512
- TrendIndicator = React81__default.forwardRef(
5582
+ TrendIndicator = React82__default.forwardRef(
5513
5583
  ({
5514
5584
  className,
5515
5585
  value,
@@ -5576,7 +5646,7 @@ var init_RangeSlider = __esm({
5576
5646
  md: "w-4 h-4",
5577
5647
  lg: "w-5 h-5"
5578
5648
  };
5579
- RangeSlider = React81__default.forwardRef(
5649
+ RangeSlider = React82__default.forwardRef(
5580
5650
  ({
5581
5651
  className,
5582
5652
  min = 0,
@@ -5719,7 +5789,7 @@ var init_RangeSlider = __esm({
5719
5789
  "border-2 border-primary",
5720
5790
  "shadow-sm",
5721
5791
  "pointer-events-none",
5722
- "transition-transform duration-100",
5792
+ "transition-transform duration-instant",
5723
5793
  isDragging && "scale-[var(--hover-scale)]",
5724
5794
  thumbSizes[size]
5725
5795
  ),
@@ -6152,7 +6222,7 @@ var init_ContentSection = __esm({
6152
6222
  md: "py-16",
6153
6223
  lg: "py-24"
6154
6224
  };
6155
- ContentSection = React81__default.forwardRef(
6225
+ ContentSection = React82__default.forwardRef(
6156
6226
  ({ children, background = "default", padding = "lg", id, className }, ref) => {
6157
6227
  return /* @__PURE__ */ jsx(
6158
6228
  Box,
@@ -6686,7 +6756,7 @@ var init_AnimatedReveal = __esm({
6686
6756
  "scale-up": { opacity: 1, transform: "scale(1) translateY(0)" },
6687
6757
  "none": {}
6688
6758
  };
6689
- AnimatedReveal = React81__default.forwardRef(
6759
+ AnimatedReveal = React82__default.forwardRef(
6690
6760
  ({
6691
6761
  trigger = "scroll",
6692
6762
  animation = "fade-up",
@@ -6846,7 +6916,7 @@ var init_AnimatedGraphic = __esm({
6846
6916
  "components/marketing/atoms/AnimatedGraphic.tsx"() {
6847
6917
  "use client";
6848
6918
  init_cn();
6849
- AnimatedGraphic = React81__default.forwardRef(
6919
+ AnimatedGraphic = React82__default.forwardRef(
6850
6920
  ({
6851
6921
  src,
6852
6922
  svgContent,
@@ -6869,7 +6939,7 @@ var init_AnimatedGraphic = __esm({
6869
6939
  const fetchedSvg = useFetchedSvg(svgContent ? void 0 : src);
6870
6940
  const resolvedSvg = svgContent ?? fetchedSvg;
6871
6941
  const prevAnimateRef = useRef(animate);
6872
- const setRef = React81__default.useCallback(
6942
+ const setRef = React82__default.useCallback(
6873
6943
  (node) => {
6874
6944
  containerRef.current = node;
6875
6945
  if (typeof ref === "function") ref(node);
@@ -7597,9 +7667,9 @@ function ControlButton({
7597
7667
  className
7598
7668
  }) {
7599
7669
  const eventBus = useEventBus();
7600
- const [isPressed, setIsPressed] = React81.useState(false);
7670
+ const [isPressed, setIsPressed] = React82.useState(false);
7601
7671
  const actualPressed = pressed ?? isPressed;
7602
- const handlePointerDown = React81.useCallback(
7672
+ const handlePointerDown = React82.useCallback(
7603
7673
  (e) => {
7604
7674
  e.preventDefault();
7605
7675
  if (disabled) return;
@@ -7609,7 +7679,7 @@ function ControlButton({
7609
7679
  },
7610
7680
  [disabled, pressEvent, eventBus, onPress]
7611
7681
  );
7612
- const handlePointerUp = React81.useCallback(
7682
+ const handlePointerUp = React82.useCallback(
7613
7683
  (e) => {
7614
7684
  e.preventDefault();
7615
7685
  if (disabled) return;
@@ -7619,7 +7689,7 @@ function ControlButton({
7619
7689
  },
7620
7690
  [disabled, releaseEvent, eventBus, onRelease]
7621
7691
  );
7622
- const handlePointerLeave = React81.useCallback(
7692
+ const handlePointerLeave = React82.useCallback(
7623
7693
  (e) => {
7624
7694
  if (isPressed) {
7625
7695
  setIsPressed(false);
@@ -7877,8 +7947,8 @@ function ControlGrid({
7877
7947
  className
7878
7948
  }) {
7879
7949
  const eventBus = useEventBus();
7880
- const [active, setActive] = React81.useState(/* @__PURE__ */ new Set());
7881
- const handlePress = React81.useCallback(
7950
+ const [active, setActive] = React82.useState(/* @__PURE__ */ new Set());
7951
+ const handlePress = React82.useCallback(
7882
7952
  (id) => {
7883
7953
  setActive((prev) => new Set(prev).add(id));
7884
7954
  if (actionEvent) eventBus.emit(`UI:${actionEvent}`, { id, pressed: true });
@@ -7892,7 +7962,7 @@ function ControlGrid({
7892
7962
  },
7893
7963
  [kind, actionEvent, directionEvent, directionEvents, eventBus, onAction, onDirection]
7894
7964
  );
7895
- const handleRelease = React81.useCallback(
7965
+ const handleRelease = React82.useCallback(
7896
7966
  (id) => {
7897
7967
  setActive((prev) => {
7898
7968
  const next = new Set(prev);
@@ -8185,17 +8255,18 @@ function GameHud({
8185
8255
  const mid = Math.ceil(stats.length / 2);
8186
8256
  const leftStats = stats.slice(0, mid);
8187
8257
  const rightStats = stats.slice(mid);
8188
- const isTop = position === "top";
8189
8258
  return /* @__PURE__ */ jsxs(
8190
- Box,
8259
+ Card,
8191
8260
  {
8261
+ variant: "bordered",
8262
+ padding: "none",
8192
8263
  className: cn(
8193
- "flex items-center justify-between w-full",
8264
+ "flex items-center justify-between w-full rounded-none bg-card",
8194
8265
  "px-4 py-2 gap-4",
8195
- !transparent && (isTop ? "border-b border-border/40 bg-surface/90 backdrop-blur-sm" : "border-t border-border/40 bg-surface/90 backdrop-blur-sm"),
8196
- transparent && (isTop ? "border-b border-white/10 bg-black/40 backdrop-blur-sm" : "border-t border-white/10 bg-black/40 backdrop-blur-sm"),
8266
+ transparent && "backdrop-blur-sm",
8197
8267
  className
8198
8268
  ),
8269
+ style: transparent ? { backgroundColor: "color-mix(in srgb, var(--color-card) 40%, transparent)" } : void 0,
8199
8270
  children: [
8200
8271
  /* @__PURE__ */ jsx(Box, { className: "flex items-center gap-3 flex-shrink-0", children: leftStats.map((stat, i) => /* @__PURE__ */ jsx(StatBadge, { ...stat, size }, i)) }),
8201
8272
  rightStats.length > 0 && /* @__PURE__ */ jsx(Box, { className: "flex items-center gap-3 flex-shrink-0", children: rightStats.map((stat, i) => /* @__PURE__ */ jsx(StatBadge, { ...stat, size }, i)) })
@@ -8204,14 +8275,16 @@ function GameHud({
8204
8275
  );
8205
8276
  }
8206
8277
  return /* @__PURE__ */ jsx(
8207
- Box,
8278
+ Card,
8208
8279
  {
8209
- position: "relative",
8280
+ variant: "bordered",
8281
+ padding: "sm",
8210
8282
  className: cn(
8211
- "z-10 flex items-center gap-4 px-4 py-2",
8212
- transparent ? "bg-black/30 backdrop-blur-sm" : "bg-surface/90 backdrop-blur-sm",
8283
+ "z-10 relative flex items-center gap-4 bg-card",
8284
+ transparent && "backdrop-blur-sm",
8213
8285
  className
8214
8286
  ),
8287
+ style: transparent ? { backgroundColor: "color-mix(in srgb, var(--color-card) 30%, transparent)" } : void 0,
8215
8288
  children: stats.map((stat, i) => /* @__PURE__ */ jsx(StatBadge, { ...stat, size }, i))
8216
8289
  }
8217
8290
  );
@@ -8221,6 +8294,7 @@ var init_GameHud = __esm({
8221
8294
  "components/game/molecules/GameHud.tsx"() {
8222
8295
  init_cn();
8223
8296
  init_Box();
8297
+ init_Card();
8224
8298
  init_StatBadge();
8225
8299
  positionMap = {
8226
8300
  corners: "inset-0 pointer-events-none"
@@ -8246,7 +8320,7 @@ function GameMenu({
8246
8320
  }) {
8247
8321
  const resolvedOptions = (options?.length ? options : void 0) ?? (menuItems?.length ? menuItems : void 0) ?? DEFAULT_MENU_OPTIONS;
8248
8322
  const eventBus = useEventBus();
8249
- const handleOptionClick = React81.useCallback(
8323
+ const handleOptionClick = React82.useCallback(
8250
8324
  (option) => {
8251
8325
  if (option.event) {
8252
8326
  eventBus.emit(`UI:${option.event}`, { option });
@@ -8265,39 +8339,48 @@ function GameMenu({
8265
8339
  {
8266
8340
  className: cn(
8267
8341
  "min-h-screen w-full flex flex-col items-center justify-center p-8",
8342
+ !background && "bg-background",
8268
8343
  className
8269
8344
  ),
8270
- style: {
8271
- background: background ?? "linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f0e17 100%)"
8272
- },
8345
+ style: background ? { background } : void 0,
8273
8346
  children: [
8274
- /* @__PURE__ */ jsxs(Box, { className: "text-center mb-12 animate-fade-in", children: [
8275
- logo && /* @__PURE__ */ jsx(GameIcon, { assetUrl: logo, icon: "image", size: 96, alt: title, className: "h-24 w-auto mx-auto mb-6 drop-shadow-2xl" }),
8276
- /* @__PURE__ */ jsx(
8277
- Typography,
8278
- {
8279
- variant: "h1",
8280
- className: "text-5xl md:text-7xl font-bold text-[var(--color-foreground)] tracking-tight",
8281
- style: {
8282
- textShadow: "0 4px 12px rgba(0,0,0,0.5)"
8283
- },
8284
- children: title
8285
- }
8286
- ),
8287
- subtitle && /* @__PURE__ */ jsx(Typography, { variant: "body", className: "mt-2 text-lg text-muted-foreground tracking-widest uppercase", children: subtitle })
8288
- ] }),
8289
- /* @__PURE__ */ jsx(Box, { className: "flex flex-col gap-4 w-full max-w-md", children: resolvedOptions.map((option, index) => /* @__PURE__ */ jsx(
8290
- ChoiceButton,
8347
+ /* @__PURE__ */ jsxs(
8348
+ Card,
8291
8349
  {
8292
- text: option.label,
8293
- index: index + 1,
8294
- disabled: option.disabled,
8295
- onClick: () => handleOptionClick(option),
8296
- className: "text-lg py-4 px-8"
8297
- },
8298
- index
8299
- )) }),
8300
- /* @__PURE__ */ jsxs(Box, { position: "absolute", className: "inset-0 pointer-events-none overflow-hidden", children: [
8350
+ variant: "bordered",
8351
+ padding: "lg",
8352
+ className: "bg-card flex flex-col items-center max-w-md w-full",
8353
+ children: [
8354
+ /* @__PURE__ */ jsxs(Box, { className: "text-center mb-8 animate-fade-in", children: [
8355
+ logo && /* @__PURE__ */ jsx(GameIcon, { assetUrl: logo, icon: "image", size: 96, alt: title, className: "h-24 w-auto mx-auto mb-6 drop-shadow-2xl" }),
8356
+ /* @__PURE__ */ jsx(
8357
+ Typography,
8358
+ {
8359
+ variant: "h1",
8360
+ className: "text-4xl md:text-5xl font-bold text-foreground tracking-tight",
8361
+ style: {
8362
+ textShadow: "0 4px 12px rgba(0,0,0,0.5)"
8363
+ },
8364
+ children: title
8365
+ }
8366
+ ),
8367
+ subtitle && /* @__PURE__ */ jsx(Typography, { variant: "body", className: "mt-2 text-lg text-muted-foreground tracking-widest uppercase", children: subtitle })
8368
+ ] }),
8369
+ /* @__PURE__ */ jsx(Box, { className: "flex flex-col gap-4 w-full", children: resolvedOptions.map((option, index) => /* @__PURE__ */ jsx(
8370
+ ChoiceButton,
8371
+ {
8372
+ text: option.label,
8373
+ index: index + 1,
8374
+ disabled: option.disabled,
8375
+ onClick: () => handleOptionClick(option),
8376
+ className: "text-lg py-4 px-8"
8377
+ },
8378
+ index
8379
+ )) })
8380
+ ]
8381
+ }
8382
+ ),
8383
+ /* @__PURE__ */ jsxs(Box, { position: "absolute", className: "inset-0 pointer-events-none overflow-hidden -z-10", children: [
8301
8384
  /* @__PURE__ */ jsx(Box, { position: "absolute", className: "top-1/4 left-1/4 w-64 h-64 bg-info/10 rounded-container blur-3xl" }),
8302
8385
  /* @__PURE__ */ jsx(Box, { position: "absolute", className: "bottom-1/4 right-1/4 w-96 h-96 bg-accent/10 rounded-container blur-3xl" })
8303
8386
  ] })
@@ -8312,6 +8395,7 @@ var init_GameMenu = __esm({
8312
8395
  init_cn();
8313
8396
  init_useEventBus();
8314
8397
  init_Box();
8398
+ init_Card();
8315
8399
  init_Typography();
8316
8400
  init_GameIcon();
8317
8401
  init_ChoiceButton();
@@ -8472,7 +8556,7 @@ function StateGraph({
8472
8556
  }) {
8473
8557
  const eventBus = useEventBus();
8474
8558
  const nodes = states ?? [];
8475
- const positions = React81.useMemo(() => layoutStates(nodes, width, height), [nodes, width, height]);
8559
+ const positions = React82.useMemo(() => layoutStates(nodes, width, height), [nodes, width, height]);
8476
8560
  return /* @__PURE__ */ jsxs(
8477
8561
  Box,
8478
8562
  {
@@ -8543,8 +8627,8 @@ function MiniMap({
8543
8627
  tileAssets,
8544
8628
  unitAssets
8545
8629
  }) {
8546
- const canvasRef = React81.useRef(null);
8547
- const imgCacheRef = React81.useRef(/* @__PURE__ */ new Map());
8630
+ const canvasRef = React82.useRef(null);
8631
+ const imgCacheRef = React82.useRef(/* @__PURE__ */ new Map());
8548
8632
  function loadImg(url) {
8549
8633
  const cached = imgCacheRef.current.get(url);
8550
8634
  if (cached) return cached.complete ? cached : null;
@@ -8559,7 +8643,7 @@ function MiniMap({
8559
8643
  imgCacheRef.current.set(url, img);
8560
8644
  return null;
8561
8645
  }
8562
- React81.useEffect(() => {
8646
+ React82.useEffect(() => {
8563
8647
  const canvas = canvasRef.current;
8564
8648
  if (!canvas) return;
8565
8649
  const ctx = canvas.getContext("2d");
@@ -9874,7 +9958,7 @@ function LinearView({
9874
9958
  /* @__PURE__ */ jsx(HStack, { className: "flex-wrap items-center", gap: "xs", children: trait.states.map((state, i) => {
9875
9959
  const isDone = i < currentIdx;
9876
9960
  const isCurrent = i === currentIdx;
9877
- return /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
9961
+ return /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
9878
9962
  i > 0 && /* @__PURE__ */ jsx(
9879
9963
  Typography,
9880
9964
  {
@@ -10409,7 +10493,7 @@ function SequenceBar({
10409
10493
  else onSlotRemove?.(index);
10410
10494
  }, [emit, slotRemoveEvent, onSlotRemove, playing]);
10411
10495
  const paddedSlots = Array.from({ length: maxSlots }, (_, i) => slots[i]);
10412
- return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
10496
+ return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
10413
10497
  i > 0 && /* @__PURE__ */ jsx(
10414
10498
  Typography,
10415
10499
  {
@@ -10496,6 +10580,7 @@ var init_GameShell = __esm({
10496
10580
  "components/game/templates/GameShell.tsx"() {
10497
10581
  init_cn();
10498
10582
  init_Box();
10583
+ init_Card();
10499
10584
  init_Typography();
10500
10585
  init_AtlasImage();
10501
10586
  FONT_BASE = "https://almadar-kflow-assets.web.app/shared/_shared/kenney-fonts/fonts";
@@ -10524,13 +10609,14 @@ var init_GameShell = __esm({
10524
10609
  showTopBar = true,
10525
10610
  children,
10526
10611
  backgroundAsset,
10527
- hudBackgroundAsset,
10528
- fontFamily = "future"
10612
+ fontFamily = "future",
10613
+ "data-theme": dataTheme
10529
10614
  }) => {
10530
10615
  const font = GAME_FONTS[fontFamily] ?? fontFamily;
10531
10616
  return /* @__PURE__ */ jsxs(
10532
10617
  Box,
10533
10618
  {
10619
+ "data-theme": dataTheme || void 0,
10534
10620
  className: cn("game-shell", className),
10535
10621
  style: {
10536
10622
  position: "relative",
@@ -10538,7 +10624,7 @@ var init_GameShell = __esm({
10538
10624
  height: "100vh",
10539
10625
  overflow: "hidden",
10540
10626
  background: "var(--color-background, #0a0a0f)",
10541
- color: "var(--color-text, #e0e0e0)",
10627
+ color: "var(--color-foreground, #e0e0e0)",
10542
10628
  fontFamily: `'${font}', system-ui, sans-serif`
10543
10629
  },
10544
10630
  children: [
@@ -10570,19 +10656,12 @@ var init_GameShell = __esm({
10570
10656
  },
10571
10657
  children: [
10572
10658
  showTopBar && /* @__PURE__ */ jsx(
10573
- AtlasPanel,
10659
+ Card,
10574
10660
  {
10575
- asset: hudBackgroundAsset,
10576
- borderSlice: 12,
10577
- borderWidth: 10,
10578
- className: "game-shell__title pointer-events-auto",
10579
- style: {
10580
- padding: "6px 16px",
10581
- background: hudBackgroundAsset ? void 0 : "rgba(18, 18, 31, 0.85)",
10582
- borderRadius: hudBackgroundAsset ? void 0 : 10,
10583
- boxShadow: "0 4px 14px rgba(0,0,0,0.45)",
10584
- flexShrink: 0
10585
- },
10661
+ variant: "bordered",
10662
+ padding: "none",
10663
+ className: "game-shell__title bg-card pointer-events-auto",
10664
+ style: { padding: "6px 16px", flexShrink: 0 },
10586
10665
  children: /* @__PURE__ */ jsx(
10587
10666
  Typography,
10588
10667
  {
@@ -11063,7 +11142,7 @@ var init_ErrorBoundary = __esm({
11063
11142
  }
11064
11143
  );
11065
11144
  };
11066
- ErrorBoundary = class extends React81__default.Component {
11145
+ ErrorBoundary = class extends React82__default.Component {
11067
11146
  constructor(props) {
11068
11147
  super(props);
11069
11148
  __publicField(this, "reset", () => {
@@ -11330,7 +11409,7 @@ var init_Container = __esm({
11330
11409
  as: Component = "div"
11331
11410
  }) => {
11332
11411
  const resolvedSize = maxWidth ?? size ?? "lg";
11333
- return React81__default.createElement(
11412
+ return React82__default.createElement(
11334
11413
  Component,
11335
11414
  {
11336
11415
  className: cn(
@@ -14157,7 +14236,7 @@ var init_CodeBlock = __esm({
14157
14236
  DIFF_STYLE_FALLBACK = { bg: "", prefix: " ", text: "text-foreground" };
14158
14237
  LINE_PROPS_FN = (n) => ({ "data-line": String(n - 1) });
14159
14238
  HIDDEN_LINE_NUMBERS = { display: "none" };
14160
- CodeBlock = React81__default.memo(
14239
+ CodeBlock = React82__default.memo(
14161
14240
  ({
14162
14241
  code: rawCode,
14163
14242
  language = "text",
@@ -14744,7 +14823,7 @@ var init_MarkdownContent = __esm({
14744
14823
  init_Box();
14745
14824
  init_CodeBlock();
14746
14825
  init_cn();
14747
- MarkdownContent = React81__default.memo(
14826
+ MarkdownContent = React82__default.memo(
14748
14827
  ({ content, direction = "ltr", className }) => {
14749
14828
  const { t: _t } = useTranslate();
14750
14829
  const safeContent = typeof content === "string" ? content : String(content ?? "");
@@ -15657,7 +15736,7 @@ var init_StateMachineView = __esm({
15657
15736
  Box,
15658
15737
  {
15659
15738
  className: cn(
15660
- "fixed z-50 animate-in fade-in-0 zoom-in-95 duration-150",
15739
+ "fixed z-50 animate-in fade-in-0 zoom-in-95 duration-fast",
15661
15740
  tooltip.pinned ? "pointer-events-auto" : "pointer-events-none"
15662
15741
  ),
15663
15742
  style: {
@@ -16021,7 +16100,7 @@ var init_StateMachineView = __esm({
16021
16100
  style: { top: title ? 30 : 0 },
16022
16101
  children: [
16023
16102
  entity && /* @__PURE__ */ jsx(EntityBox, { entity, config }),
16024
- states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(React81__default.Fragment, { children: renderStateNode(state, config) }, state.id) : /* @__PURE__ */ jsx(
16103
+ states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(React82__default.Fragment, { children: renderStateNode(state, config) }, state.id) : /* @__PURE__ */ jsx(
16025
16104
  StateNode2,
16026
16105
  {
16027
16106
  state,
@@ -18060,6 +18139,129 @@ var init_Breadcrumb = __esm({
18060
18139
  Breadcrumb.displayName = "Breadcrumb";
18061
18140
  }
18062
18141
  });
18142
+ function useSafeEventBus2() {
18143
+ try {
18144
+ return useEventBus();
18145
+ } catch {
18146
+ return { emit: () => {
18147
+ }, on: () => () => {
18148
+ }, once: () => {
18149
+ } };
18150
+ }
18151
+ }
18152
+ var log7, lookStyles4, ButtonGroup;
18153
+ var init_ButtonGroup = __esm({
18154
+ "components/core/molecules/ButtonGroup.tsx"() {
18155
+ "use client";
18156
+ init_cn();
18157
+ init_atoms();
18158
+ init_useEventBus();
18159
+ log7 = createLogger("almadar:ui:button-group");
18160
+ lookStyles4 = {
18161
+ "right-aligned-buttons": "",
18162
+ "floating-bar": "fixed bottom-section left-1/2 -translate-x-1/2 shadow-elevation-toast bg-card p-card-sm rounded-container",
18163
+ "inline-row": "gap-2 inline-flex",
18164
+ "dropdown-menu": "[&>button:not(:first-child)]:hidden",
18165
+ "command-palette-trigger": "[&>button:not(:first-child)]:hidden"
18166
+ };
18167
+ ButtonGroup = ({
18168
+ children,
18169
+ primary,
18170
+ secondary,
18171
+ variant = "default",
18172
+ orientation = "horizontal",
18173
+ className,
18174
+ // Filter-group pattern props (entity and filters are used for schema-driven filtering)
18175
+ entity: _entity,
18176
+ filters,
18177
+ look = "right-aligned-buttons"
18178
+ }) => {
18179
+ const eventBus = useSafeEventBus2();
18180
+ const variantClasses2 = {
18181
+ default: "gap-0",
18182
+ segmented: "gap-0 [&>button]:rounded-none [&>button:first-child]:rounded-l-lg [&>button:last-child]:rounded-r-lg [&>button:not(:first-child)]:border-l-0",
18183
+ toggle: "gap-0 [&>button]:rounded-none [&>button:first-child]:rounded-l-lg [&>button:last-child]:rounded-r-lg [&>button:not(:first-child)]:border-l-0"
18184
+ };
18185
+ const orientationClasses = {
18186
+ horizontal: "flex-row",
18187
+ vertical: "flex-col [&>button:first-child]:rounded-t-lg [&>button:last-child]:rounded-b-lg [&>button:not(:first-child)]:border-t-0 [&>button:not(:first-child)]:border-l"
18188
+ };
18189
+ const handleActionClick = (action) => {
18190
+ if (action.event) {
18191
+ eventBus.emit("UI:DISPATCH", { event: action.event });
18192
+ }
18193
+ if (action.navigatesTo) {
18194
+ eventBus.emit("UI:NAVIGATE", { url: action.navigatesTo });
18195
+ }
18196
+ };
18197
+ const renderFormActions = () => {
18198
+ const buttons = [];
18199
+ if (secondary) {
18200
+ secondary.forEach((action, index) => {
18201
+ buttons.push(
18202
+ /* @__PURE__ */ jsx(
18203
+ Button,
18204
+ {
18205
+ type: action.actionType === "submit" ? "submit" : "button",
18206
+ variant: action.variant || "ghost",
18207
+ onClick: () => handleActionClick(action),
18208
+ children: action.label
18209
+ },
18210
+ `secondary-${index}`
18211
+ )
18212
+ );
18213
+ });
18214
+ }
18215
+ if (primary) {
18216
+ const isSubmit = primary.actionType === "submit";
18217
+ buttons.push(
18218
+ /* @__PURE__ */ jsx(
18219
+ Button,
18220
+ {
18221
+ type: isSubmit ? "submit" : "button",
18222
+ variant: primary.variant || "primary",
18223
+ onClick: () => handleActionClick(primary),
18224
+ "data-testid": isSubmit ? "form-submit" : void 0,
18225
+ children: primary.label
18226
+ },
18227
+ "primary"
18228
+ )
18229
+ );
18230
+ }
18231
+ return buttons;
18232
+ };
18233
+ const renderFilters = () => {
18234
+ if (!filters || filters.length === 0) return null;
18235
+ return filters.map((filter, index) => /* @__PURE__ */ jsx(
18236
+ Button,
18237
+ {
18238
+ variant: "ghost",
18239
+ onClick: () => {
18240
+ log7.debug("Filter clicked", { field: filter.field });
18241
+ },
18242
+ children: filter.label
18243
+ },
18244
+ `filter-${filter.field}-${index}`
18245
+ ));
18246
+ };
18247
+ return /* @__PURE__ */ jsx(
18248
+ "div",
18249
+ {
18250
+ className: cn(
18251
+ "inline-flex gap-2",
18252
+ variantClasses2[variant],
18253
+ orientationClasses[orientation],
18254
+ lookStyles4[look],
18255
+ className
18256
+ ),
18257
+ role: "group",
18258
+ children: children || renderFilters() || renderFormActions()
18259
+ }
18260
+ );
18261
+ };
18262
+ ButtonGroup.displayName = "ButtonGroup";
18263
+ }
18264
+ });
18063
18265
  function dayWindowForViewport(width) {
18064
18266
  if (width <= 640) return 1;
18065
18267
  if (width <= 1024) return 3;
@@ -18802,7 +19004,7 @@ var init_CardGrid = __esm({
18802
19004
  CardGrid.displayName = "CardGrid";
18803
19005
  }
18804
19006
  });
18805
- function useSafeEventBus2() {
19007
+ function useSafeEventBus3() {
18806
19008
  try {
18807
19009
  return useEventBus();
18808
19010
  } catch {
@@ -18838,7 +19040,7 @@ var init_Carousel = __esm({
18838
19040
  const [activeIndex, setActiveIndex] = useState(0);
18839
19041
  const scrollRef = useRef(null);
18840
19042
  const autoPlayRef = useRef(null);
18841
- const eventBus = useSafeEventBus2();
19043
+ const eventBus = useSafeEventBus3();
18842
19044
  const { t } = useTranslate();
18843
19045
  const safeItems = items ?? [];
18844
19046
  const totalSlides = safeItems.length;
@@ -19200,7 +19402,7 @@ var init_Chart = __esm({
19200
19402
  return /* @__PURE__ */ jsx(
19201
19403
  Box,
19202
19404
  {
19203
- className: "h-full rounded-r-sm transition-all duration-500 ease-out min-w-[2px] cursor-pointer hover:opacity-80",
19405
+ className: "h-full rounded-r-sm transition-all duration-slow ease-standard min-w-[2px] cursor-pointer hover:opacity-80",
19204
19406
  style: {
19205
19407
  width: `${ratio}%`,
19206
19408
  backgroundColor: color
@@ -19256,7 +19458,7 @@ var init_Chart = __esm({
19256
19458
  Box,
19257
19459
  {
19258
19460
  className: cn(
19259
- "rounded-t-sm transition-all duration-500 ease-out min-h-[4px] cursor-pointer hover:opacity-80",
19461
+ "rounded-t-sm transition-all duration-slow ease-standard min-h-[4px] cursor-pointer hover:opacity-80",
19260
19462
  histogram ? "flex-1 mx-0" : "flex-1"
19261
19463
  ),
19262
19464
  style: {
@@ -19306,7 +19508,7 @@ var init_Chart = __esm({
19306
19508
  return /* @__PURE__ */ jsx(
19307
19509
  Box,
19308
19510
  {
19309
- className: "w-full transition-all duration-500 ease-out cursor-pointer hover:opacity-80",
19511
+ className: "w-full transition-all duration-slow ease-standard cursor-pointer hover:opacity-80",
19310
19512
  style: {
19311
19513
  height: `${ratio}%`,
19312
19514
  backgroundColor: color
@@ -19396,7 +19598,7 @@ var init_Chart = __esm({
19396
19598
  fill: seg.color,
19397
19599
  stroke: "var(--color-card)",
19398
19600
  strokeWidth: "2",
19399
- className: "transition-opacity duration-200 hover:opacity-80 cursor-pointer",
19601
+ className: "transition-opacity duration-fast hover:opacity-80 cursor-pointer",
19400
19602
  onClick: () => onPointClick?.(
19401
19603
  { label: seg.label, value: seg.value, color: seg.color },
19402
19604
  "default"
@@ -21595,8 +21797,8 @@ var init_Menu = __esm({
21595
21797
  "bottom-end": "bottom-start"
21596
21798
  };
21597
21799
  const effectivePosition = direction === "rtl" ? rtlMirror[position] ?? position : position;
21598
- const triggerChild = React81__default.isValidElement(trigger) ? trigger : /* @__PURE__ */ jsx(Typography, { variant: "small", as: "span", children: trigger });
21599
- const triggerElement = React81__default.cloneElement(
21800
+ const triggerChild = React82__default.isValidElement(trigger) ? trigger : /* @__PURE__ */ jsx(Typography, { variant: "small", as: "span", children: trigger });
21801
+ const triggerElement = React82__default.cloneElement(
21600
21802
  triggerChild,
21601
21803
  {
21602
21804
  ref: triggerRef,
@@ -21691,14 +21893,14 @@ function useDataDnd(args) {
21691
21893
  const isZone = Boolean(dragGroup || accepts || sortable);
21692
21894
  const enabled = isZone || Boolean(dndRoot);
21693
21895
  const eventBus = useEventBus();
21694
- const parentRoot = React81__default.useContext(RootCtx);
21896
+ const parentRoot = React82__default.useContext(RootCtx);
21695
21897
  const isRoot = enabled && parentRoot === null;
21696
- const zoneId = React81__default.useId();
21898
+ const zoneId = React82__default.useId();
21697
21899
  const ownGroup = dragGroup ?? accepts ?? zoneId;
21698
- const [optimisticOrders, setOptimisticOrders] = React81__default.useState(() => /* @__PURE__ */ new Map());
21699
- const optimisticOrdersRef = React81__default.useRef(optimisticOrders);
21900
+ const [optimisticOrders, setOptimisticOrders] = React82__default.useState(() => /* @__PURE__ */ new Map());
21901
+ const optimisticOrdersRef = React82__default.useRef(optimisticOrders);
21700
21902
  optimisticOrdersRef.current = optimisticOrders;
21701
- const clearOptimisticOrder = React81__default.useCallback((group) => {
21903
+ const clearOptimisticOrder = React82__default.useCallback((group) => {
21702
21904
  setOptimisticOrders((prev) => {
21703
21905
  if (!prev.has(group)) return prev;
21704
21906
  const next = new Map(prev);
@@ -21723,7 +21925,7 @@ function useDataDnd(args) {
21723
21925
  const raw = it[dndItemIdField];
21724
21926
  return raw != null ? String(raw) : `__idx_${idx}`;
21725
21927
  }).join("|");
21726
- const itemIds = React81__default.useMemo(
21928
+ const itemIds = React82__default.useMemo(
21727
21929
  () => orderedItems.map((it, idx) => {
21728
21930
  const raw = it[dndItemIdField];
21729
21931
  return raw != null ? String(raw) : `__idx_${idx}`;
@@ -21734,7 +21936,7 @@ function useDataDnd(args) {
21734
21936
  const raw = it[dndItemIdField];
21735
21937
  return raw != null ? String(raw) : `__${idx}`;
21736
21938
  }).join("|");
21737
- React81__default.useEffect(() => {
21939
+ React82__default.useEffect(() => {
21738
21940
  const root = isRoot ? null : parentRoot;
21739
21941
  if (root) {
21740
21942
  root.clearOptimisticOrder(ownGroup);
@@ -21742,20 +21944,20 @@ function useDataDnd(args) {
21742
21944
  clearOptimisticOrder(ownGroup);
21743
21945
  }
21744
21946
  }, [itemsContentSig, ownGroup]);
21745
- const zonesRef = React81__default.useRef(/* @__PURE__ */ new Map());
21746
- const registerZone = React81__default.useCallback((zoneId2, meta2) => {
21947
+ const zonesRef = React82__default.useRef(/* @__PURE__ */ new Map());
21948
+ const registerZone = React82__default.useCallback((zoneId2, meta2) => {
21747
21949
  zonesRef.current.set(zoneId2, meta2);
21748
21950
  }, []);
21749
- const unregisterZone = React81__default.useCallback((zoneId2) => {
21951
+ const unregisterZone = React82__default.useCallback((zoneId2) => {
21750
21952
  zonesRef.current.delete(zoneId2);
21751
21953
  }, []);
21752
- const [activeDrag, setActiveDrag] = React81__default.useState(null);
21753
- const [overZoneGroup, setOverZoneGroup] = React81__default.useState(null);
21754
- const meta = React81__default.useMemo(
21954
+ const [activeDrag, setActiveDrag] = React82__default.useState(null);
21955
+ const [overZoneGroup, setOverZoneGroup] = React82__default.useState(null);
21956
+ const meta = React82__default.useMemo(
21755
21957
  () => ({ group: ownGroup, dropEvent, reorderEvent, positionEvent, itemIds, rawItems: items, idField: dndItemIdField }),
21756
21958
  [ownGroup, dropEvent, reorderEvent, positionEvent, itemIds, items, dndItemIdField]
21757
21959
  );
21758
- React81__default.useEffect(() => {
21960
+ React82__default.useEffect(() => {
21759
21961
  const target = isRoot ? null : parentRoot;
21760
21962
  if (!target) {
21761
21963
  zonesRef.current.set(zoneId, meta);
@@ -21774,7 +21976,7 @@ function useDataDnd(args) {
21774
21976
  }, [parentRoot, isRoot, zoneId, meta]);
21775
21977
  const sensors = useAlmadarDndSensors(true);
21776
21978
  const collisionDetection = almadarDndCollisionDetection;
21777
- const findZoneByItem = React81__default.useCallback(
21979
+ const findZoneByItem = React82__default.useCallback(
21778
21980
  (id) => {
21779
21981
  for (const z of zonesRef.current.values()) {
21780
21982
  if (z.itemIds.includes(id)) return z;
@@ -21783,7 +21985,7 @@ function useDataDnd(args) {
21783
21985
  },
21784
21986
  []
21785
21987
  );
21786
- React81__default.useCallback(
21988
+ React82__default.useCallback(
21787
21989
  (group) => {
21788
21990
  for (const z of zonesRef.current.values()) {
21789
21991
  if (z.group === group) return z;
@@ -21792,7 +21994,7 @@ function useDataDnd(args) {
21792
21994
  },
21793
21995
  []
21794
21996
  );
21795
- const handleDragEnd = React81__default.useCallback(
21997
+ const handleDragEnd = React82__default.useCallback(
21796
21998
  (event) => {
21797
21999
  const { active, over } = event;
21798
22000
  const activeIdStr = String(active.id);
@@ -21883,8 +22085,8 @@ function useDataDnd(args) {
21883
22085
  },
21884
22086
  [eventBus]
21885
22087
  );
21886
- const sortableData = React81__default.useMemo(() => ({ dndGroup: ownGroup }), [ownGroup]);
21887
- const SortableItem = React81__default.useCallback(
22088
+ const sortableData = React82__default.useMemo(() => ({ dndGroup: ownGroup }), [ownGroup]);
22089
+ const SortableItem = React82__default.useCallback(
21888
22090
  ({ id, children }) => {
21889
22091
  const {
21890
22092
  attributes,
@@ -21924,7 +22126,7 @@ function useDataDnd(args) {
21924
22126
  id: droppableId,
21925
22127
  data: sortableData
21926
22128
  });
21927
- const ctx = React81__default.useContext(RootCtx);
22129
+ const ctx = React82__default.useContext(RootCtx);
21928
22130
  const activeDrag2 = ctx?.activeDrag ?? null;
21929
22131
  const overZoneGroup2 = ctx?.overZoneGroup ?? null;
21930
22132
  const isThisZoneOver = overZoneGroup2 === ownGroup;
@@ -21939,7 +22141,7 @@ function useDataDnd(args) {
21939
22141
  showForeignPlaceholder,
21940
22142
  ctxAvailable: ctx != null
21941
22143
  });
21942
- React81__default.useEffect(() => {
22144
+ React82__default.useEffect(() => {
21943
22145
  dndLog.info("dropzone:isOver:change", { droppableId, group: ownGroup, isOver, isThisZoneOver, showForeignPlaceholder, activeDragSourceGroup: activeDrag2?.sourceGroup ?? null });
21944
22146
  }, [droppableId, isOver, isThisZoneOver, showForeignPlaceholder]);
21945
22147
  return /* @__PURE__ */ jsx(
@@ -21953,11 +22155,11 @@ function useDataDnd(args) {
21953
22155
  }
21954
22156
  );
21955
22157
  };
21956
- const rootContextValue = React81__default.useMemo(
22158
+ const rootContextValue = React82__default.useMemo(
21957
22159
  () => ({ registerZone, unregisterZone, activeDrag, overZoneGroup, optimisticOrders, clearOptimisticOrder }),
21958
22160
  [registerZone, unregisterZone, activeDrag, overZoneGroup, optimisticOrders, clearOptimisticOrder]
21959
22161
  );
21960
- const handleDragStart = React81__default.useCallback((event) => {
22162
+ const handleDragStart = React82__default.useCallback((event) => {
21961
22163
  const sourceZone = findZoneByItem(event.active.id);
21962
22164
  const rect = event.active.rect.current.initial;
21963
22165
  const height = rect?.height && rect.height > 0 ? rect.height : 64;
@@ -21976,7 +22178,7 @@ function useDataDnd(args) {
21976
22178
  isRoot
21977
22179
  });
21978
22180
  }, [findZoneByItem, isRoot, zoneId]);
21979
- const handleDragOver = React81__default.useCallback((event) => {
22181
+ const handleDragOver = React82__default.useCallback((event) => {
21980
22182
  const { active, over } = event;
21981
22183
  const overData = over?.data?.current;
21982
22184
  const overGroup = overData?.dndGroup ?? null;
@@ -22046,7 +22248,7 @@ function useDataDnd(args) {
22046
22248
  return next;
22047
22249
  });
22048
22250
  }, []);
22049
- const handleDragCancel = React81__default.useCallback((event) => {
22251
+ const handleDragCancel = React82__default.useCallback((event) => {
22050
22252
  setActiveDrag(null);
22051
22253
  setOverZoneGroup(null);
22052
22254
  dndLog.warn("dragCancel", {
@@ -22054,12 +22256,12 @@ function useDataDnd(args) {
22054
22256
  reason: "dnd-kit cancelled the drag (escape key, pointer interrupted, or external)"
22055
22257
  });
22056
22258
  }, []);
22057
- const handleDragEndWithCleanup = React81__default.useCallback((event) => {
22259
+ const handleDragEndWithCleanup = React82__default.useCallback((event) => {
22058
22260
  handleDragEnd(event);
22059
22261
  setActiveDrag(null);
22060
22262
  setOverZoneGroup(null);
22061
22263
  }, [handleDragEnd]);
22062
- const wrapContainer = React81__default.useCallback(
22264
+ const wrapContainer = React82__default.useCallback(
22063
22265
  (children) => {
22064
22266
  if (!enabled) return children;
22065
22267
  const strategy = layout === "grid" ? rectSortingStrategy : verticalListSortingStrategy;
@@ -22113,7 +22315,7 @@ var init_useDataDnd = __esm({
22113
22315
  init_useAlmadarDndCollision();
22114
22316
  init_Box();
22115
22317
  dndLog = createLogger("almadar:ui:dnd");
22116
- RootCtx = React81__default.createContext(null);
22318
+ RootCtx = React82__default.createContext(null);
22117
22319
  }
22118
22320
  });
22119
22321
  function renderIconInput(icon, props) {
@@ -22310,7 +22512,7 @@ function DataGrid({
22310
22512
  /* @__PURE__ */ jsx(
22311
22513
  Box,
22312
22514
  {
22313
- className: cn("grid", gapStyles5[gap], scrollX ? "grid-flow-col overflow-x-auto" : colsClass, lookStyles4[look], className),
22515
+ className: cn("grid", gapStyles5[gap], scrollX ? "grid-flow-col overflow-x-auto" : colsClass, lookStyles5[look], className),
22314
22516
  style: scrollX ? { gridAutoFlow: "column", gridAutoColumns: `minmax(${minCardWidth}px, 1fr)` } : gridTemplateColumns ? { gridTemplateColumns } : void 0,
22315
22517
  children: data.map((item, index) => {
22316
22518
  const itemData = item;
@@ -22505,7 +22707,7 @@ function DataGrid({
22505
22707
  ] })
22506
22708
  );
22507
22709
  }
22508
- var dataGridLog, BADGE_VARIANTS, gapStyles5, lookStyles4;
22710
+ var dataGridLog, BADGE_VARIANTS, gapStyles5, lookStyles5;
22509
22711
  var init_DataGrid = __esm({
22510
22712
  "components/core/molecules/DataGrid.tsx"() {
22511
22713
  "use client";
@@ -22540,7 +22742,7 @@ var init_DataGrid = __esm({
22540
22742
  lg: "gap-6",
22541
22743
  xl: "gap-8"
22542
22744
  };
22543
- lookStyles4 = {
22745
+ lookStyles5 = {
22544
22746
  dense: "gap-2 [&>*]:p-card-sm",
22545
22747
  spacious: "gap-8 [&>*]:p-card-lg",
22546
22748
  striped: "[&>*:nth-child(even)]:bg-muted/30",
@@ -22640,7 +22842,7 @@ function DataList({
22640
22842
  }) {
22641
22843
  const eventBus = useEventBus();
22642
22844
  const { t } = useTranslate();
22643
- const [visibleCount, setVisibleCount] = React81__default.useState(pageSize || Infinity);
22845
+ const [visibleCount, setVisibleCount] = React82__default.useState(pageSize || Infinity);
22644
22846
  const fieldDefs = fields ?? columns ?? [];
22645
22847
  const allDataRaw = Array.isArray(entity) ? entity : entity ? [entity] : [];
22646
22848
  const dnd = useDataDnd({
@@ -22659,7 +22861,7 @@ function DataList({
22659
22861
  const data = pageSize > 0 ? allData.slice(0, visibleCount) : allData;
22660
22862
  const hasMoreLocal = pageSize > 0 && visibleCount < allData.length;
22661
22863
  const hasRenderProp = typeof children === "function";
22662
- React81__default.useEffect(() => {
22864
+ React82__default.useEffect(() => {
22663
22865
  const renderItemTypeOf = typeof schemaRenderItem;
22664
22866
  const childrenTypeOf = typeof children;
22665
22867
  if (data.length > 0 && !hasRenderProp) {
@@ -22763,7 +22965,7 @@ function DataList({
22763
22965
  const items2 = [...data];
22764
22966
  const groups2 = groupBy ? groupData(items2, groupBy) : [{ label: "", items: items2 }];
22765
22967
  const contentField = titleField?.name ?? fieldDefs[0]?.name ?? "";
22766
- return /* @__PURE__ */ jsx(VStack, { gap: "sm", className: cn("py-2", className), children: groups2.map((group, gi) => /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
22968
+ return /* @__PURE__ */ jsx(VStack, { gap: "sm", className: cn("py-2", className), children: groups2.map((group, gi) => /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
22767
22969
  group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: "my-2" }),
22768
22970
  group.items.map((itemData, index) => {
22769
22971
  const id = itemData.id || `${gi}-${index}`;
@@ -22904,7 +23106,7 @@ function DataList({
22904
23106
  className
22905
23107
  ),
22906
23108
  children: [
22907
- groups.map((group, gi) => /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
23109
+ groups.map((group, gi) => /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
22908
23110
  group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: gi > 0 ? "mt-4" : "mt-0" }),
22909
23111
  group.items.map(
22910
23112
  (itemData, index) => renderItem(itemData, index, gi === groups.length - 1 && index === group.items.length - 1)
@@ -22989,7 +23191,7 @@ var init_FormSection = __esm({
22989
23191
  columns = 1,
22990
23192
  className
22991
23193
  }) => {
22992
- const [collapsed, setCollapsed] = React81__default.useState(defaultCollapsed);
23194
+ const [collapsed, setCollapsed] = React82__default.useState(defaultCollapsed);
22993
23195
  const { t } = useTranslate();
22994
23196
  const eventBus = useEventBus();
22995
23197
  const gridClass = {
@@ -22997,7 +23199,7 @@ var init_FormSection = __esm({
22997
23199
  2: "grid-cols-1 md:grid-cols-2",
22998
23200
  3: "grid-cols-1 md:grid-cols-2 lg:grid-cols-3"
22999
23201
  }[columns];
23000
- React81__default.useCallback(() => {
23202
+ React82__default.useCallback(() => {
23001
23203
  if (collapsible) {
23002
23204
  setCollapsed((prev) => !prev);
23003
23205
  eventBus.emit("UI:TOGGLE_COLLAPSE", { collapsed: !collapsed });
@@ -23255,129 +23457,6 @@ var init_FormField = __esm({
23255
23457
  FormField.displayName = "FormField";
23256
23458
  }
23257
23459
  });
23258
- function useSafeEventBus3() {
23259
- try {
23260
- return useEventBus();
23261
- } catch {
23262
- return { emit: () => {
23263
- }, on: () => () => {
23264
- }, once: () => {
23265
- } };
23266
- }
23267
- }
23268
- var log7, lookStyles5, ButtonGroup;
23269
- var init_ButtonGroup = __esm({
23270
- "components/core/molecules/ButtonGroup.tsx"() {
23271
- "use client";
23272
- init_cn();
23273
- init_atoms();
23274
- init_useEventBus();
23275
- log7 = createLogger("almadar:ui:button-group");
23276
- lookStyles5 = {
23277
- "right-aligned-buttons": "",
23278
- "floating-bar": "fixed bottom-section left-1/2 -translate-x-1/2 shadow-elevation-toast bg-card p-card-sm rounded-container",
23279
- "inline-row": "gap-2 inline-flex",
23280
- "dropdown-menu": "[&>button:not(:first-child)]:hidden",
23281
- "command-palette-trigger": "[&>button:not(:first-child)]:hidden"
23282
- };
23283
- ButtonGroup = ({
23284
- children,
23285
- primary,
23286
- secondary,
23287
- variant = "default",
23288
- orientation = "horizontal",
23289
- className,
23290
- // Filter-group pattern props (entity and filters are used for schema-driven filtering)
23291
- entity: _entity,
23292
- filters,
23293
- look = "right-aligned-buttons"
23294
- }) => {
23295
- const eventBus = useSafeEventBus3();
23296
- const variantClasses2 = {
23297
- default: "gap-0",
23298
- segmented: "gap-0 [&>button]:rounded-none [&>button:first-child]:rounded-l-lg [&>button:last-child]:rounded-r-lg [&>button:not(:first-child)]:border-l-0",
23299
- toggle: "gap-0 [&>button]:rounded-none [&>button:first-child]:rounded-l-lg [&>button:last-child]:rounded-r-lg [&>button:not(:first-child)]:border-l-0"
23300
- };
23301
- const orientationClasses = {
23302
- horizontal: "flex-row",
23303
- vertical: "flex-col [&>button:first-child]:rounded-t-lg [&>button:last-child]:rounded-b-lg [&>button:not(:first-child)]:border-t-0 [&>button:not(:first-child)]:border-l"
23304
- };
23305
- const handleActionClick = (action) => {
23306
- if (action.event) {
23307
- eventBus.emit("UI:DISPATCH", { event: action.event });
23308
- }
23309
- if (action.navigatesTo) {
23310
- eventBus.emit("UI:NAVIGATE", { url: action.navigatesTo });
23311
- }
23312
- };
23313
- const renderFormActions = () => {
23314
- const buttons = [];
23315
- if (secondary) {
23316
- secondary.forEach((action, index) => {
23317
- buttons.push(
23318
- /* @__PURE__ */ jsx(
23319
- Button,
23320
- {
23321
- type: action.actionType === "submit" ? "submit" : "button",
23322
- variant: action.variant || "ghost",
23323
- onClick: () => handleActionClick(action),
23324
- children: action.label
23325
- },
23326
- `secondary-${index}`
23327
- )
23328
- );
23329
- });
23330
- }
23331
- if (primary) {
23332
- const isSubmit = primary.actionType === "submit";
23333
- buttons.push(
23334
- /* @__PURE__ */ jsx(
23335
- Button,
23336
- {
23337
- type: isSubmit ? "submit" : "button",
23338
- variant: primary.variant || "primary",
23339
- onClick: () => handleActionClick(primary),
23340
- "data-testid": isSubmit ? "form-submit" : void 0,
23341
- children: primary.label
23342
- },
23343
- "primary"
23344
- )
23345
- );
23346
- }
23347
- return buttons;
23348
- };
23349
- const renderFilters = () => {
23350
- if (!filters || filters.length === 0) return null;
23351
- return filters.map((filter, index) => /* @__PURE__ */ jsx(
23352
- Button,
23353
- {
23354
- variant: "ghost",
23355
- onClick: () => {
23356
- log7.debug("Filter clicked", { field: filter.field });
23357
- },
23358
- children: filter.label
23359
- },
23360
- `filter-${filter.field}-${index}`
23361
- ));
23362
- };
23363
- return /* @__PURE__ */ jsx(
23364
- "div",
23365
- {
23366
- className: cn(
23367
- "inline-flex gap-2",
23368
- variantClasses2[variant],
23369
- orientationClasses[orientation],
23370
- lookStyles5[look],
23371
- className
23372
- ),
23373
- role: "group",
23374
- children: children || renderFilters() || renderFormActions()
23375
- }
23376
- );
23377
- };
23378
- ButtonGroup.displayName = "ButtonGroup";
23379
- }
23380
- });
23381
23460
  var resolveFilterType, lookStyles6, FilterGroup;
23382
23461
  var init_FilterGroup = __esm({
23383
23462
  "components/core/molecules/FilterGroup.tsx"() {
@@ -23490,7 +23569,7 @@ var init_FilterGroup = __esm({
23490
23569
  type: "button",
23491
23570
  onClick: () => handleFilterSelect(filter.field, null),
23492
23571
  className: cn(
23493
- "px-3 py-1.5 text-sm font-medium transition-all duration-[var(--transition-fast)]",
23572
+ "px-3 py-1.5 text-sm font-medium transition-all duration-fast",
23494
23573
  !selectedValues[filter.field] ? "bg-primary text-primary-foreground" : "bg-card text-muted-foreground hover:bg-muted"
23495
23574
  ),
23496
23575
  children: t("filterGroup.all")
@@ -23502,7 +23581,7 @@ var init_FilterGroup = __esm({
23502
23581
  type: "button",
23503
23582
  onClick: () => handleFilterSelect(filter.field, option),
23504
23583
  className: cn(
23505
- "px-3 py-1.5 text-sm font-medium transition-all duration-[var(--transition-fast)]",
23584
+ "px-3 py-1.5 text-sm font-medium transition-all duration-fast",
23506
23585
  "border-l-[length:var(--border-width)] border-border",
23507
23586
  selectedValues[filter.field] === option ? "bg-primary text-primary-foreground" : "bg-card text-muted-foreground hover:bg-muted"
23508
23587
  ),
@@ -23883,7 +23962,7 @@ var init_Flex = __esm({
23883
23962
  flexStyle.flexBasis = typeof basis === "number" ? `${basis}px` : basis;
23884
23963
  }
23885
23964
  }
23886
- return React81__default.createElement(Component, {
23965
+ return React82__default.createElement(Component, {
23887
23966
  className: cn(
23888
23967
  inline ? "inline-flex" : "flex",
23889
23968
  directionStyles[direction],
@@ -24002,7 +24081,7 @@ var init_Grid = __esm({
24002
24081
  as: Component = "div"
24003
24082
  }) => {
24004
24083
  const mergedStyle = rows ? { gridTemplateRows: `repeat(${rows}, minmax(0, 1fr))`, ...style } : style;
24005
- return React81__default.createElement(
24084
+ return React82__default.createElement(
24006
24085
  Component,
24007
24086
  {
24008
24087
  className: cn(
@@ -24113,6 +24192,7 @@ var init_Popover = __esm({
24113
24192
  "components/core/molecules/Popover.tsx"() {
24114
24193
  "use client";
24115
24194
  init_Typography();
24195
+ init_Presence();
24116
24196
  init_cn();
24117
24197
  init_useTapReveal();
24118
24198
  arrowClasses = {
@@ -24136,6 +24216,7 @@ var init_Popover = __esm({
24136
24216
  const [popoverWidth, setPopoverWidth] = useState(0);
24137
24217
  const triggerRef = useRef(null);
24138
24218
  const popoverRef = useRef(null);
24219
+ const { mounted, className: panelAnim, onAnimationEnd } = usePresence(isOpen, { animation: "popover" });
24139
24220
  const updatePosition = () => {
24140
24221
  if (triggerRef.current) {
24141
24222
  setTriggerRect(triggerRef.current.getBoundingClientRect());
@@ -24161,10 +24242,11 @@ var init_Popover = __esm({
24161
24242
  useEffect(() => {
24162
24243
  if (isOpen) {
24163
24244
  updatePosition();
24164
- } else {
24165
- setPopoverWidth(0);
24166
24245
  }
24167
24246
  }, [isOpen]);
24247
+ useEffect(() => {
24248
+ if (!mounted) setPopoverWidth(0);
24249
+ }, [mounted]);
24168
24250
  useLayoutEffect(() => {
24169
24251
  if (isOpen && popoverRef.current) {
24170
24252
  const measured = popoverRef.current.offsetWidth;
@@ -24198,9 +24280,9 @@ var init_Popover = __esm({
24198
24280
  onMouseLeave: handleClose,
24199
24281
  onPointerDown: tapTriggerProps.onPointerDown
24200
24282
  };
24201
- const childElement = React81__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
24283
+ const childElement = React82__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
24202
24284
  const childPointerDown = childElement.props.onPointerDown;
24203
- const triggerElement = React81__default.cloneElement(
24285
+ const triggerElement = React82__default.cloneElement(
24204
24286
  childElement,
24205
24287
  {
24206
24288
  ref: triggerRef,
@@ -24213,13 +24295,14 @@ var init_Popover = __esm({
24213
24295
  } : void 0
24214
24296
  }
24215
24297
  );
24216
- const panel = isOpen && triggerRect ? /* @__PURE__ */ jsxs(
24298
+ const panel = mounted && triggerRect ? /* @__PURE__ */ jsxs(
24217
24299
  "div",
24218
24300
  {
24219
24301
  ref: popoverRef,
24220
24302
  className: cn(
24221
24303
  "fixed z-50 p-4",
24222
24304
  "bg-card border-2 border-border shadow-elevation-popover",
24305
+ panelAnim,
24223
24306
  className
24224
24307
  ),
24225
24308
  style: {
@@ -24227,6 +24310,7 @@ var init_Popover = __esm({
24227
24310
  ...popoverWidth === 0 ? { visibility: "hidden" } : void 0
24228
24311
  },
24229
24312
  role: "dialog",
24313
+ onAnimationEnd,
24230
24314
  onMouseEnter: trigger === "hover" ? handleOpen : void 0,
24231
24315
  onMouseLeave: trigger === "hover" ? handleClose : void 0,
24232
24316
  children: [
@@ -24640,6 +24724,7 @@ var init_SidePanel = __esm({
24640
24724
  init_Box();
24641
24725
  init_Button();
24642
24726
  init_Typography();
24727
+ init_Presence();
24643
24728
  init_cn();
24644
24729
  init_useEventBus();
24645
24730
  SidePanel = ({
@@ -24659,15 +24744,17 @@ var init_SidePanel = __esm({
24659
24744
  if (closeEvent) eventBus.emit(`UI:${closeEvent}`, {});
24660
24745
  onClose();
24661
24746
  };
24662
- if (!isOpen) return null;
24747
+ const { mounted, className: panelAnim, onAnimationEnd } = usePresence(isOpen, { animation: "drawer" });
24748
+ const drawerSign = position === "right" ? 1 : -1;
24749
+ if (!mounted) return null;
24663
24750
  return /* @__PURE__ */ jsxs(Fragment, { children: [
24664
- showOverlay && /* @__PURE__ */ jsx(
24751
+ showOverlay && /* @__PURE__ */ jsx(Presence, { show: isOpen, animation: "overlay", children: /* @__PURE__ */ jsx(
24665
24752
  Box,
24666
24753
  {
24667
24754
  className: "fixed inset-0 bg-white/80 backdrop-blur-sm z-40 lg:hidden",
24668
24755
  onClick: handleClose
24669
24756
  }
24670
- ),
24757
+ ) }),
24671
24758
  /* @__PURE__ */ jsxs(
24672
24759
  Aside,
24673
24760
  {
@@ -24677,11 +24764,13 @@ var init_SidePanel = __esm({
24677
24764
  "border-l-2 border-border",
24678
24765
  position === "left" && "border-l-0 border-r-2",
24679
24766
  "flex flex-col",
24680
- "transition-transform duration-normal ease-standard",
24767
+ panelAnim,
24681
24768
  width,
24682
24769
  position === "right" ? "right-0" : "left-0",
24683
24770
  className
24684
24771
  ),
24772
+ style: { "--motion-drawer-sign": drawerSign },
24773
+ onAnimationEnd,
24685
24774
  children: [
24686
24775
  /* @__PURE__ */ jsxs(Box, { className: "flex items-center justify-between p-4 border-b-2 border-border sticky top-0 bg-card z-10", children: [
24687
24776
  /* @__PURE__ */ jsx(Typography, { variant: "h6", children: title }),
@@ -24802,9 +24891,9 @@ var init_Tooltip = __esm({
24802
24891
  if (hideTimeoutRef.current) clearTimeout(hideTimeoutRef.current);
24803
24892
  };
24804
24893
  }, []);
24805
- const triggerElement = React81__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
24894
+ const triggerElement = React82__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
24806
24895
  const childPointerDown = triggerElement.props.onPointerDown;
24807
- const trigger = React81__default.cloneElement(triggerElement, {
24896
+ const trigger = React82__default.cloneElement(triggerElement, {
24808
24897
  ref: triggerRef,
24809
24898
  onMouseEnter: handleMouseEnter,
24810
24899
  onMouseLeave: handleMouseLeave,
@@ -24894,7 +24983,7 @@ var init_WizardProgress = __esm({
24894
24983
  children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2", children: normalizedSteps.map((step, index) => {
24895
24984
  const isActive = index === currentStep;
24896
24985
  const isCompleted = index < currentStep;
24897
- return /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
24986
+ return /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
24898
24987
  /* @__PURE__ */ jsx(
24899
24988
  "button",
24900
24989
  {
@@ -25445,7 +25534,7 @@ var init_FormSectionHeader = __esm({
25445
25534
  name: "chevron-down",
25446
25535
  size: "sm",
25447
25536
  className: cn(
25448
- "text-muted-foreground transition-transform duration-200 shrink-0",
25537
+ "text-muted-foreground transition-transform duration-fast shrink-0",
25449
25538
  isCollapsed && "-rotate-90"
25450
25539
  )
25451
25540
  }
@@ -26455,13 +26544,13 @@ var init_MapView = __esm({
26455
26544
  shadowSize: [41, 41]
26456
26545
  });
26457
26546
  L.Marker.prototype.options.icon = defaultIcon;
26458
- const { useEffect: useEffect58, useRef: useRef58, useCallback: useCallback86, useState: useState87 } = React81__default;
26547
+ const { useEffect: useEffect59, useRef: useRef59, useCallback: useCallback87, useState: useState89 } = React82__default;
26459
26548
  const { Typography: Typography2 } = await Promise.resolve().then(() => (init_Typography(), Typography_exports));
26460
26549
  const { useEventBus: useEventBus2 } = await Promise.resolve().then(() => (init_useEventBus(), useEventBus_exports));
26461
26550
  function MapUpdater({ centerLat, centerLng, zoom }) {
26462
26551
  const map = useMap();
26463
- const prevRef = useRef58({ centerLat, centerLng, zoom });
26464
- useEffect58(() => {
26552
+ const prevRef = useRef59({ centerLat, centerLng, zoom });
26553
+ useEffect59(() => {
26465
26554
  const prev = prevRef.current;
26466
26555
  if (prev.centerLat !== centerLat || prev.centerLng !== centerLng || prev.zoom !== zoom) {
26467
26556
  map.setView([centerLat, centerLng], zoom);
@@ -26472,7 +26561,7 @@ var init_MapView = __esm({
26472
26561
  }
26473
26562
  function MapClickHandler({ onMapClick }) {
26474
26563
  const map = useMap();
26475
- useEffect58(() => {
26564
+ useEffect59(() => {
26476
26565
  if (!onMapClick) return;
26477
26566
  const handler = (e) => {
26478
26567
  onMapClick(e.latlng.lat, e.latlng.lng);
@@ -26500,8 +26589,8 @@ var init_MapView = __esm({
26500
26589
  showAttribution = true
26501
26590
  }) {
26502
26591
  const eventBus = useEventBus2();
26503
- const [clickedPosition, setClickedPosition] = useState87(null);
26504
- const handleMapClick = useCallback86((lat, lng) => {
26592
+ const [clickedPosition, setClickedPosition] = useState89(null);
26593
+ const handleMapClick = useCallback87((lat, lng) => {
26505
26594
  if (showClickedPin) {
26506
26595
  setClickedPosition({ lat, lng });
26507
26596
  }
@@ -26510,7 +26599,7 @@ var init_MapView = __esm({
26510
26599
  eventBus.emit(`UI:${mapClickEvent}`, { latitude: lat, longitude: lng });
26511
26600
  }
26512
26601
  }, [onMapClick, mapClickEvent, eventBus, showClickedPin]);
26513
- const handleMarkerClick = useCallback86((marker) => {
26602
+ const handleMarkerClick = useCallback87((marker) => {
26514
26603
  onMarkerClick?.(marker);
26515
26604
  if (markerClickEvent) {
26516
26605
  eventBus.emit(`UI:${markerClickEvent}`, { ...marker });
@@ -26710,7 +26799,7 @@ var init_NumberStepper = __esm({
26710
26799
  "text-foreground",
26711
26800
  "hover:bg-muted",
26712
26801
  "active:bg-muted",
26713
- "transition-colors duration-100",
26802
+ "transition-colors duration-instant",
26714
26803
  "disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:bg-transparent",
26715
26804
  "focus:outline-none focus:ring-[length:var(--focus-ring-width)] focus:ring-ring focus:ring-inset",
26716
26805
  styles.button
@@ -26751,7 +26840,7 @@ var init_NumberStepper = __esm({
26751
26840
  "text-foreground",
26752
26841
  "hover:bg-muted",
26753
26842
  "active:bg-muted",
26754
- "transition-colors duration-100",
26843
+ "transition-colors duration-instant",
26755
26844
  "disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:bg-transparent",
26756
26845
  "focus:outline-none focus:ring-[length:var(--focus-ring-width)] focus:ring-ring focus:ring-inset",
26757
26846
  styles.button
@@ -26875,7 +26964,7 @@ var init_StarRating = __esm({
26875
26964
  className: cn(
26876
26965
  styles.star,
26877
26966
  "text-foreground/30",
26878
- "transition-colors duration-100"
26967
+ "transition-colors duration-instant"
26879
26968
  ),
26880
26969
  strokeWidth: 1.5
26881
26970
  }
@@ -26888,7 +26977,7 @@ var init_StarRating = __esm({
26888
26977
  styles.star,
26889
26978
  "absolute inset-0",
26890
26979
  "text-warning fill-warning",
26891
- "transition-colors duration-100"
26980
+ "transition-colors duration-instant"
26892
26981
  ),
26893
26982
  strokeWidth: 1.5,
26894
26983
  style: isHalf ? { clipPath: "inset(0 50% 0 0)" } : void 0
@@ -27043,7 +27132,7 @@ var init_UploadDropZone = __esm({
27043
27132
  "relative flex flex-col items-center justify-center",
27044
27133
  "p-8 rounded-sm",
27045
27134
  "border-2 border-dashed",
27046
- "transition-colors duration-150",
27135
+ "transition-colors duration-fast",
27047
27136
  "cursor-pointer",
27048
27137
  isDragOver ? "border-primary bg-primary bg-opacity-5" : "border-border bg-surface",
27049
27138
  error && "border-error",
@@ -27370,8 +27459,8 @@ function TableView({
27370
27459
  }) {
27371
27460
  const eventBus = useEventBus();
27372
27461
  const { t } = useTranslate();
27373
- const [visibleCount, setVisibleCount] = React81__default.useState(pageSize > 0 ? pageSize : Infinity);
27374
- const [localSelected, setLocalSelected] = React81__default.useState(/* @__PURE__ */ new Set());
27462
+ const [visibleCount, setVisibleCount] = React82__default.useState(pageSize > 0 ? pageSize : Infinity);
27463
+ const [localSelected, setLocalSelected] = React82__default.useState(/* @__PURE__ */ new Set());
27375
27464
  const colDefs = columns ?? fields ?? [];
27376
27465
  const allDataRaw = Array.isArray(entity) ? entity : entity ? [entity] : [];
27377
27466
  const dnd = useDataDnd({
@@ -27451,7 +27540,7 @@ function TableView({
27451
27540
  className: cn(
27452
27541
  "grid items-center gap-3 sticky top-0 z-10",
27453
27542
  "bg-[var(--color-surface-subtle)] border-b border-[var(--color-border)]",
27454
- "text-[var(--color-text-muted)] uppercase text-xs font-semibold tracking-wide",
27543
+ "text-muted-foreground uppercase text-xs font-semibold tracking-wide",
27455
27544
  lk.headPad
27456
27545
  ),
27457
27546
  children: [
@@ -27566,12 +27655,12 @@ function TableView({
27566
27655
  ]
27567
27656
  }
27568
27657
  );
27569
- return dnd.isZone ? /* @__PURE__ */ jsx(dnd.SortableItem, { id: row[idField] ?? id, children: rowInner }, id) : /* @__PURE__ */ jsx(React81__default.Fragment, { children: rowInner }, id);
27658
+ return dnd.isZone ? /* @__PURE__ */ jsx(dnd.SortableItem, { id: row[idField] ?? id, children: rowInner }, id) : /* @__PURE__ */ jsx(React82__default.Fragment, { children: rowInner }, id);
27570
27659
  };
27571
27660
  const items = Array.from(data);
27572
27661
  const groups = groupBy ? groupData2(items, groupBy) : [{ label: "", items }];
27573
27662
  let runningIndex = 0;
27574
- const body = /* @__PURE__ */ jsx(Box, { role: "rowgroup", children: groups.map((group, gi) => /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
27663
+ const body = /* @__PURE__ */ jsx(Box, { role: "rowgroup", children: groups.map((group, gi) => /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
27575
27664
  group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: gi > 0 ? "mt-3" : "mt-0" }),
27576
27665
  group.items.map((row) => renderRow(row, runningIndex++))
27577
27666
  ] }, gi)) });
@@ -28234,7 +28323,7 @@ function SortableListInner({
28234
28323
  "flex items-center justify-center",
28235
28324
  "text-muted-foreground",
28236
28325
  "hover:text-foreground",
28237
- "transition-colors duration-100",
28326
+ "transition-colors duration-instant",
28238
28327
  "px-1"
28239
28328
  ),
28240
28329
  "aria-grabbed": ariaGrabbed,
@@ -28261,7 +28350,7 @@ function SortableListInner({
28261
28350
  gap: "sm",
28262
28351
  align: "center",
28263
28352
  className: cn(
28264
- "transition-opacity duration-150",
28353
+ "transition-opacity duration-fast",
28265
28354
  isBeingDragged && "opacity-50"
28266
28355
  ),
28267
28356
  children: [
@@ -28368,7 +28457,7 @@ var init_PullToRefresh = __esm({
28368
28457
  children: /* @__PURE__ */ jsx(
28369
28458
  Box,
28370
28459
  {
28371
- className: "transition-transform duration-150",
28460
+ className: "transition-transform duration-fast",
28372
28461
  style: {
28373
28462
  transform: `scale(${isRefreshing ? 1 : pullProgress})`,
28374
28463
  opacity: isRefreshing ? 1 : pullProgress
@@ -28790,7 +28879,7 @@ var init_StepFlow = __esm({
28790
28879
  className
28791
28880
  }) => {
28792
28881
  if (orientation === "vertical") {
28793
- return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(React81__default.Fragment, { children: /* @__PURE__ */ jsxs(HStack, { gap: "md", align: "start", className: "w-full", children: [
28882
+ return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(React82__default.Fragment, { children: /* @__PURE__ */ jsxs(HStack, { gap: "md", align: "start", className: "w-full", children: [
28794
28883
  /* @__PURE__ */ jsxs(VStack, { gap: "none", align: "center", children: [
28795
28884
  /* @__PURE__ */ jsx(StepCircle, { step, index }),
28796
28885
  showConnectors && index < steps.length - 1 && /* @__PURE__ */ jsx(Box, { className: "w-px h-8 bg-border" })
@@ -28801,7 +28890,7 @@ var init_StepFlow = __esm({
28801
28890
  ] })
28802
28891
  ] }) }, index)) });
28803
28892
  }
28804
- 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(React81__default.Fragment, { children: [
28893
+ 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(React82__default.Fragment, { children: [
28805
28894
  /* @__PURE__ */ jsxs(VStack, { gap: "sm", align: "center", className: "flex-1 w-full md:w-auto", children: [
28806
28895
  /* @__PURE__ */ jsx(StepCircle, { step, index }),
28807
28896
  /* @__PURE__ */ jsx(Typography, { variant: "h4", className: "text-center", children: step.title }),
@@ -29707,7 +29796,7 @@ var init_VoteStack = __esm({
29707
29796
  isUp ? "text-primary" : "text-muted-foreground",
29708
29797
  "hover:bg-muted",
29709
29798
  "active:bg-muted",
29710
- "transition-colors duration-100",
29799
+ "transition-colors duration-instant",
29711
29800
  "disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:bg-transparent",
29712
29801
  "focus:outline-none focus:ring-[length:var(--focus-ring-width)] focus:ring-ring focus:ring-inset",
29713
29802
  styles.button
@@ -29744,7 +29833,7 @@ var init_VoteStack = __esm({
29744
29833
  isDown ? "text-primary" : "text-muted-foreground",
29745
29834
  "hover:bg-muted",
29746
29835
  "active:bg-muted",
29747
- "transition-colors duration-100",
29836
+ "transition-colors duration-instant",
29748
29837
  "disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:bg-transparent",
29749
29838
  "focus:outline-none focus:ring-[length:var(--focus-ring-width)] focus:ring-ring focus:ring-inset",
29750
29839
  styles.button
@@ -29791,7 +29880,7 @@ var init_LikertScale = __esm({
29791
29880
  md: "text-base",
29792
29881
  lg: "text-lg"
29793
29882
  };
29794
- LikertScale = React81__default.forwardRef(
29883
+ LikertScale = React82__default.forwardRef(
29795
29884
  ({
29796
29885
  question,
29797
29886
  options = DEFAULT_LIKERT_OPTIONS,
@@ -29803,7 +29892,7 @@ var init_LikertScale = __esm({
29803
29892
  variant = "radios",
29804
29893
  className
29805
29894
  }, ref) => {
29806
- const groupId = React81__default.useId();
29895
+ const groupId = React82__default.useId();
29807
29896
  const eventBus = useEventBus();
29808
29897
  const handleSelect = useCallback(
29809
29898
  (next) => {
@@ -29856,7 +29945,7 @@ var init_LikertScale = __esm({
29856
29945
  disabled,
29857
29946
  onClick: () => handleSelect(opt.value),
29858
29947
  className: cn(
29859
- "flex-1 text-center font-medium transition-colors duration-100",
29948
+ "flex-1 text-center font-medium transition-colors duration-instant",
29860
29949
  "focus:outline-none focus:ring-[length:var(--focus-ring-width)] focus:ring-ring focus:ring-inset",
29861
29950
  "disabled:cursor-not-allowed",
29862
29951
  "rounded-none gap-0 shadow-none border-none",
@@ -32085,7 +32174,7 @@ var init_DocBreadcrumb = __esm({
32085
32174
  "aria-label": t("aria.breadcrumb"),
32086
32175
  children: /* @__PURE__ */ jsx(HStack, { gap: "xs", align: "center", wrap: true, children: items.map((item, idx) => {
32087
32176
  const isLast = idx === items.length - 1;
32088
- return /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
32177
+ return /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
32089
32178
  idx > 0 && /* @__PURE__ */ jsx(
32090
32179
  Icon,
32091
32180
  {
@@ -32954,7 +33043,7 @@ var init_MiniStateMachine = __esm({
32954
33043
  const x = 2 + i * (NODE_W + GAP + ARROW_W + GAP);
32955
33044
  const tc = transitionCounts[s.name] ?? 0;
32956
33045
  const role = getStateRole(s.name, s.isInitial ?? void 0, s.isTerminal ?? void 0, tc, maxTC);
32957
- return /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
33046
+ return /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
32958
33047
  /* @__PURE__ */ jsx(
32959
33048
  AvlState,
32960
33049
  {
@@ -33158,7 +33247,7 @@ var init_PageHeader = __esm({
33158
33247
  info: "bg-info/10 text-info"
33159
33248
  };
33160
33249
  return /* @__PURE__ */ jsxs(Box, { className: cn("mb-6", className), children: [
33161
- 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(React81__default.Fragment, { children: [
33250
+ 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(React82__default.Fragment, { children: [
33162
33251
  idx > 0 && /* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: "/" }),
33163
33252
  crumb.href ? /* @__PURE__ */ jsx(
33164
33253
  "a",
@@ -33516,7 +33605,7 @@ var init_Section = __esm({
33516
33605
  as: Component = "section"
33517
33606
  }) => {
33518
33607
  const hasHeader = title || description || action;
33519
- return React81__default.createElement(
33608
+ return React82__default.createElement(
33520
33609
  Component,
33521
33610
  {
33522
33611
  className: cn(
@@ -33583,7 +33672,7 @@ var init_Sidebar = __esm({
33583
33672
  variant: "ghost",
33584
33673
  onClick: item.onClick,
33585
33674
  className: cn(
33586
- "w-full flex items-center gap-3 px-3 py-2.5 transition-all duration-[var(--transition-fast)] group relative",
33675
+ "w-full flex items-center gap-3 px-3 py-2.5 transition-all duration-fast group relative",
33587
33676
  "rounded-sm border-[length:var(--border-width-thin)] border-transparent",
33588
33677
  isActive ? [
33589
33678
  "bg-primary text-primary-foreground",
@@ -33657,7 +33746,7 @@ var init_Sidebar = __esm({
33657
33746
  className: cn(
33658
33747
  "flex flex-col h-full",
33659
33748
  "bg-card border-e border-border",
33660
- "transition-all duration-300 ease-in-out",
33749
+ "transition-all duration-normal ease-standard",
33661
33750
  collapsed ? "w-20" : "w-64",
33662
33751
  className
33663
33752
  ),
@@ -33890,7 +33979,7 @@ var init_WizardContainer = __esm({
33890
33979
  const isCompleted = index < currentStep;
33891
33980
  const stepKey = step.id ?? step.tabId ?? `step-${index}`;
33892
33981
  const stepTitle = step.title ?? step.name ?? `Step ${index + 1}`;
33893
- return /* @__PURE__ */ jsxs(React81__default.Fragment, { children: [
33982
+ return /* @__PURE__ */ jsxs(React82__default.Fragment, { children: [
33894
33983
  /* @__PURE__ */ jsx(
33895
33984
  Button,
33896
33985
  {
@@ -36493,7 +36582,7 @@ var init_DetailPanel = __esm({
36493
36582
  }
36494
36583
  });
36495
36584
  function extractTitle(children) {
36496
- if (!React81__default.isValidElement(children)) return void 0;
36585
+ if (!React82__default.isValidElement(children)) return void 0;
36497
36586
  const props = children.props;
36498
36587
  if (typeof props.title === "string") {
36499
36588
  return props.title;
@@ -36843,12 +36932,12 @@ var init_Form = __esm({
36843
36932
  const isSchemaEntity = isOrbitalEntitySchema(entity);
36844
36933
  const resolvedEntity = isSchemaEntity ? entity : void 0;
36845
36934
  const entityName = typeof entity === "string" ? entity : resolvedEntity?.name;
36846
- const normalizedInitialData = React81__default.useMemo(() => {
36935
+ const normalizedInitialData = React82__default.useMemo(() => {
36847
36936
  const entityRowAsInitial = isPlainEntityRow(entity) ? entity : void 0;
36848
36937
  const callerInitial = initialData !== null && typeof initialData === "object" && !Array.isArray(initialData) ? initialData : {};
36849
36938
  return entityRowAsInitial !== void 0 ? { ...entityRowAsInitial, ...callerInitial } : callerInitial;
36850
36939
  }, [entity, initialData]);
36851
- const entityDerivedFields = React81__default.useMemo(() => {
36940
+ const entityDerivedFields = React82__default.useMemo(() => {
36852
36941
  if (fields && fields.length > 0) return void 0;
36853
36942
  if (!resolvedEntity) return void 0;
36854
36943
  return resolvedEntity.fields.map(
@@ -36869,16 +36958,16 @@ var init_Form = __esm({
36869
36958
  const conditionalFields = typeof conditionalFieldsRaw === "boolean" ? {} : conditionalFieldsRaw;
36870
36959
  const hiddenCalculations = typeof hiddenCalculationsRaw === "boolean" ? [] : hiddenCalculationsRaw;
36871
36960
  const violationTriggers = typeof violationTriggersRaw === "boolean" ? [] : violationTriggersRaw;
36872
- const [formData, setFormData] = React81__default.useState(
36961
+ const [formData, setFormData] = React82__default.useState(
36873
36962
  normalizedInitialData
36874
36963
  );
36875
- const [collapsedSections, setCollapsedSections] = React81__default.useState(
36964
+ const [collapsedSections, setCollapsedSections] = React82__default.useState(
36876
36965
  /* @__PURE__ */ new Set()
36877
36966
  );
36878
- const [submitError, setSubmitError] = React81__default.useState(null);
36879
- const formRef = React81__default.useRef(null);
36967
+ const [submitError, setSubmitError] = React82__default.useState(null);
36968
+ const formRef = React82__default.useRef(null);
36880
36969
  const formMode = props.mode;
36881
- const mountedRef = React81__default.useRef(false);
36970
+ const mountedRef = React82__default.useRef(false);
36882
36971
  if (!mountedRef.current) {
36883
36972
  mountedRef.current = true;
36884
36973
  debug("forms", "mount", {
@@ -36891,7 +36980,7 @@ var init_Form = __esm({
36891
36980
  });
36892
36981
  }
36893
36982
  const shouldShowCancel = showCancel ?? (fields && fields.length > 0);
36894
- const evalContext = React81__default.useMemo(
36983
+ const evalContext = React82__default.useMemo(
36895
36984
  () => ({
36896
36985
  formValues: formData,
36897
36986
  globalVariables: externalContext?.globalVariables ?? {},
@@ -36900,7 +36989,7 @@ var init_Form = __esm({
36900
36989
  }),
36901
36990
  [formData, externalContext]
36902
36991
  );
36903
- React81__default.useEffect(() => {
36992
+ React82__default.useEffect(() => {
36904
36993
  debug("forms", "initialData-sync", {
36905
36994
  mode: formMode,
36906
36995
  normalizedInitialData,
@@ -36911,7 +37000,7 @@ var init_Form = __esm({
36911
37000
  setFormData(normalizedInitialData);
36912
37001
  }
36913
37002
  }, [normalizedInitialData]);
36914
- const processCalculations = React81__default.useCallback(
37003
+ const processCalculations = React82__default.useCallback(
36915
37004
  (changedFieldId, newFormData) => {
36916
37005
  if (!hiddenCalculations.length) return;
36917
37006
  const context = {
@@ -36936,7 +37025,7 @@ var init_Form = __esm({
36936
37025
  },
36937
37026
  [hiddenCalculations, externalContext, eventBus]
36938
37027
  );
36939
- const checkViolations = React81__default.useCallback(
37028
+ const checkViolations = React82__default.useCallback(
36940
37029
  (changedFieldId, newFormData) => {
36941
37030
  if (!violationTriggers.length) return;
36942
37031
  const context = {
@@ -36974,7 +37063,7 @@ var init_Form = __esm({
36974
37063
  processCalculations(name, newFormData);
36975
37064
  checkViolations(name, newFormData);
36976
37065
  };
36977
- const isFieldVisible = React81__default.useCallback(
37066
+ const isFieldVisible = React82__default.useCallback(
36978
37067
  (fieldName) => {
36979
37068
  const condition = conditionalFields[fieldName];
36980
37069
  if (!condition) return true;
@@ -36982,7 +37071,7 @@ var init_Form = __esm({
36982
37071
  },
36983
37072
  [conditionalFields, evalContext]
36984
37073
  );
36985
- const isSectionVisible = React81__default.useCallback(
37074
+ const isSectionVisible = React82__default.useCallback(
36986
37075
  (section) => {
36987
37076
  if (!section.condition) return true;
36988
37077
  return Boolean(evaluateFormExpression(section.condition, evalContext));
@@ -37058,7 +37147,7 @@ var init_Form = __esm({
37058
37147
  eventBus.emit(`UI:${onCancel}`);
37059
37148
  }
37060
37149
  };
37061
- const renderField = React81__default.useCallback(
37150
+ const renderField = React82__default.useCallback(
37062
37151
  (field) => {
37063
37152
  const fieldName = field.name || field.field;
37064
37153
  if (!fieldName) return null;
@@ -37079,7 +37168,7 @@ var init_Form = __esm({
37079
37168
  [formData, isFieldVisible, relationsData, relationsLoading, isLoading]
37080
37169
  );
37081
37170
  const effectiveFields = entityDerivedFields ?? fields;
37082
- const normalizedFields = React81__default.useMemo(() => {
37171
+ const normalizedFields = React82__default.useMemo(() => {
37083
37172
  if (!effectiveFields || effectiveFields.length === 0) return [];
37084
37173
  return effectiveFields.map((field) => {
37085
37174
  if (typeof field === "string") {
@@ -37103,7 +37192,7 @@ var init_Form = __esm({
37103
37192
  return field;
37104
37193
  });
37105
37194
  }, [effectiveFields, resolvedEntity]);
37106
- const schemaFields = React81__default.useMemo(() => {
37195
+ const schemaFields = React82__default.useMemo(() => {
37107
37196
  if (normalizedFields.length === 0) return null;
37108
37197
  if (isDebugEnabled()) {
37109
37198
  debugGroup(`Form: ${entityName || "unknown"}`);
@@ -37113,7 +37202,7 @@ var init_Form = __esm({
37113
37202
  }
37114
37203
  return normalizedFields.map(renderField).filter(Boolean);
37115
37204
  }, [normalizedFields, renderField, entityName, conditionalFields]);
37116
- const sectionElements = React81__default.useMemo(() => {
37205
+ const sectionElements = React82__default.useMemo(() => {
37117
37206
  if (!sections || sections.length === 0) return null;
37118
37207
  return sections.map((section) => {
37119
37208
  if (!isSectionVisible(section)) {
@@ -37796,7 +37885,7 @@ var init_List = __esm({
37796
37885
  Box,
37797
37886
  {
37798
37887
  className: cn(
37799
- "h-full rounded-full transition-all duration-500",
37888
+ "h-full rounded-full transition-all duration-slow",
37800
37889
  clampedValue >= 100 ? "bg-success" : clampedValue >= 70 ? "bg-info" : clampedValue >= 40 ? "bg-warning" : "bg-muted-foreground"
37801
37890
  ),
37802
37891
  style: { width: `${clampedValue}%` }
@@ -37838,7 +37927,7 @@ var init_List = __esm({
37838
37927
  if (entity && typeof entity === "object" && "id" in entity) return [entity];
37839
37928
  return [];
37840
37929
  }, [entity]);
37841
- const getItemActions = React81__default.useCallback(
37930
+ const getItemActions = React82__default.useCallback(
37842
37931
  (item) => {
37843
37932
  if (!itemActions) return [];
37844
37933
  if (typeof itemActions === "function") {
@@ -37965,7 +38054,7 @@ var init_List = __esm({
37965
38054
  {
37966
38055
  className: cn(
37967
38056
  "group flex items-center gap-5 px-6 py-5",
37968
- "transition-all duration-300 ease-out",
38057
+ "transition-all duration-normal ease-standard",
37969
38058
  hasExplicitClick && "cursor-pointer",
37970
38059
  // Hover state
37971
38060
  "hover:bg-muted/80",
@@ -38072,7 +38161,7 @@ var init_List = __esm({
38072
38161
  variant: "ghost",
38073
38162
  action: editAction.event,
38074
38163
  className: cn(
38075
- "p-2 rounded-lg transition-all duration-200",
38164
+ "p-2 rounded-lg transition-all duration-fast",
38076
38165
  "hover:bg-primary/10 hover:text-primary",
38077
38166
  "text-muted-foreground",
38078
38167
  "active:scale-95"
@@ -38088,7 +38177,7 @@ var init_List = __esm({
38088
38177
  variant: "ghost",
38089
38178
  action: viewAction.event,
38090
38179
  className: cn(
38091
- "p-2 rounded-lg transition-all duration-200",
38180
+ "p-2 rounded-lg transition-all duration-fast",
38092
38181
  "hover:bg-muted hover:text-foreground",
38093
38182
  "text-muted-foreground",
38094
38183
  "active:scale-95"
@@ -38110,7 +38199,7 @@ var init_List = __esm({
38110
38199
  {
38111
38200
  variant: "ghost",
38112
38201
  className: cn(
38113
- "p-2 rounded-lg transition-all duration-200",
38202
+ "p-2 rounded-lg transition-all duration-fast",
38114
38203
  "hover:bg-muted hover:shadow-sm",
38115
38204
  "text-muted-foreground hover:text-foreground",
38116
38205
  "active:scale-95"
@@ -38322,7 +38411,7 @@ var init_MediaGallery = __esm({
38322
38411
  [selectable, selectedItems, selectionEvent, eventBus]
38323
38412
  );
38324
38413
  const entityData = Array.isArray(entity) ? entity : [];
38325
- const items = React81__default.useMemo(() => {
38414
+ const items = React82__default.useMemo(() => {
38326
38415
  if (propItems && propItems.length > 0) return propItems;
38327
38416
  if (entityData.length === 0) return [];
38328
38417
  return entityData.map((record, idx) => {
@@ -38400,7 +38489,7 @@ var init_MediaGallery = __esm({
38400
38489
  {
38401
38490
  className: cn(
38402
38491
  "group relative overflow-hidden rounded-md cursor-pointer",
38403
- "border-2 transition-all duration-200",
38492
+ "border-2 transition-all duration-fast",
38404
38493
  isSelected ? "border-primary ring-2 ring-primary/30" : "border-transparent hover:border-border",
38405
38494
  ASPECT_CLASSES[aspectRatio]
38406
38495
  ),
@@ -38421,14 +38510,14 @@ var init_MediaGallery = __esm({
38421
38510
  {
38422
38511
  className: cn(
38423
38512
  "absolute inset-0 bg-foreground/0 group-hover:bg-foreground/20",
38424
- "transition-colors duration-200 flex items-center justify-center"
38513
+ "transition-colors duration-fast flex items-center justify-center"
38425
38514
  ),
38426
38515
  children: /* @__PURE__ */ jsx(
38427
38516
  Icon,
38428
38517
  {
38429
38518
  icon: ZoomIn,
38430
38519
  size: "md",
38431
- className: "text-white opacity-0 group-hover:opacity-100 transition-opacity duration-200"
38520
+ className: "text-white opacity-0 group-hover:opacity-100 transition-opacity duration-fast"
38432
38521
  }
38433
38522
  )
38434
38523
  }
@@ -38486,7 +38575,7 @@ var init_MediaGallery = __esm({
38486
38575
  }
38487
38576
  });
38488
38577
  function extractTitle2(children) {
38489
- if (!React81__default.isValidElement(children)) return void 0;
38578
+ if (!React82__default.isValidElement(children)) return void 0;
38490
38579
  const props = children.props;
38491
38580
  if (typeof props.title === "string") {
38492
38581
  return props.title;
@@ -38760,7 +38849,7 @@ var init_debugRegistry = __esm({
38760
38849
  }
38761
38850
  });
38762
38851
  function useDebugData() {
38763
- const [data, setData] = React81.useState(() => ({
38852
+ const [data, setData] = React82.useState(() => ({
38764
38853
  traits: [],
38765
38854
  ticks: [],
38766
38855
  guards: [],
@@ -38774,7 +38863,7 @@ function useDebugData() {
38774
38863
  },
38775
38864
  lastUpdate: Date.now()
38776
38865
  }));
38777
- React81.useEffect(() => {
38866
+ React82.useEffect(() => {
38778
38867
  const updateData = () => {
38779
38868
  setData({
38780
38869
  traits: getAllTraits(),
@@ -38883,12 +38972,12 @@ function layoutGraph(states, transitions, initialState, width, height) {
38883
38972
  return positions;
38884
38973
  }
38885
38974
  function WalkMinimap() {
38886
- const [walkStep, setWalkStep] = React81.useState(null);
38887
- const [traits2, setTraits] = React81.useState([]);
38888
- const [coveredEdges, setCoveredEdges] = React81.useState([]);
38889
- const [completedTraits, setCompletedTraits] = React81.useState(/* @__PURE__ */ new Set());
38890
- const prevTraitRef = React81.useRef(null);
38891
- React81.useEffect(() => {
38975
+ const [walkStep, setWalkStep] = React82.useState(null);
38976
+ const [traits2, setTraits] = React82.useState([]);
38977
+ const [coveredEdges, setCoveredEdges] = React82.useState([]);
38978
+ const [completedTraits, setCompletedTraits] = React82.useState(/* @__PURE__ */ new Set());
38979
+ const prevTraitRef = React82.useRef(null);
38980
+ React82.useEffect(() => {
38892
38981
  const interval = setInterval(() => {
38893
38982
  const w = window;
38894
38983
  const step = w.__orbitalWalkStep;
@@ -39324,15 +39413,15 @@ var init_EntitiesTab = __esm({
39324
39413
  });
39325
39414
  function EventFlowTab({ events: events2 }) {
39326
39415
  const { t } = useTranslate();
39327
- const [filter, setFilter] = React81.useState("all");
39328
- const containerRef = React81.useRef(null);
39329
- const [autoScroll, setAutoScroll] = React81.useState(true);
39330
- React81.useEffect(() => {
39416
+ const [filter, setFilter] = React82.useState("all");
39417
+ const containerRef = React82.useRef(null);
39418
+ const [autoScroll, setAutoScroll] = React82.useState(true);
39419
+ React82.useEffect(() => {
39331
39420
  if (autoScroll && containerRef.current) {
39332
39421
  containerRef.current.scrollTop = containerRef.current.scrollHeight;
39333
39422
  }
39334
39423
  }, [events2.length, autoScroll]);
39335
- const filteredEvents = React81.useMemo(() => {
39424
+ const filteredEvents = React82.useMemo(() => {
39336
39425
  if (filter === "all") return events2;
39337
39426
  return events2.filter((e) => e.type === filter);
39338
39427
  }, [events2, filter]);
@@ -39448,7 +39537,7 @@ var init_EventFlowTab = __esm({
39448
39537
  });
39449
39538
  function GuardsPanel({ guards }) {
39450
39539
  const { t } = useTranslate();
39451
- const [filter, setFilter] = React81.useState("all");
39540
+ const [filter, setFilter] = React82.useState("all");
39452
39541
  if (guards.length === 0) {
39453
39542
  return /* @__PURE__ */ jsx(
39454
39543
  EmptyState,
@@ -39461,7 +39550,7 @@ function GuardsPanel({ guards }) {
39461
39550
  }
39462
39551
  const passedCount = guards.filter((g) => g.result).length;
39463
39552
  const failedCount = guards.length - passedCount;
39464
- const filteredGuards = React81.useMemo(() => {
39553
+ const filteredGuards = React82.useMemo(() => {
39465
39554
  if (filter === "all") return guards;
39466
39555
  if (filter === "passed") return guards.filter((g) => g.result);
39467
39556
  return guards.filter((g) => !g.result);
@@ -39624,10 +39713,10 @@ function EffectBadge({ effect }) {
39624
39713
  }
39625
39714
  function TransitionTimeline({ transitions }) {
39626
39715
  const { t } = useTranslate();
39627
- const containerRef = React81.useRef(null);
39628
- const [autoScroll, setAutoScroll] = React81.useState(true);
39629
- const [expandedId, setExpandedId] = React81.useState(null);
39630
- React81.useEffect(() => {
39716
+ const containerRef = React82.useRef(null);
39717
+ const [autoScroll, setAutoScroll] = React82.useState(true);
39718
+ const [expandedId, setExpandedId] = React82.useState(null);
39719
+ React82.useEffect(() => {
39631
39720
  if (autoScroll && containerRef.current) {
39632
39721
  containerRef.current.scrollTop = containerRef.current.scrollHeight;
39633
39722
  }
@@ -39907,9 +39996,9 @@ function getAllEvents(traits2) {
39907
39996
  function EventDispatcherTab({ traits: traits2, schema }) {
39908
39997
  const eventBus = useEventBus();
39909
39998
  const { t } = useTranslate();
39910
- const [log9, setLog] = React81.useState([]);
39911
- const prevStatesRef = React81.useRef(/* @__PURE__ */ new Map());
39912
- React81.useEffect(() => {
39999
+ const [log9, setLog] = React82.useState([]);
40000
+ const prevStatesRef = React82.useRef(/* @__PURE__ */ new Map());
40001
+ React82.useEffect(() => {
39913
40002
  for (const trait of traits2) {
39914
40003
  const prev = prevStatesRef.current.get(trait.id);
39915
40004
  if (prev && prev !== trait.currentState) {
@@ -40078,10 +40167,10 @@ function VerifyModePanel({
40078
40167
  localCount
40079
40168
  }) {
40080
40169
  const { t } = useTranslate();
40081
- const [expanded, setExpanded] = React81.useState(true);
40082
- const scrollRef = React81.useRef(null);
40083
- const prevCountRef = React81.useRef(0);
40084
- React81.useEffect(() => {
40170
+ const [expanded, setExpanded] = React82.useState(true);
40171
+ const scrollRef = React82.useRef(null);
40172
+ const prevCountRef = React82.useRef(0);
40173
+ React82.useEffect(() => {
40085
40174
  if (expanded && transitions.length > prevCountRef.current && scrollRef.current) {
40086
40175
  scrollRef.current.scrollTop = scrollRef.current.scrollHeight;
40087
40176
  }
@@ -40138,10 +40227,10 @@ function RuntimeDebugger({
40138
40227
  schema
40139
40228
  }) {
40140
40229
  const { t } = useTranslate();
40141
- const [isCollapsed, setIsCollapsed] = React81.useState(mode === "verify" ? true : defaultCollapsed);
40142
- const [isVisible, setIsVisible] = React81.useState(mode === "inline" || mode === "verify" || isDebugEnabled2());
40230
+ const [isCollapsed, setIsCollapsed] = React82.useState(mode === "verify" ? true : defaultCollapsed);
40231
+ const [isVisible, setIsVisible] = React82.useState(mode === "inline" || mode === "verify" || isDebugEnabled2());
40143
40232
  const debugData = useDebugData();
40144
- React81.useEffect(() => {
40233
+ React82.useEffect(() => {
40145
40234
  if (mode === "inline") return;
40146
40235
  return onDebugToggle((enabled) => {
40147
40236
  setIsVisible(enabled);
@@ -40150,7 +40239,7 @@ function RuntimeDebugger({
40150
40239
  }
40151
40240
  });
40152
40241
  }, [mode]);
40153
- React81.useEffect(() => {
40242
+ React82.useEffect(() => {
40154
40243
  if (mode === "inline") return;
40155
40244
  const handleKeyDown = (e) => {
40156
40245
  if (e.key === "`" && isVisible) {
@@ -40670,7 +40759,7 @@ var init_StatCard = __esm({
40670
40759
  const labelToUse = propLabel ?? propTitle;
40671
40760
  const eventBus = useEventBus();
40672
40761
  const { t } = useTranslate();
40673
- const handleActionClick = React81__default.useCallback(() => {
40762
+ const handleActionClick = React82__default.useCallback(() => {
40674
40763
  if (action?.event) {
40675
40764
  eventBus.emit(`UI:${action.event}`, {});
40676
40765
  }
@@ -40681,7 +40770,7 @@ var init_StatCard = __esm({
40681
40770
  const data = Array.isArray(entity) ? entity : entity ? [entity] : [];
40682
40771
  const isLoading = externalLoading ?? false;
40683
40772
  const error = externalError;
40684
- const computeMetricValue = React81__default.useCallback(
40773
+ const computeMetricValue = React82__default.useCallback(
40685
40774
  (metric, items) => {
40686
40775
  if (metric.value !== void 0) {
40687
40776
  return metric.value;
@@ -40720,7 +40809,7 @@ var init_StatCard = __esm({
40720
40809
  },
40721
40810
  []
40722
40811
  );
40723
- const schemaStats = React81__default.useMemo(() => {
40812
+ const schemaStats = React82__default.useMemo(() => {
40724
40813
  if (!metrics || metrics.length === 0) return null;
40725
40814
  return metrics.map((metric) => ({
40726
40815
  label: metric.label,
@@ -40728,7 +40817,7 @@ var init_StatCard = __esm({
40728
40817
  format: metric.format
40729
40818
  }));
40730
40819
  }, [metrics, data, computeMetricValue]);
40731
- const calculatedTrend = React81__default.useMemo(() => {
40820
+ const calculatedTrend = React82__default.useMemo(() => {
40732
40821
  if (manualTrend !== void 0) return manualTrend;
40733
40822
  if (previousValue === void 0 || currentValue === void 0)
40734
40823
  return void 0;
@@ -41368,8 +41457,8 @@ var init_SubagentTracePanel = __esm({
41368
41457
  ] });
41369
41458
  };
41370
41459
  InlineActivityStream = ({ activities, autoScroll = true, className }) => {
41371
- const endRef = React81__default.useRef(null);
41372
- React81__default.useEffect(() => {
41460
+ const endRef = React82__default.useRef(null);
41461
+ React82__default.useEffect(() => {
41373
41462
  if (!autoScroll) return;
41374
41463
  endRef.current?.scrollIntoView({ behavior: "smooth", block: "end" });
41375
41464
  }, [activities.length, autoScroll]);
@@ -41463,7 +41552,7 @@ var init_SubagentTracePanel = __esm({
41463
41552
  };
41464
41553
  SubagentRichCard = ({ subagent }) => {
41465
41554
  const { t } = useTranslate();
41466
- const activities = React81__default.useMemo(
41555
+ const activities = React82__default.useMemo(
41467
41556
  () => subagentMessagesToActivities(subagent.messages),
41468
41557
  [subagent.messages]
41469
41558
  );
@@ -41540,8 +41629,8 @@ var init_SubagentTracePanel = __esm({
41540
41629
  ] });
41541
41630
  };
41542
41631
  CoordinatorConversation = ({ messages, autoScroll = true, className }) => {
41543
- const endRef = React81__default.useRef(null);
41544
- React81__default.useEffect(() => {
41632
+ const endRef = React82__default.useRef(null);
41633
+ React82__default.useEffect(() => {
41545
41634
  if (!autoScroll) return;
41546
41635
  endRef.current?.scrollIntoView({ behavior: "smooth", block: "end" });
41547
41636
  }, [messages.length, autoScroll]);
@@ -41976,7 +42065,7 @@ var init_Timeline = __esm({
41976
42065
  }) => {
41977
42066
  const { t } = useTranslate();
41978
42067
  const entityData = entity ?? [];
41979
- const items = React81__default.useMemo(() => {
42068
+ const items = React82__default.useMemo(() => {
41980
42069
  if (propItems) return propItems;
41981
42070
  if (entityData.length === 0) return [];
41982
42071
  return entityData.map((record, idx) => {
@@ -42078,7 +42167,7 @@ var init_Timeline = __esm({
42078
42167
  }
42079
42168
  });
42080
42169
  function extractToastProps(children) {
42081
- if (!React81__default.isValidElement(children)) {
42170
+ if (!React82__default.isValidElement(children)) {
42082
42171
  if (typeof children === "string") {
42083
42172
  return { message: children };
42084
42173
  }
@@ -42120,7 +42209,7 @@ var init_ToastSlot = __esm({
42120
42209
  eventBus.emit(`${prefix}CLOSE`);
42121
42210
  };
42122
42211
  if (!isVisible) return null;
42123
- const isCustomContent = React81__default.isValidElement(children) && !message;
42212
+ const isCustomContent = React82__default.isValidElement(children) && !message;
42124
42213
  return /* @__PURE__ */ jsx(Box, { className: "fixed bottom-4 right-4 z-50", children: isCustomContent ? children : /* @__PURE__ */ jsx(
42125
42214
  Toast,
42126
42215
  {
@@ -42168,6 +42257,7 @@ var init_component_registry_generated = __esm({
42168
42257
  init_LayoutPatterns();
42169
42258
  init_BranchingLogicBuilder();
42170
42259
  init_Breadcrumb();
42260
+ init_ButtonGroup();
42171
42261
  init_CTABanner();
42172
42262
  init_CalendarGrid();
42173
42263
  init_Canvas();
@@ -42238,8 +42328,8 @@ var init_component_registry_generated = __esm({
42238
42328
  init_FlipContainer();
42239
42329
  init_FloatingActionButton();
42240
42330
  init_Form();
42241
- init_FormSection();
42242
42331
  init_FormField();
42332
+ init_FormSection();
42243
42333
  init_FormSectionHeader();
42244
42334
  init_GameAudioToggle();
42245
42335
  init_GameHud();
@@ -42425,6 +42515,7 @@ var init_component_registry_generated = __esm({
42425
42515
  "BranchingLogicBuilder": BranchingLogicBuilder,
42426
42516
  "Breadcrumb": Breadcrumb,
42427
42517
  "Button": ButtonPattern,
42518
+ "ButtonGroup": ButtonGroup,
42428
42519
  "ButtonPattern": ButtonPattern,
42429
42520
  "CTABanner": CTABanner,
42430
42521
  "CalendarGrid": CalendarGrid,
@@ -42498,7 +42589,6 @@ var init_component_registry_generated = __esm({
42498
42589
  "FlipContainer": FlipContainer,
42499
42590
  "FloatingActionButton": FloatingActionButton,
42500
42591
  "Form": Form,
42501
- "FormActions": FormActions,
42502
42592
  "FormField": FormField,
42503
42593
  "FormLayout": FormLayout,
42504
42594
  "FormSectionHeader": FormSectionHeader,
@@ -42678,7 +42768,7 @@ function SuspenseConfigProvider({
42678
42768
  config,
42679
42769
  children
42680
42770
  }) {
42681
- return React81__default.createElement(
42771
+ return React82__default.createElement(
42682
42772
  SuspenseConfigContext.Provider,
42683
42773
  { value: config },
42684
42774
  children
@@ -42720,7 +42810,7 @@ function enrichFormFields(fields, entityDef) {
42720
42810
  }
42721
42811
  return { name: field, label: field.replace(/([a-z])([A-Z])/g, "$1 $2").replace(/\b\w/g, (c) => c.toUpperCase()) };
42722
42812
  }
42723
- if (field && typeof field === "object" && !Array.isArray(field) && !React81__default.isValidElement(field) && !(field instanceof Date)) {
42813
+ if (field && typeof field === "object" && !Array.isArray(field) && !React82__default.isValidElement(field) && !(field instanceof Date)) {
42724
42814
  const obj = field;
42725
42815
  const fieldName = typeof obj.name === "string" ? obj.name : typeof obj.field === "string" ? obj.field : void 0;
42726
42816
  if (!fieldName) return field;
@@ -43173,7 +43263,7 @@ function renderPatternChildren(children, onDismiss, parentId = "root", parentPat
43173
43263
  const key = `${parentId}-${index}-trait:${traitName}`;
43174
43264
  return /* @__PURE__ */ jsx(TraitFrame, { traitName }, key);
43175
43265
  }
43176
- return /* @__PURE__ */ jsx(React81__default.Fragment, { children: child }, `${parentId}-${index}`);
43266
+ return /* @__PURE__ */ jsx(React82__default.Fragment, { children: child }, `${parentId}-${index}`);
43177
43267
  }
43178
43268
  if (!child || typeof child !== "object") return null;
43179
43269
  const childId = `${parentId}-${index}`;
@@ -43226,14 +43316,14 @@ function isPatternConfig(value) {
43226
43316
  if (value === null || value === void 0) return false;
43227
43317
  if (typeof value !== "object") return false;
43228
43318
  if (Array.isArray(value)) return false;
43229
- if (React81__default.isValidElement(value)) return false;
43319
+ if (React82__default.isValidElement(value)) return false;
43230
43320
  if (value instanceof Date) return false;
43231
43321
  if (typeof value === "function") return false;
43232
43322
  const record = value;
43233
43323
  return "type" in record && typeof record.type === "string" && getComponentForPattern$1(record.type) !== null;
43234
43324
  }
43235
43325
  function isPlainConfigObject(value) {
43236
- if (React81__default.isValidElement(value)) return false;
43326
+ if (React82__default.isValidElement(value)) return false;
43237
43327
  if (value instanceof Date) return false;
43238
43328
  const proto = Object.getPrototypeOf(value);
43239
43329
  return proto === Object.prototype || proto === null;
@@ -43361,7 +43451,7 @@ function SlotContentRenderer({
43361
43451
  for (const slotKey of CONTENT_NODE_SLOTS) {
43362
43452
  const slotVal = restProps[slotKey];
43363
43453
  if (slotVal === void 0 || slotVal === null) continue;
43364
- if (React81__default.isValidElement(slotVal) || typeof slotVal === "string" || typeof slotVal === "number" || typeof slotVal === "boolean") continue;
43454
+ if (React82__default.isValidElement(slotVal) || typeof slotVal === "string" || typeof slotVal === "number" || typeof slotVal === "boolean") continue;
43365
43455
  if (Array.isArray(slotVal) || typeof slotVal === "object" && "type" in slotVal) {
43366
43456
  nodeSlotOverrides[slotKey] = renderPatternChildren(
43367
43457
  slotVal,
@@ -43414,7 +43504,7 @@ function SlotContentRenderer({
43414
43504
  const resolvedItems = Array.isArray(entityVal) && entityVal[0] !== "fn" ? entityVal : null;
43415
43505
  if (resolvedItems && resolvedItems.length > 0 && !finalProps.fields && !finalProps.columns) {
43416
43506
  const sample = resolvedItems[0];
43417
- if (sample && typeof sample === "object" && !Array.isArray(sample) && !React81__default.isValidElement(sample) && !(sample instanceof Date)) {
43507
+ if (sample && typeof sample === "object" && !Array.isArray(sample) && !React82__default.isValidElement(sample) && !(sample instanceof Date)) {
43418
43508
  const keys = Object.keys(sample).filter((k) => k !== "id" && k !== "_id");
43419
43509
  finalProps.fields = keys.map((k, i) => ({ name: k, variant: i === 0 ? "h4" : "body" }));
43420
43510
  }
@@ -43785,7 +43875,7 @@ function resolveLambdaBindings(body, params, item, index) {
43785
43875
  }
43786
43876
  return substituted;
43787
43877
  }
43788
- if (body !== null && typeof body === "object" && !React81__default.isValidElement(body) && !(body instanceof Date) && typeof body !== "function") {
43878
+ if (body !== null && typeof body === "object" && !React82__default.isValidElement(body) && !(body instanceof Date) && typeof body !== "function") {
43789
43879
  const out = {};
43790
43880
  for (const [k, v] of Object.entries(body)) {
43791
43881
  out[k] = recur(v);
@@ -43804,7 +43894,7 @@ function getSlotContentRenderer2() {
43804
43894
  function makeLambdaFn(params, lambdaBody, callerKey) {
43805
43895
  return (item, index) => {
43806
43896
  const resolvedBody = resolveLambdaBindings(lambdaBody, params, item, index);
43807
- if (resolvedBody === null || typeof resolvedBody !== "object" || Array.isArray(resolvedBody) || typeof resolvedBody === "function" || React81__default.isValidElement(resolvedBody) || resolvedBody instanceof Date) {
43897
+ if (resolvedBody === null || typeof resolvedBody !== "object" || Array.isArray(resolvedBody) || typeof resolvedBody === "function" || React82__default.isValidElement(resolvedBody) || resolvedBody instanceof Date) {
43808
43898
  return null;
43809
43899
  }
43810
43900
  const record = resolvedBody;
@@ -43823,7 +43913,7 @@ function makeLambdaFn(params, lambdaBody, callerKey) {
43823
43913
  props: childProps,
43824
43914
  priority: 0
43825
43915
  };
43826
- return React81__default.createElement(SlotContentRenderer2, { content: childContent });
43916
+ return React82__default.createElement(SlotContentRenderer2, { content: childContent });
43827
43917
  };
43828
43918
  }
43829
43919
  function convertNode(node, callerKey) {
@@ -43842,7 +43932,7 @@ function convertNode(node, callerKey) {
43842
43932
  });
43843
43933
  return anyChanged ? mapped : node;
43844
43934
  }
43845
- if (typeof node === "object" && !React81__default.isValidElement(node) && !(node instanceof Date)) {
43935
+ if (typeof node === "object" && !React82__default.isValidElement(node) && !(node instanceof Date)) {
43846
43936
  return convertObjectProps(node);
43847
43937
  }
43848
43938
  return node;