@firecms/ui 3.0.0-tw4.2 → 3.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.umd.js CHANGED
@@ -36,17 +36,17 @@
36
36
  const ReactDOM__namespace = /* @__PURE__ */ _interopNamespaceDefault(ReactDOM);
37
37
  const TabsPrimitive__namespace = /* @__PURE__ */ _interopNamespaceDefault(TabsPrimitive);
38
38
  const focusedDisabled = "focus-visible:ring-0 focus-visible:ring-offset-0";
39
- const focusedInvisibleMixin = "focus:bg-opacity-70 focus:bg-surface-accent-100 focus:dark:bg-surface-800 focus:dark:bg-opacity-60 focus:bg-surface-accent-100/70 dark:focus:bg-surface-800/60";
40
- const focusedClasses = "z-30 outline-hidden outline-none ring-2 ring-primary ring-opacity-75 ring-primary/75 ring-offset-2 ring-offset-transparent ";
41
- const fieldBackgroundMixin = "bg-opacity-50 bg-surface-accent-200 bg-surface-accent-200/50 dark:bg-surface-800 dark:bg-opacity-60 dark:bg-surface-800/60";
42
- const fieldBackgroundInvisibleMixin = "bg-opacity-0 bg-surface-accent-100 dark:bg-surface-800 dark:bg-opacity-0 bg-surface-accent-200/0 dark:bg-surface-800/0";
43
- const fieldBackgroundDisabledMixin = "dark:bg-surface-800 bg-opacity-50 dark:bg-opacity-90 bg-surface-accent-200/50 dark:bg-surface-800/90";
44
- const fieldBackgroundHoverMixin = "hover:bg-opacity-70 dark:hover:bg-surface-700 dark:hover:bg-opacity-40 hover:bg-surface-accent-200/70 hover:dark:bg-surface-700/40";
45
- const defaultBorderMixin = "border-surface-200 border-opacity-40 dark:border-surface-700 dark:border-opacity-40 border-surface-200/40 dark:border-surface-700/40 ";
46
- const paperMixin = "bg-white rounded-md dark:bg-surface-950 border border-surface-200 border-opacity-40 dark:border-surface-700 dark:border-opacity-40 border-surface-200/40 dark:border-surface-700/40";
47
- const cardMixin = "bg-white dark:bg-surface-950 rounded-md border border-surface-200/40 dark:border-surface-700/40 m-1 -p-1";
48
- const cardClickableMixin = "hover:bg-surface-accent-100 dark:hover:bg-surface-accent-800 hover:ring-2 hover:ring-primary cursor-pointer hover:bg-primary/20 dark:hover:bg-primary/10 ";
49
- const cardSelectedMixin = "bg-primary-bg dark:bg-primary-bg bg-opacity-30 bg-primary-bg/30 dark:bg-opacity-10 dark:bg-primary-bg/10 ring-1 ring-primary ring-opacity-75 ring-primary/75 bg-primary/10 dark:bg-primary/10 ring-1 ring-primary/75";
39
+ const focusedInvisibleMixin = "focus:bg-opacity-70 focus:bg-surface-accent-100 focus:dark:bg-surface-800 focus:dark:bg-opacity-60";
40
+ const focusedClasses = "z-30 outline-none ring-2 ring-primary ring-opacity-75 ring-offset-2 ring-offset-transparent ";
41
+ const fieldBackgroundMixin = "bg-opacity-50 bg-surface-accent-200 dark:bg-surface-800 dark:bg-opacity-60";
42
+ const fieldBackgroundInvisibleMixin = "bg-opacity-0 bg-surface-accent-100 dark:bg-surface-800 dark:bg-opacity-0";
43
+ const fieldBackgroundDisabledMixin = "dark:bg-surface-800 bg-opacity-50 dark:bg-opacity-90";
44
+ const fieldBackgroundHoverMixin = "hover:bg-opacity-70 dark:hover:bg-surface-700 dark:hover:bg-opacity-40";
45
+ const defaultBorderMixin = "border-surface-200 border-opacity-40 dark:border-surface-700 dark:border-opacity-40";
46
+ const paperMixin = "bg-white rounded-md dark:bg-surface-950 border border-surface-200 border-opacity-40 dark:border-surface-700 dark:border-opacity-40";
47
+ const cardMixin = "bg-white border border-surface-200 border-opacity-40 dark:border-transparent rounded-md dark:bg-surface-950 dark:border-surface-700 dark:border-opacity-40";
48
+ const cardClickableMixin = "hover:bg-surface-accent-100 dark:hover:bg-surface-accent-800 hover:ring-2 hover:ring-primary cursor-pointer";
49
+ const cardSelectedMixin = "bg-primary-bg dark:bg-primary-bg bg-opacity-30 dark:bg-opacity-10 ring-1 ring-primary ring-opacity-75";
50
50
  function cls(...classes) {
51
51
  return tailwindMerge.twMerge(clsx.clsx(classes));
52
52
  }
@@ -752,7 +752,7 @@
752
752
  } else {
753
753
  onValueChange?.(!value);
754
754
  }
755
- }, className: cls(size === "smallest" ? "w-[34px] h-[18px] min-w-[34px] min-h-[18px]" : size === "small" ? "w-[38px] h-[22px] min-w-[38px] min-h-[22px]" : "w-[42px] h-[26px] min-w-[42px] min-h-[26px]", "outline-none outline-hidden rounded-full relative shadow-sm", value ? disabled ? "bg-white bg-opacity-54 bg-white/54 dark:bg-surface-accent-950 border-surface-accent-100 dark:border-surface-accent-700 ring-1 ring-surface-accent-200 dark:ring-surface-accent-700" : "ring-secondary ring-1 bg-secondary dark:bg-secondary" : "bg-white bg-opacity-54 bg-white/54 dark:bg-surface-accent-900 ring-1 ring-surface-accent-200 dark:ring-surface-accent-700", className), ...props, children: [
755
+ }, className: cls(size === "smallest" ? "w-[34px] h-[18px] min-w-[34px] min-h-[18px]" : size === "small" ? "w-[38px] h-[22px] min-w-[38px] min-h-[22px]" : "w-[42px] h-[26px] min-w-[42px] min-h-[26px]", "outline-none rounded-full relative shadow-sm", value ? disabled ? "bg-white bg-opacity-54 dark:bg-surface-accent-950 border-surface-accent-100 dark:border-surface-accent-700 ring-1 ring-surface-accent-200 dark:ring-surface-accent-700" : "ring-secondary ring-1 bg-secondary dark:bg-secondary" : "bg-white bg-opacity-54 dark:bg-surface-accent-900 ring-1 ring-surface-accent-200 dark:ring-surface-accent-700", className), ...props, children: [
756
756
  allowIndeterminate && (value === null || value === void 0) && /* @__PURE__ */ jsxRuntime.jsx("div", { className: cls("block rounded-full transition-transform duration-100 transform will-change-auto", disabled ? "bg-surface-accent-400 dark:bg-surface-accent-600" : "bg-surface-accent-400 dark:bg-surface-accent-600", {
757
757
  "w-[21px] h-[10px]": size === "medium" || size === "large",
758
758
  "w-[19px] h-[8px]": size === "small",
@@ -901,12 +901,12 @@
901
901
  "border border-red-500 bg-red-500 hover:bg-red-500 focus:ring-red-500 shadow hover:ring-1 hover:ring-red-600 text-white hover:text-white": t10,
902
902
  "border border-surface-accent-200 bg-surface-accent-200 hover:bg-surface-accent-300 focus:ring-surface-accent-400 shadow hover:ring-1 hover:ring-surface-accent-400 text-text-primary hover:text-text-primary dark:text-text-primary-dark hover:dark:text-text-primary-dark": t11,
903
903
  "border border-transparent bg-surface-100 hover:bg-surface-accent-200 text-text-primary dark:bg-surface-800 dark:hover:bg-surface-accent-700 dark:text-text-primary-dark hover:text-text-primary dark:text-text-primary-dark hover:dark:text-text-primary-dark": t12,
904
- "border border-transparent text-primary hover:text-primary hover:bg-surface-accent-200 hover:bg-opacity-75 hover:bg-surface-accent-200/75 dark:hover:bg-surface-accent-800": t13,
905
- "border border-transparent text-secondary hover:text-secondary hover:bg-surface-accent-200 hover:bg-opacity-75 hover:bg-surface-accent-200/75 dark:hover:bg-surface-accent-800": t14,
906
- "border border-transparent text-red-500 hover:text-red-500 hover:bg-red-500 hover:bg-opacity-10 hover:bg-red-500/10": t15,
904
+ "border border-transparent text-primary hover:text-primary hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-800": t13,
905
+ "border border-transparent text-secondary hover:text-secondary hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-800": t14,
906
+ "border border-transparent text-red-500 hover:text-red-500 hover:bg-red-500 hover:bg-opacity-10": t15,
907
907
  "border border-transparent text-text-primary hover:text-text-primary dark:text-text-primary-dark hover:dark:text-text-primary-dark hover:bg-surface-accent-200 hover:dark:bg-surface-700": t16,
908
908
  "border border-transparent text-text-primary hover:text-text-primary hover:bg-surface-accent-200 dark:text-text-primary-dark dark:hover:text-text-primary-dark dark:hover:bg-surface-accent-700": t17,
909
- "border border-primary text-primary hover:text-primary hover:bg-primary-bg hover:bg-primary/10": t18,
909
+ "border border-primary text-primary hover:text-primary hover:bg-primary-bg": t18,
910
910
  "border border-secondary text-secondary hover:text-secondary hover:bg-secondary-bg": t19,
911
911
  "border border-red-500 text-red-500 hover:text-red-500 hover:bg-red-500 hover:text-white": t20,
912
912
  "border border-surface-accent-400 text-text-primary hover:text-text-primary dark:text-text-primary-dark hover:bg-surface-accent-200": t21,
@@ -914,7 +914,7 @@
914
914
  "text-text-disabled dark:text-text-disabled-dark": disabled,
915
915
  "border border-transparent opacity-50": t23,
916
916
  "border border-surface-500 opacity-50": t24,
917
- "border border-transparent bg-surface-300 dark:bg-surface-500 opacity-40 bg-surface-300/40 dark:bg-surface-500/40": t25
917
+ "border border-transparent bg-surface-300 dark:bg-surface-500 opacity-40": t25
918
918
  });
919
919
  const sizeClasses2 = cls({
920
920
  "py-1 px-2": size === "small",
@@ -27275,7 +27275,7 @@
27275
27275
  const t6 = disabled ? void 0 : onCheckedChange;
27276
27276
  const t7 = padding ? paddingClasses[size] : "";
27277
27277
  const t8 = outerSizeClasses[size];
27278
- const t9 = onCheckedChange ? "rounded-full hover:bg-surface-accent-200 hover:bg-opacity-75 hover:bg-surface-accent-200/75 dark:hover:bg-surface-accent-700 dark:hover:bg-opacity-75 dark:hover:bg-surface-accent-700/75" : "";
27278
+ const t9 = onCheckedChange ? "rounded-full hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-700 dark:hover:bg-opacity-75" : "";
27279
27279
  const t10 = onCheckedChange ? "cursor-pointer" : "cursor-default";
27280
27280
  let t11;
27281
27281
  if ($[0] !== t10 || $[1] !== t7 || $[2] !== t8 || $[3] !== t9) {
@@ -27421,7 +27421,7 @@
27421
27421
  }
27422
27422
  return t11;
27423
27423
  }
27424
- const buttonClasses = "hover:bg-surface-accent-200 hover:bg-opacity-75 hover:bg-surface-accent-200/75 dark:hover:bg-surface-accent-800 hover:scale-105 transition-transform";
27424
+ const buttonClasses = "hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-800 hover:scale-105 transition-transform";
27425
27425
  const baseClasses = "inline-flex items-center justify-center p-2 text-sm font-medium focus:outline-none transition-colors ease-in-out duration-150";
27426
27426
  const colorClasses$1 = "text-surface-accent-600 visited:text-surface-accent-600 dark:text-surface-accent-300 dark:visited:text-surface-300";
27427
27427
  const sizeClasses = {
@@ -27481,7 +27481,7 @@
27481
27481
  const size = t1 === void 0 ? "medium" : t1;
27482
27482
  const variant = t2 === void 0 ? "ghost" : t2;
27483
27483
  const shape = t3 === void 0 ? "circular" : t3;
27484
- const bgClasses = variant === "ghost" ? "bg-transparent" : "bg-surface-accent-200 bg-opacity-50 bg-surface-accent-200/50 dark:bg-surface-950 dark:bg-opacity-50 dark:bg-surface-950/50";
27484
+ const bgClasses = variant === "ghost" ? "bg-transparent" : "bg-surface-accent-200 bg-opacity-50 dark:bg-surface-950 dark:bg-opacity-50";
27485
27485
  const Component = component || "button";
27486
27486
  const t4 = disabled ? "opacity-50 pointer-events-none" : "cursor-pointer";
27487
27487
  const t5 = toggled ? "outline outline-2 outline-primary" : "";
@@ -27489,7 +27489,7 @@
27489
27489
  const t7 = sizeClasses[size];
27490
27490
  let t8;
27491
27491
  if ($[10] !== bgClasses || $[11] !== className || $[12] !== t4 || $[13] !== t5 || $[14] !== t6 || $[15] !== t7) {
27492
- t8 = cls(t4, t5, "text-inherit dark:text-inherit", colorClasses$1, bgClasses, baseClasses, buttonClasses, t6, t7, className);
27492
+ t8 = cls(t4, t5, colorClasses$1, bgClasses, baseClasses, buttonClasses, t6, t7, className);
27493
27493
  $[10] = bgClasses;
27494
27494
  $[11] = className;
27495
27495
  $[12] = t4;
@@ -27859,18 +27859,18 @@
27859
27859
  }
27860
27860
  `;
27861
27861
  const widthClasses = {
27862
- xs: "max-w-xs w-xs",
27863
- sm: "max-w-sm w-sm",
27864
- md: "max-w-md w-md",
27865
- lg: "max-w-lg w-lg",
27866
- xl: "max-w-xl w-xl",
27867
- "2xl": "max-w-2xl w-2xl",
27868
- "3xl": "max-w-3xl w-3xl",
27869
- "4xl": "max-w-4xl w-4xl",
27870
- "5xl": "max-w-5xl w-5xl",
27871
- "6xl": "max-w-6xl w-6xl",
27872
- "7xl": "max-w-7xl w-7xl",
27873
- full: "max-w-full w-full"
27862
+ xs: "max-w-xs min-w-xs w-xs",
27863
+ sm: "max-w-sm min-w-sm w-sm",
27864
+ md: "max-w-md min-w-md w-md",
27865
+ lg: "max-w-lg min-w-lg w-lg",
27866
+ xl: "max-w-xl min-w-xl w-xl",
27867
+ "2xl": "max-w-2xl min-w-2xl w-2xl",
27868
+ "3xl": "max-w-3xl min-w-3xl w-3xl",
27869
+ "4xl": "max-w-4xl min-w-4xl w-4xl",
27870
+ "5xl": "max-w-5xl min-w-5xl w-5xl",
27871
+ "6xl": "max-w-6xl min-w-6xl w-6xl",
27872
+ "7xl": "max-w-7xl min-w-7xl w-7xl",
27873
+ full: "max-w-full min-w-full w-full"
27874
27874
  };
27875
27875
  const Dialog = (t0) => {
27876
27876
  const $ = reactCompilerRuntime.c(42);
@@ -27933,7 +27933,7 @@
27933
27933
  const t10 = displayed && open ? "opacity-100" : "opacity-0";
27934
27934
  let t11;
27935
27935
  if ($[5] !== t10) {
27936
- t11 = cls("fixed inset-0 transition-opacity z-20 ease-in-out duration-200 bg-black dark:bg-opacity-60 dark:bg-black/60 bg-opacity-50 bg-black/50 dark: bg-black/60 backdrop-blur-sm ", t10, "z-20 fixed top-0 left-0 w-full h-full flex justify-center items-center");
27936
+ t11 = cls("fixed inset-0 transition-opacity z-20 ease-in-out duration-200 bg-black bg-opacity-50 dark:bg-opacity-60 backdrop-blur-sm ", t10, "z-20 fixed top-0 left-0 w-full h-full flex justify-center items-center");
27937
27937
  $[5] = t10;
27938
27938
  $[6] = t11;
27939
27939
  } else {
@@ -28062,7 +28062,7 @@
28062
28062
  const t3 = translucent ? "backdrop-blur-sm" : "";
28063
28063
  let t4;
28064
28064
  if ($[0] !== className || $[1] !== position || $[2] !== t3) {
28065
- t4 = cls(defaultBorderMixin, "pt-2 pb-4 px-4 border-t flex flex-row items-center justify-end bottom-0 right-0 left-0 text-right z-2 gap-2", position, "bg-white bg-opacity-60 bg-white/60 dark:bg-surface-900 dark:bg-opacity-60 dark:bg-surface-900/60", t3, className);
28065
+ t4 = cls(defaultBorderMixin, "pt-2 pb-4 px-4 border-t flex flex-row items-center justify-end bottom-0 right-0 left-0 text-right z-2 gap-2", position, "bg-white bg-opacity-60 dark:bg-surface-900 dark:bg-opacity-60", t3, className);
28066
28066
  $[0] = className;
28067
28067
  $[1] = position;
28068
28068
  $[2] = t3;
@@ -28310,7 +28310,7 @@
28310
28310
  const t13 = asField && fieldBackgroundMixin;
28311
28311
  let t14;
28312
28312
  if ($[11] !== t10 || $[12] !== t11 || $[13] !== t12 || $[14] !== t13 || $[15] !== titleClassName) {
28313
- t14 = cls("rounded-t flex items-center justify-between w-full min-h-[52px]", "hover:bg-surface-accent-200 hover:bg-opacity-40 hover:bg-surface-accent-200/40 dark:hover:bg-surface-800 dark:hover:bg-opacity-40 dark:hover:bg-surface-800/40", t10, t11, "transition-all duration-200", t12, t13, titleClassName);
28313
+ t14 = cls("rounded-t flex items-center justify-between w-full min-h-[52px]", "hover:bg-surface-accent-200 hover:bg-opacity-40 dark:hover:bg-surface-800 dark:hover:bg-opacity-40", t10, t11, "transition-all duration-200", t12, t13, titleClassName);
28314
28314
  $[11] = t10;
28315
28315
  $[12] = t11;
28316
28316
  $[13] = t12;
@@ -28893,7 +28893,7 @@
28893
28893
  } = t0;
28894
28894
  let t1;
28895
28895
  if ($[0] !== className) {
28896
- t1 = cls("py-2 px-3 outline-none select-none font-medium leading-none rounded text-text-primary dark:text-text-primary-dark text-[13px] flex items-center justify-between gap-[2px] data-[highlighted]:bg-surface-accent-100 data-[highlighted]:dark:bg-surface-800 data-[state=open]:bg-surface-accent-100 data-[state=open]:dark:bg-surface-800 hover:bg-surface-accent-200 hover:bg-opacity-75 hover:bg-surface-accent-200/75 dark:hover:bg-surface-accent-800", className);
28896
+ t1 = cls("py-2 px-3 outline-none select-none font-medium leading-none rounded text-text-primary dark:text-text-primary-dark text-[13px] flex items-center justify-between gap-[2px] data-[highlighted]:bg-surface-accent-100 data-[highlighted]:dark:bg-surface-800 data-[state=open]:bg-surface-accent-100 data-[state=open]:dark:bg-surface-800 hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-800", className);
28897
28897
  $[0] = className;
28898
28898
  $[1] = t1;
28899
28899
  } else {
@@ -29495,7 +29495,7 @@
29495
29495
  if (orientation === "horizontal") {
29496
29496
  let t1;
29497
29497
  if ($[0] !== className) {
29498
- t1 = cls("dark:bg-opacity-80 dark:bg-surface-800 dark:bg-surface-800/80 bg-surface-100 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px my-4", className);
29498
+ t1 = cls("dark:bg-opacity-80 dark:bg-surface-800 bg-surface-100 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px my-4", className);
29499
29499
  $[0] = className;
29500
29500
  $[1] = t1;
29501
29501
  } else {
@@ -29514,7 +29514,7 @@
29514
29514
  } else {
29515
29515
  let t1;
29516
29516
  if ($[5] !== className) {
29517
- t1 = cls("dark:bg-opacity-80 dark:bg-surface-800 dark:bg-surface-800/80 bg-surface-100 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px mx-4", className);
29517
+ t1 = cls("dark:bg-opacity-80 dark:bg-surface-800 bg-surface-100 data-[orientation=horizontal]:h-px data-[orientation=horizontal]:w-full data-[orientation=vertical]:h-full data-[orientation=vertical]:w-px mx-4", className);
29518
29518
  $[5] = className;
29519
29519
  $[6] = t1;
29520
29520
  } else {
@@ -29560,7 +29560,7 @@
29560
29560
  }
29561
29561
  const MultiSelectContext = React__namespace.createContext({});
29562
29562
  const MultiSelect = React__namespace.forwardRef((t0, ref) => {
29563
- const $ = reactCompilerRuntime.c(105);
29563
+ const $ = reactCompilerRuntime.c(103);
29564
29564
  const {
29565
29565
  value,
29566
29566
  size: t1,
@@ -29585,8 +29585,7 @@
29585
29585
  const includeClear = t3 === void 0 ? true : t3;
29586
29586
  const includeSelectAll = t4 === void 0 ? true : t4;
29587
29587
  const useChips = t5 === void 0 ? true : t5;
29588
- const [isMounted, setIsMounted] = React.useState(false);
29589
- const [isPopoverOpen, setIsPopoverOpen] = React.useState(open ?? false);
29588
+ const [isPopoverOpen, setIsPopoverOpen] = React__namespace.useState(open ?? false);
29590
29589
  let t6;
29591
29590
  if ($[0] !== value) {
29592
29591
  t6 = value ?? [];
@@ -29595,75 +29594,61 @@
29595
29594
  } else {
29596
29595
  t6 = $[1];
29597
29596
  }
29598
- const [selectedValues, setSelectedValues] = React.useState(t6);
29597
+ const [selectedValues, setSelectedValues] = React__namespace.useState(t6);
29599
29598
  let t7;
29600
- let t8;
29601
- if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
29602
- t7 = () => {
29603
- setIsMounted(true);
29604
- };
29605
- t8 = [];
29606
- $[2] = t7;
29607
- $[3] = t8;
29608
- } else {
29609
- t7 = $[2];
29610
- t8 = $[3];
29611
- }
29612
- React.useEffect(t7, t8);
29613
- let t9;
29614
- if ($[4] !== onOpenChange) {
29615
- t9 = (open_0) => {
29599
+ if ($[2] !== onOpenChange) {
29600
+ t7 = (open_0) => {
29616
29601
  setIsPopoverOpen(open_0);
29617
29602
  onOpenChange?.(open_0);
29618
29603
  };
29619
- $[4] = onOpenChange;
29620
- $[5] = t9;
29604
+ $[2] = onOpenChange;
29605
+ $[3] = t7;
29621
29606
  } else {
29622
- t9 = $[5];
29607
+ t7 = $[3];
29623
29608
  }
29624
- const onPopoverOpenChange = t9;
29625
- let t10;
29626
- let t11;
29627
- if ($[6] !== open) {
29628
- t10 = () => {
29609
+ const onPopoverOpenChange = t7;
29610
+ let t8;
29611
+ let t9;
29612
+ if ($[4] !== open) {
29613
+ t8 = () => {
29629
29614
  setIsPopoverOpen(open ?? false);
29630
29615
  };
29631
- t11 = [open];
29632
- $[6] = open;
29633
- $[7] = t10;
29634
- $[8] = t11;
29616
+ t9 = [open];
29617
+ $[4] = open;
29618
+ $[5] = t8;
29619
+ $[6] = t9;
29635
29620
  } else {
29636
- t10 = $[7];
29637
- t11 = $[8];
29621
+ t8 = $[5];
29622
+ t9 = $[6];
29638
29623
  }
29639
- React.useEffect(t10, t11);
29640
- let t12;
29641
- if ($[9] !== children) {
29642
- t12 = children ? React.Children.map(children, _temp$1).filter(Boolean) : [];
29643
- $[9] = children;
29644
- $[10] = t12;
29624
+ React.useEffect(t8, t9);
29625
+ let t10;
29626
+ if ($[7] !== children) {
29627
+ t10 = children ? React.Children.map(children, _temp$1).filter(Boolean) : [];
29628
+ $[7] = children;
29629
+ $[8] = t10;
29645
29630
  } else {
29646
- t12 = $[10];
29631
+ t10 = $[8];
29647
29632
  }
29648
- const allValues = t12;
29649
- let t13;
29650
- let t14;
29651
- if ($[11] !== value) {
29652
- t13 = () => {
29633
+ const allValues = t10;
29634
+ let t11;
29635
+ let t12;
29636
+ if ($[9] !== value) {
29637
+ t11 = () => {
29653
29638
  setSelectedValues(value ?? []);
29654
29639
  };
29655
- t14 = [value];
29656
- $[11] = value;
29657
- $[12] = t13;
29658
- $[13] = t14;
29640
+ t12 = [value];
29641
+ $[9] = value;
29642
+ $[10] = t11;
29643
+ $[11] = t12;
29659
29644
  } else {
29660
- t13 = $[12];
29661
- t14 = $[13];
29645
+ t11 = $[10];
29646
+ t12 = $[11];
29662
29647
  }
29663
- React__namespace.useEffect(t13, t14);
29648
+ React__namespace.useEffect(t11, t12);
29664
29649
  let onItemClick;
29665
29650
  let updateValues;
29666
- if ($[14] !== onValueChange || $[15] !== selectedValues) {
29651
+ if ($[12] !== onValueChange || $[13] !== selectedValues) {
29667
29652
  onItemClick = function onItemClick2(newValue) {
29668
29653
  let newSelectedValues;
29669
29654
  if (selectedValues.some((v_0) => String(v_0) === String(newValue))) {
@@ -29677,17 +29662,17 @@
29677
29662
  setSelectedValues(values);
29678
29663
  onValueChange?.(values);
29679
29664
  };
29680
- $[14] = onValueChange;
29681
- $[15] = selectedValues;
29682
- $[16] = onItemClick;
29683
- $[17] = updateValues;
29665
+ $[12] = onValueChange;
29666
+ $[13] = selectedValues;
29667
+ $[14] = onItemClick;
29668
+ $[15] = updateValues;
29684
29669
  } else {
29685
- onItemClick = $[16];
29686
- updateValues = $[17];
29670
+ onItemClick = $[14];
29671
+ updateValues = $[15];
29687
29672
  }
29688
- let t15;
29689
- if ($[18] !== onPopoverOpenChange || $[19] !== selectedValues || $[20] !== updateValues) {
29690
- t15 = (event) => {
29673
+ let t13;
29674
+ if ($[16] !== onPopoverOpenChange || $[17] !== selectedValues || $[18] !== updateValues) {
29675
+ t13 = (event) => {
29691
29676
  if (event.key === "Enter") {
29692
29677
  onPopoverOpenChange(true);
29693
29678
  } else {
@@ -29698,53 +29683,53 @@
29698
29683
  }
29699
29684
  }
29700
29685
  };
29701
- $[18] = onPopoverOpenChange;
29702
- $[19] = selectedValues;
29703
- $[20] = updateValues;
29704
- $[21] = t15;
29686
+ $[16] = onPopoverOpenChange;
29687
+ $[17] = selectedValues;
29688
+ $[18] = updateValues;
29689
+ $[19] = t13;
29705
29690
  } else {
29706
- t15 = $[21];
29691
+ t13 = $[19];
29707
29692
  }
29708
- const handleInputKeyDown = t15;
29709
- let t16;
29710
- if ($[22] !== selectedValues || $[23] !== updateValues) {
29711
- t16 = (value_0) => {
29693
+ const handleInputKeyDown = t13;
29694
+ let t14;
29695
+ if ($[20] !== selectedValues || $[21] !== updateValues) {
29696
+ t14 = (value_0) => {
29712
29697
  const newSelectedValues_1 = selectedValues.some((v_2) => String(v_2) === String(value_0)) ? selectedValues.filter((v_1) => String(v_1) !== String(value_0)) : [...selectedValues, value_0];
29713
29698
  updateValues(newSelectedValues_1);
29714
29699
  };
29715
- $[22] = selectedValues;
29716
- $[23] = updateValues;
29717
- $[24] = t16;
29700
+ $[20] = selectedValues;
29701
+ $[21] = updateValues;
29702
+ $[22] = t14;
29718
29703
  } else {
29719
- t16 = $[24];
29704
+ t14 = $[22];
29720
29705
  }
29721
- const toggleOption = t16;
29722
- let t17;
29723
- if ($[25] !== updateValues) {
29724
- t17 = () => {
29706
+ const toggleOption = t14;
29707
+ let t15;
29708
+ if ($[23] !== updateValues) {
29709
+ t15 = () => {
29725
29710
  updateValues([]);
29726
29711
  };
29727
- $[25] = updateValues;
29728
- $[26] = t17;
29712
+ $[23] = updateValues;
29713
+ $[24] = t15;
29729
29714
  } else {
29730
- t17 = $[26];
29715
+ t15 = $[24];
29731
29716
  }
29732
- const handleClear = t17;
29733
- let t18;
29734
- if ($[27] !== isPopoverOpen || $[28] !== onPopoverOpenChange) {
29735
- t18 = () => {
29717
+ const handleClear = t15;
29718
+ let t16;
29719
+ if ($[25] !== isPopoverOpen || $[26] !== onPopoverOpenChange) {
29720
+ t16 = () => {
29736
29721
  onPopoverOpenChange(!isPopoverOpen);
29737
29722
  };
29738
- $[27] = isPopoverOpen;
29739
- $[28] = onPopoverOpenChange;
29740
- $[29] = t18;
29723
+ $[25] = isPopoverOpen;
29724
+ $[26] = onPopoverOpenChange;
29725
+ $[27] = t16;
29741
29726
  } else {
29742
- t18 = $[29];
29727
+ t16 = $[27];
29743
29728
  }
29744
- const handleTogglePopover = t18;
29745
- let t19;
29746
- if ($[30] !== allValues || $[31] !== handleClear || $[32] !== onPopoverOpenChange || $[33] !== selectedValues.length || $[34] !== updateValues) {
29747
- t19 = () => {
29729
+ const handleTogglePopover = t16;
29730
+ let t17;
29731
+ if ($[28] !== allValues || $[29] !== handleClear || $[30] !== onPopoverOpenChange || $[31] !== selectedValues.length || $[32] !== updateValues) {
29732
+ t17 = () => {
29748
29733
  if (selectedValues.length === allValues.length) {
29749
29734
  handleClear();
29750
29735
  } else {
@@ -29752,55 +29737,54 @@
29752
29737
  }
29753
29738
  onPopoverOpenChange(false);
29754
29739
  };
29755
- $[30] = allValues;
29756
- $[31] = handleClear;
29757
- $[32] = onPopoverOpenChange;
29758
- $[33] = selectedValues.length;
29759
- $[34] = updateValues;
29760
- $[35] = t19;
29740
+ $[28] = allValues;
29741
+ $[29] = handleClear;
29742
+ $[30] = onPopoverOpenChange;
29743
+ $[31] = selectedValues.length;
29744
+ $[32] = updateValues;
29745
+ $[33] = t17;
29761
29746
  } else {
29762
- t19 = $[35];
29747
+ t17 = $[33];
29763
29748
  }
29764
- const toggleAll = t19;
29749
+ const toggleAll = t17;
29765
29750
  useInjectStyles("MultiSelect", `
29766
29751
  [cmdk-group] {
29767
29752
  max-height: 45vh;
29768
29753
  overflow-y: auto;
29769
29754
  // width: 400px;
29770
29755
  } `);
29771
- let t20;
29772
- if ($[36] !== onItemClick || $[37] !== selectedValues) {
29773
- t20 = {
29756
+ let t18;
29757
+ if ($[34] !== onItemClick || $[35] !== selectedValues) {
29758
+ t18 = {
29774
29759
  fieldValue: selectedValues,
29775
29760
  onItemClick
29776
29761
  };
29777
- $[36] = onItemClick;
29778
- $[37] = selectedValues;
29779
- $[38] = t20;
29762
+ $[34] = onItemClick;
29763
+ $[35] = selectedValues;
29764
+ $[36] = t18;
29780
29765
  } else {
29781
- t20 = $[38];
29766
+ t18 = $[36];
29782
29767
  }
29783
- let t21;
29784
- if ($[39] !== error || $[40] !== label) {
29785
- t21 = typeof label === "string" ? /* @__PURE__ */ jsxRuntime.jsx(SelectInputLabel, { error, children: label }) : label;
29786
- $[39] = error;
29787
- $[40] = label;
29788
- $[41] = t21;
29789
- } else {
29790
- t21 = $[41];
29791
- }
29792
- const t22 = isMounted && isPopoverOpen;
29793
- const t23 = size === "smallest";
29794
- const t24 = size === "small";
29795
- const t25 = size === "medium";
29796
- const t26 = size === "large";
29797
- let t27;
29798
- if ($[42] !== className || $[43] !== disabled || $[44] !== invisible || $[45] !== size || $[46] !== t23 || $[47] !== t24 || $[48] !== t25 || $[49] !== t26) {
29799
- t27 = cls({
29800
- "min-h-[28px]": t23,
29801
- "min-h-[32px]": t24,
29802
- "min-h-[42px]": t25,
29803
- "min-h-[64px]": t26
29768
+ let t19;
29769
+ if ($[37] !== error || $[38] !== label) {
29770
+ t19 = typeof label === "string" ? /* @__PURE__ */ jsxRuntime.jsx(SelectInputLabel, { error, children: label }) : label;
29771
+ $[37] = error;
29772
+ $[38] = label;
29773
+ $[39] = t19;
29774
+ } else {
29775
+ t19 = $[39];
29776
+ }
29777
+ const t20 = size === "smallest";
29778
+ const t21 = size === "small";
29779
+ const t22 = size === "medium";
29780
+ const t23 = size === "large";
29781
+ let t24;
29782
+ if ($[40] !== className || $[41] !== disabled || $[42] !== invisible || $[43] !== size || $[44] !== t20 || $[45] !== t21 || $[46] !== t22 || $[47] !== t23) {
29783
+ t24 = cls({
29784
+ "min-h-[28px]": t20,
29785
+ "min-h-[32px]": t21,
29786
+ "min-h-[42px]": t22,
29787
+ "min-h-[64px]": t23
29804
29788
  }, {
29805
29789
  "py-1": size === "small" || size === "smallest",
29806
29790
  "py-2": size === "medium" || size === "large"
@@ -29808,21 +29792,21 @@
29808
29792
  "px-2": size === "small" || size === "smallest",
29809
29793
  "px-4": size === "medium" || size === "large"
29810
29794
  }, "select-none rounded-md text-sm", invisible ? fieldBackgroundInvisibleMixin : fieldBackgroundMixin, disabled ? fieldBackgroundDisabledMixin : fieldBackgroundHoverMixin, "relative flex items-center", className);
29811
- $[42] = className;
29812
- $[43] = disabled;
29813
- $[44] = invisible;
29814
- $[45] = size;
29815
- $[46] = t23;
29816
- $[47] = t24;
29817
- $[48] = t25;
29818
- $[49] = t26;
29819
- $[50] = t27;
29820
- } else {
29821
- t27 = $[50];
29795
+ $[40] = className;
29796
+ $[41] = disabled;
29797
+ $[42] = invisible;
29798
+ $[43] = size;
29799
+ $[44] = t20;
29800
+ $[45] = t21;
29801
+ $[46] = t22;
29802
+ $[47] = t23;
29803
+ $[48] = t24;
29804
+ } else {
29805
+ t24 = $[48];
29822
29806
  }
29823
- let t28;
29824
- if ($[51] !== children || $[52] !== handleClear || $[53] !== includeClear || $[54] !== isPopoverOpen || $[55] !== placeholder || $[56] !== renderValues || $[57] !== selectedValues || $[58] !== size || $[59] !== toggleOption || $[60] !== useChips) {
29825
- t28 = selectedValues.length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between items-center w-full", children: [
29807
+ let t25;
29808
+ if ($[49] !== children || $[50] !== handleClear || $[51] !== includeClear || $[52] !== isPopoverOpen || $[53] !== placeholder || $[54] !== renderValues || $[55] !== selectedValues || $[56] !== size || $[57] !== toggleOption || $[58] !== useChips) {
29809
+ t25 = selectedValues.length > 0 ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex justify-between items-center w-full", children: [
29826
29810
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-wrap items-center gap-1.5 text-start", children: [
29827
29811
  renderValues && renderValues(selectedValues),
29828
29812
  !renderValues && selectedValues.map((value_1) => {
@@ -29851,176 +29835,176 @@
29851
29835
  /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm", children: placeholder }),
29852
29836
  /* @__PURE__ */ jsxRuntime.jsx("div", { className: cls("px-2 h-full flex items-center"), children: /* @__PURE__ */ jsxRuntime.jsx(KeyboardArrowDownIcon, { size: size === "large" ? "medium" : "small", className: cls("transition", isPopoverOpen ? "rotate-180" : "") }) })
29853
29837
  ] });
29854
- $[51] = children;
29855
- $[52] = handleClear;
29856
- $[53] = includeClear;
29857
- $[54] = isPopoverOpen;
29858
- $[55] = placeholder;
29859
- $[56] = renderValues;
29860
- $[57] = selectedValues;
29861
- $[58] = size;
29862
- $[59] = toggleOption;
29863
- $[60] = useChips;
29864
- $[61] = t28;
29865
- } else {
29866
- t28 = $[61];
29838
+ $[49] = children;
29839
+ $[50] = handleClear;
29840
+ $[51] = includeClear;
29841
+ $[52] = isPopoverOpen;
29842
+ $[53] = placeholder;
29843
+ $[54] = renderValues;
29844
+ $[55] = selectedValues;
29845
+ $[56] = size;
29846
+ $[57] = toggleOption;
29847
+ $[58] = useChips;
29848
+ $[59] = t25;
29849
+ } else {
29850
+ t25 = $[59];
29851
+ }
29852
+ let t26;
29853
+ if ($[60] !== handleTogglePopover || $[61] !== ref || $[62] !== t24 || $[63] !== t25) {
29854
+ t26 = /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Trigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx("button", { ref, onClick: handleTogglePopover, className: t24, children: t25 }) });
29855
+ $[60] = handleTogglePopover;
29856
+ $[61] = ref;
29857
+ $[62] = t24;
29858
+ $[63] = t25;
29859
+ $[64] = t26;
29860
+ } else {
29861
+ t26 = $[64];
29862
+ }
29863
+ let t27;
29864
+ if ($[65] === Symbol.for("react.memo_cache_sentinel")) {
29865
+ t27 = cls("z-50 relative overflow-hidden border bg-white dark:bg-surface-900 rounded-lg w-[400px]", defaultBorderMixin);
29866
+ $[65] = t27;
29867
+ } else {
29868
+ t27 = $[65];
29869
+ }
29870
+ let t28;
29871
+ if ($[66] !== onPopoverOpenChange) {
29872
+ t28 = () => onPopoverOpenChange(false);
29873
+ $[66] = onPopoverOpenChange;
29874
+ $[67] = t28;
29875
+ } else {
29876
+ t28 = $[67];
29867
29877
  }
29868
29878
  let t29;
29869
- if ($[62] !== handleTogglePopover || $[63] !== ref || $[64] !== t27 || $[65] !== t28) {
29870
- t29 = /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Trigger, { asChild: true, children: /* @__PURE__ */ jsxRuntime.jsx("button", { ref, onClick: handleTogglePopover, className: t27, children: t28 }) });
29871
- $[62] = handleTogglePopover;
29872
- $[63] = ref;
29873
- $[64] = t27;
29874
- $[65] = t28;
29875
- $[66] = t29;
29879
+ if ($[68] === Symbol.for("react.memo_cache_sentinel")) {
29880
+ t29 = cls(focusedDisabled, "bg-transparent outline-none flex-1 h-full w-full m-4 flex-grow ");
29881
+ $[68] = t29;
29876
29882
  } else {
29877
- t29 = $[66];
29883
+ t29 = $[68];
29878
29884
  }
29879
29885
  let t30;
29880
- if ($[67] === Symbol.for("react.memo_cache_sentinel")) {
29881
- t30 = cls("z-50 overflow-hidden border bg-white dark:bg-surface-900 rounded-lg w-[400px]", defaultBorderMixin);
29882
- $[67] = t30;
29886
+ if ($[69] !== handleInputKeyDown) {
29887
+ t30 = /* @__PURE__ */ jsxRuntime.jsx(cmdk.Command.Input, { className: t29, placeholder: "Search...", onKeyDown: handleInputKeyDown });
29888
+ $[69] = handleInputKeyDown;
29889
+ $[70] = t30;
29883
29890
  } else {
29884
- t30 = $[67];
29891
+ t30 = $[70];
29885
29892
  }
29886
29893
  let t31;
29887
- if ($[68] !== onPopoverOpenChange) {
29888
- t31 = () => onPopoverOpenChange(false);
29889
- $[68] = onPopoverOpenChange;
29890
- $[69] = t31;
29894
+ if ($[71] !== handleClear || $[72] !== selectedValues.length) {
29895
+ t31 = selectedValues.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { onClick: handleClear, className: "text-sm justify-center cursor-pointer py-3 px-4 text-text-secondary dark:text-text-secondary-dark", children: "Clear" });
29896
+ $[71] = handleClear;
29897
+ $[72] = selectedValues.length;
29898
+ $[73] = t31;
29891
29899
  } else {
29892
- t31 = $[69];
29900
+ t31 = $[73];
29893
29901
  }
29894
29902
  let t32;
29895
- if ($[70] === Symbol.for("react.memo_cache_sentinel")) {
29896
- t32 = cls(focusedDisabled, "bg-transparent outline-none flex-1 h-full w-full m-4 flex-grow ");
29897
- $[70] = t32;
29903
+ if ($[74] !== t30 || $[75] !== t31) {
29904
+ t32 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-row items-center", children: [
29905
+ t30,
29906
+ t31
29907
+ ] });
29908
+ $[74] = t30;
29909
+ $[75] = t31;
29910
+ $[76] = t32;
29898
29911
  } else {
29899
- t32 = $[70];
29912
+ t32 = $[76];
29900
29913
  }
29901
29914
  let t33;
29902
- if ($[71] !== handleInputKeyDown) {
29903
- t33 = /* @__PURE__ */ jsxRuntime.jsx(cmdk.Command.Input, { className: t32, placeholder: "Search...", onKeyDown: handleInputKeyDown });
29904
- $[71] = handleInputKeyDown;
29905
- $[72] = t33;
29915
+ if ($[77] === Symbol.for("react.memo_cache_sentinel")) {
29916
+ t33 = /* @__PURE__ */ jsxRuntime.jsx(Separator, { orientation: "horizontal", className: "my-0" });
29917
+ $[77] = t33;
29906
29918
  } else {
29907
- t33 = $[72];
29919
+ t33 = $[77];
29908
29920
  }
29909
29921
  let t34;
29910
- if ($[73] !== handleClear || $[74] !== selectedValues.length) {
29911
- t34 = selectedValues.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("div", { onClick: handleClear, className: "text-sm justify-center cursor-pointer py-3 px-4 text-text-secondary dark:text-text-secondary-dark", children: "Clear" });
29912
- $[73] = handleClear;
29913
- $[74] = selectedValues.length;
29914
- $[75] = t34;
29922
+ if ($[78] === Symbol.for("react.memo_cache_sentinel")) {
29923
+ t34 = /* @__PURE__ */ jsxRuntime.jsx(cmdk.Command.Empty, { className: "px-4 py-2", children: "No results found." });
29924
+ $[78] = t34;
29915
29925
  } else {
29916
- t34 = $[75];
29926
+ t34 = $[78];
29917
29927
  }
29918
29928
  let t35;
29919
- if ($[76] !== t33 || $[77] !== t34) {
29920
- t35 = /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-row items-center", children: [
29921
- t33,
29922
- t34
29923
- ] });
29924
- $[76] = t33;
29925
- $[77] = t34;
29926
- $[78] = t35;
29929
+ if ($[79] !== allValues.length || $[80] !== includeSelectAll || $[81] !== selectedValues.length || $[82] !== toggleAll) {
29930
+ t35 = includeSelectAll && /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command.Item, { onSelect: toggleAll, className: cls("flex flex-row items-center gap-1.5", "cursor-pointer", "m-1", "ring-offset-transparent", "p-1 rounded aria-[selected=true]:outline-none aria-[selected=true]:ring-2 aria-[selected=true]:ring-primary aria-[selected=true]:ring-opacity-75 aria-[selected=true]:ring-offset-2", "aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900", "cursor-pointer p-2 rounded aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900"), children: [
29931
+ /* @__PURE__ */ jsxRuntime.jsx(InnerCheckBox, { checked: selectedValues.length === allValues.length }),
29932
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-text-secondary dark:text-text-secondary-dark", children: "(Select All)" })
29933
+ ] }, "all");
29934
+ $[79] = allValues.length;
29935
+ $[80] = includeSelectAll;
29936
+ $[81] = selectedValues.length;
29937
+ $[82] = toggleAll;
29938
+ $[83] = t35;
29927
29939
  } else {
29928
- t35 = $[78];
29940
+ t35 = $[83];
29929
29941
  }
29930
29942
  let t36;
29931
- if ($[79] === Symbol.for("react.memo_cache_sentinel")) {
29932
- t36 = /* @__PURE__ */ jsxRuntime.jsx(Separator, { orientation: "horizontal", className: "my-0" });
29933
- $[79] = t36;
29943
+ if ($[84] !== children || $[85] !== t35) {
29944
+ t36 = /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command.List, { children: [
29945
+ t34,
29946
+ /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command.Group, { children: [
29947
+ t35,
29948
+ children
29949
+ ] })
29950
+ ] });
29951
+ $[84] = children;
29952
+ $[85] = t35;
29953
+ $[86] = t36;
29934
29954
  } else {
29935
- t36 = $[79];
29955
+ t36 = $[86];
29936
29956
  }
29937
29957
  let t37;
29938
- if ($[80] === Symbol.for("react.memo_cache_sentinel")) {
29939
- t37 = /* @__PURE__ */ jsxRuntime.jsx(cmdk.Command.Empty, { className: "px-4 py-2", children: "No results found." });
29940
- $[80] = t37;
29958
+ if ($[87] !== t32 || $[88] !== t36) {
29959
+ t37 = /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command, { children: [
29960
+ t32,
29961
+ t33,
29962
+ t36
29963
+ ] });
29964
+ $[87] = t32;
29965
+ $[88] = t36;
29966
+ $[89] = t37;
29941
29967
  } else {
29942
- t37 = $[80];
29968
+ t37 = $[89];
29943
29969
  }
29944
29970
  let t38;
29945
- if ($[81] !== allValues.length || $[82] !== includeSelectAll || $[83] !== selectedValues.length || $[84] !== toggleAll) {
29946
- t38 = includeSelectAll && /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command.Item, { onSelect: toggleAll, className: cls("flex flex-row items-center gap-1.5", "cursor-pointer", "m-1", "ring-offset-transparent", "p-1 rounded aria-[selected=true]:outline-none aria-[selected=true]:ring-2 aria-[selected=true]:ring-primary aria-[selected=true]:ring-opacity-75 aria-[selected=true]:ring-primary/75 aria-[selected=true]:ring-offset-2", "aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900", "cursor-pointer p-2 rounded aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900"), children: [
29947
- /* @__PURE__ */ jsxRuntime.jsx(InnerCheckBox, { checked: selectedValues.length === allValues.length }),
29948
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-sm text-text-secondary dark:text-text-secondary-dark", children: "(Select All)" })
29949
- ] }, "all");
29950
- $[81] = allValues.length;
29951
- $[82] = includeSelectAll;
29952
- $[83] = selectedValues.length;
29953
- $[84] = toggleAll;
29954
- $[85] = t38;
29971
+ if ($[90] !== t28 || $[91] !== t37) {
29972
+ t38 = /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Content, { className: t27, align: "start", sideOffset: 8, onEscapeKeyDown: t28, children: t37 });
29973
+ $[90] = t28;
29974
+ $[91] = t37;
29975
+ $[92] = t38;
29955
29976
  } else {
29956
- t38 = $[85];
29977
+ t38 = $[92];
29957
29978
  }
29958
29979
  let t39;
29959
- if ($[86] !== children || $[87] !== t38) {
29960
- t39 = /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command.List, { children: [
29961
- t37,
29962
- /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command.Group, { children: [
29963
- t38,
29964
- children
29965
- ] })
29980
+ if ($[93] !== isPopoverOpen || $[94] !== modalPopover || $[95] !== onPopoverOpenChange || $[96] !== t26 || $[97] !== t38) {
29981
+ t39 = /* @__PURE__ */ jsxRuntime.jsxs(PopoverPrimitive__namespace.Root, { open: isPopoverOpen, onOpenChange: onPopoverOpenChange, modal: modalPopover, children: [
29982
+ t26,
29983
+ t38
29966
29984
  ] });
29967
- $[86] = children;
29968
- $[87] = t38;
29969
- $[88] = t39;
29985
+ $[93] = isPopoverOpen;
29986
+ $[94] = modalPopover;
29987
+ $[95] = onPopoverOpenChange;
29988
+ $[96] = t26;
29989
+ $[97] = t38;
29990
+ $[98] = t39;
29970
29991
  } else {
29971
- t39 = $[88];
29992
+ t39 = $[98];
29972
29993
  }
29973
29994
  let t40;
29974
- if ($[89] !== t35 || $[90] !== t39) {
29975
- t40 = /* @__PURE__ */ jsxRuntime.jsxs(cmdk.Command, { children: [
29976
- t35,
29977
- t36,
29995
+ if ($[99] !== t18 || $[100] !== t19 || $[101] !== t39) {
29996
+ t40 = /* @__PURE__ */ jsxRuntime.jsxs(MultiSelectContext.Provider, { value: t18, children: [
29997
+ t19,
29978
29998
  t39
29979
29999
  ] });
29980
- $[89] = t35;
29981
- $[90] = t39;
29982
- $[91] = t40;
29983
- } else {
29984
- t40 = $[91];
29985
- }
29986
- let t41;
29987
- if ($[92] !== t31 || $[93] !== t40) {
29988
- t41 = /* @__PURE__ */ jsxRuntime.jsx(PopoverPrimitive__namespace.Content, { className: t30, align: "start", sideOffset: 8, onEscapeKeyDown: t31, children: t40 });
29989
- $[92] = t31;
29990
- $[93] = t40;
29991
- $[94] = t41;
29992
- } else {
29993
- t41 = $[94];
29994
- }
29995
- let t42;
29996
- if ($[95] !== modalPopover || $[96] !== onPopoverOpenChange || $[97] !== t22 || $[98] !== t29 || $[99] !== t41) {
29997
- t42 = /* @__PURE__ */ jsxRuntime.jsxs(PopoverPrimitive__namespace.Root, { open: t22, onOpenChange: onPopoverOpenChange, modal: modalPopover, children: [
29998
- t29,
29999
- t41
30000
- ] });
30001
- $[95] = modalPopover;
30002
- $[96] = onPopoverOpenChange;
30003
- $[97] = t22;
30004
- $[98] = t29;
30005
- $[99] = t41;
30006
- $[100] = t42;
30007
- } else {
30008
- t42 = $[100];
30009
- }
30010
- let t43;
30011
- if ($[101] !== t20 || $[102] !== t21 || $[103] !== t42) {
30012
- t43 = /* @__PURE__ */ jsxRuntime.jsxs(MultiSelectContext.Provider, { value: t20, children: [
30013
- t21,
30014
- t42
30015
- ] });
30016
- $[101] = t20;
30017
- $[102] = t21;
30018
- $[103] = t42;
30019
- $[104] = t43;
30000
+ $[99] = t18;
30001
+ $[100] = t19;
30002
+ $[101] = t39;
30003
+ $[102] = t40;
30020
30004
  } else {
30021
- t43 = $[104];
30005
+ t40 = $[102];
30022
30006
  }
30023
- return t43;
30007
+ return t40;
30024
30008
  });
30025
30009
  MultiSelect.displayName = "MultiSelect";
30026
30010
  function MultiSelectItem(t0) {
@@ -30078,7 +30062,7 @@
30078
30062
  const t4 = isSelected ? "bg-surface-accent-200 dark:bg-surface-accent-950" : "";
30079
30063
  let t5;
30080
30064
  if ($[10] !== className || $[11] !== t4) {
30081
- t5 = cls("flex flex-row items-center gap-1.5", t4, "cursor-pointer", "m-1", "ring-offset-transparent", "p-1 rounded aria-[selected=true]:outline-none aria-[selected=true]:ring-2 aria-[selected=true]:ring-primary aria-[selected=true]:ring-opacity-75 aria-[selected=true]:ring-primary/75 aria-[selected=true]:ring-offset-2", "aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900", "cursor-pointer p-2 rounded aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900", className);
30065
+ t5 = cls("flex flex-row items-center gap-1.5", t4, "cursor-pointer", "m-1", "ring-offset-transparent", "p-1 rounded aria-[selected=true]:outline-none aria-[selected=true]:ring-2 aria-[selected=true]:ring-primary aria-[selected=true]:ring-opacity-75 aria-[selected=true]:ring-offset-2", "aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900", "cursor-pointer p-2 rounded aria-[selected=true]:bg-surface-accent-100 aria-[selected=true]:dark:bg-surface-accent-900", className);
30082
30066
  $[10] = className;
30083
30067
  $[11] = t4;
30084
30068
  $[12] = t5;
@@ -30506,7 +30490,7 @@
30506
30490
  "px-4": size === "large",
30507
30491
  "px-3": size === "medium",
30508
30492
  "px-2": size === "small" || size === "smallest"
30509
- } : "", "outline-hidden focus:outline-hidden", "outline-none focus:outline-none", "select-none rounded-md text-sm", error ? "text-red-500 dark:text-red-600" : "focus:text-text-primary dark:focus:text-text-primary-dark", error ? "border border-red-500 dark:border-red-600" : "", disabled ? "text-surface-accent-600 dark:text-surface-accent-400" : "text-surface-accent-800 dark:text-white", "relative flex flex-row items-center", {
30493
+ } : "", "outline-none focus:outline-none", "select-none rounded-md text-sm", error ? "text-red-500 dark:text-red-600" : "focus:text-text-primary dark:focus:text-text-primary-dark", error ? "border border-red-500 dark:border-red-600" : "", disabled ? "text-surface-accent-600 dark:text-surface-accent-400" : "text-surface-accent-800 dark:text-white", "relative flex flex-row items-center", {
30510
30494
  "min-h-[28px]": size === "smallest",
30511
30495
  "min-h-[32px]": size === "small",
30512
30496
  "min-h-[42px]": size === "medium",
@@ -30647,7 +30631,7 @@
30647
30631
  t2 = cls({
30648
30632
  "border-primary bg-primary outline-none": t1,
30649
30633
  "border-surface-accent-300 bg-surface-accent-300 dark:border-surface-700 dark:bg-surface-700": props.props.disabled
30650
- }, props.classes, "focus-visible:ring-4 focus-visible:ring-primary focus-visible:ring-opacity-50 focus-visible:ring-primary/50", "hover:ring-4 hover:ring-primary hover:ring-opacity-25 hover:ring-primary/25", "block rounded-full transition-colors focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50");
30634
+ }, props.classes, "focus-visible:ring-4 focus-visible:ring-primary focus-visible:ring-opacity-50", "hover:ring-4 hover:ring-primary hover:ring-opacity-25", "block rounded-full transition-colors focus-visible:outline-none disabled:pointer-events-none disabled:opacity-50");
30651
30635
  $[0] = props.classes;
30652
30636
  $[1] = props.props.disabled;
30653
30637
  $[2] = t1;
@@ -30665,7 +30649,7 @@
30665
30649
  }
30666
30650
  let t4;
30667
30651
  if ($[6] === Symbol.for("react.memo_cache_sentinel")) {
30668
- t4 = cls("TooltipContent", "max-w-lg leading-relaxed", "z-50 rounded px-3 py-2 text-xs leading-none bg-surface-accent-700 dark:bg-surface-accent-800 bg-opacity-90 bg-surface-accent-700/90 dark:bg-surface-accent-800/90 font-medium text-surface-accent-50 shadow-2xl select-none duration-400 ease-in transform opacity-100");
30652
+ t4 = cls("TooltipContent", "max-w-lg leading-relaxed", "z-50 rounded px-3 py-2 text-xs leading-none bg-surface-accent-700 dark:bg-surface-accent-800 bg-opacity-90 font-medium text-surface-accent-50 shadow-2xl select-none duration-400 ease-in transform opacity-100");
30669
30653
  $[6] = t4;
30670
30654
  } else {
30671
30655
  t4 = $[6];
@@ -30770,7 +30754,7 @@
30770
30754
  }
30771
30755
  let t10;
30772
30756
  if ($[15] !== t6 || $[16] !== t9) {
30773
- t10 = /* @__PURE__ */ jsxRuntime.jsx(SliderPrimitive__namespace.Track, { style: t6, className: "relative w-full grow overflow-hidden rounded-full bg-surface-accent-300 bg-opacity-40 bg-surface-accent-300/40 dark:bg-surface-700 dark:bg-opacity-40 dark:bg-surface-700/40", children: t9 });
30757
+ t10 = /* @__PURE__ */ jsxRuntime.jsx(SliderPrimitive__namespace.Track, { style: t6, className: "relative w-full grow overflow-hidden rounded-full bg-surface-accent-300 bg-opacity-40 dark:bg-surface-700 dark:bg-opacity-40", children: t9 });
30774
30758
  $[15] = t6;
30775
30759
  $[16] = t9;
30776
30760
  $[17] = t10;
@@ -30944,7 +30928,7 @@
30944
30928
  t9 = $[41];
30945
30929
  }
30946
30930
  if ($[42] !== displayed || $[43] !== includeBackgroundOverlay || $[44] !== open || $[45] !== overlayClassName || $[46] !== overlayStyle) {
30947
- t10 = includeBackgroundOverlay && /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Overlay, { className: cls("outline-none", "fixed inset-0 transition-opacity z-20 ease-in-out duration-100 backdrop-blur-sm", "bg-black bg-opacity-50 bg-black/50", "dark:bg-surface-900 dark:bg-opacity-60 dark:bg-surface-900/60", displayed && open ? "opacity-100" : "opacity-0", overlayClassName), style: {
30931
+ t10 = includeBackgroundOverlay && /* @__PURE__ */ jsxRuntime.jsx(DialogPrimitive__namespace.Overlay, { className: cls("outline-none", "fixed inset-0 transition-opacity z-20 ease-in-out duration-100 backdrop-blur-sm", "bg-black bg-opacity-50", "dark:bg-surface-900 dark:bg-opacity-60", displayed && open ? "opacity-100" : "opacity-0", overlayClassName), style: {
30948
30932
  pointerEvents: displayed ? "auto" : "none",
30949
30933
  ...overlayStyle
30950
30934
  } });
@@ -31285,13 +31269,8 @@
31285
31269
  ...inputProps
31286
31270
  }, ref) => {
31287
31271
  const inputRef = inputRefProp ?? React.useRef(null);
31288
- const [focused, setFocused] = React.useState(false);
31272
+ const [focused, setFocused] = React.useState(document.activeElement === inputRef.current);
31289
31273
  const hasValue = value !== void 0 && value !== null && value !== "";
31290
- React.useEffect(() => {
31291
- if (inputRef.current && document.activeElement === inputRef.current) {
31292
- setFocused(true);
31293
- }
31294
- }, []);
31295
31274
  React.useEffect(() => {
31296
31275
  if (type !== "number") return;
31297
31276
  const handleWheel = (event) => {
@@ -31303,7 +31282,7 @@
31303
31282
  element?.removeEventListener("wheel", handleWheel);
31304
31283
  };
31305
31284
  }, [inputRef, type]);
31306
- const input = multiline ? /* @__PURE__ */ jsxRuntime.jsx(TextareaAutosize, { ...inputProps, ref: inputRef, placeholder: focused || hasValue || !label ? placeholder : void 0, autoFocus, minRows, maxRows, value: value ?? "", onChange, onFocus: () => setFocused(true), onBlur: () => setFocused(false), style: inputStyle, className: cls(invisible ? focusedInvisibleMixin : "", "rounded-md resize-none w-full outline-none p-[32px] text-base bg-transparent min-h-[64px] px-3 pt-8", disabled && "outline-none opacity-50 text-surface-accent-600 dark:text-surface-accent-500", inputClassName) }) : /* @__PURE__ */ jsxRuntime.jsx("input", { ...inputProps, ref: inputRef, disabled, style: inputStyle, className: cls("w-full outline-none bg-transparent leading-normal px-3", "rounded-md", "focused:text-text-primary focused:dark:text-text-primary-dark", invisible ? focusedInvisibleMixin : "", disabled ? fieldBackgroundDisabledMixin : fieldBackgroundHoverMixin, {
31285
+ const input = multiline ? /* @__PURE__ */ jsxRuntime.jsx(TextareaAutosize, { ...inputProps, ref: inputRef, placeholder: focused || hasValue || !label ? placeholder : void 0, autoFocus, minRows, maxRows, value: value ?? "", onChange, style: inputStyle, className: cls(invisible ? focusedInvisibleMixin : "", "rounded-md resize-none w-full outline-none p-[32px] text-base bg-transparent min-h-[64px] px-3 pt-8", disabled && "outline-none opacity-50 text-surface-accent-600 dark:text-surface-accent-500", inputClassName) }) : /* @__PURE__ */ jsxRuntime.jsx("input", { ...inputProps, ref: inputRef, disabled, style: inputStyle, className: cls("w-full outline-none bg-transparent leading-normal px-3", "rounded-md", "focused:text-text-primary focused:dark:text-text-primary-dark", invisible ? focusedInvisibleMixin : "", disabled ? fieldBackgroundDisabledMixin : fieldBackgroundHoverMixin, {
31307
31286
  "min-h-[28px]": size === "smallest",
31308
31287
  "min-h-[32px]": size === "small",
31309
31288
  "min-h-[42px]": size === "medium",
@@ -31373,7 +31352,7 @@
31373
31352
  const trigger = t4;
31374
31353
  let t5;
31375
31354
  if ($[7] !== tooltipClassName) {
31376
- t5 = cls("TooltipContent", "max-w-lg leading-relaxed", "z-50 rounded px-3 py-2 text-xs leading-none bg-surface-accent-700 dark:bg-surface-accent-800 bg-opacity-90 bg-surface-accent-700/90 dark:bg-surface-accent-800/90 font-medium text-surface-accent-50 shadow-2xl select-none duration-400 ease-in transform opacity-100", tooltipClassName);
31355
+ t5 = cls("TooltipContent", "max-w-lg leading-relaxed", "z-50 rounded px-3 py-2 text-xs leading-none bg-surface-accent-700 dark:bg-surface-accent-800 bg-opacity-90 font-medium text-surface-accent-50 shadow-2xl select-none duration-400 ease-in transform opacity-100", tooltipClassName);
31377
31356
  $[7] = tooltipClassName;
31378
31357
  $[8] = t5;
31379
31358
  } else {
@@ -31552,7 +31531,7 @@
31552
31531
  }
31553
31532
  let t2;
31554
31533
  if ($[3] !== innerClassName) {
31555
- t2 = cls("line-clamp-1", "uppercase inline-block p-2 px-4 rounded", "hover:bg-surface-accent-200 hover:bg-opacity-75 hover:bg-surface-accent-200/75 dark:hover:bg-surface-accent-800", innerClassName);
31534
+ t2 = cls("line-clamp-1", "uppercase inline-block p-2 px-4 rounded", "hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-800", innerClassName);
31556
31535
  $[3] = innerClassName;
31557
31536
  $[4] = t2;
31558
31537
  } else {