@spear-ai/spectral 1.9.0 → 1.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -5
- package/dist/.js +112 -239
- package/dist/Accordion-CDXdSAST.js +363 -0
- package/dist/Accordion.js +3 -498
- package/dist/Alert/AlertBase.js +69 -152
- package/dist/Alert.js +58 -106
- package/dist/AnimatePresence-D-9jXfgI.js +178 -0
- package/dist/App.js +6 -6
- package/dist/Avatar.js +83 -65
- package/dist/Badge.d.ts +1 -3
- package/dist/Badge.js +21 -25
- package/dist/Button.js +102 -178
- package/dist/ButtonGroup/ButtonGroupButton.js +38 -40
- package/dist/ButtonGroup.js +55 -59
- package/dist/ButtonIcon.js +58 -134
- package/dist/Calendar-s4lyijkn.js +3109 -0
- package/dist/Checkbox/CheckboxBase.js +94 -126
- package/dist/Checkbox.d.ts +1 -1
- package/dist/Checkbox.js +40 -105
- package/dist/Combobox/ComboboxBase.js +2 -79
- package/dist/Combobox.js +106 -172
- package/dist/ComboboxBase-D8Nf4xC-.js +491 -0
- package/dist/ControlGroup/ControlGroupSelect.d.ts +1 -1
- package/dist/ControlGroup/ControlGroupSelect.js +85 -101
- package/dist/ControlGroup.js +45 -48
- package/dist/DataCard/Card.js +37 -12
- package/dist/DataCard.d.ts +1 -1
- package/dist/DataCard.js +36 -16
- package/dist/DateTimePicker/Calendar.js +2 -2967
- package/dist/DateTimePicker/DateTimeDisplayInput.d.ts +1 -1
- package/dist/DateTimePicker/DateTimeDisplayInput.js +379 -274
- package/dist/DateTimePicker/DateTimeInput.d.ts +5 -3
- package/dist/DateTimePicker/DateTimeInput.js +133 -88
- package/dist/DateTimePicker/DateTimeUtils.js +2 -2193
- package/dist/DateTimePicker/TimePeriodSelect.d.ts +1 -1
- package/dist/DateTimePicker/TimePeriodSelect.js +45 -20
- package/dist/DateTimePicker/TimePicker.d.ts +1 -1
- package/dist/DateTimePicker/TimePicker.js +76 -60
- package/dist/DateTimePicker.d.ts +2 -2
- package/dist/DateTimePicker.js +87 -205
- package/dist/DateTimeUtils-DVvG6H-p.js +2098 -0
- package/dist/Dialog.js +74 -74
- package/dist/Drawer.js +67 -37
- package/dist/HoverCard-CYDsIiVK.js +201 -0
- package/dist/HoverCard.d.ts +1 -1
- package/dist/HoverCard.js +2 -218
- package/dist/Icons/AnalyzeIcon.js +50 -57
- package/dist/Icons/AnnotationsIcon.js +20 -15
- package/dist/Icons/ApprovedIcon.js +26 -18
- package/dist/Icons/ArrowDownIcon.js +20 -6
- package/dist/Icons/ArrowUpIcon.js +20 -6
- package/dist/Icons/BoxToolIcon.js +17 -12
- package/dist/Icons/CalendarIcon.js +43 -20
- package/dist/Icons/CheckCircleIcon.js +26 -10
- package/dist/Icons/CheckSquareIcon.js +26 -10
- package/dist/Icons/CheckmarkIcon.js +22 -9
- package/dist/Icons/ChevronDownIcon.js +22 -9
- package/dist/Icons/ChevronUpIcon.js +22 -9
- package/dist/Icons/ClockIcon.js +26 -18
- package/dist/Icons/CloseCircleIcon.js +26 -10
- package/dist/Icons/CloseIcon.js +18 -9
- package/dist/Icons/DashboardIcon.js +36 -10
- package/dist/Icons/DatabaseIcon.js +36 -19
- package/dist/Icons/DeleteIcon.js +36 -19
- package/dist/Icons/DurationIcon.js +57 -22
- package/dist/Icons/EditIcon.js +26 -27
- package/dist/Icons/EmailIcon.js +26 -10
- package/dist/Icons/EraserIcon.js +41 -25
- package/dist/Icons/ErrorIcon.js +27 -11
- package/dist/Icons/EyeClosedIcon.js +29 -13
- package/dist/Icons/EyeClosedIcon2.js +27 -11
- package/dist/Icons/EyeOpenIcon.js +22 -9
- package/dist/Icons/FileDownloadIcon.js +43 -20
- package/dist/Icons/GoToFirstIcon.js +26 -9
- package/dist/Icons/GoToLastIcon.js +26 -9
- package/dist/Icons/HarmonicCursorsIcon.js +23 -9
- package/dist/Icons/IconBase.d.ts +3 -3
- package/dist/Icons/IconBase.js +49 -23
- package/dist/Icons/InfoIcon.js +36 -10
- package/dist/Icons/KeyboardIcon.js +26 -27
- package/dist/Icons/LabelIcon.js +19 -14
- package/dist/Icons/LassoIcon.js +36 -28
- package/dist/Icons/LineToolIcon.js +48 -39
- package/dist/Icons/LiveViewIcon.js +50 -12
- package/dist/Icons/LoaderIcon.js +67 -27
- package/dist/Icons/LocationIcon.js +26 -27
- package/dist/Icons/LogoutIcon.js +20 -15
- package/dist/Icons/MeasureIcon.js +78 -25
- package/dist/Icons/MessagesIcon.js +33 -18
- package/dist/Icons/MetadataIcon.js +20 -15
- package/dist/Icons/MinusIcon.d.ts +1 -1
- package/dist/Icons/MinusIcon.js +18 -6
- package/dist/Icons/OntologyIcon.js +87 -71
- package/dist/Icons/PanelIconClose.js +28 -10
- package/dist/Icons/PanelIconOpen.js +28 -10
- package/dist/Icons/PlayIcon.js +20 -6
- package/dist/Icons/PlusIcon.js +20 -14
- package/dist/Icons/PolygonIcon.js +50 -39
- package/dist/Icons/ProgressCheckIcon.d.ts +5 -0
- package/dist/Icons/ProgressCheckIcon.js +58 -0
- package/dist/Icons/ResetIcon.js +17 -12
- package/dist/Icons/ReviewedIcon.js +36 -19
- package/dist/Icons/ScissorsIcon.js +22 -17
- package/dist/Icons/SearchIcon.js +26 -9
- package/dist/Icons/SettingsIcon.js +26 -27
- package/dist/Icons/SortAscendingIcon.js +50 -12
- package/dist/Icons/SortAtoZIcon.js +50 -12
- package/dist/Icons/SortDescendingIcon.js +50 -12
- package/dist/Icons/SortZtoAIcon.js +50 -12
- package/dist/Icons/StackIcon.js +26 -9
- package/dist/Icons/StarIcon.js +20 -6
- package/dist/Icons/TrashIcon.js +17 -12
- package/dist/Icons/UndoIcon.js +20 -15
- package/dist/Icons/User2Icon.js +26 -10
- package/dist/Icons/UserIcon.js +19 -14
- package/dist/Icons/WarningIcon.js +19 -14
- package/dist/Icons/ZoomAllIcon.js +71 -15
- package/dist/Icons/ZoomXIcon.js +36 -10
- package/dist/Icons/ZoomYIcon.js +36 -10
- package/dist/Icons/index.d.ts +1 -0
- package/dist/Icons.js +68 -136
- package/dist/IconsAnimated/PanelLeftCloseIcon.js +66 -36
- package/dist/IconsAnimated/PanelLeftOpenIcon.js +66 -36
- package/dist/IconsAnimated.js +3 -6
- package/dist/Input/InputUtils.js +51 -52
- package/dist/Input.js +132 -185
- package/dist/InputOTP-XUWW9xcI.js +461 -0
- package/dist/InputOTP.js +2 -382
- package/dist/Kbd.d.ts +1 -1
- package/dist/Kbd.js +182 -86
- package/dist/Label.js +12 -14
- package/dist/MultiSelect/MultiSelectBase.js +331 -403
- package/dist/MultiSelect.d.ts +1 -1
- package/dist/MultiSelect.js +23 -23
- package/dist/Popover.js +28 -32
- package/dist/RadioButton.d.ts +17 -0
- package/dist/RadioButton.js +33 -0
- package/dist/RadioButtonGroup/RadioButtonGroupBase.d.ts +3 -1
- package/dist/RadioButtonGroup/RadioButtonGroupBase.js +49 -46
- package/dist/RadioButtonGroup.d.ts +1 -1
- package/dist/RadioButtonGroup.js +11 -8
- package/dist/RadioGroup-w_q6RGEK.js +447 -0
- package/dist/RadioGroup.js +2 -505
- package/dist/Select.js +163 -186
- package/dist/Separator.js +16 -19
- package/dist/Skeleton.js +10 -6
- package/dist/Slider-BzzZT3Zm.js +490 -0
- package/dist/Slider.js +2 -562
- package/dist/SpectralProvider.js +8 -5
- package/dist/Switch/SwitchBase.js +91 -95
- package/dist/Switch-CVzRJ-0n.js +126 -0
- package/dist/Switch.d.ts +1 -1
- package/dist/Switch.js +2 -134
- package/dist/Tabs/TabsBase.js +242 -250
- package/dist/Tabs/tabsUtils.js +65 -73
- package/dist/Tabs.d.ts +1 -1
- package/dist/Tabs.js +73 -103
- package/dist/Textarea/TextareaUtils.js +35 -46
- package/dist/Textarea.js +83 -160
- package/dist/Toast-9zqXxKKO.js +711 -0
- package/dist/Toast.js +2 -885
- package/dist/Toggle/ToggleBase.js +46 -56
- package/dist/Toggle.d.ts +1 -1
- package/dist/Toggle.js +52 -62
- package/dist/ToggleGroup/ToggleGroupBase.js +128 -104
- package/dist/ToggleGroup.d.ts +1 -1
- package/dist/ToggleGroup.js +52 -63
- package/dist/Tooltip-D1K8kY1y.js +389 -0
- package/dist/Tooltip.js +2 -365
- package/dist/Tray.js +174 -217
- package/dist/chunk-h9knIhTc.js +20 -0
- package/dist/clsx-jM1GlMvB.js +16 -0
- package/dist/dist-3Af8168y.js +913 -0
- package/dist/dist-7HRQ5IKN.js +249 -0
- package/dist/dist-B2k1iWFp.js +129 -0
- package/dist/dist-B4FgboI8.js +122 -0
- package/dist/dist-B4g6zpUF.js +33 -0
- package/dist/dist-B9tup-4O.js +216 -0
- package/dist/dist-BK1K0g9W.js +29 -0
- package/dist/dist-Bfjk-jx9.js +28 -0
- package/dist/dist-Bft31cJh.js +65 -0
- package/dist/dist-BtdmHAzK.js +190 -0
- package/dist/dist-C0Hifjgh.js +1287 -0
- package/dist/dist-CGzgmYB9.js +68 -0
- package/dist/dist-ClmepHp4.js +10 -0
- package/dist/dist-D8Wb_MX9.js +6 -0
- package/dist/dist-Dtvmk11N.js +12 -0
- package/dist/dist-fW81qjVl.js +677 -0
- package/dist/dist-s1uWaZYZ.js +11 -0
- package/dist/es2015-YHaMV-St.js +701 -0
- package/dist/hooks/useAccordionAutoScroll.js +66 -67
- package/dist/hooks/useControllableState.js +14 -13
- package/dist/hooks/useTheme.js +21 -17
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/main.js +18954 -27224
- package/dist/primitives/button.js +39 -41
- package/dist/primitives/input-group.js +57 -73
- package/dist/primitives/input.js +11 -20
- package/dist/primitives/popover.d.ts.map +1 -1
- package/dist/primitives/popover.js +34 -25
- package/dist/primitives/select.js +70 -138
- package/dist/primitives/slot.js +32 -31
- package/dist/primitives/textarea.js +10 -16
- package/dist/proxy-Dn10Pl_g.js +4920 -0
- package/dist/styles/main.css +2 -1
- package/dist/styles/spectral.css +1 -1
- package/dist/twUtils-VNWgstKL.js +1673 -0
- package/dist/use-animation-CBUDycyW.js +57 -0
- package/dist/utils/constants.js +4 -4
- package/dist/utils/formFieldUtils.js +136 -148
- package/dist/utils/sharedUtils.js +26 -7
- package/dist/utils/twUtils.js +2 -2919
- package/package.json +24 -28
- package/dist/ComboboxBase-CxNxYtdT.js +0 -408
- package/dist/clsx-OuTLNxxd.js +0 -16
- package/dist/index-0ioNhtNM.js +0 -10
- package/dist/index-6oYKCvIn.js +0 -677
- package/dist/index-BFOf48AQ.js +0 -69
- package/dist/index-BZPx6jYI.js +0 -8
- package/dist/index-BlHU_t18.js +0 -142
- package/dist/index-Bm1RbF6w.js +0 -1037
- package/dist/index-Bv2OIg5P.js +0 -225
- package/dist/index-CKEI0pDv.js +0 -56
- package/dist/index-CM_hWgfC.js +0 -32
- package/dist/index-C_YVr64u.js +0 -1538
- package/dist/index-Cl8VeY0o.js +0 -149
- package/dist/index-CwSyIPrv.js +0 -13
- package/dist/index-D29mdTf5.js +0 -34
- package/dist/index-DEYs15GP.js +0 -66
- package/dist/index-Dc0No4pV.js +0 -233
- package/dist/index-T6XEa11q.js +0 -822
- package/dist/index-pBCLb6Gr.js +0 -240
- package/dist/index-psiVrsnE.js +0 -27
- package/dist/index-rKs9bXHr.js +0 -6
- package/dist/proxy-CO_-Vget.js +0 -4975
- package/dist/use-animation-DhEPRwZ3.js +0 -62
|
@@ -0,0 +1,249 @@
|
|
|
1
|
+
import "./styles/main.css";
|
|
2
|
+
import * as e from "react";
|
|
3
|
+
import * as t from "react-dom";
|
|
4
|
+
import { Fragment as n, jsx as r } from "react/jsx-runtime";
|
|
5
|
+
//#region node_modules/.pnpm/@radix-ui+react-context@1.1.2_@types+react@19.2.14_react@19.2.3/node_modules/@radix-ui/react-context/dist/index.mjs
|
|
6
|
+
function i(t, n) {
|
|
7
|
+
let i = e.createContext(n), a = (t) => {
|
|
8
|
+
let { children: n, ...a } = t, o = e.useMemo(() => a, Object.values(a));
|
|
9
|
+
return /* @__PURE__ */ r(i.Provider, {
|
|
10
|
+
value: o,
|
|
11
|
+
children: n
|
|
12
|
+
});
|
|
13
|
+
};
|
|
14
|
+
a.displayName = t + "Provider";
|
|
15
|
+
function o(r) {
|
|
16
|
+
let a = e.useContext(i);
|
|
17
|
+
if (a) return a;
|
|
18
|
+
if (n !== void 0) return n;
|
|
19
|
+
throw Error(`\`${r}\` must be used within \`${t}\``);
|
|
20
|
+
}
|
|
21
|
+
return [a, o];
|
|
22
|
+
}
|
|
23
|
+
function a(t, n = []) {
|
|
24
|
+
let i = [];
|
|
25
|
+
function a(n, a) {
|
|
26
|
+
let o = e.createContext(a), s = i.length;
|
|
27
|
+
i = [...i, a];
|
|
28
|
+
let c = (n) => {
|
|
29
|
+
let { scope: i, children: a, ...c } = n, l = i?.[t]?.[s] || o, u = e.useMemo(() => c, Object.values(c));
|
|
30
|
+
return /* @__PURE__ */ r(l.Provider, {
|
|
31
|
+
value: u,
|
|
32
|
+
children: a
|
|
33
|
+
});
|
|
34
|
+
};
|
|
35
|
+
c.displayName = n + "Provider";
|
|
36
|
+
function l(r, i) {
|
|
37
|
+
let c = i?.[t]?.[s] || o, l = e.useContext(c);
|
|
38
|
+
if (l) return l;
|
|
39
|
+
if (a !== void 0) return a;
|
|
40
|
+
throw Error(`\`${r}\` must be used within \`${n}\``);
|
|
41
|
+
}
|
|
42
|
+
return [c, l];
|
|
43
|
+
}
|
|
44
|
+
let s = () => {
|
|
45
|
+
let n = i.map((t) => e.createContext(t));
|
|
46
|
+
return function(r) {
|
|
47
|
+
let i = r?.[t] || n;
|
|
48
|
+
return e.useMemo(() => ({ [`__scope${t}`]: {
|
|
49
|
+
...r,
|
|
50
|
+
[t]: i
|
|
51
|
+
} }), [r, i]);
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
return s.scopeName = t, [a, o(s, ...n)];
|
|
55
|
+
}
|
|
56
|
+
function o(...t) {
|
|
57
|
+
let n = t[0];
|
|
58
|
+
if (t.length === 1) return n;
|
|
59
|
+
let r = () => {
|
|
60
|
+
let r = t.map((e) => ({
|
|
61
|
+
useScope: e(),
|
|
62
|
+
scopeName: e.scopeName
|
|
63
|
+
}));
|
|
64
|
+
return function(t) {
|
|
65
|
+
let i = r.reduce((e, { useScope: n, scopeName: r }) => {
|
|
66
|
+
let i = n(t)[`__scope${r}`];
|
|
67
|
+
return {
|
|
68
|
+
...e,
|
|
69
|
+
...i
|
|
70
|
+
};
|
|
71
|
+
}, {});
|
|
72
|
+
return e.useMemo(() => ({ [`__scope${n.scopeName}`]: i }), [i]);
|
|
73
|
+
};
|
|
74
|
+
};
|
|
75
|
+
return r.scopeName = n.scopeName, r;
|
|
76
|
+
}
|
|
77
|
+
//#endregion
|
|
78
|
+
//#region node_modules/.pnpm/@radix-ui+react-compose-refs@1.1.2_@types+react@19.2.14_react@19.2.3/node_modules/@radix-ui/react-compose-refs/dist/index.mjs
|
|
79
|
+
function s(e, t) {
|
|
80
|
+
if (typeof e == "function") return e(t);
|
|
81
|
+
e != null && (e.current = t);
|
|
82
|
+
}
|
|
83
|
+
function c(...e) {
|
|
84
|
+
return (t) => {
|
|
85
|
+
let n = !1, r = e.map((e) => {
|
|
86
|
+
let r = s(e, t);
|
|
87
|
+
return !n && typeof r == "function" && (n = !0), r;
|
|
88
|
+
});
|
|
89
|
+
if (n) return () => {
|
|
90
|
+
for (let t = 0; t < r.length; t++) {
|
|
91
|
+
let n = r[t];
|
|
92
|
+
typeof n == "function" ? n() : s(e[t], null);
|
|
93
|
+
}
|
|
94
|
+
};
|
|
95
|
+
};
|
|
96
|
+
}
|
|
97
|
+
function l(...t) {
|
|
98
|
+
return e.useCallback(c(...t), t);
|
|
99
|
+
}
|
|
100
|
+
//#endregion
|
|
101
|
+
//#region node_modules/.pnpm/@radix-ui+react-slot@1.2.3_@types+react@19.2.14_react@19.2.3/node_modules/@radix-ui/react-slot/dist/index.mjs
|
|
102
|
+
/* @__NO_SIDE_EFFECTS__ */
|
|
103
|
+
function u(t) {
|
|
104
|
+
let n = /* @__PURE__ */ d(t), i = e.forwardRef((t, i) => {
|
|
105
|
+
let { children: a, ...o } = t, s = e.Children.toArray(a), c = s.find(m);
|
|
106
|
+
if (c) {
|
|
107
|
+
let t = c.props.children, a = s.map((n) => n === c ? e.Children.count(t) > 1 ? e.Children.only(null) : e.isValidElement(t) ? t.props.children : null : n);
|
|
108
|
+
return /* @__PURE__ */ r(n, {
|
|
109
|
+
...o,
|
|
110
|
+
ref: i,
|
|
111
|
+
children: e.isValidElement(t) ? e.cloneElement(t, void 0, a) : null
|
|
112
|
+
});
|
|
113
|
+
}
|
|
114
|
+
return /* @__PURE__ */ r(n, {
|
|
115
|
+
...o,
|
|
116
|
+
ref: i,
|
|
117
|
+
children: a
|
|
118
|
+
});
|
|
119
|
+
});
|
|
120
|
+
return i.displayName = `${t}.Slot`, i;
|
|
121
|
+
}
|
|
122
|
+
/* @__NO_SIDE_EFFECTS__ */
|
|
123
|
+
function d(t) {
|
|
124
|
+
let n = e.forwardRef((t, n) => {
|
|
125
|
+
let { children: r, ...i } = t;
|
|
126
|
+
if (e.isValidElement(r)) {
|
|
127
|
+
let t = g(r), a = h(i, r.props);
|
|
128
|
+
return r.type !== e.Fragment && (a.ref = n ? c(n, t) : t), e.cloneElement(r, a);
|
|
129
|
+
}
|
|
130
|
+
return e.Children.count(r) > 1 ? e.Children.only(null) : null;
|
|
131
|
+
});
|
|
132
|
+
return n.displayName = `${t}.SlotClone`, n;
|
|
133
|
+
}
|
|
134
|
+
var f = Symbol("radix.slottable");
|
|
135
|
+
/* @__NO_SIDE_EFFECTS__ */
|
|
136
|
+
function p(e) {
|
|
137
|
+
let t = ({ children: e }) => /* @__PURE__ */ r(n, { children: e });
|
|
138
|
+
return t.displayName = `${e}.Slottable`, t.__radixId = f, t;
|
|
139
|
+
}
|
|
140
|
+
function m(t) {
|
|
141
|
+
return e.isValidElement(t) && typeof t.type == "function" && "__radixId" in t.type && t.type.__radixId === f;
|
|
142
|
+
}
|
|
143
|
+
function h(e, t) {
|
|
144
|
+
let n = { ...t };
|
|
145
|
+
for (let r in t) {
|
|
146
|
+
let i = e[r], a = t[r];
|
|
147
|
+
/^on[A-Z]/.test(r) ? i && a ? n[r] = (...e) => {
|
|
148
|
+
let t = a(...e);
|
|
149
|
+
return i(...e), t;
|
|
150
|
+
} : i && (n[r] = i) : r === "style" ? n[r] = {
|
|
151
|
+
...i,
|
|
152
|
+
...a
|
|
153
|
+
} : r === "className" && (n[r] = [i, a].filter(Boolean).join(" "));
|
|
154
|
+
}
|
|
155
|
+
return {
|
|
156
|
+
...e,
|
|
157
|
+
...n
|
|
158
|
+
};
|
|
159
|
+
}
|
|
160
|
+
function g(e) {
|
|
161
|
+
let t = Object.getOwnPropertyDescriptor(e.props, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning;
|
|
162
|
+
return n ? e.ref : (t = Object.getOwnPropertyDescriptor(e, "ref")?.get, n = t && "isReactWarning" in t && t.isReactWarning, n ? e.props.ref : e.props.ref || e.ref);
|
|
163
|
+
}
|
|
164
|
+
typeof window < "u" && window.document && window.document.createElement;
|
|
165
|
+
function _(e, t, { checkForDefaultPrevented: n = !0 } = {}) {
|
|
166
|
+
return function(r) {
|
|
167
|
+
if (e?.(r), n === !1 || !r.defaultPrevented) return t?.(r);
|
|
168
|
+
};
|
|
169
|
+
}
|
|
170
|
+
//#endregion
|
|
171
|
+
//#region node_modules/.pnpm/@radix-ui+react-use-layout-effect@1.1.1_@types+react@19.2.14_react@19.2.3/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs
|
|
172
|
+
var v = globalThis?.document ? e.useLayoutEffect : () => {}, y = e.useInsertionEffect || v;
|
|
173
|
+
function b({ prop: t, defaultProp: n, onChange: r = () => {}, caller: i }) {
|
|
174
|
+
let [a, o, s] = x({
|
|
175
|
+
defaultProp: n,
|
|
176
|
+
onChange: r
|
|
177
|
+
}), c = t !== void 0, l = c ? t : a;
|
|
178
|
+
{
|
|
179
|
+
let n = e.useRef(t !== void 0);
|
|
180
|
+
e.useEffect(() => {
|
|
181
|
+
let e = n.current;
|
|
182
|
+
e !== c && console.warn(`${i} is changing from ${e ? "controlled" : "uncontrolled"} to ${c ? "controlled" : "uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`), n.current = c;
|
|
183
|
+
}, [c, i]);
|
|
184
|
+
}
|
|
185
|
+
return [l, e.useCallback((e) => {
|
|
186
|
+
if (c) {
|
|
187
|
+
let n = S(e) ? e(t) : e;
|
|
188
|
+
n !== t && s.current?.(n);
|
|
189
|
+
} else o(e);
|
|
190
|
+
}, [
|
|
191
|
+
c,
|
|
192
|
+
t,
|
|
193
|
+
o,
|
|
194
|
+
s
|
|
195
|
+
])];
|
|
196
|
+
}
|
|
197
|
+
function x({ defaultProp: t, onChange: n }) {
|
|
198
|
+
let [r, i] = e.useState(t), a = e.useRef(r), o = e.useRef(n);
|
|
199
|
+
return y(() => {
|
|
200
|
+
o.current = n;
|
|
201
|
+
}, [n]), e.useEffect(() => {
|
|
202
|
+
a.current !== r && (o.current?.(r), a.current = r);
|
|
203
|
+
}, [r, a]), [
|
|
204
|
+
r,
|
|
205
|
+
i,
|
|
206
|
+
o
|
|
207
|
+
];
|
|
208
|
+
}
|
|
209
|
+
function S(e) {
|
|
210
|
+
return typeof e == "function";
|
|
211
|
+
}
|
|
212
|
+
//#endregion
|
|
213
|
+
//#region node_modules/.pnpm/@radix-ui+react-primitive@2.1.3_@types+react-dom@19.2.3_@types+react@19.2.14__@types+re_412fca877c3e29a339aeb07f39bb1abf/node_modules/@radix-ui/react-primitive/dist/index.mjs
|
|
214
|
+
var C = [
|
|
215
|
+
"a",
|
|
216
|
+
"button",
|
|
217
|
+
"div",
|
|
218
|
+
"form",
|
|
219
|
+
"h2",
|
|
220
|
+
"h3",
|
|
221
|
+
"img",
|
|
222
|
+
"input",
|
|
223
|
+
"label",
|
|
224
|
+
"li",
|
|
225
|
+
"nav",
|
|
226
|
+
"ol",
|
|
227
|
+
"p",
|
|
228
|
+
"select",
|
|
229
|
+
"span",
|
|
230
|
+
"svg",
|
|
231
|
+
"ul"
|
|
232
|
+
].reduce((t, n) => {
|
|
233
|
+
let i = /* @__PURE__ */ u(`Primitive.${n}`), a = e.forwardRef((e, t) => {
|
|
234
|
+
let { asChild: a, ...o } = e, s = a ? i : n;
|
|
235
|
+
return typeof window < "u" && (window[Symbol.for("radix-ui")] = !0), /* @__PURE__ */ r(s, {
|
|
236
|
+
...o,
|
|
237
|
+
ref: t
|
|
238
|
+
});
|
|
239
|
+
});
|
|
240
|
+
return a.displayName = `Primitive.${n}`, {
|
|
241
|
+
...t,
|
|
242
|
+
[n]: a
|
|
243
|
+
};
|
|
244
|
+
}, {});
|
|
245
|
+
function w(e, n) {
|
|
246
|
+
e && t.flushSync(() => e.dispatchEvent(n));
|
|
247
|
+
}
|
|
248
|
+
//#endregion
|
|
249
|
+
export { _ as a, c, a as d, v as i, l, w as n, u as o, b as r, p as s, C as t, i as u };
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
import "./styles/main.css";
|
|
2
|
+
import { a as e, i as t, l as n, n as r, t as i } from "./dist-7HRQ5IKN.js";
|
|
3
|
+
import { t as a } from "./dist-ClmepHp4.js";
|
|
4
|
+
import * as o from "react";
|
|
5
|
+
import s from "react-dom";
|
|
6
|
+
import { jsx as c } from "react/jsx-runtime";
|
|
7
|
+
//#region node_modules/.pnpm/@radix-ui+react-use-escape-keydown@1.1.1_@types+react@19.2.14_react@19.2.3/node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs
|
|
8
|
+
function l(e, t = globalThis?.document) {
|
|
9
|
+
let n = a(e);
|
|
10
|
+
o.useEffect(() => {
|
|
11
|
+
let e = (e) => {
|
|
12
|
+
e.key === "Escape" && n(e);
|
|
13
|
+
};
|
|
14
|
+
return t.addEventListener("keydown", e, { capture: !0 }), () => t.removeEventListener("keydown", e, { capture: !0 });
|
|
15
|
+
}, [n, t]);
|
|
16
|
+
}
|
|
17
|
+
//#endregion
|
|
18
|
+
//#region node_modules/.pnpm/@radix-ui+react-dismissable-layer@1.1.11_@types+react-dom@19.2.3_@types+react@19.2.14___329efad33725aa43d6f6eb4d51e1f075/node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs
|
|
19
|
+
var u = "DismissableLayer", d = "dismissableLayer.update", f = "dismissableLayer.pointerDownOutside", p = "dismissableLayer.focusOutside", m, h = o.createContext({
|
|
20
|
+
layers: /* @__PURE__ */ new Set(),
|
|
21
|
+
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
22
|
+
branches: /* @__PURE__ */ new Set()
|
|
23
|
+
}), g = o.forwardRef((t, r) => {
|
|
24
|
+
let { disableOutsidePointerEvents: a = !1, onEscapeKeyDown: s, onPointerDownOutside: u, onFocusOutside: f, onInteractOutside: p, onDismiss: g, ..._ } = t, v = o.useContext(h), [S, C] = o.useState(null), w = S?.ownerDocument ?? globalThis?.document, [, T] = o.useState({}), E = n(r, (e) => C(e)), D = Array.from(v.layers), [O] = [...v.layersWithOutsidePointerEventsDisabled].slice(-1), k = D.indexOf(O), A = S ? D.indexOf(S) : -1, j = v.layersWithOutsidePointerEventsDisabled.size > 0, M = A >= k, N = y((e) => {
|
|
25
|
+
let t = e.target, n = [...v.branches].some((e) => e.contains(t));
|
|
26
|
+
!M || n || (u?.(e), p?.(e), e.defaultPrevented || g?.());
|
|
27
|
+
}, w), P = b((e) => {
|
|
28
|
+
let t = e.target;
|
|
29
|
+
[...v.branches].some((e) => e.contains(t)) || (f?.(e), p?.(e), e.defaultPrevented || g?.());
|
|
30
|
+
}, w);
|
|
31
|
+
return l((e) => {
|
|
32
|
+
A === v.layers.size - 1 && (s?.(e), !e.defaultPrevented && g && (e.preventDefault(), g()));
|
|
33
|
+
}, w), o.useEffect(() => {
|
|
34
|
+
if (S) return a && (v.layersWithOutsidePointerEventsDisabled.size === 0 && (m = w.body.style.pointerEvents, w.body.style.pointerEvents = "none"), v.layersWithOutsidePointerEventsDisabled.add(S)), v.layers.add(S), x(), () => {
|
|
35
|
+
a && v.layersWithOutsidePointerEventsDisabled.size === 1 && (w.body.style.pointerEvents = m);
|
|
36
|
+
};
|
|
37
|
+
}, [
|
|
38
|
+
S,
|
|
39
|
+
w,
|
|
40
|
+
a,
|
|
41
|
+
v
|
|
42
|
+
]), o.useEffect(() => () => {
|
|
43
|
+
S && (v.layers.delete(S), v.layersWithOutsidePointerEventsDisabled.delete(S), x());
|
|
44
|
+
}, [S, v]), o.useEffect(() => {
|
|
45
|
+
let e = () => T({});
|
|
46
|
+
return document.addEventListener(d, e), () => document.removeEventListener(d, e);
|
|
47
|
+
}, []), /* @__PURE__ */ c(i.div, {
|
|
48
|
+
..._,
|
|
49
|
+
ref: E,
|
|
50
|
+
style: {
|
|
51
|
+
pointerEvents: j ? M ? "auto" : "none" : void 0,
|
|
52
|
+
...t.style
|
|
53
|
+
},
|
|
54
|
+
onFocusCapture: e(t.onFocusCapture, P.onFocusCapture),
|
|
55
|
+
onBlurCapture: e(t.onBlurCapture, P.onBlurCapture),
|
|
56
|
+
onPointerDownCapture: e(t.onPointerDownCapture, N.onPointerDownCapture)
|
|
57
|
+
});
|
|
58
|
+
});
|
|
59
|
+
g.displayName = u;
|
|
60
|
+
var _ = "DismissableLayerBranch", v = o.forwardRef((e, t) => {
|
|
61
|
+
let r = o.useContext(h), a = o.useRef(null), s = n(t, a);
|
|
62
|
+
return o.useEffect(() => {
|
|
63
|
+
let e = a.current;
|
|
64
|
+
if (e) return r.branches.add(e), () => {
|
|
65
|
+
r.branches.delete(e);
|
|
66
|
+
};
|
|
67
|
+
}, [r.branches]), /* @__PURE__ */ c(i.div, {
|
|
68
|
+
...e,
|
|
69
|
+
ref: s
|
|
70
|
+
});
|
|
71
|
+
});
|
|
72
|
+
v.displayName = _;
|
|
73
|
+
function y(e, t = globalThis?.document) {
|
|
74
|
+
let n = a(e), r = o.useRef(!1), i = o.useRef(() => {});
|
|
75
|
+
return o.useEffect(() => {
|
|
76
|
+
let e = (e) => {
|
|
77
|
+
if (e.target && !r.current) {
|
|
78
|
+
let r = function() {
|
|
79
|
+
S(f, n, a, { discrete: !0 });
|
|
80
|
+
}, a = { originalEvent: e };
|
|
81
|
+
e.pointerType === "touch" ? (t.removeEventListener("click", i.current), i.current = r, t.addEventListener("click", i.current, { once: !0 })) : r();
|
|
82
|
+
} else t.removeEventListener("click", i.current);
|
|
83
|
+
r.current = !1;
|
|
84
|
+
}, a = window.setTimeout(() => {
|
|
85
|
+
t.addEventListener("pointerdown", e);
|
|
86
|
+
}, 0);
|
|
87
|
+
return () => {
|
|
88
|
+
window.clearTimeout(a), t.removeEventListener("pointerdown", e), t.removeEventListener("click", i.current);
|
|
89
|
+
};
|
|
90
|
+
}, [t, n]), { onPointerDownCapture: () => r.current = !0 };
|
|
91
|
+
}
|
|
92
|
+
function b(e, t = globalThis?.document) {
|
|
93
|
+
let n = a(e), r = o.useRef(!1);
|
|
94
|
+
return o.useEffect(() => {
|
|
95
|
+
let e = (e) => {
|
|
96
|
+
e.target && !r.current && S(p, n, { originalEvent: e }, { discrete: !1 });
|
|
97
|
+
};
|
|
98
|
+
return t.addEventListener("focusin", e), () => t.removeEventListener("focusin", e);
|
|
99
|
+
}, [t, n]), {
|
|
100
|
+
onFocusCapture: () => r.current = !0,
|
|
101
|
+
onBlurCapture: () => r.current = !1
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
function x() {
|
|
105
|
+
let e = new CustomEvent(d);
|
|
106
|
+
document.dispatchEvent(e);
|
|
107
|
+
}
|
|
108
|
+
function S(e, t, n, { discrete: i }) {
|
|
109
|
+
let a = n.originalEvent.target, o = new CustomEvent(e, {
|
|
110
|
+
bubbles: !1,
|
|
111
|
+
cancelable: !0,
|
|
112
|
+
detail: n
|
|
113
|
+
});
|
|
114
|
+
t && a.addEventListener(e, t, { once: !0 }), i ? r(a, o) : a.dispatchEvent(o);
|
|
115
|
+
}
|
|
116
|
+
//#endregion
|
|
117
|
+
//#region node_modules/.pnpm/@radix-ui+react-portal@1.1.9_@types+react-dom@19.2.3_@types+react@19.2.14__@types+react_5c2c61d0e62328a3bee6b1bf05b78710/node_modules/@radix-ui/react-portal/dist/index.mjs
|
|
118
|
+
var C = "Portal", w = o.forwardRef((e, n) => {
|
|
119
|
+
let { container: r, ...a } = e, [l, u] = o.useState(!1);
|
|
120
|
+
t(() => u(!0), []);
|
|
121
|
+
let d = r || l && globalThis?.document?.body;
|
|
122
|
+
return d ? s.createPortal(/* @__PURE__ */ c(i.div, {
|
|
123
|
+
...a,
|
|
124
|
+
ref: n
|
|
125
|
+
}), d) : null;
|
|
126
|
+
});
|
|
127
|
+
w.displayName = C;
|
|
128
|
+
//#endregion
|
|
129
|
+
export { g as n, w as t };
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import { useEffect as e, useMemo as t, useRef as n, useState as r } from "react";
|
|
2
|
+
//#region node_modules/.pnpm/react-use-measure@2.1.7_react-dom@19.2.3_react@19.2.3__react@19.2.3/node_modules/react-use-measure/dist/index.js
|
|
3
|
+
function i(e, t) {
|
|
4
|
+
let n;
|
|
5
|
+
return (...r) => {
|
|
6
|
+
window.clearTimeout(n), n = window.setTimeout(() => e(...r), t);
|
|
7
|
+
};
|
|
8
|
+
}
|
|
9
|
+
function a({ debounce: a, scroll: l, polyfill: d, offsetSize: f } = {
|
|
10
|
+
debounce: 0,
|
|
11
|
+
scroll: !1,
|
|
12
|
+
offsetSize: !1
|
|
13
|
+
}) {
|
|
14
|
+
let p = d || (typeof window > "u" ? class {} : window.ResizeObserver);
|
|
15
|
+
if (!p) throw Error("This browser does not support ResizeObserver out of the box. See: https://github.com/react-spring/react-use-measure/#resize-observer-polyfills");
|
|
16
|
+
let [m, h] = r({
|
|
17
|
+
left: 0,
|
|
18
|
+
top: 0,
|
|
19
|
+
width: 0,
|
|
20
|
+
height: 0,
|
|
21
|
+
bottom: 0,
|
|
22
|
+
right: 0,
|
|
23
|
+
x: 0,
|
|
24
|
+
y: 0
|
|
25
|
+
}), g = n({
|
|
26
|
+
element: null,
|
|
27
|
+
scrollContainers: null,
|
|
28
|
+
resizeObserver: null,
|
|
29
|
+
lastBounds: m,
|
|
30
|
+
orientationHandler: null
|
|
31
|
+
}), _ = a ? typeof a == "number" ? a : a.scroll : null, v = a ? typeof a == "number" ? a : a.resize : null, y = n(!1);
|
|
32
|
+
e(() => (y.current = !0, () => void (y.current = !1)));
|
|
33
|
+
let [b, x, S] = t(() => {
|
|
34
|
+
let e = () => {
|
|
35
|
+
if (!g.current.element) return;
|
|
36
|
+
let { left: e, top: t, width: n, height: r, bottom: i, right: a, x: o, y: s } = g.current.element.getBoundingClientRect(), c = {
|
|
37
|
+
left: e,
|
|
38
|
+
top: t,
|
|
39
|
+
width: n,
|
|
40
|
+
height: r,
|
|
41
|
+
bottom: i,
|
|
42
|
+
right: a,
|
|
43
|
+
x: o,
|
|
44
|
+
y: s
|
|
45
|
+
};
|
|
46
|
+
g.current.element instanceof HTMLElement && f && (c.height = g.current.element.offsetHeight, c.width = g.current.element.offsetWidth), Object.freeze(c), y.current && !u(g.current.lastBounds, c) && h(g.current.lastBounds = c);
|
|
47
|
+
};
|
|
48
|
+
return [
|
|
49
|
+
e,
|
|
50
|
+
v ? i(e, v) : e,
|
|
51
|
+
_ ? i(e, _) : e
|
|
52
|
+
];
|
|
53
|
+
}, [
|
|
54
|
+
h,
|
|
55
|
+
f,
|
|
56
|
+
_,
|
|
57
|
+
v
|
|
58
|
+
]);
|
|
59
|
+
function C() {
|
|
60
|
+
g.current.scrollContainers && (g.current.scrollContainers.forEach((e) => e.removeEventListener("scroll", S, !0)), g.current.scrollContainers = null), g.current.resizeObserver && (g.current.resizeObserver.disconnect(), g.current.resizeObserver = null), g.current.orientationHandler && ("orientation" in screen && "removeEventListener" in screen.orientation ? screen.orientation.removeEventListener("change", g.current.orientationHandler) : "onorientationchange" in window && window.removeEventListener("orientationchange", g.current.orientationHandler));
|
|
61
|
+
}
|
|
62
|
+
function w() {
|
|
63
|
+
g.current.element && (g.current.resizeObserver = new p(S), g.current.resizeObserver.observe(g.current.element), l && g.current.scrollContainers && g.current.scrollContainers.forEach((e) => e.addEventListener("scroll", S, {
|
|
64
|
+
capture: !0,
|
|
65
|
+
passive: !0
|
|
66
|
+
})), g.current.orientationHandler = () => {
|
|
67
|
+
S();
|
|
68
|
+
}, "orientation" in screen && "addEventListener" in screen.orientation ? screen.orientation.addEventListener("change", g.current.orientationHandler) : "onorientationchange" in window && window.addEventListener("orientationchange", g.current.orientationHandler));
|
|
69
|
+
}
|
|
70
|
+
return s(S, !!l), o(x), e(() => {
|
|
71
|
+
C(), w();
|
|
72
|
+
}, [
|
|
73
|
+
l,
|
|
74
|
+
S,
|
|
75
|
+
x
|
|
76
|
+
]), e(() => C, []), [
|
|
77
|
+
(e) => {
|
|
78
|
+
!e || e === g.current.element || (C(), g.current.element = e, g.current.scrollContainers = c(e), w());
|
|
79
|
+
},
|
|
80
|
+
m,
|
|
81
|
+
b
|
|
82
|
+
];
|
|
83
|
+
}
|
|
84
|
+
function o(t) {
|
|
85
|
+
e(() => {
|
|
86
|
+
let e = t;
|
|
87
|
+
return window.addEventListener("resize", e), () => void window.removeEventListener("resize", e);
|
|
88
|
+
}, [t]);
|
|
89
|
+
}
|
|
90
|
+
function s(t, n) {
|
|
91
|
+
e(() => {
|
|
92
|
+
if (n) {
|
|
93
|
+
let e = t;
|
|
94
|
+
return window.addEventListener("scroll", e, {
|
|
95
|
+
capture: !0,
|
|
96
|
+
passive: !0
|
|
97
|
+
}), () => void window.removeEventListener("scroll", e, !0);
|
|
98
|
+
}
|
|
99
|
+
}, [t, n]);
|
|
100
|
+
}
|
|
101
|
+
function c(e) {
|
|
102
|
+
let t = [];
|
|
103
|
+
if (!e || e === document.body) return t;
|
|
104
|
+
let { overflow: n, overflowX: r, overflowY: i } = window.getComputedStyle(e);
|
|
105
|
+
return [
|
|
106
|
+
n,
|
|
107
|
+
r,
|
|
108
|
+
i
|
|
109
|
+
].some((e) => e === "auto" || e === "scroll") && t.push(e), [...t, ...c(e.parentElement)];
|
|
110
|
+
}
|
|
111
|
+
var l = [
|
|
112
|
+
"x",
|
|
113
|
+
"y",
|
|
114
|
+
"top",
|
|
115
|
+
"bottom",
|
|
116
|
+
"left",
|
|
117
|
+
"right",
|
|
118
|
+
"width",
|
|
119
|
+
"height"
|
|
120
|
+
], u = (e, t) => l.every((n) => e[n] === t[n]);
|
|
121
|
+
//#endregion
|
|
122
|
+
export { a as t };
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { t as e } from "./clsx-jM1GlMvB.js";
|
|
2
|
+
//#region node_modules/.pnpm/class-variance-authority@0.7.1/node_modules/class-variance-authority/dist/index.mjs
|
|
3
|
+
var t = (e) => typeof e == "boolean" ? `${e}` : e === 0 ? "0" : e, n = e, r = (e, r) => (i) => {
|
|
4
|
+
if (r?.variants == null) return n(e, i?.class, i?.className);
|
|
5
|
+
let { variants: a, defaultVariants: o } = r, s = Object.keys(a).map((e) => {
|
|
6
|
+
let n = i?.[e], r = o?.[e];
|
|
7
|
+
if (n === null) return null;
|
|
8
|
+
let s = t(n) || t(r);
|
|
9
|
+
return a[e][s];
|
|
10
|
+
}), c = i && Object.entries(i).reduce((e, t) => {
|
|
11
|
+
let [n, r] = t;
|
|
12
|
+
return r === void 0 || (e[n] = r), e;
|
|
13
|
+
}, {});
|
|
14
|
+
return n(e, s, r?.compoundVariants?.reduce((e, t) => {
|
|
15
|
+
let { class: n, className: r, ...i } = t;
|
|
16
|
+
return Object.entries(i).every((e) => {
|
|
17
|
+
let [t, n] = e;
|
|
18
|
+
return Array.isArray(n) ? n.includes({
|
|
19
|
+
...o,
|
|
20
|
+
...c
|
|
21
|
+
}[t]) : {
|
|
22
|
+
...o,
|
|
23
|
+
...c
|
|
24
|
+
}[t] === n;
|
|
25
|
+
}) ? [
|
|
26
|
+
...e,
|
|
27
|
+
n,
|
|
28
|
+
r
|
|
29
|
+
] : e;
|
|
30
|
+
}, []), i?.class, i?.className);
|
|
31
|
+
};
|
|
32
|
+
//#endregion
|
|
33
|
+
export { r as t };
|