@blakesteve/roster 4.6.2 → 4.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +167 -13
- package/dist/{Table-DuLc2mEo.js → Table--O-sD53L.js} +8 -8
- package/dist/{Table-C8f0KOSf.cjs → Table-CoQRmik0.cjs} +1 -1
- package/dist/components/atoms/Input/Input.d.ts +10 -1
- package/dist/components/atoms/Input/input-variants.d.ts +1 -0
- package/dist/components/atoms/Select/Select.d.ts +11 -1
- package/dist/components/atoms/Select/select-variants.d.ts +4 -0
- package/dist/components/atoms/Textarea/Textarea.d.ts +9 -0
- package/dist/data-table.cjs.js +1 -1
- package/dist/data-table.es.js +1 -1
- package/dist/meta.json +2 -2
- package/dist/roster.cjs.js +2 -2
- package/dist/roster.css +1 -1
- package/dist/roster.es.js +837 -672
- package/package.json +1 -1
package/dist/roster.es.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { o as I, Y as Q, K as J, p as zt, m as Ea, n as oe, q as ot, r as ct, $ as ve, s as xe, w as tr, V as It, t as jt, u as pe, v as ht, x as ye, y as Kt, z as me, A as ge, C as
|
|
3
|
-
import { a5 as
|
|
2
|
+
import { o as I, Y as Q, K as J, p as zt, m as Ea, n as oe, q as ot, r as ct, $ as ve, s as xe, w as tr, V as It, t as jt, u as pe, v as ht, x as ye, y as Kt, z as me, A as ge, C as Ps, D as Cs, E as At, G as Mi, H as de, I as Li, J as _i, L as Z, j as f, F as mt, M as Vi, N as Na, O as Oa, P as xn, Q as Bi, R as Hi, B as Ut, S as zi, U as ps, W as hr, X as Pa, Z as Wi, _ as Ui, a0 as Ge, a1 as Yi, a2 as Gi, a3 as Ki, a4 as qi } from "./Table--O-sD53L.js";
|
|
3
|
+
import { a5 as rg, T as sg, e as ng, a6 as ag, g as og, a7 as ig, c as lg, a as cg, b as ug, a8 as dg, a9 as fg, aa as pg, ab as mg, ac as gg, ad as hg, ae as bg } from "./Table--O-sD53L.js";
|
|
4
4
|
import * as y from "react";
|
|
5
5
|
import S, { useState as X, useRef as V, isValidElement as Ca, useEffect as st, useContext as at, createContext as pt, useMemo as ft, useId as dt, useCallback as tt, useSyncExternalStore as Ta, useLayoutEffect as ja, cloneElement as Xi, Fragment as xt, useReducer as Qi, createRef as Zi, forwardRef as Ra } from "react";
|
|
6
6
|
import { c as C } from "./utils-hNxf9HpA.js";
|
|
@@ -117,7 +117,7 @@ function Va(t) {
|
|
|
117
117
|
function ul(t) {
|
|
118
118
|
return Gt(t) ? t.matches('a[href],audio[controls],button,details,embed,iframe,img[usemap],input:not([type="hidden"]),label,select,textarea,video[controls]') : !1;
|
|
119
119
|
}
|
|
120
|
-
function
|
|
120
|
+
function Pe(t) {
|
|
121
121
|
let e = t.parentElement, r = null;
|
|
122
122
|
for (; e && !cl(e); ) Va(e) && (r = e), e = e.parentElement;
|
|
123
123
|
let s = e?.getAttribute("disabled") === "";
|
|
@@ -226,16 +226,16 @@ function hl(t, e) {
|
|
|
226
226
|
}
|
|
227
227
|
let bl = Q(hl), De = Object.assign(bl, {}), vl = "span";
|
|
228
228
|
function xl(t, e) {
|
|
229
|
-
let r = dt(), s = Ie(), n = oe(), { id: a = s || `headlessui-checkbox-${r}`, disabled: o = n || !1, autoFocus: i = !1, checked: l, defaultChecked: c, onChange: u, name: p, value: m, form: d, indeterminate: g = !1, tabIndex: h = 0, ...b } = t, v = js(c), [w, x] = Ts(l, u, v ?? !1), k = Ae(), E = er(), T = zt(), [
|
|
229
|
+
let r = dt(), s = Ie(), n = oe(), { id: a = s || `headlessui-checkbox-${r}`, disabled: o = n || !1, autoFocus: i = !1, checked: l, defaultChecked: c, onChange: u, name: p, value: m, form: d, indeterminate: g = !1, tabIndex: h = 0, ...b } = t, v = js(c), [w, x] = Ts(l, u, v ?? !1), k = Ae(), E = er(), T = zt(), [O, M] = X(!1), z = I(() => {
|
|
230
230
|
M(!0), x?.(!w), T.nextFrame(() => {
|
|
231
231
|
M(!1);
|
|
232
232
|
});
|
|
233
233
|
}), N = I((A) => {
|
|
234
|
-
if (
|
|
234
|
+
if (Pe(A.currentTarget)) return A.preventDefault();
|
|
235
235
|
A.preventDefault(), z();
|
|
236
236
|
}), $ = I((A) => {
|
|
237
237
|
A.key === Y.Space ? (A.preventDefault(), z()) : A.key === Y.Enter && Rs(A.currentTarget);
|
|
238
|
-
}), L = I((A) => A.preventDefault()), { isFocusVisible: _, focusProps: R } = ve({ autoFocus: i }), { isHovered: D, hoverProps: F } = xe({ isDisabled: o }), { pressed: U, pressProps:
|
|
238
|
+
}), L = I((A) => A.preventDefault()), { isFocusVisible: _, focusProps: R } = ve({ autoFocus: i }), { isHovered: D, hoverProps: F } = xe({ isDisabled: o }), { pressed: U, pressProps: P } = tr({ disabled: o }), j = It({ ref: e, id: a, role: "checkbox", "aria-checked": g ? "mixed" : w ? "true" : "false", "aria-labelledby": k, "aria-describedby": E, "aria-disabled": o ? !0 : void 0, indeterminate: g ? "true" : void 0, tabIndex: o ? void 0 : h, onKeyUp: o ? void 0 : $, onKeyPress: o ? void 0 : L, onClick: o ? void 0 : N }, R, F, P), H = ct({ checked: w, disabled: o, hover: D, focus: _, active: U, indeterminate: g, changing: O, autofocus: i }), nt = tt(() => {
|
|
239
239
|
if (v !== void 0) return x?.(v);
|
|
240
240
|
}, [x, v]), et = J();
|
|
241
241
|
return S.createElement(S.Fragment, null, p != null && S.createElement($s, { disabled: o, data: { [p]: m || "on" }, overrides: { type: "checkbox", checked: w }, form: d, onReset: nt }), et({ ourProps: j, theirProps: b, slot: H, defaultTag: vl, name: "Checkbox" }));
|
|
@@ -280,9 +280,9 @@ function Ds(t, e, r = !1) {
|
|
|
280
280
|
var Wa = ((t) => (t[t.Left = 0] = "Left", t[t.Right = 2] = "Right", t))(Wa || {});
|
|
281
281
|
function Ua(t) {
|
|
282
282
|
let e = V(null), r = I((n) => {
|
|
283
|
-
e.current = n.pointerType, !
|
|
283
|
+
e.current = n.pointerType, !Pe(n.currentTarget) && n.pointerType === "mouse" && n.button === Wa.Left && (n.preventDefault(), t(n));
|
|
284
284
|
}), s = I((n) => {
|
|
285
|
-
e.current !== "mouse" && (
|
|
285
|
+
e.current !== "mouse" && (Pe(n.currentTarget) || t(n));
|
|
286
286
|
});
|
|
287
287
|
return { onPointerDown: r, onClick: s };
|
|
288
288
|
}
|
|
@@ -295,7 +295,7 @@ let Ya = class extends Map {
|
|
|
295
295
|
return r === void 0 && (r = this.factory(e), this.set(e, r)), r;
|
|
296
296
|
}
|
|
297
297
|
};
|
|
298
|
-
var El = Object.defineProperty, Nl = (t, e, r) => e in t ? El(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r,
|
|
298
|
+
var El = Object.defineProperty, Nl = (t, e, r) => e in t ? El(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, Ol = (t, e, r) => (Nl(t, e + "", r), r), Ga = (t, e, r) => {
|
|
299
299
|
if (!e.has(t)) throw TypeError("Cannot " + r);
|
|
300
300
|
}, Rt = (t, e, r) => (Ga(t, e, "read from private field"), r ? r.call(t) : e.get(t)), ns = (t, e, r) => {
|
|
301
301
|
if (e.has(t)) throw TypeError("Cannot add the same private member more than once");
|
|
@@ -303,7 +303,7 @@ var El = Object.defineProperty, Nl = (t, e, r) => e in t ? El(t, e, { enumerable
|
|
|
303
303
|
}, wn = (t, e, r, s) => (Ga(t, e, "write to private field"), e.set(t, r), r), Ft, Be, He;
|
|
304
304
|
let Ar = class {
|
|
305
305
|
constructor(e) {
|
|
306
|
-
ns(this, Ft, {}), ns(this, Be, new Ya(() => /* @__PURE__ */ new Set())), ns(this, He, /* @__PURE__ */ new Set()),
|
|
306
|
+
ns(this, Ft, {}), ns(this, Be, new Ya(() => /* @__PURE__ */ new Set())), ns(this, He, /* @__PURE__ */ new Set()), Ol(this, "disposables", jt()), wn(this, Ft, e), pe.isServer && this.disposables.microTask(() => {
|
|
307
307
|
this.dispose();
|
|
308
308
|
});
|
|
309
309
|
}
|
|
@@ -361,7 +361,7 @@ function We(t) {
|
|
|
361
361
|
e(...n), s.dispose(), s.microTask(r);
|
|
362
362
|
};
|
|
363
363
|
}
|
|
364
|
-
var
|
|
364
|
+
var Pl = Object.defineProperty, Cl = (t, e, r) => e in t ? Pl(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, Sn = (t, e, r) => (Cl(t, typeof e != "symbol" ? e + "" : e, r), r), Fs = ((t) => (t[t.Push = 0] = "Push", t[t.Pop = 1] = "Pop", t))(Fs || {});
|
|
365
365
|
let Tl = { 0(t, e) {
|
|
366
366
|
let r = e.id, s = t.stack, n = t.stack.indexOf(r);
|
|
367
367
|
if (n !== -1) {
|
|
@@ -414,8 +414,8 @@ function Rl() {
|
|
|
414
414
|
return x = E;
|
|
415
415
|
}
|
|
416
416
|
if (T = x, r(w, E)) return T;
|
|
417
|
-
var
|
|
418
|
-
return m !== void 0 && m(T,
|
|
417
|
+
var O = p(E);
|
|
418
|
+
return m !== void 0 && m(T, O) ? (w = E, T) : (w = E, x = O);
|
|
419
419
|
}
|
|
420
420
|
var v = !1, w, x, k = u === void 0 ? null : u;
|
|
421
421
|
return [
|
|
@@ -466,8 +466,8 @@ function $l() {
|
|
|
466
466
|
}
|
|
467
467
|
if (T = x, r(w, E))
|
|
468
468
|
return T;
|
|
469
|
-
var
|
|
470
|
-
return m !== void 0 && m(T,
|
|
469
|
+
var O = p(E);
|
|
470
|
+
return m !== void 0 && m(T, O) ? (w = E, T) : (w = E, x = O);
|
|
471
471
|
}
|
|
472
472
|
var v = !1, w, x, k = u === void 0 ? null : u;
|
|
473
473
|
return [
|
|
@@ -491,9 +491,9 @@ function $l() {
|
|
|
491
491
|
}, typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ < "u" && typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop == "function" && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
|
|
492
492
|
})()), is;
|
|
493
493
|
}
|
|
494
|
-
var
|
|
494
|
+
var On;
|
|
495
495
|
function Il() {
|
|
496
|
-
return
|
|
496
|
+
return On || (On = 1, process.env.NODE_ENV === "production" ? br.exports = Rl() : br.exports = $l()), br.exports;
|
|
497
497
|
}
|
|
498
498
|
var Al = Il();
|
|
499
499
|
function rt(t, e, r = Ka) {
|
|
@@ -509,7 +509,7 @@ function nr(t, e) {
|
|
|
509
509
|
}, [s, t, r]), t ? a ? n : !0 : !1;
|
|
510
510
|
}
|
|
511
511
|
let gs = /* @__PURE__ */ new Map(), Ue = /* @__PURE__ */ new Map();
|
|
512
|
-
function
|
|
512
|
+
function Pn(t) {
|
|
513
513
|
var e;
|
|
514
514
|
let r = (e = Ue.get(t)) != null ? e : 0;
|
|
515
515
|
return Ue.set(t, r + 1), r !== 0 ? () => Cn(t) : (gs.set(t, { "aria-hidden": t.getAttribute("aria-hidden"), inert: t.inert }), t.setAttribute("aria-hidden", "true"), t.inert = !0, () => Cn(t));
|
|
@@ -527,7 +527,7 @@ function Ms(t, { allowed: e, disallowed: r } = {}) {
|
|
|
527
527
|
var n, a;
|
|
528
528
|
if (!s) return;
|
|
529
529
|
let o = jt();
|
|
530
|
-
for (let l of (n = r?.()) != null ? n : []) l && o.add(
|
|
530
|
+
for (let l of (n = r?.()) != null ? n : []) l && o.add(Pn(l));
|
|
531
531
|
let i = (a = e?.()) != null ? a : [];
|
|
532
532
|
for (let l of i) {
|
|
533
533
|
if (!l) continue;
|
|
@@ -535,7 +535,7 @@ function Ms(t, { allowed: e, disallowed: r } = {}) {
|
|
|
535
535
|
if (!c) continue;
|
|
536
536
|
let u = l.parentElement;
|
|
537
537
|
for (; u && u !== c.body; ) {
|
|
538
|
-
for (let p of u.children) i.some((m) => p.contains(m)) || o.add(
|
|
538
|
+
for (let p of u.children) i.some((m) => p.contains(m)) || o.add(Pn(p));
|
|
539
539
|
u = u.parentElement;
|
|
540
540
|
}
|
|
541
541
|
}
|
|
@@ -614,9 +614,9 @@ function Ls(t, e = (r) => r) {
|
|
|
614
614
|
});
|
|
615
615
|
}
|
|
616
616
|
function Qa(t, e, r = t === null ? document.body : me(t)) {
|
|
617
|
-
return
|
|
617
|
+
return Pt(ar(r), e, { relativeTo: t });
|
|
618
618
|
}
|
|
619
|
-
function
|
|
619
|
+
function Pt(t, e, { sorted: r = !0, relativeTo: s = null, skipElements: n = [] } = {}) {
|
|
620
620
|
let a = Array.isArray(t) ? t.length > 0 ? me(t[0]) : document : me(t), o = Array.isArray(t) ? r ? Ls(t) : t : e & 64 ? Ll(t) : ar(t);
|
|
621
621
|
n.length > 0 && o.length > 1 && (o = o.filter((d) => !n.some((g) => g != null && "current" in g ? g?.current === d : g === d))), s = s ?? a?.activeElement;
|
|
622
622
|
let i = (() => {
|
|
@@ -1292,7 +1292,7 @@ async function ao(t, e) {
|
|
|
1292
1292
|
right: (E.right - v.right + g.right) / k.x
|
|
1293
1293
|
};
|
|
1294
1294
|
}
|
|
1295
|
-
const
|
|
1295
|
+
const Oc = async (t, e, r) => {
|
|
1296
1296
|
const {
|
|
1297
1297
|
placement: s = "bottom",
|
|
1298
1298
|
strategy: n = "absolute",
|
|
@@ -1356,7 +1356,7 @@ const Pc = async (t, e, r) => {
|
|
|
1356
1356
|
strategy: n,
|
|
1357
1357
|
middlewareData: d
|
|
1358
1358
|
};
|
|
1359
|
-
},
|
|
1359
|
+
}, Pc = (t) => ({
|
|
1360
1360
|
name: "arrow",
|
|
1361
1361
|
options: t,
|
|
1362
1362
|
async fn(e) {
|
|
@@ -1378,9 +1378,9 @@ const Pc = async (t, e, r) => {
|
|
|
1378
1378
|
x: r,
|
|
1379
1379
|
y: s
|
|
1380
1380
|
}, d = Us(n), g = Ws(d), h = await o.getDimensions(c), b = d === "y", v = b ? "top" : "left", w = b ? "bottom" : "right", x = b ? "clientHeight" : "clientWidth", k = a.reference[g] + a.reference[d] - m[d] - a.floating[g], E = m[d] - a.reference[d], T = await (o.getOffsetParent == null ? void 0 : o.getOffsetParent(c));
|
|
1381
|
-
let
|
|
1382
|
-
(!
|
|
1383
|
-
const M = k / 2 - E / 2, z =
|
|
1381
|
+
let O = T ? T[x] : 0;
|
|
1382
|
+
(!O || !await (o.isElement == null ? void 0 : o.isElement(T))) && (O = i.floating[x] || a.floating[g]);
|
|
1383
|
+
const M = k / 2 - E / 2, z = O / 2 - h[g] / 2 - 1, N = Qt(p[v], z), $ = Qt(p[w], z), L = N, _ = O - h[g] - $, R = O / 2 - h[g] / 2 + M, D = bs(L, R, _), F = !l.arrow && Me(n) != null && R !== D && a.reference[g] / 2 - (R < L ? N : $) - h[g] / 2 < 0, U = F ? R < L ? R - L : R - _ : 0;
|
|
1384
1384
|
return {
|
|
1385
1385
|
[d]: m[d] + U,
|
|
1386
1386
|
data: {
|
|
@@ -1419,7 +1419,7 @@ const Pc = async (t, e, r) => {
|
|
|
1419
1419
|
return {};
|
|
1420
1420
|
const v = Zt(n), w = Mt(i), x = Zt(i) === i, k = await (l.isRTL == null ? void 0 : l.isRTL(c.floating)), E = m || (x || !h ? [Er(i)] : yc(i)), T = g !== "none";
|
|
1421
1421
|
!m && T && E.push(...Ec(i, h, g, k));
|
|
1422
|
-
const
|
|
1422
|
+
const O = [i, ...E], M = await l.detectOverflow(e, b), z = [];
|
|
1423
1423
|
let N = ((s = a.flip) == null ? void 0 : s.overflows) || [];
|
|
1424
1424
|
if (u && z.push(M[v]), p) {
|
|
1425
1425
|
const R = xc(n, o, k);
|
|
@@ -1430,10 +1430,10 @@ const Pc = async (t, e, r) => {
|
|
|
1430
1430
|
overflows: z
|
|
1431
1431
|
}], !z.every((R) => R <= 0)) {
|
|
1432
1432
|
var $, L;
|
|
1433
|
-
const R = ((($ = a.flip) == null ? void 0 : $.index) || 0) + 1, D =
|
|
1433
|
+
const R = ((($ = a.flip) == null ? void 0 : $.index) || 0) + 1, D = O[R];
|
|
1434
1434
|
if (D && (!(p === "alignment" ? w !== Mt(D) : !1) || // We leave the current main axis only if every placement on that axis
|
|
1435
1435
|
// overflows the main axis.
|
|
1436
|
-
N.every((
|
|
1436
|
+
N.every((P) => Mt(P.placement) === w ? P.overflows[0] > 0 : !0)))
|
|
1437
1437
|
return {
|
|
1438
1438
|
data: {
|
|
1439
1439
|
index: R,
|
|
@@ -1443,20 +1443,20 @@ const Pc = async (t, e, r) => {
|
|
|
1443
1443
|
placement: D
|
|
1444
1444
|
}
|
|
1445
1445
|
};
|
|
1446
|
-
let F = (L = N.filter((U) => U.overflows[0] <= 0).sort((U,
|
|
1446
|
+
let F = (L = N.filter((U) => U.overflows[0] <= 0).sort((U, P) => U.overflows[1] - P.overflows[1])[0]) == null ? void 0 : L.placement;
|
|
1447
1447
|
if (!F)
|
|
1448
1448
|
switch (d) {
|
|
1449
1449
|
case "bestFit": {
|
|
1450
1450
|
var _;
|
|
1451
|
-
const U = (_ = N.filter((
|
|
1451
|
+
const U = (_ = N.filter((P) => {
|
|
1452
1452
|
if (T) {
|
|
1453
|
-
const j = Mt(
|
|
1453
|
+
const j = Mt(P.placement);
|
|
1454
1454
|
return j === w || // Create a bias to the `y` side axis due to horizontal
|
|
1455
1455
|
// reading directions favoring greater width.
|
|
1456
1456
|
j === "y";
|
|
1457
1457
|
}
|
|
1458
1458
|
return !0;
|
|
1459
|
-
}).map((
|
|
1459
|
+
}).map((P) => [P.placement, P.overflows.filter((j) => j > 0).reduce((j, H) => j + H, 0)]).sort((P, j) => P[1] - j[1])[0]) == null ? void 0 : _[0];
|
|
1460
1460
|
U && (F = U);
|
|
1461
1461
|
break;
|
|
1462
1462
|
}
|
|
@@ -1699,15 +1699,15 @@ const Rc = function(t) {
|
|
|
1699
1699
|
let b, v;
|
|
1700
1700
|
p === "top" || p === "bottom" ? (b = p, v = m === (await (o.isRTL == null ? void 0 : o.isRTL(i.floating)) ? "start" : "end") ? "left" : "right") : (v = p, b = m === "end" ? "top" : "bottom");
|
|
1701
1701
|
const w = h - u.top - u.bottom, x = g - u.left - u.right, k = Qt(h - u[b], w), E = Qt(g - u[v], x), T = !e.middlewareData.shift;
|
|
1702
|
-
let
|
|
1703
|
-
if ((r = e.middlewareData.shift) != null && r.enabled.x && (M = x), (s = e.middlewareData.shift) != null && s.enabled.y && (
|
|
1702
|
+
let O = k, M = E;
|
|
1703
|
+
if ((r = e.middlewareData.shift) != null && r.enabled.x && (M = x), (s = e.middlewareData.shift) != null && s.enabled.y && (O = w), T && !m) {
|
|
1704
1704
|
const N = St(u.left, 0), $ = St(u.right, 0), L = St(u.top, 0), _ = St(u.bottom, 0);
|
|
1705
|
-
d ? M = g - 2 * (N !== 0 || $ !== 0 ? N + $ : St(u.left, u.right)) :
|
|
1705
|
+
d ? M = g - 2 * (N !== 0 || $ !== 0 ? N + $ : St(u.left, u.right)) : O = h - 2 * (L !== 0 || _ !== 0 ? L + _ : St(u.top, u.bottom));
|
|
1706
1706
|
}
|
|
1707
1707
|
await l({
|
|
1708
1708
|
...e,
|
|
1709
1709
|
availableWidth: M,
|
|
1710
|
-
availableHeight:
|
|
1710
|
+
availableHeight: O
|
|
1711
1711
|
});
|
|
1712
1712
|
const z = await o.getDimensions(i.floating);
|
|
1713
1713
|
return g !== z.width || h !== z.height ? {
|
|
@@ -1731,7 +1731,7 @@ function io(t) {
|
|
|
1731
1731
|
function Ys(t) {
|
|
1732
1732
|
return Nt(t) ? t : t.contextElement;
|
|
1733
1733
|
}
|
|
1734
|
-
function
|
|
1734
|
+
function Oe(t) {
|
|
1735
1735
|
const e = Ys(t);
|
|
1736
1736
|
if (!Bt(e))
|
|
1737
1737
|
return _t(1);
|
|
@@ -1761,14 +1761,14 @@ function be(t, e, r, s) {
|
|
|
1761
1761
|
e === void 0 && (e = !1), r === void 0 && (r = !1);
|
|
1762
1762
|
const n = t.getBoundingClientRect(), a = Ys(t);
|
|
1763
1763
|
let o = _t(1);
|
|
1764
|
-
e && (s ? Nt(s) && (o =
|
|
1764
|
+
e && (s ? Nt(s) && (o = Oe(s)) : o = Oe(t));
|
|
1765
1765
|
const i = Fc(a, r, s) ? lo(a) : _t(0);
|
|
1766
1766
|
let l = (n.left + i.x) / o.x, c = (n.top + i.y) / o.y, u = n.width / o.x, p = n.height / o.y;
|
|
1767
1767
|
if (a) {
|
|
1768
1768
|
const m = Tt(a), d = s && Nt(s) ? Tt(s) : s;
|
|
1769
1769
|
let g = m, h = hs(g);
|
|
1770
1770
|
for (; h && s && d !== g; ) {
|
|
1771
|
-
const b =
|
|
1771
|
+
const b = Oe(h), v = h.getBoundingClientRect(), w = Dt(h), x = v.left + (h.clientLeft + parseFloat(w.paddingLeft)) * b.x, k = v.top + (h.clientTop + parseFloat(w.paddingTop)) * b.y;
|
|
1772
1772
|
l *= b.x, c *= b.y, u *= b.x, p *= b.y, l += x, c += k, g = Tt(h), h = hs(g);
|
|
1773
1773
|
}
|
|
1774
1774
|
}
|
|
@@ -1807,7 +1807,7 @@ function Mc(t) {
|
|
|
1807
1807
|
const u = _t(0), p = Bt(s);
|
|
1808
1808
|
if ((p || !p && !a) && ((Fe(s) !== "body" || ur(o)) && (l = Br(s)), Bt(s))) {
|
|
1809
1809
|
const d = be(s);
|
|
1810
|
-
c =
|
|
1810
|
+
c = Oe(s), u.x = d.x + s.clientLeft, u.y = d.y + s.clientTop;
|
|
1811
1811
|
}
|
|
1812
1812
|
const m = o && !p && !a ? co(o, l) : _t(0);
|
|
1813
1813
|
return {
|
|
@@ -1854,7 +1854,7 @@ function Vc(t, e) {
|
|
|
1854
1854
|
}
|
|
1855
1855
|
const Bc = /* @__PURE__ */ new Set(["absolute", "fixed"]);
|
|
1856
1856
|
function Hc(t, e) {
|
|
1857
|
-
const r = be(t, !0, e === "fixed"), s = r.top + t.clientTop, n = r.left + t.clientLeft, a = Bt(t) ?
|
|
1857
|
+
const r = be(t, !0, e === "fixed"), s = r.top + t.clientTop, n = r.left + t.clientLeft, a = Bt(t) ? Oe(t) : _t(1), o = t.clientWidth * a.x, i = t.clientHeight * a.y, l = n * a.x, c = s * a.y;
|
|
1858
1858
|
return {
|
|
1859
1859
|
width: o,
|
|
1860
1860
|
height: i,
|
|
@@ -2002,7 +2002,7 @@ const qc = {
|
|
|
2002
2002
|
getElementRects: Gc,
|
|
2003
2003
|
getClientRects: Lc,
|
|
2004
2004
|
getDimensions: Uc,
|
|
2005
|
-
getScale:
|
|
2005
|
+
getScale: Oe,
|
|
2006
2006
|
isElement: Nt,
|
|
2007
2007
|
isRTL: Kc
|
|
2008
2008
|
};
|
|
@@ -2032,15 +2032,15 @@ function Xc(t, e) {
|
|
|
2032
2032
|
};
|
|
2033
2033
|
let k = !0;
|
|
2034
2034
|
function E(T) {
|
|
2035
|
-
const
|
|
2036
|
-
if (
|
|
2035
|
+
const O = T[0].intersectionRatio;
|
|
2036
|
+
if (O !== l) {
|
|
2037
2037
|
if (!k)
|
|
2038
2038
|
return o();
|
|
2039
|
-
|
|
2039
|
+
O ? o(!1, O) : s = setTimeout(() => {
|
|
2040
2040
|
o(!1, 1e-7);
|
|
2041
2041
|
}, 1e3);
|
|
2042
2042
|
}
|
|
2043
|
-
|
|
2043
|
+
O === 1 && !po(c, t.getBoundingClientRect()) && o(), k = !1;
|
|
2044
2044
|
}
|
|
2045
2045
|
try {
|
|
2046
2046
|
r = new IntersectionObserver(E, {
|
|
@@ -2091,7 +2091,7 @@ function mo(t, e, r, s) {
|
|
|
2091
2091
|
}), p?.(), (v = d) == null || v.disconnect(), d = null, l && cancelAnimationFrame(g);
|
|
2092
2092
|
};
|
|
2093
2093
|
}
|
|
2094
|
-
const cs = ao, Qc = Rc, Zc = $c, Jc = Cc, tu = Ac, eu = Tc, Un =
|
|
2094
|
+
const cs = ao, Qc = Rc, Zc = $c, Jc = Cc, tu = Ac, eu = Tc, Un = Pc, ru = Ic, su = (t, e, r) => {
|
|
2095
2095
|
const s = /* @__PURE__ */ new Map(), n = {
|
|
2096
2096
|
platform: qc,
|
|
2097
2097
|
...r
|
|
@@ -2099,14 +2099,14 @@ const cs = ao, Qc = Rc, Zc = $c, Jc = Cc, tu = Ac, eu = Tc, Un = Oc, ru = Ic, su
|
|
|
2099
2099
|
...n.platform,
|
|
2100
2100
|
_c: s
|
|
2101
2101
|
};
|
|
2102
|
-
return
|
|
2102
|
+
return Oc(t, e, {
|
|
2103
2103
|
...n,
|
|
2104
2104
|
platform: a
|
|
2105
2105
|
});
|
|
2106
2106
|
};
|
|
2107
2107
|
var nu = typeof document < "u", au = function() {
|
|
2108
2108
|
}, wr = nu ? ja : au;
|
|
2109
|
-
function
|
|
2109
|
+
function Or(t, e) {
|
|
2110
2110
|
if (t === e)
|
|
2111
2111
|
return !0;
|
|
2112
2112
|
if (typeof t != typeof e)
|
|
@@ -2118,7 +2118,7 @@ function Pr(t, e) {
|
|
|
2118
2118
|
if (Array.isArray(t)) {
|
|
2119
2119
|
if (r = t.length, r !== e.length) return !1;
|
|
2120
2120
|
for (s = r; s-- !== 0; )
|
|
2121
|
-
if (!
|
|
2121
|
+
if (!Or(t[s], e[s]))
|
|
2122
2122
|
return !1;
|
|
2123
2123
|
return !0;
|
|
2124
2124
|
}
|
|
@@ -2129,7 +2129,7 @@ function Pr(t, e) {
|
|
|
2129
2129
|
return !1;
|
|
2130
2130
|
for (s = r; s-- !== 0; ) {
|
|
2131
2131
|
const a = n[s];
|
|
2132
|
-
if (!(a === "_owner" && t.$$typeof) && !
|
|
2132
|
+
if (!(a === "_owner" && t.$$typeof) && !Or(t[a], e[a]))
|
|
2133
2133
|
return !1;
|
|
2134
2134
|
}
|
|
2135
2135
|
return !0;
|
|
@@ -2171,20 +2171,20 @@ function ho(t) {
|
|
|
2171
2171
|
middlewareData: {},
|
|
2172
2172
|
isPositioned: !1
|
|
2173
2173
|
}), [m, d] = y.useState(s);
|
|
2174
|
-
|
|
2175
|
-
const [g, h] = y.useState(null), [b, v] = y.useState(null), w = y.useCallback((
|
|
2176
|
-
|
|
2177
|
-
}, []), x = y.useCallback((
|
|
2178
|
-
|
|
2179
|
-
}, []), k = a || g, E = o || b, T = y.useRef(null),
|
|
2180
|
-
if (!T.current || !
|
|
2174
|
+
Or(m, s) || d(s);
|
|
2175
|
+
const [g, h] = y.useState(null), [b, v] = y.useState(null), w = y.useCallback((P) => {
|
|
2176
|
+
P !== T.current && (T.current = P, h(P));
|
|
2177
|
+
}, []), x = y.useCallback((P) => {
|
|
2178
|
+
P !== O.current && (O.current = P, v(P));
|
|
2179
|
+
}, []), k = a || g, E = o || b, T = y.useRef(null), O = y.useRef(null), M = y.useRef(u), z = l != null, N = us(l), $ = us(n), L = us(c), _ = y.useCallback(() => {
|
|
2180
|
+
if (!T.current || !O.current)
|
|
2181
2181
|
return;
|
|
2182
|
-
const
|
|
2182
|
+
const P = {
|
|
2183
2183
|
placement: e,
|
|
2184
2184
|
strategy: r,
|
|
2185
2185
|
middleware: m
|
|
2186
2186
|
};
|
|
2187
|
-
$.current && (
|
|
2187
|
+
$.current && (P.platform = $.current), su(T.current, O.current, P).then((j) => {
|
|
2188
2188
|
const H = {
|
|
2189
2189
|
...j,
|
|
2190
2190
|
// The floating element's position may be recomputed while it's closed
|
|
@@ -2193,14 +2193,14 @@ function ho(t) {
|
|
|
2193
2193
|
// setting it to `true` when `open === false` (must be specified).
|
|
2194
2194
|
isPositioned: L.current !== !1
|
|
2195
2195
|
};
|
|
2196
|
-
R.current && !
|
|
2196
|
+
R.current && !Or(M.current, H) && (M.current = H, Ke.flushSync(() => {
|
|
2197
2197
|
p(H);
|
|
2198
2198
|
}));
|
|
2199
2199
|
});
|
|
2200
2200
|
}, [m, e, r, $, L]);
|
|
2201
2201
|
wr(() => {
|
|
2202
|
-
c === !1 && M.current.isPositioned && (M.current.isPositioned = !1, p((
|
|
2203
|
-
...
|
|
2202
|
+
c === !1 && M.current.isPositioned && (M.current.isPositioned = !1, p((P) => ({
|
|
2203
|
+
...P,
|
|
2204
2204
|
isPositioned: !1
|
|
2205
2205
|
})));
|
|
2206
2206
|
}, [c]);
|
|
@@ -2208,7 +2208,7 @@ function ho(t) {
|
|
|
2208
2208
|
wr(() => (R.current = !0, () => {
|
|
2209
2209
|
R.current = !1;
|
|
2210
2210
|
}), []), wr(() => {
|
|
2211
|
-
if (k && (T.current = k), E && (
|
|
2211
|
+
if (k && (T.current = k), E && (O.current = E), k && E) {
|
|
2212
2212
|
if (N.current)
|
|
2213
2213
|
return N.current(k, E, _);
|
|
2214
2214
|
_();
|
|
@@ -2216,23 +2216,23 @@ function ho(t) {
|
|
|
2216
2216
|
}, [k, E, _, N, z]);
|
|
2217
2217
|
const D = y.useMemo(() => ({
|
|
2218
2218
|
reference: T,
|
|
2219
|
-
floating:
|
|
2219
|
+
floating: O,
|
|
2220
2220
|
setReference: w,
|
|
2221
2221
|
setFloating: x
|
|
2222
2222
|
}), [w, x]), F = y.useMemo(() => ({
|
|
2223
2223
|
reference: k,
|
|
2224
2224
|
floating: E
|
|
2225
2225
|
}), [k, E]), U = y.useMemo(() => {
|
|
2226
|
-
const
|
|
2226
|
+
const P = {
|
|
2227
2227
|
position: r,
|
|
2228
2228
|
left: 0,
|
|
2229
2229
|
top: 0
|
|
2230
2230
|
};
|
|
2231
2231
|
if (!F.floating)
|
|
2232
|
-
return
|
|
2232
|
+
return P;
|
|
2233
2233
|
const j = Yn(F.floating, u.x), H = Yn(F.floating, u.y);
|
|
2234
2234
|
return i ? {
|
|
2235
|
-
...
|
|
2235
|
+
...P,
|
|
2236
2236
|
transform: "translate(" + j + "px, " + H + "px)",
|
|
2237
2237
|
...go(F.floating) >= 1.5 && {
|
|
2238
2238
|
willChange: "transform"
|
|
@@ -2497,7 +2497,7 @@ function ds(t, e, r) {
|
|
|
2497
2497
|
}), o), {})
|
|
2498
2498
|
};
|
|
2499
2499
|
}
|
|
2500
|
-
function
|
|
2500
|
+
function Ou(t) {
|
|
2501
2501
|
t === void 0 && (t = []);
|
|
2502
2502
|
const e = t.map((i) => i?.reference), r = t.map((i) => i?.floating), s = t.map((i) => i?.item), n = y.useCallback(
|
|
2503
2503
|
(i) => ds(i, t, "reference"),
|
|
@@ -2530,7 +2530,7 @@ function Qn(t, e) {
|
|
|
2530
2530
|
}
|
|
2531
2531
|
};
|
|
2532
2532
|
}
|
|
2533
|
-
const
|
|
2533
|
+
const Pu = (t) => ({
|
|
2534
2534
|
name: "inner",
|
|
2535
2535
|
options: t,
|
|
2536
2536
|
async fn(e) {
|
|
@@ -2558,16 +2558,16 @@ const Ou = (t) => ({
|
|
|
2558
2558
|
}, k = await cs(Qn(x, g.scrollHeight + h + m.clientTop), u), E = await cs(x, {
|
|
2559
2559
|
...u,
|
|
2560
2560
|
elementContext: "reference"
|
|
2561
|
-
}), T = St(0, k.top),
|
|
2561
|
+
}), T = St(0, k.top), O = x.y + T, N = (g.scrollHeight > g.clientHeight ? ($) => $ : Xe)(St(0, g.scrollHeight + (b && w || v ? h * 2 : 0) - T - St(0, k.bottom)));
|
|
2562
2562
|
if (g.style.maxHeight = N + "px", g.scrollTop = T, n) {
|
|
2563
2563
|
const $ = g.offsetHeight < d.offsetHeight * Qt(i, r.current.length) - 1 || E.top >= -l || E.bottom >= -l;
|
|
2564
2564
|
Ke.flushSync(() => n($));
|
|
2565
2565
|
}
|
|
2566
2566
|
return s && (s.current = await cs(Qn({
|
|
2567
2567
|
...x,
|
|
2568
|
-
y:
|
|
2568
|
+
y: O
|
|
2569
2569
|
}, g.offsetHeight + h + m.clientTop), u)), {
|
|
2570
|
-
y:
|
|
2570
|
+
y: O
|
|
2571
2571
|
};
|
|
2572
2572
|
}
|
|
2573
2573
|
});
|
|
@@ -2667,29 +2667,29 @@ function Js({ children: t, enabled: e = !0 }) {
|
|
|
2667
2667
|
ot(() => {
|
|
2668
2668
|
c && a(0);
|
|
2669
2669
|
}, [c]);
|
|
2670
|
-
let { refs: v, floatingStyles: w, context: x } = Nu({ open: c, placement: h === "selection" ? b === "center" ? "bottom" : `bottom-${b}` : b === "center" ? `${h}` : `${h}-${b}`, strategy: "absolute", transform: !1, middleware: [Gs({ mainAxis: h === "selection" ? 0 : p, crossAxis: m }), bo({ padding: d }), h !== "selection" && vo({ padding: d }), h === "selection" && g ?
|
|
2670
|
+
let { refs: v, floatingStyles: w, context: x } = Nu({ open: c, placement: h === "selection" ? b === "center" ? "bottom" : `bottom-${b}` : b === "center" ? `${h}` : `${h}-${b}`, strategy: "absolute", transform: !1, middleware: [Gs({ mainAxis: h === "selection" ? 0 : p, crossAxis: m }), bo({ padding: d }), h !== "selection" && vo({ padding: d }), h === "selection" && g ? Pu({ ...g, padding: d, overflowRef: o, offset: n, minItemsVisible: Zn, referenceOverflowThreshold: d, onFallbackChange($) {
|
|
2671
2671
|
var L, _;
|
|
2672
2672
|
if (!$) return;
|
|
2673
2673
|
let R = x.elements.floating;
|
|
2674
2674
|
if (!R) return;
|
|
2675
|
-
let D = parseFloat(getComputedStyle(R).scrollPaddingBottom) || 0, F = Math.min(Zn, R.childElementCount), U = 0,
|
|
2675
|
+
let D = parseFloat(getComputedStyle(R).scrollPaddingBottom) || 0, F = Math.min(Zn, R.childElementCount), U = 0, P = 0;
|
|
2676
2676
|
for (let j of (_ = (L = x.elements.floating) == null ? void 0 : L.childNodes) != null ? _ : []) if (wt(j)) {
|
|
2677
2677
|
let H = j.offsetTop, nt = H + j.clientHeight + D, et = R.scrollTop, A = et + R.clientHeight;
|
|
2678
2678
|
if (H >= et && nt <= A) F--;
|
|
2679
2679
|
else {
|
|
2680
|
-
|
|
2680
|
+
P = Math.max(0, Math.min(nt, A) - Math.max(H, et)), U = j.clientHeight;
|
|
2681
2681
|
break;
|
|
2682
2682
|
}
|
|
2683
2683
|
}
|
|
2684
2684
|
F >= 1 && a((j) => {
|
|
2685
|
-
let H = U * F -
|
|
2685
|
+
let H = U * F - P + D;
|
|
2686
2686
|
return j >= H ? j : H;
|
|
2687
2687
|
});
|
|
2688
2688
|
} }) : null, xo({ padding: d, apply({ availableWidth: $, availableHeight: L, elements: _ }) {
|
|
2689
2689
|
Object.assign(_.floating.style, { overflow: "auto", maxWidth: `${$}px`, maxHeight: `min(var(--anchor-max-height, 100vh), ${L}px)` });
|
|
2690
2690
|
} })].filter(Boolean), whileElementsMounted: mo }), [k = h, E = b] = x.placement.split("-");
|
|
2691
2691
|
h === "selection" && (k = "selection");
|
|
2692
|
-
let T = ft(() => ({ anchor: [k, E].filter(Boolean).join(" ") }), [k, E]),
|
|
2692
|
+
let T = ft(() => ({ anchor: [k, E].filter(Boolean).join(" ") }), [k, E]), O = Cu(x, { overflowRef: o, onChange: a }), { getReferenceProps: M, getFloatingProps: z } = Ou([O]), N = I(($) => {
|
|
2693
2693
|
l($), v.setFloating($);
|
|
2694
2694
|
});
|
|
2695
2695
|
return y.createElement(Ks.Provider, { value: s }, y.createElement(Le.Provider, { value: { setFloating: N, setReference: v.setReference, styles: w, getReferenceProps: M, getFloatingProps: z, slot: T } }, t));
|
|
@@ -2840,17 +2840,17 @@ function ee(t, e) {
|
|
|
2840
2840
|
function dr(t) {
|
|
2841
2841
|
let e = I(t), r = V(!1);
|
|
2842
2842
|
st(() => (r.current = !1, () => {
|
|
2843
|
-
r.current = !0,
|
|
2843
|
+
r.current = !0, Ps(() => {
|
|
2844
2844
|
r.current && e();
|
|
2845
2845
|
});
|
|
2846
2846
|
}), [e]);
|
|
2847
2847
|
}
|
|
2848
|
-
let
|
|
2848
|
+
let Oo = pt(!1);
|
|
2849
2849
|
function Au() {
|
|
2850
|
-
return at(
|
|
2850
|
+
return at(Oo);
|
|
2851
2851
|
}
|
|
2852
2852
|
function ta(t) {
|
|
2853
|
-
return S.createElement(
|
|
2853
|
+
return S.createElement(Oo.Provider, { value: t.force }, t.children);
|
|
2854
2854
|
}
|
|
2855
2855
|
function Du(t) {
|
|
2856
2856
|
let e = Au(), r = at(Co), [s, n] = X(() => {
|
|
@@ -2869,7 +2869,7 @@ function Du(t) {
|
|
|
2869
2869
|
e || r !== null && n(r.current);
|
|
2870
2870
|
}, [r, n, e]), s;
|
|
2871
2871
|
}
|
|
2872
|
-
let
|
|
2872
|
+
let Po = xt, Fu = Q(function(t, e) {
|
|
2873
2873
|
let { ownerDocument: r = null, ...s } = t, n = V(null), a = lt(Ha((m) => {
|
|
2874
2874
|
n.current = m;
|
|
2875
2875
|
}), e), o = Xt(n.current), i = r ?? o, l = Du(i), c = at(ys), u = zt(), p = J();
|
|
@@ -2878,11 +2878,11 @@ let Oo = xt, Fu = Q(function(t, e) {
|
|
|
2878
2878
|
l && l.childNodes.length <= 0 && ((m = l.parentElement) == null || m.removeChild(l));
|
|
2879
2879
|
}), l ? $a(S.createElement("div", { "data-headlessui-portal": "", ref: (m) => {
|
|
2880
2880
|
u.dispose(), c && m && u.add(c.register(m));
|
|
2881
|
-
} }, p({ ourProps: { ref: a }, theirProps: s, slot: {}, defaultTag:
|
|
2881
|
+
} }, p({ ourProps: { ref: a }, theirProps: s, slot: {}, defaultTag: Po, name: "Portal" })), l) : null;
|
|
2882
2882
|
});
|
|
2883
2883
|
function Mu(t, e) {
|
|
2884
2884
|
let r = lt(e), { enabled: s = !0, ownerDocument: n, ...a } = t, o = J();
|
|
2885
|
-
return s ? S.createElement(Fu, { ...a, ownerDocument: n, ref: r }) : o({ ourProps: { ref: r }, theirProps: a, slot: {}, defaultTag:
|
|
2885
|
+
return s ? S.createElement(Fu, { ...a, ownerDocument: n, ref: r }) : o({ ourProps: { ref: r }, theirProps: a, slot: {}, defaultTag: Po, name: "Portal" });
|
|
2886
2886
|
}
|
|
2887
2887
|
let Lu = xt, Co = pt(null);
|
|
2888
2888
|
function _u(t, e) {
|
|
@@ -2944,7 +2944,7 @@ function $o({ defaultContainers: t = [], portals: e, mainTreeNode: r } = {}) {
|
|
|
2944
2944
|
return { resolveContainers: s, contains: I((n) => s().some((a) => a.contains(n))) };
|
|
2945
2945
|
}
|
|
2946
2946
|
let Io = pt(null);
|
|
2947
|
-
function
|
|
2947
|
+
function Pr({ children: t, node: e }) {
|
|
2948
2948
|
let [r, s] = X(null), n = en(e ?? r);
|
|
2949
2949
|
return S.createElement(Io.Provider, { value: n }, t, n === null && S.createElement(qt, { features: Vt.Hidden, ref: (a) => {
|
|
2950
2950
|
var o, i;
|
|
@@ -3005,9 +3005,9 @@ function Uu(t, e) {
|
|
|
3005
3005
|
let x = r.current;
|
|
3006
3006
|
((k) => k())(() => {
|
|
3007
3007
|
ht(p.current, { [Ct.Forwards]: () => {
|
|
3008
|
-
|
|
3008
|
+
Pt(x, gt.First, { skipElements: [w.relatedTarget, a] });
|
|
3009
3009
|
}, [Ct.Backwards]: () => {
|
|
3010
|
-
|
|
3010
|
+
Pt(x, gt.Last, { skipElements: [w.relatedTarget, a] });
|
|
3011
3011
|
} });
|
|
3012
3012
|
});
|
|
3013
3013
|
}), d = nr(!!(i & 2), "focus-trap#tab-lock"), g = zt(), h = V(!1), b = { ref: s, onKeyDown(w) {
|
|
@@ -3019,7 +3019,7 @@ function Uu(t, e) {
|
|
|
3019
3019
|
let x = Ao(o);
|
|
3020
3020
|
wt(r.current) && x.add(r.current);
|
|
3021
3021
|
let k = w.relatedTarget;
|
|
3022
|
-
$t(k) && k.dataset.headlessuiFocusGuard !== "true" && (Do(x, k) || (h.current ?
|
|
3022
|
+
$t(k) && k.dataset.headlessuiFocusGuard !== "true" && (Do(x, k) || (h.current ? Pt(r.current, ht(p.current, { [Ct.Forwards]: () => gt.Next, [Ct.Backwards]: () => gt.Previous }) | gt.WrapAround, { relativeTo: w.target }) : $t(w.target) && Lt(w.target)));
|
|
3023
3023
|
} }, v = J();
|
|
3024
3024
|
return S.createElement(S.Fragment, null, d && S.createElement(qt, { as: "button", type: "button", "data-headlessui-focus-guard": !0, onFocus: m, features: Vt.Focusable }), v({ ourProps: b, theirProps: l, defaultTag: Wu, name: "FocusTrap" }), d && S.createElement(qt, { as: "button", type: "button", "data-headlessui-focus-guard": !0, onFocus: m, features: Vt.Focusable }));
|
|
3025
3025
|
}
|
|
@@ -3027,7 +3027,7 @@ let Yu = Q(Uu), Gu = Object.assign(Yu, { features: ue });
|
|
|
3027
3027
|
function Ku(t = !0) {
|
|
3028
3028
|
let e = V(Jt.slice());
|
|
3029
3029
|
return Vs(([r], [s]) => {
|
|
3030
|
-
s === !0 && r === !1 &&
|
|
3030
|
+
s === !0 && r === !1 && Ps(() => {
|
|
3031
3031
|
e.current.splice(0);
|
|
3032
3032
|
}), s === !1 && r === !0 && (e.current = Jt.slice());
|
|
3033
3033
|
}, [t, Jt, e]), I(() => {
|
|
@@ -3052,7 +3052,7 @@ function Xu(t, { ownerDocument: e, container: r, initialFocus: s, initialFocusFa
|
|
|
3052
3052
|
return;
|
|
3053
3053
|
}
|
|
3054
3054
|
let l = r.current;
|
|
3055
|
-
l &&
|
|
3055
|
+
l && Ps(() => {
|
|
3056
3056
|
if (!i.current) return;
|
|
3057
3057
|
let c = e?.activeElement;
|
|
3058
3058
|
if (s != null && s.current) {
|
|
@@ -3067,8 +3067,8 @@ function Xu(t, { ownerDocument: e, container: r, initialFocus: s, initialFocusFa
|
|
|
3067
3067
|
if (s != null && s.current) Lt(s.current);
|
|
3068
3068
|
else {
|
|
3069
3069
|
if (t & 16) {
|
|
3070
|
-
if (
|
|
3071
|
-
} else if (
|
|
3070
|
+
if (Pt(l, gt.First | gt.AutoFocus) !== Ce.Error) return;
|
|
3071
|
+
} else if (Pt(l, gt.First) !== Ce.Error) return;
|
|
3072
3072
|
if (n != null && n.current && (Lt(n.current), e?.activeElement === n.current)) return;
|
|
3073
3073
|
console.warn("There are no focusable elements inside the <FocusTrap />");
|
|
3074
3074
|
}
|
|
@@ -3145,39 +3145,39 @@ function Mo(t, e) {
|
|
|
3145
3145
|
let Lo = xt, _o = At.RenderStrategy;
|
|
3146
3146
|
function ed(t, e) {
|
|
3147
3147
|
var r, s;
|
|
3148
|
-
let { transition: n = !0, beforeEnter: a, afterEnter: o, beforeLeave: i, afterLeave: l, enter: c, enterFrom: u, enterTo: p, entered: m, leave: d, leaveFrom: g, leaveTo: h, ...b } = t, [v, w] = X(null), x = V(null), k = Fo(t), E = lt(...k ? [x, e, w] : e === null ? [] : [e]), T = (r = b.unmount) == null || r ? de.Unmount : de.Hidden, { show:
|
|
3148
|
+
let { transition: n = !0, beforeEnter: a, afterEnter: o, beforeLeave: i, afterLeave: l, enter: c, enterFrom: u, enterTo: p, entered: m, leave: d, leaveFrom: g, leaveTo: h, ...b } = t, [v, w] = X(null), x = V(null), k = Fo(t), E = lt(...k ? [x, e, w] : e === null ? [] : [e]), T = (r = b.unmount) == null || r ? de.Unmount : de.Hidden, { show: O, appear: M, initial: z } = Ju(), [N, $] = X(O ? "visible" : "hidden"), L = td(), { register: _, unregister: R } = L;
|
|
3149
3149
|
ot(() => _(x), [_, x]), ot(() => {
|
|
3150
3150
|
if (T === de.Hidden && x.current) {
|
|
3151
|
-
if (
|
|
3151
|
+
if (O && N !== "visible") {
|
|
3152
3152
|
$("visible");
|
|
3153
3153
|
return;
|
|
3154
3154
|
}
|
|
3155
3155
|
return ht(N, { hidden: () => R(x), visible: () => _(x) });
|
|
3156
3156
|
}
|
|
3157
|
-
}, [N, x, _, R,
|
|
3157
|
+
}, [N, x, _, R, O, T]);
|
|
3158
3158
|
let D = Yr();
|
|
3159
3159
|
ot(() => {
|
|
3160
3160
|
if (k && D && N === "visible" && x.current === null) throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?");
|
|
3161
3161
|
}, [x, N, D, k]);
|
|
3162
|
-
let F = z && !M, U = M &&
|
|
3163
|
-
|
|
3162
|
+
let F = z && !M, U = M && O && z, P = V(!1), j = Mo(() => {
|
|
3163
|
+
P.current || ($("hidden"), R(x));
|
|
3164
3164
|
}, L), H = I((q) => {
|
|
3165
|
-
|
|
3165
|
+
P.current = !0;
|
|
3166
3166
|
let bt = q ? "enter" : "leave";
|
|
3167
3167
|
j.onStart(x, bt, (yt) => {
|
|
3168
3168
|
yt === "enter" ? a?.() : yt === "leave" && i?.();
|
|
3169
3169
|
});
|
|
3170
3170
|
}), nt = I((q) => {
|
|
3171
3171
|
let bt = q ? "enter" : "leave";
|
|
3172
|
-
|
|
3172
|
+
P.current = !1, j.onStop(x, bt, (yt) => {
|
|
3173
3173
|
yt === "enter" ? o?.() : yt === "leave" && l?.();
|
|
3174
3174
|
}), bt === "leave" && !qr(j) && ($("hidden"), R(x));
|
|
3175
3175
|
});
|
|
3176
3176
|
st(() => {
|
|
3177
|
-
k && n || (H(
|
|
3178
|
-
}, [
|
|
3179
|
-
let et = !(!n || !k || !D || F), [, A] = cr(et, v,
|
|
3180
|
-
N === "visible" && (G |= ut.Open), N === "hidden" && (G |= ut.Closed),
|
|
3177
|
+
k && n || (H(O), nt(O));
|
|
3178
|
+
}, [O, k, n]);
|
|
3179
|
+
let et = !(!n || !k || !D || F), [, A] = cr(et, v, O, { start: H, end: nt }), W = Ea({ ref: E, className: ((s = Li(b.className, U && c, U && u, A.enter && c, A.enter && A.closed && u, A.enter && !A.closed && p, A.leave && d, A.leave && !A.closed && g, A.leave && A.closed && h, !A.transition && O && m)) == null ? void 0 : s.trim()) || void 0, ...lr(A) }), G = 0;
|
|
3180
|
+
N === "visible" && (G |= ut.Open), N === "hidden" && (G |= ut.Closed), O && N === "hidden" && (G |= ut.Opening), !O && N === "visible" && (G |= ut.Closing);
|
|
3181
3181
|
let B = J();
|
|
3182
3182
|
return S.createElement(Kr.Provider, { value: j }, S.createElement(Wr, { value: G }, B({ ourProps: W, theirProps: b, defaultTag: Lo, features: _o, visible: N === "visible", name: "Transition.Child" })));
|
|
3183
3183
|
}
|
|
@@ -3233,10 +3233,10 @@ let ea = Q(function(t, e) {
|
|
|
3233
3233
|
})();
|
|
3234
3234
|
let d = ie();
|
|
3235
3235
|
n === void 0 && d !== null && (n = (d & ut.Open) === ut.Open);
|
|
3236
|
-
let g = V(null), h = lt(g, e), b = Xt(g.current), v = n ? 0 : 1, [w, x] = Qi(id, { titleId: null, descriptionId: null, panelRef: Zi() }), k = I(() => a(!1)), E = I((A) => x({ type: 0, id: A })), T = Yr() ? v === 0 : !1, [
|
|
3236
|
+
let g = V(null), h = lt(g, e), b = Xt(g.current), v = n ? 0 : 1, [w, x] = Qi(id, { titleId: null, descriptionId: null, panelRef: Zi() }), k = I(() => a(!1)), E = I((A) => x({ type: 0, id: A })), T = Yr() ? v === 0 : !1, [O, M] = To(), z = { get current() {
|
|
3237
3237
|
var A;
|
|
3238
3238
|
return (A = w.panelRef.current) != null ? A : g.current;
|
|
3239
|
-
} }, N = en(), { resolveContainers: $ } = $o({ mainTreeNode: N, portals:
|
|
3239
|
+
} }, N = en(), { resolveContainers: $ } = $o({ mainTreeNode: N, portals: O, defaultContainers: [z] }), L = d !== null ? (d & ut.Closing) === ut.Closing : !1;
|
|
3240
3240
|
Ms(c || L ? !1 : T, { allowed: I(() => {
|
|
3241
3241
|
var A, W;
|
|
3242
3242
|
return [(W = (A = g.current) == null ? void 0 : A.closest("[data-headlessui-portal]")) != null ? W : null];
|
|
@@ -3254,10 +3254,10 @@ let ea = Q(function(t, e) {
|
|
|
3254
3254
|
}), Bu(R, b?.defaultView, (A) => {
|
|
3255
3255
|
A.preventDefault(), A.stopPropagation(), document.activeElement && "blur" in document.activeElement && typeof document.activeElement.blur == "function" && document.activeElement.blur(), k();
|
|
3256
3256
|
}), Lr(c || L ? !1 : T, b, $), Dr(T, g, k);
|
|
3257
|
-
let [D, F] = $r(), U = ft(() => [{ dialogState: v, close: k, setTitleId: E, unmount: u }, w], [v, k, E, u, w]),
|
|
3257
|
+
let [D, F] = $r(), U = ft(() => [{ dialogState: v, close: k, setTitleId: E, unmount: u }, w], [v, k, E, u, w]), P = ct({ open: v === 0 }), j = { ref: h, id: s, role: i, tabIndex: -1, "aria-modal": c ? void 0 : v === 0 ? !0 : void 0, "aria-labelledby": w.titleId, "aria-describedby": D, unmount: u }, H = !Hu(), nt = ue.None;
|
|
3258
3258
|
T && !c && (nt |= ue.RestoreFocus, nt |= ue.TabLock, l && (nt |= ue.AutoFocus), H && (nt |= ue.InitialFocus));
|
|
3259
3259
|
let et = J();
|
|
3260
|
-
return S.createElement(No, null, S.createElement(ta, { force: !0 }, S.createElement(Ur, null, S.createElement(nn.Provider, { value: U }, S.createElement(jo, { target: g }, S.createElement(ta, { force: !1 }, S.createElement(F, { slot:
|
|
3260
|
+
return S.createElement(No, null, S.createElement(ta, { force: !0 }, S.createElement(Ur, null, S.createElement(nn.Provider, { value: U }, S.createElement(jo, { target: g }, S.createElement(ta, { force: !1 }, S.createElement(F, { slot: P }, S.createElement(M, null, S.createElement(Gu, { initialFocus: o, initialFocusFallback: g, containers: $, features: nt }, S.createElement(As, { value: k }, et({ ourProps: j, theirProps: p, slot: P, defaultTag: ld, features: cd, visible: v === 0, name: "Dialog" })))))))))));
|
|
3261
3261
|
}), ld = "div", cd = At.RenderStrategy | At.Static;
|
|
3262
3262
|
function ud(t, e) {
|
|
3263
3263
|
let { transition: r = !1, open: s, ...n } = t, a = ie(), o = t.hasOwnProperty("open") || a !== null, i = t.hasOwnProperty("onClose");
|
|
@@ -3266,7 +3266,7 @@ function ud(t, e) {
|
|
|
3266
3266
|
if (!i) throw new Error("You provided an `open` prop to the `Dialog`, but forgot an `onClose` prop.");
|
|
3267
3267
|
if (!a && typeof t.open != "boolean") throw new Error(`You provided an \`open\` prop to the \`Dialog\`, but the value is not a boolean. Received: ${t.open}`);
|
|
3268
3268
|
if (typeof t.onClose != "function") throw new Error(`You provided an \`onClose\` prop to the \`Dialog\`, but the value is not a function. Received: ${t.onClose}`);
|
|
3269
|
-
return (s !== void 0 || r) && !n.static ? S.createElement(
|
|
3269
|
+
return (s !== void 0 || r) && !n.static ? S.createElement(Pr, null, S.createElement(je, { show: s, transition: r, unmount: n.unmount }, S.createElement(ea, { ref: e, ...n }))) : S.createElement(Pr, null, S.createElement(ea, { ref: e, open: s, ...n }));
|
|
3270
3270
|
}
|
|
3271
3271
|
let dd = "div";
|
|
3272
3272
|
function fd(t, e) {
|
|
@@ -3335,7 +3335,7 @@ function zo(t) {
|
|
|
3335
3335
|
return e.current = n, r.current = a, a;
|
|
3336
3336
|
});
|
|
3337
3337
|
}
|
|
3338
|
-
var
|
|
3338
|
+
var Od = Object.defineProperty, Pd = (t, e, r) => e in t ? Od(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, na = (t, e, r) => (Pd(t, typeof e != "symbol" ? e + "" : e, r), r), Et = ((t) => (t[t.Open = 0] = "Open", t[t.Closed = 1] = "Closed", t))(Et || {}), re = ((t) => (t[t.Single = 0] = "Single", t[t.Multi = 1] = "Multi", t))(re || {}), kr = ((t) => (t[t.Pointer = 0] = "Pointer", t[t.Other = 1] = "Other", t))(kr || {}), Wo = ((t) => (t[t.OpenListbox = 0] = "OpenListbox", t[t.CloseListbox = 1] = "CloseListbox", t[t.GoToOption = 2] = "GoToOption", t[t.Search = 3] = "Search", t[t.ClearSearch = 4] = "ClearSearch", t[t.SelectOption = 5] = "SelectOption", t[t.RegisterOptions = 6] = "RegisterOptions", t[t.UnregisterOptions = 7] = "UnregisterOptions", t[t.SetButtonElement = 8] = "SetButtonElement", t[t.SetOptionsElement = 9] = "SetOptionsElement", t[t.SortOptions = 10] = "SortOptions", t[t.MarkButtonAsMoved = 11] = "MarkButtonAsMoved", t))(Wo || {});
|
|
3339
3339
|
function aa(t, e = (r) => r) {
|
|
3340
3340
|
let r = t.activeOptionIndex !== null ? t.options[t.activeOptionIndex] : null, s = Ls(e(t.options.slice()), (a) => a.dataRef.current.domRef.current), n = r ? s.indexOf(r) : null;
|
|
3341
3341
|
return n === -1 && (n = null), { options: s, activeOptionIndex: n };
|
|
@@ -3519,7 +3519,7 @@ let jd = xt;
|
|
|
3519
3519
|
function Rd(t, e) {
|
|
3520
3520
|
let r = dt(), s = oe(), { value: n, defaultValue: a, form: o, name: i, onChange: l, by: c, invalid: u = !1, disabled: p = s || !1, horizontal: m = !1, multiple: d = !1, __demoMode: g = !1, ...h } = t;
|
|
3521
3521
|
const b = m ? "horizontal" : "vertical";
|
|
3522
|
-
let v = lt(e), w = js(a), [x = d ? [] : void 0, k] = Ts(n, l, w), E = Go({ id: r, __demoMode: g }), T = V({ static: !1, hold: !1 }),
|
|
3522
|
+
let v = lt(e), w = js(a), [x = d ? [] : void 0, k] = Ts(n, l, w), E = Go({ id: r, __demoMode: g }), T = V({ static: !1, hold: !1 }), O = V(/* @__PURE__ */ new Map()), M = Sl(c), z = tt((et) => ht(N.mode, { [re.Multi]: () => x.some((A) => M(A, et)), [re.Single]: () => M(x, et) }), [x]), N = ct({ value: x, disabled: p, invalid: u, mode: d ? re.Multi : re.Single, orientation: b, onChange: k, compare: M, isSelected: z, optionsPropsRef: T, listRef: O });
|
|
3523
3523
|
ot(() => {
|
|
3524
3524
|
E.state.dataRef.current = N;
|
|
3525
3525
|
}, [N]);
|
|
@@ -3527,10 +3527,10 @@ function Rd(t, e) {
|
|
|
3527
3527
|
Fr(_, [R, D], (et, A) => {
|
|
3528
3528
|
E.send({ type: Wo.CloseListbox }), ir(A, or.Loose) || (et.preventDefault(), R?.focus());
|
|
3529
3529
|
});
|
|
3530
|
-
let F = ct({ open: $ === Et.Open, disabled: p, invalid: u, value: x }), [U,
|
|
3530
|
+
let F = ct({ open: $ === Et.Open, disabled: p, invalid: u, value: x }), [U, P] = sr({ inherit: !0 }), j = { ref: v }, H = tt(() => {
|
|
3531
3531
|
if (w !== void 0) return k?.(w);
|
|
3532
3532
|
}, [k, w]), nt = J();
|
|
3533
|
-
return S.createElement(
|
|
3533
|
+
return S.createElement(P, { value: U, props: { htmlFor: R?.id }, slot: { open: $ === Et.Open, disabled: p } }, S.createElement(Js, null, S.createElement(Yo.Provider, { value: E }, S.createElement(Zr.Provider, { value: N }, S.createElement(Wr, { value: ht($, { [Et.Open]: ut.Open, [Et.Closed]: ut.Closed }) }, i != null && x != null && S.createElement($s, { disabled: p, data: { [i]: x }, form: o, onReset: H }), nt({ ourProps: j, theirProps: h, slot: F, defaultTag: jd, name: "Listbox" }))))));
|
|
3534
3534
|
}
|
|
3535
3535
|
let $d = "button";
|
|
3536
3536
|
function Id(t, e) {
|
|
@@ -3558,7 +3558,7 @@ function Id(t, e) {
|
|
|
3558
3558
|
}), w = Ua((D) => {
|
|
3559
3559
|
var F;
|
|
3560
3560
|
a.state.listboxState === Et.Open ? (he(() => a.actions.closeListbox()), (F = a.state.buttonElement) == null || F.focus({ preventScroll: !0 })) : (D.preventDefault(), a.actions.openListbox({ focus: K.Nothing }));
|
|
3561
|
-
}), x = I((D) => D.preventDefault()), k = Ae([o]), E = er(), { isFocusVisible: T, focusProps:
|
|
3561
|
+
}), x = I((D) => D.preventDefault()), k = Ae([o]), E = er(), { isFocusVisible: T, focusProps: O } = ve({ autoFocus: l }), { isHovered: M, hoverProps: z } = xe({ isDisabled: i }), { pressed: N, pressProps: $ } = tr({ disabled: i }), L = ct({ open: m === Et.Open, active: N || m === Et.Open, disabled: i, invalid: n.invalid, value: n.value, hover: M, focus: T, autofocus: l }), _ = rt(a, (D) => D.listboxState === Et.Open), R = It(p(), { ref: u, id: o, type: Mr(t, d), "aria-haspopup": "listbox", "aria-controls": g?.id, "aria-expanded": _, "aria-labelledby": k, "aria-describedby": E, disabled: i || void 0, autoFocus: l, onKeyDown: b, onKeyUp: v, onKeyPress: x }, w, O, z, $);
|
|
3562
3562
|
return J()({ ourProps: R, theirProps: c, slot: L, defaultTag: $d, name: "Listbox.Button" });
|
|
3563
3563
|
}
|
|
3564
3564
|
let Ko = pt(!1), Ad = "div", Dd = At.RenderStrategy | At.Static;
|
|
@@ -3567,8 +3567,8 @@ function Fd(t, e) {
|
|
|
3567
3567
|
c && (a = !0);
|
|
3568
3568
|
let m = fr("Listbox.Options"), d = an("Listbox.Options"), [g, h, b, v] = rt(d, (B) => [B.listboxState, B.buttonElement, B.optionsElement, B.__demoMode]), w = Xt(h), x = Xt(b), k = ie(), [E, T] = cr(i, u, k !== null ? (k & ut.Open) === ut.Open : g === Et.Open);
|
|
3569
3569
|
Dr(E, h, d.actions.closeListbox);
|
|
3570
|
-
let
|
|
3571
|
-
Lr(
|
|
3570
|
+
let O = v ? !1 : o && g === Et.Open;
|
|
3571
|
+
Lr(O, x);
|
|
3572
3572
|
let M = v ? !1 : o && g === Et.Open;
|
|
3573
3573
|
Ms(M, { allowed: tt(() => [h, b], [h, b]) });
|
|
3574
3574
|
let z = rt(d, d.selectors.didButtonMove) ? !1 : E, N = rt(d, d.selectors.hasFrozenValue) && !t.static, $ = Eo(N, m.value), L = tt((B) => m.compare($, B), [m.compare, $]), _ = rt(d, (B) => {
|
|
@@ -3581,7 +3581,7 @@ function Fd(t, e) {
|
|
|
3581
3581
|
if (_ === null) return { ...c, inner: void 0 };
|
|
3582
3582
|
let B = Array.from(m.listRef.current.values());
|
|
3583
3583
|
return { ...c, inner: { listRef: { current: B }, index: _ } };
|
|
3584
|
-
})(), [D, F] = Zs(R), U = Qs(),
|
|
3584
|
+
})(), [D, F] = Zs(R), U = Qs(), P = lt(e, c ? D : null, d.actions.setOptionsElement, p), j = zt();
|
|
3585
3585
|
st(() => {
|
|
3586
3586
|
let B = b;
|
|
3587
3587
|
B && g === Et.Open && (Cs(B) || B == null || B.focus({ preventScroll: !0 }));
|
|
@@ -3617,7 +3617,7 @@ function Fd(t, e) {
|
|
|
3617
3617
|
}), nt = rt(d, (B) => {
|
|
3618
3618
|
var q;
|
|
3619
3619
|
return (q = B.buttonElement) == null ? void 0 : q.id;
|
|
3620
|
-
}), et = ct({ open: g === Et.Open }), A = It(c ? U() : {}, { id: s, ref:
|
|
3620
|
+
}), et = ct({ open: g === Et.Open }), A = It(c ? U() : {}, { id: s, ref: P, "aria-activedescendant": rt(d, d.selectors.activeDescendantId), "aria-multiselectable": m.mode === re.Multi ? !0 : void 0, "aria-labelledby": nt, "aria-orientation": m.orientation, onKeyDown: H, role: "listbox", tabIndex: g === Et.Open ? 0 : void 0, style: { ...l.style, ...F, "--button-width": Ds(E, h, !0).width }, ...lr(T) }), W = J(), G = ft(() => m.mode === re.Multi ? m : { ...m, isSelected: L }, [m, L]);
|
|
3621
3621
|
return S.createElement(Ur, { enabled: a ? t.static || E : !1, ownerDocument: w }, S.createElement(Zr.Provider, { value: G }, W({ ourProps: A, theirProps: l, slot: et, defaultTag: Ad, features: Dd, visible: z, name: "Listbox.Options" })));
|
|
3622
3622
|
}
|
|
3623
3623
|
let Md = "div";
|
|
@@ -3645,8 +3645,8 @@ function Ld(t, e) {
|
|
|
3645
3645
|
x.wasMoved(N) && (n || u && c.state.activationTrigger === kr.Pointer || c.actions.goToOption({ focus: K.Specific, id: s }, kr.Pointer));
|
|
3646
3646
|
}), T = I((N) => {
|
|
3647
3647
|
x.wasMoved(N) && (n || u && c.state.activationTrigger === kr.Pointer && c.actions.goToOption({ focus: K.Nothing }));
|
|
3648
|
-
}),
|
|
3649
|
-
return !p && i ? null : z({ ourProps: M, theirProps: o, slot:
|
|
3648
|
+
}), O = ct({ active: u, focus: u, selected: p, disabled: n, selectedOption: p && i }), M = i ? {} : { id: s, ref: h, role: "option", tabIndex: n === !0 ? void 0 : -1, "aria-disabled": n === !0 ? !0 : void 0, "aria-selected": p, disabled: void 0, onClick: v, onFocus: w, onPointerEnter: k, onMouseEnter: k, onPointerMove: E, onMouseMove: E, onPointerLeave: T, onMouseLeave: T }, z = J();
|
|
3649
|
+
return !p && i ? null : z({ ourProps: M, theirProps: o, slot: O, defaultTag: Md, name: "Listbox.Option" });
|
|
3650
3650
|
}
|
|
3651
3651
|
let _d = xt;
|
|
3652
3652
|
function Vd(t, e) {
|
|
@@ -3810,68 +3810,68 @@ function Zd(t, e) {
|
|
|
3810
3810
|
let v = Ua((N) => {
|
|
3811
3811
|
var $;
|
|
3812
3812
|
a || (d === kt.Open ? (he(() => r.send({ type: it.CloseMenu })), ($ = l.current) == null || $.focus({ preventScroll: !0 })) : (N.preventDefault(), r.send({ type: it.OpenMenu, focus: { focus: K.Nothing }, trigger: Cr.Pointer })));
|
|
3813
|
-
}), { isFocusVisible: w, focusProps: x } = ve({ autoFocus: o }), { isHovered: k, hoverProps: E } = xe({ isDisabled: a }), { pressed: T, pressProps:
|
|
3813
|
+
}), { isFocusVisible: w, focusProps: x } = ve({ autoFocus: o }), { isHovered: k, hoverProps: E } = xe({ isDisabled: a }), { pressed: T, pressProps: O } = tr({ disabled: a }), M = ct({ open: d === kt.Open, active: T || d === kt.Open, disabled: a, hover: k, focus: w, autofocus: o }), z = It(c(), { ref: u, id: n, type: Mr(t, l.current), "aria-haspopup": "menu", "aria-controls": h?.id, "aria-expanded": d === kt.Open, disabled: a || void 0, autoFocus: o, onKeyDown: p, onKeyUp: m }, v, x, E, O);
|
|
3814
3814
|
return J()({ ourProps: z, theirProps: i, slot: M, defaultTag: Qd, name: "Menu.Button" });
|
|
3815
3815
|
}
|
|
3816
3816
|
let Jd = "div", tf = At.RenderStrategy | At.Static;
|
|
3817
3817
|
function ef(t, e) {
|
|
3818
|
-
let r = dt(), { id: s = `headlessui-menu-items-${r}`, anchor: n, portal: a = !1, modal: o = !0, transition: i = !1, ...l } = t, c = qs(n), u = on("Menu.Items"), [p, m] = Zs(c), d = Qs(), [g, h] = X(null), b = lt(e, c ? p : null, I((
|
|
3818
|
+
let r = dt(), { id: s = `headlessui-menu-items-${r}`, anchor: n, portal: a = !1, modal: o = !0, transition: i = !1, ...l } = t, c = qs(n), u = on("Menu.Items"), [p, m] = Zs(c), d = Qs(), [g, h] = X(null), b = lt(e, c ? p : null, I((P) => u.send({ type: it.SetItemsElement, element: P })), h), [v, w] = rt(u, (P) => [P.menuState, P.buttonElement]), x = Xt(w), k = Xt(g);
|
|
3819
3819
|
c && (a = !0);
|
|
3820
|
-
let E = ie(), [T,
|
|
3820
|
+
let E = ie(), [T, O] = cr(i, g, E !== null ? (E & ut.Open) === ut.Open : v === kt.Open);
|
|
3821
3821
|
Dr(T, w, () => {
|
|
3822
3822
|
u.send({ type: it.CloseMenu });
|
|
3823
3823
|
});
|
|
3824
|
-
let M = rt(u, (
|
|
3824
|
+
let M = rt(u, (P) => P.__demoMode), z = M ? !1 : o && v === kt.Open;
|
|
3825
3825
|
Lr(z, k);
|
|
3826
3826
|
let N = M ? !1 : o && v === kt.Open;
|
|
3827
3827
|
Ms(N, { allowed: tt(() => [w, g], [w, g]) });
|
|
3828
3828
|
let $ = rt(u, u.selectors.didButtonMove) ? !1 : T;
|
|
3829
3829
|
st(() => {
|
|
3830
|
-
let
|
|
3831
|
-
|
|
3832
|
-
}, [v, g]), nc(v === kt.Open, { container: g, accept(
|
|
3833
|
-
return
|
|
3834
|
-
}, walk(
|
|
3835
|
-
|
|
3830
|
+
let P = g;
|
|
3831
|
+
P && v === kt.Open && (Cs(P) || P.focus({ preventScroll: !0 }));
|
|
3832
|
+
}, [v, g]), nc(v === kt.Open, { container: g, accept(P) {
|
|
3833
|
+
return P.getAttribute("role") === "menuitem" ? NodeFilter.FILTER_REJECT : P.hasAttribute("role") ? NodeFilter.FILTER_SKIP : NodeFilter.FILTER_ACCEPT;
|
|
3834
|
+
}, walk(P) {
|
|
3835
|
+
P.setAttribute("role", "none");
|
|
3836
3836
|
} });
|
|
3837
|
-
let L = zt(), _ = I((
|
|
3837
|
+
let L = zt(), _ = I((P) => {
|
|
3838
3838
|
var j, H, nt;
|
|
3839
|
-
switch (L.dispose(),
|
|
3839
|
+
switch (L.dispose(), P.key) {
|
|
3840
3840
|
case Y.Space:
|
|
3841
|
-
if (u.state.searchQuery !== "") return
|
|
3841
|
+
if (u.state.searchQuery !== "") return P.preventDefault(), P.stopPropagation(), u.send({ type: it.Search, value: P.key });
|
|
3842
3842
|
case Y.Enter:
|
|
3843
|
-
if (
|
|
3843
|
+
if (P.preventDefault(), P.stopPropagation(), u.state.activeItemIndex !== null) {
|
|
3844
3844
|
let { dataRef: et } = u.state.items[u.state.activeItemIndex];
|
|
3845
3845
|
(H = (j = et.current) == null ? void 0 : j.domRef.current) == null || H.click();
|
|
3846
3846
|
}
|
|
3847
3847
|
u.send({ type: it.CloseMenu }), Xa(u.state.buttonElement);
|
|
3848
3848
|
break;
|
|
3849
3849
|
case Y.ArrowDown:
|
|
3850
|
-
return
|
|
3850
|
+
return P.preventDefault(), P.stopPropagation(), u.send({ type: it.GoToItem, focus: K.Next });
|
|
3851
3851
|
case Y.ArrowUp:
|
|
3852
|
-
return
|
|
3852
|
+
return P.preventDefault(), P.stopPropagation(), u.send({ type: it.GoToItem, focus: K.Previous });
|
|
3853
3853
|
case Y.Home:
|
|
3854
3854
|
case Y.PageUp:
|
|
3855
|
-
return
|
|
3855
|
+
return P.preventDefault(), P.stopPropagation(), u.send({ type: it.GoToItem, focus: K.First });
|
|
3856
3856
|
case Y.End:
|
|
3857
3857
|
case Y.PageDown:
|
|
3858
|
-
return
|
|
3858
|
+
return P.preventDefault(), P.stopPropagation(), u.send({ type: it.GoToItem, focus: K.Last });
|
|
3859
3859
|
case Y.Escape:
|
|
3860
|
-
|
|
3860
|
+
P.preventDefault(), P.stopPropagation(), he(() => u.send({ type: it.CloseMenu })), (nt = u.state.buttonElement) == null || nt.focus({ preventScroll: !0 });
|
|
3861
3861
|
break;
|
|
3862
3862
|
case Y.Tab:
|
|
3863
|
-
|
|
3863
|
+
P.preventDefault(), P.stopPropagation(), he(() => u.send({ type: it.CloseMenu })), Qa(u.state.buttonElement, P.shiftKey ? gt.Previous : gt.Next);
|
|
3864
3864
|
break;
|
|
3865
3865
|
default:
|
|
3866
|
-
|
|
3866
|
+
P.key.length === 1 && (u.send({ type: it.Search, value: P.key }), L.setTimeout(() => u.send({ type: it.ClearSearch }), 350));
|
|
3867
3867
|
break;
|
|
3868
3868
|
}
|
|
3869
|
-
}), R = I((
|
|
3870
|
-
|
|
3871
|
-
}), D = ct({ open: v === kt.Open }), F = It(c ? d() : {}, { "aria-activedescendant": rt(u, u.selectors.activeDescendantId), "aria-labelledby": rt(u, (
|
|
3869
|
+
}), R = I((P) => {
|
|
3870
|
+
P.key === Y.Space && P.preventDefault();
|
|
3871
|
+
}), D = ct({ open: v === kt.Open }), F = It(c ? d() : {}, { "aria-activedescendant": rt(u, u.selectors.activeDescendantId), "aria-labelledby": rt(u, (P) => {
|
|
3872
3872
|
var j;
|
|
3873
|
-
return (j =
|
|
3874
|
-
}), id: s, onKeyDown: _, onKeyUp: R, role: "menu", tabIndex: v === kt.Open ? 0 : void 0, ref: b, style: { ...l.style, ...m, "--button-width": Ds(T, w, !0).width }, ...lr(
|
|
3873
|
+
return (j = P.buttonElement) == null ? void 0 : j.id;
|
|
3874
|
+
}), id: s, onKeyDown: _, onKeyUp: R, role: "menu", tabIndex: v === kt.Open ? 0 : void 0, ref: b, style: { ...l.style, ...m, "--button-width": Ds(T, w, !0).width }, ...lr(O) }), U = J();
|
|
3875
3875
|
return S.createElement(Ur, { enabled: a ? t.static || T : !1, ownerDocument: x }, U({ ourProps: F, theirProps: l, slot: D, defaultTag: Jd, features: tf, visible: $, name: "Menu.Items" }));
|
|
3876
3876
|
}
|
|
3877
3877
|
let rf = xt;
|
|
@@ -3901,8 +3901,8 @@ function sf(t, e) {
|
|
|
3901
3901
|
b.wasMoved($) && (n || i || o.send({ type: it.GoToItem, focus: K.Specific, id: s, trigger: Cr.Pointer }));
|
|
3902
3902
|
}), x = I(($) => {
|
|
3903
3903
|
b.wasMoved($) && (n || i && o.state.activationTrigger === Cr.Pointer && o.send({ type: it.GoToItem, focus: K.Nothing }));
|
|
3904
|
-
}), [k, E] = sr(), [T,
|
|
3905
|
-
return S.createElement(E, null, S.createElement(
|
|
3904
|
+
}), [k, E] = sr(), [T, O] = $r(), M = ct({ active: i, focus: i, disabled: n, close: d }), z = { id: s, ref: c, role: "menuitem", tabIndex: n === !0 ? void 0 : -1, "aria-disabled": n === !0 ? !0 : void 0, "aria-labelledby": k, "aria-describedby": T, disabled: void 0, onClick: g, onFocus: h, onPointerEnter: v, onMouseEnter: v, onPointerMove: w, onMouseMove: w, onPointerLeave: x, onMouseLeave: x }, N = J();
|
|
3905
|
+
return S.createElement(E, null, S.createElement(O, null, N({ ourProps: z, theirProps: a, slot: M, defaultTag: rf, name: "Menu.Item" })));
|
|
3906
3906
|
}
|
|
3907
3907
|
let nf = "div";
|
|
3908
3908
|
function af(t, e) {
|
|
@@ -3994,21 +3994,21 @@ function Sf(t, e) {
|
|
|
3994
3994
|
return (D = w?.isFocusWithinPopoverGroup()) != null ? D : F && (u?.contains(F) || p?.contains(F));
|
|
3995
3995
|
});
|
|
3996
3996
|
st(() => x?.(v), [x, v]);
|
|
3997
|
-
let [E, T] = To(),
|
|
3997
|
+
let [E, T] = To(), O = en(u), M = $o({ mainTreeNode: O, portals: E, defaultContainers: [{ get current() {
|
|
3998
3998
|
return o.state.button;
|
|
3999
3999
|
} }, { get current() {
|
|
4000
4000
|
return o.state.panel;
|
|
4001
4001
|
} }] });
|
|
4002
4002
|
_s(g, "focus", (R) => {
|
|
4003
|
-
var D, F, U,
|
|
4004
|
-
R.target !== window && $t(R.target) && o.state.popoverState === vt.Open && (k() || o.state.button && o.state.panel && (M.contains(R.target) || (F = (D = o.state.beforePanelSentinel.current) == null ? void 0 : D.contains) != null && F.call(D, R.target) || (
|
|
4003
|
+
var D, F, U, P, j, H;
|
|
4004
|
+
R.target !== window && $t(R.target) && o.state.popoverState === vt.Open && (k() || o.state.button && o.state.panel && (M.contains(R.target) || (F = (D = o.state.beforePanelSentinel.current) == null ? void 0 : D.contains) != null && F.call(D, R.target) || (P = (U = o.state.afterPanelSentinel.current) == null ? void 0 : U.contains) != null && P.call(U, R.target) || (H = (j = o.state.afterButtonSentinel.current) == null ? void 0 : j.contains) != null && H.call(j, R.target) || o.actions.close()));
|
|
4005
4005
|
}, !0);
|
|
4006
4006
|
let z = c === vt.Open;
|
|
4007
4007
|
Fr(z, M.resolveContainers, (R, D) => {
|
|
4008
4008
|
o.actions.close(), ir(D, or.Loose) || (R.preventDefault(), u?.focus());
|
|
4009
4009
|
});
|
|
4010
4010
|
let N = ct({ open: c === vt.Open, close: o.actions.refocusableClose }), $ = rt(o, tt((R) => ht(R.popoverState, { [vt.Open]: ut.Open, [vt.Closed]: ut.Closed }), [])), L = { ref: l }, _ = J();
|
|
4011
|
-
return S.createElement(
|
|
4011
|
+
return S.createElement(Pr, { node: O }, S.createElement(Js, null, S.createElement(ts.Provider, { value: null }, S.createElement(si.Provider, { value: o }, S.createElement(As, { value: o.actions.refocusableClose }, S.createElement(Wr, { value: $ }, S.createElement(T, null, _({ ourProps: L, theirProps: a, slot: N, defaultTag: kf, name: "Popover" }))))))));
|
|
4012
4012
|
}
|
|
4013
4013
|
let Ef = "button";
|
|
4014
4014
|
function Nf(t, e) {
|
|
@@ -4025,7 +4025,7 @@ function Nf(t, e) {
|
|
|
4025
4025
|
}
|
|
4026
4026
|
i.state.buttons.current.length > 1 && console.warn("You are already using a <Popover.Button /> but only 1 <Popover.Button /> is supported."), W && i.actions.setButton(W);
|
|
4027
4027
|
}
|
|
4028
|
-
})), T = lt(h, e),
|
|
4028
|
+
})), T = lt(h, e), O = I((W) => {
|
|
4029
4029
|
var G, B, q;
|
|
4030
4030
|
if (x) {
|
|
4031
4031
|
if (i.state.popoverState === vt.Closed) return;
|
|
@@ -4052,30 +4052,30 @@ function Nf(t, e) {
|
|
|
4052
4052
|
x || W.key === Y.Space && W.preventDefault();
|
|
4053
4053
|
}), z = I((W) => {
|
|
4054
4054
|
var G, B;
|
|
4055
|
-
|
|
4055
|
+
Pe(W.currentTarget) || n || (x ? (i.actions.close(), (G = i.state.button) == null || G.focus()) : (W.preventDefault(), W.stopPropagation(), i.state.popoverState === vt.Closed ? (w?.(i.state.buttonId), i.actions.open()) : i.actions.close(), (B = i.state.button) == null || B.focus()));
|
|
4056
4056
|
}), N = I((W) => {
|
|
4057
4057
|
W.preventDefault(), W.stopPropagation();
|
|
4058
|
-
}), { isFocusVisible: $, focusProps: L } = ve({ autoFocus: a }), { isHovered: _, hoverProps: R } = xe({ isDisabled: n }), { pressed: D, pressProps: F } = tr({ disabled: n }), U = l === vt.Open,
|
|
4058
|
+
}), { isFocusVisible: $, focusProps: L } = ve({ autoFocus: a }), { isHovered: _, hoverProps: R } = xe({ isDisabled: n }), { pressed: D, pressProps: F } = tr({ disabled: n }), U = l === vt.Open, P = ct({ open: U, active: D || U, disabled: n, hover: _, focus: $, autofocus: a }), j = Mr(t, u), H = x ? It({ ref: T, type: j, onKeyDown: O, onClick: z, disabled: n || void 0, autoFocus: a }, L, R, F) : It({ ref: E, id: p, type: j, "aria-expanded": l === vt.Open, "aria-controls": m ? d : void 0, disabled: n || void 0, autoFocus: a, onKeyDown: O, onKeyUp: M, onClick: z, onMouseDown: N }, L, R, F), nt = sn(), et = I(() => {
|
|
4059
4059
|
if (!wt(i.state.panel)) return;
|
|
4060
4060
|
let W = i.state.panel;
|
|
4061
4061
|
function G() {
|
|
4062
|
-
ht(nt.current, { [Ct.Forwards]: () =>
|
|
4062
|
+
ht(nt.current, { [Ct.Forwards]: () => Pt(W, gt.First), [Ct.Backwards]: () => Pt(W, gt.Last) }) === Ce.Error && Pt(ar(me(i.state.button)).filter((B) => B.dataset.headlessuiFocusGuard !== "true"), ht(nt.current, { [Ct.Forwards]: gt.Next, [Ct.Backwards]: gt.Previous }), { relativeTo: i.state.button });
|
|
4063
4063
|
}
|
|
4064
4064
|
G();
|
|
4065
4065
|
}), A = J();
|
|
4066
|
-
return S.createElement(S.Fragment, null, A({ ourProps: H, theirProps: o, slot:
|
|
4066
|
+
return S.createElement(S.Fragment, null, A({ ourProps: H, theirProps: o, slot: P, defaultTag: Ef, name: "Popover.Button" }), U && !x && c && S.createElement(qt, { id: b, ref: g, features: Vt.Focusable, "data-headlessui-focus-guard": !0, as: "button", type: "button", onFocus: et }));
|
|
4067
4067
|
}
|
|
4068
|
-
let
|
|
4068
|
+
let Of = "div", Pf = At.RenderStrategy | At.Static;
|
|
4069
4069
|
function ai(t, e) {
|
|
4070
4070
|
let r = dt(), { id: s = `headlessui-popover-backdrop-${r}`, transition: n = !1, ...a } = t, o = Jr("Popover.Backdrop"), i = rt(o, tt((v) => v.popoverState, [])), [l, c] = X(null), u = lt(e, c), p = ie(), [m, d] = cr(n, l, p !== null ? (p & ut.Open) === ut.Open : i === vt.Open), g = I((v) => {
|
|
4071
|
-
if (
|
|
4071
|
+
if (Pe(v.currentTarget)) return v.preventDefault();
|
|
4072
4072
|
o.actions.close();
|
|
4073
4073
|
}), h = ct({ open: i === vt.Open }), b = { ref: u, id: s, "aria-hidden": !0, onClick: g, ...lr(d) };
|
|
4074
|
-
return J()({ ourProps: b, theirProps: a, slot: h, defaultTag:
|
|
4074
|
+
return J()({ ourProps: b, theirProps: a, slot: h, defaultTag: Of, features: Pf, visible: m, name: "Popover.Backdrop" });
|
|
4075
4075
|
}
|
|
4076
4076
|
let Cf = "div", Tf = At.RenderStrategy | At.Static;
|
|
4077
4077
|
function jf(t, e) {
|
|
4078
|
-
let r = dt(), { id: s = `headlessui-popover-panel-${r}`, focus: n = !1, anchor: a, portal: o = !1, modal: i = !1, transition: l = !1, ...c } = t, u = Jr("Popover.Panel"), p = rt(u, u.selectors.isPortalled), [m, d, g, h, b] = rt(u, tt((A) => [A.popoverState, A.button, A.__demoMode, A.beforePanelSentinel, A.afterPanelSentinel], [])), v = `headlessui-focus-sentinel-before-${r}`, w = `headlessui-focus-sentinel-after-${r}`, x = V(null), k = qs(a), [E, T] = Zs(k),
|
|
4078
|
+
let r = dt(), { id: s = `headlessui-popover-panel-${r}`, focus: n = !1, anchor: a, portal: o = !1, modal: i = !1, transition: l = !1, ...c } = t, u = Jr("Popover.Panel"), p = rt(u, u.selectors.isPortalled), [m, d, g, h, b] = rt(u, tt((A) => [A.popoverState, A.button, A.__demoMode, A.beforePanelSentinel, A.afterPanelSentinel], [])), v = `headlessui-focus-sentinel-before-${r}`, w = `headlessui-focus-sentinel-after-${r}`, x = V(null), k = qs(a), [E, T] = Zs(k), O = Qs();
|
|
4079
4079
|
k && (o = !0);
|
|
4080
4080
|
let [M, z] = X(null), N = lt(x, e, k ? E : null, u.actions.setPanel, z), $ = Xt(d), L = Xt(x.current);
|
|
4081
4081
|
ot(() => (u.actions.setPanelId(s), () => u.actions.setPanelId(null)), [s, u]);
|
|
@@ -4098,9 +4098,9 @@ function jf(t, e) {
|
|
|
4098
4098
|
}, [m, t.unmount, t.static, u]), st(() => {
|
|
4099
4099
|
if (g || !n || m !== vt.Open || !x.current) return;
|
|
4100
4100
|
let A = ge(x.current);
|
|
4101
|
-
x.current.contains(A) ||
|
|
4101
|
+
x.current.contains(A) || Pt(x.current, gt.First);
|
|
4102
4102
|
}, [g, n, x.current, m]);
|
|
4103
|
-
let U = ct({ open: m === vt.Open, close: u.actions.refocusableClose }),
|
|
4103
|
+
let U = ct({ open: m === vt.Open, close: u.actions.refocusableClose }), P = It(k ? O() : {}, { ref: N, id: s, onKeyDown: F, onBlur: n && m === vt.Open ? (A) => {
|
|
4104
4104
|
var W, G, B, q, bt;
|
|
4105
4105
|
let yt = A.relatedTarget;
|
|
4106
4106
|
yt && x.current && ((W = x.current) != null && W.contains(yt) || (u.actions.close(), ((B = (G = h.current) == null ? void 0 : G.contains) != null && B.call(G, yt) || (bt = (q = b.current) == null ? void 0 : q.contains) != null && bt.call(q, yt)) && yt.focus({ preventScroll: !0 })));
|
|
@@ -4110,7 +4110,7 @@ function jf(t, e) {
|
|
|
4110
4110
|
function W() {
|
|
4111
4111
|
ht(j.current, { [Ct.Forwards]: () => {
|
|
4112
4112
|
var G;
|
|
4113
|
-
|
|
4113
|
+
Pt(A, gt.First) === Ce.Error && ((G = u.state.afterPanelSentinel.current) == null || G.focus());
|
|
4114
4114
|
}, [Ct.Backwards]: () => {
|
|
4115
4115
|
var G;
|
|
4116
4116
|
(G = u.state.button) == null || G.focus({ preventScroll: !0 });
|
|
@@ -4129,15 +4129,15 @@ function jf(t, e) {
|
|
|
4129
4129
|
let mr = Se.indexOf(_e);
|
|
4130
4130
|
mr !== -1 && Se.splice(mr, 1);
|
|
4131
4131
|
}
|
|
4132
|
-
|
|
4132
|
+
Pt(Se, gt.First, { sorted: !1 });
|
|
4133
4133
|
}, [Ct.Backwards]: () => {
|
|
4134
4134
|
var G;
|
|
4135
|
-
|
|
4135
|
+
Pt(A, gt.Previous) === Ce.Error && ((G = u.state.button) == null || G.focus());
|
|
4136
4136
|
} });
|
|
4137
4137
|
}
|
|
4138
4138
|
W();
|
|
4139
4139
|
}), et = J();
|
|
4140
|
-
return S.createElement(No, null, S.createElement(ts.Provider, { value: s }, S.createElement(As, { value: u.actions.refocusableClose }, S.createElement(Ur, { enabled: o ? t.static || R : !1, ownerDocument: $ }, R && p && S.createElement(qt, { id: v, ref: h, features: Vt.Focusable, "data-headlessui-focus-guard": !0, as: "button", type: "button", onFocus: H }), et({ ourProps:
|
|
4140
|
+
return S.createElement(No, null, S.createElement(ts.Provider, { value: s }, S.createElement(As, { value: u.actions.refocusableClose }, S.createElement(Ur, { enabled: o ? t.static || R : !1, ownerDocument: $ }, R && p && S.createElement(qt, { id: v, ref: h, features: Vt.Focusable, "data-headlessui-focus-guard": !0, as: "button", type: "button", onFocus: H }), et({ ourProps: P, theirProps: c, slot: U, defaultTag: Cf, features: Tf, visible: R, name: "Popover.Panel" }), R && p && S.createElement(qt, { id: w, ref: b, features: Vt.Focusable, "data-headlessui-focus-guard": !0, as: "button", type: "button", onFocus: nt })))));
|
|
4141
4141
|
}
|
|
4142
4142
|
let Rf = "div";
|
|
4143
4143
|
function $f(t, e) {
|
|
@@ -4162,7 +4162,7 @@ function $f(t, e) {
|
|
|
4162
4162
|
}), c = I((h) => {
|
|
4163
4163
|
for (let b of n) b.buttonId.current !== h && b.close();
|
|
4164
4164
|
}), u = ft(() => ({ registerPopover: i, unregisterPopover: o, isFocusWithinPopoverGroup: l, closeOthers: c }), [i, o, l, c]), p = ct({}), m = t, d = { ref: s }, g = J();
|
|
4165
|
-
return S.createElement(
|
|
4165
|
+
return S.createElement(Pr, null, S.createElement(cn.Provider, { value: u }, g({ ourProps: d, theirProps: m, slot: p, defaultTag: Rf, name: "Popover.Group" })));
|
|
4166
4166
|
}
|
|
4167
4167
|
let If = Q(Sf), Tr = Q(Nf), Af = Q(ai), Df = Q(ai), un = Q(jf), Ff = Q($f), oi = Object.assign(If, { Button: Tr, Backdrop: Df, Overlay: Af, Panel: un, Group: Ff }), dn = pt(null);
|
|
4168
4168
|
dn.displayName = "GroupContext";
|
|
@@ -4177,18 +4177,18 @@ function Lf(t) {
|
|
|
4177
4177
|
let _f = "button";
|
|
4178
4178
|
function Vf(t, e) {
|
|
4179
4179
|
var r;
|
|
4180
|
-
let s = dt(), n = Ie(), a = oe(), { id: o = n || `headlessui-switch-${s}`, disabled: i = a || !1, checked: l, defaultChecked: c, onChange: u, name: p, value: m, form: d, autoFocus: g = !1, ...h } = t, b = at(dn), [v, w] = X(null), x = V(null), k = lt(x, e, b === null ? null : b.setSwitch, w), E = js(c), [T,
|
|
4181
|
-
N(!0),
|
|
4180
|
+
let s = dt(), n = Ie(), a = oe(), { id: o = n || `headlessui-switch-${s}`, disabled: i = a || !1, checked: l, defaultChecked: c, onChange: u, name: p, value: m, form: d, autoFocus: g = !1, ...h } = t, b = at(dn), [v, w] = X(null), x = V(null), k = lt(x, e, b === null ? null : b.setSwitch, w), E = js(c), [T, O] = Ts(l, u, E ?? !1), M = zt(), [z, N] = X(!1), $ = I(() => {
|
|
4181
|
+
N(!0), O?.(!T), M.nextFrame(() => {
|
|
4182
4182
|
N(!1);
|
|
4183
4183
|
});
|
|
4184
4184
|
}), L = I((q) => {
|
|
4185
|
-
if (
|
|
4185
|
+
if (Pe(q.currentTarget)) return q.preventDefault();
|
|
4186
4186
|
q.preventDefault(), $();
|
|
4187
4187
|
}), _ = I((q) => {
|
|
4188
4188
|
q.key === Y.Space ? (q.preventDefault(), $()) : q.key === Y.Enter && Rs(q.currentTarget);
|
|
4189
|
-
}), R = I((q) => q.preventDefault()), D = Ae(), F = er(), { isFocusVisible: U, focusProps:
|
|
4190
|
-
if (E !== void 0) return
|
|
4191
|
-
}, [
|
|
4189
|
+
}), R = I((q) => q.preventDefault()), D = Ae(), F = er(), { isFocusVisible: U, focusProps: P } = ve({ autoFocus: g }), { isHovered: j, hoverProps: H } = xe({ isDisabled: i }), { pressed: nt, pressProps: et } = tr({ disabled: i }), A = ct({ checked: T, disabled: i, hover: j, focus: U, active: nt, autofocus: g, changing: z }), W = It({ id: o, ref: k, role: "switch", type: Mr(t, v), tabIndex: t.tabIndex === -1 ? 0 : (r = t.tabIndex) != null ? r : 0, "aria-checked": T, "aria-labelledby": D, "aria-describedby": F, disabled: i || void 0, autoFocus: g, onClick: L, onKeyUp: _, onKeyPress: R }, P, H, et), G = tt(() => {
|
|
4190
|
+
if (E !== void 0) return O?.(E);
|
|
4191
|
+
}, [O, E]), B = J();
|
|
4192
4192
|
return S.createElement(S.Fragment, null, p != null && S.createElement($s, { disabled: i, data: { [p]: m || "on" }, overrides: { type: "checkbox", checked: T }, form: d, onReset: G }), B({ ourProps: W, theirProps: h, slot: A, defaultTag: _f, name: "Switch" }));
|
|
4193
4193
|
}
|
|
4194
4194
|
let Bf = Q(Vf), Hf = Lf, zf = De, Wf = rr, Uf = Object.assign(Bf, { Group: Hf, Label: zf, Description: Wf }), Yf = "textarea";
|
|
@@ -4342,14 +4342,14 @@ const Xf = Z(
|
|
|
4342
4342
|
{ fill: "outline", variant: "error", className: "rst:border-error-600 rst:text-error-600 rst:dark:border-error-500 rst:dark:text-error-400" },
|
|
4343
4343
|
{ fill: "outline", variant: "neutral", className: "rst:border-gray-500 rst:text-gray-600 rst:dark:border-gray-500 rst:dark:text-gray-400" },
|
|
4344
4344
|
// --- SOLID ---
|
|
4345
|
-
{ fill: "solid", variant: "primary", className: "rst:border-transparent rst:bg-primary-500 rst:hover:bg-primary-600 rst:
|
|
4346
|
-
{ fill: "solid", variant: "orange", className: "rst:border-transparent rst:bg-orange-500 rst:hover:bg-orange-400 rst:
|
|
4347
|
-
{ fill: "solid", variant: "teal", className: "rst:border-transparent rst:bg-teal-500 rst:hover:bg-teal-600 rst:
|
|
4348
|
-
{ fill: "solid", variant: "purple", className: "rst:border-transparent rst:bg-purple-500 rst:hover:bg-purple-400 rst:
|
|
4349
|
-
{ fill: "solid", variant: "amber", className: "rst:border-transparent rst:bg-amber-400 rst:hover:bg-amber-500 rst:
|
|
4350
|
-
{ fill: "solid", variant: "success", className: "rst:border-transparent rst:bg-success-500 rst:hover:bg-success-400 rst:
|
|
4351
|
-
{ fill: "solid", variant: "error", className: "rst:border-transparent rst:bg-error-500 rst:hover:bg-error-600 rst:
|
|
4352
|
-
{ fill: "solid", variant: "neutral", className: "rst:border-transparent rst:bg-gray-500 rst:hover:bg-gray-600 rst:
|
|
4345
|
+
{ fill: "solid", variant: "primary", className: "rst:border-transparent rst:bg-primary-500 rst:hover:bg-primary-600 rst:dark:bg-primary-600 rst:dark:hover:bg-primary-500 rst:text-primary-500-ink rst:hover:text-primary-600-ink rst:dark:text-primary-600-ink rst:dark:hover:text-primary-500-ink" },
|
|
4346
|
+
{ fill: "solid", variant: "orange", className: "rst:border-transparent rst:bg-orange-500 rst:hover:bg-orange-400 rst:dark:bg-orange-600 rst:dark:hover:bg-orange-700 rst:text-orange-500-ink rst:hover:text-orange-400-ink rst:dark:text-orange-600-ink rst:dark:hover:text-orange-700-ink" },
|
|
4347
|
+
{ fill: "solid", variant: "teal", className: "rst:border-transparent rst:bg-teal-500 rst:hover:bg-teal-600 rst:dark:bg-teal-600 rst:dark:hover:bg-teal-500 rst:text-teal-500-ink rst:hover:text-teal-600-ink rst:dark:text-teal-600-ink rst:dark:hover:text-teal-500-ink" },
|
|
4348
|
+
{ fill: "solid", variant: "purple", className: "rst:border-transparent rst:bg-purple-500 rst:hover:bg-purple-400 rst:dark:bg-purple-600 rst:dark:hover:bg-purple-700 rst:text-purple-500-ink rst:hover:text-purple-400-ink rst:dark:text-purple-600-ink rst:dark:hover:text-purple-700-ink" },
|
|
4349
|
+
{ fill: "solid", variant: "amber", className: "rst:border-transparent rst:bg-amber-400 rst:hover:bg-amber-500 rst:dark:bg-amber-500 rst:dark:hover:bg-amber-400 rst:text-amber-400-ink rst:hover:text-amber-500-ink rst:dark:text-amber-500-ink rst:dark:hover:text-amber-400-ink" },
|
|
4350
|
+
{ fill: "solid", variant: "success", className: "rst:border-transparent rst:bg-success-500 rst:hover:bg-success-400 rst:dark:bg-success-600 rst:dark:hover:bg-success-700 rst:text-success-500-ink rst:hover:text-success-400-ink rst:dark:text-success-600-ink rst:dark:hover:text-success-700-ink" },
|
|
4351
|
+
{ fill: "solid", variant: "error", className: "rst:border-transparent rst:bg-error-500 rst:hover:bg-error-600 rst:dark:bg-error-600 rst:dark:hover:bg-error-500 rst:text-error-500-ink rst:hover:text-error-600-ink rst:dark:text-error-600-ink rst:dark:hover:text-error-500-ink" },
|
|
4352
|
+
{ fill: "solid", variant: "neutral", className: "rst:border-transparent rst:bg-gray-500 rst:hover:bg-gray-600 rst:dark:bg-gray-600 rst:dark:hover:bg-gray-500 rst:text-gray-500-ink rst:hover:text-gray-600-ink rst:dark:text-gray-600-ink rst:dark:hover:text-gray-500-ink" },
|
|
4353
4353
|
// --- STATUS PILL SIZES ---
|
|
4354
4354
|
{ statusBadge: !0, size: "xs", className: "rst:min-w-[1.25rem] rst:h-5 rst:px-1" },
|
|
4355
4355
|
{ statusBadge: !0, size: "sm", className: "rst:min-w-[1.5rem] rst:h-6 rst:px-1.5" },
|
|
@@ -4502,14 +4502,14 @@ const Jf = Z(
|
|
|
4502
4502
|
},
|
|
4503
4503
|
compoundVariants: [
|
|
4504
4504
|
// --- SOLID VARIANTS ---
|
|
4505
|
-
{ checked: !0, variant: "solid", colorScheme: "primary", className: "rst:bg-primary-600 rst:border-primary-600 rst:
|
|
4506
|
-
{ checked: !0, variant: "solid", colorScheme: "orange", className: "rst:bg-orange-600 rst:border-orange-600 rst:
|
|
4507
|
-
{ checked: !0, variant: "solid", colorScheme: "teal", className: "rst:bg-teal-600 rst:border-teal-600 rst:
|
|
4508
|
-
{ checked: !0, variant: "solid", colorScheme: "purple", className: "rst:bg-purple-600 rst:border-purple-600 rst:
|
|
4509
|
-
{ checked: !0, variant: "solid", colorScheme: "amber", className: "rst:bg-amber-400 rst:border-amber-400 rst:
|
|
4510
|
-
{ checked: !0, variant: "solid", colorScheme: "success", className: "rst:bg-success-600 rst:border-success-600 rst:
|
|
4511
|
-
{ checked: !0, variant: "solid", colorScheme: "error", className: "rst:bg-error-600 rst:border-error-600 rst:
|
|
4512
|
-
{ checked: !0, variant: "solid", colorScheme: "neutral", className: "rst:bg-gray-600 rst:border-gray-600 rst:
|
|
4505
|
+
{ checked: !0, variant: "solid", colorScheme: "primary", className: "rst:bg-primary-600 rst:border-primary-600 rst:dark:bg-primary-600 rst:dark:border-primary-500 rst:text-primary-600-ink" },
|
|
4506
|
+
{ checked: !0, variant: "solid", colorScheme: "orange", className: "rst:bg-orange-600 rst:border-orange-600 rst:dark:bg-orange-600 rst:dark:border-orange-500 rst:text-orange-600-ink" },
|
|
4507
|
+
{ checked: !0, variant: "solid", colorScheme: "teal", className: "rst:bg-teal-600 rst:border-teal-600 rst:dark:bg-teal-600 rst:dark:border-teal-500 rst:text-teal-600-ink" },
|
|
4508
|
+
{ checked: !0, variant: "solid", colorScheme: "purple", className: "rst:bg-purple-600 rst:border-purple-600 rst:dark:bg-purple-600 rst:dark:border-purple-500 rst:text-purple-600-ink" },
|
|
4509
|
+
{ checked: !0, variant: "solid", colorScheme: "amber", className: "rst:bg-amber-400 rst:border-amber-400 rst:dark:bg-amber-500 rst:dark:border-amber-500 rst:text-amber-400-ink rst:dark:text-amber-500-ink" },
|
|
4510
|
+
{ checked: !0, variant: "solid", colorScheme: "success", className: "rst:bg-success-600 rst:border-success-600 rst:dark:bg-success-600 rst:dark:border-success-500 rst:text-success-600-ink" },
|
|
4511
|
+
{ checked: !0, variant: "solid", colorScheme: "error", className: "rst:bg-error-600 rst:border-error-600 rst:dark:bg-error-600 rst:dark:border-error-500 rst:text-error-600-ink" },
|
|
4512
|
+
{ checked: !0, variant: "solid", colorScheme: "neutral", className: "rst:bg-gray-600 rst:border-gray-600 rst:dark:bg-gray-600 rst:dark:border-gray-500 rst:text-gray-600-ink" },
|
|
4513
4513
|
// --- SOFT VARIANTS ---
|
|
4514
4514
|
{ checked: !0, variant: "soft", colorScheme: "primary", className: "rst:bg-primary-50 rst:border-primary-200 rst:text-primary-700 rst:dark:bg-primary-900/40 rst:dark:border-primary-800/50 rst:dark:text-primary-300" },
|
|
4515
4515
|
{ checked: !0, variant: "soft", colorScheme: "orange", className: "rst:bg-orange-50 rst:border-orange-200 rst:text-orange-700 rst:dark:bg-orange-900/30 rst:dark:border-orange-800/50 rst:dark:text-orange-300" },
|
|
@@ -4652,7 +4652,7 @@ const e0 = Z(
|
|
|
4652
4652
|
children: i || /* @__PURE__ */ f.jsx(
|
|
4653
4653
|
mt,
|
|
4654
4654
|
{
|
|
4655
|
-
icon:
|
|
4655
|
+
icon: Oa,
|
|
4656
4656
|
className: "rst:h-3.5 rst:w-3.5 rst:opacity-60"
|
|
4657
4657
|
}
|
|
4658
4658
|
)
|
|
@@ -4682,16 +4682,44 @@ const e0 = Z(
|
|
|
4682
4682
|
)
|
|
4683
4683
|
] });
|
|
4684
4684
|
}, n0 = Z(
|
|
4685
|
-
|
|
4685
|
+
/* `h-10 px-4` are floors, not defaults. `VariantProps` admits `null`, so
|
|
4686
|
+
`size={fieldSize ?? null}` typechecks and `defaultVariants` cannot catch it
|
|
4687
|
+
— and because padding moved out of this base into the size scale, a null
|
|
4688
|
+
size produced a field with no height AND no horizontal padding, text flush
|
|
4689
|
+
against the border. `cn()` is tailwind-merge, so a real size still wins. */
|
|
4690
|
+
"rst:font-ui rst:flex rst:w-full rst:rounded-md rst:border rst:h-10 rst:px-4 rst:text-sm rst:ring-offset-background rst:focus-visible:ring-offset-2 rst:file:border-0 rst:file:bg-transparent rst:file:text-sm rst:file:font-medium rst:focus-visible:outline-hidden rst:focus-visible:ring-2 rst:focus-visible:ring-ring rst:disabled:cursor-not-allowed rst:disabled:opacity-50 rst:transition-all",
|
|
4686
4691
|
{
|
|
4687
4692
|
variants: {
|
|
4688
4693
|
variant: {
|
|
4689
4694
|
white: "rst:border-gray-300 rst:bg-white rst:text-gray-900 rst:placeholder:text-gray-400 rst:focus-visible:border-primary-500 rst:dark:border-gray-700 rst:dark:bg-gray-800 rst:dark:text-gray-100 rst:dark:placeholder:text-gray-500",
|
|
4690
4695
|
soft: "rst:border-transparent rst:bg-gray-100 rst:text-gray-900 rst:placeholder:text-gray-400 rst:focus-visible:bg-white rst:focus-visible:border-primary-500 rst:dark:bg-gray-800 rst:dark:text-gray-100 rst:dark:placeholder:text-gray-500 rst:dark:focus-visible:bg-gray-900",
|
|
4691
4696
|
slate: "rst:border-transparent rst:bg-gray-700 rst:text-gray-100 rst:placeholder:text-gray-400 rst:focus-visible:bg-gray-600 rst:dark:bg-gray-900 rst:dark:placeholder:text-gray-500 rst:dark:focus-visible:bg-gray-800",
|
|
4692
|
-
|
|
4697
|
+
/* The default variant, and the only one that reads tokens.
|
|
4698
|
+
`Button`'s colors resolve through `--roster-*`, so remapping a palette
|
|
4699
|
+
carries; these were hardcoded, so a consumer wanting a field border in
|
|
4700
|
+
their own accent had no variant for it and no token to point at.
|
|
4701
|
+
The four tokens default to exactly the values this variant used
|
|
4702
|
+
before, so nothing moves for a consumer who sets none of them at
|
|
4703
|
+
`:root`. The other four
|
|
4704
|
+
variants stay opinionated on purpose: `white`, `soft`, `slate` and
|
|
4705
|
+
`ghost` each name a specific surface, and a token that meant something
|
|
4706
|
+
different in each would not be a token. */
|
|
4707
|
+
outline: "rst:border-[var(--roster-control-border)] rst:bg-[var(--roster-control-bg)] rst:text-[var(--roster-control-text)] rst:placeholder:text-gray-400 rst:focus-visible:border-[var(--roster-control-border-focus)] rst:dark:placeholder:text-gray-500",
|
|
4693
4708
|
ghost: "rst:border-transparent rst:bg-transparent rst:text-gray-900 rst:placeholder:text-gray-400 rst:hover:bg-gray-100 rst:focus-visible:bg-gray-100 rst:dark:text-gray-100 rst:dark:placeholder:text-gray-500 rst:dark:hover:bg-gray-800 rst:dark:focus-visible:bg-gray-800"
|
|
4694
4709
|
},
|
|
4710
|
+
/* Deliberately the same three heights as Button: h-9 / h-10 / h-11.
|
|
4711
|
+
Input was a fixed 42px, which agreed with Button at no size at all, so
|
|
4712
|
+
a field beside a submit button never lined up. retrospect gave up and
|
|
4713
|
+
kept a raw <input> pinned to h-11. */
|
|
4714
|
+
size: {
|
|
4715
|
+
sm: "rst:h-9 rst:px-3",
|
|
4716
|
+
default: "rst:h-10 rst:px-4",
|
|
4717
|
+
/* Heights mirror Button exactly. Padding does not at `lg`: Button is
|
|
4718
|
+
`px-8`, which centres a short label, while a field's text should
|
|
4719
|
+
start near its edge at every size. The alignment contract is the
|
|
4720
|
+
height, and that is what the parity test asserts. */
|
|
4721
|
+
lg: "rst:h-11 rst:px-4"
|
|
4722
|
+
},
|
|
4695
4723
|
error: {
|
|
4696
4724
|
true: "rst:border-error-500 rst:focus-visible:ring-error-500 rst:text-error-600 rst:placeholder:text-error-300 rst:dark:border-error-500 rst:dark:text-error-400 rst:dark:placeholder:text-error-800 rst:dark:focus-visible:ring-error-400",
|
|
4697
4725
|
false: ""
|
|
@@ -4699,6 +4727,7 @@ const e0 = Z(
|
|
|
4699
4727
|
},
|
|
4700
4728
|
defaultVariants: {
|
|
4701
4729
|
variant: "outline",
|
|
4730
|
+
size: "default",
|
|
4702
4731
|
error: !1
|
|
4703
4732
|
}
|
|
4704
4733
|
}
|
|
@@ -4731,72 +4760,88 @@ const e0 = Z(
|
|
|
4731
4760
|
helperText: s,
|
|
4732
4761
|
errorMessage: n,
|
|
4733
4762
|
variant: a,
|
|
4734
|
-
|
|
4735
|
-
|
|
4736
|
-
|
|
4737
|
-
|
|
4738
|
-
|
|
4739
|
-
|
|
4740
|
-
|
|
4741
|
-
|
|
4742
|
-
|
|
4743
|
-
|
|
4744
|
-
|
|
4745
|
-
|
|
4746
|
-
|
|
4747
|
-
|
|
4748
|
-
|
|
4749
|
-
|
|
4750
|
-
|
|
4751
|
-
|
|
4752
|
-
|
|
4753
|
-
/* @__PURE__ */ f.jsxs(
|
|
4754
|
-
|
|
4755
|
-
|
|
4756
|
-
{
|
|
4757
|
-
className: C(
|
|
4758
|
-
ca({ variant: a, error: m }),
|
|
4759
|
-
"rst:left-3"
|
|
4760
|
-
),
|
|
4761
|
-
children: i
|
|
4762
|
-
}
|
|
4763
|
-
),
|
|
4764
|
-
/* @__PURE__ */ f.jsx(
|
|
4765
|
-
Ed,
|
|
4763
|
+
size: o,
|
|
4764
|
+
error: i,
|
|
4765
|
+
startIcon: l,
|
|
4766
|
+
endIcon: c,
|
|
4767
|
+
disabled: u,
|
|
4768
|
+
inputClassName: p,
|
|
4769
|
+
...m
|
|
4770
|
+
}, d) => {
|
|
4771
|
+
const g = !!n || i;
|
|
4772
|
+
return (
|
|
4773
|
+
/* No `space-y-*` here, deliberately. Headless UI's Field appends a
|
|
4774
|
+
hidden zero-height <span> after the control, and Tailwind v4 applies
|
|
4775
|
+
space-y as `margin-block-end` on `:not(:last-child)` — so the input's
|
|
4776
|
+
wrapper stopped being the last child and picked up a stray 6px bottom
|
|
4777
|
+
margin. The Field's box then ended 6px below the control, and any
|
|
4778
|
+
`items-end` row aligned a neighbouring Button to that phantom edge
|
|
4779
|
+
rather than to the field. Measured in Storybook: 6px off at every
|
|
4780
|
+
size, while both were the correct height. Spacing is set explicitly on
|
|
4781
|
+
the label and the description instead. */
|
|
4782
|
+
/* @__PURE__ */ f.jsxs(Qr, { className: C("rst:w-full", t), children: [
|
|
4783
|
+
r && /* @__PURE__ */ f.jsx(
|
|
4784
|
+
De,
|
|
4766
4785
|
{
|
|
4767
|
-
ref: p,
|
|
4768
|
-
type: e,
|
|
4769
|
-
disabled: c,
|
|
4770
4786
|
className: C(
|
|
4771
|
-
|
|
4772
|
-
|
|
4773
|
-
|
|
4787
|
+
"rst:block rst:text-sm rst:font-medium rst:leading-none rst:text-left rst:mb-1.5 rst:transition-colors",
|
|
4788
|
+
"rst:text-gray-900 rst:dark:text-gray-100",
|
|
4789
|
+
"rst:peer-disabled:cursor-not-allowed rst:peer-disabled:opacity-70"
|
|
4774
4790
|
),
|
|
4775
|
-
|
|
4791
|
+
children: r
|
|
4776
4792
|
}
|
|
4777
4793
|
),
|
|
4778
|
-
|
|
4779
|
-
|
|
4794
|
+
/* @__PURE__ */ f.jsxs("div", { className: "rst:relative", children: [
|
|
4795
|
+
l && /* @__PURE__ */ f.jsx(
|
|
4796
|
+
"div",
|
|
4797
|
+
{
|
|
4798
|
+
className: C(
|
|
4799
|
+
ca({ variant: a, error: g }),
|
|
4800
|
+
"rst:left-3"
|
|
4801
|
+
),
|
|
4802
|
+
children: l
|
|
4803
|
+
}
|
|
4804
|
+
),
|
|
4805
|
+
/* @__PURE__ */ f.jsx(
|
|
4806
|
+
Ed,
|
|
4807
|
+
{
|
|
4808
|
+
ref: d,
|
|
4809
|
+
type: e,
|
|
4810
|
+
disabled: u,
|
|
4811
|
+
className: C(
|
|
4812
|
+
n0({ variant: a, size: o, error: g }),
|
|
4813
|
+
/* Icon inset tracks the size's own padding: sm is px-3, so it
|
|
4814
|
+
needs one step less clearance than the 16px sizes. */
|
|
4815
|
+
l && (o === "sm" ? "rst:pl-9" : "rst:pl-10"),
|
|
4816
|
+
c && (o === "sm" ? "rst:pr-9" : "rst:pr-10"),
|
|
4817
|
+
p
|
|
4818
|
+
),
|
|
4819
|
+
...m
|
|
4820
|
+
}
|
|
4821
|
+
),
|
|
4822
|
+
c && /* @__PURE__ */ f.jsx(
|
|
4823
|
+
"div",
|
|
4824
|
+
{
|
|
4825
|
+
className: C(
|
|
4826
|
+
ca({ variant: a, error: g }),
|
|
4827
|
+
"rst:right-3"
|
|
4828
|
+
),
|
|
4829
|
+
children: c
|
|
4830
|
+
}
|
|
4831
|
+
)
|
|
4832
|
+
] }),
|
|
4833
|
+
(s || n) && /* @__PURE__ */ f.jsx(
|
|
4834
|
+
rr,
|
|
4780
4835
|
{
|
|
4781
4836
|
className: C(
|
|
4782
|
-
|
|
4783
|
-
"rst:
|
|
4837
|
+
"rst:text-xs rst:text-left rst:mt-1.5",
|
|
4838
|
+
g ? "rst:text-error-600 rst:dark:text-error-400 rst:font-medium" : "rst:text-gray-500 rst:dark:text-gray-400"
|
|
4784
4839
|
),
|
|
4785
|
-
children:
|
|
4840
|
+
children: n || s
|
|
4786
4841
|
}
|
|
4787
4842
|
)
|
|
4788
|
-
] })
|
|
4789
|
-
|
|
4790
|
-
rr,
|
|
4791
|
-
{
|
|
4792
|
-
className: C(
|
|
4793
|
-
"rst:text-xs rst:text-left rst:mt-1",
|
|
4794
|
-
m ? "rst:text-error-600 rst:dark:text-error-400 rst:font-medium" : "rst:text-gray-500 rst:dark:text-gray-400"
|
|
4795
|
-
),
|
|
4796
|
-
children: n || s
|
|
4797
|
-
}
|
|
4798
|
-
)
|
|
4799
|
-
] });
|
|
4843
|
+
] })
|
|
4844
|
+
);
|
|
4800
4845
|
}
|
|
4801
4846
|
);
|
|
4802
4847
|
ii.displayName = "Input";
|
|
@@ -4894,30 +4939,31 @@ const a0 = Z(
|
|
|
4894
4939
|
variant: i,
|
|
4895
4940
|
error: l,
|
|
4896
4941
|
errorMessage: c,
|
|
4897
|
-
|
|
4898
|
-
|
|
4899
|
-
|
|
4900
|
-
|
|
4901
|
-
|
|
4942
|
+
className: u,
|
|
4943
|
+
...p
|
|
4944
|
+
}, m) => {
|
|
4945
|
+
const [d, g] = S.useState(e), h = r !== void 0, b = h ? r : d, v = () => {
|
|
4946
|
+
const w = !b;
|
|
4947
|
+
h || g(w), s?.(w);
|
|
4902
4948
|
};
|
|
4903
4949
|
return /* @__PURE__ */ f.jsx(
|
|
4904
4950
|
ii,
|
|
4905
4951
|
{
|
|
4906
|
-
ref:
|
|
4907
|
-
type:
|
|
4952
|
+
ref: m,
|
|
4953
|
+
type: b ? "text" : "password",
|
|
4908
4954
|
disabled: o,
|
|
4909
4955
|
variant: i,
|
|
4910
4956
|
error: l,
|
|
4911
4957
|
errorMessage: c,
|
|
4912
|
-
className: C("rst:[&_input::-ms-reveal]:hidden", u
|
|
4958
|
+
className: C("rst:[&_input::-ms-reveal]:hidden", u),
|
|
4913
4959
|
endIcon: t ? /* @__PURE__ */ f.jsx(
|
|
4914
4960
|
"button",
|
|
4915
4961
|
{
|
|
4916
4962
|
type: "button",
|
|
4917
|
-
onClick:
|
|
4963
|
+
onClick: v,
|
|
4918
4964
|
disabled: o,
|
|
4919
|
-
"aria-label":
|
|
4920
|
-
"aria-pressed":
|
|
4965
|
+
"aria-label": b ? a : n,
|
|
4966
|
+
"aria-pressed": b,
|
|
4921
4967
|
className: C(
|
|
4922
4968
|
"rst:-m-1 rst:flex rst:items-center rst:rounded rst:p-1 rst:transition-opacity",
|
|
4923
4969
|
"rst:opacity-70 rst:hover:opacity-100",
|
|
@@ -4927,14 +4973,14 @@ const a0 = Z(
|
|
|
4927
4973
|
children: /* @__PURE__ */ f.jsx(
|
|
4928
4974
|
mt,
|
|
4929
4975
|
{
|
|
4930
|
-
icon:
|
|
4976
|
+
icon: b ? Bi : Hi,
|
|
4931
4977
|
className: "rst:h-4 rst:w-4",
|
|
4932
4978
|
"aria-hidden": "true"
|
|
4933
4979
|
}
|
|
4934
4980
|
)
|
|
4935
4981
|
}
|
|
4936
4982
|
) : void 0,
|
|
4937
|
-
...
|
|
4983
|
+
...p
|
|
4938
4984
|
}
|
|
4939
4985
|
);
|
|
4940
4986
|
}
|
|
@@ -4978,12 +5024,12 @@ const i0 = Z(
|
|
|
4978
5024
|
{ variant: "outline", colorScheme: "info", className: "rst:border-info-300 rst:text-info-700 rst:dark:border-info-700 rst:dark:text-info-300" },
|
|
4979
5025
|
{ variant: "outline", colorScheme: "neutral", className: "rst:border-gray-300 rst:text-gray-700 rst:dark:border-gray-600 rst:dark:text-gray-300" },
|
|
4980
5026
|
// Solid is for when the pill is the loudest thing in its row on purpose.
|
|
4981
|
-
{ variant: "solid", colorScheme: "primary", className: "rst:bg-primary-500 rst:text-
|
|
4982
|
-
{ variant: "solid", colorScheme: "success", className: "rst:bg-success-500 rst:text-
|
|
4983
|
-
{ variant: "solid", colorScheme: "error", className: "rst:bg-error-500 rst:text-
|
|
4984
|
-
{ variant: "solid", colorScheme: "amber", className: "rst:bg-amber-500 rst:text-
|
|
4985
|
-
{ variant: "solid", colorScheme: "info", className: "rst:bg-info-500 rst:text-
|
|
4986
|
-
{ variant: "solid", colorScheme: "neutral", className: "rst:bg-gray-600 rst:text-
|
|
5027
|
+
{ variant: "solid", colorScheme: "primary", className: "rst:bg-primary-500 rst:text-primary-500-ink" },
|
|
5028
|
+
{ variant: "solid", colorScheme: "success", className: "rst:bg-success-500 rst:text-success-500-ink" },
|
|
5029
|
+
{ variant: "solid", colorScheme: "error", className: "rst:bg-error-500 rst:text-error-500-ink" },
|
|
5030
|
+
{ variant: "solid", colorScheme: "amber", className: "rst:bg-amber-500 rst:text-amber-500-ink" },
|
|
5031
|
+
{ variant: "solid", colorScheme: "info", className: "rst:bg-info-500 rst:text-info-500-ink" },
|
|
5032
|
+
{ variant: "solid", colorScheme: "neutral", className: "rst:bg-gray-600 rst:dark:bg-gray-500 rst:text-gray-600-ink rst:dark:text-gray-500-ink" }
|
|
4987
5033
|
],
|
|
4988
5034
|
defaultVariants: {
|
|
4989
5035
|
colorScheme: "neutral",
|
|
@@ -5230,117 +5276,221 @@ const x0 = S.forwardRef(
|
|
|
5230
5276
|
);
|
|
5231
5277
|
x0.displayName = "ThemeToggle";
|
|
5232
5278
|
const y0 = Z(
|
|
5233
|
-
|
|
5279
|
+
/* `h-10 pl-4 pr-10` are floors, not defaults, for the same reason Input's
|
|
5280
|
+
are: `VariantProps` admits `null`, so `size={fieldSize ?? null}`
|
|
5281
|
+
typechecks and would otherwise leave the trigger with no height and its
|
|
5282
|
+
label flush against the ring. `cn()` is tailwind-merge, so a real size
|
|
5283
|
+
still wins.
|
|
5284
|
+
|
|
5285
|
+
Height used to be a side effect of `py-2.5` plus the line box, and the
|
|
5286
|
+
base carried `sm:leading-6` — which made this the only control in the
|
|
5287
|
+
library whose height changed at a breakpoint: 40px on mobile, 44px from
|
|
5288
|
+
`sm` up. It is now an explicit height at every width. */
|
|
5289
|
+
"rst:font-ui rst:relative rst:flex rst:w-full rst:cursor-pointer rst:disabled:cursor-not-allowed rst:disabled:opacity-50 rst:items-center rst:rounded-md rst:h-10 rst:pl-4 rst:pr-10 rst:text-left rst:text-sm rst:font-medium rst:shadow-sm rst:ring-1 rst:ring-inset rst:transition-all rst:focus:outline-hidden rst:focus-visible:ring-2 rst:focus-visible:ring-ring",
|
|
5234
5290
|
{
|
|
5235
5291
|
variants: {
|
|
5236
5292
|
variant: {
|
|
5237
5293
|
white: "rst:bg-white rst:text-gray-900 rst:ring-gray-300 rst:hover:bg-gray-50 rst:dark:bg-gray-800 rst:dark:text-gray-100 rst:dark:ring-gray-700 rst:dark:hover:bg-gray-700",
|
|
5238
5294
|
soft: "rst:bg-gray-100 rst:text-gray-900 rst:ring-transparent rst:hover:bg-gray-200 rst:dark:bg-gray-800 rst:dark:text-gray-100 rst:dark:hover:bg-gray-700",
|
|
5239
5295
|
slate: "rst:bg-gray-700 rst:text-gray-100 rst:ring-transparent rst:hover:bg-gray-600 rst:dark:bg-gray-900 rst:dark:text-gray-100 rst:dark:hover:bg-gray-800",
|
|
5240
|
-
|
|
5296
|
+
/* The default variant, and the only one that reads tokens, exactly as
|
|
5297
|
+
in Input. It takes three of the four: focus on the trigger is the
|
|
5298
|
+
shared ring, not a border color, so `--roster-control-border-focus`
|
|
5299
|
+
has nothing to apply to here.
|
|
5300
|
+
|
|
5301
|
+
No `hover:bg-*`, unlike the other four. A hover fill is a second
|
|
5302
|
+
hardcoded surface painted over the one the consumer just chose:
|
|
5303
|
+
tailwind-merge keeps both (different modifier), so a themed trigger
|
|
5304
|
+
took the host's color at rest and gray-50 on hover. The
|
|
5305
|
+
`ThemedWithTokens` story was the repro — near-white text on gray-50,
|
|
5306
|
+
about 1:1. Input's outline has no hover either, so this is also the
|
|
5307
|
+
parity the size scale is arguing for. */
|
|
5308
|
+
outline: "rst:bg-[var(--roster-control-bg)] rst:text-[var(--roster-control-text)] rst:ring-[color:var(--roster-control-border)]",
|
|
5241
5309
|
ghost: "rst:bg-transparent rst:text-gray-700 rst:ring-transparent rst:hover:bg-gray-100 rst:hover:text-gray-900 rst:dark:text-gray-300 rst:dark:hover:bg-gray-800 rst:dark:hover:text-gray-100"
|
|
5242
5310
|
},
|
|
5311
|
+
/* The same three heights as Button and Input: h-9 / h-10 / h-11. */
|
|
5312
|
+
size: {
|
|
5313
|
+
sm: "rst:h-9 rst:pl-3 rst:pr-9",
|
|
5314
|
+
default: "rst:h-10 rst:pl-4 rst:pr-10",
|
|
5315
|
+
/* Right padding does not grow with `lg`. It is clearance for the
|
|
5316
|
+
chevron, which is a fixed 14px at every size, so widening it would
|
|
5317
|
+
only push the label away from a gap that is already big enough. */
|
|
5318
|
+
lg: "rst:h-11 rst:pl-4 rst:pr-10"
|
|
5319
|
+
},
|
|
5243
5320
|
error: {
|
|
5244
|
-
|
|
5321
|
+
/* `focus-visible:`, not `focus:`. The base sets
|
|
5322
|
+
`focus-visible:ring-ring`; a `focus:` class lands in a different
|
|
5323
|
+
tailwind-merge group, so both survived, and equal specificity meant
|
|
5324
|
+
the later rule in the stylesheet won — an errored Select drew the
|
|
5325
|
+
PRIMARY ring on keyboard focus. Input avoided this by accident of
|
|
5326
|
+
modifier choice. */
|
|
5327
|
+
true: "rst:ring-error-500 rst:text-error-600 rst:focus-visible:ring-error-500 rst:dark:ring-error-500 rst:dark:text-error-400 rst:dark:focus-visible:ring-error-400",
|
|
5245
5328
|
false: ""
|
|
5246
5329
|
}
|
|
5247
5330
|
},
|
|
5248
5331
|
defaultVariants: {
|
|
5249
5332
|
variant: "outline",
|
|
5333
|
+
size: "default",
|
|
5250
5334
|
error: !1
|
|
5251
5335
|
}
|
|
5252
5336
|
}
|
|
5253
|
-
),
|
|
5337
|
+
), w0 = Z(
|
|
5338
|
+
/* Horizontal padding is a floor here, and tracks the trigger's so the label's
|
|
5339
|
+
left edge stays put between the closed trigger and the open menu. (The menu
|
|
5340
|
+
does not open OVER the trigger — it is anchored `bottom start` with a 4px
|
|
5341
|
+
gap — so this is vertical continuity, not overlap.)
|
|
5342
|
+
|
|
5343
|
+
`text-sm` lives here rather than on the popup, and carries no `sm:`. The
|
|
5344
|
+
popup used to set `text-base sm:text-sm`, which made a menu row 44px on
|
|
5345
|
+
mobile and 40px from `sm` up: the exact breakpoint-dependent geometry this
|
|
5346
|
+
change removed from the trigger, still alive one element away. */
|
|
5347
|
+
"rst:text-sm rst:group rst:relative rst:cursor-default rst:select-none rst:py-2.5 rst:pl-4 rst:pr-9 rst:transition-colors rst:text-gray-900 rst:dark:text-gray-100 rst:data-focus:bg-primary-100 rst:data-focus:text-primary-900 rst:dark:data-focus:bg-primary-900/30 rst:dark:data-focus:text-primary-100 rst:data-selected:bg-gray-50 rst:dark:data-selected:bg-gray-700/50 rst:data-disabled:opacity-50 rst:data-disabled:cursor-not-allowed",
|
|
5348
|
+
{
|
|
5349
|
+
variants: {
|
|
5350
|
+
size: {
|
|
5351
|
+
sm: "rst:py-2 rst:pl-3 rst:pr-8",
|
|
5352
|
+
default: "rst:py-2.5 rst:pl-4 rst:pr-9",
|
|
5353
|
+
/* `lg` matches `default` on purpose: trigger height is an alignment
|
|
5354
|
+
contract with a neighbouring Button, while menu row height is a
|
|
5355
|
+
scan-density choice with nothing to align to. Density does not have
|
|
5356
|
+
to follow alignment. */
|
|
5357
|
+
lg: "rst:py-2.5 rst:pl-4 rst:pr-9"
|
|
5358
|
+
}
|
|
5359
|
+
},
|
|
5360
|
+
defaultVariants: {
|
|
5361
|
+
size: "default"
|
|
5362
|
+
}
|
|
5363
|
+
}
|
|
5364
|
+
), _m = ({
|
|
5254
5365
|
options: t,
|
|
5255
5366
|
value: e,
|
|
5256
5367
|
onChange: r,
|
|
5257
5368
|
placeholder: s = "Select an option",
|
|
5258
5369
|
disabled: n = !1,
|
|
5259
5370
|
variant: a,
|
|
5260
|
-
|
|
5261
|
-
|
|
5262
|
-
|
|
5371
|
+
size: o,
|
|
5372
|
+
error: i,
|
|
5373
|
+
className: l,
|
|
5374
|
+
triggerClassName: c,
|
|
5375
|
+
label: u,
|
|
5376
|
+
...p
|
|
5263
5377
|
}) => {
|
|
5264
|
-
const
|
|
5265
|
-
return
|
|
5266
|
-
|
|
5267
|
-
|
|
5268
|
-
|
|
5269
|
-
|
|
5270
|
-
|
|
5271
|
-
|
|
5272
|
-
|
|
5273
|
-
|
|
5274
|
-
|
|
5275
|
-
|
|
5276
|
-
|
|
5277
|
-
|
|
5278
|
-
|
|
5279
|
-
|
|
5280
|
-
|
|
5281
|
-
|
|
5282
|
-
|
|
5283
|
-
|
|
5284
|
-
|
|
5285
|
-
|
|
5286
|
-
|
|
5287
|
-
|
|
5288
|
-
|
|
5289
|
-
|
|
5290
|
-
|
|
5291
|
-
|
|
5292
|
-
|
|
5293
|
-
className: "rst:h-3.5 rst:w-3.5 rst:text-gray-400 rst:dark:text-gray-500",
|
|
5294
|
-
"aria-hidden": "true"
|
|
5295
|
-
}
|
|
5296
|
-
) })
|
|
5297
|
-
]
|
|
5298
|
-
}
|
|
5299
|
-
),
|
|
5300
|
-
/* @__PURE__ */ f.jsx(
|
|
5301
|
-
je,
|
|
5302
|
-
{
|
|
5303
|
-
as: xt,
|
|
5304
|
-
leave: "rst:transition rst:ease-in rst:duration-100",
|
|
5305
|
-
leaveFrom: "rst:opacity-100",
|
|
5306
|
-
leaveTo: "rst:opacity-0",
|
|
5307
|
-
children: /* @__PURE__ */ f.jsx(
|
|
5308
|
-
Xo,
|
|
5378
|
+
const m = t.find((b) => b.value === e), d = S.useRef(null), [g, h] = S.useState(!1);
|
|
5379
|
+
return S.useLayoutEffect(() => {
|
|
5380
|
+
h(!!d.current?.closest(".dark"));
|
|
5381
|
+
}, []), /* `...props` is spread here, and was not before. The prop type has always
|
|
5382
|
+
extended `HTMLAttributes<HTMLDivElement>`, so `id`, `data-*` and the
|
|
5383
|
+
handlers all typechecked and were then silently dropped on the floor.
|
|
5384
|
+
|
|
5385
|
+
Deliberately NOT claimed: `aria-*`. This is a plain wrapper div with no
|
|
5386
|
+
role, so an `aria-describedby` landing here is inert, and Headless UI
|
|
5387
|
+
wires the trigger's description from the Field's <Description> context
|
|
5388
|
+
rather than from the wrapper's attributes. Select has no `helperText` /
|
|
5389
|
+
`errorMessage` yet, so there is currently no supported way to describe
|
|
5390
|
+
the trigger at all — filed, not fixed here. */
|
|
5391
|
+
/* @__PURE__ */ f.jsxs(
|
|
5392
|
+
Qr,
|
|
5393
|
+
{
|
|
5394
|
+
className: C("rst:flex rst:flex-col rst:gap-1.5", l),
|
|
5395
|
+
...p,
|
|
5396
|
+
children: [
|
|
5397
|
+
u && /* @__PURE__ */ f.jsx(De, { className: "rst:block rst:text-sm rst:font-medium rst:text-inherit rst:text-left", children: u }),
|
|
5398
|
+
/* @__PURE__ */ f.jsx(
|
|
5399
|
+
Wd,
|
|
5400
|
+
{
|
|
5401
|
+
value: e ?? void 0,
|
|
5402
|
+
onChange: r,
|
|
5403
|
+
disabled: n,
|
|
5404
|
+
children: /* @__PURE__ */ f.jsxs("div", { ref: d, className: "rst:relative", children: [
|
|
5405
|
+
/* @__PURE__ */ f.jsxs(
|
|
5406
|
+
qo,
|
|
5309
5407
|
{
|
|
5310
|
-
anchor: "bottom start",
|
|
5311
5408
|
className: C(
|
|
5312
|
-
|
|
5313
|
-
|
|
5409
|
+
y0({ variant: a, size: o, error: i }),
|
|
5410
|
+
c
|
|
5314
5411
|
),
|
|
5315
|
-
children:
|
|
5316
|
-
|
|
5412
|
+
children: [
|
|
5413
|
+
/* @__PURE__ */ f.jsx(
|
|
5414
|
+
"span",
|
|
5415
|
+
{
|
|
5416
|
+
className: C(
|
|
5417
|
+
"rst:block rst:truncate",
|
|
5418
|
+
!m && "rst:text-gray-500 rst:dark:text-gray-400"
|
|
5419
|
+
),
|
|
5420
|
+
children: m ? m.label : s
|
|
5421
|
+
}
|
|
5422
|
+
),
|
|
5423
|
+
/* @__PURE__ */ f.jsx(
|
|
5424
|
+
"span",
|
|
5425
|
+
{
|
|
5426
|
+
className: C(
|
|
5427
|
+
"rst:pointer-events-none rst:absolute rst:inset-y-0 rst:right-0 rst:flex rst:items-center",
|
|
5428
|
+
/* Clearance tracks the size's own right padding, the way
|
|
5429
|
+
Input's icon inset tracks its horizontal padding. */
|
|
5430
|
+
o === "sm" ? "rst:pr-2.5" : "rst:pr-3"
|
|
5431
|
+
),
|
|
5432
|
+
children: /* @__PURE__ */ f.jsx(
|
|
5433
|
+
mt,
|
|
5434
|
+
{
|
|
5435
|
+
icon: Oa,
|
|
5436
|
+
className: "rst:h-3.5 rst:w-3.5 rst:text-gray-400 rst:dark:text-gray-500",
|
|
5437
|
+
"aria-hidden": "true"
|
|
5438
|
+
}
|
|
5439
|
+
)
|
|
5440
|
+
}
|
|
5441
|
+
)
|
|
5442
|
+
]
|
|
5443
|
+
}
|
|
5444
|
+
),
|
|
5445
|
+
/* @__PURE__ */ f.jsx(
|
|
5446
|
+
je,
|
|
5447
|
+
{
|
|
5448
|
+
as: xt,
|
|
5449
|
+
leave: "rst:transition rst:ease-in rst:duration-100",
|
|
5450
|
+
leaveFrom: "rst:opacity-100",
|
|
5451
|
+
leaveTo: "rst:opacity-0",
|
|
5452
|
+
children: /* @__PURE__ */ f.jsx(
|
|
5453
|
+
Xo,
|
|
5317
5454
|
{
|
|
5318
|
-
|
|
5319
|
-
disabled: u.disabled,
|
|
5455
|
+
anchor: "bottom start",
|
|
5320
5456
|
className: C(
|
|
5321
|
-
|
|
5322
|
-
"rst:
|
|
5323
|
-
"rst:
|
|
5324
|
-
"rst:dark:data-focus:bg-primary-900/30 rst:dark:data-focus:text-primary-100",
|
|
5325
|
-
"rst:data-selected:bg-gray-50 rst:dark:data-selected:bg-gray-700/50",
|
|
5326
|
-
"rst:data-disabled:opacity-50 rst:data-disabled:cursor-not-allowed"
|
|
5457
|
+
g && "dark",
|
|
5458
|
+
"rst:w-(--button-width) rst:z-50 rst:rounded-md rst:bg-white rst:dark:bg-gray-800 rst:py-1 rst:shadow-lg rst:ring-1 rst:ring-black/5 rst:dark:ring-gray-700 rst:focus:outline-hidden",
|
|
5459
|
+
"rst:[--anchor-gap:4px]"
|
|
5327
5460
|
),
|
|
5328
|
-
children:
|
|
5329
|
-
|
|
5330
|
-
|
|
5331
|
-
|
|
5332
|
-
|
|
5333
|
-
|
|
5334
|
-
|
|
5461
|
+
children: t.map((b) => /* @__PURE__ */ f.jsxs(
|
|
5462
|
+
Qo,
|
|
5463
|
+
{
|
|
5464
|
+
value: b.value,
|
|
5465
|
+
disabled: b.disabled,
|
|
5466
|
+
className: C(w0({ size: o })),
|
|
5467
|
+
children: [
|
|
5468
|
+
/* @__PURE__ */ f.jsx("span", { className: "rst:block rst:truncate rst:font-normal rst:group-data-selected:font-semibold", children: b.label }),
|
|
5469
|
+
/* @__PURE__ */ f.jsx(
|
|
5470
|
+
"span",
|
|
5471
|
+
{
|
|
5472
|
+
className: C(
|
|
5473
|
+
"rst:absolute rst:inset-y-0 rst:right-0 rst:hidden rst:items-center rst:text-primary-600 rst:dark:text-primary-400 rst:group-data-selected:flex",
|
|
5474
|
+
o === "sm" ? "rst:pr-3" : "rst:pr-4"
|
|
5475
|
+
),
|
|
5476
|
+
children: /* @__PURE__ */ f.jsx(mt, { icon: Na, className: "rst:h-3.5 rst:w-3.5" })
|
|
5477
|
+
}
|
|
5478
|
+
)
|
|
5479
|
+
]
|
|
5480
|
+
},
|
|
5481
|
+
b.value
|
|
5482
|
+
))
|
|
5483
|
+
}
|
|
5484
|
+
)
|
|
5335
5485
|
}
|
|
5336
5486
|
)
|
|
5337
|
-
}
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5341
|
-
|
|
5342
|
-
|
|
5343
|
-
},
|
|
5487
|
+
] })
|
|
5488
|
+
}
|
|
5489
|
+
)
|
|
5490
|
+
]
|
|
5491
|
+
}
|
|
5492
|
+
);
|
|
5493
|
+
}, k0 = Z(
|
|
5344
5494
|
"rst:font-ui rst:group rst:relative rst:inline-flex rst:shrink-0 rst:cursor-pointer rst:rounded-full rst:border-2 rst:border-transparent rst:transition-colors rst:duration-200 rst:ease-in-out rst:focus:outline-hidden rst:focus-visible:ring-2 rst:focus-visible:ring-offset-2 rst:ring-offset-background rst:disabled:cursor-not-allowed rst:disabled:opacity-50",
|
|
5345
5495
|
{
|
|
5346
5496
|
variants: {
|
|
@@ -5362,7 +5512,7 @@ const y0 = Z(
|
|
|
5362
5512
|
size: "md"
|
|
5363
5513
|
}
|
|
5364
5514
|
}
|
|
5365
|
-
),
|
|
5515
|
+
), S0 = Z(
|
|
5366
5516
|
"rst:pointer-events-none rst:inline-block rst:rounded-full rst:bg-white rst:shadow rst:ring-0 rst:transition rst:duration-200 rst:ease-in-out rst:transform",
|
|
5367
5517
|
{
|
|
5368
5518
|
variants: {
|
|
@@ -5425,12 +5575,12 @@ const y0 = Z(
|
|
|
5425
5575
|
onChange: e,
|
|
5426
5576
|
disabled: n,
|
|
5427
5577
|
"aria-label": c,
|
|
5428
|
-
className: C(
|
|
5578
|
+
className: C(k0({ variant: o, size: a })),
|
|
5429
5579
|
children: /* @__PURE__ */ f.jsx(
|
|
5430
5580
|
"span",
|
|
5431
5581
|
{
|
|
5432
5582
|
"aria-hidden": "true",
|
|
5433
|
-
className: C(
|
|
5583
|
+
className: C(S0({ size: a }))
|
|
5434
5584
|
}
|
|
5435
5585
|
)
|
|
5436
5586
|
}
|
|
@@ -5438,7 +5588,7 @@ const y0 = Z(
|
|
|
5438
5588
|
]
|
|
5439
5589
|
}
|
|
5440
5590
|
);
|
|
5441
|
-
},
|
|
5591
|
+
}, E0 = Z(
|
|
5442
5592
|
"rst:font-ui rst:flex rst:w-full rst:min-h-[80px] rst:rounded-md rst:border rst:py-2.5 rst:px-4 rst:text-sm rst:ring-offset-background rst:focus-visible:ring-offset-2 rst:placeholder:text-gray-400 rst:focus-visible:outline-hidden rst:focus-visible:ring-2 rst:focus-visible:ring-ring rst:disabled:cursor-not-allowed rst:disabled:opacity-50 rst:transition-colors rst:custom-scrollbar",
|
|
5443
5593
|
{
|
|
5444
5594
|
variants: {
|
|
@@ -5465,7 +5615,7 @@ const y0 = Z(
|
|
|
5465
5615
|
resize: "vertical"
|
|
5466
5616
|
}
|
|
5467
5617
|
}
|
|
5468
|
-
),
|
|
5618
|
+
), N0 = S.forwardRef(
|
|
5469
5619
|
({
|
|
5470
5620
|
className: t,
|
|
5471
5621
|
label: e,
|
|
@@ -5475,35 +5625,49 @@ const y0 = Z(
|
|
|
5475
5625
|
error: a,
|
|
5476
5626
|
resize: o,
|
|
5477
5627
|
disabled: i,
|
|
5478
|
-
|
|
5479
|
-
|
|
5480
|
-
|
|
5481
|
-
|
|
5482
|
-
|
|
5483
|
-
/*
|
|
5484
|
-
|
|
5485
|
-
|
|
5486
|
-
|
|
5487
|
-
|
|
5488
|
-
|
|
5489
|
-
|
|
5490
|
-
|
|
5491
|
-
),
|
|
5492
|
-
|
|
5493
|
-
|
|
5494
|
-
|
|
5495
|
-
|
|
5496
|
-
|
|
5497
|
-
|
|
5498
|
-
|
|
5499
|
-
|
|
5500
|
-
|
|
5501
|
-
|
|
5502
|
-
|
|
5628
|
+
textareaClassName: l,
|
|
5629
|
+
...c
|
|
5630
|
+
}, u) => {
|
|
5631
|
+
const p = !!s || a;
|
|
5632
|
+
return (
|
|
5633
|
+
/* No `space-y-*` here, for the reason documented on Input: Headless UI's
|
|
5634
|
+
Field always renders a trailing hidden element, and Tailwind v4
|
|
5635
|
+
applies space-y as `margin-block-end` on `:not(:last-child)`, so the
|
|
5636
|
+
control stopped being the last child and picked up a stray 6px bottom
|
|
5637
|
+
margin against a sibling nobody can see. Spacing is set explicitly on
|
|
5638
|
+
the label and description instead. Select is immune to the same trap
|
|
5639
|
+
only because it spaces with `gap`, and the hidden element is
|
|
5640
|
+
`display: none` so it is not a flex item. */
|
|
5641
|
+
/* @__PURE__ */ f.jsxs(Qr, { className: C("rst:w-full", t), children: [
|
|
5642
|
+
e && /* @__PURE__ */ f.jsx(De, { className: "rst:block rst:text-sm rst:font-medium rst:leading-none rst:text-gray-900 rst:dark:text-gray-100 rst:peer-disabled:cursor-not-allowed rst:peer-disabled:opacity-70 rst:text-left rst:mb-1.5", children: e }),
|
|
5643
|
+
/* @__PURE__ */ f.jsx(
|
|
5644
|
+
Kf,
|
|
5645
|
+
{
|
|
5646
|
+
ref: u,
|
|
5647
|
+
disabled: i,
|
|
5648
|
+
className: C(
|
|
5649
|
+
E0({ variant: n, resize: o, error: p }),
|
|
5650
|
+
l
|
|
5651
|
+
),
|
|
5652
|
+
...c
|
|
5653
|
+
}
|
|
5654
|
+
),
|
|
5655
|
+
(r || s) && /* @__PURE__ */ f.jsx(
|
|
5656
|
+
rr,
|
|
5657
|
+
{
|
|
5658
|
+
className: C(
|
|
5659
|
+
"rst:text-xs rst:text-left rst:mt-1.5",
|
|
5660
|
+
p ? "rst:text-error-600 rst:dark:text-error-400 rst:font-medium" : "rst:text-gray-500 rst:dark:text-gray-400"
|
|
5661
|
+
),
|
|
5662
|
+
children: s || r
|
|
5663
|
+
}
|
|
5664
|
+
)
|
|
5665
|
+
] })
|
|
5666
|
+
);
|
|
5503
5667
|
}
|
|
5504
5668
|
);
|
|
5505
|
-
|
|
5506
|
-
function
|
|
5669
|
+
N0.displayName = "Textarea";
|
|
5670
|
+
function Vm({
|
|
5507
5671
|
items: t,
|
|
5508
5672
|
maxDisplay: e = 5,
|
|
5509
5673
|
totalCount: r,
|
|
@@ -5596,7 +5760,7 @@ function _m({
|
|
|
5596
5760
|
}
|
|
5597
5761
|
);
|
|
5598
5762
|
}
|
|
5599
|
-
function
|
|
5763
|
+
function Bm({
|
|
5600
5764
|
tabs: t,
|
|
5601
5765
|
activeTab: e,
|
|
5602
5766
|
onChange: r,
|
|
@@ -5767,9 +5931,9 @@ function ci(t, e = []) {
|
|
|
5767
5931
|
);
|
|
5768
5932
|
};
|
|
5769
5933
|
};
|
|
5770
|
-
return n.scopeName = t, [s,
|
|
5934
|
+
return n.scopeName = t, [s, O0(n, ...e)];
|
|
5771
5935
|
}
|
|
5772
|
-
function
|
|
5936
|
+
function O0(...t) {
|
|
5773
5937
|
const e = t[0];
|
|
5774
5938
|
if (t.length === 1) return e;
|
|
5775
5939
|
const r = () => {
|
|
@@ -5789,8 +5953,8 @@ function N0(...t) {
|
|
|
5789
5953
|
}
|
|
5790
5954
|
// @__NO_SIDE_EFFECTS__
|
|
5791
5955
|
function P0(t) {
|
|
5792
|
-
const e = /* @__PURE__ */
|
|
5793
|
-
const { children: a, ...o } = s, i = y.Children.toArray(a), l = i.find(
|
|
5956
|
+
const e = /* @__PURE__ */ C0(t), r = y.forwardRef((s, n) => {
|
|
5957
|
+
const { children: a, ...o } = s, i = y.Children.toArray(a), l = i.find(j0);
|
|
5794
5958
|
if (l) {
|
|
5795
5959
|
const c = l.props.children, u = i.map((p) => p === l ? y.Children.count(c) > 1 ? y.Children.only(null) : y.isValidElement(c) ? c.props.children : null : p);
|
|
5796
5960
|
return /* @__PURE__ */ f.jsx(e, { ...o, ref: n, children: y.isValidElement(c) ? y.cloneElement(c, void 0, u) : null });
|
|
@@ -5800,11 +5964,11 @@ function P0(t) {
|
|
|
5800
5964
|
return r.displayName = `${t}.Slot`, r;
|
|
5801
5965
|
}
|
|
5802
5966
|
// @__NO_SIDE_EFFECTS__
|
|
5803
|
-
function
|
|
5967
|
+
function C0(t) {
|
|
5804
5968
|
const e = y.forwardRef((r, s) => {
|
|
5805
5969
|
const { children: n, ...a } = r;
|
|
5806
5970
|
if (y.isValidElement(n)) {
|
|
5807
|
-
const o =
|
|
5971
|
+
const o = $0(n), i = R0(a, n.props);
|
|
5808
5972
|
return n.type !== y.Fragment && (i.ref = s ? li(s, o) : o), y.cloneElement(n, i);
|
|
5809
5973
|
}
|
|
5810
5974
|
return y.Children.count(n) > 1 ? y.Children.only(null) : null;
|
|
@@ -5813,14 +5977,14 @@ function O0(t) {
|
|
|
5813
5977
|
}
|
|
5814
5978
|
var ui = /* @__PURE__ */ Symbol("radix.slottable");
|
|
5815
5979
|
// @__NO_SIDE_EFFECTS__
|
|
5816
|
-
function
|
|
5980
|
+
function T0(t) {
|
|
5817
5981
|
const e = ({ children: r }) => /* @__PURE__ */ f.jsx(f.Fragment, { children: r });
|
|
5818
5982
|
return e.displayName = `${t}.Slottable`, e.__radixId = ui, e;
|
|
5819
5983
|
}
|
|
5820
|
-
function
|
|
5984
|
+
function j0(t) {
|
|
5821
5985
|
return y.isValidElement(t) && typeof t.type == "function" && "__radixId" in t.type && t.type.__radixId === ui;
|
|
5822
5986
|
}
|
|
5823
|
-
function
|
|
5987
|
+
function R0(t, e) {
|
|
5824
5988
|
const r = { ...e };
|
|
5825
5989
|
for (const s in e) {
|
|
5826
5990
|
const n = t[s], a = e[s];
|
|
@@ -5831,11 +5995,11 @@ function j0(t, e) {
|
|
|
5831
5995
|
}
|
|
5832
5996
|
return { ...t, ...r };
|
|
5833
5997
|
}
|
|
5834
|
-
function
|
|
5998
|
+
function $0(t) {
|
|
5835
5999
|
let e = Object.getOwnPropertyDescriptor(t.props, "ref")?.get, r = e && "isReactWarning" in e && e.isReactWarning;
|
|
5836
6000
|
return r ? t.ref : (e = Object.getOwnPropertyDescriptor(t, "ref")?.get, r = e && "isReactWarning" in e && e.isReactWarning, r ? t.props.ref : t.props.ref || t.ref);
|
|
5837
6001
|
}
|
|
5838
|
-
var
|
|
6002
|
+
var I0 = [
|
|
5839
6003
|
"a",
|
|
5840
6004
|
"button",
|
|
5841
6005
|
"div",
|
|
@@ -5853,14 +6017,14 @@ var $0 = [
|
|
|
5853
6017
|
"span",
|
|
5854
6018
|
"svg",
|
|
5855
6019
|
"ul"
|
|
5856
|
-
], le =
|
|
6020
|
+
], le = I0.reduce((t, e) => {
|
|
5857
6021
|
const r = /* @__PURE__ */ P0(`Primitive.${e}`), s = y.forwardRef((n, a) => {
|
|
5858
6022
|
const { asChild: o, ...i } = n, l = o ? r : e;
|
|
5859
6023
|
return typeof window < "u" && (window[/* @__PURE__ */ Symbol.for("radix-ui")] = !0), /* @__PURE__ */ f.jsx(l, { ...i, ref: a });
|
|
5860
6024
|
});
|
|
5861
6025
|
return s.displayName = `Primitive.${e}`, { ...t, [e]: s };
|
|
5862
6026
|
}, {});
|
|
5863
|
-
function
|
|
6027
|
+
function A0(t, e) {
|
|
5864
6028
|
t && Ke.flushSync(() => t.dispatchEvent(e));
|
|
5865
6029
|
}
|
|
5866
6030
|
function es(t) {
|
|
@@ -5869,7 +6033,7 @@ function es(t) {
|
|
|
5869
6033
|
e.current = t;
|
|
5870
6034
|
}), y.useMemo(() => (...r) => e.current?.(...r), []);
|
|
5871
6035
|
}
|
|
5872
|
-
function
|
|
6036
|
+
function D0(t, e = globalThis?.document) {
|
|
5873
6037
|
const r = es(t);
|
|
5874
6038
|
y.useEffect(() => {
|
|
5875
6039
|
const s = (n) => {
|
|
@@ -5878,7 +6042,7 @@ function A0(t, e = globalThis?.document) {
|
|
|
5878
6042
|
return e.addEventListener("keydown", s, { capture: !0 }), () => e.removeEventListener("keydown", s, { capture: !0 });
|
|
5879
6043
|
}, [r, e]);
|
|
5880
6044
|
}
|
|
5881
|
-
var
|
|
6045
|
+
var F0 = "DismissableLayer", Es = "dismissableLayer.update", M0 = "dismissableLayer.pointerDownOutside", L0 = "dismissableLayer.focusOutside", pa, di = y.createContext({
|
|
5882
6046
|
layers: /* @__PURE__ */ new Set(),
|
|
5883
6047
|
layersWithOutsidePointerEventsDisabled: /* @__PURE__ */ new Set(),
|
|
5884
6048
|
branches: /* @__PURE__ */ new Set()
|
|
@@ -5892,15 +6056,15 @@ var D0 = "DismissableLayer", Es = "dismissableLayer.update", F0 = "dismissableLa
|
|
|
5892
6056
|
onInteractOutside: o,
|
|
5893
6057
|
onDismiss: i,
|
|
5894
6058
|
...l
|
|
5895
|
-
} = t, c = y.useContext(di), [u, p] = y.useState(null), m = u?.ownerDocument ?? globalThis?.document, [, d] = y.useState({}), g = ke(e, (
|
|
5896
|
-
const M =
|
|
5897
|
-
!k || z || (n?.(
|
|
5898
|
-
}, m), T =
|
|
5899
|
-
const M =
|
|
5900
|
-
[...c.branches].some((N) => N.contains(M)) || (a?.(
|
|
6059
|
+
} = t, c = y.useContext(di), [u, p] = y.useState(null), m = u?.ownerDocument ?? globalThis?.document, [, d] = y.useState({}), g = ke(e, (O) => p(O)), h = Array.from(c.layers), [b] = [...c.layersWithOutsidePointerEventsDisabled].slice(-1), v = h.indexOf(b), w = u ? h.indexOf(u) : -1, x = c.layersWithOutsidePointerEventsDisabled.size > 0, k = w >= v, E = B0((O) => {
|
|
6060
|
+
const M = O.target, z = [...c.branches].some((N) => N.contains(M));
|
|
6061
|
+
!k || z || (n?.(O), o?.(O), O.defaultPrevented || i?.());
|
|
6062
|
+
}, m), T = H0((O) => {
|
|
6063
|
+
const M = O.target;
|
|
6064
|
+
[...c.branches].some((N) => N.contains(M)) || (a?.(O), o?.(O), O.defaultPrevented || i?.());
|
|
5901
6065
|
}, m);
|
|
5902
|
-
return
|
|
5903
|
-
w === c.layers.size - 1 && (s?.(
|
|
6066
|
+
return D0((O) => {
|
|
6067
|
+
w === c.layers.size - 1 && (s?.(O), !O.defaultPrevented && i && (O.preventDefault(), i()));
|
|
5904
6068
|
}, m), y.useEffect(() => {
|
|
5905
6069
|
if (u)
|
|
5906
6070
|
return r && (c.layersWithOutsidePointerEventsDisabled.size === 0 && (pa = m.body.style.pointerEvents, m.body.style.pointerEvents = "none"), c.layersWithOutsidePointerEventsDisabled.add(u)), c.layers.add(u), ma(), () => {
|
|
@@ -5909,8 +6073,8 @@ var D0 = "DismissableLayer", Es = "dismissableLayer.update", F0 = "dismissableLa
|
|
|
5909
6073
|
}, [u, m, r, c]), y.useEffect(() => () => {
|
|
5910
6074
|
u && (c.layers.delete(u), c.layersWithOutsidePointerEventsDisabled.delete(u), ma());
|
|
5911
6075
|
}, [u, c]), y.useEffect(() => {
|
|
5912
|
-
const
|
|
5913
|
-
return document.addEventListener(Es,
|
|
6076
|
+
const O = () => d({});
|
|
6077
|
+
return document.addEventListener(Es, O), () => document.removeEventListener(Es, O);
|
|
5914
6078
|
}, []), /* @__PURE__ */ f.jsx(
|
|
5915
6079
|
le.div,
|
|
5916
6080
|
{
|
|
@@ -5930,8 +6094,8 @@ var D0 = "DismissableLayer", Es = "dismissableLayer.update", F0 = "dismissableLa
|
|
|
5930
6094
|
);
|
|
5931
6095
|
}
|
|
5932
6096
|
);
|
|
5933
|
-
fi.displayName =
|
|
5934
|
-
var
|
|
6097
|
+
fi.displayName = F0;
|
|
6098
|
+
var _0 = "DismissableLayerBranch", V0 = y.forwardRef((t, e) => {
|
|
5935
6099
|
const r = y.useContext(di), s = y.useRef(null), n = ke(e, s);
|
|
5936
6100
|
return y.useEffect(() => {
|
|
5937
6101
|
const a = s.current;
|
|
@@ -5941,8 +6105,8 @@ var L0 = "DismissableLayerBranch", _0 = y.forwardRef((t, e) => {
|
|
|
5941
6105
|
};
|
|
5942
6106
|
}, [r.branches]), /* @__PURE__ */ f.jsx(le.div, { ...t, ref: n });
|
|
5943
6107
|
});
|
|
5944
|
-
|
|
5945
|
-
function
|
|
6108
|
+
V0.displayName = _0;
|
|
6109
|
+
function B0(t, e = globalThis?.document) {
|
|
5946
6110
|
const r = es(t), s = y.useRef(!1), n = y.useRef(() => {
|
|
5947
6111
|
});
|
|
5948
6112
|
return y.useEffect(() => {
|
|
@@ -5950,7 +6114,7 @@ function V0(t, e = globalThis?.document) {
|
|
|
5950
6114
|
if (i.target && !s.current) {
|
|
5951
6115
|
let l = function() {
|
|
5952
6116
|
pi(
|
|
5953
|
-
|
|
6117
|
+
M0,
|
|
5954
6118
|
r,
|
|
5955
6119
|
c,
|
|
5956
6120
|
{ discrete: !0 }
|
|
@@ -5972,11 +6136,11 @@ function V0(t, e = globalThis?.document) {
|
|
|
5972
6136
|
onPointerDownCapture: () => s.current = !0
|
|
5973
6137
|
};
|
|
5974
6138
|
}
|
|
5975
|
-
function
|
|
6139
|
+
function H0(t, e = globalThis?.document) {
|
|
5976
6140
|
const r = es(t), s = y.useRef(!1);
|
|
5977
6141
|
return y.useEffect(() => {
|
|
5978
6142
|
const n = (a) => {
|
|
5979
|
-
a.target && !s.current && pi(
|
|
6143
|
+
a.target && !s.current && pi(L0, r, { originalEvent: a }, {
|
|
5980
6144
|
discrete: !1
|
|
5981
6145
|
});
|
|
5982
6146
|
};
|
|
@@ -5992,18 +6156,18 @@ function ma() {
|
|
|
5992
6156
|
}
|
|
5993
6157
|
function pi(t, e, r, { discrete: s }) {
|
|
5994
6158
|
const n = r.originalEvent.target, a = new CustomEvent(t, { bubbles: !1, cancelable: !0, detail: r });
|
|
5995
|
-
e && n.addEventListener(t, e, { once: !0 }), s ?
|
|
6159
|
+
e && n.addEventListener(t, e, { once: !0 }), s ? A0(n, a) : n.dispatchEvent(a);
|
|
5996
6160
|
}
|
|
5997
6161
|
var ae = globalThis?.document ? y.useLayoutEffect : () => {
|
|
5998
|
-
},
|
|
5999
|
-
}),
|
|
6000
|
-
function
|
|
6001
|
-
const [e, r] = y.useState(
|
|
6162
|
+
}, z0 = y[" useId ".trim().toString()] || (() => {
|
|
6163
|
+
}), W0 = 0;
|
|
6164
|
+
function U0(t) {
|
|
6165
|
+
const [e, r] = y.useState(z0());
|
|
6002
6166
|
return ae(() => {
|
|
6003
|
-
r((s) => s ?? String(
|
|
6167
|
+
r((s) => s ?? String(W0++));
|
|
6004
6168
|
}, [t]), e ? `radix-${e}` : "";
|
|
6005
6169
|
}
|
|
6006
|
-
var
|
|
6170
|
+
var Y0 = "Arrow", mi = y.forwardRef((t, e) => {
|
|
6007
6171
|
const { children: r, width: s = 10, height: n = 5, ...a } = t;
|
|
6008
6172
|
return /* @__PURE__ */ f.jsx(
|
|
6009
6173
|
le.svg,
|
|
@@ -6018,9 +6182,9 @@ var U0 = "Arrow", mi = y.forwardRef((t, e) => {
|
|
|
6018
6182
|
}
|
|
6019
6183
|
);
|
|
6020
6184
|
});
|
|
6021
|
-
mi.displayName =
|
|
6022
|
-
var
|
|
6023
|
-
function
|
|
6185
|
+
mi.displayName = Y0;
|
|
6186
|
+
var G0 = mi;
|
|
6187
|
+
function K0(t) {
|
|
6024
6188
|
const [e, r] = y.useState(void 0);
|
|
6025
6189
|
return ae(() => {
|
|
6026
6190
|
if (t) {
|
|
@@ -6042,9 +6206,9 @@ function G0(t) {
|
|
|
6042
6206
|
r(void 0);
|
|
6043
6207
|
}, [t]), e;
|
|
6044
6208
|
}
|
|
6045
|
-
var pn = "Popper", [gi, hi] = ci(pn), [
|
|
6209
|
+
var pn = "Popper", [gi, hi] = ci(pn), [q0, bi] = gi(pn), vi = (t) => {
|
|
6046
6210
|
const { __scopePopper: e, children: r } = t, [s, n] = y.useState(null);
|
|
6047
|
-
return /* @__PURE__ */ f.jsx(
|
|
6211
|
+
return /* @__PURE__ */ f.jsx(q0, { scope: e, anchor: s, onAnchorChange: n, children: r });
|
|
6048
6212
|
};
|
|
6049
6213
|
vi.displayName = pn;
|
|
6050
6214
|
var xi = "PopperAnchor", yi = y.forwardRef(
|
|
@@ -6057,7 +6221,7 @@ var xi = "PopperAnchor", yi = y.forwardRef(
|
|
|
6057
6221
|
}
|
|
6058
6222
|
);
|
|
6059
6223
|
yi.displayName = xi;
|
|
6060
|
-
var mn = "PopperContent", [
|
|
6224
|
+
var mn = "PopperContent", [X0, Q0] = gi(mn), wi = y.forwardRef(
|
|
6061
6225
|
(t, e) => {
|
|
6062
6226
|
const {
|
|
6063
6227
|
__scopePopper: r,
|
|
@@ -6074,12 +6238,12 @@ var mn = "PopperContent", [q0, X0] = gi(mn), wi = y.forwardRef(
|
|
|
6074
6238
|
updatePositionStrategy: d = "optimized",
|
|
6075
6239
|
onPlaced: g,
|
|
6076
6240
|
...h
|
|
6077
|
-
} = t, b = bi(mn, r), [v, w] = y.useState(null), x = ke(e, (q) => w(q)), [k, E] = y.useState(null), T =
|
|
6241
|
+
} = t, b = bi(mn, r), [v, w] = y.useState(null), x = ke(e, (q) => w(q)), [k, E] = y.useState(null), T = K0(k), O = T?.width ?? 0, M = T?.height ?? 0, z = s + (a !== "center" ? "-" + a : ""), N = typeof u == "number" ? u : { top: 0, right: 0, bottom: 0, left: 0, ...u }, $ = Array.isArray(c) ? c : [c], L = $.length > 0, _ = {
|
|
6078
6242
|
padding: N,
|
|
6079
|
-
boundary: $.filter(
|
|
6243
|
+
boundary: $.filter(J0),
|
|
6080
6244
|
// with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
|
|
6081
6245
|
altBoundary: L
|
|
6082
|
-
}, { refs: R, floatingStyles: D, placement: F, isPositioned: U, middlewareData:
|
|
6246
|
+
}, { refs: R, floatingStyles: D, placement: F, isPositioned: U, middlewareData: P } = ho({
|
|
6083
6247
|
// default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
|
|
6084
6248
|
strategy: "fixed",
|
|
6085
6249
|
placement: z,
|
|
@@ -6106,14 +6270,14 @@ var mn = "PopperContent", [q0, X0] = gi(mn), wi = y.forwardRef(
|
|
|
6106
6270
|
}
|
|
6107
6271
|
}),
|
|
6108
6272
|
k && cu({ element: k, padding: i }),
|
|
6109
|
-
|
|
6273
|
+
tp({ arrowWidth: O, arrowHeight: M }),
|
|
6110
6274
|
m && lu({ strategy: "referenceHidden", ..._ })
|
|
6111
6275
|
]
|
|
6112
6276
|
}), [j, H] = Ei(F), nt = es(g);
|
|
6113
6277
|
ae(() => {
|
|
6114
6278
|
U && nt?.();
|
|
6115
6279
|
}, [U, nt]);
|
|
6116
|
-
const et =
|
|
6280
|
+
const et = P.arrow?.x, A = P.arrow?.y, W = P.arrow?.centerOffset !== 0, [G, B] = y.useState();
|
|
6117
6281
|
return ae(() => {
|
|
6118
6282
|
v && B(window.getComputedStyle(v).zIndex);
|
|
6119
6283
|
}, [v]), /* @__PURE__ */ f.jsx(
|
|
@@ -6128,20 +6292,20 @@ var mn = "PopperContent", [q0, X0] = gi(mn), wi = y.forwardRef(
|
|
|
6128
6292
|
minWidth: "max-content",
|
|
6129
6293
|
zIndex: G,
|
|
6130
6294
|
"--radix-popper-transform-origin": [
|
|
6131
|
-
|
|
6132
|
-
|
|
6295
|
+
P.transformOrigin?.x,
|
|
6296
|
+
P.transformOrigin?.y
|
|
6133
6297
|
].join(" "),
|
|
6134
6298
|
// hide the content if using the hide middleware and should be hidden
|
|
6135
6299
|
// set visibility to hidden and disable pointer events so the UI behaves
|
|
6136
6300
|
// as if the PopperContent isn't there at all
|
|
6137
|
-
...
|
|
6301
|
+
...P.hide?.referenceHidden && {
|
|
6138
6302
|
visibility: "hidden",
|
|
6139
6303
|
pointerEvents: "none"
|
|
6140
6304
|
}
|
|
6141
6305
|
},
|
|
6142
6306
|
dir: t.dir,
|
|
6143
6307
|
children: /* @__PURE__ */ f.jsx(
|
|
6144
|
-
|
|
6308
|
+
X0,
|
|
6145
6309
|
{
|
|
6146
6310
|
scope: r,
|
|
6147
6311
|
placedSide: j,
|
|
@@ -6171,13 +6335,13 @@ var mn = "PopperContent", [q0, X0] = gi(mn), wi = y.forwardRef(
|
|
|
6171
6335
|
}
|
|
6172
6336
|
);
|
|
6173
6337
|
wi.displayName = mn;
|
|
6174
|
-
var ki = "PopperArrow",
|
|
6338
|
+
var ki = "PopperArrow", Z0 = {
|
|
6175
6339
|
top: "bottom",
|
|
6176
6340
|
right: "left",
|
|
6177
6341
|
bottom: "top",
|
|
6178
6342
|
left: "right"
|
|
6179
6343
|
}, Si = y.forwardRef(function(e, r) {
|
|
6180
|
-
const { __scopePopper: s, ...n } = e, a =
|
|
6344
|
+
const { __scopePopper: s, ...n } = e, a = Q0(ki, s), o = Z0[a.placedSide];
|
|
6181
6345
|
return (
|
|
6182
6346
|
// we have to use an extra wrapper because `ResizeObserver` (used by `useSize`)
|
|
6183
6347
|
// doesn't report size as we'd expect on SVG elements.
|
|
@@ -6206,7 +6370,7 @@ var ki = "PopperArrow", Q0 = {
|
|
|
6206
6370
|
visibility: a.shouldHideArrow ? "hidden" : void 0
|
|
6207
6371
|
},
|
|
6208
6372
|
children: /* @__PURE__ */ f.jsx(
|
|
6209
|
-
|
|
6373
|
+
G0,
|
|
6210
6374
|
{
|
|
6211
6375
|
...n,
|
|
6212
6376
|
ref: r,
|
|
@@ -6222,10 +6386,10 @@ var ki = "PopperArrow", Q0 = {
|
|
|
6222
6386
|
);
|
|
6223
6387
|
});
|
|
6224
6388
|
Si.displayName = ki;
|
|
6225
|
-
function
|
|
6389
|
+
function J0(t) {
|
|
6226
6390
|
return t !== null;
|
|
6227
6391
|
}
|
|
6228
|
-
var
|
|
6392
|
+
var tp = (t) => ({
|
|
6229
6393
|
name: "transformOrigin",
|
|
6230
6394
|
options: t,
|
|
6231
6395
|
fn(e) {
|
|
@@ -6238,23 +6402,23 @@ function Ei(t) {
|
|
|
6238
6402
|
const [e, r = "center"] = t.split("-");
|
|
6239
6403
|
return [e, r];
|
|
6240
6404
|
}
|
|
6241
|
-
var
|
|
6405
|
+
var ep = vi, rp = yi, sp = wi, np = Si, ap = "Portal", Ni = y.forwardRef((t, e) => {
|
|
6242
6406
|
const { container: r, ...s } = t, [n, a] = y.useState(!1);
|
|
6243
6407
|
ae(() => a(!0), []);
|
|
6244
6408
|
const o = r || n && globalThis?.document?.body;
|
|
6245
6409
|
return o ? Ji.createPortal(/* @__PURE__ */ f.jsx(le.div, { ...s, ref: e }), o) : null;
|
|
6246
6410
|
});
|
|
6247
|
-
Ni.displayName =
|
|
6248
|
-
function
|
|
6411
|
+
Ni.displayName = ap;
|
|
6412
|
+
function op(t, e) {
|
|
6249
6413
|
return y.useReducer((r, s) => e[r][s] ?? r, t);
|
|
6250
6414
|
}
|
|
6251
6415
|
var gn = (t) => {
|
|
6252
|
-
const { present: e, children: r } = t, s =
|
|
6416
|
+
const { present: e, children: r } = t, s = ip(e), n = typeof r == "function" ? r({ present: s.isPresent }) : y.Children.only(r), a = ke(s.ref, lp(n));
|
|
6253
6417
|
return typeof r == "function" || s.isPresent ? y.cloneElement(n, { ref: a }) : null;
|
|
6254
6418
|
};
|
|
6255
6419
|
gn.displayName = "Presence";
|
|
6256
|
-
function
|
|
6257
|
-
const [e, r] = y.useState(), s = y.useRef(null), n = y.useRef(t), a = y.useRef("none"), o = t ? "mounted" : "unmounted", [i, l] =
|
|
6420
|
+
function ip(t) {
|
|
6421
|
+
const [e, r] = y.useState(), s = y.useRef(null), n = y.useRef(t), a = y.useRef("none"), o = t ? "mounted" : "unmounted", [i, l] = op(o, {
|
|
6258
6422
|
mounted: {
|
|
6259
6423
|
UNMOUNT: "unmounted",
|
|
6260
6424
|
ANIMATION_OUT: "unmountSuspended"
|
|
@@ -6305,19 +6469,19 @@ function op(t) {
|
|
|
6305
6469
|
function xr(t) {
|
|
6306
6470
|
return t?.animationName || "none";
|
|
6307
6471
|
}
|
|
6308
|
-
function
|
|
6472
|
+
function lp(t) {
|
|
6309
6473
|
let e = Object.getOwnPropertyDescriptor(t.props, "ref")?.get, r = e && "isReactWarning" in e && e.isReactWarning;
|
|
6310
6474
|
return r ? t.ref : (e = Object.getOwnPropertyDescriptor(t, "ref")?.get, r = e && "isReactWarning" in e && e.isReactWarning, r ? t.props.ref : t.props.ref || t.ref);
|
|
6311
6475
|
}
|
|
6312
|
-
var
|
|
6313
|
-
function
|
|
6476
|
+
var cp = y[" useInsertionEffect ".trim().toString()] || ae;
|
|
6477
|
+
function up({
|
|
6314
6478
|
prop: t,
|
|
6315
6479
|
defaultProp: e,
|
|
6316
6480
|
onChange: r = () => {
|
|
6317
6481
|
},
|
|
6318
6482
|
caller: s
|
|
6319
6483
|
}) {
|
|
6320
|
-
const [n, a, o] =
|
|
6484
|
+
const [n, a, o] = dp({
|
|
6321
6485
|
defaultProp: e,
|
|
6322
6486
|
onChange: r
|
|
6323
6487
|
}), i = t !== void 0, l = i ? t : n;
|
|
@@ -6333,7 +6497,7 @@ function cp({
|
|
|
6333
6497
|
const c = y.useCallback(
|
|
6334
6498
|
(u) => {
|
|
6335
6499
|
if (i) {
|
|
6336
|
-
const p =
|
|
6500
|
+
const p = fp(u) ? u(t) : u;
|
|
6337
6501
|
p !== t && o.current?.(p);
|
|
6338
6502
|
} else
|
|
6339
6503
|
a(u);
|
|
@@ -6342,21 +6506,21 @@ function cp({
|
|
|
6342
6506
|
);
|
|
6343
6507
|
return [l, c];
|
|
6344
6508
|
}
|
|
6345
|
-
function
|
|
6509
|
+
function dp({
|
|
6346
6510
|
defaultProp: t,
|
|
6347
6511
|
onChange: e
|
|
6348
6512
|
}) {
|
|
6349
6513
|
const [r, s] = y.useState(t), n = y.useRef(r), a = y.useRef(e);
|
|
6350
|
-
return
|
|
6514
|
+
return cp(() => {
|
|
6351
6515
|
a.current = e;
|
|
6352
6516
|
}, [e]), y.useEffect(() => {
|
|
6353
6517
|
n.current !== r && (a.current?.(r), n.current = r);
|
|
6354
6518
|
}, [r, n]), [r, s, a];
|
|
6355
6519
|
}
|
|
6356
|
-
function
|
|
6520
|
+
function fp(t) {
|
|
6357
6521
|
return typeof t == "function";
|
|
6358
6522
|
}
|
|
6359
|
-
var
|
|
6523
|
+
var pp = Object.freeze({
|
|
6360
6524
|
// See: https://github.com/twbs/bootstrap/blob/main/scss/mixins/_visually-hidden.scss
|
|
6361
6525
|
position: "absolute",
|
|
6362
6526
|
border: 0,
|
|
@@ -6368,23 +6532,23 @@ var fp = Object.freeze({
|
|
|
6368
6532
|
clip: "rect(0, 0, 0, 0)",
|
|
6369
6533
|
whiteSpace: "nowrap",
|
|
6370
6534
|
wordWrap: "normal"
|
|
6371
|
-
}),
|
|
6535
|
+
}), mp = "VisuallyHidden", Oi = y.forwardRef(
|
|
6372
6536
|
(t, e) => /* @__PURE__ */ f.jsx(
|
|
6373
6537
|
le.span,
|
|
6374
6538
|
{
|
|
6375
6539
|
...t,
|
|
6376
6540
|
ref: e,
|
|
6377
|
-
style: { ...
|
|
6541
|
+
style: { ...pp, ...t.style }
|
|
6378
6542
|
}
|
|
6379
6543
|
)
|
|
6380
6544
|
);
|
|
6381
|
-
|
|
6382
|
-
var
|
|
6545
|
+
Oi.displayName = mp;
|
|
6546
|
+
var gp = Oi, [rs] = ci("Tooltip", [
|
|
6383
6547
|
hi
|
|
6384
|
-
]), ss = hi(),
|
|
6548
|
+
]), ss = hi(), Pi = "TooltipProvider", hp = 700, Ns = "tooltip.open", [bp, hn] = rs(Pi), Ci = (t) => {
|
|
6385
6549
|
const {
|
|
6386
6550
|
__scopeTooltip: e,
|
|
6387
|
-
delayDuration: r =
|
|
6551
|
+
delayDuration: r = hp,
|
|
6388
6552
|
skipDelayDuration: s = 300,
|
|
6389
6553
|
disableHoverableContent: n = !1,
|
|
6390
6554
|
children: a
|
|
@@ -6393,7 +6557,7 @@ var mp = Pi, [rs] = ci("Tooltip", [
|
|
|
6393
6557
|
const c = l.current;
|
|
6394
6558
|
return () => window.clearTimeout(c);
|
|
6395
6559
|
}, []), /* @__PURE__ */ f.jsx(
|
|
6396
|
-
|
|
6560
|
+
bp,
|
|
6397
6561
|
{
|
|
6398
6562
|
scope: e,
|
|
6399
6563
|
isOpenDelayedRef: o,
|
|
@@ -6416,8 +6580,8 @@ var mp = Pi, [rs] = ci("Tooltip", [
|
|
|
6416
6580
|
}
|
|
6417
6581
|
);
|
|
6418
6582
|
};
|
|
6419
|
-
Ci.displayName =
|
|
6420
|
-
var Je = "Tooltip", [
|
|
6583
|
+
Ci.displayName = Pi;
|
|
6584
|
+
var Je = "Tooltip", [vp, pr] = rs(Je), Ti = (t) => {
|
|
6421
6585
|
const {
|
|
6422
6586
|
__scopeTooltip: e,
|
|
6423
6587
|
children: r,
|
|
@@ -6426,11 +6590,11 @@ var Je = "Tooltip", [bp, pr] = rs(Je), Ti = (t) => {
|
|
|
6426
6590
|
onOpenChange: a,
|
|
6427
6591
|
disableHoverableContent: o,
|
|
6428
6592
|
delayDuration: i
|
|
6429
|
-
} = t, l = hn(Je, t.__scopeTooltip), c = ss(e), [u, p] = y.useState(null), m =
|
|
6593
|
+
} = t, l = hn(Je, t.__scopeTooltip), c = ss(e), [u, p] = y.useState(null), m = U0(), d = y.useRef(0), g = o ?? l.disableHoverableContent, h = i ?? l.delayDuration, b = y.useRef(!1), [v, w] = up({
|
|
6430
6594
|
prop: s,
|
|
6431
6595
|
defaultProp: n ?? !1,
|
|
6432
|
-
onChange: (
|
|
6433
|
-
|
|
6596
|
+
onChange: (O) => {
|
|
6597
|
+
O ? (l.onOpen(), document.dispatchEvent(new CustomEvent(Ns))) : l.onClose(), a?.(O);
|
|
6434
6598
|
},
|
|
6435
6599
|
caller: Je
|
|
6436
6600
|
}), x = y.useMemo(() => v ? b.current ? "delayed-open" : "instant-open" : "closed", [v]), k = y.useCallback(() => {
|
|
@@ -6444,8 +6608,8 @@ var Je = "Tooltip", [bp, pr] = rs(Je), Ti = (t) => {
|
|
|
6444
6608
|
}, [h, w]);
|
|
6445
6609
|
return y.useEffect(() => () => {
|
|
6446
6610
|
d.current && (window.clearTimeout(d.current), d.current = 0);
|
|
6447
|
-
}, []), /* @__PURE__ */ f.jsx(
|
|
6448
|
-
|
|
6611
|
+
}, []), /* @__PURE__ */ f.jsx(ep, { ...c, children: /* @__PURE__ */ f.jsx(
|
|
6612
|
+
vp,
|
|
6449
6613
|
{
|
|
6450
6614
|
scope: e,
|
|
6451
6615
|
contentId: m,
|
|
@@ -6467,10 +6631,10 @@ var Je = "Tooltip", [bp, pr] = rs(Je), Ti = (t) => {
|
|
|
6467
6631
|
) });
|
|
6468
6632
|
};
|
|
6469
6633
|
Ti.displayName = Je;
|
|
6470
|
-
var
|
|
6634
|
+
var Os = "TooltipTrigger", ji = y.forwardRef(
|
|
6471
6635
|
(t, e) => {
|
|
6472
|
-
const { __scopeTooltip: r, ...s } = t, n = pr(
|
|
6473
|
-
return y.useEffect(() => () => document.removeEventListener("pointerup", p), [p]), /* @__PURE__ */ f.jsx(
|
|
6636
|
+
const { __scopeTooltip: r, ...s } = t, n = pr(Os, r), a = hn(Os, r), o = ss(r), i = y.useRef(null), l = ke(e, i, n.onTriggerChange), c = y.useRef(!1), u = y.useRef(!1), p = y.useCallback(() => c.current = !1, []);
|
|
6637
|
+
return y.useEffect(() => () => document.removeEventListener("pointerup", p), [p]), /* @__PURE__ */ f.jsx(rp, { asChild: !0, ...o, children: /* @__PURE__ */ f.jsx(
|
|
6474
6638
|
le.button,
|
|
6475
6639
|
{
|
|
6476
6640
|
"aria-describedby": n.open ? n.contentId : void 0,
|
|
@@ -6495,25 +6659,25 @@ var Ps = "TooltipTrigger", ji = y.forwardRef(
|
|
|
6495
6659
|
) });
|
|
6496
6660
|
}
|
|
6497
6661
|
);
|
|
6498
|
-
ji.displayName =
|
|
6499
|
-
var bn = "TooltipPortal", [
|
|
6662
|
+
ji.displayName = Os;
|
|
6663
|
+
var bn = "TooltipPortal", [xp, yp] = rs(bn, {
|
|
6500
6664
|
forceMount: void 0
|
|
6501
6665
|
}), Ri = (t) => {
|
|
6502
6666
|
const { __scopeTooltip: e, forceMount: r, children: s, container: n } = t, a = pr(bn, e);
|
|
6503
|
-
return /* @__PURE__ */ f.jsx(
|
|
6667
|
+
return /* @__PURE__ */ f.jsx(xp, { scope: e, forceMount: r, children: /* @__PURE__ */ f.jsx(gn, { present: r || a.open, children: /* @__PURE__ */ f.jsx(Ni, { asChild: !0, container: n, children: s }) }) });
|
|
6504
6668
|
};
|
|
6505
6669
|
Ri.displayName = bn;
|
|
6506
6670
|
var Re = "TooltipContent", $i = y.forwardRef(
|
|
6507
6671
|
(t, e) => {
|
|
6508
|
-
const r =
|
|
6509
|
-
return /* @__PURE__ */ f.jsx(gn, { present: s || o.open, children: o.disableHoverableContent ? /* @__PURE__ */ f.jsx(Ii, { side: n, ...a, ref: e }) : /* @__PURE__ */ f.jsx(
|
|
6672
|
+
const r = yp(Re, t.__scopeTooltip), { forceMount: s = r.forceMount, side: n = "top", ...a } = t, o = pr(Re, t.__scopeTooltip);
|
|
6673
|
+
return /* @__PURE__ */ f.jsx(gn, { present: s || o.open, children: o.disableHoverableContent ? /* @__PURE__ */ f.jsx(Ii, { side: n, ...a, ref: e }) : /* @__PURE__ */ f.jsx(wp, { side: n, ...a, ref: e }) });
|
|
6510
6674
|
}
|
|
6511
|
-
),
|
|
6675
|
+
), wp = y.forwardRef((t, e) => {
|
|
6512
6676
|
const r = pr(Re, t.__scopeTooltip), s = hn(Re, t.__scopeTooltip), n = y.useRef(null), a = ke(e, n), [o, i] = y.useState(null), { trigger: l, onClose: c } = r, u = n.current, { onPointerInTransitChange: p } = s, m = y.useCallback(() => {
|
|
6513
6677
|
i(null), p(!1);
|
|
6514
6678
|
}, [p]), d = y.useCallback(
|
|
6515
6679
|
(g, h) => {
|
|
6516
|
-
const b = g.currentTarget, v = { x: g.clientX, y: g.clientY }, w =
|
|
6680
|
+
const b = g.currentTarget, v = { x: g.clientX, y: g.clientY }, w = Np(v, b.getBoundingClientRect()), x = Op(v, w), k = Pp(h.getBoundingClientRect()), E = Tp([...x, ...k]);
|
|
6517
6681
|
i(E), p(!0);
|
|
6518
6682
|
},
|
|
6519
6683
|
[p]
|
|
@@ -6528,13 +6692,13 @@ var Re = "TooltipContent", $i = y.forwardRef(
|
|
|
6528
6692
|
}, [l, u, d, m]), y.useEffect(() => {
|
|
6529
6693
|
if (o) {
|
|
6530
6694
|
const g = (h) => {
|
|
6531
|
-
const b = h.target, v = { x: h.clientX, y: h.clientY }, w = l?.contains(b) || u?.contains(b), x = !
|
|
6695
|
+
const b = h.target, v = { x: h.clientX, y: h.clientY }, w = l?.contains(b) || u?.contains(b), x = !Cp(v, o);
|
|
6532
6696
|
w ? m() : x && (m(), c());
|
|
6533
6697
|
};
|
|
6534
6698
|
return document.addEventListener("pointermove", g), () => document.removeEventListener("pointermove", g);
|
|
6535
6699
|
}
|
|
6536
6700
|
}, [l, u, o, c, m]), /* @__PURE__ */ f.jsx(Ii, { ...t, ref: a });
|
|
6537
|
-
}), [
|
|
6701
|
+
}), [kp, Sp] = rs(Je, { isInside: !1 }), Ep = /* @__PURE__ */ T0("TooltipContent"), Ii = y.forwardRef(
|
|
6538
6702
|
(t, e) => {
|
|
6539
6703
|
const {
|
|
6540
6704
|
__scopeTooltip: r,
|
|
@@ -6561,7 +6725,7 @@ var Re = "TooltipContent", $i = y.forwardRef(
|
|
|
6561
6725
|
onFocusOutside: (p) => p.preventDefault(),
|
|
6562
6726
|
onDismiss: u,
|
|
6563
6727
|
children: /* @__PURE__ */ f.jsxs(
|
|
6564
|
-
|
|
6728
|
+
sp,
|
|
6565
6729
|
{
|
|
6566
6730
|
"data-state": l.stateAttribute,
|
|
6567
6731
|
...c,
|
|
@@ -6576,8 +6740,8 @@ var Re = "TooltipContent", $i = y.forwardRef(
|
|
|
6576
6740
|
"--radix-tooltip-trigger-height": "var(--radix-popper-anchor-height)"
|
|
6577
6741
|
},
|
|
6578
6742
|
children: [
|
|
6579
|
-
/* @__PURE__ */ f.jsx(
|
|
6580
|
-
/* @__PURE__ */ f.jsx(
|
|
6743
|
+
/* @__PURE__ */ f.jsx(Ep, { children: s }),
|
|
6744
|
+
/* @__PURE__ */ f.jsx(kp, { scope: r, isInside: !0, children: /* @__PURE__ */ f.jsx(gp, { id: l.contentId, role: "tooltip", children: n || s }) })
|
|
6581
6745
|
]
|
|
6582
6746
|
}
|
|
6583
6747
|
)
|
|
@@ -6589,14 +6753,14 @@ $i.displayName = Re;
|
|
|
6589
6753
|
var Ai = "TooltipArrow", Di = y.forwardRef(
|
|
6590
6754
|
(t, e) => {
|
|
6591
6755
|
const { __scopeTooltip: r, ...s } = t, n = ss(r);
|
|
6592
|
-
return
|
|
6756
|
+
return Sp(
|
|
6593
6757
|
Ai,
|
|
6594
6758
|
r
|
|
6595
|
-
).isInside ? null : /* @__PURE__ */ f.jsx(
|
|
6759
|
+
).isInside ? null : /* @__PURE__ */ f.jsx(np, { ...n, ...s, ref: e });
|
|
6596
6760
|
}
|
|
6597
6761
|
);
|
|
6598
6762
|
Di.displayName = Ai;
|
|
6599
|
-
function
|
|
6763
|
+
function Np(t, e) {
|
|
6600
6764
|
const r = Math.abs(e.top - t.y), s = Math.abs(e.bottom - t.y), n = Math.abs(e.right - t.x), a = Math.abs(e.left - t.x);
|
|
6601
6765
|
switch (Math.min(r, s, n, a)) {
|
|
6602
6766
|
case a:
|
|
@@ -6611,7 +6775,7 @@ function Ep(t, e) {
|
|
|
6611
6775
|
throw new Error("unreachable");
|
|
6612
6776
|
}
|
|
6613
6777
|
}
|
|
6614
|
-
function
|
|
6778
|
+
function Op(t, e, r = 5) {
|
|
6615
6779
|
const s = [];
|
|
6616
6780
|
switch (e) {
|
|
6617
6781
|
case "top":
|
|
@@ -6650,7 +6814,7 @@ function Pp(t) {
|
|
|
6650
6814
|
{ x: n, y: s }
|
|
6651
6815
|
];
|
|
6652
6816
|
}
|
|
6653
|
-
function
|
|
6817
|
+
function Cp(t, e) {
|
|
6654
6818
|
const { x: r, y: s } = t;
|
|
6655
6819
|
let n = !1;
|
|
6656
6820
|
for (let a = 0, o = e.length - 1; a < e.length; o = a++) {
|
|
@@ -6659,11 +6823,11 @@ function Op(t, e) {
|
|
|
6659
6823
|
}
|
|
6660
6824
|
return n;
|
|
6661
6825
|
}
|
|
6662
|
-
function
|
|
6826
|
+
function Tp(t) {
|
|
6663
6827
|
const e = t.slice();
|
|
6664
|
-
return e.sort((r, s) => r.x < s.x ? -1 : r.x > s.x ? 1 : r.y < s.y ? -1 : r.y > s.y ? 1 : 0),
|
|
6828
|
+
return e.sort((r, s) => r.x < s.x ? -1 : r.x > s.x ? 1 : r.y < s.y ? -1 : r.y > s.y ? 1 : 0), jp(e);
|
|
6665
6829
|
}
|
|
6666
|
-
function
|
|
6830
|
+
function jp(t) {
|
|
6667
6831
|
if (t.length <= 1) return t.slice();
|
|
6668
6832
|
const e = [];
|
|
6669
6833
|
for (let s = 0; s < t.length; s++) {
|
|
@@ -6688,8 +6852,8 @@ function Tp(t) {
|
|
|
6688
6852
|
}
|
|
6689
6853
|
return r.pop(), e.length === 1 && r.length === 1 && e[0].x === r[0].x && e[0].y === r[0].y ? e : e.concat(r);
|
|
6690
6854
|
}
|
|
6691
|
-
var
|
|
6692
|
-
function
|
|
6855
|
+
var Rp = Ci, $p = Ti, Ip = ji, Ap = Ri, Dp = $i, Fp = Di;
|
|
6856
|
+
function Hm({
|
|
6693
6857
|
content: t,
|
|
6694
6858
|
children: e,
|
|
6695
6859
|
placement: r = "top",
|
|
@@ -6699,8 +6863,8 @@ function Bm({
|
|
|
6699
6863
|
className: o
|
|
6700
6864
|
}) {
|
|
6701
6865
|
const [i, l] = X(a), c = tt(() => l((u) => !u), []);
|
|
6702
|
-
return /* @__PURE__ */ f.jsx(
|
|
6703
|
-
/* @__PURE__ */ f.jsx(
|
|
6866
|
+
return /* @__PURE__ */ f.jsx(Rp, { delayDuration: n, children: /* @__PURE__ */ f.jsxs($p, { open: i, onOpenChange: l, children: [
|
|
6867
|
+
/* @__PURE__ */ f.jsx(Ip, { asChild: !0, onClick: c, children: /* @__PURE__ */ f.jsx(
|
|
6704
6868
|
"span",
|
|
6705
6869
|
{
|
|
6706
6870
|
className: "rst:inline-flex rst:items-center rst:cursor-default",
|
|
@@ -6709,8 +6873,8 @@ function Bm({
|
|
|
6709
6873
|
children: e
|
|
6710
6874
|
}
|
|
6711
6875
|
) }),
|
|
6712
|
-
/* @__PURE__ */ f.jsx(
|
|
6713
|
-
|
|
6876
|
+
/* @__PURE__ */ f.jsx(Ap, { children: /* @__PURE__ */ f.jsxs(
|
|
6877
|
+
Dp,
|
|
6714
6878
|
{
|
|
6715
6879
|
side: r,
|
|
6716
6880
|
sideOffset: 8,
|
|
@@ -6729,7 +6893,7 @@ function Bm({
|
|
|
6729
6893
|
children: [
|
|
6730
6894
|
t,
|
|
6731
6895
|
/* @__PURE__ */ f.jsx(
|
|
6732
|
-
|
|
6896
|
+
Fp,
|
|
6733
6897
|
{
|
|
6734
6898
|
className: s === "dark" ? "rst:fill-zinc-900" : "rst:fill-white",
|
|
6735
6899
|
width: 12,
|
|
@@ -6741,7 +6905,7 @@ function Bm({
|
|
|
6741
6905
|
) })
|
|
6742
6906
|
] }) });
|
|
6743
6907
|
}
|
|
6744
|
-
const
|
|
6908
|
+
const Mp = {
|
|
6745
6909
|
xs: "rst:max-h-8",
|
|
6746
6910
|
// single row of chips, tags, or badges
|
|
6747
6911
|
sm: "rst:max-h-16",
|
|
@@ -6751,7 +6915,7 @@ const Fp = {
|
|
|
6751
6915
|
lg: "rst:max-h-36"
|
|
6752
6916
|
// ~6-7 lines
|
|
6753
6917
|
};
|
|
6754
|
-
function
|
|
6918
|
+
function zm({
|
|
6755
6919
|
children: t,
|
|
6756
6920
|
size: e = "md",
|
|
6757
6921
|
expandLabel: r = "Show more",
|
|
@@ -6768,7 +6932,7 @@ function Hm({
|
|
|
6768
6932
|
{
|
|
6769
6933
|
ref: c,
|
|
6770
6934
|
"data-testid": "collapsible-content",
|
|
6771
|
-
className: C(!a &&
|
|
6935
|
+
className: C(!a && Mp[e], !a && "rst:overflow-hidden"),
|
|
6772
6936
|
style: !a && i ? {
|
|
6773
6937
|
maskImage: "linear-gradient(to bottom, black 50%, transparent 100%)",
|
|
6774
6938
|
WebkitMaskImage: "linear-gradient(to bottom, black 50%, transparent 100%)"
|
|
@@ -6788,7 +6952,7 @@ function Hm({
|
|
|
6788
6952
|
)
|
|
6789
6953
|
] });
|
|
6790
6954
|
}
|
|
6791
|
-
function
|
|
6955
|
+
function Wm({
|
|
6792
6956
|
segments: t,
|
|
6793
6957
|
size: e = "md",
|
|
6794
6958
|
showLegend: r = !0,
|
|
@@ -6855,7 +7019,7 @@ function zm({
|
|
|
6855
7019
|
)
|
|
6856
7020
|
] });
|
|
6857
7021
|
}
|
|
6858
|
-
const
|
|
7022
|
+
const Lp = Z(
|
|
6859
7023
|
"rst:font-ui rst:flex rst:items-start rst:gap-2.5 rst:rounded-lg rst:border-l-4 rst:px-4 rst:py-3 rst:text-sm",
|
|
6860
7024
|
{
|
|
6861
7025
|
variants: {
|
|
@@ -6930,15 +7094,15 @@ const Mp = Z(
|
|
|
6930
7094
|
surface: "tint"
|
|
6931
7095
|
}
|
|
6932
7096
|
}
|
|
6933
|
-
),
|
|
7097
|
+
), _p = {
|
|
6934
7098
|
error: Ui,
|
|
6935
7099
|
success: Wi,
|
|
6936
|
-
amber:
|
|
7100
|
+
amber: Pa,
|
|
6937
7101
|
info: hr,
|
|
6938
7102
|
primary: hr,
|
|
6939
7103
|
neutral: hr,
|
|
6940
7104
|
current: hr
|
|
6941
|
-
},
|
|
7105
|
+
}, Vp = S.forwardRef(
|
|
6942
7106
|
({
|
|
6943
7107
|
colorScheme: t = "error",
|
|
6944
7108
|
surface: e,
|
|
@@ -6957,13 +7121,13 @@ const Mp = Z(
|
|
|
6957
7121
|
ref: c,
|
|
6958
7122
|
role: u ? "alert" : "status",
|
|
6959
7123
|
"aria-live": u ? "assertive" : "polite",
|
|
6960
|
-
className: C(
|
|
7124
|
+
className: C(Lp({ colorScheme: t, surface: e }), i),
|
|
6961
7125
|
...l,
|
|
6962
7126
|
children: [
|
|
6963
7127
|
n === void 0 ? /* @__PURE__ */ f.jsx(
|
|
6964
7128
|
mt,
|
|
6965
7129
|
{
|
|
6966
|
-
icon:
|
|
7130
|
+
icon: _p[t ?? "error"],
|
|
6967
7131
|
className: "rst:mt-0.5 rst:h-4 rst:w-4 rst:shrink-0",
|
|
6968
7132
|
"aria-hidden": "true"
|
|
6969
7133
|
}
|
|
@@ -6987,8 +7151,8 @@ const Mp = Z(
|
|
|
6987
7151
|
);
|
|
6988
7152
|
}
|
|
6989
7153
|
);
|
|
6990
|
-
|
|
6991
|
-
const
|
|
7154
|
+
Vp.displayName = "Alert";
|
|
7155
|
+
const Um = ({
|
|
6992
7156
|
items: t,
|
|
6993
7157
|
allowMultiple: e = !1,
|
|
6994
7158
|
variant: r = "soft",
|
|
@@ -7017,7 +7181,7 @@ const Wm = ({
|
|
|
7017
7181
|
}
|
|
7018
7182
|
)
|
|
7019
7183
|
] }, c.id)) });
|
|
7020
|
-
},
|
|
7184
|
+
}, Bp = Z("rst:m-0", {
|
|
7021
7185
|
variants: {
|
|
7022
7186
|
layout: {
|
|
7023
7187
|
/** Term and description on one row, term column sized to content. */
|
|
@@ -7033,12 +7197,12 @@ const Wm = ({
|
|
|
7033
7197
|
}
|
|
7034
7198
|
},
|
|
7035
7199
|
defaultVariants: { layout: "inline", size: "sm" }
|
|
7036
|
-
}),
|
|
7200
|
+
}), Hp = S.forwardRef(
|
|
7037
7201
|
({ items: t, layout: e, size: r, dividers: s = !1, className: n, ...a }, o) => /* @__PURE__ */ f.jsx(
|
|
7038
7202
|
"dl",
|
|
7039
7203
|
{
|
|
7040
7204
|
ref: o,
|
|
7041
|
-
className: C(
|
|
7205
|
+
className: C(Bp({ layout: e, size: r }), n),
|
|
7042
7206
|
...a,
|
|
7043
7207
|
children: t.map((i, l) => {
|
|
7044
7208
|
const c = l === t.length - 1, u = s && !c ? "rst:border-b rst:border-gray-200 rst:pb-1.5 rst:dark:border-gray-800" : "";
|
|
@@ -7056,8 +7220,8 @@ const Wm = ({
|
|
|
7056
7220
|
}
|
|
7057
7221
|
)
|
|
7058
7222
|
);
|
|
7059
|
-
|
|
7060
|
-
const
|
|
7223
|
+
Hp.displayName = "DescriptionList";
|
|
7224
|
+
const zp = Z("rst:my-1", {
|
|
7061
7225
|
variants: {
|
|
7062
7226
|
variant: {
|
|
7063
7227
|
/** Accent rule down the left. The quiet default. */
|
|
@@ -7084,12 +7248,12 @@ const Hp = Z("rst:my-1", {
|
|
|
7084
7248
|
}
|
|
7085
7249
|
},
|
|
7086
7250
|
defaultVariants: { variant: "rule", colorScheme: "primary" }
|
|
7087
|
-
}),
|
|
7251
|
+
}), Wp = S.forwardRef(
|
|
7088
7252
|
({ children: t, cite: e, citeUrl: r, variant: s, colorScheme: n, className: a, ...o }, i) => /* @__PURE__ */ f.jsxs(
|
|
7089
7253
|
"figure",
|
|
7090
7254
|
{
|
|
7091
7255
|
ref: i,
|
|
7092
|
-
className: C(
|
|
7256
|
+
className: C(zp({ variant: s, colorScheme: n }), a),
|
|
7093
7257
|
...o,
|
|
7094
7258
|
children: [
|
|
7095
7259
|
/* @__PURE__ */ f.jsx(
|
|
@@ -7105,7 +7269,7 @@ const Hp = Z("rst:my-1", {
|
|
|
7105
7269
|
}
|
|
7106
7270
|
)
|
|
7107
7271
|
);
|
|
7108
|
-
|
|
7272
|
+
Wp.displayName = "Pullquote";
|
|
7109
7273
|
const ga = Z(
|
|
7110
7274
|
"rst:font-ui rst:flex rst:items-center rst:text-sm rst:font-medium rst:transition-colors",
|
|
7111
7275
|
{
|
|
@@ -7120,7 +7284,7 @@ const ga = Z(
|
|
|
7120
7284
|
variant: "default"
|
|
7121
7285
|
}
|
|
7122
7286
|
}
|
|
7123
|
-
),
|
|
7287
|
+
), Ym = ({
|
|
7124
7288
|
items: t,
|
|
7125
7289
|
separator: e,
|
|
7126
7290
|
showHomeIcon: r,
|
|
@@ -7197,7 +7361,7 @@ const ga = Z(
|
|
|
7197
7361
|
);
|
|
7198
7362
|
})
|
|
7199
7363
|
] }) });
|
|
7200
|
-
},
|
|
7364
|
+
}, Up = Z(
|
|
7201
7365
|
"rst:font-ui rst:relative rst:flex rst:flex-col rst:gap-4 rst:overflow-hidden rst:rounded-lg rst:border rst:p-6 rst:shadow-sm rst:transition-all rst:md:flex-row rst:md:items-center rst:md:justify-between",
|
|
7202
7366
|
{
|
|
7203
7367
|
variants: {
|
|
@@ -7214,7 +7378,7 @@ const ga = Z(
|
|
|
7214
7378
|
variant: "primary"
|
|
7215
7379
|
}
|
|
7216
7380
|
}
|
|
7217
|
-
),
|
|
7381
|
+
), Gm = ({
|
|
7218
7382
|
title: t,
|
|
7219
7383
|
description: e,
|
|
7220
7384
|
action: r,
|
|
@@ -7223,7 +7387,7 @@ const ga = Z(
|
|
|
7223
7387
|
onDismiss: a,
|
|
7224
7388
|
className: o,
|
|
7225
7389
|
...i
|
|
7226
|
-
}) => /* @__PURE__ */ f.jsxs("div", { className: C(
|
|
7390
|
+
}) => /* @__PURE__ */ f.jsxs("div", { className: C(Up({ variant: n }), o), ...i, children: [
|
|
7227
7391
|
/* @__PURE__ */ f.jsxs("div", { className: "rst:flex rst:items-start rst:gap-4", children: [
|
|
7228
7392
|
s && /* @__PURE__ */ f.jsx("div", { className: "rst:mt-1 rst:shrink-0 rst:text-current", children: s }),
|
|
7229
7393
|
/* @__PURE__ */ f.jsxs("div", { className: "rst:flex rst:flex-col rst:gap-1.5 rst:w-full", children: [
|
|
@@ -7243,7 +7407,7 @@ const ga = Z(
|
|
|
7243
7407
|
children: /* @__PURE__ */ f.jsx(mt, { icon: Ge, className: "rst:h-4 rst:w-4" })
|
|
7244
7408
|
}
|
|
7245
7409
|
) })
|
|
7246
|
-
] }),
|
|
7410
|
+
] }), Yp = Z(
|
|
7247
7411
|
"rst:font-ui rst:flex rst:flex-col rst:items-center rst:justify-center rst:text-center rst:p-8 rst:rounded-lg rst:transition-colors",
|
|
7248
7412
|
{
|
|
7249
7413
|
variants: {
|
|
@@ -7256,7 +7420,7 @@ const ga = Z(
|
|
|
7256
7420
|
variant: "dashed"
|
|
7257
7421
|
}
|
|
7258
7422
|
}
|
|
7259
|
-
),
|
|
7423
|
+
), Km = ({
|
|
7260
7424
|
title: t,
|
|
7261
7425
|
description: e,
|
|
7262
7426
|
icon: r,
|
|
@@ -7264,12 +7428,12 @@ const ga = Z(
|
|
|
7264
7428
|
variant: n,
|
|
7265
7429
|
className: a,
|
|
7266
7430
|
...o
|
|
7267
|
-
}) => /* @__PURE__ */ f.jsxs("div", { className: C(
|
|
7431
|
+
}) => /* @__PURE__ */ f.jsxs("div", { className: C(Yp({ variant: n }), a), ...o, children: [
|
|
7268
7432
|
r && /* @__PURE__ */ f.jsx("div", { className: "rst:mb-4 rst:flex rst:h-12 rst:w-12 rst:items-center rst:justify-center rst:rounded-full rst:bg-gray-100 rst:text-gray-400 rst:dark:bg-gray-800 rst:dark:text-gray-500", children: /* @__PURE__ */ f.jsx("div", { className: "rst:h-6 rst:w-6 rst:[&>svg]:h-full rst:[&>svg]:w-full", children: r }) }),
|
|
7269
7433
|
/* @__PURE__ */ f.jsx("h3", { className: "rst:text-lg rst:font-semibold rst:text-gray-900 rst:dark:text-gray-100", children: t }),
|
|
7270
7434
|
e && /* @__PURE__ */ f.jsx("p", { className: "rst:mt-1 rst:max-w-sm rst:text-sm rst:text-gray-500 rst:dark:text-gray-400", children: e }),
|
|
7271
7435
|
s && /* @__PURE__ */ f.jsx("div", { className: "rst:mt-6", children: s })
|
|
7272
|
-
] }),
|
|
7436
|
+
] }), Gp = Z(
|
|
7273
7437
|
"rst:font-ui rst:flex rst:flex-col rst:items-center rst:justify-center rst:text-center rst:p-8 rst:rounded-lg rst:transition-colors",
|
|
7274
7438
|
{
|
|
7275
7439
|
variants: {
|
|
@@ -7282,7 +7446,7 @@ const ga = Z(
|
|
|
7282
7446
|
variant: "card"
|
|
7283
7447
|
}
|
|
7284
7448
|
}
|
|
7285
|
-
),
|
|
7449
|
+
), qm = ({
|
|
7286
7450
|
title: t = "An Error Occurred",
|
|
7287
7451
|
description: e,
|
|
7288
7452
|
onRetry: r,
|
|
@@ -7291,11 +7455,11 @@ const ga = Z(
|
|
|
7291
7455
|
variant: a,
|
|
7292
7456
|
className: o,
|
|
7293
7457
|
...i
|
|
7294
|
-
}) => /* @__PURE__ */ f.jsxs("div", { className: C(
|
|
7458
|
+
}) => /* @__PURE__ */ f.jsxs("div", { className: C(Gp({ variant: a }), o), ...i, children: [
|
|
7295
7459
|
/* @__PURE__ */ f.jsx("div", { className: "rst:mb-4 rst:flex rst:h-12 rst:w-12 rst:items-center rst:justify-center rst:rounded-full rst:bg-error-100 rst:text-error-600 rst:dark:bg-error-500/15 rst:dark:text-error-400", children: /* @__PURE__ */ f.jsx("div", { className: "rst:h-6 rst:w-6 rst:flex rst:items-center rst:justify-center", children: n || /* @__PURE__ */ f.jsx(
|
|
7296
7460
|
mt,
|
|
7297
7461
|
{
|
|
7298
|
-
icon:
|
|
7462
|
+
icon: Pa,
|
|
7299
7463
|
className: "rst:h-full rst:w-full"
|
|
7300
7464
|
}
|
|
7301
7465
|
) }) }),
|
|
@@ -7339,7 +7503,7 @@ const ga = Z(
|
|
|
7339
7503
|
}
|
|
7340
7504
|
},
|
|
7341
7505
|
defaultVariants: { state: "default" }
|
|
7342
|
-
}),
|
|
7506
|
+
}), Kp = S.forwardRef(
|
|
7343
7507
|
({
|
|
7344
7508
|
awayTeam: t,
|
|
7345
7509
|
homeTeam: e,
|
|
@@ -7412,8 +7576,8 @@ const ga = Z(
|
|
|
7412
7576
|
);
|
|
7413
7577
|
}
|
|
7414
7578
|
);
|
|
7415
|
-
|
|
7416
|
-
const
|
|
7579
|
+
Kp.displayName = "MatchupCard";
|
|
7580
|
+
const qp = Z(
|
|
7417
7581
|
"rst:font-ui rst:w-full rst:z-40 rst:shadow-lg rst:backdrop-blur-md rst:transition-all",
|
|
7418
7582
|
{
|
|
7419
7583
|
variants: {
|
|
@@ -7434,7 +7598,7 @@ const Kp = Z(
|
|
|
7434
7598
|
position: "top"
|
|
7435
7599
|
}
|
|
7436
7600
|
}
|
|
7437
|
-
),
|
|
7601
|
+
), Xp = Ra(
|
|
7438
7602
|
({
|
|
7439
7603
|
title: t,
|
|
7440
7604
|
subtitle: e,
|
|
@@ -7449,7 +7613,7 @@ const Kp = Z(
|
|
|
7449
7613
|
"div",
|
|
7450
7614
|
{
|
|
7451
7615
|
ref: c,
|
|
7452
|
-
className: C(
|
|
7616
|
+
className: C(qp({ variant: o, position: a }), i),
|
|
7453
7617
|
...l,
|
|
7454
7618
|
children: /* @__PURE__ */ f.jsxs("div", { className: "rst:container rst:mx-auto rst:p-4", children: [
|
|
7455
7619
|
/* @__PURE__ */ f.jsxs("div", { className: "rst:flex rst:justify-between rst:items-center", children: [
|
|
@@ -7465,20 +7629,20 @@ const Kp = Z(
|
|
|
7465
7629
|
}
|
|
7466
7630
|
)
|
|
7467
7631
|
);
|
|
7468
|
-
|
|
7469
|
-
const
|
|
7632
|
+
Xp.displayName = "ActionBar";
|
|
7633
|
+
const Qp = 864e5, Zp = 6e4, Jp = 36e5, va = /* @__PURE__ */ Symbol.for("constructDateFrom");
|
|
7470
7634
|
function $e(t, e) {
|
|
7471
7635
|
return typeof t == "function" ? t(e) : t && typeof t == "object" && va in t ? t[va](e) : t instanceof Date ? new t.constructor(e) : new Date(e);
|
|
7472
7636
|
}
|
|
7473
|
-
function
|
|
7637
|
+
function Ot(t, e) {
|
|
7474
7638
|
return $e(t, t);
|
|
7475
7639
|
}
|
|
7476
|
-
function
|
|
7477
|
-
const s =
|
|
7640
|
+
function tm(t, e, r) {
|
|
7641
|
+
const s = Ot(t);
|
|
7478
7642
|
return isNaN(e) ? $e(t, NaN) : (e && s.setDate(s.getDate() + e), s);
|
|
7479
7643
|
}
|
|
7480
|
-
function
|
|
7481
|
-
const s =
|
|
7644
|
+
function em(t, e, r) {
|
|
7645
|
+
const s = Ot(t);
|
|
7482
7646
|
if (isNaN(e)) return $e(t, NaN);
|
|
7483
7647
|
if (!e)
|
|
7484
7648
|
return s;
|
|
@@ -7500,11 +7664,11 @@ function Ve(t, e, r) {
|
|
|
7500
7664
|
hours: i = 0,
|
|
7501
7665
|
minutes: l = 0,
|
|
7502
7666
|
seconds: c = 0
|
|
7503
|
-
} = e, u =
|
|
7667
|
+
} = e, u = Ot(t), p = n || s ? em(u, n + s * 12) : u, m = o || a ? tm(p, o + a * 7) : p, d = l + i * 60, h = (c + d * 60) * 1e3;
|
|
7504
7668
|
return $e(t, +m + h);
|
|
7505
7669
|
}
|
|
7506
7670
|
function xa(t) {
|
|
7507
|
-
const e =
|
|
7671
|
+
const e = Ot(t), r = new Date(
|
|
7508
7672
|
Date.UTC(
|
|
7509
7673
|
e.getFullYear(),
|
|
7510
7674
|
e.getMonth(),
|
|
@@ -7525,22 +7689,22 @@ function ce(t, ...e) {
|
|
|
7525
7689
|
return e.map(r);
|
|
7526
7690
|
}
|
|
7527
7691
|
function ya(t, e) {
|
|
7528
|
-
const r =
|
|
7692
|
+
const r = Ot(t);
|
|
7529
7693
|
return r.setHours(0, 0, 0, 0), r;
|
|
7530
7694
|
}
|
|
7531
|
-
function
|
|
7695
|
+
function rm(t, e, r) {
|
|
7532
7696
|
const [s, n] = ce(
|
|
7533
7697
|
r?.in,
|
|
7534
7698
|
t,
|
|
7535
7699
|
e
|
|
7536
7700
|
), a = ya(s), o = ya(n), i = +a - xa(a), l = +o - xa(o);
|
|
7537
|
-
return Math.round((i - l) /
|
|
7701
|
+
return Math.round((i - l) / Qp);
|
|
7538
7702
|
}
|
|
7539
7703
|
function Ye(t, e) {
|
|
7540
|
-
const r = +
|
|
7704
|
+
const r = +Ot(t) - +Ot(e);
|
|
7541
7705
|
return r < 0 ? -1 : r > 0 ? 1 : r;
|
|
7542
7706
|
}
|
|
7543
|
-
function
|
|
7707
|
+
function sm(t, e, r) {
|
|
7544
7708
|
const [s, n] = ce(
|
|
7545
7709
|
r?.in,
|
|
7546
7710
|
t,
|
|
@@ -7548,7 +7712,7 @@ function rm(t, e, r) {
|
|
|
7548
7712
|
), a = s.getFullYear() - n.getFullYear(), o = s.getMonth() - n.getMonth();
|
|
7549
7713
|
return a * 12 + o;
|
|
7550
7714
|
}
|
|
7551
|
-
function
|
|
7715
|
+
function nm(t, e, r) {
|
|
7552
7716
|
const [s, n] = ce(
|
|
7553
7717
|
r?.in,
|
|
7554
7718
|
t,
|
|
@@ -7556,13 +7720,13 @@ function sm(t, e, r) {
|
|
|
7556
7720
|
);
|
|
7557
7721
|
return s.getFullYear() - n.getFullYear();
|
|
7558
7722
|
}
|
|
7559
|
-
function
|
|
7723
|
+
function am(t, e, r) {
|
|
7560
7724
|
const [s, n] = ce(
|
|
7561
7725
|
r?.in,
|
|
7562
7726
|
t,
|
|
7563
7727
|
e
|
|
7564
7728
|
), a = wa(s, n), o = Math.abs(
|
|
7565
|
-
|
|
7729
|
+
rm(s, n)
|
|
7566
7730
|
);
|
|
7567
7731
|
s.setDate(s.getDate() - a * o);
|
|
7568
7732
|
const i = +(wa(s, n) === -a), l = a * (o - i);
|
|
@@ -7578,90 +7742,90 @@ function vn(t) {
|
|
|
7578
7742
|
return s === 0 ? 0 : s;
|
|
7579
7743
|
};
|
|
7580
7744
|
}
|
|
7581
|
-
function
|
|
7745
|
+
function om(t, e, r) {
|
|
7582
7746
|
const [s, n] = ce(
|
|
7583
7747
|
r?.in,
|
|
7584
7748
|
t,
|
|
7585
7749
|
e
|
|
7586
|
-
), a = (+s - +n) /
|
|
7750
|
+
), a = (+s - +n) / Jp;
|
|
7587
7751
|
return vn(r?.roundingMethod)(a);
|
|
7588
7752
|
}
|
|
7589
7753
|
function Fi(t, e) {
|
|
7590
|
-
return +
|
|
7754
|
+
return +Ot(t) - +Ot(e);
|
|
7591
7755
|
}
|
|
7592
|
-
function
|
|
7593
|
-
const s = Fi(t, e) /
|
|
7756
|
+
function im(t, e, r) {
|
|
7757
|
+
const s = Fi(t, e) / Zp;
|
|
7594
7758
|
return vn(r?.roundingMethod)(s);
|
|
7595
7759
|
}
|
|
7596
|
-
function
|
|
7597
|
-
const r =
|
|
7760
|
+
function lm(t, e) {
|
|
7761
|
+
const r = Ot(t);
|
|
7598
7762
|
return r.setHours(23, 59, 59, 999), r;
|
|
7599
7763
|
}
|
|
7600
|
-
function
|
|
7601
|
-
const r =
|
|
7764
|
+
function cm(t, e) {
|
|
7765
|
+
const r = Ot(t), s = r.getMonth();
|
|
7602
7766
|
return r.setFullYear(r.getFullYear(), s + 1, 0), r.setHours(23, 59, 59, 999), r;
|
|
7603
7767
|
}
|
|
7604
|
-
function
|
|
7605
|
-
const r =
|
|
7606
|
-
return +
|
|
7768
|
+
function um(t, e) {
|
|
7769
|
+
const r = Ot(t);
|
|
7770
|
+
return +lm(r) == +cm(r);
|
|
7607
7771
|
}
|
|
7608
|
-
function
|
|
7772
|
+
function dm(t, e, r) {
|
|
7609
7773
|
const [s, n, a] = ce(
|
|
7610
7774
|
r?.in,
|
|
7611
7775
|
t,
|
|
7612
7776
|
t,
|
|
7613
7777
|
e
|
|
7614
7778
|
), o = Ye(n, a), i = Math.abs(
|
|
7615
|
-
|
|
7779
|
+
sm(n, a)
|
|
7616
7780
|
);
|
|
7617
7781
|
if (i < 1) return 0;
|
|
7618
7782
|
n.getMonth() === 1 && n.getDate() > 27 && n.setDate(30), n.setMonth(n.getMonth() - o * i);
|
|
7619
7783
|
let l = Ye(n, a) === -o;
|
|
7620
|
-
|
|
7784
|
+
um(s) && i === 1 && Ye(s, a) === 1 && (l = !1);
|
|
7621
7785
|
const c = o * (i - +l);
|
|
7622
7786
|
return c === 0 ? 0 : c;
|
|
7623
7787
|
}
|
|
7624
|
-
function
|
|
7788
|
+
function fm(t, e, r) {
|
|
7625
7789
|
const s = Fi(t, e) / 1e3;
|
|
7626
7790
|
return vn(r?.roundingMethod)(s);
|
|
7627
7791
|
}
|
|
7628
|
-
function
|
|
7792
|
+
function pm(t, e, r) {
|
|
7629
7793
|
const [s, n] = ce(
|
|
7630
7794
|
r?.in,
|
|
7631
7795
|
t,
|
|
7632
7796
|
e
|
|
7633
|
-
), a = Ye(s, n), o = Math.abs(
|
|
7797
|
+
), a = Ye(s, n), o = Math.abs(nm(s, n));
|
|
7634
7798
|
s.setFullYear(1584), n.setFullYear(1584);
|
|
7635
7799
|
const i = Ye(s, n) === -a, l = a * (o - +i);
|
|
7636
7800
|
return l === 0 ? 0 : l;
|
|
7637
7801
|
}
|
|
7638
|
-
function
|
|
7802
|
+
function mm(t, e) {
|
|
7639
7803
|
const [r, s] = ce(t, e.start, e.end);
|
|
7640
7804
|
return { start: r, end: s };
|
|
7641
7805
|
}
|
|
7642
|
-
function
|
|
7643
|
-
const { start: r, end: s } =
|
|
7806
|
+
function gm(t, e) {
|
|
7807
|
+
const { start: r, end: s } = mm(e?.in, t), n = {}, a = pm(s, r);
|
|
7644
7808
|
a && (n.years = a);
|
|
7645
|
-
const o = Ve(r, { years: n.years }), i =
|
|
7809
|
+
const o = Ve(r, { years: n.years }), i = dm(s, o);
|
|
7646
7810
|
i && (n.months = i);
|
|
7647
|
-
const l = Ve(o, { months: n.months }), c =
|
|
7811
|
+
const l = Ve(o, { months: n.months }), c = am(s, l);
|
|
7648
7812
|
c && (n.days = c);
|
|
7649
|
-
const u = Ve(l, { days: n.days }), p =
|
|
7813
|
+
const u = Ve(l, { days: n.days }), p = om(s, u);
|
|
7650
7814
|
p && (n.hours = p);
|
|
7651
|
-
const m = Ve(u, { hours: n.hours }), d =
|
|
7815
|
+
const m = Ve(u, { hours: n.hours }), d = im(s, m);
|
|
7652
7816
|
d && (n.minutes = d);
|
|
7653
|
-
const g = Ve(m, { minutes: n.minutes }), h =
|
|
7817
|
+
const g = Ve(m, { minutes: n.minutes }), h = fm(s, g);
|
|
7654
7818
|
return h && (n.seconds = h), n;
|
|
7655
7819
|
}
|
|
7656
|
-
function
|
|
7657
|
-
return +
|
|
7820
|
+
function hm(t, e) {
|
|
7821
|
+
return +Ot(t) > +Ot(e);
|
|
7658
7822
|
}
|
|
7659
|
-
const
|
|
7823
|
+
const bm = (t) => {
|
|
7660
7824
|
const e = t.getTime(), r = tt(() => {
|
|
7661
7825
|
const i = /* @__PURE__ */ new Date(), l = new Date(e);
|
|
7662
|
-
if (
|
|
7826
|
+
if (hm(i, l))
|
|
7663
7827
|
return { days: 0, hours: 0, minutes: 0, seconds: 0, isFinished: !0 };
|
|
7664
|
-
const c =
|
|
7828
|
+
const c = gm({
|
|
7665
7829
|
start: i,
|
|
7666
7830
|
end: l
|
|
7667
7831
|
});
|
|
@@ -7697,7 +7861,7 @@ const hm = (t) => {
|
|
|
7697
7861
|
size: "md"
|
|
7698
7862
|
}
|
|
7699
7863
|
}
|
|
7700
|
-
),
|
|
7864
|
+
), vm = Z(
|
|
7701
7865
|
"rst:font-mono rst:bg-clip-text rst:transition-all",
|
|
7702
7866
|
{
|
|
7703
7867
|
variants: {
|
|
@@ -7719,7 +7883,7 @@ const hm = (t) => {
|
|
|
7719
7883
|
size: "md"
|
|
7720
7884
|
}
|
|
7721
7885
|
}
|
|
7722
|
-
),
|
|
7886
|
+
), xm = Z(
|
|
7723
7887
|
"rst:uppercase rst:tracking-widest rst:mt-1 rst:transition-colors rst:text-gray-500 rst:dark:text-gray-400",
|
|
7724
7888
|
{
|
|
7725
7889
|
variants: {
|
|
@@ -7736,9 +7900,9 @@ const hm = (t) => {
|
|
|
7736
7900
|
}
|
|
7737
7901
|
}
|
|
7738
7902
|
), yr = ({ value: t, label: e, size: r, variant: s }) => /* @__PURE__ */ f.jsxs("div", { className: "rst:flex rst:flex-col rst:items-center", children: [
|
|
7739
|
-
/* @__PURE__ */ f.jsx("span", { className: C(
|
|
7740
|
-
/* @__PURE__ */ f.jsx("span", { className: C(
|
|
7741
|
-
] }),
|
|
7903
|
+
/* @__PURE__ */ f.jsx("span", { className: C(vm({ size: r, variant: s })), children: String(t).padStart(2, "0") }),
|
|
7904
|
+
/* @__PURE__ */ f.jsx("span", { className: C(xm({ size: r })), children: e })
|
|
7905
|
+
] }), ym = S.forwardRef(
|
|
7742
7906
|
({
|
|
7743
7907
|
targetDate: t,
|
|
7744
7908
|
title: e,
|
|
@@ -7748,7 +7912,7 @@ const hm = (t) => {
|
|
|
7748
7912
|
completionText: a,
|
|
7749
7913
|
...o
|
|
7750
7914
|
}, i) => {
|
|
7751
|
-
const { days: l, hours: c, minutes: u, seconds: p, isFinished: m } =
|
|
7915
|
+
const { days: l, hours: c, minutes: u, seconds: p, isFinished: m } = bm(t);
|
|
7752
7916
|
return m ? a ? /* @__PURE__ */ f.jsx(
|
|
7753
7917
|
"div",
|
|
7754
7918
|
{
|
|
@@ -7814,8 +7978,8 @@ const hm = (t) => {
|
|
|
7814
7978
|
);
|
|
7815
7979
|
}
|
|
7816
7980
|
);
|
|
7817
|
-
|
|
7818
|
-
const
|
|
7981
|
+
ym.displayName = "Countdown";
|
|
7982
|
+
const wm = Z(
|
|
7819
7983
|
"rst:relative rst:w-full rst:transform rst:overflow-hidden rst:rounded-2xl rst:p-6 rst:text-left rst:align-middle rst:shadow-xl rst:transition-all rst:border",
|
|
7820
7984
|
{
|
|
7821
7985
|
variants: {
|
|
@@ -7847,9 +8011,9 @@ const ym = Z(
|
|
|
7847
8011
|
status: "default"
|
|
7848
8012
|
}
|
|
7849
8013
|
}
|
|
7850
|
-
),
|
|
8014
|
+
), km = Z("rst:text-xl rst:font-bold rst:leading-6 rst:text-inherit"), Sm = Z("rst:mt-1 rst:text-sm rst:text-inherit rst:opacity-75"), Em = Z(
|
|
7851
8015
|
"rst:inline-flex rst:rounded-md rst:bg-transparent rst:text-inherit rst:opacity-50 rst:hover:opacity-100 rst:focus:outline-hidden rst:focus-visible:ring-2 rst:focus-visible:ring-ring rst:focus-visible:ring-offset-2 rst:ring-offset-background rst:transition-opacity"
|
|
7852
|
-
),
|
|
8016
|
+
), Xm = ({
|
|
7853
8017
|
isOpen: t,
|
|
7854
8018
|
onClose: e,
|
|
7855
8019
|
title: r,
|
|
@@ -7895,21 +8059,21 @@ const ym = Z(
|
|
|
7895
8059
|
Bo,
|
|
7896
8060
|
{
|
|
7897
8061
|
className: C(
|
|
7898
|
-
|
|
8062
|
+
wm({ size: n, variant: a, status: o }),
|
|
7899
8063
|
l
|
|
7900
8064
|
),
|
|
7901
8065
|
children: [
|
|
7902
8066
|
/* @__PURE__ */ f.jsxs("div", { className: "rst:flex rst:items-start rst:justify-between", children: [
|
|
7903
8067
|
/* @__PURE__ */ f.jsxs("div", { children: [
|
|
7904
|
-
/* @__PURE__ */ f.jsx(Ho, { as: "h2", className: C(
|
|
7905
|
-
s && /* @__PURE__ */ f.jsx("p", { className: C(
|
|
8068
|
+
/* @__PURE__ */ f.jsx(Ho, { as: "h2", className: C(km()), children: r }),
|
|
8069
|
+
s && /* @__PURE__ */ f.jsx("p", { className: C(Sm()), children: s })
|
|
7906
8070
|
] }),
|
|
7907
8071
|
/* @__PURE__ */ f.jsx("div", { className: "rst:ml-4 rst:flex rst:shrink-0", children: /* @__PURE__ */ f.jsx(
|
|
7908
8072
|
"button",
|
|
7909
8073
|
{
|
|
7910
8074
|
type: "button",
|
|
7911
8075
|
onClick: e,
|
|
7912
|
-
className: C(
|
|
8076
|
+
className: C(Em()),
|
|
7913
8077
|
"aria-label": "Close dialog",
|
|
7914
8078
|
children: /* @__PURE__ */ f.jsx(mt, { icon: Ge, className: "rst:h-5 rst:w-5" })
|
|
7915
8079
|
}
|
|
@@ -7921,7 +8085,7 @@ const ym = Z(
|
|
|
7921
8085
|
)
|
|
7922
8086
|
}
|
|
7923
8087
|
) }) })
|
|
7924
|
-
] }) }),
|
|
8088
|
+
] }) }), Nm = Z(
|
|
7925
8089
|
"rst:font-ui rst:w-full rst:py-6 rst:mt-auto rst:transition-colors rst:duration-200",
|
|
7926
8090
|
{
|
|
7927
8091
|
variants: {
|
|
@@ -7941,14 +8105,14 @@ const ym = Z(
|
|
|
7941
8105
|
variant: "default"
|
|
7942
8106
|
}
|
|
7943
8107
|
}
|
|
7944
|
-
),
|
|
8108
|
+
), Om = S.forwardRef(
|
|
7945
8109
|
({ className: t, variant: e, companyName: r = "Ball Collaborative", links: s, routerElement: n, ...a }, o) => {
|
|
7946
8110
|
const i = (/* @__PURE__ */ new Date()).getFullYear(), l = n ?? "a";
|
|
7947
8111
|
return /* @__PURE__ */ f.jsx(
|
|
7948
8112
|
"footer",
|
|
7949
8113
|
{
|
|
7950
8114
|
ref: o,
|
|
7951
|
-
className: C(
|
|
8115
|
+
className: C(Nm({ variant: e }), t),
|
|
7952
8116
|
...a,
|
|
7953
8117
|
children: /* @__PURE__ */ f.jsxs("div", { className: "rst:container rst:mx-auto rst:px-4 rst:flex rst:flex-col rst:items-center rst:gap-2", children: [
|
|
7954
8118
|
s && s.length > 0 && /* @__PURE__ */ f.jsx("nav", { "aria-label": "Footer navigation", className: "rst:flex rst:flex-wrap rst:justify-center rst:gap-x-5 rst:gap-y-1", children: s.map((c) => /* @__PURE__ */ f.jsx(
|
|
@@ -7973,7 +8137,7 @@ const ym = Z(
|
|
|
7973
8137
|
);
|
|
7974
8138
|
}
|
|
7975
8139
|
);
|
|
7976
|
-
|
|
8140
|
+
Om.displayName = "Footer";
|
|
7977
8141
|
const Pm = Z(
|
|
7978
8142
|
"rst:font-ui rst:w-full rst:z-30 rst:border-b rst:transition-colors rst:duration-200",
|
|
7979
8143
|
{
|
|
@@ -8005,7 +8169,7 @@ const Pm = Z(
|
|
|
8005
8169
|
}
|
|
8006
8170
|
}
|
|
8007
8171
|
), Sa = (t, e) => typeof t == "function" ? t({ close: e }) : t;
|
|
8008
|
-
function
|
|
8172
|
+
function Cm(t) {
|
|
8009
8173
|
return S.useSyncExternalStore(
|
|
8010
8174
|
(e) => {
|
|
8011
8175
|
if (!t || typeof document > "u") return () => {
|
|
@@ -8020,7 +8184,7 @@ function Om(t) {
|
|
|
8020
8184
|
() => !1
|
|
8021
8185
|
);
|
|
8022
8186
|
}
|
|
8023
|
-
function
|
|
8187
|
+
function Tm({ close: t }) {
|
|
8024
8188
|
return st(() => {
|
|
8025
8189
|
const e = (r) => {
|
|
8026
8190
|
const s = document.querySelector("[data-roster-mobile-panel]"), n = document.querySelector("[data-roster-hamburger]"), a = r.target;
|
|
@@ -8029,7 +8193,7 @@ function Cm({ close: t }) {
|
|
|
8029
8193
|
return document.addEventListener("pointerdown", e, { capture: !0 }), () => document.removeEventListener("pointerdown", e, { capture: !0 });
|
|
8030
8194
|
}, [t]), null;
|
|
8031
8195
|
}
|
|
8032
|
-
function
|
|
8196
|
+
function jm({
|
|
8033
8197
|
activePath: t,
|
|
8034
8198
|
close: e
|
|
8035
8199
|
}) {
|
|
@@ -8038,7 +8202,7 @@ function Tm({
|
|
|
8038
8202
|
r.current !== t && (r.current = t, e());
|
|
8039
8203
|
}, [t, e]), null;
|
|
8040
8204
|
}
|
|
8041
|
-
const
|
|
8205
|
+
const Qm = ({
|
|
8042
8206
|
logoSrc: t,
|
|
8043
8207
|
logoSize: e = "2rem",
|
|
8044
8208
|
logoClassName: r,
|
|
@@ -8063,7 +8227,7 @@ const Xm = ({
|
|
|
8063
8227
|
notificationFill: E = "solid",
|
|
8064
8228
|
...T
|
|
8065
8229
|
}) => {
|
|
8066
|
-
const
|
|
8230
|
+
const O = (i?.notificationCount || 0) > 0, M = typeof e == "number" ? `${e}px` : e, z = { width: M, height: M }, N = Cm(x === "auto"), L = (x === "auto" ? N ? "dark" : "light" : x ?? (v === "white" || v === "default" ? "light" : "dark")) === "dark", _ = v === "slate" || v === "primary" || v === "default" && L || v === "white" && L || v === "transparent" && L, R = {
|
|
8067
8231
|
brand: _ ? "rst:text-white rst:dark:text-white rst:hover:text-gray-200 rst:dark:hover:text-gray-200" : "rst:text-gray-900 rst:dark:text-gray-900 rst:hover:text-gray-600 rst:dark:hover:text-gray-600",
|
|
8068
8232
|
linkBase: _ ? "rst:text-gray-300 rst:dark:text-gray-300 rst:hover:text-white rst:dark:hover:text-white" : "rst:text-gray-600 rst:dark:text-gray-600 rst:hover:text-gray-900 rst:dark:hover:text-gray-900",
|
|
8069
8233
|
linkActive: _ ? "rst:text-primary-400 rst:dark:text-primary-400 rst:font-semibold rst:hover:text-primary-300 rst:dark:hover:text-primary-300" : "rst:text-primary-600 rst:dark:text-primary-600 rst:font-semibold rst:hover:text-primary-700 rst:dark:hover:text-primary-700",
|
|
@@ -8076,7 +8240,7 @@ const Xm = ({
|
|
|
8076
8240
|
className: C("rst:z-50", Pm({ variant: v, position: w }), b),
|
|
8077
8241
|
...T,
|
|
8078
8242
|
children: ({ open: D, close: F }) => {
|
|
8079
|
-
const U = Sa(m, F),
|
|
8243
|
+
const U = Sa(m, F), P = Sa(g, F);
|
|
8080
8244
|
return /* @__PURE__ */ f.jsxs(f.Fragment, { children: [
|
|
8081
8245
|
/* @__PURE__ */ f.jsxs("div", { className: "rst:container rst:mx-auto rst:flex rst:items-center rst:justify-between rst:px-4 rst:h-16", children: [
|
|
8082
8246
|
/* @__PURE__ */ f.jsxs(
|
|
@@ -8128,7 +8292,7 @@ const Xm = ({
|
|
|
8128
8292
|
j.path
|
|
8129
8293
|
);
|
|
8130
8294
|
}) }),
|
|
8131
|
-
|
|
8295
|
+
P,
|
|
8132
8296
|
U ?? (i ? /* @__PURE__ */ f.jsxs(gf, { as: "div", className: "rst:relative rst:ml-2", children: [
|
|
8133
8297
|
/* @__PURE__ */ f.jsxs(ei, { className: "rst:relative rst:flex rst:rounded-full rst:text-sm rst:focus-visible:outline-hidden rst:focus-visible:ring-2 rst:focus-visible:ring-ring rst:focus-visible:ring-offset-2 rst:ring-offset-background", children: [
|
|
8134
8298
|
/* @__PURE__ */ f.jsx("span", { className: "rst:sr-only", children: "Open user menu" }),
|
|
@@ -8142,7 +8306,7 @@ const Xm = ({
|
|
|
8142
8306
|
colorScheme: i.avatarColor ?? "primary"
|
|
8143
8307
|
}
|
|
8144
8308
|
),
|
|
8145
|
-
|
|
8309
|
+
O && /* @__PURE__ */ f.jsx("div", { className: "rst:absolute rst:-top-1 rst:-right-2", children: /* @__PURE__ */ f.jsx(
|
|
8146
8310
|
ks,
|
|
8147
8311
|
{
|
|
8148
8312
|
fill: E,
|
|
@@ -8165,7 +8329,7 @@ const Xm = ({
|
|
|
8165
8329
|
leaveTo: "rst:transform rst:opacity-0 rst:scale-95",
|
|
8166
8330
|
children: /* @__PURE__ */ f.jsxs(ri, { className: "rst:absolute rst:right-0 rst:z-50 rst:mt-2 rst:w-48 rst:origin-top-right rst:rounded-md rst:bg-white rst:dark:bg-gray-800 rst:py-1 rst:shadow-lg rst:ring-1 rst:ring-black/5 rst:dark:ring-white/10 rst:focus:outline-hidden rst:divide-y rst:divide-gray-100 rst:dark:divide-gray-700", children: [
|
|
8167
8331
|
/* @__PURE__ */ f.jsxs("div", { className: "rst:py-1", children: [
|
|
8168
|
-
|
|
8332
|
+
O && u && /* @__PURE__ */ f.jsx(ze, { children: ({ focus: j }) => /* @__PURE__ */ f.jsxs(
|
|
8169
8333
|
Ut,
|
|
8170
8334
|
{
|
|
8171
8335
|
variant: "ghost",
|
|
@@ -8303,14 +8467,14 @@ const Xm = ({
|
|
|
8303
8467
|
"aria-hidden": "true"
|
|
8304
8468
|
}
|
|
8305
8469
|
),
|
|
8306
|
-
|
|
8470
|
+
O && /* @__PURE__ */ f.jsx("span", { className: "rst:absolute rst:top-0 rst:right-0 rst:block rst:h-2.5 rst:w-2.5 rst:rounded-full rst:bg-error-500 rst:ring-2 rst:ring-transparent rst:transform rst:translate-x-1/4 rst:-translate-y-1/4" })
|
|
8307
8471
|
] })
|
|
8308
8472
|
]
|
|
8309
8473
|
}
|
|
8310
8474
|
) })
|
|
8311
8475
|
] }),
|
|
8312
|
-
D && /* @__PURE__ */ f.jsx(
|
|
8313
|
-
D && /* @__PURE__ */ f.jsx(
|
|
8476
|
+
D && /* @__PURE__ */ f.jsx(Tm, { close: F }),
|
|
8477
|
+
D && /* @__PURE__ */ f.jsx(jm, { activePath: a, close: F }),
|
|
8314
8478
|
/* @__PURE__ */ f.jsx(
|
|
8315
8479
|
je,
|
|
8316
8480
|
{
|
|
@@ -8354,7 +8518,7 @@ const Xm = ({
|
|
|
8354
8518
|
] }) })
|
|
8355
8519
|
] }),
|
|
8356
8520
|
/* @__PURE__ */ f.jsxs("div", { className: "rst:mt-6", children: [
|
|
8357
|
-
|
|
8521
|
+
P && /* @__PURE__ */ f.jsx("div", { className: "rst:mb-4", children: P }),
|
|
8358
8522
|
/* @__PURE__ */ f.jsxs("nav", { className: "rst:grid rst:gap-y-4", children: [
|
|
8359
8523
|
n.map((j) => {
|
|
8360
8524
|
const H = a === j.path;
|
|
@@ -8440,7 +8604,7 @@ const Xm = ({
|
|
|
8440
8604
|
children: "Log In"
|
|
8441
8605
|
}
|
|
8442
8606
|
) : /* @__PURE__ */ f.jsxs(f.Fragment, { children: [
|
|
8443
|
-
|
|
8607
|
+
O && u && /* @__PURE__ */ f.jsx(
|
|
8444
8608
|
Ut,
|
|
8445
8609
|
{
|
|
8446
8610
|
variant: "ghost",
|
|
@@ -8524,13 +8688,13 @@ const Xm = ({
|
|
|
8524
8688
|
}
|
|
8525
8689
|
}
|
|
8526
8690
|
);
|
|
8527
|
-
},
|
|
8691
|
+
}, Rm = {
|
|
8528
8692
|
timeout: 1500,
|
|
8529
8693
|
ignoreCase: !0,
|
|
8530
8694
|
preventDefault: !1,
|
|
8531
8695
|
enabled: !0,
|
|
8532
8696
|
ignoreWhenTyping: !0
|
|
8533
|
-
},
|
|
8697
|
+
}, Zm = [
|
|
8534
8698
|
"ArrowUp",
|
|
8535
8699
|
"ArrowUp",
|
|
8536
8700
|
"ArrowDown",
|
|
@@ -8543,15 +8707,15 @@ const Xm = ({
|
|
|
8543
8707
|
"a",
|
|
8544
8708
|
"Enter"
|
|
8545
8709
|
];
|
|
8546
|
-
function
|
|
8710
|
+
function $m(t) {
|
|
8547
8711
|
if (!(t instanceof HTMLElement)) return !1;
|
|
8548
8712
|
if (t.isContentEditable) return !0;
|
|
8549
8713
|
const e = t.getAttribute("contenteditable");
|
|
8550
8714
|
return e !== null && e !== "false" ? !0 : ["INPUT", "TEXTAREA", "SELECT"].includes(t.tagName);
|
|
8551
8715
|
}
|
|
8552
|
-
function
|
|
8716
|
+
function Jm(t, e, r = {}) {
|
|
8553
8717
|
const { timeout: s, ignoreCase: n, preventDefault: a, enabled: o, ignoreWhenTyping: i } = {
|
|
8554
|
-
...
|
|
8718
|
+
...Rm,
|
|
8555
8719
|
...r
|
|
8556
8720
|
}, l = V(0), c = V(0), u = V(e);
|
|
8557
8721
|
st(() => {
|
|
@@ -8560,7 +8724,7 @@ function Zm(t, e, r = {}) {
|
|
|
8560
8724
|
if (!o || t.length === 0) return;
|
|
8561
8725
|
const p = (g) => n ? g.toLowerCase() : g, m = t.map(p);
|
|
8562
8726
|
function d(g) {
|
|
8563
|
-
if (i &&
|
|
8727
|
+
if (i && $m(g.target)) return;
|
|
8564
8728
|
const h = Date.now();
|
|
8565
8729
|
s > 0 && l.current > 0 && h - c.current > s && (l.current = 0), c.current = h;
|
|
8566
8730
|
const b = p(g.key);
|
|
@@ -8574,68 +8738,68 @@ function Zm(t, e, r = {}) {
|
|
|
8574
8738
|
}, [t, s, n, a, o, i]);
|
|
8575
8739
|
}
|
|
8576
8740
|
export {
|
|
8577
|
-
|
|
8578
|
-
|
|
8579
|
-
|
|
8741
|
+
Um as Accordion,
|
|
8742
|
+
Xp as ActionBar,
|
|
8743
|
+
Vp as Alert,
|
|
8580
8744
|
fn as Avatar,
|
|
8581
|
-
|
|
8745
|
+
Vm as AvatarStrip,
|
|
8582
8746
|
ks as Badge,
|
|
8583
|
-
|
|
8747
|
+
Ym as Breadcrumbs,
|
|
8584
8748
|
Ut as Button,
|
|
8585
|
-
|
|
8749
|
+
Gm as CallToAction,
|
|
8586
8750
|
Zf as Card,
|
|
8587
8751
|
t0 as Checkbox,
|
|
8588
|
-
|
|
8589
|
-
|
|
8590
|
-
|
|
8591
|
-
|
|
8752
|
+
zm as CollapsibleSection,
|
|
8753
|
+
ym as Countdown,
|
|
8754
|
+
Hp as DescriptionList,
|
|
8755
|
+
Xm as Dialog,
|
|
8592
8756
|
s0 as Disclosure,
|
|
8593
|
-
|
|
8594
|
-
|
|
8757
|
+
Km as EmptyState,
|
|
8758
|
+
qm as ErrorState,
|
|
8595
8759
|
jr as Eyebrow,
|
|
8596
|
-
|
|
8760
|
+
Om as Footer,
|
|
8597
8761
|
d0 as InlineCode,
|
|
8598
8762
|
ii as Input,
|
|
8599
|
-
|
|
8763
|
+
Zm as KONAMI_CODE,
|
|
8600
8764
|
f0 as LabeledDivider,
|
|
8601
8765
|
Ee as Link,
|
|
8602
|
-
|
|
8603
|
-
|
|
8604
|
-
|
|
8766
|
+
Bm as LiquidTabs,
|
|
8767
|
+
Kp as MatchupCard,
|
|
8768
|
+
Qm as Navbar,
|
|
8605
8769
|
o0 as PasswordInput,
|
|
8606
8770
|
l0 as Pill,
|
|
8607
|
-
|
|
8608
|
-
|
|
8609
|
-
|
|
8610
|
-
|
|
8771
|
+
Wp as Pullquote,
|
|
8772
|
+
Wm as SegmentBar,
|
|
8773
|
+
_m as Select,
|
|
8774
|
+
rg as Spinner,
|
|
8611
8775
|
m0 as Stat,
|
|
8612
8776
|
da as Switch,
|
|
8613
|
-
|
|
8614
|
-
|
|
8615
|
-
|
|
8616
|
-
|
|
8617
|
-
|
|
8618
|
-
|
|
8619
|
-
|
|
8620
|
-
|
|
8621
|
-
|
|
8777
|
+
sg as Table,
|
|
8778
|
+
ng as TableBody,
|
|
8779
|
+
ag as TableCaption,
|
|
8780
|
+
og as TableCell,
|
|
8781
|
+
ig as TableFooter,
|
|
8782
|
+
lg as TableHead,
|
|
8783
|
+
cg as TableHeader,
|
|
8784
|
+
ug as TableRow,
|
|
8785
|
+
N0 as Textarea,
|
|
8622
8786
|
x0 as ThemeToggle,
|
|
8623
|
-
|
|
8624
|
-
|
|
8625
|
-
|
|
8787
|
+
Hm as Tooltip,
|
|
8788
|
+
qp as actionBarVariants,
|
|
8789
|
+
Lp as alertVariants,
|
|
8626
8790
|
qf as avatarVariants,
|
|
8627
8791
|
Xf as badgeVariants,
|
|
8628
8792
|
ga as breadcrumbVariants,
|
|
8629
|
-
|
|
8793
|
+
dg as buttonVariants,
|
|
8630
8794
|
Qf as cardVariants,
|
|
8631
8795
|
Jf as checkboxVariants,
|
|
8632
8796
|
C as cn,
|
|
8633
|
-
|
|
8634
|
-
|
|
8797
|
+
Up as ctaVariants,
|
|
8798
|
+
Bp as descriptionListVariants,
|
|
8635
8799
|
r0 as disclosureContentVariants,
|
|
8636
8800
|
e0 as disclosureTriggerVariants,
|
|
8637
|
-
|
|
8638
|
-
|
|
8801
|
+
Yp as emptyStateVariants,
|
|
8802
|
+
Gp as errorStateVariants,
|
|
8639
8803
|
c0 as eyebrowVariants,
|
|
8640
8804
|
ca as iconVariants,
|
|
8641
8805
|
u0 as inlineCodeVariants,
|
|
@@ -8644,18 +8808,19 @@ export {
|
|
|
8644
8808
|
Pm as navbarVariants,
|
|
8645
8809
|
ua as pillDotVariants,
|
|
8646
8810
|
i0 as pillVariants,
|
|
8647
|
-
|
|
8811
|
+
zp as pullquoteVariants,
|
|
8812
|
+
w0 as selectOptionVariants,
|
|
8648
8813
|
y0 as selectTriggerVariants,
|
|
8649
8814
|
p0 as statValueVariants,
|
|
8650
|
-
|
|
8651
|
-
|
|
8652
|
-
|
|
8653
|
-
|
|
8654
|
-
|
|
8655
|
-
|
|
8656
|
-
|
|
8657
|
-
|
|
8658
|
-
|
|
8659
|
-
|
|
8660
|
-
|
|
8815
|
+
S0 as switchThumbVariants,
|
|
8816
|
+
k0 as switchTrackVariants,
|
|
8817
|
+
fg as tableCellVariants,
|
|
8818
|
+
pg as tableHeadVariants,
|
|
8819
|
+
mg as tableHeaderVariants,
|
|
8820
|
+
gg as tableRowVariants,
|
|
8821
|
+
hg as tableVariants,
|
|
8822
|
+
bg as tableWrapperVariants,
|
|
8823
|
+
E0 as textareaVariants,
|
|
8824
|
+
bm as useCountdown,
|
|
8825
|
+
Jm as useKeySequence
|
|
8661
8826
|
};
|