@danxbot/ui 24.1.0 → 24.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -183,6 +183,10 @@ const UO = {
183
183
  crown: [["path", { d: "M11.562 3.266a.5.5 0 0 1 .876 0L15.39 8.87a1 1 0 0 0 1.516.294L21.183 5.5a.5.5 0 0 1 .798.519l-2.834 10.246a1 1 0 0 1-.956.734H5.81a1 1 0 0 1-.957-.734L2.02 6.02a.5.5 0 0 1 .798-.519l4.276 3.664a1 1 0 0 0 1.516-.294z" }], ["path", { d: "M5 21h14" }]],
184
184
  medal: [["path", { d: "M7.21 15 2.66 7.14a2 2 0 0 1 .13-2.2L4.4 2.8A2 2 0 0 1 6 2h12a2 2 0 0 1 1.6.8l1.6 2.14a2 2 0 0 1 .14 2.2L16.79 15" }], ["path", { d: "M11 12 5.12 2.2" }], ["path", { d: "m13 12 5.88-9.8" }], ["path", { d: "M8 7h8" }], ["circle", { cx: "12", cy: "17", r: "5" }], ["path", { d: "M12 18v-2h-.5" }]],
185
185
  mountain: [["path", { d: "m8 3 4 8 5-5 5 15H2L8 3z" }]],
186
+ "piggy-bank": [["path", { d: "M11 17h3v2a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1v-3a3.16 3.16 0 0 0 2-2h1a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1h-1a5 5 0 0 0-2-4V3a4 4 0 0 0-3.2 1.6l-.3.4H11a6 6 0 0 0-6 6v1a5 5 0 0 0 2 4v3a1 1 0 0 0 1 1h2a1 1 0 0 0 1-1z" }], ["path", { d: "M16 10h.01" }], ["path", { d: "M2 8v1a2 2 0 0 0 2 2h1" }]],
187
+ radio: [["path", { d: "M16.247 7.761a6 6 0 0 1 0 8.478" }], ["path", { d: "M19.075 4.933a10 10 0 0 1 0 14.134" }], ["path", { d: "M4.925 19.067a10 10 0 0 1 0-14.134" }], ["path", { d: "M7.753 16.239a6 6 0 0 1 0-8.478" }], ["circle", { cx: "12", cy: "12", r: "2" }]],
188
+ scale: [["path", { d: "m16 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z" }], ["path", { d: "m2 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z" }], ["path", { d: "M7 21h10" }], ["path", { d: "M12 3v18" }], ["path", { d: "M3 7h2c2 0 5-1 7-2 2 1 5 2 7 2h2" }]],
189
+ signal: [["path", { d: "M2 20h.01" }], ["path", { d: "M7 20v-4" }], ["path", { d: "M12 20v-8" }], ["path", { d: "M17 20V8" }], ["path", { d: "M22 4v16" }]],
186
190
  trophy: [["path", { d: "M10 14.66v1.626a2 2 0 0 1-.976 1.696A5 5 0 0 0 7 21.978" }], ["path", { d: "M14 14.66v1.626a2 2 0 0 0 .976 1.696A5 5 0 0 1 17 21.978" }], ["path", { d: "M18 9h1.5a1 1 0 0 0 0-5H18" }], ["path", { d: "M4 22h16" }], ["path", { d: "M6 9a6 6 0 0 0 12 0V3a1 1 0 0 0-1-1H7a1 1 0 0 0-1 1z" }], ["path", { d: "M6 9H4.5a1 1 0 0 1 0-5H6" }]],
187
191
  /* --- text authoring --- */
188
192
  "align-center": [["path", { d: "M21 5H3" }], ["path", { d: "M17 12H7" }], ["path", { d: "M19 19H5" }]],
@@ -16968,7 +16972,7 @@ const Wg = /* @__PURE__ */ k.forwardRef(function(t, n) {
16968
16972
  });
16969
16973
  });
16970
16974
  process.env.NODE_ENV !== "production" && (Wg.displayName = "Input");
16971
- const ez = ht({
16975
+ const e5 = ht({
16972
16976
  base: [
16973
16977
  /* dx-field carries the WebKit search-clear suppression in components.css —
16974
16978
  without it a `type="search"` field with a trailing clear action renders
@@ -17049,7 +17053,7 @@ function Dt(e) {
17049
17053
  Wg,
17050
17054
  {
17051
17055
  ref: i,
17052
- className: H(ez({ size: n, hasLeading: c, hasTrailing: d }), t),
17056
+ className: H(e5({ size: n, hasLeading: c, hasTrailing: d }), t),
17053
17057
  ...a
17054
17058
  }
17055
17059
  );
@@ -17062,7 +17066,7 @@ function Dt(e) {
17062
17066
  /* @__PURE__ */ u("span", { className: H(Tw({ side: "trailing", size: n }), "[&>*]:pointer-events-auto"), children: l })
17063
17067
  ] }) : p;
17064
17068
  }
17065
- const tz = ht({
17069
+ const t5 = ht({
17066
17070
  base: [
17067
17071
  "w-full min-w-0 font-sans text-primary",
17068
17072
  "border border-field-border bg-field",
@@ -17095,13 +17099,13 @@ const tz = ht({
17095
17099
  },
17096
17100
  defaultVariants: { size: "md", resize: "vertical" }
17097
17101
  });
17098
- function nz({ className: e, size: t, resize: n, rows: r = 4, ref: o, ...s }) {
17102
+ function n5({ className: e, size: t, resize: n, rows: r = 4, ref: o, ...s }) {
17099
17103
  return /* @__PURE__ */ u(
17100
17104
  Wg,
17101
17105
  {
17102
17106
  ref: o,
17103
17107
  render: /* @__PURE__ */ u("textarea", { rows: r }),
17104
- className: H(tz({ size: t, resize: n }), e),
17108
+ className: H(t5({ size: t, resize: n }), e),
17105
17109
  ...s
17106
17110
  }
17107
17111
  );
@@ -17129,7 +17133,7 @@ function Zc(e) {
17129
17133
  function fE(e) {
17130
17134
  return typeof e?.then == "function";
17131
17135
  }
17132
- function rz(e, t, n) {
17136
+ function r5(e, t, n) {
17133
17137
  if (t === "")
17134
17138
  throw new Error(
17135
17139
  `${e}: ${n} refused a value with an empty reason. A refusal nobody can read leaves the field open with nothing beside it — return ${n === "validate" ? "null" : "nothing"} to accept the value, or say why it cannot be used.`
@@ -17185,7 +17189,7 @@ function hE(e) {
17185
17189
  f.current += 1, b();
17186
17190
  }
17187
17191
  function y(N, I) {
17188
- rz(t.current.component, N, I), g(!1), s(N), c((A) => A + 1);
17192
+ r5(t.current.component, N, I), g(!1), s(N), c((A) => A + 1);
17189
17193
  }
17190
17194
  function w(N) {
17191
17195
  g(!1), a(t.current.failureMessage), t.current.onError?.(N), c((I) => I + 1);
@@ -17276,7 +17280,7 @@ function hE(e) {
17276
17280
  whenIdle: S
17277
17281
  };
17278
17282
  }
17279
- const oz = ht({
17283
+ const o5 = ht({
17280
17284
  slots: {
17281
17285
  /* THE ONE GEOMETRY RECIPE. Every property that can move text inside the
17282
17286
  box lives here, on the SAME element in both states — there is no second
@@ -17355,33 +17359,33 @@ function bE(e, t) {
17355
17359
  const o = document.createTextNode(t);
17356
17360
  r.insertNode(o), r.setStartAfter(o), r.setEndAfter(o), n.removeAllRanges(), n.addRange(r), e.normalize();
17357
17361
  }
17358
- const sz = /* @__PURE__ */ new Set([
17362
+ const s5 = /* @__PURE__ */ new Set([
17359
17363
  "insertFromPaste",
17360
17364
  "insertFromPasteAsQuotation",
17361
17365
  "insertFromDrop",
17362
17366
  "insertReplacementText",
17363
17367
  "insertFromYank"
17364
17368
  ]);
17365
- function iz(e, t) {
17369
+ function i5(e, t) {
17366
17370
  return t === "multiline" ? e : t === "wrap" ? e.replace(/\r\n|\r|\n/g, " ") : e.replace(/\r\n|\r|\n/g, "");
17367
17371
  }
17368
- function az(e, t, n) {
17372
+ function a5(e, t, n) {
17369
17373
  const r = xe(n);
17370
17374
  r.current = n, _e(() => {
17371
17375
  const o = e.current;
17372
17376
  if (!o) return;
17373
17377
  function s(i) {
17374
- if (!sz.has(i.inputType)) return;
17378
+ if (!s5.has(i.inputType)) return;
17375
17379
  i.preventDefault();
17376
17380
  const a = e.current;
17377
17381
  if (!a) return;
17378
- const l = i.dataTransfer?.getData("text/plain") ?? i.data ?? "", c = iz(l, t);
17382
+ const l = i.dataTransfer?.getData("text/plain") ?? i.data ?? "", c = i5(l, t);
17379
17383
  bE(a, c), r.current();
17380
17384
  }
17381
17385
  return o.addEventListener("beforeinput", s), () => o.removeEventListener("beforeinput", s);
17382
17386
  }, [e, t]);
17383
17387
  }
17384
- function lz({ delayMs: e, session: t, elRef: n, openRef: r, composingRef: o, ...s }) {
17388
+ function l5({ delayMs: e, session: t, elRef: n, openRef: r, composingRef: o, ...s }) {
17385
17389
  const i = e !== void 0, [a, l] = ne(!1), c = xe(null), d = xe(""), f = xe(""), p = xe("none"), h = xe(!1), m = xe(s);
17386
17390
  m.current = s;
17387
17391
  function g() {
@@ -17515,7 +17519,7 @@ function iee(e) {
17515
17519
  );
17516
17520
  qg("InlineEdit", p, h);
17517
17521
  const { inlineEdit: y, keyNames: w } = he(), C = i ?? y.empty, S = l === "multiline", R = e.failureMessage ?? // I18N-ALLOW: key ids of the retry chord, named by the catalog through chordLabel
17518
- y.failure(Su(S && c === void 0 ? "ctrl+enter" : "enter", w)), E = oz({ size: a }), N = p !== void 0, [I, A] = fi(p, !1, h), [D, P] = ne(t.length === 0), T = xe(null), $ = xe(!1), L = xe(!1), F = xe(!1), _ = hE({
17522
+ y.failure(Su(S && c === void 0 ? "ctrl+enter" : "enter", w)), E = o5({ size: a }), N = p !== void 0, [I, A] = fi(p, !1, h), [D, P] = ne(t.length === 0), T = xe(null), $ = xe(!1), L = xe(!1), F = xe(!1), _ = hE({
17519
17523
  component: "InlineEdit",
17520
17524
  value: t,
17521
17525
  onCommit: n,
@@ -17523,7 +17527,7 @@ function iee(e) {
17523
17527
  failureMessage: R,
17524
17528
  close: oe,
17525
17529
  refocus: () => T.current?.focus()
17526
- }), z = lz({
17530
+ }), z = l5({
17527
17531
  delayMs: c,
17528
17532
  session: _,
17529
17533
  elRef: T,
@@ -17548,7 +17552,7 @@ function iee(e) {
17548
17552
  function Y() {
17549
17553
  return T.current ? mE(T.current) : "";
17550
17554
  }
17551
- az(T, l, te);
17555
+ a5(T, l, te);
17552
17556
  function K() {
17553
17557
  N || G || W || O || A(!0);
17554
17558
  }
@@ -17630,8 +17634,8 @@ function iee(e) {
17630
17634
  "data-editing": W || void 0,
17631
17635
  className: H(
17632
17636
  E.box(),
17633
- cz({ editing: W, controlled: N, unavailable: G, pending: O, refused: V !== null }),
17634
- uz(l, W),
17637
+ c5({ editing: W, controlled: N, unavailable: G, pending: O, refused: V !== null }),
17638
+ u5(l, W),
17635
17639
  g
17636
17640
  ),
17637
17641
  onClick: K,
@@ -17654,7 +17658,7 @@ function iee(e) {
17654
17658
  ] });
17655
17659
  return G ? /* @__PURE__ */ u(Gt, { content: d.reason, children: Se }) : Se;
17656
17660
  }
17657
- function cz({
17661
+ function c5({
17658
17662
  editing: e,
17659
17663
  controlled: t,
17660
17664
  unavailable: n,
@@ -17677,7 +17681,7 @@ function cz({
17677
17681
  n && ["cursor-not-allowed", "hover:border-transparent hover:bg-transparent"]
17678
17682
  );
17679
17683
  }
17680
- function uz(e, t) {
17684
+ function u5(e, t) {
17681
17685
  return e === "multiline" ? "whitespace-pre-wrap break-words" : e === "wrap" ? "whitespace-normal break-words" : t ? "whitespace-nowrap overflow-x-auto" : "truncate";
17682
17686
  }
17683
17687
  function aee({
@@ -17691,7 +17695,7 @@ function aee({
17691
17695
  }) {
17692
17696
  qg("EditGutter", n, r);
17693
17697
  const [a, l] = fi(n, !1, r), c = xe(null), d = xe(null), f = !a && !o, p = xe("");
17694
- pz(c, d, f), hz(c, d, a);
17698
+ p5(c, d, f), h5(c, d, a);
17695
17699
  function h(m) {
17696
17700
  p.current !== "touch" || !f || m.target.closest("a, button, input, textarea, select, [role='button']") === null && l(!0);
17697
17701
  }
@@ -17733,33 +17737,33 @@ function aee({
17733
17737
  }
17734
17738
  );
17735
17739
  }
17736
- function dz(e, t) {
17740
+ function d5(e, t) {
17737
17741
  return document.createTreeWalker(e, NodeFilter.SHOW_TEXT, {
17738
17742
  acceptNode: (r) => t !== null && t.contains(r) || (r.textContent ?? "").trim() === "" ? NodeFilter.FILTER_REJECT : NodeFilter.FILTER_ACCEPT
17739
17743
  }).nextNode();
17740
17744
  }
17741
- function fz(e) {
17745
+ function f5(e) {
17742
17746
  for (let t = e.parentElement; t !== null && t !== document.body; t = t.parentElement) {
17743
17747
  const { overflowX: n } = getComputedStyle(t);
17744
17748
  if (n !== "visible") return t;
17745
17749
  }
17746
17750
  return null;
17747
17751
  }
17748
- function pz(e, t, n) {
17752
+ function p5(e, t, n) {
17749
17753
  const r = xe(!1);
17750
17754
  _e(() => {
17751
17755
  const o = e.current, s = t.current;
17752
17756
  if (!n || !o || !s) return;
17753
17757
  function i() {
17754
17758
  if (!o || !s) return;
17755
- const l = o.getBoundingClientRect(), c = s.getBoundingClientRect(), d = dz(o, s);
17759
+ const l = o.getBoundingClientRect(), c = s.getBoundingClientRect(), d = d5(o, s);
17756
17760
  if (d !== null) {
17757
17761
  const p = document.createRange();
17758
17762
  p.selectNodeContents(d);
17759
17763
  const h = p.getClientRects()[0];
17760
17764
  h !== void 0 && h.height > 0 && (s.style.top = `${h.top - l.top + (h.height - c.height) / 2}px`);
17761
17765
  }
17762
- const f = fz(o);
17766
+ const f = f5(o);
17763
17767
  f !== null && !r.current && c.left < f.getBoundingClientRect().left && (r.current = !0, console.warn(
17764
17768
  "[danxbot] EditGutter: an ancestor with `overflow` other than visible clips the pencil — it sits in the gutter LEFT of the field, outside its box. Leave that gutter inside the clipping box (padding on the clipping element, or move the overflow further out).",
17765
17769
  f
@@ -17770,7 +17774,7 @@ function pz(e, t, n) {
17770
17774
  return a.observe(o), () => a.disconnect();
17771
17775
  }, [e, t, n]);
17772
17776
  }
17773
- function hz(e, t, n) {
17777
+ function h5(e, t, n) {
17774
17778
  const r = xe(n);
17775
17779
  _e(() => {
17776
17780
  const o = r.current && !n;
@@ -17829,7 +17833,7 @@ function Kg(e, t, n) {
17829
17833
  }
17830
17834
  return r;
17831
17835
  }
17832
- function mz(e, t, n) {
17836
+ function m5(e, t, n) {
17833
17837
  const r = Kg(e, t, n);
17834
17838
  return r.length ? { start: r[0].start, end: r[r.length - 1].end } : null;
17835
17839
  }
@@ -17837,7 +17841,7 @@ function Cn(e, t, n, r, o) {
17837
17841
  if (!(!t || r <= n))
17838
17842
  for (const s of Kg(e, n, r)) t.span(s.start, s.end, o);
17839
17843
  }
17840
- const $h = /[!-/:-@[-`{-~]/, gz = 8;
17844
+ const $h = /[!-/:-@[-`{-~]/, g5 = 8;
17841
17845
  function Ow(e, t, n, r = "text", o = 0, s = e.text.length) {
17842
17846
  const i = Yg(yE(e, t, o, s, 0));
17843
17847
  return n && Lh(i, e, n, r), ps(i);
@@ -17863,28 +17867,28 @@ function yE(e, t, n, r, o) {
17863
17867
  }
17864
17868
  }
17865
17869
  if (d === "`") {
17866
- const f = bz(s, a, r);
17870
+ const f = b5(s, a, r);
17867
17871
  if (f) {
17868
17872
  c(a), i.push(f), a = f.b, l = a;
17869
17873
  continue;
17870
17874
  }
17871
17875
  }
17872
17876
  if (d === "<") {
17873
- const f = yz(s, a, r);
17877
+ const f = y5(s, a, r);
17874
17878
  if (f) {
17875
17879
  c(a), i.push(f), a = f.b, l = a;
17876
17880
  continue;
17877
17881
  }
17878
17882
  }
17879
17883
  if (d === "&") {
17880
- const f = Cz(s, a, r);
17884
+ const f = C5(s, a, r);
17881
17885
  if (f) {
17882
17886
  c(a), i.push(f), a = f.b, l = a;
17883
17887
  continue;
17884
17888
  }
17885
17889
  }
17886
17890
  if (d === "[" || d === "!" && s[a + 1] === "[") {
17887
- const f = Rz(e, t, a, r, o);
17891
+ const f = R5(e, t, a, r, o);
17888
17892
  if (f) {
17889
17893
  c(a), i.push(f), a = f.b, l = a;
17890
17894
  continue;
@@ -17893,7 +17897,7 @@ function yE(e, t, n, r, o) {
17893
17897
  if (d === "*" || d === "_" || d === "~") {
17894
17898
  let f = a;
17895
17899
  for (; f < r && s[f] === d; ) f++;
17896
- c(a), i.push(Nz(s, a, f, d, n, r)), a = f, l = a;
17900
+ c(a), i.push(N5(s, a, f, d, n, r)), a = f, l = a;
17897
17901
  continue;
17898
17902
  }
17899
17903
  if (d === `
@@ -17913,8 +17917,8 @@ function yE(e, t, n, r, o) {
17913
17917
  a += 1, l = a;
17914
17918
  continue;
17915
17919
  }
17916
- if ((d === "h" || d === "w") && Sz(s, a, n)) {
17917
- const f = Ez(s, a, r);
17920
+ if ((d === "h" || d === "w") && S5(s, a, n)) {
17921
+ const f = E5(s, a, r);
17918
17922
  if (f) {
17919
17923
  c(a), i.push(f), a = f.b, l = a;
17920
17924
  continue;
@@ -17924,7 +17928,7 @@ function yE(e, t, n, r, o) {
17924
17928
  }
17925
17929
  return c(r), i;
17926
17930
  }
17927
- function bz(e, t, n) {
17931
+ function b5(e, t, n) {
17928
17932
  let r = t;
17929
17933
  for (; r < n && e[r] === "`"; ) r++;
17930
17934
  const o = r - t;
@@ -17944,14 +17948,14 @@ function bz(e, t, n) {
17944
17948
  }
17945
17949
  return null;
17946
17950
  }
17947
- const vz = /^<([a-zA-Z][a-zA-Z0-9+.-]{1,31}:[^<>\u0000-\u0020]*)>/, xz = /^<([^\s<>@]+@[^\s<>@]+\.[^\s<>@]+)>/;
17948
- function yz(e, t, n) {
17949
- const r = e.slice(t, n), o = vz.exec(r);
17951
+ const v5 = /^<([a-zA-Z][a-zA-Z0-9+.-]{1,31}:[^<>\u0000-\u0020]*)>/, x5 = /^<([^\s<>@]+@[^\s<>@]+\.[^\s<>@]+)>/;
17952
+ function y5(e, t, n) {
17953
+ const r = e.slice(t, n), o = v5.exec(r);
17950
17954
  if (o) return { t: "auto", a: t, b: t + o[0].length, href: o[1], label: o[1] };
17951
- const s = xz.exec(r);
17955
+ const s = x5.exec(r);
17952
17956
  return s ? { t: "auto", a: t, b: t + s[0].length, href: `mailto:${s[1]}`, label: s[1] } : null;
17953
17957
  }
17954
- const wz = {
17958
+ const w5 = {
17955
17959
  amp: "&",
17956
17960
  lt: "<",
17957
17961
  gt: ">",
@@ -17993,12 +17997,12 @@ const wz = {
17993
17997
  para: "¶",
17994
17998
  frac12: "½",
17995
17999
  frac14: "¼"
17996
- }, kz = /^&(?:#[xX]([0-9a-fA-F]{1,6})|#(\d{1,7})|([a-zA-Z][a-zA-Z0-9]{1,31}));/;
17997
- function Cz(e, t, n) {
17998
- const r = kz.exec(e.slice(t, n));
18000
+ }, k5 = /^&(?:#[xX]([0-9a-fA-F]{1,6})|#(\d{1,7})|([a-zA-Z][a-zA-Z0-9]{1,31}));/;
18001
+ function C5(e, t, n) {
18002
+ const r = k5.exec(e.slice(t, n));
17999
18003
  if (!r) return null;
18000
18004
  let o;
18001
- return r[1] !== void 0 ? o = Aw(parseInt(r[1], 16)) : r[2] !== void 0 ? o = Aw(parseInt(r[2], 10)) : o = wz[r[3]], o === void 0 ? null : { t: "text", a: t, b: t + r[0].length, value: o, esc: !0 };
18005
+ return r[1] !== void 0 ? o = Aw(parseInt(r[1], 16)) : r[2] !== void 0 ? o = Aw(parseInt(r[2], 10)) : o = w5[r[3]], o === void 0 ? null : { t: "text", a: t, b: t + r[0].length, value: o, esc: !0 };
18002
18006
  }
18003
18007
  function Aw(e) {
18004
18008
  if (!Number.isFinite(e) || e <= 0 || e > 1114111) return "�";
@@ -18008,11 +18012,11 @@ function Aw(e) {
18008
18012
  return "�";
18009
18013
  }
18010
18014
  }
18011
- function Sz(e, t, n) {
18015
+ function S5(e, t, n) {
18012
18016
  const r = t > n ? e[t - 1] : " ";
18013
18017
  return /[\w/@.-]/.test(r) ? !1 : /^(https?:\/\/|www\.)/.test(e.slice(t, t + 8));
18014
18018
  }
18015
- function Ez(e, t, n) {
18019
+ function E5(e, t, n) {
18016
18020
  const r = /^(?:https?:\/\/|www\.)[^\s<>]+/.exec(e.slice(t, n));
18017
18021
  if (!r) return null;
18018
18022
  let o = r[0];
@@ -18030,19 +18034,19 @@ function Dw(e, t) {
18030
18034
  for (const r of e) r === t && n++;
18031
18035
  return n;
18032
18036
  }
18033
- function Nz(e, t, n, r, o, s) {
18037
+ function N5(e, t, n, r, o, s) {
18034
18038
  const i = t > o ? e[t - 1] : " ", a = n < s ? e[n] : " ", l = /\s/.test(i), c = /\s/.test(a), d = $h.test(i), f = $h.test(a), p = !c && (!f || l || d), h = !l && (!d || c || f), m = r === "_" ? p && (!h || d) : p, g = r === "_" ? h && (!p || f) : h;
18035
18039
  return { t: "delim", a: t, b: n, ch: r, len: n - t, olen: n - t, canOpen: m, canClose: g };
18036
18040
  }
18037
- function Rz(e, t, n, r, o) {
18041
+ function R5(e, t, n, r, o) {
18038
18042
  const s = e.text, i = s[n] === "!", a = i ? n + 1 : n, l = _w(s, a, r);
18039
18043
  if (l < 0) return null;
18040
18044
  const c = a + 1, d = l, f = s.slice(c, d);
18041
18045
  if (!i && f.startsWith("^") && f.length > 1 && !/\s/.test(f))
18042
18046
  return { t: "footref", a: n, b: l + 1, label: f.slice(1) };
18043
- const p = o >= gz ? [] : Yg(yE(e, t, c, d, o + 1));
18047
+ const p = o >= g5 ? [] : Yg(yE(e, t, c, d, o + 1));
18044
18048
  if (s[l + 1] === "(") {
18045
- const v = Iz(s, l + 1, r);
18049
+ const v = I5(s, l + 1, r);
18046
18050
  if (v)
18047
18051
  return {
18048
18052
  t: i ? "image" : "link",
@@ -18094,7 +18098,7 @@ function _w(e, t, n) {
18094
18098
  }
18095
18099
  return -1;
18096
18100
  }
18097
- function Iz(e, t, n) {
18101
+ function I5(e, t, n) {
18098
18102
  let r = t + 1;
18099
18103
  for (; r < n && /[ \t\n]/.test(e[r]); ) r++;
18100
18104
  let o = "";
@@ -18151,7 +18155,7 @@ function Yg(e) {
18151
18155
  let o = n - 1, s = null;
18152
18156
  for (; o >= 0; o--) {
18153
18157
  const m = t[o];
18154
- if (!(m.t !== "delim" || m.ch !== r.ch || !m.canOpen) && Mz(m, r)) {
18158
+ if (!(m.t !== "delim" || m.ch !== r.ch || !m.canOpen) && M5(m, r)) {
18155
18159
  s = m;
18156
18160
  break;
18157
18161
  }
@@ -18176,11 +18180,11 @@ function Yg(e) {
18176
18180
  }
18177
18181
  return t;
18178
18182
  }
18179
- function Mz(e, t) {
18183
+ function M5(e, t) {
18180
18184
  return e.t !== "delim" || t.t !== "delim" ? !1 : !t.canOpen && !e.canClose || (t.olen + e.olen) % 3 !== 0 ? !0 : t.olen % 3 === 0 && e.olen % 3 === 0;
18181
18185
  }
18182
18186
  function Zs(e, t, n, r, o, s, i) {
18183
- const a = mz(t, r, o);
18187
+ const a = m5(t, r, o);
18184
18188
  if (!a) {
18185
18189
  i();
18186
18190
  return;
@@ -18307,20 +18311,20 @@ function Xd(e) {
18307
18311
  }
18308
18312
  return t;
18309
18313
  }
18310
- const Tz = 12, Ha = /^( {0,3})(`{3,}|~{3,})(.*)$/, kE = /^( {0,3})(#{1,6})(?:[ \t]|$)/, CE = /^ {0,3}(?:\*[ \t]*){3,}$|^ {0,3}(?:-[ \t]*){3,}$|^ {0,3}(?:_[ \t]*){3,}$/, Xg = /^ {0,3}>[ \t]?/, pi = /^( {0,3})([-*+])(?:[ \t]|$)/, hi = /^( {0,3})(\d{1,9})([.)])(?:[ \t]|$)/, Pz = /^ {0,3}(=+|-+)[ \t]*$/, Zg = /^( {0,3})(\[\^([^\]\s]+)\]:)[ \t]*/d, SE = /^( {0,3})(\[([^\]]+)\]:)[ \t]*(<[^>]*>|\S+)(?:[ \t]+(["'(].*["')]))?[ \t]*$/d, Oz = /^\[([ xX])\](?:[ \t]+|$)/, Az = /^[ \t]*\|?[ \t]*:?-+:?[ \t]*(?:\|[ \t]*:?-+:?[ \t]*)*\|?[ \t]*$/, Dz = /^(---|\+\+\+)[ \t]*$/;
18314
+ const T5 = 12, Ha = /^( {0,3})(`{3,}|~{3,})(.*)$/, kE = /^( {0,3})(#{1,6})(?:[ \t]|$)/, CE = /^ {0,3}(?:\*[ \t]*){3,}$|^ {0,3}(?:-[ \t]*){3,}$|^ {0,3}(?:_[ \t]*){3,}$/, Xg = /^ {0,3}>[ \t]?/, pi = /^( {0,3})([-*+])(?:[ \t]|$)/, hi = /^( {0,3})(\d{1,9})([.)])(?:[ \t]|$)/, P5 = /^ {0,3}(=+|-+)[ \t]*$/, Zg = /^( {0,3})(\[\^([^\]\s]+)\]:)[ \t]*/d, SE = /^( {0,3})(\[([^\]]+)\]:)[ \t]*(<[^>]*>|\S+)(?:[ \t]+(["'(].*["')]))?[ \t]*$/d, O5 = /^\[([ xX])\](?:[ \t]+|$)/, A5 = /^[ \t]*\|?[ \t]*:?-+:?[ \t]*(?:\|[ \t]*:?-+:?[ \t]*)*\|?[ \t]*$/, D5 = /^(---|\+\+\+)[ \t]*$/;
18311
18315
  function EE(e) {
18312
18316
  return Jg(e);
18313
18317
  }
18314
18318
  function Jg(e, t) {
18315
- const n = $z(e), r = { source: e, sink: t, refs: Fz(n), footnotes: [], ids: /* @__PURE__ */ new Map() }, o = [];
18319
+ const n = $5(e), r = { source: e, sink: t, refs: F5(n), footnotes: [], ids: /* @__PURE__ */ new Map() }, o = [];
18316
18320
  let s = 0;
18317
- const i = zz(n, r);
18321
+ const i = z5(n, r);
18318
18322
  return i && (o.push(i.node), s = i.next), o.push(...Zd(n.slice(s), r, 0, "text")), r.footnotes.length && o.push({ kind: "footnotes", items: r.footnotes }), o;
18319
18323
  }
18320
- function _z(e) {
18324
+ function _5(e) {
18321
18325
  return e.toLowerCase().replace(/[^\p{L}\p{N}]+/gu, "-").replace(/^-+|-+$/g, "");
18322
18326
  }
18323
- function $z(e) {
18327
+ function $5(e) {
18324
18328
  const t = [];
18325
18329
  let n = 0;
18326
18330
  for (; ; ) {
@@ -18368,7 +18372,7 @@ function ir(e, t) {
18368
18372
  e.source[n] === "\r" && n++, e.source[n] === `
18369
18373
  ` && n++, e.sink.close(n, n > t ? [{ start: t, end: n }] : void 0);
18370
18374
  }
18371
- function Lz(e, t, n) {
18375
+ function L5(e, t, n) {
18372
18376
  return { start: e[t].start, end: Vt(e[n]) };
18373
18377
  }
18374
18378
  function Qg(e, t, n, r) {
@@ -18389,7 +18393,7 @@ function Qg(e, t, n, r) {
18389
18393
  function Vt(e) {
18390
18394
  return e.start + e.text.length;
18391
18395
  }
18392
- function Fz(e) {
18396
+ function F5(e) {
18393
18397
  const t = /* @__PURE__ */ new Map();
18394
18398
  let n = null, r = !0;
18395
18399
  for (const o of e) {
@@ -18405,19 +18409,19 @@ function Fz(e) {
18405
18409
  const i = r ? SE.exec(o.text) : null;
18406
18410
  if (i) {
18407
18411
  const a = wE(i[3]);
18408
- t.has(a) || t.set(a, { href: Vz(i[4]), title: i[5] ? i[5].slice(1, -1) : void 0 }), r = !0;
18412
+ t.has(a) || t.set(a, { href: V5(i[4]), title: i[5] ? i[5].slice(1, -1) : void 0 }), r = !0;
18409
18413
  continue;
18410
18414
  }
18411
18415
  r = uo(o);
18412
18416
  }
18413
18417
  return t;
18414
18418
  }
18415
- function Vz(e) {
18419
+ function V5(e) {
18416
18420
  return (e.startsWith("<") && e.endsWith(">") ? e.slice(1, -1) : e).replace(/\\([!-/:-@[-`{-~])/g, "$1");
18417
18421
  }
18418
- function zz(e, t) {
18422
+ function z5(e, t) {
18419
18423
  if (!e.length) return null;
18420
- const n = Dz.exec(e[0].text);
18424
+ const n = D5.exec(e[0].text);
18421
18425
  if (!n) return null;
18422
18426
  let r = -1;
18423
18427
  for (let i = 1; i < e.length; i++)
@@ -18440,7 +18444,7 @@ function zz(e, t) {
18440
18444
  }
18441
18445
  function Zd(e, t, n, r) {
18442
18446
  const o = [];
18443
- if (n > Tz) return o;
18447
+ if (n > T5) return o;
18444
18448
  let s = 0;
18445
18449
  for (; s < e.length; ) {
18446
18450
  const i = e[s];
@@ -18448,12 +18452,12 @@ function Zd(e, t, n, r) {
18448
18452
  s++;
18449
18453
  continue;
18450
18454
  }
18451
- const a = Bz(e, s, t);
18455
+ const a = B5(e, s, t);
18452
18456
  if (a) {
18453
18457
  o.push(a.node), s = a.next;
18454
18458
  continue;
18455
18459
  }
18456
- const l = Uz(i, t, r);
18460
+ const l = U5(i, t, r);
18457
18461
  if (l) {
18458
18462
  o.push(l), s++;
18459
18463
  continue;
@@ -18464,41 +18468,41 @@ function Zd(e, t, n, r) {
18464
18468
  }
18465
18469
  if (Xg.test(i.text)) {
18466
18470
  Jt(t, { kind: "quote" }, i.start);
18467
- const p = jz(e, s, t, n);
18471
+ const p = j5(e, s, t, n);
18468
18472
  o.push(p.node), ir(t, Vt(e[p.next - 1])), s = p.next;
18469
18473
  continue;
18470
18474
  }
18471
18475
  const c = Zg.exec(i.text);
18472
18476
  if (c) {
18473
18477
  Jt(t, { kind: "footnoteDef", label: c[3] }, i.start);
18474
- const p = Wz(e, s, t, n);
18478
+ const p = W5(e, s, t, n);
18475
18479
  ir(t, Vt(e[p.next - 1])), s = p.next;
18476
18480
  continue;
18477
18481
  }
18478
18482
  const d = SE.exec(i.text);
18479
18483
  if (d) {
18480
- Jt(t, { kind: "linkDef" }, i.start), qz(i, d, t), ir(t, Vt(i)), s++;
18484
+ Jt(t, { kind: "linkDef" }, i.start), q5(i, d, t), ir(t, Vt(i)), s++;
18481
18485
  continue;
18482
18486
  }
18483
18487
  if (RE(e, s)) {
18484
18488
  Jt(t, { kind: "table" }, i.start);
18485
- const p = Kz(e, s, t);
18489
+ const p = K5(e, s, t);
18486
18490
  o.push(p.node), qr(t, Vt(e[p.next - 1])), s = p.next;
18487
18491
  continue;
18488
18492
  }
18489
18493
  if (pi.test(i.text) || hi.test(i.text)) {
18490
18494
  const p = hi.exec(i.text), m = !pi.exec(i.text) && !!p, g = { kind: "list", ordered: m, start: m ? Number(p[2]) : 1, tight: !0 };
18491
18495
  Jt(t, g, i.start);
18492
- const b = Gz(e, s, t, n, r, g);
18496
+ const b = G5(e, s, t, n, r, g);
18493
18497
  o.push(b.node), ir(t, Vt(e[b.next - 1])), s = b.next;
18494
18498
  continue;
18495
18499
  }
18496
18500
  if (Ua(i.text) >= 4) {
18497
- const p = Hz(e, s, t);
18501
+ const p = H5(e, s, t);
18498
18502
  o.push(p.node), s = p.next;
18499
18503
  continue;
18500
18504
  }
18501
- const f = Zz(e, s, t, r);
18505
+ const f = Z5(e, s, t, r);
18502
18506
  o.push(f.node), s = f.next;
18503
18507
  }
18504
18508
  return o;
@@ -18506,7 +18510,7 @@ function Zd(e, t, n, r) {
18506
18510
  function ml(e) {
18507
18511
  return Ha.test(e) || kE.test(e) || CE.test(e) || Xg.test(e) || pi.test(e) || hi.test(e) || Zg.test(e);
18508
18512
  }
18509
- function Bz(e, t, n) {
18513
+ function B5(e, t, n) {
18510
18514
  const r = e[t], o = Ha.exec(r.text);
18511
18515
  if (!o || o[2][0] === "`" && o[3].includes("`")) return null;
18512
18516
  const s = o[1].length, i = r.start + s;
@@ -18538,7 +18542,7 @@ function Bz(e, t, n) {
18538
18542
  `);
18539
18543
  return { node: { kind: "code", language: l, code: m, open: h }, next: p };
18540
18544
  }
18541
- function Hz(e, t, n) {
18545
+ function H5(e, t, n) {
18542
18546
  const r = [];
18543
18547
  let o = t;
18544
18548
  for (; o < e.length && (uo(e[o]) || Ua(e[o].text) >= 4); )
@@ -18554,7 +18558,7 @@ function Hz(e, t, n) {
18554
18558
  ), qr(n, i), ir(n, i), { node: { kind: "code", language: null, code: r.map((l) => ja(l, 4).text).join(`
18555
18559
  `), open: !1 }, next: o };
18556
18560
  }
18557
- function Uz(e, t, n) {
18561
+ function U5(e, t, n) {
18558
18562
  const r = kE.exec(e.text);
18559
18563
  if (!r) return null;
18560
18564
  const o = r[2].length, s = e.start + r[1].length;
@@ -18573,10 +18577,10 @@ function Uz(e, t, n) {
18573
18577
  return ir(t, Vt(e)), { kind: "heading", level: o, id: NE(t, d), children: d };
18574
18578
  }
18575
18579
  function NE(e, t) {
18576
- const n = _z(Xd(t)) || "section", r = e.ids.get(n) ?? 0;
18580
+ const n = _5(Xd(t)) || "section", r = e.ids.get(n) ?? 0;
18577
18581
  return e.ids.set(n, r + 1), r === 0 ? n : `${n}-${r}`;
18578
18582
  }
18579
- function jz(e, t, n, r) {
18583
+ function j5(e, t, n, r) {
18580
18584
  const o = [];
18581
18585
  let s = t;
18582
18586
  for (; s < e.length; ) {
@@ -18590,7 +18594,7 @@ function jz(e, t, n, r) {
18590
18594
  }
18591
18595
  return { node: { kind: "quote", children: Zd(o, n, r + 1, "quote") }, next: s };
18592
18596
  }
18593
- function Gz(e, t, n, r, o, s) {
18597
+ function G5(e, t, n, r, o, s) {
18594
18598
  const i = hi.exec(e[t].text), a = pi.exec(e[t].text), l = !a && !!i, c = l ? i[3] : a[2], d = l ? Number(i[2]) : 1, f = [];
18595
18599
  let p = !1, h = t;
18596
18600
  for (; h < e.length; ) {
@@ -18627,14 +18631,14 @@ function Gz(e, t, n, r, o, s) {
18627
18631
  T && (l ? T[3] : T[2]) === c && (p = !0);
18628
18632
  }
18629
18633
  let A = null;
18630
- const D = Oz.exec(N[0].text);
18634
+ const D = O5.exec(N[0].text);
18631
18635
  D && (A = D[1] !== " ", y.checked = A, on(n, N[0].start, N[0].start + 3, "marker"), N[0] = { text: N[0].text.slice(D[0].length), start: N[0].start + D[0].length }), f.push({ checked: A, children: Zd(N, n, r + 1, o) });
18632
18636
  const P = N[N.length - 1];
18633
18637
  ir(n, P.start + P.text.length);
18634
18638
  }
18635
18639
  return s && (s.tight = !p), { node: { kind: "list", ordered: l, start: d, tight: !p, items: f }, next: h };
18636
18640
  }
18637
- function Wz(e, t, n, r) {
18641
+ function W5(e, t, n, r) {
18638
18642
  const o = e[t], s = Zg.exec(o.text);
18639
18643
  if (!s) return null;
18640
18644
  const i = o.start + s[1].length;
@@ -18659,7 +18663,7 @@ function Wz(e, t, n, r) {
18659
18663
  }
18660
18664
  return n.footnotes.push({ label: s[3], children: Zd(a, n, r + 1, "text") }), { next: l };
18661
18665
  }
18662
- function qz(e, t, n) {
18666
+ function q5(e, t, n) {
18663
18667
  const r = e.start + t[1].length;
18664
18668
  on(n, r, r + t[2].length, "marker");
18665
18669
  const o = t.indices?.[4];
@@ -18670,7 +18674,7 @@ function qz(e, t, n) {
18670
18674
  function RE(e, t) {
18671
18675
  if (t + 1 >= e.length) return !1;
18672
18676
  const n = e[t], r = e[t + 1];
18673
- return !n.text.includes("|") || !r.text.includes("-") || !Az.test(r.text) ? !1 : Ra(n).cells.length === Ra(r).cells.length;
18677
+ return !n.text.includes("|") || !r.text.includes("-") || !A5.test(r.text) ? !1 : Ra(n).cells.length === Ra(r).cells.length;
18674
18678
  }
18675
18679
  function Ra(e) {
18676
18680
  const t = [], n = [], r = e.text;
@@ -18688,14 +18692,14 @@ function Lw(e) {
18688
18692
  const t = /^[ \t]*/.exec(e.text)[0].length;
18689
18693
  return { text: e.text.slice(t).replace(/[ \t]+$/, ""), start: e.start + t };
18690
18694
  }
18691
- function Kz(e, t, n) {
18695
+ function K5(e, t, n) {
18692
18696
  let r = t + 1;
18693
18697
  for (; r + 1 < e.length; ) {
18694
18698
  const d = e[r + 1];
18695
18699
  if (uo(d) || !d.text.includes("|") || ml(d.text)) break;
18696
18700
  r++;
18697
18701
  }
18698
- const s = Ra(e[t + 1]).cells.map(Xz), i = Ra(e[t]);
18702
+ const s = Ra(e[t + 1]).cells.map(X5), i = Ra(e[t]);
18699
18703
  for (const d of i.pipes) on(n, d.start, d.end, "punctuation");
18700
18704
  const a = Fw(n, e[t], i.cells, !0, s, wp(n, Vt(e[t])));
18701
18705
  on(n, e[t + 1].start, Vt(e[t + 1]), "marker");
@@ -18725,26 +18729,26 @@ function Fw(e, t, n, r, o, s) {
18725
18729
  };
18726
18730
  for (let c = 0; c < n.length; c++) {
18727
18731
  const d = n[c];
18728
- l(d.start), i.push(Yz(d, e, r, o[c] ?? null)), a = d.start + d.text.length;
18732
+ l(d.start), i.push(Y5(d, e, r, o[c] ?? null)), a = d.start + d.text.length;
18729
18733
  }
18730
18734
  return l(s), qr(e, s), i;
18731
18735
  }
18732
- function Yz(e, t, n, r) {
18736
+ function Y5(e, t, n, r) {
18733
18737
  Jt(t, { kind: "tableCell", header: n, align: r }, e.start);
18734
18738
  const o = Qg(t, [e], xE(e), "text");
18735
18739
  return qr(t, e.start + e.text.length), { children: o };
18736
18740
  }
18737
- function Xz(e) {
18741
+ function X5(e) {
18738
18742
  const t = e.text.trim(), n = t.startsWith(":"), r = t.endsWith(":");
18739
18743
  return n && r ? "center" : r ? "right" : n ? "left" : null;
18740
18744
  }
18741
- function Zz(e, t, n, r) {
18745
+ function Z5(e, t, n, r) {
18742
18746
  const o = [e[t]];
18743
18747
  let s = t + 1;
18744
18748
  for (; s < e.length; ) {
18745
18749
  const a = e[s];
18746
18750
  if (uo(a)) break;
18747
- const l = Pz.exec(a.text);
18751
+ const l = P5.exec(a.text);
18748
18752
  if (l) {
18749
18753
  on(n, a.start, Vt(a), "marker");
18750
18754
  const c = l[1][0] === "=" ? 1 : 2;
@@ -18757,7 +18761,7 @@ function Zz(e, t, n, r) {
18757
18761
  }
18758
18762
  Jt(n, { kind: "paragraph" }, e[t].start);
18759
18763
  const i = { kind: "paragraph", children: Vw(o, n, r) };
18760
- return ir(n, Lz(e, t, s - 1).end), { node: i, next: s };
18764
+ return ir(n, L5(e, t, s - 1).end), { node: i, next: s };
18761
18765
  }
18762
18766
  function Vw(e, t, n) {
18763
18767
  return Qg(t, e, vE(e), n);
@@ -18803,10 +18807,10 @@ function Jd(e) {
18803
18807
  if (e)
18804
18808
  return Eu.get(e.trim().toLowerCase());
18805
18809
  }
18806
- function Jz(e) {
18810
+ function J5(e) {
18807
18811
  return Jd(e)?.name ?? null;
18808
18812
  }
18809
- function Qz() {
18813
+ function Q5() {
18810
18814
  return [...new Set([...Eu.values()].map((e) => e.name))].sort();
18811
18815
  }
18812
18816
  const Fh = Zn({
@@ -18832,10 +18836,10 @@ const Fh = Zn({
18832
18836
  },
18833
18837
  close() {
18834
18838
  }
18835
- }), e5(e, n);
18839
+ }), ez(e, n);
18836
18840
  }
18837
18841
  });
18838
- function e5(e, t) {
18842
+ function ez(e, t) {
18839
18843
  t.sort((s, i) => s.start - i.start || s.end - i.end);
18840
18844
  const n = [];
18841
18845
  let r = 0;
@@ -18937,13 +18941,13 @@ const tb = /* @__PURE__ */ k.forwardRef(function(t, n) {
18937
18941
  process.env.NODE_ENV !== "production" && (tb.displayName = "DialogDescription");
18938
18942
  const nb = /* @__PURE__ */ k.createContext(void 0);
18939
18943
  process.env.NODE_ENV !== "production" && (nb.displayName = "DialogPortalContext");
18940
- function t5() {
18944
+ function tz() {
18941
18945
  const e = k.useContext(nb);
18942
18946
  if (e === void 0)
18943
18947
  throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: <Dialog.Portal> is missing." : rt(26));
18944
18948
  return e;
18945
18949
  }
18946
- const n5 = {
18950
+ const nz = {
18947
18951
  ...Bs,
18948
18952
  ...In,
18949
18953
  nestedDialogOpen(e) {
@@ -18960,7 +18964,7 @@ const n5 = {
18960
18964
  initialFocus: a,
18961
18965
  ...l
18962
18966
  } = t, c = os(), d = c.useState("descriptionElementId"), f = c.useState("disablePointerDismissal"), p = c.useState("floatingRootContext"), h = c.useState("popupProps"), m = c.useState("modal"), g = c.useState("mounted"), b = c.useState("nested"), x = c.useState("nestedOpenDialogCount"), v = c.useState("open"), y = c.useState("openMethod"), w = c.useState("titleElementId"), C = c.useState("transitionStatus"), S = c.useState("role"), R = p.useState("floatingId");
18963
- t5(), an({
18967
+ tz(), an({
18964
18968
  open: v,
18965
18969
  ref: c.context.popupRef,
18966
18970
  onComplete() {
@@ -18989,7 +18993,7 @@ const n5 = {
18989
18993
  }
18990
18994
  }, l],
18991
18995
  ref: [n, c.context.popupRef, I],
18992
- stateAttributesMapping: n5
18996
+ stateAttributesMapping: nz
18993
18997
  });
18994
18998
  return /* @__PURE__ */ u(cl, {
18995
18999
  context: p,
@@ -19022,7 +19026,7 @@ const xl = /* @__PURE__ */ k.forwardRef(function(t, n) {
19022
19026
  }) : null;
19023
19027
  });
19024
19028
  process.env.NODE_ENV !== "production" && (xl.displayName = "DialogPortal");
19025
- function r5({
19029
+ function rz({
19026
19030
  store: e,
19027
19031
  parentContext: t,
19028
19032
  isDrawer: n
@@ -19072,7 +19076,7 @@ function r5({
19072
19076
  nestedOpenDrawerCount: d
19073
19077
  }), null;
19074
19078
  }
19075
- const o5 = {
19079
+ const oz = {
19076
19080
  ...$d,
19077
19081
  modal: (e) => e.modal,
19078
19082
  nested: (e) => e.nested,
@@ -19085,10 +19089,10 @@ const o5 = {
19085
19089
  viewportElement: (e) => e.viewportElement,
19086
19090
  role: (e) => e.role
19087
19091
  };
19088
- class s5 extends Vs {
19092
+ class sz extends Vs {
19089
19093
  constructor(t, n, r) {
19090
- const o = new Li(), s = i5(t, o, n, r);
19091
- super(s, a5(o), o5);
19094
+ const o = new Li(), s = iz(t, o, n, r);
19095
+ super(s, az(o), oz);
19092
19096
  }
19093
19097
  setOpen = (t, n) => {
19094
19098
  if (n.preventUnmountOnClose = () => {
@@ -19102,7 +19106,7 @@ class s5 extends Vs {
19102
19106
  Td(r, t, n.trigger), this.update(r);
19103
19107
  };
19104
19108
  }
19105
- function i5(e, t, n, r = !1) {
19109
+ function iz(e, t, n, r = !1) {
19106
19110
  const o = {
19107
19111
  ..._d(),
19108
19112
  modal: !0,
@@ -19119,7 +19123,7 @@ function i5(e, t, n, r = !1) {
19119
19123
  };
19120
19124
  return o.floatingRootContext = wg(t, n, r), o;
19121
19125
  }
19122
- function a5(e) {
19126
+ function az(e) {
19123
19127
  return {
19124
19128
  popupRef: /* @__PURE__ */ k.createRef(),
19125
19129
  backdropRef: /* @__PURE__ */ k.createRef(),
@@ -19150,7 +19154,7 @@ function ME(e, t) {
19150
19154
  disablePointerDismissal: b,
19151
19155
  nested: y,
19152
19156
  role: x
19153
- }, C = xg((A, D) => new s5({
19157
+ }, C = xg((A, D) => new sz({
19154
19158
  open: o,
19155
19159
  openProp: r,
19156
19160
  activeTriggerId: p,
@@ -19173,7 +19177,7 @@ function ME(e, t) {
19173
19177
  children: [d && /* @__PURE__ */ u(Md, {
19174
19178
  handle: d,
19175
19179
  store: C
19176
- }), I && /* @__PURE__ */ u(r5, {
19180
+ }), I && /* @__PURE__ */ u(rz, {
19177
19181
  store: C,
19178
19182
  parentContext: v?.context,
19179
19183
  isDrawer: h
@@ -19246,10 +19250,10 @@ const Qd = /* @__PURE__ */ k.forwardRef(function(t, n) {
19246
19250
  });
19247
19251
  });
19248
19252
  process.env.NODE_ENV !== "production" && (Qd.displayName = "DialogTrigger");
19249
- function l5(e) {
19253
+ function lz(e) {
19250
19254
  return ME("alert-dialog", e);
19251
19255
  }
19252
- const c5 = Qd;
19256
+ const cz = Qd;
19253
19257
  function TE(e) {
19254
19258
  const t = xe(null), n = xe(!1);
19255
19259
  return Qt(() => {
@@ -19432,12 +19436,12 @@ function ss({
19432
19436
  if (f === "")
19433
19437
  throw new Error("AlertDialog: confirmText must be a non-empty string (an empty phrase would make type-to-confirm a no-op).");
19434
19438
  const m = OE({ size: "sm" }), g = TE(t), b = PE(t, n);
19435
- return /* @__PURE__ */ M(l5, { open: t, onOpenChange: b, children: [
19436
- e && /* @__PURE__ */ u(c5, { render: e }),
19439
+ return /* @__PURE__ */ M(lz, { open: t, onOpenChange: b, children: [
19440
+ e && /* @__PURE__ */ u(cz, { render: e }),
19437
19441
  /* @__PURE__ */ M(xl, { children: [
19438
19442
  /* @__PURE__ */ u(gl, { className: m.backdrop() }),
19439
19443
  /* @__PURE__ */ u(vl, { ref: h, className: H(m.popup(), p), finalFocus: g, children: /* @__PURE__ */ u(
19440
- f5,
19444
+ fz,
19441
19445
  {
19442
19446
  s: m,
19443
19447
  title: r,
@@ -19454,11 +19458,11 @@ function ss({
19454
19458
  ] })
19455
19459
  ] });
19456
19460
  }
19457
- const u5 = (e) => /* @__PURE__ */ u("strong", { className: "font-mono font-semibold text-primary", children: e });
19458
- function d5({ phrase: e }) {
19459
- return /* @__PURE__ */ u(We, { children: he().dialog.typeToConfirm(e, u5) });
19461
+ const uz = (e) => /* @__PURE__ */ u("strong", { className: "font-mono font-semibold text-primary", children: e });
19462
+ function dz({ phrase: e }) {
19463
+ return /* @__PURE__ */ u(We, { children: he().dialog.typeToConfirm(e, uz) });
19460
19464
  }
19461
- function f5({
19465
+ function fz({
19462
19466
  s: e,
19463
19467
  title: t,
19464
19468
  description: n,
@@ -19482,7 +19486,7 @@ function f5({
19482
19486
  vt,
19483
19487
  {
19484
19488
  className: "mt-4",
19485
- label: /* @__PURE__ */ u(d5, { phrase: c }),
19489
+ label: /* @__PURE__ */ u(dz, { phrase: c }),
19486
19490
  children: /* @__PURE__ */ u(
19487
19491
  Dt,
19488
19492
  {
@@ -19519,9 +19523,9 @@ function AE({ title: e, children: t }) {
19519
19523
  return e ? /* @__PURE__ */ u(Gt, { content: e, children: t }) : t;
19520
19524
  }
19521
19525
  function wl({ nodes: e, renderCode: t }) {
19522
- return e.map((n, r) => /* @__PURE__ */ u(h5, { node: n, renderCode: t }, r));
19526
+ return e.map((n, r) => /* @__PURE__ */ u(hz, { node: n, renderCode: t }, r));
19523
19527
  }
19524
- const p5 = {
19528
+ const pz = {
19525
19529
  1: "text-xl",
19526
19530
  2: "text-lg",
19527
19531
  3: "text-base",
@@ -19529,7 +19533,7 @@ const p5 = {
19529
19533
  5: "text-sm",
19530
19534
  6: "text-xs uppercase tracking-wide text-secondary"
19531
19535
  };
19532
- function h5({ node: e, renderCode: t }) {
19536
+ function hz({ node: e, renderCode: t }) {
19533
19537
  switch (e.kind) {
19534
19538
  case "heading": {
19535
19539
  const n = `h${e.level}`;
@@ -19539,7 +19543,7 @@ function h5({ node: e, renderCode: t }) {
19539
19543
  id: e.id,
19540
19544
  className: H(
19541
19545
  "mt-4 mb-1 scroll-mt-4 font-display font-semibold text-primary first:mt-0",
19542
- p5[e.level]
19546
+ pz[e.level]
19543
19547
  ),
19544
19548
  children: /* @__PURE__ */ u(Fr, { nodes: e.children })
19545
19549
  }
@@ -19559,14 +19563,14 @@ function h5({ node: e, renderCode: t }) {
19559
19563
  case "rule":
19560
19564
  return /* @__PURE__ */ u("hr", { className: "my-3 border-0 border-t border-border-subtle" });
19561
19565
  case "list":
19562
- return /* @__PURE__ */ u(m5, { node: e, renderCode: t });
19566
+ return /* @__PURE__ */ u(mz, { node: e, renderCode: t });
19563
19567
  case "table":
19564
- return /* @__PURE__ */ u(b5, { node: e });
19568
+ return /* @__PURE__ */ u(bz, { node: e });
19565
19569
  case "footnotes":
19566
- return /* @__PURE__ */ u(v5, { node: e, renderCode: t });
19570
+ return /* @__PURE__ */ u(vz, { node: e, renderCode: t });
19567
19571
  }
19568
19572
  }
19569
- function m5({
19573
+ function mz({
19570
19574
  node: e,
19571
19575
  renderCode: t
19572
19576
  }) {
@@ -19582,11 +19586,11 @@ function m5({
19582
19586
  two bullets, one of which does nothing. */
19583
19587
  r ? "list-none pl-1" : e.ordered ? "list-decimal" : "list-disc"
19584
19588
  ),
19585
- children: e.items.map((o, s) => /* @__PURE__ */ u(g5, { item: o, tight: e.tight, renderCode: t }, s))
19589
+ children: e.items.map((o, s) => /* @__PURE__ */ u(gz, { item: o, tight: e.tight, renderCode: t }, s))
19586
19590
  }
19587
19591
  );
19588
19592
  }
19589
- function g5({
19593
+ function gz({
19590
19594
  item: e,
19591
19595
  tight: t,
19592
19596
  renderCode: n
@@ -19612,7 +19616,7 @@ const Bw = {
19612
19616
  center: "text-center",
19613
19617
  right: "text-right"
19614
19618
  };
19615
- function b5({ node: e }) {
19619
+ function bz({ node: e }) {
19616
19620
  const t = he().markdownRender;
19617
19621
  return (
19618
19622
  /* Focusable because it scrolls sideways. A region that can only be panned
@@ -19654,7 +19658,7 @@ function b5({ node: e }) {
19654
19658
  )
19655
19659
  );
19656
19660
  }
19657
- function v5({
19661
+ function vz({
19658
19662
  node: e,
19659
19663
  renderCode: t
19660
19664
  }) {
@@ -19665,16 +19669,16 @@ function v5({
19665
19669
  /* @__PURE__ */ u("a", { href: `#${_E(r.label)}`, "aria-label": n.backToReference, className: "text-accent-text", children: "↩" })
19666
19670
  ] }, r.label)) }) });
19667
19671
  }
19668
- const DE = (e) => `fn-${e}`, _E = (e) => `fnref-${e}`, x5 = "rounded-[4px] border border-border-subtle bg-surface-inset px-1 py-px font-mono text-[0.88em] text-primary", Hw = "text-accent-text underline decoration-accent-border underline-offset-2 transition-colors duration-(--dur-fast) hover:decoration-accent";
19672
+ const DE = (e) => `fn-${e}`, _E = (e) => `fnref-${e}`, xz = "rounded-[4px] border border-border-subtle bg-surface-inset px-1 py-px font-mono text-[0.88em] text-primary", Hw = "text-accent-text underline decoration-accent-border underline-offset-2 transition-colors duration-(--dur-fast) hover:decoration-accent";
19669
19673
  function Fr({ nodes: e }) {
19670
- return e.map((t, n) => /* @__PURE__ */ u(y5, { node: t }, n));
19674
+ return e.map((t, n) => /* @__PURE__ */ u(yz, { node: t }, n));
19671
19675
  }
19672
- function y5({ node: e }) {
19676
+ function yz({ node: e }) {
19673
19677
  switch (e.kind) {
19674
19678
  case "text":
19675
19679
  return /* @__PURE__ */ u(We, { children: e.value });
19676
19680
  case "code":
19677
- return /* @__PURE__ */ u("code", { className: x5, children: e.value });
19681
+ return /* @__PURE__ */ u("code", { className: xz, children: e.value });
19678
19682
  case "emphasis":
19679
19683
  return /* @__PURE__ */ u("em", { children: /* @__PURE__ */ u(Fr, { nodes: e.children }) });
19680
19684
  case "strong":
@@ -19687,7 +19691,7 @@ function y5({ node: e }) {
19687
19691
  return /* @__PURE__ */ u("sup", { id: _E(e.label), children: /* @__PURE__ */ u("a", { href: `#${DE(e.label)}`, className: Hw, children: e.label }) });
19688
19692
  case "image": {
19689
19693
  const t = Nu(e.src);
19690
- return t ? /* @__PURE__ */ u(w5, { src: t, alt: e.alt, title: e.title }) : /* @__PURE__ */ u("span", { className: "text-tertiary italic", children: e.alt });
19694
+ return t ? /* @__PURE__ */ u(wz, { src: t, alt: e.alt, title: e.title }) : /* @__PURE__ */ u("span", { className: "text-tertiary italic", children: e.alt });
19691
19695
  }
19692
19696
  case "link": {
19693
19697
  const t = Nu(e.href);
@@ -19707,7 +19711,7 @@ function y5({ node: e }) {
19707
19711
  }
19708
19712
  }
19709
19713
  }
19710
- function w5({ src: e, alt: t, title: n }) {
19714
+ function wz({ src: e, alt: t, title: n }) {
19711
19715
  const r = he().markdownRender, [o, s] = ne(!1);
19712
19716
  return /* @__PURE__ */ M(We, { children: [
19713
19717
  /* @__PURE__ */ u(AE, { title: n, children: /* @__PURE__ */ u(
@@ -19728,7 +19732,7 @@ function Nu(e) {
19728
19732
  const n = e.trim().replace(/[\u0000-\u0020]/g, "");
19729
19733
  return /^[a-z][a-z0-9+.-]*:/i.test(n) ? /^(https?|mailto|tel|ftp):/i.test(n) ? n : null : n;
19730
19734
  }
19731
- const ks = { "(": ")", "[": "]", "{": "}" }, Vh = /* @__PURE__ */ new Set(['"', "'", "`"]), k5 = /* @__PURE__ */ new Set([")", "]", "}"]), Uw = /[\p{L}\p{N}_$]/u;
19735
+ const ks = { "(": ")", "[": "]", "{": "}" }, Vh = /* @__PURE__ */ new Set(['"', "'", "`"]), kz = /* @__PURE__ */ new Set([")", "]", "}"]), Uw = /[\p{L}\p{N}_$]/u;
19732
19736
  function Ci(e, t, n, r, o) {
19733
19737
  e.focus(), e.setSelectionRange(t, n);
19734
19738
  let s = !1;
@@ -19747,23 +19751,23 @@ function $E(e, t) {
19747
19751
  return e.lastIndexOf(`
19748
19752
  `, t - 1) + 1;
19749
19753
  }
19750
- function C5(e, t) {
19754
+ function Cz(e, t) {
19751
19755
  const n = e.indexOf(`
19752
19756
  `, t);
19753
19757
  return n < 0 ? e.length : n;
19754
19758
  }
19755
- function S5(e, t) {
19759
+ function Sz(e, t) {
19756
19760
  const n = $E(e, t);
19757
19761
  return /^[ \t]*/.exec(e.slice(n, t))?.[0] ?? "";
19758
19762
  }
19759
- function E5(e, t, n) {
19763
+ function Ez(e, t, n) {
19760
19764
  const r = e.value, { selectionStart: o, selectionEnd: s } = e;
19761
19765
  if (!r.slice(o, s).includes(`
19762
19766
  `) && !n) {
19763
19767
  Ci(e, o, s, t, [o + t.length, o + t.length]);
19764
19768
  return;
19765
19769
  }
19766
- const a = $E(r, o), l = C5(r, s), c = r.slice(a, l).split(`
19770
+ const a = $E(r, o), l = Cz(r, s), c = r.slice(a, l).split(`
19767
19771
  `);
19768
19772
  let d = 0, f = 0;
19769
19773
  const p = c.map((h, m) => {
@@ -19781,21 +19785,21 @@ function E5(e, t, n) {
19781
19785
  Math.max(a, s + f)
19782
19786
  ]);
19783
19787
  }
19784
- function N5(e, t) {
19785
- const n = e.value, { selectionStart: r, selectionEnd: o } = e, s = S5(n, r), i = r > 0 ? n[r - 1] : "", a = o < n.length ? n[o] : "", l = i in ks, c = l ? `
19788
+ function Nz(e, t) {
19789
+ const n = e.value, { selectionStart: r, selectionEnd: o } = e, s = Sz(n, r), i = r > 0 ? n[r - 1] : "", a = o < n.length ? n[o] : "", l = i in ks, c = l ? `
19786
19790
  ${s}${t}` : `
19787
19791
  ${s}`, d = l && ks[i] === a ? `
19788
19792
  ${s}` : "", f = r + c.length;
19789
19793
  Ci(e, r, o, c + d, [f, f]);
19790
19794
  }
19791
- function R5(e, t) {
19795
+ function Rz(e, t) {
19792
19796
  const n = e.value, { selectionStart: r, selectionEnd: o } = e, s = t in ks, i = Vh.has(t);
19793
19797
  if (r !== o && (s || i)) {
19794
19798
  const c = i ? t : ks[t];
19795
19799
  return Ci(e, r, o, t + n.slice(r, o) + c, [r + 1, o + 1]), !0;
19796
19800
  }
19797
19801
  const a = o < n.length ? n[o] : "";
19798
- if ((k5.has(t) || i) && a === t)
19802
+ if ((kz.has(t) || i) && a === t)
19799
19803
  return e.setSelectionRange(o + 1, o + 1), !0;
19800
19804
  if (!s && !i || a && Uw.test(a)) return !1;
19801
19805
  if (i) {
@@ -19805,13 +19809,13 @@ function R5(e, t) {
19805
19809
  const l = i ? t : ks[t];
19806
19810
  return Ci(e, r, o, t + l, [r + 1, r + 1]), !0;
19807
19811
  }
19808
- function I5(e) {
19812
+ function Iz(e) {
19809
19813
  const { selectionStart: t, selectionEnd: n } = e;
19810
19814
  if (t !== n || t === 0) return !1;
19811
19815
  const r = e.value[t - 1], o = n < e.value.length ? e.value[n] : "", s = r in ks ? ks[r] : Vh.has(r) ? r : "";
19812
19816
  return !s || o !== s ? !1 : (Ci(e, t - 1, n + 1, "", [t - 1, t - 1]), !0);
19813
19817
  }
19814
- const LE = Rn(null), M5 = LE.Provider;
19818
+ const LE = Rn(null), Mz = LE.Provider;
19815
19819
  function kl(e) {
19816
19820
  const t = gn(LE);
19817
19821
  if (!t)
@@ -19821,11 +19825,11 @@ function kl(e) {
19821
19825
  function FE(e) {
19822
19826
  return e.trim().split(/\s+/).sort((t, n) => n.length - t.length).join("|");
19823
19827
  }
19824
- const T5 = FE(`
19828
+ const Tz = FE(`
19825
19829
  alias break case continue declare do done elif else esac eval exec exit export
19826
19830
  fi for function if in local readonly return select set shift source then time
19827
19831
  trap typeset unset until while
19828
- `), P5 = FE(`
19832
+ `), Pz = FE(`
19829
19833
  awk basename cat cd chmod chown cp curl cut date dirname docker echo env find
19830
19834
  git grep head jq kill ln ls make mkdir mv npm printf ps pwd read rm rmdir sed
19831
19835
  seq sleep sort ssh sudo tail tar tee test touch tr uname uniq wc wget which
@@ -19852,8 +19856,8 @@ function kp() {
19852
19856
  { match: /"/, token: "string", push: "dqString" },
19853
19857
  { match: /'/, token: "string", push: "sqString" },
19854
19858
  { match: /`/, token: "punctuation", push: "backtick" },
19855
- { match: new RegExp(`\\b(?:${T5})\\b`), token: "keyword" },
19856
- { match: new RegExp(`(?<![\\w./-])(?:${P5})(?![\\w./-])`), token: "function" },
19859
+ { match: new RegExp(`\\b(?:${Tz})\\b`), token: "keyword" },
19860
+ { match: new RegExp(`(?<![\\w./-])(?:${Pz})(?![\\w./-])`), token: "function" },
19857
19861
  /* Flags are named switches on a command — the same role an attribute plays
19858
19862
  on a tag, which is the closest honest category in the closed set. */
19859
19863
  { match: new RegExp("(?<=\\s)--?[A-Za-z][\\w-]*"), token: "attribute" },
@@ -19864,7 +19868,7 @@ function kp() {
19864
19868
  { match: /[(){}]/, token: "punctuation" }
19865
19869
  ];
19866
19870
  }
19867
- const O5 = Zn({
19871
+ const Oz = Zn({
19868
19872
  name: "bash",
19869
19873
  aliases: ["sh", "shell", "zsh", "ksh", "shellscript"],
19870
19874
  states: {
@@ -19890,7 +19894,7 @@ const O5 = Zn({
19890
19894
  ]
19891
19895
  }
19892
19896
  });
19893
- function A5() {
19897
+ function Az() {
19894
19898
  return [
19895
19899
  { match: /--[\w-]+/, token: "variable" },
19896
19900
  { match: /[$@][\w-]+/, token: "variable" },
@@ -19915,7 +19919,7 @@ function jw() {
19915
19919
  { match: /\/\/[^\n]*/, token: "comment" }
19916
19920
  ];
19917
19921
  }
19918
- const D5 = Zn({
19922
+ const Dz = Zn({
19919
19923
  name: "css",
19920
19924
  aliases: ["scss", "sass", "less", "postcss", "pcss"],
19921
19925
  states: {
@@ -19950,7 +19954,7 @@ const D5 = Zn({
19950
19954
  { match: /@[\w-]+(?=[\s({;])/, token: "atrule" },
19951
19955
  { match: /--[\w-]+(?=\s*:)/, token: "property" },
19952
19956
  { match: /-?[A-Za-z_][\w-]*(?=\s*:)/, token: "property" },
19953
- ...A5()
19957
+ ...Az()
19954
19958
  ],
19955
19959
  dqString: [
19956
19960
  { match: /\\[^]/, token: "escape" },
@@ -19970,14 +19974,14 @@ function Ru(e, t) {
19970
19974
  const n = new RegExp(`\\b${t}\\s*=\\s*("[^"]*"|'[^']*'|[^\\s>]+)`, "i").exec(e);
19971
19975
  return n ? n[1].replace(/^["']|["']$/g, "").trim() : null;
19972
19976
  }
19973
- function _5(e) {
19977
+ function _z(e) {
19974
19978
  const t = Ru(e, "lang")?.toLowerCase();
19975
19979
  if (t)
19976
19980
  return t === "ts" || t === "typescript" ? "typescript" : t === "tsx" ? "tsx" : t === "jsx" ? "jsx" : "javascript";
19977
19981
  const n = Ru(e, "type")?.toLowerCase() ?? "";
19978
19982
  return n.includes("typescript") ? "typescript" : n.includes("json") || n === "importmap" || n === "speculationrules" ? "json" : "javascript";
19979
19983
  }
19980
- function $5(e) {
19984
+ function $z(e) {
19981
19985
  const t = Ru(e, "lang")?.toLowerCase();
19982
19986
  return t === "scss" || t === "sass" ? "scss" : t === "less" ? "less" : "css";
19983
19987
  }
@@ -20014,20 +20018,20 @@ function zE(e, t) {
20014
20018
  {
20015
20019
  match: /(<script)(?=[\s/>])((?:"[^"]*"|'[^']*'|[^>"'])*)(>)/i,
20016
20020
  groups: ["tag", "attribute", "tag"],
20017
- embed: (n) => _5(n[2]),
20021
+ embed: (n) => _z(n[2]),
20018
20022
  until: e,
20019
20023
  untilToken: "tag"
20020
20024
  },
20021
20025
  {
20022
20026
  match: /(<style)(?=[\s/>])((?:"[^"]*"|'[^']*'|[^>"'])*)(>)/i,
20023
20027
  groups: ["tag", "attribute", "tag"],
20024
- embed: (n) => $5(n[2]),
20028
+ embed: (n) => $z(n[2]),
20025
20029
  until: t,
20026
20030
  untilToken: "tag"
20027
20031
  }
20028
20032
  ];
20029
20033
  }
20030
- const L5 = Zn({
20034
+ const Lz = Zn({
20031
20035
  name: "html",
20032
20036
  aliases: ["htm", "xml", "svg"],
20033
20037
  states: {
@@ -20055,11 +20059,11 @@ const Gw = ob(`
20055
20059
  do else export extends finally for from function get if import in instanceof
20056
20060
  let new of return set static super switch this throw try typeof var void
20057
20061
  while with yield
20058
- `), F5 = ob(`
20062
+ `), Fz = ob(`
20059
20063
  abstract accessor asserts declare enum global implements infer interface is
20060
20064
  keyof module namespace out override private protected public readonly require
20061
20065
  satisfies type unique
20062
- `), V5 = ob("any bigint boolean never number object string symbol unknown");
20066
+ `), Vz = ob("any bigint boolean never number object string symbol unknown");
20063
20067
  function Cl(e, t = []) {
20064
20068
  const n = [
20065
20069
  ...t,
@@ -20089,9 +20093,9 @@ function Cl(e, t = []) {
20089
20093
  happily end a keyword at `for$` and colour half an identifier. */
20090
20094
  { match: /\b(?:true|false)(?![\w$])/, token: "boolean" },
20091
20095
  { match: /\b(?:null|undefined)(?![\w$])/, token: "null" },
20092
- ...e.ts ? [{ match: new RegExp(`\\b(?:${V5})(?![\\w$])`), token: "type" }] : [],
20096
+ ...e.ts ? [{ match: new RegExp(`\\b(?:${Vz})(?![\\w$])`), token: "type" }] : [],
20093
20097
  {
20094
- match: new RegExp(`\\b(?:${e.ts ? `${Gw}|${F5}` : Gw})(?![\\w$])`),
20098
+ match: new RegExp(`\\b(?:${e.ts ? `${Gw}|${Fz}` : Gw})(?![\\w$])`),
20095
20099
  token: "keyword"
20096
20100
  },
20097
20101
  /* Decorators read as annotations, which is what `attribute` is for — the
@@ -20156,21 +20160,21 @@ function Cl(e, t = []) {
20156
20160
  { match: /\s+/, token: "text" }
20157
20161
  ]), s;
20158
20162
  }
20159
- const z5 = Zn({
20163
+ const zz = Zn({
20160
20164
  name: "javascript",
20161
20165
  aliases: ["js", "mjs", "cjs", "node"],
20162
20166
  states: Cl({ ts: !1, jsx: !1 })
20163
- }), B5 = Zn({
20167
+ }), Bz = Zn({
20164
20168
  name: "typescript",
20165
20169
  aliases: ["ts", "mts", "cts"],
20166
20170
  states: Cl({ ts: !0, jsx: !1 })
20167
- }), H5 = Zn({
20171
+ }), Hz = Zn({
20168
20172
  name: "jsx",
20169
20173
  states: Cl({ ts: !1, jsx: !0 })
20170
- }), U5 = Zn({
20174
+ }), Uz = Zn({
20171
20175
  name: "tsx",
20172
20176
  states: Cl({ ts: !0, jsx: !0 })
20173
- }), j5 = Zn({
20177
+ }), jz = Zn({
20174
20178
  name: "json",
20175
20179
  aliases: ["jsonc", "json5"],
20176
20180
  states: {
@@ -20209,7 +20213,7 @@ const z5 = Zn({
20209
20213
  { match: /\n/, token: "text", pop: !0 }
20210
20214
  ]
20211
20215
  }
20212
- }), G5 = Zn({
20216
+ }), Gz = Zn({
20213
20217
  name: "mongodb",
20214
20218
  aliases: ["mongo", "nosql"],
20215
20219
  states: Cl({ ts: !1, jsx: !1 }, [
@@ -20226,7 +20230,7 @@ const z5 = Zn({
20226
20230
  },
20227
20231
  { match: /\b(?:db|rs|sh|use)(?![\w$])/, token: "keyword" }
20228
20232
  ])
20229
- }), W5 = Zn({
20233
+ }), Wz = Zn({
20230
20234
  name: "plain",
20231
20235
  aliases: ["text", "txt", "plaintext", "none"],
20232
20236
  states: { root: [{ match: /[^]+/, token: "text" }] }
@@ -20246,17 +20250,17 @@ const Ww = ef(`
20246
20250
  revoke right rollback row rows savepoint schema select set show some table
20247
20251
  temporary then to transaction trigger truncate union unique unlock update
20248
20252
  usage use using vacuum values view when where while window with within
20249
- `), q5 = ef(`
20253
+ `), qz = ef(`
20250
20254
  array bigint binary bit blob bool boolean bytea char character clob date
20251
20255
  datetime decimal double float inet int int2 int4 int8 integer interval json
20252
20256
  jsonb longtext mediumint money numeric real serial smallint text time
20253
20257
  timestamp timestamptz tinyint uuid varbinary varchar xml year
20254
- `), K5 = ef(`
20258
+ `), Kz = ef(`
20255
20259
  auto_increment binlog change charset collation columns databases delayed
20256
20260
  describe engine fields fulltext high_priority keys kill low_priority modify
20257
20261
  optimize privileges processlist repair spatial straight_join tables unsigned
20258
20262
  variables warnings zerofill
20259
- `), Y5 = ef(`
20263
+ `), Yz = ef(`
20260
20264
  analyse concurrently conflict deferrable ilike immediate initially isnull
20261
20265
  materialized notnull nowait owned reindex reset returns similar tablespace
20262
20266
  unlogged variadic verbose
@@ -20282,7 +20286,7 @@ function sb(e) {
20282
20286
  { match: /\b\d+(?:\.\d*)?(?:[eE][+-]?\d+)?\b|\B\.\d+\b/, token: "number" },
20283
20287
  { match: /\bnull\b/i, token: "null" },
20284
20288
  { match: /\b(?:true|false)\b/i, token: "boolean" },
20285
- { match: new RegExp(`\\b(?:${q5})\\b`, "i"), token: "type" },
20289
+ { match: new RegExp(`\\b(?:${qz})\\b`, "i"), token: "type" },
20286
20290
  { match: new RegExp(`\\b(?:${t})\\b`, "i"), token: "keyword" },
20287
20291
  { match: /[A-Za-z_][\w$]*(?=\s*\()/, token: "function" },
20288
20292
  { match: new RegExp("(?<=\\.)[A-Za-z_][\\w$]*"), token: "property" },
@@ -20318,30 +20322,30 @@ function sb(e) {
20318
20322
  }
20319
20323
  });
20320
20324
  }
20321
- const X5 = sb({
20325
+ const Xz = sb({
20322
20326
  name: "sql",
20323
20327
  aliases: ["sqlite"],
20324
20328
  mysql: !1,
20325
20329
  postgres: !1,
20326
20330
  extra: ""
20327
- }), Z5 = sb({
20331
+ }), Zz = sb({
20328
20332
  name: "mysql",
20329
20333
  aliases: ["mariadb"],
20330
20334
  mysql: !0,
20331
20335
  postgres: !1,
20332
- extra: K5
20333
- }), J5 = sb({
20336
+ extra: Kz
20337
+ }), Jz = sb({
20334
20338
  name: "postgresql",
20335
20339
  aliases: ["postgres", "pgsql"],
20336
20340
  mysql: !1,
20337
20341
  postgres: !0,
20338
- extra: Y5
20342
+ extra: Yz
20339
20343
  });
20340
- function Q5(e) {
20344
+ function Qz(e) {
20341
20345
  const t = Ru(e, "lang")?.toLowerCase();
20342
20346
  return t && t !== "html" ? t : "html";
20343
20347
  }
20344
- const e4 = Zn({
20348
+ const e3 = Zn({
20345
20349
  name: "vue",
20346
20350
  states: {
20347
20351
  root: [
@@ -20350,7 +20354,7 @@ const e4 = Zn({
20350
20354
  {
20351
20355
  match: /(<template)(?=[\s/>])((?:"[^"]*"|'[^']*'|[^>"'])*)(>)/i,
20352
20356
  groups: ["tag", "attribute", "tag"],
20353
- embed: (e) => Q5(e[2]),
20357
+ embed: (e) => Qz(e[2]),
20354
20358
  until: /^<\/template\s*>/m,
20355
20359
  untilToken: "tag"
20356
20360
  },
@@ -20361,7 +20365,7 @@ const e4 = Zn({
20361
20365
  ],
20362
20366
  ...VE()
20363
20367
  }
20364
- }), t4 = Zn({
20368
+ }), t3 = Zn({
20365
20369
  name: "yaml",
20366
20370
  aliases: ["yml"],
20367
20371
  states: {
@@ -20410,43 +20414,43 @@ const e4 = Zn({
20410
20414
  { match: /\n/, token: "text", pop: !0 }
20411
20415
  ]
20412
20416
  }
20413
- }), n4 = [
20414
- W5,
20415
- j5,
20416
- t4,
20417
+ }), n3 = [
20418
+ Wz,
20419
+ jz,
20420
+ t3,
20417
20421
  Fh,
20418
- z5,
20419
- B5,
20420
- H5,
20421
- U5,
20422
- L5,
20423
- D5,
20424
- X5,
20425
- Z5,
20426
- J5,
20427
- G5,
20428
- O5,
20429
- e4
20430
- ], r4 = 12;
20431
- function o4(e, t) {
20422
+ zz,
20423
+ Bz,
20424
+ Hz,
20425
+ Uz,
20426
+ Lz,
20427
+ Dz,
20428
+ Xz,
20429
+ Zz,
20430
+ Jz,
20431
+ Gz,
20432
+ Oz,
20433
+ e3
20434
+ ], r3 = 12;
20435
+ function o3(e, t) {
20432
20436
  return ib(e, Jd(t), 0, 0);
20433
20437
  }
20434
20438
  function ib(e, t, n, r) {
20435
20439
  if (!e) return [];
20436
- if (!t || r > r4)
20440
+ if (!t || r > r3)
20437
20441
  return [{ start: n, end: n + e.length, type: "text", lang: t?.name ?? "text" }];
20438
20442
  if (t.tokenize) {
20439
20443
  const o = {
20440
20444
  sub: (s, i, a) => ib(s, Jd(i), a, r + 1)
20441
20445
  };
20442
- return s4(t.tokenize(e, o), n);
20446
+ return s3(t.tokenize(e, o), n);
20443
20447
  }
20444
- return i4(e, t, n, r);
20448
+ return i3(e, t, n, r);
20445
20449
  }
20446
- function s4(e, t) {
20450
+ function s3(e, t) {
20447
20451
  return t === 0 ? e : e.map((n) => ({ ...n, start: n.start + t, end: n.end + t }));
20448
20452
  }
20449
- function i4(e, t, n, r) {
20453
+ function i3(e, t, n, r) {
20450
20454
  const o = [], s = ["root"];
20451
20455
  let i = 0, a = 0;
20452
20456
  const l = () => {
@@ -20462,7 +20466,7 @@ function i4(e, t, n, r) {
20462
20466
  if (!(!m || m.index !== i)) {
20463
20467
  if (m[0].length === 0)
20464
20468
  throw new Error(`${t.name}.${c}[${p}] matched empty at ${i}`);
20465
- l(), l4(o, m, h, n, t.name), i += m[0].length, h.embed ? i = a4(e, m, h, o, t, n, r, i) : h.push ? s.push(h.push) : h.pop && s.length > 1 && s.pop(), a = i, f = !0;
20469
+ l(), l3(o, m, h, n, t.name), i += m[0].length, h.embed ? i = a3(e, m, h, o, t, n, r, i) : h.push ? s.push(h.push) : h.pop && s.length > 1 && s.pop(), a = i, f = !0;
20466
20470
  break;
20467
20471
  }
20468
20472
  }
@@ -20470,7 +20474,7 @@ function i4(e, t, n, r) {
20470
20474
  }
20471
20475
  return i = e.length, l(), o;
20472
20476
  }
20473
- function a4(e, t, n, r, o, s, i, a) {
20477
+ function a3(e, t, n, r, o, s, i, a) {
20474
20478
  const l = typeof n.embed == "function" ? n.embed(t) : n.embed, c = n.until, d = new RegExp(c.source, c.flags.replace("y", "") + "g");
20475
20479
  d.lastIndex = a;
20476
20480
  const f = d.exec(e), p = f ? f.index : e.length, h = e.slice(a, p);
@@ -20480,7 +20484,7 @@ function a4(e, t, n, r, o, s, i, a) {
20480
20484
  }
20481
20485
  return f ? (hs(r, s + f.index, s + f.index + f[0].length, n.untilToken ?? "punctuation", o.name), f.index + f[0].length) : e.length;
20482
20486
  }
20483
- function l4(e, t, n, r, o) {
20487
+ function l3(e, t, n, r, o) {
20484
20488
  const s = t.index, i = s + t[0].length;
20485
20489
  if (n.token) {
20486
20490
  hs(e, r + s, r + i, n.token, o);
@@ -20521,25 +20525,25 @@ let qw = !1;
20521
20525
  function tf() {
20522
20526
  if (!qw) {
20523
20527
  qw = !0;
20524
- for (const e of n4) IE(e);
20528
+ for (const e of n3) IE(e);
20525
20529
  }
20526
20530
  }
20527
20531
  function BE(e, t) {
20528
- return tf(), o4(e, t);
20532
+ return tf(), o3(e, t);
20529
20533
  }
20530
- function c4() {
20531
- return tf(), Qz();
20534
+ function c3() {
20535
+ return tf(), Q5();
20532
20536
  }
20533
20537
  function uee(e) {
20534
- return tf(), Jz(e);
20538
+ return tf(), J5(e);
20535
20539
  }
20536
20540
  function dee(e) {
20537
20541
  tf(), IE(e);
20538
20542
  }
20539
- function u4(e, t) {
20543
+ function u3(e, t) {
20540
20544
  return Oe(() => BE(e, t), [e, t]);
20541
20545
  }
20542
- const d4 = fd(function({
20546
+ const d3 = fd(function({
20543
20547
  source: t,
20544
20548
  tokens: n
20545
20549
  }) {
@@ -20548,7 +20552,7 @@ const d4 = fd(function({
20548
20552
  `
20549
20553
  `
20550
20554
  ] });
20551
- }), f4 = fd(function({
20555
+ }), f3 = fd(function({
20552
20556
  count: t,
20553
20557
  from: n
20554
20558
  }) {
@@ -20624,7 +20628,7 @@ const d4 = fd(function({
20624
20628
  }
20625
20629
  }), ab = /* @__PURE__ */ k.createContext(void 0);
20626
20630
  process.env.NODE_ENV !== "production" && (ab.displayName = "ToggleGroupContext");
20627
- function p4() {
20631
+ function p3() {
20628
20632
  return k.useContext(ab);
20629
20633
  }
20630
20634
  const lb = /* @__PURE__ */ k.createContext({
@@ -20639,7 +20643,7 @@ const lb = /* @__PURE__ */ k.createContext({
20639
20643
  }
20640
20644
  });
20641
20645
  process.env.NODE_ENV !== "production" && (lb.displayName = "CompositeListContext");
20642
- function h4() {
20646
+ function h3() {
20643
20647
  return k.useContext(lb);
20644
20648
  }
20645
20649
  function Rr(e = {}) {
@@ -20654,7 +20658,7 @@ function Rr(e = {}) {
20654
20658
  unregister: a,
20655
20659
  subscribeMapChange: l,
20656
20660
  nextIndexRef: c
20657
- } = h4(), d = k.useRef(-1), [f, p] = k.useState(s == null && t ? () => {
20661
+ } = h3(), d = k.useRef(-1), [f, p] = k.useState(s == null && t ? () => {
20658
20662
  if (d.current === -1) {
20659
20663
  const b = c.current;
20660
20664
  c.current += 1, d.current = b;
@@ -20749,7 +20753,7 @@ const UE = /* @__PURE__ */ k.forwardRef(function(t, n) {
20749
20753
  nativeButton: p = !0,
20750
20754
  style: h,
20751
20755
  ...m
20752
- } = t, g = Nt(f || void 0), b = p4(), x = b?.value ?? [], v = b ? void 0 : o, y = (s || b?.disabled) ?? !1;
20756
+ } = t, g = Nt(f || void 0), b = p3(), x = b?.value ?? [], v = b ? void 0 : o, y = (s || b?.disabled) ?? !1;
20753
20757
  process.env.NODE_ENV !== "production" && k.useEffect(() => {
20754
20758
  b && f === void 0 && b.isValueInitialized && Os("A `<Toggle>` component rendered in a `<ToggleGroup>` has no explicit `value` prop.", "This will cause issues between the Toggle Group and Toggle values.", "Provide the `<Toggle>` with a `value` prop matching the `<ToggleGroup>` values prop type.");
20755
20759
  }, [b, f, b?.isValueInitialized]);
@@ -20800,7 +20804,7 @@ function xo(e) {
20800
20804
  elementsRef: n,
20801
20805
  labelsRef: r,
20802
20806
  onMapChange: o
20803
- } = e, s = Ce(o), [, i] = k.useState(!1), a = jt(g4).current, l = jt(m4).current, c = k.useRef(0), d = k.useRef(!0), f = k.useRef([]), p = k.useRef(null), h = Ce(() => {
20807
+ } = e, s = Ce(o), [, i] = k.useState(!1), a = jt(g3).current, l = jt(m3).current, c = k.useRef(0), d = k.useRef(!0), f = k.useRef([]), p = k.useRef(null), h = Ce(() => {
20804
20808
  d.current || (d.current = !0, i((C) => !C));
20805
20809
  }), m = Ce((C, S) => {
20806
20810
  l.set(C, S), h();
@@ -20819,7 +20823,7 @@ function xo(e) {
20819
20823
  if (p.current?.disconnect(), p.current = null, typeof MutationObserver != "function" || C.length < 2)
20820
20824
  return;
20821
20825
  const S = new MutationObserver((E) => {
20822
- if (!x4(E))
20826
+ if (!x3(E))
20823
20827
  return;
20824
20828
  let N = null;
20825
20829
  for (const I of C)
@@ -20834,7 +20838,7 @@ function xo(e) {
20834
20838
  p.current = S;
20835
20839
  const R = /* @__PURE__ */ new Set();
20836
20840
  for (let E = 1; E < C.length; E += 1) {
20837
- const N = v4(C[E - 1], C[E]);
20841
+ const N = v3(C[E - 1], C[E]);
20838
20842
  N && R.add(N);
20839
20843
  }
20840
20844
  R.forEach((E) => S.observe(E, {
@@ -20842,7 +20846,7 @@ function xo(e) {
20842
20846
  }));
20843
20847
  }
20844
20848
  const v = Ce(() => {
20845
- const [C, S] = b4(l), R = b(C);
20849
+ const [C, S] = b3(l), R = b(C);
20846
20850
  x(S), f.current = C, d.current = !1, a.forEach((E) => E(R)), s(R);
20847
20851
  });
20848
20852
  Ee(() => (d.current || b(f.current), () => {
@@ -20865,13 +20869,13 @@ function xo(e) {
20865
20869
  children: t
20866
20870
  });
20867
20871
  }
20868
- function m4() {
20872
+ function m3() {
20869
20873
  return /* @__PURE__ */ new Map();
20870
20874
  }
20871
- function g4() {
20875
+ function g3() {
20872
20876
  return /* @__PURE__ */ new Set();
20873
20877
  }
20874
- function b4(e) {
20878
+ function b3(e) {
20875
20879
  const t = /* @__PURE__ */ new Set(), n = [], r = [];
20876
20880
  e.forEach((s, i) => {
20877
20881
  if (!i.isConnected)
@@ -20890,13 +20894,13 @@ function b4(e) {
20890
20894
  s.index = o, n.push(s), o += 1;
20891
20895
  }), t.size > 0 && n.sort((s, i) => s.index - i.index), [n, r.map((s) => s.element)];
20892
20896
  }
20893
- function v4(e, t) {
20897
+ function v3(e, t) {
20894
20898
  let n = e.parentElement;
20895
20899
  for (; n && !n.contains(t); )
20896
20900
  n = n.parentElement;
20897
20901
  return n;
20898
20902
  }
20899
- function x4(e) {
20903
+ function x3(e) {
20900
20904
  for (const t of e)
20901
20905
  for (let n = 0; n < t.removedNodes.length; n += 1)
20902
20906
  if (t.removedNodes[n].isConnected)
@@ -20909,8 +20913,8 @@ function jE(e, t) {
20909
20913
  function GE(e) {
20910
20914
  return e == null || e.hasAttribute("disabled") || e.getAttribute("aria-disabled") === "true";
20911
20915
  }
20912
- const cb = "data-composite-item-active", y4 = [];
20913
- function w4(e) {
20916
+ const cb = "data-composite-item-active", y3 = [];
20917
+ function w3(e) {
20914
20918
  const {
20915
20919
  loopFocus: t = !0,
20916
20920
  orientation: n = "both",
@@ -20923,7 +20927,7 @@ function w4(e) {
20923
20927
  enableHomeAndEndKeys: c = !1,
20924
20928
  stopEventPropagation: d,
20925
20929
  disabledIndices: f,
20926
- modifierKeys: p = y4
20930
+ modifierKeys: p = y3
20927
20931
  } = e, [h, m] = k.useState(0), g = r != null, b = k.useRef(null), x = Sn(b, l), v = k.useRef([]), y = k.useRef(!1), w = i ?? h, C = Ce((I, A = !1) => {
20928
20932
  if ((a ?? m)(I), A) {
20929
20933
  const D = v.current[I];
@@ -20957,7 +20961,7 @@ function w4(e) {
20957
20961
  }, [f, i, w, v, C]);
20958
20962
  const R = Ce((I, A, D) => o ? o(I, A, D, v) : D), E = Ce((I) => {
20959
20963
  const A = I.key === wu || I.key === ku;
20960
- if (!Us.has(I.key) || !c && A || k4(I, p) || !b.current)
20964
+ if (!Us.has(I.key) || !c && A || k3(I, p) || !b.current)
20961
20965
  return;
20962
20966
  const P = s === "rtl", T = P ? xu : yu, $ = P ? yu : xu, L = n === "vertical" ? vu : T, F = n === "vertical" ? bu : $, _ = Et(I.nativeEvent);
20963
20967
  if (_ != null && cw(_) && !GE(_)) {
@@ -21004,7 +21008,7 @@ function w4(e) {
21004
21008
  relayKeyboardEvent: E
21005
21009
  };
21006
21010
  }
21007
- function k4(e, t) {
21011
+ function k3(e, t) {
21008
21012
  for (const n of zF)
21009
21013
  if (!t.includes(n) && e.getModifierState(n))
21010
21014
  return !0;
@@ -21041,7 +21045,7 @@ function nf(e) {
21041
21045
  elementsRef: A,
21042
21046
  onMapChange: D,
21043
21047
  relayKeyboardEvent: P
21044
- } = w4({
21048
+ } = w3({
21045
21049
  grid: f,
21046
21050
  loopFocus: p,
21047
21051
  onLoop: h,
@@ -21327,7 +21331,7 @@ const ZE = /* @__PURE__ */ k.forwardRef(function(t, n) {
21327
21331
  });
21328
21332
  });
21329
21333
  process.env.NODE_ENV !== "production" && (ZE.displayName = "ToolbarInput");
21330
- const C4 = ht({
21334
+ const C3 = ht({
21331
21335
  base: [
21332
21336
  "inline-flex shrink-0 cursor-pointer items-center justify-center gap-2",
21333
21337
  "rounded-md font-medium whitespace-nowrap text-secondary",
@@ -21352,7 +21356,7 @@ const C4 = ht({
21352
21356
  defaultVariants: { size: "md", iconOnly: !1 }
21353
21357
  });
21354
21358
  function Iu({ size: e, iconOnly: t, className: n, children: r, ref: o, ...s }) {
21355
- return /* @__PURE__ */ u(UE, { ref: o, className: H(C4({ size: e, iconOnly: t }), n), ...s, children: r });
21359
+ return /* @__PURE__ */ u(UE, { ref: o, className: H(C3({ size: e, iconOnly: t }), n), ...s, children: r });
21356
21360
  }
21357
21361
  function JE({
21358
21362
  className: e,
@@ -21440,7 +21444,7 @@ function gee({ className: e, children: t, ref: n, ...r }) {
21440
21444
  }
21441
21445
  );
21442
21446
  }
21443
- const S4 = /* @__PURE__ */ new Set([Fh.name, ...Fh.aliases ?? []]), E4 = (e) => !!e && S4.has(e.trim().toLowerCase());
21447
+ const S3 = /* @__PURE__ */ new Set([Fh.name, ...Fh.aliases ?? []]), E3 = (e) => !!e && S3.has(e.trim().toLowerCase());
21444
21448
  function QE({
21445
21449
  value: e,
21446
21450
  defaultValue: t,
@@ -21465,7 +21469,7 @@ function QE({
21465
21469
  ref: w,
21466
21470
  ...C
21467
21471
  }) {
21468
- const [S, R] = fi(e, t ?? "", n), [E, N] = fi(d, f, p), I = E4(o), A = Oe(
21472
+ const [S, R] = fi(e, t ?? "", n), [E, N] = fi(d, f, p), I = E3(o), A = Oe(
21469
21473
  () => I ? r ? ["source", "rendered"] : ["source", "rendered", "split"] : ["source"],
21470
21474
  [I, r]
21471
21475
  ), [D, P] = fi(
@@ -21508,7 +21512,7 @@ function QE({
21508
21512
  $
21509
21513
  ]
21510
21514
  ), K = js(), re = G ? c : l, oe = re === void 0 ? void 0 : { maxHeight: `calc(${re} * 1lh + 2 * var(--code-pad-y))` };
21511
- return /* @__PURE__ */ u(M5, { value: Y, children: /* @__PURE__ */ M(
21515
+ return /* @__PURE__ */ u(Mz, { value: Y, children: /* @__PURE__ */ M(
21512
21516
  "div",
21513
21517
  {
21514
21518
  ref: w,
@@ -21518,11 +21522,11 @@ function QE({
21518
21522
  className: H(K.root(), y),
21519
21523
  ...C,
21520
21524
  children: [
21521
- v ?? /* @__PURE__ */ u(O4, {}),
21525
+ v ?? /* @__PURE__ */ u(O3, {}),
21522
21526
  /* @__PURE__ */ M("div", { className: "relative min-w-0", children: [
21523
21527
  /* @__PURE__ */ M("div", { className: K.body(), children: [
21524
21528
  T !== "rendered" && /* @__PURE__ */ u(
21525
- N4,
21529
+ N3,
21526
21530
  {
21527
21531
  text: S,
21528
21532
  onText: R,
@@ -21550,7 +21554,7 @@ function QE({
21550
21554
  "flex min-w-0 flex-1",
21551
21555
  T === "split" && "border-t border-border-subtle md:border-t-0 md:border-l"
21552
21556
  ),
21553
- children: /* @__PURE__ */ u(R4, { text: S, style: oe, collapsed: G })
21557
+ children: /* @__PURE__ */ u(R3, { text: S, style: oe, collapsed: G })
21554
21558
  }
21555
21559
  )
21556
21560
  ] }),
@@ -21570,12 +21574,12 @@ function QE({
21570
21574
  ]
21571
21575
  }
21572
21576
  ),
21573
- !r && /* @__PURE__ */ u(A4, { tabLeaves: W })
21577
+ !r && /* @__PURE__ */ u(A3, { tabLeaves: W })
21574
21578
  ]
21575
21579
  }
21576
21580
  ) });
21577
21581
  }
21578
- function N4({
21582
+ function N3({
21579
21583
  text: e,
21580
21584
  onText: t,
21581
21585
  language: n,
@@ -21590,7 +21594,7 @@ function N4({
21590
21594
  tabLeaves: f,
21591
21595
  onTabLeavesChange: p
21592
21596
  }) {
21593
- const h = js(), m = u4(e, n), g = Oe(() => e.split(`
21597
+ const h = js(), m = u3(e, n), g = Oe(() => e.split(`
21594
21598
  `).length, [e]), b = s !== void 0 && !i, x = b ? String(s + g - 1).length : 0, v = xe(f), y = (C) => {
21595
21599
  v.current = C, p(C);
21596
21600
  }, w = (C) => {
@@ -21605,19 +21609,19 @@ function N4({
21605
21609
  y(!1);
21606
21610
  return;
21607
21611
  }
21608
- C.preventDefault(), E5(S, a, C.shiftKey);
21612
+ C.preventDefault(), Ez(S, a, C.shiftKey);
21609
21613
  return;
21610
21614
  }
21611
21615
  if (v.current && y(!1), !(C.ctrlKey || C.metaKey || C.altKey)) {
21612
21616
  if (C.key === "Enter") {
21613
- C.preventDefault(), N5(S, a);
21617
+ C.preventDefault(), Nz(S, a);
21614
21618
  return;
21615
21619
  }
21616
21620
  if (C.key === "Backspace") {
21617
- I5(S) && C.preventDefault();
21621
+ Iz(S) && C.preventDefault();
21618
21622
  return;
21619
21623
  }
21620
- C.key.length === 1 && R5(S, C.key) && C.preventDefault();
21624
+ C.key.length === 1 && Rz(S, C.key) && C.preventDefault();
21621
21625
  }
21622
21626
  }
21623
21627
  };
@@ -21636,7 +21640,7 @@ function N4({
21636
21640
  style: { "--code-digits": x },
21637
21641
  className: H(h.layers(), i ? "w-full" : "w-max min-w-full"),
21638
21642
  children: [
21639
- b && /* @__PURE__ */ u("div", { "data-code-gutter": "", "aria-hidden": "true", className: H(h.gutter(), "dx-code-nowrap"), children: /* @__PURE__ */ u(f4, { count: g, from: s }) }),
21643
+ b && /* @__PURE__ */ u("div", { "data-code-gutter": "", "aria-hidden": "true", className: H(h.gutter(), "dx-code-nowrap"), children: /* @__PURE__ */ u(f3, { count: g, from: s }) }),
21640
21644
  /* @__PURE__ */ u(
21641
21645
  "pre",
21642
21646
  {
@@ -21646,7 +21650,7 @@ function N4({
21646
21650
  h.pre(),
21647
21651
  i ? "dx-code-wrap min-w-0 flex-1" : "dx-code-nowrap w-max shrink-0"
21648
21652
  ),
21649
- children: /* @__PURE__ */ u(d4, { source: e, tokens: m })
21653
+ children: /* @__PURE__ */ u(d3, { source: e, tokens: m })
21650
21654
  }
21651
21655
  ),
21652
21656
  !o && /* @__PURE__ */ u(
@@ -21677,7 +21681,7 @@ function N4({
21677
21681
  }
21678
21682
  );
21679
21683
  }
21680
- function R4({
21684
+ function R3({
21681
21685
  text: e,
21682
21686
  style: t,
21683
21687
  collapsed: n
@@ -21726,7 +21730,7 @@ function tN({ className: e }) {
21726
21730
  const { filename: t, language: n } = kl("CodeEditorCaption"), r = js(), o = he().codeEditor;
21727
21731
  return /* @__PURE__ */ u("span", { "data-code-caption": "", className: H(r.caption(), e), children: t ?? n ?? o.captionFallback });
21728
21732
  }
21729
- function I4({ className: e }) {
21733
+ function I3({ className: e }) {
21730
21734
  const { copy: t, copied: n } = kl("CodeEditorCopyButton"), r = js(), o = he().codeEditor;
21731
21735
  return /* @__PURE__ */ u(Gt, { content: n ? o.copied : o.copy, children: /* @__PURE__ */ u(
21732
21736
  "button",
@@ -21740,7 +21744,7 @@ function I4({ className: e }) {
21740
21744
  }
21741
21745
  ) });
21742
21746
  }
21743
- function M4({ className: e }) {
21747
+ function M3({ className: e }) {
21744
21748
  const { wrap: t, setWrap: n } = kl("CodeEditorWrapToggle"), r = he().codeEditor;
21745
21749
  return /* @__PURE__ */ u(Gt, { content: t ? r.stopWrapping : r.wrapLongLines, children: /* @__PURE__ */ u(
21746
21750
  Iu,
@@ -21755,8 +21759,8 @@ function M4({ className: e }) {
21755
21759
  }
21756
21760
  ) });
21757
21761
  }
21758
- const T4 = { source: "code", rendered: "file-text", split: "columns-3" };
21759
- function P4({ className: e }) {
21762
+ const T3 = { source: "code", rendered: "file-text", split: "columns-3" };
21763
+ function P3({ className: e }) {
21760
21764
  const { view: t, setView: n, views: r } = kl("CodeEditorViewSwitch"), o = he().codeEditor;
21761
21765
  return r.length < 2 ? null : /* @__PURE__ */ u(
21762
21766
  JE,
@@ -21779,22 +21783,22 @@ function P4({ className: e }) {
21779
21783
  value: s,
21780
21784
  "aria-label": o.views[s],
21781
21785
  className: H("dx-tap shrink-0", s === "split" && "hidden md:inline-flex"),
21782
- children: /* @__PURE__ */ u(ue, { name: T4[s], size: "xs" })
21786
+ children: /* @__PURE__ */ u(ue, { name: T3[s], size: "xs" })
21783
21787
  }
21784
21788
  ) }, s))
21785
21789
  }
21786
21790
  );
21787
21791
  }
21788
- function O4() {
21792
+ function O3() {
21789
21793
  const { view: e } = kl("CodeEditorDefaultToolbar");
21790
21794
  return /* @__PURE__ */ M(eN, { children: [
21791
21795
  /* @__PURE__ */ u(tN, {}),
21792
- /* @__PURE__ */ u(P4, {}),
21793
- e !== "rendered" && /* @__PURE__ */ u(M4, {}),
21794
- /* @__PURE__ */ u(I4, {})
21796
+ /* @__PURE__ */ u(P3, {}),
21797
+ e !== "rendered" && /* @__PURE__ */ u(M3, {}),
21798
+ /* @__PURE__ */ u(I3, {})
21795
21799
  ] });
21796
21800
  }
21797
- function A4({ tabLeaves: e }) {
21801
+ function A3({ tabLeaves: e }) {
21798
21802
  const t = js(), n = he().codeEditor;
21799
21803
  return /* @__PURE__ */ u("div", { className: t.footer(), children: /* @__PURE__ */ u("span", { "data-code-hint": "", "aria-live": "polite", className: t.hint(), children: e ? n.tabLeavesHint : n.tabIndentsHint }) });
21800
21804
  }
@@ -21811,9 +21815,9 @@ function fb({ code: e, language: t, filename: n, streaming: r, className: o }) {
21811
21815
  }
21812
21816
  );
21813
21817
  }
21814
- const D4 = (e) => /* @__PURE__ */ u(fb, { code: e.code, language: e.language, streaming: e.open }), Si = fd(function({ children: t, className: n, renderCode: r }) {
21818
+ const D3 = (e) => /* @__PURE__ */ u(fb, { code: e.code, language: e.language, streaming: e.open }), Si = fd(function({ children: t, className: n, renderCode: r }) {
21815
21819
  const o = Oe(() => EE(t), [t]);
21816
- return /* @__PURE__ */ u("div", { className: H("text-sm leading-relaxed text-secondary", n), children: /* @__PURE__ */ u(wl, { nodes: o, renderCode: r ?? D4 }) });
21820
+ return /* @__PURE__ */ u("div", { className: H("text-sm leading-relaxed text-secondary", n), children: /* @__PURE__ */ u(wl, { nodes: o, renderCode: r ?? D3 }) });
21817
21821
  });
21818
21822
  function nN(e) {
21819
21823
  const t = Nu(e);
@@ -21861,7 +21865,7 @@ function Kw(e, t, n) {
21861
21865
  children: [ya(n)]
21862
21866
  };
21863
21867
  }
21864
- function _4(e, t, n) {
21868
+ function _3(e, t, n) {
21865
21869
  const r = t ? e.src : nN(e.src), o = t?.state ?? (r ? "stored" : "broken"), s = (a) => ({
21866
21870
  tag: "span",
21867
21871
  attrs: { "data-md-image-state": o },
@@ -21932,7 +21936,7 @@ function _4(e, t, n) {
21932
21936
  return s([i]);
21933
21937
  }
21934
21938
  }
21935
- const of = "data-md-syntax", $4 = "data-md", sf = "data-md-decoration";
21939
+ const of = "data-md-syntax", $3 = "data-md", sf = "data-md-decoration";
21936
21940
  function Bh(e) {
21937
21941
  switch (e.kind) {
21938
21942
  case "paragraph":
@@ -22007,9 +22011,9 @@ function Bh(e) {
22007
22011
  }
22008
22012
  }
22009
22013
  function rN(e, t, n) {
22010
- return e.kind === "image" ? _4(e, t?.(e.src) ?? null, n) : void 0;
22014
+ return e.kind === "image" ? _3(e, t?.(e.src) ?? null, n) : void 0;
22011
22015
  }
22012
- function L4(e, t) {
22016
+ function L3(e, t) {
22013
22017
  if (e.kind !== t.kind) return !1;
22014
22018
  const n = Bh(e), r = Bh(t);
22015
22019
  if (n.tag !== r.tag) return !1;
@@ -22023,27 +22027,27 @@ class mb extends Error {
22023
22027
  super(t), this.name = "CompositionConflictError";
22024
22028
  }
22025
22029
  }
22026
- function F4(e, t) {
22030
+ function F3(e, t) {
22027
22031
  const n = e.createTextNode(t.text);
22028
22032
  if (n[hb] = { start: t.start, end: t.end }, !t.syntax && !t.token) return n;
22029
22033
  const r = e.createElement("span");
22030
22034
  return t.syntax && r.setAttribute(of, ""), t.token && r.setAttribute(oN, t.token), r.appendChild(n), r;
22031
22035
  }
22032
22036
  const oN = "data-t";
22033
- function V4(e, t) {
22037
+ function V3(e, t) {
22034
22038
  const n = Bh(t.frame), r = e.createElement(n.tag);
22035
- r.setAttribute($4, t.frame.kind);
22039
+ r.setAttribute($3, t.frame.kind);
22036
22040
  for (const [o, s] of Object.entries(n.attrs ?? {})) r.setAttribute(o, s);
22037
22041
  return r[pb] = t.frame, r;
22038
22042
  }
22039
22043
  function Hh(e, t, n, r) {
22040
- if (t.type === "text") return F4(e, t);
22041
- const o = V4(e, t);
22044
+ if (t.type === "text") return F3(e, t);
22045
+ const o = V3(e, t);
22042
22046
  for (const i of t.children) o.appendChild(Hh(e, i, n, r));
22043
22047
  const s = rN(t.frame, n, r);
22044
22048
  return s && o.appendChild(dN(e, s)), o;
22045
22049
  }
22046
- function z4(e, t) {
22050
+ function z3(e, t) {
22047
22051
  if (!e) return null;
22048
22052
  if (!(t.syntax || !!t.token)) return e.nodeType === 3 ? e : null;
22049
22053
  if (e.nodeType !== 1) return null;
@@ -22052,25 +22056,25 @@ function z4(e, t) {
22052
22056
  const o = r.firstChild;
22053
22057
  return r.childNodes.length === 1 && o && o.nodeType === 3 ? o : null;
22054
22058
  }
22055
- function B4(e, t) {
22059
+ function B3(e, t) {
22056
22060
  if (!e || e.nodeType !== 1) return null;
22057
22061
  const n = e, r = n[pb];
22058
- return r && L4(r, t.frame) ? n : null;
22062
+ return r && L3(r, t.frame) ? n : null;
22059
22063
  }
22060
- function H4(e, t, n) {
22061
- const r = { textUpdated: 0, textUntouched: 0, elementsReused: 0, created: 0, removed: 0 }, o = e.lastChild && j4(e.lastChild) ? e.lastChild : null;
22062
- if (o && e.removeChild(o), aN(e, t, { protect: n.protect ?? null, images: n.images, imageStrings: n.imageStrings, stats: r }), G4(t)) {
22063
- const s = o ?? U4(e.ownerDocument);
22064
+ function H3(e, t, n) {
22065
+ const r = { textUpdated: 0, textUntouched: 0, elementsReused: 0, created: 0, removed: 0 }, o = e.lastChild && j3(e.lastChild) ? e.lastChild : null;
22066
+ if (o && e.removeChild(o), aN(e, t, { protect: n.protect ?? null, images: n.images, imageStrings: n.imageStrings, stats: r }), G3(t)) {
22067
+ const s = o ?? U3(e.ownerDocument);
22064
22068
  o || r.created++, e.appendChild(s);
22065
22069
  }
22066
22070
  return r;
22067
22071
  }
22068
22072
  const sN = "data-md-filler";
22069
- function U4(e) {
22073
+ function U3(e) {
22070
22074
  const t = e.createElement("br");
22071
22075
  return t.setAttribute(sN, ""), t;
22072
22076
  }
22073
- function j4(e) {
22077
+ function j3(e) {
22074
22078
  return e.nodeType === 1 && e.hasAttribute(sN);
22075
22079
  }
22076
22080
  function iN(e) {
@@ -22085,7 +22089,7 @@ function iN(e) {
22085
22089
  }
22086
22090
  return null;
22087
22091
  }
22088
- function G4(e) {
22092
+ function G3(e) {
22089
22093
  return iN(e) === `
22090
22094
  `;
22091
22095
  }
@@ -22094,7 +22098,7 @@ function aN(e, t, n) {
22094
22098
  for (let i = 0; i < t.length; i++) {
22095
22099
  const a = t[i], l = e.childNodes[i] ?? null;
22096
22100
  if (a.type === "text") {
22097
- const d = z4(l, a);
22101
+ const d = z3(l, a);
22098
22102
  if (d) {
22099
22103
  if (d.data === a.text)
22100
22104
  s.textUntouched++;
@@ -22111,9 +22115,9 @@ function aN(e, t, n) {
22111
22115
  Yw(e, i, Hh(r, a, n.images, n.imageStrings), o, s);
22112
22116
  continue;
22113
22117
  }
22114
- const c = B4(l, a);
22118
+ const c = B3(l, a);
22115
22119
  if (c) {
22116
- c[pb] = a.frame, s.elementsReused++, W4(c, a, n);
22120
+ c[pb] = a.frame, s.elementsReused++, W3(c, a, n);
22117
22121
  continue;
22118
22122
  }
22119
22123
  Yw(e, i, Hh(r, a, n.images, n.imageStrings), o, s);
@@ -22123,13 +22127,13 @@ function aN(e, t, n) {
22123
22127
  fN(i, o, "removed"), e.removeChild(i), s.removed++;
22124
22128
  }
22125
22129
  }
22126
- function W4(e, t, n) {
22127
- const r = rN(t.frame, n.images, n.imageStrings), o = q4(e);
22130
+ function W3(e, t, n) {
22131
+ const r = rN(t.frame, n.images, n.imageStrings), o = q3(e);
22128
22132
  if (o && e.removeChild(o), aN(e, t.children, n), !r) return;
22129
22133
  const s = o && lN(o, r) ? o : dN(e.ownerDocument, r);
22130
22134
  s !== o && n.stats.created++, e.appendChild(s);
22131
22135
  }
22132
- function q4(e) {
22136
+ function q3(e) {
22133
22137
  const t = e.lastChild;
22134
22138
  return t && t.nodeType === 1 && t.hasAttribute(sf) ? t : null;
22135
22139
  }
@@ -22141,9 +22145,9 @@ function lN(e, t) {
22141
22145
  const r = t.children ?? [];
22142
22146
  return e.children.length !== r.length ? !1 : r.every((o, s) => lN(e.children[s], o));
22143
22147
  }
22144
- const K4 = "http://www.w3.org/2000/svg";
22148
+ const K3 = "http://www.w3.org/2000/svg";
22145
22149
  function cN(e, t, n) {
22146
- const r = n || t.tag === "svg", o = r ? e.createElementNS(K4, t.tag) : e.createElement(t.tag);
22150
+ const r = n || t.tag === "svg", o = r ? e.createElementNS(K3, t.tag) : e.createElement(t.tag);
22147
22151
  for (const [s, i] of Object.entries(t.attrs)) o.setAttribute(s, i);
22148
22152
  for (const s of t.children ?? []) o.appendChild(cN(e, s, r));
22149
22153
  return o;
@@ -22172,7 +22176,7 @@ function fN(e, t, n) {
22172
22176
  function Wn(e) {
22173
22177
  return e[hb] ?? null;
22174
22178
  }
22175
- function Y4(e) {
22179
+ function Y3(e) {
22176
22180
  const t = [], n = (r) => {
22177
22181
  if (r.nodeType === 3) {
22178
22182
  Wn(r) && t.push(r);
@@ -22199,7 +22203,7 @@ function Cp(e, t) {
22199
22203
  return { node: r, offset: i ? o + 1 : o };
22200
22204
  }
22201
22205
  function jh(e, t, n = "after") {
22202
- const r = Y4(e);
22206
+ const r = Y3(e);
22203
22207
  if (!r.length) return null;
22204
22208
  let o = null;
22205
22209
  for (let a = 0; a < r.length; a++) {
@@ -22229,7 +22233,7 @@ function fo(e, t, n) {
22229
22233
  const s = af(o);
22230
22234
  if (s) return Wn(s).end;
22231
22235
  }
22232
- return X4(e, t);
22236
+ return X3(e, t);
22233
22237
  }
22234
22238
  function gb(e) {
22235
22239
  if (e.nodeType === 3) return Wn(e) ? e : null;
@@ -22247,7 +22251,7 @@ function af(e) {
22247
22251
  }
22248
22252
  return null;
22249
22253
  }
22250
- function X4(e, t) {
22254
+ function X3(e, t) {
22251
22255
  for (let n = t; n && n !== e.parentNode; n = n.parentNode) {
22252
22256
  for (let r = n.previousSibling; r; r = r.previousSibling) {
22253
22257
  const o = af(r);
@@ -22274,7 +22278,7 @@ function wa(e, t, n = "after") {
22274
22278
  const i = e.ownerDocument.getSelection();
22275
22279
  return i ? (i.setBaseAndExtent(o.node, o.offset, s.node, s.offset), !0) : !1;
22276
22280
  }
22277
- const Z4 = new Intl.Segmenter(void 0, { granularity: "grapheme" });
22281
+ const Z3 = new Intl.Segmenter(void 0, { granularity: "grapheme" });
22278
22282
  function bee(e, t, n) {
22279
22283
  const r = Math.max(0, Math.min(t, e.length));
22280
22284
  if (n === 1 && r >= e.length) return e.length;
@@ -22282,7 +22286,7 @@ function bee(e, t, n) {
22282
22286
  const o = en(e, r), s = o.start, i = e.slice(s, o.end), a = r - s;
22283
22287
  if (n === -1 && a <= 0) return r - 1;
22284
22288
  const l = [0];
22285
- for (const d of Z4.segment(i)) l.push(d.index + d.segment.length);
22289
+ for (const d of Z3.segment(i)) l.push(d.index + d.segment.length);
22286
22290
  if (n === 1) {
22287
22291
  for (const d of l) if (d > a) return s + d;
22288
22292
  return r + 1;
@@ -22309,7 +22313,7 @@ class Sp extends Error {
22309
22313
  super(t), this.name = "ProjectionError";
22310
22314
  }
22311
22315
  }
22312
- function J4(e) {
22316
+ function J3(e) {
22313
22317
  const t = [], n = [];
22314
22318
  let r = 0;
22315
22319
  if (Jg(e, {
@@ -22339,18 +22343,18 @@ function J4(e) {
22339
22343
  throw new Sp(`${n.length} frame(s) left open: ${n.map((s) => s.frame.kind).join(", ")}`);
22340
22344
  return t;
22341
22345
  }
22342
- function Q4(e, t) {
22346
+ function Q3(e, t) {
22343
22347
  for (const n of e) if (t >= n.start && t < n.end) return !0;
22344
22348
  return !1;
22345
22349
  }
22346
- function e3(e, t, n) {
22350
+ function e4(e, t, n) {
22347
22351
  let r = n;
22348
22352
  for (const o of e)
22349
22353
  o.start > t && o.start < r && (r = o.start), o.end > t && o.end < r && (r = o.end);
22350
22354
  return r;
22351
22355
  }
22352
22356
  function Tu(e, t = {}) {
22353
- const n = J4(e), r = /* @__PURE__ */ new Map();
22357
+ const n = J3(e), r = /* @__PURE__ */ new Map();
22354
22358
  if (t.highlight)
22355
22359
  for (const d of n) {
22356
22360
  if (d.frame.kind !== "codeBody" || !d.content.length) continue;
@@ -22362,8 +22366,8 @@ function Tu(e, t = {}) {
22362
22366
  function a(d, f, p, h) {
22363
22367
  let m = f;
22364
22368
  for (; m < p; ) {
22365
- const g = h ? h.content : null, b = g !== null && !Q4(g, m);
22366
- let x = g === null ? p : Math.min(e3(g, m, p), p);
22369
+ const g = h ? h.content : null, b = g !== null && !Q3(g, m);
22370
+ let x = g === null ? p : Math.min(e4(g, m, p), p);
22367
22371
  const v = h ? r.get(h) : void 0;
22368
22372
  let y;
22369
22373
  if (v && !b) {
@@ -22400,16 +22404,16 @@ function Tu(e, t = {}) {
22400
22404
  const c = [];
22401
22405
  return l(c, e.length, null), c.length || c.push({ type: "text", start: 0, end: 0, text: "", syntax: !1 }), { source: e, children: c, frames: n };
22402
22406
  }
22403
- function t3(e) {
22407
+ function t4(e) {
22404
22408
  let t = "";
22405
- for (const n of e) t += n.type === "text" ? n.text : t3(n.children);
22409
+ for (const n of e) t += n.type === "text" ? n.text : t4(n.children);
22406
22410
  return t;
22407
22411
  }
22408
- const n3 = /^\s*blob:/i;
22412
+ const n4 = /^\s*blob:/i;
22409
22413
  function bb(e) {
22410
- return n3.test(e);
22414
+ return n4.test(e);
22411
22415
  }
22412
- function r3(e) {
22416
+ function r4(e) {
22413
22417
  if (!/blob:/i.test(e)) return [];
22414
22418
  const t = [];
22415
22419
  for (const n of Tu(e).frames) {
@@ -22418,14 +22422,14 @@ function r3(e) {
22418
22422
  }
22419
22423
  return t.sort((n, r) => n.start - r.start);
22420
22424
  }
22421
- const o3 = /[\\[\]*_`<>|!]/g;
22425
+ const o4 = /[\\[\]*_`<>|!]/g;
22422
22426
  function pN(e) {
22423
22427
  return e.trim().replace(/[\s()<>\\]/g, (t) => `%${t.charCodeAt(0).toString(16).toUpperCase().padStart(2, "0")}`);
22424
22428
  }
22425
22429
  function hN(e, t) {
22426
- return `![${t.replace(o3, "\\$&")}](${pN(e)})`;
22430
+ return `![${t.replace(o4, "\\$&")}](${pN(e)})`;
22427
22431
  }
22428
- function s3(e, t) {
22432
+ function s4(e, t) {
22429
22433
  const n = e.replace(/\.[^./\\]+$/, "").replace(/[\u0000-\u001f\u007f]+/g, " ").trim();
22430
22434
  return n.length ? n : t;
22431
22435
  }
@@ -22525,7 +22529,7 @@ function lf(e) {
22525
22529
  };
22526
22530
  }
22527
22531
  const vN = lf("**"), xN = lf("*"), yN = lf("`"), wN = lf("~~"), kN = /^(\s*)(#{1,6})(\s+)/;
22528
- function i3(e) {
22532
+ function i4(e) {
22529
22533
  const t = kN.exec(e);
22530
22534
  return t ? t[2].length : 0;
22531
22535
  }
@@ -22537,15 +22541,15 @@ function Ro(e) {
22537
22541
  }
22538
22542
  function Xw(e) {
22539
22543
  return (t, n) => {
22540
- const r = po(t, n)[0], o = i3(r.text), s = Math.max(0, Math.min(6, o + e));
22544
+ const r = po(t, n)[0], o = i4(r.text), s = Math.max(0, Math.min(6, o + e));
22541
22545
  return s === o ? null : Ro(s)(t, n);
22542
22546
  };
22543
22547
  }
22544
- const a3 = /^(\s*)([-*+])(\s+)/, l3 = /^(\s*)(\d{1,9})([.)])(\s+)/;
22548
+ const a4 = /^(\s*)([-*+])(\s+)/, l4 = /^(\s*)(\d{1,9})([.)])(\s+)/;
22545
22549
  function Nr(e) {
22546
- const t = a3.exec(e);
22550
+ const t = a4.exec(e);
22547
22551
  if (t) return { indent: t[1], marker: t[2], body: e.slice(t[0].length), ordered: !1 };
22548
- const n = l3.exec(e);
22552
+ const n = l4.exec(e);
22549
22553
  return n ? { indent: n[1], marker: n[2] + n[3], body: e.slice(n[0].length), ordered: !0 } : null;
22550
22554
  }
22551
22555
  function Zw(e) {
@@ -22563,7 +22567,7 @@ function Zw(e) {
22563
22567
  };
22564
22568
  }
22565
22569
  const Ga = " ", vb = /^\[([ xX])\]\s?/;
22566
- function c3(e, t) {
22570
+ function c4(e, t) {
22567
22571
  const n = Nr(e.slice(t.start, en(e, t.start).end));
22568
22572
  if (!n) return !1;
22569
22573
  const r = n.indent.length;
@@ -22579,22 +22583,22 @@ function c3(e, t) {
22579
22583
  }
22580
22584
  return !1;
22581
22585
  }
22582
- const u3 = (e, t) => {
22586
+ const u4 = (e, t) => {
22583
22587
  const n = po(e, t);
22584
- return Nr(n[0].text) && !c3(e, n[0]) ? null : zi(t, n, n.map((r) => Ga + r.text));
22585
- }, d3 = (e, t) => {
22588
+ return Nr(n[0].text) && !c4(e, n[0]) ? null : zi(t, n, n.map((r) => Ga + r.text));
22589
+ }, d4 = (e, t) => {
22586
22590
  const n = po(e, t);
22587
22591
  return n.some((r) => r.text.startsWith(" ") || r.text.startsWith(" ")) ? zi(
22588
22592
  t,
22589
22593
  n,
22590
22594
  n.map((r) => r.text.startsWith(Ga) ? r.text.slice(Ga.length) : r.text.replace(/^[ \t]/, ""))
22591
22595
  ) : null;
22592
- }, f3 = (e, t) => {
22596
+ }, f4 = (e, t) => {
22593
22597
  const n = po(e, t)[0], r = Nr(n.text);
22594
22598
  if (!r) return null;
22595
22599
  const o = n.text.slice(0, n.text.length - r.body.length), s = vb.exec(r.body), i = s ? `${o}[${s[1] === " " ? "x" : " "}] ${r.body.slice(s[0].length)}` : `${o}[ ] ${r.body}`;
22596
22600
  return zi(t, [n], [i]);
22597
- }, Pu = /^(\s*)>\s?/, p3 = (e, t) => {
22601
+ }, Pu = /^(\s*)>\s?/, p4 = (e, t) => {
22598
22602
  const n = po(e, t), r = n.every((o) => Pu.test(o.text));
22599
22603
  return zi(
22600
22604
  t,
@@ -22602,7 +22606,7 @@ const u3 = (e, t) => {
22602
22606
  n.map((o) => r ? o.text.replace(Pu, "$1") : `> ${o.text}`)
22603
22607
  );
22604
22608
  };
22605
- function h3(e = "") {
22609
+ function h4(e = "") {
22606
22610
  return (t, n) => {
22607
22611
  const r = Bi(t, sn(n).from);
22608
22612
  if (r) {
@@ -22644,14 +22648,14 @@ function Bi(e, t) {
22644
22648
  }
22645
22649
  return s && t >= s.start ? { start: s.start, end: e.length, bodyStart: s.end + 1, bodyEnd: e.length } : null;
22646
22650
  }
22647
- const m3 = (e, t) => {
22651
+ const m4 = (e, t) => {
22648
22652
  const n = en(e, sn(t).from), r = e.slice(n.start, n.end).trim().length === 0, o = r ? "---" : `
22649
22653
 
22650
22654
  ---
22651
22655
  `, s = r ? n.start : n.end;
22652
22656
  return { splice: { start: s, end: n.end, text: o }, select: hn(s + o.length) };
22653
22657
  };
22654
- function g3(e = "", t) {
22658
+ function g4(e = "", t) {
22655
22659
  return (n, r) => {
22656
22660
  const { from: o, to: s } = sn(r), i = n.slice(o, s), a = t ? ` "${t}"` : "", l = `[${i}](${e}${a})`;
22657
22661
  return {
@@ -22671,7 +22675,7 @@ function vee(e, t) {
22671
22675
  return { splice: { start: o, end: s, text: i }, select: hn(o + i.length) };
22672
22676
  };
22673
22677
  }
22674
- const b3 = /^[ \t]*\|?[ \t]*:?-+:?[ \t]*(?:\|[ \t]*:?-+:?[ \t]*)*\|?[ \t]*$/;
22678
+ const b4 = /^[ \t]*\|?[ \t]*:?-+:?[ \t]*(?:\|[ \t]*:?-+:?[ \t]*)*\|?[ \t]*$/;
22675
22679
  function El(e, t) {
22676
22680
  const n = en(e, t), r = (i) => {
22677
22681
  const a = en(e, i);
@@ -22688,7 +22692,7 @@ function El(e, t) {
22688
22692
  if (!o(a.text)) break;
22689
22693
  s.push(a), i = a.end;
22690
22694
  }
22691
- return s.length < 2 || !b3.test(s[1].text) ? null : { start: s[0].start, end: s[s.length - 1].end, rows: s };
22695
+ return s.length < 2 || !b4.test(s[1].text) ? null : { start: s[0].start, end: s[s.length - 1].end, rows: s };
22692
22696
  }
22693
22697
  function Ds(e) {
22694
22698
  let t = e.trim();
@@ -22703,7 +22707,7 @@ function CN(e, t, n) {
22703
22707
  const o = t.rows[r], i = (e.slice(o.start, Math.max(o.start, n)).match(/\|/g) ?? []).length, a = /^\s*\|/.test(o.text) ? 1 : 0;
22704
22708
  return { row: r, column: Math.max(0, i - a) };
22705
22709
  }
22706
- function v3(e, t = 3, n = 2) {
22710
+ function v4(e, t = 3, n = 2) {
22707
22711
  return (r, o) => {
22708
22712
  const s = en(r, sn(o).from), i = e(1), a = Cs(Array.from({ length: t }, (m, g) => e(g + 1))), l = Cs(Array.from({ length: t }, () => "---")), c = Array.from({ length: n }, () => Cs(Array.from({ length: t }, () => " "))).join(`
22709
22713
  `), d = `${a}
@@ -22790,7 +22794,7 @@ function RN(e) {
22790
22794
  };
22791
22795
  };
22792
22796
  }
22793
- const x3 = (e, t) => {
22797
+ const x4 = (e, t) => {
22794
22798
  const { from: n, to: r } = sn(t);
22795
22799
  if (n !== r) return null;
22796
22800
  const o = en(e, n), s = e.slice(o.start, o.end), i = (d, f) => ({
@@ -22818,7 +22822,7 @@ const x3 = (e, t) => {
22818
22822
  return { splice: { start: o.start, end: d, text: "" }, select: hn(o.start) };
22819
22823
  }
22820
22824
  return null;
22821
- }, y3 = (e, t) => {
22825
+ }, y4 = (e, t) => {
22822
22826
  const { from: n, to: r } = sn(t), o = en(e, n), s = e.slice(o.start, o.end), i = Nr(s);
22823
22827
  if (i) {
22824
22828
  const l = vb.exec(i.body);
@@ -22851,12 +22855,12 @@ ${a[0]}`;
22851
22855
  const n = RN(!0)(e, t);
22852
22856
  if (n) return n;
22853
22857
  const r = en(e, sn(t).from), o = e.slice(r.start, r.end);
22854
- return !Nr(o) && !Bi(e, sn(t).from) ? null : u3(e, t);
22858
+ return !Nr(o) && !Bi(e, sn(t).from) ? null : u4(e, t);
22855
22859
  }, MN = (e, t) => {
22856
22860
  const n = RN(!1)(e, t);
22857
22861
  if (n) return n;
22858
22862
  const r = en(e, sn(t).from), o = e.slice(r.start, r.end);
22859
- return !Nr(o) && !Bi(e, sn(t).from) ? null : d3(e, t);
22863
+ return !Nr(o) && !Bi(e, sn(t).from) ? null : d4(e, t);
22860
22864
  }, Jw = /* @__PURE__ */ new Set([
22861
22865
  "inline",
22862
22866
  "emphasis",
@@ -22868,7 +22872,7 @@ ${a[0]}`;
22868
22872
  "autolink",
22869
22873
  "footnoteRef",
22870
22874
  "hardBreak"
22871
- ]), w3 = new Intl.Segmenter(void 0, { granularity: "grapheme" });
22875
+ ]), w4 = new Intl.Segmenter(void 0, { granularity: "grapheme" });
22872
22876
  function TN(e, t = []) {
22873
22877
  for (const n of e)
22874
22878
  n.type === "text" ? t.push(n) : TN(n.children, t);
@@ -22886,7 +22890,7 @@ function Qw(e) {
22886
22890
  continue;
22887
22891
  }
22888
22892
  s.add(y.start);
22889
- for (const w of w3.segment(y.text)) {
22893
+ for (const w of w4.segment(y.text)) {
22890
22894
  const C = y.start + w.index, S = C + w.segment.length;
22891
22895
  o.push({ start: C, end: S }), s.add(S);
22892
22896
  }
@@ -22965,22 +22969,22 @@ function sr(e, t) {
22965
22969
  const n = Math.max(0, Math.min(t, e.source.length));
22966
22970
  return e.representative[n] ?? 0;
22967
22971
  }
22968
- function k3(e, t, n) {
22972
+ function k4(e, t, n) {
22969
22973
  const r = sr(e, t), s = e.stops.indexOf(r) + n;
22970
22974
  return s < 0 || s >= e.stops.length ? r : e.stops[s];
22971
22975
  }
22972
- function C3(e, t) {
22976
+ function C4(e, t) {
22973
22977
  let n = null;
22974
22978
  for (const r of e.graphemes)
22975
22979
  if (r.end <= t) n = r;
22976
22980
  else break;
22977
22981
  return n;
22978
22982
  }
22979
- function S3(e, t) {
22983
+ function S4(e, t) {
22980
22984
  for (const n of e.graphemes) if (n.start >= t) return n;
22981
22985
  return null;
22982
22986
  }
22983
- function E3(e, t) {
22987
+ function E4(e, t) {
22984
22988
  const { source: n } = e;
22985
22989
  let r = Math.max(0, Math.min(t, n.length));
22986
22990
  for (; r > 0 && n[r - 1] !== `
@@ -22988,7 +22992,7 @@ function E3(e, t) {
22988
22992
  for (const o of e.stops) if (o >= r) return o;
22989
22993
  return r;
22990
22994
  }
22991
- function N3(e, t) {
22995
+ function N4(e, t) {
22992
22996
  const { source: n } = e;
22993
22997
  let r = Math.max(0, Math.min(t, n.length));
22994
22998
  for (; r < n.length && n[r] !== `
@@ -23015,7 +23019,7 @@ function ON(e, t = []) {
23015
23019
  n.type === "text" ? t.push(n) : ON(n.children, t);
23016
23020
  return t;
23017
23021
  }
23018
- function R3(e, t) {
23022
+ function R4(e, t) {
23019
23023
  return Math.max(0, Math.min(e.end, t.end) - Math.max(e.start, t.start));
23020
23024
  }
23021
23025
  function Ou(e, t, n) {
@@ -23033,7 +23037,7 @@ function Ou(e, t, n) {
23033
23037
  if (!PN.has(g.frame.kind)) continue;
23034
23038
  let b = 0, x = 0;
23035
23039
  for (const v of g.content)
23036
- b += v.end - v.start, x += R3(v, { start: o, end: s });
23040
+ b += v.end - v.start, x += R4(v, { start: o, end: s });
23037
23041
  b > 0 && x === b && c.push(g);
23038
23042
  }
23039
23043
  let d = o, f = s;
@@ -23061,7 +23065,7 @@ function DN(e) {
23061
23065
  select: { anchor: e.start, head: e.start }
23062
23066
  };
23063
23067
  }
23064
- function I3(e, t, n) {
23068
+ function I4(e, t, n) {
23065
23069
  const { source: r } = e;
23066
23070
  let o = Math.max(0, Math.min(n, r.length));
23067
23071
  for (; o > 0 && r[o - 1] !== `
@@ -23073,37 +23077,37 @@ function I3(e, t, n) {
23073
23077
  for (const i of t.graphemes) if (i.start < s && i.end > o) return null;
23074
23078
  return { start: o, end: Math.min(r.length, s + 1) };
23075
23079
  }
23076
- function M3(e, t, n) {
23077
- const r = C3(t, n), o = AN(e, r ? r.end : 0, n);
23080
+ function M4(e, t, n) {
23081
+ const r = C4(t, n), o = AN(e, r ? r.end : 0, n);
23078
23082
  if (o) return DN(o);
23079
- const s = I3(e, t, n);
23083
+ const s = I4(e, t, n);
23080
23084
  return s ? { splice: { ...s, text: "" }, select: { anchor: s.start, head: s.start } } : r ? Ou(e, r.start, r.end) : null;
23081
23085
  }
23082
- function T3(e, t, n) {
23083
- const r = S3(t, n), o = AN(e, n, r ? r.start : e.source.length);
23086
+ function T4(e, t, n) {
23087
+ const r = S4(t, n), o = AN(e, n, r ? r.start : e.source.length);
23084
23088
  return o ? DN(o) : r ? Ou(e, r.start, r.end) : null;
23085
23089
  }
23086
- const P3 = (e) => ({
23090
+ const P4 = (e) => ({
23087
23091
  start: Math.min(e.anchor, e.head),
23088
23092
  end: Math.max(e.anchor, e.head)
23089
23093
  }), Ep = (e, t, n) => ({
23090
23094
  splice: { start: e, end: t, text: n },
23091
23095
  select: { anchor: e + n.length, head: e + n.length }
23092
23096
  });
23093
- function O3(e, t, n) {
23094
- const { start: r, end: o } = P3(t), s = r === o;
23097
+ function O4(e, t, n) {
23098
+ const { start: r, end: o } = P4(t), s = r === o;
23095
23099
  switch (n.kind) {
23096
23100
  case "insert":
23097
23101
  return Ep(r, o, n.text);
23098
23102
  case "backspace": {
23099
23103
  if (!s) return Ou(e.projection, r, o);
23100
- const i = x3(e.source, t);
23101
- return i || M3(e.projection, e.map, r);
23104
+ const i = x4(e.source, t);
23105
+ return i || M4(e.projection, e.map, r);
23102
23106
  }
23103
23107
  case "delete":
23104
- return s ? T3(e.projection, e.map, r) : Ou(e.projection, r, o);
23108
+ return s ? T4(e.projection, e.map, r) : Ou(e.projection, r, o);
23105
23109
  case "enter":
23106
- return y3(e.source, t) ?? Ep(r, o, `
23110
+ return y4(e.source, t) ?? Ep(r, o, `
23107
23111
  `);
23108
23112
  case "lineBreak":
23109
23113
  return Ep(r, o, `
@@ -23120,7 +23124,7 @@ const xb = [
23120
23124
  { id: "italic", key: "ctrl+i", group: "formatting", command: xN },
23121
23125
  { id: "inlineCode", key: "ctrl+e", group: "formatting", command: yN },
23122
23126
  { id: "strikethrough", key: "ctrl+shift+s", group: "formatting", command: wN },
23123
- { id: "link", key: "ctrl+k", group: "formatting", command: g3() },
23127
+ { id: "link", key: "ctrl+k", group: "formatting", command: g4() },
23124
23128
  { id: "image", key: "ctrl+shift+i", group: "formatting", request: "pickImages" },
23125
23129
  /* Headings */
23126
23130
  { id: "paragraph", key: "ctrl+0", group: "headings", command: Ro(0) },
@@ -23135,14 +23139,14 @@ const xb = [
23135
23139
  /* Lists */
23136
23140
  { id: "bulletList", key: "ctrl+shift+bracketleft", group: "lists", command: Zw(!1) },
23137
23141
  { id: "numberedList", key: "ctrl+shift+bracketright", group: "lists", command: Zw(!0) },
23138
- { id: "taskCheckbox", key: "ctrl+shift+x", group: "lists", command: f3 },
23142
+ { id: "taskCheckbox", key: "ctrl+shift+x", group: "lists", command: f4 },
23139
23143
  // I18N-ALLOW: the chord string "tab" is a key id matched against the registry and never rendered (chordLabel names it from the catalog); the scan reads the lone word as English
23140
23144
  { id: "indent", key: "tab", group: "lists", command: IN },
23141
23145
  { id: "outdent", key: "shift+tab", group: "lists", command: MN },
23142
23146
  /* Blocks */
23143
- { id: "codeBlock", key: "ctrl+shift+k", group: "blocks", command: h3() },
23144
- { id: "blockquote", key: "ctrl+shift+q", group: "blocks", command: p3 },
23145
- { id: "horizontalRule", key: "ctrl+shift+enter", group: "blocks", command: m3 },
23147
+ { id: "codeBlock", key: "ctrl+shift+k", group: "blocks", command: h4() },
23148
+ { id: "blockquote", key: "ctrl+shift+q", group: "blocks", command: p4 },
23149
+ { id: "horizontalRule", key: "ctrl+shift+enter", group: "blocks", command: m4 },
23146
23150
  /* Tables */
23147
23151
  { id: "table", key: "ctrl+alt+shift+t", group: "tables", request: "insertTable" },
23148
23152
  { id: "rowAbove", key: "ctrl+alt+shift+arrowup", group: "tables", command: Gh(!1) },
@@ -23156,27 +23160,27 @@ const xb = [
23156
23160
  { id: "alignCenter", key: "ctrl+alt+c", group: "tables", command: mi("center") },
23157
23161
  { id: "alignRight", key: "ctrl+alt+r", group: "tables", command: mi("right") }
23158
23162
  ];
23159
- function A3(e) {
23163
+ function A4(e) {
23160
23164
  const t = [];
23161
23165
  (e.ctrlKey || e.metaKey) && t.push("ctrl"), e.altKey && t.push("alt"), e.shiftKey && t.push("shift");
23162
23166
  const n = t.length ? t.join("+") + "+" : "", r = [n + e.key.toLowerCase()];
23163
23167
  return e.code && r.push(n + e.code.toLowerCase()), r;
23164
23168
  }
23165
- const D3 = new Map(xb.map((e) => [e.key, e]));
23166
- function _3(e) {
23167
- for (const t of A3(e)) {
23168
- const n = D3.get(t);
23169
+ const D4 = new Map(xb.map((e) => [e.key, e]));
23170
+ function _4(e) {
23171
+ for (const t of A4(e)) {
23172
+ const n = D4.get(t);
23169
23173
  if (n) return n;
23170
23174
  }
23171
23175
  return null;
23172
23176
  }
23173
- function $3(e) {
23177
+ function $4(e) {
23174
23178
  return e.replace(/([\\`*_[\]<>])/g, "\\$1");
23175
23179
  }
23176
23180
  function Jc(e, t) {
23177
23181
  return e.getAttribute(t) ?? "";
23178
23182
  }
23179
- function L3(e, t) {
23183
+ function L4(e, t) {
23180
23184
  const r = t(e).body;
23181
23185
  return r ? Wa(r, "").trim().replace(/\n{3,}/g, `
23182
23186
 
@@ -23184,12 +23188,12 @@ function L3(e, t) {
23184
23188
  }
23185
23189
  function Wa(e, t) {
23186
23190
  let n = "";
23187
- for (let r = e.firstChild; r; r = r.nextSibling) n += F3(r, t);
23191
+ for (let r = e.firstChild; r; r = r.nextSibling) n += F4(r, t);
23188
23192
  return n;
23189
23193
  }
23190
- function F3(e, t) {
23194
+ function F4(e, t) {
23191
23195
  if (e.nodeType === 3)
23192
- return $3(e.data.replace(/\s+/g, " "));
23196
+ return $4(e.data.replace(/\s+/g, " "));
23193
23197
  if (e.nodeType !== 1) return "";
23194
23198
  const n = e, r = n.tagName.toLowerCase(), o = () => Wa(n, t);
23195
23199
  switch (r) {
@@ -23236,7 +23240,7 @@ ${"#".repeat(Number(r[1]))} ${o()}
23236
23240
  case "strike":
23237
23241
  return Np(n) ? o() : `~~${o()}~~`;
23238
23242
  case "code":
23239
- return n.parentElement?.tagName.toLowerCase() === "pre" ? n.textContent ?? "" : B3(n.textContent ?? "");
23243
+ return n.parentElement?.tagName.toLowerCase() === "pre" ? n.textContent ?? "" : B4(n.textContent ?? "");
23240
23244
  case "pre":
23241
23245
  return `
23242
23246
 
@@ -23267,7 +23271,7 @@ ${Wa(n, t).trim().replace(/\n{3,}/g, `
23267
23271
  case "ol":
23268
23272
  return `
23269
23273
 
23270
- ${H3(n, t, r === "ol")}
23274
+ ${H4(n, t, r === "ol")}
23271
23275
 
23272
23276
  `;
23273
23277
  case "li":
@@ -23276,7 +23280,7 @@ ${t}- ${o().trim()}`;
23276
23280
  case "table":
23277
23281
  return `
23278
23282
 
23279
- ${U3(n)}
23283
+ ${U4(n)}
23280
23284
 
23281
23285
  `;
23282
23286
  case "script":
@@ -23284,12 +23288,12 @@ ${U3(n)}
23284
23288
  case "head":
23285
23289
  return "";
23286
23290
  case "span":
23287
- return V3(n, o());
23291
+ return V4(n, o());
23288
23292
  default:
23289
23293
  return o();
23290
23294
  }
23291
23295
  }
23292
- function V3(e, t) {
23296
+ function V4(e, t) {
23293
23297
  const n = Jc(e, "style").toLowerCase();
23294
23298
  if (!n) return t;
23295
23299
  let r = t;
@@ -23301,17 +23305,17 @@ function V3(e, t) {
23301
23305
  }
23302
23306
  return r;
23303
23307
  }
23304
- const z3 = /* @__PURE__ */ new Set(["p", "div", "h1", "h2", "h3", "h4", "h5", "h6", "ul", "ol", "li", "table", "blockquote", "pre", "hr"]);
23308
+ const z4 = /* @__PURE__ */ new Set(["p", "div", "h1", "h2", "h3", "h4", "h5", "h6", "ul", "ol", "li", "table", "blockquote", "pre", "hr"]);
23305
23309
  function Np(e) {
23306
23310
  for (let t = e.firstChild; t; t = t.nextSibling)
23307
- if (t.nodeType === 1 && z3.has(t.tagName.toLowerCase())) return !0;
23311
+ if (t.nodeType === 1 && z4.has(t.tagName.toLowerCase())) return !0;
23308
23312
  return !1;
23309
23313
  }
23310
- function B3(e) {
23314
+ function B4(e) {
23311
23315
  const t = (e.match(/`+/g) ?? []).reduce((o, s) => Math.max(o, s.length), 0), n = "`".repeat(t + 1), r = e.startsWith("`") || e.endsWith("`") ? " " : "";
23312
23316
  return `${n}${r}${e}${r}${n}`;
23313
23317
  }
23314
- function H3(e, t, n) {
23318
+ function H4(e, t, n) {
23315
23319
  const r = [];
23316
23320
  let o = Number(e.getAttribute("start") ?? "1") || 1;
23317
23321
  for (let s = e.firstChild; s; s = s.nextSibling) {
@@ -23325,7 +23329,7 @@ ${a}`)}`);
23325
23329
  return r.join(`
23326
23330
  `);
23327
23331
  }
23328
- function U3(e) {
23332
+ function U4(e) {
23329
23333
  const t = [];
23330
23334
  for (const a of Array.from(e.querySelectorAll("tr"))) {
23331
23335
  const l = Array.from(a.querySelectorAll("th, td")).map(
@@ -23346,7 +23350,7 @@ function U3(e) {
23346
23350
  return [r(s), `| ${Array.from({ length: n }, () => "---").join(" | ")} |`, ...i.map(r)].join(`
23347
23351
  `);
23348
23352
  }
23349
- const j3 = /* @__PURE__ */ new Set([
23353
+ const j4 = /* @__PURE__ */ new Set([
23350
23354
  "insertText",
23351
23355
  "insertReplacementText",
23352
23356
  "insertFromPaste",
@@ -23355,7 +23359,7 @@ const j3 = /* @__PURE__ */ new Set([
23355
23359
  "insertFromYank",
23356
23360
  "insertTranspose",
23357
23361
  "insertLink"
23358
- ]), G3 = /* @__PURE__ */ new Set([
23362
+ ]), G4 = /* @__PURE__ */ new Set([
23359
23363
  "deleteContent",
23360
23364
  "deleteContentBackward",
23361
23365
  "deleteContentForward",
@@ -23369,7 +23373,7 @@ const j3 = /* @__PURE__ */ new Set([
23369
23373
  "deleteByDrag",
23370
23374
  "deleteByCut"
23371
23375
  ]);
23372
- function W3(e, t = {}) {
23376
+ function W4(e, t = {}) {
23373
23377
  const n = e.root, r = (f) => {
23374
23378
  const p = f.inputType;
23375
23379
  if (!f.cancelable) return;
@@ -23381,19 +23385,19 @@ function W3(e, t = {}) {
23381
23385
  f.preventDefault(), e.redo();
23382
23386
  return;
23383
23387
  }
23384
- const h = Z3(n, f) ?? J3(e);
23388
+ const h = Z4(n, f) ?? J4(e);
23385
23389
  if (!h) return;
23386
23390
  const m = e.getSelection(), g = m !== null && m.anchor === m.head ? m : null, b = (x, v, y = g ?? { anchor: h.start, head: h.end }) => {
23387
- const w = O3(
23391
+ const w = O4(
23388
23392
  { source: e.getSource(), projection: e.getProjection(), map: e.getCaretMap() },
23389
23393
  y,
23390
23394
  x
23391
23395
  );
23392
23396
  return w ? (e.apply(w.splice, w.select, v), !0) : !1;
23393
23397
  };
23394
- if (j3.has(p)) {
23398
+ if (j4.has(p)) {
23395
23399
  f.preventDefault();
23396
- const x = Q3(f);
23400
+ const x = Q4(f);
23397
23401
  if (x === null) {
23398
23402
  t.onUnhandled?.(p);
23399
23403
  return;
@@ -23401,7 +23405,7 @@ function W3(e, t = {}) {
23401
23405
  b({ kind: "insert", text: x }, "type");
23402
23406
  return;
23403
23407
  }
23404
- if (G3.has(p)) {
23408
+ if (G4.has(p)) {
23405
23409
  f.preventDefault(), b(
23406
23410
  { kind: p === "deleteContentBackward" || p === "deleteWordBackward" ? "backspace" : "delete" },
23407
23411
  "delete",
@@ -23430,8 +23434,8 @@ function W3(e, t = {}) {
23430
23434
  const g = Nu(m);
23431
23435
  g && (f.preventDefault(), n.ownerDocument.defaultView?.open(g, "_blank", "noopener,noreferrer"));
23432
23436
  }, a = (f) => {
23433
- if (q3(f.target)) return;
23434
- const p = _3(f);
23437
+ if (q4(f.target)) return;
23438
+ const p = _4(f);
23435
23439
  if (p?.request) {
23436
23440
  t.onRequest && (f.preventDefault(), t.onRequest(p.request));
23437
23441
  return;
@@ -23454,13 +23458,13 @@ function W3(e, t = {}) {
23454
23458
  }, l = n.ownerDocument, c = () => {
23455
23459
  const p = l.getSelection()?.anchorNode;
23456
23460
  !p || !n.contains(p) || e.snapCaret();
23457
- }, d = t.onImageFiles ? X3(e, t.onImageFiles) : () => {
23461
+ }, d = t.onImageFiles ? X4(e, t.onImageFiles) : () => {
23458
23462
  };
23459
23463
  return n.addEventListener("beforeinput", r), n.addEventListener("pointerdown", s), n.addEventListener("click", i), n.addEventListener("keydown", a), l.addEventListener("selectionchange", c), () => {
23460
23464
  d(), n.removeEventListener("beforeinput", r), n.removeEventListener("pointerdown", s), n.removeEventListener("click", i), n.removeEventListener("keydown", a), l.removeEventListener("selectionchange", c);
23461
23465
  };
23462
23466
  }
23463
- function q3(e) {
23467
+ function q4(e) {
23464
23468
  return e instanceof Element && e.closest(`[${sf}]`) !== null;
23465
23469
  }
23466
23470
  const e0 = "data-md-drop-target";
@@ -23470,14 +23474,14 @@ function t0(e) {
23470
23474
  function n0(e) {
23471
23475
  return e ? Array.from(e.items).some((t) => t.kind === "file" && t.type.startsWith("image/")) : !1;
23472
23476
  }
23473
- function K3(e, t) {
23477
+ function K4(e, t) {
23474
23478
  const n = new Set(t.map((o) => o.name)), r = e.split(/\r?\n/).map((o) => o.trim()).filter(Boolean);
23475
23479
  return r.length > 0 && r.every((o) => n.has(o) || n.has(o.split(/[\\/]/).pop() ?? ""));
23476
23480
  }
23477
23481
  function bc(e) {
23478
23482
  return !!e && Array.from(e.types).includes("Files");
23479
23483
  }
23480
- function Y3(e, t, n) {
23484
+ function Y4(e, t, n) {
23481
23485
  const r = e.root.ownerDocument;
23482
23486
  let o = null, s = 0;
23483
23487
  if (typeof r.caretPositionFromPoint == "function") {
@@ -23491,7 +23495,7 @@ function Y3(e, t, n) {
23491
23495
  const i = fo(e.root, o, s);
23492
23496
  return i === null ? null : sr(e.getCaretMap(), i);
23493
23497
  }
23494
- function X3(e, t) {
23498
+ function X4(e, t) {
23495
23499
  const n = e.root;
23496
23500
  let r = 0;
23497
23501
  const o = (d) => {
@@ -23501,7 +23505,7 @@ function X3(e, t) {
23501
23505
  const f = d.clipboardData, p = t0(f);
23502
23506
  if (!p.length) return;
23503
23507
  const h = f.getData("text/plain");
23504
- h.length && !K3(h, p) || (d.preventDefault(), t(p, e.getSelection()));
23508
+ h.length && !K4(h, p) || (d.preventDefault(), t(p, e.getSelection()));
23505
23509
  }, i = (d) => {
23506
23510
  !n.isContentEditable || !bc(d.dataTransfer) || (r++, o(n0(d.dataTransfer)));
23507
23511
  }, a = (d) => {
@@ -23513,14 +23517,14 @@ function X3(e, t) {
23513
23517
  d.preventDefault(), r = 0, o(!1);
23514
23518
  const f = t0(d.dataTransfer);
23515
23519
  if (!f.length) return;
23516
- const p = Y3(e, d.clientX, d.clientY);
23520
+ const p = Y4(e, d.clientX, d.clientY);
23517
23521
  t(f, p === null ? null : { anchor: p, head: p });
23518
23522
  };
23519
23523
  return n.addEventListener("paste", s), n.addEventListener("dragenter", i), n.addEventListener("dragover", a), n.addEventListener("dragleave", l), n.addEventListener("drop", c), () => {
23520
23524
  n.removeEventListener("paste", s), n.removeEventListener("dragenter", i), n.removeEventListener("dragover", a), n.removeEventListener("dragleave", l), n.removeEventListener("drop", c), o(!1);
23521
23525
  };
23522
23526
  }
23523
- function Z3(e, t) {
23527
+ function Z4(e, t) {
23524
23528
  const n = typeof t.getTargetRanges == "function" ? t.getTargetRanges() : [];
23525
23529
  if (!n.length) return null;
23526
23530
  let r = Number.POSITIVE_INFINITY, o = Number.NEGATIVE_INFINITY;
@@ -23531,17 +23535,17 @@ function Z3(e, t) {
23531
23535
  }
23532
23536
  return Number.isFinite(r) ? { start: r, end: o } : null;
23533
23537
  }
23534
- function J3(e) {
23538
+ function J4(e) {
23535
23539
  const t = e.getSelection();
23536
23540
  return t ? { start: Math.min(t.anchor, t.head), end: Math.max(t.anchor, t.head) } : null;
23537
23541
  }
23538
- function Q3(e) {
23542
+ function Q4(e) {
23539
23543
  if (typeof e.data == "string") return e.data;
23540
23544
  const t = e.dataTransfer;
23541
23545
  if (!t) return null;
23542
23546
  const n = t.getData("text/plain"), r = t.getData("text/html");
23543
23547
  if (r && r.trim().length) {
23544
- const o = L3(
23548
+ const o = L4(
23545
23549
  r,
23546
23550
  (s) => new DOMParser().parseFromString(s, "text/html")
23547
23551
  );
@@ -23824,7 +23828,7 @@ class rB {
23824
23828
  const r = Tu(this.source, { highlight: this.options.highlight });
23825
23829
  this.projection = r, this.caretStops = Qw(r), this.write(() => {
23826
23830
  try {
23827
- H4(this.root, r.children, { images: this.options.images, imageStrings: this.options.imageStrings() });
23831
+ H3(this.root, r.children, { images: this.options.images, imageStrings: this.options.imageStrings() });
23828
23832
  } catch (s) {
23829
23833
  if (s instanceof mb) {
23830
23834
  this.deferred = !0, this.options.onDesync?.(s.message);
@@ -23874,7 +23878,7 @@ class rB {
23874
23878
  moveCaret(t, n) {
23875
23879
  const r = this.getSelection();
23876
23880
  if (!r) return !1;
23877
- const o = !n && r.anchor !== r.head ? t === 1 ? Math.max(r.anchor, r.head) : Math.min(r.anchor, r.head) : k3(this.caretStops, r.head, t), s = n ? { anchor: r.anchor, head: o } : { anchor: o, head: o };
23881
+ const o = !n && r.anchor !== r.head ? t === 1 ? Math.max(r.anchor, r.head) : Math.min(r.anchor, r.head) : k4(this.caretStops, r.head, t), s = n ? { anchor: r.anchor, head: o } : { anchor: o, head: o };
23878
23882
  return this.write(() => wa(this.root, s, t === 1 ? "after" : "before")), !0;
23879
23883
  }
23880
23884
  /**
@@ -23891,7 +23895,7 @@ class rB {
23891
23895
  moveToLineEdge(t, n) {
23892
23896
  const r = this.getSelection();
23893
23897
  if (!r) return !1;
23894
- const o = t === "start" ? E3(this.caretStops, r.head) : N3(this.caretStops, r.head), s = n ? { anchor: r.anchor, head: o } : { anchor: o, head: o };
23898
+ const o = t === "start" ? E4(this.caretStops, r.head) : N4(this.caretStops, r.head), s = n ? { anchor: r.anchor, head: o } : { anchor: o, head: o };
23895
23899
  return this.write(() => wa(this.root, s, t === "start" ? "after" : "before")), !0;
23896
23900
  }
23897
23901
  /**
@@ -24089,7 +24093,7 @@ class iB {
24089
24093
  const b = this.env.createObjectURL(g);
24090
24094
  return this.entries.set(b, { file: g, state: s ? "uploading" : "local", controller: null }), b;
24091
24095
  });
24092
- let a = o.map((g, b) => hN(i[b], s3(g.name, this.options.defaultAlt()))).join(" ");
24096
+ let a = o.map((g, b) => hN(i[b], s4(g.name, this.options.defaultAlt()))).join(" ");
24093
24097
  const l = n ?? r.getSelection() ?? { anchor: r.getSource().length, head: r.getSource().length }, c = r.getCaretMap();
24094
24098
  let d = sr(c, Math.min(l.anchor, l.head)), f = sr(c, Math.max(l.anchor, l.head));
24095
24099
  const p = r.getSource(), h = gN(r.getProjection(), d);
@@ -24151,7 +24155,7 @@ class iB {
24151
24155
  const n = t.getSource();
24152
24156
  for (const [l, c] of this.entries)
24153
24157
  c.controller || n.includes(l) || t.remembers(l) || this.release(l);
24154
- const r = r3(n), o = [], s = /* @__PURE__ */ new Set(), i = {
24158
+ const r = r4(n), o = [], s = /* @__PURE__ */ new Set(), i = {
24155
24159
  uploading: 0,
24156
24160
  failed: 0,
24157
24161
  unstored: r.length,
@@ -25937,7 +25941,7 @@ function zB({
25937
25941
  }
25938
25942
  function BB({ language: e, run: t }) {
25939
25943
  const n = he().markdownAffordances, r = Oe(() => {
25940
- const o = c4().sort();
25944
+ const o = c3().sort();
25941
25945
  return e && !o.includes(e) ? [e, ...o] : o;
25942
25946
  }, [e]);
25943
25947
  return /* @__PURE__ */ M("label", { className: "flex items-center gap-1.5 px-1 text-xs text-tertiary", children: [
@@ -26257,7 +26261,7 @@ function QB({
26257
26261
  }))
26258
26262
  });
26259
26263
  C.current = ee, _(ee), te.attach(ee);
26260
- const Z = ee.bind(), de = te.bind(), pe = W3(ee, {
26264
+ const Z = ee.bind(), de = te.bind(), pe = W4(ee, {
26261
26265
  /* Paste and drop: the files go into the ONE pipeline the picker also
26262
26266
  uses, at the caret or the drop point. Focus follows a drop, the way it
26263
26267
  would follow dropped text — the caret is now after the new image. */
@@ -26327,7 +26331,7 @@ function QB({
26327
26331
  G();
26328
26332
  return;
26329
26333
  case "insertTable":
26330
- q(v3((ee) => b.current.tableColumnHeader(v.current(ee))));
26334
+ q(v4((ee) => b.current.tableColumnHeader(v.current(ee))));
26331
26335
  return;
26332
26336
  case "insertColumnLeft":
26333
26337
  q(Wh(!1, b.current.newColumnHeader));
@@ -53093,7 +53097,7 @@ function rK({
53093
53097
  }
53094
53098
  ) }),
53095
53099
  /* @__PURE__ */ u(vt, { label: c.description, description: c.descriptionHint, children: /* @__PURE__ */ u(
53096
- nz,
53100
+ n5,
53097
53101
  {
53098
53102
  value: p,
53099
53103
  onChange: (v) => h(v.target.value),
@@ -61771,10 +61775,10 @@ export {
61771
61775
  fb as CodeBlock,
61772
61776
  QE as CodeEditor,
61773
61777
  tN as CodeEditorCaption,
61774
- I4 as CodeEditorCopyButton,
61778
+ I3 as CodeEditorCopyButton,
61775
61779
  eN as CodeEditorToolbar,
61776
- P4 as CodeEditorViewSwitch,
61777
- M4 as CodeEditorWrapToggle,
61780
+ P3 as CodeEditorViewSwitch,
61781
+ M3 as CodeEditorWrapToggle,
61778
61782
  Vb as Collapsible,
61779
61783
  TH as CollapsiblePanel,
61780
61784
  IH as CollapsibleRoot,
@@ -61966,7 +61970,7 @@ export {
61966
61970
  mne as TeamSettingsForm,
61967
61971
  ene as TeamSwitcher,
61968
61972
  fP as TermsAcceptance,
61969
- nz as Textarea,
61973
+ n5 as Textarea,
61970
61974
  Aee as ThemeMenu,
61971
61975
  vte as TimeSeriesChart,
61972
61976
  Cee as Timeline,
@@ -62008,7 +62012,7 @@ export {
62008
62012
  Fee as atMidnight,
62009
62013
  Vee as atTime,
62010
62014
  o7 as attachAutoScroll,
62011
- W3 as attachInput,
62015
+ W4 as attachInput,
62012
62016
  n7 as attachKeyboardSensor,
62013
62017
  J9 as attachPointerSensor,
62014
62018
  Q9 as attachSessionWindowListeners,
@@ -62024,7 +62028,7 @@ export {
62024
62028
  Jv as chartSeriesColor,
62025
62029
  cee as checkCoverage,
62026
62030
  Su as chordLabel,
62027
- A3 as chordsOf,
62031
+ A4 as chordsOf,
62028
62032
  Yu as clampScale,
62029
62033
  N6 as clearStored,
62030
62034
  H as cn,
@@ -62053,8 +62057,8 @@ export {
62053
62057
  SN as deleteRow,
62054
62058
  NN as deleteTable,
62055
62059
  Ou as deleteVisible,
62056
- T3 as deleteVisibleAfter,
62057
- M3 as deleteVisibleBefore,
62060
+ T4 as deleteVisibleAfter,
62061
+ M4 as deleteVisibleBefore,
62058
62062
  kx as deriveRoadmapItemStatus,
62059
62063
  S2 as describeMoveRejection,
62060
62064
  q2 as describeTarget,
@@ -62067,7 +62071,7 @@ export {
62067
62071
  Zu as eventLabel,
62068
62072
  Bi as fenceAround,
62069
62073
  fx as fileIconFor,
62070
- r3 as findUnstoredImages,
62074
+ r4 as findUnstoredImages,
62071
62075
  xx as fitBox,
62072
62076
  jW as fitBoxWithFloor,
62073
62077
  UW as fitWidth,
@@ -62086,23 +62090,23 @@ export {
62086
62090
  Ik as getIcon,
62087
62091
  Qq as getNetworkSpeed,
62088
62092
  zf as getRecordStoreTenant,
62089
- S3 as graphemeAfter,
62090
- C3 as graphemeBefore,
62093
+ S4 as graphemeAfter,
62094
+ C4 as graphemeBefore,
62091
62095
  xJ as groupOperations,
62092
62096
  ZQ as hasIcon,
62093
- i3 as headingLevel,
62094
- _3 as hotkeyFor,
62097
+ i4 as headingLevel,
62098
+ _4 as hotkeyFor,
62095
62099
  Bee as hoursInDay,
62096
- L3 as htmlFragmentToMarkdown,
62100
+ L4 as htmlFragmentToMarkdown,
62097
62101
  XQ as iconNames,
62098
- u3 as indentLines,
62102
+ u4 as indentLines,
62099
62103
  Rq as initialFocusDay,
62100
62104
  Wh as insertColumn,
62101
62105
  vee as insertImage,
62102
- g3 as insertLink,
62106
+ g4 as insertLink,
62103
62107
  Gh as insertRow,
62104
- m3 as insertRule,
62105
- v3 as insertTable,
62108
+ m4 as insertRule,
62109
+ v4 as insertTable,
62106
62110
  LI as instantAtFraction,
62107
62111
  zee as instantToPlainDate,
62108
62112
  Kn as instantToPlainDateTime,
@@ -62125,8 +62129,8 @@ export {
62125
62129
  dK as leastPrivilegeRoleId,
62126
62130
  Ma as legalSectionAnchor,
62127
62131
  en as lineAt,
62128
- E3 as lineStartStop,
62129
- c4 as listLanguages,
62132
+ E4 as lineStartStop,
62133
+ c3 as listLanguages,
62130
62134
  Xu as longDate,
62131
62135
  vJ as mergedParameters,
62132
62136
  mU as monthGridDays,
@@ -62143,7 +62147,7 @@ export {
62143
62147
  Vu as offsetAt,
62144
62148
  kJ as operationAnchorId,
62145
62149
  tre as optimisticWrite,
62146
- d3 as outdentLines,
62150
+ d4 as outdentLines,
62147
62151
  U2 as packBand,
62148
62152
  Oq as packLanes,
62149
62153
  nl as paletteFor,
@@ -62158,7 +62162,7 @@ export {
62158
62162
  av as plainDateTimeToInstant,
62159
62163
  ux as positionInColumn,
62160
62164
  Tu as project,
62161
- t3 as projectedText,
62165
+ t4 as projectedText,
62162
62166
  Mne as provenanceStateLabel,
62163
62167
  Ine as ratedConfidence,
62164
62168
  pQ as readRealtimeEpoch,
@@ -62180,7 +62184,7 @@ export {
62180
62184
  Wq as resetSimStores,
62181
62185
  Xne as resetSlots,
62182
62186
  pa as resolveCalendarTarget,
62183
- O3 as resolveKey,
62187
+ O4 as resolveKey,
62184
62188
  uee as resolveLanguage,
62185
62189
  P7 as resolveMove,
62186
62190
  Ff as resolveSchema,
@@ -62199,7 +62203,7 @@ export {
62199
62203
  V1 as setSimSettings,
62200
62204
  Uc as simulateLatency,
62201
62205
  LQ as slotKeys,
62202
- y3 as smartEnter,
62206
+ y4 as smartEnter,
62203
62207
  MN as smartShiftTab,
62204
62208
  IN as smartTab,
62205
62209
  Ute as snapFractionToInstant,
@@ -62211,7 +62215,7 @@ export {
62211
62215
  Xa as startOfWeek,
62212
62216
  bee as stepOffset,
62213
62217
  vG as stepStatus,
62214
- k3 as stepStop,
62218
+ k4 as stepStop,
62215
62219
  yG as stepperProgress,
62216
62220
  Ol as storageKey,
62217
62221
  Ax as subscribeToKey,
@@ -62232,13 +62236,13 @@ export {
62232
62236
  E1 as toScreenPoint,
62233
62237
  vN as toggleBold,
62234
62238
  yN as toggleCode,
62235
- h3 as toggleCodeBlock,
62239
+ h4 as toggleCodeBlock,
62236
62240
  lf as toggleInline,
62237
62241
  xN as toggleItalic,
62238
62242
  Zw as toggleList,
62239
- p3 as toggleQuote,
62243
+ p4 as toggleQuote,
62240
62244
  wN as toggleStrike,
62241
- f3 as toggleTask,
62245
+ f4 as toggleTask,
62242
62246
  BE as tokenize,
62243
62247
  j1 as toneForIndex,
62244
62248
  Cx as trackIds,