@danxbot/ui 15.6.1 → 15.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { jsx as d, jsxs as P, Fragment as ct } from "react/jsx-runtime";
2
2
  import * as y from "react";
3
- import uu, { createElement as ix, useLayoutEffect as Gn, useState as fe, useRef as ye, useId as _t, Component as ZM, useCallback as Ne, useEffect as $e, createContext as Mn, useContext as Tn, useMemo as De, memo as du, useImperativeHandle as QM, Fragment as fh, Children as JM, isValidElement as eT, useSyncExternalStore as Vr } from "react";
3
+ import uu, { createElement as ix, useLayoutEffect as Gn, useState as fe, useRef as ye, useId as _t, Component as ZM, useCallback as Ne, useEffect as Ve, createContext as Mn, useContext as Tn, useMemo as De, memo as du, useImperativeHandle as QM, Fragment as fh, Children as JM, isValidElement as eT, useSyncExternalStore as Vr } from "react";
4
4
  import * as Rn from "react-dom";
5
5
  import { createPortal as tT } from "react-dom";
6
6
  const nT = {
@@ -12328,9 +12328,9 @@ function GD(e, t) {
12328
12328
  padding: H
12329
12329
  }, Z = y.useRef(null), ne = Tt(s), te = Tt(a), q = typeof s != "function" ? s : 0, J = typeof a != "function" ? a : 0, se = [];
12330
12330
  h && se.push(h), se.push(jA((Ke) => {
12331
- const et = pv(Ke, o, O), Ve = typeof ne.current == "function" ? ne.current(et) : ne.current, bt = typeof te.current == "function" ? te.current(et) : te.current;
12331
+ const et = pv(Ke, o, O), $e = typeof ne.current == "function" ? ne.current(et) : ne.current, bt = typeof te.current == "function" ? te.current(et) : te.current;
12332
12332
  return {
12333
- mainAxis: Ve,
12333
+ mainAxis: $e,
12334
12334
  crossAxis: bt,
12335
12335
  alignmentAxis: bt
12336
12336
  };
@@ -12359,8 +12359,8 @@ function GD(e, t) {
12359
12359
  return {};
12360
12360
  const {
12361
12361
  width: et,
12362
- height: Ve
12363
- } = Z.current.getBoundingClientRect(), bt = er(or(Ke.placement)), Xe = bt === "y" ? et : Ve, it = bt === "y" ? H.left + H.right : H.top + H.bottom;
12362
+ height: $e
12363
+ } = Z.current.getBoundingClientRect(), bt = er(or(Ke.placement)), Xe = bt === "y" ? et : $e, it = bt === "y" ? H.left + H.right : H.top + H.bottom;
12364
12364
  return {
12365
12365
  offset: Xe / 2 + it / 2
12366
12366
  };
@@ -12373,13 +12373,13 @@ function GD(e, t) {
12373
12373
  floating: Ke
12374
12374
  },
12375
12375
  availableWidth: et,
12376
- availableHeight: Ve,
12376
+ availableHeight: $e,
12377
12377
  rects: bt
12378
12378
  }) {
12379
12379
  if (!F.current)
12380
12380
  return;
12381
12381
  const Xe = Ke.style;
12382
- Xe.setProperty(dv, `${et}px`), Xe.setProperty(fv, `${Ve}px`);
12382
+ Xe.setProperty(dv, `${et}px`), Xe.setProperty(fv, `${$e}px`);
12383
12383
  const it = ht(Ke).devicePixelRatio || 1, {
12384
12384
  x: ut,
12385
12385
  y: Bt,
@@ -12399,11 +12399,11 @@ function GD(e, t) {
12399
12399
  fn(Ke) {
12400
12400
  const {
12401
12401
  elements: et,
12402
- middlewareData: Ve,
12402
+ middlewareData: $e,
12403
12403
  placement: bt,
12404
12404
  rects: Xe,
12405
12405
  y: it
12406
- } = Ke, ut = or(bt), Bt = er(ut), _e = Z.current, Rt = Ve.arrow?.x || 0, Nt = Ve.arrow?.y || 0, qe = _e?.clientWidth || 0, xt = _e?.clientHeight || 0, Ht = Rt + qe / 2, en = Nt + xt / 2, vn = Math.abs(Ve.shift?.y || 0), Kt = Xe.reference.height / 2, ln = typeof s == "function" ? s(pv(Ke, o, O)) : s, tn = vn > ln, nt = {
12406
+ } = Ke, ut = or(bt), Bt = er(ut), _e = Z.current, Rt = $e.arrow?.x || 0, Nt = $e.arrow?.y || 0, qe = _e?.clientWidth || 0, xt = _e?.clientHeight || 0, Ht = Rt + qe / 2, en = Nt + xt / 2, vn = Math.abs($e.shift?.y || 0), Kt = Xe.reference.height / 2, ln = typeof s == "function" ? s(pv(Ke, o, O)) : s, tn = vn > ln, nt = {
12407
12407
  top: `${Ht}px calc(100% + ${ln}px)`,
12408
12408
  bottom: `${Ht}px ${-ln}px`,
12409
12409
  left: `calc(100% + ${ln}px) ${en}px`,
@@ -15498,9 +15498,9 @@ function VC(e) {
15498
15498
  const t = ye(e);
15499
15499
  t.current = e;
15500
15500
  const [n, r] = fe(!1), [o, s] = fe(null), [i, a] = fe(null), [l, c] = fe(0), u = ye(!1), p = ye(0), f = ye(e.value), h = ye(null), m = ye([]);
15501
- $e(() => {
15501
+ Ve(() => {
15502
15502
  l > 0 && t.current.refocus();
15503
- }, [l]), $e(
15503
+ }, [l]), Ve(
15504
15504
  () => () => {
15505
15505
  p.current += 1;
15506
15506
  },
@@ -15701,7 +15701,7 @@ function A_(e, t) {
15701
15701
  }
15702
15702
  function D_(e, t, n) {
15703
15703
  const r = ye(n);
15704
- r.current = n, $e(() => {
15704
+ r.current = n, Ve(() => {
15705
15705
  const o = e.current;
15706
15706
  if (!o) return;
15707
15707
  function s(i) {
@@ -15721,7 +15721,7 @@ function __({ delayMs: e, session: t, elRef: n, openRef: r, composingRef: o, ...
15721
15721
  function g() {
15722
15722
  c.current !== null && (clearTimeout(c.current), c.current = null);
15723
15723
  }
15724
- $e(
15724
+ Ve(
15725
15725
  () => () => {
15726
15726
  if (h.current = !0, c.current === null) return;
15727
15727
  g();
@@ -15867,13 +15867,13 @@ function M8(e) {
15867
15867
  onError: p,
15868
15868
  close: W
15869
15869
  }), { pending: z, refusal: F, blocked: B } = _, O = _t(), L = _t(), $ = u !== void 0, H = R && !$;
15870
- $e(() => {
15870
+ Ve(() => {
15871
15871
  S && R && $ && k(!1);
15872
15872
  }, [S, R, $, k]);
15873
15873
  function G(ie) {
15874
15874
  I.current = ie, typeof w == "function" ? w(ie) : w && (w.current = ie);
15875
15875
  }
15876
- $e(() => {
15876
+ Ve(() => {
15877
15877
  const ie = I.current;
15878
15878
  if (!ie) return;
15879
15879
  H && !D.current ? (_.begin(t, o?.(t) ?? null), V.seed(t), T.current = !0, Tv(ie, t), LC(ie), ie.focus(), M(t.length === 0)) : H || (T.current && X(), Tv(ie, t), M(t.length === 0)), D.current = H;
@@ -16012,33 +16012,61 @@ function F_({
16012
16012
  function V_(e, t) {
16013
16013
  return e === "multiline" ? "whitespace-pre-wrap break-words" : e === "wrap" ? "whitespace-normal break-words" : t ? "whitespace-nowrap overflow-x-auto" : "truncate";
16014
16014
  }
16015
- function T8({ label: e, children: t, editing: n, onEditingChange: r, disabled: o, className: s }) {
16015
+ function T8({
16016
+ label: e,
16017
+ children: t,
16018
+ editing: n,
16019
+ onEditingChange: r,
16020
+ disabled: o,
16021
+ className: s,
16022
+ size: i = "sm"
16023
+ }) {
16016
16024
  km("EditGutter", n, r);
16017
- const [i, a] = Us(n, !1, r), l = ye(null), c = ye(null), u = !i && !o;
16018
- return z_(l, c, u), B_(l, c, i), /* @__PURE__ */ P(
16025
+ const [a, l] = Us(n, !1, r), c = ye(null), u = ye(null), p = !a && !o, [f, h] = fe(!1);
16026
+ z_(c, u, p), B_(c, u, a), Ve(() => {
16027
+ p || h(!1);
16028
+ }, [p]);
16029
+ function m(g) {
16030
+ g.pointerType === "touch" && h(!0);
16031
+ }
16032
+ return /* @__PURE__ */ P(
16019
16033
  "div",
16020
16034
  {
16021
- ref: l,
16035
+ ref: c,
16022
16036
  "data-slot": "edit-gutter",
16023
- "data-editing": i || void 0,
16037
+ "data-editing": a || void 0,
16038
+ onPointerDown: m,
16024
16039
  className: U("group/edit-gutter relative min-w-0", s),
16025
16040
  children: [
16026
- u && /* @__PURE__ */ d(
16041
+ p && /* @__PURE__ */ d(
16027
16042
  "span",
16028
16043
  {
16029
- ref: c,
16044
+ ref: u,
16030
16045
  "data-slot": "edit-gutter-pencil",
16046
+ "data-touch-revealed": f || void 0,
16031
16047
  className: U(
16032
16048
  "absolute top-0 right-full z-10 flex",
16033
16049
  "transition-[var(--tx-colors),opacity] duration-(--dur-fast)",
16050
+ // DX-3623 — reveal on real HOVER or the pencil's OWN
16051
+ // `:focus-visible` (never `focus-within`, which also fires for
16052
+ // the M2 return-focus programmatic `.focus()` after a
16053
+ // pointer-driven close — see the module comment).
16034
16054
  "[@media(any-hover:hover)]:opacity-0",
16055
+ "[@media(any-hover:hover)]:pointer-events-none",
16035
16056
  "[@media(any-hover:hover)]:group-hover/edit-gutter:opacity-100",
16036
- "[@media(any-hover:hover)]:focus-within:opacity-100"
16057
+ "[@media(any-hover:hover)]:group-hover/edit-gutter:pointer-events-auto",
16058
+ "[@media(any-hover:hover)]:has-focus-visible:opacity-100",
16059
+ "[@media(any-hover:hover)]:has-focus-visible:pointer-events-auto",
16060
+ // DX-3623 AC3 — a device with NO hover capability starts
16061
+ // hidden too, and is armed only by `touchRevealed` (a tap).
16062
+ "[@media(any-hover:none)]:opacity-0",
16063
+ "[@media(any-hover:none)]:pointer-events-none",
16064
+ f && "[@media(any-hover:none)]:opacity-100 [@media(any-hover:none)]:pointer-events-auto"
16037
16065
  ),
16038
- children: /* @__PURE__ */ d(gt, { icon: /* @__PURE__ */ d(de, { name: "pencil", size: "sm" }), label: e, size: "sm", onClick: () => a(!0) })
16066
+ children: /* @__PURE__ */ d(gt, { icon: /* @__PURE__ */ d(de, { name: "pencil", size: i }), label: e, size: i, onClick: () => l(!0) })
16039
16067
  }
16040
16068
  ),
16041
- t({ editing: i, onEditingChange: a })
16069
+ t({ editing: a, onEditingChange: l })
16042
16070
  ]
16043
16071
  }
16044
16072
  );
@@ -16057,7 +16085,7 @@ function L_(e) {
16057
16085
  }
16058
16086
  function z_(e, t, n) {
16059
16087
  const r = ye(!1);
16060
- $e(() => {
16088
+ Ve(() => {
16061
16089
  const o = e.current, s = t.current;
16062
16090
  if (!n || !o || !s) return;
16063
16091
  function i() {
@@ -16082,7 +16110,7 @@ function z_(e, t, n) {
16082
16110
  }
16083
16111
  function B_(e, t, n) {
16084
16112
  const r = ye(n);
16085
- $e(() => {
16113
+ Ve(() => {
16086
16114
  const o = r.current && !n;
16087
16115
  if (r.current = n, !o) return;
16088
16116
  const s = document.activeElement;
@@ -23786,7 +23814,7 @@ function sz(e, t) {
23786
23814
  }
23787
23815
  function iz(e, t) {
23788
23816
  const [n, r] = fe(0), o = ye(null);
23789
- return $e(() => {
23817
+ return Ve(() => {
23790
23818
  if (!e) return;
23791
23819
  const s = e.root.ownerDocument, i = () => r((a) => a + 1);
23792
23820
  return s.addEventListener("selectionchange", i), () => s.removeEventListener("selectionchange", i);
@@ -23837,7 +23865,7 @@ function iy({ surface: e, state: t, run: n, container: r, external: o }) {
23837
23865
  },
23838
23866
  [e, r]
23839
23867
  );
23840
- $e(() => {
23868
+ Ve(() => {
23841
23869
  if (!e || !r || c) return;
23842
23870
  const h = e.root, m = (b) => {
23843
23871
  const x = gz(e, b.clientX, b.clientY);
@@ -23849,7 +23877,7 @@ function iy({ surface: e, state: t, run: n, container: r, external: o }) {
23849
23877
  return h.addEventListener("pointermove", m), r.addEventListener("pointerleave", g), () => {
23850
23878
  h.removeEventListener("pointermove", m), r.removeEventListener("pointerleave", g);
23851
23879
  };
23852
- }, [e, r, p, c, t.caret]), $e(() => {
23880
+ }, [e, r, p, c, t.caret]), Ve(() => {
23853
23881
  c || t.caret === null || (l(t.caret), i(p(t.caret)));
23854
23882
  }, [t.caret, p, c]);
23855
23883
  const f = De(
@@ -24061,7 +24089,7 @@ function Rr({ icon: e, label: t, onClick: n }) {
24061
24089
  }
24062
24090
  function fz({ surface: e, state: t, run: n, container: r }) {
24063
24091
  const [o, s] = fe(null);
24064
- if ($e(() => {
24092
+ if (Ve(() => {
24065
24093
  if (!e || !r) return;
24066
24094
  const a = e.root, l = (c) => {
24067
24095
  const u = e.getSelection();
@@ -24305,7 +24333,7 @@ function Ez({
24305
24333
  const R = ye(p);
24306
24334
  R.current = p;
24307
24335
  const [k, N] = fe(e.length === 0), M = _t(), I = ye(c), [T, A] = fe(null), [D, _] = fe(0), [V, z] = fe(null), F = ye(t);
24308
- F.current = t, $e(() => {
24336
+ F.current = t, Ve(() => {
24309
24337
  if (!g.current) return;
24310
24338
  const W = new TL({
24311
24339
  uploader: () => S.current,
@@ -24371,13 +24399,13 @@ function Ez({
24371
24399
  }
24372
24400
  }),
24373
24401
  [r, n]
24374
- ), $e(() => {
24402
+ ), Ve(() => {
24375
24403
  b.current?.setSource(e), N(e.length === 0), x.current?.sync();
24376
- }, [e]), $e(() => {
24404
+ }, [e]), Ve(() => {
24377
24405
  x.current?.uploaderChanged();
24378
24406
  }, [E]);
24379
24407
  const B = !n && v.unstored > 0;
24380
- $e(() => {
24408
+ Ve(() => {
24381
24409
  if (!B) return;
24382
24410
  const W = (j) => {
24383
24411
  j.preventDefault(), j.returnValue = !0;
@@ -24791,7 +24819,7 @@ function U8(e) {
24791
24819
  close: () => n(!1),
24792
24820
  refocus: () => o.current?.focus()
24793
24821
  });
24794
- return $e(() => {
24822
+ return Ve(() => {
24795
24823
  t && r && n(!1);
24796
24824
  }, [t, r, n]), t && !r ? /* @__PURE__ */ d(Oz, { ...e, session: s, editorRef: o }) : /* @__PURE__ */ d(Pz, { ...e });
24797
24825
  }
@@ -24836,12 +24864,12 @@ function Oz({
24836
24864
  function E(N) {
24837
24865
  C.current !== N && (C.current = N, v.current?.(N));
24838
24866
  }
24839
- $e(() => () => E(!1), []);
24867
+ Ve(() => () => E(!1), []);
24840
24868
  const S = Az({
24841
24869
  shouldCommit: () => !l.isPending() && x.current === null,
24842
24870
  commit: w
24843
24871
  });
24844
- $e(() => {
24872
+ Ve(() => {
24845
24873
  l.begin(e);
24846
24874
  const N = c.current;
24847
24875
  if (!N) throw new Error("InlineMarkdownEdit: the editor was not mounted when the field opened.");
@@ -24900,7 +24928,7 @@ function Az({ shouldCommit: e, commit: t }) {
24900
24928
  function i() {
24901
24929
  r.current !== null && clearTimeout(r.current), r.current = null, o.current !== null && window.removeEventListener("focus", o.current), o.current = null;
24902
24930
  }
24903
- $e(() => i, []);
24931
+ Ve(() => i, []);
24904
24932
  function a() {
24905
24933
  r.current !== null && clearTimeout(r.current), r.current = setTimeout(l, 0);
24906
24934
  }
@@ -25408,31 +25436,31 @@ const zS = /* @__PURE__ */ y.forwardRef(function(t, n) {
25408
25436
  let Q = 0, re = 0;
25409
25437
  !ue && !se && (Q = L?.offsetWidth || 0, re = $?.offsetHeight || 0);
25410
25438
  const be = h.width === 0 && h.height === 0, Ce = be ? Q : 0, Oe = be ? re : 0, Te = bo($, "padding", "x"), Ie = bo(L, "padding", "y"), Re = bo(G, "margin", "x"), Ye = bo(H, "margin", "y"), Ue = ce - Te - Re, Le = xe - Ie - Ye, Me = $ ? Math.min($.offsetWidth - Ce, Ue) : Ue, Fe = L ? Math.min(L.offsetHeight - Oe, Le) : Le, We = Math.max(Pp, Me * pe), tt = Math.max(Pp, Fe * le);
25411
- if (g((Ve) => _l(Ve, {
25439
+ if (g(($e) => _l($e, {
25412
25440
  width: We,
25413
25441
  height: tt
25414
25442
  })), L && H) {
25415
- const Ve = L.offsetHeight - tt - Ie - Ye, bt = dy(H, "--scroll-area-thumb-height", Z, ie, K, tt, Ve);
25443
+ const $e = L.offsetHeight - tt - Ie - Ye, bt = dy(H, "--scroll-area-thumb-height", Z, ie, K, tt, $e);
25416
25444
  H.style.transform = `translate3d(0,${bt}px,0)`;
25417
25445
  }
25418
25446
  if ($ && G) {
25419
- const Ve = $.offsetWidth - We - Te - Re, bt = M === "rtl" ? -ne : ne, Xe = dy(G, "--scroll-area-thumb-width", bt, ae, X, We, Ve);
25447
+ const $e = $.offsetWidth - We - Te - Re, bt = M === "rtl" ? -ne : ne, Xe = dy(G, "--scroll-area-thumb-width", bt, ae, X, We, $e);
25420
25448
  G.style.transform = `translate3d(${M === "rtl" ? -Xe : Xe}px,0,0)`;
25421
25449
  }
25422
25450
  const Ke = [he, we, oe, ee];
25423
- LS.forEach((Ve, bt) => {
25424
- O.style.setProperty(Ve, `${Ke[bt]}px`);
25425
- }), Y && m((Ve) => _l(Ve, {
25451
+ LS.forEach(($e, bt) => {
25452
+ O.style.setProperty($e, `${Ke[bt]}px`);
25453
+ }), Y && m(($e) => _l($e, {
25426
25454
  width: Q,
25427
25455
  height: re
25428
- })), x((Ve) => _l(Ve, J));
25456
+ })), x(($e) => _l($e, J));
25429
25457
  const et = {
25430
25458
  xStart: !ue && he > k.xStart,
25431
25459
  xEnd: !ue && we > k.xEnd,
25432
25460
  yStart: !se && oe > k.yStart,
25433
25461
  yEnd: !se && ee > k.yEnd
25434
25462
  };
25435
- R((Ve) => _l(Ve, et));
25463
+ R(($e) => _l($e, et));
25436
25464
  });
25437
25465
  ve(() => {
25438
25466
  jz();
@@ -26839,13 +26867,13 @@ const c5 = "data-parent", tk = /* @__PURE__ */ y.forwardRef(function(t, n) {
26839
26867
  if (Me.key !== "Enter" || (Me.preventBaseUIHandler(), Me.defaultPrevented))
26840
26868
  return;
26841
26869
  const Fe = re.current?.form ?? null, We = Me.currentTarget, tt = Me.nativeEvent, Ke = Me.preventDefault, et = tt.preventDefault;
26842
- let Ve = !1;
26870
+ let $e = !1;
26843
26871
  Me.preventDefault = () => {
26844
- Ve = !0, Ke.call(Me);
26872
+ $e = !0, Ke.call(Me);
26845
26873
  }, tt.preventDefault = () => {
26846
- Ve = !0, et.call(tt);
26874
+ $e = !0, et.call(tt);
26847
26875
  }, et.call(tt), ht(We).queueMicrotask(() => {
26848
- Me.preventDefault = Ke, tt.preventDefault = et, Ve || i5(Fe)?.click();
26876
+ Me.preventDefault = Ke, tt.preventDefault = et, $e || i5(Fe)?.click();
26849
26877
  });
26850
26878
  },
26851
26879
  onClick(Me) {
@@ -29577,8 +29605,8 @@ const Dk = /* @__PURE__ */ y.forwardRef(function(t, n) {
29577
29605
  const tt = ue ? "bottom" : "insetInlineStart", Ke = ue ? "left" : "top";
29578
29606
  let et;
29579
29607
  se ? R === Te ? et = 2 : Fe === Te && (et = 1) : R === Te && (et = 1);
29580
- let Ve;
29581
- !D && !Number.isFinite(Ye) ? Ve = Kn : Ve = {
29608
+ let $e;
29609
+ !D && !Number.isFinite(Ye) ? $e = Kn : $e = {
29582
29610
  position: "absolute",
29583
29611
  [tt]: D ? "var(--position)" : `${Ye}%`,
29584
29612
  [Ke]: "50%",
@@ -29698,7 +29726,7 @@ const Dk = /* @__PURE__ */ y.forwardRef(function(t, n) {
29698
29726
  const Rt = Ik(_e.currentTarget, ue);
29699
29727
  G.current = (ue ? _e.clientY : _e.clientX) - Rt;
29700
29728
  },
29701
- style: Ve,
29729
+ style: $e,
29702
29730
  suppressHydrationWarning: K || void 0
29703
29731
  }, E],
29704
29732
  stateAttributesMapping: vi
@@ -29980,7 +30008,7 @@ function Vk(e, t, { isValid: n, enabled: r = !0 }) {
29980
30008
  const c = Rg(e, n);
29981
30009
  return c === void 0 ? o() : c;
29982
30010
  }), a = ye(!1);
29983
- $e(() => {
30011
+ Ve(() => {
29984
30012
  if (!(!e || !r)) {
29985
30013
  if (!a.current) {
29986
30014
  a.current = !0;
@@ -30009,7 +30037,7 @@ function hd({
30009
30037
  const a = W5(t);
30010
30038
  return n.includes(a ?? "") ? a : r();
30011
30039
  });
30012
- $e(() => {
30040
+ Ve(() => {
30013
30041
  Y5(e, o), K5(t, o);
30014
30042
  }, [e, t, o]);
30015
30043
  const i = Ne(() => {
@@ -30224,7 +30252,7 @@ function iK({
30224
30252
  !1,
30225
30253
  { isValid: iB }
30226
30254
  ), x = ye(null);
30227
- $e(() => {
30255
+ Ve(() => {
30228
30256
  c !== void 0 && x.current?.scrollTo({ top: 0, behavior: "instant" });
30229
30257
  }, [c]);
30230
30258
  const [w, v] = fe(!1), C = /* @__PURE__ */ d(
@@ -31795,9 +31823,9 @@ function pK({
31795
31823
  })).filter((m) => m.score >= 0);
31796
31824
  return h.sort((m, g) => g.score - m.score), h.map((m) => m.item);
31797
31825
  }, [e, s]);
31798
- $e(() => {
31826
+ Ve(() => {
31799
31827
  t && (i(""), l(0));
31800
- }, [t]), $e(() => l(0), [s]);
31828
+ }, [t]), Ve(() => l(0), [s]);
31801
31829
  function u(h) {
31802
31830
  h.key === "ArrowDown" ? (h.preventDefault(), l((m) => (m + 1) % Math.max(c.length, 1))) : h.key === "ArrowUp" ? (h.preventDefault(), l((m) => (m - 1 + c.length) % Math.max(c.length, 1))) : h.key === "Enter" && c[a] && (h.preventDefault(), c[a].onSelect(), n(!1));
31803
31831
  }
@@ -31911,7 +31939,7 @@ function pK({
31911
31939
  }
31912
31940
  function hK(e = "k") {
31913
31941
  const [t, n] = fe(!1);
31914
- return $e(() => {
31942
+ return Ve(() => {
31915
31943
  function r(o) {
31916
31944
  o.key.toLowerCase() === e && (o.metaKey || o.ctrlKey) && (o.preventDefault(), n((s) => !s));
31917
31945
  }
@@ -33194,7 +33222,7 @@ const mR = /* @__PURE__ */ y.forwardRef(function(t, n) {
33194
33222
  readOnly: v,
33195
33223
  required: C,
33196
33224
  value: ee
33197
- }), [Y, z, xe, Oe, f, v, C, ee]), Ve = y.useMemo(() => ({
33225
+ }), [Y, z, xe, Oe, f, v, C, ee]), $e = y.useMemo(() => ({
33198
33226
  autoComplete: i,
33199
33227
  activeIndex: Ie,
33200
33228
  disabled: Y,
@@ -33234,7 +33262,7 @@ const mR = /* @__PURE__ */ y.forwardRef(function(t, n) {
33234
33262
  re(Xe.size);
33235
33263
  },
33236
33264
  children: /* @__PURE__ */ P(Fg.Provider, {
33237
- value: Ve,
33265
+ value: $e,
33238
33266
  children: [bt, oe && /* @__PURE__ */ d("input", {
33239
33267
  ...F.getValidationProps(Y, {
33240
33268
  onFocus() {
@@ -33788,12 +33816,12 @@ function F3(e) {
33788
33816
  }), [ue, pe] = y.useState(!1), [le, ae] = y.useState(null), ie = y.useRef([]), he = y.useRef([]), we = y.useRef(null), oe = y.useRef(null), ee = y.useRef(null), ce = y.useRef(null), xe = y.useRef(null), Q = y.useRef(!0), re = y.useRef(!1), be = y.useRef(null), Ce = y.useRef(null), Oe = y.useRef(null), Te = y.useRef(Nf), Ie = y.useRef(null), Re = y.useRef([]), Ye = y.useRef(null), Ue = W || m, Le = X ?? f, Me = u === "multiple", Fe = u === "single", We = a !== void 0 || i !== void 0, tt = v !== void 0, Ke = C !== void 0;
33789
33817
  let et;
33790
33818
  R === "always" ? et = "always" : et = R ? "input-change" : !1;
33791
- const [Ve, bt] = fn({
33819
+ const [$e, bt] = fn({
33792
33820
  controlled: o,
33793
33821
  default: Me ? r ?? Sn : r,
33794
33822
  name: "Combobox",
33795
33823
  state: "selectedValue"
33796
- }), Xe = y.useMemo(() => E === null ? () => !0 : E !== void 0 ? E : A3(se, I), [E, se, I]), it = $t(() => We ? i ?? "" : Fe ? Xn(Ve, I) : "").current, [ut, Bt] = fn({
33824
+ }), Xe = y.useMemo(() => E === null ? () => !0 : E !== void 0 ? E : A3(se, I), [E, se, I]), it = $t(() => We ? i ?? "" : Fe ? Xn($e, I) : "").current, [ut, Bt] = fn({
33797
33825
  controlled: a,
33798
33826
  default: it,
33799
33827
  name: "Combobox",
@@ -33803,7 +33831,7 @@ function F3(e) {
33803
33831
  default: c,
33804
33832
  name: "Combobox",
33805
33833
  state: "open"
33806
- }), Nt = Ug(v), qe = le ?? String(ut).trim(), xt = Fe ? Xn(Ve, I) : "", Ht = Fe && !ue && qe !== "" && xt.length === qe.length && se.contains(xt, qe), en = Ht ? "" : qe, vn = tt && Ke && Ht, Kt = y.useMemo(() => v ? Nt ? v.flatMap((Ae) => Ae.items) : v : Sn, [v, Nt]), ln = y.useMemo(() => {
33834
+ }), Nt = Ug(v), qe = le ?? String(ut).trim(), xt = Fe ? Xn($e, I) : "", Ht = Fe && !ue && qe !== "" && xt.length === qe.length && se.contains(xt, qe), en = Ht ? "" : qe, vn = tt && Ke && Ht, Kt = y.useMemo(() => v ? Nt ? v.flatMap((Ae) => Ae.items) : v : Sn, [v, Nt]), ln = y.useMemo(() => {
33807
33835
  if (C && !vn)
33808
33836
  return C;
33809
33837
  if (!v)
@@ -33850,10 +33878,10 @@ function F3(e) {
33850
33878
  return Ae;
33851
33879
  }, [C, vn, v, Nt, en, F, Xe, I, Kt]), tn = y.useMemo(() => Nt ? ln.flatMap((ze) => ze.items) : ln, [ln, Nt]), nt = $t(() => {
33852
33880
  let Ae = null;
33853
- return _ && _e && tt && u !== "none" && (Ae = Rf(tn, Ve, A, Me)), new D1({
33881
+ return _ && _e && tt && u !== "none" && (Ae = Rf(tn, $e, A, Me)), new D1({
33854
33882
  id: J,
33855
33883
  labelId: void 0,
33856
- selectedValue: Ve,
33884
+ selectedValue: $e,
33857
33885
  open: _e,
33858
33886
  items: v,
33859
33887
  selectionMode: u,
@@ -33917,7 +33945,7 @@ function F3(e) {
33917
33945
  forceMount: mt,
33918
33946
  requestSubmit: mt
33919
33947
  });
33920
- }).current, cr = u === "none" ? ut : Ve, PM = y.useMemo(() => u === "none" ? cr : Array.isArray(Ve) ? Ve.map((Ae) => dr(Ae, T)) : dr(Ve, T), [cr, T, u, Ve]), OM = ge(p), Yb = ge(n), Xb = me(nt, ke.activeIndex), AM = me(nt, ke.selectedIndex), il = me(nt, ke.positionerElement), Zb = me(nt, ke.listElement), ki = me(nt, ke.triggerElement), al = me(nt, ke.inputElement), DM = me(nt, ke.inputGroupElement), On = me(nt, ke.inline), vr = me(nt, ke.inputInsidePopup), _M = me(nt, ke.inputOwnsFormValue), FM = Tt(ki), {
33948
+ }).current, cr = u === "none" ? ut : $e, PM = y.useMemo(() => u === "none" ? cr : Array.isArray($e) ? $e.map((Ae) => dr(Ae, T)) : dr($e, T), [cr, T, u, $e]), OM = ge(p), Yb = ge(n), Xb = me(nt, ke.activeIndex), AM = me(nt, ke.selectedIndex), il = me(nt, ke.positionerElement), Zb = me(nt, ke.listElement), ki = me(nt, ke.triggerElement), al = me(nt, ke.inputElement), DM = me(nt, ke.inputGroupElement), On = me(nt, ke.inline), vr = me(nt, ke.inputInsidePopup), _M = me(nt, ke.inputOwnsFormValue), FM = Tt(ki), {
33921
33949
  mounted: Qb,
33922
33950
  setMounted: VM,
33923
33951
  transitionStatus: $d
@@ -33982,7 +34010,7 @@ function F3(e) {
33982
34010
  if (_e !== Ae && (ze.reason === ms && tt && tn.length === 0 && !xe.current && ze.allowPropagation(), e.onOpenChange?.(Ae, ze), !ze.isCanceled && (Ae && vr && !On && le !== null && (pe(!1), ae(null), ut !== "" && ze.reason !== nr && wr("", Se(_n, ze.event))), !Ae && ue && (Fe ? (On || ae(qe), qe === "" && pe(!1)) : Me && (On || ae(qe), vr && yr({
33983
34011
  activeIndex: null
33984
34012
  }), (!vr || On) && wr("", Se(_n, ze.event)))), Rt(Ae), !Ae && vr && (ze.reason === Jr || ze.reason === Ia) && (j(!0), Z(!1), ne === "onBlur")))) {
33985
- const Pt = u === "none" ? ut : Ve;
34013
+ const Pt = u === "none" ? ut : $e;
33986
34014
  te.commit(Pt);
33987
34015
  }
33988
34016
  }), ll = ge((Ae, ze) => {
@@ -33998,7 +34026,7 @@ function F3(e) {
33998
34026
  return;
33999
34027
  }
34000
34028
  if (Me) {
34001
- const zt = Array.isArray(Ve) ? Ve : [], ur = O3(zt, ze, A) ? vR(zt, ze, A) : [...zt, ze];
34029
+ const zt = Array.isArray($e) ? $e : [], ur = O3(zt, ze, A) ? vR(zt, ze, A) : [...zt, ze];
34002
34030
  if (ll(ur, nn), nn.isCanceled || !(oe.current ? oe.current.value.trim() !== "" : !1))
34003
34031
  return;
34004
34032
  nt.state.inputInsidePopup ? wr("", Se(_n, nn.event)) : Ri(!1, nn);
@@ -34020,7 +34048,7 @@ function F3(e) {
34020
34048
  if (nt.state.inputInsidePopup)
34021
34049
  oe.current && oe.current.value !== "" && wr("", Se(_n));
34022
34050
  else {
34023
- const Ae = Xn(Ve, I);
34051
+ const Ae = Xn($e, I);
34024
34052
  oe.current && oe.current.value !== Ae && wr(Ae, Se(Ae === "" ? _n : It));
34025
34053
  }
34026
34054
  }), BM = y.useMemo(() => On && il ? {
@@ -34040,9 +34068,9 @@ function F3(e) {
34040
34068
  return;
34041
34069
  const ze = tt ? Kt : Re.current;
34042
34070
  yr({
34043
- selectedIndex: Rf(ze, Ve, A, Me)
34071
+ selectedIndex: Rf(ze, $e, A, Me)
34044
34072
  });
34045
- }, [_e, Ve, u, Me, tt, Kt, A, yr]), ve(() => {
34073
+ }, [_e, $e, u, Me, tt, Kt, A, yr]), ve(() => {
34046
34074
  v && (Re.current = tn, ie.current.length = tn.length);
34047
34075
  }, [v, tn]), ve(() => {
34048
34076
  const Ae = Ie.current;
@@ -34098,8 +34126,8 @@ function F3(e) {
34098
34126
  K(String(ut) !== "");
34099
34127
  return;
34100
34128
  }
34101
- K(Me ? Array.isArray(Ve) && Ve.length > 0 : Ve != null);
34102
- }, [K, u, ut, Ve, Me]), y.useEffect(() => {
34129
+ K(Me ? Array.isArray($e) && $e.length > 0 : $e != null);
34130
+ }, [K, u, ut, $e, Me]), y.useEffect(() => {
34103
34131
  tt && et && tn.length === 0 && yr({
34104
34132
  activeIndex: null
34105
34133
  });
@@ -34112,11 +34140,11 @@ function F3(e) {
34112
34140
  !_e || qe === "" || qe === String(it) || pe(!0);
34113
34141
  });
34114
34142
  function tx() {
34115
- const Ae = Xn(Ve, I);
34143
+ const Ae = Xn($e, I);
34116
34144
  ut !== Ae && wr(Ae, Se(It));
34117
34145
  }
34118
- tr(Ve, () => {
34119
- u !== "none" && (H(Le), G(HM(Ve)), te.change(Ve), Fe && !We && !vr && tx());
34146
+ tr($e, () => {
34147
+ u !== "none" && (H(Le), G(HM($e)), te.change($e), Fe && !We && !vr && tx());
34120
34148
  }), tr(ut, () => {
34121
34149
  u === "none" && (H(Le), G(ut !== Y.initialValue), te.change(ut));
34122
34150
  }), tr(v, () => {
@@ -34220,7 +34248,7 @@ function F3(e) {
34220
34248
  }), ve(() => {
34221
34249
  nt.update({
34222
34250
  id: J,
34223
- selectedValue: Ve,
34251
+ selectedValue: $e,
34224
34252
  open: _e,
34225
34253
  mounted: Qb,
34226
34254
  transitionStatus: $d,
@@ -34249,13 +34277,13 @@ function F3(e) {
34249
34277
  hasInputValue: We,
34250
34278
  inputOwnsFormValue: u === "none" && (_ || !nt.state.inputInsidePopup)
34251
34279
  });
34252
- }, [nt, J, Ve, _e, Qb, $d, v, Hd, Ud, Bd, jd, Jb, Ld, u, Le, Ue, g, b, w, D, S, I, z, A, $, We, _, et, h]);
34280
+ }, [nt, J, $e, _e, Qb, $d, v, Hd, Ud, Bd, jd, Jb, Ld, u, Le, Ue, g, b, w, D, S, I, z, A, $, We, _, et, h]);
34253
34281
  const UM = gn(x, te.inputRef), jM = y.useMemo(() => ({
34254
34282
  query: qe,
34255
34283
  hasItems: tt,
34256
34284
  filteredItems: ln,
34257
34285
  flatFilteredItems: tn
34258
- }), [qe, tt, ln, tn]), GM = y.useMemo(() => Array.isArray(cr) ? "" : dr(cr, T), [cr, T]), WM = Me && Array.isArray(Ve) && Ve.length > 0, Gd = Me || u === "none" && _M ? void 0 : Le, KM = y.useMemo(() => !Me || !Array.isArray(Ve) || !Le ? null : Ve.map((Ae) => {
34286
+ }), [qe, tt, ln, tn]), GM = y.useMemo(() => Array.isArray(cr) ? "" : dr(cr, T), [cr, T]), WM = Me && Array.isArray($e) && $e.length > 0, Gd = Me || u === "none" && _M ? void 0 : Le, KM = y.useMemo(() => !Me || !Array.isArray($e) || !Le ? null : $e.map((Ae) => {
34259
34287
  const ze = dr(Ae, T);
34260
34288
  return /* @__PURE__ */ d("input", {
34261
34289
  type: "hidden",
@@ -34264,7 +34292,7 @@ function F3(e) {
34264
34292
  value: ze,
34265
34293
  disabled: Ue
34266
34294
  }, ze);
34267
- }), [Me, Ve, h, Le, T, Ue]), qM = /* @__PURE__ */ P(y.Fragment, {
34295
+ }), [Me, $e, h, Le, T, Ue]), qM = /* @__PURE__ */ P(y.Fragment, {
34268
34296
  children: [e.children, /* @__PURE__ */ d("input", {
34269
34297
  ...te.getValidationProps(Ue, {
34270
34298
  // Move focus when the hidden input is focused.
@@ -35842,7 +35870,7 @@ function t4(e) {
35842
35870
  }), Ke = di(tt, {
35843
35871
  enabled: !f && !O,
35844
35872
  event: "mousedown"
35845
- }), et = fi(tt), Ve = im(tt, {
35873
+ }), et = fi(tt), $e = im(tt, {
35846
35874
  enabled: !f && !O,
35847
35875
  listRef: K,
35848
35876
  activeIndex: ee,
@@ -35869,7 +35897,7 @@ function t4(e) {
35869
35897
  onTyping(qe) {
35870
35898
  q.current = qe;
35871
35899
  }
35872
- }), Xe = y.useMemo(() => dn(bt.reference, Ve.reference, et.reference, Ke.reference, we), [Ke.reference, bt.reference, Ve.reference, et.reference, we]), it = y.useMemo(() => dn(pi, bt.floating, Ve.floating, et.floating), [bt.floating, Ve.floating, et.floating]), ut = Ve.item ?? yt;
35900
+ }), Xe = y.useMemo(() => dn(bt.reference, $e.reference, et.reference, Ke.reference, we), [Ke.reference, bt.reference, $e.reference, et.reference, we]), it = y.useMemo(() => dn(pi, bt.floating, $e.floating, et.floating), [bt.floating, $e.floating, et.floating]), ut = $e.item ?? yt;
35873
35901
  bR(() => {
35874
35902
  oe.update({
35875
35903
  popupProps: it,
@@ -36390,8 +36418,8 @@ const i4 = {
36390
36418
  let We = Math.min(Ie, Fe);
36391
36419
  const tt = Ie - xe - Q, Ke = Fe - We, et = Re - Oe;
36392
36420
  L.style.left = `${Vt(Le, Ce, et - he.width)}px`, L.style.height = `${We}px`, L.style.maxHeight = "none", L.style.marginTop = `${xe}px`, L.style.marginBottom = `${Q}px`, ne.style.height = "100%";
36393
- const Ve = zl(oe), bt = Ke >= Ve - Ur;
36394
- bt && (We = Math.min(Ie, he.height) - (Ke - Ve));
36421
+ const $e = zl(oe), bt = Ke >= $e - Ur;
36422
+ bt && (We = Math.min(Ie, he.height) - (Ke - $e));
36395
36423
  const Xe = ie.top < Te || ie.bottom > Ie - Te || Math.ceil(We) + Ur < Math.min(ee, re), it = (se.visualViewport?.scale ?? 1) !== 1 && ar;
36396
36424
  if (Xe || it) {
36397
36425
  qc(L, Y.current), N(!1);
@@ -37782,7 +37810,7 @@ function Wy(e) {
37782
37810
  }
37783
37811
  function w4({ className: e, children: t, variant: n }) {
37784
37812
  const r = yd({ variant: n }), o = ye(null);
37785
- return $e(() => {
37813
+ return Ve(() => {
37786
37814
  const s = o.current;
37787
37815
  if (!s) return;
37788
37816
  Wy(s);
@@ -38766,7 +38794,7 @@ function OK({
38766
38794
  v(
38767
38795
  Object.fromEntries(O.map((X) => [X.id, X.defaultSize ?? K]))
38768
38796
  );
38769
- }, [f, S, C, v]), $e(() => {
38797
+ }, [f, S, C, v]), Ve(() => {
38770
38798
  Object.keys(w).length > 0 && s?.(w);
38771
38799
  }, [w, s]);
38772
38800
  const A = Ne(
@@ -42154,19 +42182,19 @@ function cU(e) {
42154
42182
  const t = ye(null);
42155
42183
  t.current ??= new eU(e);
42156
42184
  const n = t.current;
42157
- return n.setCallbacks(e), $e(() => rU(n), [n]), n;
42185
+ return n.setCallbacks(e), Ve(() => rU(n), [n]), n;
42158
42186
  }
42159
42187
  function Rd(e) {
42160
42188
  return Vr(e.subscribe, e.getState, e.getState);
42161
42189
  }
42162
42190
  function uU(e, t) {
42163
42191
  const { id: n, container: r, index: o, axis: s = "y", disabled: i = !1, activation: a } = t, [l, c] = fe(null), [u, p] = fe(null);
42164
- $e(() => {
42192
+ Ve(() => {
42165
42193
  if (l)
42166
42194
  return e.registerItem({ id: n, container: r, index: o, element: l });
42167
42195
  }, [e, l, n, r, o]);
42168
42196
  const f = `${a?.distance ?? ""}/${a?.delay ?? ""}/${a?.tolerance ?? ""}`, h = ye(a);
42169
- h.current = a, $e(() => {
42197
+ h.current = a, Ve(() => {
42170
42198
  if (!u || i) return;
42171
42199
  const g = nU(e, u, {
42172
42200
  id: n,
@@ -42185,7 +42213,7 @@ function uU(e, t) {
42185
42213
  }
42186
42214
  function dU(e, t) {
42187
42215
  const { id: n, axis: r = "y" } = t, [o, s] = fe(null);
42188
- $e(() => {
42216
+ Ve(() => {
42189
42217
  if (o)
42190
42218
  return e.registerContainer({ id: n, element: o, axis: r });
42191
42219
  }, [e, o, n, r]);
@@ -42221,7 +42249,7 @@ function pU(e, t = {}) {
42221
42249
  const [n, r] = fe(""), o = ye(t);
42222
42250
  o.current = t;
42223
42251
  const s = ye(null), i = ye(null), a = ye(null), l = ye(0);
42224
- return $e(() => {
42252
+ return Ve(() => {
42225
42253
  function c() {
42226
42254
  i.current !== null && (window.clearTimeout(i.current), i.current = null, a.current = null);
42227
42255
  }
@@ -42646,7 +42674,7 @@ function SU(e) {
42646
42674
  r.current = null, o();
42647
42675
  }, 0));
42648
42676
  }, [o]);
42649
- return $e(
42677
+ return Ve(
42650
42678
  () => () => {
42651
42679
  r.current !== null && (clearTimeout(r.current), r.current = null);
42652
42680
  },
@@ -42680,7 +42708,7 @@ function Sb({
42680
42708
  () => ({ threshold: u, maxSpeed: p, reducedMaxSpeed: f }),
42681
42709
  [u, p, f]
42682
42710
  );
42683
- $e(() => aU(i, h), [i, h]);
42711
+ Ve(() => aU(i, h), [i, h]);
42684
42712
  const m = ye({
42685
42713
  item: /* @__PURE__ */ new Map(),
42686
42714
  container: /* @__PURE__ */ new Map()
@@ -42716,7 +42744,7 @@ function kb({
42716
42744
  children: o
42717
42745
  }) {
42718
42746
  const { session: s, registerLabel: i } = Nd("DragDropContainer"), { setContainerRef: a, isOver: l } = dU(s, { id: e, axis: n }), c = Rd(s), u = Ss({ axis: n });
42719
- $e(
42747
+ Ve(
42720
42748
  () => i("container", e, t),
42721
42749
  [i, e, t]
42722
42750
  );
@@ -42748,7 +42776,7 @@ function Rb({
42748
42776
  index: t,
42749
42777
  axis: u
42750
42778
  }), m = Rd(s);
42751
- $e(() => a("item", e, n), [a, e, n]), $e(() => l.item(e, c, t), [l, e, c, t]);
42779
+ Ve(() => a("item", e, n), [a, e, n]), Ve(() => l.item(e, c, t), [l, e, c, t]);
42752
42780
  const g = m.phase === "dragging" && m.id === e, b = Ss({ axis: u, moving: p !== null }), x = m.from && m.from.container === c && m.from.index < t ? t - 1 : t, w = !g && p?.markerAt === x, v = !g && p !== null && p.markerAt === p.restCount && x === p.restCount - 1, C = p && /* @__PURE__ */ d(iI, { shift: p, at: w ? x : p.restCount - 1 });
42753
42781
  return (
42754
42782
  /* A FRAGMENT, so the marker is a DIRECT CHILD of the container. Wrapping the
@@ -42822,14 +42850,14 @@ function kU({
42822
42850
  const RU = 'a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])';
42823
42851
  function oI({ label: e, className: t, children: n }) {
42824
42852
  const { instructionsId: r, census: o } = Nd("DragDropSurface"), { axis: s } = Id("DragDropSurface"), { id: i, setHandleRef: a, label: l } = eI("DragDropSurface"), c = JN();
42825
- $e(() => c ? void 0 : o.source(i), [o, i, c]);
42853
+ Ve(() => c ? void 0 : o.source(i), [o, i, c]);
42826
42854
  const u = Ss({ axis: s }), [p, f] = fe(null), [h, m] = fe(!1), g = Ne(
42827
42855
  (b) => {
42828
42856
  f(b), a(b);
42829
42857
  },
42830
42858
  [a]
42831
42859
  );
42832
- return $e(() => {
42860
+ return Ve(() => {
42833
42861
  if (!p || c) return;
42834
42862
  const b = p.querySelector(RU);
42835
42863
  if (m(b === null), !b) return;
@@ -42860,7 +42888,7 @@ function oI({ label: e, className: t, children: n }) {
42860
42888
  }
42861
42889
  function sI({ label: e, className: t, children: n }) {
42862
42890
  const { instructionsId: r, census: o } = Nd("DragDropHandle"), { axis: s } = Id("DragDropHandle"), { id: i, setHandleRef: a, label: l } = eI("DragDropHandle"), c = JN();
42863
- $e(() => c ? void 0 : o.source(i), [o, i, c]);
42891
+ Ve(() => c ? void 0 : o.source(i), [o, i, c]);
42864
42892
  const u = Ss({ axis: s }), p = n ?? /* @__PURE__ */ d(de, { name: "grip-vertical", size: "sm" });
42865
42893
  return c ? /* @__PURE__ */ d("span", { "aria-hidden": "true", className: U(u.handle(), t), children: p }) : /* @__PURE__ */ d(
42866
42894
  "span",
@@ -43701,7 +43729,7 @@ function jK({ id: e, index: t, label: n, className: r, children: o }) {
43701
43729
  const { columnId: s } = $U("BoardCard"), i = ye(!1), a = Ne(() => (i.current = !0, () => {
43702
43730
  i.current = !1;
43703
43731
  }), []);
43704
- $e(() => {
43732
+ Ve(() => {
43705
43733
  i.current || console.warn(
43706
43734
  `[danxbot] board: card "${String(e)}" rendered without placing the move control it was handed. Every drag outcome must stay reachable by pointer alone without dragging (WCAG 2.2 SC 2.5.7) — a keyboard path does not satisfy it. Render the node \`BoardCard\` passes to its children function.`
43707
43735
  );
@@ -43714,7 +43742,7 @@ function jK({ id: e, index: t, label: n, className: r, children: o }) {
43714
43742
  }
43715
43743
  function HU({ columnId: e }) {
43716
43744
  const t = VU("BoardCardHandle"), n = LU("BoardCardHandle"), r = AU(), [o, s] = fe(!1), i = Nb(), { registerHandle: a } = n;
43717
- $e(() => a(), [a]);
43745
+ Ve(() => a(), [a]);
43718
43746
  const c = t.columns.find((g) => g.id === e)?.count ?? 0, u = t.columns.filter((g) => g.id !== e);
43719
43747
  function p(g) {
43720
43748
  s(!1), t.requestMove({
@@ -44857,7 +44885,7 @@ function sj({
44857
44885
  return Gn(() => {
44858
44886
  const h = i.current;
44859
44887
  h && (h.scrollTop = h.scrollHeight);
44860
- }, []), $e(() => {
44888
+ }, []), Ve(() => {
44861
44889
  const h = a.current;
44862
44890
  if (!h || typeof ResizeObserver > "u") return;
44863
44891
  const m = new ResizeObserver(() => {
@@ -44929,7 +44957,7 @@ function ij({
44929
44957
  className: l
44930
44958
  }) {
44931
44959
  const [c, u] = fe(!1), [p, f] = fe(!1), h = e.filter((b) => !b.secondary), m = e.filter((b) => b.secondary), g = e.find((b) => b.id === t);
44932
- return $e(() => {
44960
+ return Ve(() => {
44933
44961
  if (!c || !o) return;
44934
44962
  const b = (x) => {
44935
44963
  if (x.metaKey || x.ctrlKey || x.altKey) return;
@@ -44937,7 +44965,7 @@ function ij({
44937
44965
  !Number.isInteger(w) || w < 0 || !v || v.disabled || (x.preventDefault(), n(v.id), u(!1));
44938
44966
  };
44939
44967
  return document.addEventListener("keydown", b), () => document.removeEventListener("keydown", b);
44940
- }, [c, o, h, n]), $e(() => {
44968
+ }, [c, o, h, n]), Ve(() => {
44941
44969
  c || f(!1);
44942
44970
  }, [c]), /* @__PURE__ */ P(
44943
44971
  Ka,
@@ -45711,7 +45739,7 @@ function nq({
45711
45739
  Rj(b, e, o, s),
45712
45740
  { month: e, weekStartsOn: r, onMonthChange: l }
45713
45741
  ), v = ye(/* @__PURE__ */ new Map()), C = ye(!1);
45714
- $e(() => {
45742
+ Ve(() => {
45715
45743
  C.current && v.current.get(Vn(w.focusedDay))?.focus();
45716
45744
  }, [w.focusedDay]);
45717
45745
  const E = De(
@@ -45978,7 +46006,7 @@ function Pj(e, t = {}) {
45978
46006
  }
45979
46007
  function Oj(e = {}) {
45980
46008
  const { resolutionMs: t = 6e4, enabled: n = !0, fixed: r } = e, [o, s] = fe(() => r ?? Date.now());
45981
- return $e(() => {
46009
+ return Ve(() => {
45982
46010
  if (r !== void 0) {
45983
46011
  s(r);
45984
46012
  return;
@@ -46065,11 +46093,11 @@ function Dj(e) {
46065
46093
  const x = ye({ columns: [], origin: null, anchor: null, last: null, spoken: null, point: null }), w = Ne(() => {
46066
46094
  x.current.columns = b.current.measure();
46067
46095
  }, []);
46068
- $e(() => {
46096
+ Ve(() => {
46069
46097
  if (!u && !f) return;
46070
46098
  const A = () => w();
46071
46099
  return window.addEventListener("scroll", A, { capture: !0, passive: !0 }), () => window.removeEventListener("scroll", A, { capture: !0 });
46072
- }, [u, f, w]), $e(() => {
46100
+ }, [u, f, w]), Ve(() => {
46073
46101
  if (!u && !f) return;
46074
46102
  const A = (D) => {
46075
46103
  D.key === "Escape" && (D.preventDefault(), x.current.origin = null, x.current.anchor = null, x.current.last = null, p(null), h(null), g(!1), b.current.onAnnounce?.("Move cancelled"));
@@ -46508,7 +46536,7 @@ function rq({
46508
46536
  const $ = e[0], H = un(t, $) + a * 36e5;
46509
46537
  return Math.max(0, Math.min(1, Ca(t, $, H))) * T;
46510
46538
  }, [_, t, a, T]);
46511
- $e(() => {
46539
+ Ve(() => {
46512
46540
  const $ = S.current;
46513
46541
  !$ || V === null || ($.scrollTop = V);
46514
46542
  }, [V]);
@@ -46543,7 +46571,7 @@ function rq({
46543
46571
  },
46544
46572
  locale: x
46545
46573
  });
46546
- $e(() => {
46574
+ Ve(() => {
46547
46575
  if (!(!F.draft && !F.creating || !S.current))
46548
46576
  return Eb({ getPoint: F.getPoint, onScrolled: F.onScrolled });
46549
46577
  }, [F.draft, F.creating, F.getPoint, F.onScrolled]);
@@ -47281,7 +47309,7 @@ function rG({
47281
47309
  className: l
47282
47310
  }) {
47283
47311
  const [c, u] = fe(o), [p, f] = fe(s), [h, m] = fe(zi);
47284
- $e(() => {
47312
+ Ve(() => {
47285
47313
  t && (u(o), f(s), m(zi));
47286
47314
  }, [t]);
47287
47315
  const g = c.trim().length > 0 && !i;
@@ -48203,7 +48231,7 @@ function vq({
48203
48231
  className: i
48204
48232
  }) {
48205
48233
  const [a, l] = fe([]), [c, u] = fe(""), [p, f] = fe(n[0]?.id ?? ""), [h, m] = fe(void 0);
48206
- $e(() => {
48234
+ Ve(() => {
48207
48235
  e && (l([]), u(""), m(void 0), f(n[0]?.id ?? ""));
48208
48236
  }, [e]);
48209
48237
  function g() {
@@ -51796,7 +51824,7 @@ function vW(e) {
51796
51824
  ), w = Ne(() => {
51797
51825
  m.current.drag = null, m.current.point = null, c(null);
51798
51826
  }, []);
51799
- $e(() => {
51827
+ Ve(() => {
51800
51828
  if (!l) return;
51801
51829
  const N = (M) => {
51802
51830
  if (M.key !== "Escape") return;
@@ -51807,13 +51835,13 @@ function vW(e) {
51807
51835
  }), w());
51808
51836
  };
51809
51837
  return window.addEventListener("keydown", N), () => window.removeEventListener("keydown", N);
51810
- }, [l, w]), $e(() => {
51838
+ }, [l, w]), Ve(() => {
51811
51839
  if (!l && !u) return;
51812
51840
  const N = () => g();
51813
51841
  return window.addEventListener("scroll", N, { capture: !0, passive: !0 }), window.addEventListener("resize", N), () => {
51814
51842
  window.removeEventListener("scroll", N, { capture: !0 }), window.removeEventListener("resize", N);
51815
51843
  };
51816
- }, [l, u, g]), $e(() => {
51844
+ }, [l, u, g]), Ve(() => {
51817
51845
  if (l)
51818
51846
  return Eb({
51819
51847
  getPoint: () => m.current.point,
@@ -51947,7 +51975,7 @@ function $q({
51947
51975
  () => S ? { cycleMemberIds: S } : C,
51948
51976
  [S, C]
51949
51977
  ), [N, M] = fe(null), [I, T] = fe("canvas"), A = ye(!1);
51950
- $e(() => {
51978
+ Ve(() => {
51951
51979
  A.current || (A.current = !0, typeof window < "u" && window.matchMedia("(max-width: 640px)").matches && T("list"));
51952
51980
  }, []);
51953
51981
  const D = ye(e.nodes), _ = ye(e.edges);
@@ -51992,7 +52020,7 @@ function $q({
51992
52020
  onNodeDragEnd: m,
51993
52021
  disabled: g
51994
52022
  }), { clearOffsets: G } = H, Y = `${C ?? ""}:${S?.join(",") ?? ""}:${i}`, K = ye(Y);
51995
- $e(() => {
52023
+ Ve(() => {
51996
52024
  K.current !== Y && (K.current = Y, G());
51997
52025
  }, [Y, G]);
51998
52026
  const X = Ne(
@@ -52078,7 +52106,7 @@ function $q({
52078
52106
  },
52079
52107
  [ie]
52080
52108
  );
52081
- $e(() => {
52109
+ Ve(() => {
52082
52110
  const Q = ae.current;
52083
52111
  !Q || V.nodes.length === 0 || (Q.scrollLeft = Math.max(0, B.width / 2 - Q.clientWidth / 2), Q.scrollTop = Math.max(0, B.height / 2 - Q.clientHeight / 2));
52084
52112
  }, [C, S, B.width, B.height]);
@@ -52493,7 +52521,7 @@ function FW(e) {
52493
52521
  const L = v.current;
52494
52522
  L.width === 0 || L.height === 0 || k(dM(S.current.contentBox, L, S.current.fitBounds));
52495
52523
  }, [k]), I = ye(!1), [T, A] = fe(PW);
52496
- $e(() => {
52524
+ Ve(() => {
52497
52525
  if (!C) return;
52498
52526
  const L = v.current, $ = S.current.frameBox ?? S.current.contentBox, H = { ...S.current.fitBounds, padding: S.current.framePadding ?? Or.fitPadding }, { camera: G, overflow: Y } = SW($, L, {
52499
52527
  ...H,
@@ -52595,7 +52623,7 @@ function FW(e) {
52595
52623
  },
52596
52624
  [N, B]
52597
52625
  );
52598
- return $e(
52626
+ return Ve(
52599
52627
  () => () => {
52600
52628
  R.current !== null && window.clearTimeout(R.current);
52601
52629
  },
@@ -52642,7 +52670,7 @@ function Yw({
52642
52670
  pe.observe(se), S.current.set(q, pe);
52643
52671
  }, R.current.set(q, J), J);
52644
52672
  }, []);
52645
- $e(() => {
52673
+ Ve(() => {
52646
52674
  const q = S.current;
52647
52675
  return () => {
52648
52676
  for (const J of q.values()) J.disconnect();
@@ -53891,7 +53919,7 @@ function A7(e, t, n) {
53891
53919
  () => r === null ? rl : Dd(r, o),
53892
53920
  [r, o]
53893
53921
  ), a = Vr(s, i, E7);
53894
- return $e(() => r === null ? void 0 : Gb([r]), [r]), a;
53922
+ return Ve(() => r === null ? void 0 : Gb([r]), [r]), a;
53895
53923
  }
53896
53924
  function Wq(e, t, n) {
53897
53925
  const r = n.needs, o = De(() => t.map((f) => co(e.type, f)), [e.type, t.join("\0")]), s = o.join("\0"), i = Ne(
@@ -53907,7 +53935,7 @@ function Wq(e, t, n) {
53907
53935
  const m = Object.freeze(f);
53908
53936
  return a.current = { signature: s, needs: r, states: m }, m;
53909
53937
  }, [s, r]), c = De(() => Object.freeze(o.map(() => rl)), [s]), u = Ne(() => c, [c]), p = Vr(i, l, u);
53910
- return $e(() => Gb(o), [s]), p;
53938
+ return Ve(() => Gb(o), [s]), p;
53911
53939
  }
53912
53940
  function Kq() {
53913
53941
  return Vr(CM, jb, M7);
@@ -54379,7 +54407,7 @@ function Yq({
54379
54407
  ...o
54380
54408
  }) {
54381
54409
  const [s] = fe(() => new U7({ transport: e, tenant: t, ...o })), i = ye(t);
54382
- return $e(() => (s.start(), () => s.stop()), [s]), $e(() => {
54410
+ return Ve(() => (s.start(), () => s.stop()), [s]), Ve(() => {
54383
54411
  i.current !== t && (i.current = t, s.setTenant(t)), n && p7(t);
54384
54412
  }, [s, t, n]), /* @__PURE__ */ d(SM.Provider, { value: s, children: r });
54385
54413
  }
@@ -54388,7 +54416,7 @@ function kM() {
54388
54416
  }
54389
54417
  function Xq(e, t, n) {
54390
54418
  const r = kM(), o = Kb(Fd(t)), s = [...n].sort().join(","), i = ye({ scope: t, events: n });
54391
- i.current = { scope: t, events: n }, $e(() => {
54419
+ i.current = { scope: t, events: n }, Ve(() => {
54392
54420
  if (r)
54393
54421
  return r.acquire(e.type, i.current.scope, i.current.events);
54394
54422
  }, [r, e.type, o, s]);
@@ -54683,11 +54711,11 @@ function tY(e, t, n) {
54683
54711
  const f = ye(o);
54684
54712
  f.current = o;
54685
54713
  const h = ye(!0);
54686
- $e(() => (h.current = !0, () => {
54714
+ Ve(() => (h.current = !0, () => {
54687
54715
  h.current = !1;
54688
54716
  }), []);
54689
54717
  const m = ye(null);
54690
- $e(() => {
54718
+ Ve(() => {
54691
54719
  if (a === null || !s) {
54692
54720
  m.current = null;
54693
54721
  return;
@@ -54729,14 +54757,14 @@ function nY(e, t) {
54729
54757
  const g = ye(o);
54730
54758
  g.current = o;
54731
54759
  const b = ye(!0);
54732
- $e(() => (b.current = !0, () => {
54760
+ Ve(() => (b.current = !0, () => {
54733
54761
  b.current = !1;
54734
- }), []), $e(
54762
+ }), []), Ve(
54735
54763
  () => J7(n, { type: e.type, tag: r, createdScope: u.current }),
54736
54764
  [n, e.type, r, c]
54737
54765
  );
54738
54766
  const x = Ne((S) => l8(n, S), [n]), w = Ne(() => u8(n), [n]), v = Vr(x, w, X7), C = ye(null);
54739
- $e(() => {
54767
+ Ve(() => {
54740
54768
  if (!s) {
54741
54769
  C.current = null;
54742
54770
  return;
@@ -54782,7 +54810,7 @@ function rY(e, t) {
54782
54810
  });
54783
54811
  }
54784
54812
  function oY(e = 6e4) {
54785
- $e(() => {
54813
+ Ve(() => {
54786
54814
  const t = setInterval(() => O7(), e);
54787
54815
  return () => clearInterval(t);
54788
54816
  }, [e]);