@almadar/ui 6.4.0 → 6.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
2
- import * as React78 from 'react';
3
- import React78__default, { createContext, useContext, useMemo, useRef, useEffect, useCallback, useState, useLayoutEffect, useId, Suspense, lazy, useSyncExternalStore } from 'react';
2
+ import * as React79 from 'react';
3
+ import React79__default, { createContext, useContext, useMemo, useRef, useEffect, useCallback, useState, useLayoutEffect, useId, Suspense, lazy, useSyncExternalStore } from 'react';
4
4
  import { clsx } from 'clsx';
5
5
  import { twMerge } from 'tailwind-merge';
6
6
  import { EventBusContext, useTraitScopeChain, useCurrentPagePath, useGameAudioContextOptional, useRenderSlot, useNavStack, useEntitySchemaOptional, RenderSlotProvider, useEntityBindingSnapshot, useTraitScope, TraitScopeProvider } from '@almadar/ui/providers';
@@ -262,7 +262,7 @@ var init_SvgFlow = __esm({
262
262
  width = 100,
263
263
  height = 100
264
264
  }) => {
265
- const markerId = React78__default.useMemo(() => {
265
+ const markerId = React79__default.useMemo(() => {
266
266
  flowIdCounter += 1;
267
267
  return `almadar-flow-arrow-${flowIdCounter}`;
268
268
  }, []);
@@ -855,7 +855,7 @@ var init_SvgRing = __esm({
855
855
  width = 100,
856
856
  height = 100
857
857
  }) => {
858
- const gradientId = React78__default.useMemo(() => {
858
+ const gradientId = React79__default.useMemo(() => {
859
859
  ringIdCounter += 1;
860
860
  return `almadar-ring-glow-${ringIdCounter}`;
861
861
  }, []);
@@ -1397,7 +1397,7 @@ var init_Icon = __esm({
1397
1397
  const effectiveName = typeof icon === "string" && icon !== "" ? icon : name;
1398
1398
  const effectiveStrokeWidth = strokeWidth != null && strokeWidth > 0 ? strokeWidth : void 0;
1399
1399
  const family = useIconFamily();
1400
- const RenderedComponent = React78__default.useMemo(() => {
1400
+ const RenderedComponent = React79__default.useMemo(() => {
1401
1401
  if (directIcon) return null;
1402
1402
  return effectiveName ? resolveIconForFamily(effectiveName) : null;
1403
1403
  }, [directIcon, effectiveName, family]);
@@ -1526,7 +1526,7 @@ var init_atlasSlice = __esm({
1526
1526
  }
1527
1527
  });
1528
1528
  function useAtlasSliceDataUrl(asset) {
1529
- const [, bump] = React78.useReducer((x) => x + 1, 0);
1529
+ const [, bump] = React79.useReducer((x) => x + 1, 0);
1530
1530
  if (!isAtlasAsset(asset)) return void 0;
1531
1531
  const key = `${asset.atlas}#${asset.sprite}`;
1532
1532
  const cached = sliceDataUrlCache.get(key);
@@ -1589,13 +1589,13 @@ function AtlasImage({
1589
1589
  style,
1590
1590
  "aria-hidden": ariaHidden
1591
1591
  }) {
1592
- const [, bump] = React78.useReducer((x) => x + 1, 0);
1593
- const canvasRef = React78.useRef(null);
1592
+ const [, bump] = React79.useReducer((x) => x + 1, 0);
1593
+ const canvasRef = React79.useRef(null);
1594
1594
  const sliced = isAtlasAsset(asset);
1595
1595
  const atlas = sliced ? getAtlas(asset.atlas, bump) : void 0;
1596
1596
  const img = sliced && asset?.url ? getSheetImage(asset.url, bump) : null;
1597
1597
  const rect = sliced && atlas ? subRectFor(atlas, asset.sprite) : null;
1598
- React78.useEffect(() => {
1598
+ React79.useEffect(() => {
1599
1599
  const canvas = canvasRef.current;
1600
1600
  if (!canvas || !img || !rect) return;
1601
1601
  canvas.width = rect.sw;
@@ -1671,7 +1671,7 @@ function resolveIconProp(value, sizeClass) {
1671
1671
  const IconComp = value;
1672
1672
  return /* @__PURE__ */ jsx(IconComp, { className: sizeClass });
1673
1673
  }
1674
- if (React78__default.isValidElement(value)) {
1674
+ if (React79__default.isValidElement(value)) {
1675
1675
  return value;
1676
1676
  }
1677
1677
  if (typeof value === "object" && value !== null && isIconLike(value)) {
@@ -1748,7 +1748,7 @@ var init_Button = __esm({
1748
1748
  md: "h-icon-default w-icon-default",
1749
1749
  lg: "h-icon-default w-icon-default"
1750
1750
  };
1751
- Button = React78__default.forwardRef(
1751
+ Button = React79__default.forwardRef(
1752
1752
  ({
1753
1753
  className,
1754
1754
  variant = "primary",
@@ -1820,7 +1820,7 @@ var init_Input = __esm({
1820
1820
  init_cn();
1821
1821
  init_Icon();
1822
1822
  init_useEventBus();
1823
- Input = React78__default.forwardRef(
1823
+ Input = React79__default.forwardRef(
1824
1824
  ({
1825
1825
  className,
1826
1826
  inputType,
@@ -1844,9 +1844,9 @@ var init_Input = __esm({
1844
1844
  const eventBus = useEventBus();
1845
1845
  const type = inputType || htmlType || "text";
1846
1846
  const isDeclarative = typeof onChange === "string";
1847
- const [localValue, setLocalValue] = React78__default.useState(value);
1848
- const pendingEchoRef = React78__default.useRef(/* @__PURE__ */ new Set());
1849
- React78__default.useEffect(() => {
1847
+ const [localValue, setLocalValue] = React79__default.useState(value);
1848
+ const pendingEchoRef = React79__default.useRef(/* @__PURE__ */ new Set());
1849
+ React79__default.useEffect(() => {
1850
1850
  if (!isDeclarative) return;
1851
1851
  const incoming = value == null ? "" : String(value);
1852
1852
  if (pendingEchoRef.current.has(incoming)) {
@@ -2013,7 +2013,7 @@ var Label;
2013
2013
  var init_Label = __esm({
2014
2014
  "components/core/atoms/Label.tsx"() {
2015
2015
  init_cn();
2016
- Label = React78__default.forwardRef(
2016
+ Label = React79__default.forwardRef(
2017
2017
  ({ className, required, children, ...props }, ref) => {
2018
2018
  return /* @__PURE__ */ jsxs(
2019
2019
  "label",
@@ -2040,7 +2040,7 @@ var init_Textarea = __esm({
2040
2040
  "components/core/atoms/Textarea.tsx"() {
2041
2041
  init_cn();
2042
2042
  init_useEventBus();
2043
- Textarea = React78__default.forwardRef(
2043
+ Textarea = React79__default.forwardRef(
2044
2044
  ({ className, error, onChange, ...props }, ref) => {
2045
2045
  const eventBus = useEventBus();
2046
2046
  const handleChange = (e) => {
@@ -2290,7 +2290,7 @@ var init_Select = __esm({
2290
2290
  init_cn();
2291
2291
  init_Icon();
2292
2292
  init_useEventBus();
2293
- Select = React78__default.forwardRef(
2293
+ Select = React79__default.forwardRef(
2294
2294
  (props, _ref) => {
2295
2295
  const { multiple, searchable, clearable } = props;
2296
2296
  if (multiple || searchable || clearable) {
@@ -2307,7 +2307,7 @@ var init_Checkbox = __esm({
2307
2307
  "components/core/atoms/Checkbox.tsx"() {
2308
2308
  init_cn();
2309
2309
  init_useEventBus();
2310
- Checkbox = React78__default.forwardRef(
2310
+ Checkbox = React79__default.forwardRef(
2311
2311
  ({ className, label, id, onChange, ...props }, ref) => {
2312
2312
  const inputId = id || `checkbox-${Math.random().toString(36).substr(2, 9)}`;
2313
2313
  const eventBus = useEventBus();
@@ -2361,7 +2361,7 @@ var init_Spinner = __esm({
2361
2361
  md: "h-6 w-6",
2362
2362
  lg: "h-8 w-8"
2363
2363
  };
2364
- Spinner = React78__default.forwardRef(
2364
+ Spinner = React79__default.forwardRef(
2365
2365
  ({ className, size = "md", overlay, ...props }, ref) => {
2366
2366
  if (overlay) {
2367
2367
  return /* @__PURE__ */ jsx(
@@ -2451,7 +2451,7 @@ var init_Card = __esm({
2451
2451
  chip: "shadow-none rounded-pill border-[length:var(--border-width)] border-border",
2452
2452
  "tile-image-first": "p-0 overflow-hidden"
2453
2453
  };
2454
- Card = React78__default.forwardRef(
2454
+ Card = React79__default.forwardRef(
2455
2455
  ({
2456
2456
  className,
2457
2457
  variant = "bordered",
@@ -2500,9 +2500,9 @@ var init_Card = __esm({
2500
2500
  }
2501
2501
  );
2502
2502
  Card.displayName = "Card";
2503
- CardHeader = React78__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("mb-4", className), ...props }));
2503
+ CardHeader = React79__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("mb-4", className), ...props }));
2504
2504
  CardHeader.displayName = "CardHeader";
2505
- CardTitle = React78__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
2505
+ CardTitle = React79__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
2506
2506
  "h3",
2507
2507
  {
2508
2508
  ref,
@@ -2515,11 +2515,11 @@ var init_Card = __esm({
2515
2515
  }
2516
2516
  ));
2517
2517
  CardTitle.displayName = "CardTitle";
2518
- CardContent = React78__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("", className), ...props }));
2518
+ CardContent = React79__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx("div", { ref, className: cn("", className), ...props }));
2519
2519
  CardContent.displayName = "CardContent";
2520
2520
  CardBody = CardContent;
2521
2521
  CardBody.displayName = "CardBody";
2522
- CardFooter = React78__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
2522
+ CardFooter = React79__default.forwardRef(({ className, ...props }, ref) => /* @__PURE__ */ jsx(
2523
2523
  "div",
2524
2524
  {
2525
2525
  ref,
@@ -2573,7 +2573,7 @@ var init_Badge = __esm({
2573
2573
  md: "px-2.5 py-1 text-sm",
2574
2574
  lg: "px-3 py-1.5 text-base"
2575
2575
  };
2576
- Badge = React78__default.forwardRef(
2576
+ Badge = React79__default.forwardRef(
2577
2577
  ({ className, variant = "default", size = "sm", amount, label, icon, iconAsset, children, onRemove, removeLabel, ...props }, ref) => {
2578
2578
  const iconSizes3 = {
2579
2579
  sm: "h-icon-default w-icon-default",
@@ -2701,7 +2701,7 @@ var init_FilterPill = __esm({
2701
2701
  md: "w-3.5 h-3.5",
2702
2702
  lg: "w-4 h-4"
2703
2703
  };
2704
- FilterPill = React78__default.forwardRef(
2704
+ FilterPill = React79__default.forwardRef(
2705
2705
  ({
2706
2706
  className,
2707
2707
  variant = "default",
@@ -2830,8 +2830,8 @@ var init_Avatar = __esm({
2830
2830
  actionPayload
2831
2831
  }) => {
2832
2832
  const eventBus = useEventBus();
2833
- const [imgFailed, setImgFailed] = React78__default.useState(false);
2834
- React78__default.useEffect(() => {
2833
+ const [imgFailed, setImgFailed] = React79__default.useState(false);
2834
+ React79__default.useEffect(() => {
2835
2835
  setImgFailed(false);
2836
2836
  }, [src]);
2837
2837
  const initials = providedInitials ?? (name ? generateInitials(name) : void 0);
@@ -3083,7 +3083,7 @@ var init_Box = __esm({
3083
3083
  fixed: "fixed",
3084
3084
  sticky: "sticky"
3085
3085
  };
3086
- Box = React78__default.forwardRef(
3086
+ Box = React79__default.forwardRef(
3087
3087
  ({
3088
3088
  padding,
3089
3089
  paddingX,
@@ -3148,7 +3148,7 @@ var init_Box = __esm({
3148
3148
  onPointerDown?.(e);
3149
3149
  }, [hoverEvent, tapReveal, triggerProps, onPointerDown]);
3150
3150
  const isClickable = action || onClick;
3151
- return React78__default.createElement(
3151
+ return React79__default.createElement(
3152
3152
  Component,
3153
3153
  {
3154
3154
  ref,
@@ -3202,7 +3202,7 @@ var init_Center = __esm({
3202
3202
  as: Component = "div"
3203
3203
  }) => {
3204
3204
  const mergedStyle = minHeight ? { minHeight, ...style } : style;
3205
- return React78__default.createElement(Component, {
3205
+ return React79__default.createElement(Component, {
3206
3206
  className: cn(
3207
3207
  inline ? "inline-flex" : "flex",
3208
3208
  horizontal && "justify-center",
@@ -3470,7 +3470,7 @@ var init_Radio = __esm({
3470
3470
  md: "w-2.5 h-2.5",
3471
3471
  lg: "w-3 h-3"
3472
3472
  };
3473
- Radio = React78__default.forwardRef(
3473
+ Radio = React79__default.forwardRef(
3474
3474
  ({
3475
3475
  label,
3476
3476
  helperText,
@@ -3487,12 +3487,12 @@ var init_Radio = __esm({
3487
3487
  onChange,
3488
3488
  ...props
3489
3489
  }, ref) => {
3490
- const reactId = React78__default.useId();
3490
+ const reactId = React79__default.useId();
3491
3491
  const baseId = id || `radio-${reactId}`;
3492
3492
  const hasError = !!error;
3493
3493
  const eventBus = useEventBus();
3494
- const [selected, setSelected] = React78__default.useState(value);
3495
- React78__default.useEffect(() => {
3494
+ const [selected, setSelected] = React79__default.useState(value);
3495
+ React79__default.useEffect(() => {
3496
3496
  if (value !== void 0) setSelected(value);
3497
3497
  }, [value]);
3498
3498
  const pick = (next, e) => {
@@ -3674,7 +3674,7 @@ var init_Switch = __esm({
3674
3674
  "components/core/atoms/Switch.tsx"() {
3675
3675
  "use client";
3676
3676
  init_cn();
3677
- Switch = React78.forwardRef(
3677
+ Switch = React79.forwardRef(
3678
3678
  ({
3679
3679
  checked,
3680
3680
  defaultChecked = false,
@@ -3685,10 +3685,10 @@ var init_Switch = __esm({
3685
3685
  name,
3686
3686
  className
3687
3687
  }, ref) => {
3688
- const [isChecked, setIsChecked] = React78.useState(
3688
+ const [isChecked, setIsChecked] = React79.useState(
3689
3689
  checked !== void 0 ? checked : defaultChecked
3690
3690
  );
3691
- React78.useEffect(() => {
3691
+ React79.useEffect(() => {
3692
3692
  if (checked !== void 0) {
3693
3693
  setIsChecked(checked);
3694
3694
  }
@@ -3851,7 +3851,7 @@ var init_Stack = __esm({
3851
3851
  };
3852
3852
  const isHorizontal = direction === "horizontal";
3853
3853
  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";
3854
- return React78__default.createElement(
3854
+ return React79__default.createElement(
3855
3855
  Component,
3856
3856
  {
3857
3857
  className: cn(
@@ -4140,7 +4140,7 @@ var init_Typography = __esm({
4140
4140
  if (format !== void 0 && format !== "none" && (typeof body === "string" || typeof body === "number" || body instanceof Date)) {
4141
4141
  body = formatValue(body, format);
4142
4142
  }
4143
- return React78__default.createElement(
4143
+ return React79__default.createElement(
4144
4144
  Component,
4145
4145
  {
4146
4146
  id,
@@ -4374,7 +4374,7 @@ var Dialog;
4374
4374
  var init_Dialog = __esm({
4375
4375
  "components/core/atoms/Dialog.tsx"() {
4376
4376
  init_cn();
4377
- Dialog = React78__default.forwardRef(
4377
+ Dialog = React79__default.forwardRef(
4378
4378
  ({
4379
4379
  role = "dialog",
4380
4380
  "aria-modal": ariaModal = true,
@@ -4400,7 +4400,7 @@ var Aside;
4400
4400
  var init_Aside = __esm({
4401
4401
  "components/core/atoms/Aside.tsx"() {
4402
4402
  init_cn();
4403
- Aside = React78__default.forwardRef(
4403
+ Aside = React79__default.forwardRef(
4404
4404
  ({ className, children, ...rest }, ref) => /* @__PURE__ */ jsx("aside", { ref, className: cn(className), ...rest, children })
4405
4405
  );
4406
4406
  Aside.displayName = "Aside";
@@ -4479,9 +4479,9 @@ var init_LawReferenceTooltip = __esm({
4479
4479
  className
4480
4480
  }) => {
4481
4481
  const { t } = useTranslate();
4482
- const [isVisible, setIsVisible] = React78__default.useState(false);
4483
- const timeoutRef = React78__default.useRef(null);
4484
- const triggerRef = React78__default.useRef(null);
4482
+ const [isVisible, setIsVisible] = React79__default.useState(false);
4483
+ const timeoutRef = React79__default.useRef(null);
4484
+ const triggerRef = React79__default.useRef(null);
4485
4485
  const handleMouseEnter = () => {
4486
4486
  if (timeoutRef.current) clearTimeout(timeoutRef.current);
4487
4487
  timeoutRef.current = setTimeout(() => setIsVisible(true), 200);
@@ -4492,7 +4492,7 @@ var init_LawReferenceTooltip = __esm({
4492
4492
  };
4493
4493
  const { revealed, triggerProps } = useTapReveal({ refs: [triggerRef] });
4494
4494
  const open = isVisible || revealed;
4495
- React78__default.useEffect(() => {
4495
+ React79__default.useEffect(() => {
4496
4496
  return () => {
4497
4497
  if (timeoutRef.current) clearTimeout(timeoutRef.current);
4498
4498
  };
@@ -4702,7 +4702,7 @@ var init_StatusDot = __esm({
4702
4702
  md: "w-2.5 h-2.5",
4703
4703
  lg: "w-3 h-3"
4704
4704
  };
4705
- StatusDot = React78__default.forwardRef(
4705
+ StatusDot = React79__default.forwardRef(
4706
4706
  ({ className, status = "offline", pulse = false, size = "md", label, ...props }, ref) => {
4707
4707
  return /* @__PURE__ */ jsx(
4708
4708
  "span",
@@ -4756,7 +4756,7 @@ var init_TrendIndicator = __esm({
4756
4756
  down: "trending-down",
4757
4757
  flat: "arrow-right"
4758
4758
  };
4759
- TrendIndicator = React78__default.forwardRef(
4759
+ TrendIndicator = React79__default.forwardRef(
4760
4760
  ({
4761
4761
  className,
4762
4762
  value,
@@ -4825,7 +4825,7 @@ var init_RangeSlider = __esm({
4825
4825
  md: "w-4 h-4",
4826
4826
  lg: "w-5 h-5"
4827
4827
  };
4828
- RangeSlider = React78__default.forwardRef(
4828
+ RangeSlider = React79__default.forwardRef(
4829
4829
  ({
4830
4830
  className,
4831
4831
  min = 0,
@@ -5482,7 +5482,7 @@ var init_ContentSection = __esm({
5482
5482
  md: "py-16",
5483
5483
  lg: "py-24"
5484
5484
  };
5485
- ContentSection = React78__default.forwardRef(
5485
+ ContentSection = React79__default.forwardRef(
5486
5486
  ({ children, background = "default", padding = "lg", id, className }, ref) => {
5487
5487
  return /* @__PURE__ */ jsx(
5488
5488
  Box,
@@ -6016,7 +6016,7 @@ var init_AnimatedReveal = __esm({
6016
6016
  "scale-up": { opacity: 1, transform: "scale(1) translateY(0)" },
6017
6017
  "none": {}
6018
6018
  };
6019
- AnimatedReveal = React78__default.forwardRef(
6019
+ AnimatedReveal = React79__default.forwardRef(
6020
6020
  ({
6021
6021
  trigger = "scroll",
6022
6022
  animation = "fade-up",
@@ -6176,7 +6176,7 @@ var init_AnimatedGraphic = __esm({
6176
6176
  "components/marketing/atoms/AnimatedGraphic.tsx"() {
6177
6177
  "use client";
6178
6178
  init_cn();
6179
- AnimatedGraphic = React78__default.forwardRef(
6179
+ AnimatedGraphic = React79__default.forwardRef(
6180
6180
  ({
6181
6181
  src,
6182
6182
  svgContent,
@@ -6199,7 +6199,7 @@ var init_AnimatedGraphic = __esm({
6199
6199
  const fetchedSvg = useFetchedSvg(svgContent ? void 0 : src);
6200
6200
  const resolvedSvg = svgContent ?? fetchedSvg;
6201
6201
  const prevAnimateRef = useRef(animate);
6202
- const setRef = React78__default.useCallback(
6202
+ const setRef = React79__default.useCallback(
6203
6203
  (node) => {
6204
6204
  containerRef.current = node;
6205
6205
  if (typeof ref === "function") ref(node);
@@ -6300,7 +6300,7 @@ function resolveMarkerExpression(expression, entity, config, state) {
6300
6300
  function isPlainObject(value) {
6301
6301
  if (value === null || value === void 0 || typeof value !== "object") return false;
6302
6302
  if (Array.isArray(value)) return false;
6303
- if (React78__default.isValidElement(value)) return false;
6303
+ if (React79__default.isValidElement(value)) return false;
6304
6304
  if (value instanceof Date) return false;
6305
6305
  if (typeof value === "function") return false;
6306
6306
  return true;
@@ -6309,7 +6309,7 @@ function isEvaluatorResolvedData(value) {
6309
6309
  return evaluatorResolvedData.has(value);
6310
6310
  }
6311
6311
  function brandResolved(value) {
6312
- if (value !== null && typeof value === "object" && !React78__default.isValidElement(value) && !(value instanceof Date)) {
6312
+ if (value !== null && typeof value === "object" && !React79__default.isValidElement(value) && !(value instanceof Date)) {
6313
6313
  resolvedMarkerFree.add(value);
6314
6314
  }
6315
6315
  }
@@ -6342,7 +6342,7 @@ function walkValue(value, scopeTrait, entity, config, state) {
6342
6342
  }
6343
6343
  const resolved = resolveMarkerExpression(value.expression, entity, config, state);
6344
6344
  markerResolutionCache.set(value, { entity, config, state, resolved });
6345
- if (resolved !== null && typeof resolved === "object" && !React78__default.isValidElement(resolved) && !(resolved instanceof Date)) {
6345
+ if (resolved !== null && typeof resolved === "object" && !React79__default.isValidElement(resolved) && !(resolved instanceof Date)) {
6346
6346
  resolvedMarkerFree.add(resolved);
6347
6347
  evaluatorResolvedData.add(resolved);
6348
6348
  }
@@ -6999,7 +6999,7 @@ var init_ErrorBoundary = __esm({
6999
6999
  }
7000
7000
  );
7001
7001
  };
7002
- ErrorBoundary = class extends React78__default.Component {
7002
+ ErrorBoundary = class extends React79__default.Component {
7003
7003
  constructor(props) {
7004
7004
  super(props);
7005
7005
  __publicField(this, "reset", () => {
@@ -7282,7 +7282,7 @@ var init_Container = __esm({
7282
7282
  as: Component = "div"
7283
7283
  }) => {
7284
7284
  const resolvedSize = maxWidth ?? size ?? "lg";
7285
- return React78__default.createElement(
7285
+ return React79__default.createElement(
7286
7286
  Component,
7287
7287
  {
7288
7288
  className: cn(
@@ -13409,7 +13409,7 @@ function useLanguageReady(language) {
13409
13409
  }, [language]);
13410
13410
  return ready;
13411
13411
  }
13412
- var dynamicallyLoaded, codeLanguageLoader, orbStyleOverrides, orbStyle, loloStyleOverrides, loloStyle, log5, CODE_LANGUAGES, CODE_LANGUAGE_SET, DIFF_STYLES, DIFF_STYLE_FALLBACK, LINE_PROPS_FN, HIDDEN_LINE_NUMBERS, CodeBlock;
13412
+ var dynamicallyLoaded, codeLanguageLoader, orbStyleOverrides, orbStyle, loloStyleOverrides, loloStyle, log5, CODE_LANGUAGES, CODE_LANGUAGE_SET, DIFF_STYLES, DIFF_STYLE_FALLBACK, LINE_PROPS_FN, HIDDEN_LINE_NUMBERS, HIGHLIGHT_CAPACITY_BYTES, CodeBlock;
13413
13413
  var init_CodeBlock = __esm({
13414
13414
  "components/core/molecules/markdown/CodeBlock.tsx"() {
13415
13415
  init_cn();
@@ -13642,7 +13642,8 @@ var init_CodeBlock = __esm({
13642
13642
  DIFF_STYLE_FALLBACK = { bg: "", prefix: " ", text: "text-foreground" };
13643
13643
  LINE_PROPS_FN = (n) => ({ "data-line": String(n - 1) });
13644
13644
  HIDDEN_LINE_NUMBERS = { display: "none" };
13645
- CodeBlock = React78__default.memo(
13645
+ HIGHLIGHT_CAPACITY_BYTES = 512 * 1024;
13646
+ CodeBlock = React79__default.memo(
13646
13647
  ({
13647
13648
  code: rawCode,
13648
13649
  language = "text",
@@ -13672,6 +13673,8 @@ var init_CodeBlock = __esm({
13672
13673
  const isOrb = language === "orb";
13673
13674
  const isLolo = language === "lolo";
13674
13675
  const activeStyle = isOrb ? orbStyle : isLolo ? loloStyle : dark;
13676
+ const overCapacity = code.length > HIGHLIGHT_CAPACITY_BYTES;
13677
+ const plainCodeColor = activeStyle['code[class*="language-"]']?.color ?? "#d4d4d4";
13675
13678
  const languageReady = useLanguageReady(language);
13676
13679
  const eventBus = useEventBus();
13677
13680
  const { t } = useTranslate();
@@ -13738,8 +13741,8 @@ var init_CodeBlock = __esm({
13738
13741
  const isFoldable = foldableProp ?? true;
13739
13742
  const [collapsed, setCollapsed] = useState(() => /* @__PURE__ */ new Set());
13740
13743
  const foldRegions = useMemo(
13741
- () => isFoldable ? computeFoldRegions(code) : [],
13742
- [code, isFoldable]
13744
+ () => isFoldable && !overCapacity ? computeFoldRegions(code) : [],
13745
+ [code, isFoldable, overCapacity]
13743
13746
  );
13744
13747
  const foldStartMap = useMemo(() => {
13745
13748
  const m = /* @__PURE__ */ new Map();
@@ -13773,8 +13776,67 @@ var init_CodeBlock = __esm({
13773
13776
  useEffect(() => {
13774
13777
  setCollapsed(/* @__PURE__ */ new Set());
13775
13778
  }, [code]);
13779
+ const editableOverCapacity = editableValue.length > HIGHLIGHT_CAPACITY_BYTES;
13780
+ const editableHighlightedElement = useMemo(
13781
+ () => editableOverCapacity ? /* @__PURE__ */ jsx(
13782
+ "div",
13783
+ {
13784
+ style: {
13785
+ padding: "1rem",
13786
+ margin: 0,
13787
+ whiteSpace: "pre",
13788
+ minWidth: "100%",
13789
+ color: plainCodeColor,
13790
+ fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
13791
+ fontSize: "13px",
13792
+ lineHeight: "1.5"
13793
+ },
13794
+ children: editableValue || " "
13795
+ }
13796
+ ) : /* @__PURE__ */ jsx(
13797
+ SyntaxHighlighter,
13798
+ {
13799
+ PreTag: "div",
13800
+ language,
13801
+ style: activeStyle,
13802
+ wrapLines: errorLines && errorLines.size > 0,
13803
+ lineProps: errorLineProps,
13804
+ customStyle: {
13805
+ backgroundColor: "transparent",
13806
+ borderRadius: 0,
13807
+ padding: "1rem",
13808
+ margin: 0,
13809
+ whiteSpace: "pre",
13810
+ minWidth: "100%",
13811
+ fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
13812
+ fontSize: "13px",
13813
+ lineHeight: "1.5"
13814
+ },
13815
+ codeTagProps: {
13816
+ style: {
13817
+ fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
13818
+ fontSize: "13px",
13819
+ lineHeight: "1.5"
13820
+ }
13821
+ },
13822
+ children: editableValue || " "
13823
+ }
13824
+ ),
13825
+ [editableValue, editableOverCapacity, plainCodeColor, language, activeStyle, errorLines, errorLineProps, languageReady]
13826
+ );
13776
13827
  const highlightedElement = useMemo(
13777
- () => /* @__PURE__ */ jsx(
13828
+ () => overCapacity ? /* @__PURE__ */ jsx(
13829
+ "div",
13830
+ {
13831
+ style: {
13832
+ margin: 0,
13833
+ whiteSpace: "pre",
13834
+ minWidth: "100%",
13835
+ color: plainCodeColor
13836
+ },
13837
+ children: code
13838
+ }
13839
+ ) : /* @__PURE__ */ jsx(
13778
13840
  SyntaxHighlighter,
13779
13841
  {
13780
13842
  PreTag: "div",
@@ -13796,7 +13858,7 @@ var init_CodeBlock = __esm({
13796
13858
  children: code
13797
13859
  }
13798
13860
  ),
13799
- [code, language, activeStyle, languageReady]
13861
+ [code, overCapacity, plainCodeColor, language, activeStyle, languageReady]
13800
13862
  );
13801
13863
  useLayoutEffect(() => {
13802
13864
  const container = codeRef.current;
@@ -14125,35 +14187,7 @@ var init_CodeBlock = __esm({
14125
14187
  overflow: "hidden",
14126
14188
  pointerEvents: "none"
14127
14189
  },
14128
- children: /* @__PURE__ */ jsx(
14129
- SyntaxHighlighter,
14130
- {
14131
- PreTag: "div",
14132
- language,
14133
- style: activeStyle,
14134
- wrapLines: errorLines && errorLines.size > 0,
14135
- lineProps: errorLineProps,
14136
- customStyle: {
14137
- backgroundColor: "transparent",
14138
- borderRadius: 0,
14139
- padding: "1rem",
14140
- margin: 0,
14141
- whiteSpace: "pre",
14142
- minWidth: "100%",
14143
- fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
14144
- fontSize: "13px",
14145
- lineHeight: "1.5"
14146
- },
14147
- codeTagProps: {
14148
- style: {
14149
- fontFamily: 'ui-monospace, SFMono-Regular, Menlo, Monaco, "Cascadia Mono", "Courier New", monospace',
14150
- fontSize: "13px",
14151
- lineHeight: "1.5"
14152
- }
14153
- },
14154
- children: editableValue || " "
14155
- }
14156
- )
14190
+ children: editableHighlightedElement
14157
14191
  }
14158
14192
  ),
14159
14193
  /* @__PURE__ */ jsx(
@@ -14237,7 +14271,7 @@ var init_MermaidDiagram = __esm({
14237
14271
  init_CodeBlock();
14238
14272
  init_cn();
14239
14273
  mermaidModule = null;
14240
- MermaidDiagram = React78__default.memo(
14274
+ MermaidDiagram = React79__default.memo(
14241
14275
  ({ code, className }) => {
14242
14276
  const { resolvedMode } = useTheme();
14243
14277
  const containerRef = useRef(null);
@@ -14295,7 +14329,7 @@ var init_MarkdownContent = __esm({
14295
14329
  init_CodeBlock();
14296
14330
  init_MermaidDiagram();
14297
14331
  init_cn();
14298
- MarkdownContent = React78__default.memo(
14332
+ MarkdownContent = React79__default.memo(
14299
14333
  ({ content, direction = "ltr", className }) => {
14300
14334
  const { t: _t } = useTranslate();
14301
14335
  const safeContent = typeof content === "string" ? content : String(content ?? "");
@@ -15625,7 +15659,7 @@ var init_StateMachineView = __esm({
15625
15659
  style: { top: title ? 30 : 0 },
15626
15660
  children: [
15627
15661
  entity && /* @__PURE__ */ jsx(EntityBox, { entity, config }),
15628
- states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(React78__default.Fragment, { children: renderStateNode(state, config) }, state.id) : /* @__PURE__ */ jsx(
15662
+ states.map((state) => renderStateNode ? /* @__PURE__ */ jsx(React79__default.Fragment, { children: renderStateNode(state, config) }, state.id) : /* @__PURE__ */ jsx(
15629
15663
  StateNode,
15630
15664
  {
15631
15665
  state,
@@ -18266,8 +18300,8 @@ function MiniMap({
18266
18300
  tileAssets,
18267
18301
  unitAssets
18268
18302
  }) {
18269
- const canvasRef = React78.useRef(null);
18270
- const imgCacheRef = React78.useRef(/* @__PURE__ */ new Map());
18303
+ const canvasRef = React79.useRef(null);
18304
+ const imgCacheRef = React79.useRef(/* @__PURE__ */ new Map());
18271
18305
  function loadImg(url) {
18272
18306
  const cached = imgCacheRef.current.get(url);
18273
18307
  if (cached) return cached.complete ? cached : null;
@@ -18283,7 +18317,7 @@ function MiniMap({
18283
18317
  imgCacheRef.current.set(url, img);
18284
18318
  return null;
18285
18319
  }
18286
- React78.useEffect(() => {
18320
+ React79.useEffect(() => {
18287
18321
  const canvas = canvasRef.current;
18288
18322
  if (!canvas) return;
18289
18323
  const ctx = canvas.getContext("2d");
@@ -18864,7 +18898,7 @@ function Canvas2D({
18864
18898
  const registerChildDrawable = useCallback((node) => {
18865
18899
  childDrawablesRef.current.push(node);
18866
18900
  }, []);
18867
- const hasJsxChildren = React78.Children.count(children) > 0;
18901
+ const hasJsxChildren = React79.Children.count(children) > 0;
18868
18902
  function isDrawableLayer(node) {
18869
18903
  return node.type === "draw-sprite-layer" || node.type === "draw-shape-layer" || node.type === "draw-text-layer";
18870
18904
  }
@@ -19422,7 +19456,7 @@ function Canvas({
19422
19456
  if (mode !== "3d") return;
19423
19457
  const next = childDrawablesRef.current;
19424
19458
  canvasLog.debug("children:adopt", { registered: next.length, adopted: childDrawables.length });
19425
- if (next.length === 0 && React78.Children.count(children) > 0) return;
19459
+ if (next.length === 0 && React79.Children.count(children) > 0) return;
19426
19460
  setChildDrawables(
19427
19461
  (prev) => prev.length === next.length && JSON.stringify(prev) === JSON.stringify(next) ? prev : [...next]
19428
19462
  );
@@ -19460,7 +19494,7 @@ function Canvas({
19460
19494
  };
19461
19495
  return /* @__PURE__ */ jsxs(Fragment, { children: [
19462
19496
  /* @__PURE__ */ jsx(Suspense, { fallback: null, children: /* @__PURE__ */ jsx(Canvas3DHost2, { ...props3d }) }),
19463
- React78.Children.count(children) > 0 && /* @__PURE__ */ jsx(DrawableRegistryContext.Provider, { value: registerChildDrawable, children: /* @__PURE__ */ jsx("div", { "aria-hidden": "true", style: { position: "absolute", width: 0, height: 0, overflow: "hidden" }, children }) })
19497
+ React79.Children.count(children) > 0 && /* @__PURE__ */ jsx(DrawableRegistryContext.Provider, { value: registerChildDrawable, children: /* @__PURE__ */ jsx("div", { "aria-hidden": "true", style: { position: "absolute", width: 0, height: 0, overflow: "hidden" }, children }) })
19464
19498
  ] });
19465
19499
  }
19466
19500
  return /* @__PURE__ */ jsx(
@@ -21852,6 +21886,183 @@ var init_CodeRunnerPanel = __esm({
21852
21886
  CodeRunnerPanel.displayName = "CodeRunnerPanel";
21853
21887
  }
21854
21888
  });
21889
+ function matchesQuery(query, text) {
21890
+ if (!query) return true;
21891
+ let qi = 0;
21892
+ const q = query.toLowerCase();
21893
+ const t = text.toLowerCase();
21894
+ for (let ti = 0; ti < t.length && qi < q.length; ti++) {
21895
+ if (t[ti] === q[qi]) qi++;
21896
+ }
21897
+ return qi === q.length;
21898
+ }
21899
+ function commandMatches(command, query) {
21900
+ if (!query) return true;
21901
+ if (matchesQuery(query, command.label)) return true;
21902
+ return (command.keywords ?? []).some((keyword) => matchesQuery(query, keyword));
21903
+ }
21904
+ var UNGROUPED, CommandPalette;
21905
+ var init_CommandPalette = __esm({
21906
+ "components/core/molecules/CommandPalette.tsx"() {
21907
+ "use client";
21908
+ init_Box();
21909
+ init_Stack();
21910
+ init_Typography();
21911
+ init_Icon();
21912
+ init_Input();
21913
+ init_Badge();
21914
+ init_cn();
21915
+ init_useEventBus();
21916
+ init_Modal();
21917
+ UNGROUPED = /* @__PURE__ */ Symbol("command-palette-ungrouped");
21918
+ CommandPalette = ({
21919
+ open,
21920
+ onOpenChange,
21921
+ commands,
21922
+ onSelect,
21923
+ placeholder = "Type a command...",
21924
+ emptyLabel = "No matching commands",
21925
+ className
21926
+ }) => {
21927
+ const eventBus = useEventBus();
21928
+ const [query, setQuery] = useState("");
21929
+ const [highlightIndex, setHighlightIndex] = useState(0);
21930
+ const filtered = useMemo(
21931
+ () => commands.filter((command) => commandMatches(command, query)),
21932
+ [commands, query]
21933
+ );
21934
+ const groups = useMemo(() => {
21935
+ const order = [];
21936
+ const byGroup = /* @__PURE__ */ new Map();
21937
+ for (const command of filtered) {
21938
+ const key = command.group ?? UNGROUPED;
21939
+ if (!byGroup.has(key)) {
21940
+ byGroup.set(key, []);
21941
+ order.push(key);
21942
+ }
21943
+ byGroup.get(key).push(command);
21944
+ }
21945
+ return order.map((key) => ({ group: key === UNGROUPED ? void 0 : key, items: byGroup.get(key) }));
21946
+ }, [filtered]);
21947
+ const resetQuery = useCallback(() => {
21948
+ setQuery("");
21949
+ setHighlightIndex(0);
21950
+ }, []);
21951
+ const handleClose = useCallback(() => {
21952
+ resetQuery();
21953
+ onOpenChange(false);
21954
+ }, [onOpenChange, resetQuery]);
21955
+ const handleSelect = useCallback(
21956
+ (command) => {
21957
+ if (command.disabled) return;
21958
+ if (command.event) eventBus.emit(`UI:${command.event}`, { commandId: command.id });
21959
+ if (command.action) eventBus.emit(`UI:${command.action}`, command.actionPayload ?? {});
21960
+ onSelect?.(command);
21961
+ handleClose();
21962
+ },
21963
+ [eventBus, onSelect, handleClose]
21964
+ );
21965
+ const handleQueryChange = useCallback((e) => {
21966
+ setQuery(e.target.value);
21967
+ setHighlightIndex(0);
21968
+ }, []);
21969
+ const handleKeyDown = useCallback(
21970
+ (e) => {
21971
+ if (filtered.length === 0) return;
21972
+ if (e.key === "ArrowDown") {
21973
+ e.preventDefault();
21974
+ setHighlightIndex((prev) => prev < filtered.length - 1 ? prev + 1 : 0);
21975
+ } else if (e.key === "ArrowUp") {
21976
+ e.preventDefault();
21977
+ setHighlightIndex((prev) => prev > 0 ? prev - 1 : filtered.length - 1);
21978
+ } else if (e.key === "Enter") {
21979
+ e.preventDefault();
21980
+ const command = filtered[highlightIndex];
21981
+ if (command) handleSelect(command);
21982
+ }
21983
+ },
21984
+ [filtered, highlightIndex, handleSelect]
21985
+ );
21986
+ return /* @__PURE__ */ jsx(
21987
+ Modal,
21988
+ {
21989
+ isOpen: open,
21990
+ onClose: handleClose,
21991
+ onExited: resetQuery,
21992
+ showCloseButton: false,
21993
+ size: "md",
21994
+ className,
21995
+ children: /* @__PURE__ */ jsx(Box, { "data-testid": "command-palette", children: /* @__PURE__ */ jsxs(VStack, { gap: "sm", children: [
21996
+ /* @__PURE__ */ jsx(
21997
+ Input,
21998
+ {
21999
+ inputType: "search",
22000
+ placeholder,
22001
+ value: query,
22002
+ onChange: handleQueryChange,
22003
+ onKeyDown: handleKeyDown,
22004
+ leftIcon: "search",
22005
+ clearable: query.length > 0,
22006
+ onClear: resetQuery,
22007
+ autoFocus: true,
22008
+ "data-testid": "command-palette-input"
22009
+ }
22010
+ ),
22011
+ filtered.length === 0 ? /* @__PURE__ */ jsx(Box, { className: "px-2 py-6 text-center", "data-testid": "command-palette-empty", children: /* @__PURE__ */ jsx(Typography, { variant: "body", color: "muted", children: emptyLabel }) }) : /* @__PURE__ */ jsx(
22012
+ Box,
22013
+ {
22014
+ className: "max-h-80 overflow-y-auto",
22015
+ role: "listbox",
22016
+ "aria-label": placeholder,
22017
+ children: /* @__PURE__ */ jsx(VStack, { gap: "none", children: groups.map(({ group, items }) => /* @__PURE__ */ jsxs(Box, { children: [
22018
+ group ? /* @__PURE__ */ jsx(
22019
+ Typography,
22020
+ {
22021
+ variant: "caption",
22022
+ color: "muted",
22023
+ className: "px-3 pt-2 pb-1 block",
22024
+ children: group
22025
+ }
22026
+ ) : null,
22027
+ items.map((command) => {
22028
+ const index = filtered.indexOf(command);
22029
+ const isHighlighted = index === highlightIndex;
22030
+ return /* @__PURE__ */ jsxs(
22031
+ Box,
22032
+ {
22033
+ as: "button",
22034
+ role: "option",
22035
+ "aria-selected": isHighlighted,
22036
+ "aria-disabled": command.disabled || void 0,
22037
+ "data-testid": `command-palette-item-${command.id}`,
22038
+ onMouseEnter: () => !command.disabled && setHighlightIndex(index),
22039
+ onClick: () => handleSelect(command),
22040
+ className: cn(
22041
+ "w-full flex items-center gap-3 px-3 py-2 text-start rounded-sm",
22042
+ "text-sm transition-colors",
22043
+ "focus:outline-none",
22044
+ isHighlighted && "bg-muted",
22045
+ command.disabled && "opacity-50 cursor-not-allowed"
22046
+ ),
22047
+ children: [
22048
+ command.icon ? /* @__PURE__ */ jsx(Icon, { icon: command.icon, size: "sm", className: "flex-shrink-0" }) : null,
22049
+ /* @__PURE__ */ jsx(Typography, { variant: "small", className: "flex-1 truncate", children: command.label }),
22050
+ command.shortcut ? /* @__PURE__ */ jsx(Badge, { variant: "neutral", size: "sm", children: command.shortcut }) : null
22051
+ ]
22052
+ },
22053
+ command.id
22054
+ );
22055
+ })
22056
+ ] }, String(group ?? "__ungrouped__"))) })
22057
+ }
22058
+ )
22059
+ ] }) })
22060
+ }
22061
+ );
22062
+ };
22063
+ CommandPalette.displayName = "CommandPalette";
22064
+ }
22065
+ });
21855
22066
  function formatCount(count) {
21856
22067
  if (count >= 1e3) {
21857
22068
  return `${(count / 1e3).toFixed(1)}k`;
@@ -22055,9 +22266,9 @@ function ControlButton({
22055
22266
  className
22056
22267
  }) {
22057
22268
  const eventBus = useEventBus();
22058
- const [isPressed, setIsPressed] = React78.useState(false);
22269
+ const [isPressed, setIsPressed] = React79.useState(false);
22059
22270
  const actualPressed = pressed ?? isPressed;
22060
- const handlePointerDown = React78.useCallback(
22271
+ const handlePointerDown = React79.useCallback(
22061
22272
  (e) => {
22062
22273
  e.preventDefault();
22063
22274
  if (disabled) return;
@@ -22067,7 +22278,7 @@ function ControlButton({
22067
22278
  },
22068
22279
  [disabled, pressEvent, eventBus, onPress]
22069
22280
  );
22070
- const handlePointerUp = React78.useCallback(
22281
+ const handlePointerUp = React79.useCallback(
22071
22282
  (e) => {
22072
22283
  e.preventDefault();
22073
22284
  if (disabled) return;
@@ -22077,7 +22288,7 @@ function ControlButton({
22077
22288
  },
22078
22289
  [disabled, releaseEvent, eventBus, onRelease]
22079
22290
  );
22080
- const handlePointerLeave = React78.useCallback(
22291
+ const handlePointerLeave = React79.useCallback(
22081
22292
  (e) => {
22082
22293
  if (isPressed) {
22083
22294
  setIsPressed(false);
@@ -22166,18 +22377,18 @@ function ControlGrid({
22166
22377
  className
22167
22378
  }) {
22168
22379
  const eventBus = useEventBus();
22169
- const [active, setActive] = React78.useState(/* @__PURE__ */ new Set());
22170
- const [coarse, setCoarse] = React78.useState(
22380
+ const [active, setActive] = React79.useState(/* @__PURE__ */ new Set());
22381
+ const [coarse, setCoarse] = React79.useState(
22171
22382
  () => typeof window !== "undefined" && window.matchMedia("(pointer: coarse)").matches
22172
22383
  );
22173
- React78.useEffect(() => {
22384
+ React79.useEffect(() => {
22174
22385
  if (visibility !== "auto" || typeof window === "undefined") return;
22175
22386
  const mq = window.matchMedia("(pointer: coarse)");
22176
22387
  const onChange = (e) => setCoarse(e.matches);
22177
22388
  mq.addEventListener("change", onChange);
22178
22389
  return () => mq.removeEventListener("change", onChange);
22179
22390
  }, [visibility]);
22180
- const handlePress = React78.useCallback(
22391
+ const handlePress = React79.useCallback(
22181
22392
  (id) => {
22182
22393
  setActive((prev) => new Set(prev).add(id));
22183
22394
  if (actionEvent) eventBus.emit(`UI:${actionEvent}`, { id, pressed: true });
@@ -22191,7 +22402,7 @@ function ControlGrid({
22191
22402
  },
22192
22403
  [kind, actionEvent, directionEvent, directionEvents, eventBus, onAction, onDirection]
22193
22404
  );
22194
- const handleRelease = React78.useCallback(
22405
+ const handleRelease = React79.useCallback(
22195
22406
  (id) => {
22196
22407
  setActive((prev) => {
22197
22408
  const next = new Set(prev);
@@ -23447,7 +23658,7 @@ var init_Menu = __esm({
23447
23658
  "bottom-end": "bottom-start"
23448
23659
  };
23449
23660
  const effectivePosition = direction === "rtl" ? rtlMirror[position] ?? position : position;
23450
- const triggerElement = React78__default.isValidElement(trigger) ? React78__default.cloneElement(trigger, {
23661
+ const triggerElement = React79__default.isValidElement(trigger) ? React79__default.cloneElement(trigger, {
23451
23662
  ref: triggerRef,
23452
23663
  onClick: handleToggle
23453
23664
  }) : /* @__PURE__ */ jsx(
@@ -23550,14 +23761,14 @@ function useDataDnd(args) {
23550
23761
  const isZone = Boolean(dragGroup || accepts || sortable);
23551
23762
  const enabled = isZone || Boolean(dndRoot);
23552
23763
  const eventBus = useEventBus();
23553
- const parentRoot = React78__default.useContext(RootCtx);
23764
+ const parentRoot = React79__default.useContext(RootCtx);
23554
23765
  const isRoot = enabled && parentRoot === null;
23555
- const zoneId = React78__default.useId();
23766
+ const zoneId = React79__default.useId();
23556
23767
  const ownGroup = dragGroup ?? accepts ?? zoneId;
23557
- const [optimisticOrders, setOptimisticOrders] = React78__default.useState(() => /* @__PURE__ */ new Map());
23558
- const optimisticOrdersRef = React78__default.useRef(optimisticOrders);
23768
+ const [optimisticOrders, setOptimisticOrders] = React79__default.useState(() => /* @__PURE__ */ new Map());
23769
+ const optimisticOrdersRef = React79__default.useRef(optimisticOrders);
23559
23770
  optimisticOrdersRef.current = optimisticOrders;
23560
- const clearOptimisticOrder = React78__default.useCallback((group) => {
23771
+ const clearOptimisticOrder = React79__default.useCallback((group) => {
23561
23772
  setOptimisticOrders((prev) => {
23562
23773
  if (!prev.has(group)) return prev;
23563
23774
  const next = new Map(prev);
@@ -23582,7 +23793,7 @@ function useDataDnd(args) {
23582
23793
  const raw = it[dndItemIdField];
23583
23794
  return raw != null ? String(raw) : `__idx_${idx}`;
23584
23795
  }).join("|");
23585
- const itemIds = React78__default.useMemo(
23796
+ const itemIds = React79__default.useMemo(
23586
23797
  () => orderedItems.map((it, idx) => {
23587
23798
  const raw = it[dndItemIdField];
23588
23799
  return raw != null ? String(raw) : `__idx_${idx}`;
@@ -23593,7 +23804,7 @@ function useDataDnd(args) {
23593
23804
  const raw = it[dndItemIdField];
23594
23805
  return raw != null ? String(raw) : `__${idx}`;
23595
23806
  }).join("|");
23596
- React78__default.useEffect(() => {
23807
+ React79__default.useEffect(() => {
23597
23808
  const root = isRoot ? null : parentRoot;
23598
23809
  if (root) {
23599
23810
  root.clearOptimisticOrder(ownGroup);
@@ -23601,20 +23812,20 @@ function useDataDnd(args) {
23601
23812
  clearOptimisticOrder(ownGroup);
23602
23813
  }
23603
23814
  }, [itemsContentSig, ownGroup]);
23604
- const zonesRef = React78__default.useRef(/* @__PURE__ */ new Map());
23605
- const registerZone = React78__default.useCallback((zoneId2, meta2) => {
23815
+ const zonesRef = React79__default.useRef(/* @__PURE__ */ new Map());
23816
+ const registerZone = React79__default.useCallback((zoneId2, meta2) => {
23606
23817
  zonesRef.current.set(zoneId2, meta2);
23607
23818
  }, []);
23608
- const unregisterZone = React78__default.useCallback((zoneId2) => {
23819
+ const unregisterZone = React79__default.useCallback((zoneId2) => {
23609
23820
  zonesRef.current.delete(zoneId2);
23610
23821
  }, []);
23611
- const [activeDrag, setActiveDrag] = React78__default.useState(null);
23612
- const [overZoneGroup, setOverZoneGroup] = React78__default.useState(null);
23613
- const meta = React78__default.useMemo(
23822
+ const [activeDrag, setActiveDrag] = React79__default.useState(null);
23823
+ const [overZoneGroup, setOverZoneGroup] = React79__default.useState(null);
23824
+ const meta = React79__default.useMemo(
23614
23825
  () => ({ group: ownGroup, dropEvent, reorderEvent, positionEvent, itemIds, rawItems: items, idField: dndItemIdField }),
23615
23826
  [ownGroup, dropEvent, reorderEvent, positionEvent, itemIds, items, dndItemIdField]
23616
23827
  );
23617
- React78__default.useEffect(() => {
23828
+ React79__default.useEffect(() => {
23618
23829
  const target = isRoot ? null : parentRoot;
23619
23830
  if (!target) {
23620
23831
  zonesRef.current.set(zoneId, meta);
@@ -23633,7 +23844,7 @@ function useDataDnd(args) {
23633
23844
  }, [parentRoot, isRoot, zoneId, meta]);
23634
23845
  const sensors = useAlmadarDndSensors(true);
23635
23846
  const collisionDetection = almadarDndCollisionDetection;
23636
- const findZoneByItem = React78__default.useCallback(
23847
+ const findZoneByItem = React79__default.useCallback(
23637
23848
  (id) => {
23638
23849
  for (const z of zonesRef.current.values()) {
23639
23850
  if (z.itemIds.includes(id)) return z;
@@ -23642,7 +23853,7 @@ function useDataDnd(args) {
23642
23853
  },
23643
23854
  []
23644
23855
  );
23645
- React78__default.useCallback(
23856
+ React79__default.useCallback(
23646
23857
  (group) => {
23647
23858
  for (const z of zonesRef.current.values()) {
23648
23859
  if (z.group === group) return z;
@@ -23651,7 +23862,7 @@ function useDataDnd(args) {
23651
23862
  },
23652
23863
  []
23653
23864
  );
23654
- const handleDragEnd = React78__default.useCallback(
23865
+ const handleDragEnd = React79__default.useCallback(
23655
23866
  (event) => {
23656
23867
  const { active, over } = event;
23657
23868
  const activeIdStr = String(active.id);
@@ -23742,8 +23953,8 @@ function useDataDnd(args) {
23742
23953
  },
23743
23954
  [eventBus]
23744
23955
  );
23745
- const sortableData = React78__default.useMemo(() => ({ dndGroup: ownGroup }), [ownGroup]);
23746
- const SortableItem = React78__default.useCallback(
23956
+ const sortableData = React79__default.useMemo(() => ({ dndGroup: ownGroup }), [ownGroup]);
23957
+ const SortableItem = React79__default.useCallback(
23747
23958
  ({ id, children }) => {
23748
23959
  const {
23749
23960
  attributes,
@@ -23783,7 +23994,7 @@ function useDataDnd(args) {
23783
23994
  id: droppableId,
23784
23995
  data: sortableData
23785
23996
  });
23786
- const ctx = React78__default.useContext(RootCtx);
23997
+ const ctx = React79__default.useContext(RootCtx);
23787
23998
  const activeDrag2 = ctx?.activeDrag ?? null;
23788
23999
  const overZoneGroup2 = ctx?.overZoneGroup ?? null;
23789
24000
  const isThisZoneOver = overZoneGroup2 === ownGroup;
@@ -23798,7 +24009,7 @@ function useDataDnd(args) {
23798
24009
  showForeignPlaceholder,
23799
24010
  ctxAvailable: ctx != null
23800
24011
  });
23801
- React78__default.useEffect(() => {
24012
+ React79__default.useEffect(() => {
23802
24013
  dndLog.info("dropzone:isOver:change", { droppableId, group: ownGroup, isOver, isThisZoneOver, showForeignPlaceholder, activeDragSourceGroup: activeDrag2?.sourceGroup ?? null });
23803
24014
  }, [droppableId, isOver, isThisZoneOver, showForeignPlaceholder]);
23804
24015
  return /* @__PURE__ */ jsx(
@@ -23812,11 +24023,11 @@ function useDataDnd(args) {
23812
24023
  }
23813
24024
  );
23814
24025
  };
23815
- const rootContextValue = React78__default.useMemo(
24026
+ const rootContextValue = React79__default.useMemo(
23816
24027
  () => ({ registerZone, unregisterZone, activeDrag, overZoneGroup, optimisticOrders, clearOptimisticOrder }),
23817
24028
  [registerZone, unregisterZone, activeDrag, overZoneGroup, optimisticOrders, clearOptimisticOrder]
23818
24029
  );
23819
- const handleDragStart = React78__default.useCallback((event) => {
24030
+ const handleDragStart = React79__default.useCallback((event) => {
23820
24031
  const sourceZone = findZoneByItem(event.active.id);
23821
24032
  const rect = event.active.rect.current.initial;
23822
24033
  const height = rect?.height && rect.height > 0 ? rect.height : 64;
@@ -23835,7 +24046,7 @@ function useDataDnd(args) {
23835
24046
  isRoot
23836
24047
  });
23837
24048
  }, [findZoneByItem, isRoot, zoneId]);
23838
- const handleDragOver = React78__default.useCallback((event) => {
24049
+ const handleDragOver = React79__default.useCallback((event) => {
23839
24050
  const { active, over } = event;
23840
24051
  const overData = over?.data?.current;
23841
24052
  const overGroup = overData?.dndGroup ?? null;
@@ -23905,7 +24116,7 @@ function useDataDnd(args) {
23905
24116
  return next;
23906
24117
  });
23907
24118
  }, []);
23908
- const handleDragCancel = React78__default.useCallback((event) => {
24119
+ const handleDragCancel = React79__default.useCallback((event) => {
23909
24120
  setActiveDrag(null);
23910
24121
  setOverZoneGroup(null);
23911
24122
  dndLog.warn("dragCancel", {
@@ -23913,12 +24124,12 @@ function useDataDnd(args) {
23913
24124
  reason: "dnd-kit cancelled the drag (escape key, pointer interrupted, or external)"
23914
24125
  });
23915
24126
  }, []);
23916
- const handleDragEndWithCleanup = React78__default.useCallback((event) => {
24127
+ const handleDragEndWithCleanup = React79__default.useCallback((event) => {
23917
24128
  handleDragEnd(event);
23918
24129
  setActiveDrag(null);
23919
24130
  setOverZoneGroup(null);
23920
24131
  }, [handleDragEnd]);
23921
- const wrapContainer = React78__default.useCallback(
24132
+ const wrapContainer = React79__default.useCallback(
23922
24133
  (children) => {
23923
24134
  if (!enabled) return children;
23924
24135
  const strategy = layout === "grid" ? rectSortingStrategy : verticalListSortingStrategy;
@@ -23972,7 +24183,7 @@ var init_useDataDnd = __esm({
23972
24183
  init_useAlmadarDndCollision();
23973
24184
  init_Box();
23974
24185
  dndLog = createLogger("almadar:ui:dnd");
23975
- RootCtx = React78__default.createContext(null);
24186
+ RootCtx = React79__default.createContext(null);
23976
24187
  }
23977
24188
  });
23978
24189
  function renderIconInput(icon, props) {
@@ -24487,7 +24698,7 @@ function DataList({
24487
24698
  }) {
24488
24699
  const eventBus = useEventBus();
24489
24700
  const { t } = useTranslate();
24490
- const [visibleCount, setVisibleCount] = React78__default.useState(pageSize || Infinity);
24701
+ const [visibleCount, setVisibleCount] = React79__default.useState(pageSize || Infinity);
24491
24702
  const fieldDefs = fields ?? columns ?? [];
24492
24703
  const allDataRaw = Array.isArray(entity) ? entity : entity ? [entity] : [];
24493
24704
  const dnd = useDataDnd({
@@ -24503,14 +24714,14 @@ function DataList({
24503
24714
  dndRoot
24504
24715
  });
24505
24716
  const orderedData = dnd.orderedItems;
24506
- const allData = React78__default.useMemo(
24717
+ const allData = React79__default.useMemo(
24507
24718
  () => sortRows(orderedData, sortBy, sortDirection),
24508
24719
  [orderedData, sortBy, sortDirection]
24509
24720
  );
24510
24721
  const data = pageSize > 0 ? allData.slice(0, visibleCount) : allData;
24511
24722
  const hasMoreLocal = pageSize > 0 && visibleCount < allData.length;
24512
24723
  const hasRenderProp = typeof children === "function";
24513
- React78__default.useEffect(() => {
24724
+ React79__default.useEffect(() => {
24514
24725
  const renderItemTypeOf = typeof schemaRenderItem;
24515
24726
  const childrenTypeOf = typeof children;
24516
24727
  if (data.length > 0 && !hasRenderProp) {
@@ -24630,7 +24841,7 @@ function DataList({
24630
24841
  return v === void 0 || v === null || v === "" ? raw : String(v);
24631
24842
  };
24632
24843
  return /* @__PURE__ */ jsxs(VStack, { gap: "sm", className: cn("py-2", className), children: [
24633
- groups2.map((group, gi) => /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
24844
+ groups2.map((group, gi) => /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
24634
24845
  group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: "my-2" }),
24635
24846
  group.items.map((itemData, index) => {
24636
24847
  const id = itemData.id || `${gi}-${index}`;
@@ -24846,7 +25057,7 @@ function DataList({
24846
25057
  className
24847
25058
  ),
24848
25059
  children: [
24849
- groups.map((group, gi) => /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
25060
+ groups.map((group, gi) => /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
24850
25061
  group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: gi > 0 ? "mt-4" : "mt-0" }),
24851
25062
  group.items.map(
24852
25063
  (itemData, index) => renderItem(itemData, index, gi === groups.length - 1 && index === group.items.length - 1)
@@ -24955,8 +25166,8 @@ function ScalarControl({
24955
25166
  }
24956
25167
  const numeric = typeof value === "number";
24957
25168
  const initial = value === null ? "" : String(value);
24958
- const [draft, setDraft] = React78__default.useState(initial);
24959
- React78__default.useEffect(() => setDraft(initial), [initial]);
25169
+ const [draft, setDraft] = React79__default.useState(initial);
25170
+ React79__default.useEffect(() => setDraft(initial), [initial]);
24960
25171
  const commit = () => {
24961
25172
  if (numeric) {
24962
25173
  const n = draft.trim() === "" ? 0 : Number(draft);
@@ -25024,8 +25235,8 @@ function Row({
25024
25235
  onRemove,
25025
25236
  readonly
25026
25237
  }) {
25027
- const [keyDraft, setKeyDraft] = React78__default.useState(rowKey);
25028
- React78__default.useEffect(() => setKeyDraft(rowKey), [rowKey]);
25238
+ const [keyDraft, setKeyDraft] = React79__default.useState(rowKey);
25239
+ React79__default.useEffect(() => setKeyDraft(rowKey), [rowKey]);
25029
25240
  const container = isObj(value) || isArr(value);
25030
25241
  return /* @__PURE__ */ jsxs(VStack, { gap: "none", className: "group w-max min-w-full", children: [
25031
25242
  /* @__PURE__ */ jsxs(HStack, { gap: "xs", align: "center", className: "py-0.5 w-max", children: [
@@ -25068,7 +25279,7 @@ function ContainerNode({
25068
25279
  depth,
25069
25280
  readonly
25070
25281
  }) {
25071
- const [open, setOpen] = React78__default.useState(depth < 2);
25282
+ const [open, setOpen] = React79__default.useState(depth < 2);
25072
25283
  const array = isArr(value);
25073
25284
  const entries = array ? value.map((v, i) => [String(i), v]) : Object.entries(value);
25074
25285
  const setObjValue = (key, next) => {
@@ -25210,7 +25421,7 @@ var init_FormSection = __esm({
25210
25421
  columns = 1,
25211
25422
  className
25212
25423
  }) => {
25213
- const [collapsed, setCollapsed] = React78__default.useState(defaultCollapsed);
25424
+ const [collapsed, setCollapsed] = React79__default.useState(defaultCollapsed);
25214
25425
  const { t } = useTranslate();
25215
25426
  const eventBus = useEventBus();
25216
25427
  const gridClass = {
@@ -25218,7 +25429,7 @@ var init_FormSection = __esm({
25218
25429
  2: "grid-cols-1 md:grid-cols-2",
25219
25430
  3: "grid-cols-1 md:grid-cols-2 lg:grid-cols-3"
25220
25431
  }[columns];
25221
- React78__default.useCallback(() => {
25432
+ React79__default.useCallback(() => {
25222
25433
  if (collapsible) {
25223
25434
  setCollapsed((prev) => !prev);
25224
25435
  eventBus.emit("UI:TOGGLE_COLLAPSE", { collapsed: !collapsed });
@@ -25627,8 +25838,8 @@ function TextLikeControl({
25627
25838
  onCommit
25628
25839
  }) {
25629
25840
  const initial = value === void 0 || value === null ? "" : String(value);
25630
- const [draft, setDraft] = React78__default.useState(initial);
25631
- React78__default.useEffect(() => setDraft(initial), [initial]);
25841
+ const [draft, setDraft] = React79__default.useState(initial);
25842
+ React79__default.useEffect(() => setDraft(initial), [initial]);
25632
25843
  const commit = () => {
25633
25844
  if (numeric) {
25634
25845
  const n = draft.trim() === "" ? 0 : Number(draft);
@@ -25817,14 +26028,14 @@ var init_NodeSlotEditor = __esm({
25817
26028
  isObj2 = (v) => v !== null && v !== void 0 && typeof v === "object" && !Array.isArray(v);
25818
26029
  NodeSlotEditor = ({ value, onChange, className }) => {
25819
26030
  const { type, props, wasArray } = normalize(value);
25820
- const patterns = React78__default.useMemo(() => {
26031
+ const patterns = React79__default.useMemo(() => {
25821
26032
  try {
25822
26033
  return [...getKnownPatterns()].sort();
25823
26034
  } catch {
25824
26035
  return [];
25825
26036
  }
25826
26037
  }, []);
25827
- const options = React78__default.useMemo(
26038
+ const options = React79__default.useMemo(
25828
26039
  () => [{ value: "", label: "\u2014 none \u2014" }, ...patterns.map((p) => ({ value: p, label: p }))],
25829
26040
  [patterns]
25830
26041
  );
@@ -25836,7 +26047,7 @@ var init_NodeSlotEditor = __esm({
25836
26047
  const pattern = { type: nextType, ...nextProps };
25837
26048
  onChange(wasArray || value === void 0 ? [pattern] : pattern);
25838
26049
  };
25839
- const schemaEntries = React78__default.useMemo(() => {
26050
+ const schemaEntries = React79__default.useMemo(() => {
25840
26051
  if (!type) return [];
25841
26052
  const def = getPatternDefinition(type);
25842
26053
  if (!def?.propsSchema) return [];
@@ -26264,10 +26475,10 @@ var init_FileTree = __esm({
26264
26475
  indent = 16
26265
26476
  }) => {
26266
26477
  const [overrides, setOverrides] = useState(() => /* @__PURE__ */ new Map());
26267
- const byId = React78__default.useMemo(() => new Map(items.map((node) => [node.id, node])), [items]);
26268
- const selectedAncestors = React78__default.useMemo(() => ancestorsOf(selectedId, byId), [selectedId, byId]);
26269
- const lastSelectedRef = React78__default.useRef(selectedId);
26270
- React78__default.useEffect(() => {
26478
+ const byId = React79__default.useMemo(() => new Map(items.map((node) => [node.id, node])), [items]);
26479
+ const selectedAncestors = React79__default.useMemo(() => ancestorsOf(selectedId, byId), [selectedId, byId]);
26480
+ const lastSelectedRef = React79__default.useRef(selectedId);
26481
+ React79__default.useEffect(() => {
26271
26482
  if (selectedId === lastSelectedRef.current) return;
26272
26483
  lastSelectedRef.current = selectedId;
26273
26484
  setOverrides((prev) => {
@@ -26395,183 +26606,6 @@ var init_FormField = __esm({
26395
26606
  FormField.displayName = "FormField";
26396
26607
  }
26397
26608
  });
26398
- function matchesQuery(query, text) {
26399
- if (!query) return true;
26400
- let qi = 0;
26401
- const q = query.toLowerCase();
26402
- const t = text.toLowerCase();
26403
- for (let ti = 0; ti < t.length && qi < q.length; ti++) {
26404
- if (t[ti] === q[qi]) qi++;
26405
- }
26406
- return qi === q.length;
26407
- }
26408
- function commandMatches(command, query) {
26409
- if (!query) return true;
26410
- if (matchesQuery(query, command.label)) return true;
26411
- return (command.keywords ?? []).some((keyword) => matchesQuery(query, keyword));
26412
- }
26413
- var UNGROUPED, CommandPalette;
26414
- var init_CommandPalette = __esm({
26415
- "components/core/molecules/CommandPalette.tsx"() {
26416
- "use client";
26417
- init_Box();
26418
- init_Stack();
26419
- init_Typography();
26420
- init_Icon();
26421
- init_Input();
26422
- init_Badge();
26423
- init_cn();
26424
- init_useEventBus();
26425
- init_Modal();
26426
- UNGROUPED = /* @__PURE__ */ Symbol("command-palette-ungrouped");
26427
- CommandPalette = ({
26428
- open,
26429
- onOpenChange,
26430
- commands,
26431
- onSelect,
26432
- placeholder = "Type a command...",
26433
- emptyLabel = "No matching commands",
26434
- className
26435
- }) => {
26436
- const eventBus = useEventBus();
26437
- const [query, setQuery] = useState("");
26438
- const [highlightIndex, setHighlightIndex] = useState(0);
26439
- const filtered = useMemo(
26440
- () => commands.filter((command) => commandMatches(command, query)),
26441
- [commands, query]
26442
- );
26443
- const groups = useMemo(() => {
26444
- const order = [];
26445
- const byGroup = /* @__PURE__ */ new Map();
26446
- for (const command of filtered) {
26447
- const key = command.group ?? UNGROUPED;
26448
- if (!byGroup.has(key)) {
26449
- byGroup.set(key, []);
26450
- order.push(key);
26451
- }
26452
- byGroup.get(key).push(command);
26453
- }
26454
- return order.map((key) => ({ group: key === UNGROUPED ? void 0 : key, items: byGroup.get(key) }));
26455
- }, [filtered]);
26456
- const resetQuery = useCallback(() => {
26457
- setQuery("");
26458
- setHighlightIndex(0);
26459
- }, []);
26460
- const handleClose = useCallback(() => {
26461
- resetQuery();
26462
- onOpenChange(false);
26463
- }, [onOpenChange, resetQuery]);
26464
- const handleSelect = useCallback(
26465
- (command) => {
26466
- if (command.disabled) return;
26467
- if (command.event) eventBus.emit(`UI:${command.event}`, { commandId: command.id });
26468
- if (command.action) eventBus.emit(`UI:${command.action}`, command.actionPayload ?? {});
26469
- onSelect?.(command);
26470
- handleClose();
26471
- },
26472
- [eventBus, onSelect, handleClose]
26473
- );
26474
- const handleQueryChange = useCallback((e) => {
26475
- setQuery(e.target.value);
26476
- setHighlightIndex(0);
26477
- }, []);
26478
- const handleKeyDown = useCallback(
26479
- (e) => {
26480
- if (filtered.length === 0) return;
26481
- if (e.key === "ArrowDown") {
26482
- e.preventDefault();
26483
- setHighlightIndex((prev) => prev < filtered.length - 1 ? prev + 1 : 0);
26484
- } else if (e.key === "ArrowUp") {
26485
- e.preventDefault();
26486
- setHighlightIndex((prev) => prev > 0 ? prev - 1 : filtered.length - 1);
26487
- } else if (e.key === "Enter") {
26488
- e.preventDefault();
26489
- const command = filtered[highlightIndex];
26490
- if (command) handleSelect(command);
26491
- }
26492
- },
26493
- [filtered, highlightIndex, handleSelect]
26494
- );
26495
- return /* @__PURE__ */ jsx(
26496
- Modal,
26497
- {
26498
- isOpen: open,
26499
- onClose: handleClose,
26500
- onExited: resetQuery,
26501
- showCloseButton: false,
26502
- size: "md",
26503
- className,
26504
- children: /* @__PURE__ */ jsx(Box, { "data-testid": "command-palette", children: /* @__PURE__ */ jsxs(VStack, { gap: "sm", children: [
26505
- /* @__PURE__ */ jsx(
26506
- Input,
26507
- {
26508
- inputType: "search",
26509
- placeholder,
26510
- value: query,
26511
- onChange: handleQueryChange,
26512
- onKeyDown: handleKeyDown,
26513
- leftIcon: "search",
26514
- clearable: query.length > 0,
26515
- onClear: resetQuery,
26516
- autoFocus: true,
26517
- "data-testid": "command-palette-input"
26518
- }
26519
- ),
26520
- filtered.length === 0 ? /* @__PURE__ */ jsx(Box, { className: "px-2 py-6 text-center", "data-testid": "command-palette-empty", children: /* @__PURE__ */ jsx(Typography, { variant: "body", color: "muted", children: emptyLabel }) }) : /* @__PURE__ */ jsx(
26521
- Box,
26522
- {
26523
- className: "max-h-80 overflow-y-auto",
26524
- role: "listbox",
26525
- "aria-label": placeholder,
26526
- children: /* @__PURE__ */ jsx(VStack, { gap: "none", children: groups.map(({ group, items }) => /* @__PURE__ */ jsxs(Box, { children: [
26527
- group ? /* @__PURE__ */ jsx(
26528
- Typography,
26529
- {
26530
- variant: "caption",
26531
- color: "muted",
26532
- className: "px-3 pt-2 pb-1 block",
26533
- children: group
26534
- }
26535
- ) : null,
26536
- items.map((command) => {
26537
- const index = filtered.indexOf(command);
26538
- const isHighlighted = index === highlightIndex;
26539
- return /* @__PURE__ */ jsxs(
26540
- Box,
26541
- {
26542
- as: "button",
26543
- role: "option",
26544
- "aria-selected": isHighlighted,
26545
- "aria-disabled": command.disabled || void 0,
26546
- "data-testid": `command-palette-item-${command.id}`,
26547
- onMouseEnter: () => !command.disabled && setHighlightIndex(index),
26548
- onClick: () => handleSelect(command),
26549
- className: cn(
26550
- "w-full flex items-center gap-3 px-3 py-2 text-start rounded-sm",
26551
- "text-sm transition-colors",
26552
- "focus:outline-none",
26553
- isHighlighted && "bg-muted",
26554
- command.disabled && "opacity-50 cursor-not-allowed"
26555
- ),
26556
- children: [
26557
- command.icon ? /* @__PURE__ */ jsx(Icon, { icon: command.icon, size: "sm", className: "flex-shrink-0" }) : null,
26558
- /* @__PURE__ */ jsx(Typography, { variant: "small", className: "flex-1 truncate", children: command.label }),
26559
- command.shortcut ? /* @__PURE__ */ jsx(Badge, { variant: "neutral", size: "sm", children: command.shortcut }) : null
26560
- ]
26561
- },
26562
- command.id
26563
- );
26564
- })
26565
- ] }, String(group ?? "__ungrouped__"))) })
26566
- }
26567
- )
26568
- ] }) })
26569
- }
26570
- );
26571
- };
26572
- CommandPalette.displayName = "CommandPalette";
26573
- }
26574
- });
26575
26609
  function getOrCreateStore(query) {
26576
26610
  if (!queryStores.has(query)) {
26577
26611
  queryStores.set(query, {
@@ -27286,7 +27320,7 @@ var init_Flex = __esm({
27286
27320
  flexStyle.flexBasis = typeof basis === "number" ? `${basis}px` : basis;
27287
27321
  }
27288
27322
  }
27289
- return React78__default.createElement(Component, {
27323
+ return React79__default.createElement(Component, {
27290
27324
  className: cn(
27291
27325
  inline ? "inline-flex" : "flex",
27292
27326
  directionStyles[direction],
@@ -27405,7 +27439,7 @@ var init_Grid = __esm({
27405
27439
  as: Component = "div"
27406
27440
  }) => {
27407
27441
  const mergedStyle = rows2 ? { gridTemplateRows: `repeat(${rows2}, minmax(0, 1fr))`, ...style } : style;
27408
- return React78__default.createElement(
27442
+ return React79__default.createElement(
27409
27443
  Component,
27410
27444
  {
27411
27445
  className: cn(
@@ -27827,9 +27861,9 @@ var init_Popover = __esm({
27827
27861
  onMouseLeave: handleClose,
27828
27862
  onPointerDown: tapTriggerProps.onPointerDown
27829
27863
  };
27830
- const childElement = React78__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
27864
+ const childElement = React79__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
27831
27865
  const childPointerDown = childElement.props.onPointerDown;
27832
- const triggerElement = React78__default.cloneElement(
27866
+ const triggerElement = React79__default.cloneElement(
27833
27867
  childElement,
27834
27868
  {
27835
27869
  ref: triggerRef,
@@ -28693,9 +28727,9 @@ var init_Tooltip = __esm({
28693
28727
  if (hideTimeoutRef.current) clearTimeout(hideTimeoutRef.current);
28694
28728
  };
28695
28729
  }, []);
28696
- const triggerElement = React78__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
28730
+ const triggerElement = React79__default.isValidElement(children) ? children : /* @__PURE__ */ jsx("span", { children });
28697
28731
  const childPointerDown = triggerElement.props.onPointerDown;
28698
- const trigger = React78__default.cloneElement(triggerElement, {
28732
+ const trigger = React79__default.cloneElement(triggerElement, {
28699
28733
  ref: triggerRef,
28700
28734
  onMouseEnter: handleMouseEnter,
28701
28735
  onMouseLeave: handleMouseLeave,
@@ -28785,7 +28819,7 @@ var init_WizardProgress = __esm({
28785
28819
  children: /* @__PURE__ */ jsx("div", { className: "flex items-center gap-2", children: normalizedSteps.map((step, index) => {
28786
28820
  const isActive = index === currentStep;
28787
28821
  const isCompleted = index < currentStep;
28788
- return /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
28822
+ return /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
28789
28823
  /* @__PURE__ */ jsx(
28790
28824
  "button",
28791
28825
  {
@@ -30469,7 +30503,7 @@ function GameMenu({
30469
30503
  }) {
30470
30504
  const resolvedOptions = (options?.length ? options : void 0) ?? (menuItems?.length ? menuItems : void 0) ?? DEFAULT_MENU_OPTIONS;
30471
30505
  const eventBus = useEventBus();
30472
- const handleOptionClick = React78.useCallback(
30506
+ const handleOptionClick = React79.useCallback(
30473
30507
  (option) => {
30474
30508
  if (option.event) {
30475
30509
  eventBus.emit(`UI:${option.event}`, { option });
@@ -30705,7 +30739,7 @@ function StateGraph({
30705
30739
  }) {
30706
30740
  const eventBus = useEventBus();
30707
30741
  const nodes = states ?? [];
30708
- const positions = React78.useMemo(() => layoutStates(nodes, width, height), [nodes, width, height]);
30742
+ const positions = React79.useMemo(() => layoutStates(nodes, width, height), [nodes, width, height]);
30709
30743
  return /* @__PURE__ */ jsxs(
30710
30744
  Box,
30711
30745
  {
@@ -31242,7 +31276,7 @@ function LinearView({
31242
31276
  /* @__PURE__ */ jsx(HStack, { className: "flex-wrap items-center", gap: "xs", children: trait.states.map((state, i) => {
31243
31277
  const isDone = i < currentIdx;
31244
31278
  const isCurrent = i === currentIdx;
31245
- return /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
31279
+ return /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
31246
31280
  i > 0 && /* @__PURE__ */ jsx(
31247
31281
  Typography,
31248
31282
  {
@@ -31875,7 +31909,7 @@ function SequenceBar({
31875
31909
  else onSlotRemove?.(index);
31876
31910
  }, [emit, slotRemoveEvent, onSlotRemove, playing]);
31877
31911
  const paddedSlots = Array.from({ length: maxSlots }, (_, i) => slots[i]);
31878
- return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
31912
+ return /* @__PURE__ */ jsx(HStack, { className: cn("items-center", className), gap: "sm", children: paddedSlots.map((slot, i) => /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
31879
31913
  i > 0 && /* @__PURE__ */ jsx(
31880
31914
  Typography,
31881
31915
  {
@@ -33880,7 +33914,7 @@ var init_MapView = __esm({
33880
33914
  shadowSize: [41, 41]
33881
33915
  });
33882
33916
  L.Marker.prototype.options.icon = defaultIcon;
33883
- const { useEffect: useEffect70, useRef: useRef67, useCallback: useCallback109, useState: useState109 } = React78__default;
33917
+ const { useEffect: useEffect70, useRef: useRef67, useCallback: useCallback109, useState: useState109 } = React79__default;
33884
33918
  const { Typography: Typography2 } = await Promise.resolve().then(() => (init_Typography(), Typography_exports));
33885
33919
  const { useEventBus: useEventBus2 } = await Promise.resolve().then(() => (init_useEventBus(), useEventBus_exports));
33886
33920
  function MapUpdater({ centerLat, centerLng, zoom }) {
@@ -34825,8 +34859,8 @@ function TableView({
34825
34859
  }) {
34826
34860
  const eventBus = useEventBus();
34827
34861
  const { t } = useTranslate();
34828
- const [visibleCount, setVisibleCount] = React78__default.useState(pageSize > 0 ? pageSize : Infinity);
34829
- const [localSelected, setLocalSelected] = React78__default.useState(/* @__PURE__ */ new Set());
34862
+ const [visibleCount, setVisibleCount] = React79__default.useState(pageSize > 0 ? pageSize : Infinity);
34863
+ const [localSelected, setLocalSelected] = React79__default.useState(/* @__PURE__ */ new Set());
34830
34864
  const colDefs = (Array.isArray(columns) ? columns : void 0) ?? (Array.isArray(fields) ? fields : void 0) ?? [];
34831
34865
  const actionDefs = Array.isArray(itemActions) ? itemActions : [];
34832
34866
  const allDataRaw = Array.isArray(entity) ? entity : entity ? [entity] : [];
@@ -34847,7 +34881,7 @@ function TableView({
34847
34881
  const hasMore = pageSize > 0 && visibleCount < ordered2.length;
34848
34882
  const hasRenderProp = typeof children === "function";
34849
34883
  const idField = dndItemIdField ?? "id";
34850
- React78__default.useEffect(() => {
34884
+ React79__default.useEffect(() => {
34851
34885
  tableViewLog.debug("render", {
34852
34886
  rowCount: data.length,
34853
34887
  colCount: colDefs.length,
@@ -34897,7 +34931,7 @@ function TableView({
34897
34931
  };
34898
34932
  eventBus.emit(`UI:${rowClickEvent}`, payload);
34899
34933
  };
34900
- const colFloors = React78__default.useMemo(
34934
+ const colFloors = React79__default.useMemo(
34901
34935
  () => colDefs.map((col) => {
34902
34936
  const longest = data.reduce((widest, row) => {
34903
34937
  const cell = formatCell(asFieldValue(getNestedValue(row, col.field ?? col.key)), col.format);
@@ -35040,12 +35074,12 @@ function TableView({
35040
35074
  ]
35041
35075
  }
35042
35076
  );
35043
- return dnd.isZone ? /* @__PURE__ */ jsx(dnd.SortableItem, { id: row[idField] ?? id, children: rowInner }, id) : /* @__PURE__ */ jsx(React78__default.Fragment, { children: rowInner }, id);
35077
+ return dnd.isZone ? /* @__PURE__ */ jsx(dnd.SortableItem, { id: row[idField] ?? id, children: rowInner }, id) : /* @__PURE__ */ jsx(React79__default.Fragment, { children: rowInner }, id);
35044
35078
  };
35045
35079
  const items = Array.from(data);
35046
35080
  const groups = groupBy ? groupData2(items, groupBy) : [{ label: "", items }];
35047
35081
  let runningIndex = 0;
35048
- const body = /* @__PURE__ */ jsx(Box, { role: "rowgroup", children: groups.map((group, gi) => /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
35082
+ const body = /* @__PURE__ */ jsx(Box, { role: "rowgroup", children: groups.map((group, gi) => /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
35049
35083
  group.label && /* @__PURE__ */ jsx(Divider, { label: group.label, className: gi > 0 ? "mt-3" : "mt-0" }),
35050
35084
  group.items.map((row) => renderRow(row, runningIndex++))
35051
35085
  ] }, gi)) });
@@ -36414,7 +36448,7 @@ var init_StepFlow = __esm({
36414
36448
  className
36415
36449
  }) => {
36416
36450
  if (orientation === "vertical") {
36417
- return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(React78__default.Fragment, { children: /* @__PURE__ */ jsxs(HStack, { gap: "md", align: "start", className: "w-full", children: [
36451
+ return /* @__PURE__ */ jsx(VStack, { gap: "none", className: cn("w-full", className), children: steps.map((step, index) => /* @__PURE__ */ jsx(React79__default.Fragment, { children: /* @__PURE__ */ jsxs(HStack, { gap: "md", align: "start", className: "w-full", children: [
36418
36452
  /* @__PURE__ */ jsxs(VStack, { gap: "none", align: "center", children: [
36419
36453
  /* @__PURE__ */ jsx(StepCircle, { step, index }),
36420
36454
  showConnectors && index < steps.length - 1 && /* @__PURE__ */ jsx(Box, { className: "w-px h-8 bg-border" })
@@ -36425,7 +36459,7 @@ var init_StepFlow = __esm({
36425
36459
  ] })
36426
36460
  ] }) }, index)) });
36427
36461
  }
36428
- 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(React78__default.Fragment, { children: [
36462
+ 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(React79__default.Fragment, { children: [
36429
36463
  /* @__PURE__ */ jsxs(VStack, { gap: "sm", align: "center", className: "flex-1 w-full md:w-auto", children: [
36430
36464
  /* @__PURE__ */ jsx(StepCircle, { step, index }),
36431
36465
  /* @__PURE__ */ jsx(Typography, { variant: "h4", className: "text-center", children: step.title }),
@@ -37415,7 +37449,7 @@ var init_LikertScale = __esm({
37415
37449
  md: "text-base",
37416
37450
  lg: "text-lg"
37417
37451
  };
37418
- LikertScale = React78__default.forwardRef(
37452
+ LikertScale = React79__default.forwardRef(
37419
37453
  ({
37420
37454
  question,
37421
37455
  options = DEFAULT_LIKERT_OPTIONS,
@@ -37427,7 +37461,7 @@ var init_LikertScale = __esm({
37427
37461
  variant = "radios",
37428
37462
  className
37429
37463
  }, ref) => {
37430
- const groupId = React78__default.useId();
37464
+ const groupId = React79__default.useId();
37431
37465
  const eventBus = useEventBus();
37432
37466
  const handleSelect = useCallback(
37433
37467
  (next) => {
@@ -39850,7 +39884,7 @@ var init_DocBreadcrumb = __esm({
39850
39884
  "aria-label": t("aria.breadcrumb"),
39851
39885
  children: /* @__PURE__ */ jsx(HStack, { gap: "xs", align: "center", wrap: true, children: items.map((item, idx) => {
39852
39886
  const isLast = idx === items.length - 1;
39853
- return /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
39887
+ return /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
39854
39888
  idx > 0 && /* @__PURE__ */ jsx(
39855
39889
  Icon,
39856
39890
  {
@@ -40719,7 +40753,7 @@ var init_MiniStateMachine = __esm({
40719
40753
  const x = 2 + i * (NODE_W + GAP2 + ARROW_W + GAP2);
40720
40754
  const tc = transitionCounts[s.name] ?? 0;
40721
40755
  const role = getStateRole(s.name, s.isInitial ?? void 0, s.isTerminal ?? void 0, tc, maxTC);
40722
- return /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
40756
+ return /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
40723
40757
  /* @__PURE__ */ jsx(
40724
40758
  AvlState,
40725
40759
  {
@@ -40924,7 +40958,7 @@ var init_PageHeader = __esm({
40924
40958
  info: "bg-info/10 text-info"
40925
40959
  };
40926
40960
  return /* @__PURE__ */ jsxs(Box, { className: cn("mb-6", className), children: [
40927
- 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(React78__default.Fragment, { children: [
40961
+ 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(React79__default.Fragment, { children: [
40928
40962
  idx > 0 && /* @__PURE__ */ jsx(Typography, { variant: "small", color: "muted", children: "/" }),
40929
40963
  crumb.href ? /* @__PURE__ */ jsx(
40930
40964
  "a",
@@ -41282,7 +41316,7 @@ var init_Section = __esm({
41282
41316
  as: Component = "section"
41283
41317
  }) => {
41284
41318
  const hasHeader = title || description || action;
41285
- return React78__default.createElement(
41319
+ return React79__default.createElement(
41286
41320
  Component,
41287
41321
  {
41288
41322
  className: cn(
@@ -41656,7 +41690,7 @@ var init_WizardContainer = __esm({
41656
41690
  const isCompleted = index < currentStep;
41657
41691
  const stepKey = step.id ?? step.tabId ?? `step-${index}`;
41658
41692
  const stepTitle = step.title ?? step.name ?? `Step ${index + 1}`;
41659
- return /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
41693
+ return /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
41660
41694
  /* @__PURE__ */ jsx(
41661
41695
  Button,
41662
41696
  {
@@ -43443,7 +43477,7 @@ var init_ImportPreviewTree = __esm({
43443
43477
  const renderUnit = (unit, childrenByParent, depth) => {
43444
43478
  const summary = fieldSummary(unit);
43445
43479
  const children = childrenByParent.get(unit.ref) ?? [];
43446
- return /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
43480
+ return /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
43447
43481
  /* @__PURE__ */ jsxs(
43448
43482
  Box,
43449
43483
  {
@@ -43540,7 +43574,7 @@ var init_ImportProgress = __esm({
43540
43574
  PIPELINE.map((key, index) => {
43541
43575
  const isComplete = index < currentIndex;
43542
43576
  const isActive = index === currentIndex;
43543
- return /* @__PURE__ */ jsxs(React78__default.Fragment, { children: [
43577
+ return /* @__PURE__ */ jsxs(React79__default.Fragment, { children: [
43544
43578
  index > 0 ? /* @__PURE__ */ jsx(Box, { className: "h-px w-4 bg-border" }) : null,
43545
43579
  /* @__PURE__ */ jsxs(Box, { className: "flex items-center gap-1", "data-testid": `import-progress-step-${key}`, children: [
43546
43580
  /* @__PURE__ */ jsx(
@@ -44710,7 +44744,7 @@ var init_DetailPanel = __esm({
44710
44744
  }) => {
44711
44745
  const eventBus = useEventBus();
44712
44746
  const { t } = useTranslate();
44713
- const [titleDraft, setTitleDraft] = React78__default.useState(null);
44747
+ const [titleDraft, setTitleDraft] = React79__default.useState(null);
44714
44748
  const isFieldDefArray = (arr) => {
44715
44749
  if (!arr || arr.length === 0) return false;
44716
44750
  const first = arr[0];
@@ -45176,7 +45210,7 @@ var init_SplitPane = __esm({
45176
45210
  /* @__PURE__ */ jsx(
45177
45211
  "div",
45178
45212
  {
45179
- className: cn("overflow-auto", leftClassName),
45213
+ className: cn("flex flex-col overflow-auto", leftClassName),
45180
45214
  style: {
45181
45215
  [isHorizontal ? "width" : "height"]: `${ratio}%`,
45182
45216
  flexShrink: 0
@@ -45194,7 +45228,7 @@ var init_SplitPane = __esm({
45194
45228
  )
45195
45229
  }
45196
45230
  ),
45197
- /* @__PURE__ */ jsx("div", { className: cn("flex-1 overflow-auto", rightClassName), children: right })
45231
+ /* @__PURE__ */ jsx("div", { className: cn("flex flex-col flex-1 min-h-0 min-w-0 overflow-auto", rightClassName), children: right })
45198
45232
  ]
45199
45233
  }
45200
45234
  );
@@ -45240,7 +45274,7 @@ var init_DockLayout = __esm({
45240
45274
  const showBottomPanel = Boolean(bottomPanel) && !bottomPanelCollapsed;
45241
45275
  const showSecondarySidebar = Boolean(secondarySidebar) && !secondarySidebarCollapsed;
45242
45276
  const centerRow = /* @__PURE__ */ jsxs(HStack, { gap: "none", className: "flex-1 min-h-0 min-w-0", children: [
45243
- /* @__PURE__ */ jsx(Box, { className: cn("flex-1 min-w-0 h-full overflow-auto", mainClassName), children: main }),
45277
+ /* @__PURE__ */ jsx(Box, { className: cn("flex-1 min-w-0 min-h-0 overflow-auto", mainClassName), children: main }),
45244
45278
  showSecondarySidebar && /* @__PURE__ */ jsx(
45245
45279
  Box,
45246
45280
  {
@@ -45271,7 +45305,7 @@ var init_DockLayout = __esm({
45271
45305
  Box,
45272
45306
  {
45273
45307
  className: cn(
45274
- "flex-shrink-0 h-full overflow-auto border-r border-border",
45308
+ "flex-shrink-0 min-h-0 overflow-auto border-r border-border",
45275
45309
  railClassName
45276
45310
  ),
45277
45311
  style: { width: railWidth },
@@ -45320,7 +45354,7 @@ var init_DockLayout = __esm({
45320
45354
  }
45321
45355
  });
45322
45356
  function extractTitle(children) {
45323
- if (!React78__default.isValidElement(children)) return void 0;
45357
+ if (!React79__default.isValidElement(children)) return void 0;
45324
45358
  const props = children.props;
45325
45359
  if (typeof props.title === "string") {
45326
45360
  return props.title;
@@ -45682,7 +45716,7 @@ var init_Form = __esm({
45682
45716
  const isSchemaEntity = isOrbitalEntitySchema(entity);
45683
45717
  const resolvedEntity = isSchemaEntity ? entity : void 0;
45684
45718
  const entityName = typeof entity === "string" ? entity : resolvedEntity?.name;
45685
- const normalizedInitialData = React78__default.useMemo(() => {
45719
+ const normalizedInitialData = React79__default.useMemo(() => {
45686
45720
  const entityRowAsInitial = isPlainEntityRow(entity) ? entity : void 0;
45687
45721
  const callerInitial = initialData !== null && typeof initialData === "object" && !Array.isArray(initialData) ? initialData : {};
45688
45722
  const merged = entityRowAsInitial !== void 0 ? { ...entityRowAsInitial, ...callerInitial } : callerInitial;
@@ -45701,7 +45735,7 @@ var init_Form = __esm({
45701
45735
  }
45702
45736
  return normalized;
45703
45737
  }, [entity, initialData]);
45704
- const entityDerivedFields = React78__default.useMemo(() => {
45738
+ const entityDerivedFields = React79__default.useMemo(() => {
45705
45739
  if (fields && fields.length > 0) return void 0;
45706
45740
  if (!resolvedEntity) return void 0;
45707
45741
  return resolvedEntity.fields.map(
@@ -45722,16 +45756,16 @@ var init_Form = __esm({
45722
45756
  const conditionalFields = typeof conditionalFieldsRaw === "boolean" ? {} : conditionalFieldsRaw;
45723
45757
  const hiddenCalculations = typeof hiddenCalculationsRaw === "boolean" ? [] : hiddenCalculationsRaw;
45724
45758
  const violationTriggers = typeof violationTriggersRaw === "boolean" ? [] : violationTriggersRaw;
45725
- const [formData, setFormData] = React78__default.useState(
45759
+ const [formData, setFormData] = React79__default.useState(
45726
45760
  normalizedInitialData
45727
45761
  );
45728
- const [collapsedSections, setCollapsedSections] = React78__default.useState(
45762
+ const [collapsedSections, setCollapsedSections] = React79__default.useState(
45729
45763
  /* @__PURE__ */ new Set()
45730
45764
  );
45731
- const [submitError, setSubmitError] = React78__default.useState(null);
45732
- const formRef = React78__default.useRef(null);
45765
+ const [submitError, setSubmitError] = React79__default.useState(null);
45766
+ const formRef = React79__default.useRef(null);
45733
45767
  const formMode = props.mode;
45734
- const mountedRef = React78__default.useRef(false);
45768
+ const mountedRef = React79__default.useRef(false);
45735
45769
  if (!mountedRef.current) {
45736
45770
  mountedRef.current = true;
45737
45771
  debug("forms", "mount", {
@@ -45744,7 +45778,7 @@ var init_Form = __esm({
45744
45778
  });
45745
45779
  }
45746
45780
  const shouldShowCancel = showCancel ?? (fields && fields.length > 0);
45747
- const evalContext = React78__default.useMemo(
45781
+ const evalContext = React79__default.useMemo(
45748
45782
  () => ({
45749
45783
  formValues: formData,
45750
45784
  globalVariables: externalContext?.globalVariables ?? {},
@@ -45753,7 +45787,7 @@ var init_Form = __esm({
45753
45787
  }),
45754
45788
  [formData, externalContext]
45755
45789
  );
45756
- React78__default.useEffect(() => {
45790
+ React79__default.useEffect(() => {
45757
45791
  debug("forms", "initialData-sync", {
45758
45792
  mode: formMode,
45759
45793
  normalizedInitialData,
@@ -45764,7 +45798,7 @@ var init_Form = __esm({
45764
45798
  setFormData(normalizedInitialData);
45765
45799
  }
45766
45800
  }, [normalizedInitialData]);
45767
- const processCalculations = React78__default.useCallback(
45801
+ const processCalculations = React79__default.useCallback(
45768
45802
  (changedFieldId, newFormData) => {
45769
45803
  if (!hiddenCalculations.length) return;
45770
45804
  const context = {
@@ -45789,7 +45823,7 @@ var init_Form = __esm({
45789
45823
  },
45790
45824
  [hiddenCalculations, externalContext, eventBus]
45791
45825
  );
45792
- const checkViolations = React78__default.useCallback(
45826
+ const checkViolations = React79__default.useCallback(
45793
45827
  (changedFieldId, newFormData) => {
45794
45828
  if (!violationTriggers.length) return;
45795
45829
  const context = {
@@ -45827,7 +45861,7 @@ var init_Form = __esm({
45827
45861
  processCalculations(name, newFormData);
45828
45862
  checkViolations(name, newFormData);
45829
45863
  };
45830
- const isFieldVisible = React78__default.useCallback(
45864
+ const isFieldVisible = React79__default.useCallback(
45831
45865
  (fieldName2) => {
45832
45866
  const condition = conditionalFields[fieldName2];
45833
45867
  if (!condition) return true;
@@ -45835,7 +45869,7 @@ var init_Form = __esm({
45835
45869
  },
45836
45870
  [conditionalFields, evalContext]
45837
45871
  );
45838
- const isSectionVisible = React78__default.useCallback(
45872
+ const isSectionVisible = React79__default.useCallback(
45839
45873
  (section) => {
45840
45874
  if (!section.condition) return true;
45841
45875
  return Boolean(evaluateFormExpression(section.condition, evalContext));
@@ -45911,7 +45945,7 @@ var init_Form = __esm({
45911
45945
  eventBus.emit(`UI:${onCancel}`);
45912
45946
  }
45913
45947
  };
45914
- const renderField = React78__default.useCallback(
45948
+ const renderField = React79__default.useCallback(
45915
45949
  (field) => {
45916
45950
  const fieldName2 = field.name || field.field;
45917
45951
  if (!fieldName2) return null;
@@ -45933,7 +45967,7 @@ var init_Form = __esm({
45933
45967
  [formData, isFieldVisible, relationsData, relationsLoading, isLoading]
45934
45968
  );
45935
45969
  const effectiveFields = entityDerivedFields ?? fields;
45936
- const normalizedFields = React78__default.useMemo(() => {
45970
+ const normalizedFields = React79__default.useMemo(() => {
45937
45971
  if (!effectiveFields || effectiveFields.length === 0) return [];
45938
45972
  return effectiveFields.map((field) => {
45939
45973
  if (typeof field === "string") {
@@ -45968,7 +46002,7 @@ var init_Form = __esm({
45968
46002
  };
45969
46003
  });
45970
46004
  }, [effectiveFields, resolvedEntity, fieldOverrides]);
45971
- const schemaFields = React78__default.useMemo(() => {
46005
+ const schemaFields = React79__default.useMemo(() => {
45972
46006
  if (normalizedFields.length === 0) return null;
45973
46007
  if (isDebugEnabled()) {
45974
46008
  debugGroup(`Form: ${entityName || "unknown"}`);
@@ -45978,7 +46012,7 @@ var init_Form = __esm({
45978
46012
  }
45979
46013
  return normalizedFields.map(renderField).filter(Boolean);
45980
46014
  }, [normalizedFields, renderField, entityName, conditionalFields]);
45981
- const sectionElements = React78__default.useMemo(() => {
46015
+ const sectionElements = React79__default.useMemo(() => {
45982
46016
  if (!sections || sections.length === 0) return null;
45983
46017
  return sections.map((section) => {
45984
46018
  if (!isSectionVisible(section)) {
@@ -46814,7 +46848,7 @@ var init_List = __esm({
46814
46848
  if (entity && typeof entity === "object" && "id" in entity) return [entity];
46815
46849
  return [];
46816
46850
  }, [entity]);
46817
- const getItemActions = React78__default.useCallback(
46851
+ const getItemActions = React79__default.useCallback(
46818
46852
  (item) => {
46819
46853
  if (!itemActions) return [];
46820
46854
  if (typeof itemActions === "function") {
@@ -47296,7 +47330,7 @@ var init_MediaGallery = __esm({
47296
47330
  [selectable, selectedItems, selectionEvent, eventBus]
47297
47331
  );
47298
47332
  const entityData = Array.isArray(entity) ? entity : [];
47299
- const items = React78__default.useMemo(() => {
47333
+ const items = React79__default.useMemo(() => {
47300
47334
  if (propItems && propItems.length > 0) return propItems;
47301
47335
  if (entityData.length === 0) return [];
47302
47336
  return entityData.map((record, idx) => {
@@ -47461,7 +47495,7 @@ var init_MediaGallery = __esm({
47461
47495
  }
47462
47496
  });
47463
47497
  function extractTitle2(children) {
47464
- if (!React78__default.isValidElement(children)) return void 0;
47498
+ if (!React79__default.isValidElement(children)) return void 0;
47465
47499
  const props = children.props;
47466
47500
  if (typeof props.title === "string") {
47467
47501
  return props.title;
@@ -47716,7 +47750,7 @@ var init_debugRegistry = __esm({
47716
47750
  }
47717
47751
  });
47718
47752
  function useDebugData() {
47719
- const [data, setData] = React78.useState(() => ({
47753
+ const [data, setData] = React79.useState(() => ({
47720
47754
  traits: [],
47721
47755
  ticks: [],
47722
47756
  guards: [],
@@ -47730,7 +47764,7 @@ function useDebugData() {
47730
47764
  },
47731
47765
  lastUpdate: Date.now()
47732
47766
  }));
47733
- React78.useEffect(() => {
47767
+ React79.useEffect(() => {
47734
47768
  const updateData = () => {
47735
47769
  setData({
47736
47770
  traits: getAllTraits(),
@@ -47839,12 +47873,12 @@ function layoutGraph(states, transitions, initialState, width, height) {
47839
47873
  return positions;
47840
47874
  }
47841
47875
  function WalkMinimap() {
47842
- const [walkStep, setWalkStep] = React78.useState(null);
47843
- const [traits2, setTraits] = React78.useState([]);
47844
- const [coveredEdges, setCoveredEdges] = React78.useState([]);
47845
- const [completedTraits, setCompletedTraits] = React78.useState(/* @__PURE__ */ new Set());
47846
- const prevTraitRef = React78.useRef(null);
47847
- React78.useEffect(() => {
47876
+ const [walkStep, setWalkStep] = React79.useState(null);
47877
+ const [traits2, setTraits] = React79.useState([]);
47878
+ const [coveredEdges, setCoveredEdges] = React79.useState([]);
47879
+ const [completedTraits, setCompletedTraits] = React79.useState(/* @__PURE__ */ new Set());
47880
+ const prevTraitRef = React79.useRef(null);
47881
+ React79.useEffect(() => {
47848
47882
  const interval = setInterval(() => {
47849
47883
  const w = window;
47850
47884
  const step = w.__orbitalWalkStep;
@@ -48280,15 +48314,15 @@ var init_EntitiesTab = __esm({
48280
48314
  });
48281
48315
  function EventFlowTab({ events: events2 }) {
48282
48316
  const { t } = useTranslate();
48283
- const [filter, setFilter] = React78.useState("all");
48284
- const containerRef = React78.useRef(null);
48285
- const [autoScroll, setAutoScroll] = React78.useState(true);
48286
- React78.useEffect(() => {
48317
+ const [filter, setFilter] = React79.useState("all");
48318
+ const containerRef = React79.useRef(null);
48319
+ const [autoScroll, setAutoScroll] = React79.useState(true);
48320
+ React79.useEffect(() => {
48287
48321
  if (autoScroll && containerRef.current) {
48288
48322
  containerRef.current.scrollTop = containerRef.current.scrollHeight;
48289
48323
  }
48290
48324
  }, [events2.length, autoScroll]);
48291
- const filteredEvents = React78.useMemo(() => {
48325
+ const filteredEvents = React79.useMemo(() => {
48292
48326
  if (filter === "all") return events2;
48293
48327
  return events2.filter((e) => e.type === filter);
48294
48328
  }, [events2, filter]);
@@ -48404,7 +48438,7 @@ var init_EventFlowTab = __esm({
48404
48438
  });
48405
48439
  function GuardsPanel({ guards }) {
48406
48440
  const { t } = useTranslate();
48407
- const [filter, setFilter] = React78.useState("all");
48441
+ const [filter, setFilter] = React79.useState("all");
48408
48442
  if (guards.length === 0) {
48409
48443
  return /* @__PURE__ */ jsx(
48410
48444
  EmptyState,
@@ -48417,7 +48451,7 @@ function GuardsPanel({ guards }) {
48417
48451
  }
48418
48452
  const passedCount = guards.filter((g) => g.result).length;
48419
48453
  const failedCount = guards.length - passedCount;
48420
- const filteredGuards = React78.useMemo(() => {
48454
+ const filteredGuards = React79.useMemo(() => {
48421
48455
  if (filter === "all") return guards;
48422
48456
  if (filter === "passed") return guards.filter((g) => g.result);
48423
48457
  return guards.filter((g) => !g.result);
@@ -48580,10 +48614,10 @@ function EffectBadge({ effect }) {
48580
48614
  }
48581
48615
  function TransitionTimeline({ transitions }) {
48582
48616
  const { t } = useTranslate();
48583
- const containerRef = React78.useRef(null);
48584
- const [autoScroll, setAutoScroll] = React78.useState(true);
48585
- const [expandedId, setExpandedId] = React78.useState(null);
48586
- React78.useEffect(() => {
48617
+ const containerRef = React79.useRef(null);
48618
+ const [autoScroll, setAutoScroll] = React79.useState(true);
48619
+ const [expandedId, setExpandedId] = React79.useState(null);
48620
+ React79.useEffect(() => {
48587
48621
  if (autoScroll && containerRef.current) {
48588
48622
  containerRef.current.scrollTop = containerRef.current.scrollHeight;
48589
48623
  }
@@ -48863,9 +48897,9 @@ function getAllEvents(traits2) {
48863
48897
  function EventDispatcherTab({ traits: traits2, schema }) {
48864
48898
  const eventBus = useEventBus();
48865
48899
  const { t } = useTranslate();
48866
- const [log19, setLog] = React78.useState([]);
48867
- const prevStatesRef = React78.useRef(/* @__PURE__ */ new Map());
48868
- React78.useEffect(() => {
48900
+ const [log19, setLog] = React79.useState([]);
48901
+ const prevStatesRef = React79.useRef(/* @__PURE__ */ new Map());
48902
+ React79.useEffect(() => {
48869
48903
  for (const trait of traits2) {
48870
48904
  const prev = prevStatesRef.current.get(trait.id);
48871
48905
  if (prev && prev !== trait.currentState) {
@@ -49034,10 +49068,10 @@ function VerifyModePanel({
49034
49068
  localCount
49035
49069
  }) {
49036
49070
  const { t } = useTranslate();
49037
- const [expanded, setExpanded] = React78.useState(true);
49038
- const scrollRef = React78.useRef(null);
49039
- const prevCountRef = React78.useRef(0);
49040
- React78.useEffect(() => {
49071
+ const [expanded, setExpanded] = React79.useState(true);
49072
+ const scrollRef = React79.useRef(null);
49073
+ const prevCountRef = React79.useRef(0);
49074
+ React79.useEffect(() => {
49041
49075
  if (expanded && transitions.length > prevCountRef.current && scrollRef.current) {
49042
49076
  scrollRef.current.scrollTop = scrollRef.current.scrollHeight;
49043
49077
  }
@@ -49094,10 +49128,10 @@ function RuntimeDebugger({
49094
49128
  schema
49095
49129
  }) {
49096
49130
  const { t } = useTranslate();
49097
- const [isCollapsed, setIsCollapsed] = React78.useState(mode === "verify" ? true : defaultCollapsed);
49098
- const [isVisible, setIsVisible] = React78.useState(mode === "inline" || mode === "verify" || isDebugEnabled2());
49131
+ const [isCollapsed, setIsCollapsed] = React79.useState(mode === "verify" ? true : defaultCollapsed);
49132
+ const [isVisible, setIsVisible] = React79.useState(mode === "inline" || mode === "verify" || isDebugEnabled2());
49099
49133
  const debugData = useDebugData();
49100
- React78.useEffect(() => {
49134
+ React79.useEffect(() => {
49101
49135
  if (mode === "inline") return;
49102
49136
  return onDebugToggle((enabled) => {
49103
49137
  setIsVisible(enabled);
@@ -49106,7 +49140,7 @@ function RuntimeDebugger({
49106
49140
  }
49107
49141
  });
49108
49142
  }, [mode]);
49109
- React78.useEffect(() => {
49143
+ React79.useEffect(() => {
49110
49144
  if (mode === "inline") return;
49111
49145
  const handleKeyDown = (e) => {
49112
49146
  if (e.key === "`" && isVisible) {
@@ -49537,7 +49571,7 @@ var init_StatCard = __esm({
49537
49571
  const labelToUse = propLabel ?? propTitle;
49538
49572
  const eventBus = useEventBus();
49539
49573
  const { t } = useTranslate();
49540
- const handleActionClick = React78__default.useCallback(() => {
49574
+ const handleActionClick = React79__default.useCallback(() => {
49541
49575
  if (action?.event) {
49542
49576
  eventBus.emit(`UI:${action.event}`, {});
49543
49577
  }
@@ -49548,7 +49582,7 @@ var init_StatCard = __esm({
49548
49582
  const data = Array.isArray(entity) ? entity : entity ? [entity] : [];
49549
49583
  const isLoading = externalLoading ?? false;
49550
49584
  const error = externalError;
49551
- const computeMetricValue = React78__default.useCallback(
49585
+ const computeMetricValue = React79__default.useCallback(
49552
49586
  (metric, items) => {
49553
49587
  if (metric.value !== void 0) {
49554
49588
  return metric.value;
@@ -49587,7 +49621,7 @@ var init_StatCard = __esm({
49587
49621
  },
49588
49622
  []
49589
49623
  );
49590
- const schemaStats = React78__default.useMemo(() => {
49624
+ const schemaStats = React79__default.useMemo(() => {
49591
49625
  if (!metrics || metrics.length === 0) return null;
49592
49626
  return metrics.map((metric) => ({
49593
49627
  label: metric.label,
@@ -49595,7 +49629,7 @@ var init_StatCard = __esm({
49595
49629
  format: metric.format
49596
49630
  }));
49597
49631
  }, [metrics, data, computeMetricValue]);
49598
- const calculatedTrend = React78__default.useMemo(() => {
49632
+ const calculatedTrend = React79__default.useMemo(() => {
49599
49633
  if (manualTrend !== void 0) return manualTrend;
49600
49634
  if (previousValue === void 0 || currentValue2 === void 0)
49601
49635
  return void 0;
@@ -50235,8 +50269,8 @@ var init_SubagentTracePanel = __esm({
50235
50269
  ] });
50236
50270
  };
50237
50271
  InlineActivityStream = ({ activities, autoScroll = true, className }) => {
50238
- const endRef = React78__default.useRef(null);
50239
- React78__default.useEffect(() => {
50272
+ const endRef = React79__default.useRef(null);
50273
+ React79__default.useEffect(() => {
50240
50274
  if (!autoScroll) return;
50241
50275
  endRef.current?.scrollIntoView({ behavior: "smooth", block: "end" });
50242
50276
  }, [activities.length, autoScroll]);
@@ -50330,7 +50364,7 @@ var init_SubagentTracePanel = __esm({
50330
50364
  };
50331
50365
  SubagentRichCard = ({ subagent }) => {
50332
50366
  const { t } = useTranslate();
50333
- const activities = React78__default.useMemo(
50367
+ const activities = React79__default.useMemo(
50334
50368
  () => subagentMessagesToActivities(subagent.messages),
50335
50369
  [subagent.messages]
50336
50370
  );
@@ -50407,8 +50441,8 @@ var init_SubagentTracePanel = __esm({
50407
50441
  ] });
50408
50442
  };
50409
50443
  CoordinatorConversation = ({ messages, autoScroll = true, className }) => {
50410
- const endRef = React78__default.useRef(null);
50411
- React78__default.useEffect(() => {
50444
+ const endRef = React79__default.useRef(null);
50445
+ React79__default.useEffect(() => {
50412
50446
  if (!autoScroll) return;
50413
50447
  endRef.current?.scrollIntoView({ behavior: "smooth", block: "end" });
50414
50448
  }, [messages.length, autoScroll]);
@@ -50843,7 +50877,7 @@ var init_Timeline = __esm({
50843
50877
  }) => {
50844
50878
  const { t } = useTranslate();
50845
50879
  const entityData = entity ?? [];
50846
- const items = React78__default.useMemo(() => {
50880
+ const items = React79__default.useMemo(() => {
50847
50881
  if (propItems) return propItems;
50848
50882
  if (entityData.length === 0) return [];
50849
50883
  return entityData.map((record, idx) => {
@@ -50945,7 +50979,7 @@ var init_Timeline = __esm({
50945
50979
  }
50946
50980
  });
50947
50981
  function extractToastProps(children) {
50948
- if (!React78__default.isValidElement(children)) {
50982
+ if (!React79__default.isValidElement(children)) {
50949
50983
  if (typeof children === "string") {
50950
50984
  return { message: children };
50951
50985
  }
@@ -50987,7 +51021,7 @@ var init_ToastSlot = __esm({
50987
51021
  eventBus.emit(`${prefix}CLOSE`);
50988
51022
  };
50989
51023
  if (!isVisible) return null;
50990
- const isCustomContent = React78__default.isValidElement(children) && !message;
51024
+ const isCustomContent = React79__default.isValidElement(children) && !message;
50991
51025
  return /* @__PURE__ */ jsx(Box, { className: "fixed bottom-4 right-4 z-50", children: isCustomContent ? children : /* @__PURE__ */ jsx(
50992
51026
  Toast,
50993
51027
  {
@@ -51055,6 +51089,7 @@ var init_component_registry_generated = __esm({
51055
51089
  init_ChoiceButton();
51056
51090
  init_CodeBlock();
51057
51091
  init_CodeRunnerPanel();
51092
+ init_CommandPalette();
51058
51093
  init_CommunityLinks();
51059
51094
  init_ConditionalWrapper();
51060
51095
  init_ConfettiEffect();
@@ -51329,6 +51364,7 @@ var init_component_registry_generated = __esm({
51329
51364
  "ChoiceButton": ChoiceButton,
51330
51365
  "CodeBlock": CodeBlock,
51331
51366
  "CodeRunnerPanel": CodeRunnerPanel,
51367
+ "CommandPalette": CommandPalette,
51332
51368
  "CommunityLinks": CommunityLinks,
51333
51369
  "ConditionalWrapper": ConditionalWrapper,
51334
51370
  "ConfettiEffect": ConfettiEffect,
@@ -51577,7 +51613,7 @@ function SuspenseConfigProvider({
51577
51613
  config,
51578
51614
  children
51579
51615
  }) {
51580
- return React78__default.createElement(
51616
+ return React79__default.createElement(
51581
51617
  SuspenseConfigContext.Provider,
51582
51618
  { value: config },
51583
51619
  children
@@ -51625,7 +51661,7 @@ function enrichFormFields(fields, entityDef) {
51625
51661
  }
51626
51662
  return { name: field, label: humanizeFieldName(field) };
51627
51663
  }
51628
- if (field && typeof field === "object" && !Array.isArray(field) && !React78__default.isValidElement(field) && !(field instanceof Date)) {
51664
+ if (field && typeof field === "object" && !Array.isArray(field) && !React79__default.isValidElement(field) && !(field instanceof Date)) {
51629
51665
  const obj = field;
51630
51666
  const fieldName2 = typeof obj.name === "string" ? obj.name : typeof obj.field === "string" ? obj.field : void 0;
51631
51667
  if (!fieldName2) return field;
@@ -51678,7 +51714,7 @@ function enrichDetailFields(fields, entityDef) {
51678
51714
  const meta = metaFor(field);
51679
51715
  return meta ? { key: field, ...meta } : field;
51680
51716
  }
51681
- if (field && typeof field === "object" && !Array.isArray(field) && !React78__default.isValidElement(field) && !(field instanceof Date)) {
51717
+ if (field && typeof field === "object" && !Array.isArray(field) && !React79__default.isValidElement(field) && !(field instanceof Date)) {
51682
51718
  const obj = field;
51683
51719
  const fieldName2 = typeof obj.key === "string" ? obj.key : typeof obj.name === "string" ? obj.name : void 0;
51684
51720
  if (!fieldName2 || obj.type) return field;
@@ -52137,7 +52173,7 @@ function renderPatternChildren(children, onDismiss, parentId = "root", parentPat
52137
52173
  const key = `${parentId}-${index}-trait:${traitName}`;
52138
52174
  return /* @__PURE__ */ jsx(TraitFrame, { traitName }, key);
52139
52175
  }
52140
- return /* @__PURE__ */ jsx(React78__default.Fragment, { children: child }, `${parentId}-${index}`);
52176
+ return /* @__PURE__ */ jsx(React79__default.Fragment, { children: child }, `${parentId}-${index}`);
52141
52177
  }
52142
52178
  if (!child || typeof child !== "object") return null;
52143
52179
  const childId = `${parentId}-${index}`;
@@ -52194,7 +52230,7 @@ function isPatternConfig(value) {
52194
52230
  if (value === null || value === void 0) return false;
52195
52231
  if (typeof value !== "object") return false;
52196
52232
  if (Array.isArray(value)) return false;
52197
- if (React78__default.isValidElement(value)) return false;
52233
+ if (React79__default.isValidElement(value)) return false;
52198
52234
  if (value instanceof Date) return false;
52199
52235
  if (typeof value === "function") return false;
52200
52236
  const record = value;
@@ -52207,9 +52243,9 @@ function renderPatternValue(value) {
52207
52243
  if (typeof value === "string") return renderPatternChildren(value, () => {
52208
52244
  });
52209
52245
  if (value instanceof Date) return value.toLocaleString();
52210
- if (React78__default.isValidElement(value)) return value;
52246
+ if (React79__default.isValidElement(value)) return value;
52211
52247
  if (Array.isArray(value)) {
52212
- return value.map((item, index) => /* @__PURE__ */ jsx(React78__default.Fragment, { children: renderPatternValue(item) }, index));
52248
+ return value.map((item, index) => /* @__PURE__ */ jsx(React79__default.Fragment, { children: renderPatternValue(item) }, index));
52213
52249
  }
52214
52250
  if (isPatternConfig(value)) {
52215
52251
  const { type, ...props } = value;
@@ -52219,7 +52255,7 @@ function renderPatternValue(value) {
52219
52255
  return null;
52220
52256
  }
52221
52257
  function isPlainConfigObject(value) {
52222
- if (React78__default.isValidElement(value)) return false;
52258
+ if (React79__default.isValidElement(value)) return false;
52223
52259
  if (value instanceof Date) return false;
52224
52260
  const proto = Object.getPrototypeOf(value);
52225
52261
  return proto === Object.prototype || proto === null;
@@ -52393,7 +52429,7 @@ function SlotContentRenderer({
52393
52429
  for (const slotKey of CONTENT_NODE_SLOTS) {
52394
52430
  const slotVal = restProps[slotKey];
52395
52431
  if (slotVal === void 0 || slotVal === null) continue;
52396
- if (React78__default.isValidElement(slotVal) || typeof slotVal === "string" || typeof slotVal === "number" || typeof slotVal === "boolean") continue;
52432
+ if (React79__default.isValidElement(slotVal) || typeof slotVal === "string" || typeof slotVal === "number" || typeof slotVal === "boolean") continue;
52397
52433
  const typelessChildren = !Array.isArray(slotVal) && typeof slotVal === "object" && !("type" in slotVal) && Array.isArray(slotVal.children) ? slotVal.children : void 0;
52398
52434
  if (typelessChildren !== void 0 || Array.isArray(slotVal) || typeof slotVal === "object" && "type" in slotVal) {
52399
52435
  nodeSlotOverrides[slotKey] = renderPatternChildren(
@@ -52447,7 +52483,7 @@ function SlotContentRenderer({
52447
52483
  const resolvedItems = Array.isArray(entityVal) && entityVal[0] !== "fn" ? entityVal : null;
52448
52484
  if (resolvedItems && resolvedItems.length > 0 && !finalProps.fields && !finalProps.columns) {
52449
52485
  const sample = resolvedItems[0];
52450
- if (sample && typeof sample === "object" && !Array.isArray(sample) && !React78__default.isValidElement(sample) && !(sample instanceof Date)) {
52486
+ if (sample && typeof sample === "object" && !Array.isArray(sample) && !React79__default.isValidElement(sample) && !(sample instanceof Date)) {
52451
52487
  const keys = Object.keys(sample).filter((k) => k !== "id" && k !== "_id");
52452
52488
  finalProps.fields = keys.map((k, i) => ({ name: k, variant: i === 0 ? "h4" : "body" }));
52453
52489
  }
@@ -53781,7 +53817,7 @@ function expressionEqual(a, b) {
53781
53817
  function isPlainSlotObject(value) {
53782
53818
  if (value === null || value === void 0 || typeof value !== "object") return false;
53783
53819
  if (Array.isArray(value)) return false;
53784
- if (React78__default.isValidElement(value)) return false;
53820
+ if (React79__default.isValidElement(value)) return false;
53785
53821
  if (value instanceof Date) return false;
53786
53822
  if (isRenderBindingMarker(value)) return false;
53787
53823
  return true;
@@ -53800,7 +53836,7 @@ function shareValue(prev, next) {
53800
53836
  return prev instanceof Date && next instanceof Date && prev.getTime() === next.getTime() ? { value: prev, equal: true } : { value: next, equal: false };
53801
53837
  }
53802
53838
  if (typeof prev === "function" || typeof next === "function") return { value: next, equal: false };
53803
- if (React78__default.isValidElement(prev) || React78__default.isValidElement(next)) return { value: next, equal: false };
53839
+ if (React79__default.isValidElement(prev) || React79__default.isValidElement(next)) return { value: next, equal: false };
53804
53840
  if (Array.isArray(prev) && Array.isArray(next)) {
53805
53841
  let equal = prev.length === next.length;
53806
53842
  const out = new Array(next.length);