@firecms/ui 3.0.1 → 3.1.0-canary.24c8270
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/README.md +9 -7
- package/dist/components/Card.d.ts +1 -1
- package/dist/components/ColorPicker.d.ts +30 -0
- package/dist/components/DateTimeField.d.ts +7 -0
- package/dist/components/Dialog.d.ts +2 -1
- package/dist/components/FileUpload.d.ts +1 -1
- package/dist/components/Menu.d.ts +2 -1
- package/dist/components/Menubar.d.ts +2 -1
- package/dist/components/MultiSelect.d.ts +2 -1
- package/dist/components/SearchBar.d.ts +11 -1
- package/dist/components/Select.d.ts +2 -1
- package/dist/components/Sheet.d.ts +1 -0
- package/dist/components/ToggleButtonGroup.d.ts +30 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/hooks/PortalContainerContext.d.ts +31 -0
- package/dist/hooks/index.d.ts +1 -0
- package/dist/hooks/useOutsideAlerter.d.ts +1 -1
- package/dist/index.css +57 -6
- package/dist/index.es.js +1731 -949
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +1731 -949
- package/dist/index.umd.js.map +1 -1
- package/dist/styles.d.ts +11 -11
- package/package.json +7 -7
- package/src/components/BooleanSwitch.tsx +3 -3
- package/src/components/Button.tsx +5 -5
- package/src/components/Card.tsx +7 -7
- package/src/components/Checkbox.tsx +1 -1
- package/src/components/ColorPicker.tsx +134 -0
- package/src/components/DateTimeField.tsx +123 -34
- package/src/components/DebouncedTextField.tsx +3 -3
- package/src/components/Dialog.tsx +25 -16
- package/src/components/DialogActions.tsx +1 -1
- package/src/components/ExpandablePanel.tsx +1 -1
- package/src/components/FileUpload.tsx +25 -24
- package/src/components/IconButton.tsx +3 -2
- package/src/components/Menu.tsx +44 -30
- package/src/components/Menubar.tsx +14 -3
- package/src/components/MultiSelect.tsx +91 -74
- package/src/components/Popover.tsx +11 -3
- package/src/components/SearchBar.tsx +37 -19
- package/src/components/Select.tsx +86 -73
- package/src/components/Separator.tsx +2 -2
- package/src/components/Sheet.tsx +12 -3
- package/src/components/Slider.tsx +4 -4
- package/src/components/Table.tsx +1 -1
- package/src/components/Tabs.tsx +121 -36
- package/src/components/TextField.tsx +19 -8
- package/src/components/ToggleButtonGroup.tsx +67 -0
- package/src/components/Tooltip.tsx +9 -2
- package/src/components/index.tsx +2 -0
- package/src/hooks/PortalContainerContext.tsx +48 -0
- package/src/hooks/index.ts +1 -0
- package/src/hooks/useInjectStyles.tsx +12 -3
- package/src/hooks/useOutsideAlerter.tsx +1 -1
- package/src/index.css +57 -6
- package/src/styles.ts +11 -11
- package/src/util/cls.ts +1 -1
- package/tailwind.config.js +2 -3
package/dist/index.es.js
CHANGED
|
@@ -2,12 +2,13 @@
|
|
|
2
2
|
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
3
3
|
import { c } from "react-compiler-runtime";
|
|
4
4
|
import * as React from "react";
|
|
5
|
-
import React__default, { useEffect, useState, useRef, Children, forwardRef,
|
|
5
|
+
import React__default, { createContext, useContext, useEffect, useState, useRef, Children, forwardRef, useLayoutEffect, useDeferredValue } from "react";
|
|
6
6
|
import * as Collapsible from "@radix-ui/react-collapsible";
|
|
7
7
|
import { clsx } from "clsx";
|
|
8
8
|
import { twMerge } from "tailwind-merge";
|
|
9
9
|
import * as CheckboxPrimitive from "@radix-ui/react-checkbox";
|
|
10
10
|
import "@material-design-icons/font/filled.css";
|
|
11
|
+
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
11
12
|
import * as DialogPrimitive from "@radix-ui/react-dialog";
|
|
12
13
|
import * as VisuallyHidden from "@radix-ui/react-visually-hidden";
|
|
13
14
|
import { useDropzone } from "react-dropzone";
|
|
@@ -22,21 +23,20 @@ import * as SeparatorPrimitive from "@radix-ui/react-separator";
|
|
|
22
23
|
import * as RadioGroupPrimitive from "@radix-ui/react-radio-group";
|
|
23
24
|
import * as SelectPrimitive from "@radix-ui/react-select";
|
|
24
25
|
import * as SliderPrimitive from "@radix-ui/react-slider";
|
|
25
|
-
import * as TooltipPrimitive from "@radix-ui/react-tooltip";
|
|
26
26
|
import * as ReactDOM from "react-dom";
|
|
27
27
|
import * as TabsPrimitive from "@radix-ui/react-tabs";
|
|
28
28
|
const focusedDisabled = "focus-visible:ring-0 focus-visible:ring-offset-0";
|
|
29
|
-
const focusedInvisibleMixin = "focus:bg-opacity-70 focus:bg-surface-accent-100 focus:dark:bg-surface-800 focus:dark:bg-opacity-60";
|
|
30
|
-
const focusedClasses = "z-30 outline-none ring-2 ring-primary ring-opacity-75 ring-offset-2 ring-offset-transparent ";
|
|
31
|
-
const fieldBackgroundMixin = "bg-opacity-50 bg-surface-accent-200 dark:bg-surface-800 dark:bg-opacity-60";
|
|
32
|
-
const fieldBackgroundInvisibleMixin = "bg-opacity-0 bg-surface-accent-100 dark:bg-surface-800 dark:bg-opacity-0";
|
|
33
|
-
const fieldBackgroundDisabledMixin = "dark:bg-surface-800 bg-opacity-50 dark:bg-opacity-90";
|
|
34
|
-
const fieldBackgroundHoverMixin = "hover:bg-opacity-70 dark:hover:bg-surface-700 dark:hover:bg-opacity-40";
|
|
35
|
-
const defaultBorderMixin = "border-surface-200 border-opacity-40 dark:border-surface-700 dark:border-opacity-40";
|
|
36
|
-
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";
|
|
37
|
-
const cardMixin = "bg-white
|
|
38
|
-
const cardClickableMixin = "hover:bg-surface-accent-100 dark:hover:bg-surface-accent-800 hover:ring-2 hover:ring-primary cursor-pointer";
|
|
39
|
-
const cardSelectedMixin = "bg-primary-bg dark:bg-primary-bg bg-opacity-30 dark:bg-opacity-10 ring-1 ring-primary ring-opacity-75";
|
|
29
|
+
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";
|
|
30
|
+
const focusedClasses = "z-30 outline-hidden outline-none ring-2 ring-primary ring-opacity-75 ring-primary/75 ring-offset-2 ring-offset-transparent ";
|
|
31
|
+
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";
|
|
32
|
+
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";
|
|
33
|
+
const fieldBackgroundDisabledMixin = "dark:bg-surface-800 bg-opacity-50 dark:bg-opacity-90 bg-surface-accent-200/50 dark:bg-surface-800/90";
|
|
34
|
+
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";
|
|
35
|
+
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 ";
|
|
36
|
+
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";
|
|
37
|
+
const cardMixin = "bg-white dark:bg-surface-950 rounded-md border border-surface-200/40 dark:border-surface-700/40 m-1 -p-1";
|
|
38
|
+
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 ";
|
|
39
|
+
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";
|
|
40
40
|
function cls(...classes) {
|
|
41
41
|
return twMerge(clsx(classes));
|
|
42
42
|
}
|
|
@@ -247,31 +247,69 @@ function keyToIconComponent(key) {
|
|
|
247
247
|
}).join("") + "Icon";
|
|
248
248
|
return componentName;
|
|
249
249
|
}
|
|
250
|
+
const PortalContainerContext = createContext(void 0);
|
|
251
|
+
function PortalContainerProvider(t0) {
|
|
252
|
+
const $ = c(5);
|
|
253
|
+
const {
|
|
254
|
+
container,
|
|
255
|
+
children
|
|
256
|
+
} = t0;
|
|
257
|
+
let t1;
|
|
258
|
+
if ($[0] !== container) {
|
|
259
|
+
t1 = {
|
|
260
|
+
container
|
|
261
|
+
};
|
|
262
|
+
$[0] = container;
|
|
263
|
+
$[1] = t1;
|
|
264
|
+
} else {
|
|
265
|
+
t1 = $[1];
|
|
266
|
+
}
|
|
267
|
+
let t2;
|
|
268
|
+
if ($[2] !== children || $[3] !== t1) {
|
|
269
|
+
t2 = /* @__PURE__ */ jsx(PortalContainerContext.Provider, { value: t1, children });
|
|
270
|
+
$[2] = children;
|
|
271
|
+
$[3] = t1;
|
|
272
|
+
$[4] = t2;
|
|
273
|
+
} else {
|
|
274
|
+
t2 = $[4];
|
|
275
|
+
}
|
|
276
|
+
return t2;
|
|
277
|
+
}
|
|
278
|
+
function usePortalContainer() {
|
|
279
|
+
const context = useContext(PortalContainerContext);
|
|
280
|
+
return context?.container ?? null;
|
|
281
|
+
}
|
|
250
282
|
function useInjectStyles(key, styles2) {
|
|
251
|
-
const $ = c(
|
|
283
|
+
const $ = c(5);
|
|
284
|
+
const portalContainer = usePortalContainer();
|
|
252
285
|
let t0;
|
|
253
|
-
if ($[0] !== key || $[1] !== styles2) {
|
|
286
|
+
if ($[0] !== key || $[1] !== portalContainer || $[2] !== styles2) {
|
|
254
287
|
t0 = () => {
|
|
255
|
-
|
|
256
|
-
|
|
288
|
+
if (typeof document === "undefined") {
|
|
289
|
+
return;
|
|
290
|
+
}
|
|
291
|
+
const targetContainer = portalContainer ?? document.head;
|
|
292
|
+
const existingStyle = targetContainer.querySelector?.(`#${key}`);
|
|
293
|
+
if (!existingStyle) {
|
|
257
294
|
const style = document.createElement("style");
|
|
258
295
|
style.id = key;
|
|
259
296
|
style.innerHTML = styles2;
|
|
260
|
-
document.head.appendChild(style);
|
|
297
|
+
(targetContainer || document.head).appendChild(style);
|
|
261
298
|
}
|
|
262
299
|
};
|
|
263
300
|
$[0] = key;
|
|
264
|
-
$[1] =
|
|
265
|
-
$[2] =
|
|
301
|
+
$[1] = portalContainer;
|
|
302
|
+
$[2] = styles2;
|
|
303
|
+
$[3] = t0;
|
|
266
304
|
} else {
|
|
267
|
-
t0 = $[
|
|
305
|
+
t0 = $[3];
|
|
268
306
|
}
|
|
269
307
|
let t1;
|
|
270
|
-
if ($[
|
|
308
|
+
if ($[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
271
309
|
t1 = [];
|
|
272
|
-
$[
|
|
310
|
+
$[4] = t1;
|
|
273
311
|
} else {
|
|
274
|
-
t1 = $[
|
|
312
|
+
t1 = $[4];
|
|
275
313
|
}
|
|
276
314
|
useEffect(t0, t1);
|
|
277
315
|
}
|
|
@@ -742,7 +780,7 @@ const BooleanSwitch = React__default.forwardRef(function BooleanSwitch2({
|
|
|
742
780
|
} else {
|
|
743
781
|
onValueChange?.(!value);
|
|
744
782
|
}
|
|
745
|
-
}, 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-[44px] h-[26px] min-w-[44px] 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: [
|
|
783
|
+
}, 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-[44px] h-[26px] min-w-[44px] 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: [
|
|
746
784
|
allowIndeterminate && (value === null || value === void 0) && /* @__PURE__ */ 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", {
|
|
747
785
|
"w-[21px] h-[10px]": size === "medium" || size === "large",
|
|
748
786
|
"w-[19px] h-[8px]": size === "small",
|
|
@@ -891,12 +929,12 @@ const ButtonInner = React__default.memo(React__default.forwardRef((t0, ref) => {
|
|
|
891
929
|
"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,
|
|
892
930
|
"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,
|
|
893
931
|
"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,
|
|
894
|
-
"border border-transparent text-primary hover:text-primary hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-800": t13,
|
|
895
|
-
"border border-transparent text-secondary hover:text-secondary hover:bg-surface-accent-200 hover:bg-opacity-75 dark:hover:bg-surface-accent-800": t14,
|
|
896
|
-
"border border-transparent text-red-500 hover:text-red-500 hover:bg-red-500 hover:bg-opacity-10": t15,
|
|
932
|
+
"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,
|
|
933
|
+
"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,
|
|
934
|
+
"border border-transparent text-red-500 hover:text-red-500 hover:bg-red-500 hover:bg-opacity-10 hover:bg-red-500/10": t15,
|
|
897
935
|
"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,
|
|
898
936
|
"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,
|
|
899
|
-
"border border-primary text-primary hover:text-primary hover:bg-primary-bg": t18,
|
|
937
|
+
"border border-primary text-primary hover:text-primary hover:bg-primary-bg hover:bg-primary/10": t18,
|
|
900
938
|
"border border-secondary text-secondary hover:text-secondary hover:bg-secondary-bg": t19,
|
|
901
939
|
"border border-red-500 text-red-500 hover:text-red-500 hover:bg-red-500 hover:text-white": t20,
|
|
902
940
|
"border border-surface-accent-400 text-text-primary hover:text-text-primary dark:text-text-primary-dark hover:bg-surface-accent-200": t21,
|
|
@@ -904,7 +942,7 @@ const ButtonInner = React__default.memo(React__default.forwardRef((t0, ref) => {
|
|
|
904
942
|
"text-text-disabled dark:text-text-disabled-dark": disabled,
|
|
905
943
|
"border border-transparent opacity-50": t23,
|
|
906
944
|
"border border-surface-500 opacity-50": t24,
|
|
907
|
-
"border border-transparent bg-surface-300 dark:bg-surface-500 opacity-40": t25
|
|
945
|
+
"border border-transparent bg-surface-300 dark:bg-surface-500 opacity-40 bg-surface-300/40 dark:bg-surface-500/40": t25
|
|
908
946
|
});
|
|
909
947
|
const sizeClasses2 = cls({
|
|
910
948
|
"py-1 px-2": size === "small",
|
|
@@ -32172,7 +32210,7 @@ const Checkbox = React__default.memo((t0) => {
|
|
|
32172
32210
|
const t6 = disabled ? void 0 : onCheckedChange;
|
|
32173
32211
|
const t7 = padding ? paddingClasses[size] : "";
|
|
32174
32212
|
const t8 = outerSizeClasses[size];
|
|
32175
|
-
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" : "";
|
|
32213
|
+
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" : "";
|
|
32176
32214
|
const t10 = onCheckedChange ? "cursor-pointer" : "cursor-default";
|
|
32177
32215
|
let t11;
|
|
32178
32216
|
if ($[0] !== t10 || $[1] !== t7 || $[2] !== t8 || $[3] !== t9) {
|
|
@@ -32318,7 +32356,258 @@ function Chip(t0) {
|
|
|
32318
32356
|
}
|
|
32319
32357
|
return t11;
|
|
32320
32358
|
}
|
|
32321
|
-
const
|
|
32359
|
+
const Tooltip = (t0) => {
|
|
32360
|
+
const $ = c(28);
|
|
32361
|
+
const {
|
|
32362
|
+
open,
|
|
32363
|
+
defaultOpen,
|
|
32364
|
+
side: t1,
|
|
32365
|
+
delayDuration: t2,
|
|
32366
|
+
sideOffset,
|
|
32367
|
+
align,
|
|
32368
|
+
onOpenChange,
|
|
32369
|
+
title,
|
|
32370
|
+
tooltipClassName,
|
|
32371
|
+
tooltipStyle,
|
|
32372
|
+
children,
|
|
32373
|
+
asChild: t3,
|
|
32374
|
+
container,
|
|
32375
|
+
className,
|
|
32376
|
+
style
|
|
32377
|
+
} = t0;
|
|
32378
|
+
const side = t1 === void 0 ? "bottom" : t1;
|
|
32379
|
+
const delayDuration = t2 === void 0 ? 200 : t2;
|
|
32380
|
+
const asChild = t3 === void 0 ? false : t3;
|
|
32381
|
+
useInjectStyles("Tooltip", styles$1);
|
|
32382
|
+
const contextContainer = usePortalContainer();
|
|
32383
|
+
const finalContainer = container ?? contextContainer ?? void 0;
|
|
32384
|
+
if (!title) {
|
|
32385
|
+
let t42;
|
|
32386
|
+
if ($[0] !== children) {
|
|
32387
|
+
t42 = /* @__PURE__ */ jsx(Fragment, { children });
|
|
32388
|
+
$[0] = children;
|
|
32389
|
+
$[1] = t42;
|
|
32390
|
+
} else {
|
|
32391
|
+
t42 = $[1];
|
|
32392
|
+
}
|
|
32393
|
+
return t42;
|
|
32394
|
+
}
|
|
32395
|
+
let t4;
|
|
32396
|
+
if ($[2] !== asChild || $[3] !== children || $[4] !== className || $[5] !== style) {
|
|
32397
|
+
t4 = asChild ? /* @__PURE__ */ jsx(TooltipPrimitive.Trigger, { asChild: true, children }) : /* @__PURE__ */ jsx(TooltipPrimitive.Trigger, { asChild: true, children: /* @__PURE__ */ jsx("div", { style, className, children }) });
|
|
32398
|
+
$[2] = asChild;
|
|
32399
|
+
$[3] = children;
|
|
32400
|
+
$[4] = className;
|
|
32401
|
+
$[5] = style;
|
|
32402
|
+
$[6] = t4;
|
|
32403
|
+
} else {
|
|
32404
|
+
t4 = $[6];
|
|
32405
|
+
}
|
|
32406
|
+
const trigger = t4;
|
|
32407
|
+
let t5;
|
|
32408
|
+
if ($[7] !== tooltipClassName) {
|
|
32409
|
+
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);
|
|
32410
|
+
$[7] = tooltipClassName;
|
|
32411
|
+
$[8] = t5;
|
|
32412
|
+
} else {
|
|
32413
|
+
t5 = $[8];
|
|
32414
|
+
}
|
|
32415
|
+
const t6 = sideOffset === void 0 ? 4 : sideOffset;
|
|
32416
|
+
let t7;
|
|
32417
|
+
if ($[9] !== align || $[10] !== side || $[11] !== t5 || $[12] !== t6 || $[13] !== title || $[14] !== tooltipStyle) {
|
|
32418
|
+
t7 = /* @__PURE__ */ jsx(TooltipPrimitive.Content, { className: t5, style: tooltipStyle, sideOffset: t6, align, side, children: title });
|
|
32419
|
+
$[9] = align;
|
|
32420
|
+
$[10] = side;
|
|
32421
|
+
$[11] = t5;
|
|
32422
|
+
$[12] = t6;
|
|
32423
|
+
$[13] = title;
|
|
32424
|
+
$[14] = tooltipStyle;
|
|
32425
|
+
$[15] = t7;
|
|
32426
|
+
} else {
|
|
32427
|
+
t7 = $[15];
|
|
32428
|
+
}
|
|
32429
|
+
let t8;
|
|
32430
|
+
if ($[16] !== finalContainer || $[17] !== t7) {
|
|
32431
|
+
t8 = /* @__PURE__ */ jsx(TooltipPrimitive.Portal, { container: finalContainer, children: t7 });
|
|
32432
|
+
$[16] = finalContainer;
|
|
32433
|
+
$[17] = t7;
|
|
32434
|
+
$[18] = t8;
|
|
32435
|
+
} else {
|
|
32436
|
+
t8 = $[18];
|
|
32437
|
+
}
|
|
32438
|
+
let t9;
|
|
32439
|
+
if ($[19] !== defaultOpen || $[20] !== onOpenChange || $[21] !== open || $[22] !== t8 || $[23] !== trigger) {
|
|
32440
|
+
t9 = /* @__PURE__ */ jsxs(TooltipPrimitive.Root, { open, onOpenChange, defaultOpen, children: [
|
|
32441
|
+
trigger,
|
|
32442
|
+
t8
|
|
32443
|
+
] });
|
|
32444
|
+
$[19] = defaultOpen;
|
|
32445
|
+
$[20] = onOpenChange;
|
|
32446
|
+
$[21] = open;
|
|
32447
|
+
$[22] = t8;
|
|
32448
|
+
$[23] = trigger;
|
|
32449
|
+
$[24] = t9;
|
|
32450
|
+
} else {
|
|
32451
|
+
t9 = $[24];
|
|
32452
|
+
}
|
|
32453
|
+
let t10;
|
|
32454
|
+
if ($[25] !== delayDuration || $[26] !== t9) {
|
|
32455
|
+
t10 = /* @__PURE__ */ jsx(TooltipPrimitive.Provider, { delayDuration, children: t9 });
|
|
32456
|
+
$[25] = delayDuration;
|
|
32457
|
+
$[26] = t9;
|
|
32458
|
+
$[27] = t10;
|
|
32459
|
+
} else {
|
|
32460
|
+
t10 = $[27];
|
|
32461
|
+
}
|
|
32462
|
+
return t10;
|
|
32463
|
+
};
|
|
32464
|
+
const styles$1 = `
|
|
32465
|
+
|
|
32466
|
+
.TooltipContent {
|
|
32467
|
+
animation-duration: 220ms;
|
|
32468
|
+
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
|
32469
|
+
will-change: transform, opacity;
|
|
32470
|
+
}
|
|
32471
|
+
|
|
32472
|
+
.TooltipContent[data-state='delayed-open'][data-side='top'] {
|
|
32473
|
+
animation-name: slideDownAndFade;
|
|
32474
|
+
}
|
|
32475
|
+
.TooltipContent[data-state='delayed-open'][data-side='right'] {
|
|
32476
|
+
animation-name: slideLeftAndFade;
|
|
32477
|
+
}
|
|
32478
|
+
.TooltipContent[data-state='delayed-open'][data-side='bottom'] {
|
|
32479
|
+
animation-name: slideUpAndFade;
|
|
32480
|
+
}
|
|
32481
|
+
.TooltipContent[data-state='delayed-open'][data-side='left'] {
|
|
32482
|
+
animation-name: slideRightAndFade;
|
|
32483
|
+
}
|
|
32484
|
+
|
|
32485
|
+
|
|
32486
|
+
@keyframes slideUpAndFade {
|
|
32487
|
+
from {
|
|
32488
|
+
opacity: 0;
|
|
32489
|
+
transform: translateY(4px);
|
|
32490
|
+
}
|
|
32491
|
+
to {
|
|
32492
|
+
opacity: 1;
|
|
32493
|
+
transform: translateY(0);
|
|
32494
|
+
}
|
|
32495
|
+
}
|
|
32496
|
+
|
|
32497
|
+
@keyframes slideRightAndFade {
|
|
32498
|
+
from {
|
|
32499
|
+
opacity: 0;
|
|
32500
|
+
transform: translateX(-4px);
|
|
32501
|
+
}
|
|
32502
|
+
to {
|
|
32503
|
+
opacity: 1;
|
|
32504
|
+
transform: translateX(0);
|
|
32505
|
+
}
|
|
32506
|
+
}
|
|
32507
|
+
|
|
32508
|
+
@keyframes slideDownAndFade {
|
|
32509
|
+
from {
|
|
32510
|
+
opacity: 0;
|
|
32511
|
+
transform: translateY(-4px);
|
|
32512
|
+
}
|
|
32513
|
+
to {
|
|
32514
|
+
opacity: 1;
|
|
32515
|
+
transform: translateY(0);
|
|
32516
|
+
}
|
|
32517
|
+
}
|
|
32518
|
+
|
|
32519
|
+
@keyframes slideLeftAndFade {
|
|
32520
|
+
from {
|
|
32521
|
+
opacity: 0;
|
|
32522
|
+
transform: translateX(4px);
|
|
32523
|
+
}
|
|
32524
|
+
to {
|
|
32525
|
+
opacity: 1;
|
|
32526
|
+
transform: translateX(0);
|
|
32527
|
+
}
|
|
32528
|
+
}`;
|
|
32529
|
+
const BASE_COLORS = ["blue", "cyan", "teal", "green", "yellow", "orange", "red", "pink", "purple", "gray"];
|
|
32530
|
+
const VARIANTS = ["Darker", "Dark", "Light", "Lighter"];
|
|
32531
|
+
function getColorDisplayName(colorKey) {
|
|
32532
|
+
const base = colorKey.replace(/(Lighter|Light|Dark|Darker)$/, "");
|
|
32533
|
+
const variant = colorKey.replace(base, "");
|
|
32534
|
+
return `${base.charAt(0).toUpperCase()}${base.slice(1)} ${variant}`;
|
|
32535
|
+
}
|
|
32536
|
+
function ColorPicker(t0) {
|
|
32537
|
+
const $ = c(18);
|
|
32538
|
+
const {
|
|
32539
|
+
value,
|
|
32540
|
+
onChange,
|
|
32541
|
+
size: t1,
|
|
32542
|
+
allowClear: t2,
|
|
32543
|
+
disabled: t3
|
|
32544
|
+
} = t0;
|
|
32545
|
+
const size = t1 === void 0 ? "medium" : t1;
|
|
32546
|
+
const allowClear = t2 === void 0 ? true : t2;
|
|
32547
|
+
const disabled = t3 === void 0 ? false : t3;
|
|
32548
|
+
const swatchSize = size === "small" ? "w-5 h-5" : "w-6 h-6";
|
|
32549
|
+
const checkSize = size === "small" ? 12 : 14;
|
|
32550
|
+
let t4;
|
|
32551
|
+
if ($[0] !== allowClear || $[1] !== checkSize || $[2] !== disabled || $[3] !== onChange || $[4] !== swatchSize || $[5] !== value) {
|
|
32552
|
+
t4 = allowClear && /* @__PURE__ */ jsxs("button", { type: "button", disabled, onClick: () => onChange(void 0), className: cls("flex items-center gap-2 px-2 py-1 rounded text-sm transition-colors", "hover:bg-surface-accent-100 dark:hover:bg-surface-accent-800", disabled && "opacity-50 cursor-not-allowed", !value && "bg-surface-accent-100 dark:bg-surface-accent-800 font-medium"), children: [
|
|
32553
|
+
/* @__PURE__ */ jsx("div", { className: cls(swatchSize, "rounded-full border-2 border-dashed border-surface-accent-400 dark:border-surface-accent-600", "flex items-center justify-center"), children: !value && /* @__PURE__ */ jsx(CheckIcon, { size: checkSize }) }),
|
|
32554
|
+
/* @__PURE__ */ jsx("span", { className: "text-surface-accent-700 dark:text-surface-accent-300", children: "Auto (based on ID)" })
|
|
32555
|
+
] });
|
|
32556
|
+
$[0] = allowClear;
|
|
32557
|
+
$[1] = checkSize;
|
|
32558
|
+
$[2] = disabled;
|
|
32559
|
+
$[3] = onChange;
|
|
32560
|
+
$[4] = swatchSize;
|
|
32561
|
+
$[5] = value;
|
|
32562
|
+
$[6] = t4;
|
|
32563
|
+
} else {
|
|
32564
|
+
t4 = $[6];
|
|
32565
|
+
}
|
|
32566
|
+
let t5;
|
|
32567
|
+
if ($[7] !== checkSize || $[8] !== disabled || $[9] !== onChange || $[10] !== swatchSize || $[11] !== value) {
|
|
32568
|
+
t5 = VARIANTS.map((variant) => BASE_COLORS.map((base) => {
|
|
32569
|
+
const colorKey = `${base}${variant}`;
|
|
32570
|
+
const colorScheme = CHIP_COLORS[colorKey];
|
|
32571
|
+
const isSelected = value === colorKey;
|
|
32572
|
+
const displayName = getColorDisplayName(colorKey);
|
|
32573
|
+
return /* @__PURE__ */ jsx(Tooltip, { title: displayName, delayDuration: 300, children: /* @__PURE__ */ jsx("button", { type: "button", disabled, onClick: () => onChange(colorKey), className: cls(swatchSize, "rounded-full transition-all flex items-center justify-center", "hover:scale-110 hover:shadow-md", "focus:outline-none focus:ring-2 focus:ring-primary focus:ring-offset-1", disabled && "opacity-50 cursor-not-allowed hover:scale-100", isSelected && "ring-2 ring-primary ring-offset-1"), style: {
|
|
32574
|
+
backgroundColor: colorScheme.color
|
|
32575
|
+
}, "aria-label": displayName, "aria-pressed": isSelected, children: isSelected && /* @__PURE__ */ jsx(CheckIcon, { size: checkSize, style: {
|
|
32576
|
+
color: colorScheme.text
|
|
32577
|
+
} }) }) }, colorKey);
|
|
32578
|
+
}));
|
|
32579
|
+
$[7] = checkSize;
|
|
32580
|
+
$[8] = disabled;
|
|
32581
|
+
$[9] = onChange;
|
|
32582
|
+
$[10] = swatchSize;
|
|
32583
|
+
$[11] = value;
|
|
32584
|
+
$[12] = t5;
|
|
32585
|
+
} else {
|
|
32586
|
+
t5 = $[12];
|
|
32587
|
+
}
|
|
32588
|
+
let t6;
|
|
32589
|
+
if ($[13] !== t5) {
|
|
32590
|
+
t6 = /* @__PURE__ */ jsx("div", { className: "grid grid-cols-10 gap-1", children: t5 });
|
|
32591
|
+
$[13] = t5;
|
|
32592
|
+
$[14] = t6;
|
|
32593
|
+
} else {
|
|
32594
|
+
t6 = $[14];
|
|
32595
|
+
}
|
|
32596
|
+
let t7;
|
|
32597
|
+
if ($[15] !== t4 || $[16] !== t6) {
|
|
32598
|
+
t7 = /* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2", children: [
|
|
32599
|
+
t4,
|
|
32600
|
+
t6
|
|
32601
|
+
] });
|
|
32602
|
+
$[15] = t4;
|
|
32603
|
+
$[16] = t6;
|
|
32604
|
+
$[17] = t7;
|
|
32605
|
+
} else {
|
|
32606
|
+
t7 = $[17];
|
|
32607
|
+
}
|
|
32608
|
+
return t7;
|
|
32609
|
+
}
|
|
32610
|
+
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";
|
|
32322
32611
|
const baseClasses = "inline-flex items-center justify-center p-2 text-sm font-medium focus:outline-none transition-colors ease-in-out duration-150";
|
|
32323
32612
|
const colorClasses$1 = "text-surface-accent-600 visited:text-surface-accent-600 dark:text-surface-accent-300 dark:visited:text-surface-300";
|
|
32324
32613
|
const sizeClasses = {
|
|
@@ -32378,7 +32667,7 @@ const IconButtonInner = (t0, ref) => {
|
|
|
32378
32667
|
const size = t1 === void 0 ? "medium" : t1;
|
|
32379
32668
|
const variant = t2 === void 0 ? "ghost" : t2;
|
|
32380
32669
|
const shape = t3 === void 0 ? "circular" : t3;
|
|
32381
|
-
const bgClasses = variant === "ghost" ? "bg-transparent" : "bg-surface-accent-200 bg-opacity-50 dark:bg-surface-950 dark:bg-opacity-50";
|
|
32670
|
+
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";
|
|
32382
32671
|
const Component = component || "button";
|
|
32383
32672
|
const t4 = disabled ? "opacity-50 pointer-events-none" : "cursor-pointer";
|
|
32384
32673
|
const t5 = toggled ? "outline outline-2 outline-primary" : "";
|
|
@@ -32386,7 +32675,7 @@ const IconButtonInner = (t0, ref) => {
|
|
|
32386
32675
|
const t7 = sizeClasses[size];
|
|
32387
32676
|
let t8;
|
|
32388
32677
|
if ($[10] !== bgClasses || $[11] !== className || $[12] !== t4 || $[13] !== t5 || $[14] !== t6 || $[15] !== t7) {
|
|
32389
|
-
t8 = cls(t4, t5, colorClasses$1, bgClasses, baseClasses, buttonClasses, t6, t7, className);
|
|
32678
|
+
t8 = cls(t4, t5, "text-inherit dark:text-inherit", colorClasses$1, bgClasses, baseClasses, buttonClasses, t6, t7, className);
|
|
32390
32679
|
$[10] = bgClasses;
|
|
32391
32680
|
$[11] = className;
|
|
32392
32681
|
$[12] = t4;
|
|
@@ -32637,7 +32926,8 @@ const DateTimeField = ({
|
|
|
32637
32926
|
className,
|
|
32638
32927
|
style,
|
|
32639
32928
|
inputClassName,
|
|
32640
|
-
invisible
|
|
32929
|
+
invisible,
|
|
32930
|
+
timezone
|
|
32641
32931
|
}) => {
|
|
32642
32932
|
const inputRef = useRef(null);
|
|
32643
32933
|
const [focused, setFocused] = useState(false);
|
|
@@ -32655,18 +32945,59 @@ const DateTimeField = ({
|
|
|
32655
32945
|
if (!dateValue) {
|
|
32656
32946
|
return "";
|
|
32657
32947
|
}
|
|
32658
|
-
const
|
|
32659
|
-
|
|
32660
|
-
|
|
32661
|
-
|
|
32948
|
+
const options = {
|
|
32949
|
+
year: "numeric",
|
|
32950
|
+
month: "2-digit",
|
|
32951
|
+
day: "2-digit",
|
|
32952
|
+
hour: "2-digit",
|
|
32953
|
+
minute: "2-digit",
|
|
32954
|
+
hour12: false,
|
|
32955
|
+
timeZone: timezone
|
|
32956
|
+
// undefined = local timezone
|
|
32957
|
+
};
|
|
32958
|
+
const formatter = new Intl.DateTimeFormat("en-CA", options);
|
|
32959
|
+
const parts = formatter.formatToParts(dateValue);
|
|
32960
|
+
const getPart = (type) => parts.find((p) => p.type === type)?.value ?? "";
|
|
32961
|
+
const year = getPart("year");
|
|
32962
|
+
const month = getPart("month");
|
|
32963
|
+
const day = getPart("day");
|
|
32662
32964
|
if (mode_0 === "date") {
|
|
32663
32965
|
return `${year}-${month}-${day}`;
|
|
32664
32966
|
} else {
|
|
32665
|
-
const hours =
|
|
32666
|
-
const minutes =
|
|
32967
|
+
const hours = getPart("hour");
|
|
32968
|
+
const minutes = getPart("minute");
|
|
32667
32969
|
return `${year}-${month}-${day}T${hours}:${minutes}`;
|
|
32668
32970
|
}
|
|
32669
32971
|
};
|
|
32972
|
+
const getTimezoneOffsetMinutes = (date, tz) => {
|
|
32973
|
+
if (!tz) {
|
|
32974
|
+
return -date.getTimezoneOffset();
|
|
32975
|
+
}
|
|
32976
|
+
const utcFormatter = new Intl.DateTimeFormat("en-CA", {
|
|
32977
|
+
year: "numeric",
|
|
32978
|
+
month: "2-digit",
|
|
32979
|
+
day: "2-digit",
|
|
32980
|
+
hour: "2-digit",
|
|
32981
|
+
minute: "2-digit",
|
|
32982
|
+
hour12: false,
|
|
32983
|
+
timeZone: "UTC"
|
|
32984
|
+
});
|
|
32985
|
+
const tzFormatter = new Intl.DateTimeFormat("en-CA", {
|
|
32986
|
+
year: "numeric",
|
|
32987
|
+
month: "2-digit",
|
|
32988
|
+
day: "2-digit",
|
|
32989
|
+
hour: "2-digit",
|
|
32990
|
+
minute: "2-digit",
|
|
32991
|
+
hour12: false,
|
|
32992
|
+
timeZone: tz
|
|
32993
|
+
});
|
|
32994
|
+
const utcParts = utcFormatter.formatToParts(date);
|
|
32995
|
+
const tzParts = tzFormatter.formatToParts(date);
|
|
32996
|
+
const getPart_0 = (parts_0, type_0) => parseInt(parts_0.find((p_0) => p_0.type === type_0)?.value ?? "0", 10);
|
|
32997
|
+
const utcDate = new Date(Date.UTC(getPart_0(utcParts, "year"), getPart_0(utcParts, "month") - 1, getPart_0(utcParts, "day"), getPart_0(utcParts, "hour"), getPart_0(utcParts, "minute")));
|
|
32998
|
+
const tzDate = new Date(Date.UTC(getPart_0(tzParts, "year"), getPart_0(tzParts, "month") - 1, getPart_0(tzParts, "day"), getPart_0(tzParts, "hour"), getPart_0(tzParts, "minute")));
|
|
32999
|
+
return (tzDate.getTime() - utcDate.getTime()) / 6e4;
|
|
33000
|
+
};
|
|
32670
33001
|
const handleInputChange = (e_0) => {
|
|
32671
33002
|
const inputValue = e_0.target.value;
|
|
32672
33003
|
setInternalValue(inputValue);
|
|
@@ -32676,18 +33007,26 @@ const DateTimeField = ({
|
|
|
32676
33007
|
return;
|
|
32677
33008
|
}
|
|
32678
33009
|
try {
|
|
32679
|
-
|
|
32680
|
-
if (isNaN(parsed.getTime())) {
|
|
32681
|
-
throw new Error("Invalid date");
|
|
32682
|
-
}
|
|
32683
|
-
let newDate;
|
|
33010
|
+
let year_0, month_0, day_0, hours_0 = 0, minutes_0 = 0;
|
|
32684
33011
|
if (mode === "date") {
|
|
32685
|
-
|
|
32686
|
-
|
|
33012
|
+
[year_0, month_0, day_0] = inputValue.split("-").map(Number);
|
|
33013
|
+
} else {
|
|
33014
|
+
const [datePart, timePart] = inputValue.split("T");
|
|
33015
|
+
[year_0, month_0, day_0] = datePart.split("-").map(Number);
|
|
33016
|
+
[hours_0, minutes_0] = timePart.split(":").map(Number);
|
|
33017
|
+
}
|
|
33018
|
+
let resultDate;
|
|
33019
|
+
if (!timezone) {
|
|
33020
|
+
resultDate = new Date(year_0, month_0 - 1, day_0, hours_0, minutes_0);
|
|
32687
33021
|
} else {
|
|
32688
|
-
|
|
33022
|
+
const refUtcDate = new Date(Date.UTC(year_0, month_0 - 1, day_0, hours_0, minutes_0));
|
|
33023
|
+
const offsetMinutes = getTimezoneOffsetMinutes(refUtcDate, timezone);
|
|
33024
|
+
resultDate = new Date(Date.UTC(year_0, month_0 - 1, day_0, hours_0, minutes_0) - offsetMinutes * 6e4);
|
|
33025
|
+
}
|
|
33026
|
+
if (isNaN(resultDate.getTime())) {
|
|
33027
|
+
throw new Error("Invalid date");
|
|
32689
33028
|
}
|
|
32690
|
-
onChange?.(
|
|
33029
|
+
onChange?.(resultDate);
|
|
32691
33030
|
} catch (e_1) {
|
|
32692
33031
|
return;
|
|
32693
33032
|
}
|
|
@@ -32756,21 +33095,21 @@ const inputStyles = `
|
|
|
32756
33095
|
}
|
|
32757
33096
|
`;
|
|
32758
33097
|
const widthClasses = {
|
|
32759
|
-
xs: "max-w-xs
|
|
32760
|
-
sm: "max-w-sm
|
|
32761
|
-
md: "max-w-md
|
|
32762
|
-
lg: "max-w-lg
|
|
32763
|
-
xl: "max-w-xl
|
|
32764
|
-
"2xl": "max-w-2xl
|
|
32765
|
-
"3xl": "max-w-3xl
|
|
32766
|
-
"4xl": "max-w-4xl
|
|
32767
|
-
"5xl": "max-w-5xl
|
|
32768
|
-
"6xl": "max-w-6xl
|
|
32769
|
-
"7xl": "max-w-7xl
|
|
32770
|
-
full: "max-w-full
|
|
33098
|
+
xs: "max-w-xs w-xs",
|
|
33099
|
+
sm: "max-w-sm w-sm",
|
|
33100
|
+
md: "max-w-md w-md",
|
|
33101
|
+
lg: "max-w-lg w-lg",
|
|
33102
|
+
xl: "max-w-xl w-xl",
|
|
33103
|
+
"2xl": "max-w-2xl w-2xl",
|
|
33104
|
+
"3xl": "max-w-3xl w-3xl",
|
|
33105
|
+
"4xl": "max-w-4xl w-4xl",
|
|
33106
|
+
"5xl": "max-w-5xl w-5xl",
|
|
33107
|
+
"6xl": "max-w-6xl w-6xl",
|
|
33108
|
+
"7xl": "max-w-7xl w-7xl",
|
|
33109
|
+
full: "max-w-full w-full"
|
|
32771
33110
|
};
|
|
32772
33111
|
const Dialog = (t0) => {
|
|
32773
|
-
const $ = c(
|
|
33112
|
+
const $ = c(45);
|
|
32774
33113
|
const {
|
|
32775
33114
|
open,
|
|
32776
33115
|
onOpenChange,
|
|
@@ -32787,7 +33126,8 @@ const Dialog = (t0) => {
|
|
|
32787
33126
|
onEscapeKeyDown,
|
|
32788
33127
|
onPointerDownOutside,
|
|
32789
33128
|
onInteractOutside,
|
|
32790
|
-
disableInitialFocus: t5
|
|
33129
|
+
disableInitialFocus: t5,
|
|
33130
|
+
portalContainer
|
|
32791
33131
|
} = t0;
|
|
32792
33132
|
const fullWidth = t1 === void 0 ? true : t1;
|
|
32793
33133
|
const scrollable = t2 === void 0 ? true : t2;
|
|
@@ -32795,6 +33135,8 @@ const Dialog = (t0) => {
|
|
|
32795
33135
|
const modal = t4 === void 0 ? true : t4;
|
|
32796
33136
|
const disableInitialFocus = t5 === void 0 ? true : t5;
|
|
32797
33137
|
const [displayed, setDisplayed] = useState(false);
|
|
33138
|
+
const contextContainer = usePortalContainer();
|
|
33139
|
+
const finalContainer = portalContainer ?? contextContainer ?? void 0;
|
|
32798
33140
|
let t6;
|
|
32799
33141
|
let t7;
|
|
32800
33142
|
if ($[0] !== open) {
|
|
@@ -32802,11 +33144,11 @@ const Dialog = (t0) => {
|
|
|
32802
33144
|
if (!open) {
|
|
32803
33145
|
const timeout = setTimeout(() => {
|
|
32804
33146
|
setDisplayed(false);
|
|
32805
|
-
},
|
|
33147
|
+
}, 100);
|
|
32806
33148
|
return () => clearTimeout(timeout);
|
|
32807
33149
|
} else {
|
|
32808
33150
|
setDisplayed(true);
|
|
32809
|
-
return _temp$
|
|
33151
|
+
return _temp$3;
|
|
32810
33152
|
}
|
|
32811
33153
|
};
|
|
32812
33154
|
t7 = [open];
|
|
@@ -32830,7 +33172,7 @@ const Dialog = (t0) => {
|
|
|
32830
33172
|
const t10 = displayed && open ? "opacity-100" : "opacity-0";
|
|
32831
33173
|
let t11;
|
|
32832
33174
|
if ($[5] !== t10) {
|
|
32833
|
-
t11 = cls("fixed inset-0 transition-opacity z-20 ease-in-out duration-200 bg-black bg-opacity-
|
|
33175
|
+
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");
|
|
32834
33176
|
$[5] = t10;
|
|
32835
33177
|
$[6] = t11;
|
|
32836
33178
|
} else {
|
|
@@ -32920,10 +33262,10 @@ const Dialog = (t0) => {
|
|
|
32920
33262
|
}
|
|
32921
33263
|
let t26;
|
|
32922
33264
|
if ($[33] !== t14 || $[34] !== t25 || $[35] !== t9) {
|
|
32923
|
-
t26 = /* @__PURE__ */
|
|
33265
|
+
t26 = /* @__PURE__ */ jsxs("div", { className: t9, children: [
|
|
32924
33266
|
t14,
|
|
32925
33267
|
t25
|
|
32926
|
-
] })
|
|
33268
|
+
] });
|
|
32927
33269
|
$[33] = t14;
|
|
32928
33270
|
$[34] = t25;
|
|
32929
33271
|
$[35] = t9;
|
|
@@ -32932,19 +33274,28 @@ const Dialog = (t0) => {
|
|
|
32932
33274
|
t26 = $[36];
|
|
32933
33275
|
}
|
|
32934
33276
|
let t27;
|
|
32935
|
-
if ($[37] !==
|
|
32936
|
-
t27 = /* @__PURE__ */ jsx(DialogPrimitive.
|
|
32937
|
-
$[37] =
|
|
32938
|
-
$[38] =
|
|
32939
|
-
$[39] =
|
|
32940
|
-
|
|
32941
|
-
$[
|
|
33277
|
+
if ($[37] !== finalContainer || $[38] !== t26) {
|
|
33278
|
+
t27 = /* @__PURE__ */ jsx(DialogPrimitive.Portal, { container: finalContainer, children: t26 });
|
|
33279
|
+
$[37] = finalContainer;
|
|
33280
|
+
$[38] = t26;
|
|
33281
|
+
$[39] = t27;
|
|
33282
|
+
} else {
|
|
33283
|
+
t27 = $[39];
|
|
33284
|
+
}
|
|
33285
|
+
let t28;
|
|
33286
|
+
if ($[40] !== modal || $[41] !== onOpenChange || $[42] !== t27 || $[43] !== t8) {
|
|
33287
|
+
t28 = /* @__PURE__ */ jsx(DialogPrimitive.Root, { open: t8, modal, onOpenChange, children: t27 });
|
|
33288
|
+
$[40] = modal;
|
|
33289
|
+
$[41] = onOpenChange;
|
|
33290
|
+
$[42] = t27;
|
|
33291
|
+
$[43] = t8;
|
|
33292
|
+
$[44] = t28;
|
|
32942
33293
|
} else {
|
|
32943
|
-
|
|
33294
|
+
t28 = $[44];
|
|
32944
33295
|
}
|
|
32945
|
-
return
|
|
33296
|
+
return t28;
|
|
32946
33297
|
};
|
|
32947
|
-
function _temp$
|
|
33298
|
+
function _temp$3() {
|
|
32948
33299
|
}
|
|
32949
33300
|
function DialogActions(t0) {
|
|
32950
33301
|
const $ = c(7);
|
|
@@ -32959,7 +33310,7 @@ function DialogActions(t0) {
|
|
|
32959
33310
|
const t3 = translucent ? "backdrop-blur-sm" : "";
|
|
32960
33311
|
let t4;
|
|
32961
33312
|
if ($[0] !== className || $[1] !== position || $[2] !== t3) {
|
|
32962
|
-
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);
|
|
33313
|
+
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);
|
|
32963
33314
|
$[0] = className;
|
|
32964
33315
|
$[1] = position;
|
|
32965
33316
|
$[2] = t3;
|
|
@@ -33207,7 +33558,7 @@ function ExpandablePanel(t0) {
|
|
|
33207
33558
|
const t13 = asField && fieldBackgroundMixin;
|
|
33208
33559
|
let t14;
|
|
33209
33560
|
if ($[11] !== t10 || $[12] !== t11 || $[13] !== t12 || $[14] !== t13 || $[15] !== titleClassName) {
|
|
33210
|
-
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, "cursor-pointer");
|
|
33561
|
+
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, "cursor-pointer");
|
|
33211
33562
|
$[11] = t10;
|
|
33212
33563
|
$[12] = t11;
|
|
33213
33564
|
$[13] = t12;
|
|
@@ -33301,7 +33652,7 @@ function ExpandablePanel(t0) {
|
|
|
33301
33652
|
return t24;
|
|
33302
33653
|
}
|
|
33303
33654
|
function FileUpload(t0) {
|
|
33304
|
-
const $ = c(
|
|
33655
|
+
const $ = c(33);
|
|
33305
33656
|
const {
|
|
33306
33657
|
accept,
|
|
33307
33658
|
onFilesAdded,
|
|
@@ -33356,15 +33707,17 @@ function FileUpload(t0) {
|
|
|
33356
33707
|
}
|
|
33357
33708
|
const t4 = size === "large";
|
|
33358
33709
|
const t5 = size === "medium";
|
|
33359
|
-
const t6 =
|
|
33360
|
-
const t7 = !
|
|
33361
|
-
|
|
33362
|
-
|
|
33363
|
-
|
|
33710
|
+
const t6 = size === "small";
|
|
33711
|
+
const t7 = !disabled;
|
|
33712
|
+
const t8 = !isDragActive;
|
|
33713
|
+
let t9;
|
|
33714
|
+
if ($[10] !== isDragAccept || $[11] !== isDragReject || $[12] !== t4 || $[13] !== t5 || $[14] !== t6 || $[15] !== t7 || $[16] !== t8) {
|
|
33715
|
+
t9 = cls(fieldBackgroundMixin, "flex gap-2", "p-4 box-border relative items-center border-2 border-solid border-transparent outline-none rounded-md duration-200 ease-[cubic-bezier(0.4,0,0.2,1)] focus:border-primary-solid", {
|
|
33364
33716
|
"h-44": t4,
|
|
33365
33717
|
"h-28": t5,
|
|
33366
|
-
"
|
|
33367
|
-
|
|
33718
|
+
"h-16": t6,
|
|
33719
|
+
"cursor-pointer": t7,
|
|
33720
|
+
[fieldBackgroundHoverMixin]: t8,
|
|
33368
33721
|
"transition-colors duration-200 ease-[cubic-bezier(0,0,0.2,1)] border-red-500": isDragReject,
|
|
33369
33722
|
"transition-colors duration-200 ease-[cubic-bezier(0,0,0.2,1)] border-green-500": isDragAccept
|
|
33370
33723
|
});
|
|
@@ -33375,60 +33728,61 @@ function FileUpload(t0) {
|
|
|
33375
33728
|
$[14] = t6;
|
|
33376
33729
|
$[15] = t7;
|
|
33377
33730
|
$[16] = t8;
|
|
33731
|
+
$[17] = t9;
|
|
33378
33732
|
} else {
|
|
33379
|
-
|
|
33380
|
-
}
|
|
33381
|
-
let t9;
|
|
33382
|
-
if ($[17] !== title) {
|
|
33383
|
-
t9 = /* @__PURE__ */ jsx(Typography, { variant: "caption", color: "secondary", className: "absolute top-2 left-3.5 cursor-inherit", children: title });
|
|
33384
|
-
$[17] = title;
|
|
33385
|
-
$[18] = t9;
|
|
33386
|
-
} else {
|
|
33387
|
-
t9 = $[18];
|
|
33733
|
+
t9 = $[17];
|
|
33388
33734
|
}
|
|
33389
33735
|
let t10;
|
|
33390
|
-
if ($[
|
|
33391
|
-
t10 =
|
|
33392
|
-
$[
|
|
33393
|
-
$[
|
|
33736
|
+
if ($[18] !== title) {
|
|
33737
|
+
t10 = /* @__PURE__ */ jsx(Typography, { variant: "caption", color: "secondary", className: "absolute top-2 left-3.5 cursor-inherit", children: title });
|
|
33738
|
+
$[18] = title;
|
|
33739
|
+
$[19] = t10;
|
|
33394
33740
|
} else {
|
|
33395
|
-
t10 = $[
|
|
33741
|
+
t10 = $[19];
|
|
33396
33742
|
}
|
|
33397
33743
|
let t11;
|
|
33398
|
-
if ($[
|
|
33399
|
-
t11 =
|
|
33400
|
-
$[
|
|
33401
|
-
$[
|
|
33744
|
+
if ($[20] !== getInputProps) {
|
|
33745
|
+
t11 = getInputProps();
|
|
33746
|
+
$[20] = getInputProps;
|
|
33747
|
+
$[21] = t11;
|
|
33402
33748
|
} else {
|
|
33403
|
-
t11 = $[
|
|
33749
|
+
t11 = $[21];
|
|
33404
33750
|
}
|
|
33405
33751
|
let t12;
|
|
33406
|
-
if ($[
|
|
33407
|
-
t12 = /* @__PURE__ */ jsx("
|
|
33408
|
-
$[
|
|
33409
|
-
$[
|
|
33752
|
+
if ($[22] !== t11) {
|
|
33753
|
+
t12 = /* @__PURE__ */ jsx("input", { ...t11 });
|
|
33754
|
+
$[22] = t11;
|
|
33755
|
+
$[23] = t12;
|
|
33410
33756
|
} else {
|
|
33411
|
-
t12 = $[
|
|
33757
|
+
t12 = $[23];
|
|
33412
33758
|
}
|
|
33413
33759
|
let t13;
|
|
33414
|
-
if ($[
|
|
33415
|
-
t13 = /* @__PURE__ */
|
|
33416
|
-
|
|
33417
|
-
|
|
33760
|
+
if ($[24] !== uploadDescription) {
|
|
33761
|
+
t13 = /* @__PURE__ */ jsx("div", { className: "flex-grow h-28 box-border flex flex-col items-center justify-center text-center", children: /* @__PURE__ */ jsx(Typography, { align: "center", variant: "label", className: "flex flex-row gap-2 justify-center", children: uploadDescription }) });
|
|
33762
|
+
$[24] = uploadDescription;
|
|
33763
|
+
$[25] = t13;
|
|
33764
|
+
} else {
|
|
33765
|
+
t13 = $[25];
|
|
33766
|
+
}
|
|
33767
|
+
let t14;
|
|
33768
|
+
if ($[26] !== children || $[27] !== t10 || $[28] !== t12 || $[29] !== t13 || $[30] !== t3 || $[31] !== t9) {
|
|
33769
|
+
t14 = /* @__PURE__ */ jsxs("div", { ...t3, className: t9, children: [
|
|
33770
|
+
t10,
|
|
33771
|
+
t12,
|
|
33418
33772
|
children,
|
|
33419
|
-
|
|
33773
|
+
t13
|
|
33420
33774
|
] });
|
|
33421
|
-
$[
|
|
33422
|
-
$[
|
|
33423
|
-
$[
|
|
33424
|
-
$[
|
|
33425
|
-
$[
|
|
33426
|
-
$[
|
|
33427
|
-
$[
|
|
33775
|
+
$[26] = children;
|
|
33776
|
+
$[27] = t10;
|
|
33777
|
+
$[28] = t12;
|
|
33778
|
+
$[29] = t13;
|
|
33779
|
+
$[30] = t3;
|
|
33780
|
+
$[31] = t9;
|
|
33781
|
+
$[32] = t14;
|
|
33428
33782
|
} else {
|
|
33429
|
-
|
|
33783
|
+
t14 = $[32];
|
|
33430
33784
|
}
|
|
33431
|
-
return
|
|
33785
|
+
return t14;
|
|
33432
33786
|
}
|
|
33433
33787
|
const colorClasses = {
|
|
33434
33788
|
info: "bg-sky-200 dark:bg-teal-900",
|
|
@@ -33649,6 +34003,8 @@ const Menu = React__default.forwardRef((t0, ref) => {
|
|
|
33649
34003
|
className
|
|
33650
34004
|
} = t0;
|
|
33651
34005
|
const sideOffset = t1 === void 0 ? 4 : t1;
|
|
34006
|
+
const contextContainer = usePortalContainer();
|
|
34007
|
+
const finalContainer = portalContainer ?? contextContainer ?? void 0;
|
|
33652
34008
|
let t2;
|
|
33653
34009
|
if ($[0] !== ref || $[1] !== trigger) {
|
|
33654
34010
|
t2 = /* @__PURE__ */ jsx(DropdownMenu.Trigger, { ref, asChild: true, children: trigger });
|
|
@@ -33679,9 +34035,9 @@ const Menu = React__default.forwardRef((t0, ref) => {
|
|
|
33679
34035
|
t4 = $[10];
|
|
33680
34036
|
}
|
|
33681
34037
|
let t5;
|
|
33682
|
-
if ($[11] !==
|
|
33683
|
-
t5 = /* @__PURE__ */ jsx(DropdownMenu.Portal, { container:
|
|
33684
|
-
$[11] =
|
|
34038
|
+
if ($[11] !== finalContainer || $[12] !== t4) {
|
|
34039
|
+
t5 = /* @__PURE__ */ jsx(DropdownMenu.Portal, { container: finalContainer, children: t4 });
|
|
34040
|
+
$[11] = finalContainer;
|
|
33685
34041
|
$[12] = t4;
|
|
33686
34042
|
$[13] = t5;
|
|
33687
34043
|
} else {
|
|
@@ -33706,38 +34062,46 @@ const Menu = React__default.forwardRef((t0, ref) => {
|
|
|
33706
34062
|
});
|
|
33707
34063
|
Menu.displayName = "Menu";
|
|
33708
34064
|
const MenuItem = React__default.memo((t0) => {
|
|
33709
|
-
const $ = c(
|
|
34065
|
+
const $ = c(11);
|
|
33710
34066
|
const {
|
|
33711
34067
|
children,
|
|
33712
34068
|
dense: t1,
|
|
34069
|
+
disabled: t2,
|
|
33713
34070
|
onClick,
|
|
33714
34071
|
className
|
|
33715
34072
|
} = t0;
|
|
33716
34073
|
const dense = t1 === void 0 ? false : t1;
|
|
33717
|
-
const
|
|
33718
|
-
const t3 =
|
|
33719
|
-
|
|
33720
|
-
|
|
33721
|
-
|
|
34074
|
+
const disabled = t2 === void 0 ? false : t2;
|
|
34075
|
+
const t3 = onClick && !disabled && "cursor-pointer";
|
|
34076
|
+
const t4 = disabled && "opacity-50 cursor-not-allowed";
|
|
34077
|
+
const t5 = !disabled && "hover:bg-surface-accent-100 dark:hover:bg-surface-accent-900";
|
|
34078
|
+
const t6 = dense ? "px-4 py-1.5" : "px-4 py-2";
|
|
34079
|
+
let t7;
|
|
34080
|
+
if ($[0] !== className || $[1] !== t3 || $[2] !== t4 || $[3] !== t5 || $[4] !== t6) {
|
|
34081
|
+
t7 = cls(t3, t4, "rounded-md text-sm font-medium text-surface-accent-700 dark:text-surface-accent-300 flex items-center gap-4", t5, t6, className);
|
|
33722
34082
|
$[0] = className;
|
|
33723
|
-
$[1] =
|
|
33724
|
-
$[2] =
|
|
33725
|
-
$[3] =
|
|
34083
|
+
$[1] = t3;
|
|
34084
|
+
$[2] = t4;
|
|
34085
|
+
$[3] = t5;
|
|
34086
|
+
$[4] = t6;
|
|
34087
|
+
$[5] = t7;
|
|
33726
34088
|
} else {
|
|
33727
|
-
|
|
34089
|
+
t7 = $[5];
|
|
33728
34090
|
}
|
|
33729
|
-
const classNames =
|
|
33730
|
-
|
|
33731
|
-
|
|
33732
|
-
|
|
33733
|
-
|
|
33734
|
-
$[
|
|
33735
|
-
$[
|
|
33736
|
-
$[
|
|
34091
|
+
const classNames = t7;
|
|
34092
|
+
const t8 = disabled ? void 0 : onClick;
|
|
34093
|
+
let t9;
|
|
34094
|
+
if ($[6] !== children || $[7] !== classNames || $[8] !== disabled || $[9] !== t8) {
|
|
34095
|
+
t9 = /* @__PURE__ */ jsx(DropdownMenu.Item, { className: classNames, disabled, onClick: t8, children });
|
|
34096
|
+
$[6] = children;
|
|
34097
|
+
$[7] = classNames;
|
|
34098
|
+
$[8] = disabled;
|
|
34099
|
+
$[9] = t8;
|
|
34100
|
+
$[10] = t9;
|
|
33737
34101
|
} else {
|
|
33738
|
-
|
|
34102
|
+
t9 = $[10];
|
|
33739
34103
|
}
|
|
33740
|
-
return
|
|
34104
|
+
return t9;
|
|
33741
34105
|
});
|
|
33742
34106
|
function Menubar(t0) {
|
|
33743
34107
|
const $ = c(6);
|
|
@@ -33790,7 +34154,7 @@ function MenubarTrigger(t0) {
|
|
|
33790
34154
|
} = t0;
|
|
33791
34155
|
let t1;
|
|
33792
34156
|
if ($[0] !== className) {
|
|
33793
|
-
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);
|
|
34157
|
+
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);
|
|
33794
34158
|
$[0] = className;
|
|
33795
34159
|
$[1] = t1;
|
|
33796
34160
|
} else {
|
|
@@ -33809,17 +34173,21 @@ function MenubarTrigger(t0) {
|
|
|
33809
34173
|
return t2;
|
|
33810
34174
|
}
|
|
33811
34175
|
function MenubarPortal(t0) {
|
|
33812
|
-
const $ = c(
|
|
34176
|
+
const $ = c(3);
|
|
33813
34177
|
const {
|
|
33814
|
-
children
|
|
34178
|
+
children,
|
|
34179
|
+
portalContainer
|
|
33815
34180
|
} = t0;
|
|
34181
|
+
const contextContainer = usePortalContainer();
|
|
34182
|
+
const finalContainer = portalContainer ?? contextContainer ?? void 0;
|
|
33816
34183
|
let t1;
|
|
33817
|
-
if ($[0] !== children) {
|
|
33818
|
-
t1 = /* @__PURE__ */ jsx(MenubarPrimitive.Portal, { children });
|
|
34184
|
+
if ($[0] !== children || $[1] !== finalContainer) {
|
|
34185
|
+
t1 = /* @__PURE__ */ jsx(MenubarPrimitive.Portal, { container: finalContainer, children });
|
|
33819
34186
|
$[0] = children;
|
|
33820
|
-
$[1] =
|
|
34187
|
+
$[1] = finalContainer;
|
|
34188
|
+
$[2] = t1;
|
|
33821
34189
|
} else {
|
|
33822
|
-
t1 = $[
|
|
34190
|
+
t1 = $[2];
|
|
33823
34191
|
}
|
|
33824
34192
|
return t1;
|
|
33825
34193
|
}
|
|
@@ -34392,7 +34760,7 @@ function Separator(t0) {
|
|
|
34392
34760
|
if (orientation === "horizontal") {
|
|
34393
34761
|
let t1;
|
|
34394
34762
|
if ($[0] !== className) {
|
|
34395
|
-
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);
|
|
34763
|
+
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);
|
|
34396
34764
|
$[0] = className;
|
|
34397
34765
|
$[1] = t1;
|
|
34398
34766
|
} else {
|
|
@@ -34411,7 +34779,7 @@ function Separator(t0) {
|
|
|
34411
34779
|
} else {
|
|
34412
34780
|
let t1;
|
|
34413
34781
|
if ($[5] !== className) {
|
|
34414
|
-
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);
|
|
34782
|
+
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);
|
|
34415
34783
|
$[5] = className;
|
|
34416
34784
|
$[6] = t1;
|
|
34417
34785
|
} else {
|
|
@@ -34457,7 +34825,7 @@ function SelectInputLabel(t0) {
|
|
|
34457
34825
|
}
|
|
34458
34826
|
const MultiSelectContext = React.createContext({});
|
|
34459
34827
|
const MultiSelect = React.forwardRef((t0, ref) => {
|
|
34460
|
-
const $ = c(
|
|
34828
|
+
const $ = c(111);
|
|
34461
34829
|
const {
|
|
34462
34830
|
value,
|
|
34463
34831
|
size: t1,
|
|
@@ -34472,17 +34840,21 @@ const MultiSelect = React.forwardRef((t0, ref) => {
|
|
|
34472
34840
|
includeSelectAll: t4,
|
|
34473
34841
|
useChips: t5,
|
|
34474
34842
|
className,
|
|
34843
|
+
inputClassName,
|
|
34844
|
+
inputRef,
|
|
34475
34845
|
children,
|
|
34476
34846
|
renderValues,
|
|
34477
34847
|
open,
|
|
34478
|
-
onOpenChange
|
|
34848
|
+
onOpenChange,
|
|
34849
|
+
portalContainer
|
|
34479
34850
|
} = t0;
|
|
34480
34851
|
const size = t1 === void 0 ? "large" : t1;
|
|
34481
34852
|
const modalPopover = t2 === void 0 ? true : t2;
|
|
34482
34853
|
const includeClear = t3 === void 0 ? true : t3;
|
|
34483
34854
|
const includeSelectAll = t4 === void 0 ? true : t4;
|
|
34484
34855
|
const useChips = t5 === void 0 ? true : t5;
|
|
34485
|
-
const [
|
|
34856
|
+
const [isMounted, setIsMounted] = useState(false);
|
|
34857
|
+
const [isPopoverOpen, setIsPopoverOpen] = useState(open ?? false);
|
|
34486
34858
|
let t6;
|
|
34487
34859
|
if ($[0] !== value) {
|
|
34488
34860
|
t6 = value ?? [];
|
|
@@ -34491,79 +34863,95 @@ const MultiSelect = React.forwardRef((t0, ref) => {
|
|
|
34491
34863
|
} else {
|
|
34492
34864
|
t6 = $[1];
|
|
34493
34865
|
}
|
|
34494
|
-
const [selectedValues, setSelectedValues] =
|
|
34866
|
+
const [selectedValues, setSelectedValues] = useState(t6);
|
|
34867
|
+
const contextContainer = usePortalContainer();
|
|
34868
|
+
const finalContainer = portalContainer ?? contextContainer ?? void 0;
|
|
34495
34869
|
let t7;
|
|
34496
|
-
|
|
34497
|
-
|
|
34498
|
-
|
|
34499
|
-
|
|
34870
|
+
let t8;
|
|
34871
|
+
if ($[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
34872
|
+
t7 = () => {
|
|
34873
|
+
setIsMounted(true);
|
|
34500
34874
|
};
|
|
34501
|
-
|
|
34502
|
-
$[
|
|
34875
|
+
t8 = [];
|
|
34876
|
+
$[2] = t7;
|
|
34877
|
+
$[3] = t8;
|
|
34503
34878
|
} else {
|
|
34504
|
-
t7 = $[
|
|
34879
|
+
t7 = $[2];
|
|
34880
|
+
t8 = $[3];
|
|
34505
34881
|
}
|
|
34506
|
-
|
|
34507
|
-
let t8;
|
|
34882
|
+
useEffect(t7, t8);
|
|
34508
34883
|
let t9;
|
|
34509
|
-
if ($[4] !==
|
|
34510
|
-
|
|
34511
|
-
setIsPopoverOpen(
|
|
34884
|
+
if ($[4] !== onOpenChange) {
|
|
34885
|
+
t9 = (open_0) => {
|
|
34886
|
+
setIsPopoverOpen(open_0);
|
|
34887
|
+
onOpenChange?.(open_0);
|
|
34512
34888
|
};
|
|
34513
|
-
|
|
34514
|
-
$[
|
|
34515
|
-
$[5] = t8;
|
|
34516
|
-
$[6] = t9;
|
|
34889
|
+
$[4] = onOpenChange;
|
|
34890
|
+
$[5] = t9;
|
|
34517
34891
|
} else {
|
|
34518
|
-
|
|
34519
|
-
t9 = $[6];
|
|
34892
|
+
t9 = $[5];
|
|
34520
34893
|
}
|
|
34521
|
-
|
|
34894
|
+
const onPopoverOpenChange = t9;
|
|
34522
34895
|
let t10;
|
|
34523
34896
|
let t11;
|
|
34524
|
-
if ($[
|
|
34525
|
-
|
|
34526
|
-
|
|
34897
|
+
if ($[6] !== open) {
|
|
34898
|
+
t10 = () => {
|
|
34899
|
+
setIsPopoverOpen(open ?? false);
|
|
34900
|
+
};
|
|
34901
|
+
t11 = [open];
|
|
34902
|
+
$[6] = open;
|
|
34903
|
+
$[7] = t10;
|
|
34527
34904
|
$[8] = t11;
|
|
34528
34905
|
} else {
|
|
34906
|
+
t10 = $[7];
|
|
34529
34907
|
t11 = $[8];
|
|
34530
34908
|
}
|
|
34531
|
-
t10
|
|
34532
|
-
const allValues = t10;
|
|
34909
|
+
useEffect(t10, t11);
|
|
34533
34910
|
let t12;
|
|
34534
|
-
let
|
|
34911
|
+
let t13;
|
|
34535
34912
|
if ($[9] !== children) {
|
|
34913
|
+
t13 = children ? Children.map(children, _temp$2)?.filter(Boolean) ?? [] : [];
|
|
34914
|
+
$[9] = children;
|
|
34915
|
+
$[10] = t13;
|
|
34916
|
+
} else {
|
|
34917
|
+
t13 = $[10];
|
|
34918
|
+
}
|
|
34919
|
+
t12 = t13;
|
|
34920
|
+
const allValues = t12;
|
|
34921
|
+
let t14;
|
|
34922
|
+
let map;
|
|
34923
|
+
if ($[11] !== children) {
|
|
34536
34924
|
map = /* @__PURE__ */ new Map();
|
|
34537
34925
|
Children.forEach(children, (child_0) => {
|
|
34538
34926
|
if (React.isValidElement(child_0)) {
|
|
34539
34927
|
map.set(String(child_0.props.value), child_0.props.children);
|
|
34540
34928
|
}
|
|
34541
34929
|
});
|
|
34542
|
-
$[
|
|
34543
|
-
$[
|
|
34930
|
+
$[11] = children;
|
|
34931
|
+
$[12] = map;
|
|
34544
34932
|
} else {
|
|
34545
|
-
map = $[
|
|
34933
|
+
map = $[12];
|
|
34546
34934
|
}
|
|
34547
|
-
|
|
34548
|
-
const optionsMap =
|
|
34549
|
-
let
|
|
34550
|
-
let
|
|
34551
|
-
if ($[
|
|
34552
|
-
|
|
34935
|
+
t14 = map;
|
|
34936
|
+
const optionsMap = t14;
|
|
34937
|
+
let t15;
|
|
34938
|
+
let t16;
|
|
34939
|
+
if ($[13] !== value) {
|
|
34940
|
+
t15 = () => {
|
|
34553
34941
|
setSelectedValues(value ?? []);
|
|
34554
34942
|
};
|
|
34555
|
-
|
|
34556
|
-
$[
|
|
34557
|
-
$[
|
|
34558
|
-
$[
|
|
34943
|
+
t16 = [value];
|
|
34944
|
+
$[13] = value;
|
|
34945
|
+
$[14] = t15;
|
|
34946
|
+
$[15] = t16;
|
|
34559
34947
|
} else {
|
|
34560
|
-
|
|
34561
|
-
|
|
34948
|
+
t15 = $[14];
|
|
34949
|
+
t16 = $[15];
|
|
34562
34950
|
}
|
|
34563
|
-
React.useEffect(
|
|
34951
|
+
React.useEffect(t15, t16);
|
|
34564
34952
|
let onItemClick;
|
|
34565
34953
|
let updateValues;
|
|
34566
|
-
if ($[
|
|
34954
|
+
if ($[16] !== onValueChange || $[17] !== selectedValues) {
|
|
34567
34955
|
onItemClick = function onItemClick2(newValue) {
|
|
34568
34956
|
let newSelectedValues;
|
|
34569
34957
|
if (selectedValues.some((v_0) => String(v_0) === String(newValue))) {
|
|
@@ -34577,17 +34965,17 @@ const MultiSelect = React.forwardRef((t0, ref) => {
|
|
|
34577
34965
|
setSelectedValues(values);
|
|
34578
34966
|
onValueChange?.(values);
|
|
34579
34967
|
};
|
|
34580
|
-
$[
|
|
34581
|
-
$[
|
|
34582
|
-
$[
|
|
34583
|
-
$[
|
|
34968
|
+
$[16] = onValueChange;
|
|
34969
|
+
$[17] = selectedValues;
|
|
34970
|
+
$[18] = onItemClick;
|
|
34971
|
+
$[19] = updateValues;
|
|
34584
34972
|
} else {
|
|
34585
|
-
onItemClick = $[
|
|
34586
|
-
updateValues = $[
|
|
34973
|
+
onItemClick = $[18];
|
|
34974
|
+
updateValues = $[19];
|
|
34587
34975
|
}
|
|
34588
|
-
let
|
|
34589
|
-
if ($[
|
|
34590
|
-
|
|
34976
|
+
let t17;
|
|
34977
|
+
if ($[20] !== onPopoverOpenChange || $[21] !== selectedValues || $[22] !== updateValues) {
|
|
34978
|
+
t17 = (event) => {
|
|
34591
34979
|
if (event.key === "Enter") {
|
|
34592
34980
|
onPopoverOpenChange(true);
|
|
34593
34981
|
} else {
|
|
@@ -34598,53 +34986,53 @@ const MultiSelect = React.forwardRef((t0, ref) => {
|
|
|
34598
34986
|
}
|
|
34599
34987
|
}
|
|
34600
34988
|
};
|
|
34601
|
-
$[
|
|
34602
|
-
$[
|
|
34603
|
-
$[
|
|
34604
|
-
$[
|
|
34989
|
+
$[20] = onPopoverOpenChange;
|
|
34990
|
+
$[21] = selectedValues;
|
|
34991
|
+
$[22] = updateValues;
|
|
34992
|
+
$[23] = t17;
|
|
34605
34993
|
} else {
|
|
34606
|
-
|
|
34994
|
+
t17 = $[23];
|
|
34607
34995
|
}
|
|
34608
|
-
const handleInputKeyDown =
|
|
34609
|
-
let
|
|
34610
|
-
if ($[
|
|
34611
|
-
|
|
34996
|
+
const handleInputKeyDown = t17;
|
|
34997
|
+
let t18;
|
|
34998
|
+
if ($[24] !== selectedValues || $[25] !== updateValues) {
|
|
34999
|
+
t18 = (value_0) => {
|
|
34612
35000
|
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];
|
|
34613
35001
|
updateValues(newSelectedValues_1);
|
|
34614
35002
|
};
|
|
34615
|
-
$[
|
|
34616
|
-
$[
|
|
34617
|
-
$[
|
|
35003
|
+
$[24] = selectedValues;
|
|
35004
|
+
$[25] = updateValues;
|
|
35005
|
+
$[26] = t18;
|
|
34618
35006
|
} else {
|
|
34619
|
-
|
|
35007
|
+
t18 = $[26];
|
|
34620
35008
|
}
|
|
34621
|
-
const toggleOption =
|
|
34622
|
-
let
|
|
34623
|
-
if ($[
|
|
34624
|
-
|
|
35009
|
+
const toggleOption = t18;
|
|
35010
|
+
let t19;
|
|
35011
|
+
if ($[27] !== updateValues) {
|
|
35012
|
+
t19 = () => {
|
|
34625
35013
|
updateValues([]);
|
|
34626
35014
|
};
|
|
34627
|
-
$[
|
|
34628
|
-
$[
|
|
35015
|
+
$[27] = updateValues;
|
|
35016
|
+
$[28] = t19;
|
|
34629
35017
|
} else {
|
|
34630
|
-
|
|
35018
|
+
t19 = $[28];
|
|
34631
35019
|
}
|
|
34632
|
-
const handleClear =
|
|
34633
|
-
let
|
|
34634
|
-
if ($[
|
|
34635
|
-
|
|
35020
|
+
const handleClear = t19;
|
|
35021
|
+
let t20;
|
|
35022
|
+
if ($[29] !== isPopoverOpen || $[30] !== onPopoverOpenChange) {
|
|
35023
|
+
t20 = () => {
|
|
34636
35024
|
onPopoverOpenChange(!isPopoverOpen);
|
|
34637
35025
|
};
|
|
34638
|
-
$[
|
|
34639
|
-
$[
|
|
34640
|
-
$[
|
|
35026
|
+
$[29] = isPopoverOpen;
|
|
35027
|
+
$[30] = onPopoverOpenChange;
|
|
35028
|
+
$[31] = t20;
|
|
34641
35029
|
} else {
|
|
34642
|
-
|
|
35030
|
+
t20 = $[31];
|
|
34643
35031
|
}
|
|
34644
|
-
const handleTogglePopover =
|
|
34645
|
-
let
|
|
34646
|
-
if ($[
|
|
34647
|
-
|
|
35032
|
+
const handleTogglePopover = t20;
|
|
35033
|
+
let t21;
|
|
35034
|
+
if ($[32] !== allValues || $[33] !== handleClear || $[34] !== onPopoverOpenChange || $[35] !== selectedValues.length || $[36] !== updateValues) {
|
|
35035
|
+
t21 = () => {
|
|
34648
35036
|
if (selectedValues.length === allValues.length) {
|
|
34649
35037
|
handleClear();
|
|
34650
35038
|
} else {
|
|
@@ -34652,76 +35040,79 @@ const MultiSelect = React.forwardRef((t0, ref) => {
|
|
|
34652
35040
|
}
|
|
34653
35041
|
onPopoverOpenChange(false);
|
|
34654
35042
|
};
|
|
34655
|
-
$[
|
|
34656
|
-
$[
|
|
34657
|
-
$[
|
|
34658
|
-
$[
|
|
34659
|
-
$[
|
|
34660
|
-
$[
|
|
35043
|
+
$[32] = allValues;
|
|
35044
|
+
$[33] = handleClear;
|
|
35045
|
+
$[34] = onPopoverOpenChange;
|
|
35046
|
+
$[35] = selectedValues.length;
|
|
35047
|
+
$[36] = updateValues;
|
|
35048
|
+
$[37] = t21;
|
|
34661
35049
|
} else {
|
|
34662
|
-
|
|
35050
|
+
t21 = $[37];
|
|
34663
35051
|
}
|
|
34664
|
-
const toggleAll =
|
|
35052
|
+
const toggleAll = t21;
|
|
34665
35053
|
useInjectStyles("MultiSelect", `
|
|
34666
35054
|
[cmdk-group] {
|
|
34667
35055
|
max-height: 45vh;
|
|
34668
35056
|
overflow-y: auto;
|
|
34669
35057
|
// width: 400px;
|
|
34670
35058
|
} `);
|
|
34671
|
-
let
|
|
34672
|
-
if ($[
|
|
34673
|
-
|
|
35059
|
+
let t22;
|
|
35060
|
+
if ($[38] !== onItemClick || $[39] !== selectedValues) {
|
|
35061
|
+
t22 = {
|
|
34674
35062
|
fieldValue: selectedValues,
|
|
34675
35063
|
onItemClick
|
|
34676
35064
|
};
|
|
34677
|
-
$[
|
|
34678
|
-
$[
|
|
34679
|
-
$[
|
|
35065
|
+
$[38] = onItemClick;
|
|
35066
|
+
$[39] = selectedValues;
|
|
35067
|
+
$[40] = t22;
|
|
34680
35068
|
} else {
|
|
34681
|
-
|
|
35069
|
+
t22 = $[40];
|
|
34682
35070
|
}
|
|
34683
|
-
let
|
|
34684
|
-
if ($[
|
|
34685
|
-
|
|
34686
|
-
$[
|
|
34687
|
-
$[
|
|
34688
|
-
$[
|
|
34689
|
-
} else {
|
|
34690
|
-
|
|
34691
|
-
}
|
|
34692
|
-
const
|
|
34693
|
-
const
|
|
34694
|
-
const
|
|
34695
|
-
const
|
|
34696
|
-
|
|
34697
|
-
|
|
34698
|
-
|
|
34699
|
-
|
|
34700
|
-
|
|
34701
|
-
"min-h-[
|
|
34702
|
-
"min-h-[
|
|
35071
|
+
let t23;
|
|
35072
|
+
if ($[41] !== error || $[42] !== label) {
|
|
35073
|
+
t23 = typeof label === "string" ? /* @__PURE__ */ jsx(SelectInputLabel, { error, children: label }) : label;
|
|
35074
|
+
$[41] = error;
|
|
35075
|
+
$[42] = label;
|
|
35076
|
+
$[43] = t23;
|
|
35077
|
+
} else {
|
|
35078
|
+
t23 = $[43];
|
|
35079
|
+
}
|
|
35080
|
+
const t24 = isMounted && isPopoverOpen;
|
|
35081
|
+
const t25 = inputRef ?? ref;
|
|
35082
|
+
const t26 = size === "smallest";
|
|
35083
|
+
const t27 = size === "small";
|
|
35084
|
+
const t28 = size === "medium";
|
|
35085
|
+
const t29 = size === "large";
|
|
35086
|
+
let t30;
|
|
35087
|
+
if ($[44] !== className || $[45] !== disabled || $[46] !== inputClassName || $[47] !== invisible || $[48] !== size || $[49] !== t26 || $[50] !== t27 || $[51] !== t28 || $[52] !== t29) {
|
|
35088
|
+
t30 = cls({
|
|
35089
|
+
"min-h-[28px]": t26,
|
|
35090
|
+
"min-h-[32px]": t27,
|
|
35091
|
+
"min-h-[44px]": t28,
|
|
35092
|
+
"min-h-[64px]": t29
|
|
34703
35093
|
}, {
|
|
34704
35094
|
"py-1": size === "small" || size === "smallest",
|
|
34705
35095
|
"py-2": size === "medium" || size === "large"
|
|
34706
35096
|
}, {
|
|
34707
35097
|
"px-2": size === "small" || size === "smallest",
|
|
34708
35098
|
"px-4": size === "medium" || size === "large"
|
|
34709
|
-
}, "select-none rounded-md text-sm", invisible ? fieldBackgroundInvisibleMixin : fieldBackgroundMixin, disabled ? fieldBackgroundDisabledMixin : fieldBackgroundHoverMixin, "relative flex items-center", className);
|
|
34710
|
-
$[
|
|
34711
|
-
$[
|
|
34712
|
-
$[
|
|
34713
|
-
$[
|
|
34714
|
-
$[
|
|
34715
|
-
$[
|
|
34716
|
-
$[
|
|
34717
|
-
$[
|
|
34718
|
-
$[
|
|
35099
|
+
}, "select-none rounded-md text-sm", "focus:ring-0 focus-visible:ring-0 outline-none focus:outline-none focus-visible:outline-none", invisible ? fieldBackgroundInvisibleMixin : fieldBackgroundMixin, disabled ? fieldBackgroundDisabledMixin : fieldBackgroundHoverMixin, "relative flex items-center", className, inputClassName);
|
|
35100
|
+
$[44] = className;
|
|
35101
|
+
$[45] = disabled;
|
|
35102
|
+
$[46] = inputClassName;
|
|
35103
|
+
$[47] = invisible;
|
|
35104
|
+
$[48] = size;
|
|
35105
|
+
$[49] = t26;
|
|
35106
|
+
$[50] = t27;
|
|
35107
|
+
$[51] = t28;
|
|
35108
|
+
$[52] = t29;
|
|
35109
|
+
$[53] = t30;
|
|
34719
35110
|
} else {
|
|
34720
|
-
|
|
35111
|
+
t30 = $[53];
|
|
34721
35112
|
}
|
|
34722
|
-
let
|
|
34723
|
-
if ($[
|
|
34724
|
-
|
|
35113
|
+
let t31;
|
|
35114
|
+
if ($[54] !== handleClear || $[55] !== includeClear || $[56] !== isPopoverOpen || $[57] !== optionsMap || $[58] !== placeholder || $[59] !== renderValues || $[60] !== selectedValues || $[61] !== size || $[62] !== toggleOption || $[63] !== useChips) {
|
|
35115
|
+
t31 = selectedValues.length > 0 ? /* @__PURE__ */ jsxs("div", { className: "flex justify-between items-center w-full", children: [
|
|
34725
35116
|
/* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-1.5 text-start", children: [
|
|
34726
35117
|
renderValues && renderValues(selectedValues),
|
|
34727
35118
|
!renderValues && selectedValues.map((value_1) => {
|
|
@@ -34749,176 +35140,185 @@ const MultiSelect = React.forwardRef((t0, ref) => {
|
|
|
34749
35140
|
/* @__PURE__ */ jsx("span", { className: "text-sm", children: placeholder }),
|
|
34750
35141
|
/* @__PURE__ */ jsx("div", { className: cls("px-2 h-full flex items-center"), children: /* @__PURE__ */ jsx(KeyboardArrowDownIcon, { size: size === "large" ? "medium" : "small", className: cls("transition", isPopoverOpen ? "rotate-180" : "") }) })
|
|
34751
35142
|
] });
|
|
34752
|
-
$[
|
|
34753
|
-
$[
|
|
34754
|
-
$[
|
|
34755
|
-
$[
|
|
34756
|
-
$[
|
|
34757
|
-
$[
|
|
34758
|
-
$[
|
|
34759
|
-
$[
|
|
34760
|
-
$[
|
|
34761
|
-
$[
|
|
34762
|
-
$[
|
|
34763
|
-
} else {
|
|
34764
|
-
|
|
35143
|
+
$[54] = handleClear;
|
|
35144
|
+
$[55] = includeClear;
|
|
35145
|
+
$[56] = isPopoverOpen;
|
|
35146
|
+
$[57] = optionsMap;
|
|
35147
|
+
$[58] = placeholder;
|
|
35148
|
+
$[59] = renderValues;
|
|
35149
|
+
$[60] = selectedValues;
|
|
35150
|
+
$[61] = size;
|
|
35151
|
+
$[62] = toggleOption;
|
|
35152
|
+
$[63] = useChips;
|
|
35153
|
+
$[64] = t31;
|
|
35154
|
+
} else {
|
|
35155
|
+
t31 = $[64];
|
|
34765
35156
|
}
|
|
34766
|
-
let
|
|
34767
|
-
if ($[
|
|
34768
|
-
|
|
34769
|
-
$[
|
|
34770
|
-
$[
|
|
34771
|
-
$[
|
|
34772
|
-
$[
|
|
34773
|
-
$[
|
|
35157
|
+
let t32;
|
|
35158
|
+
if ($[65] !== handleTogglePopover || $[66] !== t25 || $[67] !== t30 || $[68] !== t31) {
|
|
35159
|
+
t32 = /* @__PURE__ */ jsx(PopoverPrimitive.Trigger, { asChild: true, children: /* @__PURE__ */ jsx("button", { ref: t25, onClick: handleTogglePopover, className: t30, children: t31 }) });
|
|
35160
|
+
$[65] = handleTogglePopover;
|
|
35161
|
+
$[66] = t25;
|
|
35162
|
+
$[67] = t30;
|
|
35163
|
+
$[68] = t31;
|
|
35164
|
+
$[69] = t32;
|
|
34774
35165
|
} else {
|
|
34775
|
-
|
|
35166
|
+
t32 = $[69];
|
|
34776
35167
|
}
|
|
34777
|
-
let
|
|
34778
|
-
if ($[
|
|
34779
|
-
|
|
34780
|
-
$[
|
|
35168
|
+
let t33;
|
|
35169
|
+
if ($[70] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
35170
|
+
t33 = cls("z-50 overflow-hidden border bg-white dark:bg-surface-900 rounded-lg w-[400px]", defaultBorderMixin);
|
|
35171
|
+
$[70] = t33;
|
|
34781
35172
|
} else {
|
|
34782
|
-
|
|
35173
|
+
t33 = $[70];
|
|
34783
35174
|
}
|
|
34784
|
-
let
|
|
34785
|
-
if ($[
|
|
34786
|
-
|
|
34787
|
-
$[
|
|
34788
|
-
$[
|
|
35175
|
+
let t34;
|
|
35176
|
+
if ($[71] !== onPopoverOpenChange) {
|
|
35177
|
+
t34 = () => onPopoverOpenChange(false);
|
|
35178
|
+
$[71] = onPopoverOpenChange;
|
|
35179
|
+
$[72] = t34;
|
|
34789
35180
|
} else {
|
|
34790
|
-
|
|
35181
|
+
t34 = $[72];
|
|
34791
35182
|
}
|
|
34792
|
-
let
|
|
34793
|
-
if ($[
|
|
34794
|
-
|
|
34795
|
-
$[
|
|
35183
|
+
let t35;
|
|
35184
|
+
if ($[73] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
35185
|
+
t35 = cls(focusedDisabled, "bg-transparent outline-none flex-1 h-full w-full m-4 flex-grow text-surface-accent-900 dark:text-white");
|
|
35186
|
+
$[73] = t35;
|
|
34796
35187
|
} else {
|
|
34797
|
-
|
|
35188
|
+
t35 = $[73];
|
|
34798
35189
|
}
|
|
34799
|
-
let
|
|
34800
|
-
if ($[
|
|
34801
|
-
|
|
34802
|
-
$[
|
|
34803
|
-
$[
|
|
35190
|
+
let t36;
|
|
35191
|
+
if ($[74] !== handleInputKeyDown) {
|
|
35192
|
+
t36 = /* @__PURE__ */ jsx(Command.Input, { className: t35, placeholder: "Search...", onKeyDown: handleInputKeyDown });
|
|
35193
|
+
$[74] = handleInputKeyDown;
|
|
35194
|
+
$[75] = t36;
|
|
34804
35195
|
} else {
|
|
34805
|
-
|
|
35196
|
+
t36 = $[75];
|
|
34806
35197
|
}
|
|
34807
|
-
let
|
|
34808
|
-
if ($[
|
|
34809
|
-
|
|
34810
|
-
$[
|
|
34811
|
-
$[
|
|
34812
|
-
$[
|
|
35198
|
+
let t37;
|
|
35199
|
+
if ($[76] !== handleClear || $[77] !== selectedValues.length) {
|
|
35200
|
+
t37 = selectedValues.length > 0 && /* @__PURE__ */ 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" });
|
|
35201
|
+
$[76] = handleClear;
|
|
35202
|
+
$[77] = selectedValues.length;
|
|
35203
|
+
$[78] = t37;
|
|
34813
35204
|
} else {
|
|
34814
|
-
|
|
35205
|
+
t37 = $[78];
|
|
34815
35206
|
}
|
|
34816
|
-
let
|
|
34817
|
-
if ($[
|
|
34818
|
-
|
|
34819
|
-
|
|
34820
|
-
|
|
35207
|
+
let t38;
|
|
35208
|
+
if ($[79] !== t36 || $[80] !== t37) {
|
|
35209
|
+
t38 = /* @__PURE__ */ jsxs("div", { className: "flex flex-row items-center", children: [
|
|
35210
|
+
t36,
|
|
35211
|
+
t37
|
|
34821
35212
|
] });
|
|
34822
|
-
$[
|
|
34823
|
-
$[
|
|
34824
|
-
$[
|
|
35213
|
+
$[79] = t36;
|
|
35214
|
+
$[80] = t37;
|
|
35215
|
+
$[81] = t38;
|
|
34825
35216
|
} else {
|
|
34826
|
-
|
|
35217
|
+
t38 = $[81];
|
|
34827
35218
|
}
|
|
34828
|
-
let
|
|
34829
|
-
if ($[
|
|
34830
|
-
|
|
34831
|
-
$[
|
|
35219
|
+
let t39;
|
|
35220
|
+
if ($[82] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
35221
|
+
t39 = /* @__PURE__ */ jsx(Separator, { orientation: "horizontal", className: "my-0" });
|
|
35222
|
+
$[82] = t39;
|
|
34832
35223
|
} else {
|
|
34833
|
-
|
|
35224
|
+
t39 = $[82];
|
|
34834
35225
|
}
|
|
34835
|
-
let
|
|
34836
|
-
if ($[
|
|
34837
|
-
|
|
34838
|
-
$[
|
|
35226
|
+
let t40;
|
|
35227
|
+
if ($[83] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
35228
|
+
t40 = /* @__PURE__ */ jsx(Command.Empty, { className: "px-4 py-2 text-sm text-text-secondary dark:text-text-secondary-dark", children: "No results found." });
|
|
35229
|
+
$[83] = t40;
|
|
34839
35230
|
} else {
|
|
34840
|
-
|
|
35231
|
+
t40 = $[83];
|
|
34841
35232
|
}
|
|
34842
|
-
let
|
|
34843
|
-
if ($[
|
|
34844
|
-
|
|
35233
|
+
let t41;
|
|
35234
|
+
if ($[84] !== allValues.length || $[85] !== includeSelectAll || $[86] !== selectedValues.length || $[87] !== toggleAll) {
|
|
35235
|
+
t41 = includeSelectAll && /* @__PURE__ */ jsxs(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: [
|
|
34845
35236
|
/* @__PURE__ */ jsx(InnerCheckBox, { checked: selectedValues.length === allValues.length }),
|
|
34846
35237
|
/* @__PURE__ */ jsx("span", { className: "text-sm text-text-secondary dark:text-text-secondary-dark", children: "(Select All)" })
|
|
34847
35238
|
] }, "all");
|
|
34848
|
-
$[
|
|
34849
|
-
$[
|
|
34850
|
-
$[
|
|
34851
|
-
$[
|
|
34852
|
-
$[
|
|
35239
|
+
$[84] = allValues.length;
|
|
35240
|
+
$[85] = includeSelectAll;
|
|
35241
|
+
$[86] = selectedValues.length;
|
|
35242
|
+
$[87] = toggleAll;
|
|
35243
|
+
$[88] = t41;
|
|
34853
35244
|
} else {
|
|
34854
|
-
|
|
35245
|
+
t41 = $[88];
|
|
34855
35246
|
}
|
|
34856
|
-
let
|
|
34857
|
-
if ($[
|
|
34858
|
-
|
|
34859
|
-
|
|
35247
|
+
let t42;
|
|
35248
|
+
if ($[89] !== children || $[90] !== t41) {
|
|
35249
|
+
t42 = /* @__PURE__ */ jsxs(Command.List, { children: [
|
|
35250
|
+
t40,
|
|
34860
35251
|
/* @__PURE__ */ jsxs(Command.Group, { children: [
|
|
34861
|
-
|
|
35252
|
+
t41,
|
|
34862
35253
|
children
|
|
34863
35254
|
] })
|
|
34864
35255
|
] });
|
|
34865
|
-
$[
|
|
34866
|
-
$[
|
|
34867
|
-
$[
|
|
34868
|
-
} else {
|
|
34869
|
-
|
|
34870
|
-
}
|
|
34871
|
-
let
|
|
34872
|
-
if ($[
|
|
34873
|
-
|
|
34874
|
-
|
|
34875
|
-
|
|
34876
|
-
|
|
35256
|
+
$[89] = children;
|
|
35257
|
+
$[90] = t41;
|
|
35258
|
+
$[91] = t42;
|
|
35259
|
+
} else {
|
|
35260
|
+
t42 = $[91];
|
|
35261
|
+
}
|
|
35262
|
+
let t43;
|
|
35263
|
+
if ($[92] !== t38 || $[93] !== t42) {
|
|
35264
|
+
t43 = /* @__PURE__ */ jsxs(Command, { children: [
|
|
35265
|
+
t38,
|
|
35266
|
+
t39,
|
|
35267
|
+
t42
|
|
34877
35268
|
] });
|
|
34878
|
-
$[
|
|
34879
|
-
$[
|
|
34880
|
-
$[
|
|
35269
|
+
$[92] = t38;
|
|
35270
|
+
$[93] = t42;
|
|
35271
|
+
$[94] = t43;
|
|
34881
35272
|
} else {
|
|
34882
|
-
|
|
35273
|
+
t43 = $[94];
|
|
34883
35274
|
}
|
|
34884
|
-
let
|
|
34885
|
-
if ($[
|
|
34886
|
-
|
|
34887
|
-
$[
|
|
34888
|
-
$[
|
|
34889
|
-
$[
|
|
35275
|
+
let t44;
|
|
35276
|
+
if ($[95] !== t34 || $[96] !== t43) {
|
|
35277
|
+
t44 = /* @__PURE__ */ jsx(PopoverPrimitive.Content, { className: t33, align: "start", sideOffset: 8, onEscapeKeyDown: t34, children: t43 });
|
|
35278
|
+
$[95] = t34;
|
|
35279
|
+
$[96] = t43;
|
|
35280
|
+
$[97] = t44;
|
|
34890
35281
|
} else {
|
|
34891
|
-
|
|
35282
|
+
t44 = $[97];
|
|
34892
35283
|
}
|
|
34893
|
-
let
|
|
34894
|
-
if ($[
|
|
34895
|
-
|
|
34896
|
-
|
|
34897
|
-
|
|
34898
|
-
]
|
|
34899
|
-
$[95] = isPopoverOpen;
|
|
34900
|
-
$[96] = modalPopover;
|
|
34901
|
-
$[97] = onPopoverOpenChange;
|
|
34902
|
-
$[98] = t28;
|
|
34903
|
-
$[99] = t40;
|
|
34904
|
-
$[100] = t41;
|
|
35284
|
+
let t45;
|
|
35285
|
+
if ($[98] !== finalContainer || $[99] !== t44) {
|
|
35286
|
+
t45 = /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { container: finalContainer, children: t44 });
|
|
35287
|
+
$[98] = finalContainer;
|
|
35288
|
+
$[99] = t44;
|
|
35289
|
+
$[100] = t45;
|
|
34905
35290
|
} else {
|
|
34906
|
-
|
|
35291
|
+
t45 = $[100];
|
|
34907
35292
|
}
|
|
34908
|
-
let
|
|
34909
|
-
if ($[101] !==
|
|
34910
|
-
|
|
34911
|
-
|
|
34912
|
-
|
|
35293
|
+
let t46;
|
|
35294
|
+
if ($[101] !== modalPopover || $[102] !== onPopoverOpenChange || $[103] !== t24 || $[104] !== t32 || $[105] !== t45) {
|
|
35295
|
+
t46 = /* @__PURE__ */ jsxs(PopoverPrimitive.Root, { open: t24, onOpenChange: onPopoverOpenChange, modal: modalPopover, children: [
|
|
35296
|
+
t32,
|
|
35297
|
+
t45
|
|
34913
35298
|
] });
|
|
34914
|
-
$[101] =
|
|
34915
|
-
$[102] =
|
|
34916
|
-
$[103] =
|
|
34917
|
-
$[104] =
|
|
35299
|
+
$[101] = modalPopover;
|
|
35300
|
+
$[102] = onPopoverOpenChange;
|
|
35301
|
+
$[103] = t24;
|
|
35302
|
+
$[104] = t32;
|
|
35303
|
+
$[105] = t45;
|
|
35304
|
+
$[106] = t46;
|
|
35305
|
+
} else {
|
|
35306
|
+
t46 = $[106];
|
|
35307
|
+
}
|
|
35308
|
+
let t47;
|
|
35309
|
+
if ($[107] !== t22 || $[108] !== t23 || $[109] !== t46) {
|
|
35310
|
+
t47 = /* @__PURE__ */ jsxs(MultiSelectContext.Provider, { value: t22, children: [
|
|
35311
|
+
t23,
|
|
35312
|
+
t46
|
|
35313
|
+
] });
|
|
35314
|
+
$[107] = t22;
|
|
35315
|
+
$[108] = t23;
|
|
35316
|
+
$[109] = t46;
|
|
35317
|
+
$[110] = t47;
|
|
34918
35318
|
} else {
|
|
34919
|
-
|
|
35319
|
+
t47 = $[110];
|
|
34920
35320
|
}
|
|
34921
|
-
return
|
|
35321
|
+
return t47;
|
|
34922
35322
|
});
|
|
34923
35323
|
MultiSelect.displayName = "MultiSelect";
|
|
34924
35324
|
const MultiSelectItem = React.memo(function MultiSelectItem2(t0) {
|
|
@@ -34976,7 +35376,7 @@ const MultiSelectItem = React.memo(function MultiSelectItem2(t0) {
|
|
|
34976
35376
|
const t4 = isSelected ? "bg-surface-accent-200 dark:bg-surface-accent-950" : "";
|
|
34977
35377
|
let t5;
|
|
34978
35378
|
if ($[10] !== className || $[11] !== t4) {
|
|
34979
|
-
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);
|
|
35379
|
+
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", "text-surface-accent-700 dark:text-surface-accent-300", className);
|
|
34980
35380
|
$[10] = className;
|
|
34981
35381
|
$[11] = t4;
|
|
34982
35382
|
$[12] = t5;
|
|
@@ -34993,7 +35393,7 @@ const MultiSelectItem = React.memo(function MultiSelectItem2(t0) {
|
|
|
34993
35393
|
}
|
|
34994
35394
|
let t7;
|
|
34995
35395
|
if ($[15] !== children || $[16] !== t3 || $[17] !== t5 || $[18] !== t6) {
|
|
34996
|
-
t7 = /* @__PURE__ */ jsxs(Command.Item, { onMouseDown: _temp2, onSelect: t3, className: t5, children: [
|
|
35396
|
+
t7 = /* @__PURE__ */ jsxs(Command.Item, { onMouseDown: _temp2$1, onSelect: t3, className: t5, children: [
|
|
34997
35397
|
t6,
|
|
34998
35398
|
children
|
|
34999
35399
|
] });
|
|
@@ -35051,13 +35451,13 @@ const InnerCheckBox = React.memo(function InnerCheckBox2(t0) {
|
|
|
35051
35451
|
}
|
|
35052
35452
|
return t7;
|
|
35053
35453
|
});
|
|
35054
|
-
function _temp$
|
|
35454
|
+
function _temp$2(child) {
|
|
35055
35455
|
if (React.isValidElement(child)) {
|
|
35056
35456
|
return child.props.value;
|
|
35057
35457
|
}
|
|
35058
35458
|
return null;
|
|
35059
35459
|
}
|
|
35060
|
-
function _temp2(e) {
|
|
35460
|
+
function _temp2$1(e) {
|
|
35061
35461
|
e.preventDefault();
|
|
35062
35462
|
e.stopPropagation();
|
|
35063
35463
|
}
|
|
@@ -35170,13 +35570,13 @@ const RadioGroupItem = React.forwardRef((t0, ref) => {
|
|
|
35170
35570
|
});
|
|
35171
35571
|
RadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;
|
|
35172
35572
|
function SearchBar(t0) {
|
|
35173
|
-
const $ = c(
|
|
35573
|
+
const $ = c(47);
|
|
35174
35574
|
const {
|
|
35175
35575
|
onClick,
|
|
35176
35576
|
onTextSearch,
|
|
35177
35577
|
placeholder: t1,
|
|
35178
35578
|
expandable: t2,
|
|
35179
|
-
|
|
35579
|
+
size: t3,
|
|
35180
35580
|
innerClassName,
|
|
35181
35581
|
className,
|
|
35182
35582
|
autoFocus,
|
|
@@ -35186,7 +35586,7 @@ function SearchBar(t0) {
|
|
|
35186
35586
|
} = t0;
|
|
35187
35587
|
const placeholder = t1 === void 0 ? "Search" : t1;
|
|
35188
35588
|
const expandable = t2 === void 0 ? false : t2;
|
|
35189
|
-
const
|
|
35589
|
+
const size = t3 === void 0 ? "medium" : t3;
|
|
35190
35590
|
const [searchText, setSearchText] = useState("");
|
|
35191
35591
|
const [active, setActive] = useState(false);
|
|
35192
35592
|
const deferredValues = useDebounceValue(searchText, 200);
|
|
@@ -35232,217 +35632,586 @@ function SearchBar(t0) {
|
|
|
35232
35632
|
t6 = $[6];
|
|
35233
35633
|
}
|
|
35234
35634
|
const clearText = t6;
|
|
35235
|
-
const
|
|
35236
|
-
|
|
35237
|
-
|
|
35238
|
-
|
|
35635
|
+
const heightClass = size === "small" ? "h-[36px]" : "h-[44px]";
|
|
35636
|
+
const iconPaddingClass = size === "small" ? "px-2" : "px-4";
|
|
35637
|
+
const inputPaddingClass = size === "small" ? "pl-8" : "pl-12";
|
|
35638
|
+
let t7;
|
|
35639
|
+
if ($[7] !== className || $[8] !== heightClass) {
|
|
35640
|
+
t7 = cls("relative", heightClass, "bg-surface-accent-50 dark:bg-surface-800 border", defaultBorderMixin, "rounded-lg", className);
|
|
35239
35641
|
$[7] = className;
|
|
35240
|
-
$[8] =
|
|
35241
|
-
$[9] =
|
|
35642
|
+
$[8] = heightClass;
|
|
35643
|
+
$[9] = t7;
|
|
35644
|
+
} else {
|
|
35645
|
+
t7 = $[9];
|
|
35646
|
+
}
|
|
35647
|
+
let t8;
|
|
35648
|
+
if ($[10] !== iconPaddingClass) {
|
|
35649
|
+
t8 = cls("absolute p-0 h-full pointer-events-none flex items-center justify-center top-0", iconPaddingClass);
|
|
35650
|
+
$[10] = iconPaddingClass;
|
|
35651
|
+
$[11] = t8;
|
|
35242
35652
|
} else {
|
|
35243
|
-
t8 = $[
|
|
35653
|
+
t8 = $[11];
|
|
35244
35654
|
}
|
|
35245
35655
|
let t9;
|
|
35246
|
-
if ($[
|
|
35247
|
-
t9 =
|
|
35248
|
-
$[
|
|
35249
|
-
$[
|
|
35656
|
+
if ($[12] !== loading || $[13] !== size) {
|
|
35657
|
+
t9 = loading ? /* @__PURE__ */ jsx(CircularProgress, { size: "smallest" }) : /* @__PURE__ */ jsx(SearchIcon, { className: "text-text-disabled dark:text-text-disabled-dark", size: size === "small" ? "small" : "medium" });
|
|
35658
|
+
$[12] = loading;
|
|
35659
|
+
$[13] = size;
|
|
35660
|
+
$[14] = t9;
|
|
35250
35661
|
} else {
|
|
35251
|
-
t9 = $[
|
|
35662
|
+
t9 = $[14];
|
|
35252
35663
|
}
|
|
35253
|
-
|
|
35254
|
-
|
|
35255
|
-
|
|
35256
|
-
|
|
35257
|
-
|
|
35664
|
+
let t10;
|
|
35665
|
+
if ($[15] !== t8 || $[16] !== t9) {
|
|
35666
|
+
t10 = /* @__PURE__ */ jsx("div", { className: t8, children: t9 });
|
|
35667
|
+
$[15] = t8;
|
|
35668
|
+
$[16] = t9;
|
|
35669
|
+
$[17] = t10;
|
|
35670
|
+
} else {
|
|
35671
|
+
t10 = $[17];
|
|
35672
|
+
}
|
|
35673
|
+
const t11 = searchText ?? "";
|
|
35674
|
+
const t12 = !onTextSearch;
|
|
35675
|
+
let t13;
|
|
35676
|
+
if ($[18] !== onTextSearch) {
|
|
35677
|
+
t13 = onTextSearch ? (event) => {
|
|
35258
35678
|
setSearchText(event.target.value);
|
|
35259
35679
|
} : void 0;
|
|
35260
|
-
$[
|
|
35261
|
-
$[
|
|
35680
|
+
$[18] = onTextSearch;
|
|
35681
|
+
$[19] = t13;
|
|
35262
35682
|
} else {
|
|
35263
|
-
|
|
35683
|
+
t13 = $[19];
|
|
35264
35684
|
}
|
|
35265
|
-
let t13;
|
|
35266
35685
|
let t14;
|
|
35267
|
-
|
|
35268
|
-
|
|
35269
|
-
t14 = () => setActive(
|
|
35270
|
-
|
|
35271
|
-
$[
|
|
35686
|
+
let t15;
|
|
35687
|
+
if ($[20] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
35688
|
+
t14 = () => setActive(true);
|
|
35689
|
+
t15 = () => setActive(false);
|
|
35690
|
+
$[20] = t14;
|
|
35691
|
+
$[21] = t15;
|
|
35272
35692
|
} else {
|
|
35273
|
-
|
|
35274
|
-
|
|
35693
|
+
t14 = $[20];
|
|
35694
|
+
t15 = $[21];
|
|
35275
35695
|
}
|
|
35276
|
-
const
|
|
35277
|
-
const
|
|
35278
|
-
|
|
35279
|
-
|
|
35280
|
-
|
|
35281
|
-
|
|
35282
|
-
$[
|
|
35283
|
-
$[
|
|
35284
|
-
$[
|
|
35696
|
+
const t16 = (disabled || loading) && "pointer-events-none";
|
|
35697
|
+
const t17 = size === "small" ? "text-sm" : "";
|
|
35698
|
+
const t18 = expandable ? active ? "w-[220px]" : "w-[180px]" : "";
|
|
35699
|
+
let t19;
|
|
35700
|
+
if ($[22] !== innerClassName || $[23] !== inputPaddingClass || $[24] !== t16 || $[25] !== t17 || $[26] !== t18) {
|
|
35701
|
+
t19 = cls(t16, "placeholder-text-disabled dark:placeholder-text-disabled-dark", "relative flex items-center rounded-lg transition-all bg-transparent outline-none appearance-none border-none", inputPaddingClass, "h-full text-current", t17, t18, innerClassName);
|
|
35702
|
+
$[22] = innerClassName;
|
|
35703
|
+
$[23] = inputPaddingClass;
|
|
35704
|
+
$[24] = t16;
|
|
35705
|
+
$[25] = t17;
|
|
35706
|
+
$[26] = t18;
|
|
35707
|
+
$[27] = t19;
|
|
35285
35708
|
} else {
|
|
35286
|
-
|
|
35709
|
+
t19 = $[27];
|
|
35287
35710
|
}
|
|
35288
|
-
let
|
|
35289
|
-
if ($[
|
|
35290
|
-
|
|
35291
|
-
$[
|
|
35292
|
-
$[
|
|
35293
|
-
$[
|
|
35294
|
-
$[
|
|
35295
|
-
$[
|
|
35296
|
-
$[
|
|
35297
|
-
$[
|
|
35298
|
-
$[
|
|
35299
|
-
$[
|
|
35711
|
+
let t20;
|
|
35712
|
+
if ($[28] !== autoFocus || $[29] !== inputRef || $[30] !== onClick || $[31] !== placeholder || $[32] !== t11 || $[33] !== t12 || $[34] !== t13 || $[35] !== t19) {
|
|
35713
|
+
t20 = /* @__PURE__ */ jsx("input", { value: t11, ref: inputRef, onClick, placeholder, readOnly: t12, onChange: t13, autoFocus, onFocus: t14, onBlur: t15, className: t19 });
|
|
35714
|
+
$[28] = autoFocus;
|
|
35715
|
+
$[29] = inputRef;
|
|
35716
|
+
$[30] = onClick;
|
|
35717
|
+
$[31] = placeholder;
|
|
35718
|
+
$[32] = t11;
|
|
35719
|
+
$[33] = t12;
|
|
35720
|
+
$[34] = t13;
|
|
35721
|
+
$[35] = t19;
|
|
35722
|
+
$[36] = t20;
|
|
35300
35723
|
} else {
|
|
35301
|
-
|
|
35724
|
+
t20 = $[36];
|
|
35302
35725
|
}
|
|
35303
|
-
let
|
|
35304
|
-
if ($[
|
|
35305
|
-
|
|
35726
|
+
let t21;
|
|
35727
|
+
if ($[37] !== clearText || $[38] !== searchText || $[39] !== size) {
|
|
35728
|
+
t21 = searchText ? /* @__PURE__ */ jsx(IconButton, { className: `${size === "small" ? "mr-0 top-0" : "mr-1 top-0"} absolute right-0 z-10`, size: "small", onClick: clearText, children: /* @__PURE__ */ jsx(CloseIcon, { size: "smallest" }) }) : /* @__PURE__ */ jsx("div", { style: {
|
|
35306
35729
|
width: 26
|
|
35307
35730
|
} });
|
|
35308
|
-
$[
|
|
35309
|
-
$[
|
|
35310
|
-
$[
|
|
35311
|
-
$[
|
|
35731
|
+
$[37] = clearText;
|
|
35732
|
+
$[38] = searchText;
|
|
35733
|
+
$[39] = size;
|
|
35734
|
+
$[40] = t21;
|
|
35312
35735
|
} else {
|
|
35313
|
-
|
|
35736
|
+
t21 = $[40];
|
|
35314
35737
|
}
|
|
35315
|
-
let
|
|
35316
|
-
if ($[
|
|
35317
|
-
|
|
35318
|
-
|
|
35319
|
-
|
|
35320
|
-
|
|
35738
|
+
let t22;
|
|
35739
|
+
if ($[41] !== onClick || $[42] !== t10 || $[43] !== t20 || $[44] !== t21 || $[45] !== t7) {
|
|
35740
|
+
t22 = /* @__PURE__ */ jsxs("div", { onClick, className: t7, children: [
|
|
35741
|
+
t10,
|
|
35742
|
+
t20,
|
|
35743
|
+
t21
|
|
35321
35744
|
] });
|
|
35322
|
-
$[
|
|
35323
|
-
$[
|
|
35324
|
-
$[
|
|
35325
|
-
$[
|
|
35326
|
-
$[
|
|
35327
|
-
$[
|
|
35745
|
+
$[41] = onClick;
|
|
35746
|
+
$[42] = t10;
|
|
35747
|
+
$[43] = t20;
|
|
35748
|
+
$[44] = t21;
|
|
35749
|
+
$[45] = t7;
|
|
35750
|
+
$[46] = t22;
|
|
35328
35751
|
} else {
|
|
35329
|
-
|
|
35752
|
+
t22 = $[46];
|
|
35330
35753
|
}
|
|
35331
|
-
return
|
|
35754
|
+
return t22;
|
|
35332
35755
|
}
|
|
35333
|
-
const Select = forwardRef(({
|
|
35334
|
-
|
|
35335
|
-
|
|
35336
|
-
|
|
35337
|
-
|
|
35338
|
-
|
|
35339
|
-
|
|
35340
|
-
|
|
35341
|
-
|
|
35342
|
-
|
|
35343
|
-
|
|
35344
|
-
|
|
35345
|
-
|
|
35346
|
-
|
|
35347
|
-
|
|
35348
|
-
|
|
35349
|
-
|
|
35350
|
-
|
|
35351
|
-
|
|
35352
|
-
|
|
35353
|
-
|
|
35354
|
-
|
|
35355
|
-
|
|
35356
|
-
|
|
35357
|
-
|
|
35358
|
-
|
|
35359
|
-
|
|
35756
|
+
const Select = forwardRef((t0, ref) => {
|
|
35757
|
+
const $ = c(121);
|
|
35758
|
+
let children;
|
|
35759
|
+
let className;
|
|
35760
|
+
let disabled;
|
|
35761
|
+
let endAdornment;
|
|
35762
|
+
let error;
|
|
35763
|
+
let id;
|
|
35764
|
+
let inputClassName;
|
|
35765
|
+
let inputRef;
|
|
35766
|
+
let invisible;
|
|
35767
|
+
let label;
|
|
35768
|
+
let manualContainer;
|
|
35769
|
+
let name;
|
|
35770
|
+
let onChange;
|
|
35771
|
+
let onOpenChange;
|
|
35772
|
+
let onValueChange;
|
|
35773
|
+
let open;
|
|
35774
|
+
let placeholder;
|
|
35775
|
+
let props;
|
|
35776
|
+
let renderValue;
|
|
35777
|
+
let t1;
|
|
35778
|
+
let t2;
|
|
35779
|
+
let t3;
|
|
35780
|
+
let t4;
|
|
35781
|
+
let t5;
|
|
35782
|
+
let value;
|
|
35783
|
+
let viewportClassName;
|
|
35784
|
+
if ($[0] !== t0) {
|
|
35785
|
+
({
|
|
35786
|
+
inputRef,
|
|
35787
|
+
open,
|
|
35788
|
+
name,
|
|
35789
|
+
fullWidth: t1,
|
|
35790
|
+
id,
|
|
35791
|
+
onOpenChange,
|
|
35792
|
+
value,
|
|
35793
|
+
onChange,
|
|
35794
|
+
onValueChange,
|
|
35795
|
+
className,
|
|
35796
|
+
inputClassName,
|
|
35797
|
+
viewportClassName,
|
|
35798
|
+
placeholder,
|
|
35799
|
+
renderValue,
|
|
35800
|
+
label,
|
|
35801
|
+
size: t2,
|
|
35802
|
+
error,
|
|
35803
|
+
disabled,
|
|
35804
|
+
padding: t3,
|
|
35805
|
+
position: t4,
|
|
35806
|
+
endAdornment,
|
|
35807
|
+
invisible,
|
|
35808
|
+
children,
|
|
35809
|
+
dataType: t5,
|
|
35810
|
+
portalContainer: manualContainer,
|
|
35811
|
+
...props
|
|
35812
|
+
} = t0);
|
|
35813
|
+
$[0] = t0;
|
|
35814
|
+
$[1] = children;
|
|
35815
|
+
$[2] = className;
|
|
35816
|
+
$[3] = disabled;
|
|
35817
|
+
$[4] = endAdornment;
|
|
35818
|
+
$[5] = error;
|
|
35819
|
+
$[6] = id;
|
|
35820
|
+
$[7] = inputClassName;
|
|
35821
|
+
$[8] = inputRef;
|
|
35822
|
+
$[9] = invisible;
|
|
35823
|
+
$[10] = label;
|
|
35824
|
+
$[11] = manualContainer;
|
|
35825
|
+
$[12] = name;
|
|
35826
|
+
$[13] = onChange;
|
|
35827
|
+
$[14] = onOpenChange;
|
|
35828
|
+
$[15] = onValueChange;
|
|
35829
|
+
$[16] = open;
|
|
35830
|
+
$[17] = placeholder;
|
|
35831
|
+
$[18] = props;
|
|
35832
|
+
$[19] = renderValue;
|
|
35833
|
+
$[20] = t1;
|
|
35834
|
+
$[21] = t2;
|
|
35835
|
+
$[22] = t3;
|
|
35836
|
+
$[23] = t4;
|
|
35837
|
+
$[24] = t5;
|
|
35838
|
+
$[25] = value;
|
|
35839
|
+
$[26] = viewportClassName;
|
|
35840
|
+
} else {
|
|
35841
|
+
children = $[1];
|
|
35842
|
+
className = $[2];
|
|
35843
|
+
disabled = $[3];
|
|
35844
|
+
endAdornment = $[4];
|
|
35845
|
+
error = $[5];
|
|
35846
|
+
id = $[6];
|
|
35847
|
+
inputClassName = $[7];
|
|
35848
|
+
inputRef = $[8];
|
|
35849
|
+
invisible = $[9];
|
|
35850
|
+
label = $[10];
|
|
35851
|
+
manualContainer = $[11];
|
|
35852
|
+
name = $[12];
|
|
35853
|
+
onChange = $[13];
|
|
35854
|
+
onOpenChange = $[14];
|
|
35855
|
+
onValueChange = $[15];
|
|
35856
|
+
open = $[16];
|
|
35857
|
+
placeholder = $[17];
|
|
35858
|
+
props = $[18];
|
|
35859
|
+
renderValue = $[19];
|
|
35860
|
+
t1 = $[20];
|
|
35861
|
+
t2 = $[21];
|
|
35862
|
+
t3 = $[22];
|
|
35863
|
+
t4 = $[23];
|
|
35864
|
+
t5 = $[24];
|
|
35865
|
+
value = $[25];
|
|
35866
|
+
viewportClassName = $[26];
|
|
35867
|
+
}
|
|
35868
|
+
const fullWidth = t1 === void 0 ? false : t1;
|
|
35869
|
+
const size = t2 === void 0 ? "large" : t2;
|
|
35870
|
+
const padding = t3 === void 0 ? true : t3;
|
|
35871
|
+
const position = t4 === void 0 ? "item-aligned" : t4;
|
|
35872
|
+
const dataType = t5 === void 0 ? "string" : t5;
|
|
35360
35873
|
const [openInternal, setOpenInternal] = useState(open ?? false);
|
|
35361
|
-
|
|
35362
|
-
|
|
35363
|
-
|
|
35364
|
-
|
|
35365
|
-
|
|
35366
|
-
|
|
35367
|
-
|
|
35368
|
-
|
|
35369
|
-
|
|
35370
|
-
|
|
35371
|
-
|
|
35372
|
-
|
|
35373
|
-
|
|
35374
|
-
|
|
35375
|
-
|
|
35376
|
-
|
|
35377
|
-
|
|
35874
|
+
let t6;
|
|
35875
|
+
let t7;
|
|
35876
|
+
if ($[27] !== open) {
|
|
35877
|
+
t6 = () => {
|
|
35878
|
+
setOpenInternal(open ?? false);
|
|
35879
|
+
};
|
|
35880
|
+
t7 = [open];
|
|
35881
|
+
$[27] = open;
|
|
35882
|
+
$[28] = t6;
|
|
35883
|
+
$[29] = t7;
|
|
35884
|
+
} else {
|
|
35885
|
+
t6 = $[28];
|
|
35886
|
+
t7 = $[29];
|
|
35887
|
+
}
|
|
35888
|
+
useEffect(t6, t7);
|
|
35889
|
+
const contextContainer = usePortalContainer();
|
|
35890
|
+
const finalContainer = manualContainer ?? contextContainer ?? void 0;
|
|
35891
|
+
let t8;
|
|
35892
|
+
if ($[30] !== dataType || $[31] !== name || $[32] !== onChange || $[33] !== onValueChange) {
|
|
35893
|
+
t8 = (newValue) => {
|
|
35894
|
+
let typedValue = newValue;
|
|
35895
|
+
if (dataType === "boolean") {
|
|
35896
|
+
if (newValue === "true") {
|
|
35897
|
+
typedValue = true;
|
|
35898
|
+
} else {
|
|
35899
|
+
if (newValue === "false") {
|
|
35900
|
+
typedValue = false;
|
|
35901
|
+
}
|
|
35378
35902
|
}
|
|
35379
|
-
}
|
|
35380
|
-
|
|
35381
|
-
|
|
35382
|
-
|
|
35903
|
+
} else {
|
|
35904
|
+
if (dataType === "number") {
|
|
35905
|
+
if (!isNaN(Number(newValue)) && newValue.trim() !== "") {
|
|
35906
|
+
typedValue = Number(newValue);
|
|
35907
|
+
}
|
|
35908
|
+
}
|
|
35909
|
+
}
|
|
35910
|
+
onValueChange?.(typedValue);
|
|
35911
|
+
if (onChange) {
|
|
35912
|
+
const event = {
|
|
35913
|
+
target: {
|
|
35914
|
+
name,
|
|
35915
|
+
value: typedValue
|
|
35916
|
+
}
|
|
35917
|
+
};
|
|
35918
|
+
onChange(event);
|
|
35919
|
+
}
|
|
35920
|
+
};
|
|
35921
|
+
$[30] = dataType;
|
|
35922
|
+
$[31] = name;
|
|
35923
|
+
$[32] = onChange;
|
|
35924
|
+
$[33] = onValueChange;
|
|
35925
|
+
$[34] = t8;
|
|
35926
|
+
} else {
|
|
35927
|
+
t8 = $[34];
|
|
35928
|
+
}
|
|
35929
|
+
const onValueChangeInternal = t8;
|
|
35383
35930
|
const hasValue = Array.isArray(value) ? value.length > 0 : value != null && value !== "" && value !== void 0;
|
|
35384
35931
|
const stringValue = value !== void 0 ? String(value) : void 0;
|
|
35385
|
-
|
|
35386
|
-
|
|
35387
|
-
|
|
35388
|
-
|
|
35389
|
-
|
|
35390
|
-
|
|
35391
|
-
|
|
35392
|
-
|
|
35393
|
-
|
|
35394
|
-
|
|
35395
|
-
|
|
35396
|
-
|
|
35397
|
-
|
|
35398
|
-
|
|
35399
|
-
|
|
35400
|
-
|
|
35932
|
+
let t9;
|
|
35933
|
+
bb0: {
|
|
35934
|
+
if (!hasValue || renderValue) {
|
|
35935
|
+
t9 = null;
|
|
35936
|
+
break bb0;
|
|
35937
|
+
}
|
|
35938
|
+
let found;
|
|
35939
|
+
if ($[35] !== children || $[36] !== value) {
|
|
35940
|
+
found = null;
|
|
35941
|
+
Children.forEach(children, (child) => {
|
|
35942
|
+
if (React__default.isValidElement(child) && String(child.props.value) === String(value)) {
|
|
35943
|
+
found = child.props.children;
|
|
35944
|
+
}
|
|
35945
|
+
});
|
|
35946
|
+
$[35] = children;
|
|
35947
|
+
$[36] = value;
|
|
35948
|
+
$[37] = found;
|
|
35949
|
+
} else {
|
|
35950
|
+
found = $[37];
|
|
35951
|
+
}
|
|
35952
|
+
t9 = found;
|
|
35953
|
+
}
|
|
35954
|
+
const displayChildren = t9;
|
|
35955
|
+
let t10;
|
|
35956
|
+
if ($[38] !== onOpenChange) {
|
|
35957
|
+
t10 = (open_0) => {
|
|
35958
|
+
onOpenChange?.(open_0);
|
|
35959
|
+
setOpenInternal(open_0);
|
|
35960
|
+
};
|
|
35961
|
+
$[38] = onOpenChange;
|
|
35962
|
+
$[39] = t10;
|
|
35963
|
+
} else {
|
|
35964
|
+
t10 = $[39];
|
|
35965
|
+
}
|
|
35966
|
+
let t11;
|
|
35967
|
+
if ($[40] !== error || $[41] !== label) {
|
|
35968
|
+
t11 = typeof label === "string" ? /* @__PURE__ */ jsx(SelectInputLabel, { error, children: label }) : label;
|
|
35969
|
+
$[40] = error;
|
|
35970
|
+
$[41] = label;
|
|
35971
|
+
$[42] = t11;
|
|
35972
|
+
} else {
|
|
35973
|
+
t11 = $[42];
|
|
35974
|
+
}
|
|
35975
|
+
const t12 = invisible ? fieldBackgroundInvisibleMixin : fieldBackgroundMixin;
|
|
35976
|
+
const t13 = disabled ? fieldBackgroundDisabledMixin : fieldBackgroundHoverMixin;
|
|
35977
|
+
const t14 = size === "smallest";
|
|
35978
|
+
const t15 = size === "small";
|
|
35979
|
+
const t16 = size === "medium";
|
|
35980
|
+
const t17 = size === "large";
|
|
35981
|
+
const t18 = !fullWidth;
|
|
35982
|
+
let t19;
|
|
35983
|
+
if ($[43] !== className || $[44] !== fullWidth || $[45] !== t12 || $[46] !== t13 || $[47] !== t14 || $[48] !== t15 || $[49] !== t16 || $[50] !== t17 || $[51] !== t18) {
|
|
35984
|
+
t19 = cls("select-none rounded-md text-sm", t12, t13, "relative flex items-center", className, {
|
|
35985
|
+
"min-h-[28px]": t14,
|
|
35986
|
+
"min-h-[32px]": t15,
|
|
35987
|
+
"min-h-[44px]": t16,
|
|
35988
|
+
"min-h-[64px]": t17,
|
|
35989
|
+
"w-fit": t18,
|
|
35990
|
+
"w-full": fullWidth
|
|
35991
|
+
});
|
|
35992
|
+
$[43] = className;
|
|
35993
|
+
$[44] = fullWidth;
|
|
35994
|
+
$[45] = t12;
|
|
35995
|
+
$[46] = t13;
|
|
35996
|
+
$[47] = t14;
|
|
35997
|
+
$[48] = t15;
|
|
35998
|
+
$[49] = t16;
|
|
35999
|
+
$[50] = t17;
|
|
36000
|
+
$[51] = t18;
|
|
36001
|
+
$[52] = t19;
|
|
36002
|
+
} else {
|
|
36003
|
+
t19 = $[52];
|
|
36004
|
+
}
|
|
36005
|
+
let t20;
|
|
36006
|
+
if ($[53] !== disabled || $[54] !== error || $[55] !== fullWidth || $[56] !== inputClassName || $[57] !== padding || $[58] !== size) {
|
|
36007
|
+
t20 = cls("h-full", padding ? {
|
|
36008
|
+
"px-4": size === "large",
|
|
36009
|
+
"px-3": size === "medium",
|
|
36010
|
+
"px-2": size === "small" || size === "smallest"
|
|
36011
|
+
} : "", "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", {
|
|
35401
36012
|
"min-h-[28px]": size === "smallest",
|
|
35402
36013
|
"min-h-[32px]": size === "small",
|
|
35403
36014
|
"min-h-[44px]": size === "medium",
|
|
35404
36015
|
"min-h-[64px]": size === "large",
|
|
35405
|
-
"w-
|
|
35406
|
-
"w-
|
|
35407
|
-
}
|
|
35408
|
-
|
|
35409
|
-
|
|
35410
|
-
|
|
35411
|
-
|
|
35412
|
-
|
|
35413
|
-
|
|
35414
|
-
|
|
35415
|
-
|
|
35416
|
-
|
|
35417
|
-
|
|
35418
|
-
|
|
35419
|
-
|
|
35420
|
-
|
|
35421
|
-
|
|
35422
|
-
|
|
35423
|
-
|
|
35424
|
-
|
|
35425
|
-
|
|
35426
|
-
|
|
35427
|
-
|
|
35428
|
-
|
|
35429
|
-
|
|
35430
|
-
|
|
35431
|
-
|
|
35432
|
-
|
|
35433
|
-
|
|
35434
|
-
|
|
35435
|
-
|
|
35436
|
-
|
|
35437
|
-
|
|
35438
|
-
|
|
35439
|
-
|
|
35440
|
-
|
|
35441
|
-
]
|
|
35442
|
-
|
|
36016
|
+
"w-full": fullWidth,
|
|
36017
|
+
"w-fit": !fullWidth
|
|
36018
|
+
}, inputClassName);
|
|
36019
|
+
$[53] = disabled;
|
|
36020
|
+
$[54] = error;
|
|
36021
|
+
$[55] = fullWidth;
|
|
36022
|
+
$[56] = inputClassName;
|
|
36023
|
+
$[57] = padding;
|
|
36024
|
+
$[58] = size;
|
|
36025
|
+
$[59] = t20;
|
|
36026
|
+
} else {
|
|
36027
|
+
t20 = $[59];
|
|
36028
|
+
}
|
|
36029
|
+
const t21 = size === "smallest";
|
|
36030
|
+
const t22 = size === "small";
|
|
36031
|
+
const t23 = size === "medium";
|
|
36032
|
+
const t24 = size === "large";
|
|
36033
|
+
let t25;
|
|
36034
|
+
if ($[60] !== t21 || $[61] !== t22 || $[62] !== t23 || $[63] !== t24) {
|
|
36035
|
+
t25 = cls("flex-grow max-w-full flex flex-row gap-2 items-center", "overflow-visible", {
|
|
36036
|
+
"min-h-[28px]": t21,
|
|
36037
|
+
"min-h-[32px]": t22,
|
|
36038
|
+
"min-h-[44px]": t23,
|
|
36039
|
+
"min-h-[64px]": t24
|
|
36040
|
+
});
|
|
36041
|
+
$[60] = t21;
|
|
36042
|
+
$[61] = t22;
|
|
36043
|
+
$[62] = t23;
|
|
36044
|
+
$[63] = t24;
|
|
36045
|
+
$[64] = t25;
|
|
36046
|
+
} else {
|
|
36047
|
+
t25 = $[64];
|
|
36048
|
+
}
|
|
36049
|
+
let t26;
|
|
36050
|
+
if ($[65] !== displayChildren || $[66] !== hasValue || $[67] !== placeholder || $[68] !== renderValue || $[69] !== value) {
|
|
36051
|
+
t26 = hasValue && value !== void 0 && renderValue ? renderValue(value) : displayChildren || placeholder;
|
|
36052
|
+
$[65] = displayChildren;
|
|
36053
|
+
$[66] = hasValue;
|
|
36054
|
+
$[67] = placeholder;
|
|
36055
|
+
$[68] = renderValue;
|
|
36056
|
+
$[69] = value;
|
|
36057
|
+
$[70] = t26;
|
|
36058
|
+
} else {
|
|
36059
|
+
t26 = $[70];
|
|
36060
|
+
}
|
|
36061
|
+
let t27;
|
|
36062
|
+
if ($[71] !== placeholder || $[72] !== t26) {
|
|
36063
|
+
t27 = /* @__PURE__ */ jsx(SelectPrimitive.Value, { onClick: _temp$1, placeholder, className: "w-full", children: t26 });
|
|
36064
|
+
$[71] = placeholder;
|
|
36065
|
+
$[72] = t26;
|
|
36066
|
+
$[73] = t27;
|
|
36067
|
+
} else {
|
|
36068
|
+
t27 = $[73];
|
|
36069
|
+
}
|
|
36070
|
+
let t28;
|
|
36071
|
+
if ($[74] !== ref || $[75] !== t25 || $[76] !== t27) {
|
|
36072
|
+
t28 = /* @__PURE__ */ jsx("div", { ref, className: t25, children: t27 });
|
|
36073
|
+
$[74] = ref;
|
|
36074
|
+
$[75] = t25;
|
|
36075
|
+
$[76] = t27;
|
|
36076
|
+
$[77] = t28;
|
|
36077
|
+
} else {
|
|
36078
|
+
t28 = $[77];
|
|
36079
|
+
}
|
|
36080
|
+
const t29 = size === "large" ? "medium" : "small";
|
|
36081
|
+
const t30 = open ? "rotate-180" : "";
|
|
36082
|
+
const t31 = size === "large";
|
|
36083
|
+
const t32 = size === "medium" || size === "small";
|
|
36084
|
+
let t33;
|
|
36085
|
+
if ($[78] !== t30 || $[79] !== t31 || $[80] !== t32) {
|
|
36086
|
+
t33 = cls("transition", t30, {
|
|
36087
|
+
"px-2": t31,
|
|
36088
|
+
"px-1": t32
|
|
36089
|
+
});
|
|
36090
|
+
$[78] = t30;
|
|
36091
|
+
$[79] = t31;
|
|
36092
|
+
$[80] = t32;
|
|
36093
|
+
$[81] = t33;
|
|
36094
|
+
} else {
|
|
36095
|
+
t33 = $[81];
|
|
36096
|
+
}
|
|
36097
|
+
let t34;
|
|
36098
|
+
if ($[82] !== t29 || $[83] !== t33) {
|
|
36099
|
+
t34 = /* @__PURE__ */ jsx(SelectPrimitive.Icon, { asChild: true, children: /* @__PURE__ */ jsx(KeyboardArrowDownIcon, { size: t29, className: t33 }) });
|
|
36100
|
+
$[82] = t29;
|
|
36101
|
+
$[83] = t33;
|
|
36102
|
+
$[84] = t34;
|
|
36103
|
+
} else {
|
|
36104
|
+
t34 = $[84];
|
|
36105
|
+
}
|
|
36106
|
+
let t35;
|
|
36107
|
+
if ($[85] !== id || $[86] !== inputRef || $[87] !== t20 || $[88] !== t28 || $[89] !== t34) {
|
|
36108
|
+
t35 = /* @__PURE__ */ jsxs(SelectPrimitive.Trigger, { ref: inputRef, id, asChild: false, type: "button", className: t20, children: [
|
|
36109
|
+
t28,
|
|
36110
|
+
t34
|
|
36111
|
+
] });
|
|
36112
|
+
$[85] = id;
|
|
36113
|
+
$[86] = inputRef;
|
|
36114
|
+
$[87] = t20;
|
|
36115
|
+
$[88] = t28;
|
|
36116
|
+
$[89] = t34;
|
|
36117
|
+
$[90] = t35;
|
|
36118
|
+
} else {
|
|
36119
|
+
t35 = $[90];
|
|
36120
|
+
}
|
|
36121
|
+
let t36;
|
|
36122
|
+
if ($[91] !== endAdornment) {
|
|
36123
|
+
t36 = endAdornment && /* @__PURE__ */ jsx("div", { className: cls("h-full flex items-center absolute right-0 pr-12"), onClick: _temp2, children: endAdornment });
|
|
36124
|
+
$[91] = endAdornment;
|
|
36125
|
+
$[92] = t36;
|
|
36126
|
+
} else {
|
|
36127
|
+
t36 = $[92];
|
|
36128
|
+
}
|
|
36129
|
+
let t37;
|
|
36130
|
+
if ($[93] !== t19 || $[94] !== t35 || $[95] !== t36) {
|
|
36131
|
+
t37 = /* @__PURE__ */ jsxs("div", { className: t19, children: [
|
|
36132
|
+
t35,
|
|
36133
|
+
t36
|
|
36134
|
+
] });
|
|
36135
|
+
$[93] = t19;
|
|
36136
|
+
$[94] = t35;
|
|
36137
|
+
$[95] = t36;
|
|
36138
|
+
$[96] = t37;
|
|
36139
|
+
} else {
|
|
36140
|
+
t37 = $[96];
|
|
36141
|
+
}
|
|
36142
|
+
let t38;
|
|
36143
|
+
if ($[97] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
36144
|
+
t38 = cls(focusedDisabled, "z-50 relative overflow-hidden border bg-white dark:bg-surface-900 p-2 rounded-lg", defaultBorderMixin);
|
|
36145
|
+
$[97] = t38;
|
|
36146
|
+
} else {
|
|
36147
|
+
t38 = $[97];
|
|
36148
|
+
}
|
|
36149
|
+
let t39;
|
|
36150
|
+
if ($[98] !== viewportClassName) {
|
|
36151
|
+
t39 = cls("p-1", viewportClassName);
|
|
36152
|
+
$[98] = viewportClassName;
|
|
36153
|
+
$[99] = t39;
|
|
36154
|
+
} else {
|
|
36155
|
+
t39 = $[99];
|
|
36156
|
+
}
|
|
36157
|
+
let t40;
|
|
36158
|
+
if ($[100] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
36159
|
+
t40 = {
|
|
35443
36160
|
maxHeight: "var(--radix-select-content-available-height)"
|
|
35444
|
-
}
|
|
35445
|
-
|
|
36161
|
+
};
|
|
36162
|
+
$[100] = t40;
|
|
36163
|
+
} else {
|
|
36164
|
+
t40 = $[100];
|
|
36165
|
+
}
|
|
36166
|
+
let t41;
|
|
36167
|
+
if ($[101] !== children || $[102] !== t39) {
|
|
36168
|
+
t41 = /* @__PURE__ */ jsx(SelectPrimitive.Viewport, { className: t39, style: t40, children });
|
|
36169
|
+
$[101] = children;
|
|
36170
|
+
$[102] = t39;
|
|
36171
|
+
$[103] = t41;
|
|
36172
|
+
} else {
|
|
36173
|
+
t41 = $[103];
|
|
36174
|
+
}
|
|
36175
|
+
let t42;
|
|
36176
|
+
if ($[104] !== position || $[105] !== t41) {
|
|
36177
|
+
t42 = /* @__PURE__ */ jsx(SelectPrimitive.Content, { position, className: t38, children: t41 });
|
|
36178
|
+
$[104] = position;
|
|
36179
|
+
$[105] = t41;
|
|
36180
|
+
$[106] = t42;
|
|
36181
|
+
} else {
|
|
36182
|
+
t42 = $[106];
|
|
36183
|
+
}
|
|
36184
|
+
let t43;
|
|
36185
|
+
if ($[107] !== finalContainer || $[108] !== t42) {
|
|
36186
|
+
t43 = /* @__PURE__ */ jsx(SelectPrimitive.Portal, { container: finalContainer, children: t42 });
|
|
36187
|
+
$[107] = finalContainer;
|
|
36188
|
+
$[108] = t42;
|
|
36189
|
+
$[109] = t43;
|
|
36190
|
+
} else {
|
|
36191
|
+
t43 = $[109];
|
|
36192
|
+
}
|
|
36193
|
+
let t44;
|
|
36194
|
+
if ($[110] !== disabled || $[111] !== name || $[112] !== onValueChangeInternal || $[113] !== openInternal || $[114] !== props || $[115] !== stringValue || $[116] !== t10 || $[117] !== t11 || $[118] !== t37 || $[119] !== t43) {
|
|
36195
|
+
t44 = /* @__PURE__ */ jsxs(SelectPrimitive.Root, { name, value: stringValue, open: openInternal, disabled, onValueChange: onValueChangeInternal, onOpenChange: t10, ...props, children: [
|
|
36196
|
+
t11,
|
|
36197
|
+
t37,
|
|
36198
|
+
t43
|
|
36199
|
+
] });
|
|
36200
|
+
$[110] = disabled;
|
|
36201
|
+
$[111] = name;
|
|
36202
|
+
$[112] = onValueChangeInternal;
|
|
36203
|
+
$[113] = openInternal;
|
|
36204
|
+
$[114] = props;
|
|
36205
|
+
$[115] = stringValue;
|
|
36206
|
+
$[116] = t10;
|
|
36207
|
+
$[117] = t11;
|
|
36208
|
+
$[118] = t37;
|
|
36209
|
+
$[119] = t43;
|
|
36210
|
+
$[120] = t44;
|
|
36211
|
+
} else {
|
|
36212
|
+
t44 = $[120];
|
|
36213
|
+
}
|
|
36214
|
+
return t44;
|
|
35446
36215
|
});
|
|
35447
36216
|
Select.displayName = "Select";
|
|
35448
36217
|
const SelectItem = React__default.memo(function SelectItem2(t0) {
|
|
@@ -35533,6 +36302,14 @@ const SelectGroup = React__default.memo(function SelectGroup2(t0) {
|
|
|
35533
36302
|
}
|
|
35534
36303
|
return t3;
|
|
35535
36304
|
});
|
|
36305
|
+
function _temp$1(e) {
|
|
36306
|
+
e.preventDefault();
|
|
36307
|
+
e.stopPropagation();
|
|
36308
|
+
}
|
|
36309
|
+
function _temp2(e_0) {
|
|
36310
|
+
e_0.preventDefault();
|
|
36311
|
+
e_0.stopPropagation();
|
|
36312
|
+
}
|
|
35536
36313
|
function SliderThumb(props) {
|
|
35537
36314
|
const $ = c(13);
|
|
35538
36315
|
const t0 = props.hovered;
|
|
@@ -35542,7 +36319,7 @@ function SliderThumb(props) {
|
|
|
35542
36319
|
t2 = cls({
|
|
35543
36320
|
"border-primary bg-primary outline-none": t1,
|
|
35544
36321
|
"border-surface-accent-300 bg-surface-accent-300 dark:border-surface-700 dark:bg-surface-700": props.props.disabled
|
|
35545
|
-
}, 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");
|
|
36322
|
+
}, 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");
|
|
35546
36323
|
$[0] = props.classes;
|
|
35547
36324
|
$[1] = props.props.disabled;
|
|
35548
36325
|
$[2] = t1;
|
|
@@ -35560,7 +36337,7 @@ function SliderThumb(props) {
|
|
|
35560
36337
|
}
|
|
35561
36338
|
let t4;
|
|
35562
36339
|
if ($[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
35563
|
-
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");
|
|
36340
|
+
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");
|
|
35564
36341
|
$[6] = t4;
|
|
35565
36342
|
} else {
|
|
35566
36343
|
t4 = $[6];
|
|
@@ -35665,7 +36442,7 @@ const Slider = React.forwardRef((t0, ref) => {
|
|
|
35665
36442
|
}
|
|
35666
36443
|
let t10;
|
|
35667
36444
|
if ($[15] !== t6 || $[16] !== t9) {
|
|
35668
|
-
t10 = /* @__PURE__ */ jsx(SliderPrimitive.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 });
|
|
36445
|
+
t10 = /* @__PURE__ */ jsx(SliderPrimitive.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 });
|
|
35669
36446
|
$[15] = t6;
|
|
35670
36447
|
$[16] = t9;
|
|
35671
36448
|
$[17] = t10;
|
|
@@ -35720,13 +36497,14 @@ const Slider = React.forwardRef((t0, ref) => {
|
|
|
35720
36497
|
});
|
|
35721
36498
|
Slider.displayName = "Slider";
|
|
35722
36499
|
const Sheet = (t0) => {
|
|
35723
|
-
const $ = c(
|
|
36500
|
+
const $ = c(70);
|
|
35724
36501
|
let children;
|
|
35725
36502
|
let className;
|
|
35726
36503
|
let onOpenChange;
|
|
35727
36504
|
let open;
|
|
35728
36505
|
let overlayClassName;
|
|
35729
36506
|
let overlayStyle;
|
|
36507
|
+
let portalContainer;
|
|
35730
36508
|
let props;
|
|
35731
36509
|
let style;
|
|
35732
36510
|
let t1;
|
|
@@ -35748,6 +36526,7 @@ const Sheet = (t0) => {
|
|
|
35748
36526
|
style,
|
|
35749
36527
|
overlayClassName,
|
|
35750
36528
|
overlayStyle,
|
|
36529
|
+
portalContainer,
|
|
35751
36530
|
...props
|
|
35752
36531
|
} = t0);
|
|
35753
36532
|
$[0] = t0;
|
|
@@ -35757,13 +36536,14 @@ const Sheet = (t0) => {
|
|
|
35757
36536
|
$[4] = open;
|
|
35758
36537
|
$[5] = overlayClassName;
|
|
35759
36538
|
$[6] = overlayStyle;
|
|
35760
|
-
$[7] =
|
|
35761
|
-
$[8] =
|
|
35762
|
-
$[9] =
|
|
35763
|
-
$[10] =
|
|
35764
|
-
$[11] =
|
|
35765
|
-
$[12] =
|
|
35766
|
-
$[13] =
|
|
36539
|
+
$[7] = portalContainer;
|
|
36540
|
+
$[8] = props;
|
|
36541
|
+
$[9] = style;
|
|
36542
|
+
$[10] = t1;
|
|
36543
|
+
$[11] = t2;
|
|
36544
|
+
$[12] = t3;
|
|
36545
|
+
$[13] = title;
|
|
36546
|
+
$[14] = transparent;
|
|
35767
36547
|
} else {
|
|
35768
36548
|
children = $[1];
|
|
35769
36549
|
className = $[2];
|
|
@@ -35771,21 +36551,24 @@ const Sheet = (t0) => {
|
|
|
35771
36551
|
open = $[4];
|
|
35772
36552
|
overlayClassName = $[5];
|
|
35773
36553
|
overlayStyle = $[6];
|
|
35774
|
-
|
|
35775
|
-
|
|
35776
|
-
|
|
35777
|
-
|
|
35778
|
-
|
|
35779
|
-
|
|
35780
|
-
|
|
36554
|
+
portalContainer = $[7];
|
|
36555
|
+
props = $[8];
|
|
36556
|
+
style = $[9];
|
|
36557
|
+
t1 = $[10];
|
|
36558
|
+
t2 = $[11];
|
|
36559
|
+
t3 = $[12];
|
|
36560
|
+
title = $[13];
|
|
36561
|
+
transparent = $[14];
|
|
35781
36562
|
}
|
|
35782
36563
|
const side = t1 === void 0 ? "right" : t1;
|
|
35783
36564
|
const modal = t2 === void 0 ? true : t2;
|
|
35784
36565
|
const includeBackgroundOverlay = t3 === void 0 ? true : t3;
|
|
35785
36566
|
const [displayed, setDisplayed] = useState(false);
|
|
36567
|
+
const contextContainer = usePortalContainer();
|
|
36568
|
+
const finalContainer = portalContainer ?? contextContainer ?? void 0;
|
|
35786
36569
|
let t4;
|
|
35787
36570
|
let t5;
|
|
35788
|
-
if ($[
|
|
36571
|
+
if ($[15] !== open) {
|
|
35789
36572
|
t4 = () => {
|
|
35790
36573
|
const timeout = setTimeout(() => {
|
|
35791
36574
|
setDisplayed(open);
|
|
@@ -35793,12 +36576,12 @@ const Sheet = (t0) => {
|
|
|
35793
36576
|
return () => clearTimeout(timeout);
|
|
35794
36577
|
};
|
|
35795
36578
|
t5 = [open];
|
|
35796
|
-
$[
|
|
35797
|
-
$[
|
|
35798
|
-
$[
|
|
36579
|
+
$[15] = open;
|
|
36580
|
+
$[16] = t4;
|
|
36581
|
+
$[17] = t5;
|
|
35799
36582
|
} else {
|
|
35800
|
-
t4 = $[
|
|
35801
|
-
t5 = $[
|
|
36583
|
+
t4 = $[16];
|
|
36584
|
+
t5 = $[17];
|
|
35802
36585
|
}
|
|
35803
36586
|
useEffect(t4, t5);
|
|
35804
36587
|
let T0;
|
|
@@ -35808,11 +36591,12 @@ const Sheet = (t0) => {
|
|
|
35808
36591
|
let t11;
|
|
35809
36592
|
let t12;
|
|
35810
36593
|
let t13;
|
|
36594
|
+
let t14;
|
|
35811
36595
|
let t6;
|
|
35812
36596
|
let t7;
|
|
35813
36597
|
let t8;
|
|
35814
36598
|
let t9;
|
|
35815
|
-
if ($[
|
|
36599
|
+
if ($[18] !== className || $[19] !== displayed || $[20] !== finalContainer || $[21] !== includeBackgroundOverlay || $[22] !== modal || $[23] !== onOpenChange || $[24] !== open || $[25] !== overlayClassName || $[26] !== overlayStyle || $[27] !== props || $[28] !== side || $[29] !== title || $[30] !== transparent) {
|
|
35816
36600
|
const transformValue = {
|
|
35817
36601
|
top: "-translate-y-full",
|
|
35818
36602
|
bottom: "translate-y-full",
|
|
@@ -35826,113 +36610,118 @@ const Sheet = (t0) => {
|
|
|
35826
36610
|
right: "border-l"
|
|
35827
36611
|
};
|
|
35828
36612
|
T2 = DialogPrimitive.Root;
|
|
35829
|
-
|
|
35830
|
-
|
|
35831
|
-
|
|
36613
|
+
t12 = displayed || open;
|
|
36614
|
+
t13 = modal;
|
|
36615
|
+
t14 = onOpenChange;
|
|
35832
36616
|
T1 = DialogPrimitive.Portal;
|
|
35833
|
-
|
|
35834
|
-
|
|
35835
|
-
|
|
35836
|
-
|
|
35837
|
-
$[
|
|
36617
|
+
t9 = finalContainer;
|
|
36618
|
+
const t152 = title ?? "Sheet";
|
|
36619
|
+
if ($[43] !== t152) {
|
|
36620
|
+
t10 = /* @__PURE__ */ jsx(DialogPrimitive.Title, { autoFocus: true, tabIndex: 0, children: t152 });
|
|
36621
|
+
$[43] = t152;
|
|
36622
|
+
$[44] = t10;
|
|
35838
36623
|
} else {
|
|
35839
|
-
|
|
36624
|
+
t10 = $[44];
|
|
35840
36625
|
}
|
|
35841
|
-
if ($[
|
|
35842
|
-
|
|
36626
|
+
if ($[45] !== displayed || $[46] !== includeBackgroundOverlay || $[47] !== open || $[48] !== overlayClassName || $[49] !== overlayStyle) {
|
|
36627
|
+
t11 = includeBackgroundOverlay && /* @__PURE__ */ jsx(DialogPrimitive.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: {
|
|
35843
36628
|
pointerEvents: displayed ? "auto" : "none",
|
|
35844
36629
|
...overlayStyle
|
|
35845
36630
|
} });
|
|
35846
|
-
$[
|
|
35847
|
-
$[
|
|
35848
|
-
$[
|
|
35849
|
-
$[
|
|
35850
|
-
$[
|
|
35851
|
-
$[
|
|
36631
|
+
$[45] = displayed;
|
|
36632
|
+
$[46] = includeBackgroundOverlay;
|
|
36633
|
+
$[47] = open;
|
|
36634
|
+
$[48] = overlayClassName;
|
|
36635
|
+
$[49] = overlayStyle;
|
|
36636
|
+
$[50] = t11;
|
|
35852
36637
|
} else {
|
|
35853
|
-
|
|
36638
|
+
t11 = $[50];
|
|
35854
36639
|
}
|
|
35855
36640
|
T0 = DialogPrimitive.Content;
|
|
35856
36641
|
t6 = props;
|
|
35857
36642
|
t7 = _temp;
|
|
35858
36643
|
t8 = cls("outline-none", borderClass[side], defaultBorderMixin, "transform-gpu", "will-change-transform", "text-surface-accent-900 dark:text-white", "fixed transform z-20 transition-all ease-in-out", !displayed ? "duration-150" : "duration-100", "outline-none focus:outline-none", transparent ? "" : "shadow-md bg-white dark:bg-surface-950", side === "top" || side === "bottom" ? "w-full" : "h-full", side === "left" || side === "top" ? "left-0 top-0" : "right-0 bottom-0", displayed && open ? "opacity-100" : "opacity-50", !displayed || !open ? transformValue[side] : "", className);
|
|
35859
|
-
$[
|
|
35860
|
-
$[
|
|
35861
|
-
$[
|
|
35862
|
-
$[
|
|
35863
|
-
$[
|
|
35864
|
-
$[
|
|
35865
|
-
$[
|
|
35866
|
-
$[
|
|
35867
|
-
$[
|
|
35868
|
-
$[
|
|
35869
|
-
$[
|
|
35870
|
-
$[
|
|
35871
|
-
$[
|
|
35872
|
-
$[
|
|
35873
|
-
$[
|
|
35874
|
-
$[
|
|
35875
|
-
$[
|
|
35876
|
-
$[
|
|
35877
|
-
$[
|
|
35878
|
-
$[
|
|
35879
|
-
$[
|
|
35880
|
-
$[
|
|
35881
|
-
$[
|
|
35882
|
-
|
|
35883
|
-
|
|
35884
|
-
|
|
35885
|
-
|
|
35886
|
-
|
|
35887
|
-
|
|
35888
|
-
|
|
35889
|
-
|
|
35890
|
-
|
|
35891
|
-
|
|
35892
|
-
|
|
35893
|
-
|
|
35894
|
-
|
|
35895
|
-
|
|
35896
|
-
|
|
35897
|
-
t14 = /* @__PURE__ */ jsx(T0, { ...t6, onFocusCapture: t7, className: t8, style, children });
|
|
35898
|
-
$[48] = T0;
|
|
35899
|
-
$[49] = children;
|
|
35900
|
-
$[50] = style;
|
|
35901
|
-
$[51] = t6;
|
|
35902
|
-
$[52] = t7;
|
|
35903
|
-
$[53] = t8;
|
|
35904
|
-
$[54] = t14;
|
|
35905
|
-
} else {
|
|
35906
|
-
t14 = $[54];
|
|
36644
|
+
$[18] = className;
|
|
36645
|
+
$[19] = displayed;
|
|
36646
|
+
$[20] = finalContainer;
|
|
36647
|
+
$[21] = includeBackgroundOverlay;
|
|
36648
|
+
$[22] = modal;
|
|
36649
|
+
$[23] = onOpenChange;
|
|
36650
|
+
$[24] = open;
|
|
36651
|
+
$[25] = overlayClassName;
|
|
36652
|
+
$[26] = overlayStyle;
|
|
36653
|
+
$[27] = props;
|
|
36654
|
+
$[28] = side;
|
|
36655
|
+
$[29] = title;
|
|
36656
|
+
$[30] = transparent;
|
|
36657
|
+
$[31] = T0;
|
|
36658
|
+
$[32] = T1;
|
|
36659
|
+
$[33] = T2;
|
|
36660
|
+
$[34] = t10;
|
|
36661
|
+
$[35] = t11;
|
|
36662
|
+
$[36] = t12;
|
|
36663
|
+
$[37] = t13;
|
|
36664
|
+
$[38] = t14;
|
|
36665
|
+
$[39] = t6;
|
|
36666
|
+
$[40] = t7;
|
|
36667
|
+
$[41] = t8;
|
|
36668
|
+
$[42] = t9;
|
|
36669
|
+
} else {
|
|
36670
|
+
T0 = $[31];
|
|
36671
|
+
T1 = $[32];
|
|
36672
|
+
T2 = $[33];
|
|
36673
|
+
t10 = $[34];
|
|
36674
|
+
t11 = $[35];
|
|
36675
|
+
t12 = $[36];
|
|
36676
|
+
t13 = $[37];
|
|
36677
|
+
t14 = $[38];
|
|
36678
|
+
t6 = $[39];
|
|
36679
|
+
t7 = $[40];
|
|
36680
|
+
t8 = $[41];
|
|
36681
|
+
t9 = $[42];
|
|
35907
36682
|
}
|
|
35908
36683
|
let t15;
|
|
35909
|
-
if ($[
|
|
35910
|
-
t15 = /* @__PURE__ */
|
|
35911
|
-
|
|
36684
|
+
if ($[51] !== T0 || $[52] !== children || $[53] !== style || $[54] !== t6 || $[55] !== t7 || $[56] !== t8) {
|
|
36685
|
+
t15 = /* @__PURE__ */ jsx(T0, { ...t6, onFocusCapture: t7, className: t8, style, children });
|
|
36686
|
+
$[51] = T0;
|
|
36687
|
+
$[52] = children;
|
|
36688
|
+
$[53] = style;
|
|
36689
|
+
$[54] = t6;
|
|
36690
|
+
$[55] = t7;
|
|
36691
|
+
$[56] = t8;
|
|
36692
|
+
$[57] = t15;
|
|
36693
|
+
} else {
|
|
36694
|
+
t15 = $[57];
|
|
36695
|
+
}
|
|
36696
|
+
let t16;
|
|
36697
|
+
if ($[58] !== T1 || $[59] !== t10 || $[60] !== t11 || $[61] !== t15 || $[62] !== t9) {
|
|
36698
|
+
t16 = /* @__PURE__ */ jsxs(T1, { container: t9, children: [
|
|
35912
36699
|
t10,
|
|
35913
|
-
|
|
36700
|
+
t11,
|
|
36701
|
+
t15
|
|
35914
36702
|
] });
|
|
35915
|
-
$[
|
|
35916
|
-
$[
|
|
35917
|
-
$[
|
|
35918
|
-
$[
|
|
35919
|
-
$[
|
|
36703
|
+
$[58] = T1;
|
|
36704
|
+
$[59] = t10;
|
|
36705
|
+
$[60] = t11;
|
|
36706
|
+
$[61] = t15;
|
|
36707
|
+
$[62] = t9;
|
|
36708
|
+
$[63] = t16;
|
|
35920
36709
|
} else {
|
|
35921
|
-
|
|
36710
|
+
t16 = $[63];
|
|
35922
36711
|
}
|
|
35923
|
-
let
|
|
35924
|
-
if ($[
|
|
35925
|
-
|
|
35926
|
-
$[
|
|
35927
|
-
$[
|
|
35928
|
-
$[
|
|
35929
|
-
$[
|
|
35930
|
-
$[
|
|
35931
|
-
$[
|
|
35932
|
-
} else {
|
|
35933
|
-
|
|
35934
|
-
}
|
|
35935
|
-
return
|
|
36712
|
+
let t17;
|
|
36713
|
+
if ($[64] !== T2 || $[65] !== t12 || $[66] !== t13 || $[67] !== t14 || $[68] !== t16) {
|
|
36714
|
+
t17 = /* @__PURE__ */ jsx(T2, { open: t12, modal: t13, onOpenChange: t14, children: t16 });
|
|
36715
|
+
$[64] = T2;
|
|
36716
|
+
$[65] = t12;
|
|
36717
|
+
$[66] = t13;
|
|
36718
|
+
$[67] = t14;
|
|
36719
|
+
$[68] = t16;
|
|
36720
|
+
$[69] = t17;
|
|
36721
|
+
} else {
|
|
36722
|
+
t17 = $[69];
|
|
36723
|
+
}
|
|
36724
|
+
return t17;
|
|
35936
36725
|
};
|
|
35937
36726
|
function _temp(event) {
|
|
35938
36727
|
return event.preventDefault();
|
|
@@ -35940,7 +36729,7 @@ function _temp(event) {
|
|
|
35940
36729
|
function getStyleValue(value) {
|
|
35941
36730
|
return parseInt(value, 10) || 0;
|
|
35942
36731
|
}
|
|
35943
|
-
const styles
|
|
36732
|
+
const styles = {
|
|
35944
36733
|
shadow: {
|
|
35945
36734
|
// Visibility needed to hide the extra text area on iPads
|
|
35946
36735
|
visibility: "hidden",
|
|
@@ -36133,7 +36922,7 @@ const TextareaAutosize = React.forwardRef(function TextareaAutosize2(props, ref)
|
|
|
36133
36922
|
),
|
|
36134
36923
|
/* @__PURE__ */ jsx("textarea", { "aria-hidden": true, className: cls(props.className, props.shadowClassName), readOnly: true, ref: shadowRef, tabIndex: -1, style: {
|
|
36135
36924
|
padding: 0,
|
|
36136
|
-
...styles
|
|
36925
|
+
...styles.shadow,
|
|
36137
36926
|
...style
|
|
36138
36927
|
} })
|
|
36139
36928
|
] });
|
|
@@ -36180,8 +36969,13 @@ const TextField = forwardRef(({
|
|
|
36180
36969
|
...inputProps
|
|
36181
36970
|
}, ref) => {
|
|
36182
36971
|
const inputRef = inputRefProp ?? useRef(null);
|
|
36183
|
-
const [focused, setFocused] = React__default.useState(
|
|
36972
|
+
const [focused, setFocused] = React__default.useState(false);
|
|
36184
36973
|
const hasValue = value !== void 0 && value !== null && value !== "";
|
|
36974
|
+
useEffect(() => {
|
|
36975
|
+
if (inputRef.current && document.activeElement === inputRef.current) {
|
|
36976
|
+
setFocused(true);
|
|
36977
|
+
}
|
|
36978
|
+
}, []);
|
|
36185
36979
|
useEffect(() => {
|
|
36186
36980
|
if (type !== "number") return;
|
|
36187
36981
|
const handleWheel = (event) => {
|
|
@@ -36193,12 +36987,12 @@ const TextField = forwardRef(({
|
|
|
36193
36987
|
element?.removeEventListener("wheel", handleWheel);
|
|
36194
36988
|
};
|
|
36195
36989
|
}, [inputRef, type]);
|
|
36196
|
-
const input = multiline ? /* @__PURE__ */ jsx(
|
|
36990
|
+
const input = multiline ? /* @__PURE__ */ jsx("textarea", { ...inputProps, ref: inputRef, placeholder: focused || hasValue || !label ? placeholder : void 0, autoFocus, rows: typeof minRows === "string" ? parseInt(minRows) : minRows ?? 3, value: value ?? "", onChange, onFocus: () => setFocused(true), onBlur: () => setFocused(false), style: inputStyle, className: cls(invisible ? focusedInvisibleMixin : "", "rounded-md resize-none w-full outline-none text-base bg-transparent min-h-[64px] px-3", label ? "pt-8 pb-2" : "py-2", disabled && "outline-none opacity-50 text-surface-accent-600 dark:text-surface-accent-500", inputClassName) }) : /* @__PURE__ */ 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, {
|
|
36197
36991
|
"min-h-[28px]": size === "smallest",
|
|
36198
36992
|
"min-h-[32px]": size === "small",
|
|
36199
36993
|
"min-h-[44px]": size === "medium",
|
|
36200
36994
|
"min-h-[64px]": size === "large"
|
|
36201
|
-
}, label ? size === "large" ? "pt-8 pb-2" : "pt-4 pb-2" : "py-2", endAdornment ? "pr-12" : "pr-3", disabled && "outline-none opacity-65 dark:opacity-60 text-surface-accent-800 dark:text-white", inputClassName), placeholder: focused || hasValue || !label ? placeholder : void 0, autoFocus, onFocus: () => setFocused(true), onBlur: () => setFocused(false), type, value: type === "number" && Number.isNaN(value) ? "" : value ?? "", onChange });
|
|
36995
|
+
}, label ? size === "large" ? "pt-8 pb-2" : "pt-4 pb-2" : size === "smallest" ? "py-0.5" : size === "small" ? "py-1" : "py-2", endAdornment ? "pr-12" : "pr-3", disabled && "outline-none opacity-65 dark:opacity-60 text-surface-accent-800 dark:text-white", inputClassName), placeholder: focused || hasValue || !label ? placeholder : void 0, autoFocus, onFocus: () => setFocused(true), onBlur: () => setFocused(false), type, value: type === "number" && Number.isNaN(value) ? "" : value ?? "", onChange });
|
|
36202
36996
|
return /* @__PURE__ */ jsxs("div", { ref, className: cls("rounded-md relative max-w-full", invisible ? fieldBackgroundInvisibleMixin : fieldBackgroundMixin, disabled ? fieldBackgroundDisabledMixin : fieldBackgroundHoverMixin, error ? "border border-red-500 dark:border-red-600" : "", {
|
|
36203
36997
|
"min-h-[28px]": size === "smallest",
|
|
36204
36998
|
"min-h-[32px]": size === "small",
|
|
@@ -36215,215 +37009,161 @@ const TextField = forwardRef(({
|
|
|
36215
37009
|
] });
|
|
36216
37010
|
});
|
|
36217
37011
|
TextField.displayName = "TextField";
|
|
36218
|
-
|
|
36219
|
-
const $ = c(
|
|
37012
|
+
function Tabs(t0) {
|
|
37013
|
+
const $ = c(26);
|
|
36220
37014
|
const {
|
|
36221
|
-
|
|
36222
|
-
|
|
36223
|
-
side: t1,
|
|
36224
|
-
delayDuration: t2,
|
|
36225
|
-
sideOffset,
|
|
36226
|
-
align,
|
|
36227
|
-
onOpenChange,
|
|
36228
|
-
title,
|
|
36229
|
-
tooltipClassName,
|
|
36230
|
-
tooltipStyle,
|
|
36231
|
-
children,
|
|
36232
|
-
asChild: t3,
|
|
36233
|
-
container,
|
|
37015
|
+
value,
|
|
37016
|
+
onValueChange,
|
|
36234
37017
|
className,
|
|
36235
|
-
|
|
37018
|
+
innerClassName,
|
|
37019
|
+
children
|
|
36236
37020
|
} = t0;
|
|
36237
|
-
const
|
|
36238
|
-
const
|
|
36239
|
-
const
|
|
36240
|
-
|
|
36241
|
-
|
|
36242
|
-
|
|
36243
|
-
|
|
36244
|
-
|
|
36245
|
-
|
|
36246
|
-
|
|
36247
|
-
|
|
36248
|
-
|
|
36249
|
-
|
|
36250
|
-
|
|
37021
|
+
const scrollContainerRef = useRef(null);
|
|
37022
|
+
const [showLeftScroll, setShowLeftScroll] = useState(false);
|
|
37023
|
+
const [showRightScroll, setShowRightScroll] = useState(false);
|
|
37024
|
+
const [isScrollable, setIsScrollable] = useState(false);
|
|
37025
|
+
let t1;
|
|
37026
|
+
if ($[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
37027
|
+
t1 = () => {
|
|
37028
|
+
if (scrollContainerRef.current) {
|
|
37029
|
+
const {
|
|
37030
|
+
scrollLeft,
|
|
37031
|
+
scrollWidth,
|
|
37032
|
+
clientWidth
|
|
37033
|
+
} = scrollContainerRef.current;
|
|
37034
|
+
setShowLeftScroll(scrollLeft > 0);
|
|
37035
|
+
setShowRightScroll(Math.ceil(scrollLeft + clientWidth) < scrollWidth);
|
|
37036
|
+
setIsScrollable(scrollWidth > clientWidth);
|
|
37037
|
+
}
|
|
37038
|
+
};
|
|
37039
|
+
$[0] = t1;
|
|
37040
|
+
} else {
|
|
37041
|
+
t1 = $[0];
|
|
37042
|
+
}
|
|
37043
|
+
const checkScroll = t1;
|
|
37044
|
+
let t2;
|
|
37045
|
+
if ($[1] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
37046
|
+
t2 = () => {
|
|
37047
|
+
checkScroll();
|
|
37048
|
+
window.addEventListener("resize", checkScroll);
|
|
37049
|
+
let observer;
|
|
37050
|
+
if (scrollContainerRef.current) {
|
|
37051
|
+
observer = new ResizeObserver(checkScroll);
|
|
37052
|
+
observer.observe(scrollContainerRef.current);
|
|
37053
|
+
if (scrollContainerRef.current.firstElementChild) {
|
|
37054
|
+
observer.observe(scrollContainerRef.current.firstElementChild);
|
|
37055
|
+
}
|
|
37056
|
+
}
|
|
37057
|
+
return () => {
|
|
37058
|
+
window.removeEventListener("resize", checkScroll);
|
|
37059
|
+
observer?.disconnect();
|
|
37060
|
+
};
|
|
37061
|
+
};
|
|
37062
|
+
$[1] = t2;
|
|
37063
|
+
} else {
|
|
37064
|
+
t2 = $[1];
|
|
37065
|
+
}
|
|
37066
|
+
let t3;
|
|
37067
|
+
if ($[2] !== children) {
|
|
37068
|
+
t3 = [children];
|
|
37069
|
+
$[2] = children;
|
|
37070
|
+
$[3] = t3;
|
|
37071
|
+
} else {
|
|
37072
|
+
t3 = $[3];
|
|
36251
37073
|
}
|
|
37074
|
+
useEffect(t2, t3);
|
|
36252
37075
|
let t4;
|
|
36253
|
-
if ($[
|
|
36254
|
-
t4 =
|
|
36255
|
-
|
|
36256
|
-
|
|
36257
|
-
|
|
36258
|
-
|
|
36259
|
-
|
|
37076
|
+
if ($[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
37077
|
+
t4 = (direction) => {
|
|
37078
|
+
if (scrollContainerRef.current) {
|
|
37079
|
+
const container = scrollContainerRef.current;
|
|
37080
|
+
const scrollAmount = Math.max(container.clientWidth / 2, 200);
|
|
37081
|
+
const targetScroll = container.scrollLeft + (direction === "left" ? -scrollAmount : scrollAmount);
|
|
37082
|
+
container.scrollTo({
|
|
37083
|
+
left: targetScroll,
|
|
37084
|
+
behavior: "smooth"
|
|
37085
|
+
});
|
|
37086
|
+
}
|
|
37087
|
+
};
|
|
37088
|
+
$[4] = t4;
|
|
36260
37089
|
} else {
|
|
36261
|
-
t4 = $[
|
|
37090
|
+
t4 = $[4];
|
|
36262
37091
|
}
|
|
36263
|
-
const
|
|
37092
|
+
const scroll = t4;
|
|
36264
37093
|
let t5;
|
|
36265
|
-
if ($[
|
|
36266
|
-
t5 = cls("
|
|
36267
|
-
$[
|
|
36268
|
-
$[
|
|
37094
|
+
if ($[5] !== className) {
|
|
37095
|
+
t5 = cls("flex flex-row items-center min-w-0", className);
|
|
37096
|
+
$[5] = className;
|
|
37097
|
+
$[6] = t5;
|
|
36269
37098
|
} else {
|
|
36270
|
-
t5 = $[
|
|
37099
|
+
t5 = $[6];
|
|
37100
|
+
}
|
|
37101
|
+
let t6;
|
|
37102
|
+
if ($[7] !== isScrollable || $[8] !== showLeftScroll) {
|
|
37103
|
+
t6 = isScrollable && /* @__PURE__ */ jsx("button", { type: "button", disabled: !showLeftScroll, onClick: () => scroll("left"), className: cls("flex-shrink-0 z-10 flex items-center justify-center rounded-md px-0.5 py-1.5 transition-all h-10 w-6", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-surface-400", "disabled:pointer-events-none disabled:opacity-0", "text-surface-600 dark:text-surface-400 hover:bg-surface-200 dark:hover:bg-surface-800", "mr-1 bg-surface-50 dark:bg-surface-900 border", defaultBorderMixin), children: /* @__PURE__ */ jsx(ChevronLeftIcon, { size: "small" }) });
|
|
37104
|
+
$[7] = isScrollable;
|
|
37105
|
+
$[8] = showLeftScroll;
|
|
37106
|
+
$[9] = t6;
|
|
37107
|
+
} else {
|
|
37108
|
+
t6 = $[9];
|
|
36271
37109
|
}
|
|
36272
|
-
const t6 = sideOffset === void 0 ? 4 : sideOffset;
|
|
36273
37110
|
let t7;
|
|
36274
|
-
if ($[
|
|
36275
|
-
t7 =
|
|
36276
|
-
|
|
36277
|
-
|
|
36278
|
-
|
|
36279
|
-
$[
|
|
36280
|
-
$[13] = title;
|
|
36281
|
-
$[14] = tooltipStyle;
|
|
36282
|
-
$[15] = t7;
|
|
37111
|
+
if ($[10] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel")) {
|
|
37112
|
+
t7 = {
|
|
37113
|
+
scrollbarWidth: "none",
|
|
37114
|
+
msOverflowStyle: "none"
|
|
37115
|
+
};
|
|
37116
|
+
$[10] = t7;
|
|
36283
37117
|
} else {
|
|
36284
|
-
t7 = $[
|
|
37118
|
+
t7 = $[10];
|
|
36285
37119
|
}
|
|
36286
37120
|
let t8;
|
|
36287
|
-
if ($[
|
|
36288
|
-
t8 =
|
|
36289
|
-
$[
|
|
36290
|
-
$[
|
|
36291
|
-
$[18] = t8;
|
|
37121
|
+
if ($[11] !== innerClassName) {
|
|
37122
|
+
t8 = cls("border", defaultBorderMixin, "gap-2", "inline-flex h-10 items-center justify-center rounded-md bg-surface-50 p-1 text-surface-600 dark:bg-surface-900 dark:text-surface-400", innerClassName);
|
|
37123
|
+
$[11] = innerClassName;
|
|
37124
|
+
$[12] = t8;
|
|
36292
37125
|
} else {
|
|
36293
|
-
t8 = $[
|
|
37126
|
+
t8 = $[12];
|
|
36294
37127
|
}
|
|
36295
37128
|
let t9;
|
|
36296
|
-
if ($[
|
|
36297
|
-
t9 = /* @__PURE__ */
|
|
36298
|
-
|
|
36299
|
-
|
|
36300
|
-
]
|
|
36301
|
-
$[19] = defaultOpen;
|
|
36302
|
-
$[20] = onOpenChange;
|
|
36303
|
-
$[21] = open;
|
|
36304
|
-
$[22] = t8;
|
|
36305
|
-
$[23] = trigger;
|
|
36306
|
-
$[24] = t9;
|
|
37129
|
+
if ($[13] !== children || $[14] !== t8) {
|
|
37130
|
+
t9 = /* @__PURE__ */ jsx("div", { ref: scrollContainerRef, className: "flex-1 overflow-x-auto no-scrollbar min-w-0", onScroll: checkScroll, style: t7, children: /* @__PURE__ */ jsx(TabsPrimitive.List, { className: t8, children }) });
|
|
37131
|
+
$[13] = children;
|
|
37132
|
+
$[14] = t8;
|
|
37133
|
+
$[15] = t9;
|
|
36307
37134
|
} else {
|
|
36308
|
-
t9 = $[
|
|
37135
|
+
t9 = $[15];
|
|
36309
37136
|
}
|
|
36310
37137
|
let t10;
|
|
36311
|
-
if ($[
|
|
36312
|
-
t10 = /* @__PURE__ */ jsx(
|
|
36313
|
-
$[
|
|
36314
|
-
$[
|
|
36315
|
-
$[
|
|
36316
|
-
} else {
|
|
36317
|
-
t10 = $[27];
|
|
36318
|
-
}
|
|
36319
|
-
return t10;
|
|
36320
|
-
};
|
|
36321
|
-
const styles = `
|
|
36322
|
-
|
|
36323
|
-
.TooltipContent {
|
|
36324
|
-
animation-duration: 220ms;
|
|
36325
|
-
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
|
36326
|
-
will-change: transform, opacity;
|
|
36327
|
-
}
|
|
36328
|
-
|
|
36329
|
-
.TooltipContent[data-state='delayed-open'][data-side='top'] {
|
|
36330
|
-
animation-name: slideDownAndFade;
|
|
36331
|
-
}
|
|
36332
|
-
.TooltipContent[data-state='delayed-open'][data-side='right'] {
|
|
36333
|
-
animation-name: slideLeftAndFade;
|
|
36334
|
-
}
|
|
36335
|
-
.TooltipContent[data-state='delayed-open'][data-side='bottom'] {
|
|
36336
|
-
animation-name: slideUpAndFade;
|
|
36337
|
-
}
|
|
36338
|
-
.TooltipContent[data-state='delayed-open'][data-side='left'] {
|
|
36339
|
-
animation-name: slideRightAndFade;
|
|
36340
|
-
}
|
|
36341
|
-
|
|
36342
|
-
|
|
36343
|
-
@keyframes slideUpAndFade {
|
|
36344
|
-
from {
|
|
36345
|
-
opacity: 0;
|
|
36346
|
-
transform: translateY(4px);
|
|
36347
|
-
}
|
|
36348
|
-
to {
|
|
36349
|
-
opacity: 1;
|
|
36350
|
-
transform: translateY(0);
|
|
36351
|
-
}
|
|
36352
|
-
}
|
|
36353
|
-
|
|
36354
|
-
@keyframes slideRightAndFade {
|
|
36355
|
-
from {
|
|
36356
|
-
opacity: 0;
|
|
36357
|
-
transform: translateX(-4px);
|
|
36358
|
-
}
|
|
36359
|
-
to {
|
|
36360
|
-
opacity: 1;
|
|
36361
|
-
transform: translateX(0);
|
|
36362
|
-
}
|
|
36363
|
-
}
|
|
36364
|
-
|
|
36365
|
-
@keyframes slideDownAndFade {
|
|
36366
|
-
from {
|
|
36367
|
-
opacity: 0;
|
|
36368
|
-
transform: translateY(-4px);
|
|
36369
|
-
}
|
|
36370
|
-
to {
|
|
36371
|
-
opacity: 1;
|
|
36372
|
-
transform: translateY(0);
|
|
36373
|
-
}
|
|
36374
|
-
}
|
|
36375
|
-
|
|
36376
|
-
@keyframes slideLeftAndFade {
|
|
36377
|
-
from {
|
|
36378
|
-
opacity: 0;
|
|
36379
|
-
transform: translateX(4px);
|
|
36380
|
-
}
|
|
36381
|
-
to {
|
|
36382
|
-
opacity: 1;
|
|
36383
|
-
transform: translateX(0);
|
|
36384
|
-
}
|
|
36385
|
-
}`;
|
|
36386
|
-
function Tabs(t0) {
|
|
36387
|
-
const $ = c(10);
|
|
36388
|
-
const {
|
|
36389
|
-
value,
|
|
36390
|
-
onValueChange,
|
|
36391
|
-
className,
|
|
36392
|
-
innerClassName,
|
|
36393
|
-
children
|
|
36394
|
-
} = t0;
|
|
36395
|
-
let t1;
|
|
36396
|
-
if ($[0] !== innerClassName) {
|
|
36397
|
-
t1 = cls("w-max", "flex text-sm font-medium text-center text-surface-accent-800 dark:text-white max-w-full overflow-auto no-scrollbar items-end", innerClassName);
|
|
36398
|
-
$[0] = innerClassName;
|
|
36399
|
-
$[1] = t1;
|
|
36400
|
-
} else {
|
|
36401
|
-
t1 = $[1];
|
|
36402
|
-
}
|
|
36403
|
-
let t2;
|
|
36404
|
-
if ($[2] !== children || $[3] !== t1) {
|
|
36405
|
-
t2 = /* @__PURE__ */ jsx(TabsPrimitive.List, { className: t1, children });
|
|
36406
|
-
$[2] = children;
|
|
36407
|
-
$[3] = t1;
|
|
36408
|
-
$[4] = t2;
|
|
37138
|
+
if ($[16] !== isScrollable || $[17] !== showRightScroll) {
|
|
37139
|
+
t10 = isScrollable && /* @__PURE__ */ jsx("button", { type: "button", disabled: !showRightScroll, onClick: () => scroll("right"), className: cls("flex-shrink-0 z-10 flex items-center justify-center rounded-md px-0.5 py-1.5 transition-all h-10 w-6", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-surface-400", "disabled:pointer-events-none disabled:opacity-0", "text-surface-600 dark:text-surface-400 hover:bg-surface-200 dark:hover:bg-surface-800", "ml-1 bg-surface-50 dark:bg-surface-900 border", defaultBorderMixin), children: /* @__PURE__ */ jsx(ChevronRightIcon, { size: "small" }) });
|
|
37140
|
+
$[16] = isScrollable;
|
|
37141
|
+
$[17] = showRightScroll;
|
|
37142
|
+
$[18] = t10;
|
|
36409
37143
|
} else {
|
|
36410
|
-
|
|
37144
|
+
t10 = $[18];
|
|
36411
37145
|
}
|
|
36412
|
-
let
|
|
36413
|
-
if ($[
|
|
36414
|
-
|
|
36415
|
-
|
|
36416
|
-
|
|
36417
|
-
|
|
36418
|
-
|
|
36419
|
-
$[
|
|
37146
|
+
let t11;
|
|
37147
|
+
if ($[19] !== onValueChange || $[20] !== t10 || $[21] !== t5 || $[22] !== t6 || $[23] !== t9 || $[24] !== value) {
|
|
37148
|
+
t11 = /* @__PURE__ */ jsxs(TabsPrimitive.Root, { value, onValueChange, className: t5, children: [
|
|
37149
|
+
t6,
|
|
37150
|
+
t9,
|
|
37151
|
+
t10
|
|
37152
|
+
] });
|
|
37153
|
+
$[19] = onValueChange;
|
|
37154
|
+
$[20] = t10;
|
|
37155
|
+
$[21] = t5;
|
|
37156
|
+
$[22] = t6;
|
|
37157
|
+
$[23] = t9;
|
|
37158
|
+
$[24] = value;
|
|
37159
|
+
$[25] = t11;
|
|
36420
37160
|
} else {
|
|
36421
|
-
|
|
37161
|
+
t11 = $[25];
|
|
36422
37162
|
}
|
|
36423
|
-
return
|
|
37163
|
+
return t11;
|
|
36424
37164
|
}
|
|
36425
37165
|
function Tab(t0) {
|
|
36426
|
-
const $ = c(
|
|
37166
|
+
const $ = c(8);
|
|
36427
37167
|
const {
|
|
36428
37168
|
value,
|
|
36429
37169
|
className,
|
|
@@ -36432,43 +37172,26 @@ function Tab(t0) {
|
|
|
36432
37172
|
disabled
|
|
36433
37173
|
} = t0;
|
|
36434
37174
|
let t1;
|
|
36435
|
-
if ($[0] !== className || $[1] !==
|
|
36436
|
-
t1 = cls("
|
|
37175
|
+
if ($[0] !== className || $[1] !== innerClassName) {
|
|
37176
|
+
t1 = cls("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-white transition-all", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-surface-400 focus-visible:ring-offset-2", "disabled:pointer-events-none disabled:opacity-50", "data-[state=active]:bg-white data-[state=active]:text-surface-900 dark:data-[state=active]:bg-surface-950 dark:data-[state=active]:text-surface-50", className, innerClassName);
|
|
36437
37177
|
$[0] = className;
|
|
36438
|
-
$[1] =
|
|
37178
|
+
$[1] = innerClassName;
|
|
36439
37179
|
$[2] = t1;
|
|
36440
37180
|
} else {
|
|
36441
37181
|
t1 = $[2];
|
|
36442
37182
|
}
|
|
36443
37183
|
let t2;
|
|
36444
|
-
if ($[3] !==
|
|
36445
|
-
t2 =
|
|
36446
|
-
$[3] =
|
|
36447
|
-
$[4] =
|
|
36448
|
-
|
|
36449
|
-
|
|
36450
|
-
|
|
36451
|
-
let t3;
|
|
36452
|
-
if ($[5] !== children || $[6] !== t2) {
|
|
36453
|
-
t3 = /* @__PURE__ */ jsx("div", { className: t2, children });
|
|
36454
|
-
$[5] = children;
|
|
36455
|
-
$[6] = t2;
|
|
36456
|
-
$[7] = t3;
|
|
36457
|
-
} else {
|
|
36458
|
-
t3 = $[7];
|
|
36459
|
-
}
|
|
36460
|
-
let t4;
|
|
36461
|
-
if ($[8] !== disabled || $[9] !== t1 || $[10] !== t3 || $[11] !== value) {
|
|
36462
|
-
t4 = /* @__PURE__ */ jsx(TabsPrimitive.Trigger, { value, disabled, className: t1, children: t3 });
|
|
36463
|
-
$[8] = disabled;
|
|
36464
|
-
$[9] = t1;
|
|
36465
|
-
$[10] = t3;
|
|
36466
|
-
$[11] = value;
|
|
36467
|
-
$[12] = t4;
|
|
37184
|
+
if ($[3] !== children || $[4] !== disabled || $[5] !== t1 || $[6] !== value) {
|
|
37185
|
+
t2 = /* @__PURE__ */ jsx(TabsPrimitive.Trigger, { value, disabled, className: t1, children });
|
|
37186
|
+
$[3] = children;
|
|
37187
|
+
$[4] = disabled;
|
|
37188
|
+
$[5] = t1;
|
|
37189
|
+
$[6] = value;
|
|
37190
|
+
$[7] = t2;
|
|
36468
37191
|
} else {
|
|
36469
|
-
|
|
37192
|
+
t2 = $[7];
|
|
36470
37193
|
}
|
|
36471
|
-
return
|
|
37194
|
+
return t2;
|
|
36472
37195
|
}
|
|
36473
37196
|
const Table = React__default.memo((t0) => {
|
|
36474
37197
|
const $ = c(12);
|
|
@@ -36537,7 +37260,7 @@ const TableBody = React__default.memo((t0) => {
|
|
|
36537
37260
|
}
|
|
36538
37261
|
let t1;
|
|
36539
37262
|
if ($[4] !== className) {
|
|
36540
|
-
t1 = cls("bg-white dark:bg-surface-950 text-sm divide-y divide-surface-100 dark:divide-surface-700 dark:divide-opacity-70", className);
|
|
37263
|
+
t1 = cls("bg-white dark:bg-surface-950 text-sm divide-y divide-surface-100 dark:divide-surface-700 dark:divide-opacity-70 dark:divide-surface-700/70", className);
|
|
36541
37264
|
$[4] = className;
|
|
36542
37265
|
$[5] = t1;
|
|
36543
37266
|
} else {
|
|
@@ -36712,6 +37435,8 @@ function Popover(t0) {
|
|
|
36712
37435
|
const enabled = t2 === void 0 ? true : t2;
|
|
36713
37436
|
const modal = t3 === void 0 ? false : t3;
|
|
36714
37437
|
useInjectStyles("Popover", popoverStyles);
|
|
37438
|
+
const contextContainer = usePortalContainer();
|
|
37439
|
+
const finalContainer = portalContainer ?? contextContainer ?? void 0;
|
|
36715
37440
|
if (!enabled) {
|
|
36716
37441
|
let t42;
|
|
36717
37442
|
if ($[0] !== trigger) {
|
|
@@ -36767,9 +37492,9 @@ function Popover(t0) {
|
|
|
36767
37492
|
t7 = $[17];
|
|
36768
37493
|
}
|
|
36769
37494
|
let t8;
|
|
36770
|
-
if ($[18] !==
|
|
36771
|
-
t8 = /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { container:
|
|
36772
|
-
$[18] =
|
|
37495
|
+
if ($[18] !== finalContainer || $[19] !== t7) {
|
|
37496
|
+
t8 = /* @__PURE__ */ jsx(PopoverPrimitive.Portal, { container: finalContainer, children: t7 });
|
|
37497
|
+
$[18] = finalContainer;
|
|
36773
37498
|
$[19] = t7;
|
|
36774
37499
|
$[20] = t8;
|
|
36775
37500
|
} else {
|
|
@@ -36793,7 +37518,7 @@ function Popover(t0) {
|
|
|
36793
37518
|
return t9;
|
|
36794
37519
|
}
|
|
36795
37520
|
const popoverStyles = `
|
|
36796
|
-
|
|
37521
|
+
/* ... (styles remain unchanged) ... */
|
|
36797
37522
|
.PopoverContent {
|
|
36798
37523
|
animation-duration: 400ms;
|
|
36799
37524
|
animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1);
|
|
@@ -36812,7 +37537,6 @@ const popoverStyles = `
|
|
|
36812
37537
|
animation-name: slideRightAndFade;
|
|
36813
37538
|
}
|
|
36814
37539
|
|
|
36815
|
-
|
|
36816
37540
|
@keyframes slideUpAndFade {
|
|
36817
37541
|
from {
|
|
36818
37542
|
opacity: 0;
|
|
@@ -36910,7 +37634,7 @@ const Badge = React__default.forwardRef((t0, ref) => {
|
|
|
36910
37634
|
Badge.displayName = "Badge";
|
|
36911
37635
|
function DebouncedTextField(props) {
|
|
36912
37636
|
const $ = c(13);
|
|
36913
|
-
const previousEventRef = React__default.useRef();
|
|
37637
|
+
const previousEventRef = React__default.useRef(void 0);
|
|
36914
37638
|
const [internalValue, setInternalValue] = React__default.useState(props.value);
|
|
36915
37639
|
const deferredValue = useDeferredValue(internalValue);
|
|
36916
37640
|
let t0;
|
|
@@ -37017,6 +37741,60 @@ function Skeleton(t0) {
|
|
|
37017
37741
|
}
|
|
37018
37742
|
return t5;
|
|
37019
37743
|
}
|
|
37744
|
+
function ToggleButtonGroup(t0) {
|
|
37745
|
+
const $ = c(12);
|
|
37746
|
+
const {
|
|
37747
|
+
value,
|
|
37748
|
+
onValueChange,
|
|
37749
|
+
options,
|
|
37750
|
+
className
|
|
37751
|
+
} = t0;
|
|
37752
|
+
let t1;
|
|
37753
|
+
if ($[0] !== className) {
|
|
37754
|
+
t1 = cls("inline-flex flex-row bg-surface-100 dark:bg-surface-800 rounded-lg p-1 gap-1", className);
|
|
37755
|
+
$[0] = className;
|
|
37756
|
+
$[1] = t1;
|
|
37757
|
+
} else {
|
|
37758
|
+
t1 = $[1];
|
|
37759
|
+
}
|
|
37760
|
+
let t2;
|
|
37761
|
+
if ($[2] !== onValueChange || $[3] !== options || $[4] !== value) {
|
|
37762
|
+
let t32;
|
|
37763
|
+
if ($[6] !== onValueChange || $[7] !== value) {
|
|
37764
|
+
t32 = (option) => /* @__PURE__ */ jsxs("button", { type: "button", onClick: (e) => {
|
|
37765
|
+
e.stopPropagation();
|
|
37766
|
+
if (!option.disabled) {
|
|
37767
|
+
onValueChange(option.value);
|
|
37768
|
+
}
|
|
37769
|
+
}, disabled: option.disabled, className: cls("flex flex-row items-center justify-center gap-2 py-3 px-4 rounded-md transition-colors", value === option.value ? "bg-white dark:bg-surface-950 text-primary dark:text-primary-300" : "text-surface-500 dark:text-surface-400 hover:bg-surface-100 dark:hover:bg-surface-700", option.disabled && "opacity-50 cursor-not-allowed"), children: [
|
|
37770
|
+
option.icon,
|
|
37771
|
+
/* @__PURE__ */ jsx("span", { className: "text-sm font-medium", children: option.label })
|
|
37772
|
+
] }, option.value);
|
|
37773
|
+
$[6] = onValueChange;
|
|
37774
|
+
$[7] = value;
|
|
37775
|
+
$[8] = t32;
|
|
37776
|
+
} else {
|
|
37777
|
+
t32 = $[8];
|
|
37778
|
+
}
|
|
37779
|
+
t2 = options.map(t32);
|
|
37780
|
+
$[2] = onValueChange;
|
|
37781
|
+
$[3] = options;
|
|
37782
|
+
$[4] = value;
|
|
37783
|
+
$[5] = t2;
|
|
37784
|
+
} else {
|
|
37785
|
+
t2 = $[5];
|
|
37786
|
+
}
|
|
37787
|
+
let t3;
|
|
37788
|
+
if ($[9] !== t1 || $[10] !== t2) {
|
|
37789
|
+
t3 = /* @__PURE__ */ jsx("div", { className: t1, children: t2 });
|
|
37790
|
+
$[9] = t1;
|
|
37791
|
+
$[10] = t2;
|
|
37792
|
+
$[11] = t3;
|
|
37793
|
+
} else {
|
|
37794
|
+
t3 = $[11];
|
|
37795
|
+
}
|
|
37796
|
+
return t3;
|
|
37797
|
+
}
|
|
37020
37798
|
export {
|
|
37021
37799
|
AbcIcon,
|
|
37022
37800
|
AcUnitIcon,
|
|
@@ -37405,6 +38183,7 @@ export {
|
|
|
37405
38183
|
CollectionsBookmarkIcon,
|
|
37406
38184
|
CollectionsIcon,
|
|
37407
38185
|
ColorLensIcon,
|
|
38186
|
+
ColorPicker,
|
|
37408
38187
|
ColorizeIcon,
|
|
37409
38188
|
CommentBankIcon,
|
|
37410
38189
|
CommentIcon,
|
|
@@ -38521,6 +39300,7 @@ export {
|
|
|
38521
39300
|
PoolIcon,
|
|
38522
39301
|
Popover,
|
|
38523
39302
|
PortableWifiOffIcon,
|
|
39303
|
+
PortalContainerProvider,
|
|
38524
39304
|
PortraitIcon,
|
|
38525
39305
|
PostAddIcon,
|
|
38526
39306
|
PowerIcon,
|
|
@@ -39027,6 +39807,7 @@ export {
|
|
|
39027
39807
|
TitleIcon,
|
|
39028
39808
|
TocIcon,
|
|
39029
39809
|
TodayIcon,
|
|
39810
|
+
ToggleButtonGroup,
|
|
39030
39811
|
ToggleOffIcon,
|
|
39031
39812
|
ToggleOnIcon,
|
|
39032
39813
|
TokenIcon,
|
|
@@ -39316,6 +40097,7 @@ export {
|
|
|
39316
40097
|
useDebounceValue,
|
|
39317
40098
|
useIconStyles,
|
|
39318
40099
|
useInjectStyles,
|
|
39319
|
-
useOutsideAlerter
|
|
40100
|
+
useOutsideAlerter,
|
|
40101
|
+
usePortalContainer
|
|
39320
40102
|
};
|
|
39321
40103
|
//# sourceMappingURL=index.es.js.map
|