@q1travel/design-system 0.30.5 → 0.30.6

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.
@@ -555,7 +555,7 @@ function _a(e) {
555
555
  function Wc({ children: e }) {
556
556
  const [t, r] = Y([]), [o, i] = Y(() => Vt()), a = R(0), s = R(/* @__PURE__ */ new Map()), l = R(
557
557
  new Set(typeof document < "u" && document.hidden ? ["hidden"] : [])
558
- ), u = R(null), m = R(null), d = R(0), f = R(null), [g, h] = Y(!1);
558
+ ), u = R(null), m = R(null), d = R(0), f = R(null), [b, h] = Y(!1);
559
559
  ie(() => {
560
560
  const x = Gr(() => {
561
561
  i(Vt());
@@ -592,7 +592,7 @@ function Wc({ children: e }) {
592
592
  window.clearTimeout(N.handle), N.remaining = Math.max(0, N.remaining - (v - N.start));
593
593
  });
594
594
  }
595
- function b(x) {
595
+ function g(x) {
596
596
  if (!l.current.delete(x) || l.current.size > 0) return;
597
597
  const T = Date.now();
598
598
  s.current.forEach((v, N) => {
@@ -601,7 +601,7 @@ function Wc({ children: e }) {
601
601
  }
602
602
  ie(() => {
603
603
  const x = () => {
604
- document.hidden ? y("hidden") : b("hidden");
604
+ document.hidden ? y("hidden") : g("hidden");
605
605
  };
606
606
  return document.addEventListener("visibilitychange", x), x(), () => document.removeEventListener("visibilitychange", x);
607
607
  }, []), ie(
@@ -628,9 +628,9 @@ function Wc({ children: e }) {
628
628
  C === 0 && (M = S), D.style.setProperty("--depth", String(C)), D.style.setProperty("--h", `${S}px`), D.style.setProperty("--y", `${-N}px`), D.style.zIndex = String(100 + P), D.dataset.front = String(C === 0), D.dataset.visible = String(C < pn), N += S + jn;
629
629
  }
630
630
  x.style.setProperty("--front-h", `${M}px`);
631
- const L = M + Math.min(T.length - 1, pn - 1) * pa, E = T.length === 0 ? 0 : g ? Math.max(N - jn, 0) : L;
631
+ const L = M + Math.min(T.length - 1, pn - 1) * pa, E = T.length === 0 ? 0 : b ? Math.max(N - jn, 0) : L;
632
632
  x.style.setProperty("--toast-stack-h", `${E}px`);
633
- }, [t, g]), ie(() => {
633
+ }, [t, b]), ie(() => {
634
634
  t.filter((x) => !x.removed).length <= 1 && h(!1);
635
635
  }, [t]);
636
636
  const w = De(() => ({ push: c, dismiss: p }), [c, p]), k = new Set(
@@ -656,19 +656,19 @@ function Wc({ children: e }) {
656
656
  className: "q1-toast-region",
657
657
  role: "region",
658
658
  "aria-label": "通知",
659
- "data-expanded": g,
659
+ "data-expanded": b,
660
660
  onMouseEnter: () => {
661
661
  h(!0), y("pointer");
662
662
  },
663
663
  onMouseLeave: () => {
664
- h(!1), b("pointer");
664
+ h(!1), g("pointer");
665
665
  },
666
666
  onFocusCapture: (x) => {
667
667
  const T = x.relatedTarget;
668
668
  T instanceof HTMLElement && !u.current?.contains(T) && (f.current = T), h(!0), y("focus");
669
669
  },
670
670
  onBlurCapture: (x) => {
671
- x.currentTarget.contains(x.relatedTarget) || (h(!1), b("focus"));
671
+ x.currentTarget.contains(x.relatedTarget) || (h(!1), g("focus"));
672
672
  },
673
673
  children: t.map((x) => /* @__PURE__ */ n(
674
674
  ya,
@@ -685,19 +685,19 @@ function Wc({ children: e }) {
685
685
  ] });
686
686
  }
687
687
  function ya({ toast: e, interactionInert: t, controlsDisabled: r, onDismiss: o }) {
688
- const i = R(null), [a, s] = Y(!1), [l, u] = Y(!0), [m, d] = Y(!1), [f, g] = Y(!1), [h, p] = Y(null), c = R(null), y = R(null), b = R({ x: 0, y: 0 }), w = R(null), k = R(null);
688
+ const i = R(null), [a, s] = Y(!1), [l, u] = Y(!0), [m, d] = Y(!1), [f, b] = Y(!1), [h, p] = Y(null), c = R(null), y = R(null), g = R({ x: 0, y: 0 }), w = R(null), k = R(null);
689
689
  ie(() => (s(!0), w.current = window.setTimeout(() => u(!1), Pn("--q1-duration-base")), () => {
690
690
  w.current !== null && window.clearTimeout(w.current), k.current !== null && window.clearTimeout(k.current);
691
691
  }), []);
692
692
  const x = e.tone === "default" ? null : ma[e.tone];
693
693
  function T(P, D = !0) {
694
694
  const C = y.current;
695
- c.current = null, y.current = null, b.current = { x: 0, y: 0 };
695
+ c.current = null, y.current = null, g.current = { x: 0, y: 0 };
696
696
  const S = P?.currentTarget ?? i.current;
697
- S && C !== null && S.hasPointerCapture(C) && S.releasePointerCapture(C), d(!1), g(D), k.current !== null && window.clearTimeout(k.current), D && !window.matchMedia("(prefers-reduced-motion: reduce)").matches ? k.current = window.setTimeout(
698
- () => g(!1),
697
+ S && C !== null && S.hasPointerCapture(C) && S.releasePointerCapture(C), d(!1), b(D), k.current !== null && window.clearTimeout(k.current), D && !window.matchMedia("(prefers-reduced-motion: reduce)").matches ? k.current = window.setTimeout(
698
+ () => b(!1),
699
699
  Pn("--q1-duration-fast")
700
- ) : g(!1);
700
+ ) : b(!1);
701
701
  const O = i.current;
702
702
  O?.style.removeProperty("--swipe-x"), O?.style.removeProperty("--swipe-y"), O?.style.removeProperty("opacity");
703
703
  }
@@ -706,7 +706,7 @@ function ya({ toast: e, interactionInert: t, controlsDisabled: r, onDismiss: o }
706
706
  }, [t]);
707
707
  function v(P) {
708
708
  if (!(t || e.removed || P.button !== 0 || y.current !== null) && !P.target.closest("button, a")) {
709
- k.current !== null && window.clearTimeout(k.current), g(!1), y.current = P.pointerId, c.current = { x: P.clientX, y: P.clientY, time: Date.now() };
709
+ k.current !== null && window.clearTimeout(k.current), b(!1), y.current = P.pointerId, c.current = { x: P.clientX, y: P.clientY, time: Date.now() };
710
710
  try {
711
711
  P.currentTarget.setPointerCapture(P.pointerId);
712
712
  } catch {
@@ -716,16 +716,16 @@ function ya({ toast: e, interactionInert: t, controlsDisabled: r, onDismiss: o }
716
716
  function N(P) {
717
717
  if (!c.current || y.current !== P.pointerId) return;
718
718
  const D = P.clientX - c.current.x, C = P.clientY - c.current.y, S = (U) => Math.sign(U) * Math.log1p(Math.abs(U)) * 2;
719
- b.current = { x: D > 0 ? D : S(D), y: C > 0 ? C : S(C) }, !m && (Math.abs(D) > 2 || Math.abs(C) > 2) && d(!0);
719
+ g.current = { x: D > 0 ? D : S(D), y: C > 0 ? C : S(C) }, !m && (Math.abs(D) > 2 || Math.abs(C) > 2) && d(!0);
720
720
  const O = i.current;
721
721
  if (!O) return;
722
- O.style.setProperty("--swipe-x", `${b.current.x}px`), O.style.setProperty("--swipe-y", `${b.current.y}px`);
722
+ O.style.setProperty("--swipe-x", `${g.current.x}px`), O.style.setProperty("--swipe-y", `${g.current.y}px`);
723
723
  const B = Math.max(0, Math.abs(D) >= Math.abs(C) ? D : C), A = 1 - 0.35 * Math.min(B / Yn, 1);
724
724
  O.style.opacity = String(A);
725
725
  }
726
726
  function M(P) {
727
727
  if (!c.current || y.current !== P.pointerId) return;
728
- const { x: D, y: C } = b.current, S = Math.max(1, Date.now() - c.current.time), O = Math.abs(D) >= Math.abs(C) ? "x" : "y", B = O === "x" ? D : C;
728
+ const { x: D, y: C } = g.current, S = Math.max(1, Date.now() - c.current.time), O = Math.abs(D) >= Math.abs(C) ? "x" : "y", B = O === "x" ? D : C;
729
729
  if (B > 0 && (B >= Yn || B / S > ha)) {
730
730
  T(P, !1), p(O === "x" ? "right" : "down"), o(e.id);
731
731
  return;
@@ -834,10 +834,10 @@ function An({ success: e = "toast", resetAfterMs: t = 1500 } = {}) {
834
834
  }
835
835
  },
836
836
  [d, t, e]
837
- ), g = fe(() => {
837
+ ), b = fe(() => {
838
838
  u.current += 1, s.current && clearTimeout(s.current), m.current && o(!1);
839
839
  }, []);
840
- return { copied: r, pending: i, copy: f, reset: g };
840
+ return { copied: r, pending: i, copy: f, reset: b };
841
841
  }
842
842
  const wa = typeof document > "u" ? ie : pe;
843
843
  function Xn({
@@ -847,9 +847,9 @@ function Xn({
847
847
  size: o = 16,
848
848
  className: i
849
849
  }) {
850
- const { copied: a, pending: s, copy: l, reset: u } = An({ success: "inline", resetAfterMs: 2e3 }), m = R(e), d = m.current !== e, f = R(!1), g = R(!1), [h, p] = Y(!1), [c, y] = Y("instant"), [b, w] = Y(!1);
851
- ie(() => (g.current = !0, () => {
852
- g.current = !1;
850
+ const { copied: a, pending: s, copy: l, reset: u } = An({ success: "inline", resetAfterMs: 2e3 }), m = R(e), d = m.current !== e, f = R(!1), b = R(!1), [h, p] = Y(!1), [c, y] = Y("instant"), [g, w] = Y(!1);
851
+ ie(() => (b.current = !0, () => {
852
+ b.current = !1;
853
853
  }), []), wa(() => {
854
854
  m.current !== e && (m.current = e, y("instant"), u());
855
855
  }, [u, e]), ie(() => {
@@ -864,7 +864,7 @@ function Xn({
864
864
  if (f.current) return;
865
865
  f.current = !0, y(T.detail === 0 ? "instant" : "pointer"), u();
866
866
  const v = l(e, r), N = () => {
867
- f.current = !1, g.current && (p(!1), w(!1));
867
+ f.current = !1, b.current && (p(!1), w(!1));
868
868
  };
869
869
  v.then(N, N);
870
870
  }
@@ -878,7 +878,7 @@ function Xn({
878
878
  "aria-label": t,
879
879
  "aria-busy": s || void 0,
880
880
  "aria-disabled": s || void 0,
881
- "data-pointer-pressed": b || void 0,
881
+ "data-pointer-pressed": g || void 0,
882
882
  onPointerDown: () => {
883
883
  f.current || w(!0);
884
884
  },
@@ -1077,12 +1077,12 @@ function $e(e) {
1077
1077
  rounded: m,
1078
1078
  selected: d,
1079
1079
  loading: f,
1080
- loadingLabel: g,
1080
+ loadingLabel: b,
1081
1081
  busy: h,
1082
1082
  busyLabel: p,
1083
1083
  disabled: c,
1084
1084
  type: y = "button",
1085
- shortcut: b,
1085
+ shortcut: g,
1086
1086
  className: w,
1087
1087
  children: k,
1088
1088
  prefix: x,
@@ -1151,10 +1151,10 @@ function $e(e) {
1151
1151
  onBlur: B,
1152
1152
  onKeyDown: A,
1153
1153
  onTransitionEnd: I,
1154
- children: eo({ svgOnly: s, iconOnly: l, busy: h, busyLabel: p, loading: f, loadingLabel: g, prefix: x, children: k, suffix: T, shortcut: b, touchTarget: !0 })
1154
+ children: eo({ svgOnly: s, iconOnly: l, busy: h, busyLabel: p, loading: f, loadingLabel: b, prefix: x, children: k, suffix: T, shortcut: g, touchTarget: !0 })
1155
1155
  }
1156
1156
  ),
1157
- to({ busy: h, busyLabel: p, loadingLabel: g })
1157
+ to({ busy: h, busyLabel: p, loadingLabel: b })
1158
1158
  ] });
1159
1159
  }
1160
1160
  function ka(e) {
@@ -1167,12 +1167,12 @@ function ka(e) {
1167
1167
  variant: m,
1168
1168
  size: d,
1169
1169
  svgOnly: f,
1170
- iconOnly: g,
1170
+ iconOnly: b,
1171
1171
  circle: h,
1172
1172
  rounded: p,
1173
1173
  selected: c,
1174
1174
  disabled: y,
1175
- type: b,
1175
+ type: g,
1176
1176
  shortcut: w,
1177
1177
  className: k,
1178
1178
  children: x,
@@ -1194,12 +1194,12 @@ function ka(e) {
1194
1194
  onTransitionCancel: Q,
1195
1195
  ref: G,
1196
1196
  ...X
1197
- } = e, ne = f ?? g, z = !!(u || ne), te = !!(ne && (l || a) || u && l), $ = ce(
1197
+ } = e, ne = f ?? b, z = !!(u || ne), te = !!(ne && (l || a) || u && l), $ = ce(
1198
1198
  Fn({
1199
1199
  variant: m,
1200
1200
  size: d,
1201
1201
  svgOnly: f,
1202
- iconOnly: g,
1202
+ iconOnly: b,
1203
1203
  circle: h,
1204
1204
  rounded: p,
1205
1205
  selected: c,
@@ -1242,7 +1242,7 @@ function ka(e) {
1242
1242
  onKeyDown: U,
1243
1243
  onTransitionEnd: F,
1244
1244
  onTransitionCancel: F,
1245
- children: eo({ svgOnly: f, iconOnly: g, busy: l, busyLabel: u, loading: a, loadingLabel: s, prefix: T, children: x, suffix: v, shortcut: w })
1245
+ children: eo({ svgOnly: f, iconOnly: b, busy: l, busyLabel: u, loading: a, loadingLabel: s, prefix: T, children: x, suffix: v, shortcut: w })
1246
1246
  }
1247
1247
  ),
1248
1248
  to({ busy: l, busyLabel: u, loadingLabel: s })
@@ -1311,11 +1311,11 @@ function Vc({
1311
1311
  a.current = null, s.current = 0, l.current = !1;
1312
1312
  return;
1313
1313
  }
1314
- const c = a.current, y = i.current?.ownerDocument, b = y?.activeElement, w = p.find((v) => v === b), k = Math.min(s.current, p.length - 1), x = (c && p.includes(c) ? c : null) ?? w ?? p[k], T = !!(c && !p.includes(c) && l.current && (b === c || b === y?.body || b === y?.documentElement || b === null));
1314
+ const c = a.current, y = i.current?.ownerDocument, g = y?.activeElement, w = p.find((v) => v === g), k = Math.min(s.current, p.length - 1), x = (c && p.includes(c) ? c : null) ?? w ?? p[k], T = !!(c && !p.includes(c) && l.current && (g === c || g === y?.body || g === y?.documentElement || g === null));
1315
1315
  p.forEach((v, N) => {
1316
1316
  const M = v === x ? 0 : -1;
1317
1317
  v.tabIndex !== M && (v.tabIndex = M), v === x && (s.current = N);
1318
- }), a.current = x, T && b !== x && x.focus();
1318
+ }), a.current = x, T && g !== x && x.focus();
1319
1319
  }, [u]);
1320
1320
  pe(() => {
1321
1321
  const p = i.current;
@@ -1330,16 +1330,16 @@ function Vc({
1330
1330
  }, [m]);
1331
1331
  function d(p, c = u()) {
1332
1332
  const y = c.indexOf(p);
1333
- y !== -1 && (c.forEach((b) => {
1334
- const w = b === p ? 0 : -1;
1335
- b.tabIndex !== w && (b.tabIndex = w);
1333
+ y !== -1 && (c.forEach((g) => {
1334
+ const w = g === p ? 0 : -1;
1335
+ g.tabIndex !== w && (g.tabIndex = w);
1336
1336
  }), a.current = p, s.current = y);
1337
1337
  }
1338
1338
  function f(p) {
1339
- const c = u(), y = c.find((b) => b === p.target);
1339
+ const c = u(), y = c.find((g) => g === p.target);
1340
1340
  y && (l.current = !0, d(y, c));
1341
1341
  }
1342
- function g(p) {
1342
+ function b(p) {
1343
1343
  const c = i.current;
1344
1344
  if (!c) return;
1345
1345
  const y = c.ownerDocument.defaultView?.Node;
@@ -1357,12 +1357,12 @@ function Vc({
1357
1357
  if (p.defaultPrevented || p.altKey || p.ctrlKey || p.metaKey) return;
1358
1358
  const c = t === "horizontal" ? "ArrowRight" : "ArrowDown", y = t === "horizontal" ? "ArrowLeft" : "ArrowUp";
1359
1359
  if (!["Home", "End", c, y].includes(p.key)) return;
1360
- const b = u();
1361
- if (b.length === 0) return;
1362
- const w = b.indexOf(i.current?.ownerDocument.activeElement);
1363
- if (w === -1 || Ea(b[w])) return;
1360
+ const g = u();
1361
+ if (g.length === 0) return;
1362
+ const w = g.indexOf(i.current?.ownerDocument.activeElement);
1363
+ if (w === -1 || Ea(g[w])) return;
1364
1364
  let k;
1365
- p.key === c ? k = (w + 1) % b.length : p.key === y ? k = (w - 1 + b.length) % b.length : p.key === "Home" ? k = 0 : k = b.length - 1, p.preventDefault(), d(b[k], b), b[k].focus();
1365
+ p.key === c ? k = (w + 1) % g.length : p.key === y ? k = (w - 1 + g.length) % g.length : p.key === "Home" ? k = 0 : k = g.length - 1, p.preventDefault(), d(g[k], g), g[k].focus();
1366
1366
  }
1367
1367
  return /* @__PURE__ */ n(
1368
1368
  "div",
@@ -1372,7 +1372,7 @@ function Vc({
1372
1372
  role: "toolbar",
1373
1373
  "aria-label": e,
1374
1374
  "aria-orientation": t === "vertical" ? "vertical" : void 0,
1375
- onBlurCapture: g,
1375
+ onBlurCapture: b,
1376
1376
  onFocusCapture: f,
1377
1377
  onKeyDown: h,
1378
1378
  children: r
@@ -1392,14 +1392,14 @@ function Ia({
1392
1392
  onPointerDown: m,
1393
1393
  onPointerLeave: d,
1394
1394
  onPointerUp: f,
1395
- onLostPointerCapture: g,
1395
+ onLostPointerCapture: b,
1396
1396
  ...h
1397
1397
  }) {
1398
- const [p, c] = Y(!1), [y, b] = Y(), w = R(!1), k = R(!1), x = R(!1), T = e ?? t, v = r === !0 || r === "true" ? !0 : r === !1 || r === "false" ? !1 : void 0;
1398
+ const [p, c] = Y(!1), [y, g] = Y(), w = R(!1), k = R(!1), x = R(!1), T = e ?? t, v = r === !0 || r === "true" ? !0 : r === !1 || r === "false" ? !1 : void 0;
1399
1399
  ie(() => {
1400
1400
  (o || i) && c(!1);
1401
1401
  }, [o, i]), ie(() => {
1402
- i && y === "pointer" ? w.current = !0 : !i && w.current ? (w.current = !1, b(void 0)) : !i && y === "pointer" && b(void 0);
1402
+ i && y === "pointer" ? w.current = !0 : !i && w.current ? (w.current = !1, g(void 0)) : !i && y === "pointer" && g(void 0);
1403
1403
  }, [i, y]);
1404
1404
  const S = {
1405
1405
  ...h,
@@ -1407,32 +1407,32 @@ function Ia({
1407
1407
  loading: i,
1408
1408
  onClick: (O) => {
1409
1409
  const B = O.detail > 0 && (k.current || x.current);
1410
- k.current = !1, x.current = !1, B && !O.defaultPrevented && !o && !i ? b("pointer") : w.current || b(void 0), a?.(O);
1410
+ k.current = !1, x.current = !1, B && !O.defaultPrevented && !o && !i ? g("pointer") : w.current || g(void 0), a?.(O);
1411
1411
  },
1412
1412
  onBlur: (O) => {
1413
- s?.(O), k.current = !1, x.current = !1, c(!1), w.current || b(void 0);
1413
+ s?.(O), k.current = !1, x.current = !1, c(!1), w.current || g(void 0);
1414
1414
  },
1415
1415
  onKeyDown: (O) => {
1416
- l?.(O), k.current = !1, x.current = !1, c(!1), w.current || b(void 0);
1416
+ l?.(O), k.current = !1, x.current = !1, c(!1), w.current || g(void 0);
1417
1417
  },
1418
1418
  onPointerCancel: (O) => {
1419
- u?.(O), k.current = !1, x.current = !1, c(!1), w.current || b(void 0);
1419
+ u?.(O), k.current = !1, x.current = !1, c(!1), w.current || g(void 0);
1420
1420
  },
1421
1421
  onPointerDown: (O) => {
1422
1422
  if (m?.(O), O.defaultPrevented || !O.isPrimary || O.button !== 0 || o || i) {
1423
1423
  k.current = !1, x.current = !1;
1424
1424
  return;
1425
1425
  }
1426
- k.current = !0, x.current = !1, b(void 0), c(!0);
1426
+ k.current = !0, x.current = !1, g(void 0), c(!0);
1427
1427
  },
1428
1428
  onPointerLeave: (O) => {
1429
- d?.(O), k.current = !1, x.current = !1, c(!1), w.current || b(void 0);
1429
+ d?.(O), k.current = !1, x.current = !1, c(!1), w.current || g(void 0);
1430
1430
  },
1431
1431
  onPointerUp: (O) => {
1432
- f?.(O), x.current = k.current && O.isPrimary && O.button === 0, x.current || (k.current = !1), c(!1), w.current || b(void 0);
1432
+ f?.(O), x.current = k.current && O.isPrimary && O.button === 0, x.current || (k.current = !1), c(!1), w.current || g(void 0);
1433
1433
  },
1434
1434
  onLostPointerCapture: (O) => {
1435
- g?.(O), x.current || (k.current = !1), c(!1), w.current || b(void 0);
1435
+ b?.(O), x.current || (k.current = !1), c(!1), w.current || g(void 0);
1436
1436
  },
1437
1437
  "data-icon-button": "",
1438
1438
  "data-icon-button-pointer-pressed": p ? "true" : void 0,
@@ -1563,12 +1563,12 @@ function ro({
1563
1563
  tip: l = !0,
1564
1564
  center: u = !1
1565
1565
  }) {
1566
- const m = Ra(), d = o || m, [f, g] = Y(!1), [h, p] = Y({
1566
+ const m = Ra(), d = o || m, [f, b] = Y(!1), [h, p] = Y({
1567
1567
  p: t,
1568
1568
  left: 0,
1569
1569
  top: 0,
1570
1570
  caret: 0
1571
- }), c = R(null), y = R(null), b = R(null), w = R(null), k = R(null), x = R(!1), T = R(!1), v = R(!1), N = R(!1), M = R(!1), L = R(!1), E = R(!1), P = R(!1), [D, C] = Y(!0), [S, O] = Y(null), B = R(null), A = R(null), U = me(), K = R({
1571
+ }), c = R(null), y = R(null), g = R(null), w = R(null), k = R(null), x = R(!1), T = R(!1), v = R(!1), N = R(!1), M = R(!1), L = R(!1), E = R(!1), P = R(!1), [D, C] = Y(!0), [S, O] = Y(null), B = R(null), A = R(null), U = me(), K = R({
1572
1572
  id: `q1-tooltip-${U}`,
1573
1573
  dismiss: () => !1,
1574
1574
  cancelPending: () => {
@@ -1609,7 +1609,7 @@ function ro({
1609
1609
  N.current = !1, w.current?.(), w.current = null;
1610
1610
  }
1611
1611
  function $() {
1612
- b.current && (b.current.view.clearTimeout(b.current.id), b.current = null);
1612
+ g.current && (g.current.view.clearTimeout(g.current.id), g.current = null);
1613
1613
  }
1614
1614
  function I() {
1615
1615
  k.current?.(), k.current = null;
@@ -1627,7 +1627,7 @@ function ro({
1627
1627
  return x.current || T.current || v.current || N.current;
1628
1628
  }
1629
1629
  function V(ue, he) {
1630
- z(), !M.current && (E.current = he, P.current = !0, C(ue), g(!0));
1630
+ z(), !M.current && (E.current = he, P.current = !0, C(ue), b(!0));
1631
1631
  }
1632
1632
  function Z({ clearWarm: ue = !1 } = {}) {
1633
1633
  z(), I();
@@ -1636,7 +1636,7 @@ function ro({
1636
1636
  const we = Jt(he);
1637
1637
  ue ? we.warmUntil = 0 : P.current && E.current && (we.warmUntil = Date.now() + La);
1638
1638
  }
1639
- P.current = !1, E.current = !1, g(!1);
1639
+ P.current = !1, E.current = !1, b(!1);
1640
1640
  }
1641
1641
  pe(() => {
1642
1642
  d && (te(), Z({ clearWarm: !0 }));
@@ -1711,9 +1711,9 @@ function ro({
1711
1711
  const he = B.current?.ownerDocument.defaultView;
1712
1712
  if ($(), !he) return;
1713
1713
  const we = he.setTimeout(() => {
1714
- L.current = !1, b.current = null;
1714
+ L.current = !1, g.current = null;
1715
1715
  }, 0);
1716
- if (b.current = { view: he, id: we }, ue.pointerType === "touch") {
1716
+ if (g.current = { view: he, id: we }, ue.pointerType === "touch") {
1717
1717
  ke();
1718
1718
  return;
1719
1719
  }
@@ -1813,27 +1813,27 @@ const Oa = {
1813
1813
  panelData: { "data-info-tip-panel": "true" }
1814
1814
  };
1815
1815
  function oo({ label: e, content: t, parts: r }) {
1816
- const [o, i] = Y(!1), [a, s] = Y(!1), [l, u] = Y(), m = R(null), d = R(null), f = me(), g = me();
1816
+ const [o, i] = Y(!1), [a, s] = Y(!1), [l, u] = Y(), m = R(null), d = R(null), f = me(), b = me();
1817
1817
  ie(() => {
1818
1818
  if (o) {
1819
1819
  d.current?.focus();
1820
1820
  return;
1821
1821
  }
1822
1822
  if (!a) return;
1823
- const b = m.current?.ownerDocument.defaultView;
1824
- if (!b) return;
1823
+ const g = m.current?.ownerDocument.defaultView;
1824
+ if (!g) return;
1825
1825
  m.current?.focus();
1826
- const w = b.requestAnimationFrame(() => s(!1));
1827
- return () => b.cancelAnimationFrame(w);
1826
+ const w = g.requestAnimationFrame(() => s(!1));
1827
+ return () => g.cancelAnimationFrame(w);
1828
1828
  }, [o, a]);
1829
1829
  function h() {
1830
1830
  i(!1);
1831
1831
  }
1832
- function p(b) {
1833
- b.key !== "Escape" || !o || (b.preventDefault(), b.stopPropagation(), h());
1832
+ function p(g) {
1833
+ g.key !== "Escape" || !o || (g.preventDefault(), g.stopPropagation(), h());
1834
1834
  }
1835
- function c(b) {
1836
- !b.isPrimary || b.button !== 0 || u("pointer");
1835
+ function c(g) {
1836
+ !g.isPrimary || g.button !== 0 || u("pointer");
1837
1837
  }
1838
1838
  const y = /* @__PURE__ */ _(
1839
1839
  "button",
@@ -1863,8 +1863,8 @@ function oo({ label: e, content: t, parts: r }) {
1863
1863
  return /* @__PURE__ */ _("span", { className: r.wrap, onKeyDown: p, children: [
1864
1864
  /* @__PURE__ */ n(qa, { disabled: a, children: /* @__PURE__ */ n(ro, { content: t, placement: "top", children: y }) }),
1865
1865
  /* @__PURE__ */ _("span", { id: f, className: r.panel, ...r.panelData, role: "note", hidden: !o, children: [
1866
- /* @__PURE__ */ n("span", { id: g, className: r.content, children: t }),
1867
- /* @__PURE__ */ _("button", { ref: d, type: "button", className: r.close, "aria-label": `关闭${e}说明`, "aria-describedby": g, onClick: h, children: [
1866
+ /* @__PURE__ */ n("span", { id: b, className: r.content, children: t }),
1867
+ /* @__PURE__ */ _("button", { ref: d, type: "button", className: r.close, "aria-label": `关闭${e}说明`, "aria-describedby": b, onClick: h, children: [
1868
1868
  /* @__PURE__ */ n(Ve, { size: r.iconSize, strokeWidth: oe, "aria-hidden": "true" }),
1869
1869
  /* @__PURE__ */ n(Te, {})
1870
1870
  ] })
@@ -1938,12 +1938,12 @@ function ht({
1938
1938
  prefix: m,
1939
1939
  suffix: d,
1940
1940
  prefixStyling: f = !0,
1941
- suffixStyling: g = !0,
1941
+ suffixStyling: b = !0,
1942
1942
  rounded: h,
1943
1943
  wide: p,
1944
1944
  size: c = "md",
1945
1945
  className: y,
1946
- revealable: b,
1946
+ revealable: g,
1947
1947
  revealed: w,
1948
1948
  onRevealedChange: k,
1949
1949
  revealLabel: x = "显示内容",
@@ -1978,7 +1978,7 @@ function ht({
1978
1978
  V = !0, window.cancelAnimationFrame(Z);
1979
1979
  };
1980
1980
  }, [Q, B]);
1981
- const ne = b ? /* @__PURE__ */ n(
1981
+ const ne = g ? /* @__PURE__ */ n(
1982
1982
  Ia,
1983
1983
  {
1984
1984
  type: "button",
@@ -2041,7 +2041,7 @@ function ht({
2041
2041
  "aria-invalid": s || a ? !0 : void 0,
2042
2042
  ...N,
2043
2043
  disabled: v,
2044
- ...b ? { type: Q ? "text" : "password" } : null
2044
+ ...g ? { type: Q ? "text" : "password" } : null
2045
2045
  }
2046
2046
  ), q = m || d || ne || h ? /* @__PURE__ */ _(
2047
2047
  "span",
@@ -2063,7 +2063,7 @@ function ht({
2063
2063
  d ? /* @__PURE__ */ n(
2064
2064
  "span",
2065
2065
  {
2066
- className: `input-control__suffix${g ? "" : " input-control__suffix--plain"}`,
2066
+ className: `input-control__suffix${b ? "" : " input-control__suffix--plain"}`,
2067
2067
  "aria-hidden": "true",
2068
2068
  children: d
2069
2069
  }
@@ -2099,18 +2099,18 @@ function Uc({
2099
2099
  size: m = "md",
2100
2100
  separator: d = !1,
2101
2101
  ref: f,
2102
- label: g,
2102
+ label: b,
2103
2103
  labelHidden: h = !1,
2104
2104
  labelHint: p,
2105
2105
  description: c,
2106
2106
  error: y,
2107
- "aria-label": b,
2107
+ "aria-label": g,
2108
2108
  "aria-labelledby": w,
2109
2109
  "aria-describedby": k
2110
2110
  }) {
2111
2111
  if (typeof r != "string" || !/^[0-9]{0,6}$/.test(r))
2112
2112
  throw new Error("InputOTP value must be a string of up to six ASCII digits.");
2113
- const x = me(), T = e ?? x, v = R(null), N = De(() => rt(v, f), [f]), [M, L] = Y({ start: 0, end: 0, backward: !1 }), [E, P] = Y(null), [D, C] = Y(""), S = R(""), O = R(null), B = R(!1), A = R(null), U = R(null), K = E ?? r, Q = `${T}-format`, G = D || y, X = y || g !== void 0 && (c || G) ? Qe(T, !!G) : void 0, ne = (I) => {
2113
+ const x = me(), T = e ?? x, v = R(null), N = De(() => rt(v, f), [f]), [M, L] = Y({ start: 0, end: 0, backward: !1 }), [E, P] = Y(null), [D, C] = Y(""), S = R(""), O = R(null), B = R(!1), A = R(null), U = R(null), K = E ?? r, Q = `${T}-format`, G = D || y, X = y || b !== void 0 && (c || G) ? Qe(T, !!G) : void 0, ne = (I) => {
2114
2114
  L({ start: I.selectionStart ?? 0, end: I.selectionEnd ?? 0, backward: I.selectionDirection === "backward" });
2115
2115
  };
2116
2116
  pe(() => {
@@ -2162,8 +2162,8 @@ function Uc({
2162
2162
  readOnly: a,
2163
2163
  required: s,
2164
2164
  invalid: l || !!y || !!D,
2165
- errorId: un(u, k, X, g === void 0 && D ? Q : void 0),
2166
- "aria-label": b,
2165
+ errorId: un(u, k, X, b === void 0 && D ? Q : void 0),
2166
+ "aria-label": g,
2167
2167
  "aria-labelledby": w,
2168
2168
  onFocus: (I) => ne(I.currentTarget),
2169
2169
  onSelect: (I) => ne(I.currentTarget),
@@ -2229,13 +2229,13 @@ function Uc({
2229
2229
  }
2230
2230
  )
2231
2231
  ] }),
2232
- g === void 0 && /* @__PURE__ */ n(fn, { controlId: T, error: y }),
2233
- g === void 0 && /* @__PURE__ */ _("span", { id: Q, className: D ? "form-field__message" : "q1-sr-only", role: "status", "aria-atomic": "true", children: [
2232
+ b === void 0 && /* @__PURE__ */ n(fn, { controlId: T, error: y }),
2233
+ b === void 0 && /* @__PURE__ */ _("span", { id: Q, className: D ? "form-field__message" : "q1-sr-only", role: "status", "aria-atomic": "true", children: [
2234
2234
  D && /* @__PURE__ */ n(tt, {}),
2235
2235
  D
2236
2236
  ] })
2237
2237
  ] });
2238
- return g === void 0 ? $ : /* @__PURE__ */ n(ao, { value: !0, children: /* @__PURE__ */ n(dn, { controlId: T, label: g, labelHidden: h, labelHint: p, description: c, error: G, children: $ }) });
2238
+ return b === void 0 ? $ : /* @__PURE__ */ n(ao, { value: !0, children: /* @__PURE__ */ n(dn, { controlId: T, label: b, labelHidden: h, labelHint: p, description: c, error: G, children: $ }) });
2239
2239
  }
2240
2240
  function so({
2241
2241
  value: e,
@@ -2244,17 +2244,17 @@ function so({
2244
2244
  onClear: o,
2245
2245
  preventComposingEscapeDefault: i = !1
2246
2246
  } = {}) {
2247
- const [a, s] = Y(t), l = R(null), u = e ?? a, m = (g) => {
2248
- e === void 0 && s(g), r?.(g);
2247
+ const [a, s] = Y(t), l = R(null), u = e ?? a, m = (b) => {
2248
+ e === void 0 && s(b), r?.(b);
2249
2249
  }, d = () => {
2250
2250
  m(""), l.current?.focus(), o?.();
2251
2251
  };
2252
- return { value: u, setValue: m, inputRef: l, clear: d, onKeyDown: (g) => {
2253
- if ((g.nativeEvent.isComposing || g.keyCode === 229) && g.key === "Escape") {
2254
- i && g.preventDefault();
2252
+ return { value: u, setValue: m, inputRef: l, clear: d, onKeyDown: (b) => {
2253
+ if ((b.nativeEvent.isComposing || b.keyCode === 229) && b.key === "Escape") {
2254
+ i && b.preventDefault();
2255
2255
  return;
2256
2256
  }
2257
- g.key === "Escape" && u && (g.preventDefault(), d());
2257
+ b.key === "Escape" && u && (b.preventDefault(), d());
2258
2258
  } };
2259
2259
  }
2260
2260
  function jc({
@@ -2270,16 +2270,16 @@ function jc({
2270
2270
  ariaLabel: m,
2271
2271
  ref: d,
2272
2272
  className: f,
2273
- onChange: g,
2273
+ onChange: b,
2274
2274
  onKeyDown: h,
2275
2275
  ...p
2276
2276
  }) {
2277
- const { value: c, setValue: y, inputRef: b, clear: w, onKeyDown: k } = so({
2277
+ const { value: c, setValue: y, inputRef: g, clear: w, onKeyDown: k } = so({
2278
2278
  value: r,
2279
2279
  defaultValue: o,
2280
2280
  onValueChange: i,
2281
2281
  onClear: u
2282
- }), x = De(() => rt(b, d), [d]), [T, v] = Y(!1), N = () => v(!1), M = (P) => {
2282
+ }), x = De(() => rt(g, d), [d]), [T, v] = Y(!1), N = () => v(!1), M = (P) => {
2283
2283
  !P.isPrimary || P.button !== 0 || v(!0);
2284
2284
  }, L = (P) => {
2285
2285
  h?.(P), !P.defaultPrevented && !s && k(P);
@@ -2301,7 +2301,7 @@ function jc({
2301
2301
  disabled: a,
2302
2302
  readOnly: s,
2303
2303
  onChange: (P) => {
2304
- y(P.target.value), g?.(P);
2304
+ y(P.target.value), b?.(P);
2305
2305
  },
2306
2306
  onKeyDown: L
2307
2307
  }
@@ -2370,13 +2370,13 @@ function Yc({
2370
2370
  ref: m,
2371
2371
  className: d,
2372
2372
  disabled: f,
2373
- readOnly: g,
2373
+ readOnly: b,
2374
2374
  autoComplete: h = "off",
2375
2375
  spellCheck: p = !1,
2376
2376
  onKeyDown: c,
2377
2377
  ...y
2378
2378
  }) {
2379
- const { value: b, setValue: w, inputRef: k, clear: x, onKeyDown: T } = so({
2379
+ const { value: g, setValue: w, inputRef: k, clear: x, onKeyDown: T } = so({
2380
2380
  value: o,
2381
2381
  defaultValue: i,
2382
2382
  onValueChange: a,
@@ -2384,7 +2384,7 @@ function Yc({
2384
2384
  }), v = De(() => rt(k, m), [m]);
2385
2385
  Mt("SearchInput", !0, k);
2386
2386
  const N = (L) => {
2387
- c?.(L), !L.defaultPrevented && !g && T(L);
2387
+ c?.(L), !L.defaultPrevented && !b && T(L);
2388
2388
  }, M = l === !0 ? /* @__PURE__ */ _(ye, { children: [
2389
2389
  /* @__PURE__ */ n(He, { small: !0, meta: !0 }),
2390
2390
  /* @__PURE__ */ n(He, { small: !0, children: "K" })
@@ -2405,14 +2405,14 @@ function Yc({
2405
2405
  "aria-busy": s || void 0,
2406
2406
  autoComplete: h,
2407
2407
  spellCheck: p,
2408
- value: b,
2408
+ value: g,
2409
2409
  disabled: f,
2410
- readOnly: g,
2410
+ readOnly: b,
2411
2411
  onChange: (L) => w(L.target.value),
2412
2412
  onKeyDown: N
2413
2413
  }
2414
2414
  ),
2415
- b && !f && !g ? /* @__PURE__ */ n(Jr, { className: "search-input__clear", label: "清除搜索", onClick: x }) : M && !f ? /* @__PURE__ */ n("span", { className: "search-input__hint", "aria-hidden": "true", children: M }) : null
2415
+ g && !f && !b ? /* @__PURE__ */ n(Jr, { className: "search-input__clear", label: "清除搜索", onClick: x }) : M && !f ? /* @__PURE__ */ n("span", { className: "search-input__hint", "aria-hidden": "true", children: M }) : null
2416
2416
  ] }),
2417
2417
  /* @__PURE__ */ n("span", { className: "q1-sr-only", role: "status", "aria-live": "polite", "aria-atomic": "true", children: s ? "正在搜索…" : "" })
2418
2418
  ] });
@@ -2430,15 +2430,15 @@ function Xc({
2430
2430
  wide: m,
2431
2431
  size: d = "md",
2432
2432
  className: f,
2433
- maxLength: g,
2433
+ maxLength: b,
2434
2434
  onInput: h,
2435
2435
  ...p
2436
2436
  }) {
2437
- const c = me(), y = e ?? c, b = t === void 0, w = R(null), k = De(() => rt(w, u), [u]);
2438
- Mt("Textarea", b, w);
2437
+ const c = me(), y = e ?? c, g = t === void 0, w = R(null), k = De(() => rt(w, u), [u]);
2438
+ Mt("Textarea", g, w);
2439
2439
  const [x, T] = Y(
2440
2440
  () => typeof p.defaultValue == "string" ? p.defaultValue.length : 0
2441
- ), v = typeof p.value == "string" ? p.value.length : x, N = g !== void 0, M = a || !b && i ? Qe(y, !!a) : void 0, L = ce(
2441
+ ), v = typeof p.value == "string" ? p.value.length : x, N = b !== void 0, M = a || !g && i ? Qe(y, !!a) : void 0, L = ce(
2442
2442
  "form-control",
2443
2443
  "form-control--textarea",
2444
2444
  d !== "md" ? `form-control--${d}` : "",
@@ -2449,7 +2449,7 @@ function Xc({
2449
2449
  id: y,
2450
2450
  ref: k,
2451
2451
  className: L,
2452
- maxLength: g,
2452
+ maxLength: b,
2453
2453
  "aria-describedby": un(l, M),
2454
2454
  "aria-invalid": s || a ? !0 : void 0,
2455
2455
  onInput: N ? (D) => {
@@ -2462,10 +2462,10 @@ function Xc({
2462
2462
  /* @__PURE__ */ _("span", { className: "textarea-control__count", "aria-live": "polite", children: [
2463
2463
  v,
2464
2464
  "/",
2465
- g
2465
+ b
2466
2466
  ] })
2467
2467
  ] }) : E;
2468
- return b ? a ? /* @__PURE__ */ _(ye, { children: [
2468
+ return g ? a ? /* @__PURE__ */ _(ye, { children: [
2469
2469
  P,
2470
2470
  /* @__PURE__ */ n(fn, { controlId: y, error: a })
2471
2471
  ] }) : P : /* @__PURE__ */ n(dn, { controlId: y, label: t, labelHidden: r, labelHint: o, description: i, error: a, wide: m, children: P });
@@ -2487,12 +2487,12 @@ function lo({
2487
2487
  prefix: m,
2488
2488
  suffix: d,
2489
2489
  className: f,
2490
- children: g,
2490
+ children: b,
2491
2491
  value: h,
2492
2492
  defaultValue: p,
2493
2493
  multiple: c,
2494
2494
  "aria-describedby": y,
2495
- "aria-invalid": b,
2495
+ "aria-invalid": g,
2496
2496
  ...w
2497
2497
  }) {
2498
2498
  const k = R(null), x = De(() => rt(k, s), [s]);
@@ -2519,8 +2519,8 @@ function lo({
2519
2519
  value: h,
2520
2520
  defaultValue: p,
2521
2521
  "aria-describedby": za(y, T),
2522
- "aria-invalid": a ? !0 : b,
2523
- children: g
2522
+ "aria-invalid": a ? !0 : g,
2523
+ children: b
2524
2524
  }
2525
2525
  ),
2526
2526
  d ? /* @__PURE__ */ n("span", { className: "select-control__suffix", "aria-hidden": "true", children: d }) : null,
@@ -2574,17 +2574,17 @@ function En({
2574
2574
  "aria-invalid": m,
2575
2575
  "aria-label": d,
2576
2576
  "aria-labelledby": f,
2577
- onClick: g,
2577
+ onClick: b,
2578
2578
  ...h
2579
2579
  }) {
2580
- const p = st(co), c = me(), y = e ?? c, b = t === void 0, w = l === "radio", k = b ? void 0 : `${y}-label`, x = i || !b && o ? Qe(y, !!i) : void 0, T = Ha(u, x), v = i ? !0 : m, N = w ? "control-option__visual control-option__visual--radio" : "control-option__visual", M = R(null), L = R(!!a);
2580
+ const p = st(co), c = me(), y = e ?? c, g = t === void 0, w = l === "radio", k = g ? void 0 : `${y}-label`, x = i || !g && o ? Qe(y, !!i) : void 0, T = Ha(u, x), v = i ? !0 : m, N = w ? "control-option__visual control-option__visual--radio" : "control-option__visual", M = R(null), L = R(!!a);
2581
2581
  L.current = !!a;
2582
2582
  const [E, P] = Y(!1), D = R(null), C = De(() => rt(M, s), [s]);
2583
- Mt(w ? "Radio" : "Checkbox", b, M), ie(() => {
2583
+ Mt(w ? "Radio" : "Checkbox", g, M), ie(() => {
2584
2584
  M.current && (M.current.indeterminate = !w && !!a);
2585
2585
  }, [a, w]);
2586
2586
  function S(K) {
2587
- g?.(K);
2587
+ b?.(K);
2588
2588
  const Q = M.current;
2589
2589
  !w && Q && queueMicrotask(() => {
2590
2590
  Q.isConnected && M.current === Q && (Q.indeterminate = L.current);
@@ -2612,7 +2612,7 @@ function En({
2612
2612
  ...h
2613
2613
  }
2614
2614
  );
2615
- return b ? /* @__PURE__ */ _(ye, { children: [
2615
+ return g ? /* @__PURE__ */ _(ye, { children: [
2616
2616
  /* @__PURE__ */ _(
2617
2617
  "span",
2618
2618
  {
@@ -2690,18 +2690,18 @@ function Zc({
2690
2690
  "aria-describedby": l,
2691
2691
  ...u
2692
2692
  }) {
2693
- const m = me(), d = `${m}-label`, f = r ? `${m}-description` : void 0, [g, h] = Y(!1), p = R(null);
2694
- function c(b) {
2695
- p.current !== null || !b.isPrimary || b.button !== 0 || b.currentTarget.control?.matches(":disabled") || (p.current = b.pointerId, h(!0));
2693
+ const m = me(), d = `${m}-label`, f = r ? `${m}-description` : void 0, [b, h] = Y(!1), p = R(null);
2694
+ function c(g) {
2695
+ p.current !== null || !g.isPrimary || g.button !== 0 || g.currentTarget.control?.matches(":disabled") || (p.current = g.pointerId, h(!0));
2696
2696
  }
2697
- function y(b) {
2698
- b && p.current !== null && b.pointerId !== p.current || (p.current = null, h(!1));
2697
+ function y(g) {
2698
+ g && p.current !== null && g.pointerId !== p.current || (p.current = null, h(!1));
2699
2699
  }
2700
2700
  return /* @__PURE__ */ _(
2701
2701
  "label",
2702
2702
  {
2703
2703
  className: ce("choicebox", `choicebox--${e}`, i),
2704
- "data-pointer-pressed": g ? "true" : void 0,
2704
+ "data-pointer-pressed": b ? "true" : void 0,
2705
2705
  onBlur: () => y(),
2706
2706
  onPointerCancel: y,
2707
2707
  onPointerDown: c,
@@ -2777,17 +2777,17 @@ function Jc({
2777
2777
  description: m,
2778
2778
  error: d,
2779
2779
  form: f,
2780
- id: g,
2780
+ id: b,
2781
2781
  className: h,
2782
2782
  "aria-describedby": p,
2783
2783
  ...c
2784
2784
  }) {
2785
- const y = me(), b = g ?? y, w = o ?? `${b}-name`, k = `${b}-description`, x = `${b}-error`, T = i !== void 0, [v, N] = Y(a), M = T ? i : v, L = [p, m ? k : void 0, d ? x : void 0].filter(Boolean).join(" ") || void 0;
2785
+ const y = me(), g = b ?? y, w = o ?? `${g}-name`, k = `${g}-description`, x = `${g}-error`, T = i !== void 0, [v, N] = Y(a), M = T ? i : v, L = [p, m ? k : void 0, d ? x : void 0].filter(Boolean).join(" ") || void 0;
2786
2786
  return /* @__PURE__ */ _(
2787
2787
  "fieldset",
2788
2788
  {
2789
2789
  ...c,
2790
- id: b,
2790
+ id: g,
2791
2791
  className: ce("radio-group", d ? "radio-group--error" : "", h),
2792
2792
  disabled: l,
2793
2793
  "aria-describedby": L,
@@ -2944,20 +2944,20 @@ function je({
2944
2944
  containerRef: m,
2945
2945
  themeAnchorRef: d,
2946
2946
  initialFocusRef: f,
2947
- initialFocusTiming: g = "deferred",
2947
+ initialFocusTiming: b = "deferred",
2948
2948
  registrationTiming: h = "deferred",
2949
2949
  focusOnOpen: p = !0,
2950
2950
  deferPortalUntilReady: c = !1,
2951
2951
  restoreFocusFallbackCandidates: y,
2952
- onClose: b,
2952
+ onClose: g,
2953
2953
  onEscapeKeyDown: w,
2954
2954
  escapeAction: k,
2955
2955
  restoreFocus: x = !0
2956
2956
  }) {
2957
2957
  const T = R(void 0);
2958
2958
  T.current || (T.current = `q1-overlay-${Math.random().toString(36).slice(2)}`);
2959
- const [v, N] = Y(null), M = R(b), L = R(w), E = R(k), P = R(x), D = R(!1), C = R(null), S = R(null), O = R(null);
2960
- M.current = b, L.current = w, E.current = k, P.current = x, Rt(() => {
2959
+ const [v, N] = Y(null), M = R(g), L = R(w), E = R(k), P = R(x), D = R(!1), C = R(null), S = R(null), O = R(null);
2960
+ M.current = g, L.current = w, E.current = k, P.current = x, Rt(() => {
2961
2961
  if (!t || typeof document > "u") return;
2962
2962
  const X = document, ne = ln(X);
2963
2963
  return N(ne), () => {
@@ -3047,12 +3047,12 @@ function je({
3047
3047
  outsidePointer: i
3048
3048
  });
3049
3049
  }, [r, o, k, e, i]), Rt(() => {
3050
- !e || !p || g !== "layout" || gn(m.current, f);
3051
- }, [m, p, f, g, e, v]), ie(() => {
3052
- if (!e || !p || g !== "deferred") return;
3050
+ !e || !p || b !== "layout" || gn(m.current, f);
3051
+ }, [m, p, f, b, e, v]), ie(() => {
3052
+ if (!e || !p || b !== "deferred") return;
3053
3053
  const X = window.setTimeout(() => gn(m.current, f), 0);
3054
3054
  return () => window.clearTimeout(X);
3055
- }, [m, p, f, g, e, v]);
3055
+ }, [m, p, f, b, e, v]);
3056
3056
  const U = fe((X) => {
3057
3057
  if (s && X.defaultPrevented) return;
3058
3058
  const ne = S.current;
@@ -3083,14 +3083,14 @@ function je({
3083
3083
  return { focusInitialIfTopMost: Q, onKeyDown: U, portal: G, portalRoot: v, requestClose: K };
3084
3084
  }
3085
3085
  function Qa(e, t, r, o, i, a, s) {
3086
- const l = e.getBoundingClientRect().width, u = Math.min(e.scrollHeight, Number.isFinite(s) ? s : 1 / 0), m = t.left - o * 2, d = r.innerWidth - t.right - o * 2, f = i === "right" ? d >= l || d >= m : m < l && d > m, g = Math.max(0, Math.min(u, r.innerHeight - o * 2)), h = f ? t.right + o : t.left - l - o, p = t.top + (a === "end" ? t.height - g : a === "center" ? (t.height - g) / 2 : 0);
3086
+ const l = e.getBoundingClientRect().width, u = Math.min(e.scrollHeight, Number.isFinite(s) ? s : 1 / 0), m = t.left - o * 2, d = r.innerWidth - t.right - o * 2, f = i === "right" ? d >= l || d >= m : m < l && d > m, b = Math.max(0, Math.min(u, r.innerHeight - o * 2)), h = f ? t.right + o : t.left - l - o, p = t.top + (a === "end" ? t.height - b : a === "center" ? (t.height - b) / 2 : 0);
3087
3087
  return Object.assign(e.style, {
3088
3088
  position: "fixed",
3089
3089
  left: `${Math.max(o, Math.min(h, r.innerWidth - l - o))}px`,
3090
- top: `${Math.max(o, Math.min(p, r.innerHeight - g - o))}px`,
3090
+ top: `${Math.max(o, Math.min(p, r.innerHeight - b - o))}px`,
3091
3091
  right: "auto",
3092
3092
  bottom: "auto",
3093
- maxHeight: `${g}px`,
3093
+ maxHeight: `${b}px`,
3094
3094
  overflowY: "auto",
3095
3095
  visibility: "visible"
3096
3096
  }), { side: f ? "right" : "left", align: a };
@@ -3102,9 +3102,9 @@ function ot(e, t, r, o, i = {}) {
3102
3102
  gapToken: l = "--q1-space-1",
3103
3103
  outsidePointer: u = !1,
3104
3104
  present: m = e
3105
- } = i, [d, f] = Y({ align: s, side: "bottom" }), g = R(o);
3106
- g.current = o;
3107
- const { focusInitialIfTopMost: h, onKeyDown: p, portal: c, portalRoot: y, requestClose: b } = je({
3105
+ } = i, [d, f] = Y({ align: s, side: "bottom" }), b = R(o);
3106
+ b.current = o;
3107
+ const { focusInitialIfTopMost: h, onKeyDown: p, portal: c, portalRoot: y, requestClose: g } = je({
3108
3108
  open: e,
3109
3109
  present: m,
3110
3110
  blocking: i.blocking ?? !1,
@@ -3118,7 +3118,7 @@ function ot(e, t, r, o, i = {}) {
3118
3118
  deferPortalUntilReady: !0,
3119
3119
  containerRef: r,
3120
3120
  themeAnchorRef: t,
3121
- onClose: (w) => g.current(w),
3121
+ onClose: (w) => b.current(w),
3122
3122
  registrationTiming: "layout"
3123
3123
  });
3124
3124
  return pe(() => {
@@ -3132,12 +3132,12 @@ function ot(e, t, r, o, i = {}) {
3132
3132
  const v = Number.parseFloat(x.getComputedStyle(k).maxHeight), N = Number.parseFloat(x.getComputedStyle(k).maxWidth);
3133
3133
  function M() {
3134
3134
  if (!w.isConnected || !k.isConnected) {
3135
- g.current();
3135
+ b.current();
3136
3136
  return;
3137
3137
  }
3138
3138
  const A = w.getBoundingClientRect(), U = T?.offset ?? (Number.parseFloat(x.getComputedStyle(w).getPropertyValue(l)) || 0), K = T ? Number.parseFloat(x.getComputedStyle(w).getPropertyValue("--q1-space-3")) || 0 : U;
3139
3139
  if (T?.closeWhenAnchorHidden && (A.bottom <= 0 || A.top >= x.innerHeight || A.right <= 0 || A.left >= x.innerWidth)) {
3140
- g.current("anchor-hidden");
3140
+ b.current("anchor-hidden");
3141
3141
  return;
3142
3142
  }
3143
3143
  if (a === "content" ? (k.style.width = T ? "" : "max-content", k.style.maxWidth = `${Math.min(
@@ -3172,7 +3172,7 @@ function ot(e, t, r, o, i = {}) {
3172
3172
  if (!/(auto|scroll|overlay)/.test(`${K.overflow} ${K.overflowX} ${K.overflowY}`)) continue;
3173
3173
  const Q = U.getBoundingClientRect();
3174
3174
  if (A.bottom <= Q.top || A.top >= Q.bottom || A.right <= Q.left || A.left >= Q.right) {
3175
- g.current("anchor-hidden");
3175
+ b.current("anchor-hidden");
3176
3176
  return;
3177
3177
  }
3178
3178
  }
@@ -3182,7 +3182,7 @@ function ot(e, t, r, o, i = {}) {
3182
3182
  return T ? x.addEventListener("scroll", B, !0) : x.addEventListener("scroll", M, !0), w.ownerDocument.addEventListener("animationend", C, !0), w.ownerDocument.addEventListener("transitionend", C, !0), () => {
3183
3183
  S.disconnect(), O.disconnect(), x.cancelAnimationFrame(L), x.cancelAnimationFrame(E), x.removeEventListener("resize", M), T ? x.removeEventListener("scroll", B, !0) : x.removeEventListener("scroll", M, !0), w.ownerDocument.removeEventListener("animationend", C, !0), w.ownerDocument.removeEventListener("transitionend", C, !0);
3184
3184
  };
3185
- }, [s, l, e, r, y, t, a, i.side, i.popoverLayout?.offset, i.popoverLayout?.fixedSide, i.popoverLayout?.matchWidth, i.popoverLayout?.closeWhenAnchorHidden]), { portalPopup: (w) => c(w), placement: d, onOverlayKeyDown: p, focusInitialIfTopMost: h, portalRoot: y, requestClose: b };
3185
+ }, [s, l, e, r, y, t, a, i.side, i.popoverLayout?.offset, i.popoverLayout?.fixedSide, i.popoverLayout?.matchWidth, i.popoverLayout?.closeWhenAnchorHidden]), { portalPopup: (w) => c(w), placement: d, onOverlayKeyDown: p, focusInitialIfTopMost: h, portalRoot: y, requestClose: g };
3186
3186
  }
3187
3187
  function eu({
3188
3188
  options: e,
@@ -3197,12 +3197,12 @@ function eu({
3197
3197
  size: m = "md",
3198
3198
  disabled: d,
3199
3199
  readOnly: f,
3200
- invalid: g,
3200
+ invalid: b,
3201
3201
  errorId: h,
3202
3202
  error: p,
3203
3203
  emptyText: c = "没有匹配项",
3204
3204
  clearable: y,
3205
- id: b,
3205
+ id: g,
3206
3206
  className: w,
3207
3207
  name: k,
3208
3208
  inputMode: x,
@@ -3254,7 +3254,7 @@ function eu({
3254
3254
  const xe = new MutationObserver(_e);
3255
3255
  return J && xe.observe(J, { attributes: !0, attributeFilter: ["style"] }), () => xe.disconnect();
3256
3256
  }, [ee, U, Ce]);
3257
- const le = s || E === "" ? e : e.filter((J) => J.label.toLowerCase().includes(E.toLowerCase())), ke = ee && !l && le[S] ? `${I}-opt-${S}` : void 0, Se = !!p, qe = !!g || Se, Re = [h, Se ? F : null].filter(Boolean).join(" ") || void 0, ue = {};
3257
+ const le = s || E === "" ? e : e.filter((J) => J.label.toLowerCase().includes(E.toLowerCase())), ke = ee && !l && le[S] ? `${I}-opt-${S}` : void 0, Se = !!p, qe = !!b || Se, Re = [h, Se ? F : null].filter(Boolean).join(" ") || void 0, ue = {};
3258
3258
  for (const [J, ae] of Object.entries(L))
3259
3259
  J.startsWith("data-") && (ue[J] = ae);
3260
3260
  const he = fe(
@@ -3387,7 +3387,7 @@ function eu({
3387
3387
  {
3388
3388
  type: "button",
3389
3389
  ref: A,
3390
- id: b ?? `${I}-input`,
3390
+ id: g ?? `${I}-input`,
3391
3391
  className: "combobox__panel-trigger",
3392
3392
  disabled: d,
3393
3393
  "aria-disabled": f || void 0,
@@ -3413,7 +3413,7 @@ function eu({
3413
3413
  "input",
3414
3414
  {
3415
3415
  ref: he,
3416
- id: b ?? `${I}-input`,
3416
+ id: g ?? `${I}-input`,
3417
3417
  type: "text",
3418
3418
  role: "combobox",
3419
3419
  className: "combobox__input",
@@ -3578,14 +3578,14 @@ function tu({
3578
3578
  fullWidth: u = !1,
3579
3579
  iconOnly: m = !1
3580
3580
  }) {
3581
- const d = me(), f = R([]), g = i !== void 0, [h, p] = Y(() => Ja(e, o)), c = g ? i : h, y = e.reduce((S, O, B) => (O.disabled || S.push(B), S), []), b = y[0] ?? -1, w = e.findIndex((S) => S.value === c && !S.disabled), [k, x] = Y(w >= 0 ? w : b), [T, v] = Y(null);
3581
+ const d = me(), f = R([]), b = i !== void 0, [h, p] = Y(() => Ja(e, o)), c = b ? i : h, y = e.reduce((S, O, B) => (O.disabled || S.push(B), S), []), g = y[0] ?? -1, w = e.findIndex((S) => S.value === c && !S.disabled), [k, x] = Y(w >= 0 ? w : g), [T, v] = Y(null);
3582
3582
  if (ie(() => {
3583
- x((S) => w >= 0 ? w : S >= 0 && !e[S]?.disabled ? S : b);
3584
- }, [w, b, e]), e.length === 0) return null;
3583
+ x((S) => w >= 0 ? w : S >= 0 && !e[S]?.disabled ? S : g);
3584
+ }, [w, g, e]), e.length === 0) return null;
3585
3585
  const N = r ?? d;
3586
3586
  function M(S) {
3587
3587
  const O = e.find((B) => B.value === S);
3588
- !O || O.disabled || (g || p(S), a?.(S));
3588
+ !O || O.disabled || (b || p(S), a?.(S));
3589
3589
  }
3590
3590
  function L(S, O) {
3591
3591
  if (y.length === 0) return -1;
@@ -3660,13 +3660,13 @@ function nu({
3660
3660
  "aria-labelledby": d,
3661
3661
  ariaLabel: f
3662
3662
  }) {
3663
- const [g, h] = Y(t), [p, c] = Y(!1), y = e !== void 0, b = y ? e : g, w = me(), k = me(), x = a ? { "--toggle-on": a } : void 0;
3663
+ const [b, h] = Y(t), [p, c] = Y(!1), y = e !== void 0, g = y ? e : b, w = me(), k = me(), x = a ? { "--toggle-on": a } : void 0;
3664
3664
  return /* @__PURE__ */ _(
3665
3665
  "button",
3666
3666
  {
3667
3667
  type: "button",
3668
3668
  role: "switch",
3669
- "aria-checked": b,
3669
+ "aria-checked": g,
3670
3670
  "aria-label": s ? void 0 : m !== void 0 ? m : f,
3671
3671
  "aria-labelledby": s ? w : d,
3672
3672
  "aria-describedby": s && l ? k : void 0,
@@ -3681,7 +3681,7 @@ function nu({
3681
3681
  onPointerLeave: () => c(!1),
3682
3682
  onBlur: () => c(!1),
3683
3683
  onClick: () => {
3684
- const v = !b;
3684
+ const v = !g;
3685
3685
  y || h(v), r?.(v);
3686
3686
  },
3687
3687
  children: [
@@ -3711,8 +3711,8 @@ const es = {
3711
3711
  removed: { marker: "−", label: "删除行" }
3712
3712
  };
3713
3713
  function iu(e) {
3714
- const { lineNumbers: t = !0, variant: r = "default" } = e, o = r === "flush" && !e.tabs && !e.filename, [i, a] = Y(0), s = e.tabs ? e.tabs[i] ?? e.tabs[0] : void 0, l = s ? s.lines : e.lines ?? [], u = s ? s.filename : e.filename, m = l.map((g) => g.tokens.map((h) => h.text).join("")).join(`
3715
- `), d = l.some((g) => g.state);
3714
+ const { lineNumbers: t = !0, variant: r = "default" } = e, o = r === "flush" && !e.tabs && !e.filename, [i, a] = Y(0), s = e.tabs ? e.tabs[i] ?? e.tabs[0] : void 0, l = s ? s.lines : e.lines ?? [], u = s ? s.filename : e.filename, m = l.map((b) => b.tokens.map((h) => h.text).join("")).join(`
3715
+ `), d = l.some((b) => b.state);
3716
3716
  let f = 0;
3717
3717
  return /* @__PURE__ */ _(
3718
3718
  "div",
@@ -3720,17 +3720,17 @@ function iu(e) {
3720
3720
  className: `codeblock${r === "flush" ? " codeblock--flush" : ""}${o ? " codeblock--floating-copy" : ""}${t ? "" : " codeblock--without-line-numbers"}${d ? " codeblock--annotated" : ""}`,
3721
3721
  children: [
3722
3722
  o ? /* @__PURE__ */ n(Xn, { className: "codeblock__copy", value: m, label: "复制代码", successMessage: "已复制代码", size: 14 }) : /* @__PURE__ */ _("header", { className: "codeblock__header", children: [
3723
- e.tabs ? /* @__PURE__ */ n("span", { className: "codeblock__tabs", children: e.tabs.map((g, h) => /* @__PURE__ */ n(
3723
+ e.tabs ? /* @__PURE__ */ n("span", { className: "codeblock__tabs", children: e.tabs.map((b, h) => /* @__PURE__ */ n(
3724
3724
  "button",
3725
3725
  {
3726
3726
  type: "button",
3727
3727
  className: `codeblock__tab${h === i ? " codeblock__tab--active" : ""}`,
3728
3728
  "aria-pressed": h === i,
3729
- "aria-label": `切换到 ${g.label} 示例`,
3729
+ "aria-label": `切换到 ${b.label} 示例`,
3730
3730
  onClick: () => a(h),
3731
- children: g.label
3731
+ children: b.label
3732
3732
  },
3733
- g.label
3733
+ b.label
3734
3734
  )) }) : u ? /* @__PURE__ */ _("span", { className: "codeblock__filename", children: [
3735
3735
  /* @__PURE__ */ n(Vn, { size: 14, strokeWidth: oe, "aria-hidden": "true" }),
3736
3736
  u
@@ -3750,13 +3750,13 @@ function iu(e) {
3750
3750
  /* @__PURE__ */ n(Vn, { size: 14, strokeWidth: oe, "aria-hidden": "true" }),
3751
3751
  s.filename
3752
3752
  ] }) : null,
3753
- /* @__PURE__ */ n("pre", { className: "codeblock__pre", children: /* @__PURE__ */ n("code", { children: l.map((g, h) => {
3754
- g.state !== "removed" && (f += 1);
3755
- const p = g.state ? es[g.state] : void 0;
3753
+ /* @__PURE__ */ n("pre", { className: "codeblock__pre", children: /* @__PURE__ */ n("code", { children: l.map((b, h) => {
3754
+ b.state !== "removed" && (f += 1);
3755
+ const p = b.state ? es[b.state] : void 0;
3756
3756
  return /* @__PURE__ */ _(
3757
3757
  "span",
3758
3758
  {
3759
- className: `codeblock__line${g.state ? ` codeblock__line--${g.state}` : ""}`,
3759
+ className: `codeblock__line${b.state ? ` codeblock__line--${b.state}` : ""}`,
3760
3760
  children: [
3761
3761
  p ? /* @__PURE__ */ _(ye, { children: [
3762
3762
  /* @__PURE__ */ n("span", { className: "codeblock__marker", "aria-hidden": "true", children: p.marker }),
@@ -3765,8 +3765,8 @@ function iu(e) {
3765
3765
  ":"
3766
3766
  ] })
3767
3767
  ] }) : null,
3768
- t ? /* @__PURE__ */ n("span", { className: "codeblock__ln", "aria-hidden": "true", children: g.state === "removed" ? null : f }) : null,
3769
- /* @__PURE__ */ n("span", { className: "codeblock__code", children: /* @__PURE__ */ n(bo, { tokens: g.tokens }) })
3768
+ t ? /* @__PURE__ */ n("span", { className: "codeblock__ln", "aria-hidden": "true", children: b.state === "removed" ? null : f }) : null,
3769
+ /* @__PURE__ */ n("span", { className: "codeblock__code", children: /* @__PURE__ */ n(bo, { tokens: b.tokens }) })
3770
3770
  ]
3771
3771
  },
3772
3772
  h
@@ -3784,14 +3784,14 @@ function au({
3784
3784
  defaultValue: i,
3785
3785
  onValueChange: a
3786
3786
  }) {
3787
- const s = me(), l = e.filter((D) => !D.disabled), u = l[0], m = o !== void 0, [d, f] = Y(i ?? u?.id ?? ""), h = (l.find((D) => D.id === (m ? o : d)) ?? u)?.id ?? "", p = R(/* @__PURE__ */ new Map()), c = R(null), y = R(null), [b, w] = Y(""), [k, x] = Y("keyboard"), T = b ? l.some((D) => D.id === b) : !1;
3787
+ const s = me(), l = e.filter((D) => !D.disabled), u = l[0], m = o !== void 0, [d, f] = Y(i ?? u?.id ?? ""), h = (l.find((D) => D.id === (m ? o : d)) ?? u)?.id ?? "", p = R(/* @__PURE__ */ new Map()), c = R(null), y = R(null), [g, w] = Y(""), [k, x] = Y("keyboard"), T = g ? l.some((D) => D.id === g) : !1;
3788
3788
  pe(() => {
3789
3789
  if (m || d === h) return;
3790
3790
  const D = y.current === d;
3791
3791
  f(h), D && h ? (p.current.get(h)?.focus(), y.current = h) : D && (y.current = null);
3792
3792
  }, [m, h, d]), pe(() => {
3793
- b && !T && w("");
3794
- }, [b, T]);
3793
+ g && !T && w("");
3794
+ }, [g, T]);
3795
3795
  function v(D) {
3796
3796
  w((C) => C === D ? "" : C);
3797
3797
  }
@@ -3865,7 +3865,7 @@ function au({
3865
3865
  "aria-describedby": C,
3866
3866
  "aria-selected": D.id === h,
3867
3867
  className: "tabs-control__tab",
3868
- "data-pointer-pressed": b === D.id ? "true" : void 0,
3868
+ "data-pointer-pressed": g === D.id ? "true" : void 0,
3869
3869
  disabled: D.disabled,
3870
3870
  id: `${s}-tab-${D.id}`,
3871
3871
  onBlur: () => v(D.id),
@@ -3941,20 +3941,20 @@ function lu({
3941
3941
  headingLevel: o = 3,
3942
3942
  children: i
3943
3943
  }) {
3944
- const a = st(go), s = me(), [l, u] = Y(t ?? !1), [m, d] = Y(), [f, g] = Y(!1), h = R(null), p = R(null);
3944
+ const a = st(go), s = me(), [l, u] = Y(t ?? !1), [m, d] = Y(), [f, b] = Y(!1), h = R(null), p = R(null);
3945
3945
  pe(() => {
3946
3946
  a && t && a.setOpenId(s);
3947
3947
  }, []);
3948
- const c = a ? a.openId === s : l, y = a?.inputModality ?? m, b = R(c), w = typeof e == "function" ? e(c) : e, k = o === null ? "div" : `h${o}`;
3948
+ const c = a ? a.openId === s : l, y = a?.inputModality ?? m, g = R(c), w = typeof e == "function" ? e(c) : e, k = o === null ? "div" : `h${o}`;
3949
3949
  pe(() => {
3950
3950
  const N = p.current?.contains(document.activeElement) ?? !1;
3951
- b.current && !c && N && h.current?.focus(), b.current = c;
3951
+ g.current && !c && N && h.current?.focus(), g.current = c;
3952
3952
  }, [c]);
3953
3953
  const x = () => {
3954
3954
  a ? a.setOpenId(c ? null : s) : u((N) => !N);
3955
3955
  }, T = (N) => {
3956
- !N.isPrimary || N.button !== 0 || (d("pointer"), a?.setInputModality("pointer"), g(!0));
3957
- }, v = () => g(!1);
3956
+ !N.isPrimary || N.button !== 0 || (d("pointer"), a?.setInputModality("pointer"), b(!0));
3957
+ }, v = () => b(!1);
3958
3958
  return /* @__PURE__ */ _("div", { className: `collapse${r ? " collapse--small" : ""}`, "data-input-modality": y, children: [
3959
3959
  /* @__PURE__ */ n(k, { className: "collapse__heading", children: /* @__PURE__ */ _(
3960
3960
  "button",
@@ -4003,7 +4003,7 @@ function ts() {
4003
4003
  return /Mac|iPhone|iPad|iPod/.test(navigator.platform) ? "⌘K" : "Ctrl K";
4004
4004
  }
4005
4005
  function cu({ sections: e, triggerLabel: t = "打开命令面板", hotkey: r }) {
4006
- const o = me(), i = `${o}-dialog`, a = `${o}-listbox`, [s, l] = Y(!1), [u, m] = Y(""), [d, f] = Y(0), [g, h] = Y(!1), [p, c] = Y(), [y, b] = Y("Ctrl K"), w = R(null), k = R(null), x = R(null), T = R(null), v = De(() => {
4006
+ const o = me(), i = `${o}-dialog`, a = `${o}-listbox`, [s, l] = Y(!1), [u, m] = Y(""), [d, f] = Y(0), [b, h] = Y(!1), [p, c] = Y(), [y, g] = Y("Ctrl K"), w = R(null), k = R(null), x = R(null), T = R(null), v = De(() => {
4007
4007
  const A = u.trim().toLowerCase();
4008
4008
  let U = 0;
4009
4009
  return e.map((K, Q) => ({
@@ -4036,7 +4036,7 @@ function cu({ sections: e, triggerLabel: t = "打开命令面板", hotkey: r })
4036
4036
  const A = () => c(void 0);
4037
4037
  return window.addEventListener("blur", A), () => window.removeEventListener("blur", A);
4038
4038
  }, [s]), ie(() => {
4039
- r && b(ts());
4039
+ r && g(ts());
4040
4040
  }, [r]), ie(() => {
4041
4041
  if (!r) return;
4042
4042
  function A(U) {
@@ -4144,7 +4144,7 @@ function cu({ sections: e, triggerLabel: t = "打开命令面板", hotkey: r })
4144
4144
  ref: x,
4145
4145
  role: "listbox",
4146
4146
  "aria-label": "命令",
4147
- "data-command-menu-pointer-navigation": g ? "true" : void 0,
4147
+ "data-command-menu-pointer-navigation": b ? "true" : void 0,
4148
4148
  children: v.length > 0 ? v.map((A) => {
4149
4149
  const U = `${o}-section-${A.sectionIndex}`;
4150
4150
  return /* @__PURE__ */ _(
@@ -4224,10 +4224,10 @@ function uu({
4224
4224
  emptyTitle: m = "没有找到结果",
4225
4225
  clearQueryLabel: d,
4226
4226
  footer: f,
4227
- onEscapeKeyDown: g,
4227
+ onEscapeKeyDown: b,
4228
4228
  onInputKeyDown: h
4229
4229
  }) {
4230
- const p = me(), c = `${p}-dialog`, y = `${p}-listbox`, b = R(null), w = R(null), k = R(null), x = R(null), T = R(r), v = De(
4230
+ const p = me(), c = `${p}-dialog`, y = `${p}-listbox`, g = R(null), w = R(null), k = R(null), x = R(null), T = R(r), v = De(
4231
4231
  () => i.flatMap(
4232
4232
  (I, q) => I.items.flatMap(
4233
4233
  (V, Z) => V.disabled ? [] : [{ key: rr(I.id, V.id), optionId: or(p, q, Z), sectionId: I.id, item: V }]
@@ -4235,7 +4235,7 @@ function uu({
4235
4235
  ),
4236
4236
  [p, i]
4237
4237
  ), [N, M] = Y(), [L, E] = Y(!1), [P, D] = Y(), C = R(null), S = v.findIndex((I) => I.key === N), O = S === -1 ? void 0 : v[S], B = i.reduce((I, q) => I + q.items.length, 0), A = i.some((I) => Ze(I.status)), U = i.flatMap((I, q) => I.items.length > 0 ? [`${p}-group-${q}`] : []), K = fe((I) => {
4238
- b.current?.classList.remove("search-dialog__trigger-control"), b.current = I, I?.classList.add("search-dialog__trigger-control");
4238
+ g.current?.classList.remove("search-dialog__trigger-control"), g.current = I, I?.classList.add("search-dialog__trigger-control");
4239
4239
  }, []);
4240
4240
  ie(() => {
4241
4241
  const I = T.current !== r;
@@ -4258,15 +4258,15 @@ function uu({
4258
4258
  function Q() {
4259
4259
  E(!1), D(void 0), t(!1);
4260
4260
  }
4261
- const G = fe(() => [b.current], []), { onKeyDown: X, portal: ne } = je({
4261
+ const G = fe(() => [g.current], []), { onKeyDown: X, portal: ne } = je({
4262
4262
  open: e,
4263
4263
  blocking: !0,
4264
4264
  containerRef: w,
4265
- themeAnchorRef: b,
4265
+ themeAnchorRef: g,
4266
4266
  initialFocusRef: x,
4267
4267
  restoreFocusFallbackCandidates: G,
4268
4268
  onClose: Q,
4269
- onEscapeKeyDown: g
4269
+ onEscapeKeyDown: b
4270
4270
  });
4271
4271
  function z(I) {
4272
4272
  if (v.length === 0) return;
@@ -4464,36 +4464,36 @@ function rs({
4464
4464
  onConfirm: r,
4465
4465
  inputRef: o
4466
4466
  }) {
4467
- const [i, a] = Y(null), [s, l] = Y(!1), u = R(!0), m = R(e), d = R(0), f = R(!1), g = R(!1);
4467
+ const [i, a] = Y(null), [s, l] = Y(!1), u = R(!0), m = R(e), d = R(0), f = R(!1), b = R(!1);
4468
4468
  ie(() => (u.current = !0, () => {
4469
4469
  u.current = !1, d.current += 1, f.current = !1;
4470
4470
  }), []), ie(() => {
4471
4471
  m.current = e, d.current += 1, f.current = !1, l(!1), e && a(null);
4472
4472
  }, [e]), pe(() => {
4473
- !i || s || !g.current || (g.current = !1, o.current?.focus());
4473
+ !i || s || !b.current || (b.current = !1, o.current?.focus());
4474
4474
  }, [i, o, s]);
4475
4475
  const h = fe(() => {
4476
4476
  t(), queueMicrotask(() => {
4477
4477
  m.current && (f.current = !1);
4478
4478
  });
4479
4479
  }, [t]), p = fe((y) => {
4480
- f.current = !1, g.current = !0, l(!1), a(y);
4480
+ f.current = !1, b.current = !0, l(!1), a(y);
4481
4481
  }, []), c = fe(() => {
4482
4482
  if (!m.current || f.current) return;
4483
4483
  const y = d.current;
4484
4484
  f.current = !0;
4485
- let b;
4485
+ let g;
4486
4486
  try {
4487
- b = r();
4487
+ g = r();
4488
4488
  } catch {
4489
4489
  p(ir);
4490
4490
  return;
4491
4491
  }
4492
- if (!ns(b)) {
4493
- b ? (f.current = !1, g.current = !0, a(b)) : h();
4492
+ if (!ns(g)) {
4493
+ g ? (f.current = !1, b.current = !0, a(g)) : h();
4494
4494
  return;
4495
4495
  }
4496
- l(!0), b.then(
4496
+ l(!0), g.then(
4497
4497
  (w) => {
4498
4498
  !u.current || !m.current || d.current !== y || (w ? p(w) : (l(!1), h()));
4499
4499
  },
@@ -4523,15 +4523,15 @@ function os({
4523
4523
  dialogRef: r,
4524
4524
  backdropRef: o
4525
4525
  }) {
4526
- const i = R("keyboard"), a = R(e), s = R(t), [l, u] = Y(e), [m, d] = Y("keyboard"), g = e && !a.current ? i.current : m, h = fe(() => {
4526
+ const i = R("keyboard"), a = R(e), s = R(t), [l, u] = Y(e), [m, d] = Y("keyboard"), b = e && !a.current ? i.current : m, h = fe(() => {
4527
4527
  u(!1), d("keyboard");
4528
4528
  }, []), p = fe((c) => {
4529
4529
  i.current = c, d(c);
4530
4530
  }, []);
4531
4531
  return ie(() => {
4532
4532
  if (typeof document > "u") return;
4533
- function c(b) {
4534
- b.isPrimary && p("pointer");
4533
+ function c(g) {
4534
+ g.isPrimary && p("pointer");
4535
4535
  }
4536
4536
  function y() {
4537
4537
  p("keyboard");
@@ -4543,7 +4543,7 @@ function os({
4543
4543
  a.current = e, e && (s.current = t, d(i.current), u(!0));
4544
4544
  }, [e, t]), pe(() => {
4545
4545
  if (e || !l) return;
4546
- if (g !== "pointer" || !r.current) {
4546
+ if (b !== "pointer" || !r.current) {
4547
4547
  h();
4548
4548
  return;
4549
4549
  }
@@ -4557,10 +4557,10 @@ function os({
4557
4557
  }
4558
4558
  const y = window.setTimeout(h, c + 50);
4559
4559
  return () => window.clearTimeout(y);
4560
- }, [o, r, h, e, l, g]), {
4560
+ }, [o, r, h, e, l, b]), {
4561
4561
  finishVisualClose: h,
4562
4562
  rememberInput: p,
4563
- resolvedMotion: g,
4563
+ resolvedMotion: b,
4564
4564
  visualPresent: e || l,
4565
4565
  visualSnapshot: e ? t : s.current
4566
4566
  };
@@ -4577,7 +4577,7 @@ function du({
4577
4577
  loading: u,
4578
4578
  onConfirm: m
4579
4579
  }) {
4580
- const [d, f] = Y(""), g = R(null), h = R(null), p = R(null), c = me(), y = me(), b = me(), w = me(), { clearError: k, error: x, pending: T, submit: v } = rs({
4580
+ const [d, f] = Y(""), b = R(null), h = R(null), p = R(null), c = me(), y = me(), g = me(), w = me(), { clearError: k, error: x, pending: T, submit: v } = rs({
4581
4581
  open: e,
4582
4582
  onClose: t,
4583
4583
  onConfirm: m,
@@ -4598,7 +4598,7 @@ function du({
4598
4598
  verificationLabel: a,
4599
4599
  verificationPhrase: s
4600
4600
  },
4601
- dialogRef: g,
4601
+ dialogRef: b,
4602
4602
  backdropRef: h
4603
4603
  }), { onKeyDown: S, portal: O } = je({
4604
4604
  open: e,
@@ -4606,14 +4606,14 @@ function du({
4606
4606
  blocking: !0,
4607
4607
  dismissable: !N,
4608
4608
  outsidePointer: !N,
4609
- containerRef: g,
4609
+ containerRef: b,
4610
4610
  initialFocusRef: p,
4611
4611
  onClose: t
4612
4612
  });
4613
4613
  if (ie(() => {
4614
4614
  e && (f(""), k());
4615
4615
  }, [k, e]), pe(() => {
4616
- const G = g.current, X = document.activeElement;
4616
+ const G = b.current, X = document.activeElement;
4617
4617
  !e || !N || !G || X instanceof HTMLElement && G.contains(X) && !X.matches(":disabled") || G.focus();
4618
4618
  }, [N, e]), !D) return null;
4619
4619
  const B = C.title, A = C.description, U = C.verificationLabel, K = C.verificationPhrase;
@@ -4651,7 +4651,7 @@ function du({
4651
4651
  "aria-labelledby": c,
4652
4652
  "aria-describedby": typeof A == "string" ? y : void 0,
4653
4653
  "aria-busy": N || void 0,
4654
- ref: g,
4654
+ ref: b,
4655
4655
  tabIndex: -1,
4656
4656
  inert: e ? void 0 : !0,
4657
4657
  onTransitionEnd: (G) => {
@@ -4665,7 +4665,7 @@ function du({
4665
4665
  /* @__PURE__ */ n(It, { size: 15, strokeWidth: oe, "aria-hidden": "true" }),
4666
4666
  /* @__PURE__ */ n("span", { children: C.irreversibleDescription })
4667
4667
  ] }) : null,
4668
- /* @__PURE__ */ _("label", { className: "destructive-modal__prompt", id: b, htmlFor: `${b}-input`, children: [
4668
+ /* @__PURE__ */ _("label", { className: "destructive-modal__prompt", id: g, htmlFor: `${g}-input`, children: [
4669
4669
  "请输入",
4670
4670
  U,
4671
4671
  "「",
@@ -4676,9 +4676,9 @@ function du({
4676
4676
  "input",
4677
4677
  {
4678
4678
  ref: p,
4679
- id: `${b}-input`,
4679
+ id: `${g}-input`,
4680
4680
  className: "modal-input destructive-modal__input",
4681
- "aria-labelledby": b,
4681
+ "aria-labelledby": g,
4682
4682
  "aria-describedby": x ? w : void 0,
4683
4683
  disabled: N,
4684
4684
  value: d,
@@ -4758,7 +4758,7 @@ function ls({
4758
4758
  panelRef: r,
4759
4759
  backdropRef: o
4760
4760
  }) {
4761
- const i = R("keyboard"), a = R(e), s = R(t), [l, u] = Y(e), [m, d] = Y("keyboard"), g = e && !a.current ? i.current : m, h = fe(() => {
4761
+ const i = R("keyboard"), a = R(e), s = R(t), [l, u] = Y(e), [m, d] = Y("keyboard"), b = e && !a.current ? i.current : m, h = fe(() => {
4762
4762
  u(!1), d("keyboard");
4763
4763
  }, []), p = fe((c) => {
4764
4764
  i.current = c, d(c);
@@ -4777,13 +4777,13 @@ function ls({
4777
4777
  a.current = e, e && (s.current = t, d(i.current), u(!0));
4778
4778
  }, [e, t]), pe(() => {
4779
4779
  if (e || !l) return;
4780
- if (g !== "pointer" || !r.current) {
4780
+ if (b !== "pointer" || !r.current) {
4781
4781
  h();
4782
4782
  return;
4783
4783
  }
4784
- const c = Math.max(0, ...[r.current, o.current].map((b) => {
4785
- if (!b) return 0;
4786
- const w = getComputedStyle(b), k = w.transitionDuration.split(",").map((v) => Number.parseFloat(v) * (v.trim().endsWith("ms") ? 1 : 1e3)), x = w.transitionDelay.split(",").map((v) => Number.parseFloat(v) * (v.trim().endsWith("ms") ? 1 : 1e3)), T = Math.max(k.length, x.length);
4784
+ const c = Math.max(0, ...[r.current, o.current].map((g) => {
4785
+ if (!g) return 0;
4786
+ const w = getComputedStyle(g), k = w.transitionDuration.split(",").map((v) => Number.parseFloat(v) * (v.trim().endsWith("ms") ? 1 : 1e3)), x = w.transitionDelay.split(",").map((v) => Number.parseFloat(v) * (v.trim().endsWith("ms") ? 1 : 1e3)), T = Math.max(k.length, x.length);
4787
4787
  return Math.max(0, ...Array.from(
4788
4788
  { length: T },
4789
4789
  (v, N) => k[N % k.length] + x[N % x.length]
@@ -4795,10 +4795,10 @@ function ls({
4795
4795
  }
4796
4796
  const y = window.setTimeout(h, c + 50);
4797
4797
  return () => window.clearTimeout(y);
4798
- }, [o, h, e, r, l, g]), {
4798
+ }, [o, h, e, r, l, b]), {
4799
4799
  finishVisualClose: h,
4800
4800
  rememberInput: p,
4801
- resolvedMotion: g,
4801
+ resolvedMotion: b,
4802
4802
  visualPresent: e || l,
4803
4803
  visualSnapshot: e ? t : s.current
4804
4804
  };
@@ -4821,7 +4821,7 @@ function fu({
4821
4821
  }, [e]);
4822
4822
  const {
4823
4823
  finishVisualClose: f,
4824
- rememberInput: g,
4824
+ rememberInput: b,
4825
4825
  resolvedMotion: h,
4826
4826
  visualPresent: p,
4827
4827
  visualSnapshot: c
@@ -4830,7 +4830,7 @@ function fu({
4830
4830
  snapshot: { title: r, children: o, footer: i, height: a },
4831
4831
  panelRef: l,
4832
4832
  backdropRef: s
4833
- }), { onKeyDown: y, portal: b, requestClose: w } = je({
4833
+ }), { onKeyDown: y, portal: g, requestClose: w } = je({
4834
4834
  open: e,
4835
4835
  present: p,
4836
4836
  blocking: !0,
@@ -4847,7 +4847,7 @@ function fu({
4847
4847
  }
4848
4848
  function x(L) {
4849
4849
  if (u.current || !e || !l.current) return;
4850
- g("pointer");
4850
+ b("pointer");
4851
4851
  const E = Math.max(0, cs(l.current));
4852
4852
  l.current.dataset.dragging = "true", l.current.style.transform = `translateY(${E}px)`, u.current = as(L.pointerId, L.clientY, L.timeStamp, E), m.current = !1, L.currentTarget.setPointerCapture(L.pointerId);
4853
4853
  }
@@ -4867,18 +4867,18 @@ function fu({
4867
4867
  u.current?.pointerId === L.pointerId && (k(), m.current = !1);
4868
4868
  }
4869
4869
  const M = c.height ? { maxHeight: `min(${c.height}px, calc(100dvh - env(safe-area-inset-top, 0px)))` } : void 0;
4870
- return b(
4870
+ return g(
4871
4871
  /* @__PURE__ */ _(
4872
4872
  "div",
4873
4873
  {
4874
4874
  className: "drawer",
4875
4875
  "data-state": e ? "open" : "closed",
4876
4876
  onKeyDownCapture: () => {
4877
- g("keyboard");
4877
+ b("keyboard");
4878
4878
  },
4879
4879
  onKeyDown: y,
4880
4880
  onPointerDownCapture: () => {
4881
- g("pointer");
4881
+ b("pointer");
4882
4882
  },
4883
4883
  children: [
4884
4884
  /* @__PURE__ */ n(
@@ -5099,7 +5099,7 @@ function _u({
5099
5099
  onSubmit: i,
5100
5100
  disabled: a = !1
5101
5101
  }) {
5102
- const [s, l] = Y(r), [u, m] = Y(r), [d, f] = Y("keyboard"), [g, h] = Y(null), [p, c] = $r(ms, void 0, us), y = R(null), b = R(null), w = R(null), k = R([]), x = R(!1), T = R(0), v = R(!1), N = R(!0), M = R("keyboard"), L = me(), E = me(), P = me(), D = me(), C = p.status === "pending", S = a || C;
5102
+ const [s, l] = Y(r), [u, m] = Y(r), [d, f] = Y("keyboard"), [b, h] = Y(null), [p, c] = $r(ms, void 0, us), y = R(null), g = R(null), w = R(null), k = R([]), x = R(!1), T = R(0), v = R(!1), N = R(!0), M = R("keyboard"), L = me(), E = me(), P = me(), D = me(), C = p.status === "pending", S = a || C;
5103
5103
  ie(() => (N.current = !0, () => {
5104
5104
  N.current = !1, T.current += 1;
5105
5105
  }), []), ie(() => {
@@ -5116,7 +5116,7 @@ function _u({
5116
5116
  function I(q) {
5117
5117
  if (q.key !== "Escape") return;
5118
5118
  const V = document.activeElement;
5119
- V !== y.current && !b.current?.contains(V) || (q.preventDefault(), B("keyboard"));
5119
+ V !== y.current && !g.current?.contains(V) || (q.preventDefault(), B("keyboard"));
5120
5120
  }
5121
5121
  return document.addEventListener("keydown", I), () => document.removeEventListener("keydown", I);
5122
5122
  }, [r, s]), ie(() => {
@@ -5163,7 +5163,7 @@ function _u({
5163
5163
  const X = ut.findIndex((I) => I.value === p.draft.rating), ne = X === -1 ? 0 : X, z = i ? p.error === "validation" ? "请选择评分或填写反馈" : p.error === "submission" ? "无法发送反馈,请重试。" : p.status === "success" ? "已收到反馈" : "" : "暂时无法发送反馈。", te = /* @__PURE__ */ _(
5164
5164
  "form",
5165
5165
  {
5166
- ref: b,
5166
+ ref: g,
5167
5167
  className: "feedback__panel",
5168
5168
  id: L,
5169
5169
  "data-state": s ? "open" : "closed",
@@ -5192,7 +5192,7 @@ function _u({
5192
5192
  className: "feedback__emotion",
5193
5193
  "aria-label": q,
5194
5194
  "aria-checked": p.draft.rating === I,
5195
- "data-pointer-pressed": g === I || void 0,
5195
+ "data-pointer-pressed": b === I || void 0,
5196
5196
  tabIndex: Z === ne ? 0 : -1,
5197
5197
  disabled: S,
5198
5198
  onPointerDown: () => {
@@ -5355,12 +5355,12 @@ function vu({
5355
5355
  const c = [];
5356
5356
  return vo(e, 1, "", o, c), c;
5357
5357
  }, [e, o]), f = d.some((c) => c.path === a) ? a : d[0]?.path ?? "";
5358
- function g(c) {
5358
+ function b(c) {
5359
5359
  s(c), m.current.get(c)?.focus();
5360
5360
  }
5361
5361
  function h(c, y) {
5362
- i((b) => {
5363
- const w = new Set(b);
5362
+ i((g) => {
5363
+ const w = new Set(g);
5364
5364
  return y ?? !w.has(c) ? w.add(c) : w.delete(c), w;
5365
5365
  });
5366
5366
  }
@@ -5368,8 +5368,8 @@ function vu({
5368
5368
  u("keyboard");
5369
5369
  const y = d.findIndex((w) => w.path === f);
5370
5370
  if (y === -1) return;
5371
- const b = d[y];
5372
- c.key === "ArrowDown" ? (c.preventDefault(), y < d.length - 1 && g(d[y + 1].path)) : c.key === "ArrowUp" ? (c.preventDefault(), y > 0 && g(d[y - 1].path)) : c.key === "ArrowRight" ? (c.preventDefault(), b.hasChildren && !o.has(b.path) ? h(b.path, !0) : b.hasChildren && y < d.length - 1 && g(d[y + 1].path)) : c.key === "ArrowLeft" ? (c.preventDefault(), b.hasChildren && o.has(b.path) ? h(b.path, !1) : b.parentPath && g(b.parentPath)) : c.key === "Home" ? (c.preventDefault(), g(d[0].path)) : c.key === "End" ? (c.preventDefault(), g(d[d.length - 1].path)) : (c.key === "Enter" || c.key === " ") && (c.preventDefault(), b.hasChildren && h(b.path));
5371
+ const g = d[y];
5372
+ c.key === "ArrowDown" ? (c.preventDefault(), y < d.length - 1 && b(d[y + 1].path)) : c.key === "ArrowUp" ? (c.preventDefault(), y > 0 && b(d[y - 1].path)) : c.key === "ArrowRight" ? (c.preventDefault(), g.hasChildren && !o.has(g.path) ? h(g.path, !0) : g.hasChildren && y < d.length - 1 && b(d[y + 1].path)) : c.key === "ArrowLeft" ? (c.preventDefault(), g.hasChildren && o.has(g.path) ? h(g.path, !1) : g.parentPath && b(g.parentPath)) : c.key === "Home" ? (c.preventDefault(), b(d[0].path)) : c.key === "End" ? (c.preventDefault(), b(d[d.length - 1].path)) : (c.key === "Enter" || c.key === " ") && (c.preventDefault(), g.hasChildren && h(g.path));
5373
5373
  }
5374
5374
  return /* @__PURE__ */ n(
5375
5375
  "ul",
@@ -5387,7 +5387,7 @@ function vu({
5387
5387
  c.currentTarget.contains(c.relatedTarget) || u("keyboard");
5388
5388
  },
5389
5389
  children: d.map((c) => {
5390
- const y = o.has(c.path), b = y ? Ci : Di;
5390
+ const y = o.has(c.path), g = y ? Ci : Di;
5391
5391
  return /* @__PURE__ */ n(
5392
5392
  "li",
5393
5393
  {
@@ -5405,11 +5405,11 @@ function vu({
5405
5405
  style: { paddingLeft: `calc(${c.level} * var(--q1-space-4))` },
5406
5406
  onFocus: () => s(c.path),
5407
5407
  onClick: (w) => {
5408
- w.stopPropagation(), u(w.detail > 0 ? "pointer" : "keyboard"), g(c.path), c.hasChildren && h(c.path);
5408
+ w.stopPropagation(), u(w.detail > 0 ? "pointer" : "keyboard"), b(c.path), c.hasChildren && h(c.path);
5409
5409
  },
5410
5410
  children: /* @__PURE__ */ _("span", { className: "file-tree__row", children: [
5411
5411
  c.hasChildren ? /* @__PURE__ */ n(Le, { className: `file-tree__chevron${y ? " file-tree__chevron--open" : ""}`, size: 14, strokeWidth: oe, "aria-hidden": "true" }) : /* @__PURE__ */ n("span", { className: "file-tree__chevron-spacer", "aria-hidden": "true" }),
5412
- c.type === "folder" ? /* @__PURE__ */ n(b, { className: "file-tree__icon", size: 15, strokeWidth: oe, "aria-hidden": "true" }) : /* @__PURE__ */ n(Or, { className: "file-tree__icon", size: 15, strokeWidth: oe, "aria-hidden": "true" }),
5412
+ c.type === "folder" ? /* @__PURE__ */ n(g, { className: "file-tree__icon", size: 15, strokeWidth: oe, "aria-hidden": "true" }) : /* @__PURE__ */ n(Or, { className: "file-tree__icon", size: 15, strokeWidth: oe, "aria-hidden": "true" }),
5413
5413
  /* @__PURE__ */ n("span", { className: "file-tree__name", translate: "no", children: c.name })
5414
5414
  ] })
5415
5415
  },
@@ -5489,7 +5489,7 @@ function bt({
5489
5489
  a(-1);
5490
5490
  }
5491
5491
  function d(f) {
5492
- const g = s.current.indexOf(f.target), h = e.indexOf(g >= 0 ? g : i);
5492
+ const b = s.current.indexOf(f.target), h = e.indexOf(b >= 0 ? b : i);
5493
5493
  if (f.key === "ArrowDown")
5494
5494
  f.preventDefault(), u(e[(h + 1) % e.length]);
5495
5495
  else if (f.key === "ArrowUp")
@@ -5549,7 +5549,7 @@ function bs({
5549
5549
  const c = i.current;
5550
5550
  !c || p.pointerId !== c.id || (Math.abs(p.clientX - c.startX) > lr || Math.abs(p.clientY - c.startY) > lr) && m();
5551
5551
  }
5552
- function g(p) {
5552
+ function b(p) {
5553
5553
  a.current.delete(p.pointerId), i.current?.id === p.pointerId && m(), a.current.size === 0 && (s.current = !1);
5554
5554
  }
5555
5555
  function h() {
@@ -5559,8 +5559,8 @@ function bs({
5559
5559
  pending: r,
5560
5560
  onPointerDown: d,
5561
5561
  onPointerMove: f,
5562
- onPointerUp: g,
5563
- onPointerCancel: g,
5562
+ onPointerUp: b,
5563
+ onPointerCancel: b,
5564
5564
  consumeContextMenuAfterLongPress: h
5565
5565
  };
5566
5566
  }
@@ -5574,10 +5574,10 @@ function gs({
5574
5574
  function i() {
5575
5575
  const l = t.current;
5576
5576
  if (!l || !e) return;
5577
- const u = getComputedStyle(l), m = Number.parseFloat(u.getPropertyValue("--q1-space-2")), d = Number.isFinite(m) ? m : 0, f = Number.parseFloat(u.borderTopWidth) + Number.parseFloat(u.borderBottomWidth), g = l.offsetWidth, h = Math.max(l.offsetHeight, l.scrollHeight + f), p = Math.max(0, window.innerWidth - e.x - d), c = Math.max(0, e.x - d), y = Math.max(0, window.innerHeight - e.y - d), b = Math.max(0, e.y - d), w = g <= p || p >= c, k = h <= y || h > b && y >= b, x = w ? e.x : e.x - g, T = Math.min(
5577
+ const u = getComputedStyle(l), m = Number.parseFloat(u.getPropertyValue("--q1-space-2")), d = Number.isFinite(m) ? m : 0, f = Number.parseFloat(u.borderTopWidth) + Number.parseFloat(u.borderBottomWidth), b = l.offsetWidth, h = Math.max(l.offsetHeight, l.scrollHeight + f), p = Math.max(0, window.innerWidth - e.x - d), c = Math.max(0, e.x - d), y = Math.max(0, window.innerHeight - e.y - d), g = Math.max(0, e.y - d), w = b <= p || p >= c, k = h <= y || h > g && y >= g, x = w ? e.x : e.x - b, T = Math.min(
5578
5578
  Math.max(x, d),
5579
- Math.max(d, window.innerWidth - d - g)
5580
- ), v = k ? y : b, N = k ? e.y : Math.max(d, e.y - Math.min(h, v));
5579
+ Math.max(d, window.innerWidth - d - b)
5580
+ ), v = k ? y : g, N = k ? e.y : Math.max(d, e.y - Math.min(h, v));
5581
5581
  o({ x: T, y: N, maxHeight: v });
5582
5582
  }
5583
5583
  let a = 0;
@@ -5597,7 +5597,7 @@ function ku({
5597
5597
  entries: t,
5598
5598
  children: r
5599
5599
  }) {
5600
- const [o, i] = Y(null), a = R(null), s = R(null), l = me(), u = o !== null, m = t.flatMap((T, v) => _s(T) ? [v] : []), d = m.length === 0, { itemRefs: f, focusItem: g, reset: h, onMenuKeyDown: p } = bt({
5600
+ const [o, i] = Y(null), a = R(null), s = R(null), l = me(), u = o !== null, m = t.flatMap((T, v) => _s(T) ? [v] : []), d = m.length === 0, { itemRefs: f, focusItem: b, reset: h, onMenuKeyDown: p } = bt({
5601
5601
  focusableIndices: m,
5602
5602
  getText: (T) => {
5603
5603
  const v = t[T];
@@ -5605,9 +5605,9 @@ function ku({
5605
5605
  },
5606
5606
  onClose: () => w(),
5607
5607
  onTabExit: () => window.setTimeout(() => w(!1), 0)
5608
- }), c = gs({ anchor: o, menuRef: s }), y = bs({ disabled: d, onLongPress: b });
5609
- function b(T, v) {
5610
- d || (i({ x: T, y: v }), window.requestAnimationFrame(() => g(m[0])));
5608
+ }), c = gs({ anchor: o, menuRef: s }), y = bs({ disabled: d, onLongPress: g });
5609
+ function g(T, v) {
5610
+ d || (i({ x: T, y: v }), window.requestAnimationFrame(() => b(m[0])));
5611
5611
  }
5612
5612
  function w(T = !0) {
5613
5613
  i(null), h(), T && a.current?.focus();
@@ -5622,14 +5622,14 @@ function ku({
5622
5622
  return document.addEventListener("pointerdown", T), () => document.removeEventListener("pointerdown", T);
5623
5623
  }, [u]);
5624
5624
  function k(T) {
5625
- d || (T.preventDefault(), !y.consumeContextMenuAfterLongPress() && b(T.clientX, T.clientY));
5625
+ d || (T.preventDefault(), !y.consumeContextMenuAfterLongPress() && g(T.clientX, T.clientY));
5626
5626
  }
5627
5627
  function x(T) {
5628
5628
  const v = T.target === T.currentTarget && (T.key === "Enter" || T.key === " ");
5629
5629
  if (T.shiftKey && T.key === "F10" || T.key === "ContextMenu" || v) {
5630
5630
  T.preventDefault();
5631
5631
  const N = a.current.getBoundingClientRect();
5632
- b(N.left + 16, N.top + 16);
5632
+ g(N.left + 16, N.top + 16);
5633
5633
  }
5634
5634
  }
5635
5635
  return /* @__PURE__ */ _(ye, { children: [
@@ -5734,7 +5734,7 @@ function xu({
5734
5734
  align: o = "end",
5735
5735
  label: i = "更多操作"
5736
5736
  }) {
5737
- const [a, s] = Y(!1), [l, u] = Y("keyboard"), m = R(null), d = R(null), f = R(0), g = me(), { portalPopup: h, placement: p, onOverlayKeyDown: c } = ot(
5737
+ const [a, s] = Y(!1), [l, u] = Y("keyboard"), m = R(null), d = R(null), f = R(0), b = me(), { portalPopup: h, placement: p, onOverlayKeyDown: c } = ot(
5738
5738
  a,
5739
5739
  m,
5740
5740
  d,
@@ -5743,8 +5743,8 @@ function xu({
5743
5743
  M(D !== "outside-pointer" && (D !== "anchor-hidden" || !S || S === C?.body || !!d.current?.contains(S)));
5744
5744
  },
5745
5745
  { width: "content", align: o, gapToken: "--q1-space-2", outsidePointer: !0 }
5746
- ), y = i === "更多操作" ? {} : { "aria-label": i }, b = e.flatMap((D, C) => D.type === "separator" || D.disabled ? [] : [C]), w = !!r || b.length === 0, { itemRefs: k, focusItem: x, reset: T, onMenuKeyDown: v } = bt({
5747
- focusableIndices: b,
5746
+ ), y = i === "更多操作" ? {} : { "aria-label": i }, g = e.flatMap((D, C) => D.type === "separator" || D.disabled ? [] : [C]), w = !!r || g.length === 0, { itemRefs: k, focusItem: x, reset: T, onMenuKeyDown: v } = bt({
5747
+ focusableIndices: g,
5748
5748
  getText: (D) => {
5749
5749
  const C = e[D];
5750
5750
  return C.type === "separator" ? "" : C.label;
@@ -5754,7 +5754,7 @@ function xu({
5754
5754
  function N(D, C) {
5755
5755
  if (w) return;
5756
5756
  u(C), s(!0);
5757
- const S = D === "first" ? b[0] : b[b.length - 1];
5757
+ const S = D === "first" ? g[0] : g[g.length - 1];
5758
5758
  window.cancelAnimationFrame(f.current), f.current = window.requestAnimationFrame(() => {
5759
5759
  f.current = 0, x(S);
5760
5760
  });
@@ -5783,7 +5783,7 @@ function xu({
5783
5783
  ...y,
5784
5784
  "aria-haspopup": "menu",
5785
5785
  "aria-expanded": a,
5786
- "aria-controls": a ? g : void 0,
5786
+ "aria-controls": a ? b : void 0,
5787
5787
  disabled: w || void 0,
5788
5788
  onClick: E,
5789
5789
  onKeyDown: L,
@@ -5798,7 +5798,7 @@ function xu({
5798
5798
  "div",
5799
5799
  {
5800
5800
  ref: d,
5801
- id: g,
5801
+ id: b,
5802
5802
  role: "menu",
5803
5803
  "aria-label": "更多操作",
5804
5804
  ...y,
@@ -5863,10 +5863,10 @@ function Pu({
5863
5863
  i === "md" ? "" : `badge--${i}`,
5864
5864
  s ? "badge--count" : "",
5865
5865
  u
5866
- ), g = a != null && (m == null || m === "");
5867
- return /* @__PURE__ */ _("span", { className: f, title: l, ...g ? { role: "img", "aria-label": l } : {}, ...d, children: [
5866
+ ), b = a != null && (m == null || m === "");
5867
+ return /* @__PURE__ */ _("span", { className: f, title: l, ...b ? { role: "img", "aria-label": l } : {}, ...d, children: [
5868
5868
  a ? /* @__PURE__ */ n("span", { className: "badge__icon", "aria-hidden": "true", children: a }) : null,
5869
- g || m === void 0 || m === null || m === "" ? null : (
5869
+ b || m === void 0 || m === null || m === "" ? null : (
5870
5870
  // 文字包裹层:光学补偿开关 --q1-badge-optical-shift 的作用点(0.15.2 起的 DOM 结构)。
5871
5871
  /* @__PURE__ */ n("span", { className: "badge__label", children: m })
5872
5872
  )
@@ -5885,18 +5885,18 @@ function Du({
5885
5885
  onPointerCancel: m,
5886
5886
  onPointerDown: d,
5887
5887
  onPointerLeave: f,
5888
- onPointerUp: g,
5888
+ onPointerUp: b,
5889
5889
  ...h
5890
5890
  }) {
5891
- const [p, c] = Y(!1), [y, b] = Y(), w = ce("badge", "badge--pill", t === "md" ? "" : `badge--${t}`, i), x = r != null && (a == null || a === "") ? { "aria-label": o } : {};
5891
+ const [p, c] = Y(!1), [y, g] = Y(), w = ce("badge", "badge--pill", t === "md" ? "" : `badge--${t}`, i), x = r != null && (a == null || a === "") ? { "aria-label": o } : {};
5892
5892
  function T() {
5893
5893
  c(!1);
5894
5894
  }
5895
5895
  function v(C) {
5896
- d?.(C), !C.defaultPrevented && C.isPrimary && C.button === 0 && (b("pointer"), c(!0));
5896
+ d?.(C), !C.defaultPrevented && C.isPrimary && C.button === 0 && (g("pointer"), c(!0));
5897
5897
  }
5898
5898
  function N(C) {
5899
- g?.(C), T();
5899
+ b?.(C), T();
5900
5900
  }
5901
5901
  function M(C) {
5902
5902
  f?.(C), T();
@@ -5911,7 +5911,7 @@ function Du({
5911
5911
  s?.(C), T();
5912
5912
  }
5913
5913
  function D(C) {
5914
- l?.(C), b("keyboard"), T();
5914
+ l?.(C), g("keyboard"), T();
5915
5915
  }
5916
5916
  return /* @__PURE__ */ n(
5917
5917
  "a",
@@ -5982,7 +5982,7 @@ function Eu({ title: e, children: t, tone: r, icon: o, action: i, onDismiss: a,
5982
5982
  " — ",
5983
5983
  t
5984
5984
  ] }) : null
5985
- ] }), g = i ? /* @__PURE__ */ n(ys, { announcement: m, action: i }) : null, h = !m && a ? /* @__PURE__ */ n(vs, { title: e, onDismiss: a }) : null;
5985
+ ] }), b = i ? /* @__PURE__ */ n(ys, { announcement: m, action: i }) : null, h = !m && a ? /* @__PURE__ */ n(vs, { title: e, onDismiss: a }) : null;
5986
5986
  if (s) {
5987
5987
  const p = Number.isFinite(s.value) ? Math.min(100, Math.max(0, s.value)) : 0;
5988
5988
  return /* @__PURE__ */ _("div", { className: d, ...u, children: [
@@ -6011,10 +6011,10 @@ function Eu({ title: e, children: t, tone: r, icon: o, action: i, onDismiss: a,
6011
6011
  return /* @__PURE__ */ _("div", { className: d, ...u, children: [
6012
6012
  !m && o ? /* @__PURE__ */ n("span", { className: "banner__icon", "aria-hidden": "true", children: o }) : null,
6013
6013
  f,
6014
- g && h ? /* @__PURE__ */ _("div", { className: "banner__actions", children: [
6015
- g,
6014
+ b && h ? /* @__PURE__ */ _("div", { className: "banner__actions", children: [
6015
+ b,
6016
6016
  h
6017
- ] }) : g ?? h
6017
+ ] }) : b ?? h
6018
6018
  ] });
6019
6019
  }
6020
6020
  function dt(e) {
@@ -6069,12 +6069,12 @@ function ks(e) {
6069
6069
  if (e.href !== void 0) {
6070
6070
  const {
6071
6071
  hover: f,
6072
- secondary: g,
6072
+ secondary: b,
6073
6073
  divided: h,
6074
6074
  direction: p,
6075
6075
  shadow: c,
6076
6076
  bordered: y,
6077
- className: b,
6077
+ className: g,
6078
6078
  children: w,
6079
6079
  onBlur: k,
6080
6080
  onKeyDown: x,
@@ -6172,7 +6172,7 @@ function Tu({
6172
6172
  }) {
6173
6173
  if (!Number.isFinite(l) || l <= 0)
6174
6174
  throw new Error("SidebarDrawer collapseBelow must be a positive finite number");
6175
- const f = Ts(l), g = me(), h = me(), p = R(null), c = R(null), y = R(null), b = R(!1), w = R(!1), [k, x] = Y(!1), [T, v] = Y("keyboard"), N = f && t, M = R(N), L = f && (N || k), E = fe(() => {
6175
+ const f = Ts(l), b = me(), h = me(), p = R(null), c = R(null), y = R(null), g = R(!1), w = R(!1), [k, x] = Y(!1), [T, v] = Y("keyboard"), N = f && t, M = R(N), L = f && (N || k), E = fe(() => {
6176
6176
  if (typeof document > "u") return [];
6177
6177
  const A = document.getElementById(h);
6178
6178
  if (!(A instanceof HTMLElement)) return [];
@@ -6224,10 +6224,10 @@ function Tu({
6224
6224
  return () => window.clearTimeout(K);
6225
6225
  }, [f, N, D, k]), ie(() => {
6226
6226
  if (f || !t) {
6227
- b.current = !1;
6227
+ g.current = !1;
6228
6228
  return;
6229
6229
  }
6230
- b.current || (b.current = !0, P(!1, "keyboard"));
6230
+ g.current || (g.current = !0, P(!1, "keyboard"));
6231
6231
  }, [f, t, P]), !f)
6232
6232
  return /* @__PURE__ */ _(Lt, { id: h, "aria-label": e, variant: m, tabIndex: -1, "data-sidebar-drawer-persistent": !0, children: [
6233
6233
  i ? /* @__PURE__ */ n(Lt.Header, { children: i }) : null,
@@ -6242,7 +6242,7 @@ function Tu({
6242
6242
  ref: y,
6243
6243
  type: "button",
6244
6244
  onClick: (A) => P(!t, A.detail > 0 ? "pointer" : "keyboard"),
6245
- "aria-controls": g,
6245
+ "aria-controls": b,
6246
6246
  "aria-expanded": t,
6247
6247
  "aria-haspopup": "dialog"
6248
6248
  }),
@@ -6262,7 +6262,7 @@ function Tu({
6262
6262
  "div",
6263
6263
  {
6264
6264
  ref: p,
6265
- id: g,
6265
+ id: b,
6266
6266
  role: "dialog",
6267
6267
  "aria-modal": "true",
6268
6268
  "aria-hidden": N ? void 0 : !0,
@@ -6373,7 +6373,7 @@ function Su({ label: e, action: t, children: r, className: o, ...i }) {
6373
6373
  );
6374
6374
  }
6375
6375
  function $u(e) {
6376
- const t = st(No), { active: r, disabled: o, icon: i, badge: a, description: s, action: l, children: u, className: m, href: d, ...f } = e, g = ce(
6376
+ const t = st(No), { active: r, disabled: o, icon: i, badge: a, description: s, action: l, children: u, className: m, href: d, ...f } = e, b = ce(
6377
6377
  "q1-navigation__item",
6378
6378
  r && "q1-navigation__item--active",
6379
6379
  o && "q1-navigation__item--disabled",
@@ -6391,7 +6391,7 @@ function $u(e) {
6391
6391
  "a",
6392
6392
  {
6393
6393
  ...p,
6394
- className: g,
6394
+ className: b,
6395
6395
  href: o ? void 0 : d,
6396
6396
  "aria-disabled": o || void 0,
6397
6397
  "aria-current": r ? "page" : void 0,
@@ -6402,7 +6402,7 @@ function $u(e) {
6402
6402
  "button",
6403
6403
  {
6404
6404
  type: "button",
6405
- className: g,
6405
+ className: b,
6406
6406
  disabled: o,
6407
6407
  ...f,
6408
6408
  "aria-current": r ? "page" : void 0,
@@ -6430,8 +6430,8 @@ function qu({
6430
6430
  "aria-expanded": d,
6431
6431
  "aria-controls": s,
6432
6432
  onClick: () => {
6433
- const g = !d;
6434
- m || u(g), i?.(g);
6433
+ const b = !d;
6434
+ m || u(b), i?.(b);
6435
6435
  },
6436
6436
  children: [
6437
6437
  t ? /* @__PURE__ */ n("span", { className: "q1-navigation__group-icon", "aria-hidden": "true", children: t }) : null,
@@ -6557,12 +6557,12 @@ function Fs({
6557
6557
  onFooterAction: m,
6558
6558
  label: d,
6559
6559
  isOpen: f,
6560
- popupRef: g,
6560
+ popupRef: b,
6561
6561
  triggerRef: h,
6562
6562
  errorRef: p,
6563
6563
  dialogId: c,
6564
6564
  placement: y,
6565
- openingModality: b,
6565
+ openingModality: g,
6566
6566
  onClose: w
6567
6567
  }) {
6568
6568
  const [k, x] = $r(Ss, ko), T = R(null), v = R({}), N = R(null), M = R(null), L = R(null), E = R(i), P = R(!1), D = R(k.view), C = R({ buffer: "", timer: 0 }), S = `${c}-title`, O = `${c}-${k.view}-listbox`, B = k.view === "primary" ? r : o, A = Ht(k.query), U = De(
@@ -6649,12 +6649,12 @@ function Fs({
6649
6649
  k.view === "primary" && z ? N.current : M.current,
6650
6650
  T.current,
6651
6651
  G ? v.current[G] : null,
6652
- ...k.view === "primary" ? (s ?? []).map((Se) => qs(g.current, Se.id)) : []
6652
+ ...k.view === "primary" ? (s ?? []).map((Se) => qs(b.current, Se.id)) : []
6653
6653
  ].filter(
6654
6654
  (Se) => Se !== null && !Se.disabled
6655
6655
  ), Me = Ie.indexOf(j.target);
6656
6656
  if (!(Me < 0 || j.shiftKey && Me === 0 || !j.shiftKey && Me === Ie.length - 1)) return;
6657
- j.preventDefault(), xo(h.current, g.current, j.shiftKey ? -1 : 1)?.focus(), w(!1);
6657
+ j.preventDefault(), xo(h.current, b.current, j.shiftKey ? -1 : 1)?.focus(), w(!1);
6658
6658
  }
6659
6659
  function Z(j) {
6660
6660
  if (!(j.disabled || j.id === i)) {
@@ -6680,7 +6680,7 @@ function Fs({
6680
6680
  return /* @__PURE__ */ _(
6681
6681
  "div",
6682
6682
  {
6683
- ref: g,
6683
+ ref: b,
6684
6684
  id: c,
6685
6685
  role: "dialog",
6686
6686
  tabIndex: -1,
@@ -6689,7 +6689,7 @@ function Fs({
6689
6689
  dir: y.direction,
6690
6690
  "data-align": y.align,
6691
6691
  "data-side": y.side,
6692
- "data-open-modality": b,
6692
+ "data-open-modality": g,
6693
6693
  style: { left: y.left, top: y.top },
6694
6694
  onKeyDown: V,
6695
6695
  children: [
@@ -6838,7 +6838,7 @@ function Co({
6838
6838
  }) {
6839
6839
  const o = me(), [i, a] = Y(null), s = R(null), l = fe((N) => {
6840
6840
  s.current = N, a(N);
6841
- }, []), u = R(0), m = R(0), d = R(null), f = R(/* @__PURE__ */ new Map()), g = R(null), h = R([]), p = (N) => `${o}-${encodeURIComponent(N)}-submenu`, c = fe(() => {
6841
+ }, []), u = R(0), m = R(0), d = R(null), f = R(/* @__PURE__ */ new Map()), b = R(null), h = R([]), p = (N) => `${o}-${encodeURIComponent(N)}-submenu`, c = fe(() => {
6842
6842
  window.clearTimeout(u.current), window.clearTimeout(m.current);
6843
6843
  }, []);
6844
6844
  ie(() => c, [c]);
@@ -6847,11 +6847,11 @@ function Co({
6847
6847
  const M = s.current;
6848
6848
  l(null), M && N && f.current.get(M.key)?.focus();
6849
6849
  }, [c, l]);
6850
- function b(N, M) {
6850
+ function g(N, M) {
6851
6851
  c(), l({ key: N, focus: M });
6852
6852
  }
6853
6853
  ur(() => {
6854
- const N = g.current, M = e.current, L = i ? f.current.get(i.key) : null;
6854
+ const N = b.current, M = e.current, L = i ? f.current.get(i.key) : null;
6855
6855
  if (!i || !N || !M || !L) return;
6856
6856
  if (wn()) {
6857
6857
  N.style.left = "", N.style.top = "", N.dataset.side = "inline";
@@ -6878,13 +6878,13 @@ function Co({
6878
6878
  return;
6879
6879
  }
6880
6880
  window.clearTimeout(u.current), u.current = window.setTimeout(
6881
- () => b(N, null),
6881
+ () => g(N, null),
6882
6882
  dr(e.current, "--q1-duration-base", 200)
6883
6883
  );
6884
6884
  }
6885
6885
  function k(N) {
6886
6886
  if (window.clearTimeout(u.current), !i || wn()) return;
6887
- const M = g.current, L = d.current;
6887
+ const M = b.current, L = d.current;
6888
6888
  if (M && L) {
6889
6889
  const E = M.getBoundingClientRect(), P = M.dataset.side === "left" ? E.right : E.left, D = { x: N.clientX, y: N.clientY };
6890
6890
  if (Bs(D, L, { x: P, y: E.top }, { x: P, y: E.bottom })) {
@@ -6908,10 +6908,10 @@ function Co({
6908
6908
  "aria-controls": L ? p(N) : void 0,
6909
6909
  "data-context-submenu-trigger": N,
6910
6910
  onClick: (E) => {
6911
- M || L && E.detail !== 0 || b(N, E.detail === 0 ? "first" : null);
6911
+ M || L && E.detail !== 0 || g(N, E.detail === 0 ? "first" : null);
6912
6912
  },
6913
6913
  onKeyDown: (E) => {
6914
- M || (E.key === "ArrowRight" || E.key === "Enter" || E.key === " ") && (E.preventDefault(), E.stopPropagation(), b(N, "first"));
6914
+ M || (E.key === "ArrowRight" || E.key === "Enter" || E.key === " ") && (E.preventDefault(), E.stopPropagation(), g(N, "first"));
6915
6915
  },
6916
6916
  onPointerEnter: (E) => {
6917
6917
  M || E.pointerType !== "mouse" || wn() || w(N);
@@ -6931,7 +6931,7 @@ function Co({
6931
6931
  return i?.key !== N ? null : (h.current = [], /* @__PURE__ */ n(
6932
6932
  "div",
6933
6933
  {
6934
- ref: g,
6934
+ ref: b,
6935
6935
  id: p(N),
6936
6936
  role: "menu",
6937
6937
  "aria-label": L,
@@ -7004,12 +7004,12 @@ function Ks({
7004
7004
  popupRef: m,
7005
7005
  triggerRef: d,
7006
7006
  menuId: f,
7007
- placement: g,
7007
+ placement: b,
7008
7008
  openingEdge: h,
7009
7009
  didFocusOnOpen: p,
7010
7010
  resetRef: c,
7011
7011
  onClose: y,
7012
- onOverlayKeyDown: b
7012
+ onOverlayKeyDown: g
7013
7013
  }) {
7014
7014
  const w = De(() => [
7015
7015
  ...t.flatMap((C) => C.items.map((S) => ({ kind: "item", group: C, item: S }))),
@@ -7047,7 +7047,7 @@ function Ks({
7047
7047
  C !== void 0 && N(C);
7048
7048
  }, [N, k, l, u, m, T]);
7049
7049
  function D(C) {
7050
- if (E.openKey && C.key !== "Escape" && E.close(!1), b(C), !(C.defaultPrevented || C.key === "Escape")) {
7050
+ if (E.openKey && C.key !== "Escape" && E.close(!1), g(C), !(C.defaultPrevented || C.key === "Escape")) {
7051
7051
  if (C.key === "Tab") {
7052
7052
  d.current?.focus(), y(!1);
7053
7053
  return;
@@ -7068,10 +7068,10 @@ function Ks({
7068
7068
  tabIndex: -1,
7069
7069
  className: "q1-context-switcher__popup",
7070
7070
  "aria-label": s ?? e,
7071
- dir: g.direction,
7072
- "data-align": g.align,
7073
- "data-side": g.side,
7074
- style: { left: g.left, top: g.top },
7071
+ dir: b.direction,
7072
+ "data-align": b.align,
7073
+ "data-side": b.side,
7074
+ style: { left: b.left, top: b.top },
7075
7075
  onKeyDown: D,
7076
7076
  children: [
7077
7077
  /* @__PURE__ */ n("div", { className: "q1-context-switcher__groups", children: t.map((C) => /* @__PURE__ */ _(
@@ -7184,13 +7184,13 @@ function zs({
7184
7184
  const d = o !== void 0 && Number.isFinite(o) && o > 0 ? { "--q1-avatar-button-size": `${o}px` } : void 0, f = /* @__PURE__ */ _(ye, { children: [
7185
7185
  /* @__PURE__ */ n("span", { className: "q1-avatar-button__tile", "aria-hidden": "true", children: t ? /* @__PURE__ */ n("img", { className: "q1-avatar-button__img", src: t, alt: "" }) : r }),
7186
7186
  s ? /* @__PURE__ */ n("span", { className: "q1-avatar-button__badge", "aria-hidden": "true", children: /* @__PURE__ */ n(zi, { size: 8, strokeWidth: 2.5 }) }) : null
7187
- ] }), g = {
7187
+ ] }), b = {
7188
7188
  ...m,
7189
7189
  className: ce("q1-avatar-button", l),
7190
7190
  style: d,
7191
7191
  "aria-label": e
7192
7192
  };
7193
- return i ? /* @__PURE__ */ n("a", { ...g, ref: u, href: i, onClick: a, children: f }) : /* @__PURE__ */ n("button", { ...g, ref: u, type: "button", onClick: a, children: f });
7193
+ return i ? /* @__PURE__ */ n("a", { ...b, ref: u, href: i, onClick: a, children: f }) : /* @__PURE__ */ n("button", { ...b, ref: u, type: "button", onClick: a, children: f });
7194
7194
  }
7195
7195
  function Vs(e, t) {
7196
7196
  const r = new Set(t.map((a) => a.id)), o = /* @__PURE__ */ new Map();
@@ -7224,12 +7224,12 @@ function Us({
7224
7224
  openingModality: m,
7225
7225
  portalRoot: d,
7226
7226
  popupRef: f,
7227
- triggerRef: g,
7227
+ triggerRef: b,
7228
7228
  menuId: h,
7229
7229
  placement: p,
7230
7230
  openingEdge: c,
7231
7231
  didFocusOnOpen: y,
7232
- resetRef: b,
7232
+ resetRef: g,
7233
7233
  onClose: w,
7234
7234
  onOverlayKeyDown: k
7235
7235
  }) {
@@ -7272,7 +7272,7 @@ function Us({
7272
7272
  onLeaf: ($) => l?.($),
7273
7273
  onCloseAll: () => w(!0)
7274
7274
  });
7275
- b.current = () => {
7275
+ g.current = () => {
7276
7276
  X.close(!1), K();
7277
7277
  }, mr(() => {
7278
7278
  if (!u || !d || y.current) return;
@@ -7314,7 +7314,7 @@ function Us({
7314
7314
  $.stopPropagation(), Z.focus();
7315
7315
  return;
7316
7316
  }
7317
- xo(g.current, f.current, $.shiftKey ? -1 : 1)?.focus(), w(!1);
7317
+ xo(b.current, f.current, $.shiftKey ? -1 : 1)?.focus(), w(!1);
7318
7318
  return;
7319
7319
  }
7320
7320
  if (!($.target.matches('input[type="search"]') && $.key !== "Escape")) {
@@ -7530,24 +7530,24 @@ function Xs({
7530
7530
  onRequestClose: m,
7531
7531
  onCloseTransition: d
7532
7532
  }) {
7533
- const [f, g] = Y(null), [h, p] = Y({
7533
+ const [f, b] = Y(null), [h, p] = Y({
7534
7534
  align: "start",
7535
7535
  side: "bottom",
7536
7536
  direction: "ltr",
7537
7537
  left: Ye,
7538
7538
  top: Ye
7539
- }), c = R("trigger"), y = R(t), b = R(m), w = R(d);
7540
- b.current = m, w.current = d;
7539
+ }), c = R("trigger"), y = R(t), g = R(m), w = R(d);
7540
+ g.current = m, w.current = d;
7541
7541
  function k(x) {
7542
7542
  c.current = x;
7543
7543
  }
7544
7544
  return ie(() => {
7545
7545
  if (!r) {
7546
- g(null);
7546
+ b(null);
7547
7547
  return;
7548
7548
  }
7549
7549
  const x = js();
7550
- return g(x), () => Ys();
7550
+ return b(x), () => Ys();
7551
7551
  }, [r]), hr(() => {
7552
7552
  const x = y.current;
7553
7553
  if (y.current = t, !x && t) {
@@ -7589,7 +7589,7 @@ function Xs({
7589
7589
  if (!t || !i) return;
7590
7590
  function x(T) {
7591
7591
  const v = T.target;
7592
- !a.current?.contains(v) && !s.current?.contains(v) && (k("preserve"), b.current());
7592
+ !a.current?.contains(v) && !s.current?.contains(v) && (k("preserve"), g.current());
7593
7593
  }
7594
7594
  return document.addEventListener("pointerdown", x), () => document.removeEventListener("pointerdown", x);
7595
7595
  }, [t, i]), { triggerRef: a, popupRef: s, portalRoot: f, placement: h, closeWithFocus: k };
@@ -7650,12 +7650,12 @@ function Js(e, t, r) {
7650
7650
  u || (u = !0, f.disconnect(), document.removeEventListener("focusin", d, !0), l !== null && window.clearTimeout(l));
7651
7651
  }, d = () => {
7652
7652
  !e.isConnected && document.activeElement !== i && m();
7653
- }, f = new MutationObserver((g) => {
7654
- if (g.flatMap((p) => Array.from(p.addedNodes)).forEach((p) => {
7653
+ }, f = new MutationObserver((b) => {
7654
+ if (b.flatMap((p) => Array.from(p.addedNodes)).forEach((p) => {
7655
7655
  if (!(p instanceof HTMLElement)) return [];
7656
7656
  (p.matches(".q1-context-switcher") ? [p] : Array.from(p.querySelectorAll(".q1-context-switcher"))).forEach((y) => {
7657
- const b = y.querySelector(".q1-context-switcher__trigger");
7658
- b && s.add(b);
7657
+ const g = y.querySelector(".q1-context-switcher__trigger");
7658
+ g && s.add(g);
7659
7659
  });
7660
7660
  }), e.isConnected) return;
7661
7661
  if (document.activeElement !== i) {
@@ -7688,23 +7688,23 @@ function Ru({
7688
7688
  header: m,
7689
7689
  headerActions: d,
7690
7690
  onFooterAction: f,
7691
- label: g,
7691
+ label: b,
7692
7692
  presentation: h
7693
7693
  }) {
7694
7694
  Gs(t, h, m, [...d ?? [], ...u ?? []]);
7695
- const [p, c] = Y(o), y = r !== void 0, b = y ? r : p, w = R(null), k = R(null), x = R(null), T = R("selected"), v = R("pointer"), N = R(null), M = R(!1), L = R(() => {
7696
- }), E = R(!1), P = me(), D = h?.type === "drilldown" ? h : null, C = D !== null, S = h?.type === "stacked", O = S ? m.textValue : e.textValue, B = g ? `${g} ${O}` : O, A = D ? {
7695
+ const [p, c] = Y(o), y = r !== void 0, g = y ? r : p, w = R(null), k = R(null), x = R(null), T = R("selected"), v = R("pointer"), N = R(null), M = R(!1), L = R(() => {
7696
+ }), E = R(!1), P = me(), D = h?.type === "drilldown" ? h : null, C = D !== null, S = h?.type === "stacked", O = S ? m.textValue : e.textValue, B = b ? `${b} ${O}` : O, A = D ? {
7697
7697
  primary: t.find((j) => j.id === D.primaryGroupId),
7698
7698
  scope: t.find((j) => j.id === D.scopeGroupId)
7699
7699
  } : null, U = A?.primary?.items.find(
7700
7700
  (j) => j.id === A.primary?.selectedId
7701
7701
  ), K = D && A?.scope ? JSON.stringify([
7702
- g ?? "",
7702
+ b ?? "",
7703
7703
  D.primaryGroupId,
7704
7704
  D.scopeGroupId,
7705
7705
  A.scope.selectedId ?? ""
7706
7706
  ]) : void 0, Q = S ? m : C && U ? U : e;
7707
- b && (E.current = !1);
7707
+ g && (E.current = !1);
7708
7708
  function G(j) {
7709
7709
  y || c(j), i?.(j);
7710
7710
  }
@@ -7720,7 +7720,7 @@ function Ru({
7720
7720
  q(!1), se && te.triggerRef.current?.focus();
7721
7721
  }
7722
7722
  const z = je({
7723
- open: b && !C,
7723
+ open: g && !C,
7724
7724
  blocking: !1,
7725
7725
  dismissable: !0,
7726
7726
  outsidePointer: !0,
@@ -7733,7 +7733,7 @@ function Ru({
7733
7733
  restoreFocus: !1
7734
7734
  }), te = Xs({
7735
7735
  controlled: y,
7736
- isOpen: b,
7736
+ isOpen: g,
7737
7737
  managePortal: C,
7738
7738
  positioningReady: C || !!z.portalRoot,
7739
7739
  outsidePointer: C,
@@ -7744,7 +7744,7 @@ function Ru({
7744
7744
  onRequestClose: X,
7745
7745
  onCloseTransition: I
7746
7746
  });
7747
- St(k, x, b);
7747
+ St(k, x, g);
7748
7748
  function $() {
7749
7749
  N.current?.disconnect(), N.current = null, !E.current && (E.current = !0, L.current());
7750
7750
  }
@@ -7758,7 +7758,7 @@ function Ru({
7758
7758
  T.current = j, v.current = se, te.closeWithFocus("trigger"), M.current = !1, G(!0);
7759
7759
  }
7760
7760
  function Z(j) {
7761
- j.key === "ArrowDown" || j.key === "Enter" || j.key === " " ? (j.preventDefault(), b || V("selected", "keyboard")) : j.key === "ArrowUp" ? (j.preventDefault(), b || V(C ? "selected" : "last", "keyboard")) : j.key === "Escape" && b && (j.preventDefault(), q(!0));
7761
+ j.key === "ArrowDown" || j.key === "Enter" || j.key === " " ? (j.preventDefault(), g || V("selected", "keyboard")) : j.key === "ArrowUp" ? (j.preventDefault(), g || V(C ? "selected" : "last", "keyboard")) : j.key === "Escape" && g && (j.preventDefault(), q(!0));
7762
7762
  }
7763
7763
  function F(j, se) {
7764
7764
  C && se.id === A?.primary?.id && (N.current?.disconnect(), N.current = K ? Js(te.triggerRef.current, K, j.id) : null), te.closeWithFocus("trigger"), a(j, se), y || q(!0);
@@ -7782,8 +7782,8 @@ function Ru({
7782
7782
  onPrimarySelect: F,
7783
7783
  onScopeSelect: re,
7784
7784
  onFooterAction: W,
7785
- label: g,
7786
- isOpen: b,
7785
+ label: b,
7786
+ isOpen: g,
7787
7787
  popupRef: te.popupRef,
7788
7788
  triggerRef: te.triggerRef,
7789
7789
  errorRef: w,
@@ -7804,7 +7804,7 @@ function Ru({
7804
7804
  footerActions: u,
7805
7805
  onSelect: F,
7806
7806
  onFooterAction: W,
7807
- isOpen: b,
7807
+ isOpen: g,
7808
7808
  portalRoot: z.portalRoot,
7809
7809
  popupRef: te.popupRef,
7810
7810
  triggerRef: te.triggerRef,
@@ -7825,8 +7825,8 @@ function Ru({
7825
7825
  footerActions: u,
7826
7826
  onSelect: F,
7827
7827
  onFooterAction: W,
7828
- label: g,
7829
- isOpen: b,
7828
+ label: b,
7829
+ isOpen: g,
7830
7830
  portalRoot: z.portalRoot,
7831
7831
  popupRef: te.popupRef,
7832
7832
  triggerRef: te.triggerRef,
@@ -7838,7 +7838,7 @@ function Ru({
7838
7838
  onClose: q,
7839
7839
  onOverlayKeyDown: z.onKeyDown
7840
7840
  }
7841
- ), ee = b ? C ? te.portalRoot ? Dt(H, te.portalRoot) : null : z.portal(H) : null;
7841
+ ), ee = g ? C ? te.portalRoot ? Dt(H, te.portalRoot) : null : z.portal(H) : null;
7842
7842
  return /* @__PURE__ */ _(
7843
7843
  "div",
7844
7844
  {
@@ -7853,10 +7853,10 @@ function Ru({
7853
7853
  type: "button",
7854
7854
  className: "q1-context-switcher__trigger",
7855
7855
  "aria-haspopup": C || S ? "dialog" : "menu",
7856
- "aria-expanded": b,
7856
+ "aria-expanded": g,
7857
7857
  "aria-controls": P,
7858
7858
  "aria-label": B,
7859
- onClick: (j) => b ? q(!0) : V("selected", j.detail === 0 ? "keyboard" : "pointer"),
7859
+ onClick: (j) => g ? q(!0) : V("selected", j.detail === 0 ? "keyboard" : "pointer"),
7860
7860
  onKeyDown: Z,
7861
7861
  children: [
7862
7862
  Q.avatar ? /* @__PURE__ */ n("span", { className: `q1-context-switcher__avatar${S ? " q1-context-switcher__avatar--stacked" : ""}`, "aria-hidden": "true", children: Q.avatar }) : null,
@@ -7894,11 +7894,11 @@ function rl({ title: e, ellipsis: t, children: r }) {
7894
7894
  const o = R(null), i = R(null), [a, s] = Y(!1), [l, u] = Y(!1), m = me(), d = !!(t && nl(r));
7895
7895
  return pe(() => {
7896
7896
  if (!d) return;
7897
- const f = o.current, g = i.current;
7898
- if (!f || !g) return;
7897
+ const f = o.current, b = i.current;
7898
+ if (!f || !b) return;
7899
7899
  const h = () => {
7900
- const b = g.scrollWidth > f.clientWidth;
7901
- s(b), b || u(!1);
7900
+ const g = b.scrollWidth > f.clientWidth;
7901
+ s(g), g || u(!1);
7902
7902
  };
7903
7903
  h();
7904
7904
  const p = f.ownerDocument.defaultView, c = p && typeof p.ResizeObserver == "function" ? new p.ResizeObserver(h) : null;
@@ -7964,14 +7964,14 @@ function _r(e, t, r, o, i, a, s) {
7964
7964
  }
7965
7965
  function il(e) {
7966
7966
  const { trigger: t, card: r, viewportWidth: o, viewportHeight: i, align: a, gap: s, margin: l } = e, u = ol[e.placement], m = !_r(e.placement, t, r, o, i, s, l) && _r(u, t, r, o, i, s, l) ? u : e.placement, d = t.left + t.width / 2, f = t.top + t.height / 2;
7967
- let g, h;
7968
- m === "top" || m === "bottom" ? (g = a === "start" ? t.left : a === "end" ? t.right - r.width : d - r.width / 2, h = m === "top" ? t.top - s - r.height : t.bottom + s) : (g = m === "left" ? t.left - s - r.width : t.right + s, h = a === "start" ? t.top : a === "end" ? t.bottom - r.height : f - r.height / 2), g = Ft(g, l, Math.max(l, o - l - r.width)), h = Ft(h, l, Math.max(l, i - l - r.height));
7967
+ let b, h;
7968
+ m === "top" || m === "bottom" ? (b = a === "start" ? t.left : a === "end" ? t.right - r.width : d - r.width / 2, h = m === "top" ? t.top - s - r.height : t.bottom + s) : (b = m === "left" ? t.left - s - r.width : t.right + s, h = a === "start" ? t.top : a === "end" ? t.bottom - r.height : f - r.height / 2), b = Ft(b, l, Math.max(l, o - l - r.width)), h = Ft(h, l, Math.max(l, i - l - r.height));
7969
7969
  const p = Math.min(l, r.width / 2, r.height / 2);
7970
7970
  return {
7971
7971
  placement: m,
7972
- left: g,
7972
+ left: b,
7973
7973
  top: h,
7974
- originX: m === "left" ? r.width : m === "right" ? 0 : Ft(d - g, p, r.width - p),
7974
+ originX: m === "left" ? r.width : m === "right" ? 0 : Ft(d - b, p, r.width - p),
7975
7975
  originY: m === "top" ? r.height : m === "bottom" ? 0 : Ft(f - h, p, r.height - p)
7976
7976
  };
7977
7977
  }
@@ -8006,9 +8006,9 @@ function ll({
8006
8006
  placement: t,
8007
8007
  align: r
8008
8008
  }) {
8009
- const [o, i] = Y(!1), [a, s] = Y(!1), [l, u] = Y(!1), [m, d] = Y(t), [f, g] = Y({ left: 0, top: 0, originX: 0, originY: 0 }), [h, p] = Y(null), c = R(null), y = R(null);
8009
+ const [o, i] = Y(!1), [a, s] = Y(!1), [l, u] = Y(!1), [m, d] = Y(t), [f, b] = Y({ left: 0, top: 0, originX: 0, originY: 0 }), [h, p] = Y(null), c = R(null), y = R(null);
8010
8010
  St(c, y, !!h);
8011
- const b = R(!1), w = R(null), k = R(null), x = R(!1), T = R(!1), v = R(!1), N = R(!1), M = R(!1), L = R(!1), E = R(!1), P = R(null), D = fe(() => {
8011
+ const g = R(!1), w = R(null), k = R(null), x = R(!1), T = R(!1), v = R(!1), N = R(!1), M = R(!1), L = R(!1), E = R(!1), P = R(null), D = fe(() => {
8012
8012
  const F = c.current?.ownerDocument.defaultView;
8013
8013
  w.current !== null && F?.clearTimeout(w.current), w.current = null;
8014
8014
  }, []), C = fe(() => {
@@ -8016,9 +8016,9 @@ function ll({
8016
8016
  }, []), S = fe(() => c.current?.querySelector(
8017
8017
  'button, a[href], input, select, textarea, summary, [contenteditable="true"], [tabindex]:not([tabindex="-1"])'
8018
8018
  )?.matches(':disabled, [aria-disabled="true"]') ?? !1, []), O = fe((F = !1) => {
8019
- D(), C(), b.current = !1, s(!F), i(!1);
8019
+ D(), C(), g.current = !1, s(!F), i(!1);
8020
8020
  }, [D, C]), B = fe((F) => {
8021
- D(), !(M.current || S()) && (b.current = !0, s(F), i(!0));
8021
+ D(), !(M.current || S()) && (g.current = !0, s(F), i(!0));
8022
8022
  }, [D, S]), A = fe(() => x.current || T.current || v.current || N.current || k.current !== null, []), U = fe((F = !1) => {
8023
8023
  A() || (O(F), L.current || (M.current = !1));
8024
8024
  }, [A, O]), K = fe(() => {
@@ -8036,7 +8036,7 @@ function ll({
8036
8036
  gap: H,
8037
8037
  margin: H
8038
8038
  });
8039
- d(ee.placement), g({ left: ee.left, top: ee.top, originX: ee.originX, originY: ee.originY }), u(!0);
8039
+ d(ee.placement), b({ left: ee.left, top: ee.top, originX: ee.originX, originY: ee.originY }), u(!0);
8040
8040
  }, [r, t]);
8041
8041
  ie(() => {
8042
8042
  const F = c.current;
@@ -8076,7 +8076,7 @@ function ll({
8076
8076
  if (!F) return null;
8077
8077
  const W = yr(F.ownerDocument, y.current), re = W.indexOf(F), H = re >= 0 ? W[re + 1] : void 0;
8078
8078
  return H?.focus(), H ?? null;
8079
- }, []), X = fe((F, W = !1) => b.current ? (M.current = !0, L.current = W, O(!0), F && Q(), !0) : !1, [Q, O]);
8079
+ }, []), X = fe((F, W = !1) => g.current ? (M.current = !0, L.current = W, O(!0), F && Q(), !0) : !1, [Q, O]);
8080
8080
  ie(() => {
8081
8081
  if (!o) return;
8082
8082
  const F = c.current;
@@ -8112,7 +8112,7 @@ function ll({
8112
8112
  }
8113
8113
  function z(F, W) {
8114
8114
  const re = c.current, H = y.current, ee = re?.ownerDocument;
8115
- if (!re || !H || !ee || !b.current) return !1;
8115
+ if (!re || !H || !ee || !g.current) return !1;
8116
8116
  const j = re.getBoundingClientRect(), se = H.getBoundingClientRect();
8117
8117
  if (!ne(j, se, F, W) && !Ot(j, F, W) && !Ot(se, F, W)) return !1;
8118
8118
  C();
@@ -8123,7 +8123,7 @@ function ll({
8123
8123
  return ee.addEventListener("pointermove", be, { passive: !0 }), k.current = () => ee.removeEventListener("pointermove", be), !0;
8124
8124
  }
8125
8125
  function te(F) {
8126
- F.pointerType !== "mouse" || S() || !F.currentTarget.ownerDocument.defaultView?.matchMedia("(hover: hover) and (pointer: fine)").matches || (x.current = !0, M.current = !1, L.current = !1, C(), !b.current && (D(), w.current = F.currentTarget.ownerDocument.defaultView.setTimeout(() => {
8126
+ F.pointerType !== "mouse" || S() || !F.currentTarget.ownerDocument.defaultView?.matchMedia("(hover: hover) and (pointer: fine)").matches || (x.current = !0, M.current = !1, L.current = !1, C(), !g.current && (D(), w.current = F.currentTarget.ownerDocument.defaultView.setTimeout(() => {
8127
8127
  w.current = null, x.current && !M.current && B(!0);
8128
8128
  }, sl)));
8129
8129
  }
@@ -8141,7 +8141,7 @@ function ll({
8141
8141
  E.current = !1, v.current = !1, !(W && y.current?.contains(W)) && U(!0);
8142
8142
  }
8143
8143
  function Z(F) {
8144
- S() || (E.current = !1, M.current = !1, L.current = !1, b.current ? X(!1) : B(F.detail > 0));
8144
+ S() || (E.current = !1, M.current = !1, L.current = !1, g.current ? X(!1) : B(F.detail > 0));
8145
8145
  }
8146
8146
  return {
8147
8147
  open: o,
@@ -8160,7 +8160,7 @@ function ll({
8160
8160
  onTriggerBlur: V,
8161
8161
  onTriggerClick: Z,
8162
8162
  onTriggerKeyDown(F) {
8163
- if ((F.key === "Enter" || F.key === " ") && (M.current = !1, L.current = !1), F.key !== "Tab" || F.shiftKey || !b.current) return;
8163
+ if ((F.key === "Enter" || F.key === " ") && (M.current = !1, L.current = !1), F.key !== "Tab" || F.shiftKey || !g.current) return;
8164
8164
  const W = y.current?.querySelector(".context-card__action");
8165
8165
  W && (F.preventDefault(), W.focus());
8166
8166
  },
@@ -8198,7 +8198,7 @@ function Au({
8198
8198
  align: l = "start",
8199
8199
  children: u
8200
8200
  }) {
8201
- const d = `context-card-${me().replace(/:/g, "")}`, f = ll({ id: d, placement: s, align: l }), g = ce(
8201
+ const d = `context-card-${me().replace(/:/g, "")}`, f = ll({ id: d, placement: s, align: l }), b = ce(
8202
8202
  "context-card-wrap",
8203
8203
  `context-card-wrap--${s}`,
8204
8204
  l !== "start" ? `context-card-wrap--align-${l}` : "",
@@ -8216,20 +8216,20 @@ function Au({
8216
8216
  Qt(u) && u.type !== Be && cl(u) ? p = on(u, {
8217
8217
  ...h,
8218
8218
  className: ce("context-card__trigger", u.props.className),
8219
- onFocus: (b) => {
8220
- u.props.onFocus?.(b), f.onTriggerFocus();
8219
+ onFocus: (g) => {
8220
+ u.props.onFocus?.(g), f.onTriggerFocus();
8221
8221
  },
8222
- onBlur: (b) => {
8223
- u.props.onBlur?.(b), f.onTriggerBlur(b);
8222
+ onBlur: (g) => {
8223
+ u.props.onBlur?.(g), f.onTriggerBlur(g);
8224
8224
  },
8225
- onPointerDown: (b) => {
8226
- u.props.onPointerDown?.(b), f.onPointerDown(b);
8225
+ onPointerDown: (g) => {
8226
+ u.props.onPointerDown?.(g), f.onPointerDown(g);
8227
8227
  },
8228
- onClick: (b) => {
8229
- u.props.onClick?.(b), b.defaultPrevented || f.onTriggerClick(b);
8228
+ onClick: (g) => {
8229
+ u.props.onClick?.(g), g.defaultPrevented || f.onTriggerClick(g);
8230
8230
  },
8231
- onKeyDown: (b) => {
8232
- u.props.onKeyDown?.(b), b.defaultPrevented || f.onTriggerKeyDown(b);
8231
+ onKeyDown: (g) => {
8232
+ u.props.onKeyDown?.(g), g.defaultPrevented || f.onTriggerKeyDown(g);
8233
8233
  }
8234
8234
  }) : p = /* @__PURE__ */ n(
8235
8235
  "button",
@@ -8272,17 +8272,17 @@ function Au({
8272
8272
  children: [
8273
8273
  /* @__PURE__ */ n("span", { className: "context-card__name", children: e }),
8274
8274
  /* @__PURE__ */ n("span", { className: "context-card__identity", children: t }),
8275
- /* @__PURE__ */ n("dl", { className: "context-card__rows", children: r.map(([b, w], k) => /* @__PURE__ */ _("div", { className: "context-card__row", children: [
8276
- /* @__PURE__ */ n("dt", { className: "context-card__key", children: b }),
8275
+ /* @__PURE__ */ n("dl", { className: "context-card__rows", children: r.map(([g, w], k) => /* @__PURE__ */ _("div", { className: "context-card__row", children: [
8276
+ /* @__PURE__ */ n("dt", { className: "context-card__key", children: g }),
8277
8277
  /* @__PURE__ */ n("dd", { className: "context-card__value", children: w })
8278
- ] }, `${b}-${k}`)) }),
8278
+ ] }, `${g}-${k}`)) }),
8279
8279
  o && i ? /* @__PURE__ */ n(
8280
8280
  "button",
8281
8281
  {
8282
8282
  type: "button",
8283
8283
  className: "context-card__action",
8284
- onClick: (b) => {
8285
- f.dismiss(!0, !0), i(b);
8284
+ onClick: (g) => {
8285
+ f.dismiss(!0, !0), i(g);
8286
8286
  },
8287
8287
  children: o
8288
8288
  }
@@ -8294,11 +8294,11 @@ function Au({
8294
8294
  "span",
8295
8295
  {
8296
8296
  ref: f.wrapRef,
8297
- className: g,
8297
+ className: b,
8298
8298
  onPointerEnter: f.onPointerEnter,
8299
8299
  onPointerLeave: f.onPointerLeave,
8300
- onKeyDown: (b) => {
8301
- b.key === "Escape" && f.dismiss(!0);
8300
+ onKeyDown: (g) => {
8301
+ g.key === "Escape" && f.dismiss(!0);
8302
8302
  },
8303
8303
  children: [
8304
8304
  p,
@@ -8349,13 +8349,13 @@ function Fu({
8349
8349
  className: m,
8350
8350
  style: d,
8351
8351
  onLostPointerCapture: f,
8352
- onPointerCancel: g,
8352
+ onPointerCancel: b,
8353
8353
  onPointerDown: h,
8354
8354
  onPointerLeave: p,
8355
8355
  onPointerUp: c,
8356
8356
  ...y
8357
8357
  }) {
8358
- const b = ce("book", `book--${t}`, l ? "book--textured" : "", m), w = typeof u == "number" ? Number.isFinite(u) && u > 0 ? `${u}px` : void 0 : u, k = {
8358
+ const g = ce("book", `book--${t}`, l ? "book--textured" : "", m), w = typeof u == "number" ? Number.isFinite(u) && u > 0 ? `${u}px` : void 0 : u, k = {
8359
8359
  ...d,
8360
8360
  ...r ? { "--book-cover": r } : null,
8361
8361
  ...o ? { "--book-band": o } : null,
@@ -8363,12 +8363,12 @@ function Fu({
8363
8363
  ...w ? { "--book-width": w } : null
8364
8364
  }, x = a ? /* @__PURE__ */ n("span", { className: "book__icon", "aria-hidden": "true", inert: !0, children: a }) : null, T = ul({
8365
8365
  onLostPointerCapture: f,
8366
- onPointerCancel: g,
8366
+ onPointerCancel: b,
8367
8367
  onPointerDown: h,
8368
8368
  onPointerLeave: p,
8369
8369
  onPointerUp: c
8370
8370
  });
8371
- return /* @__PURE__ */ n("div", { className: b, style: k, ...y, ...T, children: /* @__PURE__ */ _("div", { className: "book__inner", children: [
8371
+ return /* @__PURE__ */ n("div", { className: g, style: k, ...y, ...T, children: /* @__PURE__ */ _("div", { className: "book__inner", children: [
8372
8372
  /* @__PURE__ */ _("div", { className: "book__cover", children: [
8373
8373
  s ? /* @__PURE__ */ n("span", { className: "book__illustration", "aria-hidden": "true", inert: !0, children: s }) : null,
8374
8374
  t === "stripe" && !s ? /* @__PURE__ */ n("span", { className: "book__band", "aria-hidden": "true", children: x }) : null,
@@ -8398,24 +8398,24 @@ function fl({ className: e } = {}) {
8398
8398
  }
8399
8399
  const ml = typeof document > "u" ? ie : pe;
8400
8400
  function pl({ address: e, className: t }) {
8401
- const r = e.lastIndexOf("/"), o = r > 0 ? e.slice(0, r) : e, i = r > 0 ? e.slice(r) : "", [a, s] = Y("idle"), [l, u] = Y("instant"), [m, d] = Y(!1), f = R(void 0), g = R(0), h = R(void 0), p = R(!0), c = R(e), y = c.current !== e, b = y ? "idle" : a;
8401
+ const r = e.lastIndexOf("/"), o = r > 0 ? e.slice(0, r) : e, i = r > 0 ? e.slice(r) : "", [a, s] = Y("idle"), [l, u] = Y("instant"), [m, d] = Y(!1), f = R(void 0), b = R(0), h = R(void 0), p = R(!0), c = R(e), y = c.current !== e, g = y ? "idle" : a;
8402
8402
  ie(() => (p.current = !0, () => {
8403
- p.current = !1, g.current += 1, h.current = void 0, clearTimeout(f.current);
8403
+ p.current = !1, b.current += 1, h.current = void 0, clearTimeout(f.current);
8404
8404
  }), []), ml(() => {
8405
- c.current !== e && (c.current = e, g.current += 1, h.current = void 0, clearTimeout(f.current), u("instant"), d(!1), s("idle"));
8405
+ c.current !== e && (c.current = e, b.current += 1, h.current = void 0, clearTimeout(f.current), u("instant"), d(!1), s("idle"));
8406
8406
  }, [e]);
8407
8407
  const w = async (T) => {
8408
8408
  if (h.current !== void 0) return;
8409
8409
  clearTimeout(f.current);
8410
- const v = g.current + 1;
8411
- g.current = v, h.current = v, u(T.detail === 0 ? "instant" : "pointer"), s("pending");
8410
+ const v = b.current + 1;
8411
+ b.current = v, h.current = v, u(T.detail === 0 ? "instant" : "pointer"), s("pending");
8412
8412
  try {
8413
- if (await Zr(e), !p.current || v !== g.current) return;
8413
+ if (await Zr(e), !p.current || v !== b.current) return;
8414
8414
  s("success"), f.current = setTimeout(() => {
8415
- p.current && v === g.current && s("idle");
8415
+ p.current && v === b.current && s("idle");
8416
8416
  }, 1500);
8417
8417
  } catch {
8418
- if (!p.current || v !== g.current) return;
8418
+ if (!p.current || v !== b.current) return;
8419
8419
  s("error");
8420
8420
  } finally {
8421
8421
  h.current === v && (h.current = void 0);
@@ -8424,8 +8424,8 @@ function pl({ address: e, className: t }) {
8424
8424
  function k(T) {
8425
8425
  T.isPrimary && T.button === 0 && h.current === void 0 && d(!0);
8426
8426
  }
8427
- const x = b === "success" ? "已复制网址" : b === "error" ? "无法复制网址,请手动选择网址。" : "";
8428
- return /* @__PURE__ */ _("span", { className: ce("browser__address", t), "data-status": b, children: [
8427
+ const x = g === "success" ? "已复制网址" : g === "error" ? "无法复制网址,请手动选择网址。" : "";
8428
+ return /* @__PURE__ */ _("span", { className: ce("browser__address", t), "data-status": g, children: [
8429
8429
  /* @__PURE__ */ _("span", { className: "browser__url", title: e, translate: "no", children: [
8430
8430
  /* @__PURE__ */ n("span", { className: "browser__url-head", children: o }),
8431
8431
  i ? /* @__PURE__ */ n("span", { className: "browser__url-tail", children: i }) : null
@@ -8442,10 +8442,10 @@ function pl({ address: e, className: t }) {
8442
8442
  onPointerLeave: () => d(!1),
8443
8443
  onBlur: () => d(!1),
8444
8444
  "aria-label": "复制网址",
8445
- "aria-busy": b === "pending" || void 0,
8446
- "aria-disabled": b === "pending" || void 0,
8447
- title: b === "error" ? "无法复制网址,请手动选择网址。" : void 0,
8448
- "data-status": b,
8445
+ "aria-busy": g === "pending" || void 0,
8446
+ "aria-disabled": g === "pending" || void 0,
8447
+ title: g === "error" ? "无法复制网址,请手动选择网址。" : void 0,
8448
+ "data-status": g,
8449
8449
  "data-motion": y ? "instant" : l,
8450
8450
  "data-pointer-pressed": m ? "true" : void 0,
8451
8451
  children: [
@@ -8491,9 +8491,9 @@ const Eo = (e) => e !== void 0 && Number.isFinite(e) && e > 0 ? e : void 0, Io =
8491
8491
  return t ? new RegExp("\\p{Script=Han}", "u").test(t[0]) ? t[0] : t.split(/\s+/).slice(0, 2).map((r) => r[0]).join("").toUpperCase() : "";
8492
8492
  };
8493
8493
  function gl({ title: e, src: t, letter: r, glyph: o, placeholder: i = !1, icon: a, iconColor: s, size: l, className: u }) {
8494
- const [m, d] = Y(null), f = Eo(l), g = !!t && m !== t, h = e.trim() || "头像", p = r ? { variant: "avatar--letter", node: r } : o ? { variant: "avatar--glyph", node: o } : { variant: "avatar--letter", node: bl(e) }, c = i ? "avatar--placeholder" : g ? "avatar--image" : p.variant, y = i ? { "aria-hidden": !0 } : g ? {} : { role: "img", "aria-label": h };
8494
+ const [m, d] = Y(null), f = Eo(l), b = !!t && m !== t, h = e.trim() || "头像", p = r ? { variant: "avatar--letter", node: r } : o ? { variant: "avatar--glyph", node: o } : { variant: "avatar--letter", node: bl(e) }, c = i ? "avatar--placeholder" : b ? "avatar--image" : p.variant, y = i ? { "aria-hidden": !0 } : b ? {} : { role: "img", "aria-label": h };
8495
8495
  return /* @__PURE__ */ _("span", { className: ce("avatar", c, u), style: Io(f), ...y, children: [
8496
- g ? /* @__PURE__ */ n(
8496
+ b ? /* @__PURE__ */ n(
8497
8497
  "img",
8498
8498
  {
8499
8499
  className: "avatar__img",
@@ -8524,11 +8524,11 @@ function Wu({
8524
8524
  reverse: a = !1,
8525
8525
  className: s
8526
8526
  }) {
8527
- const l = Eo(r), u = l ?? 32, m = o !== void 0 && Number.isFinite(o) && o >= 0 ? Math.floor(o) : void 0, d = m !== void 0 && e.length > m ? e.slice(0, m) : e, f = e.length - d.length, g = d.length + (f > 0 ? 1 : 0), h = i !== "auto" && Number.isFinite(i) ? Math.max(0, i) : Math.round(u * 0.3), p = { ...Io(l), "--q1-avatar-overlap": `${h}px` }, c = (b) => a ? void 0 : g - 1 - b, y = t ? { role: "group", "aria-label": t } : {};
8527
+ const l = Eo(r), u = l ?? 32, m = o !== void 0 && Number.isFinite(o) && o >= 0 ? Math.floor(o) : void 0, d = m !== void 0 && e.length > m ? e.slice(0, m) : e, f = e.length - d.length, b = d.length + (f > 0 ? 1 : 0), h = i !== "auto" && Number.isFinite(i) ? Math.max(0, i) : Math.round(u * 0.3), p = { ...Io(l), "--q1-avatar-overlap": `${h}px` }, c = (g) => a ? void 0 : b - 1 - g, y = t ? { role: "group", "aria-label": t } : {};
8528
8528
  return /* @__PURE__ */ _("span", { className: ce("avatar-group", s), style: p, ...y, children: [
8529
- d.map((b, w) => (
8529
+ d.map((g, w) => (
8530
8530
  // 成员不再 aria-hidden——每个 Avatar 自带 aria-label(名字),读屏逐个念。
8531
- /* @__PURE__ */ n("span", { className: "avatar-group__item", style: { zIndex: c(w) }, children: /* @__PURE__ */ n(gl, { ...b, size: l }) }, `${b.title}-${w}`)
8531
+ /* @__PURE__ */ n("span", { className: "avatar-group__item", style: { zIndex: c(w) }, children: /* @__PURE__ */ n(gl, { ...g, size: l }) }, `${g.title}-${w}`)
8532
8532
  )),
8533
8533
  f > 0 ? (
8534
8534
  // +N 独立可访问名「还有 N 位成员」,不再 aria-hidden。
@@ -8706,11 +8706,11 @@ function ju({
8706
8706
  size: o = "default"
8707
8707
  }) {
8708
8708
  const { copied: i, copy: a } = An(), s = t ?? e, l = R(0), [u, m] = Y("instant");
8709
- function d(g) {
8710
- m(l.current > 0 ? "instant" : g);
8709
+ function d(b) {
8710
+ m(l.current > 0 ? "instant" : b);
8711
8711
  }
8712
- async function f(g) {
8713
- const h = g.detail === 0 ? "instant" : "pointer";
8712
+ async function f(b) {
8713
+ const h = b.detail === 0 ? "instant" : "pointer";
8714
8714
  l.current += 1, m(l.current > 1 ? "instant" : h);
8715
8715
  try {
8716
8716
  await a(s, r);
@@ -8727,8 +8727,8 @@ function ju({
8727
8727
  className: "twc__copy",
8728
8728
  "aria-label": `复制${e}`,
8729
8729
  onPointerDown: () => d("pointer"),
8730
- onKeyDown: (g) => {
8731
- (g.key === "Enter" || g.key === " ") && d("instant");
8730
+ onKeyDown: (b) => {
8731
+ (b.key === "Enter" || b.key === " ") && d("instant");
8732
8732
  },
8733
8733
  onClick: f,
8734
8734
  children: [
@@ -8756,19 +8756,19 @@ function Yu({
8756
8756
  onCopy: a
8757
8757
  }) {
8758
8758
  const { copied: s, copy: l, reset: u } = An({ success: "inline", resetAfterMs: 2e3 }), m = Array.isArray(e) ? e : [e], d = i ?? m.join(`
8759
- `), f = o ? Cl[o] : void 0, g = ce("snippet", r ? "snippet--inverted" : "", o ? `snippet--${o}` : ""), h = R(d), p = h.current !== d, c = R(!1), y = R(!1), [b, w] = Y(!1), [k, x] = Y(!1), [T, v] = Y("instant");
8759
+ `), f = o ? Cl[o] : void 0, b = ce("snippet", r ? "snippet--inverted" : "", o ? `snippet--${o}` : ""), h = R(d), p = h.current !== d, c = R(!1), y = R(!1), [g, w] = Y(!1), [k, x] = Y(!1), [T, v] = Y("instant");
8760
8760
  ie(() => (y.current = !0, () => {
8761
8761
  y.current = !1;
8762
8762
  }), []), Pl(() => {
8763
8763
  h.current !== d && (h.current = d, v("instant"), u());
8764
8764
  }, [u, d]), ie(() => {
8765
- if (!b) {
8765
+ if (!g) {
8766
8766
  x(!1);
8767
8767
  return;
8768
8768
  }
8769
8769
  const L = window.setTimeout(() => x(!0), 200);
8770
8770
  return () => window.clearTimeout(L);
8771
- }, [b]);
8771
+ }, [g]);
8772
8772
  function N(L) {
8773
8773
  c.current || v(L);
8774
8774
  }
@@ -8780,7 +8780,7 @@ function Yu({
8780
8780
  };
8781
8781
  E.then(P, P), a?.();
8782
8782
  }
8783
- return /* @__PURE__ */ _("div", { className: g, children: [
8783
+ return /* @__PURE__ */ _("div", { className: b, children: [
8784
8784
  f ? /* @__PURE__ */ _("span", { className: "snippet__tone", children: [
8785
8785
  /* @__PURE__ */ n(f.Icon, { size: 16, strokeWidth: oe, "aria-hidden": "true" }),
8786
8786
  /* @__PURE__ */ _("span", { className: "q1-sr-only", children: [
@@ -8801,8 +8801,8 @@ function Yu({
8801
8801
  type: "button",
8802
8802
  className: "snippet__copy",
8803
8803
  "aria-label": "复制命令",
8804
- "aria-busy": b || void 0,
8805
- "aria-disabled": b || void 0,
8804
+ "aria-busy": g || void 0,
8805
+ "aria-disabled": g || void 0,
8806
8806
  onPointerDown: () => N("pointer"),
8807
8807
  onKeyDown: (L) => {
8808
8808
  (L.key === "Enter" || L.key === " ") && N("instant");
@@ -8814,7 +8814,7 @@ function Yu({
8814
8814
  className: "snippet__copy-icon",
8815
8815
  "data-copied": !p && s,
8816
8816
  "data-motion": p ? "instant" : T,
8817
- "data-pending": b && k || void 0,
8817
+ "data-pending": g && k || void 0,
8818
8818
  "aria-hidden": "true",
8819
8819
  children: [
8820
8820
  /* @__PURE__ */ n(sn, { className: "snippet__copy-glyph snippet__copy-glyph--copy", size: 14, strokeWidth: oe }),
@@ -8856,7 +8856,7 @@ function Xu({
8856
8856
  label: a,
8857
8857
  indeterminate: s = !1
8858
8858
  }) {
8859
- const { boxPx: l, radius: u, strokeWidth: m, valueFontSize: d } = El[t], f = 2 * Math.PI * u, g = typeof e == "number" && Number.isFinite(e) ? Math.min(100, Math.max(0, e)) : 0, h = 50, p = s ? 25 : g, c = s ? 0 : Tl(g, m, f), y = s ? 0 : Math.max(0, 100 - g - c), b = -90 + (p + c / 2) / 100 * 360, w = s ? "primary" : Ml(g, i, o);
8859
+ const { boxPx: l, radius: u, strokeWidth: m, valueFontSize: d } = El[t], f = 2 * Math.PI * u, b = typeof e == "number" && Number.isFinite(e) ? Math.min(100, Math.max(0, e)) : 0, h = 50, p = s ? 25 : b, c = s ? 0 : Tl(b, m, f), y = s ? 0 : Math.max(0, 100 - b - c), g = -90 + (p + c / 2) / 100 * 360, w = s ? "primary" : Ml(b, i, o);
8860
8860
  return /* @__PURE__ */ _(
8861
8861
  "span",
8862
8862
  {
@@ -8865,7 +8865,7 @@ function Xu({
8865
8865
  "aria-label": a,
8866
8866
  "aria-valuemin": s ? void 0 : 0,
8867
8867
  "aria-valuemax": s ? void 0 : 100,
8868
- "aria-valuenow": s ? void 0 : g,
8868
+ "aria-valuenow": s ? void 0 : b,
8869
8869
  children: [
8870
8870
  /* @__PURE__ */ _("svg", { className: "gauge__svg", width: l, height: l, viewBox: "0 0 100 100", "aria-hidden": "true", children: [
8871
8871
  y > 0 ? /* @__PURE__ */ n(
@@ -8879,7 +8879,7 @@ function Xu({
8879
8879
  fill: "none",
8880
8880
  strokeLinecap: "round",
8881
8881
  strokeDasharray: `${y / 100 * f} ${f}`,
8882
- transform: `rotate(${b} ${h} ${h})`
8882
+ transform: `rotate(${g} ${h} ${h})`
8883
8883
  }
8884
8884
  ) : null,
8885
8885
  p > 0 ? /* @__PURE__ */ n(
@@ -8897,7 +8897,7 @@ function Xu({
8897
8897
  }
8898
8898
  ) : null
8899
8899
  ] }),
8900
- !s && r && d ? /* @__PURE__ */ n("span", { className: "gauge__value", style: { fontSize: d }, children: g }) : null
8900
+ !s && r && d ? /* @__PURE__ */ n("span", { className: "gauge__value", style: { fontSize: d }, children: b }) : null
8901
8901
  ]
8902
8902
  }
8903
8903
  );
@@ -8913,9 +8913,9 @@ function Sl({
8913
8913
  const s = Number.isFinite(t) && t > 0 ? t : 100, l = e === null, u = typeof e == "number" && Number.isFinite(e) ? Math.min(s, Math.max(0, e)) : 0, m = u / s * 100, d = (l ? [] : i ?? []).flatMap((h) => {
8914
8914
  const p = typeof h == "number" ? h : h.at;
8915
8915
  return p > 0 && p < 100 ? [{ at: p, label: typeof h == "number" ? `${h}%` : h.label ?? `${h.at}%` }] : [];
8916
- }), f = d.map(({ at: h }) => h).sort((h, p) => h - p), g = (h) => {
8917
- const p = f.indexOf(h), c = p > 0 ? (h - f[p - 1]) / 2 : h, y = p < f.length - 1 ? (f[p + 1] - h) / 2 : 100 - h, b = Math.min(c, y);
8918
- return { marginInlineStart: `${h - b}%`, width: `${b * 2}%` };
8916
+ }), f = d.map(({ at: h }) => h).sort((h, p) => h - p), b = (h) => {
8917
+ const p = f.indexOf(h), c = p > 0 ? (h - f[p - 1]) / 2 : h, y = p < f.length - 1 ? (f[p + 1] - h) / 2 : 100 - h, g = Math.min(c, y);
8918
+ return { marginInlineStart: `${h - g}%`, width: `${g * 2}%` };
8919
8919
  };
8920
8920
  return /* @__PURE__ */ _("div", { className: `progress${l ? " progress--indeterminate" : ""}${o ? " progress--slim" : ""}${d.length > 0 ? " progress--with-stages" : ""}`, children: [
8921
8921
  /* @__PURE__ */ _(
@@ -8942,7 +8942,7 @@ function Sl({
8942
8942
  ]
8943
8943
  }
8944
8944
  ),
8945
- d.length > 0 ? /* @__PURE__ */ n("ol", { className: "progress__stage-list", children: d.map(({ at: h, label: p }, c) => /* @__PURE__ */ _("li", { className: "progress__stage", style: g(h), children: [
8945
+ d.length > 0 ? /* @__PURE__ */ n("ol", { className: "progress__stage-list", children: d.map(({ at: h, label: p }, c) => /* @__PURE__ */ _("li", { className: "progress__stage", style: b(h), children: [
8946
8946
  /* @__PURE__ */ _("span", { className: "progress__stage-position", children: [
8947
8947
  h,
8948
8948
  "%"
@@ -9133,20 +9133,20 @@ function Zu({
9133
9133
  pageSizeSlot: m,
9134
9134
  prevLabel: d = "上一页",
9135
9135
  nextLabel: f = "下一页",
9136
- compact: g = !1,
9136
+ compact: b = !1,
9137
9137
  className: h = ""
9138
9138
  }) {
9139
- const [p, c] = Y(""), [y, b] = Y(), w = R(s), k = Ol(t), x = Number.isFinite(r) && Number(r) >= 0, T = Bl({
9139
+ const [p, c] = Y(""), [y, g] = Y(), w = R(s), k = Ol(t), x = Number.isFinite(r) && Number(r) >= 0, T = Bl({
9140
9140
  totalPages: o,
9141
9141
  total: r,
9142
9142
  pageSize: k
9143
- }), v = T ? Math.min(Nr(e), T) : Nr(e), N = x && Number(r) <= 0 || o === 0, M = x ? Kl(v, k, Number(r)) : null, L = !x && o === void 0, E = !N && v > 1, P = !N && (L ? i === !0 : T !== void 0 && v < T), D = l && !L && T ? Wl(v, T, g) : [], C = ["pagination", g ? "pagination--compact" : "", h].filter(Boolean).join(" "), S = String(T ?? 1).length, O = S <= 3 ? "pagination__page-buttons--short" : S <= 6 ? "pagination__page-buttons--medium" : S <= 10 ? "pagination__page-buttons--long" : "pagination__page-buttons--extra-long", B = () => b(void 0), A = (K, Q) => {
9144
- !Q.isPrimary || Q.button !== 0 || s || N || b(K);
9143
+ }), v = T ? Math.min(Nr(e), T) : Nr(e), N = x && Number(r) <= 0 || o === 0, M = x ? Kl(v, k, Number(r)) : null, L = !x && o === void 0, E = !N && v > 1, P = !N && (L ? i === !0 : T !== void 0 && v < T), D = l && !L && T ? Wl(v, T, b) : [], C = ["pagination", b ? "pagination--compact" : "", h].filter(Boolean).join(" "), S = String(T ?? 1).length, O = S <= 3 ? "pagination__page-buttons--short" : S <= 6 ? "pagination__page-buttons--medium" : S <= 10 ? "pagination__page-buttons--long" : "pagination__page-buttons--extra-long", B = () => g(void 0), A = (K, Q) => {
9144
+ !Q.isPrimary || Q.button !== 0 || s || N || g(K);
9145
9145
  };
9146
9146
  return ie(() => {
9147
9147
  w.current && !s ? c("分页已更新") : s && c(""), w.current = s;
9148
9148
  }, [s]), ie(() => {
9149
- (s || N) && b(void 0);
9149
+ (s || N) && g(void 0);
9150
9150
  }, [N, s]), /* @__PURE__ */ _("nav", { className: C, "aria-label": "分页导航", "aria-busy": s ? "true" : void 0, children: [
9151
9151
  /* @__PURE__ */ n("span", { className: "pagination__summary", "aria-live": "polite", "aria-atomic": "true", children: typeof u == "function" ? u({
9152
9152
  page: v,
@@ -9277,12 +9277,12 @@ function Ju({
9277
9277
  renderRow: m,
9278
9278
  showHeader: d = !0,
9279
9279
  sortKey: f,
9280
- sortDirection: g,
9280
+ sortDirection: b,
9281
9281
  onSortChange: h,
9282
9282
  selection: p,
9283
9283
  actions: c,
9284
9284
  bulkActions: y,
9285
- bulkActionsLabel: b = "批量操作",
9285
+ bulkActionsLabel: g = "批量操作",
9286
9286
  rowActivation: w,
9287
9287
  className: k,
9288
9288
  style: x,
@@ -9319,14 +9319,14 @@ function Ju({
9319
9319
  !w || Cr(I.target, I.currentTarget) || I.key !== "Enter" && I.key !== " " || (I.preventDefault(), w.onActivate($.row, $.rowIndex));
9320
9320
  }
9321
9321
  function G($) {
9322
- return $.nextSortDirection ?? (f === $.key && g === "asc" ? "desc" : "asc");
9322
+ return $.nextSortDirection ?? (f === $.key && b === "asc" ? "desc" : "asc");
9323
9323
  }
9324
9324
  function X($) {
9325
9325
  h && h($.key, G($));
9326
9326
  }
9327
9327
  function ne($) {
9328
9328
  if ($.sortable)
9329
- return f !== $.key ? "none" : g === "asc" ? "ascending" : g === "desc" ? "descending" : "none";
9329
+ return f !== $.key ? "none" : b === "asc" ? "ascending" : b === "desc" ? "descending" : "none";
9330
9330
  }
9331
9331
  const z = /* @__PURE__ */ _("table", { ...T, className: D, style: C, children: [
9332
9332
  o != null ? /* @__PURE__ */ n("caption", { children: o }) : null,
@@ -9347,7 +9347,7 @@ function Ju({
9347
9347
  }
9348
9348
  ) }) }) : null,
9349
9349
  t.map(($) => {
9350
- const I = ne($), q = $.sortable && f === $.key && g ? g === "asc" ? "升序" : "降序" : null, V = G($) === "asc" ? "升序" : "降序", Z = q ? /* @__PURE__ */ n("span", { className: "table__sort-state", children: q }) : null, F = $.sortLabel ?? (typeof $.header == "string" ? $.header : $.key), W = $.sortable ? /* @__PURE__ */ _(
9350
+ const I = ne($), q = $.sortable && f === $.key && b ? b === "asc" ? "升序" : "降序" : null, V = G($) === "asc" ? "升序" : "降序", Z = q ? /* @__PURE__ */ n("span", { className: "table__sort-state", children: q }) : null, F = $.sortLabel ?? (typeof $.header == "string" ? $.header : $.key), W = $.sortable ? /* @__PURE__ */ _(
9351
9351
  "button",
9352
9352
  {
9353
9353
  type: "button",
@@ -9400,7 +9400,7 @@ function Ju({
9400
9400
  }) })
9401
9401
  ] }), te = B ? /* @__PURE__ */ n("div", { className: S, style: O, tabIndex: 0, children: z }) : z;
9402
9402
  return /* @__PURE__ */ _(ye, { children: [
9403
- y && p && p.selectedKeys.length > 0 ? /* @__PURE__ */ n("div", { className: "table__bulk-actions", role: "toolbar", "aria-label": b, children: y }) : null,
9403
+ y && p && p.selectedKeys.length > 0 ? /* @__PURE__ */ n("div", { className: "table__bulk-actions", role: "toolbar", "aria-label": g, children: y }) : null,
9404
9404
  te
9405
9405
  ] });
9406
9406
  }
@@ -9415,15 +9415,15 @@ function ed({
9415
9415
  onOpenChange: l,
9416
9416
  unit: u = "项"
9417
9417
  }) {
9418
- const [m, d] = Y(a), f = s !== void 0, g = f ? s : m, [h, p] = Y("keyboard"), [c, y] = Y(!1), b = me(), w = e ?? [], k = Math.min(
9418
+ const [m, d] = Y(a), f = s !== void 0, b = f ? s : m, [h, p] = Y("keyboard"), [c, y] = Y(!1), g = me(), w = e ?? [], k = Math.min(
9419
9419
  w.length,
9420
9420
  Math.max(0, Math.trunc(Number.isFinite(t) ? t : 4))
9421
- ), x = g ? w : w.slice(0, k), T = e === void 0, v = T ? o ?? 0 : w.length - k;
9421
+ ), x = b ? w : w.slice(0, k), T = e === void 0, v = T ? o ?? 0 : w.length - k;
9422
9422
  function N() {
9423
9423
  y(!1);
9424
9424
  }
9425
- return /* @__PURE__ */ _("div", { className: "show-more", "data-expanded": g, "data-input-modality": h, children: [
9426
- T ? null : /* @__PURE__ */ n("ul", { className: "show-more__list", id: b, children: x.map((M, L) => /* @__PURE__ */ n(
9425
+ return /* @__PURE__ */ _("div", { className: "show-more", "data-expanded": b, "data-input-modality": h, children: [
9426
+ T ? null : /* @__PURE__ */ n("ul", { className: "show-more__list", id: g, children: x.map((M, L) => /* @__PURE__ */ n(
9427
9427
  "li",
9428
9428
  {
9429
9429
  className: L >= k ? "show-more__row show-more__row--revealed" : "show-more__row",
@@ -9436,13 +9436,13 @@ function ed({
9436
9436
  {
9437
9437
  type: "button",
9438
9438
  className: "show-more__trigger",
9439
- "aria-expanded": g,
9440
- "aria-controls": T ? r : b,
9439
+ "aria-expanded": b,
9440
+ "aria-controls": T ? r : g,
9441
9441
  "data-pointer-pressed": c ? "true" : void 0,
9442
9442
  onBlur: () => N(),
9443
9443
  onClick: (M) => {
9444
9444
  M.detail === 0 && p("keyboard");
9445
- const L = !g;
9445
+ const L = !b;
9446
9446
  f || d(L), l?.(L);
9447
9447
  },
9448
9448
  onKeyDown: (M) => {
@@ -9455,7 +9455,7 @@ function ed({
9455
9455
  onPointerLeave: N,
9456
9456
  onPointerUp: N,
9457
9457
  children: [
9458
- g ? "收起" : `显示更多 ${v} ${u}`,
9458
+ b ? "收起" : `显示更多 ${v} ${u}`,
9459
9459
  /* @__PURE__ */ n(Ke, { className: "show-more__chevron", size: 16, strokeWidth: oe, "aria-hidden": "true" })
9460
9460
  ]
9461
9461
  }
@@ -9475,7 +9475,7 @@ function td({
9475
9475
  onKeyDown: m,
9476
9476
  ref: d,
9477
9477
  "aria-disabled": f,
9478
- ...g
9478
+ ...b
9479
9479
  }) {
9480
9480
  const h = R(!1), [p, c] = Y(), y = e && !i;
9481
9481
  return ie(() => {
@@ -9484,7 +9484,7 @@ function td({
9484
9484
  /* @__PURE__ */ n(
9485
9485
  "button",
9486
9486
  {
9487
- ...g,
9487
+ ...b,
9488
9488
  ref: d,
9489
9489
  type: a,
9490
9490
  className: ce(
@@ -9497,11 +9497,11 @@ function td({
9497
9497
  "aria-disabled": y ? !0 : f,
9498
9498
  disabled: i || void 0,
9499
9499
  "data-motion-input": p,
9500
- onKeyDown: (b) => {
9501
- (b.key === "Enter" || b.key === " ") && (h.current = !1, c(void 0)), m?.(b);
9500
+ onKeyDown: (g) => {
9501
+ (g.key === "Enter" || g.key === " ") && (h.current = !1, c(void 0)), m?.(g);
9502
9502
  },
9503
- onClick: e ? (b) => b.preventDefault() : (b) => {
9504
- h.current = !1, c(b.detail > 0 ? "pointer" : void 0), u?.(b);
9503
+ onClick: e ? (g) => g.preventDefault() : (g) => {
9504
+ h.current = !1, c(g.detail > 0 ? "pointer" : void 0), u?.(g);
9505
9505
  },
9506
9506
  children: /* @__PURE__ */ _("span", { className: "load-more-btn__content", children: [
9507
9507
  /* @__PURE__ */ n(
@@ -9509,8 +9509,8 @@ function td({
9509
9509
  {
9510
9510
  className: "load-more-btn__spinner-slot",
9511
9511
  "aria-hidden": "true",
9512
- onTransitionEnd: (b) => {
9513
- b.propertyName === "opacity" && !e && (h.current = !1, c(void 0));
9512
+ onTransitionEnd: (g) => {
9513
+ g.propertyName === "opacity" && !e && (h.current = !1, c(void 0));
9514
9514
  },
9515
9515
  children: /* @__PURE__ */ n(Fe, { className: "load-more-btn__spinner", size: 16, strokeWidth: oe, "aria-hidden": "true" })
9516
9516
  }
@@ -9541,11 +9541,11 @@ function nd({
9541
9541
  local: o,
9542
9542
  utc: i
9543
9543
  }) {
9544
- const [a, s] = Y(!1), [l, u] = Y(!1), [m, d] = Y(null), [f, g] = Y({ side: "top", left: 0, top: 0 }), [h, p] = Y(!1), c = R(null), y = R(null);
9544
+ const [a, s] = Y(!1), [l, u] = Y(!1), [m, d] = Y(null), [f, b] = Y({ side: "top", left: 0, top: 0 }), [h, p] = Y(!1), c = R(null), y = R(null);
9545
9545
  St(c, y, !!m);
9546
- const b = R(null), w = R(null), k = R(!1), x = R(null), T = R(!1), v = R(!1), N = R(!1), M = R(!1), L = `relative-time-card-${me().replace(/:/g, "")}`, E = `${L}-title`, P = Vl(r), D = fe(() => {
9546
+ const g = R(null), w = R(null), k = R(!1), x = R(null), T = R(!1), v = R(!1), N = R(!1), M = R(!1), L = `relative-time-card-${me().replace(/:/g, "")}`, E = `${L}-title`, P = Vl(r), D = fe(() => {
9547
9547
  const $ = c.current?.ownerDocument.defaultView;
9548
- b.current !== null && $ && $.clearTimeout(b.current), b.current = null;
9548
+ g.current !== null && $ && $.clearTimeout(g.current), g.current = null;
9549
9549
  }, []), C = fe(() => {
9550
9550
  w.current?.(), w.current = null;
9551
9551
  }, []), S = fe(($) => {
@@ -9561,7 +9561,7 @@ function nd({
9561
9561
  const $ = c.current, I = y.current;
9562
9562
  if (!$ || !I) return;
9563
9563
  const q = 8, V = 8, Z = $.getBoundingClientRect(), F = I.offsetWidth, W = I.offsetHeight, re = $.ownerDocument, H = re.documentElement.clientWidth, ee = re.documentElement.clientHeight, j = Z.top - V - W >= q, se = Z.bottom + V + W <= ee - q, be = j || !se && Z.top >= ee - Z.bottom ? "top" : "bottom", de = Z.left + Z.width / 2 - F / 2, Ce = Math.max(q, Math.min(de, H - q - F)), Ie = be === "top" ? Z.top - V - W : Z.bottom + V, Me = Math.max(q, Math.min(Ie, ee - q - W));
9564
- g({ side: be, left: Ce, top: Me }), p(!0);
9564
+ b({ side: be, left: Ce, top: Me }), p(!0);
9565
9565
  }, []);
9566
9566
  ie(() => {
9567
9567
  const $ = c.current;
@@ -9599,7 +9599,7 @@ function nd({
9599
9599
  }, [L, B, O, a]), ie(() => {
9600
9600
  const $ = c.current?.ownerDocument.defaultView;
9601
9601
  return () => {
9602
- b.current !== null && $?.clearTimeout(b.current), x.current !== null && $?.clearTimeout(x.current), C();
9602
+ g.current !== null && $?.clearTimeout(g.current), x.current !== null && $?.clearTimeout(x.current), C();
9603
9603
  };
9604
9604
  }, [C]);
9605
9605
  function K($, I, q, V) {
@@ -9623,8 +9623,8 @@ function nd({
9623
9623
  }
9624
9624
  function G() {
9625
9625
  const $ = c.current?.ownerDocument.defaultView;
9626
- $?.matchMedia("(hover: hover) and (pointer: fine)").matches && (N.current = !1, T.current = !0, C(), !M.current && (D(), b.current = $.setTimeout(() => {
9627
- b.current = null, T.current && !N.current && S(!1);
9626
+ $?.matchMedia("(hover: hover) and (pointer: fine)").matches && (N.current = !1, T.current = !0, C(), !M.current && (D(), g.current = $.setTimeout(() => {
9627
+ g.current = null, T.current && !N.current && S(!1);
9628
9628
  }, 120)));
9629
9629
  }
9630
9630
  function X($) {
@@ -9731,8 +9731,8 @@ function To({ value: e, depth: t, path: r, collapsedDepth: o, highlight: i, seen
9731
9731
  d,
9732
9732
  /* @__PURE__ */ n("span", { className: "q1-json-view__primitive tok-comment", children: "<循环引用>" })
9733
9733
  ] });
9734
- const f = new Set(a).add(e), g = u ? e.map((L, E) => [String(E), L]) : Object.entries(e), h = o === void 0 || t < o, [p, c] = u ? ["[", "]"] : ["{", "}"];
9735
- if (g.length === 0)
9734
+ const f = new Set(a).add(e), b = u ? e.map((L, E) => [String(E), L]) : Object.entries(e), h = o === void 0 || t < o, [p, c] = u ? ["[", "]"] : ["{", "}"];
9735
+ if (b.length === 0)
9736
9736
  return /* @__PURE__ */ _(ye, { children: [
9737
9737
  d,
9738
9738
  /* @__PURE__ */ _("span", { className: "q1-json-view__punct", children: [
@@ -9740,7 +9740,7 @@ function To({ value: e, depth: t, path: r, collapsedDepth: o, highlight: i, seen
9740
9740
  c
9741
9741
  ] })
9742
9742
  ] });
9743
- const y = u ? `${g.length} 项` : `${g.length} 个键`, w = `${s === void 0 ? "根节点" : l ? `索引 ${s}` : `字段 ${s}`},${u ? "数组" : "对象"},${y}`;
9743
+ const y = u ? `${b.length} 项` : `${b.length} 个键`, w = `${s === void 0 ? "根节点" : l ? `索引 ${s}` : `字段 ${s}`},${u ? "数组" : "对象"},${y}`;
9744
9744
  function k(L) {
9745
9745
  delete L.dataset.pointerId, delete L.dataset.pointerPressed;
9746
9746
  }
@@ -9783,7 +9783,7 @@ function To({ value: e, depth: t, path: r, collapsedDepth: o, highlight: i, seen
9783
9783
  ]
9784
9784
  }
9785
9785
  ),
9786
- /* @__PURE__ */ n("ul", { className: "q1-json-view__list", children: g.map(([L, E]) => {
9786
+ /* @__PURE__ */ n("ul", { className: "q1-json-view__list", children: b.map(([L, E]) => {
9787
9787
  const P = Yl(r, L), D = i.has(P) || i.has(L);
9788
9788
  return /* @__PURE__ */ n(
9789
9789
  "li",
@@ -9867,7 +9867,7 @@ function od({
9867
9867
  loop: s = !1,
9868
9868
  muted: l = !1
9869
9869
  }) {
9870
- const u = i === "decorative", m = o || "视频", d = R(null), f = R(null), g = Gl(), [h, p] = Y(!u), [c, y] = Y("idle"), [b, w] = Y(!1);
9870
+ const u = i === "decorative", m = o || "视频", d = R(null), f = R(null), b = Gl(), [h, p] = Y(!u), [c, y] = Y("idle"), [g, w] = Y(!1);
9871
9871
  ie(() => {
9872
9872
  y("idle");
9873
9873
  }, [i, e]), ie(() => {
@@ -9875,7 +9875,7 @@ function od({
9875
9875
  p(!0);
9876
9876
  return;
9877
9877
  }
9878
- if (g) {
9878
+ if (b) {
9879
9879
  p(!1);
9880
9880
  return;
9881
9881
  }
@@ -9891,11 +9891,11 @@ function od({
9891
9891
  { rootMargin: "200px" }
9892
9892
  );
9893
9893
  return N.observe(v), () => N.disconnect();
9894
- }, [u, g]), ie(() => {
9895
- if (!u || !g) return;
9894
+ }, [u, b]), ie(() => {
9895
+ if (!u || !b) return;
9896
9896
  const v = f.current;
9897
9897
  v && (v.pause(), v.currentTime = 0, v.load(), y("idle"));
9898
- }, [u, g]), ie(() => {
9898
+ }, [u, b]), ie(() => {
9899
9899
  if (c !== "loading") {
9900
9900
  w(!1);
9901
9901
  return;
@@ -9923,7 +9923,7 @@ function od({
9923
9923
  ref: f,
9924
9924
  className: "ds-video",
9925
9925
  "data-purpose": i,
9926
- src: u && (!h || g) ? void 0 : e,
9926
+ src: u && (!h || b) ? void 0 : e,
9927
9927
  poster: t,
9928
9928
  width: 1280,
9929
9929
  height: 720,
@@ -9932,7 +9932,7 @@ function od({
9932
9932
  muted: u ? !0 : l,
9933
9933
  playsInline: !0,
9934
9934
  preload: u ? "metadata" : "none",
9935
- autoPlay: u && h && !g,
9935
+ autoPlay: u && h && !b,
9936
9936
  onWaiting: () => y("loading"),
9937
9937
  onPlaying: () => y("playing"),
9938
9938
  onPause: (v) => {
@@ -9959,7 +9959,7 @@ function od({
9959
9959
  ]
9960
9960
  }
9961
9961
  ),
9962
- !u && b ? /* @__PURE__ */ n("div", { className: "ds-video__status", role: "status", "aria-live": "polite", children: "正在加载视频…" }) : null,
9962
+ !u && g ? /* @__PURE__ */ n("div", { className: "ds-video__status", role: "status", "aria-live": "polite", children: "正在加载视频…" }) : null,
9963
9963
  u ? null : /* @__PURE__ */ _(
9964
9964
  "div",
9965
9965
  {
@@ -10114,7 +10114,7 @@ function Lo(e, t) {
10114
10114
  canScrollTop: d && s.scrollTop > 1,
10115
10115
  canScrollBottom: d && s.scrollTop < u - 1
10116
10116
  };
10117
- i((g) => oc(g, f) ? g : f);
10117
+ i((b) => oc(b, f) ? b : f);
10118
10118
  }, [e]);
10119
10119
  return pe(() => {
10120
10120
  const s = r.current;
@@ -10122,13 +10122,13 @@ function Lo(e, t) {
10122
10122
  const l = s, u = l.ownerDocument.defaultView, m = u?.ResizeObserver, d = u?.MutationObserver, f = m ? new m(() => {
10123
10123
  t?.(), a();
10124
10124
  }) : null;
10125
- function g() {
10125
+ function b() {
10126
10126
  f?.disconnect(), f?.observe(l), Array.from(l.children).forEach((p) => f?.observe(p));
10127
10127
  }
10128
10128
  const h = d ? new d(() => {
10129
- t?.(), g(), a();
10129
+ t?.(), b(), a();
10130
10130
  }) : null;
10131
- return g(), h?.observe(l, { childList: !0, characterData: !0, subtree: !0 }), a(), () => {
10131
+ return b(), h?.observe(l, { childList: !0, characterData: !0, subtree: !0 }), a(), () => {
10132
10132
  f?.disconnect(), h?.disconnect();
10133
10133
  };
10134
10134
  }, [a, t]), { viewportRef: r, scrollState: o, measure: a };
@@ -10169,11 +10169,11 @@ function sd({
10169
10169
  label: r,
10170
10170
  children: o
10171
10171
  }) {
10172
- const i = e === "horizontal", [a, s] = Y("instant"), l = fe(() => s("instant"), []), { viewportRef: u, scrollState: m, measure: d } = Lo(e, l), f = i ? m.canScrollLeft : m.canScrollTop, g = i ? m.canScrollRight : m.canScrollBottom;
10172
+ const i = e === "horizontal", [a, s] = Y("instant"), l = fe(() => s("instant"), []), { viewportRef: u, scrollState: m, measure: d } = Lo(e, l), f = i ? m.canScrollLeft : m.canScrollTop, b = i ? m.canScrollRight : m.canScrollBottom;
10173
10173
  function h(p, c) {
10174
10174
  const y = u.current;
10175
10175
  if (!y) return;
10176
- const b = Array.from(y.children), w = i ? y.scrollLeft : y.scrollTop, k = i ? y.clientWidth : y.clientHeight, x = w + (p === 1 ? k : 0), T = (C) => i ? C.offsetLeft : C.offsetTop, v = (C) => i ? C.offsetLeft + C.offsetWidth : C.offsetTop + C.offsetHeight, N = p === 1 ? b.find((C) => v(C) > x + 1) : [...b].reverse().find((C) => T(C) < w - 1);
10176
+ const g = Array.from(y.children), w = i ? y.scrollLeft : y.scrollTop, k = i ? y.clientWidth : y.clientHeight, x = w + (p === 1 ? k : 0), T = (C) => i ? C.offsetLeft : C.offsetTop, v = (C) => i ? C.offsetLeft + C.offsetWidth : C.offsetTop + C.offsetHeight, N = p === 1 ? g.find((C) => v(C) > x + 1) : [...g].reverse().find((C) => T(C) < w - 1);
10177
10177
  if (!N) return;
10178
10178
  const M = c.detail > 0;
10179
10179
  s(M ? "pointer" : "instant");
@@ -10228,7 +10228,7 @@ function sd({
10228
10228
  type: "button",
10229
10229
  className: "scroller-buttons__control",
10230
10230
  "aria-label": `${i ? "向右滚动" : "向下滚动"}${t}`,
10231
- disabled: !g,
10231
+ disabled: !b,
10232
10232
  onClick: (p) => h(1, p),
10233
10233
  children: i ? /* @__PURE__ */ n(Le, { size: 16, strokeWidth: oe, "aria-hidden": "true" }) : /* @__PURE__ */ n(Ke, { size: 16, strokeWidth: oe, "aria-hidden": "true" })
10234
10234
  }
@@ -10275,11 +10275,11 @@ const ld = Pt(function({
10275
10275
  id: m,
10276
10276
  name: d,
10277
10277
  disabled: f = !1,
10278
- "aria-describedby": g
10278
+ "aria-describedby": b
10279
10279
  }, h) {
10280
- const p = Fo(o, i, a), c = l !== void 0, [y, b] = Y(() => at(s ?? o, p)), w = at(c ? l : y, p), k = me(), x = m ?? k, T = qn(w, p), v = R(null), [N, M] = Y(!1), L = (E) => {
10280
+ const p = Fo(o, i, a), c = l !== void 0, [y, g] = Y(() => at(s ?? o, p)), w = at(c ? l : y, p), k = me(), x = m ?? k, T = qn(w, p), v = R(null), [N, M] = Y(!1), L = (E) => {
10281
10281
  const P = at(E, p);
10282
- P !== w && (c || b(P), u?.(P));
10282
+ P !== w && (c || g(P), u?.(P));
10283
10283
  };
10284
10284
  return /* @__PURE__ */ _("div", { className: `slider-field${f ? " slider-field--disabled" : ""}`, children: [
10285
10285
  /* @__PURE__ */ _("div", { className: "slider-field__head", children: [
@@ -10300,7 +10300,7 @@ const ld = Pt(function({
10300
10300
  step: a,
10301
10301
  value: w,
10302
10302
  disabled: f,
10303
- "aria-describedby": g,
10303
+ "aria-describedby": b,
10304
10304
  "aria-valuetext": rn(w, r),
10305
10305
  "data-pressed": N || void 0,
10306
10306
  style: { "--slider-pct": `${T}%` },
@@ -10334,12 +10334,12 @@ const ld = Pt(function({
10334
10334
  onValueChange: m,
10335
10335
  id: d,
10336
10336
  name: f,
10337
- disabled: g = !1,
10337
+ disabled: b = !1,
10338
10338
  "aria-describedby": h
10339
10339
  }, p) {
10340
- const c = Fo(o, i, a), y = u !== void 0, [b, w] = Y(
10340
+ const c = Fo(o, i, a), y = u !== void 0, [g, w] = Y(
10341
10341
  () => Dr([s ?? o, l ?? i], c)
10342
- ), [k, x] = Dr(y ? u : b, c), T = me(), v = d ?? T, N = `${v}-low-number`, M = `${v}-high-number`, L = qn(k, c), E = qn(x, c), P = R(null), D = R(null), C = R(null), S = R(null), O = R(!1), B = R(!1), [A, U] = Y(String(k)), [K, Q] = Y(String(x)), [G, X] = Y(null);
10342
+ ), [k, x] = Dr(y ? u : g, c), T = me(), v = d ?? T, N = `${v}-low-number`, M = `${v}-high-number`, L = qn(k, c), E = qn(x, c), P = R(null), D = R(null), C = R(null), S = R(null), O = R(!1), B = R(!1), [A, U] = Y(String(k)), [K, Q] = Y(String(x)), [G, X] = Y(null);
10343
10343
  qr(p, () => P.current), ie(() => {
10344
10344
  O.current || U(String(k));
10345
10345
  }, [k]), ie(() => {
@@ -10356,7 +10356,7 @@ const ld = Pt(function({
10356
10356
  const re = Math.min(1, Math.max(0, (F - W.left) / W.width));
10357
10357
  return at(o + re * (i - o), c);
10358
10358
  }, $ = (F) => {
10359
- if (g || !F.isPrimary || S.current || F.pointerType === "mouse" && F.button !== 0) return;
10359
+ if (b || !F.isPrimary || S.current || F.pointerType === "mouse" && F.button !== 0) return;
10360
10360
  const W = te(F.clientX);
10361
10361
  let re;
10362
10362
  k === x && W === k ? re = null : k === x ? re = W < k ? "low" : "high" : re = Math.abs(W - k) <= Math.abs(W - x) ? "low" : "high";
@@ -10413,8 +10413,8 @@ const ld = Pt(function({
10413
10413
  "fieldset",
10414
10414
  {
10415
10415
  id: v,
10416
- className: `range-slider${g ? " range-slider--disabled" : ""}`,
10417
- disabled: g,
10416
+ className: `range-slider${b ? " range-slider--disabled" : ""}`,
10417
+ disabled: b,
10418
10418
  "aria-describedby": h,
10419
10419
  children: [
10420
10420
  /* @__PURE__ */ n("legend", { className: "range-slider__legend", children: t }),
@@ -10435,7 +10435,7 @@ const ld = Pt(function({
10435
10435
  max: i,
10436
10436
  step: a,
10437
10437
  value: A,
10438
- disabled: g,
10438
+ disabled: b,
10439
10439
  onFocus: () => {
10440
10440
  O.current = !0;
10441
10441
  },
@@ -10475,7 +10475,7 @@ const ld = Pt(function({
10475
10475
  max: i,
10476
10476
  step: a,
10477
10477
  value: k,
10478
- disabled: g,
10478
+ disabled: b,
10479
10479
  "data-pressed": G === "low" || void 0,
10480
10480
  onChange: (F) => z("low", Number(F.currentTarget.value))
10481
10481
  }
@@ -10493,7 +10493,7 @@ const ld = Pt(function({
10493
10493
  max: i,
10494
10494
  step: a,
10495
10495
  value: x,
10496
- disabled: g,
10496
+ disabled: b,
10497
10497
  "data-pressed": G === "high" || void 0,
10498
10498
  onChange: (F) => z("high", Number(F.currentTarget.value))
10499
10499
  }
@@ -10519,7 +10519,7 @@ const ld = Pt(function({
10519
10519
  max: i,
10520
10520
  step: a,
10521
10521
  value: K,
10522
- disabled: g,
10522
+ disabled: b,
10523
10523
  onFocus: () => {
10524
10524
  B.current = !0;
10525
10525
  },
@@ -10561,10 +10561,10 @@ function ic({
10561
10561
  function ud({ items: e, label: t }) {
10562
10562
  const [r, o] = Y(!1), [i, a] = Y(), [s, l] = Y(!1), u = R(null);
10563
10563
  if (e.length < 3) return /* @__PURE__ */ n(ic, { items: e, label: t });
10564
- const m = e[0], d = e[e.length - 1], f = e.slice(1, -1), g = () => {
10564
+ const m = e[0], d = e[e.length - 1], f = e.slice(1, -1), b = () => {
10565
10565
  u.current = null, l(!1);
10566
10566
  }, h = (c) => {
10567
- u.current === c.pointerId && g();
10567
+ u.current === c.pointerId && b();
10568
10568
  };
10569
10569
  return /* @__PURE__ */ n("nav", { className: "breadcrumb breadcrumb--collapsible", "aria-label": t, "data-expanded": r ? "true" : "false", children: /* @__PURE__ */ _("ol", { className: "breadcrumb__list", children: [
10570
10570
  /* @__PURE__ */ _("li", { className: "breadcrumb__item breadcrumb__item--endpoint breadcrumb__item--first", children: [
@@ -10581,12 +10581,12 @@ function ud({ items: e, label: t }) {
10581
10581
  "aria-label": r ? "收起中间层级" : "展开折叠的中间层级",
10582
10582
  "data-motion-input": i,
10583
10583
  "data-pointer-pressed": s ? "true" : void 0,
10584
- onBlur: g,
10584
+ onBlur: b,
10585
10585
  onClick: (c) => {
10586
- a(c.detail > 0 ? "pointer" : "keyboard"), g(), o((y) => !y);
10586
+ a(c.detail > 0 ? "pointer" : "keyboard"), b(), o((y) => !y);
10587
10587
  },
10588
10588
  onKeyDown: () => {
10589
- a("keyboard"), g();
10589
+ a("keyboard"), b();
10590
10590
  },
10591
10591
  onLostPointerCapture: h,
10592
10592
  onPointerCancel: h,
@@ -10632,7 +10632,7 @@ function ud({ items: e, label: t }) {
10632
10632
  ] }) });
10633
10633
  }
10634
10634
  function ac({ open: e, onClose: t, title: r, side: o = "right", size: i, dismissable: a = !0, mobileFullscreen: s = !1, children: l, footer: u }) {
10635
- const m = R(null), d = R(!1), f = R({ side: o, size: i, title: r, children: l, footer: u, mobileFullscreen: s }), g = me(), [h, p] = Y(e), [c, y] = Y("keyboard"), b = e || h, w = e ? { side: o, size: i, title: r, children: l, footer: u, mobileFullscreen: s } : f.current, k = fe(() => {
10635
+ const m = R(null), d = R(!1), f = R({ side: o, size: i, title: r, children: l, footer: u, mobileFullscreen: s }), b = me(), [h, p] = Y(e), [c, y] = Y("keyboard"), g = e || h, w = e ? { side: o, size: i, title: r, children: l, footer: u, mobileFullscreen: s } : f.current, k = fe(() => {
10636
10636
  d.current = !1, p(!1), y("keyboard");
10637
10637
  }, []);
10638
10638
  pe(() => {
@@ -10671,7 +10671,7 @@ function ac({ open: e, onClose: t, title: r, side: o = "right", size: i, dismiss
10671
10671
  }
10672
10672
  const { onKeyDown: T, portal: v } = je({
10673
10673
  open: e,
10674
- present: b,
10674
+ present: g,
10675
10675
  blocking: !0,
10676
10676
  dismissable: a,
10677
10677
  outsidePointer: !1,
@@ -10679,7 +10679,7 @@ function ac({ open: e, onClose: t, title: r, side: o = "right", size: i, dismiss
10679
10679
  initialFocusRef: m,
10680
10680
  onClose: t
10681
10681
  });
10682
- return b ? v(
10682
+ return g ? v(
10683
10683
  /* @__PURE__ */ _(ye, { children: [
10684
10684
  /* @__PURE__ */ n(
10685
10685
  "div",
@@ -10698,7 +10698,7 @@ function ac({ open: e, onClose: t, title: r, side: o = "right", size: i, dismiss
10698
10698
  role: "dialog",
10699
10699
  "aria-modal": "true",
10700
10700
  "aria-hidden": e ? void 0 : !0,
10701
- "aria-labelledby": g,
10701
+ "aria-labelledby": b,
10702
10702
  className: `sheet__panel sheet__panel--${w.side}${w.size ? ` sheet__panel--${w.size}` : ""}${w.mobileFullscreen ? " sheet__panel--mobile-fullscreen" : ""}`,
10703
10703
  tabIndex: -1,
10704
10704
  inert: e ? void 0 : !0,
@@ -10710,7 +10710,7 @@ function ac({ open: e, onClose: t, title: r, side: o = "right", size: i, dismiss
10710
10710
  },
10711
10711
  children: [
10712
10712
  /* @__PURE__ */ _("header", { className: "sheet__header", children: [
10713
- /* @__PURE__ */ n("h2", { className: "sheet__title", id: g, children: w.title }),
10713
+ /* @__PURE__ */ n("h2", { className: "sheet__title", id: b, children: w.title }),
10714
10714
  a ? /* @__PURE__ */ n("button", { type: "button", className: "sheet__close", "aria-label": "关闭", onClick: x, children: /* @__PURE__ */ n(Ve, { size: 16, strokeWidth: oe, "aria-hidden": "true" }) }) : null
10715
10715
  ] }),
10716
10716
  /* @__PURE__ */ n("div", { className: "sheet__body", children: w.children }),
@@ -10733,7 +10733,7 @@ function dd({
10733
10733
  loading: u = !1,
10734
10734
  loadingLabel: m = "正在加载…"
10735
10735
  }) {
10736
- const [d, f] = Y(!1), [g, h] = Y("keyboard"), p = R(null), c = R(null), y = R(null), b = R(!1), w = R(-1), k = me(), { portalPopup: x, placement: T, onOverlayKeyDown: v } = ot(
10736
+ const [d, f] = Y(!1), [b, h] = Y("keyboard"), p = R(null), c = R(null), y = R(null), g = R(!1), w = R(-1), k = me(), { portalPopup: x, placement: T, onOverlayKeyDown: v } = ot(
10737
10737
  d,
10738
10738
  p,
10739
10739
  y,
@@ -10774,20 +10774,20 @@ function dd({
10774
10774
  }
10775
10775
  }, [d, l, u, M, t]);
10776
10776
  function A(G) {
10777
- b.current = !1, !u && (G.key === "ArrowDown" || G.key === "Enter" || G.key === " " ? (G.preventDefault(), B("first", "keyboard")) : G.key === "ArrowUp" && (G.preventDefault(), B("last", "keyboard")));
10777
+ g.current = !1, !u && (G.key === "ArrowDown" || G.key === "Enter" || G.key === " " ? (G.preventDefault(), B("first", "keyboard")) : G.key === "ArrowUp" && (G.preventDefault(), B("last", "keyboard")));
10778
10778
  }
10779
10779
  function U(G) {
10780
10780
  if (u) {
10781
- b.current = !1, G.preventDefault();
10781
+ g.current = !1, G.preventDefault();
10782
10782
  return;
10783
10783
  }
10784
10784
  if (d)
10785
10785
  P();
10786
10786
  else {
10787
- const X = b.current && G.detail > 0 ? "pointer" : "keyboard";
10787
+ const X = g.current && G.detail > 0 ? "pointer" : "keyboard";
10788
10788
  B("first", X);
10789
10789
  }
10790
- b.current = !1;
10790
+ g.current = !1;
10791
10791
  }
10792
10792
  function K() {
10793
10793
  window.requestAnimationFrame(() => {
@@ -10835,10 +10835,10 @@ function dd({
10835
10835
  "aria-expanded": d,
10836
10836
  "aria-controls": d ? k : void 0,
10837
10837
  onPointerDown: () => {
10838
- b.current = !0;
10838
+ g.current = !0;
10839
10839
  },
10840
10840
  onPointerCancel: () => {
10841
- b.current = !1;
10841
+ g.current = !1;
10842
10842
  },
10843
10843
  onClick: U,
10844
10844
  onKeyDown: A,
@@ -10854,7 +10854,7 @@ function dd({
10854
10854
  role: "menu",
10855
10855
  "aria-label": a,
10856
10856
  className: `menu__popup menu__popup--${T.align} menu__popup--${T.side} split-button__menu`,
10857
- "data-open-modality": g,
10857
+ "data-open-modality": b,
10858
10858
  onKeyDown: (G) => {
10859
10859
  G.key === "Tab" ? (G.preventDefault(), On(c.current, G.shiftKey), P(!1)) : G.key === "Escape" ? v(G) : O(G);
10860
10860
  },
@@ -10888,7 +10888,7 @@ function dd({
10888
10888
  }
10889
10889
  const sc = (e) => e.type === "item" || e.type === "link";
10890
10890
  function fd({ label: e, entries: t, withChevron: r, align: o = "start", triggerContent: i, prefix: a, size: s = "md" }) {
10891
- const [l, u] = Y(!1), [m, d] = Y(!1), [f, g] = Y("keyboard"), [h, p] = Y(!1), c = R(null), y = R(null), b = R(!1), w = me(), { portalPopup: k, placement: x, onOverlayKeyDown: T } = ot(
10891
+ const [l, u] = Y(!1), [m, d] = Y(!1), [f, b] = Y("keyboard"), [h, p] = Y(!1), c = R(null), y = R(null), g = R(!1), w = me(), { portalPopup: k, placement: x, onOverlayKeyDown: T } = ot(
10892
10892
  l,
10893
10893
  c,
10894
10894
  y,
@@ -10925,7 +10925,7 @@ function fd({ label: e, entries: t, withChevron: r, align: o = "start", triggerC
10925
10925
  });
10926
10926
  function O(q, V) {
10927
10927
  if (!E) return;
10928
- g(V), d(!0), u(!0);
10928
+ b(V), d(!0), u(!0);
10929
10929
  const Z = q === "first" ? N[0] : N[N.length - 1];
10930
10930
  window.requestAnimationFrame(() => D(Z));
10931
10931
  }
@@ -10956,10 +10956,10 @@ function fd({ label: e, entries: t, withChevron: r, align: o = "start", triggerC
10956
10956
  ne(), q.key === "ArrowDown" || q.key === "Enter" || q.key === " " ? (q.preventDefault(), O("first", "keyboard")) : q.key === "ArrowUp" && (q.preventDefault(), O("last", "keyboard"));
10957
10957
  }
10958
10958
  function X(q) {
10959
- !q.isPrimary || q.button !== 0 || (b.current = !0, p(!0));
10959
+ !q.isPrimary || q.button !== 0 || (g.current = !0, p(!0));
10960
10960
  }
10961
10961
  function ne() {
10962
- b.current = !1, p(!1);
10962
+ g.current = !1, p(!1);
10963
10963
  }
10964
10964
  function z(q) {
10965
10965
  q.isPrimary && p(!1);
@@ -10971,13 +10971,13 @@ function fd({ label: e, entries: t, withChevron: r, align: o = "start", triggerC
10971
10971
  if (l)
10972
10972
  B();
10973
10973
  else {
10974
- const V = b.current && q.detail > 0 ? "pointer" : "keyboard";
10974
+ const V = g.current && q.detail > 0 ? "pointer" : "keyboard";
10975
10975
  O("first", V);
10976
10976
  }
10977
10977
  ne();
10978
10978
  }
10979
10979
  function I(q) {
10980
- (q.key === "Escape" || q.key === "Tab" || q.key === "Enter" || q.key === " ") && g("keyboard"), q.key === "Tab" ? (q.preventDefault(), On(c.current, q.shiftKey), B(!1)) : q.key === "Escape" ? T(q) : S(q);
10980
+ (q.key === "Escape" || q.key === "Tab" || q.key === "Enter" || q.key === " ") && b("keyboard"), q.key === "Tab" ? (q.preventDefault(), On(c.current, q.shiftKey), B(!1)) : q.key === "Escape" ? T(q) : S(q);
10981
10981
  }
10982
10982
  return /* @__PURE__ */ _("div", { className: "menu", children: [
10983
10983
  /* @__PURE__ */ _(
@@ -11089,8 +11089,8 @@ function fd({ label: e, entries: t, withChevron: r, align: o = "start", triggerC
11089
11089
  ) : null
11090
11090
  ] });
11091
11091
  }
11092
- function md({ options: e, defaultSelected: t = [], placeholder: r, onChange: o, preserveSelectionOrder: i = !1, value: a, disabled: s, readOnly: l, id: u, ref: m, invalid: d, errorId: f, "aria-label": g, "aria-labelledby": h, "aria-describedby": p }) {
11093
- const c = e.map((H) => typeof H == "string" ? { value: H, label: H } : H), y = me(), b = `${y}-listbox`, w = `${y}-summary`, [k, x] = Y(!1), [T, v] = Y(t), N = a ?? T, M = !s && !l, [L, E] = Y(-1), [P, D] = Y(), C = R(null), S = R(null), O = R(null), { portalPopup: B } = ot(k, S, O, () => x(!1), { gapToken: "--q1-space-2" }), A = R([]), U = R(void 0), K = R(!1);
11092
+ function md({ options: e, defaultSelected: t = [], placeholder: r, onChange: o, preserveSelectionOrder: i = !1, value: a, disabled: s, readOnly: l, id: u, ref: m, invalid: d, errorId: f, "aria-label": b, "aria-labelledby": h, "aria-describedby": p }) {
11093
+ const c = e.map((H) => typeof H == "string" ? { value: H, label: H } : H), y = me(), g = `${y}-listbox`, w = `${y}-summary`, [k, x] = Y(!1), [T, v] = Y(t), N = a ?? T, M = !s && !l, [L, E] = Y(-1), [P, D] = Y(), C = R(null), S = R(null), O = R(null), { portalPopup: B } = ot(k, S, O, () => x(!1), { gapToken: "--q1-space-2" }), A = R([]), U = R(void 0), K = R(!1);
11094
11094
  ie(() => {
11095
11095
  M || x(!1);
11096
11096
  }, [M]);
@@ -11219,12 +11219,12 @@ function md({ options: e, defaultSelected: t = [], placeholder: r, onChange: o,
11219
11219
  "aria-invalid": d || void 0,
11220
11220
  type: "button",
11221
11221
  className: "multi-select__trigger",
11222
- "aria-label": g ?? (h ? void 0 : r),
11222
+ "aria-label": b ?? (h ? void 0 : r),
11223
11223
  "aria-labelledby": h,
11224
11224
  "aria-describedby": [w, f, p].filter(Boolean).join(" "),
11225
11225
  "aria-haspopup": "listbox",
11226
11226
  "aria-expanded": k,
11227
- "aria-controls": b,
11227
+ "aria-controls": g,
11228
11228
  onPointerDown: (H) => {
11229
11229
  k && H.preventDefault();
11230
11230
  },
@@ -11272,7 +11272,7 @@ function md({ options: e, defaultSelected: t = [], placeholder: r, onChange: o,
11272
11272
  c.length
11273
11273
  ] })
11274
11274
  ] }) : null,
11275
- /* @__PURE__ */ n("div", { id: b, role: "listbox", "aria-multiselectable": "true", "aria-label": r, children: c.map((H, ee) => {
11275
+ /* @__PURE__ */ n("div", { id: g, role: "listbox", "aria-multiselectable": "true", "aria-label": r, children: c.map((H, ee) => {
11276
11276
  const j = G(H.value);
11277
11277
  return /* @__PURE__ */ _(
11278
11278
  "button",
@@ -11328,7 +11328,7 @@ function lc(e) {
11328
11328
  }
11329
11329
  function pd(e) {
11330
11330
  lc(e);
11331
- const { open: t, title: r, description: o, children: i, footer: a, initialFocusRef: s, sticky: l = !1 } = e, u = e.dismissal, m = u === void 0 ? e.dismissable ?? !0 : !1, d = R(null), f = me(), g = me(), h = o != null && o !== !1, { focusInitialIfTopMost: p, onKeyDown: c, portal: y } = je({
11331
+ const { open: t, title: r, description: o, children: i, footer: a, initialFocusRef: s, sticky: l = !1 } = e, u = e.dismissal, m = u === void 0 ? e.dismissable ?? !0 : !1, d = R(null), f = me(), b = me(), h = o != null && o !== !1, { focusInitialIfTopMost: p, onKeyDown: c, portal: y } = je({
11332
11332
  open: t,
11333
11333
  blocking: !0,
11334
11334
  dismissable: m,
@@ -11353,7 +11353,7 @@ function pd(e) {
11353
11353
  "aria-label": "关闭",
11354
11354
  tabIndex: -1
11355
11355
  }
11356
- ) : /* @__PURE__ */ n("div", { className: "modal__backdrop", "aria-hidden": "true", onPointerDown: (b) => b.preventDefault() }),
11356
+ ) : /* @__PURE__ */ n("div", { className: "modal__backdrop", "aria-hidden": "true", onPointerDown: (g) => g.preventDefault() }),
11357
11357
  /* @__PURE__ */ _(
11358
11358
  "div",
11359
11359
  {
@@ -11361,14 +11361,14 @@ function pd(e) {
11361
11361
  role: "dialog",
11362
11362
  "aria-modal": "true",
11363
11363
  "aria-labelledby": f,
11364
- "aria-describedby": h ? g : void 0,
11364
+ "aria-describedby": h ? b : void 0,
11365
11365
  "aria-busy": u?.busy || void 0,
11366
11366
  tabIndex: -1,
11367
11367
  ref: d,
11368
11368
  children: [
11369
11369
  h ? /* @__PURE__ */ n("header", { className: "modal__header modal__header--described", children: /* @__PURE__ */ _("div", { className: "modal__heading", children: [
11370
11370
  /* @__PURE__ */ n("h2", { className: "modal__title", id: f, children: r }),
11371
- /* @__PURE__ */ n("div", { className: "modal__description", id: g, children: o })
11371
+ /* @__PURE__ */ n("div", { className: "modal__description", id: b, children: o })
11372
11372
  ] }) }) : /* @__PURE__ */ n("header", { className: "modal__header", children: /* @__PURE__ */ n("h2", { className: "modal__title", id: f, children: r }) }),
11373
11373
  /* @__PURE__ */ n("div", { className: "modal__body", children: i }),
11374
11374
  a === null ? null : /* @__PURE__ */ n("footer", { className: "modal__footer", children: a })
@@ -11386,12 +11386,12 @@ function bd({ data: e, summary: t, axisLabels: r = "ends-and-middle", height: o
11386
11386
  const a = typeof t == "string" && !!t.trim(), s = typeof o == "number" && Number.isFinite(o) && o > 0, l = Array.isArray(e) && e.every(
11387
11387
  (E) => E !== null && typeof E == "object" && typeof E.label == "string" && Number.isFinite(E.value)
11388
11388
  ), u = !a || !s || !l, m = u ? [] : e.map((E) => E.value), d = m.length;
11389
- let f = 0, g = 0, h = 0;
11389
+ let f = 0, b = 0, h = 0;
11390
11390
  for (const E of m)
11391
- f = Math.min(f, E), g = Math.max(g, E), h = Math.max(h, Math.abs(E));
11392
- const p = h || 1, c = f / p, b = g / p - c, w = (E) => {
11393
- if (b === 0) return vt;
11394
- const P = (E / p - c) / b;
11391
+ f = Math.min(f, E), b = Math.max(b, E), h = Math.max(h, Math.abs(E));
11392
+ const p = h || 1, c = f / p, g = b / p - c, w = (E) => {
11393
+ if (g === 0) return vt;
11394
+ const P = (E / p - c) / g;
11395
11395
  return vt - P * vt;
11396
11396
  }, k = m.map((E, P) => {
11397
11397
  const D = d === 1 ? Kt / 2 : P / (d - 1) * Kt, C = w(E);
@@ -11498,7 +11498,7 @@ function gd({
11498
11498
  activeLabel: t,
11499
11499
  onPick: r
11500
11500
  }) {
11501
- const [o, i] = Y(!1), [a, s] = Y(-1), l = R(null), u = R(null), m = R(null), { portalPopup: d } = ot(o, u, m, () => i(!1)), f = me(), g = o && a >= 0 ? `${f}-option-${a}` : void 0;
11501
+ const [o, i] = Y(!1), [a, s] = Y(-1), l = R(null), u = R(null), m = R(null), { portalPopup: d } = ot(o, u, m, () => i(!1)), f = me(), b = o && a >= 0 ? `${f}-option-${a}` : void 0;
11502
11502
  function h() {
11503
11503
  return t ? e.findIndex((w) => w.label === t) : -1;
11504
11504
  }
@@ -11522,7 +11522,7 @@ function gd({
11522
11522
  }
11523
11523
  return document.addEventListener("pointerdown", w), () => document.removeEventListener("pointerdown", w);
11524
11524
  }, [o]);
11525
- function b(w) {
11525
+ function g(w) {
11526
11526
  if (!o) {
11527
11527
  w.key === "ArrowDown" || w.key === "Enter" || w.key === " " ? (w.preventDefault(), p("first")) : w.key === "ArrowUp" && (w.preventDefault(), p("last"));
11528
11528
  return;
@@ -11553,12 +11553,12 @@ function gd({
11553
11553
  "aria-haspopup": "listbox",
11554
11554
  "aria-expanded": o,
11555
11555
  "aria-controls": f,
11556
- "aria-activedescendant": g,
11556
+ "aria-activedescendant": b,
11557
11557
  disabled: e.length === 0 || void 0,
11558
11558
  onClick: () => {
11559
11559
  o ? c() : p();
11560
11560
  },
11561
- onKeyDown: b,
11561
+ onKeyDown: g,
11562
11562
  children: [
11563
11563
  /* @__PURE__ */ n(mi, { size: 15, strokeWidth: oe, "aria-hidden": "true" }),
11564
11564
  /* @__PURE__ */ n("span", { className: "cal-period__label", children: t ?? "选择周期" }),
@@ -11626,7 +11626,7 @@ function mc({
11626
11626
  const T = Number.parseFloat(d.getComputedStyle(u).getPropertyValue(x));
11627
11627
  return Number.isFinite(T) ? T : 0;
11628
11628
  }
11629
- let g = 0, h = !0;
11629
+ let b = 0, h = !0;
11630
11630
  const p = [
11631
11631
  d.matchMedia("(max-width: 40rem)"),
11632
11632
  d.matchMedia("(pointer: coarse)"),
@@ -11653,11 +11653,11 @@ function mc({
11653
11653
  u.style.left = `${D}px`, u.style.top = `${Q}px`, u.dataset.side = O ? "top" : "bottom", u.dataset.positioned = "true", u.style.setProperty("--cal-popover-origin-x", `${G}px`);
11654
11654
  }
11655
11655
  function y() {
11656
- g || (g = d.requestAnimationFrame(() => {
11657
- g = 0, c();
11656
+ b || (b = d.requestAnimationFrame(() => {
11657
+ b = 0, c();
11658
11658
  }));
11659
11659
  }
11660
- function b(x) {
11660
+ function g(x) {
11661
11661
  x.target instanceof Node && u.contains(x.target) || y();
11662
11662
  }
11663
11663
  function w() {
@@ -11665,8 +11665,8 @@ function mc({
11665
11665
  }
11666
11666
  c();
11667
11667
  const k = new ResizeObserver(y);
11668
- return k.observe(u), k.observe(m), Array.from(u.children).forEach((x) => k.observe(x)), d.addEventListener("resize", y), p.forEach((x) => x.addEventListener("change", w)), d.addEventListener("scroll", b, !0), () => {
11669
- k.disconnect(), d.removeEventListener("resize", y), p.forEach((x) => x.removeEventListener("change", w)), d.removeEventListener("scroll", b, !0), g && d.cancelAnimationFrame(g);
11668
+ return k.observe(u), k.observe(m), Array.from(u.children).forEach((x) => k.observe(x)), d.addEventListener("resize", y), p.forEach((x) => x.addEventListener("change", w)), d.addEventListener("scroll", g, !0), () => {
11669
+ k.disconnect(), d.removeEventListener("resize", y), p.forEach((x) => x.removeEventListener("change", w)), d.removeEventListener("scroll", g, !0), b && d.cancelAnimationFrame(b);
11670
11670
  };
11671
11671
  }, [e, o, t, r, i]);
11672
11672
  }
@@ -11677,8 +11677,8 @@ function pc({ id: e, triggerRef: t, children: r }) {
11677
11677
  if (!i || !a || !s || !l) return;
11678
11678
  a.id = e;
11679
11679
  function u() {
11680
- const f = Number.parseFloat(l.getComputedStyle(s).getPropertyValue("--q1-space-2")) || 0, g = Number.parseFloat(l.getComputedStyle(a).bottom) || 0;
11681
- a.style.maxHeight = `${Math.max(0, l.innerHeight - s.getBoundingClientRect().bottom - f - g)}px`;
11680
+ const f = Number.parseFloat(l.getComputedStyle(s).getPropertyValue("--q1-space-2")) || 0, b = Number.parseFloat(l.getComputedStyle(a).bottom) || 0;
11681
+ a.style.maxHeight = `${Math.max(0, l.innerHeight - s.getBoundingClientRect().bottom - f - b)}px`;
11682
11682
  }
11683
11683
  u();
11684
11684
  function m() {
@@ -11792,19 +11792,19 @@ function Tr(e, t) {
11792
11792
  return s.setFullYear(o, i - 1, a), s.setHours(0, 0, 0, 0), s.getFullYear() !== o || s.getMonth() !== i - 1 || s.getDate() !== a ? null : xt(s, t);
11793
11793
  }
11794
11794
  function Bo(e) {
11795
- const { withTime: t, pinnedTimezone: r, minValue: o, maxValue: i } = e, a = e.mode === "single", s = e.mode === "single" ? { start: e.value, end: null } : e.value, l = s.start ? Ne(s.start) : "", u = s.end ? Ne(s.end) : "", [m, d] = Y({ start: l, end: u }), [f, g] = Y({ start: !1, end: !1 }), h = R(null), p = me(), c = Intl.DateTimeFormat().resolvedOptions().timeZone;
11795
+ const { withTime: t, pinnedTimezone: r, minValue: o, maxValue: i } = e, a = e.mode === "single", s = e.mode === "single" ? { start: e.value, end: null } : e.value, l = s.start ? Ne(s.start) : "", u = s.end ? Ne(s.end) : "", [m, d] = Y({ start: l, end: u }), [f, b] = Y({ start: !1, end: !1 }), h = R(null), p = me(), c = Intl.DateTimeFormat().resolvedOptions().timeZone;
11796
11796
  ie(() => {
11797
- d((v) => ({ ...v, start: l })), g((v) => ({ ...v, start: !1 }));
11797
+ d((v) => ({ ...v, start: l })), b((v) => ({ ...v, start: !1 }));
11798
11798
  }, [l]), ie(() => {
11799
- d((v) => ({ ...v, end: u })), g((v) => ({ ...v, end: !1 }));
11799
+ d((v) => ({ ...v, end: u })), b((v) => ({ ...v, end: !1 }));
11800
11800
  }, [u]);
11801
11801
  const y = {
11802
11802
  start: Tr(m.start, s.start),
11803
11803
  end: a ? null : Tr(m.end, s.end)
11804
- }, b = a ? ["start"] : ["start", "end"];
11804
+ }, g = a ? ["start"] : ["start", "end"];
11805
11805
  function w(v) {
11806
11806
  const N = { start: "", end: "" };
11807
- for (const M of b)
11807
+ for (const M of g)
11808
11808
  v[M] ? Xt(v[M], o, i) && (N[M] = "日期超出可选范围") : N[M] = "请输入有效日期,例如 2026-06-08";
11809
11809
  return !a && v.start && v.end && (t ? v.end < v.start : Ne(v.end) < Ne(v.start)) && (N.end = "结束日期时间不能早于开始日期时间"), N;
11810
11810
  }
@@ -11816,8 +11816,8 @@ function Bo(e) {
11816
11816
  const N = { ...y }, M = v ? N[v.key] : null;
11817
11817
  v && M && M.setHours(v.date.getHours(), v.date.getMinutes(), 0, 0);
11818
11818
  const L = w(N);
11819
- if (g({ start: !0, end: !0 }), b.some((E) => L[E])) {
11820
- const E = b.find((P) => L[P]);
11819
+ if (b({ start: !0, end: !0 }), g.some((E) => L[E])) {
11820
+ const E = g.find((P) => L[P]);
11821
11821
  h.current?.querySelector(`#${CSS.escape(`${p}-${E}`)}`)?.focus();
11822
11822
  return;
11823
11823
  }
@@ -11826,7 +11826,7 @@ function Bo(e) {
11826
11826
  return /* @__PURE__ */ _("div", { className: "cal-inputs", ref: h, onKeyDown: (v) => {
11827
11827
  v.key !== "Enter" || v.nativeEvent.isComposing || !(v.target instanceof HTMLInputElement) || (v.preventDefault(), T());
11828
11828
  }, children: [
11829
- b.map((v) => {
11829
+ g.map((v) => {
11830
11830
  const N = a ? "日期" : v === "start" ? "开始" : "结束", M = f[v] ? k[v] : "";
11831
11831
  return /* @__PURE__ */ _("div", { className: "cal-inputs__field", children: [
11832
11832
  /* @__PURE__ */ n("label", { className: "cal-inputs__label", htmlFor: `${p}-${v}`, children: N }),
@@ -11845,10 +11845,10 @@ function Bo(e) {
11845
11845
  invalid: !!M,
11846
11846
  errorId: M ? `${p}-${v}-error` : void 0,
11847
11847
  onChange: (L) => {
11848
- d((E) => ({ ...E, [v]: L.target.value })), g((E) => ({ ...E, [v]: !0 }));
11848
+ d((E) => ({ ...E, [v]: L.target.value })), b((E) => ({ ...E, [v]: !0 }));
11849
11849
  },
11850
11850
  onBlur: () => {
11851
- g((L) => ({ ...L, [v]: !0 })), y[v] && !k[v] && (x({ ...s, [v]: y[v] }), d((L) => ({ ...L, [v]: Ne(y[v]) })));
11851
+ b((L) => ({ ...L, [v]: !0 })), y[v] && !k[v] && (x({ ...s, [v]: y[v] }), d((L) => ({ ...L, [v]: Ne(y[v]) })));
11852
11852
  }
11853
11853
  }
11854
11854
  ),
@@ -11900,14 +11900,14 @@ function vc(e) {
11900
11900
  }
11901
11901
  const [m, d] = Y(
11902
11902
  () => ft(zt(l.start ?? i, r, o))
11903
- ), [f, g] = Y(null), [h, p] = Y(() => zt(l.start ?? i, r, o)), [c, y] = Y(""), b = R(/* @__PURE__ */ new Map()), w = R(null), k = dc(m), x = l.start ? Ne(l.start) : null;
11903
+ ), [f, b] = Y(null), [h, p] = Y(() => zt(l.start ?? i, r, o)), [c, y] = Y(""), g = R(/* @__PURE__ */ new Map()), w = R(null), k = dc(m), x = l.start ? Ne(l.start) : null;
11904
11904
  ie(() => {
11905
11905
  if (!x) return;
11906
11906
  const [S, O, B] = x.split("-").map(Number), A = zt(new Date(S, O - 1, B), r, o);
11907
11907
  d(ft(A)), p(A);
11908
11908
  }, [x, r, o]), pe(() => {
11909
11909
  if (!w.current) return;
11910
- const S = b.current.get(w.current);
11910
+ const S = g.current.get(w.current);
11911
11911
  S && (w.current = null, S.focus({ preventScroll: !0 }));
11912
11912
  });
11913
11913
  const T = !s && l.start && !l.end && f ? Ne(f) < Ne(l.start) ? { start: f, end: l.start } : { start: l.start, end: f } : l;
@@ -12030,7 +12030,7 @@ function vc(e) {
12030
12030
  {
12031
12031
  type: "button",
12032
12032
  ref: ($) => {
12033
- $ ? b.current.set(Ne(B), $) : b.current.delete(Ne(B));
12033
+ $ ? g.current.set(Ne(B), $) : g.current.delete(Ne(B));
12034
12034
  },
12035
12035
  className: te,
12036
12036
  tabIndex: A && !U && it(B, h) ? 0 : -1,
@@ -12038,8 +12038,8 @@ function vc(e) {
12038
12038
  "aria-label": fc(B),
12039
12039
  "aria-current": A && it(B, i) ? "date" : void 0,
12040
12040
  onClick: () => !U && v(B),
12041
- onMouseEnter: () => g(B),
12042
- onMouseLeave: () => g(null),
12041
+ onMouseEnter: () => b(B),
12042
+ onMouseLeave: () => b(null),
12043
12043
  onFocus: () => p(B),
12044
12044
  children: B.getDate()
12045
12045
  }
@@ -12058,13 +12058,13 @@ function _d(e) {
12058
12058
  return /* @__PURE__ */ n(Bo, { ...e });
12059
12059
  }
12060
12060
  function wc(e) {
12061
- const { layout: t = "vertical", trigger: r = "default", size: o = "large", fieldSize: i = "md", minValue: a, maxValue: s, pinnedTimezone: l, today: u, withTime: m = !1, disabled: d = !1 } = e, f = e.mode === "single", g = e.mode === "single" ? { start: e.value, end: null } : e.value;
12061
+ const { layout: t = "vertical", trigger: r = "default", size: o = "large", fieldSize: i = "md", minValue: a, maxValue: s, pinnedTimezone: l, today: u, withTime: m = !1, disabled: d = !1 } = e, f = e.mode === "single", b = e.mode === "single" ? { start: e.value, end: null } : e.value;
12062
12062
  function h(z) {
12063
12063
  e.mode === "single" ? e.onChange(z.start) : e.onChange(z);
12064
12064
  }
12065
- const [p, c] = Y(!1), [y, b] = Y(!1), w = fe((z) => b(z), []), [k, x] = Y(g), [T, v] = Y("keyboard"), N = R(null), M = R(null), L = R(null), E = R(!1), P = R(null), D = R(!1), C = me();
12065
+ const [p, c] = Y(!1), [y, g] = Y(!1), w = fe((z) => g(z), []), [k, x] = Y(b), [T, v] = Y("keyboard"), N = R(null), M = R(null), L = R(null), E = R(!1), P = R(null), D = R(!1), C = me();
12066
12066
  ie(() => {
12067
- p || (x(g), E.current && (E.current = !1, L.current?.focus()));
12067
+ p || (x(b), E.current && (E.current = !1, L.current?.focus()));
12068
12068
  }, [p, e.value]), ie(() => {
12069
12069
  d && c(!1);
12070
12070
  }, [d]);
@@ -12096,7 +12096,7 @@ function wc(e) {
12096
12096
  const z = P.current;
12097
12097
  (z?.querySelector('.calendar__day[tabindex="0"]') ?? z?.querySelector("button:not([disabled]), input:not([disabled])"))?.focus({ preventScroll: !0 });
12098
12098
  }, [p, B, y]);
12099
- const A = !!g.start && (f || !!g.end), U = f ? "选择日期" : "选择日期区间", K = A ? f ? kn(g.start, m) : `${kn(g.start, m)} ~ ${kn(g.end, m)}` : U;
12099
+ const A = !!b.start && (f || !!b.end), U = f ? "选择日期" : "选择日期区间", K = A ? f ? kn(b.start, m) : `${kn(b.start, m)} ~ ${kn(b.end, m)}` : U;
12100
12100
  function Q(z) {
12101
12101
  if (d) return;
12102
12102
  const te = z.currentTarget, $ = D.current && z.detail !== 0;
@@ -12104,7 +12104,7 @@ function wc(e) {
12104
12104
  c(!1);
12105
12105
  return;
12106
12106
  }
12107
- L.current = te, x(g), b(!1), v($ ? "pointer" : "keyboard"), c(!0);
12107
+ L.current = te, x(b), g(!1), v($ ? "pointer" : "keyboard"), c(!0);
12108
12108
  }
12109
12109
  const G = f ? { mode: "single", value: k.start, onChange: (z) => x({ start: z, end: null }) } : { value: k, onChange: x }, X = /* @__PURE__ */ n(vc, { ...G, withTime: m, size: o, minValue: a, maxValue: s, today: u }), ne = /* @__PURE__ */ n(Bo, { ...G, minValue: a, maxValue: s, withTime: m, pinnedTimezone: l, onApply: (z) => {
12110
12110
  !z.start || !f && !z.end || (h(z), E.current = !0, c(!1));
@@ -12229,10 +12229,10 @@ const Nc = [
12229
12229
  { value: "love", label: "非常清楚", Icon: Wr }
12230
12230
  ];
12231
12231
  function vd({ variant: e, onSubmit: t }) {
12232
- const r = me(), [o, i] = Y(null), [a, s] = Y(""), [l, u] = Y("idle"), [m, d] = Y("submit"), f = R(!1), g = R(null), h = l === "pending", p = o !== null && !(e === "helpful" && o === "yes") && l !== "success";
12232
+ const r = me(), [o, i] = Y(null), [a, s] = Y(""), [l, u] = Y("idle"), [m, d] = Y("submit"), f = R(!1), b = R(null), h = l === "pending", p = o !== null && !(e === "helpful" && o === "yes") && l !== "success";
12233
12233
  async function c(w, k = "submit") {
12234
12234
  if (!f.current) {
12235
- f.current = !0, g.current = w, d(k), u("pending");
12235
+ f.current = !0, b.current = w, d(k), u("pending");
12236
12236
  try {
12237
12237
  await t(w), u("success");
12238
12238
  } catch {
@@ -12245,9 +12245,9 @@ function vd({ variant: e, onSubmit: t }) {
12245
12245
  function y(w) {
12246
12246
  f.current || (i(w), u("idle"), e === "helpful" && w === "yes" && c({ scale: "helpful", rating: "yes", comment: "" }, "yes"));
12247
12247
  }
12248
- function b() {
12249
- if (l === "error" && g.current) {
12250
- c(g.current);
12248
+ function g() {
12249
+ if (l === "error" && b.current) {
12250
+ c(b.current);
12251
12251
  return;
12252
12252
  }
12253
12253
  e === "rating" && o !== null && o !== "yes" && o !== "no" ? c({ scale: "rating4", rating: o, comment: a.trim() }) : e === "helpful" && o === "no" && c({ scale: "helpful", rating: o, comment: a.trim() });
@@ -12296,7 +12296,7 @@ function vd({ variant: e, onSubmit: t }) {
12296
12296
  variant: "secondary",
12297
12297
  loading: h,
12298
12298
  onClick: () => {
12299
- g.current && c(g.current, "retry");
12299
+ b.current && c(b.current, "retry");
12300
12300
  },
12301
12301
  children: "重试"
12302
12302
  }
@@ -12307,7 +12307,7 @@ function vd({ variant: e, onSubmit: t }) {
12307
12307
  {
12308
12308
  className: "page-feedback__panel",
12309
12309
  onSubmit: (w) => {
12310
- w.preventDefault(), b();
12310
+ w.preventDefault(), g();
12311
12311
  },
12312
12312
  children: [
12313
12313
  /* @__PURE__ */ _("label", { className: "page-feedback__field", children: [
@@ -12494,9 +12494,9 @@ function Cd({
12494
12494
  onCommand: m,
12495
12495
  disabled: d = !1
12496
12496
  }) {
12497
- const f = me(), g = R(null), [h, p] = Y(""), [c, y] = Y(0), [b, w] = Y(0), [k, x] = Y(!1), T = R(0), [v, N] = Y(!1), [M, L] = Y([]), E = Cc(s, o, i), P = Pc(h, c, E), D = h.slice(0, c).match(/(?:^|\n)\/([^\s/]*)$/), C = !!D, S = E.some((z) => z.char === "@"), O = P?.trigger, B = Ec(!d && !v && !C ? P?.query : void 0, O?.onQuery), A = D ? u.filter((z) => [z.label, ...z.keywords ?? []].some((te) => te.includes(D[1]))) : P ? O?.onQuery ? B.matches : (O?.options ?? []).filter((z) => z.label.includes(P.query)) : [], U = !d && !v && (A.length > 0 || !!(!C && P && O?.onQuery)), K = Math.min(b, Math.max(0, A.length - 1));
12497
+ const f = me(), b = R(null), [h, p] = Y(""), [c, y] = Y(0), [g, w] = Y(0), [k, x] = Y(!1), T = R(0), [v, N] = Y(!1), [M, L] = Y([]), E = Cc(s, o, i), P = Pc(h, c, E), D = h.slice(0, c).match(/(?:^|\n)\/([^\s/]*)$/), C = !!D, S = E.some((z) => z.char === "@"), O = P?.trigger, B = Ec(!d && !v && !C ? P?.query : void 0, O?.onQuery), A = D ? u.filter((z) => [z.label, ...z.keywords ?? []].some((te) => te.includes(D[1]))) : P ? O?.onQuery ? B.matches : (O?.options ?? []).filter((z) => z.label.includes(P.query)) : [], U = !d && !v && (A.length > 0 || !!(!C && P && O?.onQuery)), K = Math.min(g, Math.max(0, A.length - 1));
12498
12498
  pe(() => {
12499
- const z = g.current;
12499
+ const z = b.current;
12500
12500
  if (!z) return;
12501
12501
  z.style.height = "auto";
12502
12502
  const te = Number.parseFloat(getComputedStyle(z).maxHeight);
@@ -12520,7 +12520,7 @@ function Cd({
12520
12520
  const V = c - (D?.[1].length ?? 0) - 1, Z = h.slice(0, V) + `/${z.label} `;
12521
12521
  Zt(() => {
12522
12522
  Q(Z + h.slice(c), Z.length), N(!0);
12523
- }), g.current?.focus(), g.current?.setSelectionRange(Z.length, Z.length);
12523
+ }), b.current?.focus(), b.current?.setSelectionRange(Z.length, Z.length);
12524
12524
  return;
12525
12525
  }
12526
12526
  if (!P) return;
@@ -12532,7 +12532,7 @@ function Cd({
12532
12532
  L((V) => [
12533
12533
  ...V.flatMap((Z) => Z.end <= te ? [Z] : Z.start >= c ? [{ ...Z, start: Z.start + q, end: Z.end + q }] : []),
12534
12534
  { person: z, char: P.trigger.char, token: $, start: te, end: I.length - 1 }
12535
- ]), g.current?.focus(), g.current?.setSelectionRange(I.length, I.length);
12535
+ ]), b.current?.focus(), b.current?.setSelectionRange(I.length, I.length);
12536
12536
  }
12537
12537
  function ne() {
12538
12538
  if (d || !h.trim()) return;
@@ -12566,7 +12566,7 @@ function Cd({
12566
12566
  !C && O?.onQuery && !A.length ? /* @__PURE__ */ _("div", { className: "composer__mention-status", children: [
12567
12567
  /* @__PURE__ */ n("span", { role: "status", children: B.state === "loading" ? O.char === "@" ? "正在加载成员…" : `正在加载${O.label}…` : B.state === "error" ? O.errorText ?? (O.char === "@" ? "无法加载成员,请重试。" : `无法加载${O.label},请重试。`) : O.emptyText ?? (O.char === "@" ? "没有匹配的成员" : `没有匹配的${O.label}`) }),
12568
12568
  B.state === "error" ? /* @__PURE__ */ n($e, { type: "button", size: "sm", onClick: () => {
12569
- g.current?.focus(), B.retry();
12569
+ b.current?.focus(), B.retry();
12570
12570
  }, children: "重试" }) : null
12571
12571
  ] }) : null
12572
12572
  ] }) : null,
@@ -12593,7 +12593,7 @@ function Cd({
12593
12593
  "textarea",
12594
12594
  {
12595
12595
  id: f,
12596
- ref: g,
12596
+ ref: b,
12597
12597
  value: h,
12598
12598
  disabled: d,
12599
12599
  rows: 1,
@@ -12657,9 +12657,9 @@ function Cd({
12657
12657
  "aria-label": "提及成员",
12658
12658
  disabled: d,
12659
12659
  onClick: () => {
12660
- const z = g.current?.selectionStart ?? h.length;
12660
+ const z = b.current?.selectionStart ?? h.length;
12661
12661
  Q(h.slice(0, z) + "@" + h.slice(z), z + 1), requestAnimationFrame(() => {
12662
- g.current?.focus(), g.current?.setSelectionRange(z + 1, z + 1);
12662
+ b.current?.focus(), b.current?.setSelectionRange(z + 1, z + 1);
12663
12663
  });
12664
12664
  },
12665
12665
  children: [
@@ -12752,13 +12752,13 @@ function Wo(e, t) {
12752
12752
  o(!1);
12753
12753
  return;
12754
12754
  }
12755
- const u = s.getComputedStyle(a).animationDuration.split(",").map((g) => parseFloat(g) * (g.trim().endsWith("ms") ? 1 : 1e3)), m = Math.max(0, ...u);
12755
+ const u = s.getComputedStyle(a).animationDuration.split(",").map((b) => parseFloat(b) * (b.trim().endsWith("ms") ? 1 : 1e3)), m = Math.max(0, ...u);
12756
12756
  if (!m) {
12757
12757
  o(!1);
12758
12758
  return;
12759
12759
  }
12760
- const d = (g) => {
12761
- g.target === a && o(!1);
12760
+ const d = (b) => {
12761
+ b.target === a && o(!1);
12762
12762
  };
12763
12763
  a.addEventListener("animationend", d);
12764
12764
  const f = s.setTimeout(() => o(!1), m + m / 2);
@@ -12768,22 +12768,22 @@ function Wo(e, t) {
12768
12768
  }, [e, t, r]), i;
12769
12769
  }
12770
12770
  function Dd({ trigger: e, children: t, openDelay: r = 0, closeDelay: o = 90, side: i = "bottom", align: a = "start", className: s }) {
12771
- const [l, u] = Y(!1), m = me(), d = R(null), f = R(null), g = R(void 0), h = R(void 0), p = R(!1), c = R(!1), y = R(!1), b = R(!1), w = Wo(l, f);
12771
+ const [l, u] = Y(!1), m = me(), d = R(null), f = R(null), b = R(void 0), h = R(void 0), p = R(!1), c = R(!1), y = R(!1), g = R(!1), w = Wo(l, f);
12772
12772
  function k() {
12773
- clearTimeout(g.current), clearTimeout(h.current);
12773
+ clearTimeout(b.current), clearTimeout(h.current);
12774
12774
  }
12775
12775
  function x() {
12776
12776
  k(), y.current = !0, u(!1);
12777
12777
  }
12778
12778
  function T() {
12779
- clearTimeout(h.current), !y.current && (clearTimeout(g.current), g.current = setTimeout(() => u(!0), Number.isFinite(r) ? Math.max(0, r) : 0));
12779
+ clearTimeout(h.current), !y.current && (clearTimeout(b.current), b.current = setTimeout(() => u(!0), Number.isFinite(r) ? Math.max(0, r) : 0));
12780
12780
  }
12781
12781
  function v() {
12782
- p.current || c.current || (clearTimeout(g.current), clearTimeout(h.current), y.current = !1, h.current = setTimeout(() => u(!1), Number.isFinite(o) ? Math.max(0, o) : 90));
12782
+ p.current || c.current || (clearTimeout(b.current), clearTimeout(h.current), y.current = !1, h.current = setTimeout(() => u(!1), Number.isFinite(o) ? Math.max(0, o) : 90));
12783
12783
  }
12784
12784
  ie(() => {
12785
12785
  const P = d.current?.ownerDocument, D = () => {
12786
- b.current = !1;
12786
+ g.current = !1;
12787
12787
  };
12788
12788
  return P?.addEventListener("keydown", D, !0), () => {
12789
12789
  k(), P?.removeEventListener("keydown", D, !0);
@@ -12801,10 +12801,10 @@ function Dd({ trigger: e, children: t, openDelay: r = 0, closeDelay: o = 90, sid
12801
12801
  d.current = P?.querySelector("button[aria-controls]") ?? null;
12802
12802
  },
12803
12803
  onFocus: (P) => {
12804
- b.current || P.target !== d.current || (c.current = !0, T());
12804
+ g.current || P.target !== d.current || (c.current = !0, T());
12805
12805
  },
12806
12806
  onBlur: (P) => {
12807
- P.target === d.current && (c.current = !1, b.current = !1, v());
12807
+ P.target === d.current && (c.current = !1, g.current = !1, v());
12808
12808
  },
12809
12809
  onKeyDown: (P) => {
12810
12810
  P.key === "Escape" && !l && x();
@@ -12813,7 +12813,7 @@ function Dd({ trigger: e, children: t, openDelay: r = 0, closeDelay: o = 90, sid
12813
12813
  "aria-controls": m,
12814
12814
  "aria-describedby": E,
12815
12815
  onPointerDown: (P) => {
12816
- e.props.onPointerDown?.(P), b.current = !0, c.current = !1;
12816
+ e.props.onPointerDown?.(P), g.current = !0, c.current = !1;
12817
12817
  },
12818
12818
  onPointerEnter: (P) => {
12819
12819
  e.props.onPointerEnter?.(P), !(P.defaultPrevented || d.current?.disabled || P.pointerType === "touch" || matchMedia("(pointer: coarse)").matches) && (p.current = !0, T());
@@ -12884,19 +12884,19 @@ function Mc({
12884
12884
  placement: m,
12885
12885
  modal: d = !1,
12886
12886
  ariaModal: f = !1,
12887
- role: g,
12887
+ role: b,
12888
12888
  ariaLabel: h,
12889
12889
  ariaLabelledBy: p,
12890
12890
  ariaDescribedBy: c,
12891
12891
  offset: y = 8,
12892
- matchWidth: b = !1,
12892
+ matchWidth: g = !1,
12893
12893
  selectedValue: w,
12894
12894
  initialFocus: k = "first",
12895
12895
  id: x,
12896
12896
  className: T,
12897
12897
  dismissExcludeRefs: v
12898
12898
  }) {
12899
- const [N, M] = Y(t), L = st(Mr), E = (e ?? N) && L?.open !== !1, P = R(!1), D = R(null), C = a ?? D, S = R(null), O = me(), B = x ?? O, A = d || f, U = g ?? (!A && a ? "menu" : "dialog");
12899
+ const [N, M] = Y(t), L = st(Mr), E = (e ?? N) && L?.open !== !1, P = R(!1), D = R(null), C = a ?? D, S = R(null), O = me(), B = x ?? O, A = d || f, U = b ?? (!A && a ? "menu" : "dialog");
12900
12900
  if (A && U !== "dialog") throw new Error("A modal Popover requires role=dialog");
12901
12901
  const K = Wo(E, S), Q = R(s);
12902
12902
  E && (Q.current = s);
@@ -12915,9 +12915,9 @@ function Mc({
12915
12915
  }, [V, o]), F = De(() => ({
12916
12916
  offset: Number.isFinite(y) ? Math.max(0, y) : 8,
12917
12917
  fixedSide: !!(m && !m.startsWith("auto")),
12918
- matchWidth: b,
12918
+ matchWidth: g,
12919
12919
  closeWhenAnchorHidden: !!a
12920
- }), [a, b, y, m]), W = m ? m.startsWith("top") ? "top" : "bottom" : l, re = m ? m.endsWith("end") ? "end" : "start" : u, { portalPopup: H, placement: ee, onOverlayKeyDown: j, focusInitialIfTopMost: se, portalRoot: be, requestClose: de } = ot(E, C, S, (le) => {
12920
+ }), [a, g, y, m]), W = m ? m.startsWith("top") ? "top" : "bottom" : l, re = m ? m.endsWith("end") ? "end" : "start" : u, { portalPopup: H, placement: ee, onOverlayKeyDown: j, focusInitialIfTopMost: se, portalRoot: be, requestClose: de } = ot(E, C, S, (le) => {
12921
12921
  if (q.current) return;
12922
12922
  Z();
12923
12923
  const ke = S.current?.ownerDocument, Se = ke?.activeElement;
@@ -13023,26 +13023,26 @@ function Mc({
13023
13023
  ] });
13024
13024
  }
13025
13025
  function Id(e) {
13026
- const { items: t, ariaLabel: r, size: o = "md", disabled: i = !1 } = e, a = R([]), [s, l] = Y(() => e.type === "multiple" ? e.defaultValue ?? [] : e.defaultValue !== void 0 && t.some((b) => b.value === e.defaultValue) ? e.defaultValue : e.allowEmpty ? "" : t.find((b) => !b.disabled)?.value ?? ""), [u, m] = Y(null), d = t.filter((b) => !i && !b.disabled), f = e.value !== void 0, g = f ? e.value : s, h = e.type === "multiple" ? Array.isArray(g) ? g : [] : [typeof g == "string" && t.some((b) => b.value === g) ? g : f || e.allowEmpty ? typeof g == "string" ? g : "" : d[0]?.value ?? ""], p = d.find((b) => b.value === u)?.value ?? d.find((b) => h.includes(b.value))?.value ?? d[0]?.value;
13027
- for (const b of t)
13028
- if (!b.label && (!b.ariaLabel?.trim() || !b.icon))
13026
+ const { items: t, ariaLabel: r, size: o = "md", disabled: i = !1 } = e, a = R([]), [s, l] = Y(() => e.type === "multiple" ? e.defaultValue ?? [] : e.defaultValue !== void 0 && t.some((g) => g.value === e.defaultValue) ? e.defaultValue : e.allowEmpty ? "" : t.find((g) => !g.disabled)?.value ?? ""), [u, m] = Y(null), d = t.filter((g) => !i && !g.disabled), f = e.value !== void 0, b = f ? e.value : s, h = e.type === "multiple" ? Array.isArray(b) ? b : [] : [typeof b == "string" && t.some((g) => g.value === b) ? b : f || e.allowEmpty ? typeof b == "string" ? b : "" : d[0]?.value ?? ""], p = d.find((g) => g.value === u)?.value ?? d.find((g) => h.includes(g.value))?.value ?? d[0]?.value;
13027
+ for (const g of t)
13028
+ if (!g.label && (!g.ariaLabel?.trim() || !g.icon))
13029
13029
  throw new Error("ToggleGroup: icon-only items require an icon and ariaLabel.");
13030
- function c(b) {
13031
- if (!(i || b.disabled))
13030
+ function c(g) {
13031
+ if (!(i || g.disabled))
13032
13032
  if (e.type === "single") {
13033
- if (h.includes(b.value) && !e.allowEmpty) return;
13034
- const w = h.includes(b.value) ? "" : b.value;
13033
+ if (h.includes(g.value) && !e.allowEmpty) return;
13034
+ const w = h.includes(g.value) ? "" : g.value;
13035
13035
  f || l(w), e.onValueChange?.(w);
13036
13036
  } else {
13037
- const w = h.includes(b.value) ? h.filter((k) => k !== b.value) : [...h, b.value];
13037
+ const w = h.includes(g.value) ? h.filter((k) => k !== g.value) : [...h, g.value];
13038
13038
  f || l(w), e.onValueChange?.(w);
13039
13039
  }
13040
13040
  }
13041
- function y(b, w) {
13042
- if (b.nativeEvent.isComposing || b.nativeEvent.keyCode === 229) return;
13041
+ function y(g, w) {
13042
+ if (g.nativeEvent.isComposing || g.nativeEvent.keyCode === 229) return;
13043
13043
  const k = d.findIndex((v) => v.value === w);
13044
13044
  let x;
13045
- switch (b.key) {
13045
+ switch (g.key) {
13046
13046
  case "Home":
13047
13047
  x = 0;
13048
13048
  break;
@@ -13060,11 +13060,11 @@ function Id(e) {
13060
13060
  default:
13061
13061
  return;
13062
13062
  }
13063
- b.preventDefault();
13063
+ g.preventDefault();
13064
13064
  const T = d[x];
13065
13065
  T && (m(T.value), a.current[t.indexOf(T)]?.focus());
13066
13066
  }
13067
- return /* @__PURE__ */ n("div", { className: ce("toggle-group", `toggle-group--${o}`), role: "group", "aria-label": r, children: t.map((b, w) => /* @__PURE__ */ _(
13067
+ return /* @__PURE__ */ n("div", { className: ce("toggle-group", `toggle-group--${o}`), role: "group", "aria-label": r, children: t.map((g, w) => /* @__PURE__ */ _(
13068
13068
  "button",
13069
13069
  {
13070
13070
  ref: (k) => {
@@ -13072,24 +13072,24 @@ function Id(e) {
13072
13072
  },
13073
13073
  type: "button",
13074
13074
  className: "toggle-group__item",
13075
- "aria-label": b.ariaLabel,
13076
- "aria-pressed": h.includes(b.value),
13077
- disabled: i || b.disabled,
13078
- tabIndex: b.value === p ? 0 : -1,
13079
- onFocus: () => m(b.value),
13080
- onKeyDown: (k) => y(k, b.value),
13081
- onClick: () => c(b),
13075
+ "aria-label": g.ariaLabel,
13076
+ "aria-pressed": h.includes(g.value),
13077
+ disabled: i || g.disabled,
13078
+ tabIndex: g.value === p ? 0 : -1,
13079
+ onFocus: () => m(g.value),
13080
+ onKeyDown: (k) => y(k, g.value),
13081
+ onClick: () => c(g),
13082
13082
  children: [
13083
- b.icon ? /* @__PURE__ */ n("span", { className: "toggle-group__icon", "aria-hidden": "true", children: b.icon }) : null,
13084
- b.label ? /* @__PURE__ */ n("span", { children: b.label }) : null,
13083
+ g.icon ? /* @__PURE__ */ n("span", { className: "toggle-group__icon", "aria-hidden": "true", children: g.icon }) : null,
13084
+ g.label ? /* @__PURE__ */ n("span", { children: g.label }) : null,
13085
13085
  /* @__PURE__ */ n(Te, {})
13086
13086
  ]
13087
13087
  },
13088
- b.value
13088
+ g.value
13089
13089
  )) });
13090
13090
  }
13091
- function Td({ direction: e = "incoming", avatar: t, name: r, time: o, children: i, status: a = "default", pending: s = "正在发送…", error: l = "无法发送消息,请重试。", retry: u, onRetry: m, actions: d, className: f, ...g }) {
13092
- return /* @__PURE__ */ _("article", { ...g, className: `bubble bubble--${e} bubble--${a}${f ? ` ${f}` : ""}`, children: [
13091
+ function Td({ direction: e = "incoming", avatar: t, name: r, time: o, children: i, status: a = "default", pending: s = "正在发送…", error: l = "无法发送消息,请重试。", retry: u, onRetry: m, actions: d, className: f, ...b }) {
13092
+ return /* @__PURE__ */ _("article", { ...b, className: `bubble bubble--${e} bubble--${a}${f ? ` ${f}` : ""}`, children: [
13093
13093
  t ? /* @__PURE__ */ n("div", { className: "bubble__avatar", children: t }) : null,
13094
13094
  /* @__PURE__ */ _("div", { className: "bubble__main", children: [
13095
13095
  r || o ? /* @__PURE__ */ _("header", { className: "bubble__meta", children: [
@@ -13106,7 +13106,7 @@ function Td({ direction: e = "incoming", avatar: t, name: r, time: o, children:
13106
13106
  ] });
13107
13107
  }
13108
13108
  function Md({ label: e, items: t, conversationKey: r, nearBottomThreshold: o = 64, announcement: i, jumpLabel: a = "前往最新消息", before: s, empty: l, className: u, style: m }) {
13109
- const d = R(null), f = R(null), g = R(!0), h = R(null), p = R(""), c = R(!1), y = R(null), [b, w] = Y(!1), [k, x] = Y(""), T = Number.isFinite(o) ? Math.max(0, o) : 64;
13109
+ const d = R(null), f = R(null), b = R(!0), h = R(null), p = R(""), c = R(!1), y = R(null), [g, w] = Y(!1), [k, x] = Y(""), T = Number.isFinite(o) ? Math.max(0, o) : 64;
13110
13110
  function v() {
13111
13111
  const E = d.current;
13112
13112
  if (!E) return;
@@ -13117,12 +13117,12 @@ function Md({ label: e, items: t, conversationKey: r, nearBottomThreshold: o = 6
13117
13117
  const E = d.current;
13118
13118
  if (!E) return;
13119
13119
  const P = E.scrollHeight - E.clientHeight - E.scrollTop;
13120
- g.current = P <= T, P < 1 && (c.current = !1), w(!g.current), v();
13120
+ b.current = P <= T, P < 1 && (c.current = !1), w(!b.current), v();
13121
13121
  }
13122
13122
  function M(E = !1) {
13123
13123
  const P = d.current;
13124
13124
  if (P) {
13125
- if (g.current && !E) P.scrollTop = P.scrollHeight;
13125
+ if (b.current && !E) P.scrollTop = P.scrollHeight;
13126
13126
  else if (h.current) {
13127
13127
  const D = h.current, C = Array.from(f.current?.children ?? []).find((S) => S.getAttribute("data-message-id") === D.id);
13128
13128
  C && (P.scrollTop += C.getBoundingClientRect().top - P.getBoundingClientRect().top - D.top);
@@ -13133,7 +13133,7 @@ function Md({ label: e, items: t, conversationKey: r, nearBottomThreshold: o = 6
13133
13133
  pe(() => {
13134
13134
  const E = t.map((O) => String(O.id)), P = y.current;
13135
13135
  if (!P || P.key !== r)
13136
- g.current = !0, h.current = null, w(!1), x("");
13136
+ b.current = !0, h.current = null, w(!1), x("");
13137
13137
  else {
13138
13138
  const O = P.ids.at(-1), B = O === void 0 ? 0 : E.indexOf(O) + 1, A = B > 0 || P.ids.length === 0 ? E.slice(B).filter((U) => !P.ids.includes(U)).length : 0;
13139
13139
  A && x(`收到 ${A} 条新消息,共 ${E.length} 条。`);
@@ -13150,14 +13150,14 @@ function Md({ label: e, items: t, conversationKey: r, nearBottomThreshold: o = 6
13150
13150
  return C.observe(E), C.observe(P), () => C.disconnect();
13151
13151
  }, []);
13152
13152
  function L() {
13153
- g.current = !0, c.current = !1, M(), w(!1), d.current?.focus({ preventScroll: !0 });
13153
+ b.current = !0, c.current = !1, M(), w(!1), d.current?.focus({ preventScroll: !0 });
13154
13154
  }
13155
13155
  return /* @__PURE__ */ _("div", { className: `message-scroller${u ? ` ${u}` : ""}`, style: m, children: [
13156
13156
  /* @__PURE__ */ n("div", { className: "message-scroller__viewport", ref: d, role: "region", "aria-label": e, tabIndex: 0, onScroll: N, children: /* @__PURE__ */ _("div", { className: "message-scroller__content", ref: f, children: [
13157
13157
  s,
13158
13158
  t.length ? t.map((E) => /* @__PURE__ */ n("div", { className: "message-scroller__item", "data-message-id": String(E.id), children: E.content }, E.id)) : l
13159
13159
  ] }) }),
13160
- b ? /* @__PURE__ */ n("div", { className: "message-scroller__jump", children: /* @__PURE__ */ n($e, { size: "sm", onClick: L, children: a }) }) : null,
13160
+ g ? /* @__PURE__ */ n("div", { className: "message-scroller__jump", children: /* @__PURE__ */ n($e, { size: "sm", onClick: L, children: a }) }) : null,
13161
13161
  /* @__PURE__ */ n("div", { className: "message-scroller__notice", role: "status", "aria-live": "polite", "aria-atomic": "true", children: i ?? k })
13162
13162
  ] });
13163
13163
  }
@@ -13178,9 +13178,9 @@ function Sd({
13178
13178
  noMatchText: m = (h) => `没有匹配「${h}」的结果`,
13179
13179
  filter: d = Sc,
13180
13180
  query: f,
13181
- onQueryChange: g
13181
+ onQueryChange: b
13182
13182
  }) {
13183
- const [h, p] = Y(""), c = f ?? h, [y, b] = Y(t), w = me(), k = `${w}-list`, x = R(null), T = R(null), v = a || s ? [] : d(e, c), N = v.findIndex((P) => P.value === y && !P.disabled), M = N < 0 ? void 0 : `${w}-option-${N}`;
13183
+ const [h, p] = Y(""), c = f ?? h, [y, g] = Y(t), w = me(), k = `${w}-list`, x = R(null), T = R(null), v = a || s ? [] : d(e, c), N = v.findIndex((P) => P.value === y && !P.disabled), M = N < 0 ? void 0 : `${w}-option-${N}`;
13184
13184
  pe(() => {
13185
13185
  const P = x.current, D = P?.closest(".popover-panel");
13186
13186
  let C = !0;
@@ -13198,7 +13198,7 @@ function Sd({
13198
13198
  M && T.current?.ownerDocument.getElementById(M)?.scrollIntoView({ block: "nearest" });
13199
13199
  }, [M]);
13200
13200
  function L(P) {
13201
- f === void 0 && p(P), g?.(P), b(void 0);
13201
+ f === void 0 && p(P), b?.(P), g(void 0);
13202
13202
  }
13203
13203
  function E(P) {
13204
13204
  if (P.nativeEvent.isComposing) return;
@@ -13206,7 +13206,7 @@ function Sd({
13206
13206
  if (["ArrowDown", "ArrowUp", "Home", "End"].includes(P.key)) {
13207
13207
  if (P.preventDefault(), !D.length) return;
13208
13208
  const S = P.key === "Home" ? 0 : P.key === "End" ? D.length - 1 : P.key === "ArrowDown" ? (C + 1) % D.length : C < 0 ? D.length - 1 : (C - 1 + D.length) % D.length;
13209
- b(D[S].value);
13209
+ g(D[S].value);
13210
13210
  } else P.key === "Enter" && N >= 0 && (P.preventDefault(), r(v[N].value));
13211
13211
  }
13212
13212
  return /* @__PURE__ */ _("div", { className: "filter-option-panel", children: [
@@ -13276,15 +13276,15 @@ function $c(e, t, r, o) {
13276
13276
  return o >= 0 && o < i && !l.includes(o) && l.push(o), l.sort((u, m) => u - m);
13277
13277
  }
13278
13278
  function qc(e, t, r) {
13279
- const o = R(null), i = R(null), a = R(/* @__PURE__ */ new Map()), s = R(/* @__PURE__ */ new Map()), [l, u] = Y(0), [m, d] = Y(40), [f, g] = Y({ top: 0, height: 240 }), h = e.length > 30, p = (k) => k.rowKey ?? k.value, c = De(() => e.map(p).join("\0"), [e]);
13279
+ const o = R(null), i = R(null), a = R(/* @__PURE__ */ new Map()), s = R(/* @__PURE__ */ new Map()), [l, u] = Y(0), [m, d] = Y(40), [f, b] = Y({ top: 0, height: 240 }), h = e.length > 30, p = (k) => k.rowKey ?? k.value, c = De(() => e.map(p).join("\0"), [e]);
13280
13280
  pe(() => {
13281
- o.current && (o.current.scrollTop = 0), g((k) => k.top === 0 ? k : { ...k, top: 0 });
13281
+ o.current && (o.current.scrollTop = 0), b((k) => k.top === 0 ? k : { ...k, top: 0 });
13282
13282
  }, [r, c]);
13283
13283
  const y = De(() => {
13284
13284
  const k = [0];
13285
13285
  for (const x of e) k.push(k[k.length - 1] + (s.current.get(p(x)) ?? m));
13286
13286
  return k;
13287
- }, [e, l, m]), b = h ? $c(y, f.top, f.height, t) : e.map((k, x) => x);
13287
+ }, [e, l, m]), g = h ? $c(y, f.top, f.height, t) : e.map((k, x) => x);
13288
13288
  pe(() => {
13289
13289
  const k = o.current;
13290
13290
  if (!k) return;
@@ -13294,7 +13294,7 @@ function qc(e, t, r) {
13294
13294
  let L = !1;
13295
13295
  for (const E of M) {
13296
13296
  if (E.target === k) {
13297
- g((S) => ({ top: S.top, height: k.clientHeight }));
13297
+ b((S) => ({ top: S.top, height: k.clientHeight }));
13298
13298
  continue;
13299
13299
  }
13300
13300
  const P = E.target, D = P.dataset.windowKey, C = P.getBoundingClientRect().height;
@@ -13310,9 +13310,9 @@ function qc(e, t, r) {
13310
13310
  const T = a.current.get(k);
13311
13311
  T && i.current?.unobserve(T), x ? (a.current.set(k, x), i.current?.observe(x)) : a.current.delete(k);
13312
13312
  }
13313
- return { listRef: o, indices: b, offsets: y, virtual: h, measure: w, onScroll: () => {
13313
+ return { listRef: o, indices: g, offsets: y, virtual: h, measure: w, onScroll: () => {
13314
13314
  const k = o.current;
13315
- k && g({ top: k.scrollTop, height: k.clientHeight });
13315
+ k && b({ top: k.scrollTop, height: k.clientHeight });
13316
13316
  } };
13317
13317
  }
13318
13318
  function Rc({
@@ -13328,12 +13328,12 @@ function Rc({
13328
13328
  loadError: m,
13329
13329
  onRetry: d,
13330
13330
  onTabExit: f,
13331
- onFooterActivate: g,
13331
+ onFooterActivate: b,
13332
13332
  inputRef: h,
13333
13333
  emptyText: p,
13334
13334
  clearable: c,
13335
13335
  footer: y,
13336
- required: b
13336
+ required: g
13337
13337
  }) {
13338
13338
  const w = me(), k = `${w}-list`, [x, T] = Y(), v = R(!1), N = a.trim().toLowerCase();
13339
13339
  pe(() => {
@@ -13371,7 +13371,7 @@ function Rc({
13371
13371
  X && (K.preventDefault(), X.focus());
13372
13372
  }
13373
13373
  }
13374
- const U = fo(g);
13374
+ const U = fo(b);
13375
13375
  return /* @__PURE__ */ _("div", { className: "multi-combobox__panel", onKeyDown: (K) => {
13376
13376
  if (K.key !== "Tab" || K.defaultPrevented) return;
13377
13377
  const Q = Array.from(K.currentTarget.querySelectorAll('button:not([disabled]), .multi-combobox__footer a[href], .multi-combobox__footer input:not([disabled]), .multi-combobox__footer select:not([disabled]), .multi-combobox__footer textarea:not([disabled]), .multi-combobox__footer [tabindex]:not([tabindex="-1"])'));
@@ -13386,7 +13386,7 @@ function Rc({
13386
13386
  prefixStyling: !1,
13387
13387
  type: "text",
13388
13388
  role: "combobox",
13389
- "aria-required": b || void 0,
13389
+ "aria-required": g || void 0,
13390
13390
  "aria-label": o,
13391
13391
  "aria-autocomplete": "list",
13392
13392
  "aria-expanded": "true",
@@ -13471,12 +13471,12 @@ function $d({
13471
13471
  isLoading: m,
13472
13472
  loadError: d,
13473
13473
  onRetry: f,
13474
- emptyText: g,
13474
+ emptyText: b,
13475
13475
  footer: h,
13476
13476
  required: p,
13477
13477
  disabled: c,
13478
13478
  readOnly: y,
13479
- invalid: b,
13479
+ invalid: g,
13480
13480
  errorId: w,
13481
13481
  error: k,
13482
13482
  clearable: x,
@@ -13488,7 +13488,7 @@ function $d({
13488
13488
  "aria-labelledby": E,
13489
13489
  "aria-describedby": P
13490
13490
  }) {
13491
- const D = me(), C = T ?? `${D}-trigger`, S = `${D}-summary`, O = `${D}-required`, B = `${D}-error`, A = `${D}-popup`, [U, K] = Y(!1), [Q, G] = Y(""), X = R(null), ne = R(null), z = R(null), te = !c && !y, $ = U && te, I = !!(b || k), q = (H) => i.find((ee) => ee.value === H)?.label ?? e.find((ee) => ee.value === H)?.label ?? H;
13491
+ const D = me(), C = T ?? `${D}-trigger`, S = `${D}-summary`, O = `${D}-required`, B = `${D}-error`, A = `${D}-popup`, [U, K] = Y(!1), [Q, G] = Y(""), X = R(null), ne = R(null), z = R(null), te = !c && !y, $ = U && te, I = !!(g || k), q = (H) => i.find((ee) => ee.value === H)?.label ?? e.find((ee) => ee.value === H)?.label ?? H;
13492
13492
  function V(H) {
13493
13493
  H !== U && (K(H), o?.(H));
13494
13494
  }
@@ -13589,7 +13589,7 @@ function $d({
13589
13589
  isLoading: m,
13590
13590
  loadError: d,
13591
13591
  onRetry: f,
13592
- emptyText: g,
13592
+ emptyText: b,
13593
13593
  footer: h,
13594
13594
  required: p,
13595
13595
  clearable: x,
@@ -13612,8 +13612,21 @@ function qd({ ratio: e, children: t, className: r }) {
13612
13612
  return /* @__PURE__ */ n("div", { className: ce("aspect-ratio", r), style: { aspectRatio: o ? e : 1 }, children: t });
13613
13613
  }
13614
13614
  function Lc({ src: e, alt: t, loading: r, onError: o, className: i, fit: a, size: s }) {
13615
- const [l, u] = Y("loading"), m = R(null), d = fe((g) => {
13616
- m.current = g, g?.complete && u(g.naturalWidth > 0 ? "ready" : "error");
13615
+ const [l, u] = Y("loading"), m = R(null), d = fe((b) => {
13616
+ if (m.current = b, !!b?.complete) {
13617
+ if (b.naturalWidth > 0) {
13618
+ u("ready");
13619
+ return;
13620
+ }
13621
+ b.decode().then(
13622
+ () => {
13623
+ m.current === b && u("ready");
13624
+ },
13625
+ () => {
13626
+ m.current === b && u("error");
13627
+ }
13628
+ );
13629
+ }
13617
13630
  }, []), f = l === "error";
13618
13631
  return /* @__PURE__ */ _(
13619
13632
  "div",
@@ -13635,11 +13648,11 @@ function Lc({ src: e, alt: t, loading: r, onError: o, className: i, fit: a, size
13635
13648
  alt: f ? "" : t,
13636
13649
  loading: r,
13637
13650
  "aria-hidden": f ? !0 : void 0,
13638
- onLoad: (g) => {
13639
- g.currentTarget === m.current && u("ready");
13651
+ onLoad: (b) => {
13652
+ b.currentTarget === m.current && u("ready");
13640
13653
  },
13641
- onError: (g) => {
13642
- g.currentTarget === m.current && (u("error"), o?.(g));
13654
+ onError: (b) => {
13655
+ b.currentTarget === m.current && (u("error"), o?.(b));
13643
13656
  }
13644
13657
  }
13645
13658
  ),