@gryt/ui 0.5.0 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Button/Button.d.ts.map +1 -1
- package/dist/components/Combobox/Combobox.d.ts +9 -0
- package/dist/components/Combobox/Combobox.d.ts.map +1 -1
- package/dist/components/IconButton/IconButton.d.ts.map +1 -1
- package/dist/components/Meter/Meter.d.ts +8 -3
- package/dist/components/Meter/Meter.d.ts.map +1 -1
- package/dist/components/Progress/Progress.d.ts.map +1 -1
- package/dist/components/Skeleton/Skeleton.d.ts.map +1 -1
- package/dist/components/TextField/TextField.d.ts.map +1 -1
- package/dist/components/Toast/Toast.d.ts +6 -2
- package/dist/components/Toast/Toast.d.ts.map +1 -1
- package/dist/components/utils/styles.d.ts +21 -0
- package/dist/components/utils/styles.d.ts.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1514 -1255
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/theme/createGrytTheme.d.ts +55 -1
- package/dist/theme/createGrytTheme.d.ts.map +1 -1
- package/dist/theme/oklch.d.ts +74 -0
- package/dist/theme/oklch.d.ts.map +1 -0
- package/dist/theme.css +512 -12
- package/package.json +3 -1
package/dist/index.js
CHANGED
|
@@ -1,46 +1,198 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { Tooltip as
|
|
3
|
-
import { Button as
|
|
4
|
-
import { forwardRef as
|
|
5
|
-
import { clsx as
|
|
6
|
-
import { twMerge as
|
|
7
|
-
import { Field as
|
|
8
|
-
import { PaperPlaneTilt as
|
|
9
|
-
import { Avatar as
|
|
10
|
-
import { Checkbox as
|
|
11
|
-
import { Radio as
|
|
12
|
-
import { RadioGroup as
|
|
13
|
-
import { Switch as
|
|
14
|
-
import { Slider as
|
|
15
|
-
import { Select as
|
|
16
|
-
import { Separator as
|
|
17
|
-
import { Progress as
|
|
18
|
-
import { Dialog as
|
|
19
|
-
import { Drawer as
|
|
20
|
-
import { Menu as
|
|
21
|
-
import { Tabs as
|
|
22
|
-
import { Accordion as
|
|
23
|
-
import { ContextMenu as
|
|
24
|
-
import { Popover as
|
|
25
|
-
import { Toast as
|
|
26
|
-
import { ScrollArea as
|
|
27
|
-
import { Toggle as
|
|
28
|
-
import { ToggleGroup as
|
|
29
|
-
import { Meter as
|
|
30
|
-
import { AlertDialog as
|
|
31
|
-
import { Autocomplete as
|
|
32
|
-
import { Combobox as
|
|
33
|
-
import { CheckboxGroup as
|
|
34
|
-
import { Collapsible as
|
|
35
|
-
import { Form as
|
|
36
|
-
import { Fieldset as
|
|
37
|
-
import { Menubar as
|
|
38
|
-
import { NavigationMenu as
|
|
39
|
-
import { NumberField as
|
|
40
|
-
import { OTPField as
|
|
41
|
-
import { PreviewCard as
|
|
42
|
-
import { Toolbar as
|
|
43
|
-
|
|
1
|
+
import { jsx as a, jsxs as p } from "react/jsx-runtime";
|
|
2
|
+
import { Tooltip as j } from "@base-ui/react/tooltip";
|
|
3
|
+
import { Button as bt } from "@base-ui/react/button";
|
|
4
|
+
import { forwardRef as i, useRef as ht, useCallback as at, useLayoutEffect as Lt, useState as Mt, useEffect as At, useSyncExternalStore as Dt, useContext as nt, createContext as jt } from "react";
|
|
5
|
+
import { clsx as Gt } from "clsx";
|
|
6
|
+
import { twMerge as Bt } from "tailwind-merge";
|
|
7
|
+
import { Field as Q } from "@base-ui/react/field";
|
|
8
|
+
import { PaperPlaneTilt as zt, X as xt, Check as wt, CaretUpDown as Ft, CircleNotch as Et, CaretDown as Vt, Minus as _t, Plus as Ht } from "@phosphor-icons/react";
|
|
9
|
+
import { Avatar as tt } from "@base-ui/react/avatar";
|
|
10
|
+
import { Checkbox as lt } from "@base-ui/react/checkbox";
|
|
11
|
+
import { Radio as dt } from "@base-ui/react/radio";
|
|
12
|
+
import { RadioGroup as Ot } from "@base-ui/react/radio-group";
|
|
13
|
+
import { Switch as gt } from "@base-ui/react/switch";
|
|
14
|
+
import { Slider as _ } from "@base-ui/react/slider";
|
|
15
|
+
import { Select as v } from "@base-ui/react/select";
|
|
16
|
+
import { Separator as Ut } from "@base-ui/react/separator";
|
|
17
|
+
import { Progress as et } from "@base-ui/react/progress";
|
|
18
|
+
import { Dialog as L } from "@base-ui/react/dialog";
|
|
19
|
+
import { Drawer as T } from "@base-ui/react/drawer";
|
|
20
|
+
import { Menu as G } from "@base-ui/react/menu";
|
|
21
|
+
import { Tabs as W } from "@base-ui/react/tabs";
|
|
22
|
+
import { Accordion as U } from "@base-ui/react/accordion";
|
|
23
|
+
import { ContextMenu as I } from "@base-ui/react/context-menu";
|
|
24
|
+
import { Popover as C } from "@base-ui/react/popover";
|
|
25
|
+
import { Toast as R } from "@base-ui/react/toast";
|
|
26
|
+
import { ScrollArea as E } from "@base-ui/react/scroll-area";
|
|
27
|
+
import { Toggle as Xt } from "@base-ui/react/toggle";
|
|
28
|
+
import { ToggleGroup as Yt } from "@base-ui/react/toggle-group";
|
|
29
|
+
import { Meter as H } from "@base-ui/react/meter";
|
|
30
|
+
import { AlertDialog as M } from "@base-ui/react/alert-dialog";
|
|
31
|
+
import { Autocomplete as h } from "@base-ui/react/autocomplete";
|
|
32
|
+
import { Combobox as b } from "@base-ui/react/combobox";
|
|
33
|
+
import { CheckboxGroup as Wt } from "@base-ui/react/checkbox-group";
|
|
34
|
+
import { Collapsible as st } from "@base-ui/react/collapsible";
|
|
35
|
+
import { Form as Qt } from "@base-ui/react/form";
|
|
36
|
+
import { Fieldset as vt } from "@base-ui/react/fieldset";
|
|
37
|
+
import { Menubar as Jt } from "@base-ui/react/menubar";
|
|
38
|
+
import { NavigationMenu as N } from "@base-ui/react/navigation-menu";
|
|
39
|
+
import { NumberField as D } from "@base-ui/react/number-field";
|
|
40
|
+
import { OTPField as ut } from "@base-ui/react/otp-field";
|
|
41
|
+
import { PreviewCard as z } from "@base-ui/react/preview-card";
|
|
42
|
+
import { Toolbar as F } from "@base-ui/react/toolbar";
|
|
43
|
+
function Kt(o) {
|
|
44
|
+
return o <= 0.04045 ? o / 12.92 : ((o + 0.055) / 1.055) ** 2.4;
|
|
45
|
+
}
|
|
46
|
+
function rt(o) {
|
|
47
|
+
return o <= 31308e-7 ? 12.92 * o : 1.055 * o ** (1 / 2.4) - 0.055;
|
|
48
|
+
}
|
|
49
|
+
function O(o) {
|
|
50
|
+
return Math.min(1, Math.max(0, o));
|
|
51
|
+
}
|
|
52
|
+
function J(o) {
|
|
53
|
+
const e = o.replace("#", ""), r = e.length === 3 ? e.split("").map((t) => t + t).join("") : e;
|
|
54
|
+
return [
|
|
55
|
+
parseInt(r.slice(0, 2), 16) / 255,
|
|
56
|
+
parseInt(r.slice(2, 4), 16) / 255,
|
|
57
|
+
parseInt(r.slice(4, 6), 16) / 255
|
|
58
|
+
];
|
|
59
|
+
}
|
|
60
|
+
function Nt([o, e, r]) {
|
|
61
|
+
const t = (n) => Math.round(O(n) * 255).toString(16).padStart(2, "0");
|
|
62
|
+
return `#${t(o)}${t(e)}${t(r)}`;
|
|
63
|
+
}
|
|
64
|
+
function X(o) {
|
|
65
|
+
const [e, r, t] = J(o).map(Kt), n = Math.cbrt(
|
|
66
|
+
0.4122214708 * e + 0.5363325363 * r + 0.0514459929 * t
|
|
67
|
+
), c = Math.cbrt(
|
|
68
|
+
0.2119034982 * e + 0.6806995451 * r + 0.1073969566 * t
|
|
69
|
+
), l = Math.cbrt(
|
|
70
|
+
0.0883024619 * e + 0.2817188376 * r + 0.6299787005 * t
|
|
71
|
+
), d = 0.2104542553 * n + 0.793617785 * c - 0.0040720468 * l, u = 1.9779984951 * n - 2.428592205 * c + 0.4505937099 * l, m = 0.0259040371 * n + 0.7827717662 * c - 0.808675766 * l;
|
|
72
|
+
return {
|
|
73
|
+
l: d,
|
|
74
|
+
c: Math.hypot(u, m),
|
|
75
|
+
h: (Math.atan2(m, u) * 180 / Math.PI + 360) % 360
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
function S({ l: o, c: e, h: r }) {
|
|
79
|
+
const t = e * Math.cos(r * Math.PI / 180), n = e * Math.sin(r * Math.PI / 180), c = (o + 0.3963377774 * t + 0.2158037573 * n) ** 3, l = (o - 0.1055613458 * t - 0.0638541728 * n) ** 3, d = (o - 0.0894841775 * t - 1.291485548 * n) ** 3;
|
|
80
|
+
return Nt([
|
|
81
|
+
rt(O(4.0767416621 * c - 3.3077115913 * l + 0.2309699292 * d)),
|
|
82
|
+
rt(O(-1.2684380046 * c + 2.6097574011 * l - 0.3413193965 * d)),
|
|
83
|
+
rt(O(-0.0041960863 * c - 0.7034186147 * l + 1.707614701 * d))
|
|
84
|
+
]);
|
|
85
|
+
}
|
|
86
|
+
const Zt = [0.195, 0.24, 0.27, 0.3, 0.33, 0.37, 0.43, 0.52], qt = [0.014, 0.026, 0.04, 0.052, 0.062, 0.072, 0.084, 0.1];
|
|
87
|
+
function k(o, e) {
|
|
88
|
+
const { h: r } = X(o), t = Zt.map((d, u) => S({ l: d, c: qt[u], h: r }));
|
|
89
|
+
t.push(o, e);
|
|
90
|
+
const n = X(e).l, c = Math.min(0.95, Math.max(0.84, n + 0.04)), l = Math.min(0.98, Math.max(c + 0.06, 0.93));
|
|
91
|
+
return t.push(S({ l: c, c: 0.11, h: r })), t.push(S({ l, c: 0.055, h: r })), t;
|
|
92
|
+
}
|
|
93
|
+
const te = [
|
|
94
|
+
0.187,
|
|
95
|
+
0.231,
|
|
96
|
+
0.245,
|
|
97
|
+
0.268,
|
|
98
|
+
0.289,
|
|
99
|
+
0.31,
|
|
100
|
+
0.355,
|
|
101
|
+
0.425,
|
|
102
|
+
0.52,
|
|
103
|
+
0.57,
|
|
104
|
+
0.627,
|
|
105
|
+
0.908
|
|
106
|
+
], ee = [
|
|
107
|
+
0.011,
|
|
108
|
+
0.014,
|
|
109
|
+
0.016,
|
|
110
|
+
0.019,
|
|
111
|
+
0.022,
|
|
112
|
+
0.024,
|
|
113
|
+
0.026,
|
|
114
|
+
0.026,
|
|
115
|
+
0.02,
|
|
116
|
+
0.012,
|
|
117
|
+
0,
|
|
118
|
+
8e-3
|
|
119
|
+
];
|
|
120
|
+
function Pt(o) {
|
|
121
|
+
const e = {
|
|
122
|
+
0: o.bg,
|
|
123
|
+
1: o.surface,
|
|
124
|
+
2: o.surfaceRaised,
|
|
125
|
+
5: o.border,
|
|
126
|
+
10: o.muted,
|
|
127
|
+
11: o.text
|
|
128
|
+
}, r = X(o.border).h;
|
|
129
|
+
return te.map(
|
|
130
|
+
(t, n) => e[n] ?? S({ l: t, c: ee[n], h: r })
|
|
131
|
+
);
|
|
132
|
+
}
|
|
133
|
+
function Y(o, e) {
|
|
134
|
+
const r = J(e);
|
|
135
|
+
return o.map((t) => {
|
|
136
|
+
const n = J(t);
|
|
137
|
+
let c = 0;
|
|
138
|
+
for (let g = 0; g < 3; g++) {
|
|
139
|
+
const f = n[g], P = r[g];
|
|
140
|
+
f > P ? c = Math.max(c, P < 1 ? (f - P) / (1 - P) : 0) : f < P && (c = Math.max(c, P > 0 ? (P - f) / P : 0));
|
|
141
|
+
}
|
|
142
|
+
if (c < 1e-6) return "transparent";
|
|
143
|
+
const l = Nt(
|
|
144
|
+
n.map((g, f) => O(r[f] + (g - r[f]) / c))
|
|
145
|
+
), [d, u, m] = J(l).map((g) => Math.round(g * 255));
|
|
146
|
+
return `rgb(${d} ${u} ${m} / ${(c * 100).toFixed(1)}%)`;
|
|
147
|
+
});
|
|
148
|
+
}
|
|
149
|
+
const re = [
|
|
150
|
+
0.962,
|
|
151
|
+
1,
|
|
152
|
+
0.978,
|
|
153
|
+
0.952,
|
|
154
|
+
0.928,
|
|
155
|
+
0.898,
|
|
156
|
+
0.855,
|
|
157
|
+
0.79,
|
|
158
|
+
0.66,
|
|
159
|
+
0.61,
|
|
160
|
+
0.48,
|
|
161
|
+
0.25
|
|
162
|
+
], oe = [
|
|
163
|
+
6e-3,
|
|
164
|
+
0,
|
|
165
|
+
4e-3,
|
|
166
|
+
7e-3,
|
|
167
|
+
0.01,
|
|
168
|
+
0.013,
|
|
169
|
+
0.016,
|
|
170
|
+
0.018,
|
|
171
|
+
0.016,
|
|
172
|
+
0.014,
|
|
173
|
+
0.012,
|
|
174
|
+
0.014
|
|
175
|
+
], ae = [0.975, 0.955, 0.93, 0.905, 0.878, 0.845, 0.795, 0.72], ne = [0.012, 0.024, 0.038, 0.05, 0.062, 0.074, 0.09, 0.11];
|
|
176
|
+
function Tt(o) {
|
|
177
|
+
const e = {
|
|
178
|
+
0: o.bg,
|
|
179
|
+
1: o.surface,
|
|
180
|
+
2: o.surfaceRaised,
|
|
181
|
+
5: o.border,
|
|
182
|
+
10: o.muted,
|
|
183
|
+
11: o.text
|
|
184
|
+
}, r = X(o.border).h;
|
|
185
|
+
return re.map(
|
|
186
|
+
(t, n) => e[n] ?? S({ l: t, c: oe[n], h: r })
|
|
187
|
+
);
|
|
188
|
+
}
|
|
189
|
+
function $(o) {
|
|
190
|
+
const { l: e, c: r, h: t } = X(o), n = ae.map(
|
|
191
|
+
(c, l) => S({ l: c, c: ne[l], h: t })
|
|
192
|
+
);
|
|
193
|
+
return n.push(o), n.push(S({ l: Math.max(0, e - 0.07), c: r, h: t })), n.push(S({ l: 0.5, c: 0.15, h: t })), n.push(S({ l: 0.33, c: 0.1, h: t })), n;
|
|
194
|
+
}
|
|
195
|
+
const y = {
|
|
44
196
|
color: {
|
|
45
197
|
bg: "#111318",
|
|
46
198
|
surface: "#1a1d24",
|
|
@@ -49,7 +201,7 @@ const ot = {
|
|
|
49
201
|
border: "#2b303d",
|
|
50
202
|
text: "#e0e0e6",
|
|
51
203
|
muted: "#888888",
|
|
52
|
-
accent: "#
|
|
204
|
+
accent: "#968ff8",
|
|
53
205
|
accentLight: "#b4afff",
|
|
54
206
|
secondary: "#7dd3fc",
|
|
55
207
|
secondaryLight: "#bae6fd",
|
|
@@ -68,10 +220,77 @@ const ot = {
|
|
|
68
220
|
xl: 28,
|
|
69
221
|
full: 999
|
|
70
222
|
}
|
|
223
|
+
}, K = {
|
|
224
|
+
bg: "#f1f2f7",
|
|
225
|
+
surface: "#ffffff",
|
|
226
|
+
surfaceRaised: "#f7f8fb",
|
|
227
|
+
border: "#dadde6",
|
|
228
|
+
muted: "#5b5d65",
|
|
229
|
+
text: "#1f2129"
|
|
230
|
+
}, yt = {
|
|
231
|
+
neutral: Pt({
|
|
232
|
+
bg: y.color.bg,
|
|
233
|
+
surface: y.color.surface,
|
|
234
|
+
surfaceRaised: y.color.surfaceRaised,
|
|
235
|
+
border: y.color.border,
|
|
236
|
+
muted: y.color.muted,
|
|
237
|
+
text: y.color.text
|
|
238
|
+
}),
|
|
239
|
+
accent: k(y.color.accent, y.color.accentLight),
|
|
240
|
+
secondary: k(
|
|
241
|
+
y.color.secondary,
|
|
242
|
+
y.color.secondaryLight
|
|
243
|
+
),
|
|
244
|
+
success: k(y.color.success, y.color.success),
|
|
245
|
+
danger: k(y.color.danger, y.color.dangerLight),
|
|
246
|
+
warning: k(y.color.warning, y.color.warning)
|
|
247
|
+
}, mt = {
|
|
248
|
+
neutral: Tt(K),
|
|
249
|
+
accent: $(y.color.accent),
|
|
250
|
+
secondary: $(y.color.secondary),
|
|
251
|
+
success: $(y.color.success),
|
|
252
|
+
danger: $(y.color.danger),
|
|
253
|
+
warning: $(y.color.warning)
|
|
254
|
+
}, Lo = {
|
|
255
|
+
neutral: Y(yt.neutral, y.color.bg),
|
|
256
|
+
accent: Y(yt.accent, y.color.bg)
|
|
257
|
+
}, Mo = {
|
|
258
|
+
neutral: Y(mt.neutral, K.bg),
|
|
259
|
+
accent: Y(mt.accent, K.bg)
|
|
71
260
|
};
|
|
72
|
-
function
|
|
73
|
-
const t = { ...
|
|
261
|
+
function se(o = {}) {
|
|
262
|
+
const e = o.appearance === "light", t = { ...e ? { ...y.color, ...K } : y.color, ...o.color }, n = { ...y.radius, ...o.radius }, c = {
|
|
263
|
+
bg: t.bg,
|
|
264
|
+
surface: t.surface,
|
|
265
|
+
surfaceRaised: t.surfaceRaised,
|
|
266
|
+
border: t.border,
|
|
267
|
+
muted: t.muted,
|
|
268
|
+
text: t.text
|
|
269
|
+
}, l = e ? {
|
|
270
|
+
neutral: Tt(c),
|
|
271
|
+
accent: $(t.accent),
|
|
272
|
+
secondary: $(t.secondary),
|
|
273
|
+
success: $(t.success),
|
|
274
|
+
danger: $(t.danger),
|
|
275
|
+
warning: $(t.warning)
|
|
276
|
+
} : {
|
|
277
|
+
neutral: Pt(c),
|
|
278
|
+
accent: k(t.accent, t.accentLight),
|
|
279
|
+
secondary: k(t.secondary, t.secondaryLight),
|
|
280
|
+
success: k(t.success, t.success),
|
|
281
|
+
danger: k(t.danger, t.dangerLight),
|
|
282
|
+
warning: k(t.warning, t.warning)
|
|
283
|
+
}, d = {};
|
|
284
|
+
for (const [u, m] of Object.entries(l))
|
|
285
|
+
m.forEach((g, f) => {
|
|
286
|
+
d[`--gryt-${u}-${f + 1}`] = g, d[`--color-gryt-${u}-${f + 1}`] = g;
|
|
287
|
+
});
|
|
288
|
+
for (const u of ["neutral", "accent"])
|
|
289
|
+
Y(l[u], t.bg).forEach((m, g) => {
|
|
290
|
+
d[`--gryt-${u}-a${g + 1}`] = m, d[`--color-gryt-${u}-a${g + 1}`] = m;
|
|
291
|
+
});
|
|
74
292
|
return {
|
|
293
|
+
...d,
|
|
75
294
|
"--gryt-bg": t.bg,
|
|
76
295
|
"--gryt-surface": t.surface,
|
|
77
296
|
"--gryt-surface-raised": t.surfaceRaised,
|
|
@@ -111,54 +330,54 @@ function jt(a = {}) {
|
|
|
111
330
|
"--color-gryt-on-accent": t.onAccent,
|
|
112
331
|
"--color-gryt-on-secondary": t.onSecondary,
|
|
113
332
|
"--color-gryt-on-danger": t.onDanger,
|
|
114
|
-
"--gryt-radius-sm": `${
|
|
115
|
-
"--gryt-radius-md": `${
|
|
116
|
-
"--gryt-radius-lg": `${
|
|
117
|
-
"--gryt-radius-xl": `${
|
|
118
|
-
"--gryt-radius-full": `${
|
|
333
|
+
"--gryt-radius-sm": `${n.sm}px`,
|
|
334
|
+
"--gryt-radius-md": `${n.md}px`,
|
|
335
|
+
"--gryt-radius-lg": `${n.lg}px`,
|
|
336
|
+
"--gryt-radius-xl": `${n.xl}px`,
|
|
337
|
+
"--gryt-radius-full": `${n.full}px`
|
|
119
338
|
};
|
|
120
339
|
}
|
|
121
|
-
function
|
|
122
|
-
return Object.keys(
|
|
340
|
+
function ie(o) {
|
|
341
|
+
return Object.keys(o).some((e) => e.startsWith("--"));
|
|
123
342
|
}
|
|
124
|
-
function
|
|
125
|
-
children:
|
|
126
|
-
className:
|
|
127
|
-
theme:
|
|
128
|
-
tooltipDelay:
|
|
343
|
+
function Ao({
|
|
344
|
+
children: o,
|
|
345
|
+
className: e,
|
|
346
|
+
theme: r,
|
|
347
|
+
tooltipDelay: t = 400
|
|
129
348
|
}) {
|
|
130
|
-
const
|
|
131
|
-
return /* @__PURE__ */
|
|
349
|
+
const n = r && ie(r) ? r : se(r ?? {});
|
|
350
|
+
return /* @__PURE__ */ a("div", { className: e, style: n, children: /* @__PURE__ */ a(j.Provider, { delay: t, children: o }) });
|
|
132
351
|
}
|
|
133
|
-
function
|
|
134
|
-
return
|
|
352
|
+
function s(...o) {
|
|
353
|
+
return Bt(Gt(o));
|
|
135
354
|
}
|
|
136
|
-
const
|
|
355
|
+
const ce = {
|
|
137
356
|
primary: "bg-gryt-accent text-gryt-on-accent hover:not-data-disabled:bg-gryt-accent-light",
|
|
138
357
|
secondary: "bg-gryt-secondary text-gryt-on-secondary hover:not-data-disabled:bg-gryt-secondary-light",
|
|
139
358
|
neutral: "bg-gryt-surface-raised text-gryt-text hover:not-data-disabled:bg-gryt-surface-hover",
|
|
140
359
|
danger: "bg-gryt-danger text-gryt-on-danger hover:not-data-disabled:bg-gryt-danger-light",
|
|
141
360
|
ghost: "bg-transparent text-gryt-muted hover:not-data-disabled:bg-white/8 hover:not-data-disabled:text-gryt-text"
|
|
142
|
-
},
|
|
361
|
+
}, le = {
|
|
143
362
|
xsmall: "min-h-8 px-3 text-xs",
|
|
144
363
|
small: "min-h-9 px-4 text-sm",
|
|
145
364
|
medium: "min-h-10 px-5 text-sm",
|
|
146
365
|
large: "min-h-12 px-6 text-base"
|
|
147
|
-
},
|
|
366
|
+
}, de = i(
|
|
148
367
|
function({
|
|
149
|
-
children:
|
|
150
|
-
className:
|
|
151
|
-
endIcon:
|
|
152
|
-
size:
|
|
368
|
+
children: e,
|
|
369
|
+
className: r,
|
|
370
|
+
endIcon: t,
|
|
371
|
+
size: n = "medium",
|
|
153
372
|
startIcon: c,
|
|
154
373
|
tone: l = "primary",
|
|
155
|
-
...
|
|
374
|
+
...d
|
|
156
375
|
}, u) {
|
|
157
|
-
return /* @__PURE__ */
|
|
158
|
-
|
|
376
|
+
return /* @__PURE__ */ p(
|
|
377
|
+
bt,
|
|
159
378
|
{
|
|
160
379
|
ref: u,
|
|
161
|
-
className:
|
|
380
|
+
className: s(
|
|
162
381
|
"gryt-button",
|
|
163
382
|
"inline-flex items-center justify-center gap-2 border-0 shadow-none",
|
|
164
383
|
"rounded-(--gryt-radius-full) font-semibold whitespace-nowrap select-none",
|
|
@@ -169,378 +388,393 @@ const Bt = {
|
|
|
169
388
|
"duration-(--gryt-dur-spring) ease-spring",
|
|
170
389
|
// Press travels further than hover, so the button reads as being
|
|
171
390
|
// pushed down rather than just acknowledging the cursor.
|
|
172
|
-
|
|
173
|
-
|
|
391
|
+
// A button that opens something does not grow under the cursor.
|
|
392
|
+
// Base UI positions the popup against the trigger's measured box, and
|
|
393
|
+
// it keeps measuring while the popup is open — so a trigger that
|
|
394
|
+
// scales on hover drags its own menu a pixel or two sideways every
|
|
395
|
+
// time the pointer crosses it. aria-haspopup is how the trigger says
|
|
396
|
+
// that is what it is; Base UI puts it there, nothing to pass.
|
|
397
|
+
"motion-safe:not-[[aria-haspopup]]:hover:not-data-disabled:scale-[1.03]",
|
|
398
|
+
"motion-safe:not-[[aria-haspopup]]:active:not-data-disabled:scale-[0.96]",
|
|
174
399
|
"focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-gryt-accent-light",
|
|
175
400
|
"data-disabled:cursor-not-allowed data-disabled:opacity-50",
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
401
|
+
le[n],
|
|
402
|
+
ce[l],
|
|
403
|
+
r
|
|
179
404
|
),
|
|
180
|
-
...
|
|
405
|
+
...d,
|
|
181
406
|
children: [
|
|
182
407
|
c,
|
|
183
|
-
|
|
184
|
-
|
|
408
|
+
e,
|
|
409
|
+
t
|
|
185
410
|
]
|
|
186
411
|
}
|
|
187
412
|
);
|
|
188
413
|
}
|
|
189
|
-
),
|
|
414
|
+
), x = "focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-gryt-accent-light", ge = "has-[:focus-visible]:outline-2 has-[:focus-visible]:outline-offset-2 has-[:focus-visible]:outline-gryt-accent-light", kt = [
|
|
415
|
+
"w-full rounded-(--gryt-radius-xl) border bg-gryt-surface-raised",
|
|
416
|
+
"text-gryt-text outline-none placeholder:text-gryt-muted",
|
|
417
|
+
"transition-colors duration-150 motion-reduce:transition-none",
|
|
418
|
+
"hover:border-gryt-accent-light focus:border-gryt-accent",
|
|
419
|
+
"disabled:cursor-not-allowed disabled:opacity-60"
|
|
420
|
+
].join(" "), $t = {
|
|
421
|
+
small: "min-h-9 px-3 py-1.5 text-sm",
|
|
422
|
+
medium: "min-h-11 px-4 py-2.5 text-sm"
|
|
423
|
+
}, B = "rounded-(--gryt-radius-xl) border border-gryt-border bg-gryt-surface text-gryt-text", A = [
|
|
190
424
|
// scale and translate are named explicitly because Tailwind v4 sets them as
|
|
191
425
|
// standalone CSS properties rather than folding them into `transform`, so
|
|
192
426
|
// transitioning `transform` would leave the popup snapping into place.
|
|
193
427
|
"transition-[opacity,scale,translate] duration-(--gryt-dur-spring) ease-spring motion-reduce:transition-none",
|
|
194
428
|
"data-starting-style:scale-[0.98] data-starting-style:opacity-0",
|
|
195
429
|
"data-ending-style:scale-[0.98] data-ending-style:opacity-0"
|
|
196
|
-
].join(" "),
|
|
430
|
+
].join(" "), V = "data-disabled:cursor-not-allowed data-disabled:opacity-50", ue = {
|
|
197
431
|
primary: "data-checked:bg-gryt-accent data-checked:text-gryt-on-accent",
|
|
198
432
|
secondary: "data-checked:bg-gryt-secondary data-checked:text-gryt-on-secondary",
|
|
199
433
|
neutral: "data-checked:bg-gryt-surface-hover data-checked:text-gryt-text",
|
|
200
434
|
danger: "data-checked:bg-gryt-danger data-checked:text-gryt-on-danger",
|
|
201
435
|
success: "data-checked:bg-gryt-success data-checked:text-gryt-on-accent",
|
|
202
436
|
warning: "data-checked:bg-gryt-warning data-checked:text-gryt-on-accent"
|
|
203
|
-
},
|
|
437
|
+
}, Ct = {
|
|
204
438
|
primary: "bg-gryt-accent",
|
|
205
439
|
secondary: "bg-gryt-secondary",
|
|
206
440
|
neutral: "bg-gryt-surface-hover",
|
|
207
441
|
danger: "bg-gryt-danger",
|
|
208
442
|
success: "bg-gryt-success",
|
|
209
443
|
warning: "bg-gryt-warning"
|
|
210
|
-
},
|
|
444
|
+
}, ye = {
|
|
211
445
|
primary: "data-checked:border-gryt-accent",
|
|
212
446
|
secondary: "data-checked:border-gryt-secondary",
|
|
213
447
|
neutral: "data-checked:border-gryt-muted",
|
|
214
448
|
danger: "data-checked:border-gryt-danger",
|
|
215
449
|
success: "data-checked:border-gryt-success",
|
|
216
450
|
warning: "data-checked:border-gryt-warning"
|
|
217
|
-
},
|
|
451
|
+
}, me = {
|
|
218
452
|
primary: "data-checked:bg-gryt-accent",
|
|
219
453
|
secondary: "data-checked:bg-gryt-secondary",
|
|
220
454
|
neutral: "data-checked:bg-gryt-surface-hover",
|
|
221
455
|
danger: "data-checked:bg-gryt-danger",
|
|
222
456
|
success: "data-checked:bg-gryt-success",
|
|
223
457
|
warning: "data-checked:bg-gryt-warning"
|
|
224
|
-
},
|
|
458
|
+
}, pe = {
|
|
225
459
|
primary: "text-gryt-accent hover:not-data-disabled:bg-gryt-accent/10",
|
|
226
460
|
secondary: "text-gryt-secondary hover:not-data-disabled:bg-gryt-secondary/10",
|
|
227
461
|
neutral: "text-gryt-muted hover:not-data-disabled:bg-white/8 hover:not-data-disabled:text-gryt-text",
|
|
228
462
|
danger: "text-gryt-danger hover:not-data-disabled:bg-gryt-danger/10",
|
|
229
463
|
ghost: "text-gryt-muted hover:not-data-disabled:bg-white/8 hover:not-data-disabled:text-gryt-text"
|
|
230
|
-
},
|
|
464
|
+
}, fe = {
|
|
231
465
|
xsmall: "h-8 w-8",
|
|
232
466
|
small: "h-9 w-9",
|
|
233
467
|
medium: "h-10 w-10",
|
|
234
468
|
large: "h-12 w-12"
|
|
235
|
-
},
|
|
236
|
-
function({ className:
|
|
237
|
-
return /* @__PURE__ */
|
|
238
|
-
|
|
469
|
+
}, Do = i(
|
|
470
|
+
function({ className: e, size: r = "medium", tone: t = "neutral", ...n }, c) {
|
|
471
|
+
return /* @__PURE__ */ a(
|
|
472
|
+
bt,
|
|
239
473
|
{
|
|
240
474
|
ref: c,
|
|
241
|
-
className:
|
|
475
|
+
className: s(
|
|
242
476
|
"gryt-icon-button",
|
|
243
477
|
"inline-flex shrink-0 items-center justify-center border-0 bg-transparent p-0",
|
|
244
478
|
"rounded-(--gryt-radius-full) select-none",
|
|
245
479
|
// scale rather than transform — see the note in Button.
|
|
246
480
|
"transition-[scale,background-color,color] duration-(--gryt-dur-spring) ease-spring",
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
481
|
+
// A button that opens something does not grow under the cursor.
|
|
482
|
+
// Base UI positions the popup against the trigger's measured box, and
|
|
483
|
+
// it keeps measuring while the popup is open — so a trigger that
|
|
484
|
+
// scales on hover drags its own menu a pixel or two sideways every
|
|
485
|
+
// time the pointer crosses it. aria-haspopup is how the trigger says
|
|
486
|
+
// that is what it is; Base UI puts it there, nothing to pass.
|
|
487
|
+
"motion-safe:not-[[aria-haspopup]]:hover:not-data-disabled:scale-[1.06]",
|
|
488
|
+
"motion-safe:not-[[aria-haspopup]]:active:not-data-disabled:scale-[0.94]",
|
|
489
|
+
x,
|
|
490
|
+
V,
|
|
491
|
+
fe[r],
|
|
492
|
+
pe[t],
|
|
493
|
+
e
|
|
254
494
|
),
|
|
255
|
-
...
|
|
495
|
+
...n
|
|
256
496
|
}
|
|
257
497
|
);
|
|
258
498
|
}
|
|
259
|
-
),
|
|
260
|
-
function({ className:
|
|
261
|
-
return /* @__PURE__ */
|
|
499
|
+
), jo = i(
|
|
500
|
+
function({ className: e, elevated: r = !1, ...t }, n) {
|
|
501
|
+
return /* @__PURE__ */ a(
|
|
262
502
|
"div",
|
|
263
503
|
{
|
|
264
|
-
ref:
|
|
265
|
-
className:
|
|
504
|
+
ref: n,
|
|
505
|
+
className: s(
|
|
266
506
|
"gryt-surface rounded-(--gryt-radius-lg) border border-gryt-border p-4 text-gryt-text",
|
|
267
|
-
|
|
268
|
-
|
|
507
|
+
r ? "bg-gryt-surface-raised" : "bg-gryt-surface",
|
|
508
|
+
e
|
|
269
509
|
),
|
|
270
|
-
...
|
|
510
|
+
...t
|
|
271
511
|
}
|
|
272
512
|
);
|
|
273
513
|
}
|
|
274
|
-
),
|
|
275
|
-
function({ children:
|
|
276
|
-
return /* @__PURE__ */
|
|
514
|
+
), Go = i(
|
|
515
|
+
function({ children: e, className: r, from: t = "assistant", ...n }, c) {
|
|
516
|
+
return /* @__PURE__ */ a(
|
|
277
517
|
"div",
|
|
278
518
|
{
|
|
279
519
|
ref: c,
|
|
280
|
-
className:
|
|
520
|
+
className: s(
|
|
281
521
|
"gryt-message-bubble",
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
522
|
+
t === "user" && "ml-auto bg-gryt-accent text-gryt-on-accent",
|
|
523
|
+
t === "assistant" && "mr-auto border border-gryt-border bg-gryt-surface text-gryt-text",
|
|
524
|
+
t === "system" && "mx-auto border border-dashed border-gryt-border bg-transparent text-gryt-muted",
|
|
525
|
+
r
|
|
286
526
|
),
|
|
287
|
-
...
|
|
288
|
-
children:
|
|
527
|
+
...n,
|
|
528
|
+
children: e
|
|
289
529
|
}
|
|
290
530
|
);
|
|
291
531
|
}
|
|
292
|
-
),
|
|
293
|
-
small: "min-h-9 px-3 py-1.5 text-sm",
|
|
294
|
-
medium: "min-h-11 px-4 py-2.5 text-sm"
|
|
295
|
-
}, lo = s(
|
|
532
|
+
), Bo = i(
|
|
296
533
|
function({
|
|
297
|
-
className:
|
|
298
|
-
error:
|
|
299
|
-
fieldClassName:
|
|
300
|
-
helperText:
|
|
534
|
+
className: e,
|
|
535
|
+
error: r = !1,
|
|
536
|
+
fieldClassName: t,
|
|
537
|
+
helperText: n,
|
|
301
538
|
label: c,
|
|
302
539
|
minRows: l = 3,
|
|
303
|
-
multiline:
|
|
540
|
+
multiline: d = !1,
|
|
304
541
|
size: u = "medium",
|
|
305
|
-
...
|
|
306
|
-
},
|
|
307
|
-
const
|
|
308
|
-
|
|
542
|
+
...m
|
|
543
|
+
}, g) {
|
|
544
|
+
const f = /* @__PURE__ */ a(
|
|
545
|
+
Q.Control,
|
|
309
546
|
{
|
|
310
|
-
ref:
|
|
311
|
-
render:
|
|
312
|
-
className:
|
|
313
|
-
"gryt-text-field-control
|
|
314
|
-
|
|
315
|
-
"
|
|
316
|
-
"
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
e ? "border-gryt-danger" : "border-gryt-border",
|
|
320
|
-
Yt[u],
|
|
321
|
-
t
|
|
547
|
+
ref: g,
|
|
548
|
+
render: d ? /* @__PURE__ */ a("textarea", { rows: l }) : void 0,
|
|
549
|
+
className: s(
|
|
550
|
+
"gryt-text-field-control",
|
|
551
|
+
kt,
|
|
552
|
+
d && "resize-y leading-6",
|
|
553
|
+
r ? "border-gryt-danger" : "border-gryt-border",
|
|
554
|
+
$t[u],
|
|
555
|
+
e
|
|
322
556
|
),
|
|
323
|
-
...
|
|
557
|
+
...m
|
|
324
558
|
}
|
|
325
559
|
);
|
|
326
|
-
return /* @__PURE__ */
|
|
327
|
-
|
|
560
|
+
return /* @__PURE__ */ p(
|
|
561
|
+
Q.Root,
|
|
328
562
|
{
|
|
329
|
-
className:
|
|
563
|
+
className: s(
|
|
330
564
|
"gryt-text-field flex w-full flex-col gap-1.5",
|
|
331
|
-
|
|
565
|
+
t
|
|
332
566
|
),
|
|
333
567
|
children: [
|
|
334
|
-
c ? /* @__PURE__ */
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
568
|
+
c ? /* @__PURE__ */ a(Q.Label, { className: "text-xs font-medium text-gryt-muted", children: c }) : null,
|
|
569
|
+
f,
|
|
570
|
+
n ? /* @__PURE__ */ a(
|
|
571
|
+
Q.Description,
|
|
338
572
|
{
|
|
339
|
-
className:
|
|
573
|
+
className: s(
|
|
340
574
|
"text-xs",
|
|
341
|
-
|
|
575
|
+
r ? "text-gryt-danger" : "text-gryt-muted"
|
|
342
576
|
),
|
|
343
|
-
children:
|
|
577
|
+
children: n
|
|
344
578
|
}
|
|
345
579
|
) : null
|
|
346
580
|
]
|
|
347
581
|
}
|
|
348
582
|
);
|
|
349
583
|
}
|
|
350
|
-
),
|
|
584
|
+
), zo = i(
|
|
351
585
|
function({
|
|
352
|
-
className:
|
|
353
|
-
disabled:
|
|
354
|
-
maxRows:
|
|
355
|
-
minRows:
|
|
586
|
+
className: e,
|
|
587
|
+
disabled: r = !1,
|
|
588
|
+
maxRows: t = 8,
|
|
589
|
+
minRows: n = 1,
|
|
356
590
|
onSubmit: c,
|
|
357
591
|
placeholder: l = "Message Gryt",
|
|
358
|
-
submitLabel:
|
|
592
|
+
submitLabel: d = "Send",
|
|
359
593
|
...u
|
|
360
|
-
},
|
|
361
|
-
const
|
|
362
|
-
const
|
|
363
|
-
if (!
|
|
594
|
+
}, m) {
|
|
595
|
+
const g = ht(null), f = at(() => {
|
|
596
|
+
const w = g.current;
|
|
597
|
+
if (!w)
|
|
364
598
|
return;
|
|
365
|
-
const
|
|
366
|
-
|
|
367
|
-
Math.max(
|
|
368
|
-
|
|
599
|
+
const q = window.getComputedStyle(w), it = parseFloat(q.lineHeight) || 24, ct = parseFloat(q.paddingTop) + parseFloat(q.paddingBottom);
|
|
600
|
+
w.style.height = "auto", w.style.height = `${Math.min(
|
|
601
|
+
Math.max(w.scrollHeight, it * n + ct),
|
|
602
|
+
it * t + ct
|
|
369
603
|
)}px`;
|
|
370
|
-
}, [
|
|
371
|
-
|
|
372
|
-
function
|
|
604
|
+
}, [t, n]);
|
|
605
|
+
Lt(f, [f, u.value]);
|
|
606
|
+
function P(w) {
|
|
373
607
|
if (!c) {
|
|
374
|
-
|
|
608
|
+
w.preventDefault();
|
|
375
609
|
return;
|
|
376
610
|
}
|
|
377
|
-
c(
|
|
611
|
+
c(w);
|
|
378
612
|
}
|
|
379
|
-
return /* @__PURE__ */
|
|
380
|
-
/* @__PURE__ */
|
|
613
|
+
return /* @__PURE__ */ p("form", { className: s("gryt-composer", e), onSubmit: P, children: [
|
|
614
|
+
/* @__PURE__ */ a(
|
|
381
615
|
"textarea",
|
|
382
616
|
{
|
|
383
|
-
ref: (
|
|
384
|
-
|
|
617
|
+
ref: (w) => {
|
|
618
|
+
g.current = w, typeof m == "function" ? m(w) : m && (m.current = w);
|
|
385
619
|
},
|
|
386
|
-
rows:
|
|
387
|
-
disabled:
|
|
620
|
+
rows: n,
|
|
621
|
+
disabled: r,
|
|
388
622
|
placeholder: l,
|
|
389
|
-
onInput:
|
|
623
|
+
onInput: f,
|
|
390
624
|
className: "gryt-composer-textarea disabled:cursor-not-allowed disabled:opacity-60",
|
|
391
625
|
...u
|
|
392
626
|
}
|
|
393
627
|
),
|
|
394
|
-
/* @__PURE__ */
|
|
395
|
-
|
|
628
|
+
/* @__PURE__ */ a(
|
|
629
|
+
de,
|
|
396
630
|
{
|
|
397
631
|
type: "submit",
|
|
398
|
-
disabled:
|
|
632
|
+
disabled: r,
|
|
399
633
|
size: "small",
|
|
400
|
-
endIcon: /* @__PURE__ */
|
|
401
|
-
children:
|
|
634
|
+
endIcon: /* @__PURE__ */ a(zt, { size: 14, weight: "fill" }),
|
|
635
|
+
children: d
|
|
402
636
|
}
|
|
403
637
|
)
|
|
404
638
|
] });
|
|
405
639
|
}
|
|
406
|
-
),
|
|
640
|
+
), be = {
|
|
407
641
|
small: "h-8 w-8 text-xs",
|
|
408
642
|
medium: "h-10 w-10 text-sm",
|
|
409
643
|
large: "h-12 w-12 text-base"
|
|
410
|
-
},
|
|
411
|
-
return /* @__PURE__ */
|
|
412
|
-
|
|
644
|
+
}, he = i(function({ alt: e, children: r, className: t, fallback: n, size: c = "medium", src: l, ...d }, u) {
|
|
645
|
+
return /* @__PURE__ */ p(
|
|
646
|
+
tt.Root,
|
|
413
647
|
{
|
|
414
648
|
ref: u,
|
|
415
|
-
className:
|
|
649
|
+
className: s(
|
|
416
650
|
"gryt-avatar inline-flex shrink-0 items-center justify-center overflow-hidden align-middle select-none",
|
|
417
651
|
"rounded-(--gryt-radius-full) bg-gryt-surface-raised font-medium text-gryt-text ring-1 ring-gryt-border",
|
|
418
|
-
|
|
419
|
-
|
|
652
|
+
be[c],
|
|
653
|
+
t
|
|
420
654
|
),
|
|
421
|
-
...
|
|
655
|
+
...d,
|
|
422
656
|
children: [
|
|
423
|
-
l ? /* @__PURE__ */
|
|
424
|
-
|
|
657
|
+
l ? /* @__PURE__ */ a(
|
|
658
|
+
tt.Image,
|
|
425
659
|
{
|
|
426
660
|
src: l,
|
|
427
|
-
alt:
|
|
661
|
+
alt: e,
|
|
428
662
|
className: "h-full w-full object-cover"
|
|
429
663
|
}
|
|
430
664
|
) : null,
|
|
431
|
-
/* @__PURE__ */
|
|
665
|
+
/* @__PURE__ */ a(tt.Fallback, { className: "flex h-full w-full items-center justify-center", children: n ?? r })
|
|
432
666
|
]
|
|
433
667
|
}
|
|
434
668
|
);
|
|
435
|
-
}),
|
|
436
|
-
return /* @__PURE__ */
|
|
669
|
+
}), Fo = i(function({ active: e = !1, avatar: r, className: t, subtitle: n, title: c, ...l }, d) {
|
|
670
|
+
return /* @__PURE__ */ p(
|
|
437
671
|
"button",
|
|
438
672
|
{
|
|
439
|
-
ref:
|
|
673
|
+
ref: d,
|
|
440
674
|
type: "button",
|
|
441
|
-
className:
|
|
675
|
+
className: s(
|
|
442
676
|
"gryt-conversation-item",
|
|
443
|
-
|
|
444
|
-
|
|
677
|
+
e ? "bg-gryt-accent text-gryt-on-accent" : "text-gryt-text hover:bg-white/5",
|
|
678
|
+
t
|
|
445
679
|
),
|
|
446
680
|
...l,
|
|
447
681
|
children: [
|
|
448
|
-
|
|
449
|
-
|
|
682
|
+
r ?? /* @__PURE__ */ a(
|
|
683
|
+
he,
|
|
450
684
|
{
|
|
451
685
|
size: "small",
|
|
452
|
-
className:
|
|
453
|
-
|
|
686
|
+
className: s(
|
|
687
|
+
e ? "bg-gryt-on-accent text-gryt-accent ring-transparent" : "bg-gryt-surface-raised text-gryt-text"
|
|
454
688
|
),
|
|
455
689
|
children: c.slice(0, 1).toUpperCase()
|
|
456
690
|
}
|
|
457
691
|
),
|
|
458
|
-
/* @__PURE__ */
|
|
459
|
-
/* @__PURE__ */
|
|
460
|
-
|
|
692
|
+
/* @__PURE__ */ p("span", { className: "min-w-0 flex-1", children: [
|
|
693
|
+
/* @__PURE__ */ a("span", { className: "block truncate text-sm font-semibold", children: c }),
|
|
694
|
+
n ? /* @__PURE__ */ a(
|
|
461
695
|
"span",
|
|
462
696
|
{
|
|
463
|
-
className:
|
|
697
|
+
className: s(
|
|
464
698
|
"block truncate text-xs",
|
|
465
|
-
|
|
699
|
+
e ? "text-gryt-on-accent/70" : "text-gryt-muted"
|
|
466
700
|
),
|
|
467
|
-
children:
|
|
701
|
+
children: n
|
|
468
702
|
}
|
|
469
703
|
) : null
|
|
470
704
|
] })
|
|
471
705
|
]
|
|
472
706
|
}
|
|
473
707
|
);
|
|
474
|
-
}),
|
|
475
|
-
const u = typeof
|
|
476
|
-
return /* @__PURE__ */
|
|
708
|
+
}), Eo = i(function({ badgeContent: e, children: r, className: t, max: n = 99, showZero: c = !1, ...l }, d) {
|
|
709
|
+
const u = typeof e == "number" ? e : null, m = u !== null && u === 0 && !c, g = u !== null && u > n ? `${n}+` : e;
|
|
710
|
+
return /* @__PURE__ */ p(
|
|
477
711
|
"span",
|
|
478
712
|
{
|
|
479
|
-
ref:
|
|
480
|
-
className:
|
|
713
|
+
ref: d,
|
|
714
|
+
className: s("gryt-badge relative inline-flex", t),
|
|
481
715
|
...l,
|
|
482
716
|
children: [
|
|
483
|
-
|
|
484
|
-
|
|
717
|
+
r,
|
|
718
|
+
e !== void 0 && !m ? /* @__PURE__ */ a(
|
|
485
719
|
"span",
|
|
486
720
|
{
|
|
487
|
-
className:
|
|
721
|
+
className: s(
|
|
488
722
|
"gryt-badge-dot absolute -top-1 -right-1 z-10 inline-flex items-center justify-center",
|
|
489
723
|
"min-w-5 rounded-(--gryt-radius-full) px-1.5 py-0.5",
|
|
490
724
|
"bg-gryt-accent text-[0.65rem] leading-none font-semibold text-gryt-on-accent",
|
|
491
725
|
"ring-2 ring-gryt-bg"
|
|
492
726
|
),
|
|
493
|
-
children:
|
|
727
|
+
children: g
|
|
494
728
|
}
|
|
495
729
|
) : null
|
|
496
730
|
]
|
|
497
731
|
}
|
|
498
732
|
);
|
|
499
|
-
}),
|
|
733
|
+
}), xe = {
|
|
500
734
|
neutral: "border-gryt-border bg-gryt-surface-raised text-gryt-text",
|
|
501
735
|
primary: "border-gryt-accent/40 bg-gryt-accent/12 text-gryt-accent",
|
|
502
736
|
secondary: "border-gryt-secondary/40 bg-gryt-secondary/12 text-gryt-secondary",
|
|
503
737
|
success: "border-gryt-success/40 bg-gryt-success/12 text-gryt-success",
|
|
504
738
|
warning: "border-gryt-warning/40 bg-gryt-warning/12 text-gryt-warning",
|
|
505
739
|
danger: "border-gryt-danger/40 bg-gryt-danger/12 text-gryt-danger"
|
|
506
|
-
},
|
|
507
|
-
return /* @__PURE__ */
|
|
740
|
+
}, Vo = i(function({ children: e, className: r, icon: t, label: n, onDelete: c, tone: l = "neutral", ...d }, u) {
|
|
741
|
+
return /* @__PURE__ */ p(
|
|
508
742
|
"span",
|
|
509
743
|
{
|
|
510
744
|
ref: u,
|
|
511
|
-
className:
|
|
745
|
+
className: s(
|
|
512
746
|
"gryt-chip inline-flex items-center gap-1.5 rounded-(--gryt-radius-full) border px-3 py-1 text-xs font-medium",
|
|
513
|
-
|
|
514
|
-
|
|
747
|
+
xe[l],
|
|
748
|
+
r
|
|
515
749
|
),
|
|
516
|
-
...
|
|
750
|
+
...d,
|
|
517
751
|
children: [
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
c ? /* @__PURE__ */
|
|
752
|
+
t,
|
|
753
|
+
n ?? e,
|
|
754
|
+
c ? /* @__PURE__ */ a(
|
|
521
755
|
"button",
|
|
522
756
|
{
|
|
523
757
|
type: "button",
|
|
524
758
|
"aria-label": "Remove",
|
|
525
759
|
onClick: c,
|
|
526
|
-
className:
|
|
760
|
+
className: s(
|
|
527
761
|
"-mr-1 inline-flex h-4 w-4 items-center justify-center rounded-(--gryt-radius-full)",
|
|
528
762
|
"opacity-70 transition-opacity hover:opacity-100",
|
|
529
|
-
|
|
763
|
+
x
|
|
530
764
|
),
|
|
531
|
-
children: /* @__PURE__ */
|
|
765
|
+
children: /* @__PURE__ */ a(xt, { size: 10, weight: "bold", "aria-hidden": "true" })
|
|
532
766
|
}
|
|
533
767
|
) : null
|
|
534
768
|
]
|
|
535
769
|
}
|
|
536
770
|
);
|
|
537
|
-
}),
|
|
538
|
-
function({ className:
|
|
539
|
-
return /* @__PURE__ */
|
|
540
|
-
|
|
771
|
+
}), _o = i(
|
|
772
|
+
function({ className: e, tone: r = "primary", ...t }, n) {
|
|
773
|
+
return /* @__PURE__ */ a(
|
|
774
|
+
lt.Root,
|
|
541
775
|
{
|
|
542
|
-
ref:
|
|
543
|
-
className:
|
|
776
|
+
ref: n,
|
|
777
|
+
className: s(
|
|
544
778
|
"gryt-checkbox flex h-5 w-5 shrink-0 items-center justify-center",
|
|
545
779
|
"rounded-(--gryt-radius-sm) border border-gryt-border bg-gryt-surface-raised",
|
|
546
780
|
"transition-[scale,background-color,border-color] duration-(--gryt-dur-spring) ease-spring",
|
|
@@ -550,18 +784,18 @@ const Bt = {
|
|
|
550
784
|
"hover:not-data-disabled:border-gryt-accent-light",
|
|
551
785
|
"motion-safe:hover:not-data-disabled:scale-[1.08]",
|
|
552
786
|
"motion-safe:active:not-data-disabled:scale-[0.92]",
|
|
553
|
-
|
|
554
|
-
|
|
787
|
+
x,
|
|
788
|
+
V,
|
|
555
789
|
// Unchecked stays a neutral outline; the tone only paints once checked.
|
|
556
|
-
|
|
557
|
-
|
|
790
|
+
ue[r],
|
|
791
|
+
e
|
|
558
792
|
),
|
|
559
|
-
...
|
|
560
|
-
children: /* @__PURE__ */
|
|
561
|
-
|
|
793
|
+
...t,
|
|
794
|
+
children: /* @__PURE__ */ a(
|
|
795
|
+
lt.Indicator,
|
|
562
796
|
{
|
|
563
797
|
keepMounted: !0,
|
|
564
|
-
className:
|
|
798
|
+
className: s(
|
|
565
799
|
"flex origin-center",
|
|
566
800
|
"transition-[scale,opacity] duration-(--gryt-dur-spring) ease-spring",
|
|
567
801
|
// Scaling from 0 rather than from something near 1 is deliberate.
|
|
@@ -571,65 +805,65 @@ const Bt = {
|
|
|
571
805
|
"data-unchecked:scale-0 data-unchecked:opacity-0",
|
|
572
806
|
"motion-reduce:transition-none"
|
|
573
807
|
),
|
|
574
|
-
children: /* @__PURE__ */
|
|
808
|
+
children: /* @__PURE__ */ a(wt, { size: 12, weight: "bold" })
|
|
575
809
|
}
|
|
576
810
|
)
|
|
577
811
|
}
|
|
578
812
|
);
|
|
579
813
|
}
|
|
580
|
-
),
|
|
581
|
-
return /* @__PURE__ */
|
|
582
|
-
|
|
814
|
+
), Ho = i(function({ className: e, tone: r = "primary", ...t }, n) {
|
|
815
|
+
return /* @__PURE__ */ a(
|
|
816
|
+
dt.Root,
|
|
583
817
|
{
|
|
584
|
-
ref:
|
|
585
|
-
className:
|
|
818
|
+
ref: n,
|
|
819
|
+
className: s(
|
|
586
820
|
"gryt-radio flex h-5 w-5 shrink-0 items-center justify-center",
|
|
587
821
|
"rounded-(--gryt-radius-full) border border-gryt-border bg-gryt-surface-raised",
|
|
588
822
|
"transition-[scale,background-color,border-color] duration-(--gryt-dur-spring) ease-spring",
|
|
589
823
|
"hover:not-data-disabled:border-gryt-accent-light",
|
|
590
824
|
"motion-safe:hover:not-data-disabled:scale-[1.08]",
|
|
591
825
|
"motion-safe:active:not-data-disabled:scale-[0.92]",
|
|
592
|
-
|
|
593
|
-
|
|
826
|
+
x,
|
|
827
|
+
V,
|
|
594
828
|
// Border takes the tone when selected; the dot inside carries the fill.
|
|
595
|
-
|
|
596
|
-
|
|
829
|
+
ye[r],
|
|
830
|
+
e
|
|
597
831
|
),
|
|
598
|
-
...
|
|
599
|
-
children: /* @__PURE__ */
|
|
600
|
-
|
|
832
|
+
...t,
|
|
833
|
+
children: /* @__PURE__ */ a(
|
|
834
|
+
dt.Indicator,
|
|
601
835
|
{
|
|
602
836
|
keepMounted: !0,
|
|
603
|
-
className:
|
|
837
|
+
className: s(
|
|
604
838
|
"h-2.5 w-2.5 origin-center rounded-(--gryt-radius-full)",
|
|
605
839
|
"transition-[scale,opacity] duration-(--gryt-dur-spring) ease-spring",
|
|
606
840
|
// From 0, for the same reason as the Checkbox tick — see the note there.
|
|
607
841
|
"data-unchecked:scale-0 data-unchecked:opacity-0",
|
|
608
842
|
"motion-reduce:transition-none",
|
|
609
|
-
|
|
843
|
+
Ct[r]
|
|
610
844
|
)
|
|
611
845
|
}
|
|
612
846
|
)
|
|
613
847
|
}
|
|
614
848
|
);
|
|
615
|
-
}),
|
|
616
|
-
function({ className:
|
|
617
|
-
return /* @__PURE__ */
|
|
618
|
-
|
|
849
|
+
}), Oo = i(
|
|
850
|
+
function({ className: e, ...r }, t) {
|
|
851
|
+
return /* @__PURE__ */ a(
|
|
852
|
+
Ot,
|
|
619
853
|
{
|
|
620
|
-
ref:
|
|
621
|
-
className:
|
|
622
|
-
...
|
|
854
|
+
ref: t,
|
|
855
|
+
className: s("gryt-radio-group flex flex-col gap-2", e),
|
|
856
|
+
...r
|
|
623
857
|
}
|
|
624
858
|
);
|
|
625
859
|
}
|
|
626
|
-
),
|
|
627
|
-
function({ className:
|
|
628
|
-
return /* @__PURE__ */
|
|
629
|
-
|
|
860
|
+
), Uo = i(
|
|
861
|
+
function({ className: e, tone: r = "primary", ...t }, n) {
|
|
862
|
+
return /* @__PURE__ */ a(
|
|
863
|
+
gt.Root,
|
|
630
864
|
{
|
|
631
|
-
ref:
|
|
632
|
-
className:
|
|
865
|
+
ref: n,
|
|
866
|
+
className: s(
|
|
633
867
|
"gryt-switch relative inline-flex h-6 w-10 shrink-0 items-center",
|
|
634
868
|
"rounded-(--gryt-radius-full) border border-gryt-border bg-gryt-surface-raised p-0.5",
|
|
635
869
|
"transition-[scale,background-color,border-color] duration-(--gryt-dur-spring) ease-spring",
|
|
@@ -637,16 +871,16 @@ const Bt = {
|
|
|
637
871
|
"hover:not-data-disabled:border-gryt-accent-light",
|
|
638
872
|
"motion-safe:hover:not-data-disabled:scale-[1.05]",
|
|
639
873
|
"motion-safe:active:not-data-disabled:scale-[0.95]",
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
874
|
+
x,
|
|
875
|
+
V,
|
|
876
|
+
me[r],
|
|
877
|
+
e
|
|
644
878
|
),
|
|
645
|
-
...
|
|
646
|
-
children: /* @__PURE__ */
|
|
647
|
-
|
|
879
|
+
...t,
|
|
880
|
+
children: /* @__PURE__ */ a(
|
|
881
|
+
gt.Thumb,
|
|
648
882
|
{
|
|
649
|
-
className:
|
|
883
|
+
className: s(
|
|
650
884
|
"h-4.5 w-4.5 rounded-(--gryt-radius-full) bg-gryt-text",
|
|
651
885
|
"transition-transform duration-(--gryt-dur-spring) ease-spring motion-reduce:transition-none",
|
|
652
886
|
"data-checked:translate-x-4 data-checked:bg-gryt-bg"
|
|
@@ -656,70 +890,70 @@ const Bt = {
|
|
|
656
890
|
}
|
|
657
891
|
);
|
|
658
892
|
}
|
|
659
|
-
),
|
|
660
|
-
function
|
|
661
|
-
className:
|
|
662
|
-
tone:
|
|
663
|
-
"aria-label":
|
|
664
|
-
...
|
|
893
|
+
), pt = 3;
|
|
894
|
+
function Xo({
|
|
895
|
+
className: o,
|
|
896
|
+
tone: e = "primary",
|
|
897
|
+
"aria-label": r,
|
|
898
|
+
...t
|
|
665
899
|
}) {
|
|
666
|
-
const [
|
|
667
|
-
|
|
668
|
-
if (!
|
|
900
|
+
const [n, c] = Mt(!1), l = ht(null);
|
|
901
|
+
At(() => {
|
|
902
|
+
if (!n && l.current === null)
|
|
669
903
|
return;
|
|
670
|
-
const
|
|
904
|
+
const g = () => {
|
|
671
905
|
l.current = null, c(!1);
|
|
672
906
|
};
|
|
673
|
-
return window.addEventListener("pointerup",
|
|
674
|
-
window.removeEventListener("pointerup",
|
|
907
|
+
return window.addEventListener("pointerup", g), window.addEventListener("pointercancel", g), () => {
|
|
908
|
+
window.removeEventListener("pointerup", g), window.removeEventListener("pointercancel", g);
|
|
675
909
|
};
|
|
676
|
-
}, [
|
|
677
|
-
function
|
|
678
|
-
l.current = { x:
|
|
910
|
+
}, [n]);
|
|
911
|
+
function d(g) {
|
|
912
|
+
l.current = { x: g.clientX, y: g.clientY };
|
|
679
913
|
}
|
|
680
|
-
function u(
|
|
681
|
-
const
|
|
682
|
-
if (
|
|
914
|
+
function u(g) {
|
|
915
|
+
const f = l.current;
|
|
916
|
+
if (f === null || n)
|
|
683
917
|
return;
|
|
684
|
-
(Math.abs(
|
|
918
|
+
(Math.abs(g.clientX - f.x) > pt || Math.abs(g.clientY - f.y) > pt) && c(!0);
|
|
685
919
|
}
|
|
686
|
-
const
|
|
687
|
-
return /* @__PURE__ */
|
|
688
|
-
|
|
920
|
+
const m = n ? "transition-none" : "duration-(--gryt-dur-spring) ease-spring-tight motion-reduce:transition-none";
|
|
921
|
+
return /* @__PURE__ */ a(_.Root, { className: s("gryt-slider w-full", o), ...t, children: /* @__PURE__ */ a(
|
|
922
|
+
_.Control,
|
|
689
923
|
{
|
|
690
924
|
className: "flex w-full touch-none items-center py-2 select-none",
|
|
691
|
-
onPointerDown:
|
|
925
|
+
onPointerDown: d,
|
|
692
926
|
onPointerMove: u,
|
|
693
|
-
children: /* @__PURE__ */
|
|
694
|
-
/* @__PURE__ */
|
|
695
|
-
|
|
927
|
+
children: /* @__PURE__ */ p(_.Track, { className: "h-1.5 w-full rounded-(--gryt-radius-full) bg-gryt-surface-raised select-none", children: [
|
|
928
|
+
/* @__PURE__ */ a(
|
|
929
|
+
_.Indicator,
|
|
696
930
|
{
|
|
697
|
-
className:
|
|
931
|
+
className: s(
|
|
698
932
|
"h-full rounded-(--gryt-radius-full) select-none",
|
|
699
933
|
"transition-[width]",
|
|
700
|
-
|
|
701
|
-
|
|
934
|
+
m,
|
|
935
|
+
Ct[e]
|
|
702
936
|
)
|
|
703
937
|
}
|
|
704
938
|
),
|
|
705
|
-
/* @__PURE__ */
|
|
706
|
-
|
|
939
|
+
/* @__PURE__ */ a(
|
|
940
|
+
_.Thumb,
|
|
707
941
|
{
|
|
708
|
-
"aria-label":
|
|
709
|
-
className:
|
|
942
|
+
"aria-label": r,
|
|
943
|
+
className: s(
|
|
710
944
|
"group h-4 w-4 rounded-(--gryt-radius-full) select-none",
|
|
711
945
|
"transition-[inset-inline-start]",
|
|
712
|
-
|
|
946
|
+
m,
|
|
713
947
|
// The ring goes on the thumb but the focus lands on the visually
|
|
714
948
|
// hidden input inside it, so this has to match a descendant.
|
|
715
949
|
// Without it the slider is the one control here you cannot see
|
|
716
950
|
// yourself tab to.
|
|
717
|
-
|
|
951
|
+
ge
|
|
718
952
|
),
|
|
719
|
-
children: /* @__PURE__ */
|
|
953
|
+
children: /* @__PURE__ */ a(
|
|
720
954
|
"span",
|
|
721
955
|
{
|
|
722
|
-
className:
|
|
956
|
+
className: s(
|
|
723
957
|
"block h-full w-full rounded-(--gryt-radius-full) bg-gryt-text",
|
|
724
958
|
"transition-[scale] duration-(--gryt-dur-spring) ease-spring",
|
|
725
959
|
"motion-safe:group-hover:scale-[1.12] motion-safe:group-active:scale-[0.94]",
|
|
@@ -733,58 +967,58 @@ function ho({
|
|
|
733
967
|
}
|
|
734
968
|
) });
|
|
735
969
|
}
|
|
736
|
-
const
|
|
970
|
+
const we = {
|
|
737
971
|
small: "min-h-9 px-3 text-sm",
|
|
738
972
|
medium: "min-h-11 px-4 text-sm"
|
|
739
973
|
};
|
|
740
|
-
function
|
|
741
|
-
className:
|
|
742
|
-
label:
|
|
743
|
-
options:
|
|
744
|
-
placeholder:
|
|
745
|
-
size:
|
|
974
|
+
function Yo({
|
|
975
|
+
className: o,
|
|
976
|
+
label: e,
|
|
977
|
+
options: r = [],
|
|
978
|
+
placeholder: t = "Select",
|
|
979
|
+
size: n = "medium",
|
|
746
980
|
...c
|
|
747
981
|
}) {
|
|
748
|
-
return /* @__PURE__ */
|
|
749
|
-
/* @__PURE__ */
|
|
750
|
-
|
|
751
|
-
/* @__PURE__ */
|
|
752
|
-
|
|
982
|
+
return /* @__PURE__ */ p(v.Root, { items: r, ...c, children: [
|
|
983
|
+
/* @__PURE__ */ p("div", { className: s("gryt-select flex w-full flex-col gap-1.5", o), children: [
|
|
984
|
+
e ? /* @__PURE__ */ a(v.Label, { className: "text-xs font-medium text-gryt-muted", children: e }) : null,
|
|
985
|
+
/* @__PURE__ */ p(
|
|
986
|
+
v.Trigger,
|
|
753
987
|
{
|
|
754
|
-
className:
|
|
988
|
+
className: s(
|
|
755
989
|
"flex w-full items-center justify-between gap-2",
|
|
756
990
|
"rounded-(--gryt-radius-xl) border border-gryt-border bg-gryt-surface-raised",
|
|
757
991
|
"text-gryt-text select-none",
|
|
758
992
|
"transition-colors duration-150 hover:border-gryt-accent-light",
|
|
759
993
|
"data-disabled:cursor-not-allowed data-disabled:opacity-60",
|
|
760
|
-
|
|
761
|
-
|
|
994
|
+
x,
|
|
995
|
+
we[n]
|
|
762
996
|
),
|
|
763
997
|
children: [
|
|
764
|
-
/* @__PURE__ */
|
|
765
|
-
/* @__PURE__ */
|
|
998
|
+
/* @__PURE__ */ a(v.Value, { placeholder: t }),
|
|
999
|
+
/* @__PURE__ */ a(v.Icon, { className: "shrink-0 text-gryt-muted", children: /* @__PURE__ */ a(Ft, { size: 16 }) })
|
|
766
1000
|
]
|
|
767
1001
|
}
|
|
768
1002
|
)
|
|
769
1003
|
] }),
|
|
770
|
-
/* @__PURE__ */
|
|
771
|
-
|
|
1004
|
+
/* @__PURE__ */ a(v.Portal, { children: /* @__PURE__ */ a(v.Positioner, { sideOffset: 6, className: "outline-none", children: /* @__PURE__ */ a(
|
|
1005
|
+
v.Popup,
|
|
772
1006
|
{
|
|
773
|
-
className:
|
|
774
|
-
children: /* @__PURE__ */
|
|
775
|
-
|
|
1007
|
+
className: s("min-w-(--anchor-width) p-1", B, A),
|
|
1008
|
+
children: /* @__PURE__ */ a(v.List, { children: r.map((l) => /* @__PURE__ */ p(
|
|
1009
|
+
v.Item,
|
|
776
1010
|
{
|
|
777
1011
|
value: l.value,
|
|
778
1012
|
disabled: l.disabled,
|
|
779
|
-
className:
|
|
1013
|
+
className: s(
|
|
780
1014
|
"flex cursor-default items-center justify-between gap-2",
|
|
781
1015
|
"rounded-(--gryt-radius-md) px-3 py-2 text-sm text-gryt-text",
|
|
782
1016
|
"outline-none select-none data-highlighted:bg-gryt-surface-raised",
|
|
783
1017
|
"data-disabled:cursor-not-allowed data-disabled:opacity-50"
|
|
784
1018
|
),
|
|
785
1019
|
children: [
|
|
786
|
-
/* @__PURE__ */
|
|
787
|
-
/* @__PURE__ */
|
|
1020
|
+
/* @__PURE__ */ a(v.ItemText, { children: l.label }),
|
|
1021
|
+
/* @__PURE__ */ a(v.ItemIndicator, { className: "text-gryt-accent", children: /* @__PURE__ */ a(wt, { size: 14, weight: "bold" }) })
|
|
788
1022
|
]
|
|
789
1023
|
},
|
|
790
1024
|
String(l.value)
|
|
@@ -793,308 +1027,314 @@ function wo({
|
|
|
793
1027
|
) }) })
|
|
794
1028
|
] });
|
|
795
1029
|
}
|
|
796
|
-
function
|
|
797
|
-
children:
|
|
798
|
-
className:
|
|
799
|
-
side:
|
|
800
|
-
sideOffset:
|
|
801
|
-
title:
|
|
1030
|
+
function Wo({
|
|
1031
|
+
children: o,
|
|
1032
|
+
className: e,
|
|
1033
|
+
side: r = "top",
|
|
1034
|
+
sideOffset: t = 8,
|
|
1035
|
+
title: n
|
|
802
1036
|
}) {
|
|
803
|
-
return /* @__PURE__ */
|
|
804
|
-
/* @__PURE__ */
|
|
805
|
-
/* @__PURE__ */
|
|
806
|
-
|
|
1037
|
+
return /* @__PURE__ */ p(j.Root, { children: [
|
|
1038
|
+
/* @__PURE__ */ a(j.Trigger, { render: o }),
|
|
1039
|
+
/* @__PURE__ */ a(j.Portal, { children: /* @__PURE__ */ a(j.Positioner, { side: r, sideOffset: t, children: /* @__PURE__ */ a(
|
|
1040
|
+
j.Popup,
|
|
807
1041
|
{
|
|
808
|
-
className:
|
|
1042
|
+
className: s(
|
|
809
1043
|
"gryt-tooltip rounded-(--gryt-radius-md) border border-gryt-border bg-gryt-surface-raised",
|
|
810
1044
|
"px-2.5 py-1.5 text-xs text-gryt-text",
|
|
811
|
-
|
|
812
|
-
|
|
1045
|
+
A,
|
|
1046
|
+
e
|
|
813
1047
|
),
|
|
814
|
-
children:
|
|
1048
|
+
children: n
|
|
815
1049
|
}
|
|
816
1050
|
) }) })
|
|
817
1051
|
] });
|
|
818
1052
|
}
|
|
819
|
-
const
|
|
820
|
-
function({ className:
|
|
821
|
-
return /* @__PURE__ */
|
|
822
|
-
|
|
1053
|
+
const Qo = j.Provider, Jo = i(
|
|
1054
|
+
function({ className: e, orientation: r = "horizontal", ...t }, n) {
|
|
1055
|
+
return /* @__PURE__ */ a(
|
|
1056
|
+
Ut,
|
|
823
1057
|
{
|
|
824
|
-
ref:
|
|
825
|
-
orientation:
|
|
826
|
-
className:
|
|
1058
|
+
ref: n,
|
|
1059
|
+
orientation: r,
|
|
1060
|
+
className: s(
|
|
827
1061
|
"gryt-divider bg-gryt-border",
|
|
828
|
-
|
|
829
|
-
|
|
1062
|
+
r === "vertical" ? "h-full w-px" : "h-px w-full",
|
|
1063
|
+
e
|
|
830
1064
|
),
|
|
831
|
-
...
|
|
1065
|
+
...t
|
|
832
1066
|
}
|
|
833
1067
|
);
|
|
834
1068
|
}
|
|
835
|
-
),
|
|
836
|
-
return /* @__PURE__ */
|
|
1069
|
+
), Ko = i(function({ className: e, ...r }, t) {
|
|
1070
|
+
return /* @__PURE__ */ a(
|
|
837
1071
|
"div",
|
|
838
1072
|
{
|
|
839
|
-
ref:
|
|
840
|
-
className:
|
|
1073
|
+
ref: t,
|
|
1074
|
+
className: s(
|
|
841
1075
|
"gryt-card rounded-(--gryt-radius-xl) border border-gryt-border bg-gryt-surface text-gryt-text",
|
|
842
|
-
|
|
1076
|
+
e
|
|
843
1077
|
),
|
|
844
|
-
...
|
|
1078
|
+
...r
|
|
845
1079
|
}
|
|
846
1080
|
);
|
|
847
1081
|
});
|
|
848
|
-
function
|
|
849
|
-
children:
|
|
850
|
-
className:
|
|
851
|
-
subheader:
|
|
852
|
-
title:
|
|
853
|
-
...
|
|
1082
|
+
function Zo({
|
|
1083
|
+
children: o,
|
|
1084
|
+
className: e,
|
|
1085
|
+
subheader: r,
|
|
1086
|
+
title: t,
|
|
1087
|
+
...n
|
|
854
1088
|
}) {
|
|
855
|
-
return /* @__PURE__ */
|
|
1089
|
+
return /* @__PURE__ */ p(
|
|
856
1090
|
"div",
|
|
857
1091
|
{
|
|
858
|
-
className:
|
|
859
|
-
...
|
|
1092
|
+
className: s("gryt-card-header flex flex-col gap-1 p-4", e),
|
|
1093
|
+
...n,
|
|
860
1094
|
children: [
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
1095
|
+
t ? /* @__PURE__ */ a("span", { className: "text-base font-semibold text-gryt-text", children: t }) : null,
|
|
1096
|
+
r ? /* @__PURE__ */ a("span", { className: "text-sm text-gryt-muted", children: r }) : null,
|
|
1097
|
+
o
|
|
864
1098
|
]
|
|
865
1099
|
}
|
|
866
1100
|
);
|
|
867
1101
|
}
|
|
868
|
-
function
|
|
869
|
-
className:
|
|
870
|
-
...
|
|
1102
|
+
function qo({
|
|
1103
|
+
className: o,
|
|
1104
|
+
...e
|
|
871
1105
|
}) {
|
|
872
|
-
return /* @__PURE__ */
|
|
1106
|
+
return /* @__PURE__ */ a(
|
|
873
1107
|
"div",
|
|
874
1108
|
{
|
|
875
|
-
className:
|
|
1109
|
+
className: s(
|
|
876
1110
|
"gryt-card-content px-4 pb-4 text-sm text-gryt-muted",
|
|
877
|
-
|
|
1111
|
+
o
|
|
878
1112
|
),
|
|
879
|
-
...
|
|
1113
|
+
...e
|
|
880
1114
|
}
|
|
881
1115
|
);
|
|
882
1116
|
}
|
|
883
|
-
function
|
|
884
|
-
className:
|
|
885
|
-
...
|
|
1117
|
+
function ta({
|
|
1118
|
+
className: o,
|
|
1119
|
+
...e
|
|
886
1120
|
}) {
|
|
887
|
-
return /* @__PURE__ */
|
|
1121
|
+
return /* @__PURE__ */ a(
|
|
888
1122
|
"div",
|
|
889
1123
|
{
|
|
890
|
-
className:
|
|
1124
|
+
className: s(
|
|
891
1125
|
"gryt-card-actions flex items-center gap-2 px-4 pb-4",
|
|
892
|
-
|
|
1126
|
+
o
|
|
893
1127
|
),
|
|
894
|
-
...
|
|
1128
|
+
...e
|
|
895
1129
|
}
|
|
896
1130
|
);
|
|
897
1131
|
}
|
|
898
|
-
const
|
|
1132
|
+
const ve = {
|
|
899
1133
|
info: "border-gryt-secondary/40 bg-gryt-secondary/10 text-gryt-secondary",
|
|
900
1134
|
success: "border-gryt-success/40 bg-gryt-success/10 text-gryt-success",
|
|
901
1135
|
warning: "border-gryt-warning/40 bg-gryt-warning/10 text-gryt-warning",
|
|
902
1136
|
error: "border-gryt-danger/40 bg-gryt-danger/10 text-gryt-danger"
|
|
903
|
-
},
|
|
904
|
-
return /* @__PURE__ */
|
|
1137
|
+
}, ea = i(function({ className: e, severity: r = "info", ...t }, n) {
|
|
1138
|
+
return /* @__PURE__ */ a(
|
|
905
1139
|
"div",
|
|
906
1140
|
{
|
|
907
|
-
ref:
|
|
1141
|
+
ref: n,
|
|
908
1142
|
role: "alert",
|
|
909
|
-
className:
|
|
1143
|
+
className: s(
|
|
910
1144
|
"gryt-alert rounded-(--gryt-radius-lg) border px-4 py-3 text-sm",
|
|
911
|
-
|
|
912
|
-
|
|
1145
|
+
ve[r],
|
|
1146
|
+
e
|
|
913
1147
|
),
|
|
914
|
-
...
|
|
1148
|
+
...t
|
|
915
1149
|
}
|
|
916
1150
|
);
|
|
917
1151
|
});
|
|
918
|
-
function
|
|
919
|
-
return /* @__PURE__ */
|
|
920
|
-
|
|
1152
|
+
function ra({ className: o, value: e = null, ...r }) {
|
|
1153
|
+
return /* @__PURE__ */ a(
|
|
1154
|
+
et.Root,
|
|
921
1155
|
{
|
|
922
|
-
value:
|
|
923
|
-
className:
|
|
924
|
-
...
|
|
925
|
-
children: /* @__PURE__ */
|
|
1156
|
+
value: e,
|
|
1157
|
+
className: s("gryt-progress w-full", o),
|
|
1158
|
+
...r,
|
|
1159
|
+
children: /* @__PURE__ */ a(et.Track, { className: "h-1.5 w-full overflow-hidden rounded-(--gryt-radius-full) bg-gryt-surface-raised", children: /* @__PURE__ */ a(et.Indicator, { className: "h-full rounded-(--gryt-radius-full) bg-gryt-accent transition-[width] duration-300 ease-out motion-reduce:transition-none" }) })
|
|
926
1160
|
}
|
|
927
1161
|
);
|
|
928
1162
|
}
|
|
929
|
-
function
|
|
930
|
-
className:
|
|
931
|
-
size:
|
|
932
|
-
"aria-label":
|
|
1163
|
+
function oa({
|
|
1164
|
+
className: o,
|
|
1165
|
+
size: e = 24,
|
|
1166
|
+
"aria-label": r = "Loading"
|
|
933
1167
|
}) {
|
|
934
|
-
return /* @__PURE__ */
|
|
935
|
-
|
|
1168
|
+
return /* @__PURE__ */ a(
|
|
1169
|
+
Et,
|
|
936
1170
|
{
|
|
937
1171
|
role: "status",
|
|
938
|
-
"aria-label":
|
|
939
|
-
size:
|
|
1172
|
+
"aria-label": r,
|
|
1173
|
+
size: e,
|
|
940
1174
|
weight: "bold",
|
|
941
|
-
className:
|
|
1175
|
+
className: s(
|
|
942
1176
|
"gryt-spinner text-gryt-accent motion-safe:animate-spin",
|
|
943
|
-
|
|
1177
|
+
o
|
|
944
1178
|
)
|
|
945
1179
|
}
|
|
946
1180
|
);
|
|
947
1181
|
}
|
|
948
|
-
const
|
|
1182
|
+
const Ne = {
|
|
949
1183
|
text: "h-4 rounded-(--gryt-radius-sm)",
|
|
950
1184
|
rounded: "rounded-(--gryt-radius-lg)",
|
|
951
1185
|
circular: "rounded-(--gryt-radius-full)",
|
|
952
1186
|
rectangular: "rounded-none"
|
|
953
1187
|
};
|
|
954
|
-
function
|
|
955
|
-
className:
|
|
956
|
-
height:
|
|
957
|
-
style:
|
|
958
|
-
variant:
|
|
959
|
-
width:
|
|
1188
|
+
function aa({
|
|
1189
|
+
className: o,
|
|
1190
|
+
height: e,
|
|
1191
|
+
style: r,
|
|
1192
|
+
variant: t = "text",
|
|
1193
|
+
width: n,
|
|
960
1194
|
...c
|
|
961
1195
|
}) {
|
|
962
1196
|
const l = {
|
|
963
|
-
width:
|
|
964
|
-
height:
|
|
965
|
-
...
|
|
1197
|
+
width: n,
|
|
1198
|
+
height: e,
|
|
1199
|
+
...r
|
|
966
1200
|
};
|
|
967
|
-
return /* @__PURE__ */
|
|
1201
|
+
return /* @__PURE__ */ a(
|
|
968
1202
|
"div",
|
|
969
1203
|
{
|
|
970
1204
|
"aria-hidden": "true",
|
|
971
|
-
className:
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
1205
|
+
className: s(
|
|
1206
|
+
// Not bg-gryt-surface-raised. #1e2028 against #1a1d24 is four points of
|
|
1207
|
+
// luminance, which is invisible on a laptop screen at an angle — the
|
|
1208
|
+
// placeholder that is meant to say "something is coming" said nothing.
|
|
1209
|
+
// A white wash instead of a fixed colour, so it stays visible on any of
|
|
1210
|
+
// the surfaces it can land on rather than only the one it was picked
|
|
1211
|
+
// against, and it dims rather than brightens as it pulses.
|
|
1212
|
+
"gryt-skeleton bg-white/9 motion-safe:animate-pulse",
|
|
1213
|
+
Ne[t],
|
|
1214
|
+
o
|
|
975
1215
|
),
|
|
976
1216
|
style: l,
|
|
977
1217
|
...c
|
|
978
1218
|
}
|
|
979
1219
|
);
|
|
980
1220
|
}
|
|
981
|
-
const
|
|
982
|
-
function({ className:
|
|
983
|
-
return /* @__PURE__ */
|
|
984
|
-
|
|
1221
|
+
const St = "transition-[opacity,scale,translate] duration-(--gryt-dur-spring) ease-spring motion-reduce:transition-none", Pe = i(
|
|
1222
|
+
function({ className: e, ...r }, t) {
|
|
1223
|
+
return /* @__PURE__ */ a(
|
|
1224
|
+
L.Backdrop,
|
|
985
1225
|
{
|
|
986
|
-
ref:
|
|
987
|
-
className:
|
|
1226
|
+
ref: t,
|
|
1227
|
+
className: s(
|
|
988
1228
|
"gryt-dialog-backdrop fixed inset-0 min-h-dvh bg-black/60",
|
|
989
1229
|
"backdrop-blur-(--gryt-backdrop-blur)",
|
|
990
|
-
|
|
1230
|
+
St,
|
|
991
1231
|
"data-starting-style:opacity-0 data-ending-style:opacity-0",
|
|
992
|
-
|
|
1232
|
+
e
|
|
993
1233
|
),
|
|
994
|
-
...
|
|
1234
|
+
...r
|
|
995
1235
|
}
|
|
996
1236
|
);
|
|
997
1237
|
}
|
|
998
|
-
),
|
|
999
|
-
function({ className:
|
|
1000
|
-
return /* @__PURE__ */
|
|
1001
|
-
|
|
1238
|
+
), Te = i(
|
|
1239
|
+
function({ className: e, ...r }, t) {
|
|
1240
|
+
return /* @__PURE__ */ a(
|
|
1241
|
+
L.Popup,
|
|
1002
1242
|
{
|
|
1003
|
-
ref:
|
|
1004
|
-
className:
|
|
1243
|
+
ref: t,
|
|
1244
|
+
className: s(
|
|
1005
1245
|
"gryt-dialog fixed top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2",
|
|
1006
1246
|
"flex w-96 max-w-[calc(100vw-3rem)] flex-col gap-4",
|
|
1007
1247
|
"rounded-(--gryt-radius-lg) border border-gryt-border bg-gryt-surface p-5 text-gryt-text",
|
|
1008
|
-
|
|
1248
|
+
St,
|
|
1009
1249
|
"data-starting-style:scale-[0.98] data-starting-style:opacity-0",
|
|
1010
1250
|
"data-ending-style:scale-[0.98] data-ending-style:opacity-0",
|
|
1011
|
-
|
|
1251
|
+
e
|
|
1012
1252
|
),
|
|
1013
|
-
...
|
|
1253
|
+
...r
|
|
1014
1254
|
}
|
|
1015
1255
|
);
|
|
1016
1256
|
}
|
|
1017
|
-
),
|
|
1018
|
-
function({ className:
|
|
1019
|
-
return /* @__PURE__ */
|
|
1020
|
-
|
|
1257
|
+
), ke = i(
|
|
1258
|
+
function({ className: e, ...r }, t) {
|
|
1259
|
+
return /* @__PURE__ */ a(
|
|
1260
|
+
L.Title,
|
|
1021
1261
|
{
|
|
1022
|
-
ref:
|
|
1023
|
-
className:
|
|
1262
|
+
ref: t,
|
|
1263
|
+
className: s(
|
|
1024
1264
|
"gryt-dialog-title text-base font-semibold text-gryt-text",
|
|
1025
|
-
|
|
1265
|
+
e
|
|
1026
1266
|
),
|
|
1027
|
-
...
|
|
1267
|
+
...r
|
|
1028
1268
|
}
|
|
1029
1269
|
);
|
|
1030
1270
|
}
|
|
1031
|
-
),
|
|
1032
|
-
function({ className:
|
|
1033
|
-
return /* @__PURE__ */
|
|
1034
|
-
|
|
1271
|
+
), $e = i(
|
|
1272
|
+
function({ className: e, ...r }, t) {
|
|
1273
|
+
return /* @__PURE__ */ a(
|
|
1274
|
+
L.Description,
|
|
1035
1275
|
{
|
|
1036
|
-
ref:
|
|
1037
|
-
className:
|
|
1276
|
+
ref: t,
|
|
1277
|
+
className: s(
|
|
1038
1278
|
"gryt-dialog-description text-sm text-gryt-muted",
|
|
1039
|
-
|
|
1279
|
+
e
|
|
1040
1280
|
),
|
|
1041
|
-
...
|
|
1281
|
+
...r
|
|
1042
1282
|
}
|
|
1043
1283
|
);
|
|
1044
1284
|
}
|
|
1045
|
-
),
|
|
1046
|
-
function({ className:
|
|
1047
|
-
return /* @__PURE__ */
|
|
1285
|
+
), Ce = i(
|
|
1286
|
+
function({ className: e, ...r }, t) {
|
|
1287
|
+
return /* @__PURE__ */ a(
|
|
1048
1288
|
"div",
|
|
1049
1289
|
{
|
|
1050
|
-
ref:
|
|
1051
|
-
className:
|
|
1290
|
+
ref: t,
|
|
1291
|
+
className: s(
|
|
1052
1292
|
"gryt-dialog-footer flex justify-end gap-3",
|
|
1053
|
-
|
|
1293
|
+
e
|
|
1054
1294
|
),
|
|
1055
|
-
...
|
|
1295
|
+
...r
|
|
1056
1296
|
}
|
|
1057
1297
|
);
|
|
1058
1298
|
}
|
|
1059
|
-
),
|
|
1060
|
-
Root:
|
|
1061
|
-
Trigger:
|
|
1062
|
-
Portal:
|
|
1063
|
-
Close:
|
|
1064
|
-
Backdrop:
|
|
1065
|
-
Popup:
|
|
1066
|
-
Title:
|
|
1067
|
-
Description:
|
|
1068
|
-
Footer:
|
|
1069
|
-
},
|
|
1299
|
+
), na = {
|
|
1300
|
+
Root: L.Root,
|
|
1301
|
+
Trigger: L.Trigger,
|
|
1302
|
+
Portal: L.Portal,
|
|
1303
|
+
Close: L.Close,
|
|
1304
|
+
Backdrop: Pe,
|
|
1305
|
+
Popup: Te,
|
|
1306
|
+
Title: ke,
|
|
1307
|
+
Description: $e,
|
|
1308
|
+
Footer: Ce
|
|
1309
|
+
}, Se = () => () => {
|
|
1070
1310
|
};
|
|
1071
|
-
function
|
|
1072
|
-
const
|
|
1073
|
-
(
|
|
1074
|
-
if (typeof window > "u" || !window.matchMedia) return
|
|
1075
|
-
const
|
|
1076
|
-
return
|
|
1311
|
+
function Re(o) {
|
|
1312
|
+
const e = at(
|
|
1313
|
+
(t) => {
|
|
1314
|
+
if (typeof window > "u" || !window.matchMedia) return Se();
|
|
1315
|
+
const n = window.matchMedia(o);
|
|
1316
|
+
return n.addEventListener("change", t), () => n.removeEventListener("change", t);
|
|
1077
1317
|
},
|
|
1078
|
-
[
|
|
1079
|
-
),
|
|
1080
|
-
return
|
|
1318
|
+
[o]
|
|
1319
|
+
), r = at(() => typeof window > "u" || !window.matchMedia ? !1 : window.matchMedia(o).matches, [o]);
|
|
1320
|
+
return Dt(e, r, () => !1);
|
|
1081
1321
|
}
|
|
1082
|
-
const
|
|
1322
|
+
const Ie = {
|
|
1083
1323
|
left: "left",
|
|
1084
1324
|
right: "right",
|
|
1085
1325
|
top: "up",
|
|
1086
1326
|
bottom: "down"
|
|
1087
|
-
},
|
|
1327
|
+
}, Z = jt("right"), Le = {
|
|
1088
1328
|
left: "items-stretch justify-start",
|
|
1089
1329
|
right: "items-stretch justify-end",
|
|
1090
1330
|
top: "items-start justify-center",
|
|
1091
1331
|
bottom: "items-end justify-center"
|
|
1092
|
-
},
|
|
1332
|
+
}, Me = {
|
|
1093
1333
|
left: "rounded-r-(--gryt-radius-xl)",
|
|
1094
1334
|
right: "rounded-l-(--gryt-radius-xl)",
|
|
1095
1335
|
top: "rounded-b-(--gryt-radius-xl)",
|
|
1096
1336
|
bottom: "rounded-t-(--gryt-radius-xl)"
|
|
1097
|
-
},
|
|
1337
|
+
}, Ae = {
|
|
1098
1338
|
left: [
|
|
1099
1339
|
"h-full w-[calc(20rem+var(--gryt-drawer-bleed))] max-w-[calc(85vw+var(--gryt-drawer-bleed))]",
|
|
1100
1340
|
"-ml-(--gryt-drawer-bleed) border-r py-5 pr-5 pl-[calc(1.25rem+var(--gryt-drawer-bleed))]",
|
|
@@ -1124,41 +1364,41 @@ const ie = {
|
|
|
1124
1364
|
"data-ending-style:[transform:translateY(calc(100%-var(--gryt-drawer-bleed)))]"
|
|
1125
1365
|
].join(" ")
|
|
1126
1366
|
};
|
|
1127
|
-
function
|
|
1128
|
-
side:
|
|
1129
|
-
sheetOnMobile:
|
|
1130
|
-
children:
|
|
1131
|
-
...
|
|
1367
|
+
function De({
|
|
1368
|
+
side: o = "right",
|
|
1369
|
+
sheetOnMobile: e = !0,
|
|
1370
|
+
children: r,
|
|
1371
|
+
...t
|
|
1132
1372
|
}) {
|
|
1133
|
-
const
|
|
1134
|
-
return /* @__PURE__ */
|
|
1373
|
+
const n = Re("(max-width: 767px)"), c = e && n ? "bottom" : o;
|
|
1374
|
+
return /* @__PURE__ */ a(Z.Provider, { value: c, children: /* @__PURE__ */ a(T.Root, { swipeDirection: Ie[c], ...t, children: r }) });
|
|
1135
1375
|
}
|
|
1136
|
-
const
|
|
1137
|
-
function({ className:
|
|
1138
|
-
const
|
|
1139
|
-
return /* @__PURE__ */
|
|
1140
|
-
|
|
1376
|
+
const je = i(
|
|
1377
|
+
function({ className: e, ...r }, t) {
|
|
1378
|
+
const n = nt(Z);
|
|
1379
|
+
return /* @__PURE__ */ a(
|
|
1380
|
+
T.Viewport,
|
|
1141
1381
|
{
|
|
1142
|
-
ref:
|
|
1143
|
-
className:
|
|
1382
|
+
ref: t,
|
|
1383
|
+
className: s(
|
|
1144
1384
|
// z-50 matters: the popup is no longer positioned itself, so the
|
|
1145
1385
|
// viewport is what has to sit above the page. Without it a sticky
|
|
1146
1386
|
// site header renders over the panel.
|
|
1147
1387
|
"gryt-drawer-viewport fixed inset-0 z-50 flex",
|
|
1148
|
-
|
|
1149
|
-
|
|
1388
|
+
Le[n],
|
|
1389
|
+
e
|
|
1150
1390
|
),
|
|
1151
|
-
...
|
|
1391
|
+
...r
|
|
1152
1392
|
}
|
|
1153
1393
|
);
|
|
1154
1394
|
}
|
|
1155
|
-
),
|
|
1156
|
-
const
|
|
1157
|
-
return /* @__PURE__ */
|
|
1158
|
-
|
|
1395
|
+
), Ge = i(function({ className: e, ...r }, t) {
|
|
1396
|
+
const n = nt(Z);
|
|
1397
|
+
return /* @__PURE__ */ a(
|
|
1398
|
+
T.Popup,
|
|
1159
1399
|
{
|
|
1160
|
-
ref:
|
|
1161
|
-
className:
|
|
1400
|
+
ref: t,
|
|
1401
|
+
className: s(
|
|
1162
1402
|
"gryt-drawer flex flex-col gap-4 border-gryt-border bg-gryt-surface text-gryt-text",
|
|
1163
1403
|
"overflow-y-auto overscroll-contain outline-none",
|
|
1164
1404
|
"transition-transform duration-(--gryt-dur-spring-soft) ease-spring",
|
|
@@ -1166,19 +1406,19 @@ const ge = s(
|
|
|
1166
1406
|
// duration here turns a drag into a drag plus lag.
|
|
1167
1407
|
"data-swiping:duration-0 data-swiping:select-none",
|
|
1168
1408
|
"motion-reduce:transition-none",
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1409
|
+
Ae[n],
|
|
1410
|
+
Me[n],
|
|
1411
|
+
e
|
|
1172
1412
|
),
|
|
1173
|
-
...
|
|
1413
|
+
...r
|
|
1174
1414
|
}
|
|
1175
1415
|
);
|
|
1176
|
-
}),
|
|
1177
|
-
return /* @__PURE__ */
|
|
1178
|
-
|
|
1416
|
+
}), Be = i(function({ className: e, ...r }, t) {
|
|
1417
|
+
return /* @__PURE__ */ a(
|
|
1418
|
+
T.Backdrop,
|
|
1179
1419
|
{
|
|
1180
|
-
ref:
|
|
1181
|
-
className:
|
|
1420
|
+
ref: t,
|
|
1421
|
+
className: s(
|
|
1182
1422
|
"gryt-drawer-backdrop fixed inset-0 z-50 min-h-dvh bg-black/60",
|
|
1183
1423
|
"backdrop-blur-(--gryt-backdrop-blur)",
|
|
1184
1424
|
// Lightens as the panel is dragged away, so letting go halfway does not
|
|
@@ -1188,137 +1428,137 @@ const ge = s(
|
|
|
1188
1428
|
"data-swiping:duration-0",
|
|
1189
1429
|
"data-starting-style:opacity-0 data-ending-style:opacity-0",
|
|
1190
1430
|
"motion-reduce:transition-none",
|
|
1191
|
-
|
|
1431
|
+
e
|
|
1192
1432
|
),
|
|
1193
|
-
...
|
|
1433
|
+
...r
|
|
1194
1434
|
}
|
|
1195
1435
|
);
|
|
1196
1436
|
});
|
|
1197
|
-
function
|
|
1198
|
-
const
|
|
1199
|
-
return
|
|
1437
|
+
function ze({ className: o }) {
|
|
1438
|
+
const e = nt(Z);
|
|
1439
|
+
return e !== "bottom" && e !== "top" ? null : /* @__PURE__ */ a(
|
|
1200
1440
|
"div",
|
|
1201
1441
|
{
|
|
1202
1442
|
"aria-hidden": !0,
|
|
1203
|
-
className:
|
|
1443
|
+
className: s(
|
|
1204
1444
|
"gryt-drawer-grabber mx-auto h-1.5 w-10 shrink-0 rounded-(--gryt-radius-full) bg-gryt-border",
|
|
1205
|
-
|
|
1206
|
-
|
|
1445
|
+
e === "top" && "order-last",
|
|
1446
|
+
o
|
|
1207
1447
|
)
|
|
1208
1448
|
}
|
|
1209
1449
|
);
|
|
1210
1450
|
}
|
|
1211
|
-
const
|
|
1212
|
-
Root:
|
|
1213
|
-
Trigger:
|
|
1214
|
-
Portal:
|
|
1215
|
-
Backdrop:
|
|
1216
|
-
Viewport:
|
|
1217
|
-
Popup:
|
|
1218
|
-
Content:
|
|
1219
|
-
Grabber:
|
|
1220
|
-
Close:
|
|
1221
|
-
Title:
|
|
1222
|
-
Description:
|
|
1223
|
-
},
|
|
1224
|
-
function({ className:
|
|
1225
|
-
return /* @__PURE__ */
|
|
1226
|
-
|
|
1451
|
+
const sa = {
|
|
1452
|
+
Root: De,
|
|
1453
|
+
Trigger: T.Trigger,
|
|
1454
|
+
Portal: T.Portal,
|
|
1455
|
+
Backdrop: Be,
|
|
1456
|
+
Viewport: je,
|
|
1457
|
+
Popup: Ge,
|
|
1458
|
+
Content: T.Content,
|
|
1459
|
+
Grabber: ze,
|
|
1460
|
+
Close: T.Close,
|
|
1461
|
+
Title: T.Title,
|
|
1462
|
+
Description: T.Description
|
|
1463
|
+
}, Fe = i(
|
|
1464
|
+
function({ className: e, sideOffset: r = 8, ...t }, n) {
|
|
1465
|
+
return /* @__PURE__ */ a(
|
|
1466
|
+
G.Positioner,
|
|
1227
1467
|
{
|
|
1228
|
-
ref:
|
|
1229
|
-
sideOffset:
|
|
1230
|
-
className:
|
|
1231
|
-
...
|
|
1468
|
+
ref: n,
|
|
1469
|
+
sideOffset: r,
|
|
1470
|
+
className: s("gryt-menu-positioner outline-none", e),
|
|
1471
|
+
...t
|
|
1232
1472
|
}
|
|
1233
1473
|
);
|
|
1234
1474
|
}
|
|
1235
|
-
),
|
|
1236
|
-
return /* @__PURE__ */
|
|
1237
|
-
|
|
1475
|
+
), Ee = i(function({ className: e, ...r }, t) {
|
|
1476
|
+
return /* @__PURE__ */ a(
|
|
1477
|
+
G.Popup,
|
|
1238
1478
|
{
|
|
1239
|
-
ref:
|
|
1240
|
-
className:
|
|
1479
|
+
ref: t,
|
|
1480
|
+
className: s(
|
|
1241
1481
|
"gryt-menu min-w-44 p-1 outline-none",
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1482
|
+
B,
|
|
1483
|
+
A,
|
|
1484
|
+
e
|
|
1245
1485
|
),
|
|
1246
|
-
...
|
|
1486
|
+
...r
|
|
1247
1487
|
}
|
|
1248
1488
|
);
|
|
1249
|
-
}),
|
|
1250
|
-
return /* @__PURE__ */
|
|
1251
|
-
|
|
1489
|
+
}), Ve = i(function({ className: e, ...r }, t) {
|
|
1490
|
+
return /* @__PURE__ */ a(
|
|
1491
|
+
G.Item,
|
|
1252
1492
|
{
|
|
1253
|
-
ref:
|
|
1254
|
-
className:
|
|
1493
|
+
ref: t,
|
|
1494
|
+
className: s(
|
|
1255
1495
|
"gryt-menu-item flex cursor-default items-center gap-2 rounded-(--gryt-radius-md)",
|
|
1256
1496
|
"px-3 py-2 text-sm text-gryt-text outline-none select-none",
|
|
1257
1497
|
// Base UI drives keyboard and pointer highlight through the same
|
|
1258
1498
|
// attribute, so arrow keys and the mouse land on identical styling.
|
|
1259
1499
|
"data-highlighted:bg-gryt-surface-raised",
|
|
1260
1500
|
"data-disabled:cursor-not-allowed data-disabled:opacity-50",
|
|
1261
|
-
|
|
1501
|
+
e
|
|
1262
1502
|
),
|
|
1263
|
-
...
|
|
1503
|
+
...r
|
|
1264
1504
|
}
|
|
1265
1505
|
);
|
|
1266
|
-
}),
|
|
1267
|
-
return /* @__PURE__ */
|
|
1268
|
-
|
|
1506
|
+
}), _e = i(function({ className: e, ...r }, t) {
|
|
1507
|
+
return /* @__PURE__ */ a(
|
|
1508
|
+
G.Separator,
|
|
1269
1509
|
{
|
|
1270
|
-
ref:
|
|
1271
|
-
className:
|
|
1272
|
-
...
|
|
1510
|
+
ref: t,
|
|
1511
|
+
className: s("gryt-menu-separator my-1 h-px bg-gryt-border", e),
|
|
1512
|
+
...r
|
|
1273
1513
|
}
|
|
1274
1514
|
);
|
|
1275
|
-
}),
|
|
1276
|
-
Root:
|
|
1277
|
-
Trigger:
|
|
1278
|
-
Portal:
|
|
1279
|
-
Positioner:
|
|
1280
|
-
Popup:
|
|
1281
|
-
Item:
|
|
1282
|
-
Separator:
|
|
1283
|
-
},
|
|
1284
|
-
return /* @__PURE__ */
|
|
1285
|
-
|
|
1515
|
+
}), ot = {
|
|
1516
|
+
Root: G.Root,
|
|
1517
|
+
Trigger: G.Trigger,
|
|
1518
|
+
Portal: G.Portal,
|
|
1519
|
+
Positioner: Fe,
|
|
1520
|
+
Popup: Ee,
|
|
1521
|
+
Item: Ve,
|
|
1522
|
+
Separator: _e
|
|
1523
|
+
}, He = i(function({ className: e, ...r }, t) {
|
|
1524
|
+
return /* @__PURE__ */ a(
|
|
1525
|
+
W.Root,
|
|
1286
1526
|
{
|
|
1287
|
-
ref:
|
|
1288
|
-
className:
|
|
1527
|
+
ref: t,
|
|
1528
|
+
className: s(
|
|
1289
1529
|
"gryt-tabs",
|
|
1290
1530
|
// Vertical puts the rail and the panel side by side. min-w-0 on the
|
|
1291
1531
|
// panel does the rest; without the flex here the panel lands under the
|
|
1292
1532
|
// rail and the layout reads as a very tall accordion.
|
|
1293
1533
|
"data-[orientation=vertical]:flex data-[orientation=vertical]:items-stretch",
|
|
1294
|
-
|
|
1534
|
+
e
|
|
1295
1535
|
),
|
|
1296
|
-
...
|
|
1536
|
+
...r
|
|
1297
1537
|
}
|
|
1298
1538
|
);
|
|
1299
|
-
}),
|
|
1300
|
-
return /* @__PURE__ */
|
|
1301
|
-
|
|
1539
|
+
}), Oe = i(function({ className: e, ...r }, t) {
|
|
1540
|
+
return /* @__PURE__ */ a(
|
|
1541
|
+
W.List,
|
|
1302
1542
|
{
|
|
1303
|
-
ref:
|
|
1304
|
-
className:
|
|
1543
|
+
ref: t,
|
|
1544
|
+
className: s(
|
|
1305
1545
|
"gryt-tabs-list relative inline-flex items-center gap-1 rounded-(--gryt-radius-full) bg-gryt-surface-raised p-1",
|
|
1306
1546
|
// A rail, not a pill: rows are full width and the corner radius drops
|
|
1307
1547
|
// to lg, because a 999px radius on a tall box bows its short edges.
|
|
1308
1548
|
"data-[orientation=vertical]:flex data-[orientation=vertical]:shrink-0",
|
|
1309
1549
|
"data-[orientation=vertical]:flex-col data-[orientation=vertical]:items-stretch",
|
|
1310
1550
|
"data-[orientation=vertical]:rounded-(--gryt-radius-lg)",
|
|
1311
|
-
|
|
1551
|
+
e
|
|
1312
1552
|
),
|
|
1313
|
-
...
|
|
1553
|
+
...r
|
|
1314
1554
|
}
|
|
1315
1555
|
);
|
|
1316
|
-
}),
|
|
1317
|
-
return /* @__PURE__ */
|
|
1318
|
-
|
|
1556
|
+
}), Ue = i(function({ className: e, ...r }, t) {
|
|
1557
|
+
return /* @__PURE__ */ a(
|
|
1558
|
+
W.Tab,
|
|
1319
1559
|
{
|
|
1320
|
-
ref:
|
|
1321
|
-
className:
|
|
1560
|
+
ref: t,
|
|
1561
|
+
className: s(
|
|
1322
1562
|
"gryt-tab inline-flex min-h-8 items-center justify-center whitespace-nowrap",
|
|
1323
1563
|
"rounded-(--gryt-radius-full) border-0 bg-transparent px-4 py-1.5",
|
|
1324
1564
|
"text-sm font-medium text-gryt-muted select-none",
|
|
@@ -1332,20 +1572,20 @@ const Mo = {
|
|
|
1332
1572
|
"data-[orientation=vertical]:min-h-9 data-[orientation=vertical]:justify-start",
|
|
1333
1573
|
"data-[orientation=vertical]:gap-2.5 data-[orientation=vertical]:px-3",
|
|
1334
1574
|
"data-[orientation=vertical]:rounded-(--gryt-radius-md)",
|
|
1335
|
-
|
|
1336
|
-
|
|
1575
|
+
x,
|
|
1576
|
+
e
|
|
1337
1577
|
),
|
|
1338
|
-
...
|
|
1578
|
+
...r
|
|
1339
1579
|
}
|
|
1340
1580
|
);
|
|
1341
|
-
}),
|
|
1342
|
-
function({ className:
|
|
1343
|
-
return /* @__PURE__ */
|
|
1344
|
-
|
|
1581
|
+
}), Xe = i(
|
|
1582
|
+
function({ className: e, ...r }, t) {
|
|
1583
|
+
return /* @__PURE__ */ a(
|
|
1584
|
+
W.Indicator,
|
|
1345
1585
|
{
|
|
1346
|
-
ref:
|
|
1586
|
+
ref: t,
|
|
1347
1587
|
renderBeforeHydration: !0,
|
|
1348
|
-
className:
|
|
1588
|
+
className: s(
|
|
1349
1589
|
"gryt-tabs-indicator absolute top-1 left-0 z-0 h-[calc(100%-0.5rem)]",
|
|
1350
1590
|
"w-(--active-tab-width) translate-x-(--active-tab-left)",
|
|
1351
1591
|
"rounded-(--gryt-radius-full) bg-gryt-accent",
|
|
@@ -1359,340 +1599,352 @@ const Mo = {
|
|
|
1359
1599
|
"[[data-orientation=vertical]_&]:translate-y-(--active-tab-top)",
|
|
1360
1600
|
"[[data-orientation=vertical]_&]:rounded-(--gryt-radius-md)",
|
|
1361
1601
|
"[[data-orientation=vertical]_&]:transition-[translate,height]",
|
|
1362
|
-
|
|
1602
|
+
e
|
|
1363
1603
|
),
|
|
1364
|
-
...
|
|
1604
|
+
...r
|
|
1365
1605
|
}
|
|
1366
1606
|
);
|
|
1367
1607
|
}
|
|
1368
|
-
),
|
|
1369
|
-
return /* @__PURE__ */
|
|
1370
|
-
|
|
1608
|
+
), Ye = i(function({ className: e, ...r }, t) {
|
|
1609
|
+
return /* @__PURE__ */ a(
|
|
1610
|
+
W.Panel,
|
|
1371
1611
|
{
|
|
1372
|
-
ref:
|
|
1373
|
-
className:
|
|
1612
|
+
ref: t,
|
|
1613
|
+
className: s(
|
|
1374
1614
|
"gryt-tabs-panel pt-3 text-sm text-gryt-text",
|
|
1375
1615
|
// Beside the rail rather than under it, and allowed to shrink so long
|
|
1376
1616
|
// content wraps instead of pushing the rail off screen.
|
|
1377
1617
|
"data-[orientation=vertical]:min-w-0 data-[orientation=vertical]:flex-1",
|
|
1378
1618
|
"data-[orientation=vertical]:pt-0 data-[orientation=vertical]:pl-4",
|
|
1379
|
-
|
|
1619
|
+
e
|
|
1380
1620
|
),
|
|
1381
|
-
...
|
|
1621
|
+
...r
|
|
1382
1622
|
}
|
|
1383
1623
|
);
|
|
1384
|
-
}),
|
|
1385
|
-
return /* @__PURE__ */
|
|
1386
|
-
|
|
1624
|
+
}), ia = Object.assign(He, { List: Oe, Tab: Ue, Panel: Ye, Indicator: Xe }), We = i(function({ className: e, ...r }, t) {
|
|
1625
|
+
return /* @__PURE__ */ a(
|
|
1626
|
+
U.Root,
|
|
1387
1627
|
{
|
|
1388
|
-
ref:
|
|
1389
|
-
className:
|
|
1628
|
+
ref: t,
|
|
1629
|
+
className: s(
|
|
1390
1630
|
"gryt-accordion flex w-full flex-col gap-2 rounded-(--gryt-radius-xl) border border-gryt-border bg-gryt-surface p-2",
|
|
1391
|
-
|
|
1631
|
+
e
|
|
1392
1632
|
),
|
|
1393
|
-
...
|
|
1633
|
+
...r
|
|
1394
1634
|
}
|
|
1395
1635
|
);
|
|
1396
|
-
}),
|
|
1397
|
-
function({ className:
|
|
1398
|
-
return /* @__PURE__ */
|
|
1399
|
-
|
|
1636
|
+
}), Qe = i(
|
|
1637
|
+
function({ className: e, ...r }, t) {
|
|
1638
|
+
return /* @__PURE__ */ a(
|
|
1639
|
+
U.Item,
|
|
1400
1640
|
{
|
|
1401
|
-
ref:
|
|
1402
|
-
className:
|
|
1403
|
-
...
|
|
1641
|
+
ref: t,
|
|
1642
|
+
className: s("gryt-accordion-item", e),
|
|
1643
|
+
...r
|
|
1404
1644
|
}
|
|
1405
1645
|
);
|
|
1406
1646
|
}
|
|
1407
|
-
),
|
|
1408
|
-
function({ children:
|
|
1409
|
-
return /* @__PURE__ */
|
|
1410
|
-
|
|
1647
|
+
), Je = i(
|
|
1648
|
+
function({ children: e, className: r, expandIcon: t, ...n }, c) {
|
|
1649
|
+
return /* @__PURE__ */ a(U.Header, { className: "gryt-accordion-header m-0", children: /* @__PURE__ */ p(
|
|
1650
|
+
U.Trigger,
|
|
1411
1651
|
{
|
|
1412
1652
|
ref: c,
|
|
1413
|
-
className:
|
|
1653
|
+
className: s(
|
|
1414
1654
|
"gryt-accordion-trigger flex w-full items-center justify-between gap-3",
|
|
1415
1655
|
"rounded-(--gryt-radius-lg) border-0 bg-transparent px-3 py-2.5",
|
|
1416
1656
|
"text-left text-sm font-medium text-gryt-text select-none",
|
|
1417
1657
|
"transition-colors duration-150 hover:bg-gryt-surface-raised",
|
|
1418
|
-
|
|
1419
|
-
|
|
1658
|
+
x,
|
|
1659
|
+
r
|
|
1420
1660
|
),
|
|
1421
|
-
...
|
|
1661
|
+
...n,
|
|
1422
1662
|
children: [
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1663
|
+
e,
|
|
1664
|
+
t === void 0 ? /* @__PURE__ */ a(
|
|
1665
|
+
Vt,
|
|
1426
1666
|
{
|
|
1427
1667
|
size: 16,
|
|
1428
1668
|
className: "shrink-0 transition-transform duration-(--gryt-dur-spring) ease-spring data-panel-open:rotate-180 motion-reduce:transition-none"
|
|
1429
1669
|
}
|
|
1430
|
-
) :
|
|
1670
|
+
) : t
|
|
1431
1671
|
]
|
|
1432
1672
|
}
|
|
1433
1673
|
) });
|
|
1434
1674
|
}
|
|
1435
|
-
),
|
|
1436
|
-
function({ children:
|
|
1437
|
-
return /* @__PURE__ */
|
|
1438
|
-
|
|
1675
|
+
), Ke = i(
|
|
1676
|
+
function({ children: e, className: r, ...t }, n) {
|
|
1677
|
+
return /* @__PURE__ */ a(
|
|
1678
|
+
U.Panel,
|
|
1439
1679
|
{
|
|
1440
|
-
ref:
|
|
1441
|
-
className:
|
|
1680
|
+
ref: n,
|
|
1681
|
+
className: s(
|
|
1442
1682
|
"gryt-accordion-panel overflow-hidden text-sm text-gryt-muted",
|
|
1443
1683
|
// Base UI measures the panel and exposes the height as a variable,
|
|
1444
1684
|
// which is what makes a real open and close transition possible.
|
|
1445
1685
|
"h-[var(--accordion-panel-height)] transition-[height] duration-(--gryt-dur-spring-soft) ease-spring",
|
|
1446
1686
|
"data-starting-style:h-0 data-ending-style:h-0",
|
|
1447
1687
|
"motion-reduce:transition-none",
|
|
1448
|
-
|
|
1688
|
+
r
|
|
1449
1689
|
),
|
|
1450
|
-
...
|
|
1451
|
-
children: /* @__PURE__ */
|
|
1690
|
+
...t,
|
|
1691
|
+
children: /* @__PURE__ */ a("div", { className: "px-3 pt-1 pb-3", children: e })
|
|
1452
1692
|
}
|
|
1453
1693
|
);
|
|
1454
1694
|
}
|
|
1455
|
-
),
|
|
1456
|
-
function({ className:
|
|
1457
|
-
return /* @__PURE__ */
|
|
1458
|
-
|
|
1695
|
+
), ca = Object.assign(We, { Item: Qe, Trigger: Je, Panel: Ke }), Ze = i(
|
|
1696
|
+
function({ className: e, sideOffset: r = 2, ...t }, n) {
|
|
1697
|
+
return /* @__PURE__ */ a(
|
|
1698
|
+
I.Positioner,
|
|
1459
1699
|
{
|
|
1460
|
-
ref:
|
|
1461
|
-
sideOffset:
|
|
1462
|
-
className:
|
|
1463
|
-
...
|
|
1700
|
+
ref: n,
|
|
1701
|
+
sideOffset: r,
|
|
1702
|
+
className: s("gryt-context-menu-positioner outline-none", e),
|
|
1703
|
+
...t
|
|
1464
1704
|
}
|
|
1465
1705
|
);
|
|
1466
1706
|
}
|
|
1467
|
-
),
|
|
1468
|
-
Root:
|
|
1469
|
-
Trigger:
|
|
1470
|
-
Portal:
|
|
1471
|
-
Positioner:
|
|
1472
|
-
Popup:
|
|
1473
|
-
Item:
|
|
1474
|
-
Separator:
|
|
1475
|
-
Group:
|
|
1476
|
-
GroupLabel:
|
|
1477
|
-
SubmenuRoot:
|
|
1478
|
-
SubmenuTrigger:
|
|
1479
|
-
},
|
|
1480
|
-
function({ className:
|
|
1481
|
-
return /* @__PURE__ */
|
|
1482
|
-
|
|
1707
|
+
), la = {
|
|
1708
|
+
Root: I.Root,
|
|
1709
|
+
Trigger: I.Trigger,
|
|
1710
|
+
Portal: I.Portal,
|
|
1711
|
+
Positioner: Ze,
|
|
1712
|
+
Popup: ot.Popup,
|
|
1713
|
+
Item: ot.Item,
|
|
1714
|
+
Separator: ot.Separator,
|
|
1715
|
+
Group: I.Group,
|
|
1716
|
+
GroupLabel: I.GroupLabel,
|
|
1717
|
+
SubmenuRoot: I.SubmenuRoot,
|
|
1718
|
+
SubmenuTrigger: I.SubmenuTrigger
|
|
1719
|
+
}, qe = i(
|
|
1720
|
+
function({ className: e, sideOffset: r = 8, ...t }, n) {
|
|
1721
|
+
return /* @__PURE__ */ a(
|
|
1722
|
+
C.Positioner,
|
|
1483
1723
|
{
|
|
1484
|
-
ref:
|
|
1485
|
-
sideOffset:
|
|
1486
|
-
className:
|
|
1487
|
-
...
|
|
1724
|
+
ref: n,
|
|
1725
|
+
sideOffset: r,
|
|
1726
|
+
className: s("gryt-popover-positioner outline-none", e),
|
|
1727
|
+
...t
|
|
1488
1728
|
}
|
|
1489
1729
|
);
|
|
1490
1730
|
}
|
|
1491
|
-
),
|
|
1492
|
-
function({ className:
|
|
1493
|
-
return /* @__PURE__ */
|
|
1494
|
-
|
|
1731
|
+
), tr = i(
|
|
1732
|
+
function({ className: e, ...r }, t) {
|
|
1733
|
+
return /* @__PURE__ */ a(
|
|
1734
|
+
C.Popup,
|
|
1495
1735
|
{
|
|
1496
|
-
ref:
|
|
1497
|
-
className:
|
|
1736
|
+
ref: t,
|
|
1737
|
+
className: s(
|
|
1498
1738
|
"gryt-popover max-w-[min(20rem,calc(100vw-2rem))] p-4 outline-none",
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1739
|
+
B,
|
|
1740
|
+
A,
|
|
1741
|
+
e
|
|
1502
1742
|
),
|
|
1503
|
-
...
|
|
1743
|
+
...r
|
|
1504
1744
|
}
|
|
1505
1745
|
);
|
|
1506
1746
|
}
|
|
1507
|
-
),
|
|
1508
|
-
return /* @__PURE__ */
|
|
1509
|
-
|
|
1747
|
+
), er = i(function({ className: e, ...r }, t) {
|
|
1748
|
+
return /* @__PURE__ */ a(
|
|
1749
|
+
C.Title,
|
|
1510
1750
|
{
|
|
1511
|
-
ref:
|
|
1512
|
-
className:
|
|
1751
|
+
ref: t,
|
|
1752
|
+
className: s(
|
|
1513
1753
|
"gryt-popover-title text-sm font-semibold text-gryt-text",
|
|
1514
|
-
|
|
1754
|
+
e
|
|
1515
1755
|
),
|
|
1516
|
-
...
|
|
1756
|
+
...r
|
|
1517
1757
|
}
|
|
1518
1758
|
);
|
|
1519
|
-
}),
|
|
1520
|
-
return /* @__PURE__ */
|
|
1521
|
-
|
|
1759
|
+
}), rr = i(function({ className: e, ...r }, t) {
|
|
1760
|
+
return /* @__PURE__ */ a(
|
|
1761
|
+
C.Description,
|
|
1522
1762
|
{
|
|
1523
|
-
ref:
|
|
1524
|
-
className:
|
|
1763
|
+
ref: t,
|
|
1764
|
+
className: s(
|
|
1525
1765
|
"gryt-popover-description mt-1 text-sm leading-6 text-gryt-muted",
|
|
1526
|
-
|
|
1766
|
+
e
|
|
1527
1767
|
),
|
|
1528
|
-
...
|
|
1768
|
+
...r
|
|
1529
1769
|
}
|
|
1530
1770
|
);
|
|
1531
|
-
}),
|
|
1532
|
-
Root:
|
|
1533
|
-
Trigger:
|
|
1534
|
-
Portal:
|
|
1535
|
-
Positioner:
|
|
1536
|
-
Popup:
|
|
1537
|
-
Title:
|
|
1538
|
-
Description:
|
|
1539
|
-
Close:
|
|
1540
|
-
Arrow:
|
|
1541
|
-
},
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1771
|
+
}), da = {
|
|
1772
|
+
Root: C.Root,
|
|
1773
|
+
Trigger: C.Trigger,
|
|
1774
|
+
Portal: C.Portal,
|
|
1775
|
+
Positioner: qe,
|
|
1776
|
+
Popup: tr,
|
|
1777
|
+
Title: er,
|
|
1778
|
+
Description: rr,
|
|
1779
|
+
Close: C.Close,
|
|
1780
|
+
Arrow: C.Arrow
|
|
1781
|
+
}, or = {
|
|
1782
|
+
neutral: "border-white/8 bg-gryt-surface",
|
|
1783
|
+
info: "border-gryt-secondary/30 bg-gryt-secondary/8",
|
|
1784
|
+
success: "border-gryt-success/30 bg-gryt-success/8",
|
|
1785
|
+
warning: "border-gryt-warning/30 bg-gryt-warning/8",
|
|
1786
|
+
danger: "border-gryt-danger/30 bg-gryt-danger/8"
|
|
1787
|
+
}, ar = i(
|
|
1788
|
+
function({ className: e, ...r }, t) {
|
|
1789
|
+
return /* @__PURE__ */ a(
|
|
1790
|
+
R.Viewport,
|
|
1545
1791
|
{
|
|
1546
|
-
ref:
|
|
1547
|
-
className:
|
|
1792
|
+
ref: t,
|
|
1793
|
+
className: s(
|
|
1548
1794
|
"gryt-toast-viewport fixed right-4 bottom-4 z-50 flex w-[min(22rem,calc(100vw-2rem))]",
|
|
1549
1795
|
"flex-col gap-2 outline-none",
|
|
1550
|
-
|
|
1796
|
+
e
|
|
1551
1797
|
),
|
|
1552
|
-
...
|
|
1798
|
+
...r
|
|
1553
1799
|
}
|
|
1554
1800
|
);
|
|
1555
1801
|
}
|
|
1556
|
-
),
|
|
1557
|
-
return /* @__PURE__ */
|
|
1558
|
-
|
|
1802
|
+
), nr = i(function({ className: e, severity: r = "neutral", ...t }, n) {
|
|
1803
|
+
return /* @__PURE__ */ a(
|
|
1804
|
+
R.Root,
|
|
1559
1805
|
{
|
|
1560
|
-
ref:
|
|
1561
|
-
className:
|
|
1806
|
+
ref: n,
|
|
1807
|
+
className: s(
|
|
1562
1808
|
"gryt-toast relative flex flex-col p-3 pr-9",
|
|
1563
|
-
|
|
1809
|
+
// Not popupSurface. That border is --gryt-border, a solid slate line
|
|
1810
|
+
// that is right for a menu anchored to the thing that opened it and too
|
|
1811
|
+
// heavy for a card floating in the corner with nothing behind it. A
|
|
1812
|
+
// white hairline separates it from the page without drawing a box
|
|
1813
|
+
// around it.
|
|
1814
|
+
"rounded-(--gryt-radius-xl) border text-gryt-text",
|
|
1815
|
+
or[r],
|
|
1564
1816
|
// Swiping is a pointer gesture, so the toast follows the finger
|
|
1565
1817
|
// through Base UI's swipe variables before it animates out.
|
|
1566
1818
|
"transition-[opacity,transform] duration-(--gryt-dur-spring) ease-spring",
|
|
1567
1819
|
"data-starting-style:translate-y-2 data-starting-style:opacity-0",
|
|
1568
1820
|
"data-ending-style:translate-y-2 data-ending-style:opacity-0",
|
|
1569
1821
|
"motion-reduce:transition-none",
|
|
1570
|
-
|
|
1822
|
+
e
|
|
1571
1823
|
),
|
|
1572
|
-
...
|
|
1824
|
+
...t
|
|
1573
1825
|
}
|
|
1574
1826
|
);
|
|
1575
|
-
}),
|
|
1576
|
-
return /* @__PURE__ */
|
|
1577
|
-
|
|
1827
|
+
}), sr = i(function({ className: e, ...r }, t) {
|
|
1828
|
+
return /* @__PURE__ */ a(
|
|
1829
|
+
R.Title,
|
|
1578
1830
|
{
|
|
1579
|
-
ref:
|
|
1580
|
-
className:
|
|
1831
|
+
ref: t,
|
|
1832
|
+
className: s(
|
|
1581
1833
|
"gryt-toast-title text-sm font-semibold text-gryt-text",
|
|
1582
|
-
|
|
1834
|
+
e
|
|
1583
1835
|
),
|
|
1584
|
-
...
|
|
1836
|
+
...r
|
|
1585
1837
|
}
|
|
1586
1838
|
);
|
|
1587
|
-
}),
|
|
1588
|
-
return /* @__PURE__ */
|
|
1589
|
-
|
|
1839
|
+
}), ir = i(function({ className: e, ...r }, t) {
|
|
1840
|
+
return /* @__PURE__ */ a(
|
|
1841
|
+
R.Description,
|
|
1590
1842
|
{
|
|
1591
|
-
ref:
|
|
1592
|
-
className:
|
|
1843
|
+
ref: t,
|
|
1844
|
+
className: s(
|
|
1593
1845
|
"gryt-toast-description mt-0.5 text-sm leading-6 text-gryt-muted",
|
|
1594
|
-
|
|
1846
|
+
e
|
|
1595
1847
|
),
|
|
1596
|
-
...
|
|
1848
|
+
...r
|
|
1597
1849
|
}
|
|
1598
1850
|
);
|
|
1599
|
-
}),
|
|
1600
|
-
return /* @__PURE__ */
|
|
1601
|
-
|
|
1851
|
+
}), cr = i(function({ className: e, children: r, ...t }, n) {
|
|
1852
|
+
return /* @__PURE__ */ a(
|
|
1853
|
+
R.Close,
|
|
1602
1854
|
{
|
|
1603
|
-
ref:
|
|
1855
|
+
ref: n,
|
|
1604
1856
|
"aria-label": "Close",
|
|
1605
|
-
className:
|
|
1857
|
+
className: s(
|
|
1606
1858
|
"gryt-toast-close absolute top-2.5 right-2.5 inline-flex h-6 w-6 items-center justify-center",
|
|
1607
1859
|
"rounded-(--gryt-radius-full) border-0 bg-transparent text-gryt-muted",
|
|
1608
1860
|
"transition-colors hover:bg-white/8 hover:text-gryt-text motion-reduce:transition-none",
|
|
1609
1861
|
"focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-gryt-accent-light",
|
|
1610
|
-
|
|
1862
|
+
e
|
|
1611
1863
|
),
|
|
1612
|
-
...
|
|
1613
|
-
children:
|
|
1864
|
+
...t,
|
|
1865
|
+
children: r ?? /* @__PURE__ */ a(xt, { size: 14, weight: "bold" })
|
|
1614
1866
|
}
|
|
1615
1867
|
);
|
|
1616
|
-
}),
|
|
1617
|
-
return /* @__PURE__ */
|
|
1618
|
-
|
|
1868
|
+
}), lr = i(function({ className: e, ...r }, t) {
|
|
1869
|
+
return /* @__PURE__ */ a(
|
|
1870
|
+
R.Action,
|
|
1619
1871
|
{
|
|
1620
|
-
ref:
|
|
1621
|
-
className:
|
|
1872
|
+
ref: t,
|
|
1873
|
+
className: s(
|
|
1622
1874
|
"gryt-toast-action mt-2 self-start rounded-(--gryt-radius-full) border-0",
|
|
1623
1875
|
"bg-gryt-accent px-3 py-1.5 text-sm font-medium text-gryt-on-accent",
|
|
1624
1876
|
"transition-[scale] duration-(--gryt-dur-spring) ease-spring",
|
|
1625
1877
|
"motion-safe:hover:scale-[1.04] motion-safe:active:scale-[0.96]",
|
|
1626
1878
|
"focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-gryt-accent-light",
|
|
1627
|
-
|
|
1879
|
+
e
|
|
1628
1880
|
),
|
|
1629
|
-
...
|
|
1881
|
+
...r
|
|
1630
1882
|
}
|
|
1631
1883
|
);
|
|
1632
|
-
}),
|
|
1633
|
-
Provider:
|
|
1634
|
-
Portal:
|
|
1635
|
-
Viewport:
|
|
1636
|
-
Root:
|
|
1637
|
-
Title:
|
|
1638
|
-
Description:
|
|
1639
|
-
Close:
|
|
1640
|
-
Action:
|
|
1641
|
-
},
|
|
1642
|
-
function({ className:
|
|
1643
|
-
return /* @__PURE__ */
|
|
1644
|
-
|
|
1884
|
+
}), ga = {
|
|
1885
|
+
Provider: R.Provider,
|
|
1886
|
+
Portal: R.Portal,
|
|
1887
|
+
Viewport: ar,
|
|
1888
|
+
Root: nr,
|
|
1889
|
+
Title: sr,
|
|
1890
|
+
Description: ir,
|
|
1891
|
+
Close: cr,
|
|
1892
|
+
Action: lr
|
|
1893
|
+
}, ua = R.useToastManager, dr = i(
|
|
1894
|
+
function({ className: e, ...r }, t) {
|
|
1895
|
+
return /* @__PURE__ */ a(
|
|
1896
|
+
E.Root,
|
|
1645
1897
|
{
|
|
1646
|
-
ref:
|
|
1647
|
-
className:
|
|
1648
|
-
...
|
|
1898
|
+
ref: t,
|
|
1899
|
+
className: s("gryt-scroll-area relative", e),
|
|
1900
|
+
...r
|
|
1649
1901
|
}
|
|
1650
1902
|
);
|
|
1651
1903
|
}
|
|
1652
|
-
),
|
|
1653
|
-
function({ className:
|
|
1654
|
-
return /* @__PURE__ */
|
|
1655
|
-
|
|
1904
|
+
), gr = i(
|
|
1905
|
+
function({ className: e, ...r }, t) {
|
|
1906
|
+
return /* @__PURE__ */ a(
|
|
1907
|
+
E.Viewport,
|
|
1656
1908
|
{
|
|
1657
|
-
ref:
|
|
1658
|
-
className:
|
|
1909
|
+
ref: t,
|
|
1910
|
+
className: s(
|
|
1659
1911
|
"gryt-scroll-area-viewport h-full w-full overscroll-contain",
|
|
1660
1912
|
"focus-visible:outline-2 focus-visible:-outline-offset-1 focus-visible:outline-gryt-accent-light",
|
|
1661
|
-
|
|
1913
|
+
e
|
|
1662
1914
|
),
|
|
1663
|
-
...
|
|
1915
|
+
...r
|
|
1664
1916
|
}
|
|
1665
1917
|
);
|
|
1666
1918
|
}
|
|
1667
|
-
),
|
|
1668
|
-
function({ className:
|
|
1669
|
-
return /* @__PURE__ */
|
|
1670
|
-
|
|
1919
|
+
), ur = i(
|
|
1920
|
+
function({ className: e, orientation: r, ...t }, n) {
|
|
1921
|
+
return /* @__PURE__ */ a(
|
|
1922
|
+
E.Scrollbar,
|
|
1671
1923
|
{
|
|
1672
|
-
ref:
|
|
1673
|
-
orientation:
|
|
1674
|
-
className:
|
|
1924
|
+
ref: n,
|
|
1925
|
+
orientation: r,
|
|
1926
|
+
className: s(
|
|
1675
1927
|
"gryt-scroll-area-scrollbar flex touch-none p-0.5 select-none",
|
|
1676
1928
|
// Fades in on hover or while scrolling rather than sitting there
|
|
1677
1929
|
// permanently — a chat sidebar is mostly not being scrolled.
|
|
1678
1930
|
"opacity-0 transition-opacity duration-(--gryt-dur-fast)",
|
|
1679
1931
|
"data-hovering:opacity-100 data-scrolling:opacity-100",
|
|
1680
1932
|
"motion-reduce:transition-none",
|
|
1681
|
-
|
|
1682
|
-
|
|
1933
|
+
r === "horizontal" ? "h-2 flex-col" : "w-2",
|
|
1934
|
+
e
|
|
1683
1935
|
),
|
|
1684
|
-
...
|
|
1685
|
-
children: /* @__PURE__ */
|
|
1936
|
+
...t,
|
|
1937
|
+
children: /* @__PURE__ */ a(E.Thumb, { className: "flex-1 rounded-(--gryt-radius-full) bg-gryt-border transition-colors hover:bg-gryt-muted motion-reduce:transition-none" })
|
|
1686
1938
|
}
|
|
1687
1939
|
);
|
|
1688
1940
|
}
|
|
1689
|
-
),
|
|
1690
|
-
Root:
|
|
1691
|
-
Viewport:
|
|
1692
|
-
Scrollbar:
|
|
1693
|
-
Content:
|
|
1694
|
-
Corner:
|
|
1695
|
-
},
|
|
1941
|
+
), ya = {
|
|
1942
|
+
Root: dr,
|
|
1943
|
+
Viewport: gr,
|
|
1944
|
+
Scrollbar: ur,
|
|
1945
|
+
Content: E.Content,
|
|
1946
|
+
Corner: E.Corner
|
|
1947
|
+
}, yr = {
|
|
1696
1948
|
primary: [
|
|
1697
1949
|
"text-gryt-muted hover:not-data-disabled:bg-white/8",
|
|
1698
1950
|
"data-pressed:bg-gryt-accent data-pressed:text-gryt-on-accent",
|
|
@@ -1713,18 +1965,18 @@ const Mo = {
|
|
|
1713
1965
|
"data-pressed:bg-gryt-danger data-pressed:text-gryt-on-danger",
|
|
1714
1966
|
"data-pressed:hover:not-data-disabled:bg-gryt-danger"
|
|
1715
1967
|
].join(" ")
|
|
1716
|
-
},
|
|
1968
|
+
}, mr = {
|
|
1717
1969
|
xsmall: "h-8 min-w-8 px-2 text-xs",
|
|
1718
1970
|
small: "h-9 min-w-9 px-2.5 text-sm",
|
|
1719
1971
|
medium: "h-10 min-w-10 px-3 text-sm",
|
|
1720
1972
|
large: "h-12 min-w-12 px-4 text-base"
|
|
1721
|
-
},
|
|
1722
|
-
function({ className:
|
|
1723
|
-
return /* @__PURE__ */
|
|
1724
|
-
|
|
1973
|
+
}, ma = i(
|
|
1974
|
+
function({ className: e, size: r = "medium", tone: t = "primary", ...n }, c) {
|
|
1975
|
+
return /* @__PURE__ */ a(
|
|
1976
|
+
Xt,
|
|
1725
1977
|
{
|
|
1726
1978
|
ref: c,
|
|
1727
|
-
className:
|
|
1979
|
+
className: s(
|
|
1728
1980
|
"gryt-toggle",
|
|
1729
1981
|
"inline-flex shrink-0 items-center justify-center gap-2 border-0 bg-transparent",
|
|
1730
1982
|
"rounded-(--gryt-radius-full) font-medium select-none",
|
|
@@ -1732,62 +1984,63 @@ const Mo = {
|
|
|
1732
1984
|
"transition-[scale,background-color,color] duration-(--gryt-dur-spring) ease-spring",
|
|
1733
1985
|
"motion-safe:hover:not-data-disabled:scale-[1.06]",
|
|
1734
1986
|
"motion-safe:active:not-data-disabled:scale-[0.94]",
|
|
1735
|
-
|
|
1736
|
-
|
|
1737
|
-
|
|
1738
|
-
|
|
1739
|
-
|
|
1987
|
+
x,
|
|
1988
|
+
V,
|
|
1989
|
+
mr[r],
|
|
1990
|
+
yr[t],
|
|
1991
|
+
e
|
|
1740
1992
|
),
|
|
1741
|
-
...
|
|
1993
|
+
...n
|
|
1742
1994
|
}
|
|
1743
1995
|
);
|
|
1744
1996
|
}
|
|
1745
|
-
),
|
|
1746
|
-
function({ className:
|
|
1747
|
-
return /* @__PURE__ */
|
|
1748
|
-
|
|
1997
|
+
), pa = i(
|
|
1998
|
+
function({ className: e, ...r }, t) {
|
|
1999
|
+
return /* @__PURE__ */ a(
|
|
2000
|
+
Yt,
|
|
1749
2001
|
{
|
|
1750
|
-
ref:
|
|
1751
|
-
className:
|
|
2002
|
+
ref: t,
|
|
2003
|
+
className: s(
|
|
1752
2004
|
"gryt-toggle-group inline-flex items-center gap-1",
|
|
1753
2005
|
"rounded-(--gryt-radius-full) border border-gryt-border bg-gryt-surface p-1",
|
|
1754
|
-
|
|
2006
|
+
e
|
|
1755
2007
|
),
|
|
1756
|
-
...
|
|
2008
|
+
...r
|
|
1757
2009
|
}
|
|
1758
2010
|
);
|
|
1759
2011
|
}
|
|
1760
|
-
),
|
|
2012
|
+
), pr = {
|
|
1761
2013
|
primary: "bg-gryt-accent",
|
|
1762
2014
|
success: "bg-gryt-success",
|
|
1763
2015
|
warning: "bg-gryt-warning",
|
|
1764
2016
|
danger: "bg-gryt-danger"
|
|
1765
2017
|
};
|
|
1766
|
-
function
|
|
1767
|
-
className:
|
|
1768
|
-
value:
|
|
1769
|
-
label:
|
|
1770
|
-
showValue:
|
|
1771
|
-
tone:
|
|
2018
|
+
function fa({
|
|
2019
|
+
className: o,
|
|
2020
|
+
value: e,
|
|
2021
|
+
label: r,
|
|
2022
|
+
showValue: t = !1,
|
|
2023
|
+
tone: n = "primary",
|
|
1772
2024
|
...c
|
|
1773
2025
|
}) {
|
|
1774
|
-
return /* @__PURE__ */
|
|
1775
|
-
|
|
2026
|
+
return /* @__PURE__ */ p(
|
|
2027
|
+
H.Root,
|
|
1776
2028
|
{
|
|
1777
|
-
value:
|
|
1778
|
-
className:
|
|
2029
|
+
value: e,
|
|
2030
|
+
className: s("gryt-meter flex w-full flex-col gap-1.5", o),
|
|
1779
2031
|
...c,
|
|
1780
2032
|
children: [
|
|
1781
|
-
(
|
|
1782
|
-
|
|
1783
|
-
|
|
2033
|
+
(r || t) && /* @__PURE__ */ p("div", { className: "flex items-baseline justify-between gap-2", children: [
|
|
2034
|
+
r ? /* @__PURE__ */ a(H.Label, { className: "text-sm text-gryt-muted", children: r }) : /* @__PURE__ */ a("span", {}),
|
|
2035
|
+
t && /* @__PURE__ */ a(H.Value, { className: "font-mono text-xs text-gryt-muted tabular-nums" })
|
|
1784
2036
|
] }),
|
|
1785
|
-
/* @__PURE__ */
|
|
1786
|
-
|
|
2037
|
+
/* @__PURE__ */ a(H.Track, { className: "h-1.5 w-full overflow-hidden rounded-(--gryt-radius-full) bg-gryt-surface-raised", children: /* @__PURE__ */ a(
|
|
2038
|
+
H.Indicator,
|
|
1787
2039
|
{
|
|
1788
|
-
className:
|
|
2040
|
+
className: s(
|
|
1789
2041
|
"h-full rounded-(--gryt-radius-full)",
|
|
1790
|
-
|
|
2042
|
+
"transition-[width] duration-120 ease-out motion-reduce:transition-none",
|
|
2043
|
+
pr[n]
|
|
1791
2044
|
)
|
|
1792
2045
|
}
|
|
1793
2046
|
) })
|
|
@@ -1795,13 +2048,13 @@ function Ho({
|
|
|
1795
2048
|
}
|
|
1796
2049
|
);
|
|
1797
2050
|
}
|
|
1798
|
-
const
|
|
1799
|
-
function({ className:
|
|
1800
|
-
return /* @__PURE__ */
|
|
1801
|
-
|
|
2051
|
+
const fr = i(
|
|
2052
|
+
function({ className: e, ...r }, t) {
|
|
2053
|
+
return /* @__PURE__ */ a(
|
|
2054
|
+
M.Popup,
|
|
1802
2055
|
{
|
|
1803
|
-
ref:
|
|
1804
|
-
className:
|
|
2056
|
+
ref: t,
|
|
2057
|
+
className: s(
|
|
1805
2058
|
"gryt-alert-dialog fixed top-1/2 left-1/2 z-50 -translate-x-1/2 -translate-y-1/2",
|
|
1806
2059
|
"flex w-96 max-w-[calc(100vw-3rem)] flex-col gap-4",
|
|
1807
2060
|
"rounded-(--gryt-radius-lg) border border-gryt-border bg-gryt-surface p-5 text-gryt-text",
|
|
@@ -1809,61 +2062,61 @@ const Oe = s(
|
|
|
1809
2062
|
"transition-[opacity,scale] duration-(--gryt-dur-spring) ease-spring motion-reduce:transition-none",
|
|
1810
2063
|
"data-starting-style:scale-[0.98] data-starting-style:opacity-0",
|
|
1811
2064
|
"data-ending-style:scale-[0.98] data-ending-style:opacity-0",
|
|
1812
|
-
|
|
2065
|
+
e
|
|
1813
2066
|
),
|
|
1814
|
-
...
|
|
2067
|
+
...r
|
|
1815
2068
|
}
|
|
1816
2069
|
);
|
|
1817
2070
|
}
|
|
1818
|
-
),
|
|
1819
|
-
return /* @__PURE__ */
|
|
1820
|
-
|
|
2071
|
+
), br = i(function({ className: e, ...r }, t) {
|
|
2072
|
+
return /* @__PURE__ */ a(
|
|
2073
|
+
M.Backdrop,
|
|
1821
2074
|
{
|
|
1822
|
-
ref:
|
|
1823
|
-
className:
|
|
2075
|
+
ref: t,
|
|
2076
|
+
className: s(
|
|
1824
2077
|
"gryt-alert-dialog-backdrop fixed inset-0 z-50 min-h-dvh bg-black/60",
|
|
1825
2078
|
"backdrop-blur-(--gryt-backdrop-blur)",
|
|
1826
2079
|
"transition-opacity duration-(--gryt-dur-spring) ease-spring motion-reduce:transition-none",
|
|
1827
2080
|
"data-starting-style:opacity-0 data-ending-style:opacity-0",
|
|
1828
|
-
|
|
2081
|
+
e
|
|
1829
2082
|
),
|
|
1830
|
-
...
|
|
2083
|
+
...r
|
|
1831
2084
|
}
|
|
1832
2085
|
);
|
|
1833
|
-
}),
|
|
1834
|
-
return /* @__PURE__ */
|
|
1835
|
-
|
|
2086
|
+
}), hr = i(function({ className: e, ...r }, t) {
|
|
2087
|
+
return /* @__PURE__ */ a(
|
|
2088
|
+
M.Title,
|
|
1836
2089
|
{
|
|
1837
|
-
ref:
|
|
1838
|
-
className:
|
|
2090
|
+
ref: t,
|
|
2091
|
+
className: s(
|
|
1839
2092
|
"gryt-alert-dialog-title text-lg font-semibold text-gryt-text",
|
|
1840
|
-
|
|
2093
|
+
e
|
|
1841
2094
|
),
|
|
1842
|
-
...
|
|
2095
|
+
...r
|
|
1843
2096
|
}
|
|
1844
2097
|
);
|
|
1845
|
-
}),
|
|
1846
|
-
return /* @__PURE__ */
|
|
1847
|
-
|
|
2098
|
+
}), xr = i(function({ className: e, ...r }, t) {
|
|
2099
|
+
return /* @__PURE__ */ a(
|
|
2100
|
+
M.Description,
|
|
1848
2101
|
{
|
|
1849
|
-
ref:
|
|
1850
|
-
className:
|
|
2102
|
+
ref: t,
|
|
2103
|
+
className: s(
|
|
1851
2104
|
"gryt-alert-dialog-description text-sm leading-6 text-gryt-muted",
|
|
1852
|
-
|
|
2105
|
+
e
|
|
1853
2106
|
),
|
|
1854
|
-
...
|
|
2107
|
+
...r
|
|
1855
2108
|
}
|
|
1856
2109
|
);
|
|
1857
|
-
}),
|
|
1858
|
-
Root:
|
|
1859
|
-
Trigger:
|
|
1860
|
-
Portal:
|
|
1861
|
-
Backdrop:
|
|
1862
|
-
Popup:
|
|
1863
|
-
Title:
|
|
1864
|
-
Description:
|
|
1865
|
-
Close:
|
|
1866
|
-
},
|
|
2110
|
+
}), ba = {
|
|
2111
|
+
Root: M.Root,
|
|
2112
|
+
Trigger: M.Trigger,
|
|
2113
|
+
Portal: M.Portal,
|
|
2114
|
+
Backdrop: br,
|
|
2115
|
+
Popup: fr,
|
|
2116
|
+
Title: hr,
|
|
2117
|
+
Description: xr,
|
|
2118
|
+
Close: M.Close
|
|
2119
|
+
}, Rt = [
|
|
1867
2120
|
"flex cursor-default items-center gap-2 rounded-(--gryt-radius-md)",
|
|
1868
2121
|
"px-3 py-2 text-sm text-gryt-text outline-none select-none",
|
|
1869
2122
|
// Base UI drives keyboard and pointer highlight through one attribute, so
|
|
@@ -1871,377 +2124,378 @@ const Oe = s(
|
|
|
1871
2124
|
"data-highlighted:bg-gryt-surface-raised",
|
|
1872
2125
|
"data-selected:text-gryt-accent",
|
|
1873
2126
|
"data-disabled:cursor-not-allowed data-disabled:opacity-50"
|
|
1874
|
-
].join(" "),
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
2127
|
+
].join(" "), It = [
|
|
2128
|
+
kt,
|
|
2129
|
+
$t.medium,
|
|
2130
|
+
"border-gryt-border",
|
|
2131
|
+
x
|
|
2132
|
+
].join(" "), wr = i(function({ className: e, ...r }, t) {
|
|
2133
|
+
return /* @__PURE__ */ a(
|
|
2134
|
+
b.Input,
|
|
1881
2135
|
{
|
|
1882
|
-
ref:
|
|
1883
|
-
className:
|
|
1884
|
-
...
|
|
2136
|
+
ref: t,
|
|
2137
|
+
className: s("gryt-combobox-input", It, e),
|
|
2138
|
+
...r
|
|
1885
2139
|
}
|
|
1886
2140
|
);
|
|
1887
|
-
}),
|
|
1888
|
-
return /* @__PURE__ */
|
|
1889
|
-
|
|
2141
|
+
}), vr = i(function({ className: e, sideOffset: r = 6, ...t }, n) {
|
|
2142
|
+
return /* @__PURE__ */ a(
|
|
2143
|
+
b.Positioner,
|
|
1890
2144
|
{
|
|
1891
|
-
ref:
|
|
1892
|
-
sideOffset:
|
|
1893
|
-
className:
|
|
1894
|
-
...
|
|
2145
|
+
ref: n,
|
|
2146
|
+
sideOffset: r,
|
|
2147
|
+
className: s("gryt-combobox-positioner outline-none", e),
|
|
2148
|
+
...t
|
|
1895
2149
|
}
|
|
1896
2150
|
);
|
|
1897
|
-
}),
|
|
1898
|
-
function({ className:
|
|
1899
|
-
return /* @__PURE__ */
|
|
1900
|
-
|
|
2151
|
+
}), Nr = i(
|
|
2152
|
+
function({ className: e, ...r }, t) {
|
|
2153
|
+
return /* @__PURE__ */ a(
|
|
2154
|
+
b.Popup,
|
|
1901
2155
|
{
|
|
1902
|
-
ref:
|
|
1903
|
-
className:
|
|
2156
|
+
ref: t,
|
|
2157
|
+
className: s(
|
|
1904
2158
|
"gryt-combobox max-h-64 w-(--anchor-width) overflow-y-auto overscroll-contain p-1 outline-none",
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
2159
|
+
B,
|
|
2160
|
+
A,
|
|
2161
|
+
e
|
|
1908
2162
|
),
|
|
1909
|
-
...
|
|
2163
|
+
...r
|
|
1910
2164
|
}
|
|
1911
2165
|
);
|
|
1912
2166
|
}
|
|
1913
|
-
),
|
|
1914
|
-
return /* @__PURE__ */
|
|
1915
|
-
|
|
2167
|
+
), Pr = i(function({ className: e, ...r }, t) {
|
|
2168
|
+
return /* @__PURE__ */ a(
|
|
2169
|
+
b.Item,
|
|
1916
2170
|
{
|
|
1917
|
-
ref:
|
|
1918
|
-
className:
|
|
1919
|
-
...
|
|
2171
|
+
ref: t,
|
|
2172
|
+
className: s("gryt-combobox-item", Rt, e),
|
|
2173
|
+
...r
|
|
1920
2174
|
}
|
|
1921
2175
|
);
|
|
1922
|
-
}),
|
|
1923
|
-
return /* @__PURE__ */
|
|
1924
|
-
|
|
2176
|
+
}), Tr = i(function({ className: e, ...r }, t) {
|
|
2177
|
+
return /* @__PURE__ */ a(
|
|
2178
|
+
b.Empty,
|
|
1925
2179
|
{
|
|
1926
|
-
ref:
|
|
1927
|
-
className:
|
|
2180
|
+
ref: t,
|
|
2181
|
+
className: s(
|
|
1928
2182
|
"gryt-combobox-empty px-3 py-2 text-sm text-gryt-muted",
|
|
1929
|
-
|
|
2183
|
+
e
|
|
1930
2184
|
),
|
|
1931
|
-
...
|
|
2185
|
+
...r
|
|
1932
2186
|
}
|
|
1933
2187
|
);
|
|
1934
|
-
}),
|
|
1935
|
-
Root:
|
|
1936
|
-
Input:
|
|
1937
|
-
InputGroup:
|
|
1938
|
-
Trigger:
|
|
1939
|
-
Icon:
|
|
1940
|
-
Clear:
|
|
1941
|
-
Value:
|
|
1942
|
-
Chips:
|
|
1943
|
-
Chip:
|
|
1944
|
-
ChipRemove:
|
|
1945
|
-
Portal:
|
|
1946
|
-
Positioner:
|
|
1947
|
-
Popup:
|
|
1948
|
-
List:
|
|
1949
|
-
Item:
|
|
1950
|
-
ItemIndicator:
|
|
1951
|
-
Group:
|
|
1952
|
-
GroupLabel:
|
|
1953
|
-
Empty:
|
|
1954
|
-
Separator:
|
|
1955
|
-
},
|
|
1956
|
-
return /* @__PURE__ */
|
|
1957
|
-
|
|
2188
|
+
}), ha = {
|
|
2189
|
+
Root: b.Root,
|
|
2190
|
+
Input: wr,
|
|
2191
|
+
InputGroup: b.InputGroup,
|
|
2192
|
+
Trigger: b.Trigger,
|
|
2193
|
+
Icon: b.Icon,
|
|
2194
|
+
Clear: b.Clear,
|
|
2195
|
+
Value: b.Value,
|
|
2196
|
+
Chips: b.Chips,
|
|
2197
|
+
Chip: b.Chip,
|
|
2198
|
+
ChipRemove: b.ChipRemove,
|
|
2199
|
+
Portal: b.Portal,
|
|
2200
|
+
Positioner: vr,
|
|
2201
|
+
Popup: Nr,
|
|
2202
|
+
List: b.List,
|
|
2203
|
+
Item: Pr,
|
|
2204
|
+
ItemIndicator: b.ItemIndicator,
|
|
2205
|
+
Group: b.Group,
|
|
2206
|
+
GroupLabel: b.GroupLabel,
|
|
2207
|
+
Empty: Tr,
|
|
2208
|
+
Separator: b.Separator
|
|
2209
|
+
}, kr = i(function({ className: e, ...r }, t) {
|
|
2210
|
+
return /* @__PURE__ */ a(
|
|
2211
|
+
h.Input,
|
|
1958
2212
|
{
|
|
1959
|
-
ref:
|
|
1960
|
-
className:
|
|
1961
|
-
...
|
|
2213
|
+
ref: t,
|
|
2214
|
+
className: s("gryt-autocomplete-input", It, e),
|
|
2215
|
+
...r
|
|
1962
2216
|
}
|
|
1963
2217
|
);
|
|
1964
|
-
}),
|
|
1965
|
-
return /* @__PURE__ */
|
|
1966
|
-
|
|
2218
|
+
}), $r = i(function({ className: e, sideOffset: r = 6, ...t }, n) {
|
|
2219
|
+
return /* @__PURE__ */ a(
|
|
2220
|
+
h.Positioner,
|
|
1967
2221
|
{
|
|
1968
|
-
ref:
|
|
1969
|
-
sideOffset:
|
|
1970
|
-
className:
|
|
1971
|
-
...
|
|
2222
|
+
ref: n,
|
|
2223
|
+
sideOffset: r,
|
|
2224
|
+
className: s("gryt-autocomplete-positioner outline-none", e),
|
|
2225
|
+
...t
|
|
1972
2226
|
}
|
|
1973
2227
|
);
|
|
1974
|
-
}),
|
|
1975
|
-
return /* @__PURE__ */
|
|
1976
|
-
|
|
2228
|
+
}), Cr = i(function({ className: e, ...r }, t) {
|
|
2229
|
+
return /* @__PURE__ */ a(
|
|
2230
|
+
h.Popup,
|
|
1977
2231
|
{
|
|
1978
|
-
ref:
|
|
1979
|
-
className:
|
|
2232
|
+
ref: t,
|
|
2233
|
+
className: s(
|
|
1980
2234
|
"gryt-autocomplete max-h-64 w-(--anchor-width) overflow-y-auto overscroll-contain p-1 outline-none",
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
2235
|
+
B,
|
|
2236
|
+
A,
|
|
2237
|
+
e
|
|
1984
2238
|
),
|
|
1985
|
-
...
|
|
2239
|
+
...r
|
|
1986
2240
|
}
|
|
1987
2241
|
);
|
|
1988
|
-
}),
|
|
1989
|
-
return /* @__PURE__ */
|
|
1990
|
-
|
|
2242
|
+
}), Sr = i(function({ className: e, ...r }, t) {
|
|
2243
|
+
return /* @__PURE__ */ a(
|
|
2244
|
+
h.Item,
|
|
1991
2245
|
{
|
|
1992
|
-
ref:
|
|
1993
|
-
className:
|
|
1994
|
-
...
|
|
2246
|
+
ref: t,
|
|
2247
|
+
className: s("gryt-autocomplete-item", Rt, e),
|
|
2248
|
+
...r
|
|
1995
2249
|
}
|
|
1996
2250
|
);
|
|
1997
|
-
}),
|
|
1998
|
-
return /* @__PURE__ */
|
|
1999
|
-
|
|
2251
|
+
}), Rr = i(function({ className: e, ...r }, t) {
|
|
2252
|
+
return /* @__PURE__ */ a(
|
|
2253
|
+
h.Empty,
|
|
2000
2254
|
{
|
|
2001
|
-
ref:
|
|
2002
|
-
className:
|
|
2255
|
+
ref: t,
|
|
2256
|
+
className: s(
|
|
2003
2257
|
"gryt-autocomplete-empty px-3 py-2 text-sm text-gryt-muted",
|
|
2004
|
-
|
|
2258
|
+
e
|
|
2005
2259
|
),
|
|
2006
|
-
...
|
|
2260
|
+
...r
|
|
2007
2261
|
}
|
|
2008
2262
|
);
|
|
2009
|
-
}),
|
|
2010
|
-
Root:
|
|
2011
|
-
Input:
|
|
2012
|
-
InputGroup:
|
|
2013
|
-
Trigger:
|
|
2014
|
-
Icon:
|
|
2015
|
-
Clear:
|
|
2016
|
-
Value:
|
|
2017
|
-
Portal:
|
|
2018
|
-
Positioner:
|
|
2019
|
-
Popup:
|
|
2020
|
-
List:
|
|
2021
|
-
Item:
|
|
2022
|
-
Group:
|
|
2023
|
-
GroupLabel:
|
|
2024
|
-
Empty:
|
|
2025
|
-
Separator:
|
|
2026
|
-
},
|
|
2027
|
-
function({ className:
|
|
2028
|
-
return /* @__PURE__ */
|
|
2029
|
-
|
|
2263
|
+
}), xa = {
|
|
2264
|
+
Root: h.Root,
|
|
2265
|
+
Input: kr,
|
|
2266
|
+
InputGroup: h.InputGroup,
|
|
2267
|
+
Trigger: h.Trigger,
|
|
2268
|
+
Icon: h.Icon,
|
|
2269
|
+
Clear: h.Clear,
|
|
2270
|
+
Value: h.Value,
|
|
2271
|
+
Portal: h.Portal,
|
|
2272
|
+
Positioner: $r,
|
|
2273
|
+
Popup: Cr,
|
|
2274
|
+
List: h.List,
|
|
2275
|
+
Item: Sr,
|
|
2276
|
+
Group: h.Group,
|
|
2277
|
+
GroupLabel: h.GroupLabel,
|
|
2278
|
+
Empty: Rr,
|
|
2279
|
+
Separator: h.Separator
|
|
2280
|
+
}, wa = i(
|
|
2281
|
+
function({ className: e, ...r }, t) {
|
|
2282
|
+
return /* @__PURE__ */ a(
|
|
2283
|
+
Wt,
|
|
2030
2284
|
{
|
|
2031
|
-
ref:
|
|
2032
|
-
className:
|
|
2033
|
-
...
|
|
2285
|
+
ref: t,
|
|
2286
|
+
className: s("gryt-checkbox-group flex flex-col gap-2", e),
|
|
2287
|
+
...r
|
|
2034
2288
|
}
|
|
2035
2289
|
);
|
|
2036
2290
|
}
|
|
2037
|
-
),
|
|
2038
|
-
function({ className:
|
|
2039
|
-
return /* @__PURE__ */
|
|
2040
|
-
|
|
2291
|
+
), Ir = i(
|
|
2292
|
+
function({ className: e, ...r }, t) {
|
|
2293
|
+
return /* @__PURE__ */ a(
|
|
2294
|
+
st.Trigger,
|
|
2041
2295
|
{
|
|
2042
|
-
ref:
|
|
2043
|
-
className:
|
|
2296
|
+
ref: t,
|
|
2297
|
+
className: s(
|
|
2044
2298
|
"gryt-collapsible-trigger flex w-full items-center justify-between gap-2",
|
|
2045
2299
|
"rounded-(--gryt-radius-md) border-0 bg-transparent px-2 py-2 text-left",
|
|
2046
2300
|
"text-sm font-medium text-gryt-text select-none",
|
|
2047
2301
|
"transition-colors hover:bg-gryt-surface-raised motion-reduce:transition-none",
|
|
2048
|
-
|
|
2049
|
-
|
|
2302
|
+
x,
|
|
2303
|
+
e
|
|
2050
2304
|
),
|
|
2051
|
-
...
|
|
2305
|
+
...r
|
|
2052
2306
|
}
|
|
2053
2307
|
);
|
|
2054
2308
|
}
|
|
2055
|
-
),
|
|
2056
|
-
function({ className:
|
|
2057
|
-
return /* @__PURE__ */
|
|
2058
|
-
|
|
2309
|
+
), Lr = i(
|
|
2310
|
+
function({ className: e, ...r }, t) {
|
|
2311
|
+
return /* @__PURE__ */ a(
|
|
2312
|
+
st.Panel,
|
|
2059
2313
|
{
|
|
2060
|
-
ref:
|
|
2061
|
-
className:
|
|
2314
|
+
ref: t,
|
|
2315
|
+
className: s(
|
|
2062
2316
|
"gryt-collapsible-panel overflow-hidden",
|
|
2063
2317
|
// Base UI measures the panel and exposes the height as a variable, so
|
|
2064
2318
|
// this animates to the content's real height rather than to a guess.
|
|
2065
2319
|
"h-(--collapsible-panel-height) transition-[height] duration-(--gryt-dur-spring) ease-spring",
|
|
2066
2320
|
"data-starting-style:h-0 data-ending-style:h-0",
|
|
2067
2321
|
"motion-reduce:transition-none",
|
|
2068
|
-
|
|
2322
|
+
e
|
|
2069
2323
|
),
|
|
2070
|
-
...
|
|
2324
|
+
...r
|
|
2071
2325
|
}
|
|
2072
2326
|
);
|
|
2073
2327
|
}
|
|
2074
|
-
),
|
|
2075
|
-
Root:
|
|
2076
|
-
Trigger:
|
|
2077
|
-
Panel:
|
|
2078
|
-
},
|
|
2079
|
-
return /* @__PURE__ */
|
|
2080
|
-
|
|
2328
|
+
), va = {
|
|
2329
|
+
Root: st.Root,
|
|
2330
|
+
Trigger: Ir,
|
|
2331
|
+
Panel: Lr
|
|
2332
|
+
}, Na = i(function({ className: e, ...r }, t) {
|
|
2333
|
+
return /* @__PURE__ */ a(
|
|
2334
|
+
Qt,
|
|
2081
2335
|
{
|
|
2082
|
-
ref:
|
|
2083
|
-
className:
|
|
2084
|
-
...
|
|
2336
|
+
ref: t,
|
|
2337
|
+
className: s("gryt-form flex flex-col gap-(--gryt-space-lg)", e),
|
|
2338
|
+
...r
|
|
2085
2339
|
}
|
|
2086
2340
|
);
|
|
2087
|
-
}),
|
|
2088
|
-
function({ className:
|
|
2089
|
-
return /* @__PURE__ */
|
|
2090
|
-
|
|
2341
|
+
}), Mr = i(
|
|
2342
|
+
function({ className: e, ...r }, t) {
|
|
2343
|
+
return /* @__PURE__ */ a(
|
|
2344
|
+
vt.Root,
|
|
2091
2345
|
{
|
|
2092
|
-
ref:
|
|
2093
|
-
className:
|
|
2346
|
+
ref: t,
|
|
2347
|
+
className: s(
|
|
2094
2348
|
"gryt-fieldset flex min-w-0 flex-col gap-3 border-0 p-0",
|
|
2095
|
-
|
|
2349
|
+
e
|
|
2096
2350
|
),
|
|
2097
|
-
...
|
|
2351
|
+
...r
|
|
2098
2352
|
}
|
|
2099
2353
|
);
|
|
2100
2354
|
}
|
|
2101
|
-
),
|
|
2102
|
-
return /* @__PURE__ */
|
|
2103
|
-
|
|
2355
|
+
), Ar = i(function({ className: e, ...r }, t) {
|
|
2356
|
+
return /* @__PURE__ */ a(
|
|
2357
|
+
vt.Legend,
|
|
2104
2358
|
{
|
|
2105
|
-
ref:
|
|
2106
|
-
className:
|
|
2359
|
+
ref: t,
|
|
2360
|
+
className: s(
|
|
2107
2361
|
"gryt-fieldset-legend text-sm font-semibold text-gryt-text",
|
|
2108
|
-
|
|
2362
|
+
e
|
|
2109
2363
|
),
|
|
2110
|
-
...
|
|
2364
|
+
...r
|
|
2111
2365
|
}
|
|
2112
2366
|
);
|
|
2113
|
-
}),
|
|
2114
|
-
function({ className:
|
|
2115
|
-
return /* @__PURE__ */
|
|
2116
|
-
|
|
2367
|
+
}), Pa = { Root: Mr, Legend: Ar }, Ta = i(
|
|
2368
|
+
function({ className: e, ...r }, t) {
|
|
2369
|
+
return /* @__PURE__ */ a(
|
|
2370
|
+
Jt,
|
|
2117
2371
|
{
|
|
2118
|
-
ref:
|
|
2119
|
-
className:
|
|
2372
|
+
ref: t,
|
|
2373
|
+
className: s(
|
|
2120
2374
|
"gryt-menubar flex items-center gap-1",
|
|
2121
2375
|
"rounded-(--gryt-radius-md) border border-gryt-border bg-gryt-surface p-1",
|
|
2122
|
-
|
|
2376
|
+
e
|
|
2123
2377
|
),
|
|
2124
|
-
...
|
|
2378
|
+
...r
|
|
2125
2379
|
}
|
|
2126
2380
|
);
|
|
2127
2381
|
}
|
|
2128
|
-
),
|
|
2129
|
-
return /* @__PURE__ */
|
|
2130
|
-
|
|
2382
|
+
), Dr = i(function({ className: e, ...r }, t) {
|
|
2383
|
+
return /* @__PURE__ */ a(
|
|
2384
|
+
N.Trigger,
|
|
2131
2385
|
{
|
|
2132
|
-
ref:
|
|
2133
|
-
className:
|
|
2386
|
+
ref: t,
|
|
2387
|
+
className: s(
|
|
2134
2388
|
"gryt-navigation-menu-trigger flex items-center gap-1.5 rounded-(--gryt-radius-md)",
|
|
2135
2389
|
"border-0 bg-transparent px-3 py-2 text-sm font-medium text-gryt-text select-none",
|
|
2136
2390
|
"transition-colors hover:bg-gryt-surface-raised motion-reduce:transition-none",
|
|
2137
2391
|
"data-popup-open:bg-gryt-surface-raised",
|
|
2138
|
-
|
|
2139
|
-
|
|
2392
|
+
x,
|
|
2393
|
+
e
|
|
2140
2394
|
),
|
|
2141
|
-
...
|
|
2395
|
+
...r
|
|
2142
2396
|
}
|
|
2143
2397
|
);
|
|
2144
|
-
}),
|
|
2145
|
-
return /* @__PURE__ */
|
|
2146
|
-
|
|
2398
|
+
}), jr = i(function({ className: e, ...r }, t) {
|
|
2399
|
+
return /* @__PURE__ */ a(
|
|
2400
|
+
N.Popup,
|
|
2147
2401
|
{
|
|
2148
|
-
ref:
|
|
2149
|
-
className:
|
|
2402
|
+
ref: t,
|
|
2403
|
+
className: s(
|
|
2150
2404
|
"gryt-navigation-menu-popup outline-none",
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2405
|
+
B,
|
|
2406
|
+
A,
|
|
2407
|
+
e
|
|
2154
2408
|
),
|
|
2155
|
-
...
|
|
2409
|
+
...r
|
|
2156
2410
|
}
|
|
2157
2411
|
);
|
|
2158
|
-
}),
|
|
2159
|
-
return /* @__PURE__ */
|
|
2160
|
-
|
|
2412
|
+
}), Gr = i(function({ className: e, ...r }, t) {
|
|
2413
|
+
return /* @__PURE__ */ a(
|
|
2414
|
+
N.Viewport,
|
|
2161
2415
|
{
|
|
2162
|
-
ref:
|
|
2163
|
-
className:
|
|
2416
|
+
ref: t,
|
|
2417
|
+
className: s(
|
|
2164
2418
|
"gryt-navigation-menu-viewport relative overflow-hidden",
|
|
2165
|
-
|
|
2419
|
+
e
|
|
2166
2420
|
),
|
|
2167
|
-
...
|
|
2421
|
+
...r
|
|
2168
2422
|
}
|
|
2169
2423
|
);
|
|
2170
|
-
}),
|
|
2171
|
-
return /* @__PURE__ */
|
|
2172
|
-
|
|
2424
|
+
}), Br = i(function({ className: e, ...r }, t) {
|
|
2425
|
+
return /* @__PURE__ */ a(
|
|
2426
|
+
N.Link,
|
|
2173
2427
|
{
|
|
2174
|
-
ref:
|
|
2175
|
-
className:
|
|
2428
|
+
ref: t,
|
|
2429
|
+
className: s(
|
|
2176
2430
|
"gryt-navigation-menu-link block rounded-(--gryt-radius-md) px-3 py-2",
|
|
2177
2431
|
"text-sm text-gryt-text no-underline outline-none",
|
|
2178
2432
|
"transition-colors hover:bg-gryt-surface-raised motion-reduce:transition-none",
|
|
2179
|
-
|
|
2180
|
-
|
|
2433
|
+
x,
|
|
2434
|
+
e
|
|
2181
2435
|
),
|
|
2182
|
-
...
|
|
2436
|
+
...r
|
|
2183
2437
|
}
|
|
2184
2438
|
);
|
|
2185
|
-
}),
|
|
2186
|
-
Root:
|
|
2187
|
-
List:
|
|
2188
|
-
Item:
|
|
2189
|
-
Trigger:
|
|
2190
|
-
Content:
|
|
2191
|
-
Portal:
|
|
2192
|
-
Positioner:
|
|
2193
|
-
Viewport:
|
|
2194
|
-
Popup:
|
|
2195
|
-
Link:
|
|
2196
|
-
Icon:
|
|
2197
|
-
Arrow:
|
|
2198
|
-
},
|
|
2199
|
-
function({ className:
|
|
2200
|
-
return /* @__PURE__ */
|
|
2201
|
-
|
|
2439
|
+
}), ka = {
|
|
2440
|
+
Root: N.Root,
|
|
2441
|
+
List: N.List,
|
|
2442
|
+
Item: N.Item,
|
|
2443
|
+
Trigger: Dr,
|
|
2444
|
+
Content: N.Content,
|
|
2445
|
+
Portal: N.Portal,
|
|
2446
|
+
Positioner: N.Positioner,
|
|
2447
|
+
Viewport: Gr,
|
|
2448
|
+
Popup: jr,
|
|
2449
|
+
Link: Br,
|
|
2450
|
+
Icon: N.Icon,
|
|
2451
|
+
Arrow: N.Arrow
|
|
2452
|
+
}, ft = "flex h-9 w-9 shrink-0 items-center justify-center border-0 bg-transparent text-gryt-muted transition-colors hover:not-data-disabled:bg-white/8 hover:not-data-disabled:text-gryt-text motion-reduce:transition-none disabled:cursor-not-allowed disabled:opacity-50", $a = i(
|
|
2453
|
+
function({ className: e, label: r, scrubbable: t = !1, ...n }, c) {
|
|
2454
|
+
return /* @__PURE__ */ p(
|
|
2455
|
+
D.Root,
|
|
2202
2456
|
{
|
|
2203
2457
|
ref: c,
|
|
2204
|
-
className:
|
|
2205
|
-
...
|
|
2458
|
+
className: s("gryt-number-field flex flex-col gap-1.5", e),
|
|
2459
|
+
...n,
|
|
2206
2460
|
children: [
|
|
2207
|
-
|
|
2208
|
-
|
|
2209
|
-
/* @__PURE__ */
|
|
2210
|
-
] }) : /* @__PURE__ */
|
|
2211
|
-
/* @__PURE__ */
|
|
2212
|
-
|
|
2461
|
+
r && (t ? /* @__PURE__ */ p(D.ScrubArea, { className: "cursor-ew-resize text-sm text-gryt-muted select-none", children: [
|
|
2462
|
+
r,
|
|
2463
|
+
/* @__PURE__ */ a(D.ScrubAreaCursor, {})
|
|
2464
|
+
] }) : /* @__PURE__ */ a("span", { className: "text-sm text-gryt-muted", children: r })),
|
|
2465
|
+
/* @__PURE__ */ p(
|
|
2466
|
+
D.Group,
|
|
2213
2467
|
{
|
|
2214
|
-
className:
|
|
2468
|
+
className: s(
|
|
2215
2469
|
"flex w-fit items-center overflow-hidden rounded-(--gryt-radius-full)",
|
|
2216
2470
|
"border border-gryt-border bg-gryt-surface-raised",
|
|
2217
2471
|
"focus-within:outline-2 focus-within:outline-offset-2 focus-within:outline-gryt-accent-light",
|
|
2218
|
-
|
|
2472
|
+
V
|
|
2219
2473
|
),
|
|
2220
2474
|
children: [
|
|
2221
|
-
/* @__PURE__ */
|
|
2222
|
-
|
|
2475
|
+
/* @__PURE__ */ a(
|
|
2476
|
+
D.Decrement,
|
|
2223
2477
|
{
|
|
2224
2478
|
"aria-label": "Decrease",
|
|
2225
|
-
className:
|
|
2226
|
-
children: /* @__PURE__ */
|
|
2479
|
+
className: s(ft, "rounded-l-(--gryt-radius-full)"),
|
|
2480
|
+
children: /* @__PURE__ */ a(_t, { size: 14, weight: "bold" })
|
|
2227
2481
|
}
|
|
2228
2482
|
),
|
|
2229
|
-
/* @__PURE__ */
|
|
2230
|
-
|
|
2483
|
+
/* @__PURE__ */ a(
|
|
2484
|
+
D.Input,
|
|
2231
2485
|
{
|
|
2232
|
-
className:
|
|
2486
|
+
className: s(
|
|
2233
2487
|
"w-16 border-0 bg-transparent px-1 py-2 text-center",
|
|
2234
2488
|
"font-mono text-sm text-gryt-text tabular-nums outline-none",
|
|
2235
|
-
|
|
2489
|
+
x
|
|
2236
2490
|
)
|
|
2237
2491
|
}
|
|
2238
2492
|
),
|
|
2239
|
-
/* @__PURE__ */
|
|
2240
|
-
|
|
2493
|
+
/* @__PURE__ */ a(
|
|
2494
|
+
D.Increment,
|
|
2241
2495
|
{
|
|
2242
2496
|
"aria-label": "Increase",
|
|
2243
|
-
className:
|
|
2244
|
-
children: /* @__PURE__ */
|
|
2497
|
+
className: s(ft, "rounded-r-(--gryt-radius-full)"),
|
|
2498
|
+
children: /* @__PURE__ */ a(Ht, { size: 14, weight: "bold" })
|
|
2245
2499
|
}
|
|
2246
2500
|
)
|
|
2247
2501
|
]
|
|
@@ -2251,25 +2505,25 @@ const Oe = s(
|
|
|
2251
2505
|
}
|
|
2252
2506
|
);
|
|
2253
2507
|
}
|
|
2254
|
-
),
|
|
2255
|
-
function({ className:
|
|
2256
|
-
return /* @__PURE__ */
|
|
2257
|
-
|
|
2508
|
+
), Ca = i(
|
|
2509
|
+
function({ className: e, length: r = 6, ...t }, n) {
|
|
2510
|
+
return /* @__PURE__ */ a(
|
|
2511
|
+
ut.Root,
|
|
2258
2512
|
{
|
|
2259
|
-
ref:
|
|
2260
|
-
length:
|
|
2261
|
-
className:
|
|
2262
|
-
...
|
|
2263
|
-
children: Array.from({ length:
|
|
2264
|
-
|
|
2513
|
+
ref: n,
|
|
2514
|
+
length: r,
|
|
2515
|
+
className: s("gryt-otp-field flex gap-2", e),
|
|
2516
|
+
...t,
|
|
2517
|
+
children: Array.from({ length: r }, (c, l) => /* @__PURE__ */ a(
|
|
2518
|
+
ut.Input,
|
|
2265
2519
|
{
|
|
2266
|
-
className:
|
|
2520
|
+
className: s(
|
|
2267
2521
|
"gryt-otp-input h-12 w-10 rounded-(--gryt-radius-md) text-center",
|
|
2268
2522
|
"border border-gryt-border bg-gryt-surface-raised",
|
|
2269
2523
|
"font-mono text-lg text-gryt-text tabular-nums outline-none",
|
|
2270
2524
|
"transition-colors duration-(--gryt-dur-fast) motion-reduce:transition-none",
|
|
2271
2525
|
"data-filled:border-gryt-accent",
|
|
2272
|
-
|
|
2526
|
+
x
|
|
2273
2527
|
)
|
|
2274
2528
|
},
|
|
2275
2529
|
l
|
|
@@ -2277,130 +2531,135 @@ const Oe = s(
|
|
|
2277
2531
|
}
|
|
2278
2532
|
);
|
|
2279
2533
|
}
|
|
2280
|
-
),
|
|
2281
|
-
function({ className:
|
|
2282
|
-
return /* @__PURE__ */
|
|
2283
|
-
|
|
2534
|
+
), zr = i(
|
|
2535
|
+
function({ className: e, sideOffset: r = 8, ...t }, n) {
|
|
2536
|
+
return /* @__PURE__ */ a(
|
|
2537
|
+
z.Positioner,
|
|
2284
2538
|
{
|
|
2285
|
-
ref:
|
|
2286
|
-
sideOffset:
|
|
2287
|
-
className:
|
|
2288
|
-
...
|
|
2539
|
+
ref: n,
|
|
2540
|
+
sideOffset: r,
|
|
2541
|
+
className: s("gryt-preview-card-positioner outline-none", e),
|
|
2542
|
+
...t
|
|
2289
2543
|
}
|
|
2290
2544
|
);
|
|
2291
2545
|
}
|
|
2292
|
-
),
|
|
2293
|
-
function({ className:
|
|
2294
|
-
return /* @__PURE__ */
|
|
2295
|
-
|
|
2546
|
+
), Fr = i(
|
|
2547
|
+
function({ className: e, ...r }, t) {
|
|
2548
|
+
return /* @__PURE__ */ a(
|
|
2549
|
+
z.Popup,
|
|
2296
2550
|
{
|
|
2297
|
-
ref:
|
|
2298
|
-
className:
|
|
2551
|
+
ref: t,
|
|
2552
|
+
className: s(
|
|
2299
2553
|
"gryt-preview-card w-64 max-w-[calc(100vw-2rem)] p-4 outline-none",
|
|
2300
|
-
|
|
2301
|
-
|
|
2302
|
-
|
|
2554
|
+
B,
|
|
2555
|
+
A,
|
|
2556
|
+
e
|
|
2303
2557
|
),
|
|
2304
|
-
...
|
|
2558
|
+
...r
|
|
2305
2559
|
}
|
|
2306
2560
|
);
|
|
2307
2561
|
}
|
|
2308
|
-
),
|
|
2309
|
-
Root:
|
|
2310
|
-
Trigger:
|
|
2311
|
-
Portal:
|
|
2312
|
-
Positioner:
|
|
2313
|
-
Popup:
|
|
2314
|
-
Arrow:
|
|
2315
|
-
},
|
|
2316
|
-
return /* @__PURE__ */
|
|
2317
|
-
|
|
2562
|
+
), Sa = {
|
|
2563
|
+
Root: z.Root,
|
|
2564
|
+
Trigger: z.Trigger,
|
|
2565
|
+
Portal: z.Portal,
|
|
2566
|
+
Positioner: zr,
|
|
2567
|
+
Popup: Fr,
|
|
2568
|
+
Arrow: z.Arrow
|
|
2569
|
+
}, Er = i(function({ className: e, ...r }, t) {
|
|
2570
|
+
return /* @__PURE__ */ a(
|
|
2571
|
+
F.Root,
|
|
2318
2572
|
{
|
|
2319
|
-
ref:
|
|
2320
|
-
className:
|
|
2573
|
+
ref: t,
|
|
2574
|
+
className: s(
|
|
2321
2575
|
"gryt-toolbar flex items-center gap-1",
|
|
2322
2576
|
"rounded-(--gryt-radius-full) border border-gryt-border bg-gryt-surface p-1",
|
|
2323
|
-
|
|
2577
|
+
e
|
|
2324
2578
|
),
|
|
2325
|
-
...
|
|
2579
|
+
...r
|
|
2326
2580
|
}
|
|
2327
2581
|
);
|
|
2328
|
-
}),
|
|
2329
|
-
return /* @__PURE__ */
|
|
2330
|
-
|
|
2582
|
+
}), Vr = i(function({ className: e, ...r }, t) {
|
|
2583
|
+
return /* @__PURE__ */ a(
|
|
2584
|
+
F.Separator,
|
|
2331
2585
|
{
|
|
2332
|
-
ref:
|
|
2333
|
-
className:
|
|
2334
|
-
...
|
|
2586
|
+
ref: t,
|
|
2587
|
+
className: s("gryt-toolbar-separator mx-1 h-6 w-px bg-gryt-border", e),
|
|
2588
|
+
...r
|
|
2335
2589
|
}
|
|
2336
2590
|
);
|
|
2337
|
-
}),
|
|
2338
|
-
Root:
|
|
2339
|
-
Group:
|
|
2340
|
-
Button:
|
|
2341
|
-
Link:
|
|
2342
|
-
Input:
|
|
2343
|
-
Separator:
|
|
2591
|
+
}), Ra = {
|
|
2592
|
+
Root: Er,
|
|
2593
|
+
Group: F.Group,
|
|
2594
|
+
Button: F.Button,
|
|
2595
|
+
Link: F.Link,
|
|
2596
|
+
Input: F.Input,
|
|
2597
|
+
Separator: Vr
|
|
2344
2598
|
};
|
|
2345
2599
|
export {
|
|
2346
|
-
|
|
2347
|
-
|
|
2348
|
-
|
|
2349
|
-
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2360
|
-
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2377
|
-
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
|
|
2381
|
-
|
|
2382
|
-
|
|
2383
|
-
|
|
2384
|
-
|
|
2385
|
-
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
|
|
2392
|
-
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2600
|
+
ca as Accordion,
|
|
2601
|
+
ea as Alert,
|
|
2602
|
+
ba as AlertDialog,
|
|
2603
|
+
xa as Autocomplete,
|
|
2604
|
+
he as Avatar,
|
|
2605
|
+
Eo as Badge,
|
|
2606
|
+
de as Button,
|
|
2607
|
+
Ko as Card,
|
|
2608
|
+
ta as CardActions,
|
|
2609
|
+
qo as CardContent,
|
|
2610
|
+
Zo as CardHeader,
|
|
2611
|
+
_o as Checkbox,
|
|
2612
|
+
wa as CheckboxGroup,
|
|
2613
|
+
Vo as Chip,
|
|
2614
|
+
va as Collapsible,
|
|
2615
|
+
ha as Combobox,
|
|
2616
|
+
zo as Composer,
|
|
2617
|
+
la as ContextMenu,
|
|
2618
|
+
Fo as ConversationItem,
|
|
2619
|
+
na as Dialog,
|
|
2620
|
+
Jo as Divider,
|
|
2621
|
+
sa as Drawer,
|
|
2622
|
+
Pa as Fieldset,
|
|
2623
|
+
Na as Form,
|
|
2624
|
+
Ao as GrytProvider,
|
|
2625
|
+
Do as IconButton,
|
|
2626
|
+
ot as Menu,
|
|
2627
|
+
Ta as Menubar,
|
|
2628
|
+
Go as MessageBubble,
|
|
2629
|
+
fa as Meter,
|
|
2630
|
+
ka as NavigationMenu,
|
|
2631
|
+
$a as NumberField,
|
|
2632
|
+
Ca as OtpField,
|
|
2633
|
+
da as Popover,
|
|
2634
|
+
Sa as PreviewCard,
|
|
2635
|
+
ra as Progress,
|
|
2636
|
+
Ho as Radio,
|
|
2637
|
+
Oo as RadioGroup,
|
|
2638
|
+
ya as ScrollArea,
|
|
2639
|
+
Yo as Select,
|
|
2640
|
+
aa as Skeleton,
|
|
2641
|
+
Xo as Slider,
|
|
2642
|
+
oa as Spinner,
|
|
2643
|
+
jo as Surface,
|
|
2644
|
+
Uo as Switch,
|
|
2645
|
+
Ue as Tab,
|
|
2646
|
+
ia as Tabs,
|
|
2647
|
+
Bo as TextField,
|
|
2648
|
+
ga as Toast,
|
|
2649
|
+
ma as Toggle,
|
|
2650
|
+
pa as ToggleGroup,
|
|
2651
|
+
Ra as Toolbar,
|
|
2652
|
+
Wo as Tooltip,
|
|
2653
|
+
Qo as TooltipProvider,
|
|
2654
|
+
s as cn,
|
|
2655
|
+
se as createGrytTheme,
|
|
2656
|
+
Lo as grytAlphaScales,
|
|
2657
|
+
Mo as grytAlphaScalesLight,
|
|
2658
|
+
K as grytLightTokens,
|
|
2659
|
+
yt as grytScales,
|
|
2660
|
+
mt as grytScalesLight,
|
|
2661
|
+
y as grytTokens,
|
|
2662
|
+
Re as useMediaQuery,
|
|
2663
|
+
ua as useToastManager
|
|
2405
2664
|
};
|
|
2406
2665
|
//# sourceMappingURL=index.js.map
|