@danxbot/ui 20.22.0 → 20.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/confidence.css +19 -0
- package/dist/index.js +255 -254
- package/dist/index.js.map +1 -1
- package/dist/styles.css +1 -1
- package/dist/types/components/focus-web/types.d.ts +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -512,7 +512,7 @@ const HP = (e, t) => {
|
|
|
512
512
|
// For example, `hsl(0 0% 0%)` would be classified as a length without this check.
|
|
513
513
|
// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
|
|
514
514
|
pO.test(e) && !hO.test(e)
|
|
515
|
-
), am = () => !1, xO = (e) => mO.test(e), vO = (e) => gO.test(e), yO = (e) => !je(e) && !We(e), wO = (e) => e.startsWith("@container") && (e[10] === "/" && e[11] !== void 0 || e[11] === "s" && e[16] !== void 0 && e.startsWith("-size/", 10) || e[11] === "n" && e[18] !== void 0 && e.startsWith("-normal/", 10)), CO = (e) =>
|
|
515
|
+
), am = () => !1, xO = (e) => mO.test(e), vO = (e) => gO.test(e), yO = (e) => !je(e) && !We(e), wO = (e) => e.startsWith("@container") && (e[10] === "/" && e[11] !== void 0 || e[11] === "s" && e[16] !== void 0 && e.startsWith("-size/", 10) || e[11] === "n" && e[18] !== void 0 && e.startsWith("-normal/", 10)), CO = (e) => $o(e, rC, am), je = (e) => Q1.test(e), qo = (e) => $o(e, oC, bO), Ev = (e) => $o(e, TO, ht), EO = (e) => $o(e, iC, eC), SO = (e) => $o(e, sC, am), Sv = (e) => $o(e, tC, am), kO = (e) => $o(e, nC, vO), Dl = (e) => $o(e, aC, xO), We = (e) => J1.test(e), Vi = (e) => ws(e, oC), NO = (e) => ws(e, sC), kv = (e) => ws(e, tC), RO = (e) => ws(e, rC), IO = (e) => ws(e, nC), _l = (e) => ws(e, aC, !0), MO = (e) => ws(e, iC, !0), $o = (e, t, n) => {
|
|
516
516
|
const r = Q1.exec(e);
|
|
517
517
|
return r ? r[1] ? t(r[1]) : n(r[2]) : !1;
|
|
518
518
|
}, ws = (e, t, n = !1) => {
|
|
@@ -545,7 +545,7 @@ const HP = (e, t) => {
|
|
|
545
545
|
repeat: ["", "x", "y", "space", "round"]
|
|
546
546
|
}], U = () => ["auto", "cover", "contain", RO, CO, {
|
|
547
547
|
size: [We, je]
|
|
548
|
-
}], G = () => [Mf, Vi,
|
|
548
|
+
}], G = () => [Mf, Vi, qo], Y = () => [
|
|
549
549
|
// Deprecated since Tailwind CSS v4.0.0
|
|
550
550
|
"",
|
|
551
551
|
"none",
|
|
@@ -553,7 +553,7 @@ const HP = (e, t) => {
|
|
|
553
553
|
l,
|
|
554
554
|
We,
|
|
555
555
|
je
|
|
556
|
-
], q = () => ["", ht, Vi,
|
|
556
|
+
], q = () => ["", ht, Vi, qo], X = () => ["solid", "dashed", "dotted", "double"], W = () => ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"], j = () => [ht, Mf, kv, Sv], te = () => [
|
|
557
557
|
// Deprecated since Tailwind CSS v4.0.0
|
|
558
558
|
"",
|
|
559
559
|
"none",
|
|
@@ -1361,7 +1361,7 @@ const HP = (e, t) => {
|
|
|
1361
1361
|
* @see https://tailwindcss.com/docs/font-size
|
|
1362
1362
|
*/
|
|
1363
1363
|
"font-size": [{
|
|
1364
|
-
text: ["base", n, Vi,
|
|
1364
|
+
text: ["base", n, Vi, qo]
|
|
1365
1365
|
}],
|
|
1366
1366
|
/**
|
|
1367
1367
|
* Font Smoothing
|
|
@@ -1516,7 +1516,7 @@ const HP = (e, t) => {
|
|
|
1516
1516
|
* @see https://tailwindcss.com/docs/text-decoration-thickness
|
|
1517
1517
|
*/
|
|
1518
1518
|
"text-decoration-thickness": [{
|
|
1519
|
-
decoration: [ht, "from-font", "auto", We,
|
|
1519
|
+
decoration: [ht, "from-font", "auto", We, qo]
|
|
1520
1520
|
}],
|
|
1521
1521
|
/**
|
|
1522
1522
|
* Text Decoration Color
|
|
@@ -2038,7 +2038,7 @@ const HP = (e, t) => {
|
|
|
2038
2038
|
* @see https://tailwindcss.com/docs/outline-width
|
|
2039
2039
|
*/
|
|
2040
2040
|
"outline-w": [{
|
|
2041
|
-
outline: ["", ht, Vi,
|
|
2041
|
+
outline: ["", ht, Vi, qo]
|
|
2042
2042
|
}],
|
|
2043
2043
|
/**
|
|
2044
2044
|
* Outline Color
|
|
@@ -2113,7 +2113,7 @@ const HP = (e, t) => {
|
|
|
2113
2113
|
* @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
|
|
2114
2114
|
*/
|
|
2115
2115
|
"ring-offset-w": [{
|
|
2116
|
-
"ring-offset": [ht,
|
|
2116
|
+
"ring-offset": [ht, qo]
|
|
2117
2117
|
}],
|
|
2118
2118
|
/**
|
|
2119
2119
|
* Ring Offset Color
|
|
@@ -3126,7 +3126,7 @@ const HP = (e, t) => {
|
|
|
3126
3126
|
* @see https://tailwindcss.com/docs/stroke-width
|
|
3127
3127
|
*/
|
|
3128
3128
|
"stroke-w": [{
|
|
3129
|
-
stroke: [ht, Vi,
|
|
3129
|
+
stroke: [ht, Vi, qo, Ev]
|
|
3130
3130
|
}],
|
|
3131
3131
|
/**
|
|
3132
3132
|
* Stroke
|
|
@@ -4345,7 +4345,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
4345
4345
|
// For example, `hsl(0 0% 0%)` would be classified as a length without this check.
|
|
4346
4346
|
// I could also use lookbehind assertion in `lengthUnitRegex` but that isn't supported widely enough.
|
|
4347
4347
|
aD.test(e) && !lD.test(e)
|
|
4348
|
-
), gm = () => !1, hD = (e) => cD.test(e), mD = (e) => uD.test(e), gD = (e) => !Ge(e) && !qe(e), bD = (e) => e.startsWith("@container") && (e[10] === "/" && e[11] !== void 0 || e[11] === "s" && e[16] !== void 0 && e.startsWith("-size/", 10) || e[11] === "n" && e[18] !== void 0 && e.startsWith("-normal/", 10)), xD = (e) =>
|
|
4348
|
+
), gm = () => !1, hD = (e) => cD.test(e), mD = (e) => uD.test(e), gD = (e) => !Ge(e) && !qe(e), bD = (e) => e.startsWith("@container") && (e[10] === "/" && e[11] !== void 0 || e[11] === "s" && e[16] !== void 0 && e.startsWith("-size/", 10) || e[11] === "n" && e[18] !== void 0 && e.startsWith("-normal/", 10)), xD = (e) => Fo(e, DC, gm), Ge = (e) => IC.test(e), Ko = (e) => Fo(e, _C, pD), Dv = (e) => Fo(e, ND, mt), vD = (e) => Fo(e, FC, PC), yD = (e) => Fo(e, $C, gm), _v = (e) => Fo(e, OC, gm), wD = (e) => Fo(e, AC, mD), Fl = (e) => Fo(e, LC, hD), qe = (e) => MC.test(e), zi = (e) => Cs(e, _C), CD = (e) => Cs(e, $C), $v = (e) => Cs(e, OC), ED = (e) => Cs(e, DC), SD = (e) => Cs(e, AC), Ll = (e) => Cs(e, LC, !0), kD = (e) => Cs(e, FC, !0), Fo = (e, t, n) => {
|
|
4349
4349
|
const r = IC.exec(e);
|
|
4350
4350
|
return r ? r[1] ? t(r[1]) : n(r[2]) : !1;
|
|
4351
4351
|
}, Cs = (e, t, n = !1) => {
|
|
@@ -4436,7 +4436,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
4436
4436
|
ED,
|
|
4437
4437
|
xD,
|
|
4438
4438
|
{ size: [qe, Ge] }
|
|
4439
|
-
], G = () => [Pf, zi,
|
|
4439
|
+
], G = () => [Pf, zi, Ko], Y = () => [
|
|
4440
4440
|
// Deprecated since Tailwind CSS v4.0.0
|
|
4441
4441
|
"",
|
|
4442
4442
|
"none",
|
|
@@ -4444,7 +4444,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
4444
4444
|
l,
|
|
4445
4445
|
qe,
|
|
4446
4446
|
Ge
|
|
4447
|
-
], q = () => ["", mt, zi,
|
|
4447
|
+
], q = () => ["", mt, zi, Ko], X = () => ["solid", "dashed", "dotted", "double"], W = () => [
|
|
4448
4448
|
"normal",
|
|
4449
4449
|
"multiply",
|
|
4450
4450
|
"screen",
|
|
@@ -5136,7 +5136,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
5136
5136
|
* Font Size
|
|
5137
5137
|
* @see https://tailwindcss.com/docs/font-size
|
|
5138
5138
|
*/
|
|
5139
|
-
"font-size": [{ text: ["base", n, zi,
|
|
5139
|
+
"font-size": [{ text: ["base", n, zi, Ko] }],
|
|
5140
5140
|
/**
|
|
5141
5141
|
* Font Smoothing
|
|
5142
5142
|
* @see https://tailwindcss.com/docs/font-smoothing
|
|
@@ -5289,7 +5289,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
5289
5289
|
*/
|
|
5290
5290
|
"text-decoration-thickness": [
|
|
5291
5291
|
{
|
|
5292
|
-
decoration: [mt, "from-font", "auto", qe,
|
|
5292
|
+
decoration: [mt, "from-font", "auto", qe, Ko]
|
|
5293
5293
|
}
|
|
5294
5294
|
],
|
|
5295
5295
|
/**
|
|
@@ -5704,7 +5704,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
5704
5704
|
* Outline Width
|
|
5705
5705
|
* @see https://tailwindcss.com/docs/outline-width
|
|
5706
5706
|
*/
|
|
5707
|
-
"outline-w": [{ outline: ["", mt, zi,
|
|
5707
|
+
"outline-w": [{ outline: ["", mt, zi, Ko] }],
|
|
5708
5708
|
/**
|
|
5709
5709
|
* Outline Color
|
|
5710
5710
|
* @see https://tailwindcss.com/docs/outline-color
|
|
@@ -5771,7 +5771,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
5771
5771
|
* @deprecated since Tailwind CSS v4.0.0
|
|
5772
5772
|
* @see https://github.com/tailwindlabs/tailwindcss/blob/v4.0.0/packages/tailwindcss/src/utilities.ts#L4158
|
|
5773
5773
|
*/
|
|
5774
|
-
"ring-offset-w": [{ "ring-offset": [mt,
|
|
5774
|
+
"ring-offset-w": [{ "ring-offset": [mt, Ko] }],
|
|
5775
5775
|
/**
|
|
5776
5776
|
* Ring Offset Color
|
|
5777
5777
|
* @see https://v3.tailwindcss.com/docs/ring-offset-color
|
|
@@ -6566,7 +6566,7 @@ var Rn = uA(), dA = (e) => {
|
|
|
6566
6566
|
*/
|
|
6567
6567
|
"stroke-w": [
|
|
6568
6568
|
{
|
|
6569
|
-
stroke: [mt, zi,
|
|
6569
|
+
stroke: [mt, zi, Ko, Dv]
|
|
6570
6570
|
}
|
|
6571
6571
|
],
|
|
6572
6572
|
/**
|
|
@@ -6897,7 +6897,7 @@ function ym(e) {
|
|
|
6897
6897
|
return xm ? !1 : !Uc && e.width === 0 && e.height === 0 || Uc && e.width === 1 && e.height === 1 && e.pressure === 0 && e.detail === 0 && e.pointerType === "mouse" || // iOS VoiceOver returns 0.333• for width/height.
|
|
6898
6898
|
e.width < 1 && e.height < 1 && e.pressure === 0 && e.detail === 0 && e.pointerType === "touch";
|
|
6899
6899
|
}
|
|
6900
|
-
function
|
|
6900
|
+
function No(e, t) {
|
|
6901
6901
|
const n = ["mouse", "pen"];
|
|
6902
6902
|
return t || n.push("", void 0), n.includes(e);
|
|
6903
6903
|
}
|
|
@@ -6955,11 +6955,11 @@ function Yu(e) {
|
|
|
6955
6955
|
return !1;
|
|
6956
6956
|
}
|
|
6957
6957
|
}
|
|
6958
|
-
const YD = /transform|translate|scale|rotate|perspective|filter/, XD = /paint|layout|strict|content/,
|
|
6958
|
+
const YD = /transform|translate|scale|rotate|perspective|filter/, XD = /paint|layout|strict|content/, Yo = (e) => !!e && e !== "none";
|
|
6959
6959
|
let Af;
|
|
6960
6960
|
function Cm(e) {
|
|
6961
6961
|
const t = ut(e) ? On(e) : e;
|
|
6962
|
-
return
|
|
6962
|
+
return Yo(t.transform) || Yo(t.translate) || Yo(t.scale) || Yo(t.rotate) || Yo(t.perspective) || !Em() && (Yo(t.backdropFilter) || Yo(t.filter)) || YD.test(t.willChange || "") || XD.test(t.contain || "");
|
|
6963
6963
|
}
|
|
6964
6964
|
function ZD(e) {
|
|
6965
6965
|
let t = eo(e);
|
|
@@ -7089,9 +7089,9 @@ function Gc(e) {
|
|
|
7089
7089
|
return e ? e.hasAttribute(Qp) ? e : e.querySelector(`[${Qp}]`) || e : null;
|
|
7090
7090
|
}
|
|
7091
7091
|
function JD(e, t) {
|
|
7092
|
-
return t != null && !
|
|
7092
|
+
return t != null && !No(t) ? 0 : typeof e == "function" ? e() : e;
|
|
7093
7093
|
}
|
|
7094
|
-
function
|
|
7094
|
+
function Po(e, t, n) {
|
|
7095
7095
|
const r = JD(e, n);
|
|
7096
7096
|
return typeof r == "number" ? r : r?.[t];
|
|
7097
7097
|
}
|
|
@@ -7104,7 +7104,7 @@ function UC(e, t) {
|
|
|
7104
7104
|
function e_(e) {
|
|
7105
7105
|
return e?.includes("mouse") && e !== "mousedown";
|
|
7106
7106
|
}
|
|
7107
|
-
const Tt = "none", Lr = "trigger-press", Gt = "trigger-hover", Ws = "trigger-focus", ja = "outside-press",
|
|
7107
|
+
const Tt = "none", Lr = "trigger-press", Gt = "trigger-hover", Ws = "trigger-focus", ja = "outside-press", Ro = "item-press", Ju = "close-press", Vv = "clear-press", t_ = "chip-remove-press", zv = "track-press", n_ = "increment-press", r_ = "decrement-press", rr = "input-change", Fn = "input-clear", Bv = "input-blur", va = "input-paste", jC = "input-press", to = "focus-out", Es = "escape-key", ya = "list-navigation", Fr = "keyboard", ed = "pointer", o_ = "drag", Hv = "wheel", Uv = "scrub", km = "cancel-open", na = "sibling-open", GC = "disabled", jv = "missing", Gv = "initial", td = "imperative-action", s_ = "window-resize";
|
|
7108
7108
|
function Ie(e, t, n, r) {
|
|
7109
7109
|
let o = !1, s = !1;
|
|
7110
7110
|
const i = r ?? Ct;
|
|
@@ -7168,8 +7168,8 @@ function a_(e) {
|
|
|
7168
7168
|
return;
|
|
7169
7169
|
}
|
|
7170
7170
|
o.current = {
|
|
7171
|
-
open:
|
|
7172
|
-
close:
|
|
7171
|
+
open: Po(o.current, "open"),
|
|
7172
|
+
close: Po(n, "close")
|
|
7173
7173
|
};
|
|
7174
7174
|
}, [n, i, o, s]), /* @__PURE__ */ u(Nm.Provider, {
|
|
7175
7175
|
value: w.useMemo(() => ({
|
|
@@ -7224,7 +7224,7 @@ function l_(e, t = {
|
|
|
7224
7224
|
setIsInstantPhase: m
|
|
7225
7225
|
}, i.current = o, a.current = {
|
|
7226
7226
|
open: 0,
|
|
7227
|
-
close:
|
|
7227
|
+
close: Po(l.current, "close")
|
|
7228
7228
|
}, b !== null && b !== o ? (m(!0), x?.setIsInstantPhase(!0), x?.onOpenChange(!1, Ie(Tt))) : (m(!1), x?.setIsInstantPhase(!1));
|
|
7229
7229
|
}, [n, o, r, i, a, l, d, p]), Se(() => () => {
|
|
7230
7230
|
if (i.current === o) {
|
|
@@ -7373,7 +7373,7 @@ const WC = {
|
|
|
7373
7373
|
position: "fixed",
|
|
7374
7374
|
top: 0,
|
|
7375
7375
|
left: 0
|
|
7376
|
-
},
|
|
7376
|
+
}, Lo = {
|
|
7377
7377
|
...WC,
|
|
7378
7378
|
position: "absolute"
|
|
7379
7379
|
}, Vr = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
@@ -7406,13 +7406,13 @@ const ri = Math.min, Xr = Math.max, oi = Math.round, rs = Math.floor, Zr = (e) =
|
|
|
7406
7406
|
function qC(e, t, n) {
|
|
7407
7407
|
return Xr(e, ri(t, n));
|
|
7408
7408
|
}
|
|
7409
|
-
function
|
|
7409
|
+
function Oo(e, t) {
|
|
7410
7410
|
return typeof e == "function" ? e(t) : e;
|
|
7411
7411
|
}
|
|
7412
7412
|
function sr(e) {
|
|
7413
7413
|
return e.split("-")[0];
|
|
7414
7414
|
}
|
|
7415
|
-
function
|
|
7415
|
+
function Vo(e) {
|
|
7416
7416
|
return e.split("-")[1];
|
|
7417
7417
|
}
|
|
7418
7418
|
function Rm(e) {
|
|
@@ -7430,7 +7430,7 @@ function Mm(e) {
|
|
|
7430
7430
|
}
|
|
7431
7431
|
function m_(e, t, n) {
|
|
7432
7432
|
n === void 0 && (n = !1);
|
|
7433
|
-
const r =
|
|
7433
|
+
const r = Vo(e), o = Mm(e), s = Im(o);
|
|
7434
7434
|
let i = o === "x" ? r === (n ? "end" : "start") ? "right" : "left" : r === "start" ? "bottom" : "top";
|
|
7435
7435
|
return t.reference[s] > t.floating[s] && (i = Wc(i)), [i, Wc(i)];
|
|
7436
7436
|
}
|
|
@@ -7455,7 +7455,7 @@ function v_(e, t, n) {
|
|
|
7455
7455
|
}
|
|
7456
7456
|
}
|
|
7457
7457
|
function y_(e, t, n, r) {
|
|
7458
|
-
const o =
|
|
7458
|
+
const o = Vo(e);
|
|
7459
7459
|
let s = v_(sr(e), n === "start", r);
|
|
7460
7460
|
return o && (s = s.map((i) => i + "-" + o), t && (s = s.concat(s.map(eh)))), s;
|
|
7461
7461
|
}
|
|
@@ -7501,7 +7501,7 @@ function wa(e) {
|
|
|
7501
7501
|
function Ul(e, t, n) {
|
|
7502
7502
|
return Math.floor(e / t) !== n;
|
|
7503
7503
|
}
|
|
7504
|
-
function
|
|
7504
|
+
function Io(e, t) {
|
|
7505
7505
|
return t < 0 || t >= e.length;
|
|
7506
7506
|
}
|
|
7507
7507
|
function Mc(e, t) {
|
|
@@ -7622,7 +7622,7 @@ function C_(e, {
|
|
|
7622
7622
|
disabledIndices: a
|
|
7623
7623
|
}), o && (p = o(t, d, p)));
|
|
7624
7624
|
}
|
|
7625
|
-
|
|
7625
|
+
Io(e, p) && (p = d);
|
|
7626
7626
|
}
|
|
7627
7627
|
if (n === "both") {
|
|
7628
7628
|
const m = rs(d / i);
|
|
@@ -7649,7 +7649,7 @@ function C_(e, {
|
|
|
7649
7649
|
disabledIndices: a
|
|
7650
7650
|
}), o && (p = o(t, d, p))), Ul(p, i, m) && (p = d));
|
|
7651
7651
|
const g = rs(l / i) === m;
|
|
7652
|
-
|
|
7652
|
+
Io(e, p) && (r && g ? (p = t.key === (s ? is : ss) ? l : fn(e, {
|
|
7653
7653
|
startingIndex: d - d % i - 1,
|
|
7654
7654
|
disabledIndices: a
|
|
7655
7655
|
}), o && (p = o(t, d, p))) : p = d);
|
|
@@ -7812,8 +7812,8 @@ function Yv(e) {
|
|
|
7812
7812
|
delete n.dataset.tabindex, r ? n.setAttribute("tabindex", r) : n.removeAttribute("tabindex");
|
|
7813
7813
|
});
|
|
7814
7814
|
}
|
|
7815
|
-
function
|
|
7816
|
-
return e.filter((o) => o.parentId === t).flatMap((o) => [...!n || o.context?.open ? [o] : [], ...
|
|
7815
|
+
function Ao(e, t, n = !0) {
|
|
7816
|
+
return e.filter((o) => o.parentId === t).flatMap((o) => [...!n || o.context?.open ? [o] : [], ...Ao(e, o.id, n)]);
|
|
7817
7817
|
}
|
|
7818
7818
|
function Xv(e, t) {
|
|
7819
7819
|
let n = [], r = e.find((o) => o.id === t)?.parentId;
|
|
@@ -7927,7 +7927,7 @@ function D_(e, t = "mui") {
|
|
|
7927
7927
|
}, [n, t]), o;
|
|
7928
7928
|
}
|
|
7929
7929
|
const ry = ir.useId;
|
|
7930
|
-
function
|
|
7930
|
+
function Do(e, t) {
|
|
7931
7931
|
if (ry !== void 0) {
|
|
7932
7932
|
const n = ry();
|
|
7933
7933
|
return e ?? (t ? `${t}-${n}` : n);
|
|
@@ -7956,7 +7956,7 @@ function lE(e = {}) {
|
|
|
7956
7956
|
container: n,
|
|
7957
7957
|
componentProps: r = Ct,
|
|
7958
7958
|
elementProps: o
|
|
7959
|
-
} = e, s =
|
|
7959
|
+
} = e, s = Do(), a = aE()?.portalNode, [c, l] = w.useState(null), [d, f] = w.useState(null), p = ve((x) => {
|
|
7960
7960
|
x !== null && f(x);
|
|
7961
7961
|
}), h = w.useRef(null);
|
|
7962
7962
|
Se(() => {
|
|
@@ -8086,12 +8086,12 @@ const Fm = /* @__PURE__ */ w.createContext(null);
|
|
|
8086
8086
|
process.env.NODE_ENV !== "production" && (Fm.displayName = "FloatingNodeContext");
|
|
8087
8087
|
const Lm = /* @__PURE__ */ w.createContext(null);
|
|
8088
8088
|
process.env.NODE_ENV !== "production" && (Lm.displayName = "FloatingTreeContext");
|
|
8089
|
-
const
|
|
8089
|
+
const zo = () => w.useContext(Fm)?.id || null, Bo = (e) => {
|
|
8090
8090
|
const t = w.useContext(Lm);
|
|
8091
8091
|
return e ?? t;
|
|
8092
8092
|
};
|
|
8093
8093
|
function Vm(e) {
|
|
8094
|
-
const t =
|
|
8094
|
+
const t = Do(), n = Bo(e), r = zo();
|
|
8095
8095
|
return Se(() => {
|
|
8096
8096
|
if (!t)
|
|
8097
8097
|
return;
|
|
@@ -8108,7 +8108,7 @@ function uE(e) {
|
|
|
8108
8108
|
const {
|
|
8109
8109
|
children: t,
|
|
8110
8110
|
id: n
|
|
8111
|
-
} = e, r =
|
|
8111
|
+
} = e, r = zo();
|
|
8112
8112
|
return /* @__PURE__ */ u(Fm.Provider, {
|
|
8113
8113
|
value: w.useMemo(() => ({
|
|
8114
8114
|
id: n,
|
|
@@ -8135,15 +8135,15 @@ function U_(e, t) {
|
|
|
8135
8135
|
return e instanceof n.KeyboardEvent ? "keyboard" : e instanceof n.FocusEvent ? t || "keyboard" : "pointerType" in e ? e.pointerType || "keyboard" : "touches" in e ? "touch" : e instanceof n.MouseEvent ? t || (e.detail === 0 ? "keyboard" : "mouse") : "";
|
|
8136
8136
|
}
|
|
8137
8137
|
const oy = 20;
|
|
8138
|
-
let
|
|
8138
|
+
let wo = [];
|
|
8139
8139
|
function zm() {
|
|
8140
|
-
|
|
8140
|
+
wo = wo.filter((e) => e.deref()?.isConnected);
|
|
8141
8141
|
}
|
|
8142
8142
|
function sy(e) {
|
|
8143
|
-
zm(), e && wn(e) !== "body" && (
|
|
8143
|
+
zm(), e && wn(e) !== "body" && (wo.push(new WeakRef(e)), wo.length > oy && (wo = wo.slice(-oy)));
|
|
8144
8144
|
}
|
|
8145
8145
|
function iy() {
|
|
8146
|
-
return zm(),
|
|
8146
|
+
return zm(), wo[wo.length - 1]?.deref();
|
|
8147
8147
|
}
|
|
8148
8148
|
function j_(e) {
|
|
8149
8149
|
return e ? Tm(e) ? e : Ga(e)[0] || e : null;
|
|
@@ -8176,7 +8176,7 @@ function Wa(e) {
|
|
|
8176
8176
|
} = e, g = "rootStore" in t ? t.rootStore : t, x = g.useState("open"), b = g.useState("domReferenceElement"), y = g.useState("floatingElement"), {
|
|
8177
8177
|
events: v,
|
|
8178
8178
|
dataRef: C
|
|
8179
|
-
} = g.context, E = ve(() => C.current.floatingContext?.nodeId), S = o === !1, N = Jp(b) && S, k = At(o), I = At(s), M = At(l), T = At(x), D =
|
|
8179
|
+
} = g.context, E = ve(() => C.current.floatingContext?.nodeId), S = o === !1, N = Jp(b) && S, k = At(o), I = At(s), M = At(l), T = At(x), D = Bo(h), O = aE(), _ = w.useRef(!1), P = w.useRef(!1), $ = w.useRef(!1), V = w.useRef(null), F = w.useRef(""), H = w.useRef(""), A = w.useRef(null), z = w.useRef(null), L = yn(A, p, O?.beforeInsideRef), U = yn(z, O?.afterInsideRef), G = Nt(), Y = Nt(), q = gs(), X = O != null, W = Gc(y), j = ve((re = W) => re ? Ga(re) : []), te = ve(() => m?.().filter((re) => re != null) ?? []);
|
|
8180
8180
|
w.useEffect(() => {
|
|
8181
8181
|
if (r || !a)
|
|
8182
8182
|
return;
|
|
@@ -8226,7 +8226,7 @@ function Wa(e) {
|
|
|
8226
8226
|
function ae(ce) {
|
|
8227
8227
|
const ue = ce.relatedTarget, le = ce.currentTarget, be = Et(ce);
|
|
8228
8228
|
a && ue == null && be != null && $e(y, be) && sy(be), queueMicrotask(() => {
|
|
8229
|
-
const Ee = E(), oe = g.context.triggerElements, Q = te(), de = ue?.hasAttribute(Ca("focus-guard")) && [A.current, z.current, O?.beforeInsideRef.current, O?.afterInsideRef.current, O?.beforeOutsideRef.current, O?.afterOutsideRef.current, jr(f), jr(d)].includes(ue), we = !($e(b, ue) || $e(y, ue) || $e(ue, y) || $e(O?.portalNode, ue) || Q.some((Z) => Z === ue || $e(Z, ue)) || oe.hasMatchingElement((Z) => $e(Z, ue)) || de || D && (
|
|
8229
|
+
const Ee = E(), oe = g.context.triggerElements, Q = te(), de = ue?.hasAttribute(Ca("focus-guard")) && [A.current, z.current, O?.beforeInsideRef.current, O?.afterInsideRef.current, O?.beforeOutsideRef.current, O?.afterOutsideRef.current, jr(f), jr(d)].includes(ue), we = !($e(b, ue) || $e(y, ue) || $e(ue, y) || $e(O?.portalNode, ue) || Q.some((Z) => Z === ue || $e(Z, ue)) || oe.hasMatchingElement((Z) => $e(Z, ue)) || de || D && (Ao(D.nodesRef.current, Ee).find((Z) => $e(Z.context?.elements.floating, ue) || $e(Z.context?.elements.domReference, ue)) || Xv(D.nodesRef.current, Ee).find((Z) => [Z.context?.elements.floating, Gc(Z.context?.elements.floating)].includes(ue) || Z.context?.elements.domReference === ue)));
|
|
8230
8230
|
if (le === b && W && ay(W), i && le !== b && !nd(be) && Lt(re) === re.body) {
|
|
8231
8231
|
if (wt(W) && (W.focus(), i === "popup")) {
|
|
8232
8232
|
q.request(() => {
|
|
@@ -8328,7 +8328,7 @@ function Wa(e) {
|
|
|
8328
8328
|
}
|
|
8329
8329
|
return () => {
|
|
8330
8330
|
v.off("openchange", ae);
|
|
8331
|
-
const me = Lt(re), ce = te(), ue = $e(y, me) || ce.some((oe) => oe === me || $e(oe, me)) || D &&
|
|
8331
|
+
const me = Lt(re), ce = te(), ue = $e(y, me) || ce.some((oe) => oe === me || $e(oe, me)) || D && Ao(D.nodesRef.current, E(), !1).some((oe) => $e(oe.context?.elements.floating, me)), le = I.current, be = F.current, Ee = fe(be);
|
|
8332
8332
|
queueMicrotask(() => {
|
|
8333
8333
|
const oe = j_(Ee), Q = typeof le != "boolean";
|
|
8334
8334
|
if (le && !_.current && wt(oe) && // If the focus moved somewhere else after mount, avoid returning focus
|
|
@@ -8407,11 +8407,11 @@ function xi(e, t = {}) {
|
|
|
8407
8407
|
}
|
|
8408
8408
|
return {
|
|
8409
8409
|
onPointerDown(b) {
|
|
8410
|
-
f.current =
|
|
8410
|
+
f.current = No(b.pointerType, !0) && ym(b.nativeEvent) ? "virtual" : b.pointerType;
|
|
8411
8411
|
},
|
|
8412
8412
|
onMouseDown(b) {
|
|
8413
8413
|
const y = f.current, v = b.nativeEvent, C = l.select("open");
|
|
8414
|
-
if (b.button !== 0 || r === "click" ||
|
|
8414
|
+
if (b.button !== 0 || r === "click" || No(y, !0) && s)
|
|
8415
8415
|
return;
|
|
8416
8416
|
const E = x(C, b.currentTarget, (k) => k === "click" || k === "mousedown"), S = Et(v);
|
|
8417
8417
|
if (Qu(S)) {
|
|
@@ -8431,7 +8431,7 @@ function xi(e, t = {}) {
|
|
|
8431
8431
|
f.current = void 0;
|
|
8432
8432
|
return;
|
|
8433
8433
|
}
|
|
8434
|
-
if (
|
|
8434
|
+
if (No(y, !0) && s)
|
|
8435
8435
|
return;
|
|
8436
8436
|
const v = l.select("open"), C = x(v, b.currentTarget, (E) => E === "click" || E === "mousedown" || E === "keydown" || E === "keyup");
|
|
8437
8437
|
g(C, b.nativeEvent, b.currentTarget, y);
|
|
@@ -8489,7 +8489,7 @@ function W_(e, t = {}) {
|
|
|
8489
8489
|
}));
|
|
8490
8490
|
}), b = ve((C) => {
|
|
8491
8491
|
s ? d.current || (x(C.clientX, C.clientY, C.currentTarget), m([])) : x(C.clientX, C.clientY, C.currentTarget);
|
|
8492
|
-
}), y =
|
|
8492
|
+
}), y = No(f) ? i : s;
|
|
8493
8493
|
w.useEffect(() => {
|
|
8494
8494
|
if (!n) {
|
|
8495
8495
|
g(a);
|
|
@@ -8549,14 +8549,14 @@ function vi(e, t = {}) {
|
|
|
8549
8549
|
externalTree: c
|
|
8550
8550
|
} = t, l = "rootStore" in e ? e.rootStore : e, d = l.useState("open"), f = l.useState("floatingElement"), {
|
|
8551
8551
|
dataRef: p
|
|
8552
|
-
} = l.context, h =
|
|
8552
|
+
} = l.context, h = Bo(c), m = ve(typeof o == "function" ? o : () => !1), g = typeof o == "function" ? m : o, x = g !== !1, b = ve(() => s), {
|
|
8553
8553
|
escapeKey: y,
|
|
8554
8554
|
outsidePress: v
|
|
8555
8555
|
} = K_(a), C = w.useRef(!1), E = w.useRef(!1), S = w.useRef(!1), N = w.useRef(!1), k = w.useRef(""), I = w.useRef(null), M = Nt(), T = Nt(), D = ve(() => {
|
|
8556
8556
|
T.clear(), p.current.insideReactTree = !1;
|
|
8557
8557
|
}), O = ve((L) => {
|
|
8558
8558
|
const U = p.current.floatingContext?.nodeId;
|
|
8559
|
-
return (h ?
|
|
8559
|
+
return (h ? Ao(h.nodesRef.current, U) : []).some((Y) => Y.context?.open && !Y.context.dataRef.current[L]);
|
|
8560
8560
|
}), _ = ve((L) => Df(L, l.select("floatingElement")) || Df(L, l.select("domReferenceElement"))), P = ve((L) => {
|
|
8561
8561
|
i() && l.setOpen(!1, Ie(Lr, L.nativeEvent));
|
|
8562
8562
|
}), $ = ve((L) => {
|
|
@@ -8609,7 +8609,7 @@ function vi(e, t = {}) {
|
|
|
8609
8609
|
return de === "intentional" && Q.type !== "click" || de === "sloppy" && Q.type === "click";
|
|
8610
8610
|
}
|
|
8611
8611
|
function te(Q) {
|
|
8612
|
-
const de = p.current.floatingContext?.nodeId, we = h &&
|
|
8612
|
+
const de = p.current.floatingContext?.nodeId, we = h && Ao(h.nodesRef.current, de).some((Z) => Df(Q, Z.context?.elements.floating));
|
|
8613
8613
|
return _(Q) || we;
|
|
8614
8614
|
}
|
|
8615
8615
|
function se(Q) {
|
|
@@ -8789,7 +8789,7 @@ function cy(e, t, n) {
|
|
|
8789
8789
|
y: r.y
|
|
8790
8790
|
};
|
|
8791
8791
|
}
|
|
8792
|
-
const m =
|
|
8792
|
+
const m = Vo(t);
|
|
8793
8793
|
return m && (h[i] += p * (m === "end" ? 1 : -1) * (n && l ? -1 : 1)), h;
|
|
8794
8794
|
}
|
|
8795
8795
|
async function Y_(e, t) {
|
|
@@ -8808,7 +8808,7 @@ async function Y_(e, t) {
|
|
|
8808
8808
|
elementContext: f = "floating",
|
|
8809
8809
|
altBoundary: p = !1,
|
|
8810
8810
|
padding: h = 0
|
|
8811
|
-
} =
|
|
8811
|
+
} = Oo(t, e), m = KC(h), x = a[p ? f === "floating" ? "reference" : "floating" : f], b = wa(await s.getClippingRect({
|
|
8812
8812
|
element: (n = await (s.isElement == null ? void 0 : s.isElement(x))) == null || n ? x : x.contextElement || await (s.getDocumentElement == null ? void 0 : s.getDocumentElement(a.floating)),
|
|
8813
8813
|
boundary: l,
|
|
8814
8814
|
rootBoundary: d,
|
|
@@ -8919,7 +8919,7 @@ const X_ = 50, Z_ = async (e, t, n) => {
|
|
|
8919
8919
|
fallbackAxisSideDirection: m = "none",
|
|
8920
8920
|
flipAlignment: g = !0,
|
|
8921
8921
|
...x
|
|
8922
|
-
} =
|
|
8922
|
+
} = Oo(e, t);
|
|
8923
8923
|
if ((n = s.arrow) != null && n.alignmentOffset)
|
|
8924
8924
|
return {};
|
|
8925
8925
|
const b = sr(o), y = tr(a), v = sr(a) === a, C = await (c.isRTL == null ? void 0 : c.isRTL(l.floating)), E = p || (v || !g ? [Wc(a)] : g_(a)), S = m !== "none";
|
|
@@ -8985,7 +8985,7 @@ async function J_(e, t) {
|
|
|
8985
8985
|
placement: n,
|
|
8986
8986
|
platform: r,
|
|
8987
8987
|
elements: o
|
|
8988
|
-
} = e, s = await (r.isRTL == null ? void 0 : r.isRTL(o.floating)), i = sr(n), a =
|
|
8988
|
+
} = e, s = await (r.isRTL == null ? void 0 : r.isRTL(o.floating)), i = sr(n), a = Vo(n), c = tr(n) === "y", l = fE.has(i) ? -1 : 1, d = s && c ? -1 : 1, f = Oo(t, e);
|
|
8989
8989
|
let {
|
|
8990
8990
|
mainAxis: p,
|
|
8991
8991
|
crossAxis: h,
|
|
@@ -9055,7 +9055,7 @@ const e$ = function(e) {
|
|
|
9055
9055
|
}
|
|
9056
9056
|
},
|
|
9057
9057
|
...l
|
|
9058
|
-
} =
|
|
9058
|
+
} = Oo(e, t), d = {
|
|
9059
9059
|
x: n,
|
|
9060
9060
|
y: r
|
|
9061
9061
|
}, f = await s.detectOverflow(t, l), p = tr(o), h = Rm(p);
|
|
@@ -9095,12 +9095,12 @@ const e$ = function(e) {
|
|
|
9095
9095
|
offset: l = 0,
|
|
9096
9096
|
mainAxis: d = !0,
|
|
9097
9097
|
crossAxis: f = !0
|
|
9098
|
-
} =
|
|
9098
|
+
} = Oo(e, t), p = {
|
|
9099
9099
|
x: o,
|
|
9100
9100
|
y: s
|
|
9101
9101
|
}, h = tr(i), m = Rm(h);
|
|
9102
9102
|
let g = p[m], x = p[h];
|
|
9103
|
-
const b =
|
|
9103
|
+
const b = Oo(l, t), y = typeof b == "number" ? {
|
|
9104
9104
|
mainAxis: b,
|
|
9105
9105
|
crossAxis: 0
|
|
9106
9106
|
} : {
|
|
@@ -9136,7 +9136,7 @@ const e$ = function(e) {
|
|
|
9136
9136
|
apply: i = () => {
|
|
9137
9137
|
},
|
|
9138
9138
|
...a
|
|
9139
|
-
} =
|
|
9139
|
+
} = Oo(e, t), c = await o.detectOverflow(t, a), l = sr(n), d = Vo(n), f = tr(n) === "y", {
|
|
9140
9140
|
width: p,
|
|
9141
9141
|
height: h
|
|
9142
9142
|
} = r.floating;
|
|
@@ -10445,7 +10445,7 @@ function SE(e) {
|
|
|
10445
10445
|
return (t) => t === "touch" ? e.current : !0;
|
|
10446
10446
|
}
|
|
10447
10447
|
function jm(e, t = !1) {
|
|
10448
|
-
const n =
|
|
10448
|
+
const n = Do(), r = zo() != null, o = zt(() => e(n, r)).current;
|
|
10449
10449
|
return EE({
|
|
10450
10450
|
popupStore: o,
|
|
10451
10451
|
treatPopupAsFloatingElement: t,
|
|
@@ -10795,7 +10795,7 @@ function RE(e) {
|
|
|
10795
10795
|
open: t = !1,
|
|
10796
10796
|
onOpenChange: n,
|
|
10797
10797
|
elements: r = {}
|
|
10798
|
-
} = e, o =
|
|
10798
|
+
} = e, o = Do(), s = zo() != null;
|
|
10799
10799
|
if (process.env.NODE_ENV !== "production") {
|
|
10800
10800
|
const a = r.reference;
|
|
10801
10801
|
a && !ut(a) && console.error("Cannot pass a virtual element to the `elements.reference` option,", "as it must be a real DOM element. Use `context.setPositionReference()`", "instead.");
|
|
@@ -10826,7 +10826,7 @@ function eF(e, t) {
|
|
|
10826
10826
|
const {
|
|
10827
10827
|
nodeId: n,
|
|
10828
10828
|
externalTree: r
|
|
10829
|
-
} = e, o = t.useState("referenceElement"), s = t.useState("floatingElement"), i = t.useState("domReferenceElement"), a = t.useState("open"), c = t.useState("floatingId"), [l, d] = w.useState(null), [f, p] = w.useState(void 0), [h, m] = w.useState(void 0), g = w.useRef(null), x =
|
|
10829
|
+
} = e, o = t.useState("referenceElement"), s = t.useState("floatingElement"), i = t.useState("domReferenceElement"), a = t.useState("open"), c = t.useState("floatingId"), [l, d] = w.useState(null), [f, p] = w.useState(void 0), [h, m] = w.useState(void 0), g = w.useRef(null), x = Bo(r), b = w.useMemo(() => ({
|
|
10830
10830
|
reference: o,
|
|
10831
10831
|
floating: s,
|
|
10832
10832
|
domReference: i
|
|
@@ -11015,7 +11015,7 @@ function Xm(e, t = {}) {
|
|
|
11015
11015
|
nodeId: o
|
|
11016
11016
|
} = t, s = "rootStore" in e ? e.rootStore : e, i = s.useState("open"), a = s.useState("floatingElement"), c = s.useState("domReferenceElement"), {
|
|
11017
11017
|
dataRef: l
|
|
11018
|
-
} = s.context, d =
|
|
11018
|
+
} = s.context, d = Bo(), f = zo(), p = Ym(s), h = Nt(), m = ve(() => UC(l.current.openEvent?.type, p.interactedInside)), g = ve(() => e_(l.current.openEvent?.type)), x = ve(() => {
|
|
11019
11019
|
Yc(p);
|
|
11020
11020
|
});
|
|
11021
11021
|
Se(() => {
|
|
@@ -11037,10 +11037,10 @@ function Xm(e, t = {}) {
|
|
|
11037
11037
|
if (!n)
|
|
11038
11038
|
return;
|
|
11039
11039
|
function b() {
|
|
11040
|
-
return !!(d && f &&
|
|
11040
|
+
return !!(d && f && Ao(d.nodesRef.current, f).length > 0);
|
|
11041
11041
|
}
|
|
11042
11042
|
function y(k) {
|
|
11043
|
-
const I =
|
|
11043
|
+
const I = Po(r, "close", p.pointerType), M = () => {
|
|
11044
11044
|
s.setOpen(!1, Ie(Gt, k)), d?.events.emit("floating.closed", k);
|
|
11045
11045
|
};
|
|
11046
11046
|
I ? p.openChangeTimeout.start(I, M) : (p.openChangeTimeout.clear(), M());
|
|
@@ -11064,7 +11064,7 @@ function Xm(e, t = {}) {
|
|
|
11064
11064
|
if (jc(k.relatedTarget, s.context.triggerElements))
|
|
11065
11065
|
return;
|
|
11066
11066
|
const I = l.current.floatingContext?.nodeId ?? o, M = k.relatedTarget;
|
|
11067
|
-
if (!(d && I && ut(M) &&
|
|
11067
|
+
if (!(d && I && ut(M) && Ao(d.nodesRef.current, I, !1).some((D) => $e(D.context?.elements.floating, M)))) {
|
|
11068
11068
|
if (p.handler) {
|
|
11069
11069
|
p.handler(k);
|
|
11070
11070
|
return;
|
|
@@ -11104,7 +11104,7 @@ function Zm(e, t = {}) {
|
|
|
11104
11104
|
} = t, g = "rootStore" in e ? e.rootStore : e, {
|
|
11105
11105
|
dataRef: x,
|
|
11106
11106
|
events: b
|
|
11107
|
-
} = g.context, y =
|
|
11107
|
+
} = g.context, y = Bo(l), v = Ym(g), C = w.useRef(!1), E = At(o), S = At(r), N = At(i), k = At(n), I = At(h), M = At(p), T = ve(() => UC(x.current.openEvent?.type, v.interactedInside)), D = ve(() => I.current?.() !== !1), O = ve(($, V, F) => {
|
|
11108
11108
|
const H = g.context.triggerElements;
|
|
11109
11109
|
if (H.hasElement(V))
|
|
11110
11110
|
return !$ || !$e($, V);
|
|
@@ -11132,7 +11132,7 @@ function Zm(e, t = {}) {
|
|
|
11132
11132
|
if (!n)
|
|
11133
11133
|
return;
|
|
11134
11134
|
function $(L, U = !0) {
|
|
11135
|
-
const G =
|
|
11135
|
+
const G = Po(S.current, "close", v.pointerType);
|
|
11136
11136
|
G ? v.openChangeTimeout.start(G, () => {
|
|
11137
11137
|
g.setOpen(!1, Ie(Gt, L)), y?.events.emit("floating.closed", L);
|
|
11138
11138
|
}) : U && (v.openChangeTimeout.clear(), g.setOpen(!1, Ie(Gt, L)), y?.events.emit("floating.closed", L));
|
|
@@ -11141,9 +11141,9 @@ function Zm(e, t = {}) {
|
|
|
11141
11141
|
if (!ut(V))
|
|
11142
11142
|
return;
|
|
11143
11143
|
function F(L) {
|
|
11144
|
-
if (v.openChangeTimeout.clear(), v.blockMouseMove = !1, s && !
|
|
11144
|
+
if (v.openChangeTimeout.clear(), v.blockMouseMove = !1, s && !No(v.pointerType))
|
|
11145
11145
|
return;
|
|
11146
|
-
const U = Lv(N.current), G =
|
|
11146
|
+
const U = Lv(N.current), G = Po(S.current, "open", v.pointerType), Y = Et(L), q = L.currentTarget ?? null, X = g.select("domReferenceElement");
|
|
11147
11147
|
let W = q;
|
|
11148
11148
|
if (ut(Y) && !g.context.triggerElements.hasElement(Y)) {
|
|
11149
11149
|
for (const me of g.context.triggerElements.elements())
|
|
@@ -11209,7 +11209,7 @@ function Zm(e, t = {}) {
|
|
|
11209
11209
|
const {
|
|
11210
11210
|
nativeEvent: F
|
|
11211
11211
|
} = V, H = V.currentTarget, A = g.select("domReferenceElement"), z = g.select("open"), L = O(A, H, V.target);
|
|
11212
|
-
if (s && !
|
|
11212
|
+
if (s && !No(v.pointerType))
|
|
11213
11213
|
return;
|
|
11214
11214
|
if (z && L && v.handleCloseOptions?.blockPointerEvents) {
|
|
11215
11215
|
const Y = g.select("floatingElement");
|
|
@@ -11291,7 +11291,7 @@ function Qm(e, t) {
|
|
|
11291
11291
|
grid: E
|
|
11292
11292
|
} = t, S = E != null;
|
|
11293
11293
|
process.env.NODE_ENV !== "production" && (a && (c || console.warn("`useListNavigation` looping must be enabled to allow escaping."), f || console.warn("`useListNavigation` must be virtual to allow escaping.")), x === "vertical" && S && console.warn("In grid list navigation mode, the `orientation` should", 'be either "horizontal" or "both".'));
|
|
11294
|
-
const N = "rootStore" in e ? e.rootStore : e, k = N.useState("open"), I = N.useState("floatingElement"), M = N.useState("domReferenceElement"), T = N.context.dataRef, D = Gc(I), O = Jp(M), _ = At(D), P =
|
|
11294
|
+
const N = "rootStore" in e ? e.rootStore : e, k = N.useState("open"), I = N.useState("floatingElement"), M = N.useState("domReferenceElement"), T = N.context.dataRef, D = Gc(I), O = Jp(M), _ = At(D), P = zo(), $ = Bo(C), V = w.useRef(p), F = w.useRef(i ?? -1), H = w.useRef(null), A = w.useRef(!0), z = ve((Q) => {
|
|
11295
11295
|
o(F.current === -1 ? null : F.current, Q);
|
|
11296
11296
|
}), L = w.useRef(!!I), U = w.useRef(k), G = w.useRef(!1), Y = w.useRef(!1), q = w.useRef(null), X = At(g), W = At(k), j = At(i), te = At(v), se = gs(), re = gs(), K = ve(() => {
|
|
11297
11297
|
function Q(ee) {
|
|
@@ -11333,7 +11333,7 @@ function Qm(e, t) {
|
|
|
11333
11333
|
};
|
|
11334
11334
|
de();
|
|
11335
11335
|
}
|
|
11336
|
-
} else
|
|
11336
|
+
} else Io(n.current, r) || (F.current = r, K(), Y.current = !1);
|
|
11337
11337
|
}
|
|
11338
11338
|
}, [s, k, I, r, j, l, n, x, d, z, K, re]), Se(() => {
|
|
11339
11339
|
if (!s || I || !$ || f || !L.current)
|
|
@@ -11384,7 +11384,7 @@ function Qm(e, t) {
|
|
|
11384
11384
|
startingIndex: de,
|
|
11385
11385
|
decrement: !0,
|
|
11386
11386
|
disabledIndices: g
|
|
11387
|
-
})),
|
|
11387
|
+
})), Io(n.current, F.current) && (F.current = -1), z(Q);
|
|
11388
11388
|
}
|
|
11389
11389
|
}), ue = w.useMemo(() => ({
|
|
11390
11390
|
onFocus(de) {
|
|
@@ -11592,7 +11592,7 @@ function eg(e = {}) {
|
|
|
11592
11592
|
if (I && ut(v.relatedTarget) && $e(E, v.relatedTarget))
|
|
11593
11593
|
return;
|
|
11594
11594
|
function D() {
|
|
11595
|
-
return !!(d &&
|
|
11595
|
+
return !!(d && Ao(d.nodesRef.current, l).length > 0);
|
|
11596
11596
|
}
|
|
11597
11597
|
function O() {
|
|
11598
11598
|
D() || b();
|
|
@@ -12023,7 +12023,7 @@ const bF = {
|
|
|
12023
12023
|
...Cn
|
|
12024
12024
|
}, CF = 300;
|
|
12025
12025
|
function St(e) {
|
|
12026
|
-
return
|
|
12026
|
+
return Do(e, "base-ui");
|
|
12027
12027
|
}
|
|
12028
12028
|
function PE(e, t) {
|
|
12029
12029
|
const n = w.useRef(null);
|
|
@@ -12237,7 +12237,7 @@ const kF = (e) => ({
|
|
|
12237
12237
|
element: l,
|
|
12238
12238
|
padding: d = 0,
|
|
12239
12239
|
offsetParent: f = "real"
|
|
12240
|
-
} =
|
|
12240
|
+
} = Oo(e, t) || {};
|
|
12241
12241
|
if (l == null)
|
|
12242
12242
|
return {};
|
|
12243
12243
|
const p = KC(d), h = {
|
|
@@ -12246,7 +12246,7 @@ const kF = (e) => ({
|
|
|
12246
12246
|
}, m = Mm(o), g = Im(m), x = await i.getDimensions(l), b = m === "y", y = b ? "top" : "left", v = b ? "bottom" : "right", C = b ? "clientHeight" : "clientWidth", E = s.reference[g] + s.reference[m] - h[m] - s.floating[g], S = h[m] - s.reference[m], N = f === "real" ? await i.getOffsetParent?.(l) : a.floating;
|
|
12247
12247
|
let k = a.floating[C] || s.floating[g];
|
|
12248
12248
|
(!k || !await i.isElement?.(N)) && (k = a.floating[C] || s.floating[g]);
|
|
12249
|
-
const I = E / 2 - S / 2, M = k / 2 - x[g] / 2 - 1, T = Math.min(p[y], M), D = Math.min(p[v], M), O = T, _ = k - x[g] - D, P = k / 2 - x[g] / 2 + I, $ = qC(O, P, _), V = !c.arrow &&
|
|
12249
|
+
const I = E / 2 - S / 2, M = k / 2 - x[g] / 2 - 1, T = Math.min(p[y], M), D = Math.min(p[v], M), O = T, _ = k - x[g] - D, P = k / 2 - x[g] / 2 + I, $ = qC(O, P, _), V = !c.arrow && Vo(o) != null && P !== $ && s.reference[g] / 2 - (P < O ? T : D) - x[g] / 2 < 0, F = V ? P < O ? P - O : P - _ : 0;
|
|
12250
12250
|
return {
|
|
12251
12251
|
[m]: h[m] + F,
|
|
12252
12252
|
data: {
|
|
@@ -12299,7 +12299,7 @@ function Ny(e, t, n) {
|
|
|
12299
12299
|
} = e;
|
|
12300
12300
|
return {
|
|
12301
12301
|
side: $E(t, sr(o), n),
|
|
12302
|
-
align:
|
|
12302
|
+
align: Vo(o) || "center",
|
|
12303
12303
|
anchor: {
|
|
12304
12304
|
width: r.reference.width,
|
|
12305
12305
|
height: r.reference.height
|
|
@@ -12511,7 +12511,7 @@ function MF(e, t) {
|
|
|
12511
12511
|
if (m && x && Ee.reference && Ee.floating)
|
|
12512
12512
|
return fy(Ee.reference, Ee.floating, we, le);
|
|
12513
12513
|
}, [m, x, Ee, we, le]);
|
|
12514
|
-
const he = sr(Z), pe = $E(o, he, A), Ce =
|
|
12514
|
+
const he = sr(Z), pe = $E(o, he, A), Ce = Vo(Z) || "center", Te = !!de.hide?.referenceHidden;
|
|
12515
12515
|
Se(() => {
|
|
12516
12516
|
E && x && ye && he !== z && k(he);
|
|
12517
12517
|
}, [E, x, ye, he, z]);
|
|
@@ -12854,7 +12854,7 @@ function Ql(e) {
|
|
|
12854
12854
|
}
|
|
12855
12855
|
const ag = /* @__PURE__ */ w.createContext(void 0);
|
|
12856
12856
|
process.env.NODE_ENV !== "production" && (ag.displayName = "ToolbarRootContext");
|
|
12857
|
-
function
|
|
12857
|
+
function Ho(e) {
|
|
12858
12858
|
const t = w.useContext(ag);
|
|
12859
12859
|
if (t === void 0 && !e)
|
|
12860
12860
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: ToolbarRootContext is missing. Toolbar parts must be placed within <Toolbar.Root>." : nt(69));
|
|
@@ -12885,7 +12885,7 @@ const HE = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
12885
12885
|
initialFocus: i,
|
|
12886
12886
|
finalFocus: a,
|
|
12887
12887
|
...c
|
|
12888
|
-
} = t, l = ks(), d = DE(), f =
|
|
12888
|
+
} = t, l = ks(), d = DE(), f = Ho(!0) != null, {
|
|
12889
12889
|
context: p,
|
|
12890
12890
|
hasClosePart: h
|
|
12891
12891
|
} = VF(), m = l.useState("open"), g = l.useState("openMethod"), x = l.useState("instantType"), b = l.useState("transitionStatus"), y = l.useState("popupProps"), v = l.useState("titleElementId"), C = l.useState("descriptionElementId"), E = l.useState("modal"), S = l.useState("mounted"), N = l.useState("openChangeReason"), k = l.useState("activeTriggerElement"), I = l.useState("floatingRootContext"), M = I.useState("floatingId"), T = l.useState("disabled"), D = l.useState("openOnHover"), O = l.useState("closeDelay");
|
|
@@ -13214,7 +13214,7 @@ const qE = yE(function(t, n) {
|
|
|
13214
13214
|
x.useSyncedValue("isInstantPhase", D);
|
|
13215
13215
|
const P = x.useState("disabled"), $ = c ?? P, V = At($), F = x.useState("trackCursorAxis"), H = x.useState("disableHoverablePopup"), A = w.useRef(!1), z = Nt(), L = w.useRef(void 0);
|
|
13216
13216
|
function U() {
|
|
13217
|
-
return O ?
|
|
13217
|
+
return O ? Po(T.current, "open") === 0 ? 0 : l ?? M ?? $y : S;
|
|
13218
13218
|
}
|
|
13219
13219
|
function G(K) {
|
|
13220
13220
|
const J = E.current;
|
|
@@ -13235,7 +13235,7 @@ const qE = yE(function(t, n) {
|
|
|
13235
13235
|
restMs: U,
|
|
13236
13236
|
delay() {
|
|
13237
13237
|
return f == null && O ? {
|
|
13238
|
-
close:
|
|
13238
|
+
close: Po(T.current, "close")
|
|
13239
13239
|
} : {
|
|
13240
13240
|
close: N
|
|
13241
13241
|
};
|
|
@@ -13255,7 +13255,7 @@ const qE = yE(function(t, n) {
|
|
|
13255
13255
|
return;
|
|
13256
13256
|
}
|
|
13257
13257
|
if (J && !fe && ce && !V.current && !x.select("open") && me && // Match the hover hook's non-strict mouse fallback for mouse-only event sequences.
|
|
13258
|
-
|
|
13258
|
+
No(L.current)) {
|
|
13259
13259
|
const ue = () => {
|
|
13260
13260
|
!A.current && !V.current && !x.select("open") && x.setOpen(!0, Ie(Gt, K, me));
|
|
13261
13261
|
}, le = U();
|
|
@@ -13623,7 +13623,7 @@ function nL({
|
|
|
13623
13623
|
[e, t, n]
|
|
13624
13624
|
), null;
|
|
13625
13625
|
}
|
|
13626
|
-
function
|
|
13626
|
+
function vo({ children: e }) {
|
|
13627
13627
|
return /* @__PURE__ */ u(jE, { render: e });
|
|
13628
13628
|
}
|
|
13629
13629
|
function Kt({ content: e, children: t, side: n = "top", className: r, defaultOpen: o, enterable: s = !1, open: i, onOpenChange: a }) {
|
|
@@ -14213,16 +14213,16 @@ function fL(e, t, n) {
|
|
|
14213
14213
|
if (!(r > 0)) return null;
|
|
14214
14214
|
const o = Kf(r * 0.9, 18, 42) * Hy[n], s = Kf(r * 0.28, 6, 12) * Hy[n];
|
|
14215
14215
|
return {
|
|
14216
|
-
reachPx:
|
|
14217
|
-
diagonal:
|
|
14218
|
-
reachX:
|
|
14219
|
-
reachY:
|
|
14220
|
-
swellX:
|
|
14221
|
-
swellY:
|
|
14216
|
+
reachPx: Xo(o),
|
|
14217
|
+
diagonal: Xo(Math.hypot(e, t)),
|
|
14218
|
+
reachX: Xo(1 + o / e),
|
|
14219
|
+
reachY: Xo(1 + o / t),
|
|
14220
|
+
swellX: Xo(1 + s / e),
|
|
14221
|
+
swellY: Xo(1 + s / t),
|
|
14222
14222
|
/* A turn that is right for an icon is a swinging door on a card: the angle
|
|
14223
14223
|
shrinks as the thing gets longer, so the corners sweep about the same
|
|
14224
14224
|
distance whatever is wrapped. */
|
|
14225
|
-
tilt:
|
|
14225
|
+
tilt: Xo(Kf(432 / Math.max(e, t), 1.5, 9))
|
|
14226
14226
|
};
|
|
14227
14227
|
}
|
|
14228
14228
|
const lS = [
|
|
@@ -14239,7 +14239,7 @@ function hL(e) {
|
|
|
14239
14239
|
function Kf(e, t, n) {
|
|
14240
14240
|
return Math.min(n, Math.max(t, e));
|
|
14241
14241
|
}
|
|
14242
|
-
function
|
|
14242
|
+
function Xo(e) {
|
|
14243
14243
|
return Math.round(e * 1e3) / 1e3;
|
|
14244
14244
|
}
|
|
14245
14245
|
const mL = 520;
|
|
@@ -17552,7 +17552,7 @@ function TV(e, t) {
|
|
|
17552
17552
|
}
|
|
17553
17553
|
const kg = /* @__PURE__ */ w.createContext(void 0);
|
|
17554
17554
|
process.env.NODE_ENV !== "production" && (kg.displayName = "DialogRootContext");
|
|
17555
|
-
function
|
|
17555
|
+
function Uo(e) {
|
|
17556
17556
|
const t = w.useContext(kg);
|
|
17557
17557
|
if (!e && t === void 0)
|
|
17558
17558
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: DialogRootContext is missing. Dialog parts must be placed within <Dialog.Root>." : nt(27));
|
|
@@ -17565,7 +17565,7 @@ const Ja = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
17565
17565
|
style: s,
|
|
17566
17566
|
forceRender: i = !1,
|
|
17567
17567
|
...a
|
|
17568
|
-
} = t, c =
|
|
17568
|
+
} = t, c = Uo(), l = c.useState("open"), d = c.useState("nested"), f = c.useState("mounted"), p = c.useState("transitionStatus");
|
|
17569
17569
|
return Ne("div", t, {
|
|
17570
17570
|
state: {
|
|
17571
17571
|
open: l,
|
|
@@ -17593,7 +17593,7 @@ const el = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
17593
17593
|
disabled: i = !1,
|
|
17594
17594
|
nativeButton: a = !0,
|
|
17595
17595
|
...c
|
|
17596
|
-
} = t, l =
|
|
17596
|
+
} = t, l = Uo(), d = l.useState("open"), {
|
|
17597
17597
|
getButtonProps: f,
|
|
17598
17598
|
buttonRef: p
|
|
17599
17599
|
} = Bt({
|
|
@@ -17621,7 +17621,7 @@ const Ng = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
17621
17621
|
style: s,
|
|
17622
17622
|
id: i,
|
|
17623
17623
|
...a
|
|
17624
|
-
} = t, c =
|
|
17624
|
+
} = t, c = Uo(), l = St(i);
|
|
17625
17625
|
return c.useSyncedValueWithCleanup("descriptionElementId", l), Ne("p", t, {
|
|
17626
17626
|
ref: n,
|
|
17627
17627
|
props: [{
|
|
@@ -17654,7 +17654,7 @@ const OV = {
|
|
|
17654
17654
|
finalFocus: i,
|
|
17655
17655
|
initialFocus: a,
|
|
17656
17656
|
...c
|
|
17657
|
-
} = t, l =
|
|
17657
|
+
} = t, l = Uo(), d = l.useState("descriptionElementId"), f = l.useState("disablePointerDismissal"), p = l.useState("floatingRootContext"), h = l.useState("popupProps"), m = l.useState("modal"), g = l.useState("mounted"), x = l.useState("nested"), b = l.useState("nestedOpenDialogCount"), y = l.useState("open"), v = l.useState("openMethod"), C = l.useState("titleElementId"), E = l.useState("transitionStatus"), S = l.useState("role"), N = p.useState("floatingId");
|
|
17658
17658
|
PV(), tn({
|
|
17659
17659
|
open: y,
|
|
17660
17660
|
ref: l.context.popupRef,
|
|
@@ -17703,7 +17703,7 @@ const nl = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
17703
17703
|
const {
|
|
17704
17704
|
keepMounted: r = !1,
|
|
17705
17705
|
...o
|
|
17706
|
-
} = t, s =
|
|
17706
|
+
} = t, s = Uo(), i = s.useState("mounted"), a = s.useState("modal"), c = s.useState("open");
|
|
17707
17707
|
return i || r ? /* @__PURE__ */ u(Rg.Provider, {
|
|
17708
17708
|
value: r,
|
|
17709
17709
|
children: /* @__PURE__ */ R(bi, {
|
|
@@ -17840,7 +17840,7 @@ function US(e, t) {
|
|
|
17840
17840
|
handle: d,
|
|
17841
17841
|
triggerId: f,
|
|
17842
17842
|
defaultTriggerId: p = null
|
|
17843
|
-
} = t, h = e === "drawer", m = e === "alert-dialog", g = m ? !0 : c, x = m || a, b = m ? "alertdialog" : "dialog", y =
|
|
17843
|
+
} = t, h = e === "drawer", m = e === "alert-dialog", g = m ? !0 : c, x = m || a, b = m ? "alertdialog" : "dialog", y = Uo(!0), v = y != null, C = {
|
|
17844
17844
|
modal: g,
|
|
17845
17845
|
disablePointerDismissal: x,
|
|
17846
17846
|
nested: v,
|
|
@@ -17887,7 +17887,7 @@ const rl = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
17887
17887
|
style: s,
|
|
17888
17888
|
id: i,
|
|
17889
17889
|
...a
|
|
17890
|
-
} = t, c =
|
|
17890
|
+
} = t, c = Uo(), l = St(i);
|
|
17891
17891
|
return c.useSyncedValueWithCleanup("titleElementId", l), Ne("h2", t, {
|
|
17892
17892
|
ref: n,
|
|
17893
17893
|
props: [{
|
|
@@ -17907,7 +17907,7 @@ const Pd = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
17907
17907
|
payload: l,
|
|
17908
17908
|
handle: d,
|
|
17909
17909
|
...f
|
|
17910
|
-
} = t, p =
|
|
17910
|
+
} = t, p = Uo(!0), m = md(d) ?? p;
|
|
17911
17911
|
if (!m)
|
|
17912
17912
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: <Dialog.Trigger> must be used within <Dialog.Root> or provided with a handle." : nt(79));
|
|
17913
17913
|
const g = St(c), x = m.useState("floatingRootContext"), b = m.useState("isOpenedByTrigger", g), y = m.useState("triggerPopupId", g), v = w.useRef(null), {
|
|
@@ -18108,7 +18108,7 @@ function vs({
|
|
|
18108
18108
|
function cQ({ children: e }) {
|
|
18109
18109
|
return /* @__PURE__ */ u(el, { render: e });
|
|
18110
18110
|
}
|
|
18111
|
-
function
|
|
18111
|
+
function jo({
|
|
18112
18112
|
trigger: e,
|
|
18113
18113
|
open: t,
|
|
18114
18114
|
onOpenChange: n,
|
|
@@ -19633,7 +19633,7 @@ function Yz(e) {
|
|
|
19633
19633
|
const _ = fn(T, {
|
|
19634
19634
|
disabledIndices: f
|
|
19635
19635
|
});
|
|
19636
|
-
|
|
19636
|
+
Io(T, _) || E(_);
|
|
19637
19637
|
}
|
|
19638
19638
|
Ay(x.current, D, s, n);
|
|
19639
19639
|
});
|
|
@@ -19645,7 +19645,7 @@ function Yz(e) {
|
|
|
19645
19645
|
const T = fn(M, {
|
|
19646
19646
|
disabledIndices: f
|
|
19647
19647
|
});
|
|
19648
|
-
|
|
19648
|
+
Io(M, T) || E(T);
|
|
19649
19649
|
}
|
|
19650
19650
|
}, [f, i, C, y, E]);
|
|
19651
19651
|
const N = ve((M, T, D) => o ? o(M, T, D, y) : D), k = ve((M) => {
|
|
@@ -19677,7 +19677,7 @@ function Yz(e) {
|
|
|
19677
19677
|
startingIndex: H,
|
|
19678
19678
|
decrement: U,
|
|
19679
19679
|
disabledIndices: f
|
|
19680
|
-
})), H !== C && !
|
|
19680
|
+
})), H !== C && !Io(y.current, H) && (d && M.stopPropagation(), (g || T || L || U) && M.preventDefault(), E(H, !0), queueMicrotask(() => {
|
|
19681
19681
|
y.current[H]?.focus();
|
|
19682
19682
|
}));
|
|
19683
19683
|
});
|
|
@@ -19787,7 +19787,7 @@ const ik = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
19787
19787
|
render: f,
|
|
19788
19788
|
style: p,
|
|
19789
19789
|
...h
|
|
19790
|
-
} = t, m =
|
|
19790
|
+
} = t, m = Ho(!0), g = $g(), x = l !== void 0 || r !== void 0, b = (m?.disabled ?? !1) || (g?.disabled ?? !1) || o, [y, v] = un({
|
|
19791
19791
|
controlled: l,
|
|
19792
19792
|
default: l === void 0 ? r ?? In : void 0,
|
|
19793
19793
|
name: "ToggleGroup",
|
|
@@ -19849,7 +19849,7 @@ const _d = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
19849
19849
|
});
|
|
19850
19850
|
process.env.NODE_ENV !== "production" && (_d.displayName = "Separator");
|
|
19851
19851
|
const ak = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
19852
|
-
const o =
|
|
19852
|
+
const o = Ho().orientation === "vertical" ? "horizontal" : "vertical";
|
|
19853
19853
|
return /* @__PURE__ */ u(_d, {
|
|
19854
19854
|
orientation: o,
|
|
19855
19855
|
...t,
|
|
@@ -19908,7 +19908,7 @@ const ck = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
19908
19908
|
} = t, {
|
|
19909
19909
|
orientation: c,
|
|
19910
19910
|
disabled: l
|
|
19911
|
-
} =
|
|
19911
|
+
} = Ho(), d = l || o, f = w.useMemo(() => ({
|
|
19912
19912
|
disabled: d
|
|
19913
19913
|
}), [d]), h = Ne("div", t, {
|
|
19914
19914
|
state: {
|
|
@@ -19938,7 +19938,7 @@ const uk = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
19938
19938
|
} = t, {
|
|
19939
19939
|
disabled: d,
|
|
19940
19940
|
orientation: f
|
|
19941
|
-
} =
|
|
19941
|
+
} = Ho(), p = $g(), h = d || (p?.disabled ?? !1) || o, m = w.useMemo(() => ({
|
|
19942
19942
|
disabled: h,
|
|
19943
19943
|
focusableWhenDisabled: s
|
|
19944
19944
|
}), [h, s]), {
|
|
@@ -19988,7 +19988,7 @@ const dk = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
19988
19988
|
} = t, {
|
|
19989
19989
|
disabled: l,
|
|
19990
19990
|
orientation: d
|
|
19991
|
-
} =
|
|
19991
|
+
} = Ho(), f = $g(), p = l || (f?.disabled ?? !1) || i, h = w.useMemo(() => ({
|
|
19992
19992
|
disabled: p,
|
|
19993
19993
|
focusableWhenDisabled: o
|
|
19994
19994
|
}), [p, o]), {
|
|
@@ -21224,7 +21224,7 @@ function D5(e) {
|
|
|
21224
21224
|
const t = _k.exec(e);
|
|
21225
21225
|
return t ? t[2].length : 0;
|
|
21226
21226
|
}
|
|
21227
|
-
function
|
|
21227
|
+
function xo(e) {
|
|
21228
21228
|
return (t, n) => {
|
|
21229
21229
|
const r = oo(t, n)[0], o = xr(r.text), s = o ? r.text.slice(0, r.text.length - o.body.length) : "", i = o ? o.body : r.text, a = _k.exec(i), c = a ? a[1] : /^\s*/.exec(i)[0], l = a ? i.slice(a[0].length) : i.slice(c.length), d = e === 0 ? `${s}${c}${l}` : `${s}${c}${"#".repeat(e)} ${l}`;
|
|
21230
21230
|
return d === r.text ? null : Si(n, [r], [d]);
|
|
@@ -21233,7 +21233,7 @@ function bo(e) {
|
|
|
21233
21233
|
function hw(e) {
|
|
21234
21234
|
return (t, n) => {
|
|
21235
21235
|
const r = oo(t, n)[0], o = D5(r.text), s = Math.max(0, Math.min(6, o + e));
|
|
21236
|
-
return s === o ? null :
|
|
21236
|
+
return s === o ? null : xo(s)(t, n);
|
|
21237
21237
|
};
|
|
21238
21238
|
}
|
|
21239
21239
|
const _5 = /^(\s*)([-*+])(\s+)/, $5 = /^(\s*)(\d{1,9})([.)])(\s+)/;
|
|
@@ -21818,13 +21818,13 @@ const jg = [
|
|
|
21818
21818
|
{ key: "ctrl+k", label: "Ctrl+K", description: "Insert link", group: "formatting", command: j5() },
|
|
21819
21819
|
{ key: "ctrl+shift+i", label: "Ctrl+Shift+I", description: "Insert image", group: "formatting", request: "pickImages" },
|
|
21820
21820
|
/* Headings */
|
|
21821
|
-
{ key: "ctrl+0", label: "Ctrl+0", description: "Convert to paragraph", group: "headings", command:
|
|
21822
|
-
{ key: "ctrl+1", label: "Ctrl+1", description: "Heading 1", group: "headings", command:
|
|
21823
|
-
{ key: "ctrl+2", label: "Ctrl+2", description: "Heading 2", group: "headings", command:
|
|
21824
|
-
{ key: "ctrl+3", label: "Ctrl+3", description: "Heading 3", group: "headings", command:
|
|
21825
|
-
{ key: "ctrl+4", label: "Ctrl+4", description: "Heading 4", group: "headings", command:
|
|
21826
|
-
{ key: "ctrl+5", label: "Ctrl+5", description: "Heading 5", group: "headings", command:
|
|
21827
|
-
{ key: "ctrl+6", label: "Ctrl+6", description: "Heading 6", group: "headings", command:
|
|
21821
|
+
{ key: "ctrl+0", label: "Ctrl+0", description: "Convert to paragraph", group: "headings", command: xo(0) },
|
|
21822
|
+
{ key: "ctrl+1", label: "Ctrl+1", description: "Heading 1", group: "headings", command: xo(1) },
|
|
21823
|
+
{ key: "ctrl+2", label: "Ctrl+2", description: "Heading 2", group: "headings", command: xo(2) },
|
|
21824
|
+
{ key: "ctrl+3", label: "Ctrl+3", description: "Heading 3", group: "headings", command: xo(3) },
|
|
21825
|
+
{ key: "ctrl+4", label: "Ctrl+4", description: "Heading 4", group: "headings", command: xo(4) },
|
|
21826
|
+
{ key: "ctrl+5", label: "Ctrl+5", description: "Heading 5", group: "headings", command: xo(5) },
|
|
21827
|
+
{ key: "ctrl+6", label: "Ctrl+6", description: "Heading 6", group: "headings", command: xo(6) },
|
|
21828
21828
|
{ key: "ctrl+shift+comma", label: "Ctrl+Shift+,", description: "Decrease heading level", group: "headings", command: hw(-1) },
|
|
21829
21829
|
{ key: "ctrl+shift+period", label: "Ctrl+Shift+.", description: "Increase heading level", group: "headings", command: hw(1) },
|
|
21830
21830
|
/* Lists */
|
|
@@ -22938,7 +22938,7 @@ function zd(e) {
|
|
|
22938
22938
|
}
|
|
22939
22939
|
const Wg = /* @__PURE__ */ w.createContext(void 0);
|
|
22940
22940
|
process.env.NODE_ENV !== "production" && (Wg.displayName = "MenuRootContext");
|
|
22941
|
-
function
|
|
22941
|
+
function Go(e) {
|
|
22942
22942
|
const t = w.useContext(Wg);
|
|
22943
22943
|
if (t === void 0 && !e)
|
|
22944
22944
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: MenuRootContext is missing. Menu parts must be placed within <Menu.Root>." : nt(36));
|
|
@@ -22983,7 +22983,7 @@ function F4(e) {
|
|
|
22983
22983
|
onClick(h) {
|
|
22984
22984
|
t && l.emit("close", {
|
|
22985
22985
|
domEvent: h,
|
|
22986
|
-
reason:
|
|
22986
|
+
reason: Ro
|
|
22987
22987
|
});
|
|
22988
22988
|
},
|
|
22989
22989
|
onMouseUp(h) {
|
|
@@ -23070,7 +23070,7 @@ const Xg = {
|
|
|
23070
23070
|
label: i
|
|
23071
23071
|
}), x = zd(!0), b = St(s), {
|
|
23072
23072
|
store: y
|
|
23073
|
-
} =
|
|
23073
|
+
} = Go(), v = y.useState("disabled"), C = c || v, E = y.useState("isActive", g.index), S = y.useState("itemProps"), [N, k] = un({
|
|
23074
23074
|
controlled: d,
|
|
23075
23075
|
default: f ?? !1,
|
|
23076
23076
|
name: "MenuCheckboxItem",
|
|
@@ -23093,7 +23093,7 @@ const Xg = {
|
|
|
23093
23093
|
checked: N
|
|
23094
23094
|
}), [C, E, N]);
|
|
23095
23095
|
function D(_) {
|
|
23096
|
-
const P = Ie(
|
|
23096
|
+
const P = Ie(Ro, _.nativeEvent, void 0, {
|
|
23097
23097
|
preventUnmountOnClose: bt
|
|
23098
23098
|
});
|
|
23099
23099
|
p?.(!N, P), !P.isCanceled && k(($) => !$);
|
|
@@ -23178,7 +23178,7 @@ const Jk = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
23178
23178
|
label: i
|
|
23179
23179
|
}), h = zd(!0), m = St(s), {
|
|
23180
23180
|
store: g
|
|
23181
|
-
} =
|
|
23181
|
+
} = Go(), x = g.useState("disabled"), b = c || x, y = g.useState("isActive", p.index), v = g.useState("itemProps"), {
|
|
23182
23182
|
getItemProps: C,
|
|
23183
23183
|
itemRef: E
|
|
23184
23184
|
} = Yg({
|
|
@@ -23210,10 +23210,10 @@ const eN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
23210
23210
|
...a
|
|
23211
23211
|
} = t, {
|
|
23212
23212
|
store: c
|
|
23213
|
-
} =
|
|
23213
|
+
} = Go(), {
|
|
23214
23214
|
side: l,
|
|
23215
23215
|
align: d
|
|
23216
|
-
} = zd(), f =
|
|
23216
|
+
} = zd(), f = Ho(!0) != null, p = c.useState("open"), h = c.useState("transitionStatus"), m = c.useState("popupProps"), g = c.useState("mounted"), x = c.useState("instantType"), b = c.useState("activeTriggerElement"), y = c.useState("parent"), v = c.useState("lastOpenChangeReason"), C = c.useState("rootId"), E = c.useState("floatingRootContext"), S = c.useState("floatingTreeRoot"), N = c.useState("closeDelay"), k = c.useState("hoverEnabled"), I = c.useState("disabled"), M = c.useState("openMethod"), T = y.type === "context-menu";
|
|
23217
23217
|
tn({
|
|
23218
23218
|
open: p,
|
|
23219
23219
|
ref: c.context.popupRef,
|
|
@@ -23281,7 +23281,7 @@ const tN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
23281
23281
|
...o
|
|
23282
23282
|
} = t, {
|
|
23283
23283
|
store: s
|
|
23284
|
-
} =
|
|
23284
|
+
} = Go();
|
|
23285
23285
|
return s.useState("mounted") || r ? /* @__PURE__ */ u(Zg.Provider, {
|
|
23286
23286
|
value: r,
|
|
23287
23287
|
children: /* @__PURE__ */ u(bi, {
|
|
@@ -23311,7 +23311,7 @@ const nN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
23311
23311
|
...y
|
|
23312
23312
|
} = t, {
|
|
23313
23313
|
store: v
|
|
23314
|
-
} =
|
|
23314
|
+
} = Go(), C = V4(), E = qg(!0), S = v.useState("parent"), N = v.useState("floatingRootContext"), k = v.useState("floatingTreeRoot"), I = v.useState("mounted"), M = v.useState("open"), T = v.useState("modal"), D = v.useState("openMethod"), O = v.useState("activeTriggerElement"), _ = v.useState("transitionStatus"), P = v.useState("positionerElement"), $ = v.useState("instantType"), V = v.useState("adaptiveOrigin"), F = v.useState("lastOpenChangeReason"), H = v.useState("floatingNodeId"), A = v.useState("floatingParentNodeId"), z = N.useState("domReferenceElement"), L = w.useRef(null), U = id(P);
|
|
23315
23315
|
let G = r, Y = l, q = d, X = c, W = x;
|
|
23316
23316
|
S.type === "context-menu" && (G = r ?? S.context?.anchor, X = X ?? "start", !a && X !== "center" && (q = t.alignOffset ?? 2, Y = t.sideOffset ?? -5));
|
|
23317
23317
|
let j = a, te = X;
|
|
@@ -23507,7 +23507,7 @@ const oN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
23507
23507
|
label: i
|
|
23508
23508
|
}), m = zd(!0), g = St(s), {
|
|
23509
23509
|
store: x
|
|
23510
|
-
} =
|
|
23510
|
+
} = Go(), b = x.useState("isActive", h.index), y = x.useState("itemProps"), {
|
|
23511
23511
|
value: v,
|
|
23512
23512
|
setValue: C,
|
|
23513
23513
|
disabled: E
|
|
@@ -23529,7 +23529,7 @@ const oN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
23529
23529
|
checked: k
|
|
23530
23530
|
}), [N, b, k]);
|
|
23531
23531
|
function D(_) {
|
|
23532
|
-
const P = Ie(
|
|
23532
|
+
const P = Ie(Ro, _.nativeEvent, void 0, {
|
|
23533
23533
|
preventUnmountOnClose: bt
|
|
23534
23534
|
});
|
|
23535
23535
|
C(d, P);
|
|
@@ -23713,7 +23713,7 @@ const cN = Um(function(t) {
|
|
|
23713
23713
|
triggerId: m,
|
|
23714
23714
|
defaultTriggerId: g = null,
|
|
23715
23715
|
highlightItemOnHover: x = !0
|
|
23716
|
-
} = t, b = qg(!0), y =
|
|
23716
|
+
} = t, b = qg(!0), y = Go(!0), v = aN(!0), C = W4(), E = w.useMemo(() => C && y ? {
|
|
23717
23717
|
type: "menu",
|
|
23718
23718
|
store: y.store
|
|
23719
23719
|
} : v ? {
|
|
@@ -23732,7 +23732,7 @@ const cN = Um(function(t) {
|
|
|
23732
23732
|
parent: E
|
|
23733
23733
|
});
|
|
23734
23734
|
S.useControlledProp("openProp", r), S.useControlledProp("triggerIdProp", m), S.useContextCallback("onOpenChangeComplete", s);
|
|
23735
|
-
const N =
|
|
23735
|
+
const N = Do(), k = Do(), I = S.useState("floatingTreeRoot"), M = Vm(I), T = zo(), D = S.useState("open"), O = S.useState("activeTriggerElement"), _ = S.useState("positionerElement"), P = S.useState("hoverEnabled"), $ = S.useState("disabled"), V = S.useState("lastOpenChangeReason"), F = S.useState("parent"), H = S.useState("activeIndex"), A = S.useState("payload"), z = S.useState("floatingParentNodeId"), L = w.useRef(null), U = w.useRef(F.type !== "context-menu"), G = Nt(), Y = w.useRef(!0), q = Nt(), X = z != null;
|
|
23736
23736
|
process.env.NODE_ENV !== "production" && F.type !== void 0 && c !== void 0 && console.warn("Base UI: The `modal` prop is not supported on nested menus. It will be ignored.");
|
|
23737
23737
|
const {
|
|
23738
23738
|
openMethod: W,
|
|
@@ -23789,7 +23789,7 @@ const cN = Um(function(t) {
|
|
|
23789
23789
|
ee && ke === Ws ? (Y.current = !1, q.start(300, () => {
|
|
23790
23790
|
Y.current = !0;
|
|
23791
23791
|
})) : (Y.current = !0, q.clear());
|
|
23792
|
-
const Oe = (ke === Lr || ke ===
|
|
23792
|
+
const Oe = (ke === Lr || ke === Ro) && _e.detail === 0, Me = !ee && (ke === Es || ke == null), Ye = {
|
|
23793
23793
|
open: ee,
|
|
23794
23794
|
openChangeReason: ke
|
|
23795
23795
|
};
|
|
@@ -23969,10 +23969,10 @@ const dN = yE(function(t, n) {
|
|
|
23969
23969
|
handle: p,
|
|
23970
23970
|
payload: h,
|
|
23971
23971
|
...m
|
|
23972
|
-
} = t, g =
|
|
23972
|
+
} = t, g = Go(!0), b = md(p) ?? g?.store;
|
|
23973
23973
|
if (!b)
|
|
23974
23974
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: <Menu.Trigger> must be either used within a <Menu.Root> component or provided with a handle." : nt(85));
|
|
23975
|
-
const y = St(c), v = b.useState("isTriggerActive", y), C = b.useState("floatingRootContext"), E = b.useState("isOpenedByTrigger", y), S = b.useState("triggerPopupId", y), N = w.useRef(null), k = Z4(), I = bd(!0), M =
|
|
23975
|
+
const y = St(c), v = b.useState("isTriggerActive", y), C = b.useState("floatingRootContext"), E = b.useState("isOpenedByTrigger", y), S = b.useState("triggerPopupId", y), N = w.useRef(null), k = Z4(), I = bd(!0), M = Bo(), T = w.useMemo(() => M ?? new $m(), [M]), D = Vm(T), O = zo(), {
|
|
23976
23976
|
registerTrigger: _,
|
|
23977
23977
|
isMountedByThisTrigger: P
|
|
23978
23978
|
} = cd(y, N, b, {
|
|
@@ -25677,7 +25677,7 @@ function z3({
|
|
|
25677
25677
|
/* @__PURE__ */ u("span", { className: "flex-1", children: "This secret will be removed when you save." }),
|
|
25678
25678
|
/* @__PURE__ */ u(Ze, { variant: "link", size: "xs", disabled: p, onClick: _, children: "Undo" })
|
|
25679
25679
|
] }) : T && /* @__PURE__ */ u("div", { children: /* @__PURE__ */ u(
|
|
25680
|
-
|
|
25680
|
+
jo,
|
|
25681
25681
|
{
|
|
25682
25682
|
open: E,
|
|
25683
25683
|
onOpenChange: S,
|
|
@@ -25754,7 +25754,7 @@ function Hd() {
|
|
|
25754
25754
|
return e;
|
|
25755
25755
|
}
|
|
25756
25756
|
const H3 = 500, yh = 16;
|
|
25757
|
-
function
|
|
25757
|
+
function Co(e, t, n) {
|
|
25758
25758
|
if (!e)
|
|
25759
25759
|
return 0;
|
|
25760
25760
|
const r = getComputedStyle(e), o = `${t}${n === "x" ? "Inline" : "Block"}`, s = parseFloat(r[`${o}Start`]);
|
|
@@ -25858,7 +25858,7 @@ const j3 = {
|
|
|
25858
25858
|
const ee = se.current === "vertical", ye = ee ? U.current : G.current, ke = ee ? z.current : L.current;
|
|
25859
25859
|
if (!ye || !ke)
|
|
25860
25860
|
return;
|
|
25861
|
-
const Fe = ee ? "y" : "x", _e =
|
|
25861
|
+
const Fe = ee ? "y" : "x", _e = Co(ke, "padding", Fe), Oe = Co(ye, "margin", Fe), Me = ee ? ye.offsetHeight : ye.offsetWidth, he = (ee ? ke.offsetHeight : ke.offsetWidth) - Me - _e - Oe, pe = ee ? we.clientY - X.current : we.clientX - W.current, Ce = he <= 0 ? 0 : pe / he, Te = ee ? Z.scrollHeight : Z.scrollWidth, Be = ee ? Z.clientHeight : Z.clientWidth, Ve = (ee ? j.current : te.current) + Ce * (Te - Be);
|
|
25862
25862
|
ee ? Z.scrollTop = Ve : Z.scrollLeft = Ve, we.preventDefault(), J(ee);
|
|
25863
25863
|
});
|
|
25864
25864
|
function le(we) {
|
|
@@ -26030,7 +26030,7 @@ const kN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
26030
26030
|
const oe = ae ? 0 : wh(te, le), Q = ae ? 0 : le - oe, de = fe ? 0 : j, we = ae ? 0 : W;
|
|
26031
26031
|
let Z = 0, ee = 0;
|
|
26032
26032
|
!fe && !ae && (Z = z?.offsetWidth || 0, ee = L?.offsetHeight || 0);
|
|
26033
|
-
const ye = h.width === 0 && h.height === 0, ke = ye ? Z : 0, Fe = ye ? ee : 0, _e =
|
|
26033
|
+
const ye = h.width === 0 && h.height === 0, ke = ye ? Z : 0, Fe = ye ? ee : 0, _e = Co(L, "padding", "x"), Oe = Co(z, "padding", "y"), Me = Co(G, "margin", "x"), Ye = Co(U, "margin", "y"), he = de - _e - Me, pe = we - Oe - Ye, Ce = L ? Math.min(L.offsetWidth - ke, he) : he, Te = z ? Math.min(z.offsetHeight - Fe, pe) : pe, Be = Math.max(yh, Ce * me), Qe = Math.max(yh, Te * ce);
|
|
26034
26034
|
if (g((He) => nc(He, {
|
|
26035
26035
|
width: Be,
|
|
26036
26036
|
height: Qe
|
|
@@ -26224,7 +26224,7 @@ const Ch = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
26224
26224
|
const L = M ? h.current : m.current;
|
|
26225
26225
|
if (!A || !L)
|
|
26226
26226
|
return;
|
|
26227
|
-
const U = M ? "y" : "x", G =
|
|
26227
|
+
const U = M ? "y" : "x", G = Co(A, "margin", U), Y = Co(L, "padding", U), q = M ? A.offsetHeight : A.offsetWidth, X = L.getBoundingClientRect(), W = M ? F.clientY - X.top - q / 2 - Y + G / 2 : F.clientX - X.left - q / 2 - Y + G / 2, j = M ? z.scrollHeight : z.scrollWidth, te = M ? z.clientHeight : z.clientWidth, re = (M ? L.offsetHeight : L.offsetWidth) - q - Y - G;
|
|
26228
26228
|
if (re <= 0)
|
|
26229
26229
|
return;
|
|
26230
26230
|
const K = W / re, J = j - te;
|
|
@@ -27393,7 +27393,7 @@ const pB = "data-parent", zN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
27393
27393
|
id: C ? void 0 : se ?? void 0,
|
|
27394
27394
|
required: b,
|
|
27395
27395
|
ref: _e,
|
|
27396
|
-
style: X ?
|
|
27396
|
+
style: X ? Lo : qn,
|
|
27397
27397
|
tabIndex: -1,
|
|
27398
27398
|
type: "checkbox",
|
|
27399
27399
|
"aria-hidden": !0,
|
|
@@ -27632,7 +27632,7 @@ const HN = {
|
|
|
27632
27632
|
id: G,
|
|
27633
27633
|
name: F,
|
|
27634
27634
|
required: m,
|
|
27635
|
-
style: F ?
|
|
27635
|
+
style: F ? Lo : qn,
|
|
27636
27636
|
tabIndex: -1,
|
|
27637
27637
|
type: "checkbox",
|
|
27638
27638
|
"aria-hidden": !0,
|
|
@@ -27820,7 +27820,7 @@ const GN = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
27820
27820
|
id: te,
|
|
27821
27821
|
name: N,
|
|
27822
27822
|
tabIndex: -1,
|
|
27823
|
-
style: N ?
|
|
27823
|
+
style: N ? Lo : qn,
|
|
27824
27824
|
"aria-hidden": !0,
|
|
27825
27825
|
...l !== void 0 ? {
|
|
27826
27826
|
value: mu(l)
|
|
@@ -29164,7 +29164,7 @@ function tR(e, t, n) {
|
|
|
29164
29164
|
setDescriptionId: s
|
|
29165
29165
|
} = vb(), i = n === "title" ? o : s, a = t ?? (n === "title" ? r.title : r.description);
|
|
29166
29166
|
return {
|
|
29167
|
-
id:
|
|
29167
|
+
id: Do(e),
|
|
29168
29168
|
children: a,
|
|
29169
29169
|
type: r.type,
|
|
29170
29170
|
setId: i
|
|
@@ -30871,7 +30871,7 @@ function pH(e) {
|
|
|
30871
30871
|
return { platform: e, steps: "Turn off the reduce-motion (or remove-animations) setting in your system's accessibility settings." };
|
|
30872
30872
|
}
|
|
30873
30873
|
}
|
|
30874
|
-
const
|
|
30874
|
+
const Zo = ["sm", "md", "lg"], hH = [
|
|
30875
30875
|
{ value: "system", label: "System" },
|
|
30876
30876
|
{ value: "full", label: "Full" },
|
|
30877
30877
|
{ value: "reduced", label: "Reduced" }
|
|
@@ -30911,7 +30911,7 @@ function xH({
|
|
|
30911
30911
|
] });
|
|
30912
30912
|
}
|
|
30913
30913
|
function DQ({ className: e, triggerClassName: t, iconOnly: n = !1 }) {
|
|
30914
|
-
const { theme: r, setTheme: o } = oH(), { scale: s, setScale: i } = sH(), { contrast: a, setContrast: c } = iH(), { motion: l, setMotion: d } = aH(), f = dH(), p = Nb(TR), h =
|
|
30914
|
+
const { theme: r, setTheme: o } = oH(), { scale: s, setScale: i } = sH(), { contrast: a, setContrast: c } = iH(), { motion: l, setMotion: d } = aH(), f = dH(), p = Nb(TR), h = Zo.indexOf(s);
|
|
30915
30915
|
return /* @__PURE__ */ u(
|
|
30916
30916
|
gn,
|
|
30917
30917
|
{
|
|
@@ -30962,17 +30962,17 @@ function DQ({ className: e, triggerClassName: t, iconOnly: n = !1 }) {
|
|
|
30962
30962
|
/* @__PURE__ */ R("div", { className: "flex flex-col gap-2", children: [
|
|
30963
30963
|
/* @__PURE__ */ u("span", { className: "text-2xs font-semibold tracking-widest text-tertiary uppercase", children: "Text size" }),
|
|
30964
30964
|
/* @__PURE__ */ R("div", { className: "px-[calc(var(--spacing)*2.75)]", children: [
|
|
30965
|
-
/* @__PURE__ */ u("div", { className: "relative h-5 select-none", "aria-hidden": !0, children:
|
|
30965
|
+
/* @__PURE__ */ u("div", { className: "relative h-5 select-none", "aria-hidden": !0, children: Zo.map((m, g) => /* @__PURE__ */ u(
|
|
30966
30966
|
"span",
|
|
30967
30967
|
{
|
|
30968
30968
|
className: s === m ? "absolute bottom-0 -translate-x-1/2 font-display leading-none text-accent-text" : "absolute bottom-0 -translate-x-1/2 font-display leading-none text-tertiary",
|
|
30969
30969
|
style: {
|
|
30970
|
-
left: `${g / (
|
|
30970
|
+
left: `${g / (Zo.length - 1) * 100}%`,
|
|
30971
30971
|
fontSize: bH[m],
|
|
30972
30972
|
/* `translate`, not `transform` — same Tailwind v4 property as
|
|
30973
30973
|
the Slider's own extreme labels. */
|
|
30974
30974
|
...g === 0 ? { translate: "none", left: 0 } : {},
|
|
30975
|
-
...g ===
|
|
30975
|
+
...g === Zo.length - 1 ? { translate: "none", left: "auto", right: 0 } : {}
|
|
30976
30976
|
},
|
|
30977
30977
|
children: "Aa"
|
|
30978
30978
|
},
|
|
@@ -30986,11 +30986,11 @@ function DQ({ className: e, triggerClassName: t, iconOnly: n = !1 }) {
|
|
|
30986
30986
|
max: 2,
|
|
30987
30987
|
step: 1,
|
|
30988
30988
|
value: h,
|
|
30989
|
-
onValueChange: (m) => i(
|
|
30989
|
+
onValueChange: (m) => i(Zo[Number(m)]),
|
|
30990
30990
|
showValue: !1,
|
|
30991
30991
|
tooltip: "never",
|
|
30992
|
-
marks:
|
|
30993
|
-
format: (m) => Hw[
|
|
30992
|
+
marks: Zo.map((m, g) => ({ value: g, label: Hw[m] })),
|
|
30993
|
+
format: (m) => Hw[Zo[m]]
|
|
30994
30994
|
}
|
|
30995
30995
|
)
|
|
30996
30996
|
] })
|
|
@@ -33343,7 +33343,7 @@ const nI = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
33343
33343
|
required: l,
|
|
33344
33344
|
"aria-hidden": !0,
|
|
33345
33345
|
tabIndex: -1,
|
|
33346
|
-
style: z ?
|
|
33346
|
+
style: z ? Lo : qn,
|
|
33347
33347
|
suppressHydrationWarning: !0
|
|
33348
33348
|
})]
|
|
33349
33349
|
});
|
|
@@ -34398,7 +34398,7 @@ const dI = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
34398
34398
|
required: C,
|
|
34399
34399
|
"aria-hidden": !0,
|
|
34400
34400
|
tabIndex: -1,
|
|
34401
|
-
style: q ?
|
|
34401
|
+
style: q ? Lo : qn
|
|
34402
34402
|
})]
|
|
34403
34403
|
})
|
|
34404
34404
|
});
|
|
@@ -34645,7 +34645,7 @@ function Q6(e, t, n, r, o, s, i, a, c, l = 2) {
|
|
|
34645
34645
|
prevIndex: t > c ? a : t,
|
|
34646
34646
|
stopEvent: !0
|
|
34647
34647
|
});
|
|
34648
|
-
return
|
|
34648
|
+
return Io(n.current, d) ? void 0 : d;
|
|
34649
34649
|
}
|
|
34650
34650
|
const Fb = /* @__PURE__ */ w.createContext(void 0);
|
|
34651
34651
|
process.env.NODE_ENV !== "production" && (Fb.displayName = "ComboboxRootContext");
|
|
@@ -35125,7 +35125,7 @@ function oU(e) {
|
|
|
35125
35125
|
}), CP = ve((Le, Ue) => {
|
|
35126
35126
|
const _t = Et(Le), $t = Fe.current ?? Le;
|
|
35127
35127
|
Fe.current = null;
|
|
35128
|
-
const sn = Ie(
|
|
35128
|
+
const sn = Ie(Ro, $t), _n = _t?.closest("a")?.getAttribute("href");
|
|
35129
35129
|
if (_n) {
|
|
35130
35130
|
_n.startsWith("#") && Fi(!1, sn);
|
|
35131
35131
|
return;
|
|
@@ -35440,7 +35440,7 @@ function oU(e) {
|
|
|
35440
35440
|
readOnly: g,
|
|
35441
35441
|
value: IP,
|
|
35442
35442
|
ref: NP,
|
|
35443
|
-
style: If ?
|
|
35443
|
+
style: If ? Lo : qn,
|
|
35444
35444
|
tabIndex: -1,
|
|
35445
35445
|
"aria-hidden": !0,
|
|
35446
35446
|
suppressHydrationWarning: !0
|
|
@@ -35531,7 +35531,7 @@ const Kb = /* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
35531
35531
|
...c,
|
|
35532
35532
|
"aria-label": "Dismiss",
|
|
35533
35533
|
tabIndex: void 0,
|
|
35534
|
-
style:
|
|
35534
|
+
style: Lo
|
|
35535
35535
|
});
|
|
35536
35536
|
});
|
|
35537
35537
|
process.env.NODE_ENV !== "production" && (Kb.displayName = "ComboboxInternalDismissButton");
|
|
@@ -37096,7 +37096,7 @@ function wU(e) {
|
|
|
37096
37096
|
required: h && !(v && Ye),
|
|
37097
37097
|
readOnly: p,
|
|
37098
37098
|
ref: ze,
|
|
37099
|
-
style: z ?
|
|
37099
|
+
style: z ? Lo : qn,
|
|
37100
37100
|
tabIndex: -1,
|
|
37101
37101
|
"aria-hidden": !0,
|
|
37102
37102
|
suppressHydrationWarning: !0
|
|
@@ -37434,7 +37434,7 @@ const NU = {
|
|
|
37434
37434
|
alignItemWithTriggerActive: N,
|
|
37435
37435
|
isPositioned: k,
|
|
37436
37436
|
setControlledAlignItemWithTrigger: I
|
|
37437
|
-
} = XI(), M =
|
|
37437
|
+
} = XI(), M = Ho(!0) != null, T = cr(), {
|
|
37438
37438
|
nonce: D,
|
|
37439
37439
|
disableStyleElements: O
|
|
37440
37440
|
} = ib(), _ = xe(c, lt.id), P = xe(c, lt.open), $ = xe(c, lt.openMethod), V = xe(c, lt.mounted), F = xe(c, lt.popupProps), H = xe(c, lt.transitionStatus), A = xe(c, lt.triggerElement), z = xe(c, lt.positionerElement), L = xe(c, lt.listElement), U = w.useRef(!1), G = w.useRef(!1), Y = w.useRef({}), q = gs(), X = ve((se) => {
|
|
@@ -37718,9 +37718,9 @@ const tM = /* @__PURE__ */ w.memo(/* @__PURE__ */ w.forwardRef(function(t, n) {
|
|
|
37718
37718
|
const X = h.state.value;
|
|
37719
37719
|
if (C) {
|
|
37720
37720
|
const W = Array.isArray(X) ? X : [], j = T ? mI(W, i, O) : [...W, i];
|
|
37721
|
-
x(j, Ie(
|
|
37721
|
+
x(j, Ie(Ro, q));
|
|
37722
37722
|
} else
|
|
37723
|
-
x(i, Ie(
|
|
37723
|
+
x(i, Ie(Ro, q)), g(!1, Ie(Ro, q));
|
|
37724
37724
|
}
|
|
37725
37725
|
function L() {
|
|
37726
37726
|
b.current.dragY = 0;
|
|
@@ -38125,7 +38125,7 @@ function aM({
|
|
|
38125
38125
|
]
|
|
38126
38126
|
}
|
|
38127
38127
|
);
|
|
38128
|
-
return p ? /* @__PURE__ */ u("div", { children: m }, d.value) : /* @__PURE__ */ u(
|
|
38128
|
+
return p ? /* @__PURE__ */ u("div", { children: m }, d.value) : /* @__PURE__ */ u(vo, { children: m }, d.value);
|
|
38129
38129
|
}) })
|
|
38130
38130
|
}
|
|
38131
38131
|
);
|
|
@@ -38178,7 +38178,7 @@ function QQ({
|
|
|
38178
38178
|
] }),
|
|
38179
38179
|
/* @__PURE__ */ u("span", { className: "flex shrink-0 items-center gap-0.5", children: ["asc", "desc"].map((p) => {
|
|
38180
38180
|
const h = f.value === t.field && p === t.direction, m = l0(f, p);
|
|
38181
|
-
return /* @__PURE__ */ u(
|
|
38181
|
+
return /* @__PURE__ */ u(vo, { children: /* @__PURE__ */ u(
|
|
38182
38182
|
ot,
|
|
38183
38183
|
{
|
|
38184
38184
|
icon: /* @__PURE__ */ u(ie, { name: p === "asc" ? "arrow-up" : "arrow-down", size: "xs" }),
|
|
@@ -41290,14 +41290,14 @@ function bJ(e) {
|
|
|
41290
41290
|
] })
|
|
41291
41291
|
);
|
|
41292
41292
|
}
|
|
41293
|
-
function
|
|
41293
|
+
function Eo(e, t) {
|
|
41294
41294
|
return typeof e == "function" ? e(t) : e;
|
|
41295
41295
|
}
|
|
41296
41296
|
function Kn(e, t) {
|
|
41297
41297
|
return (n) => {
|
|
41298
41298
|
t.setState((r) => ({
|
|
41299
41299
|
...r,
|
|
41300
|
-
[e]:
|
|
41300
|
+
[e]: Eo(n, r[e])
|
|
41301
41301
|
}));
|
|
41302
41302
|
};
|
|
41303
41303
|
}
|
|
@@ -41680,7 +41680,7 @@ const Oj = {
|
|
|
41680
41680
|
return (n = (r = t.getState().columnFilters) == null ? void 0 : r.findIndex((o) => o.id === e.id)) != null ? n : -1;
|
|
41681
41681
|
}, e.setFilterValue = (n) => {
|
|
41682
41682
|
t.setColumnFilters((r) => {
|
|
41683
|
-
const o = e.getFilterFn(), s = r?.find((d) => d.id === e.id), i =
|
|
41683
|
+
const o = e.getFilterFn(), s = r?.find((d) => d.id === e.id), i = Eo(n, s ? s.value : void 0);
|
|
41684
41684
|
if (N0(o, i, e)) {
|
|
41685
41685
|
var a;
|
|
41686
41686
|
return (a = r?.filter((d) => d.id !== e.id)) != null ? a : [];
|
|
@@ -41704,7 +41704,7 @@ const Oj = {
|
|
|
41704
41704
|
e.setColumnFilters = (t) => {
|
|
41705
41705
|
const n = e.getAllLeafColumns(), r = (o) => {
|
|
41706
41706
|
var s;
|
|
41707
|
-
return (s =
|
|
41707
|
+
return (s = Eo(t, o)) == null ? void 0 : s.filter((i) => {
|
|
41708
41708
|
const a = n.find((c) => c.id === i.id);
|
|
41709
41709
|
if (a) {
|
|
41710
41710
|
const c = a.getFilterFn();
|
|
@@ -42329,14 +42329,14 @@ const Xj = {
|
|
|
42329
42329
|
});
|
|
42330
42330
|
}
|
|
42331
42331
|
}, e.setPagination = (r) => {
|
|
42332
|
-
const o = (s) =>
|
|
42332
|
+
const o = (s) => Eo(r, s);
|
|
42333
42333
|
return e.options.onPaginationChange == null ? void 0 : e.options.onPaginationChange(o);
|
|
42334
42334
|
}, e.resetPagination = (r) => {
|
|
42335
42335
|
var o;
|
|
42336
42336
|
e.setPagination(r ? xp() : (o = e.initialState.pagination) != null ? o : xp());
|
|
42337
42337
|
}, e.setPageIndex = (r) => {
|
|
42338
42338
|
e.setPagination((o) => {
|
|
42339
|
-
let s =
|
|
42339
|
+
let s = Eo(r, o.pageIndex);
|
|
42340
42340
|
const i = typeof e.options.pageCount > "u" || e.options.pageCount === -1 ? Number.MAX_SAFE_INTEGER : e.options.pageCount - 1;
|
|
42341
42341
|
return s = Math.max(0, Math.min(s, i)), {
|
|
42342
42342
|
...o,
|
|
@@ -42351,7 +42351,7 @@ const Xj = {
|
|
|
42351
42351
|
e.setPageSize(r ? Ph : (o = (s = e.initialState) == null || (s = s.pagination) == null ? void 0 : s.pageSize) != null ? o : Ph);
|
|
42352
42352
|
}, e.setPageSize = (r) => {
|
|
42353
42353
|
e.setPagination((o) => {
|
|
42354
|
-
const s = Math.max(1,
|
|
42354
|
+
const s = Math.max(1, Eo(r, o.pageSize)), i = o.pageSize * o.pageIndex, a = Math.floor(i / s);
|
|
42355
42355
|
return {
|
|
42356
42356
|
...o,
|
|
42357
42357
|
pageIndex: a,
|
|
@@ -42360,7 +42360,7 @@ const Xj = {
|
|
|
42360
42360
|
});
|
|
42361
42361
|
}, e.setPageCount = (r) => e.setPagination((o) => {
|
|
42362
42362
|
var s;
|
|
42363
|
-
let i =
|
|
42363
|
+
let i = Eo(r, (s = e.options.pageCount) != null ? s : -1);
|
|
42364
42364
|
return typeof i == "number" && (i = Math.max(-1, i)), {
|
|
42365
42365
|
...o,
|
|
42366
42366
|
pageCount: i
|
|
@@ -42641,14 +42641,14 @@ function Ah(e, t, n) {
|
|
|
42641
42641
|
}
|
|
42642
42642
|
}), o ? "all" : s ? "some" : !1;
|
|
42643
42643
|
}
|
|
42644
|
-
const Dh = /([0-9]+)/gm, nG = (e, t, n) => GM(
|
|
42644
|
+
const Dh = /([0-9]+)/gm, nG = (e, t, n) => GM(_o(e.getValue(n)).toLowerCase(), _o(t.getValue(n)).toLowerCase()), rG = (e, t, n) => GM(_o(e.getValue(n)), _o(t.getValue(n))), oG = (e, t, n) => Nx(_o(e.getValue(n)).toLowerCase(), _o(t.getValue(n)).toLowerCase()), sG = (e, t, n) => Nx(_o(e.getValue(n)), _o(t.getValue(n))), iG = (e, t, n) => {
|
|
42645
42645
|
const r = e.getValue(n), o = t.getValue(n);
|
|
42646
42646
|
return r > o ? 1 : r < o ? -1 : 0;
|
|
42647
42647
|
}, aG = (e, t, n) => Nx(e.getValue(n), t.getValue(n));
|
|
42648
42648
|
function Nx(e, t) {
|
|
42649
42649
|
return e === t ? 0 : e > t ? 1 : -1;
|
|
42650
42650
|
}
|
|
42651
|
-
function
|
|
42651
|
+
function _o(e) {
|
|
42652
42652
|
return typeof e == "number" ? isNaN(e) || e === 1 / 0 || e === -1 / 0 ? "" : String(e) : typeof e == "string" ? e : "";
|
|
42653
42653
|
}
|
|
42654
42654
|
function GM(e, t) {
|
|
@@ -42828,7 +42828,7 @@ function uG(e) {
|
|
|
42828
42828
|
o.setState(o.initialState);
|
|
42829
42829
|
},
|
|
42830
42830
|
setOptions: (p) => {
|
|
42831
|
-
const h =
|
|
42831
|
+
const h = Eo(p, o.options);
|
|
42832
42832
|
o.options = i(h);
|
|
42833
42833
|
},
|
|
42834
42834
|
getState: () => o.options.state,
|
|
@@ -47163,7 +47163,7 @@ function Fa(e, t, n) {
|
|
|
47163
47163
|
function M2(e, t, n) {
|
|
47164
47164
|
return pn(e, t) + n * zx(e, t);
|
|
47165
47165
|
}
|
|
47166
|
-
function
|
|
47166
|
+
function So(e, t, n, r = "compatible") {
|
|
47167
47167
|
const { days: o = 0, hours: s = 0, minutes: i = 0 } = n;
|
|
47168
47168
|
let a = t;
|
|
47169
47169
|
if (o !== 0) {
|
|
@@ -49450,7 +49450,7 @@ function UJ(e, t, n, r) {
|
|
|
49450
49450
|
return o + Math.round((s - o) / i) * i;
|
|
49451
49451
|
}
|
|
49452
49452
|
const jJ = Vn, Q0 = /* @__PURE__ */ new Map();
|
|
49453
|
-
function
|
|
49453
|
+
function Wo(e, t) {
|
|
49454
49454
|
const n = `${e ?? ""}|${JSON.stringify(t)}`;
|
|
49455
49455
|
let r = Q0.get(n);
|
|
49456
49456
|
return r || (r = new Intl.DateTimeFormat(e, t), Q0.set(n, r)), r;
|
|
@@ -49461,16 +49461,16 @@ function Jr(e) {
|
|
|
49461
49461
|
}
|
|
49462
49462
|
const Ai = { timeZone: "UTC" };
|
|
49463
49463
|
function Uh(e, t, n) {
|
|
49464
|
-
return
|
|
49464
|
+
return Wo(n, { ...Ai, weekday: t }).format(Jr(e));
|
|
49465
49465
|
}
|
|
49466
49466
|
function z2(e, t) {
|
|
49467
|
-
return
|
|
49467
|
+
return Wo(t, { ...Ai, day: "numeric" }).format(Jr(e));
|
|
49468
49468
|
}
|
|
49469
49469
|
function GJ(e, t) {
|
|
49470
|
-
return
|
|
49470
|
+
return Wo(t, { ...Ai, year: "numeric", month: "long" }).format(Jr(e));
|
|
49471
49471
|
}
|
|
49472
49472
|
function Ru(e, t) {
|
|
49473
|
-
return
|
|
49473
|
+
return Wo(t, {
|
|
49474
49474
|
...Ai,
|
|
49475
49475
|
weekday: "long",
|
|
49476
49476
|
day: "numeric",
|
|
@@ -49480,10 +49480,10 @@ function Ru(e, t) {
|
|
|
49480
49480
|
}
|
|
49481
49481
|
function io(e, t, n, r = !0) {
|
|
49482
49482
|
const o = Un(t, e), s = !r || o.minute === 0 ? { timeZone: t, hour: "numeric" } : { timeZone: t, hour: "numeric", minute: "2-digit" };
|
|
49483
|
-
return
|
|
49483
|
+
return Wo(n, s).format(new Date(e));
|
|
49484
49484
|
}
|
|
49485
49485
|
function g7(e, t, n) {
|
|
49486
|
-
return
|
|
49486
|
+
return Wo(n, { timeZone: e, timeZoneName: "shortOffset" }).formatToParts(
|
|
49487
49487
|
new Date(t)
|
|
49488
49488
|
).find((o) => o.type === "timeZoneName")?.value ?? e;
|
|
49489
49489
|
}
|
|
@@ -49491,14 +49491,14 @@ function b7(e, t, n) {
|
|
|
49491
49491
|
return e.allDay ? x7(e, n) : v7(e, t, n);
|
|
49492
49492
|
}
|
|
49493
49493
|
function x7(e, t) {
|
|
49494
|
-
const n = y7(e.endExclusive), r = n.year === e.start.year && n.month === e.start.month && n.day === e.start.day, o =
|
|
49494
|
+
const n = y7(e.endExclusive), r = n.year === e.start.year && n.month === e.start.month && n.day === e.start.day, o = Wo(t, { ...Ai, day: "numeric", month: "long" });
|
|
49495
49495
|
return r ? `All day, ${o.format(Jr(e.start))}` : `All day, ${o.format(Jr(e.start))} to ${o.format(Jr(n))}`;
|
|
49496
49496
|
}
|
|
49497
49497
|
function v7(e, t, n) {
|
|
49498
49498
|
const r = io(e.start, t, n), o = io(e.endExclusive, t, n), s = Un(t, e.start), i = Un(t, e.endExclusive);
|
|
49499
49499
|
if (s.year === i.year && s.month === i.month && s.day === i.day)
|
|
49500
49500
|
return `${r} to ${o}`;
|
|
49501
|
-
const a =
|
|
49501
|
+
const a = Wo(n, { ...Ai, day: "numeric", month: "long" }), c = { year: i.year, month: i.month, day: i.day };
|
|
49502
49502
|
return `${r} to ${o} on ${a.format(Jr(c))}`;
|
|
49503
49503
|
}
|
|
49504
49504
|
function y7(e) {
|
|
@@ -49513,7 +49513,7 @@ function Iu(e, t, n, r) {
|
|
|
49513
49513
|
const o = [e.title, b7(e, t, r)];
|
|
49514
49514
|
return e.calendarLabel ? o.push(e.calendarLabel) : n && o.push(n), o.join(", ");
|
|
49515
49515
|
}
|
|
49516
|
-
function
|
|
49516
|
+
function bo(e, t) {
|
|
49517
49517
|
return {
|
|
49518
49518
|
key: e,
|
|
49519
49519
|
label: t,
|
|
@@ -49523,13 +49523,14 @@ function Zo(e, t) {
|
|
|
49523
49523
|
};
|
|
49524
49524
|
}
|
|
49525
49525
|
const w7 = [
|
|
49526
|
-
|
|
49527
|
-
|
|
49528
|
-
|
|
49529
|
-
|
|
49530
|
-
|
|
49531
|
-
|
|
49532
|
-
|
|
49526
|
+
bo("iris", "Violet"),
|
|
49527
|
+
bo("aqua", "Teal"),
|
|
49528
|
+
bo("mint", "Green"),
|
|
49529
|
+
bo("amber", "Amber"),
|
|
49530
|
+
bo("rose", "Red"),
|
|
49531
|
+
bo("azure", "Blue"),
|
|
49532
|
+
bo("orchid", "Magenta"),
|
|
49533
|
+
bo("slate", "Grey")
|
|
49533
49534
|
], e1 = "iris", $c = new Map(w7.map((e) => [e.key, e]));
|
|
49534
49535
|
function Va(e) {
|
|
49535
49536
|
return e === void 0 ? $c.get(e1) : $c.get(e) ?? $c.get(e1);
|
|
@@ -50002,10 +50003,10 @@ function Rp(e, t, n, r = B2) {
|
|
|
50002
50003
|
}
|
|
50003
50004
|
function t1(e, t, n, r) {
|
|
50004
50005
|
if (t === "resize-end")
|
|
50005
|
-
return { ...e, endExclusive:
|
|
50006
|
+
return { ...e, endExclusive: So(r, e.endExclusive, n) };
|
|
50006
50007
|
if (t === "resize-start")
|
|
50007
|
-
return { ...e, start:
|
|
50008
|
-
const o =
|
|
50008
|
+
return { ...e, start: So(r, e.start, n) };
|
|
50009
|
+
const o = So(r, e.start, n);
|
|
50009
50010
|
return { ...e, start: o, endExclusive: o + (e.endExclusive - e.start) };
|
|
50010
50011
|
}
|
|
50011
50012
|
function Cc(e, t, n = B2) {
|
|
@@ -50219,7 +50220,7 @@ function L7({
|
|
|
50219
50220
|
s({
|
|
50220
50221
|
...e,
|
|
50221
50222
|
start: I,
|
|
50222
|
-
endExclusive:
|
|
50223
|
+
endExclusive: So(t, I, { minutes: M })
|
|
50223
50224
|
}), i?.();
|
|
50224
50225
|
};
|
|
50225
50226
|
return /* @__PURE__ */ R("div", { className: B(l.root(), c), children: [
|
|
@@ -50274,7 +50275,7 @@ function V7(e) {
|
|
|
50274
50275
|
), h = Re(
|
|
50275
50276
|
(x) => {
|
|
50276
50277
|
if (a !== x.id) return x;
|
|
50277
|
-
const b =
|
|
50278
|
+
const b = So(t, x.start, l);
|
|
50278
50279
|
return { ...x, start: b, endExclusive: b + (x.endExclusive - x.start) };
|
|
50279
50280
|
},
|
|
50280
50281
|
[l, a, t]
|
|
@@ -50300,12 +50301,12 @@ function V7(e) {
|
|
|
50300
50301
|
}
|
|
50301
50302
|
const v = (S) => {
|
|
50302
50303
|
b.preventDefault(), d((N) => {
|
|
50303
|
-
const k = { ...N, minutes: (N.minutes ?? 0) + S }, I =
|
|
50304
|
+
const k = { ...N, minutes: (N.minutes ?? 0) + S }, I = So(t, x.start, k);
|
|
50304
50305
|
return p({ ...x, start: I, endExclusive: I }, E(k)), k;
|
|
50305
50306
|
});
|
|
50306
50307
|
}, C = (S) => {
|
|
50307
50308
|
b.preventDefault(), d((N) => {
|
|
50308
|
-
const k = { ...N, days: (N.days ?? 0) + S }, I =
|
|
50309
|
+
const k = { ...N, days: (N.days ?? 0) + S }, I = So(t, x.start, k);
|
|
50309
50310
|
return p({ ...x, start: I, endExclusive: I }, E(k)), k;
|
|
50310
50311
|
});
|
|
50311
50312
|
};
|
|
@@ -50328,7 +50329,7 @@ function V7(e) {
|
|
|
50328
50329
|
[a, s, n, p, t]
|
|
50329
50330
|
);
|
|
50330
50331
|
function g(x) {
|
|
50331
|
-
const b = f.current ?? x, y =
|
|
50332
|
+
const b = f.current ?? x, y = So(t, b.start, l), v = {
|
|
50332
50333
|
...b,
|
|
50333
50334
|
start: y,
|
|
50334
50335
|
endExclusive: y + (b.endExclusive - b.start)
|
|
@@ -50893,18 +50894,18 @@ function JJ({
|
|
|
50893
50894
|
] })
|
|
50894
50895
|
] }),
|
|
50895
50896
|
(r || o) && /* @__PURE__ */ R("div", { className: "flex flex-col gap-0.5 border-t border-border-subtle pt-2", children: [
|
|
50896
|
-
r && /* @__PURE__ */ u(
|
|
50897
|
+
r && /* @__PURE__ */ u(vo, { children: /* @__PURE__ */ R("button", { type: "button", className: B(Sc), onClick: r, children: [
|
|
50897
50898
|
/* @__PURE__ */ u(ie, { name: "user", size: "sm" }),
|
|
50898
50899
|
"Profile"
|
|
50899
50900
|
] }) }),
|
|
50900
|
-
o && /* @__PURE__ */ u(
|
|
50901
|
+
o && /* @__PURE__ */ u(vo, { children: /* @__PURE__ */ R("button", { type: "button", className: B(Sc), onClick: o, children: [
|
|
50901
50902
|
/* @__PURE__ */ u(ie, { name: "shield-check", size: "sm" }),
|
|
50902
50903
|
"Roles & Permissions"
|
|
50903
50904
|
] }) })
|
|
50904
50905
|
] }),
|
|
50905
50906
|
/* @__PURE__ */ R("div", { className: "flex flex-col gap-1.5 border-t border-border-subtle px-1 py-3", children: [
|
|
50906
50907
|
/* @__PURE__ */ u("span", { className: jh, children: "Your access" }),
|
|
50907
|
-
d ? s ? /* @__PURE__ */ u(
|
|
50908
|
+
d ? s ? /* @__PURE__ */ u(vo, { children: /* @__PURE__ */ R(
|
|
50908
50909
|
"button",
|
|
50909
50910
|
{
|
|
50910
50911
|
type: "button",
|
|
@@ -50925,12 +50926,12 @@ function JJ({
|
|
|
50925
50926
|
t,
|
|
50926
50927
|
f.length > 1 && i && /* @__PURE__ */ R("div", { className: "flex flex-col gap-0.5 border-t border-border-subtle pt-2", children: [
|
|
50927
50928
|
/* @__PURE__ */ u("span", { className: B(jh, "px-1 pb-1"), children: "Switch team" }),
|
|
50928
|
-
f.map((p) => /* @__PURE__ */ u(
|
|
50929
|
+
f.map((p) => /* @__PURE__ */ u(vo, { children: /* @__PURE__ */ R("button", { type: "button", className: B(Sc), onClick: () => i(p.id), children: [
|
|
50929
50930
|
/* @__PURE__ */ u(ie, { name: "users", size: "sm" }),
|
|
50930
50931
|
p.name
|
|
50931
50932
|
] }) }, p.id))
|
|
50932
50933
|
] }),
|
|
50933
|
-
a && /* @__PURE__ */ u("div", { className: "flex flex-col gap-0.5 border-t border-border-subtle pt-2", children: /* @__PURE__ */ u(
|
|
50934
|
+
a && /* @__PURE__ */ u("div", { className: "flex flex-col gap-0.5 border-t border-border-subtle pt-2", children: /* @__PURE__ */ u(vo, { children: /* @__PURE__ */ R(
|
|
50934
50935
|
"button",
|
|
50935
50936
|
{
|
|
50936
50937
|
type: "button",
|
|
@@ -50985,7 +50986,7 @@ function eee({ onSwitchTeam: e, className: t }) {
|
|
|
50985
50986
|
),
|
|
50986
50987
|
children: /* @__PURE__ */ R("div", { className: "flex w-full min-w-0 flex-col gap-0.5", children: [
|
|
50987
50988
|
/* @__PURE__ */ u("span", { className: B(U7, "px-1.5 pt-1 pb-1.5"), children: "Switch team" }),
|
|
50988
|
-
r.map((i) => /* @__PURE__ */ u(
|
|
50989
|
+
r.map((i) => /* @__PURE__ */ u(vo, { children: /* @__PURE__ */ R(
|
|
50989
50990
|
"button",
|
|
50990
50991
|
{
|
|
50991
50992
|
type: "button",
|
|
@@ -51145,7 +51146,7 @@ function nee({
|
|
|
51145
51146
|
)
|
|
51146
51147
|
] }),
|
|
51147
51148
|
/* @__PURE__ */ u("div", { className: "flex flex-col gap-2 border-t border-border-subtle pt-4", children: /* @__PURE__ */ u(
|
|
51148
|
-
|
|
51149
|
+
jo,
|
|
51149
51150
|
{
|
|
51150
51151
|
trigger: /* @__PURE__ */ R(Ze, { variant: "outline", size: "sm", children: [
|
|
51151
51152
|
/* @__PURE__ */ u(ie, { name: "refresh-cw", size: "sm" }),
|
|
@@ -51647,7 +51648,7 @@ function oee({
|
|
|
51647
51648
|
}
|
|
51648
51649
|
),
|
|
51649
51650
|
i && /* @__PURE__ */ u(
|
|
51650
|
-
|
|
51651
|
+
jo,
|
|
51651
51652
|
{
|
|
51652
51653
|
open: h !== null,
|
|
51653
51654
|
onOpenChange: (b) => {
|
|
@@ -51697,7 +51698,7 @@ function iW({
|
|
|
51697
51698
|
}) {
|
|
51698
51699
|
const r = e.disabledReason ?? (t ? "Removing…" : void 0);
|
|
51699
51700
|
return /* @__PURE__ */ u(
|
|
51700
|
-
|
|
51701
|
+
jo,
|
|
51701
51702
|
{
|
|
51702
51703
|
trigger: /* @__PURE__ */ u(
|
|
51703
51704
|
ot,
|
|
@@ -51859,7 +51860,7 @@ function lW({
|
|
|
51859
51860
|
}) {
|
|
51860
51861
|
const [r, o] = ne(!1);
|
|
51861
51862
|
return e.current ? /* @__PURE__ */ u("span", { className: "text-2xs text-tertiary", children: "This session" }) : /* @__PURE__ */ u(
|
|
51862
|
-
|
|
51863
|
+
jo,
|
|
51863
51864
|
{
|
|
51864
51865
|
open: r,
|
|
51865
51866
|
onOpenChange: o,
|
|
@@ -52031,7 +52032,7 @@ function fW({
|
|
|
52031
52032
|
}) {
|
|
52032
52033
|
const [r, o] = ne(!1);
|
|
52033
52034
|
return /* @__PURE__ */ u(
|
|
52034
|
-
|
|
52035
|
+
jo,
|
|
52035
52036
|
{
|
|
52036
52037
|
open: r,
|
|
52037
52038
|
onOpenChange: o,
|
|
@@ -52067,7 +52068,7 @@ function pW({
|
|
|
52067
52068
|
/* @__PURE__ */ R("div", { className: "flex min-w-0 items-center gap-1", children: [
|
|
52068
52069
|
/* @__PURE__ */ u(dt, { tone: "accent", size: "sm", children: `+ ${t.label}` }),
|
|
52069
52070
|
r && /* @__PURE__ */ u(
|
|
52070
|
-
|
|
52071
|
+
jo,
|
|
52071
52072
|
{
|
|
52072
52073
|
open: o,
|
|
52073
52074
|
onOpenChange: s,
|
|
@@ -52365,7 +52366,7 @@ const vW = {
|
|
|
52365
52366
|
denied: { tone: "neutral", title: "Denied" },
|
|
52366
52367
|
expired: { tone: "warning", title: "This request expired" }
|
|
52367
52368
|
};
|
|
52368
|
-
function
|
|
52369
|
+
function Mo({ state: e, children: t }) {
|
|
52369
52370
|
const { tone: n, title: r } = vW[e];
|
|
52370
52371
|
return /* @__PURE__ */ u(Dt, { tone: n, title: r, children: t });
|
|
52371
52372
|
}
|
|
@@ -52406,7 +52407,7 @@ function sT({
|
|
|
52406
52407
|
] });
|
|
52407
52408
|
}
|
|
52408
52409
|
function iT({ note: e, fallback: t }) {
|
|
52409
|
-
return e === void 0 ? /* @__PURE__ */ u(
|
|
52410
|
+
return e === void 0 ? /* @__PURE__ */ u(Mo, { state: "expired", children: t }) : /* @__PURE__ */ u(Mo, { state: "expired", children: /* @__PURE__ */ R("div", { className: "flex flex-col gap-1", children: [
|
|
52410
52411
|
/* @__PURE__ */ u("span", { className: "font-medium text-primary", children: e.reason }),
|
|
52411
52412
|
/* @__PURE__ */ u("span", { children: e.nextStep }),
|
|
52412
52413
|
/* @__PURE__ */ u("span", { children: "Nothing was granted, so there is nothing for you to approve or deny." })
|
|
@@ -52442,11 +52443,11 @@ function CW({
|
|
|
52442
52443
|
const r = t.roleLabel ? ` with the ${t.roleLabel} role` : "";
|
|
52443
52444
|
switch (e) {
|
|
52444
52445
|
case "approved":
|
|
52445
|
-
return /* @__PURE__ */ u(
|
|
52446
|
+
return /* @__PURE__ */ u(Mo, { state: e, children: `The requester is picking up its key${r}. You can close this page.` });
|
|
52446
52447
|
case "claimed":
|
|
52447
|
-
return /* @__PURE__ */ u(
|
|
52448
|
+
return /* @__PURE__ */ u(Mo, { state: e, children: `The requester has its key${r}. If that was not you, revoke the key from your API keys.` });
|
|
52448
52449
|
case "denied":
|
|
52449
|
-
return /* @__PURE__ */ u(
|
|
52450
|
+
return /* @__PURE__ */ u(Mo, { state: e, children: "The requester was refused and holds no key. It has to ask again to get access." });
|
|
52450
52451
|
case "expired":
|
|
52451
52452
|
return /* @__PURE__ */ u(iT, { note: n, fallback: "Nothing was granted. Ask the requester to start a new request." });
|
|
52452
52453
|
}
|
|
@@ -52530,17 +52531,17 @@ function kW({
|
|
|
52530
52531
|
const o = t.grantedKeys && t.grantedKeys.length > 0 ? aT(t.grantedKeys, n).map((s) => s.label) : null;
|
|
52531
52532
|
switch (e) {
|
|
52532
52533
|
case "approved":
|
|
52533
|
-
return /* @__PURE__ */ u(
|
|
52534
|
+
return /* @__PURE__ */ u(Mo, { state: e, children: o ? /* @__PURE__ */ R(Ke, { children: [
|
|
52534
52535
|
"The agent's key now also holds these permissions, on top of its role. It picks them up on its next call.",
|
|
52535
52536
|
/* @__PURE__ */ u(s1, { labels: o })
|
|
52536
52537
|
] }) : "The agent picks up the permissions you approved on its next call. You can close this page." });
|
|
52537
52538
|
case "claimed":
|
|
52538
|
-
return /* @__PURE__ */ u(
|
|
52539
|
+
return /* @__PURE__ */ u(Mo, { state: e, children: o ? /* @__PURE__ */ R(Ke, { children: [
|
|
52539
52540
|
"The agent's key holds these permissions now. If that was not you, remove them from the key in your agent sessions.",
|
|
52540
52541
|
/* @__PURE__ */ u(s1, { labels: o })
|
|
52541
52542
|
] }) : "The agent has the permissions you approved. If that was not you, remove them from the key in your agent sessions." });
|
|
52542
52543
|
case "denied":
|
|
52543
|
-
return /* @__PURE__ */ u(
|
|
52544
|
+
return /* @__PURE__ */ u(Mo, { state: e, children: "The agent was refused these permissions and its key is unchanged. It has to ask again to get them." });
|
|
52544
52545
|
case "expired":
|
|
52545
52546
|
return /* @__PURE__ */ u(iT, { note: r, fallback: "Nothing was granted. Ask the agent to start a new request." });
|
|
52546
52547
|
}
|
|
@@ -52663,7 +52664,7 @@ function MW({
|
|
|
52663
52664
|
}
|
|
52664
52665
|
),
|
|
52665
52666
|
/* @__PURE__ */ u(
|
|
52666
|
-
|
|
52667
|
+
jo,
|
|
52667
52668
|
{
|
|
52668
52669
|
trigger: /* @__PURE__ */ u(
|
|
52669
52670
|
ot,
|
|
@@ -58583,13 +58584,13 @@ function UX(e) {
|
|
|
58583
58584
|
function Vee() {
|
|
58584
58585
|
_u.clear();
|
|
58585
58586
|
}
|
|
58586
|
-
const QT = -1, Qt = /* @__PURE__ */ new Map(), gr = /* @__PURE__ */ new Map(), qr = /* @__PURE__ */ new Map(), Kr = /* @__PURE__ */ new Map(), Ba = /* @__PURE__ */ new Set(),
|
|
58587
|
-
let ps = 0,
|
|
58587
|
+
const QT = -1, Qt = /* @__PURE__ */ new Map(), gr = /* @__PURE__ */ new Map(), qr = /* @__PURE__ */ new Map(), Kr = /* @__PURE__ */ new Map(), Ba = /* @__PURE__ */ new Set(), yo = /* @__PURE__ */ new Map();
|
|
58588
|
+
let ps = 0, ko;
|
|
58588
58589
|
function jX(e) {
|
|
58589
|
-
e !==
|
|
58590
|
+
e !== ko && (ko = e, Qt.clear(), gr.clear(), qr.clear(), Js.clear(), ps += 1, sZ());
|
|
58590
58591
|
}
|
|
58591
58592
|
function mf() {
|
|
58592
|
-
return
|
|
58593
|
+
return ko;
|
|
58593
58594
|
}
|
|
58594
58595
|
const Nc = Object.freeze([]);
|
|
58595
58596
|
function Dr(e, t) {
|
|
@@ -58598,13 +58599,13 @@ function Dr(e, t) {
|
|
|
58598
58599
|
const n = hf(e);
|
|
58599
58600
|
if (!n)
|
|
58600
58601
|
return { verdict: "rejected-shape", keys: Nc, reason: "missing __type or id" };
|
|
58601
|
-
if (
|
|
58602
|
+
if (ko !== void 0 && t.tenant !== ko)
|
|
58602
58603
|
return {
|
|
58603
58604
|
verdict: "dropped-tenant",
|
|
58604
58605
|
keys: Nc,
|
|
58605
|
-
reason: `stamped for tenant ${String(t.tenant)}; this store now serves ${String(
|
|
58606
|
+
reason: `stamped for tenant ${String(t.tenant)}; this store now serves ${String(ko)}`
|
|
58606
58607
|
};
|
|
58607
|
-
|
|
58608
|
+
ko === void 0 && t.tenant !== void 0 && Zt(
|
|
58608
58609
|
"recordStore",
|
|
58609
58610
|
"a write carried a tenant but the store has none — call setRecordStoreTenant() or the cross-tenant guard is inert."
|
|
58610
58611
|
), t.source === "broadcast" && t.tag !== void 0 && Zt(
|
|
@@ -58850,18 +58851,18 @@ function ev(e) {
|
|
|
58850
58851
|
}
|
|
58851
58852
|
function oP(e) {
|
|
58852
58853
|
Js.add(e), Wn === null && (Wn = rZ(() => {
|
|
58853
|
-
Wn = null,
|
|
58854
|
+
Wn = null, To();
|
|
58854
58855
|
}));
|
|
58855
58856
|
}
|
|
58856
58857
|
function oZ() {
|
|
58857
58858
|
!rP || !Jx || document.addEventListener("visibilitychange", () => {
|
|
58858
58859
|
!document.hidden || Wn === null || (ev(Wn), Wn = setTimeout(() => {
|
|
58859
|
-
Wn = null,
|
|
58860
|
+
Wn = null, To();
|
|
58860
58861
|
}, 0));
|
|
58861
58862
|
});
|
|
58862
58863
|
}
|
|
58863
58864
|
oZ();
|
|
58864
|
-
function
|
|
58865
|
+
function To() {
|
|
58865
58866
|
if (Wn !== null && (ev(Wn), Wn = null), Js.size === 0) return;
|
|
58866
58867
|
const e = Js;
|
|
58867
58868
|
Js = /* @__PURE__ */ new Set();
|
|
@@ -58924,20 +58925,20 @@ function lZ(e, t) {
|
|
|
58924
58925
|
});
|
|
58925
58926
|
}
|
|
58926
58927
|
function ov(e) {
|
|
58927
|
-
for (const n of e)
|
|
58928
|
+
for (const n of e) yo.set(n, (yo.get(n) ?? 0) + 1);
|
|
58928
58929
|
let t = !1;
|
|
58929
58930
|
return () => {
|
|
58930
58931
|
if (!t) {
|
|
58931
58932
|
t = !0;
|
|
58932
58933
|
for (const n of e) {
|
|
58933
|
-
const r = (
|
|
58934
|
-
r <= 0 ?
|
|
58934
|
+
const r = (yo.get(n) ?? 0) - 1;
|
|
58935
|
+
r <= 0 ? yo.delete(n) : yo.set(n, r);
|
|
58935
58936
|
}
|
|
58936
58937
|
}
|
|
58937
58938
|
};
|
|
58938
58939
|
}
|
|
58939
58940
|
function cZ() {
|
|
58940
|
-
const e = /* @__PURE__ */ new Set(), t = [...
|
|
58941
|
+
const e = /* @__PURE__ */ new Set(), t = [...yo.keys()];
|
|
58941
58942
|
for (const r of Kr.keys()) t.push(r);
|
|
58942
58943
|
for (const [r, o] of Qt) o.layers.length > 0 && t.push(r);
|
|
58943
58944
|
for (; t.length > 0; ) {
|
|
@@ -58968,10 +58969,10 @@ function Qh(e, t) {
|
|
|
58968
58969
|
for (const n of Object.values(e)) Qh(n, t);
|
|
58969
58970
|
}
|
|
58970
58971
|
function Bee() {
|
|
58971
|
-
Wn !== null && (ev(Wn), Wn = null), Qt.clear(), gr.clear(), qr.clear(), Kr.clear(), Ba.clear(),
|
|
58972
|
+
Wn !== null && (ev(Wn), Wn = null), Qt.clear(), gr.clear(), qr.clear(), Kr.clear(), Ba.clear(), yo.clear(), Js = /* @__PURE__ */ new Set(), la = nv, ps = 0, ko = void 0;
|
|
58972
58973
|
}
|
|
58973
58974
|
function Hee() {
|
|
58974
|
-
return { records: Qt.size, memos: gr.size, roots:
|
|
58975
|
+
return { records: Qt.size, memos: gr.size, roots: yo.size, listeners: Kr.size };
|
|
58975
58976
|
}
|
|
58976
58977
|
function mi(e) {
|
|
58977
58978
|
if (typeof e != "object" || e === null || Array.isArray(e)) return !1;
|
|
@@ -59932,7 +59933,7 @@ function qZ(e, t = {}) {
|
|
|
59932
59933
|
const n = t.tenant ?? mf(), r = e.type.type;
|
|
59933
59934
|
if (e.kind === "create") return KZ(e, r, n, t.tag);
|
|
59934
59935
|
const o = e.id, s = po(r, o), i = e.kind === "update" ? e.at : void 0, a = e.kind !== "update" ? {} : i === void 0 ? pP(e.patch) : YZ(e.patch), c = e.kind === "delete" ? (/* @__PURE__ */ new Date()).toISOString() : void 0, l = tP(r, o, { fields: a, at: i, tombstone: c });
|
|
59935
|
-
|
|
59936
|
+
To();
|
|
59936
59937
|
let d = !1;
|
|
59937
59938
|
return {
|
|
59938
59939
|
id: o,
|
|
@@ -59953,10 +59954,10 @@ function qZ(e, t = {}) {
|
|
|
59953
59954
|
through: l,
|
|
59954
59955
|
values: { ...h?.values ?? {}, ...WZ(s, Object.keys(a), i) }
|
|
59955
59956
|
});
|
|
59956
|
-
WX(s, l, Object.keys(a), i), $u(s, l),
|
|
59957
|
+
WX(s, l, Object.keys(a), i), $u(s, l), To();
|
|
59957
59958
|
},
|
|
59958
59959
|
rollback() {
|
|
59959
|
-
d || (d = !0, $u(s, l),
|
|
59960
|
+
d || (d = !0, $u(s, l), To());
|
|
59960
59961
|
}
|
|
59961
59962
|
};
|
|
59962
59963
|
}
|
|
@@ -59966,10 +59967,10 @@ function KZ(e, t, n, r) {
|
|
|
59966
59967
|
fields: { ...pP(e.fields), id: o },
|
|
59967
59968
|
created: !0
|
|
59968
59969
|
}), a = LZ(s, t, e.lists, e.position ?? "start");
|
|
59969
|
-
|
|
59970
|
+
To();
|
|
59970
59971
|
let c = !1;
|
|
59971
59972
|
const l = () => {
|
|
59972
|
-
H1(s, null), $u(s, i),
|
|
59973
|
+
H1(s, null), $u(s, i), To();
|
|
59973
59974
|
};
|
|
59974
59975
|
return {
|
|
59975
59976
|
id: o,
|
|
@@ -59988,7 +59989,7 @@ function KZ(e, t, n, r) {
|
|
|
59988
59989
|
const p = new Set([r, ...a.map((h) => h.tag)].filter((h) => h !== void 0));
|
|
59989
59990
|
p.size === 0 && p.add(void 0);
|
|
59990
59991
|
for (const h of p) Dr(d, { source: "fetch", tag: h, tenant: n });
|
|
59991
|
-
H1(s, f.key), $u(s, i),
|
|
59992
|
+
H1(s, f.key), $u(s, i), To();
|
|
59992
59993
|
},
|
|
59993
59994
|
rollback() {
|
|
59994
59995
|
c || (c = !0, l());
|
|
@@ -60021,7 +60022,7 @@ export {
|
|
|
60021
60022
|
QJ as AccountMenuSection,
|
|
60022
60023
|
cee as AgentKeysList,
|
|
60023
60024
|
oQ as AgentWorkingSpinner,
|
|
60024
|
-
|
|
60025
|
+
jo as AlertDialog,
|
|
60025
60026
|
Ww as AmbiguousTimeError,
|
|
60026
60027
|
lee as ApiKeysPanel,
|
|
60027
60028
|
_Q as AppShell,
|
|
@@ -60189,7 +60190,7 @@ export {
|
|
|
60189
60190
|
dee as PermissionRequestPanel,
|
|
60190
60191
|
kee as PhaseManager,
|
|
60191
60192
|
gn as Popover,
|
|
60192
|
-
|
|
60193
|
+
vo as PopoverClose,
|
|
60193
60194
|
rW as ProfileForm,
|
|
60194
60195
|
ree as ProfilePage,
|
|
60195
60196
|
TH as Progress,
|
|
@@ -60287,7 +60288,7 @@ export {
|
|
|
60287
60288
|
GT as WIDE_RING_THRESHOLD,
|
|
60288
60289
|
TZ as acquireSlot,
|
|
60289
60290
|
Ar as addDays,
|
|
60290
|
-
|
|
60291
|
+
So as addDuration,
|
|
60291
60292
|
Kw as addMonths,
|
|
60292
60293
|
hw as adjustHeading,
|
|
60293
60294
|
WU as advanceBlockReason,
|
|
@@ -60363,7 +60364,7 @@ export {
|
|
|
60363
60364
|
Bx as fitBox,
|
|
60364
60365
|
V9 as fitBoxWithFloor,
|
|
60365
60366
|
L9 as fitWidth,
|
|
60366
|
-
|
|
60367
|
+
To as flushRecordNotifications,
|
|
60367
60368
|
zJ as formatBoolean,
|
|
60368
60369
|
os as formatBytes,
|
|
60369
60370
|
MH as formatCompactNumber,
|
|
@@ -60486,7 +60487,7 @@ export {
|
|
|
60486
60487
|
Ree as scoredConfidence,
|
|
60487
60488
|
xc as scrollVelocity,
|
|
60488
60489
|
l3 as setFenceLanguage,
|
|
60489
|
-
|
|
60490
|
+
xo as setHeading,
|
|
60490
60491
|
jX as setRecordStoreTenant,
|
|
60491
60492
|
r1 as setSimSettings,
|
|
60492
60493
|
kc as simulateLatency,
|