@umriss-ui/core 0.9.1 → 0.9.2
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/CHANGELOG.md +14 -0
- package/dist/core.css +1 -1
- package/dist/core.js +773 -773
- package/package.json +1 -1
package/dist/core.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
1
|
import "./core.css";
|
|
2
|
-
import { useMemo as se, useContext as He, createContext as
|
|
2
|
+
import { useMemo as se, useContext as He, createContext as je, forwardRef as ie, useId as De, useState as B, useLayoutEffect as Oe, useRef as R, useEffect as ne, useCallback as Q, cloneElement as $n, useImperativeHandle as Vt } from "react";
|
|
3
3
|
import { jsx as s, jsxs as k, Fragment as $e } from "react/jsx-runtime";
|
|
4
|
-
import { D as
|
|
5
|
-
import { createPortal as
|
|
4
|
+
import { D as It, a as Dn, s as ar } from "./formats-DrB9TuzO.js";
|
|
5
|
+
import { createPortal as Ut } from "react-dom";
|
|
6
6
|
function P(...e) {
|
|
7
7
|
return e.filter(Boolean).join(" ");
|
|
8
8
|
}
|
|
9
|
-
const
|
|
10
|
-
alert:
|
|
11
|
-
content:
|
|
12
|
-
title:
|
|
13
|
-
text:
|
|
14
|
-
actions:
|
|
9
|
+
const cr = "_alert_3un7t_12 _text_1hv7a_23", lr = "_content_3un7t_26", dr = "_title_3un7t_34", ur = "_text_3un7t_42", hr = "_actions_3un7t_52", fr = "_neutral_3un7t_61", pr = "_accent_3un7t_69", mr = "_success_3un7t_77", _r = "_warning_3un7t_85", gr = "_danger_3un7t_93", vr = "_close_3un7t_103", nt = {
|
|
10
|
+
alert: cr,
|
|
11
|
+
content: lr,
|
|
12
|
+
title: dr,
|
|
13
|
+
text: ur,
|
|
14
|
+
actions: hr,
|
|
15
15
|
neutral: fr,
|
|
16
|
-
accent:
|
|
17
|
-
success:
|
|
18
|
-
warning:
|
|
19
|
-
danger:
|
|
20
|
-
close:
|
|
16
|
+
accent: pr,
|
|
17
|
+
success: mr,
|
|
18
|
+
warning: _r,
|
|
19
|
+
danger: gr,
|
|
20
|
+
close: vr
|
|
21
21
|
}, it = {
|
|
22
22
|
clearInput: "Clear input",
|
|
23
23
|
clearSelection: "Clear selection",
|
|
@@ -265,15 +265,15 @@ const ar = "_alert_3un7t_12 _text_1hv7a_23", cr = "_content_3un7t_26", lr = "_ti
|
|
|
265
265
|
calculationShowDerivation: (e) => `Show how ${e} is derived`,
|
|
266
266
|
calculationHideDerivation: (e) => `Hide how ${e} is derived`,
|
|
267
267
|
calculationOperandCount: (e) => `${e} operands`
|
|
268
|
-
},
|
|
269
|
-
formats:
|
|
268
|
+
}, Tn = {
|
|
269
|
+
formats: It,
|
|
270
270
|
wording: it
|
|
271
|
-
},
|
|
272
|
-
function
|
|
273
|
-
if (!e) return
|
|
271
|
+
}, Sn = je(null);
|
|
272
|
+
function yr(e) {
|
|
273
|
+
if (!e) return Tn;
|
|
274
274
|
const { presets: t, ...n } = e.wording ?? {};
|
|
275
275
|
return {
|
|
276
|
-
formats: e.formats ? { ...
|
|
276
|
+
formats: e.formats ? { ...It, ...e.formats } : It,
|
|
277
277
|
wording: e.wording ? {
|
|
278
278
|
...it,
|
|
279
279
|
...n,
|
|
@@ -281,11 +281,11 @@ function vr(e) {
|
|
|
281
281
|
} : it
|
|
282
282
|
};
|
|
283
283
|
}
|
|
284
|
-
function
|
|
285
|
-
const r = se(() =>
|
|
286
|
-
return /* @__PURE__ */ s(
|
|
284
|
+
function br({ formats: e, wording: t, children: n }) {
|
|
285
|
+
const r = se(() => yr({ formats: e, wording: t }), [e, t]);
|
|
286
|
+
return /* @__PURE__ */ s(Sn.Provider, { value: r, children: n });
|
|
287
287
|
}
|
|
288
|
-
const
|
|
288
|
+
const Mn = () => He(Sn) ?? Tn, Ve = () => Mn().formats, ce = () => Mn().wording, Ue = ie(function({ size: t = 9, ...n }, r) {
|
|
289
289
|
return /* @__PURE__ */ s("svg", { ref: r, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...n, children: /* @__PURE__ */ s(
|
|
290
290
|
"path",
|
|
291
291
|
{
|
|
@@ -296,11 +296,11 @@ const Sn = () => He(Tn) ?? Dn, je = () => Sn().formats, ce = () => Sn().wording,
|
|
|
296
296
|
strokeLinecap: "round"
|
|
297
297
|
}
|
|
298
298
|
) });
|
|
299
|
-
}), br = ie(function({ size: t = 10, ...n }, r) {
|
|
300
|
-
return /* @__PURE__ */ s("svg", { ref: r, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...n, children: /* @__PURE__ */ s("path", { d: "M5 2v6M2 5h6", fill: "none", stroke: "currentColor", strokeWidth: "1.4", strokeLinecap: "round" }) });
|
|
301
299
|
}), wr = ie(function({ size: t = 10, ...n }, r) {
|
|
302
|
-
return /* @__PURE__ */ s("svg", { ref: r, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...n, children: /* @__PURE__ */ s("path", { d: "
|
|
300
|
+
return /* @__PURE__ */ s("svg", { ref: r, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...n, children: /* @__PURE__ */ s("path", { d: "M5 2v6M2 5h6", fill: "none", stroke: "currentColor", strokeWidth: "1.4", strokeLinecap: "round" }) });
|
|
303
301
|
}), kr = ie(function({ size: t = 10, ...n }, r) {
|
|
302
|
+
return /* @__PURE__ */ s("svg", { ref: r, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...n, children: /* @__PURE__ */ s("path", { d: "M2 5h6", fill: "none", stroke: "currentColor", strokeWidth: "1.4", strokeLinecap: "round" }) });
|
|
303
|
+
}), St = ie(function({ size: t = 10, ...n }, r) {
|
|
304
304
|
return /* @__PURE__ */ s("svg", { ref: r, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...n, children: /* @__PURE__ */ s(
|
|
305
305
|
"path",
|
|
306
306
|
{
|
|
@@ -346,7 +346,7 @@ const Sn = () => He(Tn) ?? Dn, je = () => Sn().formats, ce = () => Sn().wording,
|
|
|
346
346
|
strokeLinejoin: "round"
|
|
347
347
|
}
|
|
348
348
|
) });
|
|
349
|
-
}),
|
|
349
|
+
}), Cn = ie(function({ size: t = 12, range: n = !1, ...r }, o) {
|
|
350
350
|
return /* @__PURE__ */ k("svg", { ref: o, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...r, children: [
|
|
351
351
|
/* @__PURE__ */ s("rect", { x: "1", y: "1.6", width: "8", height: "7.7", rx: "1.2", fill: "none", stroke: "currentColor", strokeWidth: "1.4" }),
|
|
352
352
|
/* @__PURE__ */ s(
|
|
@@ -360,7 +360,7 @@ const Sn = () => He(Tn) ?? Dn, je = () => Sn().formats, ce = () => Sn().wording,
|
|
|
360
360
|
}
|
|
361
361
|
)
|
|
362
362
|
] });
|
|
363
|
-
}),
|
|
363
|
+
}), An = ie(function({ size: t = 12, ...n }, r) {
|
|
364
364
|
return /* @__PURE__ */ k("svg", { ref: r, viewBox: "0 0 10 10", width: t, height: t, "aria-hidden": "true", ...n, children: [
|
|
365
365
|
/* @__PURE__ */ s("circle", { cx: "5", cy: "5", r: "4.1", fill: "none", stroke: "currentColor", strokeWidth: "1.4" }),
|
|
366
366
|
/* @__PURE__ */ s(
|
|
@@ -375,20 +375,20 @@ const Sn = () => He(Tn) ?? Dn, je = () => Sn().formats, ce = () => Sn().wording,
|
|
|
375
375
|
}
|
|
376
376
|
)
|
|
377
377
|
] });
|
|
378
|
-
}),
|
|
378
|
+
}), Bt = {
|
|
379
379
|
neutral: { role: "status", live: "polite" },
|
|
380
380
|
accent: { role: "status", live: "polite" },
|
|
381
381
|
success: { role: "status", live: "polite" },
|
|
382
382
|
warning: { role: "alert" },
|
|
383
383
|
danger: { role: "alert" }
|
|
384
384
|
}, tu = ie(function({ tone: t = "neutral", title: n, actions: r, onDismiss: o, dismissLabel: i, className: a, children: c, ...l }, d) {
|
|
385
|
-
const u = ce(), { role: p, live:
|
|
385
|
+
const u = ce(), { role: p, live: h } = Bt[t];
|
|
386
386
|
return /* @__PURE__ */ k(
|
|
387
387
|
"div",
|
|
388
388
|
{
|
|
389
389
|
ref: d,
|
|
390
390
|
role: p,
|
|
391
|
-
"aria-live":
|
|
391
|
+
"aria-live": h,
|
|
392
392
|
className: P(nt.alert, nt[t], a),
|
|
393
393
|
...l,
|
|
394
394
|
children: [
|
|
@@ -401,7 +401,7 @@ const Sn = () => He(Tn) ?? Dn, je = () => Sn().formats, ce = () => Sn().wording,
|
|
|
401
401
|
]
|
|
402
402
|
}
|
|
403
403
|
);
|
|
404
|
-
}), Nr = "_badge_5ftit_4 _text_1hv7a_23", $r = "_pill_5ftit_19", Dr = "_neutral_5ftit_34", Tr = "_accent_5ftit_39", Sr = "_success_5ftit_44", Mr = "_warning_5ftit_49", Cr = "_danger_5ftit_54",
|
|
404
|
+
}), Nr = "_badge_5ftit_4 _text_1hv7a_23", $r = "_pill_5ftit_19", Dr = "_neutral_5ftit_34", Tr = "_accent_5ftit_39", Sr = "_success_5ftit_44", Mr = "_warning_5ftit_49", Cr = "_danger_5ftit_54", Lt = {
|
|
405
405
|
badge: Nr,
|
|
406
406
|
pill: $r,
|
|
407
407
|
neutral: Dr,
|
|
@@ -411,12 +411,12 @@ const Sn = () => He(Tn) ?? Dn, je = () => Sn().formats, ce = () => Sn().wording,
|
|
|
411
411
|
danger: Cr
|
|
412
412
|
};
|
|
413
413
|
function nu({ tone: e = "neutral", pill: t = !1, className: n, children: r, ...o }) {
|
|
414
|
-
return /* @__PURE__ */ s("span", { className: P(
|
|
414
|
+
return /* @__PURE__ */ s("span", { className: P(Lt.badge, t && Lt.pill, Lt[e], n), ...o, children: r });
|
|
415
415
|
}
|
|
416
416
|
const Ar = "_spinner_1tmf7_4", Lr = {
|
|
417
417
|
spinner: Ar
|
|
418
418
|
};
|
|
419
|
-
function
|
|
419
|
+
function Ln({ size: e = 14, className: t, ...n }) {
|
|
420
420
|
const r = ce();
|
|
421
421
|
return /* @__PURE__ */ k(
|
|
422
422
|
"svg",
|
|
@@ -436,14 +436,14 @@ function An({ size: e = 14, className: t, ...n }) {
|
|
|
436
436
|
}
|
|
437
437
|
);
|
|
438
438
|
}
|
|
439
|
-
const Rr = "_button_18a70_4 _ring_1hv7a_65 _text_1hv7a_23", Pr = "_sm_18a70_46", Er = "_primary_18a70_58", Fr = "_danger_18a70_69", Ir = "_secondary_18a70_84", Br = "_ghost_18a70_100",
|
|
439
|
+
const Rr = "_button_18a70_4 _ring_1hv7a_65 _text_1hv7a_23", Pr = "_sm_18a70_46", Er = "_primary_18a70_58", Fr = "_danger_18a70_69", Ir = "_secondary_18a70_84", Br = "_ghost_18a70_100", zr = "_label_18a70_111", mt = {
|
|
440
440
|
button: Rr,
|
|
441
441
|
sm: Pr,
|
|
442
442
|
primary: Er,
|
|
443
443
|
danger: Fr,
|
|
444
444
|
secondary: Ir,
|
|
445
445
|
ghost: Br,
|
|
446
|
-
label:
|
|
446
|
+
label: zr
|
|
447
447
|
}, ve = ie(function({ variant: t = "secondary", size: n = "md", loading: r = !1, disabled: o, className: i, children: a, type: c, ...l }, d) {
|
|
448
448
|
return /* @__PURE__ */ k(
|
|
449
449
|
"button",
|
|
@@ -455,24 +455,24 @@ const Rr = "_button_18a70_4 _ring_1hv7a_65 _text_1hv7a_23", Pr = "_sm_18a70_46",
|
|
|
455
455
|
"aria-busy": r || void 0,
|
|
456
456
|
...l,
|
|
457
457
|
children: [
|
|
458
|
-
r && /* @__PURE__ */ s(
|
|
458
|
+
r && /* @__PURE__ */ s(Ln, { size: n === "sm" ? 12 : 14, className: mt.spinner }),
|
|
459
459
|
/* @__PURE__ */ s("span", { className: mt.label, children: a })
|
|
460
460
|
]
|
|
461
461
|
}
|
|
462
462
|
);
|
|
463
|
-
}), Or = "_field_1fqw6_4 _text_1hv7a_23", Hr = "_label_1fqw6_12",
|
|
463
|
+
}), Or = "_field_1fqw6_4 _text_1hv7a_23", Hr = "_label_1fqw6_12", qr = "_required_1fqw6_19", Wr = "_message_1fqw6_24", Gr = "_hint_1fqw6_30", jr = "_error_1fqw6_34", lt = {
|
|
464
464
|
field: Or,
|
|
465
465
|
label: Hr,
|
|
466
|
-
required:
|
|
466
|
+
required: qr,
|
|
467
467
|
message: Wr,
|
|
468
468
|
hint: Gr,
|
|
469
|
-
error:
|
|
470
|
-
},
|
|
469
|
+
error: jr
|
|
470
|
+
}, Yt = je(null);
|
|
471
471
|
function Be() {
|
|
472
|
-
return He(
|
|
472
|
+
return He(Yt);
|
|
473
473
|
}
|
|
474
|
-
function
|
|
475
|
-
return /* @__PURE__ */ s(
|
|
474
|
+
function Vr({ children: e }) {
|
|
475
|
+
return /* @__PURE__ */ s(Yt.Provider, { value: null, children: e });
|
|
476
476
|
}
|
|
477
477
|
function ru({
|
|
478
478
|
label: e,
|
|
@@ -491,7 +491,7 @@ function ru({
|
|
|
491
491
|
r && /* @__PURE__ */ s("span", { className: lt.required, "aria-hidden": "true", children: "*" })
|
|
492
492
|
] }),
|
|
493
493
|
/* @__PURE__ */ s(
|
|
494
|
-
|
|
494
|
+
Yt.Provider,
|
|
495
495
|
{
|
|
496
496
|
value: { id: d, describedBy: p ? u : void 0, invalid: !!n, required: r },
|
|
497
497
|
children: a
|
|
@@ -501,31 +501,31 @@ function ru({
|
|
|
501
501
|
] });
|
|
502
502
|
}
|
|
503
503
|
const Ur = 6, Yr = 8;
|
|
504
|
-
function
|
|
505
|
-
const { align: o = "start", side: i = "bottom", offset: a = Ur, margin: c = Yr } = r, { top: l = 0, left: d = 0 } = n, u = l + n.height - e.bottom - a, p = e.top - l - a,
|
|
504
|
+
function Rn(e, t, n, r = {}) {
|
|
505
|
+
const { align: o = "start", side: i = "bottom", offset: a = Ur, margin: c = Yr } = r, { top: l = 0, left: d = 0 } = n, u = l + n.height - e.bottom - a, p = e.top - l - a, h = i === "top" ? p : u, f = i === "top" ? u : p, m = h < t.height && f >= t.height, y = i === "top" !== m, b = y ? e.top - a - t.height : e.bottom + a, g = h >= t.height || f >= t.height ? b : Math.max(l + c, Math.min(b, l + n.height - t.height - c)), N = o === "end" ? e.right - t.width : o === "center" ? e.left + e.width / 2 - t.width / 2 : e.left, L = Math.max(d + c, Math.min(N, d + n.width - t.width - c));
|
|
506
506
|
return { top: g, left: L, flipped: m, side: y ? "top" : "bottom" };
|
|
507
507
|
}
|
|
508
|
-
function
|
|
508
|
+
function Kt(e, t) {
|
|
509
509
|
return `${t === "start" ? "left" : t === "end" ? "right" : "center"} ${e === "bottom" ? "top" : "bottom"}`;
|
|
510
510
|
}
|
|
511
|
-
function
|
|
511
|
+
function Pn() {
|
|
512
512
|
const e = window.visualViewport;
|
|
513
513
|
return e ? { top: e.offsetTop, left: e.offsetLeft, width: e.width, height: e.height } : { width: window.innerWidth, height: window.innerHeight };
|
|
514
514
|
}
|
|
515
515
|
const Kr = "_panel_ireao_8 _text_1hv7a_23", Xr = {
|
|
516
516
|
panel: Kr
|
|
517
|
-
},
|
|
517
|
+
}, Xt = je(null);
|
|
518
518
|
function ou(e, t) {
|
|
519
|
-
const n = He(
|
|
519
|
+
const n = He(Xt);
|
|
520
520
|
return e !== void 0 ? e : n != null && n.densityGiven ? n.density === "compact" ? "compact" : "regular" : t;
|
|
521
521
|
}
|
|
522
522
|
const Qr = {
|
|
523
523
|
density: "comfortable",
|
|
524
524
|
portalTarget: null,
|
|
525
525
|
toast: {}
|
|
526
|
-
},
|
|
527
|
-
function
|
|
528
|
-
const { portalTarget: e } =
|
|
526
|
+
}, Qt = () => He(Xt) ?? Qr, su = () => Qt().density, Zr = () => Qt().toast;
|
|
527
|
+
function Zt() {
|
|
528
|
+
const { portalTarget: e } = Qt();
|
|
529
529
|
return se(
|
|
530
530
|
() => typeof e == "function" ? e : () => e,
|
|
531
531
|
[e]
|
|
@@ -547,23 +547,23 @@ function iu({
|
|
|
547
547
|
}),
|
|
548
548
|
[e, t, n]
|
|
549
549
|
);
|
|
550
|
-
return /* @__PURE__ */ s(
|
|
550
|
+
return /* @__PURE__ */ s(Xt.Provider, { value: i, children: /* @__PURE__ */ s(br, { formats: r == null ? void 0 : r.formats, wording: r == null ? void 0 : r.wording, children: o }) });
|
|
551
551
|
}
|
|
552
|
-
function
|
|
552
|
+
function En(e, t) {
|
|
553
553
|
return (e == null ? void 0 : e.closest("dialog")) ?? t() ?? document.body;
|
|
554
554
|
}
|
|
555
|
-
function
|
|
555
|
+
function Mt() {
|
|
556
556
|
return typeof window < "u" && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
557
557
|
}
|
|
558
558
|
function yt(e, t) {
|
|
559
559
|
const n = e.getPropertyValue(t).trim(), r = Number.parseFloat(n);
|
|
560
560
|
return Number.isFinite(r) ? n.endsWith("ms") ? r : n.endsWith("s") ? r * 1e3 : r : 0;
|
|
561
561
|
}
|
|
562
|
-
function
|
|
562
|
+
function Fn(e, t, n) {
|
|
563
563
|
const [r, o] = B(e);
|
|
564
564
|
return e && !r && o(!0), Oe(() => {
|
|
565
565
|
if (e || !r) return;
|
|
566
|
-
const i = t.current, a = i && !
|
|
566
|
+
const i = t.current, a = i && !Mt() ? yt(getComputedStyle(i), n) : 0;
|
|
567
567
|
if (a <= 0) {
|
|
568
568
|
o(!1);
|
|
569
569
|
return;
|
|
@@ -585,8 +585,8 @@ function Je({
|
|
|
585
585
|
restoreFocus: d = !0,
|
|
586
586
|
hideOnScroll: u = !1,
|
|
587
587
|
role: p,
|
|
588
|
-
ariaLabel:
|
|
589
|
-
id:
|
|
588
|
+
ariaLabel: h,
|
|
589
|
+
id: f,
|
|
590
590
|
className: m,
|
|
591
591
|
children: y
|
|
592
592
|
}) {
|
|
@@ -594,41 +594,41 @@ function Je({
|
|
|
594
594
|
ne(() => {
|
|
595
595
|
v.current = o;
|
|
596
596
|
});
|
|
597
|
-
const [g, N] = B(null), [L, F] = B(null), D =
|
|
598
|
-
(
|
|
597
|
+
const [g, N] = B(null), [L, F] = B(null), D = Zt(), _ = Fn(e, b, "--u-duration-exit-fast"), E = _ && !e, w = Q(
|
|
598
|
+
(V) => {
|
|
599
599
|
var U;
|
|
600
|
-
t(!1),
|
|
600
|
+
t(!1), V && d && ((U = (r ?? n).current) == null || U.focus());
|
|
601
601
|
},
|
|
602
602
|
[t, d, n, r]
|
|
603
603
|
), O = Q(() => {
|
|
604
604
|
var G;
|
|
605
|
-
const
|
|
606
|
-
if (!
|
|
607
|
-
c === "anchor" ? U.style.width = `${l ? Math.max(
|
|
605
|
+
const V = (G = n.current) == null ? void 0 : G.getBoundingClientRect(), U = b.current;
|
|
606
|
+
if (!V || !U) return;
|
|
607
|
+
c === "anchor" ? U.style.width = `${l ? Math.max(V.width, l) : V.width}px` : typeof c == "number" && (U.style.width = `${c}px`);
|
|
608
608
|
const C = U.getBoundingClientRect();
|
|
609
609
|
N(
|
|
610
|
-
|
|
611
|
-
|
|
610
|
+
Rn(
|
|
611
|
+
V,
|
|
612
612
|
{ width: C.width, height: C.height },
|
|
613
|
-
|
|
613
|
+
Pn(),
|
|
614
614
|
{ align: i, offset: a }
|
|
615
615
|
)
|
|
616
616
|
);
|
|
617
617
|
}, [n, i, a, c, l]);
|
|
618
618
|
return Oe(() => {
|
|
619
|
-
e && F(
|
|
619
|
+
e && F(En(n.current, D));
|
|
620
620
|
}, [e, n, D]), Oe(() => {
|
|
621
621
|
!e || !L || O();
|
|
622
622
|
}, [e, L, O]), ne(() => {
|
|
623
623
|
if (!e) return;
|
|
624
|
-
const
|
|
624
|
+
const V = (Y) => {
|
|
625
625
|
var pe, A;
|
|
626
626
|
return ((pe = b.current) == null ? void 0 : pe.contains(Y)) || ((A = n.current) == null ? void 0 : A.contains(Y)) || (v.current ?? []).some((I) => {
|
|
627
|
-
var
|
|
628
|
-
return (
|
|
627
|
+
var q;
|
|
628
|
+
return (q = I.current) == null ? void 0 : q.contains(Y);
|
|
629
629
|
});
|
|
630
630
|
}, U = (Y) => {
|
|
631
|
-
|
|
631
|
+
V(Y.target) || w(!1);
|
|
632
632
|
}, C = (Y) => {
|
|
633
633
|
Y.key === "Escape" && (Y.preventDefault(), w(!0));
|
|
634
634
|
};
|
|
@@ -643,14 +643,14 @@ function Je({
|
|
|
643
643
|
return document.addEventListener("mousedown", U), document.addEventListener("keydown", C), window.addEventListener("scroll", X, !0), window.addEventListener("resize", X), H == null || H.addEventListener("resize", S), H == null || H.addEventListener("scroll", S), () => {
|
|
644
644
|
H == null || H.removeEventListener("resize", S), H == null || H.removeEventListener("scroll", S), document.removeEventListener("mousedown", U), document.removeEventListener("keydown", C), window.removeEventListener("scroll", X, !0), window.removeEventListener("resize", X), G && cancelAnimationFrame(G);
|
|
645
645
|
};
|
|
646
|
-
}, [e, n, w, O, u]), !_ || !L ? null :
|
|
646
|
+
}, [e, n, w, O, u]), !_ || !L ? null : Ut(
|
|
647
647
|
/* @__PURE__ */ s(
|
|
648
648
|
"div",
|
|
649
649
|
{
|
|
650
650
|
ref: b,
|
|
651
|
-
id:
|
|
651
|
+
id: f,
|
|
652
652
|
role: p,
|
|
653
|
-
"aria-label":
|
|
653
|
+
"aria-label": h,
|
|
654
654
|
className: P(Xr.panel, m),
|
|
655
655
|
"data-closing": E || void 0,
|
|
656
656
|
inert: E || void 0,
|
|
@@ -659,7 +659,7 @@ function Je({
|
|
|
659
659
|
top: (g == null ? void 0 : g.top) ?? 0,
|
|
660
660
|
left: (g == null ? void 0 : g.left) ?? 0,
|
|
661
661
|
/* The motion origin, computed here and drawn by the stylesheet. */
|
|
662
|
-
"--_origin": g ?
|
|
662
|
+
"--_origin": g ? Kt(g.side, i) : void 0,
|
|
663
663
|
/* Not shown before the first measurement, or it flashes in the top
|
|
664
664
|
left. Transparent and not `visibility: hidden`: a hidden panel takes
|
|
665
665
|
no focus, and the first opening of a menu lost its move to the first
|
|
@@ -667,7 +667,7 @@ function Je({
|
|
|
667
667
|
transparent pass is never seen. */
|
|
668
668
|
opacity: g ? void 0 : 0
|
|
669
669
|
},
|
|
670
|
-
children: /* @__PURE__ */ s(
|
|
670
|
+
children: /* @__PURE__ */ s(Vr, { children: y })
|
|
671
671
|
}
|
|
672
672
|
),
|
|
673
673
|
L
|
|
@@ -679,8 +679,8 @@ const Jr = "_panel_1527b_4", eo = "_item_1527b_15", to = "_danger_1527b_57", no
|
|
|
679
679
|
danger: to,
|
|
680
680
|
separator: no,
|
|
681
681
|
content: ro
|
|
682
|
-
},
|
|
683
|
-
function
|
|
682
|
+
}, Jt = je(null);
|
|
683
|
+
function In(e, t, n) {
|
|
684
684
|
var i, a, c, l;
|
|
685
685
|
const r = Array.from((t == null ? void 0 : t.querySelectorAll('[role="menuitem"]:not([disabled])')) ?? []);
|
|
686
686
|
if (r.length === 0) return;
|
|
@@ -705,21 +705,21 @@ function Fn(e, t, n) {
|
|
|
705
705
|
}
|
|
706
706
|
function oo({ trigger: e, children: t, align: n = "start" }) {
|
|
707
707
|
const [r, o] = B(!1), i = R(null), a = R(null), c = De(), l = () => {
|
|
708
|
-
var f;
|
|
709
|
-
o(!1), (f = i.current) == null || f.focus();
|
|
710
|
-
}, d = Q((f) => {
|
|
711
708
|
var h;
|
|
712
|
-
|
|
713
|
-
},
|
|
709
|
+
o(!1), (h = i.current) == null || h.focus();
|
|
710
|
+
}, d = Q((h) => {
|
|
711
|
+
var f;
|
|
712
|
+
a.current = h, (f = h == null ? void 0 : h.querySelector('[role="menuitem"]:not([disabled])')) == null || f.focus();
|
|
713
|
+
}, []), u = (h) => In(h, a.current, l), p = e.props;
|
|
714
714
|
return /* @__PURE__ */ k($e, { children: [
|
|
715
|
-
|
|
715
|
+
$n(e, {
|
|
716
716
|
ref: i,
|
|
717
717
|
"aria-haspopup": "menu",
|
|
718
718
|
"aria-expanded": r,
|
|
719
719
|
"aria-controls": r ? c : void 0,
|
|
720
|
-
onClick: (
|
|
721
|
-
var
|
|
722
|
-
(
|
|
720
|
+
onClick: (h) => {
|
|
721
|
+
var f;
|
|
722
|
+
(f = p.onClick) == null || f.call(p, h), o(!r);
|
|
723
723
|
}
|
|
724
724
|
}),
|
|
725
725
|
/* @__PURE__ */ s(
|
|
@@ -732,13 +732,13 @@ function oo({ trigger: e, children: t, align: n = "start" }) {
|
|
|
732
732
|
role: "menu",
|
|
733
733
|
id: c,
|
|
734
734
|
className: ct.panel,
|
|
735
|
-
children: /* @__PURE__ */ s("div", { ref: d, className: ct.content, onKeyDown: u, children: /* @__PURE__ */ s(
|
|
735
|
+
children: /* @__PURE__ */ s("div", { ref: d, className: ct.content, onKeyDown: u, children: /* @__PURE__ */ s(Jt.Provider, { value: { close: l }, children: t }) })
|
|
736
736
|
}
|
|
737
737
|
)
|
|
738
738
|
] });
|
|
739
739
|
}
|
|
740
740
|
function au({ onSelect: e, tone: t = "default", className: n, children: r, onClick: o, ...i }) {
|
|
741
|
-
const a = He(
|
|
741
|
+
const a = He(Jt);
|
|
742
742
|
return /* @__PURE__ */ s(
|
|
743
743
|
"button",
|
|
744
744
|
{
|
|
@@ -807,10 +807,10 @@ const so = "_group_elxi9_9", io = "_split_elxi9_97", ao = "_trigger_elxi9_97", c
|
|
|
807
807
|
}
|
|
808
808
|
)
|
|
809
809
|
] });
|
|
810
|
-
}), uo = "_card_9q2sr_4 _text_1hv7a_23",
|
|
810
|
+
}), uo = "_card_9q2sr_4 _text_1hv7a_23", ho = "_header_9q2sr_13", fo = "_divider_9q2sr_21", po = "_body_9q2sr_27", mo = "_collapse_9q2sr_28", _o = "_collapsed_9q2sr_39", go = "_collapseInner_9q2sr_43", vo = "_headerText_9q2sr_48", yo = "_eyebrow_9q2sr_55", bo = "_title_9q2sr_63", wo = "_headerRight_9q2sr_72", ko = "_collapseButton_9q2sr_79 _ring_1hv7a_65", xo = "_flush_9q2sr_27", Pe = {
|
|
811
811
|
card: uo,
|
|
812
|
-
header:
|
|
813
|
-
divider:
|
|
812
|
+
header: ho,
|
|
813
|
+
divider: fo,
|
|
814
814
|
body: po,
|
|
815
815
|
collapse: mo,
|
|
816
816
|
collapsed: _o,
|
|
@@ -821,7 +821,7 @@ const so = "_group_elxi9_9", io = "_split_elxi9_97", ao = "_trigger_elxi9_97", c
|
|
|
821
821
|
headerRight: wo,
|
|
822
822
|
collapseButton: ko,
|
|
823
823
|
flush: xo
|
|
824
|
-
},
|
|
824
|
+
}, en = je(null);
|
|
825
825
|
function du({
|
|
826
826
|
collapsible: e = !1,
|
|
827
827
|
defaultCollapsed: t = !1,
|
|
@@ -831,7 +831,7 @@ function du({
|
|
|
831
831
|
}) {
|
|
832
832
|
const [i, a] = B(t), c = De();
|
|
833
833
|
return /* @__PURE__ */ s("section", { className: P(Pe.card, n), ...o, children: /* @__PURE__ */ s(
|
|
834
|
-
|
|
834
|
+
en.Provider,
|
|
835
835
|
{
|
|
836
836
|
value: { collapsible: e, collapsed: i, toggle: () => a((l) => !l), bodyId: c },
|
|
837
837
|
children: r
|
|
@@ -839,7 +839,7 @@ function du({
|
|
|
839
839
|
) });
|
|
840
840
|
}
|
|
841
841
|
function uu({ title: e, eyebrow: t, actions: n, divider: r = !1, className: o, ...i }) {
|
|
842
|
-
const a = He(
|
|
842
|
+
const a = He(en), c = ce();
|
|
843
843
|
return /* @__PURE__ */ k("div", { className: P(Pe.header, r && Pe.divider, o), ...i, children: [
|
|
844
844
|
/* @__PURE__ */ k("div", { className: Pe.headerText, children: [
|
|
845
845
|
t && /* @__PURE__ */ s("span", { className: Pe.eyebrow, children: t }),
|
|
@@ -861,8 +861,8 @@ function uu({ title: e, eyebrow: t, actions: n, divider: r = !1, className: o, .
|
|
|
861
861
|
] })
|
|
862
862
|
] });
|
|
863
863
|
}
|
|
864
|
-
function
|
|
865
|
-
const o = He(
|
|
864
|
+
function hu({ flush: e = !1, className: t, children: n, ...r }) {
|
|
865
|
+
const o = He(en), i = /* @__PURE__ */ s(
|
|
866
866
|
"div",
|
|
867
867
|
{
|
|
868
868
|
id: o == null ? void 0 : o.bodyId,
|
|
@@ -880,7 +880,7 @@ const No = "_wrapper_1pp8c_4 _text_1hv7a_23", $o = "_input_1pp8c_13", Do = "_box
|
|
|
880
880
|
check: To,
|
|
881
881
|
dash: So,
|
|
882
882
|
label: Mo
|
|
883
|
-
},
|
|
883
|
+
}, tn = ie(function({ label: t, indeterminate: n = !1, className: r, id: o, ...i }, a) {
|
|
884
884
|
const c = R(null);
|
|
885
885
|
Vt(a, () => c.current), ne(() => {
|
|
886
886
|
c.current && (c.current.indeterminate = n);
|
|
@@ -906,7 +906,7 @@ const No = "_wrapper_1pp8c_4 _text_1hv7a_23", $o = "_input_1pp8c_13", Do = "_box
|
|
|
906
906
|
t && /* @__PURE__ */ s("span", { className: dt.label, children: t })
|
|
907
907
|
] });
|
|
908
908
|
});
|
|
909
|
-
function
|
|
909
|
+
function Bn(e, t, n) {
|
|
910
910
|
const r = R(null), [o, i] = B(!1), a = R(!1), c = () => {
|
|
911
911
|
if (a.current) {
|
|
912
912
|
a.current = !1;
|
|
@@ -925,7 +925,7 @@ function In(e, t, n) {
|
|
|
925
925
|
}
|
|
926
926
|
if (!d.open) return;
|
|
927
927
|
const u = typeof t == "number" ? t : yt(getComputedStyle(d), t);
|
|
928
|
-
if (u <= 0 ||
|
|
928
|
+
if (u <= 0 || Mt()) {
|
|
929
929
|
a.current = !0, d.close();
|
|
930
930
|
return;
|
|
931
931
|
}
|
|
@@ -942,7 +942,7 @@ function Ze(e) {
|
|
|
942
942
|
(t) => `_${t.codePointAt(0).toString(16)}_`
|
|
943
943
|
);
|
|
944
944
|
}
|
|
945
|
-
function
|
|
945
|
+
function zn(e, t) {
|
|
946
946
|
const n = t.trim().toLowerCase();
|
|
947
947
|
return n ? e.filter((r) => r.label.toLowerCase().includes(n)) : e;
|
|
948
948
|
}
|
|
@@ -963,7 +963,7 @@ function Ro(e, t) {
|
|
|
963
963
|
n.has(r) ? n.delete(r) : n.add(r);
|
|
964
964
|
}), [...n];
|
|
965
965
|
}
|
|
966
|
-
function
|
|
966
|
+
function nn(e, t, n) {
|
|
967
967
|
return t <= 0 ? 0 : (e + n + t) % t;
|
|
968
968
|
}
|
|
969
969
|
function Po(e, t) {
|
|
@@ -971,35 +971,35 @@ function Po(e, t) {
|
|
|
971
971
|
const n = e.findIndex((r) => r.value === t);
|
|
972
972
|
return n === -1 ? 0 : n;
|
|
973
973
|
}
|
|
974
|
-
const Eo = 10, Fo = 8, Io = 0.5, Bo = /[\p{L}\p{N}]/u,
|
|
974
|
+
const Eo = 10, Fo = 8, Io = 0.5, Bo = /[\p{L}\p{N}]/u, zo = (e) => e !== e.toLowerCase() && e === e.toUpperCase(), Oo = (e) => e !== e.toUpperCase() && e === e.toLowerCase();
|
|
975
975
|
function Ho(e, t) {
|
|
976
976
|
if (t === 0) return !0;
|
|
977
977
|
const n = e[t - 1], r = e[t];
|
|
978
|
-
return Bo.test(n) ? Oo(n) &&
|
|
978
|
+
return Bo.test(n) ? Oo(n) && zo(r) : !0;
|
|
979
979
|
}
|
|
980
|
-
function
|
|
980
|
+
function dn(e, t) {
|
|
981
981
|
const n = e.trim().toLowerCase();
|
|
982
982
|
if (n === "" || n.length > t.length) return null;
|
|
983
983
|
const r = t.toLowerCase();
|
|
984
984
|
let o = new Array(t.length).fill(null);
|
|
985
985
|
const i = [];
|
|
986
986
|
for (let u = 0; u < n.length; u++) {
|
|
987
|
-
const p = new Array(t.length).fill(null),
|
|
988
|
-
for (let
|
|
989
|
-
if (r[
|
|
990
|
-
const m = Ho(t,
|
|
987
|
+
const p = new Array(t.length).fill(null), h = new Array(t.length).fill(null);
|
|
988
|
+
for (let f = 0; f < t.length; f++) {
|
|
989
|
+
if (r[f] !== n[u]) continue;
|
|
990
|
+
const m = Ho(t, f) ? Eo : 0;
|
|
991
991
|
if (u === 0) {
|
|
992
|
-
p[
|
|
992
|
+
p[f] = m;
|
|
993
993
|
continue;
|
|
994
994
|
}
|
|
995
|
-
for (let y = 0; y <
|
|
995
|
+
for (let y = 0; y < f; y++) {
|
|
996
996
|
const b = o[y] ?? null;
|
|
997
997
|
if (b === null) continue;
|
|
998
|
-
const v = b + m + (y ===
|
|
999
|
-
(p[
|
|
998
|
+
const v = b + m + (y === f - 1 ? Fo : 0);
|
|
999
|
+
(p[f] === null || v > p[f]) && (p[f] = v, h[f] = y);
|
|
1000
1000
|
}
|
|
1001
1001
|
}
|
|
1002
|
-
o = p, i.push(
|
|
1002
|
+
o = p, i.push(h);
|
|
1003
1003
|
}
|
|
1004
1004
|
let a = null;
|
|
1005
1005
|
for (let u = 0; u < t.length; u++)
|
|
@@ -1011,9 +1011,9 @@ function ln(e, t) {
|
|
|
1011
1011
|
c.push(l), l = i[u][l];
|
|
1012
1012
|
c.reverse();
|
|
1013
1013
|
const d = (t.length - n.length) * Io;
|
|
1014
|
-
return { rank: o[a] - d, finds:
|
|
1014
|
+
return { rank: o[a] - d, finds: qo(c) };
|
|
1015
1015
|
}
|
|
1016
|
-
function
|
|
1016
|
+
function qo(e) {
|
|
1017
1017
|
const t = [];
|
|
1018
1018
|
for (const n of e) {
|
|
1019
1019
|
const r = t[t.length - 1];
|
|
@@ -1026,7 +1026,7 @@ function Wo(e, t) {
|
|
|
1026
1026
|
if (n === "") return [];
|
|
1027
1027
|
const r = [];
|
|
1028
1028
|
for (const o of e) {
|
|
1029
|
-
const i =
|
|
1029
|
+
const i = dn(n, o.name);
|
|
1030
1030
|
if (i !== null) {
|
|
1031
1031
|
r.push({
|
|
1032
1032
|
kandidat: o,
|
|
@@ -1035,7 +1035,7 @@ function Wo(e, t) {
|
|
|
1035
1035
|
});
|
|
1036
1036
|
continue;
|
|
1037
1037
|
}
|
|
1038
|
-
const a = o.gruppe === void 0 ? null :
|
|
1038
|
+
const a = o.gruppe === void 0 ? null : dn(n, o.gruppe);
|
|
1039
1039
|
a !== null && r.push({
|
|
1040
1040
|
kandidat: o,
|
|
1041
1041
|
rank: a.rank + (o.gewicht ?? 0),
|
|
@@ -1047,21 +1047,21 @@ function Wo(e, t) {
|
|
|
1047
1047
|
return a !== c ? a ? -1 : 1 : i.rank - o.rank;
|
|
1048
1048
|
});
|
|
1049
1049
|
}
|
|
1050
|
-
const Go = "_hidden_69gri_7",
|
|
1050
|
+
const Go = "_hidden_69gri_7", jo = "_focusable_69gri_20 _text_1hv7a_23", un = {
|
|
1051
1051
|
hidden: Go,
|
|
1052
|
-
focusable:
|
|
1053
|
-
},
|
|
1052
|
+
focusable: jo
|
|
1053
|
+
}, On = ie(function({ as: t, focusable: n = !1, className: r, children: o, ...i }, a) {
|
|
1054
1054
|
return /* @__PURE__ */ s(
|
|
1055
1055
|
t ?? "span",
|
|
1056
1056
|
{
|
|
1057
1057
|
ref: a,
|
|
1058
|
-
className: P(
|
|
1058
|
+
className: P(un.hidden, n && un.focusable, r),
|
|
1059
1059
|
...i,
|
|
1060
1060
|
children: o
|
|
1061
1061
|
}
|
|
1062
1062
|
);
|
|
1063
|
-
}),
|
|
1064
|
-
dialog:
|
|
1063
|
+
}), Vo = "_dialog_11oxz_7 _text_1hv7a_23", Uo = "_pane_11oxz_2", Yo = "_field_11oxz_86 _field_1hv7a_34", Ko = "_bodyWrap_11oxz_125", Xo = "_body_11oxz_125", Qo = "_list_11oxz_146 _scroll_1hv7a_40", Zo = "_groupHeading_11oxz_156", Jo = "_row_11oxz_165", es = "_rowActive_11oxz_179", ts = "_icon_11oxz_187", ns = "_name_11oxz_196", rs = "_mark_11oxz_207", os = "_group_11oxz_156", ss = "_noFinds_11oxz_218", is = "_footer_11oxz_227", as = "_key_11oxz_243", ge = {
|
|
1064
|
+
dialog: Vo,
|
|
1065
1065
|
pane: Uo,
|
|
1066
1066
|
field: Yo,
|
|
1067
1067
|
bodyWrap: Ko,
|
|
@@ -1078,7 +1078,7 @@ const Go = "_hidden_69gri_7", Vo = "_focusable_69gri_20 _text_1hv7a_23", dn = {
|
|
|
1078
1078
|
footer: is,
|
|
1079
1079
|
key: as
|
|
1080
1080
|
};
|
|
1081
|
-
function
|
|
1081
|
+
function hn(e) {
|
|
1082
1082
|
return {
|
|
1083
1083
|
name: e.label,
|
|
1084
1084
|
gruppe: e.group,
|
|
@@ -1087,7 +1087,7 @@ function un(e) {
|
|
|
1087
1087
|
icon: e.icon
|
|
1088
1088
|
};
|
|
1089
1089
|
}
|
|
1090
|
-
function
|
|
1090
|
+
function fu({
|
|
1091
1091
|
open: e,
|
|
1092
1092
|
onClose: t,
|
|
1093
1093
|
items: n,
|
|
@@ -1095,9 +1095,9 @@ function hu({
|
|
|
1095
1095
|
restingItems: o
|
|
1096
1096
|
}) {
|
|
1097
1097
|
var pe;
|
|
1098
|
-
const i = ce(), a = De(), c = `${a}-list`, { dialogRef: l, beimSchliessen: d, beimAbbrechen: u } =
|
|
1098
|
+
const i = ce(), a = De(), c = `${a}-list`, { dialogRef: l, beimSchliessen: d, beimAbbrechen: u } = Bn(e, 0, t), p = R(null), h = R(null), [f, m] = B(""), [y, b] = B(null), v = f.trim() !== "", g = se(() => n.map(hn), [n]), N = se(() => Wo(g, f), [g, f]), L = se(
|
|
1099
1099
|
() => (o ?? []).map((A) => ({
|
|
1100
|
-
kandidat:
|
|
1100
|
+
kandidat: hn(A),
|
|
1101
1101
|
rank: 0,
|
|
1102
1102
|
finds: []
|
|
1103
1103
|
})),
|
|
@@ -1105,24 +1105,24 @@ function hu({
|
|
|
1105
1105
|
), F = v ? N : L, D = se(() => {
|
|
1106
1106
|
const A = [];
|
|
1107
1107
|
for (const I of F) {
|
|
1108
|
-
const
|
|
1109
|
-
let te = A.find((ke) => ke.name ===
|
|
1110
|
-
te === void 0 && (te = { name:
|
|
1108
|
+
const q = I.kandidat.gruppe;
|
|
1109
|
+
let te = A.find((ke) => ke.name === q);
|
|
1110
|
+
te === void 0 && (te = { name: q, finds: [] }, A.push(te)), te.finds.push(I);
|
|
1111
1111
|
}
|
|
1112
1112
|
return A;
|
|
1113
1113
|
}, [F]), _ = se(() => D.flatMap((A) => A.finds), [D]), E = y !== null && _.some((A) => A.kandidat.id === y) ? y : ((pe = _[0]) == null ? void 0 : pe.kandidat.id) ?? null, w = R(!1), O = Q(() => {
|
|
1114
1114
|
w.current = !1;
|
|
1115
|
-
}, []),
|
|
1115
|
+
}, []), V = Q((A) => {
|
|
1116
1116
|
w.current = !0, b(A);
|
|
1117
1117
|
}, []), U = Q((A) => {
|
|
1118
1118
|
w.current && b(A);
|
|
1119
1119
|
}, []);
|
|
1120
1120
|
ne(() => {
|
|
1121
1121
|
var A;
|
|
1122
|
-
e && (
|
|
1122
|
+
e && (h.current = document.activeElement, m(""), b(null), w.current = !1, (A = p.current) == null || A.focus());
|
|
1123
1123
|
}, [e]), ne(() => {
|
|
1124
1124
|
var A;
|
|
1125
|
-
E !== null && ((A = document.getElementById(
|
|
1125
|
+
E !== null && ((A = document.getElementById(zt(a, E))) == null || A.scrollIntoView({ block: "nearest" }));
|
|
1126
1126
|
}, [E, a]);
|
|
1127
1127
|
const C = R(null), [G, S] = B(0);
|
|
1128
1128
|
ne(() => {
|
|
@@ -1134,8 +1134,8 @@ function hu({
|
|
|
1134
1134
|
}, [e]);
|
|
1135
1135
|
const X = (A) => {
|
|
1136
1136
|
if (O(), _.length === 0) return;
|
|
1137
|
-
const I = _.findIndex((te) => te.kandidat.id === E),
|
|
1138
|
-
b(_[
|
|
1137
|
+
const I = _.findIndex((te) => te.kandidat.id === E), q = nn(I === -1 ? 0 : I, _.length, A);
|
|
1138
|
+
b(_[q].kandidat.id);
|
|
1139
1139
|
}, H = (A) => {
|
|
1140
1140
|
if (!A.nativeEvent.isComposing) {
|
|
1141
1141
|
if (A.key === "ArrowDown") {
|
|
@@ -1161,7 +1161,7 @@ function hu({
|
|
|
1161
1161
|
"aria-label": i.palettePanel,
|
|
1162
1162
|
onClose: () => {
|
|
1163
1163
|
var A, I;
|
|
1164
|
-
d(), (I = (A =
|
|
1164
|
+
d(), (I = (A = h.current) == null ? void 0 : A.focus) == null || I.call(A);
|
|
1165
1165
|
},
|
|
1166
1166
|
onCancel: u,
|
|
1167
1167
|
onMouseDown: (A) => {
|
|
@@ -1174,13 +1174,13 @@ function hu({
|
|
|
1174
1174
|
ref: p,
|
|
1175
1175
|
type: "text",
|
|
1176
1176
|
className: ge.field,
|
|
1177
|
-
value:
|
|
1177
|
+
value: f,
|
|
1178
1178
|
placeholder: i.palettePlaceholder,
|
|
1179
1179
|
"aria-label": i.paletteField,
|
|
1180
1180
|
role: "combobox",
|
|
1181
1181
|
"aria-expanded": _.length > 0,
|
|
1182
1182
|
"aria-controls": _.length > 0 ? c : void 0,
|
|
1183
|
-
"aria-activedescendant": E === null ? void 0 :
|
|
1183
|
+
"aria-activedescendant": E === null ? void 0 : zt(a, E),
|
|
1184
1184
|
autoComplete: "off",
|
|
1185
1185
|
spellCheck: !1,
|
|
1186
1186
|
onChange: (A) => {
|
|
@@ -1198,7 +1198,7 @@ function hu({
|
|
|
1198
1198
|
"aria-label": i.paletteList,
|
|
1199
1199
|
className: ge.list,
|
|
1200
1200
|
children: D.map((A) => {
|
|
1201
|
-
const I = `${a}-group-${Ze(A.name ?? "")}`,
|
|
1201
|
+
const I = `${a}-group-${Ze(A.name ?? "")}`, q = A.finds.map((te) => /* @__PURE__ */ s(
|
|
1202
1202
|
cs,
|
|
1203
1203
|
{
|
|
1204
1204
|
find: te,
|
|
@@ -1206,14 +1206,14 @@ function hu({
|
|
|
1206
1206
|
active: te.kandidat.id === E,
|
|
1207
1207
|
withIcon: Y,
|
|
1208
1208
|
onSweep: U,
|
|
1209
|
-
onMove:
|
|
1209
|
+
onMove: V,
|
|
1210
1210
|
onChoose: r
|
|
1211
1211
|
},
|
|
1212
1212
|
te.kandidat.id
|
|
1213
1213
|
));
|
|
1214
|
-
return A.name === void 0 ?
|
|
1214
|
+
return A.name === void 0 ? q : /* @__PURE__ */ k("div", { role: "group", "aria-labelledby": I, children: [
|
|
1215
1215
|
/* @__PURE__ */ s("div", { id: I, className: ge.groupHeading, children: A.name }),
|
|
1216
|
-
|
|
1216
|
+
q
|
|
1217
1217
|
] }, A.name);
|
|
1218
1218
|
})
|
|
1219
1219
|
}
|
|
@@ -1238,12 +1238,12 @@ function hu({
|
|
|
1238
1238
|
] })
|
|
1239
1239
|
] })
|
|
1240
1240
|
] }) }),
|
|
1241
|
-
/* @__PURE__ */ s(
|
|
1241
|
+
/* @__PURE__ */ s(On, { role: "status", "aria-live": "polite", children: v ? i.paletteFindCount(_.length) : "" })
|
|
1242
1242
|
] })
|
|
1243
1243
|
}
|
|
1244
1244
|
);
|
|
1245
1245
|
}
|
|
1246
|
-
const
|
|
1246
|
+
const zt = (e, t) => `${e}-${Ze(t)}`;
|
|
1247
1247
|
function cs({
|
|
1248
1248
|
find: e,
|
|
1249
1249
|
baseId: t,
|
|
@@ -1257,7 +1257,7 @@ function cs({
|
|
|
1257
1257
|
return /* @__PURE__ */ k(
|
|
1258
1258
|
"div",
|
|
1259
1259
|
{
|
|
1260
|
-
id:
|
|
1260
|
+
id: zt(t, c.id),
|
|
1261
1261
|
role: "option",
|
|
1262
1262
|
"aria-selected": n,
|
|
1263
1263
|
className: P(ge.row, n && ge.rowActive),
|
|
@@ -1302,10 +1302,10 @@ function pu(e) {
|
|
|
1302
1302
|
return window.addEventListener("keydown", n), () => window.removeEventListener("keydown", n);
|
|
1303
1303
|
}, []);
|
|
1304
1304
|
}
|
|
1305
|
-
const us = "
|
|
1305
|
+
const us = "_wrapper_16ore_4 _text_1hv7a_23", hs = "_input_16ore_11 _field_1hv7a_34", fs = "_invalid_16ore_44", ps = "_chevron_16ore_53", ms = "_panel_16ore_64", _s = "_list_16ore_71 _scroll_1hv7a_40", gs = "_option_16ore_79", vs = "_active_16ore_94", ys = "_selected_16ore_98", bs = "_optionDisabled_16ore_103", ws = "_optionLabel_16ore_112", ks = "_empty_16ore_118", xs = "_inputClearable_16ore_126", Ns = "_clear_16ore_130", Ce = {
|
|
1306
1306
|
wrapper: us,
|
|
1307
|
-
input:
|
|
1308
|
-
invalid:
|
|
1307
|
+
input: hs,
|
|
1308
|
+
invalid: fs,
|
|
1309
1309
|
chevron: ps,
|
|
1310
1310
|
panel: ms,
|
|
1311
1311
|
list: _s,
|
|
@@ -1328,7 +1328,7 @@ function mu({
|
|
|
1328
1328
|
emptyText: a,
|
|
1329
1329
|
clearable: c = !1
|
|
1330
1330
|
}) {
|
|
1331
|
-
const l = Be(), d = ce(), u = r ?? d.comboboxPlaceholder, p = a ?? d.noMatches,
|
|
1331
|
+
const l = Be(), d = ce(), u = r ?? d.comboboxPlaceholder, p = a ?? d.noMatches, h = i ?? (l == null ? void 0 : l.invalid) ?? !1, [f, m] = B(!1), [y, b] = B(null), [v, g] = B(0), N = R(null), L = R(null), F = De(), D = se(() => e.find((C) => C.value === t) ?? null, [e, t]), _ = se(() => zn(e, y ?? ""), [e, y]), E = () => {
|
|
1332
1332
|
g(Po(_, t)), m(!0);
|
|
1333
1333
|
}, w = () => {
|
|
1334
1334
|
m(!1), b(null);
|
|
@@ -1338,24 +1338,24 @@ function mu({
|
|
|
1338
1338
|
};
|
|
1339
1339
|
ne(() => {
|
|
1340
1340
|
var C, G;
|
|
1341
|
-
|
|
1342
|
-
}, [
|
|
1343
|
-
const
|
|
1341
|
+
f && ((G = (C = L.current) == null ? void 0 : C.querySelector(`[data-index="${v}"]`)) == null || G.scrollIntoView({ block: "nearest" }));
|
|
1342
|
+
}, [f, v]);
|
|
1343
|
+
const V = (C) => {
|
|
1344
1344
|
if (!C.nativeEvent.isComposing) {
|
|
1345
1345
|
if (C.key === "ArrowDown" || C.key === "ArrowUp") {
|
|
1346
|
-
if (C.preventDefault(), !
|
|
1346
|
+
if (C.preventDefault(), !f) {
|
|
1347
1347
|
E();
|
|
1348
1348
|
return;
|
|
1349
1349
|
}
|
|
1350
1350
|
if (_.length === 0) return;
|
|
1351
|
-
g((G) =>
|
|
1351
|
+
g((G) => nn(G, _.length, C.key === "ArrowDown" ? 1 : -1));
|
|
1352
1352
|
return;
|
|
1353
1353
|
}
|
|
1354
1354
|
if (C.key === "Enter") {
|
|
1355
|
-
|
|
1355
|
+
f && _[v] && (C.preventDefault(), O(_[v]));
|
|
1356
1356
|
return;
|
|
1357
1357
|
}
|
|
1358
|
-
C.key === "Escape" &&
|
|
1358
|
+
C.key === "Escape" && f && (C.preventDefault(), w());
|
|
1359
1359
|
}
|
|
1360
1360
|
}, U = y ?? (D == null ? void 0 : D.label) ?? "";
|
|
1361
1361
|
return /* @__PURE__ */ k($e, { children: [
|
|
@@ -1368,23 +1368,23 @@ function mu({
|
|
|
1368
1368
|
role: "combobox",
|
|
1369
1369
|
id: l == null ? void 0 : l.id,
|
|
1370
1370
|
disabled: o,
|
|
1371
|
-
"aria-expanded":
|
|
1372
|
-
"aria-controls":
|
|
1371
|
+
"aria-expanded": f,
|
|
1372
|
+
"aria-controls": f ? F : void 0,
|
|
1373
1373
|
"aria-autocomplete": "list",
|
|
1374
|
-
"aria-activedescendant":
|
|
1374
|
+
"aria-activedescendant": f && _[v] ? `${F}-${v}` : void 0,
|
|
1375
1375
|
"aria-describedby": l == null ? void 0 : l.describedBy,
|
|
1376
1376
|
"aria-required": (l == null ? void 0 : l.required) || void 0,
|
|
1377
|
-
"aria-invalid":
|
|
1377
|
+
"aria-invalid": h || void 0,
|
|
1378
1378
|
placeholder: u,
|
|
1379
1379
|
value: U,
|
|
1380
|
-
className: P(Ce.input, c && Ce.inputClearable,
|
|
1380
|
+
className: P(Ce.input, c && Ce.inputClearable, h && Ce.invalid),
|
|
1381
1381
|
onChange: (C) => {
|
|
1382
|
-
b(C.target.value), g(0),
|
|
1382
|
+
b(C.target.value), g(0), f || E();
|
|
1383
1383
|
},
|
|
1384
1384
|
onClick: () => {
|
|
1385
|
-
|
|
1385
|
+
f || E();
|
|
1386
1386
|
},
|
|
1387
|
-
onKeyDown:
|
|
1387
|
+
onKeyDown: V,
|
|
1388
1388
|
onBlur: (C) => {
|
|
1389
1389
|
var G;
|
|
1390
1390
|
(G = L.current) != null && G.contains(C.relatedTarget) || w();
|
|
@@ -1406,12 +1406,12 @@ function mu({
|
|
|
1406
1406
|
children: /* @__PURE__ */ s(Ue, {})
|
|
1407
1407
|
}
|
|
1408
1408
|
),
|
|
1409
|
-
/* @__PURE__ */ s(
|
|
1409
|
+
/* @__PURE__ */ s(St, { className: Ce.chevron })
|
|
1410
1410
|
] }),
|
|
1411
1411
|
/* @__PURE__ */ s(
|
|
1412
1412
|
Je,
|
|
1413
1413
|
{
|
|
1414
|
-
open:
|
|
1414
|
+
open: f,
|
|
1415
1415
|
onOpenChange: (C) => {
|
|
1416
1416
|
C || w();
|
|
1417
1417
|
},
|
|
@@ -1453,7 +1453,7 @@ function $s(e, t, n, r) {
|
|
|
1453
1453
|
return [u, p];
|
|
1454
1454
|
});
|
|
1455
1455
|
}
|
|
1456
|
-
const
|
|
1456
|
+
const Hn = (e) => Math.max(0, Math.min(1, e)), Ds = (e) => Math.round(Hn(e) * 100), Ts = "_meter_jhra4_4 _text_1hv7a_23", Ss = "_track_jhra4_13", Ms = "_fill_jhra4_21", Cs = "_neutral_jhra4_28", As = "_accent_jhra4_29", Ls = "_success_jhra4_30", Rs = "_warning_jhra4_31", Ps = "_danger_jhra4_32", Es = "_meterLabel_jhra4_34", Fs = "_sparkline_jhra4_45 _text_1hv7a_23", Is = "_sparklineAccent_jhra4_54", Bs = "_sparklineDot_jhra4_58", Xe = {
|
|
1457
1457
|
meter: Ts,
|
|
1458
1458
|
track: Ss,
|
|
1459
1459
|
fill: Ms,
|
|
@@ -1475,7 +1475,7 @@ function _u({
|
|
|
1475
1475
|
className: o,
|
|
1476
1476
|
...i
|
|
1477
1477
|
}) {
|
|
1478
|
-
const a =
|
|
1478
|
+
const a = Ve(), c = ce(), l = Hn(e);
|
|
1479
1479
|
return /* @__PURE__ */ k(
|
|
1480
1480
|
"span",
|
|
1481
1481
|
{
|
|
@@ -1493,10 +1493,10 @@ function _u({
|
|
|
1493
1493
|
}
|
|
1494
1494
|
);
|
|
1495
1495
|
}
|
|
1496
|
-
function
|
|
1496
|
+
function zs({ data: e, width: t = 96, height: n = 28, tone: r = "ink", className: o, ...i }) {
|
|
1497
1497
|
const a = De();
|
|
1498
1498
|
if (e.length < 2) return null;
|
|
1499
|
-
const c = 3, l = $s(e, t, n, c), d = l.map(([
|
|
1499
|
+
const c = 3, l = $s(e, t, n, c), d = l.map(([f, m]) => `${f},${m}`).join(" "), u = `M${c},${n - c} L${d.replace(/ /g, " L")} L${t - c},${n - c} Z`, [p, h] = l[l.length - 1] ?? [0, 0];
|
|
1500
1500
|
return /* @__PURE__ */ s("span", { className: P(Xe.sparkline, r === "accent" && Xe.sparklineAccent, o), ...i, children: /* @__PURE__ */ k("svg", { width: t, height: n, viewBox: `0 0 ${t} ${n}`, "aria-hidden": "true", children: [
|
|
1501
1501
|
/* @__PURE__ */ s("defs", { children: /* @__PURE__ */ k("linearGradient", { id: a, x1: "0", y1: "0", x2: "0", y2: "1", children: [
|
|
1502
1502
|
/* @__PURE__ */ s("stop", { offset: "0%", stopColor: "currentColor", stopOpacity: "0.14" }),
|
|
@@ -1514,27 +1514,27 @@ function qs({ data: e, width: t = 96, height: n = 28, tone: r = "ink", className
|
|
|
1514
1514
|
strokeLinejoin: "round"
|
|
1515
1515
|
}
|
|
1516
1516
|
),
|
|
1517
|
-
/* @__PURE__ */ s("circle", { cx: p, cy:
|
|
1517
|
+
/* @__PURE__ */ s("circle", { cx: p, cy: h, r: "2.2", className: Xe.sparklineDot })
|
|
1518
1518
|
] }) });
|
|
1519
1519
|
}
|
|
1520
1520
|
const Me = (e) => new Date(e.getFullYear(), e.getMonth(), 1), at = (e, t) => new Date(e.getFullYear(), e.getMonth(), e.getDate() + t), Nt = (e, t) => new Date(e.getFullYear(), e.getMonth() + t, 1), Os = (e, t) => {
|
|
1521
1521
|
const n = new Date(e.getFullYear(), e.getMonth() + t + 1, 0).getDate();
|
|
1522
1522
|
return new Date(e.getFullYear(), e.getMonth() + t, Math.min(e.getDate(), n));
|
|
1523
|
-
}, Re = (e, t) => !!e && !!t && e.getFullYear() === t.getFullYear() && e.getMonth() === t.getMonth() && e.getDate() === t.getDate(), Ne = (e) => new Date(e.getFullYear(), e.getMonth(), e.getDate()),
|
|
1524
|
-
function
|
|
1523
|
+
}, Re = (e, t) => !!e && !!t && e.getFullYear() === t.getFullYear() && e.getMonth() === t.getMonth() && e.getDate() === t.getDate(), Ne = (e) => new Date(e.getFullYear(), e.getMonth(), e.getDate()), Ot = (e, t) => Ne(e).getTime() < Ne(t).getTime(), Hs = 42;
|
|
1524
|
+
function qs(e) {
|
|
1525
1525
|
const t = Me(e), n = (t.getDay() + 6) % 7, r = at(t, -n);
|
|
1526
1526
|
return Array.from({ length: Hs }, (o, i) => at(r, i));
|
|
1527
1527
|
}
|
|
1528
1528
|
function Ws(e, t, n) {
|
|
1529
1529
|
const r = t ?? n ?? null, o = !t && !!n;
|
|
1530
|
-
return !e || !r ? { from: null, to: null, isPreview: o } :
|
|
1530
|
+
return !e || !r ? { from: null, to: null, isPreview: o } : Ot(r, e) ? { from: r, to: e, isPreview: o } : { from: e, to: r, isPreview: o };
|
|
1531
1531
|
}
|
|
1532
1532
|
const Gs = {
|
|
1533
1533
|
ArrowLeft: -1,
|
|
1534
1534
|
ArrowRight: 1,
|
|
1535
1535
|
ArrowUp: -7,
|
|
1536
1536
|
ArrowDown: 7
|
|
1537
|
-
},
|
|
1537
|
+
}, js = (e) => Gs[e], Vs = (e, t) => e.getMonth() !== t.getMonth() || e.getFullYear() !== t.getFullYear(), Us = "_trigger_1cs0e_4", Ys = "_sm_1cs0e_37", Ks = "_invalid_1cs0e_43", Xs = "_value_1cs0e_52", Qs = "_placeholder_1cs0e_63", Zs = "_icon_1cs0e_75", Js = "_panel_1cs0e_84 _text_1hv7a_23", ei = "_head_1cs0e_94", ti = "_month_1cs0e_102", ni = "_page_1cs0e_107 _ring_1hv7a_65", ri = "_weekdays_1cs0e_131", oi = "_grid_1cs0e_132", si = "_day_1cs0e_151 _ring_1hv7a_65", ii = "_otherMonth_1cs0e_179", ai = "_today_1cs0e_187", ci = "_selected_1cs0e_205", li = "_foot_1cs0e_212", di = "_hangStart_1cs0e_226", ui = "_hangEnd_1cs0e_231", hi = "_timeRow_1cs0e_240", fi = "_timeLabel_1cs0e_250", pi = "_timeGroup_1cs0e_258", mi = "_timeFieldWrap_1cs0e_268", _i = "_timeField_1cs0e_268 _field_1hv7a_34", gi = "_timeStepper_1cs0e_307", vi = "_timeSeparator_1cs0e_364", yi = "_dstHint_1cs0e_370", bi = "_dstChoice_1cs0e_377", wi = "_dstButtons_1cs0e_383", ki = "_footLeft_1cs0e_388", xi = "_triggerWrap_1cs0e_397 _text_1hv7a_23", Ni = "_triggerClear_1cs0e_406", $i = "_rangeDash_1cs0e_458", Di = "_rangePanel_1cs0e_463 _text_1hv7a_23", Ti = "_rangeRight_1cs0e_471", Si = "_rangeBody_1cs0e_475", Mi = "_presetColumn_1cs0e_481", Ci = "_preset_1cs0e_481 _ring_1hv7a_65", Ai = "_presetActive_1cs0e_514", Li = "_monthPair_1cs0e_521", Ri = "_monthColumn_1cs0e_526", Pi = "_pageSpacer_1cs0e_561", Ei = "_dayEmpty_1cs0e_567", Fi = "_inRange_1cs0e_574", Ii = "_rangeFrom_1cs0e_584", Bi = "_rangeTo_1cs0e_586", zi = "_rangeSingle_1cs0e_588", Oi = "_inPreview_1cs0e_611", Hi = "_previewEnd_1cs0e_616", qi = "_footNote_1cs0e_627", Wi = "_timeRangeRow_1cs0e_647", Gi = "_timeHalf_1cs0e_656", ji = "_timeHalfHead_1cs0e_664", Vi = "_timeDate_1cs0e_671", Ui = "_footNoteRight_1cs0e_678", Yi = "_timeFieldDisabled_1cs0e_686", T = {
|
|
1538
1538
|
trigger: Us,
|
|
1539
1539
|
sm: Ys,
|
|
1540
1540
|
invalid: Ks,
|
|
@@ -1554,8 +1554,8 @@ const Gs = {
|
|
|
1554
1554
|
foot: li,
|
|
1555
1555
|
hangStart: di,
|
|
1556
1556
|
hangEnd: ui,
|
|
1557
|
-
timeRow:
|
|
1558
|
-
timeLabel:
|
|
1557
|
+
timeRow: hi,
|
|
1558
|
+
timeLabel: fi,
|
|
1559
1559
|
timeGroup: pi,
|
|
1560
1560
|
timeFieldWrap: mi,
|
|
1561
1561
|
timeField: _i,
|
|
@@ -1581,14 +1581,14 @@ const Gs = {
|
|
|
1581
1581
|
inRange: Fi,
|
|
1582
1582
|
rangeFrom: Ii,
|
|
1583
1583
|
rangeTo: Bi,
|
|
1584
|
-
rangeSingle:
|
|
1584
|
+
rangeSingle: zi,
|
|
1585
1585
|
inPreview: Oi,
|
|
1586
1586
|
previewEnd: Hi,
|
|
1587
|
-
footNote:
|
|
1587
|
+
footNote: qi,
|
|
1588
1588
|
timeRangeRow: Wi,
|
|
1589
1589
|
timeHalf: Gi,
|
|
1590
|
-
timeHalfHead:
|
|
1591
|
-
timeDate:
|
|
1590
|
+
timeHalfHead: ji,
|
|
1591
|
+
timeDate: Vi,
|
|
1592
1592
|
footNoteRight: Ui,
|
|
1593
1593
|
timeFieldDisabled: Yi
|
|
1594
1594
|
};
|
|
@@ -1606,11 +1606,11 @@ function $t({
|
|
|
1606
1606
|
previewTo: d = null,
|
|
1607
1607
|
onHoverDay: u,
|
|
1608
1608
|
withoutPrevious: p = !1,
|
|
1609
|
-
withoutNext:
|
|
1610
|
-
withoutOtherMonth:
|
|
1609
|
+
withoutNext: h = !1,
|
|
1610
|
+
withoutOtherMonth: f = !1,
|
|
1611
1611
|
today: m
|
|
1612
1612
|
}) {
|
|
1613
|
-
const y = ce(), b =
|
|
1613
|
+
const y = ce(), b = Ve(), v = R(null);
|
|
1614
1614
|
ne(() => {
|
|
1615
1615
|
var w, O;
|
|
1616
1616
|
e && ((O = (w = v.current) == null ? void 0 : w.querySelector('[data-active="true"]')) == null || O.focus());
|
|
@@ -1620,22 +1620,22 @@ function $t({
|
|
|
1620
1620
|
w && w.contains(document.activeElement) && ((O = w.querySelector('[data-active="true"]')) == null || O.focus());
|
|
1621
1621
|
}, [r]);
|
|
1622
1622
|
const g = (w) => {
|
|
1623
|
-
const O =
|
|
1623
|
+
const O = js(w.key);
|
|
1624
1624
|
if (O !== void 0) {
|
|
1625
1625
|
w.preventDefault();
|
|
1626
|
-
const
|
|
1627
|
-
o(
|
|
1626
|
+
const V = at(r, O);
|
|
1627
|
+
o(V), Vs(V, t) && n(Me(V));
|
|
1628
1628
|
return;
|
|
1629
1629
|
}
|
|
1630
1630
|
(w.key === "Enter" || w.key === " ") && (w.preventDefault(), a(r));
|
|
1631
1631
|
}, N = (w) => {
|
|
1632
1632
|
n(Nt(t, w)), o(Os(r, w));
|
|
1633
|
-
}, L =
|
|
1633
|
+
}, L = qs(t), F = m ?? /* @__PURE__ */ new Date(), { from: D, to: _, isPreview: E } = Ws(c, l, d);
|
|
1634
1634
|
return /* @__PURE__ */ k($e, { children: [
|
|
1635
1635
|
/* @__PURE__ */ k("div", { className: T.head, children: [
|
|
1636
1636
|
p ? /* @__PURE__ */ s("span", { className: T.pageSpacer, "aria-hidden": "true" }) : /* @__PURE__ */ s("button", { type: "button", className: T.page, "aria-label": y.previousMonth, onClick: () => N(-1), children: /* @__PURE__ */ s("svg", { viewBox: "0 0 10 10", width: "10", height: "10", "aria-hidden": "true", children: /* @__PURE__ */ s("path", { d: "M6.4 1.8 3.2 5l3.2 3.2", fill: "none", stroke: "currentColor", strokeWidth: "1.4", strokeLinecap: "round", strokeLinejoin: "round" }) }) }),
|
|
1637
1637
|
/* @__PURE__ */ s("span", { className: T.month, children: b.month(t) }),
|
|
1638
|
-
|
|
1638
|
+
h ? /* @__PURE__ */ s("span", { className: T.pageSpacer, "aria-hidden": "true" }) : /* @__PURE__ */ s("button", { type: "button", className: T.page, "aria-label": y.nextMonth, onClick: () => N(1), children: /* @__PURE__ */ s("svg", { viewBox: "0 0 10 10", width: "10", height: "10", "aria-hidden": "true", children: /* @__PURE__ */ s("path", { d: "M3.6 1.8 6.8 5 3.6 8.2", fill: "none", stroke: "currentColor", strokeWidth: "1.4", strokeLinecap: "round", strokeLinejoin: "round" }) }) })
|
|
1639
1639
|
] }),
|
|
1640
1640
|
/* @__PURE__ */ s("div", { className: T.weekdays, "aria-hidden": "true", children: y.weekdays.map((w) => /* @__PURE__ */ s("span", { children: w }, w)) }),
|
|
1641
1641
|
/* @__PURE__ */ s(
|
|
@@ -1647,15 +1647,15 @@ function $t({
|
|
|
1647
1647
|
onMouseLeave: u ? () => u(null) : void 0,
|
|
1648
1648
|
children: L.map((w) => {
|
|
1649
1649
|
const O = w.getMonth() === t.getMonth();
|
|
1650
|
-
if (!O &&
|
|
1650
|
+
if (!O && f)
|
|
1651
1651
|
return /* @__PURE__ */ s("span", { className: T.dayEmpty, "aria-hidden": "true" }, w.toISOString());
|
|
1652
|
-
const
|
|
1652
|
+
const V = Re(w, r) && (O || !f), U = Re(w, D), C = Re(w, _), G = U && C, S = !!D && !!_ && !U && !C && Ot(D, w) && Ot(w, _), X = !_ && Re(w, c);
|
|
1653
1653
|
return /* @__PURE__ */ s(
|
|
1654
1654
|
"button",
|
|
1655
1655
|
{
|
|
1656
1656
|
type: "button",
|
|
1657
|
-
tabIndex:
|
|
1658
|
-
"data-active":
|
|
1657
|
+
tabIndex: V ? 0 : -1,
|
|
1658
|
+
"data-active": V || void 0,
|
|
1659
1659
|
"aria-label": b.dateLong(w),
|
|
1660
1660
|
"aria-pressed": Re(w, i) || U || C || X,
|
|
1661
1661
|
"aria-current": Re(w, F) ? "date" : void 0,
|
|
@@ -1682,15 +1682,15 @@ function $t({
|
|
|
1682
1682
|
)
|
|
1683
1683
|
] });
|
|
1684
1684
|
}
|
|
1685
|
-
const
|
|
1686
|
-
function
|
|
1687
|
-
const [o, i] =
|
|
1685
|
+
const Ht = (e) => Ne(e), Ki = (e, t) => new Date(e.getFullYear(), e.getMonth(), e.getDate(), 23, 59, t ? 59 : 0), Xi = (e, t) => e.getTime() <= t.getTime() ? [e, t] : [t, e], qn = (e, t) => Ne(e).getTime() <= Ne(t).getTime() ? [e, t] : [t, e];
|
|
1686
|
+
function Wn(e, t, n, r) {
|
|
1687
|
+
const [o, i] = qn(e, t);
|
|
1688
1688
|
return {
|
|
1689
|
-
from:
|
|
1690
|
-
to: n === "day" ?
|
|
1689
|
+
from: Ht(o),
|
|
1690
|
+
to: n === "day" ? Ht(i) : Ki(i, r)
|
|
1691
1691
|
};
|
|
1692
1692
|
}
|
|
1693
|
-
function
|
|
1693
|
+
function Ct({
|
|
1694
1694
|
wrapRef: e,
|
|
1695
1695
|
triggerRef: t,
|
|
1696
1696
|
panel: n,
|
|
@@ -1703,7 +1703,7 @@ function Mt({
|
|
|
1703
1703
|
onClear: d,
|
|
1704
1704
|
ariaLabel: u
|
|
1705
1705
|
}) {
|
|
1706
|
-
const { disabled: p, invalid:
|
|
1706
|
+
const { disabled: p, invalid: h, clearable: f, size: m } = o;
|
|
1707
1707
|
return /* @__PURE__ */ k("span", { ref: e, className: T.triggerWrap, children: [
|
|
1708
1708
|
/* @__PURE__ */ k(
|
|
1709
1709
|
"button",
|
|
@@ -1716,8 +1716,8 @@ function Mt({
|
|
|
1716
1716
|
"aria-expanded": n.open,
|
|
1717
1717
|
"aria-controls": n.open ? n.id : void 0,
|
|
1718
1718
|
"aria-describedby": r == null ? void 0 : r.describedBy,
|
|
1719
|
-
"aria-invalid":
|
|
1720
|
-
className: P(T.trigger, m === "sm" && T.sm,
|
|
1719
|
+
"aria-invalid": h || void 0,
|
|
1720
|
+
className: P(T.trigger, m === "sm" && T.sm, h && T.invalid),
|
|
1721
1721
|
onClick: n.onToggle,
|
|
1722
1722
|
children: [
|
|
1723
1723
|
/* @__PURE__ */ s("span", { className: P(T.value, !c && T.placeholder), children: c ? i : l }),
|
|
@@ -1725,7 +1725,7 @@ function Mt({
|
|
|
1725
1725
|
]
|
|
1726
1726
|
}
|
|
1727
1727
|
),
|
|
1728
|
-
|
|
1728
|
+
f && c && !p && /* @__PURE__ */ s(
|
|
1729
1729
|
"button",
|
|
1730
1730
|
{
|
|
1731
1731
|
type: "button",
|
|
@@ -1748,30 +1748,30 @@ function gu({
|
|
|
1748
1748
|
size: i = "md",
|
|
1749
1749
|
clearable: a = !1
|
|
1750
1750
|
}) {
|
|
1751
|
-
const c = Be(), l = ce(), d =
|
|
1751
|
+
const c = Be(), l = ce(), d = Ve(), u = n ?? l.datePlaceholder, p = o ?? (c == null ? void 0 : c.invalid) ?? !1, [h, f] = B(!1), [m, y] = B(() => Me(e ?? /* @__PURE__ */ new Date())), [b, v] = B(() => e ?? /* @__PURE__ */ new Date()), g = R(null), N = R(null), L = R(null), F = De(), D = () => {
|
|
1752
1752
|
const w = e ?? /* @__PURE__ */ new Date();
|
|
1753
|
-
y(Me(w)), v(w),
|
|
1753
|
+
y(Me(w)), v(w), f(!0);
|
|
1754
1754
|
}, _ = (w = !0) => {
|
|
1755
1755
|
var O;
|
|
1756
|
-
|
|
1756
|
+
f(!1), w && ((O = g.current) == null || O.focus());
|
|
1757
1757
|
}, E = (w) => {
|
|
1758
|
-
t(
|
|
1758
|
+
t(Ht(w)), _();
|
|
1759
1759
|
};
|
|
1760
1760
|
return /* @__PURE__ */ k($e, { children: [
|
|
1761
1761
|
/* @__PURE__ */ s(
|
|
1762
|
-
|
|
1762
|
+
Ct,
|
|
1763
1763
|
{
|
|
1764
1764
|
wrapRef: N,
|
|
1765
1765
|
triggerRef: g,
|
|
1766
|
-
panel: { id: F, open:
|
|
1766
|
+
panel: { id: F, open: h, onToggle: () => h ? f(!1) : D() },
|
|
1767
1767
|
field: c,
|
|
1768
1768
|
state: { disabled: r, invalid: p, clearable: a, size: i },
|
|
1769
1769
|
hasValue: !!e,
|
|
1770
1770
|
display: e && d.date(e),
|
|
1771
|
-
icon: /* @__PURE__ */ s(
|
|
1771
|
+
icon: /* @__PURE__ */ s(Cn, { className: T.icon }),
|
|
1772
1772
|
placeholder: u,
|
|
1773
1773
|
onClear: () => {
|
|
1774
|
-
t(null),
|
|
1774
|
+
t(null), h && _(!1);
|
|
1775
1775
|
},
|
|
1776
1776
|
ariaLabel: l.dateClear
|
|
1777
1777
|
}
|
|
@@ -1779,9 +1779,9 @@ function gu({
|
|
|
1779
1779
|
/* @__PURE__ */ s(
|
|
1780
1780
|
Je,
|
|
1781
1781
|
{
|
|
1782
|
-
open:
|
|
1782
|
+
open: h,
|
|
1783
1783
|
onOpenChange: (w) => {
|
|
1784
|
-
w ||
|
|
1784
|
+
w || f(!1);
|
|
1785
1785
|
},
|
|
1786
1786
|
anchorRef: g,
|
|
1787
1787
|
insideRefs: [N],
|
|
@@ -1813,19 +1813,19 @@ function gu({
|
|
|
1813
1813
|
)
|
|
1814
1814
|
] });
|
|
1815
1815
|
}
|
|
1816
|
-
const
|
|
1817
|
-
function
|
|
1816
|
+
const Rt = (e, t, n, r) => e.getHours() === t && e.getMinutes() === n && e.getSeconds() === r;
|
|
1817
|
+
function rn(e, t, n, r, o, i) {
|
|
1818
1818
|
const a = new Date(e, t, n, r, o, i);
|
|
1819
|
-
if (!
|
|
1819
|
+
if (!Rt(a, r, o, i))
|
|
1820
1820
|
return { kind: "missing", date: a };
|
|
1821
1821
|
const c = 36e5, l = new Date(a.getTime() - c);
|
|
1822
|
-
if (
|
|
1822
|
+
if (Rt(l, r, o, i))
|
|
1823
1823
|
return { kind: "ambiguous", earlier: l, later: a };
|
|
1824
1824
|
const d = new Date(a.getTime() + c);
|
|
1825
|
-
return
|
|
1825
|
+
return Rt(d, r, o, i) ? { kind: "ambiguous", earlier: a, later: d } : { kind: "ok", date: a };
|
|
1826
1826
|
}
|
|
1827
|
-
function
|
|
1828
|
-
const t =
|
|
1827
|
+
function qt(e) {
|
|
1828
|
+
const t = rn(
|
|
1829
1829
|
e.getFullYear(),
|
|
1830
1830
|
e.getMonth(),
|
|
1831
1831
|
e.getDate(),
|
|
@@ -1840,7 +1840,7 @@ function Qi(e, t) {
|
|
|
1840
1840
|
return new Date(Math.floor(e.getTime() / n) * n);
|
|
1841
1841
|
}
|
|
1842
1842
|
const Qe = (e) => String(e).padStart(2, "0");
|
|
1843
|
-
function
|
|
1843
|
+
function ft({ value: e, onValue: t, max: n, label: r, next: o, own: i, disabled: a = !1 }) {
|
|
1844
1844
|
const c = ce(), l = R(e);
|
|
1845
1845
|
l.current = e;
|
|
1846
1846
|
const d = (m) => {
|
|
@@ -1850,7 +1850,7 @@ function ht({ value: e, onValue: t, max: n, label: r, next: o, own: i, disabled:
|
|
|
1850
1850
|
u.current !== null && (clearTimeout(u.current), u.current = null);
|
|
1851
1851
|
};
|
|
1852
1852
|
ne(() => p, []);
|
|
1853
|
-
const
|
|
1853
|
+
const h = (m) => {
|
|
1854
1854
|
var b;
|
|
1855
1855
|
d(m), (b = i == null ? void 0 : i.current) == null || b.focus();
|
|
1856
1856
|
const y = (v) => {
|
|
@@ -1859,7 +1859,7 @@ function ht({ value: e, onValue: t, max: n, label: r, next: o, own: i, disabled:
|
|
|
1859
1859
|
}, v);
|
|
1860
1860
|
};
|
|
1861
1861
|
y(400);
|
|
1862
|
-
},
|
|
1862
|
+
}, f = (m) => {
|
|
1863
1863
|
m.key !== "ArrowUp" && m.key !== "ArrowDown" || (m.preventDefault(), d(m.key === "ArrowUp" ? 1 : -1));
|
|
1864
1864
|
};
|
|
1865
1865
|
return /* @__PURE__ */ k("span", { className: P(T.timeFieldWrap, a && T.timeFieldDisabled), children: [
|
|
@@ -1881,7 +1881,7 @@ function ht({ value: e, onValue: t, max: n, label: r, next: o, own: i, disabled:
|
|
|
1881
1881
|
requestAnimationFrame(() => b.focus());
|
|
1882
1882
|
}
|
|
1883
1883
|
},
|
|
1884
|
-
onKeyDown:
|
|
1884
|
+
onKeyDown: f,
|
|
1885
1885
|
onFocus: (m) => m.target.select(),
|
|
1886
1886
|
onBlur: (m) => {
|
|
1887
1887
|
const y = Math.min(n, Number.parseInt(m.currentTarget.value, 10) || 0);
|
|
@@ -1898,7 +1898,7 @@ function ht({ value: e, onValue: t, max: n, label: r, next: o, own: i, disabled:
|
|
|
1898
1898
|
"aria-label": c.timeFieldIncrease(r),
|
|
1899
1899
|
disabled: a,
|
|
1900
1900
|
onPointerDown: (m) => {
|
|
1901
|
-
m.preventDefault(), !(m.button !== 0 || a) &&
|
|
1901
|
+
m.preventDefault(), !(m.button !== 0 || a) && h(1);
|
|
1902
1902
|
},
|
|
1903
1903
|
onPointerUp: p,
|
|
1904
1904
|
onPointerLeave: p,
|
|
@@ -1915,7 +1915,7 @@ function ht({ value: e, onValue: t, max: n, label: r, next: o, own: i, disabled:
|
|
|
1915
1915
|
"aria-label": c.timeFieldDecrease(r),
|
|
1916
1916
|
disabled: a,
|
|
1917
1917
|
onPointerDown: (m) => {
|
|
1918
|
-
m.preventDefault(), !(m.button !== 0 || a) &&
|
|
1918
|
+
m.preventDefault(), !(m.button !== 0 || a) && h(-1);
|
|
1919
1919
|
},
|
|
1920
1920
|
onPointerUp: p,
|
|
1921
1921
|
onPointerLeave: p,
|
|
@@ -1937,39 +1937,39 @@ function vu({
|
|
|
1937
1937
|
invalid: a,
|
|
1938
1938
|
clearable: c = !1
|
|
1939
1939
|
}) {
|
|
1940
|
-
const l = Be(), d = ce(), u =
|
|
1940
|
+
const l = Be(), d = ce(), u = Ve(), p = r ?? d.dateTimePlaceholder, h = a ?? (l == null ? void 0 : l.invalid) ?? !1, [f, m] = B(!1), [y, b] = B(() => Me(e ?? /* @__PURE__ */ new Date())), [v, g] = B(() => e ?? /* @__PURE__ */ new Date()), [N, L] = B(e), [F, D] = B("00"), [_, E] = B("00"), [w, O] = B("00"), [V, U] = B("earlier"), C = R(null), G = R(null), S = R(null), X = R(null), H = R(null), Y = R(null), pe = De(), A = () => {
|
|
1941
1941
|
const oe = e ?? /* @__PURE__ */ new Date();
|
|
1942
|
-
b(Me(oe)), g(oe), L(e ? oe : null), D(Qe(e ? oe.getHours() : 0)), E(Qe(e ? oe.getMinutes() : 0)), O(Qe(e && n ? oe.getSeconds() : 0)), U(e ?
|
|
1942
|
+
b(Me(oe)), g(oe), L(e ? oe : null), D(Qe(e ? oe.getHours() : 0)), E(Qe(e ? oe.getMinutes() : 0)), O(Qe(e && n ? oe.getSeconds() : 0)), U(e ? qt(e) : "earlier"), m(!0);
|
|
1943
1943
|
}, I = (oe = !0) => {
|
|
1944
1944
|
var K;
|
|
1945
1945
|
m(!1), oe && ((K = C.current) == null || K.focus());
|
|
1946
|
-
},
|
|
1946
|
+
}, q = se(() => N ? rn(
|
|
1947
1947
|
N.getFullYear(),
|
|
1948
1948
|
N.getMonth(),
|
|
1949
1949
|
N.getDate(),
|
|
1950
1950
|
Math.min(23, Number.parseInt(F, 10) || 0),
|
|
1951
1951
|
Math.min(59, Number.parseInt(_, 10) || 0),
|
|
1952
1952
|
n ? Math.min(59, Number.parseInt(w, 10) || 0) : 0
|
|
1953
|
-
) : null, [N, F, _, w, n]), te = se(() =>
|
|
1953
|
+
) : null, [N, F, _, w, n]), te = se(() => q ? q.kind === "ambiguous" ? V === "earlier" ? q.earlier : q.later : q.date : null, [q, V]), ke = () => {
|
|
1954
1954
|
te && (t(te), I());
|
|
1955
1955
|
}, Ee = () => {
|
|
1956
1956
|
t(Qi(/* @__PURE__ */ new Date(), n)), I();
|
|
1957
1957
|
};
|
|
1958
1958
|
return /* @__PURE__ */ k($e, { children: [
|
|
1959
1959
|
/* @__PURE__ */ s(
|
|
1960
|
-
|
|
1960
|
+
Ct,
|
|
1961
1961
|
{
|
|
1962
1962
|
wrapRef: G,
|
|
1963
1963
|
triggerRef: C,
|
|
1964
|
-
panel: { id: pe, open:
|
|
1964
|
+
panel: { id: pe, open: f, onToggle: () => f ? m(!1) : A() },
|
|
1965
1965
|
field: l,
|
|
1966
|
-
state: { disabled: o, invalid:
|
|
1966
|
+
state: { disabled: o, invalid: h, clearable: c, size: i },
|
|
1967
1967
|
hasValue: !!e,
|
|
1968
1968
|
display: e && u.dateTime(e, n),
|
|
1969
|
-
icon: /* @__PURE__ */ s(
|
|
1969
|
+
icon: /* @__PURE__ */ s(An, { className: T.icon }),
|
|
1970
1970
|
placeholder: p,
|
|
1971
1971
|
onClear: () => {
|
|
1972
|
-
t(null),
|
|
1972
|
+
t(null), f && I(!1);
|
|
1973
1973
|
},
|
|
1974
1974
|
ariaLabel: d.dateTimeClear
|
|
1975
1975
|
}
|
|
@@ -1977,7 +1977,7 @@ function vu({
|
|
|
1977
1977
|
/* @__PURE__ */ s(
|
|
1978
1978
|
Je,
|
|
1979
1979
|
{
|
|
1980
|
-
open:
|
|
1980
|
+
open: f,
|
|
1981
1981
|
onOpenChange: (oe) => {
|
|
1982
1982
|
oe || m(!1);
|
|
1983
1983
|
},
|
|
@@ -2015,37 +2015,37 @@ function vu({
|
|
|
2015
2015
|
children: [
|
|
2016
2016
|
/* @__PURE__ */ s("span", { className: T.timeLabel, children: d.timeOfDay }),
|
|
2017
2017
|
/* @__PURE__ */ k("div", { className: T.timeGroup, children: [
|
|
2018
|
-
/* @__PURE__ */ s(
|
|
2018
|
+
/* @__PURE__ */ s(ft, { own: X, value: F, onValue: D, max: 23, label: d.hour, next: H }),
|
|
2019
2019
|
/* @__PURE__ */ s("span", { className: T.timeSeparator, children: ":" }),
|
|
2020
|
-
/* @__PURE__ */ s(
|
|
2020
|
+
/* @__PURE__ */ s(ft, { own: H, value: _, onValue: E, max: 59, label: d.minute, next: n ? Y : void 0 }),
|
|
2021
2021
|
n && /* @__PURE__ */ k($e, { children: [
|
|
2022
2022
|
/* @__PURE__ */ s("span", { className: T.timeSeparator, children: ":" }),
|
|
2023
|
-
/* @__PURE__ */ s(
|
|
2023
|
+
/* @__PURE__ */ s(ft, { own: Y, value: w, onValue: O, max: 59, label: d.second })
|
|
2024
2024
|
] })
|
|
2025
2025
|
] })
|
|
2026
2026
|
]
|
|
2027
2027
|
}
|
|
2028
2028
|
),
|
|
2029
|
-
(
|
|
2030
|
-
(
|
|
2029
|
+
(q == null ? void 0 : q.kind) === "missing" && /* @__PURE__ */ s("p", { className: T.dstHint, children: d.timeMissingHint(u.time(q.date, n)) }),
|
|
2030
|
+
(q == null ? void 0 : q.kind) === "ambiguous" && /* @__PURE__ */ k("div", { className: T.dstChoice, children: [
|
|
2031
2031
|
/* @__PURE__ */ s("p", { className: T.dstHint, children: d.timeAmbiguousHint }),
|
|
2032
2032
|
/* @__PURE__ */ k("div", { className: T.dstButtons, children: [
|
|
2033
2033
|
/* @__PURE__ */ s(
|
|
2034
2034
|
ve,
|
|
2035
2035
|
{
|
|
2036
2036
|
size: "sm",
|
|
2037
|
-
variant:
|
|
2037
|
+
variant: V === "earlier" ? "primary" : "secondary",
|
|
2038
2038
|
onClick: () => U("earlier"),
|
|
2039
|
-
children: d.timeEarlier(u.offset(
|
|
2039
|
+
children: d.timeEarlier(u.offset(q.earlier))
|
|
2040
2040
|
}
|
|
2041
2041
|
),
|
|
2042
2042
|
/* @__PURE__ */ s(
|
|
2043
2043
|
ve,
|
|
2044
2044
|
{
|
|
2045
2045
|
size: "sm",
|
|
2046
|
-
variant:
|
|
2046
|
+
variant: V === "later" ? "primary" : "secondary",
|
|
2047
2047
|
onClick: () => U("later"),
|
|
2048
|
-
children: d.timeLater(u.offset(
|
|
2048
|
+
children: d.timeLater(u.offset(q.later))
|
|
2049
2049
|
}
|
|
2050
2050
|
)
|
|
2051
2051
|
] })
|
|
@@ -2097,10 +2097,10 @@ function ea(e, t) {
|
|
|
2097
2097
|
return { from: new Date(n.getFullYear(), 0, 1), to: new Date(n.getFullYear(), 11, 31) };
|
|
2098
2098
|
}
|
|
2099
2099
|
}
|
|
2100
|
-
const
|
|
2100
|
+
const on = (e) => Ji.map((t) => ({
|
|
2101
2101
|
label: e.presets[t],
|
|
2102
2102
|
range: () => ea(t, /* @__PURE__ */ new Date())
|
|
2103
|
-
})), yu =
|
|
2103
|
+
})), yu = on(it);
|
|
2104
2104
|
function ta(e, t) {
|
|
2105
2105
|
const n = Me(e).getTime(), r = Me(Nt(e, 1)).getTime(), o = Me(t).getTime();
|
|
2106
2106
|
return o === n || o === r ? null : o < n ? Me(t) : Nt(Me(t), -1);
|
|
@@ -2119,7 +2119,7 @@ function na(e) {
|
|
|
2119
2119
|
withoutOtherMonth: !0
|
|
2120
2120
|
};
|
|
2121
2121
|
}
|
|
2122
|
-
function
|
|
2122
|
+
function Gn({ presets: e, isActive: t, onChoose: n }) {
|
|
2123
2123
|
const r = ce();
|
|
2124
2124
|
return e.length === 0 ? null : /* @__PURE__ */ s("div", { className: T.presetColumn, role: "group", "aria-label": r.quickSelect, children: e.map((o) => /* @__PURE__ */ s(
|
|
2125
2125
|
"button",
|
|
@@ -2132,7 +2132,7 @@ function Wn({ presets: e, isActive: t, onChoose: n }) {
|
|
|
2132
2132
|
o.label
|
|
2133
2133
|
)) });
|
|
2134
2134
|
}
|
|
2135
|
-
function
|
|
2135
|
+
function jn({ view: e, onView: t, ...n }) {
|
|
2136
2136
|
const r = na(n), o = Nt(e, 1), i = (a) => {
|
|
2137
2137
|
const c = ta(e, a);
|
|
2138
2138
|
c && t(c);
|
|
@@ -2152,14 +2152,14 @@ function bu({
|
|
|
2152
2152
|
clearable: a = !1,
|
|
2153
2153
|
presets: c
|
|
2154
2154
|
}) {
|
|
2155
|
-
const l = Be(), d = ce(), u =
|
|
2155
|
+
const l = Be(), d = ce(), u = Ve(), p = n ?? d.dateRangePlaceholder, h = o ?? (l == null ? void 0 : l.invalid) ?? !1, f = se(() => c ?? on(d), [c, d]), [m, y] = B(!1), [b, v] = B(() => Me((e == null ? void 0 : e.from) ?? /* @__PURE__ */ new Date())), [g, N] = B(() => (e == null ? void 0 : e.from) ?? /* @__PURE__ */ new Date()), [L, F] = B(null), [D, _] = B(null), E = R(null), w = R(null), O = R(null), V = De(), U = () => {
|
|
2156
2156
|
const I = (e == null ? void 0 : e.from) ?? /* @__PURE__ */ new Date();
|
|
2157
2157
|
v(Me(I)), N(I), F(null), _(null), y(!0);
|
|
2158
2158
|
}, C = (I = !0) => {
|
|
2159
|
-
var
|
|
2160
|
-
y(!1), F(null), _(null), I && ((
|
|
2161
|
-
}, G = (I,
|
|
2162
|
-
t(
|
|
2159
|
+
var q;
|
|
2160
|
+
y(!1), F(null), _(null), I && ((q = E.current) == null || q.focus());
|
|
2161
|
+
}, G = (I, q) => {
|
|
2162
|
+
t(Wn(I, q, "day", !1)), C();
|
|
2163
2163
|
}, S = (I) => {
|
|
2164
2164
|
if (!L) {
|
|
2165
2165
|
F(I), N(I);
|
|
@@ -2168,15 +2168,15 @@ function bu({
|
|
|
2168
2168
|
G(L, I);
|
|
2169
2169
|
};
|
|
2170
2170
|
ne(() => {
|
|
2171
|
-
var
|
|
2171
|
+
var q, te;
|
|
2172
2172
|
if (!m) return;
|
|
2173
2173
|
const I = O.current;
|
|
2174
|
-
I && (
|
|
2174
|
+
I && (q = document.activeElement) != null && q.closest(`.${T.grid}`) && ((te = I.querySelector('[data-active="true"]')) == null || te.focus());
|
|
2175
2175
|
}, [g, m]);
|
|
2176
2176
|
const X = L ?? (e == null ? void 0 : e.from) ?? null, H = L ? null : (e == null ? void 0 : e.to) ?? null, Y = L ? D : null, pe = (() => {
|
|
2177
2177
|
if (L && D) {
|
|
2178
|
-
const [I,
|
|
2179
|
-
return d.rangePreview(u.dateShort(I), u.dateShort(
|
|
2178
|
+
const [I, q] = Ne(D).getTime() < Ne(L).getTime() ? [D, L] : [L, D], te = Dt(I, q);
|
|
2179
|
+
return d.rangePreview(u.dateShort(I), u.dateShort(q), te);
|
|
2180
2180
|
}
|
|
2181
2181
|
if (L) return d.chooseEndDate;
|
|
2182
2182
|
if (e) {
|
|
@@ -2186,25 +2186,25 @@ function bu({
|
|
|
2186
2186
|
return d.chooseStartDate;
|
|
2187
2187
|
})(), A = (I) => {
|
|
2188
2188
|
if (!e || L) return !1;
|
|
2189
|
-
const
|
|
2190
|
-
return Re(
|
|
2189
|
+
const q = I.range();
|
|
2190
|
+
return Re(q.from, e.from) && Re(q.to, e.to);
|
|
2191
2191
|
};
|
|
2192
2192
|
return /* @__PURE__ */ k($e, { children: [
|
|
2193
2193
|
/* @__PURE__ */ s(
|
|
2194
|
-
|
|
2194
|
+
Ct,
|
|
2195
2195
|
{
|
|
2196
2196
|
wrapRef: w,
|
|
2197
2197
|
triggerRef: E,
|
|
2198
|
-
panel: { id:
|
|
2198
|
+
panel: { id: V, open: m, onToggle: () => m ? y(!1) : U() },
|
|
2199
2199
|
field: l,
|
|
2200
|
-
state: { disabled: r, invalid:
|
|
2200
|
+
state: { disabled: r, invalid: h, clearable: a, size: i },
|
|
2201
2201
|
hasValue: !!e,
|
|
2202
2202
|
display: e && /* @__PURE__ */ k($e, { children: [
|
|
2203
2203
|
u.date(e.from),
|
|
2204
2204
|
/* @__PURE__ */ s("span", { className: T.rangeDash, children: "–" }),
|
|
2205
2205
|
u.date(e.to)
|
|
2206
2206
|
] }),
|
|
2207
|
-
icon: /* @__PURE__ */ s(
|
|
2207
|
+
icon: /* @__PURE__ */ s(Cn, { range: !0, className: T.icon }),
|
|
2208
2208
|
placeholder: p,
|
|
2209
2209
|
onClear: () => {
|
|
2210
2210
|
t(null), m && C(!1);
|
|
@@ -2223,23 +2223,23 @@ function bu({
|
|
|
2223
2223
|
insideRefs: [w],
|
|
2224
2224
|
role: "dialog",
|
|
2225
2225
|
ariaLabel: d.dateRangePanel,
|
|
2226
|
-
id:
|
|
2226
|
+
id: V,
|
|
2227
2227
|
className: P(T.panel, T.rangePanel),
|
|
2228
2228
|
children: /* @__PURE__ */ k("div", { ref: O, children: [
|
|
2229
2229
|
/* @__PURE__ */ k("div", { className: T.rangeBody, children: [
|
|
2230
2230
|
/* @__PURE__ */ s(
|
|
2231
|
-
|
|
2231
|
+
Gn,
|
|
2232
2232
|
{
|
|
2233
|
-
presets:
|
|
2233
|
+
presets: f,
|
|
2234
2234
|
isActive: A,
|
|
2235
2235
|
onChoose: (I) => {
|
|
2236
|
-
const
|
|
2237
|
-
G(
|
|
2236
|
+
const q = I.range();
|
|
2237
|
+
G(q.from, q.to);
|
|
2238
2238
|
}
|
|
2239
2239
|
}
|
|
2240
2240
|
),
|
|
2241
2241
|
/* @__PURE__ */ s(
|
|
2242
|
-
|
|
2242
|
+
jn,
|
|
2243
2243
|
{
|
|
2244
2244
|
view: b,
|
|
2245
2245
|
onView: v,
|
|
@@ -2264,7 +2264,7 @@ function bu({
|
|
|
2264
2264
|
)
|
|
2265
2265
|
] });
|
|
2266
2266
|
}
|
|
2267
|
-
const
|
|
2267
|
+
const Pt = { hour: "00", minute: "00", second: "00" }, Et = (e) => ({
|
|
2268
2268
|
hour: "23",
|
|
2269
2269
|
minute: "59",
|
|
2270
2270
|
second: e ? "59" : "00"
|
|
@@ -2272,14 +2272,14 @@ const Rt = { hour: "00", minute: "00", second: "00" }, Pt = (e) => ({
|
|
|
2272
2272
|
hour: Qe(e.getHours()),
|
|
2273
2273
|
minute: Qe(e.getMinutes()),
|
|
2274
2274
|
second: Qe(t ? e.getSeconds() : 0)
|
|
2275
|
-
}),
|
|
2275
|
+
}), pn = (e, t, n) => e ? rn(
|
|
2276
2276
|
e.getFullYear(),
|
|
2277
2277
|
e.getMonth(),
|
|
2278
2278
|
e.getDate(),
|
|
2279
2279
|
Math.min(23, Number.parseInt(t.hour, 10) || 0),
|
|
2280
2280
|
Math.min(59, Number.parseInt(t.minute, 10) || 0),
|
|
2281
2281
|
n ? Math.min(59, Number.parseInt(t.second, 10) || 0) : 0
|
|
2282
|
-
) : null,
|
|
2282
|
+
) : null, mn = (e, t) => e ? e.kind === "ambiguous" ? t === "earlier" ? e.earlier : e.later : e.date : null;
|
|
2283
2283
|
function wu({
|
|
2284
2284
|
value: e,
|
|
2285
2285
|
onChange: t,
|
|
@@ -2291,18 +2291,18 @@ function wu({
|
|
|
2291
2291
|
clearable: c = !1,
|
|
2292
2292
|
presets: l
|
|
2293
2293
|
}) {
|
|
2294
|
-
const d = Be(), u = ce(), p =
|
|
2294
|
+
const d = Be(), u = ce(), p = Ve(), h = r ?? u.dateRangePlaceholder, f = i ?? (d == null ? void 0 : d.invalid) ?? !1, m = se(() => l ?? on(u), [l, u]), [y, b] = B(!1), [v, g] = B(() => Me((e == null ? void 0 : e.from) ?? /* @__PURE__ */ new Date())), [N, L] = B(() => (e == null ? void 0 : e.from) ?? /* @__PURE__ */ new Date()), [F, D] = B(null), [_, E] = B(null), [w, O] = B(null), [V, U] = B(Pt), [C, G] = B(() => Et(n)), [S, X] = B(!0), [H, Y] = B("earlier"), [pe, A] = B("earlier"), I = R(null), q = R(null), te = R(null), ke = R(null), Ee = R(null), oe = R(null), K = R(null), _e = R(null), ye = R(null), xe = R(null), $ = De(), z = () => {
|
|
2295
2295
|
const Z = (e == null ? void 0 : e.from) ?? /* @__PURE__ */ new Date();
|
|
2296
|
-
g(Me(Z)), L(Z), D(e ? Ne(e.from) : null), E(e ? Ne(e.to) : null), U(e ? fn(e.from, n) :
|
|
2296
|
+
g(Me(Z)), L(Z), D(e ? Ne(e.from) : null), E(e ? Ne(e.to) : null), U(e ? fn(e.from, n) : Pt), G(e ? fn(e.to, n) : Et(n)), X(e ? ra(e.from, e.to, n) : !0), Y(e ? qt(e.from) : "earlier"), A(e ? qt(e.to) : "earlier"), O(null), b(!0);
|
|
2297
2297
|
}, M = (Z = !0) => {
|
|
2298
2298
|
var J;
|
|
2299
2299
|
b(!1), O(null), Z && ((J = I.current) == null || J.focus());
|
|
2300
|
-
},
|
|
2300
|
+
}, j = (Z) => {
|
|
2301
2301
|
if (!F || _) {
|
|
2302
2302
|
D(Z), E(null), L(Z);
|
|
2303
2303
|
return;
|
|
2304
2304
|
}
|
|
2305
|
-
const [J, me] =
|
|
2305
|
+
const [J, me] = qn(F, Z);
|
|
2306
2306
|
D(Ne(J)), E(Ne(me)), L(Z), Y("earlier"), A("earlier"), requestAnimationFrame(() => {
|
|
2307
2307
|
var Te, tt;
|
|
2308
2308
|
S ? (Te = xe.current) == null || Te.focus() : (tt = ke.current) == null || tt.focus();
|
|
@@ -2316,18 +2316,18 @@ function wu({
|
|
|
2316
2316
|
const J = document.activeElement;
|
|
2317
2317
|
!J || !Z.contains(J) || J.closest(`.${T.grid}`) && ((me = Z.querySelector('[data-active="true"]')) == null || me.focus());
|
|
2318
2318
|
}, [N, y]);
|
|
2319
|
-
const x = S ?
|
|
2320
|
-
() => S ?
|
|
2319
|
+
const x = S ? Pt : V, W = se(
|
|
2320
|
+
() => S ? Et(n) : C,
|
|
2321
2321
|
[S, n, C]
|
|
2322
|
-
), ee = se(() =>
|
|
2322
|
+
), ee = se(() => pn(F, x, n), [F, x, n]), ae = se(() => pn(_, W, n), [_, W, n]), le = se(() => mn(ee, H), [ee, H]), ue = se(() => mn(ae, pe), [ae, pe]), de = () => {
|
|
2323
2323
|
if (!le || !ue) return;
|
|
2324
2324
|
const [Z, J] = Xi(le, ue);
|
|
2325
2325
|
t({ from: Z, to: J }), M();
|
|
2326
|
-
},
|
|
2326
|
+
}, fe = F, be = _, we = F && !_ ? w : null, he = () => {
|
|
2327
2327
|
if (!le || !ue) return "";
|
|
2328
2328
|
if (S && F && _) {
|
|
2329
|
-
const
|
|
2330
|
-
return u.daysAllDay(
|
|
2329
|
+
const At = Dt(F, _);
|
|
2330
|
+
return u.daysAllDay(At);
|
|
2331
2331
|
}
|
|
2332
2332
|
const Z = Math.abs(ue.getTime() - le.getTime()), J = Math.round(Z / 6e4), me = Math.floor(J / 1440), Te = Math.floor(J % 1440 / 60), tt = J % 60, Ye = [];
|
|
2333
2333
|
return me > 0 && Ye.push(u.days(me)), Te > 0 && Ye.push(u.hoursShort(Te)), (tt > 0 || Ye.length === 0) && Ye.push(u.minutesShort(tt)), u.duration(Ye);
|
|
@@ -2340,13 +2340,13 @@ function wu({
|
|
|
2340
2340
|
}
|
|
2341
2341
|
return u.chooseEndDate;
|
|
2342
2342
|
}
|
|
2343
|
-
return
|
|
2343
|
+
return he();
|
|
2344
2344
|
})(), et = (Z) => {
|
|
2345
2345
|
if (!F || !_ || !S) return !1;
|
|
2346
2346
|
const J = Z.range();
|
|
2347
2347
|
return Re(J.from, F) && Re(J.to, _);
|
|
2348
2348
|
}, bt = (Z, J, me, Te, tt, Ye) => {
|
|
2349
|
-
const [
|
|
2349
|
+
const [At, cn, ln] = tt;
|
|
2350
2350
|
return /* @__PURE__ */ k("div", { className: T.timeHalf, children: [
|
|
2351
2351
|
/* @__PURE__ */ k("span", { className: T.timeHalfHead, children: [
|
|
2352
2352
|
/* @__PURE__ */ s("span", { className: T.timeLabel, children: Z === "from" ? u.sideFrom : u.sideTo }),
|
|
@@ -2354,36 +2354,36 @@ function wu({
|
|
|
2354
2354
|
] }),
|
|
2355
2355
|
/* @__PURE__ */ k("div", { className: T.timeGroup, children: [
|
|
2356
2356
|
/* @__PURE__ */ s(
|
|
2357
|
-
|
|
2357
|
+
ft,
|
|
2358
2358
|
{
|
|
2359
|
-
own:
|
|
2359
|
+
own: At,
|
|
2360
2360
|
value: me.hour,
|
|
2361
2361
|
onValue: (pt) => Te({ ...me, hour: pt }),
|
|
2362
2362
|
max: 23,
|
|
2363
2363
|
label: Z === "from" ? u.startHour : u.endHour,
|
|
2364
|
-
next:
|
|
2364
|
+
next: cn,
|
|
2365
2365
|
disabled: S
|
|
2366
2366
|
}
|
|
2367
2367
|
),
|
|
2368
2368
|
/* @__PURE__ */ s("span", { className: T.timeSeparator, children: ":" }),
|
|
2369
2369
|
/* @__PURE__ */ s(
|
|
2370
|
-
|
|
2370
|
+
ft,
|
|
2371
2371
|
{
|
|
2372
|
-
own:
|
|
2372
|
+
own: cn,
|
|
2373
2373
|
value: me.minute,
|
|
2374
2374
|
onValue: (pt) => Te({ ...me, minute: pt }),
|
|
2375
2375
|
max: 59,
|
|
2376
2376
|
label: Z === "from" ? u.startMinute : u.endMinute,
|
|
2377
|
-
next: n ?
|
|
2377
|
+
next: n ? ln : Ye,
|
|
2378
2378
|
disabled: S
|
|
2379
2379
|
}
|
|
2380
2380
|
),
|
|
2381
2381
|
n && /* @__PURE__ */ k($e, { children: [
|
|
2382
2382
|
/* @__PURE__ */ s("span", { className: T.timeSeparator, children: ":" }),
|
|
2383
2383
|
/* @__PURE__ */ s(
|
|
2384
|
-
|
|
2384
|
+
ft,
|
|
2385
2385
|
{
|
|
2386
|
-
own:
|
|
2386
|
+
own: ln,
|
|
2387
2387
|
value: me.second,
|
|
2388
2388
|
onValue: (pt) => Te({ ...me, second: pt }),
|
|
2389
2389
|
max: 59,
|
|
@@ -2395,7 +2395,7 @@ function wu({
|
|
|
2395
2395
|
] })
|
|
2396
2396
|
] })
|
|
2397
2397
|
] });
|
|
2398
|
-
},
|
|
2398
|
+
}, an = (Z, J, me, Te) => !J || J.kind === "ok" ? null : J.kind === "missing" ? /* @__PURE__ */ s("p", { className: T.dstHint, children: u.timeMissingHintSide(Z, p.time(J.date, n)) }) : /* @__PURE__ */ k("div", { className: T.dstChoice, children: [
|
|
2399
2399
|
/* @__PURE__ */ s("p", { className: T.dstHint, children: u.timeAmbiguousHintSide(Z) }),
|
|
2400
2400
|
/* @__PURE__ */ k("div", { className: T.dstButtons, children: [
|
|
2401
2401
|
/* @__PURE__ */ s(ve, { size: "sm", variant: me === "earlier" ? "primary" : "secondary", onClick: () => Te("earlier"), children: u.timeEarlier(p.offset(J.earlier)) }),
|
|
@@ -2404,13 +2404,13 @@ function wu({
|
|
|
2404
2404
|
] });
|
|
2405
2405
|
return /* @__PURE__ */ k($e, { children: [
|
|
2406
2406
|
/* @__PURE__ */ s(
|
|
2407
|
-
|
|
2407
|
+
Ct,
|
|
2408
2408
|
{
|
|
2409
|
-
wrapRef:
|
|
2409
|
+
wrapRef: q,
|
|
2410
2410
|
triggerRef: I,
|
|
2411
|
-
panel: { id: $, open: y, onToggle: () => y ? b(!1) :
|
|
2411
|
+
panel: { id: $, open: y, onToggle: () => y ? b(!1) : z() },
|
|
2412
2412
|
field: d,
|
|
2413
|
-
state: { disabled: o, invalid:
|
|
2413
|
+
state: { disabled: o, invalid: f, clearable: c, size: a },
|
|
2414
2414
|
hasValue: !!e,
|
|
2415
2415
|
display: e && (Re(e.from, e.to) ? /* @__PURE__ */ k($e, { children: [
|
|
2416
2416
|
p.date(e.from),
|
|
@@ -2427,8 +2427,8 @@ function wu({
|
|
|
2427
2427
|
", ",
|
|
2428
2428
|
p.time(e.to, n)
|
|
2429
2429
|
] })),
|
|
2430
|
-
icon: /* @__PURE__ */ s(
|
|
2431
|
-
placeholder:
|
|
2430
|
+
icon: /* @__PURE__ */ s(An, { className: T.icon }),
|
|
2431
|
+
placeholder: h,
|
|
2432
2432
|
onClear: () => {
|
|
2433
2433
|
t(null), y && M(!1);
|
|
2434
2434
|
},
|
|
@@ -2443,7 +2443,7 @@ function wu({
|
|
|
2443
2443
|
Z || b(!1);
|
|
2444
2444
|
},
|
|
2445
2445
|
anchorRef: I,
|
|
2446
|
-
insideRefs: [
|
|
2446
|
+
insideRefs: [q],
|
|
2447
2447
|
role: "dialog",
|
|
2448
2448
|
ariaLabel: u.dateTimeRangePanel,
|
|
2449
2449
|
id: $,
|
|
@@ -2451,26 +2451,26 @@ function wu({
|
|
|
2451
2451
|
children: /* @__PURE__ */ k("div", { ref: te, children: [
|
|
2452
2452
|
/* @__PURE__ */ k("div", { className: T.rangeBody, children: [
|
|
2453
2453
|
/* @__PURE__ */ s(
|
|
2454
|
-
|
|
2454
|
+
Gn,
|
|
2455
2455
|
{
|
|
2456
2456
|
presets: m,
|
|
2457
2457
|
isActive: et,
|
|
2458
2458
|
onChoose: (Z) => {
|
|
2459
2459
|
const J = Z.range();
|
|
2460
|
-
t(
|
|
2460
|
+
t(Wn(J.from, J.to, "instant", n)), M();
|
|
2461
2461
|
}
|
|
2462
2462
|
}
|
|
2463
2463
|
),
|
|
2464
2464
|
/* @__PURE__ */ k("div", { className: T.rangeRight, children: [
|
|
2465
2465
|
/* @__PURE__ */ s(
|
|
2466
|
-
|
|
2466
|
+
jn,
|
|
2467
2467
|
{
|
|
2468
2468
|
view: v,
|
|
2469
2469
|
onView: g,
|
|
2470
2470
|
active: N,
|
|
2471
2471
|
onActive: L,
|
|
2472
|
-
onPick:
|
|
2473
|
-
bandFrom:
|
|
2472
|
+
onPick: j,
|
|
2473
|
+
bandFrom: fe,
|
|
2474
2474
|
bandTo: be,
|
|
2475
2475
|
previewTo: we,
|
|
2476
2476
|
onHoverDay: O
|
|
@@ -2484,18 +2484,18 @@ function wu({
|
|
|
2484
2484
|
Z.key === "Enter" && (Z.preventDefault(), de());
|
|
2485
2485
|
},
|
|
2486
2486
|
children: [
|
|
2487
|
-
bt("from", F,
|
|
2487
|
+
bt("from", F, V, U, [ke, Ee, oe], K),
|
|
2488
2488
|
bt("to", _, C, G, [K, _e, ye])
|
|
2489
2489
|
]
|
|
2490
2490
|
}
|
|
2491
2491
|
),
|
|
2492
|
-
|
|
2493
|
-
|
|
2492
|
+
an(u.sideFrom, ee, H, Y),
|
|
2493
|
+
an(u.sideTo, ae, pe, A)
|
|
2494
2494
|
] })
|
|
2495
2495
|
] }),
|
|
2496
2496
|
/* @__PURE__ */ k("div", { className: T.foot, children: [
|
|
2497
2497
|
/* @__PURE__ */ s(
|
|
2498
|
-
|
|
2498
|
+
tn,
|
|
2499
2499
|
{
|
|
2500
2500
|
id: `${$}-allday`,
|
|
2501
2501
|
label: u.allDay,
|
|
@@ -2562,11 +2562,11 @@ const oa = "_divider_39bkm_7", sa = "_strong_39bkm_12", ia = "_horizontal_39bkm_
|
|
|
2562
2562
|
children: /* @__PURE__ */ s("span", { className: ut.label, children: r })
|
|
2563
2563
|
}
|
|
2564
2564
|
);
|
|
2565
|
-
}), da = "_empty_1dx25_4 _text_1hv7a_23", ua = "_icon_1dx25_14",
|
|
2565
|
+
}), da = "_empty_1dx25_4 _text_1hv7a_23", ua = "_icon_1dx25_14", ha = "_title_1dx25_26", fa = "_description_1dx25_33", pa = "_action_1dx25_41", _t = {
|
|
2566
2566
|
empty: da,
|
|
2567
2567
|
icon: ua,
|
|
2568
|
-
title:
|
|
2569
|
-
description:
|
|
2568
|
+
title: ha,
|
|
2569
|
+
description: fa,
|
|
2570
2570
|
action: pa
|
|
2571
2571
|
};
|
|
2572
2572
|
function xu({ title: e, description: t, action: n, icon: r, className: o, ...i }) {
|
|
@@ -2577,7 +2577,7 @@ function xu({ title: e, description: t, action: n, icon: r, className: o, ...i }
|
|
|
2577
2577
|
n && /* @__PURE__ */ s("div", { className: _t.action, children: n })
|
|
2578
2578
|
] });
|
|
2579
2579
|
}
|
|
2580
|
-
const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric_grwj8_47", va = "_invalid_grwj8_55", ya = "_wrapper_grwj8_69 _text_1hv7a_23", ba = "_wrapperSm_grwj8_92", wa = "_wrapperInvalid_grwj8_98", ka = "_wrapperDisabled_grwj8_84", xa = "_inner_grwj8_112 _field_1hv7a_34", Na = "_clear_grwj8_139",
|
|
2580
|
+
const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric_grwj8_47", va = "_invalid_grwj8_55", ya = "_wrapper_grwj8_69 _text_1hv7a_23", ba = "_wrapperSm_grwj8_92", wa = "_wrapperInvalid_grwj8_98", ka = "_wrapperDisabled_grwj8_84", xa = "_inner_grwj8_112 _field_1hv7a_34", Na = "_clear_grwj8_139", ze = {
|
|
2581
2581
|
input: ma,
|
|
2582
2582
|
sm: _a,
|
|
2583
2583
|
numeric: ga,
|
|
@@ -2589,7 +2589,7 @@ const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric
|
|
|
2589
2589
|
inner: xa,
|
|
2590
2590
|
clear: Na
|
|
2591
2591
|
}, Vn = ie(function({ size: t = "md", invalid: n, numeric: r = !1, clearable: o = !1, onClear: i, className: a, id: c, disabled: l, ...d }, u) {
|
|
2592
|
-
const p = Be(),
|
|
2592
|
+
const p = Be(), h = ce(), f = n ?? (p == null ? void 0 : p.invalid) ?? !1, m = (b) => /* @__PURE__ */ s(
|
|
2593
2593
|
"input",
|
|
2594
2594
|
{
|
|
2595
2595
|
ref: u,
|
|
@@ -2597,7 +2597,7 @@ const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric
|
|
|
2597
2597
|
disabled: l,
|
|
2598
2598
|
"aria-describedby": d["aria-describedby"] ?? (p == null ? void 0 : p.describedBy),
|
|
2599
2599
|
"aria-required": (p == null ? void 0 : p.required) || void 0,
|
|
2600
|
-
"aria-invalid":
|
|
2600
|
+
"aria-invalid": f || void 0,
|
|
2601
2601
|
className: b,
|
|
2602
2602
|
...d
|
|
2603
2603
|
}
|
|
@@ -2605,10 +2605,10 @@ const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric
|
|
|
2605
2605
|
if (!o)
|
|
2606
2606
|
return m(
|
|
2607
2607
|
P(
|
|
2608
|
-
|
|
2609
|
-
t === "sm" &&
|
|
2610
|
-
r &&
|
|
2611
|
-
|
|
2608
|
+
ze.input,
|
|
2609
|
+
t === "sm" && ze.sm,
|
|
2610
|
+
r && ze.numeric,
|
|
2611
|
+
f && ze.invalid,
|
|
2612
2612
|
a
|
|
2613
2613
|
)
|
|
2614
2614
|
);
|
|
@@ -2617,21 +2617,21 @@ const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric
|
|
|
2617
2617
|
"span",
|
|
2618
2618
|
{
|
|
2619
2619
|
className: P(
|
|
2620
|
-
|
|
2621
|
-
t === "sm" &&
|
|
2622
|
-
|
|
2623
|
-
l &&
|
|
2620
|
+
ze.wrapper,
|
|
2621
|
+
t === "sm" && ze.wrapperSm,
|
|
2622
|
+
f && ze.wrapperInvalid,
|
|
2623
|
+
l && ze.wrapperDisabled,
|
|
2624
2624
|
a
|
|
2625
2625
|
),
|
|
2626
2626
|
children: [
|
|
2627
|
-
m(P(
|
|
2627
|
+
m(P(ze.inner, r && ze.numeric)),
|
|
2628
2628
|
y && !l && /* @__PURE__ */ s(
|
|
2629
2629
|
"button",
|
|
2630
2630
|
{
|
|
2631
2631
|
type: "button",
|
|
2632
2632
|
tabIndex: -1,
|
|
2633
|
-
"aria-label":
|
|
2634
|
-
className:
|
|
2633
|
+
"aria-label": h.clearInput,
|
|
2634
|
+
className: ze.clear,
|
|
2635
2635
|
onMouseDown: (b) => b.preventDefault(),
|
|
2636
2636
|
onClick: () => i == null ? void 0 : i(),
|
|
2637
2637
|
children: /* @__PURE__ */ s(Ue, {})
|
|
@@ -2640,18 +2640,18 @@ const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric
|
|
|
2640
2640
|
]
|
|
2641
2641
|
}
|
|
2642
2642
|
);
|
|
2643
|
-
}), $a = "_stack_9r3lk_4", Da = "_grid_9r3lk_9",
|
|
2643
|
+
}), $a = "_stack_9r3lk_4", Da = "_grid_9r3lk_9", Un = {
|
|
2644
2644
|
stack: $a,
|
|
2645
2645
|
grid: Da
|
|
2646
|
-
},
|
|
2646
|
+
}, Yn = (e) => `var(--u-space-${e})`, Nu = ie(function({ direction: t = "column", gap: n = 3, align: r, justify: o, wrap: i = !1, className: a, style: c, children: l, ...d }, u) {
|
|
2647
2647
|
return /* @__PURE__ */ s(
|
|
2648
2648
|
"div",
|
|
2649
2649
|
{
|
|
2650
2650
|
ref: u,
|
|
2651
|
-
className: P(
|
|
2651
|
+
className: P(Un.stack, a),
|
|
2652
2652
|
style: {
|
|
2653
2653
|
flexDirection: t,
|
|
2654
|
-
gap:
|
|
2654
|
+
gap: Yn(n),
|
|
2655
2655
|
alignItems: r,
|
|
2656
2656
|
justifyContent: o,
|
|
2657
2657
|
flexWrap: i ? "wrap" : void 0,
|
|
@@ -2666,10 +2666,10 @@ const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric
|
|
|
2666
2666
|
"div",
|
|
2667
2667
|
{
|
|
2668
2668
|
ref: l,
|
|
2669
|
-
className: P(
|
|
2669
|
+
className: P(Un.grid, o),
|
|
2670
2670
|
style: {
|
|
2671
2671
|
gridTemplateColumns: n ? `repeat(auto-fit, minmax(min(${n}, 100%), 1fr))` : `repeat(${t}, minmax(0, 1fr))`,
|
|
2672
|
-
gap:
|
|
2672
|
+
gap: Yn(r),
|
|
2673
2673
|
...i
|
|
2674
2674
|
},
|
|
2675
2675
|
...c,
|
|
@@ -2677,13 +2677,13 @@ const ma = "_input_grwj8_4 _field_1hv7a_34", _a = "_sm_grwj8_41", ga = "_numeric
|
|
|
2677
2677
|
}
|
|
2678
2678
|
);
|
|
2679
2679
|
});
|
|
2680
|
-
function Ta(e, t =
|
|
2680
|
+
function Ta(e, t = Dn) {
|
|
2681
2681
|
const n = [...e].filter((o) => !/\s/.test(o) && (t.group === "" || o !== t.group)).map((o) => o === t.decimal ? "." : o).join("");
|
|
2682
2682
|
if (n === "" || n === "-") return null;
|
|
2683
2683
|
const r = Number(n);
|
|
2684
2684
|
return Number.isFinite(r) ? r : null;
|
|
2685
2685
|
}
|
|
2686
|
-
function
|
|
2686
|
+
function _n(e, t = {}) {
|
|
2687
2687
|
const { min: n, max: r, decimals: o } = t;
|
|
2688
2688
|
let i = e;
|
|
2689
2689
|
if (n !== void 0 && (i = Math.max(n, i)), r !== void 0 && (i = Math.min(r, i)), o !== void 0) {
|
|
@@ -2692,10 +2692,10 @@ function mn(e, t = {}) {
|
|
|
2692
2692
|
}
|
|
2693
2693
|
return i;
|
|
2694
2694
|
}
|
|
2695
|
-
const Sa = (e) => e === void 0 || e < 0,
|
|
2696
|
-
function Ma(e, t = {}, n =
|
|
2695
|
+
const Sa = (e) => e === void 0 || e < 0, Kn = (e) => e !== 0;
|
|
2696
|
+
function Ma(e, t = {}, n = Dn) {
|
|
2697
2697
|
const r = /* @__PURE__ */ new Set([..."0123456789", n.group]);
|
|
2698
|
-
return
|
|
2698
|
+
return Kn(t.decimals) && r.add(n.decimal), Sa(t.min) && r.add("-"), r.delete(""), [...e].filter((o) => r.has(o)).join("");
|
|
2699
2699
|
}
|
|
2700
2700
|
function Ca(e, t, n, r = 1) {
|
|
2701
2701
|
return e + t * n * r;
|
|
@@ -2720,14 +2720,14 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2720
2720
|
size: d = "md",
|
|
2721
2721
|
invalid: u,
|
|
2722
2722
|
disabled: p,
|
|
2723
|
-
className:
|
|
2724
|
-
id:
|
|
2723
|
+
className: h,
|
|
2724
|
+
id: f,
|
|
2725
2725
|
onFocus: m,
|
|
2726
2726
|
onBlur: y,
|
|
2727
2727
|
onKeyDown: b,
|
|
2728
2728
|
...v
|
|
2729
2729
|
}, g) {
|
|
2730
|
-
const N = Be(), L = ce(), F =
|
|
2730
|
+
const N = Be(), L = ce(), F = Ve(), D = (K) => F.number(K, a), _ = se(() => ar(F), [F]), E = (K) => Ta(K, _), w = u ?? (N == null ? void 0 : N.invalid) ?? !1, O = se(() => ({ min: r, max: o, decimals: a }), [r, o, a]), [V, U] = B(() => t === null ? "" : D(t)), [C, G] = B(!1);
|
|
2731
2731
|
ne(() => {
|
|
2732
2732
|
C || U(t === null ? "" : D(t));
|
|
2733
2733
|
}, [t, C, a, F]);
|
|
@@ -2736,10 +2736,10 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2736
2736
|
U(""), n(null);
|
|
2737
2737
|
return;
|
|
2738
2738
|
}
|
|
2739
|
-
const _e =
|
|
2739
|
+
const _e = _n(K, O);
|
|
2740
2740
|
U(D(_e)), n(_e);
|
|
2741
|
-
}, X = R(
|
|
2742
|
-
X.current =
|
|
2741
|
+
}, X = R(V);
|
|
2742
|
+
X.current = V;
|
|
2743
2743
|
const H = R(t);
|
|
2744
2744
|
H.current = t;
|
|
2745
2745
|
const Y = (K, _e = 1) => {
|
|
@@ -2751,7 +2751,7 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2751
2751
|
A.current !== null && (clearTimeout(A.current), A.current = null);
|
|
2752
2752
|
};
|
|
2753
2753
|
ne(() => I, []);
|
|
2754
|
-
const
|
|
2754
|
+
const q = (K, _e) => {
|
|
2755
2755
|
Y(K, _e ? 10 : 1);
|
|
2756
2756
|
const ye = (xe) => {
|
|
2757
2757
|
A.current = setTimeout(() => {
|
|
@@ -2759,7 +2759,7 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2759
2759
|
}, xe);
|
|
2760
2760
|
};
|
|
2761
2761
|
ye(400);
|
|
2762
|
-
}, te = E(
|
|
2762
|
+
}, te = E(V) ?? t, ke = !p && (o === void 0 || te === null || te < o), Ee = !p && (r === void 0 || te === null || te > r), oe = (K, _e, ye, xe) => /* @__PURE__ */ s(
|
|
2763
2763
|
"button",
|
|
2764
2764
|
{
|
|
2765
2765
|
type: "button",
|
|
@@ -2767,7 +2767,7 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2767
2767
|
disabled: p || !_e,
|
|
2768
2768
|
"aria-label": ye,
|
|
2769
2769
|
onPointerDown: ($) => {
|
|
2770
|
-
$.preventDefault(), $.button === 0 &&
|
|
2770
|
+
$.preventDefault(), $.button === 0 && q(K, $.shiftKey);
|
|
2771
2771
|
},
|
|
2772
2772
|
onPointerUp: I,
|
|
2773
2773
|
onPointerLeave: I,
|
|
@@ -2784,7 +2784,7 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2784
2784
|
d === "sm" && Ke.sm,
|
|
2785
2785
|
w && Ke.invalid,
|
|
2786
2786
|
p && Ke.disabled,
|
|
2787
|
-
|
|
2787
|
+
h
|
|
2788
2788
|
),
|
|
2789
2789
|
children: [
|
|
2790
2790
|
c && /* @__PURE__ */ s("span", { className: Ke.adornment, children: c }),
|
|
@@ -2793,19 +2793,19 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2793
2793
|
{
|
|
2794
2794
|
ref: g,
|
|
2795
2795
|
type: "text",
|
|
2796
|
-
inputMode:
|
|
2797
|
-
id:
|
|
2796
|
+
inputMode: Kn(a) ? "decimal" : "numeric",
|
|
2797
|
+
id: f ?? (N == null ? void 0 : N.id),
|
|
2798
2798
|
disabled: p,
|
|
2799
2799
|
"aria-describedby": v["aria-describedby"] ?? (N == null ? void 0 : N.describedBy),
|
|
2800
2800
|
"aria-required": (N == null ? void 0 : N.required) || void 0,
|
|
2801
2801
|
"aria-invalid": w || void 0,
|
|
2802
2802
|
className: Ke.input,
|
|
2803
|
-
value:
|
|
2803
|
+
value: V,
|
|
2804
2804
|
onChange: (K) => {
|
|
2805
2805
|
const _e = Ma(K.target.value, O, _);
|
|
2806
2806
|
U(_e);
|
|
2807
2807
|
const ye = E(_e);
|
|
2808
|
-
n(ye === null ? null :
|
|
2808
|
+
n(ye === null ? null : _n(ye, O));
|
|
2809
2809
|
},
|
|
2810
2810
|
...v,
|
|
2811
2811
|
onKeyDown: pe,
|
|
@@ -2819,22 +2819,22 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2819
2819
|
),
|
|
2820
2820
|
l && /* @__PURE__ */ s("span", { className: Ke.adornment, children: l }),
|
|
2821
2821
|
/* @__PURE__ */ k("span", { className: Ke.stepper, children: [
|
|
2822
|
-
oe(-1, Ee, L.decreaseValue, /* @__PURE__ */ s(
|
|
2823
|
-
oe(1, ke, L.increaseValue, /* @__PURE__ */ s(
|
|
2822
|
+
oe(-1, Ee, L.decreaseValue, /* @__PURE__ */ s(kr, {})),
|
|
2823
|
+
oe(1, ke, L.increaseValue, /* @__PURE__ */ s(wr, {}))
|
|
2824
2824
|
] })
|
|
2825
2825
|
]
|
|
2826
2826
|
}
|
|
2827
2827
|
);
|
|
2828
|
-
}), Ba = "_dialog_1hit9_8 _text_1hv7a_23",
|
|
2828
|
+
}), Ba = "_dialog_1hit9_8 _text_1hv7a_23", za = "_spacerTop_1hit9_30", Oa = "_spacerBottom_1hit9_35", Ha = "_sheet_1hit9_2", qa = "_sm_1hit9_52", Wa = "_md_1hit9_53", Ga = "_lg_1hit9_54", ja = "_header_1hit9_104", Va = "_headerText_1hit9_112", Ua = "_title_1hit9_119", Ya = "_description_1hit9_127", Ka = "_close_1hit9_134 _ring_1hv7a_65", Xa = "_footer_1hit9_164", Qa = "_body_1hit9_168 _scroll_1hv7a_40", Za = "_modalIn_1hit9_1", Ja = "_modalOut_1hit9_1", ec = "_backdropIn_1hit9_1", tc = "_backdropOut_1hit9_1", Ie = {
|
|
2829
2829
|
dialog: Ba,
|
|
2830
|
-
spacerTop:
|
|
2830
|
+
spacerTop: za,
|
|
2831
2831
|
spacerBottom: Oa,
|
|
2832
2832
|
sheet: Ha,
|
|
2833
|
-
sm:
|
|
2833
|
+
sm: qa,
|
|
2834
2834
|
md: Wa,
|
|
2835
2835
|
lg: Ga,
|
|
2836
|
-
header:
|
|
2837
|
-
headerText:
|
|
2836
|
+
header: ja,
|
|
2837
|
+
headerText: Va,
|
|
2838
2838
|
title: Ua,
|
|
2839
2839
|
description: Ya,
|
|
2840
2840
|
close: Ka,
|
|
@@ -2844,7 +2844,7 @@ const Aa = "_wrapper_7i1oo_4 _text_1hv7a_23", La = "_sm_7i1oo_26", Ra = "_invali
|
|
|
2844
2844
|
modalOut: Ja,
|
|
2845
2845
|
backdropIn: ec,
|
|
2846
2846
|
backdropOut: tc
|
|
2847
|
-
},
|
|
2847
|
+
}, Xn = je(null);
|
|
2848
2848
|
function nc({
|
|
2849
2849
|
open: e,
|
|
2850
2850
|
onClose: t,
|
|
@@ -2854,7 +2854,7 @@ function nc({
|
|
|
2854
2854
|
children: i,
|
|
2855
2855
|
...a
|
|
2856
2856
|
}) {
|
|
2857
|
-
const c = R(null), l = De(), { dialogRef: d, closing: u, beimSchliessen: p, beimAbbrechen:
|
|
2857
|
+
const c = R(null), l = De(), { dialogRef: d, closing: u, beimSchliessen: p, beimAbbrechen: h } = Bn(e, "--u-duration-exit", t), f = (m) => {
|
|
2858
2858
|
r && c.current && !c.current.contains(m.target) && t();
|
|
2859
2859
|
};
|
|
2860
2860
|
return /* @__PURE__ */ k(
|
|
@@ -2864,20 +2864,20 @@ function nc({
|
|
|
2864
2864
|
"data-closing": u || void 0,
|
|
2865
2865
|
className: P(Ie.dialog, o),
|
|
2866
2866
|
onClose: p,
|
|
2867
|
-
onCancel:
|
|
2868
|
-
onMouseDown:
|
|
2867
|
+
onCancel: h,
|
|
2868
|
+
onMouseDown: f,
|
|
2869
2869
|
"aria-labelledby": l,
|
|
2870
2870
|
...a,
|
|
2871
2871
|
children: [
|
|
2872
2872
|
/* @__PURE__ */ s("div", { className: Ie.spacerTop, "aria-hidden": "true" }),
|
|
2873
|
-
/* @__PURE__ */ s("div", { ref: c, className: P(Ie.sheet, Ie[n]), children: /* @__PURE__ */ s(
|
|
2873
|
+
/* @__PURE__ */ s("div", { ref: c, className: P(Ie.sheet, Ie[n]), children: /* @__PURE__ */ s(Xn.Provider, { value: { onClose: t, titleId: l }, children: i }) }),
|
|
2874
2874
|
/* @__PURE__ */ s("div", { className: Ie.spacerBottom, "aria-hidden": "true" })
|
|
2875
2875
|
]
|
|
2876
2876
|
}
|
|
2877
2877
|
);
|
|
2878
2878
|
}
|
|
2879
2879
|
function rc({ title: e, description: t, hideClose: n = !1, className: r, ...o }) {
|
|
2880
|
-
const i = He(
|
|
2880
|
+
const i = He(Xn), a = ce();
|
|
2881
2881
|
return /* @__PURE__ */ k("div", { className: P(Ie.header, r), ...o, children: [
|
|
2882
2882
|
/* @__PURE__ */ k("div", { className: Ie.headerText, children: [
|
|
2883
2883
|
/* @__PURE__ */ s("h2", { id: i == null ? void 0 : i.titleId, className: Ie.title, children: e }),
|
|
@@ -2921,7 +2921,7 @@ function Su({
|
|
|
2921
2921
|
] })
|
|
2922
2922
|
] });
|
|
2923
2923
|
}
|
|
2924
|
-
const sc = "
|
|
2924
|
+
const sc = "_field_ovdvz_8 _text_1hv7a_23", ic = "_invalid_ovdvz_33", ac = "_fieldDisabled_ovdvz_25", cc = "_placeholder_ovdvz_47", lc = "_summary_ovdvz_56", dc = "_measure_ovdvz_69", uc = "_chipLabel_ovdvz_80", hc = "_chip_ovdvz_80 _ring_1hv7a_65", fc = "_chipX_ovdvz_133", pc = "_counter_ovdvz_153 _ring_1hv7a_65", mc = "_main_ovdvz_183", _c = "_mainEmpty_ovdvz_208", gc = "_chevron_ovdvz_214", vc = "_panel_ovdvz_223", yc = "_scopes_ovdvz_232", bc = "_scope_ovdvz_232 _ring_1hv7a_65", wc = "_scopeActive_ovdvz_265", kc = "_qol_ovdvz_271", xc = "_qolButtons_ovdvz_281", Nc = "_count_ovdvz_153", $c = "_list_ovdvz_296 _scroll_1hv7a_40", Dc = "_option_ovdvz_308", Tc = "_empty_ovdvz_323", re = {
|
|
2925
2925
|
field: sc,
|
|
2926
2926
|
invalid: ic,
|
|
2927
2927
|
fieldDisabled: ac,
|
|
@@ -2929,8 +2929,8 @@ const sc = "_field_docqp_8 _text_1hv7a_23", ic = "_invalid_docqp_33", ac = "_fie
|
|
|
2929
2929
|
summary: lc,
|
|
2930
2930
|
measure: dc,
|
|
2931
2931
|
chipLabel: uc,
|
|
2932
|
-
chip:
|
|
2933
|
-
chipX:
|
|
2932
|
+
chip: hc,
|
|
2933
|
+
chipX: fc,
|
|
2934
2934
|
counter: pc,
|
|
2935
2935
|
main: mc,
|
|
2936
2936
|
mainEmpty: _c,
|
|
@@ -2956,7 +2956,7 @@ function Mu({
|
|
|
2956
2956
|
disabled: a = !1,
|
|
2957
2957
|
invalid: c
|
|
2958
2958
|
}) {
|
|
2959
|
-
const l = Be(), d = ce(), u = r ?? d.multiSelectPlaceholder, p = o ?? d.multiSelectSearchPlaceholder,
|
|
2959
|
+
const l = Be(), d = ce(), u = r ?? d.multiSelectPlaceholder, p = o ?? d.multiSelectSearchPlaceholder, h = i ?? d.noMatches, f = c ?? (l == null ? void 0 : l.invalid) ?? !1, [m, y] = B(!1), [b, v] = B(""), [g, N] = B("all"), [L, F] = B(/* @__PURE__ */ new Set()), D = R(null), _ = R(null), E = R(null), w = R(null), O = De(), V = (x = "all") => {
|
|
2960
2960
|
N(x), F(new Set(t)), v(""), y(!0);
|
|
2961
2961
|
}, U = (x) => {
|
|
2962
2962
|
var W;
|
|
@@ -2967,20 +2967,20 @@ function Mu({
|
|
|
2967
2967
|
}, []), G = se(
|
|
2968
2968
|
() => g === "selected" ? e.filter((x) => L.has(x.value)) : e,
|
|
2969
2969
|
[e, g, L]
|
|
2970
|
-
), S = se(() =>
|
|
2970
|
+
), S = se(() => zn(G, b), [G, b]), X = (x) => {
|
|
2971
2971
|
n(
|
|
2972
2972
|
t.includes(x) ? t.filter((W) => W !== x) : [...t, x]
|
|
2973
2973
|
);
|
|
2974
2974
|
}, H = (x) => {
|
|
2975
2975
|
n(t.filter((W) => W !== x));
|
|
2976
|
-
}, Y = se(() => Co(S), [S]), pe = () => n(Ao(t, Y)), A = () => n(Lo(t, Y)), I = () => n(Ro(t, Y)),
|
|
2976
|
+
}, Y = se(() => Co(S), [S]), pe = () => n(Ao(t, Y)), A = () => n(Lo(t, Y)), I = () => n(Ro(t, Y)), q = () => {
|
|
2977
2977
|
var x;
|
|
2978
2978
|
return Array.from(((x = w.current) == null ? void 0 : x.querySelectorAll("input:not(:disabled)")) ?? []);
|
|
2979
2979
|
}, te = (x) => {
|
|
2980
2980
|
var W;
|
|
2981
2981
|
if (!x.nativeEvent.isComposing) {
|
|
2982
2982
|
if (x.key === "ArrowDown") {
|
|
2983
|
-
x.preventDefault(), (W =
|
|
2983
|
+
x.preventDefault(), (W = q()[0]) == null || W.focus();
|
|
2984
2984
|
return;
|
|
2985
2985
|
}
|
|
2986
2986
|
if (x.key === "Enter") {
|
|
@@ -2990,10 +2990,10 @@ function Mu({
|
|
|
2990
2990
|
}
|
|
2991
2991
|
}
|
|
2992
2992
|
}, ke = (x) => {
|
|
2993
|
-
var ae, le, ue, de,
|
|
2993
|
+
var ae, le, ue, de, fe;
|
|
2994
2994
|
if (!["ArrowDown", "ArrowUp", "Home", "End"].includes(x.key)) return;
|
|
2995
|
-
const W =
|
|
2996
|
-
ee !== -1 && (x.preventDefault(), x.key === "ArrowDown" && ((ae = W[Math.min(ee + 1, W.length - 1)]) == null || ae.focus()), x.key === "ArrowUp" && (ee === 0 ? (le = E.current) == null || le.focus() : (ue = W[ee - 1]) == null || ue.focus()), x.key === "Home" && ((de = W[0]) == null || de.focus()), x.key === "End" && ((
|
|
2995
|
+
const W = q(), ee = W.findIndex((be) => be === document.activeElement);
|
|
2996
|
+
ee !== -1 && (x.preventDefault(), x.key === "ArrowDown" && ((ae = W[Math.min(ee + 1, W.length - 1)]) == null || ae.focus()), x.key === "ArrowUp" && (ee === 0 ? (le = E.current) == null || le.focus() : (ue = W[ee - 1]) == null || ue.focus()), x.key === "Home" && ((de = W[0]) == null || de.focus()), x.key === "End" && ((fe = W[W.length - 1]) == null || fe.focus()));
|
|
2997
2997
|
}, Ee = () => {
|
|
2998
2998
|
var x;
|
|
2999
2999
|
return Array.from(((x = D.current) == null ? void 0 : x.querySelectorAll("[data-nav]")) ?? []);
|
|
@@ -3008,13 +3008,13 @@ function Mu({
|
|
|
3008
3008
|
const ae = ee.indexOf(W);
|
|
3009
3009
|
ae !== -1 && (x.key === "ArrowRight" ? (x.preventDefault(), (ue = ee[ae + 1] ?? _.current) == null || ue.focus()) : x.key === "ArrowLeft" ? (x.preventDefault(), (de = ee[ae - 1]) == null || de.focus()) : (x.key === "Delete" || x.key === "Backspace") && W.dataset.value && (x.preventDefault(), H(W.dataset.value), requestAnimationFrame(() => {
|
|
3010
3010
|
var be;
|
|
3011
|
-
const
|
|
3012
|
-
(be =
|
|
3011
|
+
const fe = Ee();
|
|
3012
|
+
(be = fe[Math.min(ae, fe.length - 1)] ?? _.current) == null || be.focus();
|
|
3013
3013
|
})));
|
|
3014
3014
|
}, K = se(
|
|
3015
3015
|
() => e.filter((x) => t.includes(x.value)),
|
|
3016
3016
|
[e, t]
|
|
3017
|
-
), [_e, ye] = B(1), xe = R(null), $ = R(null),
|
|
3017
|
+
), [_e, ye] = B(1), xe = R(null), $ = R(null), z = Q(() => {
|
|
3018
3018
|
var be;
|
|
3019
3019
|
const x = xe.current, W = $.current;
|
|
3020
3020
|
if (!x || !W) return;
|
|
@@ -3024,34 +3024,34 @@ function Mu({
|
|
|
3024
3024
|
return;
|
|
3025
3025
|
}
|
|
3026
3026
|
const ae = ((be = ee[ee.length - 1]) == null ? void 0 : be.offsetWidth) ?? 0, le = ee.slice(0, -1).map((we) => we.offsetWidth), ue = x.clientWidth, de = Number.parseFloat(getComputedStyle(W).columnGap) || 0;
|
|
3027
|
-
let
|
|
3027
|
+
let fe = 1;
|
|
3028
3028
|
for (let we = le.length; we >= 1; we -= 1) {
|
|
3029
|
-
let
|
|
3030
|
-
for (let Fe = 0; Fe < we; Fe += 1)
|
|
3031
|
-
if (we < le.length && (
|
|
3032
|
-
|
|
3029
|
+
let he = (we - 1) * de;
|
|
3030
|
+
for (let Fe = 0; Fe < we; Fe += 1) he += le[Fe] ?? 0;
|
|
3031
|
+
if (we < le.length && (he += de + ae), he <= ue) {
|
|
3032
|
+
fe = we;
|
|
3033
3033
|
break;
|
|
3034
3034
|
}
|
|
3035
3035
|
}
|
|
3036
|
-
ye(
|
|
3036
|
+
ye(fe);
|
|
3037
3037
|
}, []);
|
|
3038
3038
|
Oe(() => {
|
|
3039
|
-
|
|
3039
|
+
z();
|
|
3040
3040
|
}), ne(() => {
|
|
3041
3041
|
const x = D.current;
|
|
3042
3042
|
if (!x) return;
|
|
3043
|
-
const W = new ResizeObserver(() =>
|
|
3043
|
+
const W = new ResizeObserver(() => z());
|
|
3044
3044
|
return W.observe(x), () => W.disconnect();
|
|
3045
|
-
}, [
|
|
3046
|
-
const M = t.length - _e,
|
|
3045
|
+
}, [z]);
|
|
3046
|
+
const M = t.length - _e, j = /* @__PURE__ */ s(Ue, { size: 8 });
|
|
3047
3047
|
return /* @__PURE__ */ k($e, { children: [
|
|
3048
3048
|
/* @__PURE__ */ k(
|
|
3049
3049
|
"div",
|
|
3050
3050
|
{
|
|
3051
3051
|
ref: D,
|
|
3052
|
-
className: P(re.field,
|
|
3052
|
+
className: P(re.field, f && re.invalid, a && re.fieldDisabled),
|
|
3053
3053
|
onClick: () => {
|
|
3054
|
-
a || (m ? y(!1) :
|
|
3054
|
+
a || (m ? y(!1) : V("all"));
|
|
3055
3055
|
},
|
|
3056
3056
|
onKeyDown: oe,
|
|
3057
3057
|
children: [
|
|
@@ -3072,7 +3072,7 @@ function Mu({
|
|
|
3072
3072
|
},
|
|
3073
3073
|
children: [
|
|
3074
3074
|
/* @__PURE__ */ s("span", { className: re.chipLabel, children: x.label }),
|
|
3075
|
-
/* @__PURE__ */ s("span", { className: re.chipX, children:
|
|
3075
|
+
/* @__PURE__ */ s("span", { className: re.chipX, children: j })
|
|
3076
3076
|
]
|
|
3077
3077
|
},
|
|
3078
3078
|
x.value
|
|
@@ -3087,7 +3087,7 @@ function Mu({
|
|
|
3087
3087
|
className: re.counter,
|
|
3088
3088
|
"aria-label": d.manageMoreSelected(t.length),
|
|
3089
3089
|
onClick: (x) => {
|
|
3090
|
-
x.stopPropagation(),
|
|
3090
|
+
x.stopPropagation(), V("selected");
|
|
3091
3091
|
},
|
|
3092
3092
|
children: [
|
|
3093
3093
|
"+",
|
|
@@ -3099,7 +3099,7 @@ function Mu({
|
|
|
3099
3099
|
/* @__PURE__ */ k("span", { ref: $, className: P(re.summary, re.measure), "aria-hidden": "true", children: [
|
|
3100
3100
|
K.map((x) => /* @__PURE__ */ k("span", { className: re.chip, children: [
|
|
3101
3101
|
/* @__PURE__ */ s("span", { className: re.chipLabel, children: x.label }),
|
|
3102
|
-
/* @__PURE__ */ s("span", { className: re.chipX, children:
|
|
3102
|
+
/* @__PURE__ */ s("span", { className: re.chipX, children: j })
|
|
3103
3103
|
] }, x.value)),
|
|
3104
3104
|
/* @__PURE__ */ k("span", { className: re.counter, children: [
|
|
3105
3105
|
"+",
|
|
@@ -3118,14 +3118,14 @@ function Mu({
|
|
|
3118
3118
|
"aria-expanded": m,
|
|
3119
3119
|
"aria-controls": m ? O : void 0,
|
|
3120
3120
|
"aria-describedby": l == null ? void 0 : l.describedBy,
|
|
3121
|
-
"aria-invalid":
|
|
3121
|
+
"aria-invalid": f || void 0,
|
|
3122
3122
|
className: P(re.main, t.length === 0 && re.mainEmpty),
|
|
3123
3123
|
onClick: (x) => {
|
|
3124
|
-
x.stopPropagation(), m ? y(!1) :
|
|
3124
|
+
x.stopPropagation(), m ? y(!1) : V("all");
|
|
3125
3125
|
},
|
|
3126
3126
|
children: [
|
|
3127
3127
|
t.length === 0 && /* @__PURE__ */ s("span", { className: re.placeholder, children: u }),
|
|
3128
|
-
/* @__PURE__ */ s(
|
|
3128
|
+
/* @__PURE__ */ s(St, { className: re.chevron })
|
|
3129
3129
|
]
|
|
3130
3130
|
}
|
|
3131
3131
|
)
|
|
@@ -3203,8 +3203,8 @@ function Mu({
|
|
|
3203
3203
|
role: "group",
|
|
3204
3204
|
"aria-label": d.options,
|
|
3205
3205
|
onKeyDown: ke,
|
|
3206
|
-
children: S.length === 0 ? /* @__PURE__ */ s("div", { className: re.empty, children: g === "selected" && G.length === 0 ? d.nothingSelected :
|
|
3207
|
-
|
|
3206
|
+
children: S.length === 0 ? /* @__PURE__ */ s("div", { className: re.empty, children: g === "selected" && G.length === 0 ? d.nothingSelected : h }) : S.map((x) => /* @__PURE__ */ s(
|
|
3207
|
+
tn,
|
|
3208
3208
|
{
|
|
3209
3209
|
className: re.option,
|
|
3210
3210
|
label: x.label,
|
|
@@ -3221,7 +3221,7 @@ function Mu({
|
|
|
3221
3221
|
)
|
|
3222
3222
|
] });
|
|
3223
3223
|
}
|
|
3224
|
-
const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_option_4y2h4_21", Ac = "_disabled_4y2h4_28", Lc = "_input_4y2h4_35", Rc = "_dot_4y2h4_44", Pc = "_texts_4y2h4_100", Ec = "_label_4y2h4_107", Fc = "_description_4y2h4_115", Ic = "_sm_4y2h4_124",
|
|
3224
|
+
const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_option_4y2h4_21", Ac = "_disabled_4y2h4_28", Lc = "_input_4y2h4_35", Rc = "_dot_4y2h4_44", Pc = "_texts_4y2h4_100", Ec = "_label_4y2h4_107", Fc = "_description_4y2h4_115", Ic = "_sm_4y2h4_124", qe = {
|
|
3225
3225
|
group: Sc,
|
|
3226
3226
|
horizontal: Mc,
|
|
3227
3227
|
option: Cc,
|
|
@@ -3244,8 +3244,8 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3244
3244
|
className: d,
|
|
3245
3245
|
onKeyDown: u,
|
|
3246
3246
|
...p
|
|
3247
|
-
},
|
|
3248
|
-
const
|
|
3247
|
+
}, h) {
|
|
3248
|
+
const f = Be(), m = De(), y = l ?? (f == null ? void 0 : f.id) ?? m, b = R(null), v = n !== void 0, g = t.filter((D) => !D.disabled && !c), N = (D) => {
|
|
3249
3249
|
o == null || o(D.value);
|
|
3250
3250
|
}, L = (D) => {
|
|
3251
3251
|
var G, S, X, H;
|
|
@@ -3253,7 +3253,7 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3253
3253
|
const _ = D.key === "ArrowDown" || D.key === "ArrowRight", E = D.key === "ArrowUp" || D.key === "ArrowLeft";
|
|
3254
3254
|
if (!_ && !E || g.length === 0) return;
|
|
3255
3255
|
D.preventDefault();
|
|
3256
|
-
const w = (v ? n : (S = (G = b.current) == null ? void 0 : G.querySelector("input:checked")) == null ? void 0 : S.value) ?? null, O = g.findIndex((Y) => Y.value === w),
|
|
3256
|
+
const w = (v ? n : (S = (G = b.current) == null ? void 0 : G.querySelector("input:checked")) == null ? void 0 : S.value) ?? null, O = g.findIndex((Y) => Y.value === w), V = O === -1 ? 0 : (O + (_ ? 1 : -1) + g.length) % g.length, U = g[V];
|
|
3257
3257
|
if (!U) return;
|
|
3258
3258
|
(H = Array.from(
|
|
3259
3259
|
((X = b.current) == null ? void 0 : X.querySelectorAll('input[type="radio"]')) ?? []
|
|
@@ -3266,18 +3266,18 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3266
3266
|
"div",
|
|
3267
3267
|
{
|
|
3268
3268
|
ref: (D) => {
|
|
3269
|
-
b.current = D, typeof
|
|
3269
|
+
b.current = D, typeof h == "function" ? h(D) : h && (h.current = D);
|
|
3270
3270
|
},
|
|
3271
|
-
id:
|
|
3271
|
+
id: f == null ? void 0 : f.id,
|
|
3272
3272
|
role: "radiogroup",
|
|
3273
3273
|
"aria-orientation": i,
|
|
3274
|
-
"aria-describedby": p["aria-describedby"] ?? (
|
|
3275
|
-
"aria-required": (
|
|
3276
|
-
"aria-invalid": (
|
|
3274
|
+
"aria-describedby": p["aria-describedby"] ?? (f == null ? void 0 : f.describedBy),
|
|
3275
|
+
"aria-required": (f == null ? void 0 : f.required) || void 0,
|
|
3276
|
+
"aria-invalid": (f == null ? void 0 : f.invalid) || void 0,
|
|
3277
3277
|
className: P(
|
|
3278
|
-
|
|
3279
|
-
i === "horizontal" &&
|
|
3280
|
-
a === "sm" &&
|
|
3278
|
+
qe.group,
|
|
3279
|
+
i === "horizontal" && qe.horizontal,
|
|
3280
|
+
a === "sm" && qe.sm,
|
|
3281
3281
|
d
|
|
3282
3282
|
),
|
|
3283
3283
|
...p,
|
|
@@ -3287,7 +3287,7 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3287
3287
|
return /* @__PURE__ */ k(
|
|
3288
3288
|
"label",
|
|
3289
3289
|
{
|
|
3290
|
-
className: P(
|
|
3290
|
+
className: P(qe.option, w && qe.disabled),
|
|
3291
3291
|
htmlFor: _,
|
|
3292
3292
|
children: [
|
|
3293
3293
|
/* @__PURE__ */ s(
|
|
@@ -3299,15 +3299,15 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3299
3299
|
value: D.value,
|
|
3300
3300
|
disabled: w,
|
|
3301
3301
|
tabIndex: F(D),
|
|
3302
|
-
className:
|
|
3302
|
+
className: qe.input,
|
|
3303
3303
|
"aria-describedby": E,
|
|
3304
3304
|
...v ? { checked: n === D.value, onChange: () => N(D) } : { defaultChecked: r === D.value, onChange: () => N(D) }
|
|
3305
3305
|
}
|
|
3306
3306
|
),
|
|
3307
|
-
/* @__PURE__ */ s("span", { className:
|
|
3308
|
-
/* @__PURE__ */ k("span", { className:
|
|
3309
|
-
/* @__PURE__ */ s("span", { className:
|
|
3310
|
-
D.description && /* @__PURE__ */ s("span", { id: E, className:
|
|
3307
|
+
/* @__PURE__ */ s("span", { className: qe.dot, "aria-hidden": "true" }),
|
|
3308
|
+
/* @__PURE__ */ k("span", { className: qe.texts, children: [
|
|
3309
|
+
/* @__PURE__ */ s("span", { className: qe.label, children: D.label }),
|
|
3310
|
+
D.description && /* @__PURE__ */ s("span", { id: E, className: qe.description, children: D.description })
|
|
3311
3311
|
] })
|
|
3312
3312
|
]
|
|
3313
3313
|
},
|
|
@@ -3316,16 +3316,16 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3316
3316
|
})
|
|
3317
3317
|
}
|
|
3318
3318
|
);
|
|
3319
|
-
}), Bc = "
|
|
3319
|
+
}), Bc = "_wrapper_19yjk_4 _text_1hv7a_23", zc = "_select_19yjk_11 _field_1hv7a_34", Oc = "_sm_19yjk_57", Hc = "_invalid_19yjk_63", qc = "_chevron_19yjk_72", Wc = "_selectClearable_19yjk_84", Gc = "_clear_19yjk_89", rt = {
|
|
3320
3320
|
wrapper: Bc,
|
|
3321
|
-
select:
|
|
3321
|
+
select: zc,
|
|
3322
3322
|
sm: Oc,
|
|
3323
3323
|
invalid: Hc,
|
|
3324
|
-
chevron:
|
|
3324
|
+
chevron: qc,
|
|
3325
3325
|
selectClearable: Wc,
|
|
3326
3326
|
clear: Gc
|
|
3327
3327
|
}, Au = ie(function({ selectSize: t = "md", invalid: n, clearable: r = !1, onClear: o, className: i, id: a, children: c, disabled: l, ...d }, u) {
|
|
3328
|
-
const p = Be(),
|
|
3328
|
+
const p = Be(), h = ce(), f = n ?? (p == null ? void 0 : p.invalid) ?? !1, m = r && !d.multiple && String(d.value ?? "") !== "";
|
|
3329
3329
|
return /* @__PURE__ */ k("span", { className: P(rt.wrapper, i), children: [
|
|
3330
3330
|
/* @__PURE__ */ s(
|
|
3331
3331
|
"select",
|
|
@@ -3335,12 +3335,12 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3335
3335
|
disabled: l,
|
|
3336
3336
|
"aria-describedby": d["aria-describedby"] ?? (p == null ? void 0 : p.describedBy),
|
|
3337
3337
|
"aria-required": (p == null ? void 0 : p.required) || void 0,
|
|
3338
|
-
"aria-invalid":
|
|
3338
|
+
"aria-invalid": f || void 0,
|
|
3339
3339
|
className: P(
|
|
3340
3340
|
rt.select,
|
|
3341
3341
|
t === "sm" && rt.sm,
|
|
3342
3342
|
r && rt.selectClearable,
|
|
3343
|
-
|
|
3343
|
+
f && rt.invalid
|
|
3344
3344
|
),
|
|
3345
3345
|
...d,
|
|
3346
3346
|
children: c
|
|
@@ -3351,25 +3351,25 @@ const Sc = "_group_4y2h4_8 _text_1hv7a_23", Mc = "_horizontal_4y2h4_15", Cc = "_
|
|
|
3351
3351
|
{
|
|
3352
3352
|
type: "button",
|
|
3353
3353
|
tabIndex: -1,
|
|
3354
|
-
"aria-label":
|
|
3354
|
+
"aria-label": h.clearSelection,
|
|
3355
3355
|
className: rt.clear,
|
|
3356
3356
|
onMouseDown: (y) => y.preventDefault(),
|
|
3357
3357
|
onClick: () => o == null ? void 0 : o(),
|
|
3358
3358
|
children: /* @__PURE__ */ s(Ue, {})
|
|
3359
3359
|
}
|
|
3360
3360
|
),
|
|
3361
|
-
/* @__PURE__ */ s(
|
|
3361
|
+
/* @__PURE__ */ s(St, { className: rt.chevron })
|
|
3362
3362
|
] });
|
|
3363
|
-
}),
|
|
3364
|
-
skeleton:
|
|
3365
|
-
circle:
|
|
3363
|
+
}), jc = "_skeleton_6mkat_4", Vc = "_circle_6mkat_19", gn = {
|
|
3364
|
+
skeleton: jc,
|
|
3365
|
+
circle: Vc
|
|
3366
3366
|
};
|
|
3367
3367
|
function Lu({ width: e, height: t, circle: n = !1, className: r, style: o, ...i }) {
|
|
3368
3368
|
return /* @__PURE__ */ s(
|
|
3369
3369
|
"span",
|
|
3370
3370
|
{
|
|
3371
3371
|
"aria-hidden": "true",
|
|
3372
|
-
className: P(
|
|
3372
|
+
className: P(gn.skeleton, n && gn.circle, r),
|
|
3373
3373
|
style: { width: e, height: t, ...o },
|
|
3374
3374
|
...i
|
|
3375
3375
|
}
|
|
@@ -3387,56 +3387,56 @@ const Uc = "_group_13w8u_7", Yc = "_tag_13w8u_16 _text_1hv7a_23", Kc = "_removab
|
|
|
3387
3387
|
warning: tl,
|
|
3388
3388
|
danger: nl,
|
|
3389
3389
|
remove: rl
|
|
3390
|
-
},
|
|
3390
|
+
}, Qn = je(!1), Ru = ie(function({ className: t, children: n, onKeyDown: r, onFocus: o, ...i }, a) {
|
|
3391
3391
|
const c = R(null), l = Q(
|
|
3392
3392
|
() => {
|
|
3393
|
-
var
|
|
3394
|
-
return Array.from(((
|
|
3393
|
+
var h;
|
|
3394
|
+
return Array.from(((h = c.current) == null ? void 0 : h.querySelectorAll("[data-tag]")) ?? []);
|
|
3395
3395
|
},
|
|
3396
3396
|
[]
|
|
3397
3397
|
), d = Q(
|
|
3398
|
-
(
|
|
3399
|
-
const
|
|
3400
|
-
for (const y of
|
|
3398
|
+
(h) => {
|
|
3399
|
+
const f = l(), m = h ?? f[0];
|
|
3400
|
+
for (const y of f)
|
|
3401
3401
|
y.tabIndex = y === m ? 0 : -1;
|
|
3402
3402
|
},
|
|
3403
3403
|
[l]
|
|
3404
3404
|
);
|
|
3405
3405
|
ne(() => {
|
|
3406
|
-
const
|
|
3407
|
-
d(
|
|
3406
|
+
const f = l().find((m) => m.tabIndex === 0);
|
|
3407
|
+
d(f);
|
|
3408
3408
|
});
|
|
3409
|
-
const u = (
|
|
3410
|
-
o == null || o(
|
|
3411
|
-
const
|
|
3412
|
-
|
|
3413
|
-
}, p = (
|
|
3414
|
-
if (r == null || r(
|
|
3415
|
-
const
|
|
3416
|
-
if (
|
|
3417
|
-
const m =
|
|
3409
|
+
const u = (h) => {
|
|
3410
|
+
o == null || o(h);
|
|
3411
|
+
const f = l().find((m) => m.contains(h.target));
|
|
3412
|
+
f && d(f);
|
|
3413
|
+
}, p = (h) => {
|
|
3414
|
+
if (r == null || r(h), h.defaultPrevented) return;
|
|
3415
|
+
const f = l();
|
|
3416
|
+
if (f.length === 0) return;
|
|
3417
|
+
const m = f.findIndex((b) => b.contains(document.activeElement));
|
|
3418
3418
|
if (m === -1) return;
|
|
3419
3419
|
const y = (b) => {
|
|
3420
|
-
b && (
|
|
3420
|
+
b && (h.preventDefault(), d(b), b.focus());
|
|
3421
3421
|
};
|
|
3422
|
-
|
|
3422
|
+
h.key === "ArrowRight" || h.key === "ArrowDown" ? y(f[(m + 1) % f.length]) : h.key === "ArrowLeft" || h.key === "ArrowUp" ? y(f[(m - 1 + f.length) % f.length]) : h.key === "Home" ? y(f[0]) : h.key === "End" && y(f[f.length - 1]);
|
|
3423
3423
|
};
|
|
3424
3424
|
return /* @__PURE__ */ s(
|
|
3425
3425
|
"div",
|
|
3426
3426
|
{
|
|
3427
|
-
ref: (
|
|
3428
|
-
c.current =
|
|
3427
|
+
ref: (h) => {
|
|
3428
|
+
c.current = h, typeof a == "function" ? a(h) : a && (a.current = h);
|
|
3429
3429
|
},
|
|
3430
3430
|
role: "list",
|
|
3431
3431
|
className: P(st.group, t),
|
|
3432
3432
|
onKeyDown: p,
|
|
3433
3433
|
onFocus: u,
|
|
3434
3434
|
...i,
|
|
3435
|
-
children: /* @__PURE__ */ s(
|
|
3435
|
+
children: /* @__PURE__ */ s(Qn.Provider, { value: !0, children: n })
|
|
3436
3436
|
}
|
|
3437
3437
|
);
|
|
3438
3438
|
}), Pu = ie(function({ tone: t = "neutral", children: n, onRemove: r, removeLabel: o, disabled: i = !1, className: a, onKeyDown: c, ...l }, d) {
|
|
3439
|
-
const u = He(
|
|
3439
|
+
const u = He(Qn), p = ce(), h = !!r && !i, f = o ?? (typeof n == "string" ? p.removeTag(n) : p.remove), m = (b) => {
|
|
3440
3440
|
if (!b) {
|
|
3441
3441
|
r == null || r();
|
|
3442
3442
|
return;
|
|
@@ -3444,20 +3444,20 @@ const Uc = "_group_13w8u_7", Yc = "_tag_13w8u_16 _text_1hv7a_23", Kc = "_removab
|
|
|
3444
3444
|
const v = b.closest('[role="list"]'), g = Array.from((v == null ? void 0 : v.querySelectorAll("[data-tag]")) ?? []), N = g.indexOf(b), L = g[N + 1] ?? g[N - 1];
|
|
3445
3445
|
r == null || r(), L && requestAnimationFrame(() => L.focus());
|
|
3446
3446
|
}, y = (b) => {
|
|
3447
|
-
c == null || c(b), !(b.defaultPrevented || !
|
|
3447
|
+
c == null || c(b), !(b.defaultPrevented || !h) && (b.key === "Backspace" || b.key === "Delete") && (b.preventDefault(), m(b.currentTarget));
|
|
3448
3448
|
};
|
|
3449
3449
|
return /* @__PURE__ */ k(
|
|
3450
3450
|
"span",
|
|
3451
3451
|
{
|
|
3452
3452
|
ref: d,
|
|
3453
|
-
"data-tag":
|
|
3453
|
+
"data-tag": h ? "" : void 0,
|
|
3454
3454
|
role: u ? "listitem" : void 0,
|
|
3455
3455
|
"aria-disabled": i || void 0,
|
|
3456
|
-
tabIndex:
|
|
3456
|
+
tabIndex: h ? u ? -1 : 0 : void 0,
|
|
3457
3457
|
className: P(
|
|
3458
3458
|
st.tag,
|
|
3459
3459
|
st[t],
|
|
3460
|
-
|
|
3460
|
+
h && st.removable,
|
|
3461
3461
|
i && st.disabled,
|
|
3462
3462
|
a
|
|
3463
3463
|
),
|
|
@@ -3465,12 +3465,12 @@ const Uc = "_group_13w8u_7", Yc = "_tag_13w8u_16 _text_1hv7a_23", Kc = "_removab
|
|
|
3465
3465
|
onKeyDown: y,
|
|
3466
3466
|
children: [
|
|
3467
3467
|
/* @__PURE__ */ s("span", { className: st.text, children: n }),
|
|
3468
|
-
|
|
3468
|
+
h && /* @__PURE__ */ s(
|
|
3469
3469
|
"button",
|
|
3470
3470
|
{
|
|
3471
3471
|
type: "button",
|
|
3472
3472
|
tabIndex: -1,
|
|
3473
|
-
"aria-label":
|
|
3473
|
+
"aria-label": f,
|
|
3474
3474
|
className: st.remove,
|
|
3475
3475
|
onClick: (b) => {
|
|
3476
3476
|
b.stopPropagation(), m(b.currentTarget.closest("[data-tag]"));
|
|
@@ -3486,19 +3486,19 @@ const Uc = "_group_13w8u_7", Yc = "_tag_13w8u_16 _text_1hv7a_23", Kc = "_removab
|
|
|
3486
3486
|
indicator: sl,
|
|
3487
3487
|
tab: il,
|
|
3488
3488
|
panel: al
|
|
3489
|
-
},
|
|
3490
|
-
function
|
|
3491
|
-
const t = He(
|
|
3489
|
+
}, Zn = je(null);
|
|
3490
|
+
function sn(e) {
|
|
3491
|
+
const t = He(Zn);
|
|
3492
3492
|
if (!t)
|
|
3493
3493
|
throw new Error(`${e} must be used inside <Tabs>.`);
|
|
3494
3494
|
return t;
|
|
3495
3495
|
}
|
|
3496
3496
|
function Eu({ value: e, onChange: t, className: n, children: r, ...o }) {
|
|
3497
3497
|
const i = De();
|
|
3498
|
-
return /* @__PURE__ */ s("div", { className: n, ...o, children: /* @__PURE__ */ s(
|
|
3498
|
+
return /* @__PURE__ */ s("div", { className: n, ...o, children: /* @__PURE__ */ s(Zn.Provider, { value: { value: e, onChange: t, idBase: i }, children: r }) });
|
|
3499
3499
|
}
|
|
3500
3500
|
function Fu({ className: e, children: t, onKeyDown: n, ...r }) {
|
|
3501
|
-
const o =
|
|
3501
|
+
const o = sn("TabList"), i = R(null), [a, c] = B(null), l = Q(() => {
|
|
3502
3502
|
const u = i.current;
|
|
3503
3503
|
if (!u) return;
|
|
3504
3504
|
const p = u.querySelector('[role="tab"][aria-selected="true"]');
|
|
@@ -3527,10 +3527,10 @@ function Fu({ className: e, children: t, onKeyDown: n, ...r }) {
|
|
|
3527
3527
|
u.currentTarget.querySelectorAll('[role="tab"]:not([disabled])')
|
|
3528
3528
|
);
|
|
3529
3529
|
if (p.length === 0) return;
|
|
3530
|
-
const
|
|
3530
|
+
const h = p.findIndex((b) => b === document.activeElement);
|
|
3531
3531
|
u.preventDefault();
|
|
3532
|
-
let
|
|
3533
|
-
u.key === "ArrowRight" && (
|
|
3532
|
+
let f = h;
|
|
3533
|
+
u.key === "ArrowRight" && (f = (h + 1) % p.length), u.key === "ArrowLeft" && (f = (h - 1 + p.length) % p.length), u.key === "Home" && (f = 0), u.key === "End" && (f = p.length - 1), (m = p[f]) == null || m.focus(), (y = p[f]) == null || y.click();
|
|
3534
3534
|
};
|
|
3535
3535
|
return /* @__PURE__ */ k("div", { ref: i, role: "tablist", className: P(Tt.list, e), ...r, onKeyDown: d, children: [
|
|
3536
3536
|
t,
|
|
@@ -3545,7 +3545,7 @@ function Fu({ className: e, children: t, onKeyDown: n, ...r }) {
|
|
|
3545
3545
|
] });
|
|
3546
3546
|
}
|
|
3547
3547
|
function Iu({ value: e, className: t, children: n, onClick: r, ...o }) {
|
|
3548
|
-
const i =
|
|
3548
|
+
const i = sn("Tab"), a = i.value === e;
|
|
3549
3549
|
return /* @__PURE__ */ s(
|
|
3550
3550
|
"button",
|
|
3551
3551
|
{
|
|
@@ -3565,7 +3565,7 @@ function Iu({ value: e, className: t, children: n, onClick: r, ...o }) {
|
|
|
3565
3565
|
);
|
|
3566
3566
|
}
|
|
3567
3567
|
function Bu({ value: e, className: t, children: n, ...r }) {
|
|
3568
|
-
const o =
|
|
3568
|
+
const o = sn("TabPanel");
|
|
3569
3569
|
return o.value !== e ? null : /* @__PURE__ */ s(
|
|
3570
3570
|
"div",
|
|
3571
3571
|
{
|
|
@@ -3579,14 +3579,14 @@ function Bu({ value: e, className: t, children: n, ...r }) {
|
|
|
3579
3579
|
}
|
|
3580
3580
|
);
|
|
3581
3581
|
}
|
|
3582
|
-
const cl = (e, t) => t === void 0 ? void 0 : t - e.length, ll = (e, t, n) => !n || !t ? e : Math.min(e, t * n), dl = "_textarea_mutkx_7 _field_1hv7a_34", ul = "_sm_mutkx_44",
|
|
3582
|
+
const cl = (e, t) => t === void 0 ? void 0 : t - e.length, ll = (e, t, n) => !n || !t ? e : Math.min(e, t * n), dl = "_textarea_mutkx_7 _field_1hv7a_34", ul = "_sm_mutkx_44", hl = "_invalid_mutkx_51", fl = "_wrapper_mutkx_63 _text_1hv7a_23", pl = "_count_mutkx_76", ml = "_countOver_mutkx_90", ht = {
|
|
3583
3583
|
textarea: dl,
|
|
3584
3584
|
sm: ul,
|
|
3585
|
-
invalid:
|
|
3586
|
-
wrapper:
|
|
3585
|
+
invalid: hl,
|
|
3586
|
+
wrapper: fl,
|
|
3587
3587
|
count: pl,
|
|
3588
3588
|
countOver: ml
|
|
3589
|
-
},
|
|
3589
|
+
}, zu = ie(function({
|
|
3590
3590
|
size: t = "md",
|
|
3591
3591
|
invalid: n,
|
|
3592
3592
|
autoGrow: r = !1,
|
|
@@ -3598,10 +3598,10 @@ const cl = (e, t) => t === void 0 ? void 0 : t - e.length, ll = (e, t, n) => !n
|
|
|
3598
3598
|
disabled: d,
|
|
3599
3599
|
rows: u = 3,
|
|
3600
3600
|
onInput: p,
|
|
3601
|
-
...
|
|
3602
|
-
},
|
|
3601
|
+
...h
|
|
3602
|
+
}, f) {
|
|
3603
3603
|
const m = Be(), y = n ?? (m == null ? void 0 : m.invalid) ?? !1, b = R(null);
|
|
3604
|
-
Vt(
|
|
3604
|
+
Vt(f, () => b.current);
|
|
3605
3605
|
const v = Q(() => {
|
|
3606
3606
|
const w = b.current;
|
|
3607
3607
|
if (!w || !r) return;
|
|
@@ -3609,7 +3609,7 @@ const cl = (e, t) => t === void 0 ? void 0 : t - e.length, ll = (e, t, n) => !n
|
|
|
3609
3609
|
const O = Number.parseFloat(getComputedStyle(w).lineHeight) || 0;
|
|
3610
3610
|
w.style.height = `${ll(w.scrollHeight, O, o)}px`, w.style.overflowY = o && w.scrollHeight > w.clientHeight ? "auto" : "hidden";
|
|
3611
3611
|
}, [r, o]);
|
|
3612
|
-
Oe(v, [v,
|
|
3612
|
+
Oe(v, [v, h.value, h.defaultValue]), ne(() => {
|
|
3613
3613
|
var O;
|
|
3614
3614
|
if (!r) return;
|
|
3615
3615
|
let w = !1;
|
|
@@ -3619,36 +3619,36 @@ const cl = (e, t) => t === void 0 ? void 0 : t - e.length, ll = (e, t, n) => !n
|
|
|
3619
3619
|
w = !0;
|
|
3620
3620
|
};
|
|
3621
3621
|
}, [r, v]);
|
|
3622
|
-
const [g, N] = B(() => String(
|
|
3622
|
+
const [g, N] = B(() => String(h.defaultValue ?? "")), L = h.value !== void 0, F = L ? String(h.value ?? "") : g, D = cl(F, h.maxLength), _ = i && D !== void 0, E = /* @__PURE__ */ s(
|
|
3623
3623
|
"textarea",
|
|
3624
3624
|
{
|
|
3625
3625
|
ref: b,
|
|
3626
3626
|
id: l ?? (m == null ? void 0 : m.id),
|
|
3627
3627
|
rows: u,
|
|
3628
3628
|
disabled: d,
|
|
3629
|
-
"aria-describedby":
|
|
3629
|
+
"aria-describedby": h["aria-describedby"] ?? (m == null ? void 0 : m.describedBy),
|
|
3630
3630
|
"aria-required": (m == null ? void 0 : m.required) || void 0,
|
|
3631
3631
|
"aria-invalid": y || void 0,
|
|
3632
3632
|
className: P(
|
|
3633
|
-
|
|
3634
|
-
t === "sm" &&
|
|
3635
|
-
y &&
|
|
3633
|
+
ht.textarea,
|
|
3634
|
+
t === "sm" && ht.sm,
|
|
3635
|
+
y && ht.invalid,
|
|
3636
3636
|
!_ && c
|
|
3637
3637
|
),
|
|
3638
3638
|
style: { resize: a ?? (r ? "none" : "vertical") },
|
|
3639
3639
|
onInput: (w) => {
|
|
3640
3640
|
p == null || p(w), L || N(w.currentTarget.value), v();
|
|
3641
3641
|
},
|
|
3642
|
-
...
|
|
3642
|
+
...h
|
|
3643
3643
|
}
|
|
3644
3644
|
);
|
|
3645
|
-
return _ ? /* @__PURE__ */ k("span", { className: P(
|
|
3645
|
+
return _ ? /* @__PURE__ */ k("span", { className: P(ht.wrapper, c), children: [
|
|
3646
3646
|
E,
|
|
3647
3647
|
/* @__PURE__ */ s(
|
|
3648
3648
|
"span",
|
|
3649
3649
|
{
|
|
3650
3650
|
"aria-live": "polite",
|
|
3651
|
-
className: P(
|
|
3651
|
+
className: P(ht.count, D < 0 && ht.countOver),
|
|
3652
3652
|
children: D
|
|
3653
3653
|
}
|
|
3654
3654
|
)
|
|
@@ -3670,9 +3670,9 @@ const cl = (e, t) => t === void 0 ? void 0 : t - e.length, ll = (e, t, n) => !n
|
|
|
3670
3670
|
descriptionText: Ml,
|
|
3671
3671
|
close: Cl,
|
|
3672
3672
|
toastIn: Al
|
|
3673
|
-
}, Ll = { "--_origin":
|
|
3673
|
+
}, Ll = { "--_origin": Kt("top", "end") }, Jn = je(null);
|
|
3674
3674
|
function Ou() {
|
|
3675
|
-
const e = He(
|
|
3675
|
+
const e = He(Jn);
|
|
3676
3676
|
if (!e)
|
|
3677
3677
|
throw new Error("useToast requires a <ToastProvider> around the application.");
|
|
3678
3678
|
return e;
|
|
@@ -3693,7 +3693,7 @@ function Hu({ children: e }) {
|
|
|
3693
3693
|
const g = i.current.get(v);
|
|
3694
3694
|
g != null && g.timeout && clearTimeout(g.timeout);
|
|
3695
3695
|
const N = a.current, L = N === null ? 0 : yt(getComputedStyle(N), "--u-duration-exit-collapse");
|
|
3696
|
-
if (
|
|
3696
|
+
if (Mt() || L <= 0) {
|
|
3697
3697
|
c(v);
|
|
3698
3698
|
return;
|
|
3699
3699
|
}
|
|
@@ -3722,7 +3722,7 @@ function Hu({ children: e }) {
|
|
|
3722
3722
|
), p = Q((v) => {
|
|
3723
3723
|
const g = i.current.get(v);
|
|
3724
3724
|
g != null && g.timeout && (clearTimeout(g.timeout), g.timeout = null, g.remaining = Math.max(0, g.remaining - (Date.now() - g.startedAt)));
|
|
3725
|
-
}, []),
|
|
3725
|
+
}, []), h = Q(
|
|
3726
3726
|
(v) => {
|
|
3727
3727
|
const g = i.current.get(v);
|
|
3728
3728
|
if (!(!g || g.timeout)) {
|
|
@@ -3743,7 +3743,7 @@ function Hu({ children: e }) {
|
|
|
3743
3743
|
}), v.clear();
|
|
3744
3744
|
};
|
|
3745
3745
|
}, []);
|
|
3746
|
-
const
|
|
3746
|
+
const f = se(() => ({ toast: u, dismiss: l }), [u, l]), m = ce(), y = Zt(), b = (v) => {
|
|
3747
3747
|
const g = v.tone ?? "neutral";
|
|
3748
3748
|
return /* @__PURE__ */ s(
|
|
3749
3749
|
"div",
|
|
@@ -3755,7 +3755,7 @@ function Hu({ children: e }) {
|
|
|
3755
3755
|
{
|
|
3756
3756
|
className: Le.toast,
|
|
3757
3757
|
onPointerEnter: () => p(v.id),
|
|
3758
|
-
onPointerLeave: () =>
|
|
3758
|
+
onPointerLeave: () => h(v.id),
|
|
3759
3759
|
children: [
|
|
3760
3760
|
/* @__PURE__ */ s(Rl, { tone: g }),
|
|
3761
3761
|
/* @__PURE__ */ k("div", { className: Le.text, children: [
|
|
@@ -3779,9 +3779,9 @@ function Hu({ children: e }) {
|
|
|
3779
3779
|
v.id
|
|
3780
3780
|
);
|
|
3781
3781
|
};
|
|
3782
|
-
return /* @__PURE__ */ k(
|
|
3782
|
+
return /* @__PURE__ */ k(Jn.Provider, { value: f, children: [
|
|
3783
3783
|
e,
|
|
3784
|
-
|
|
3784
|
+
Ut(
|
|
3785
3785
|
/* Two live regions that stand before the first message arrives: a
|
|
3786
3786
|
region that comes into the document with its text already in it is
|
|
3787
3787
|
often not read out at all by a screen reader. The message goes into
|
|
@@ -3790,30 +3790,30 @@ function Hu({ children: e }) {
|
|
|
3790
3790
|
`display: contents`, and `order` keeps on screen the order in which
|
|
3791
3791
|
the messages arrived - whatever their tone. */
|
|
3792
3792
|
/* @__PURE__ */ k("div", { ref: a, className: Le.region, style: Ll, children: [
|
|
3793
|
-
/* @__PURE__ */ s("div", { role: "status", "aria-live": "polite", className: Le.live, children: n.filter((v) =>
|
|
3794
|
-
/* @__PURE__ */ s("div", { role: "alert", className: Le.live, children: n.filter((v) =>
|
|
3793
|
+
/* @__PURE__ */ s("div", { role: "status", "aria-live": "polite", className: Le.live, children: n.filter((v) => Bt[v.tone ?? "neutral"].role === "status").map(b) }),
|
|
3794
|
+
/* @__PURE__ */ s("div", { role: "alert", className: Le.live, children: n.filter((v) => Bt[v.tone ?? "neutral"].role === "alert").map(b) })
|
|
3795
3795
|
] }),
|
|
3796
3796
|
y() ?? document.body
|
|
3797
3797
|
)
|
|
3798
3798
|
] });
|
|
3799
3799
|
}
|
|
3800
|
-
const Pl = "_tree_14dbz_10 _text_1hv7a_23", El = "_row_14dbz_23", Fl = "_active_14dbz_46", Il = "_pathOnly_14dbz_58", Bl = "_chevron_14dbz_62",
|
|
3800
|
+
const Pl = "_tree_14dbz_10 _text_1hv7a_23", El = "_row_14dbz_23", Fl = "_active_14dbz_46", Il = "_pathOnly_14dbz_58", Bl = "_chevron_14dbz_62", zl = "_chevronOpen_14dbz_74", Ol = "_placeholder_14dbz_80", Hl = "_emptyDot_14dbz_86", ql = "_check_14dbz_104", Wl = "_content_14dbz_110", Gl = "_noMatches_14dbz_124", jl = "_scrolls_14dbz_135 _scroll_1hv7a_40", Vl = "_disabled_14dbz_145", Ul = "_loading_14dbz_149", Ae = {
|
|
3801
3801
|
tree: Pl,
|
|
3802
3802
|
row: El,
|
|
3803
3803
|
active: Fl,
|
|
3804
3804
|
pathOnly: Il,
|
|
3805
3805
|
chevron: Bl,
|
|
3806
|
-
chevronOpen:
|
|
3806
|
+
chevronOpen: zl,
|
|
3807
3807
|
placeholder: Ol,
|
|
3808
3808
|
emptyDot: Hl,
|
|
3809
|
-
check:
|
|
3809
|
+
check: ql,
|
|
3810
3810
|
content: Wl,
|
|
3811
3811
|
noMatches: Gl,
|
|
3812
|
-
scrolls:
|
|
3813
|
-
disabled:
|
|
3812
|
+
scrolls: jl,
|
|
3813
|
+
disabled: Vl,
|
|
3814
3814
|
loading: Ul
|
|
3815
3815
|
}, Yl = 600;
|
|
3816
|
-
function
|
|
3816
|
+
function qu({
|
|
3817
3817
|
tree: e,
|
|
3818
3818
|
ariaLabel: t,
|
|
3819
3819
|
checkable: n = !1,
|
|
@@ -3826,14 +3826,14 @@ function zu({
|
|
|
3826
3826
|
...d
|
|
3827
3827
|
}) {
|
|
3828
3828
|
var D;
|
|
3829
|
-
const u = ce(), p = De(),
|
|
3829
|
+
const u = ce(), p = De(), h = e.virtual, f = R(null), m = (h == null ? void 0 : h.scrollRef) ?? f, y = R(!1), b = R(0), v = R(""), g = R(null);
|
|
3830
3830
|
ne(() => {
|
|
3831
3831
|
const _ = m.current;
|
|
3832
3832
|
if (_ === null || e.active === null) return;
|
|
3833
|
-
if (
|
|
3834
|
-
const O = e.flattening.findIndex((
|
|
3835
|
-
if (O >= 0 && (O <
|
|
3836
|
-
|
|
3833
|
+
if (h !== void 0) {
|
|
3834
|
+
const O = e.flattening.findIndex((V) => V.key === e.active);
|
|
3835
|
+
if (O >= 0 && (O < h.from || O >= h.to)) {
|
|
3836
|
+
h.showRow(O);
|
|
3837
3837
|
return;
|
|
3838
3838
|
}
|
|
3839
3839
|
}
|
|
@@ -3843,7 +3843,7 @@ function zu({
|
|
|
3843
3843
|
`[data-key="${CSS.escape(String(e.active))}"]`
|
|
3844
3844
|
);
|
|
3845
3845
|
w !== null && w !== document.activeElement && w.focus();
|
|
3846
|
-
}, [e.active, e.flattening, e.revealCount,
|
|
3846
|
+
}, [e.active, e.flattening, e.revealCount, h, m]), ne(
|
|
3847
3847
|
() => () => {
|
|
3848
3848
|
g.current !== null && window.clearTimeout(g.current);
|
|
3849
3849
|
},
|
|
@@ -3898,18 +3898,18 @@ function zu({
|
|
|
3898
3898
|
}
|
|
3899
3899
|
_.preventDefault();
|
|
3900
3900
|
}
|
|
3901
|
-
}, L =
|
|
3901
|
+
}, L = h === void 0 ? e.flattening : e.flattening.slice(h.from, h.to), F = e.active !== null && L.some((_) => _.key === e.active) ? e.active : (D = L[0]) == null ? void 0 : D.key;
|
|
3902
3902
|
return /* @__PURE__ */ k(
|
|
3903
3903
|
"div",
|
|
3904
3904
|
{
|
|
3905
3905
|
ref: m,
|
|
3906
3906
|
role: "tree",
|
|
3907
3907
|
"aria-label": t,
|
|
3908
|
-
className: P(Ae.tree,
|
|
3908
|
+
className: P(Ae.tree, h !== void 0 && Ae.scrolls, o),
|
|
3909
3909
|
...d,
|
|
3910
3910
|
onKeyDown: N,
|
|
3911
3911
|
onScroll: (_) => {
|
|
3912
|
-
l == null || l(_),
|
|
3912
|
+
l == null || l(_), h == null || h.onScroll();
|
|
3913
3913
|
},
|
|
3914
3914
|
onFocus: (_) => {
|
|
3915
3915
|
a == null || a(_), y.current = !0;
|
|
@@ -3918,7 +3918,7 @@ function zu({
|
|
|
3918
3918
|
c == null || c(_), _.currentTarget.contains(_.relatedTarget) || (y.current = !1);
|
|
3919
3919
|
},
|
|
3920
3920
|
children: [
|
|
3921
|
-
|
|
3921
|
+
h !== void 0 && h.fillerBefore > 0 ? /* @__PURE__ */ s("div", { "aria-hidden": "true", style: { height: h.fillerBefore } }) : null,
|
|
3922
3922
|
L.map((_) => {
|
|
3923
3923
|
const E = _.branch && !_.empty;
|
|
3924
3924
|
return /* @__PURE__ */ k(
|
|
@@ -3951,7 +3951,7 @@ function zu({
|
|
|
3951
3951
|
onClick: (w) => {
|
|
3952
3952
|
w.stopPropagation(), e.toggleExpanded(_.key);
|
|
3953
3953
|
},
|
|
3954
|
-
children: /* @__PURE__ */ s(
|
|
3954
|
+
children: /* @__PURE__ */ s(St, {})
|
|
3955
3955
|
}
|
|
3956
3956
|
) : _.empty ? /* @__PURE__ */ s("span", { "aria-hidden": "true", className: Ae.emptyDot }) : /* @__PURE__ */ s("span", { "aria-hidden": "true", className: Ae.placeholder }),
|
|
3957
3957
|
n ? (
|
|
@@ -3963,7 +3963,7 @@ function zu({
|
|
|
3963
3963
|
click ran through both paths and toggled twice - in the
|
|
3964
3964
|
browser nothing happened at all. */
|
|
3965
3965
|
/* @__PURE__ */ s("span", { className: Ae.check, onClick: (w) => w.stopPropagation(), children: /* @__PURE__ */ s(
|
|
3966
|
-
|
|
3966
|
+
tn,
|
|
3967
3967
|
{
|
|
3968
3968
|
id: `${p}-check-${Ze(String(_.key))}`,
|
|
3969
3969
|
checked: _.checked,
|
|
@@ -3976,13 +3976,13 @@ function zu({
|
|
|
3976
3976
|
) })
|
|
3977
3977
|
) : null,
|
|
3978
3978
|
/* @__PURE__ */ s("span", { className: Ae.content, children: r(_) }),
|
|
3979
|
-
_.unloaded && _.expanded ? /* @__PURE__ */ s(
|
|
3979
|
+
_.unloaded && _.expanded ? /* @__PURE__ */ s(Ln, { size: 12, className: Ae.loading }) : null
|
|
3980
3980
|
]
|
|
3981
3981
|
},
|
|
3982
3982
|
String(_.key)
|
|
3983
3983
|
);
|
|
3984
3984
|
}),
|
|
3985
|
-
|
|
3985
|
+
h !== void 0 && h.fillerAfter > 0 ? /* @__PURE__ */ s("div", { "aria-hidden": "true", style: { height: h.fillerAfter } }) : null,
|
|
3986
3986
|
e.flattening.length === 0 && e.search.trim() !== "" ? /* @__PURE__ */ s("p", { className: Ae.noMatches, children: u.treeNoMatches }) : null
|
|
3987
3987
|
]
|
|
3988
3988
|
}
|
|
@@ -4047,7 +4047,7 @@ function Zl(e, t) {
|
|
|
4047
4047
|
const b = y.getBoundingClientRect().height;
|
|
4048
4048
|
b > 0 && Math.abs(b - d) > 0.5 && u(b);
|
|
4049
4049
|
}, [e, c, d]);
|
|
4050
|
-
const
|
|
4050
|
+
const h = Xl({ count: e, rowHeight: d, scrollTop: i, viewportHeight: c, overscan: r }), f = Q(
|
|
4051
4051
|
(m) => {
|
|
4052
4052
|
const y = o.current;
|
|
4053
4053
|
if (!y) return;
|
|
@@ -4063,12 +4063,12 @@ function Zl(e, t) {
|
|
|
4063
4063
|
);
|
|
4064
4064
|
return {
|
|
4065
4065
|
scrollRef: o,
|
|
4066
|
-
from:
|
|
4067
|
-
to:
|
|
4068
|
-
fillerBefore:
|
|
4069
|
-
fillerAfter:
|
|
4066
|
+
from: h.from,
|
|
4067
|
+
to: h.to,
|
|
4068
|
+
fillerBefore: h.before,
|
|
4069
|
+
fillerAfter: h.after,
|
|
4070
4070
|
count: e,
|
|
4071
|
-
showRow:
|
|
4071
|
+
showRow: f,
|
|
4072
4072
|
onScroll: p
|
|
4073
4073
|
};
|
|
4074
4074
|
}
|
|
@@ -4087,13 +4087,13 @@ function Jl(e, t, n) {
|
|
|
4087
4087
|
var y;
|
|
4088
4088
|
const c = t.key(a), l = t.children(a), d = n.checked.has(c), u = r === "" || t.label(a).toLowerCase().includes(r);
|
|
4089
4089
|
u && o.matches.add(c);
|
|
4090
|
-
let p = d,
|
|
4090
|
+
let p = d, h = !1;
|
|
4091
4091
|
for (const b of l ?? []) {
|
|
4092
4092
|
const [v, g] = i(b);
|
|
4093
|
-
v && (p = !0), g && (
|
|
4093
|
+
v && (p = !0), g && (h = !0);
|
|
4094
4094
|
}
|
|
4095
|
-
l !== void 0 && !d && p && o.indeterminate.add(c),
|
|
4096
|
-
const m = u ||
|
|
4095
|
+
l !== void 0 && !d && p && o.indeterminate.add(c), h && o.descendantMatches.add(c);
|
|
4096
|
+
const m = u || h || ((y = t.unloaded) == null ? void 0 : y.call(t, a)) === !0;
|
|
4097
4097
|
return m && o.survives.add(c), [p, m];
|
|
4098
4098
|
}
|
|
4099
4099
|
for (const a of e) i(a);
|
|
@@ -4103,12 +4103,12 @@ function ed(e, t, n) {
|
|
|
4103
4103
|
const r = n.search.trim() !== "", o = Jl(e, t, n), i = [];
|
|
4104
4104
|
function a(c, l, d) {
|
|
4105
4105
|
const u = d ? c : c.filter((p) => !r || o.survives.has(t.key(p)));
|
|
4106
|
-
u.forEach((p,
|
|
4106
|
+
u.forEach((p, h) => {
|
|
4107
4107
|
var D, _;
|
|
4108
|
-
const
|
|
4108
|
+
const f = t.key(p), m = t.children(p), y = ((D = t.unloaded) == null ? void 0 : D.call(t, p)) === !0, b = m !== void 0 || y, v = b && !y && (m ?? []).length === 0, g = o.matches.has(f), N = r && !g && o.descendantMatches.has(f), L = r && o.descendantMatches.has(f), F = !v && b && (L || n.expanded.has(f));
|
|
4109
4109
|
i.push({
|
|
4110
4110
|
node: p,
|
|
4111
|
-
key:
|
|
4111
|
+
key: f,
|
|
4112
4112
|
level: l,
|
|
4113
4113
|
label: t.label(p),
|
|
4114
4114
|
branch: b,
|
|
@@ -4116,24 +4116,24 @@ function ed(e, t, n) {
|
|
|
4116
4116
|
disabled: ((_ = t.disabled) == null ? void 0 : _.call(t, p)) === !0,
|
|
4117
4117
|
unloaded: y,
|
|
4118
4118
|
expanded: F,
|
|
4119
|
-
checked: n.checked.has(
|
|
4120
|
-
indeterminate: o.indeterminate.has(
|
|
4121
|
-
active: n.active ===
|
|
4119
|
+
checked: n.checked.has(f),
|
|
4120
|
+
indeterminate: o.indeterminate.has(f),
|
|
4121
|
+
active: n.active === f,
|
|
4122
4122
|
matches: !r || g,
|
|
4123
4123
|
pathOnly: N,
|
|
4124
|
-
position:
|
|
4124
|
+
position: h + 1,
|
|
4125
4125
|
siblings: u.length
|
|
4126
4126
|
}), F && a(m ?? [], l + 1, d || g);
|
|
4127
4127
|
});
|
|
4128
4128
|
}
|
|
4129
4129
|
return a(e, 0, !1), i;
|
|
4130
4130
|
}
|
|
4131
|
-
function
|
|
4131
|
+
function er(e, t) {
|
|
4132
4132
|
if (e.expanded.has(t)) return e;
|
|
4133
4133
|
const n = new Set(e.expanded);
|
|
4134
4134
|
return n.add(t), { ...e, expanded: n };
|
|
4135
4135
|
}
|
|
4136
|
-
function
|
|
4136
|
+
function tr(e, t) {
|
|
4137
4137
|
if (!e.expanded.has(t)) return e;
|
|
4138
4138
|
const n = new Set(e.expanded);
|
|
4139
4139
|
return n.delete(t), { ...e, expanded: n };
|
|
@@ -4141,7 +4141,7 @@ function er(e, t) {
|
|
|
4141
4141
|
function Ge(e, t) {
|
|
4142
4142
|
return e.active === t ? e : { ...e, active: t };
|
|
4143
4143
|
}
|
|
4144
|
-
function
|
|
4144
|
+
function vn(e, t, n) {
|
|
4145
4145
|
if (e.length === 0) return t;
|
|
4146
4146
|
const r = e[0], o = e[e.length - 1];
|
|
4147
4147
|
if (n === "start") return Ge(t, r.key);
|
|
@@ -4160,12 +4160,12 @@ function gn(e, t, n) {
|
|
|
4160
4160
|
}
|
|
4161
4161
|
case "in": {
|
|
4162
4162
|
if (!a.branch || a.empty) return t;
|
|
4163
|
-
if (!a.expanded) return
|
|
4163
|
+
if (!a.expanded) return er(t, a.key);
|
|
4164
4164
|
const c = e[i + 1];
|
|
4165
4165
|
return c === void 0 ? t : Ge(t, c.key);
|
|
4166
4166
|
}
|
|
4167
4167
|
case "out": {
|
|
4168
|
-
if (a.branch && a.expanded) return
|
|
4168
|
+
if (a.branch && a.expanded) return tr(t, a.key);
|
|
4169
4169
|
for (let c = i - 1; c >= 0; c--) {
|
|
4170
4170
|
const l = e[c];
|
|
4171
4171
|
if (l.level < a.level) return Ge(t, l.key);
|
|
@@ -4174,7 +4174,7 @@ function gn(e, t, n) {
|
|
|
4174
4174
|
}
|
|
4175
4175
|
}
|
|
4176
4176
|
}
|
|
4177
|
-
function
|
|
4177
|
+
function yn(e, t) {
|
|
4178
4178
|
return e.anchor === t ? e : { ...e, anchor: t };
|
|
4179
4179
|
}
|
|
4180
4180
|
function td(e, t, n) {
|
|
@@ -4187,7 +4187,7 @@ function td(e, t, n) {
|
|
|
4187
4187
|
}
|
|
4188
4188
|
return c;
|
|
4189
4189
|
}
|
|
4190
|
-
function
|
|
4190
|
+
function nr(e, t) {
|
|
4191
4191
|
const n = { nodes: /* @__PURE__ */ new Map(), parents: /* @__PURE__ */ new Map(), depth: /* @__PURE__ */ new Map() };
|
|
4192
4192
|
function r(o, i, a) {
|
|
4193
4193
|
const c = t.key(o);
|
|
@@ -4197,58 +4197,58 @@ function tr(e, t) {
|
|
|
4197
4197
|
for (const o of e) r(o, null, 0);
|
|
4198
4198
|
return n;
|
|
4199
4199
|
}
|
|
4200
|
-
function
|
|
4200
|
+
function Wt(e, t, n, r, o) {
|
|
4201
4201
|
if (r.length === 0) return n;
|
|
4202
|
-
const i =
|
|
4203
|
-
function c(
|
|
4204
|
-
if (vt(t,
|
|
4205
|
-
const
|
|
4206
|
-
o ? a.add(
|
|
4202
|
+
const i = nr(e, t), a = new Set(n.checked);
|
|
4203
|
+
function c(h) {
|
|
4204
|
+
if (vt(t, h)) {
|
|
4205
|
+
const f = t.key(h);
|
|
4206
|
+
o ? a.add(f) : a.delete(f);
|
|
4207
4207
|
}
|
|
4208
|
-
for (const
|
|
4208
|
+
for (const f of t.children(h) ?? []) c(f);
|
|
4209
4209
|
}
|
|
4210
|
-
function l(
|
|
4211
|
-
const
|
|
4212
|
-
if (
|
|
4213
|
-
for (const b of
|
|
4214
|
-
if (!vt(t,
|
|
4215
|
-
const m = t.key(
|
|
4216
|
-
|
|
4210
|
+
function l(h) {
|
|
4211
|
+
const f = t.children(h) ?? [];
|
|
4212
|
+
if (f.length === 0) return;
|
|
4213
|
+
for (const b of f) l(b);
|
|
4214
|
+
if (!vt(t, h)) return;
|
|
4215
|
+
const m = t.key(h);
|
|
4216
|
+
f.every((b) => a.has(t.key(b))) ? a.add(m) : a.delete(m);
|
|
4217
4217
|
}
|
|
4218
4218
|
const d = /* @__PURE__ */ new Set();
|
|
4219
4219
|
let u = !1;
|
|
4220
|
-
for (const
|
|
4221
|
-
const
|
|
4222
|
-
if (
|
|
4223
|
-
u = !0, c(
|
|
4224
|
-
let m = i.parents.get(
|
|
4220
|
+
for (const h of r) {
|
|
4221
|
+
const f = i.nodes.get(h);
|
|
4222
|
+
if (f === void 0 || !vt(t, f)) continue;
|
|
4223
|
+
u = !0, c(f), l(f);
|
|
4224
|
+
let m = i.parents.get(h) ?? null;
|
|
4225
4225
|
for (; m !== null; )
|
|
4226
4226
|
d.add(m), m = i.parents.get(m) ?? null;
|
|
4227
4227
|
}
|
|
4228
4228
|
if (!u) return n;
|
|
4229
4229
|
const p = [...d].sort(
|
|
4230
|
-
(
|
|
4230
|
+
(h, f) => (i.depth.get(f) ?? 0) - (i.depth.get(h) ?? 0)
|
|
4231
4231
|
);
|
|
4232
|
-
for (const
|
|
4233
|
-
const
|
|
4234
|
-
if (
|
|
4235
|
-
const m = t.children(
|
|
4232
|
+
for (const h of p) {
|
|
4233
|
+
const f = i.nodes.get(h);
|
|
4234
|
+
if (f === void 0 || !vt(t, f)) continue;
|
|
4235
|
+
const m = t.children(f) ?? [];
|
|
4236
4236
|
if (m.length === 0) continue;
|
|
4237
|
-
m.every((b) => a.has(t.key(b))) ? a.add(
|
|
4237
|
+
m.every((b) => a.has(t.key(b))) ? a.add(h) : a.delete(h);
|
|
4238
4238
|
}
|
|
4239
4239
|
return { ...n, checked: a };
|
|
4240
4240
|
}
|
|
4241
|
-
function
|
|
4242
|
-
const o =
|
|
4243
|
-
return o.checked.size === n.checked.size && [...o.checked].every((a) => n.checked.has(a)) ?
|
|
4241
|
+
function rr(e, t, n, r) {
|
|
4242
|
+
const o = Wt(e, t, n, r, !0);
|
|
4243
|
+
return o.checked.size === n.checked.size && [...o.checked].every((a) => n.checked.has(a)) ? Wt(e, t, n, r, !1) : o;
|
|
4244
4244
|
}
|
|
4245
4245
|
function nd(e, t, n) {
|
|
4246
|
-
const r =
|
|
4246
|
+
const r = nr(e, t), o = [];
|
|
4247
4247
|
for (const [i, a] of r.nodes) vt(t, a) && o.push(i);
|
|
4248
|
-
return o.length === 0 ? n :
|
|
4248
|
+
return o.length === 0 ? n : rr(e, t, n, o);
|
|
4249
4249
|
}
|
|
4250
|
-
function
|
|
4251
|
-
return
|
|
4250
|
+
function bn(e, t, n, r) {
|
|
4251
|
+
return rr(e, t, n, [r]);
|
|
4252
4252
|
}
|
|
4253
4253
|
function rd(e, t, n) {
|
|
4254
4254
|
const r = t.toLowerCase();
|
|
@@ -4284,8 +4284,8 @@ function sd(e, t, n, r) {
|
|
|
4284
4284
|
const u = r[d], p = o.find((y) => t.key(y) === u);
|
|
4285
4285
|
if (p === void 0) break;
|
|
4286
4286
|
i = u;
|
|
4287
|
-
const
|
|
4288
|
-
d < r.length - 1 &&
|
|
4287
|
+
const h = t.children(p), f = h !== void 0 || ((c = t.unloaded) == null ? void 0 : c.call(t, p)) === !0, m = f && ((l = t.unloaded) == null ? void 0 : l.call(t, p)) !== !0 && (h ?? []).length === 0;
|
|
4288
|
+
d < r.length - 1 && f && !m && a.add(u), o = h ?? [];
|
|
4289
4289
|
}
|
|
4290
4290
|
return i === null ? { snapshot: n, reached: null } : { snapshot: { ...n, expanded: a }, reached: i };
|
|
4291
4291
|
}
|
|
@@ -4316,7 +4316,7 @@ function Gu(e, t) {
|
|
|
4316
4316
|
for (const i of e) o(i);
|
|
4317
4317
|
return r;
|
|
4318
4318
|
}
|
|
4319
|
-
function
|
|
4319
|
+
function ju(e, t) {
|
|
4320
4320
|
const {
|
|
4321
4321
|
reader: n,
|
|
4322
4322
|
defaultExpanded: r,
|
|
@@ -4328,8 +4328,8 @@ function Vu(e, t) {
|
|
|
4328
4328
|
anchor: d,
|
|
4329
4329
|
search: u,
|
|
4330
4330
|
onExpanded: p,
|
|
4331
|
-
onChecked:
|
|
4332
|
-
onActive:
|
|
4331
|
+
onChecked: h,
|
|
4332
|
+
onActive: f,
|
|
4333
4333
|
onAnchor: m,
|
|
4334
4334
|
onSearch: y,
|
|
4335
4335
|
onActivate: b,
|
|
@@ -4339,13 +4339,13 @@ function Vu(e, t) {
|
|
|
4339
4339
|
() => new Set(r ?? [])
|
|
4340
4340
|
), [F, D] = B(
|
|
4341
4341
|
() => new Set(o ?? [])
|
|
4342
|
-
), [_, E] = B(i), [w, O] = B(null), [
|
|
4342
|
+
), [_, E] = B(i), [w, O] = B(null), [V, U] = B(""), [C, G] = B(0), S = se(
|
|
4343
4343
|
() => ({
|
|
4344
4344
|
expanded: a ?? N,
|
|
4345
4345
|
checked: c ?? F,
|
|
4346
4346
|
active: l !== void 0 ? l : _,
|
|
4347
4347
|
anchor: d !== void 0 ? d : w,
|
|
4348
|
-
search: u ??
|
|
4348
|
+
search: u ?? V
|
|
4349
4349
|
}),
|
|
4350
4350
|
[
|
|
4351
4351
|
a,
|
|
@@ -4357,7 +4357,7 @@ function Vu(e, t) {
|
|
|
4357
4357
|
d,
|
|
4358
4358
|
w,
|
|
4359
4359
|
u,
|
|
4360
|
-
|
|
4360
|
+
V
|
|
4361
4361
|
]
|
|
4362
4362
|
), X = se(
|
|
4363
4363
|
() => ed(e, n, S),
|
|
@@ -4367,7 +4367,7 @@ function Vu(e, t) {
|
|
|
4367
4367
|
}, [e, n]);
|
|
4368
4368
|
const H = Q(
|
|
4369
4369
|
(M) => {
|
|
4370
|
-
M.expanded !== S.expanded && (a === void 0 && L(M.expanded), p == null || p(M.expanded)), M.checked !== S.checked && (c === void 0 && D(M.checked),
|
|
4370
|
+
M.expanded !== S.expanded && (a === void 0 && L(M.expanded), p == null || p(M.expanded)), M.checked !== S.checked && (c === void 0 && D(M.checked), h == null || h(M.checked)), M.anchor !== S.anchor && (d === void 0 && O(M.anchor), m == null || m(M.anchor)), M.active !== S.active && (l === void 0 && E(M.active), f == null || f(M.active));
|
|
4371
4371
|
},
|
|
4372
4372
|
[
|
|
4373
4373
|
S,
|
|
@@ -4376,39 +4376,39 @@ function Vu(e, t) {
|
|
|
4376
4376
|
l,
|
|
4377
4377
|
d,
|
|
4378
4378
|
p,
|
|
4379
|
-
f,
|
|
4380
4379
|
h,
|
|
4380
|
+
f,
|
|
4381
4381
|
m
|
|
4382
4382
|
]
|
|
4383
4383
|
), Y = Q(
|
|
4384
|
-
(M) => X.find((
|
|
4384
|
+
(M) => X.find((j) => j.key === M),
|
|
4385
4385
|
[X]
|
|
4386
4386
|
), pe = Q(
|
|
4387
4387
|
(M) => {
|
|
4388
|
-
const
|
|
4389
|
-
if (
|
|
4390
|
-
const x = !
|
|
4391
|
-
H(x ?
|
|
4388
|
+
const j = Y(M);
|
|
4389
|
+
if (j === void 0 || !j.branch || j.empty) return;
|
|
4390
|
+
const x = !j.expanded;
|
|
4391
|
+
H(x ? er(S, M) : tr(S, M)), x && j.unloaded && (v == null || v(j.node));
|
|
4392
4392
|
},
|
|
4393
4393
|
[Y, S, H, v]
|
|
4394
4394
|
), A = Q(
|
|
4395
4395
|
(M) => {
|
|
4396
|
-
H(
|
|
4396
|
+
H(yn(bn(e, n, S, M), M));
|
|
4397
4397
|
},
|
|
4398
4398
|
[e, n, S, H]
|
|
4399
4399
|
), I = Q(
|
|
4400
4400
|
(M) => {
|
|
4401
|
-
const
|
|
4402
|
-
|
|
4401
|
+
const j = S.anchor ?? S.active;
|
|
4402
|
+
j !== null && H(Wt(e, n, S, td(X, j, M), !0));
|
|
4403
4403
|
},
|
|
4404
4404
|
[e, n, S, X, H]
|
|
4405
|
-
),
|
|
4405
|
+
), q = Q(
|
|
4406
4406
|
(M) => {
|
|
4407
|
-
const
|
|
4408
|
-
|
|
4409
|
-
|
|
4410
|
-
|
|
4411
|
-
|
|
4407
|
+
const j = vn(X, S, M);
|
|
4408
|
+
j.active === null || j.active === S.active || H(
|
|
4409
|
+
yn(
|
|
4410
|
+
bn(e, n, j, j.active),
|
|
4411
|
+
j.active
|
|
4412
4412
|
)
|
|
4413
4413
|
);
|
|
4414
4414
|
},
|
|
@@ -4419,23 +4419,23 @@ function Vu(e, t) {
|
|
|
4419
4419
|
), ke = Q(
|
|
4420
4420
|
(M) => {
|
|
4421
4421
|
H(Ge(S, M));
|
|
4422
|
-
const
|
|
4423
|
-
|
|
4422
|
+
const j = Y(M);
|
|
4423
|
+
j !== void 0 && (b == null || b(j.node));
|
|
4424
4424
|
},
|
|
4425
4425
|
[S, H, Y, b]
|
|
4426
4426
|
), Ee = Q(
|
|
4427
|
-
(M) => H(
|
|
4427
|
+
(M) => H(vn(X, S, M)),
|
|
4428
4428
|
[X, S, H]
|
|
4429
4429
|
), oe = Q(
|
|
4430
4430
|
(M) => {
|
|
4431
|
-
const { snapshot:
|
|
4432
|
-
return x === null ? null : (H(Ge(
|
|
4431
|
+
const { snapshot: j, reached: x } = sd(e, n, S, M);
|
|
4432
|
+
return x === null ? null : (H(Ge(j, x)), G((W) => W + 1), x);
|
|
4433
4433
|
},
|
|
4434
4434
|
[e, n, S, H]
|
|
4435
4435
|
), K = Q(
|
|
4436
4436
|
(M) => {
|
|
4437
|
-
const
|
|
4438
|
-
return
|
|
4437
|
+
const j = od(e, n, M);
|
|
4438
|
+
return j === null ? null : oe(j);
|
|
4439
4439
|
},
|
|
4440
4440
|
[e, n, oe]
|
|
4441
4441
|
), _e = Q(() => {
|
|
@@ -4444,8 +4444,8 @@ function Vu(e, t) {
|
|
|
4444
4444
|
H({ ...S, expanded: /* @__PURE__ */ new Set() });
|
|
4445
4445
|
}, [S, H]), xe = Q(
|
|
4446
4446
|
(M) => {
|
|
4447
|
-
const
|
|
4448
|
-
|
|
4447
|
+
const j = rd(X, M, S.active);
|
|
4448
|
+
j !== null && H(Ge(S, j));
|
|
4449
4449
|
},
|
|
4450
4450
|
[X, S, H]
|
|
4451
4451
|
), $ = Q(
|
|
@@ -4453,13 +4453,13 @@ function Vu(e, t) {
|
|
|
4453
4453
|
u === void 0 && U(M), y == null || y(M);
|
|
4454
4454
|
},
|
|
4455
4455
|
[u, y]
|
|
4456
|
-
),
|
|
4456
|
+
), z = Zl(g ? X.length : 0, {
|
|
4457
4457
|
rowHeight: (g == null ? void 0 : g.rowHeight) ?? 0,
|
|
4458
4458
|
overscan: g == null ? void 0 : g.overscan
|
|
4459
4459
|
});
|
|
4460
4460
|
return {
|
|
4461
4461
|
flattening: X,
|
|
4462
|
-
virtual: g ?
|
|
4462
|
+
virtual: g ? z : void 0,
|
|
4463
4463
|
active: S.active,
|
|
4464
4464
|
search: S.search,
|
|
4465
4465
|
toggleExpanded: pe,
|
|
@@ -4474,11 +4474,11 @@ function Vu(e, t) {
|
|
|
4474
4474
|
collapseAll: ye,
|
|
4475
4475
|
typeahead: xe,
|
|
4476
4476
|
checkTo: I,
|
|
4477
|
-
moveAndCheck:
|
|
4477
|
+
moveAndCheck: q,
|
|
4478
4478
|
toggleAll: te
|
|
4479
4479
|
};
|
|
4480
4480
|
}
|
|
4481
|
-
const ad = "_text_yelu1_7 _text_1hv7a_23", cd = "_heading_yelu1_11 _text_1hv7a_23", ld = "_trackingDisplay_yelu1_100", dd = "_trackingTight_yelu1_104", ud = "_mono_yelu1_110",
|
|
4481
|
+
const ad = "_text_yelu1_7 _text_1hv7a_23", cd = "_heading_yelu1_11 _text_1hv7a_23", ld = "_trackingDisplay_yelu1_100", dd = "_trackingTight_yelu1_104", ud = "_mono_yelu1_110", hd = "_link_yelu1_119", Se = {
|
|
4482
4482
|
text: ad,
|
|
4483
4483
|
heading: cd,
|
|
4484
4484
|
"size-xs": "_size-xs_yelu1_30",
|
|
@@ -4502,8 +4502,8 @@ const ad = "_text_yelu1_7 _text_1hv7a_23", cd = "_heading_yelu1_11 _text_1hv7a_2
|
|
|
4502
4502
|
trackingDisplay: ld,
|
|
4503
4503
|
trackingTight: dd,
|
|
4504
4504
|
mono: ud,
|
|
4505
|
-
link:
|
|
4506
|
-
},
|
|
4505
|
+
link: hd
|
|
4506
|
+
}, Vu = ie(function({
|
|
4507
4507
|
as: t = "p",
|
|
4508
4508
|
size: n = "md",
|
|
4509
4509
|
weight: r = "regular",
|
|
@@ -4533,7 +4533,7 @@ const ad = "_text_yelu1_7 _text_1hv7a_23", cd = "_heading_yelu1_11 _text_1hv7a_2
|
|
|
4533
4533
|
children: d
|
|
4534
4534
|
}
|
|
4535
4535
|
);
|
|
4536
|
-
}),
|
|
4536
|
+
}), fd = {
|
|
4537
4537
|
1: "2xl",
|
|
4538
4538
|
2: "xl",
|
|
4539
4539
|
3: "lg",
|
|
@@ -4541,7 +4541,7 @@ const ad = "_text_yelu1_7 _text_1hv7a_23", cd = "_heading_yelu1_11 _text_1hv7a_2
|
|
|
4541
4541
|
5: "sm",
|
|
4542
4542
|
6: "xs"
|
|
4543
4543
|
}, Uu = ie(function({ level: t = 2, size: n, weight: r = "semibold", tone: o = "default", className: i, children: a, ...c }, l) {
|
|
4544
|
-
const d = `h${t}`, u = n ??
|
|
4544
|
+
const d = `h${t}`, u = n ?? fd[t];
|
|
4545
4545
|
return /* @__PURE__ */ s(
|
|
4546
4546
|
d,
|
|
4547
4547
|
{
|
|
@@ -4575,25 +4575,25 @@ const ad = "_text_yelu1_7 _text_1hv7a_23", cd = "_heading_yelu1_11 _text_1hv7a_2
|
|
|
4575
4575
|
tooltip: pd
|
|
4576
4576
|
};
|
|
4577
4577
|
function _d({ content: e, children: t, delay: n = 300 }) {
|
|
4578
|
-
const [r, o] = B(!1), [i, a] = B(null), [c, l] = B(null), d =
|
|
4579
|
-
|
|
4578
|
+
const [r, o] = B(!1), [i, a] = B(null), [c, l] = B(null), d = Zt(), u = R(null), p = R(null), h = R(null), f = De(), m = Fn(r, p, "--u-duration-exit-fast"), y = () => {
|
|
4579
|
+
h.current && clearTimeout(h.current), h.current = setTimeout(() => o(!0), n);
|
|
4580
4580
|
}, b = () => {
|
|
4581
|
-
|
|
4581
|
+
h.current && clearTimeout(h.current), o(!1);
|
|
4582
4582
|
};
|
|
4583
4583
|
Oe(() => {
|
|
4584
|
-
r && l(
|
|
4584
|
+
r && l(En(u.current, d));
|
|
4585
4585
|
}, [r, d]), Oe(() => {
|
|
4586
4586
|
var F;
|
|
4587
4587
|
if (!r || !c) return;
|
|
4588
4588
|
const g = (F = u.current) == null ? void 0 : F.getBoundingClientRect(), N = p.current;
|
|
4589
4589
|
if (!g || !N) return;
|
|
4590
|
-
const L =
|
|
4590
|
+
const L = Rn(
|
|
4591
4591
|
g,
|
|
4592
4592
|
{ width: N.offsetWidth, height: N.offsetHeight },
|
|
4593
|
-
|
|
4593
|
+
Pn(),
|
|
4594
4594
|
{ align: "center", side: "top", offset: 8 }
|
|
4595
4595
|
);
|
|
4596
|
-
a({ top: L.top, left: L.left, "--_origin":
|
|
4596
|
+
a({ top: L.top, left: L.left, "--_origin": Kt(L.side, "center") });
|
|
4597
4597
|
}, [r, c, e]), ne(() => {
|
|
4598
4598
|
if (!r) return;
|
|
4599
4599
|
const g = (N) => {
|
|
@@ -4603,15 +4603,15 @@ function _d({ content: e, children: t, delay: n = 300 }) {
|
|
|
4603
4603
|
window.removeEventListener("keydown", g), window.removeEventListener("scroll", b, !0);
|
|
4604
4604
|
};
|
|
4605
4605
|
}, [r]), ne(() => () => {
|
|
4606
|
-
|
|
4606
|
+
h.current && clearTimeout(h.current);
|
|
4607
4607
|
}, []);
|
|
4608
4608
|
const v = t.props;
|
|
4609
4609
|
return /* @__PURE__ */ k($e, { children: [
|
|
4610
|
-
|
|
4610
|
+
$n(t, {
|
|
4611
4611
|
ref: u,
|
|
4612
4612
|
/* Added to the child's own description, not put in its place: a field's
|
|
4613
4613
|
hint went silent for as long as the tooltip stood. */
|
|
4614
|
-
"aria-describedby": [v["aria-describedby"], r ?
|
|
4614
|
+
"aria-describedby": [v["aria-describedby"], r ? f : void 0].filter(Boolean).join(" ") || void 0,
|
|
4615
4615
|
onPointerEnter: (g) => {
|
|
4616
4616
|
var N;
|
|
4617
4617
|
(N = v.onPointerEnter) == null || N.call(v, g), y();
|
|
@@ -4629,12 +4629,12 @@ function _d({ content: e, children: t, delay: n = 300 }) {
|
|
|
4629
4629
|
(N = v.onBlur) == null || N.call(v, g), b();
|
|
4630
4630
|
}
|
|
4631
4631
|
}),
|
|
4632
|
-
m && c &&
|
|
4632
|
+
m && c && Ut(
|
|
4633
4633
|
/* @__PURE__ */ s(
|
|
4634
4634
|
"div",
|
|
4635
4635
|
{
|
|
4636
4636
|
ref: p,
|
|
4637
|
-
id:
|
|
4637
|
+
id: f,
|
|
4638
4638
|
role: "tooltip",
|
|
4639
4639
|
className: md.tooltip,
|
|
4640
4640
|
"data-closing": !r || void 0,
|
|
@@ -4647,14 +4647,14 @@ function _d({ content: e, children: t, delay: n = 300 }) {
|
|
|
4647
4647
|
)
|
|
4648
4648
|
] });
|
|
4649
4649
|
}
|
|
4650
|
-
const
|
|
4650
|
+
const Gt = {
|
|
4651
4651
|
ok: 0,
|
|
4652
4652
|
unknown: 1,
|
|
4653
4653
|
warning: 2,
|
|
4654
4654
|
alarm: 3
|
|
4655
4655
|
};
|
|
4656
4656
|
function Ku(e) {
|
|
4657
|
-
return
|
|
4657
|
+
return Gt[e];
|
|
4658
4658
|
}
|
|
4659
4659
|
function gd(e) {
|
|
4660
4660
|
return typeof e == "number" && Number.isFinite(e);
|
|
@@ -4665,7 +4665,7 @@ function vd(e, t) {
|
|
|
4665
4665
|
return n > 0 ? { limit: t, excess: n } : null;
|
|
4666
4666
|
}
|
|
4667
4667
|
function yd(e, t) {
|
|
4668
|
-
const n =
|
|
4668
|
+
const n = Gt[e.limit.severity], r = Gt[t.limit.severity];
|
|
4669
4669
|
return n !== r ? n > r : e.excess > t.excess;
|
|
4670
4670
|
}
|
|
4671
4671
|
function bd(e, t = {}) {
|
|
@@ -4680,27 +4680,27 @@ function bd(e, t = {}) {
|
|
|
4680
4680
|
}, i = t.target;
|
|
4681
4681
|
return i !== void 0 && Number.isFinite(i) && (o.deviation = e - i), o;
|
|
4682
4682
|
}
|
|
4683
|
-
function
|
|
4683
|
+
function wn(e) {
|
|
4684
4684
|
if (e == null) return null;
|
|
4685
4685
|
const t = e instanceof Date ? e.getTime() : e;
|
|
4686
4686
|
return Number.isFinite(t) ? t : null;
|
|
4687
4687
|
}
|
|
4688
|
-
const
|
|
4689
|
-
function
|
|
4690
|
-
const n =
|
|
4688
|
+
const kn = 6e4, wd = 1e3, kd = 10;
|
|
4689
|
+
function or(e, t) {
|
|
4690
|
+
const n = wn(e), r = wn(t);
|
|
4691
4691
|
return n === null || r === null ? null : Math.max(0, r - n);
|
|
4692
4692
|
}
|
|
4693
4693
|
function xd(e, t, n) {
|
|
4694
|
-
const r =
|
|
4694
|
+
const r = or(e, t);
|
|
4695
4695
|
return r === null || r >= n.lost ? "lost" : r >= n.stale ? "stale" : "fresh";
|
|
4696
4696
|
}
|
|
4697
4697
|
function Nd(e) {
|
|
4698
4698
|
const t = [e.stale, e.lost].filter(
|
|
4699
4699
|
(o) => Number.isFinite(o) && o > 0
|
|
4700
4700
|
);
|
|
4701
|
-
if (t.length === 0) return
|
|
4701
|
+
if (t.length === 0) return kn;
|
|
4702
4702
|
const n = Math.min(...t), r = Math.round(n / kd);
|
|
4703
|
-
return Math.min(
|
|
4703
|
+
return Math.min(kn, Math.max(wd, r));
|
|
4704
4704
|
}
|
|
4705
4705
|
function $d(e, t) {
|
|
4706
4706
|
const n = e instanceof Date ? e.getTime() : e, r = typeof n == "number" && Number.isFinite(n) ? n : null, { stale: o, lost: i } = t, a = Nd({ stale: o, lost: i }), [c, l] = B(() => Date.now());
|
|
@@ -4713,7 +4713,7 @@ function $d(e, t) {
|
|
|
4713
4713
|
stale: o,
|
|
4714
4714
|
lost: i
|
|
4715
4715
|
}),
|
|
4716
|
-
age:
|
|
4716
|
+
age: or(r, c),
|
|
4717
4717
|
now: c
|
|
4718
4718
|
}),
|
|
4719
4719
|
[r, c, o, i]
|
|
@@ -4752,7 +4752,7 @@ function Bd({
|
|
|
4752
4752
|
asOf: e,
|
|
4753
4753
|
ages: t
|
|
4754
4754
|
}) {
|
|
4755
|
-
const n =
|
|
4755
|
+
const n = Ve(), r = ce(), o = $d(e, t), i = o.freshness === "lost" ? r.freshnessDisconnected : o.freshness === "stale" ? r.freshnessStale : r.freshnessFresh, a = o.age;
|
|
4756
4756
|
return /* @__PURE__ */ k("span", { className: We.asOf, "data-freshness": o.freshness, children: [
|
|
4757
4757
|
i,
|
|
4758
4758
|
a !== null && /* @__PURE__ */ s("span", { className: We.age, children: n.relative(a) })
|
|
@@ -4771,13 +4771,13 @@ function Xu({
|
|
|
4771
4771
|
...d
|
|
4772
4772
|
}) {
|
|
4773
4773
|
var F;
|
|
4774
|
-
const u =
|
|
4774
|
+
const u = Ve(), p = ce(), h = bd(t, o), f = h.verdict, m = Fd(f, p), y = f !== "unknown", v = (((F = o == null ? void 0 : o.limits) == null ? void 0 : F.length) ?? 0) > 0 || !y, g = Id(h.deviation, r, u, p), N = y ? u.number(t, r) : p.statAbsentValue, L = `${e}: ${y ? `${N}${n ? ` ${n}` : ""}` : m}${y && v && f !== "ok" ? `, ${m}` : ""}`;
|
|
4775
4775
|
return /* @__PURE__ */ k(
|
|
4776
4776
|
"div",
|
|
4777
4777
|
{
|
|
4778
4778
|
role: "group",
|
|
4779
4779
|
"aria-label": L,
|
|
4780
|
-
"data-verdict": v ?
|
|
4780
|
+
"data-verdict": v ? f : void 0,
|
|
4781
4781
|
className: P(We.stat, l),
|
|
4782
4782
|
...d,
|
|
4783
4783
|
children: [
|
|
@@ -4786,28 +4786,28 @@ function Xu({
|
|
|
4786
4786
|
/* @__PURE__ */ s("span", { className: We.value, children: N }),
|
|
4787
4787
|
y && n !== void 0 && /* @__PURE__ */ s("span", { className: We.unit, children: n })
|
|
4788
4788
|
] }),
|
|
4789
|
-
v && /* @__PURE__ */ s("span", { className: We.verdict, "data-verdict":
|
|
4789
|
+
v && /* @__PURE__ */ s("span", { className: We.verdict, "data-verdict": f, children: m }),
|
|
4790
4790
|
g !== null && y && /* @__PURE__ */ s("span", { className: We.deviation, children: g }),
|
|
4791
|
-
i !== void 0 && i.length >= 2 && /* @__PURE__ */ s(
|
|
4791
|
+
i !== void 0 && i.length >= 2 && /* @__PURE__ */ s(zs, { data: i, className: We.history, "aria-hidden": "true" }),
|
|
4792
4792
|
a !== void 0 && c !== void 0 && /* @__PURE__ */ s(Bd, { asOf: a ?? null, ages: c })
|
|
4793
4793
|
]
|
|
4794
4794
|
}
|
|
4795
4795
|
);
|
|
4796
4796
|
}
|
|
4797
|
-
const
|
|
4797
|
+
const sr = "bottom", kt = ["top", "right", "bottom", "left"], xn = ["bottom", "top", "right", "left"];
|
|
4798
4798
|
function xt(e) {
|
|
4799
4799
|
return e === "left" || e === "right";
|
|
4800
4800
|
}
|
|
4801
|
-
function
|
|
4802
|
-
if (t.width <= 0 || t.height <= 0) return
|
|
4801
|
+
function zd(e, t) {
|
|
4802
|
+
if (t.width <= 0 || t.height <= 0) return sr;
|
|
4803
4803
|
const n = (e.x - (t.left + t.width / 2)) / (t.width / 2), r = (e.y - (t.top + t.height / 2)) / (t.height / 2);
|
|
4804
4804
|
return Math.abs(n) > Math.abs(r) ? n > 0 ? "right" : "left" : r < 0 ? "top" : "bottom";
|
|
4805
4805
|
}
|
|
4806
|
-
function
|
|
4806
|
+
function ir(e, t) {
|
|
4807
4807
|
return 2 * t.padding + t.grip + e * (t.gap + t.tool);
|
|
4808
4808
|
}
|
|
4809
|
-
function
|
|
4810
|
-
const o =
|
|
4809
|
+
function jt(e, t, n, r) {
|
|
4810
|
+
const o = ir(t, r), i = xt(e), a = (i ? n.height : n.width) - 2 * r.margin, c = (i ? n.width : n.height) - 2 * r.margin;
|
|
4811
4811
|
return o <= a && r.thickness <= c;
|
|
4812
4812
|
}
|
|
4813
4813
|
function Od(e) {
|
|
@@ -4824,25 +4824,25 @@ function Od(e) {
|
|
|
4824
4824
|
return;
|
|
4825
4825
|
}
|
|
4826
4826
|
}
|
|
4827
|
-
function
|
|
4827
|
+
function Nn(e, t) {
|
|
4828
4828
|
const n = Math.abs(kt.indexOf(e) - kt.indexOf(t));
|
|
4829
4829
|
return Math.min(n, kt.length - n);
|
|
4830
4830
|
}
|
|
4831
4831
|
function Hd(e, t, n, r) {
|
|
4832
4832
|
return [...kt].sort(
|
|
4833
|
-
(o, i) =>
|
|
4834
|
-
).find((o) =>
|
|
4833
|
+
(o, i) => Nn(e, o) - Nn(e, i) || xn.indexOf(o) - xn.indexOf(i)
|
|
4834
|
+
).find((o) => jt(o, t, n, r));
|
|
4835
4835
|
}
|
|
4836
|
-
const
|
|
4837
|
-
root:
|
|
4836
|
+
const qd = "_root_1oavz_22 _text_1hv7a_23", Wd = "_strip_1oavz_31", Gd = "_gripSlot_1oavz_111", jd = "_grip_1oavz_111 _ring_1hv7a_65", Vd = "_tool_1oavz_161 _ring_1hv7a_65", Ud = "_inMode_1oavz_195", Yd = "_refusal_1oavz_211", ot = {
|
|
4837
|
+
root: qd,
|
|
4838
4838
|
strip: Wd,
|
|
4839
4839
|
gripSlot: Gd,
|
|
4840
|
-
grip:
|
|
4841
|
-
tool:
|
|
4840
|
+
grip: jd,
|
|
4841
|
+
tool: Vd,
|
|
4842
4842
|
inMode: Ud,
|
|
4843
4843
|
refusal: Yd
|
|
4844
4844
|
};
|
|
4845
|
-
function
|
|
4845
|
+
function Ft(e) {
|
|
4846
4846
|
return Array.from(e.children);
|
|
4847
4847
|
}
|
|
4848
4848
|
function gt(e, t) {
|
|
@@ -4852,7 +4852,7 @@ function gt(e, t) {
|
|
|
4852
4852
|
const Qu = ie(function({
|
|
4853
4853
|
tools: t,
|
|
4854
4854
|
place: n,
|
|
4855
|
-
defaultPlace: r =
|
|
4855
|
+
defaultPlace: r = sr,
|
|
4856
4856
|
onPlaceChange: o,
|
|
4857
4857
|
mode: i,
|
|
4858
4858
|
onModeChange: a,
|
|
@@ -4862,8 +4862,8 @@ const Qu = ie(function({
|
|
|
4862
4862
|
...u
|
|
4863
4863
|
}, p) {
|
|
4864
4864
|
var xe;
|
|
4865
|
-
const
|
|
4866
|
-
Vt(p, () =>
|
|
4865
|
+
const h = ce(), f = R(null), m = R(null);
|
|
4866
|
+
Vt(p, () => f.current, []);
|
|
4867
4867
|
const [y, b] = B(r), v = n !== void 0, g = n ?? y, N = R(g);
|
|
4868
4868
|
N.current = g;
|
|
4869
4869
|
const [L, F] = B(null), [D, _] = B(""), E = R(null);
|
|
@@ -4877,11 +4877,11 @@ const Qu = ie(function({
|
|
|
4877
4877
|
var de;
|
|
4878
4878
|
const $ = m.current;
|
|
4879
4879
|
if ($ === null) return null;
|
|
4880
|
-
const
|
|
4880
|
+
const z = Ft($), M = z[0];
|
|
4881
4881
|
if (M === void 0) return null;
|
|
4882
|
-
const
|
|
4883
|
-
if (
|
|
4884
|
-
const x = getComputedStyle($), W = xt(N.current), ee = (
|
|
4882
|
+
const j = $.getBoundingClientRect();
|
|
4883
|
+
if (j.width === 0 && j.height === 0) return null;
|
|
4884
|
+
const x = getComputedStyle($), W = xt(N.current), ee = (fe) => W ? fe.height : fe.width, ae = (fe) => W ? fe.width : fe.height, le = M.getBoundingClientRect(), ue = (de = z[1]) == null ? void 0 : de.getBoundingClientRect();
|
|
4885
4885
|
return {
|
|
4886
4886
|
tool: ue === void 0 ? 0 : ee(ue),
|
|
4887
4887
|
grip: ee(le),
|
|
@@ -4898,44 +4898,44 @@ const Qu = ie(function({
|
|
|
4898
4898
|
margin: gt(x, "--u-dock-margin")
|
|
4899
4899
|
};
|
|
4900
4900
|
}, []), O = Q(() => {
|
|
4901
|
-
const $ =
|
|
4901
|
+
const $ = f.current;
|
|
4902
4902
|
if ($ === null) return null;
|
|
4903
|
-
const
|
|
4904
|
-
return { left:
|
|
4905
|
-
}, []),
|
|
4906
|
-
const
|
|
4907
|
-
return
|
|
4903
|
+
const z = $.getBoundingClientRect();
|
|
4904
|
+
return { left: z.left, top: z.top, width: z.width, height: z.height };
|
|
4905
|
+
}, []), V = R(null), U = R([]), C = Q(($) => {
|
|
4906
|
+
const z = m.current, M = f.current;
|
|
4907
|
+
return z === null || M === null ? null : {
|
|
4908
4908
|
place: $,
|
|
4909
4909
|
root: M.getBoundingClientRect(),
|
|
4910
|
-
strip:
|
|
4911
|
-
children:
|
|
4910
|
+
strip: z.getBoundingClientRect(),
|
|
4911
|
+
children: Ft(z).map((j) => j.getBoundingClientRect())
|
|
4912
4912
|
};
|
|
4913
4913
|
}, []), G = Q(() => {
|
|
4914
4914
|
E.current !== null && (clearTimeout(E.current), E.current = null), F(null);
|
|
4915
4915
|
}, []), S = Q(
|
|
4916
4916
|
($) => {
|
|
4917
|
-
$ !== N.current && (
|
|
4917
|
+
$ !== N.current && (V.current = C(N.current), G(), v || b($), N.current = $, o == null || o($), _(h.dockPlaced(h.dockPlace($))));
|
|
4918
4918
|
},
|
|
4919
|
-
[v, G, C, o,
|
|
4919
|
+
[v, G, C, o, h]
|
|
4920
4920
|
), X = Q(
|
|
4921
|
-
($,
|
|
4922
|
-
const x =
|
|
4921
|
+
($, z, M, j) => {
|
|
4922
|
+
const x = ir(M, z);
|
|
4923
4923
|
F({
|
|
4924
4924
|
place: $,
|
|
4925
|
-
width: `${xt($) ?
|
|
4926
|
-
height: `${xt($) ? x :
|
|
4927
|
-
}), _(
|
|
4925
|
+
width: `${xt($) ? z.thickness : x}px`,
|
|
4926
|
+
height: `${xt($) ? x : z.thickness}px`
|
|
4927
|
+
}), _(h.dockNoPlace(h.dockPlace($))), E.current !== null && clearTimeout(E.current);
|
|
4928
4928
|
const W = m.current === null ? null : getComputedStyle(m.current), ee = W === null ? 0 : yt(W, "--u-dock-refusal-duration");
|
|
4929
|
-
E.current =
|
|
4929
|
+
E.current = j && ee > 0 ? setTimeout(() => {
|
|
4930
4930
|
E.current = null, F(null);
|
|
4931
4931
|
}, ee) : null;
|
|
4932
4932
|
},
|
|
4933
|
-
[
|
|
4933
|
+
[h]
|
|
4934
4934
|
), H = Q(
|
|
4935
|
-
($,
|
|
4935
|
+
($, z, M, j) => {
|
|
4936
4936
|
if ($ !== N.current) {
|
|
4937
|
-
if (
|
|
4938
|
-
X($, M, t.length,
|
|
4937
|
+
if (z !== null && M !== null && !jt($, t.length, z, M)) {
|
|
4938
|
+
X($, M, t.length, j);
|
|
4939
4939
|
return;
|
|
4940
4940
|
}
|
|
4941
4941
|
S($);
|
|
@@ -4948,69 +4948,69 @@ const Qu = ie(function({
|
|
|
4948
4948
|
return ($ = Y.current) == null ? void 0 : $.call(Y);
|
|
4949
4949
|
}, []);
|
|
4950
4950
|
const pe = ($) => {
|
|
4951
|
-
const
|
|
4951
|
+
const z = $.currentTarget;
|
|
4952
4952
|
if ($.button !== 0) return;
|
|
4953
4953
|
$.preventDefault();
|
|
4954
4954
|
const M = $.pointerId;
|
|
4955
|
-
|
|
4956
|
-
const
|
|
4955
|
+
z.setPointerCapture(M), z.dataset.dragging = "";
|
|
4956
|
+
const j = O(), x = w(), W = gt(getComputedStyle(z), "--u-dock-grip-travel"), ee = N.current;
|
|
4957
4957
|
let ae = $.clientX, le = $.clientY;
|
|
4958
|
-
const ue = (
|
|
4958
|
+
const ue = (he, Fe) => {
|
|
4959
4959
|
const et = (bt) => Math.max(-W, Math.min(W, bt));
|
|
4960
|
-
|
|
4961
|
-
}, de = (
|
|
4962
|
-
if (
|
|
4960
|
+
z.style.transform = `translate(${et(he - ae)}px, ${et(Fe - le)}px)`;
|
|
4961
|
+
}, de = (he) => {
|
|
4962
|
+
if (he.pointerId !== M) return;
|
|
4963
4963
|
const Fe = N.current;
|
|
4964
|
-
if (
|
|
4965
|
-
const et =
|
|
4966
|
-
et === N.current ? G() : H(et,
|
|
4964
|
+
if (j !== null) {
|
|
4965
|
+
const et = zd({ x: he.clientX, y: he.clientY }, j);
|
|
4966
|
+
et === N.current ? G() : H(et, j, x, !1);
|
|
4967
4967
|
}
|
|
4968
|
-
N.current !== Fe && (ae =
|
|
4969
|
-
},
|
|
4970
|
-
Y.current = null,
|
|
4971
|
-
}, be = (
|
|
4972
|
-
|
|
4973
|
-
}, we = (
|
|
4974
|
-
|
|
4968
|
+
N.current !== Fe && (ae = he.clientX, le = he.clientY), ue(he.clientX, he.clientY);
|
|
4969
|
+
}, fe = () => {
|
|
4970
|
+
Y.current = null, z.removeEventListener("pointermove", de), z.removeEventListener("pointerup", be), z.removeEventListener("pointercancel", be), window.removeEventListener("keydown", we, !0), z.hasPointerCapture(M) && z.releasePointerCapture(M), delete z.dataset.dragging, z.style.transform = "", G();
|
|
4971
|
+
}, be = (he) => {
|
|
4972
|
+
he.pointerId === M && fe();
|
|
4973
|
+
}, we = (he) => {
|
|
4974
|
+
he.key === "Escape" && (he.preventDefault(), he.stopPropagation(), S(ee), fe());
|
|
4975
4975
|
};
|
|
4976
|
-
|
|
4976
|
+
z.addEventListener("pointermove", de), z.addEventListener("pointerup", be), z.addEventListener("pointercancel", be), window.addEventListener("keydown", we, !0), Y.current = fe;
|
|
4977
4977
|
}, A = ($) => {
|
|
4978
|
-
const
|
|
4979
|
-
|
|
4980
|
-
}, I = t.filter(($) => $.disabled !== !0), [
|
|
4981
|
-
var
|
|
4982
|
-
return Array.from(((
|
|
4983
|
-
}, Ee =
|
|
4978
|
+
const z = Od($.key);
|
|
4979
|
+
z !== void 0 && ($.preventDefault(), H(z, O(), w(), !0));
|
|
4980
|
+
}, I = t.filter(($) => $.disabled !== !0), [q, te] = B(null), ke = ($) => {
|
|
4981
|
+
var z;
|
|
4982
|
+
return Array.from(((z = m.current) == null ? void 0 : z.querySelectorAll("[data-tool]")) ?? []).find((M) => M.dataset.tool === $);
|
|
4983
|
+
}, Ee = q !== null && I.some(($) => $.id === q) ? q : ((xe = I[0]) == null ? void 0 : xe.id) ?? null, oe = ($) => {
|
|
4984
4984
|
var le;
|
|
4985
|
-
const
|
|
4986
|
-
if (!
|
|
4985
|
+
const z = $.key === "ArrowRight" || $.key === "ArrowDown", M = $.key === "ArrowLeft" || $.key === "ArrowUp", j = $.key === "Home", x = $.key === "End";
|
|
4986
|
+
if (!z && !M && !j && !x || I.length === 0) return;
|
|
4987
4987
|
$.preventDefault();
|
|
4988
4988
|
const W = I.findIndex(
|
|
4989
4989
|
(ue) => ue.id === $.currentTarget.dataset.tool
|
|
4990
|
-
), ee =
|
|
4990
|
+
), ee = j ? 0 : x ? I.length - 1 : nn(W === -1 ? 0 : W, I.length, z ? 1 : -1), ae = I[ee];
|
|
4991
4991
|
ae !== void 0 && (te(ae.id), (le = ke(ae.id)) == null || le.focus());
|
|
4992
4992
|
}, K = ($) => {
|
|
4993
4993
|
te($.id), c == null || c($.id), i !== void 0 && i !== $.id && (a == null || a($.id));
|
|
4994
4994
|
};
|
|
4995
4995
|
Oe(() => {
|
|
4996
|
-
const $ =
|
|
4996
|
+
const $ = V.current;
|
|
4997
4997
|
if ($ !== null && $.place === g) return;
|
|
4998
4998
|
_e();
|
|
4999
|
-
const
|
|
5000
|
-
|
|
4999
|
+
const z = C(g);
|
|
5000
|
+
V.current = z, !($ === null || z === null) && (Mt() || ye($, z));
|
|
5001
5001
|
});
|
|
5002
5002
|
function _e() {
|
|
5003
5003
|
for (const $ of U.current) $.cancel();
|
|
5004
5004
|
U.current = [];
|
|
5005
5005
|
}
|
|
5006
|
-
function ye($,
|
|
5006
|
+
function ye($, z) {
|
|
5007
5007
|
const M = m.current;
|
|
5008
5008
|
if (M === null || typeof M.animate != "function") return;
|
|
5009
|
-
const
|
|
5009
|
+
const j = getComputedStyle(M), x = yt(j, "--u-duration-medium");
|
|
5010
5010
|
if (x <= 0) return;
|
|
5011
5011
|
const W = {
|
|
5012
5012
|
duration: x,
|
|
5013
|
-
easing:
|
|
5013
|
+
easing: j.getPropertyValue("--u-ease-out").trim() || "ease-out"
|
|
5014
5014
|
}, ee = (de) => ({
|
|
5015
5015
|
left: `${de.strip.left - de.root.left}px`,
|
|
5016
5016
|
top: `${de.strip.top - de.root.top}px`,
|
|
@@ -5023,31 +5023,31 @@ const Qu = ie(function({
|
|
|
5023
5023
|
marginTop: "0px",
|
|
5024
5024
|
marginBottom: "0px"
|
|
5025
5025
|
});
|
|
5026
|
-
U.current.push(M.animate([ee($), ee(
|
|
5027
|
-
const ae =
|
|
5028
|
-
ae.forEach((de,
|
|
5029
|
-
const be = $.children[
|
|
5026
|
+
U.current.push(M.animate([ee($), ee(z)], W));
|
|
5027
|
+
const ae = Ft(M), le = $.strip.left - z.strip.left, ue = $.strip.top - z.strip.top;
|
|
5028
|
+
ae.forEach((de, fe) => {
|
|
5029
|
+
const be = $.children[fe], we = z.children[fe];
|
|
5030
5030
|
if (be === void 0 || we === void 0) return;
|
|
5031
|
-
const
|
|
5032
|
-
Math.abs(
|
|
5031
|
+
const he = be.left - we.left - le, Fe = be.top - we.top - ue;
|
|
5032
|
+
Math.abs(he) < 0.5 && Math.abs(Fe) < 0.5 || U.current.push(
|
|
5033
5033
|
de.animate(
|
|
5034
|
-
[{ transform: `translate(${
|
|
5034
|
+
[{ transform: `translate(${he}px, ${Fe}px)` }, { transform: "none" }],
|
|
5035
5035
|
W
|
|
5036
5036
|
)
|
|
5037
5037
|
);
|
|
5038
5038
|
});
|
|
5039
5039
|
}
|
|
5040
5040
|
return ne(() => {
|
|
5041
|
-
const $ =
|
|
5041
|
+
const $ = f.current;
|
|
5042
5042
|
if ($ === null || typeof ResizeObserver > "u") return;
|
|
5043
|
-
const
|
|
5044
|
-
const M = O(),
|
|
5045
|
-
if (M === null ||
|
|
5046
|
-
const x = Hd(N.current, t.length, M,
|
|
5043
|
+
const z = new ResizeObserver(() => {
|
|
5044
|
+
const M = O(), j = w();
|
|
5045
|
+
if (M === null || j === null || jt(N.current, t.length, M, j)) return;
|
|
5046
|
+
const x = Hd(N.current, t.length, M, j);
|
|
5047
5047
|
x !== void 0 && S(x);
|
|
5048
5048
|
});
|
|
5049
|
-
return
|
|
5050
|
-
}, [w, S, t.length, O]), /* @__PURE__ */ k("div", { ref:
|
|
5049
|
+
return z.observe($), () => z.disconnect();
|
|
5050
|
+
}, [w, S, t.length, O]), /* @__PURE__ */ k("div", { ref: f, className: P(ot.root, d), ...u, children: [
|
|
5051
5051
|
/* @__PURE__ */ k(
|
|
5052
5052
|
"div",
|
|
5053
5053
|
{
|
|
@@ -5055,29 +5055,29 @@ const Qu = ie(function({
|
|
|
5055
5055
|
"data-place": g,
|
|
5056
5056
|
className: ot.strip,
|
|
5057
5057
|
role: "group",
|
|
5058
|
-
"aria-label": l ??
|
|
5058
|
+
"aria-label": l ?? h.dockTools,
|
|
5059
5059
|
children: [
|
|
5060
5060
|
/* @__PURE__ */ s("span", { className: ot.gripSlot, children: /* @__PURE__ */ s(
|
|
5061
5061
|
"button",
|
|
5062
5062
|
{
|
|
5063
5063
|
type: "button",
|
|
5064
5064
|
className: ot.grip,
|
|
5065
|
-
"aria-label":
|
|
5065
|
+
"aria-label": h.dockGrip,
|
|
5066
5066
|
onPointerDown: pe,
|
|
5067
5067
|
onKeyDown: A,
|
|
5068
5068
|
children: /* @__PURE__ */ s(xr, {})
|
|
5069
5069
|
}
|
|
5070
5070
|
) }),
|
|
5071
5071
|
t.map(($) => {
|
|
5072
|
-
const
|
|
5072
|
+
const z = i !== void 0 && i === $.id;
|
|
5073
5073
|
return /* @__PURE__ */ s(_d, { content: $.label, children: /* @__PURE__ */ s(
|
|
5074
5074
|
"button",
|
|
5075
5075
|
{
|
|
5076
5076
|
type: "button",
|
|
5077
5077
|
"data-tool": $.id,
|
|
5078
|
-
className: P(ot.tool,
|
|
5078
|
+
className: P(ot.tool, z && ot.inMode),
|
|
5079
5079
|
"aria-label": $.label,
|
|
5080
|
-
"aria-pressed":
|
|
5080
|
+
"aria-pressed": z ? !0 : void 0,
|
|
5081
5081
|
disabled: $.disabled,
|
|
5082
5082
|
tabIndex: $.id === Ee ? 0 : -1,
|
|
5083
5083
|
onClick: () => K($),
|
|
@@ -5100,7 +5100,7 @@ const Qu = ie(function({
|
|
|
5100
5100
|
"aria-hidden": "true"
|
|
5101
5101
|
}
|
|
5102
5102
|
),
|
|
5103
|
-
/* @__PURE__ */ s(
|
|
5103
|
+
/* @__PURE__ */ s(On, { role: "status", "aria-live": "polite", children: D })
|
|
5104
5104
|
] });
|
|
5105
5105
|
});
|
|
5106
5106
|
function Zu({ open: e, onOpenChange: t, position: n, ariaLabel: r, children: o }) {
|
|
@@ -5143,8 +5143,8 @@ function Zu({ open: e, onOpenChange: t, position: n, ariaLabel: r, children: o }
|
|
|
5143
5143
|
{
|
|
5144
5144
|
ref: l,
|
|
5145
5145
|
className: ct.content,
|
|
5146
|
-
onKeyDown: (u) =>
|
|
5147
|
-
children: /* @__PURE__ */ s(
|
|
5146
|
+
onKeyDown: (u) => In(u, c.current, d),
|
|
5147
|
+
children: /* @__PURE__ */ s(Jt.Provider, { value: { close: d }, children: o })
|
|
5148
5148
|
}
|
|
5149
5149
|
)
|
|
5150
5150
|
}
|
|
@@ -5153,25 +5153,25 @@ function Zu({ open: e, onOpenChange: t, position: n, ariaLabel: r, children: o }
|
|
|
5153
5153
|
}
|
|
5154
5154
|
export {
|
|
5155
5155
|
tu as Alert,
|
|
5156
|
-
|
|
5156
|
+
St as AngleGlyph,
|
|
5157
5157
|
nu as Badge,
|
|
5158
5158
|
ve as Button,
|
|
5159
5159
|
lo as ButtonGroup,
|
|
5160
|
-
|
|
5160
|
+
Cn as CalendarGlyph,
|
|
5161
5161
|
du as Card,
|
|
5162
|
-
|
|
5162
|
+
hu as CardBody,
|
|
5163
5163
|
uu as CardHeader,
|
|
5164
|
-
|
|
5165
|
-
|
|
5164
|
+
tn as Checkbox,
|
|
5165
|
+
An as ClockGlyph,
|
|
5166
5166
|
mu as Combobox,
|
|
5167
|
-
|
|
5167
|
+
fu as CommandPalette,
|
|
5168
5168
|
Su as ConfirmDialog,
|
|
5169
5169
|
Zu as ContextMenu,
|
|
5170
5170
|
Ue as CrossGlyph,
|
|
5171
|
-
|
|
5172
|
-
|
|
5171
|
+
It as DEFAULT_FORMATS,
|
|
5172
|
+
Tn as DEFAULT_LANGUAGE,
|
|
5173
5173
|
yu as DEFAULT_PRESETS,
|
|
5174
|
-
|
|
5174
|
+
Dn as DEFAULT_SEPARATORS,
|
|
5175
5175
|
it as DEFAULT_WORDING,
|
|
5176
5176
|
gu as DatePicker,
|
|
5177
5177
|
bu as DateRangePicker,
|
|
@@ -5181,33 +5181,33 @@ export {
|
|
|
5181
5181
|
Qu as Dock,
|
|
5182
5182
|
xu as EmptyState,
|
|
5183
5183
|
ru as FormField,
|
|
5184
|
-
|
|
5184
|
+
Vr as FormFieldBoundary,
|
|
5185
5185
|
$u as Grid,
|
|
5186
5186
|
Jd as GridGlyph,
|
|
5187
5187
|
xr as GripGlyph,
|
|
5188
5188
|
Uu as Heading,
|
|
5189
5189
|
Vn as Input,
|
|
5190
|
-
|
|
5190
|
+
br as LanguageProvider,
|
|
5191
5191
|
Yu as Link,
|
|
5192
5192
|
eu as MeasureGlyph,
|
|
5193
5193
|
oo as Menu,
|
|
5194
5194
|
au as MenuItem,
|
|
5195
5195
|
cu as MenuSeparator,
|
|
5196
5196
|
_u as Meter,
|
|
5197
|
-
|
|
5197
|
+
kr as MinusGlyph,
|
|
5198
5198
|
nc as Modal,
|
|
5199
5199
|
Tu as ModalBody,
|
|
5200
5200
|
oc as ModalFooter,
|
|
5201
5201
|
rc as ModalHeader,
|
|
5202
5202
|
Mu as MultiSelect,
|
|
5203
5203
|
Du as NumberInput,
|
|
5204
|
-
|
|
5204
|
+
wr as PlusGlyph,
|
|
5205
5205
|
Je as Popover,
|
|
5206
5206
|
Cu as RadioGroup,
|
|
5207
5207
|
Au as Select,
|
|
5208
5208
|
Lu as Skeleton,
|
|
5209
|
-
|
|
5210
|
-
|
|
5209
|
+
zs as Sparkline,
|
|
5210
|
+
Ln as Spinner,
|
|
5211
5211
|
lu as SplitButton,
|
|
5212
5212
|
Nu as Stack,
|
|
5213
5213
|
Xu as Stat,
|
|
@@ -5217,51 +5217,51 @@ export {
|
|
|
5217
5217
|
Eu as Tabs,
|
|
5218
5218
|
Pu as Tag,
|
|
5219
5219
|
Ru as TagGroup,
|
|
5220
|
-
|
|
5221
|
-
|
|
5220
|
+
Vu as Text,
|
|
5221
|
+
zu as Textarea,
|
|
5222
5222
|
Hu as ToastProvider,
|
|
5223
5223
|
_d as Tooltip,
|
|
5224
5224
|
Wu as TreeSearch,
|
|
5225
|
-
|
|
5225
|
+
qu as TreeView,
|
|
5226
5226
|
iu as UmrissProvider,
|
|
5227
|
-
|
|
5228
|
-
|
|
5227
|
+
On as VisuallyHidden,
|
|
5228
|
+
or as age,
|
|
5229
5229
|
id as allBranches,
|
|
5230
5230
|
bd as assess,
|
|
5231
5231
|
Nd as cadence,
|
|
5232
5232
|
ll as clampedHeight,
|
|
5233
|
-
|
|
5233
|
+
tr as collapse,
|
|
5234
5234
|
Gu as duplicateKey,
|
|
5235
|
-
|
|
5235
|
+
er as expand,
|
|
5236
5236
|
xd as freshness,
|
|
5237
5237
|
td as keysBetween,
|
|
5238
|
-
|
|
5239
|
-
|
|
5238
|
+
yr as mergeLanguage,
|
|
5239
|
+
vn as move,
|
|
5240
5240
|
od as pathTo,
|
|
5241
5241
|
Dt as rangeDays,
|
|
5242
5242
|
cl as remainingChars,
|
|
5243
5243
|
sd as revealPath,
|
|
5244
5244
|
Ql as scrollForRow,
|
|
5245
|
-
|
|
5245
|
+
ar as separatorsOf,
|
|
5246
5246
|
Ge as setActive,
|
|
5247
|
-
|
|
5248
|
-
|
|
5247
|
+
yn as setAnchor,
|
|
5248
|
+
Wt as setChecked,
|
|
5249
5249
|
nd as toggleAll,
|
|
5250
|
-
|
|
5250
|
+
bn as toggleCheck,
|
|
5251
5251
|
ed as treeModel,
|
|
5252
5252
|
rd as typeaheadTarget,
|
|
5253
5253
|
pu as useCommandPaletteShortcut,
|
|
5254
5254
|
su as useDensity,
|
|
5255
5255
|
ou as useDensityFor,
|
|
5256
5256
|
Be as useFormField,
|
|
5257
|
-
|
|
5257
|
+
Ve as useFormats,
|
|
5258
5258
|
$d as useFreshness,
|
|
5259
|
-
|
|
5260
|
-
|
|
5259
|
+
Mn as useLanguage,
|
|
5260
|
+
Zt as usePortalTarget,
|
|
5261
5261
|
Ou as useToast,
|
|
5262
5262
|
Zr as useToastConfig,
|
|
5263
|
-
|
|
5264
|
-
|
|
5263
|
+
ju as useTree,
|
|
5264
|
+
Qt as useUmriss,
|
|
5265
5265
|
Zl as useVirtual,
|
|
5266
5266
|
ce as useWording,
|
|
5267
5267
|
Ku as verdictWeight,
|