@surrealdb/ui 1.0.80 → 1.0.83

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/ui.js CHANGED
@@ -4,11 +4,11 @@ import { getIndentUnit as ra, indentOnInput as Jo, bracketMatching as O2, indent
4
4
  import { highlightSelectionMatches as l2, searchKeymap as $2 } from "@codemirror/search";
5
5
  import { Facet as c2, combineConfig as u2, RangeSetBuilder as p2, EditorSelection as sa, EditorState as Ze, Compartment as oa } from "@codemirror/state";
6
6
  import { ViewPlugin as d2, EditorView as ie, Decoration as h2, highlightSpecialChars as P2, drawSelection as f2, dropCursor as S2, rectangularSelection as X2, crosshairCursor as T2, keymap as jn, highlightActiveLineGutter as g2, lineNumbers as m2 } from "@codemirror/view";
7
- import { useMantineColorScheme as An, Box as aO, useMantineTheme as En, getThemeColor as Dn, getSize as In, Paper as B1, Text as Ie, CopyButton as x2, Tooltip as D1, ActionIcon as S1, Alert as Pr, Group as z1, Title as Mn, Stack as Me, Button as T1, Image as It, useComputedColorScheme as C2, Divider as fr, Table as K, Blockquote as Sr, Checkbox as Xr, List as Qa, Anchor as Tr, Skeleton as gr, TextInput as WO, Flex as V2, Select as r1, Switch as X1, Textarea as la, Menu as $O, Popover as ni, ThemeIcon as w2, Badge as mr, Tabs as Ve, TabsList as Z2, TabsTab as y2, Code as b2, createTheme as R2, Notification as _2, Pagination as v2, Kbd as z2, NavLink as k2, SegmentedControl as q2, PasswordInput as Y2, Radio as W2, MultiSelect as L2, Overlay as U2, CloseButton as G2, Modal as j2, Loader as A2, HoverCard as E2, MenuDropdown as D2, PopoverDropdown as I2, ScrollArea as M2, Autocomplete as F2, NumberInput as N2, InputBase as B2, rem as OO, defaultVariantColorsResolver as $a } from "@mantine/core";
7
+ import { useMantineColorScheme as An, Box as aO, useMantineTheme as En, getThemeColor as Dn, getSize as In, Paper as B1, Text as Ie, CopyButton as x2, Tooltip as D1, ActionIcon as S1, Alert as Pr, Group as z1, Title as Mn, Stack as Me, Button as T1, Image as It, useComputedColorScheme as C2, Divider as fr, Table as K, Blockquote as Sr, Checkbox as Xr, List as Qa, Anchor as Tr, Skeleton as gr, TextInput as LO, Flex as V2, Select as r1, Switch as X1, Textarea as la, Menu as $O, Popover as ni, ThemeIcon as w2, Badge as mr, Tabs as Ve, TabsList as Z2, TabsTab as y2, Code as b2, createTheme as R2, Notification as _2, Pagination as v2, Kbd as z2, NavLink as k2, SegmentedControl as q2, PasswordInput as Y2, Radio as W2, MultiSelect as L2, Overlay as U2, CloseButton as G2, Modal as j2, Loader as A2, HoverCard as E2, MenuDropdown as D2, PopoverDropdown as I2, ScrollArea as M2, Autocomplete as F2, NumberInput as N2, InputBase as B2, rem as OO, defaultVariantColorsResolver as $a } from "@mantine/core";
8
8
  import "@codemirror/lint";
9
9
  import { useRef as VO, useCallback as M, useState as j, useMemo as tO, useEffect as H, createRef as K2, createElement as Fn, createContext as H2, useContext as J2, memo as xr } from "react";
10
10
  import { jsx as p, jsxs as v, Fragment as Fe } from "react/jsx-runtime";
11
- import Nn, { YooptaPlugin as K1, useYooptaEditor as dO, useYooptaReadOnly as pe, Elements as KO, Blocks as YO, createYooptaMark as O5, Marks as JO, createYooptaEditor as e5 } from "@yoopta/editor";
11
+ import Nn, { YooptaPlugin as K1, useYooptaEditor as dO, useYooptaReadOnly as pe, Elements as KO, Blocks as WO, createYooptaMark as O5, Marks as JO, createYooptaEditor as e5 } from "@yoopta/editor";
12
12
  import si from "@yoopta/headings";
13
13
  import qi, { useNumberListCount as t5 } from "@yoopta/lists";
14
14
  import { Bold as i5, Italic as r5, Underline as a5, Strike as n5, Highlight as s5 } from "@yoopta/marks";
@@ -705,7 +705,7 @@ function qg(O) {
705
705
  }
706
706
  const Os = 1024;
707
707
  let D5 = 0;
708
- class qO {
708
+ class YO {
709
709
  constructor(e, t) {
710
710
  this.from = e, this.to = t;
711
711
  }
@@ -731,7 +731,7 @@ class I {
731
731
  add(e) {
732
732
  if (this.perNode)
733
733
  throw new RangeError("Can't add per-node props to node types");
734
- return typeof e != "function" && (e = LO.match(e)), (t) => {
734
+ return typeof e != "function" && (e = UO.match(e)), (t) => {
735
735
  let i = e(t);
736
736
  return i === void 0 ? null : [this, i];
737
737
  };
@@ -760,7 +760,7 @@ class ae {
760
760
  }
761
761
  }
762
762
  const I5 = /* @__PURE__ */ Object.create(null);
763
- class LO {
763
+ class UO {
764
764
  /**
765
765
  @internal
766
766
  */
@@ -771,7 +771,7 @@ class LO {
771
771
  Define a node type.
772
772
  */
773
773
  static define(e) {
774
- let t = e.props && e.props.length ? /* @__PURE__ */ Object.create(null) : I5, i = (e.top ? 1 : 0) | (e.skipped ? 2 : 0) | (e.error ? 4 : 0) | (e.name == null ? 8 : 0), r = new LO(e.name || "", t, e.id, i);
774
+ let t = e.props && e.props.length ? /* @__PURE__ */ Object.create(null) : I5, i = (e.top ? 1 : 0) | (e.skipped ? 2 : 0) | (e.error ? 4 : 0) | (e.name == null ? 8 : 0), r = new UO(e.name || "", t, e.id, i);
775
775
  if (e.props) {
776
776
  for (let a of e.props)
777
777
  if (Array.isArray(a) || (a = a(r)), a) {
@@ -849,7 +849,7 @@ class LO {
849
849
  };
850
850
  }
851
851
  }
852
- LO.none = new LO(
852
+ UO.none = new UO(
853
853
  "",
854
854
  /* @__PURE__ */ Object.create(null),
855
855
  0,
@@ -884,7 +884,7 @@ class Cr {
884
884
  o.combine && o.id in r && (s = o.combine(r[o.id], s)), r[o.id] = s;
885
885
  }
886
886
  }
887
- t.push(r ? new LO(i.name, r, i.id, i.flags) : i);
887
+ t.push(r ? new UO(i.name, r, i.id, i.flags) : i);
888
888
  }
889
889
  return new Cr(t);
890
890
  }
@@ -1027,7 +1027,7 @@ class QO {
1027
1027
  [`NodeType.none`](#common.NodeType^none).
1028
1028
  */
1029
1029
  balance(e = {}) {
1030
- return this.children.length <= 8 ? this : Zr(LO.none, this.children, this.positions, 0, this.children.length, 0, this.length, (t, i, r) => new QO(this.type, t, i, r, this.propValues), e.makeTree || ((t, i, r) => new QO(LO.none, t, i, r)));
1030
+ return this.children.length <= 8 ? this : Zr(UO.none, this.children, this.positions, 0, this.children.length, 0, this.length, (t, i, r) => new QO(this.type, t, i, r, this.propValues), e.makeTree || ((t, i, r) => new QO(UO.none, t, i, r)));
1031
1031
  }
1032
1032
  /**
1033
1033
  Build a tree from a postfix-ordered buffer of node information,
@@ -1037,7 +1037,7 @@ class QO {
1037
1037
  return B5(e);
1038
1038
  }
1039
1039
  }
1040
- QO.empty = new QO(LO.none, [], [], 0);
1040
+ QO.empty = new QO(UO.none, [], [], 0);
1041
1041
  class Vr {
1042
1042
  constructor(e, t) {
1043
1043
  this.buffer = e, this.index = t;
@@ -1075,7 +1075,7 @@ class k1 {
1075
1075
  @internal
1076
1076
  */
1077
1077
  get type() {
1078
- return LO.none;
1078
+ return UO.none;
1079
1079
  }
1080
1080
  /**
1081
1081
  @internal
@@ -1792,12 +1792,12 @@ function wr(O) {
1792
1792
  function B5(O) {
1793
1793
  var e;
1794
1794
  let { buffer: t, nodeSet: i, maxBufferLength: r = Os, reused: a = [], minRepeatType: n = i.types.length } = O, s = Array.isArray(t) ? new Vr(t, t.length) : t, o = i.types, Q = 0, $ = 0;
1795
- function c(X, b, V, G, L, S) {
1796
- let { id: x, start: C, end: R, size: Y } = s, N = $, xO = Q;
1795
+ function c(X, y, V, G, L, S) {
1796
+ let { id: x, start: C, end: b, size: Y } = s, N = $, xO = Q;
1797
1797
  if (Y < 0)
1798
1798
  if (s.next(), Y == -1) {
1799
- let yO = a[x];
1800
- V.push(yO), G.push(C - X);
1799
+ let bO = a[x];
1800
+ V.push(bO), G.push(C - X);
1801
1801
  return;
1802
1802
  } else if (Y == -3) {
1803
1803
  Q = x;
@@ -1808,62 +1808,62 @@ function B5(O) {
1808
1808
  } else
1809
1809
  throw new RangeError(`Unrecognized record size: ${Y}`);
1810
1810
  let Q1 = o[x], U, hO, it = C - X;
1811
- if (R - C <= r && (hO = m(s.pos - b, L))) {
1812
- let yO = new Uint16Array(hO.size - hO.skip), bO = s.pos - hO.size, HO = yO.length;
1813
- for (; s.pos > bO; )
1814
- HO = P(hO.start, yO, HO);
1815
- U = new k1(yO, R - hO.start, i), it = hO.start - X;
1811
+ if (b - C <= r && (hO = w(s.pos - y, L))) {
1812
+ let bO = new Uint16Array(hO.size - hO.skip), RO = s.pos - hO.size, HO = bO.length;
1813
+ for (; s.pos > RO; )
1814
+ HO = P(hO.start, bO, HO);
1815
+ U = new k1(bO, b - hO.start, i), it = hO.start - X;
1816
1816
  } else {
1817
- let yO = s.pos - Y;
1817
+ let bO = s.pos - Y;
1818
1818
  s.next();
1819
- let bO = [], HO = [], L1 = x >= n ? x : -1, J1 = 0, rt = R;
1820
- for (; s.pos > yO; )
1821
- L1 >= 0 && s.id == L1 && s.size >= 0 ? (s.end <= rt - r && (f(bO, HO, C, J1, s.end, rt, L1, N, xO), J1 = bO.length, rt = s.end), s.next()) : S > 2500 ? d(C, yO, bO, HO) : c(C, yO, bO, HO, L1, S + 1);
1822
- if (L1 >= 0 && J1 > 0 && J1 < bO.length && f(bO, HO, C, J1, C, rt, L1, N, xO), bO.reverse(), HO.reverse(), L1 > -1 && J1 > 0) {
1819
+ let RO = [], HO = [], L1 = x >= n ? x : -1, J1 = 0, rt = b;
1820
+ for (; s.pos > bO; )
1821
+ L1 >= 0 && s.id == L1 && s.size >= 0 ? (s.end <= rt - r && (f(RO, HO, C, J1, s.end, rt, L1, N, xO), J1 = RO.length, rt = s.end), s.next()) : S > 2500 ? d(C, bO, RO, HO) : c(C, bO, RO, HO, L1, S + 1);
1822
+ if (L1 >= 0 && J1 > 0 && J1 < RO.length && f(RO, HO, C, J1, C, rt, L1, N, xO), RO.reverse(), HO.reverse(), L1 > -1 && J1 > 0) {
1823
1823
  let ta = h(Q1, xO);
1824
- U = Zr(Q1, bO, HO, 0, bO.length, 0, R - C, ta, ta);
1824
+ U = Zr(Q1, RO, HO, 0, RO.length, 0, b - C, ta, ta);
1825
1825
  } else
1826
- U = g(Q1, bO, HO, R - C, N - R, xO);
1826
+ U = g(Q1, RO, HO, b - C, N - b, xO);
1827
1827
  }
1828
1828
  V.push(U), G.push(it);
1829
1829
  }
1830
- function d(X, b, V, G) {
1830
+ function d(X, y, V, G) {
1831
1831
  let L = [], S = 0, x = -1;
1832
- for (; s.pos > b; ) {
1833
- let { id: C, start: R, end: Y, size: N } = s;
1832
+ for (; s.pos > y; ) {
1833
+ let { id: C, start: b, end: Y, size: N } = s;
1834
1834
  if (N > 4)
1835
1835
  s.next();
1836
1836
  else {
1837
- if (x > -1 && R < x)
1837
+ if (x > -1 && b < x)
1838
1838
  break;
1839
- x < 0 && (x = Y - r), L.push(C, R, Y), S++, s.next();
1839
+ x < 0 && (x = Y - r), L.push(C, b, Y), S++, s.next();
1840
1840
  }
1841
1841
  }
1842
1842
  if (S) {
1843
- let C = new Uint16Array(S * 4), R = L[L.length - 2];
1843
+ let C = new Uint16Array(S * 4), b = L[L.length - 2];
1844
1844
  for (let Y = L.length - 3, N = 0; Y >= 0; Y -= 3)
1845
- C[N++] = L[Y], C[N++] = L[Y + 1] - R, C[N++] = L[Y + 2] - R, C[N++] = N;
1846
- V.push(new k1(C, L[2] - R, i)), G.push(R - X);
1845
+ C[N++] = L[Y], C[N++] = L[Y + 1] - b, C[N++] = L[Y + 2] - b, C[N++] = N;
1846
+ V.push(new k1(C, L[2] - b, i)), G.push(b - X);
1847
1847
  }
1848
1848
  }
1849
- function h(X, b) {
1849
+ function h(X, y) {
1850
1850
  return (V, G, L) => {
1851
- let S = 0, x = V.length - 1, C, R;
1851
+ let S = 0, x = V.length - 1, C, b;
1852
1852
  if (x >= 0 && (C = V[x]) instanceof QO) {
1853
1853
  if (!x && C.type == X && C.length == L)
1854
1854
  return C;
1855
- (R = C.prop(I.lookAhead)) && (S = G[x] + C.length + R);
1855
+ (b = C.prop(I.lookAhead)) && (S = G[x] + C.length + b);
1856
1856
  }
1857
- return g(X, V, G, L, S, b);
1857
+ return g(X, V, G, L, S, y);
1858
1858
  };
1859
1859
  }
1860
- function f(X, b, V, G, L, S, x, C, R) {
1860
+ function f(X, y, V, G, L, S, x, C, b) {
1861
1861
  let Y = [], N = [];
1862
1862
  for (; X.length > G; )
1863
- Y.push(X.pop()), N.push(b.pop() + V - L);
1864
- X.push(g(i.types[x], Y, N, S - L, C - S, R)), b.push(L - V);
1863
+ Y.push(X.pop()), N.push(y.pop() + V - L);
1864
+ X.push(g(i.types[x], Y, N, S - L, C - S, b)), y.push(L - V);
1865
1865
  }
1866
- function g(X, b, V, G, L, S, x) {
1866
+ function g(X, y, V, G, L, S, x) {
1867
1867
  if (S) {
1868
1868
  let C = [I.contextHash, S];
1869
1869
  x = x ? [C].concat(x) : [C];
@@ -1872,18 +1872,18 @@ function B5(O) {
1872
1872
  let C = [I.lookAhead, L];
1873
1873
  x = x ? [C].concat(x) : [C];
1874
1874
  }
1875
- return new QO(X, b, V, G, x);
1875
+ return new QO(X, y, V, G, x);
1876
1876
  }
1877
- function m(X, b) {
1877
+ function w(X, y) {
1878
1878
  let V = s.fork(), G = 0, L = 0, S = 0, x = V.end - r, C = { size: 0, start: 0, skip: 0 };
1879
- O: for (let R = V.pos - X; V.pos > R; ) {
1879
+ O: for (let b = V.pos - X; V.pos > b; ) {
1880
1880
  let Y = V.size;
1881
- if (V.id == b && Y >= 0) {
1881
+ if (V.id == y && Y >= 0) {
1882
1882
  C.size = G, C.start = L, C.skip = S, S += 4, G += 4, V.next();
1883
1883
  continue;
1884
1884
  }
1885
1885
  let N = V.pos - Y;
1886
- if (Y < 0 || N < R || V.start < x)
1886
+ if (Y < 0 || N < b || V.start < x)
1887
1887
  break;
1888
1888
  let xO = V.id >= n ? 4 : 0, Q1 = V.start;
1889
1889
  for (V.next(); V.pos > N; ) {
@@ -1897,26 +1897,26 @@ function B5(O) {
1897
1897
  }
1898
1898
  L = Q1, G += Y, S += xO;
1899
1899
  }
1900
- return (b < 0 || G == X) && (C.size = G, C.start = L, C.skip = S), C.size > 4 ? C : void 0;
1900
+ return (y < 0 || G == X) && (C.size = G, C.start = L, C.skip = S), C.size > 4 ? C : void 0;
1901
1901
  }
1902
- function P(X, b, V) {
1902
+ function P(X, y, V) {
1903
1903
  let { id: G, start: L, end: S, size: x } = s;
1904
1904
  if (s.next(), x >= 0 && G < n) {
1905
1905
  let C = V;
1906
1906
  if (x > 4) {
1907
- let R = s.pos - (x - 4);
1908
- for (; s.pos > R; )
1909
- V = P(X, b, V);
1907
+ let b = s.pos - (x - 4);
1908
+ for (; s.pos > b; )
1909
+ V = P(X, y, V);
1910
1910
  }
1911
- b[--V] = C, b[--V] = S - X, b[--V] = L - X, b[--V] = G;
1911
+ y[--V] = C, y[--V] = S - X, y[--V] = L - X, y[--V] = G;
1912
1912
  } else x == -3 ? Q = G : x == -4 && ($ = G);
1913
1913
  return V;
1914
1914
  }
1915
- let y = [], w = [];
1915
+ let R = [], m = [];
1916
1916
  for (; s.pos > 0; )
1917
- c(O.start || 0, O.bufferStart || 0, y, w, -1, 0);
1918
- let T = (e = O.length) !== null && e !== void 0 ? e : y.length ? w[0] + y[0].length : 0;
1919
- return new QO(o[O.topID], y.reverse(), w.reverse(), T);
1917
+ c(O.start || 0, O.bufferStart || 0, R, m, -1, 0);
1918
+ let T = (e = O.length) !== null && e !== void 0 ? e : R.length ? m[0] + R[0].length : 0;
1919
+ return new QO(o[O.topID], R.reverse(), m.reverse(), T);
1920
1920
  }
1921
1921
  const ha = /* @__PURE__ */ new WeakMap();
1922
1922
  function ft(O, e) {
@@ -1944,27 +1944,27 @@ function Zr(O, e, t, i, r, a, n, s, o) {
1944
1944
  Q * 1.5 / 8
1945
1945
  /* Balance.BranchFactor */
1946
1946
  ), c = [], d = [];
1947
- function h(f, g, m, P, y) {
1948
- for (let w = m; w < P; ) {
1949
- let T = w, X = g[w], b = ft(O, f[w]);
1950
- for (w++; w < P; w++) {
1951
- let V = ft(O, f[w]);
1952
- if (b + V >= $)
1947
+ function h(f, g, w, P, R) {
1948
+ for (let m = w; m < P; ) {
1949
+ let T = m, X = g[m], y = ft(O, f[m]);
1950
+ for (m++; m < P; m++) {
1951
+ let V = ft(O, f[m]);
1952
+ if (y + V >= $)
1953
1953
  break;
1954
- b += V;
1954
+ y += V;
1955
1955
  }
1956
- if (w == T + 1) {
1957
- if (b > $) {
1956
+ if (m == T + 1) {
1957
+ if (y > $) {
1958
1958
  let V = f[T];
1959
- h(V.children, V.positions, 0, V.children.length, g[T] + y);
1959
+ h(V.children, V.positions, 0, V.children.length, g[T] + R);
1960
1960
  continue;
1961
1961
  }
1962
1962
  c.push(f[T]);
1963
1963
  } else {
1964
- let V = g[w - 1] + f[w - 1].length - X;
1965
- c.push(Zr(O, f, g, T, w, X, V, null, o));
1964
+ let V = g[m - 1] + f[m - 1].length - X;
1965
+ c.push(Zr(O, f, g, T, m, X, V, null, o));
1966
1966
  }
1967
- d.push(X + y - a);
1967
+ d.push(X + R - a);
1968
1968
  }
1969
1969
  }
1970
1970
  return h(e, t, i, r, 0), (s || o)(c, d, n);
@@ -2050,7 +2050,7 @@ let K5 = class {
2050
2050
  case will start at `ranges[0].from`.
2051
2051
  */
2052
2052
  startParse(e, t, i) {
2053
- return typeof e == "string" && (e = new H5(e)), i = i ? i.length ? i.map((r) => new qO(r.from, r.to)) : [new qO(0, 0)] : [new qO(0, e.length)], this.createParse(e, t || [], i);
2053
+ return typeof e == "string" && (e = new H5(e)), i = i ? i.length ? i.map((r) => new YO(r.from, r.to)) : [new YO(0, 0)] : [new YO(0, e.length)], this.createParse(e, t || [], i);
2054
2054
  }
2055
2055
  /**
2056
2056
  Run a full parse, returning the resulting tree.
@@ -2163,10 +2163,10 @@ class eQ {
2163
2163
  if (typeof a.overlay == "function")
2164
2164
  t = new OQ(a.parser, a.overlay, Q, this.inner.length, r.from, !!a.bracketed, r.tree, t);
2165
2165
  else {
2166
- let $ = Ta(this.ranges, a.overlay || (r.from < r.to ? [new qO(r.from, r.to)] : []));
2167
- $.length && fa($), ($.length || !a.overlay) && this.inner.push(new Pa(a.parser, $.length ? a.parser.startParse(this.input, ga(Q, $), $) : a.parser.startParse(""), a.overlay ? a.overlay.map((c) => new qO(c.from - r.from, c.to - r.from)) : null, !!a.bracketed, r.tree, $.length ? $[0].from : r.from)), a.overlay ? $.length && (i = { ranges: $, depth: 0, prev: i }) : s = !1;
2166
+ let $ = Ta(this.ranges, a.overlay || (r.from < r.to ? [new YO(r.from, r.to)] : []));
2167
+ $.length && fa($), ($.length || !a.overlay) && this.inner.push(new Pa(a.parser, $.length ? a.parser.startParse(this.input, ga(Q, $), $) : a.parser.startParse(""), a.overlay ? a.overlay.map((c) => new YO(c.from - r.from, c.to - r.from)) : null, !!a.bracketed, r.tree, $.length ? $[0].from : r.from)), a.overlay ? $.length && (i = { ranges: $, depth: 0, prev: i }) : s = !1;
2168
2168
  }
2169
- } else if (t && (o = t.predicate(r)) && (o === !0 && (o = new qO(r.from, r.to)), o.from < o.to)) {
2169
+ } else if (t && (o = t.predicate(r)) && (o === !0 && (o = new YO(r.from, r.to)), o.from < o.to)) {
2170
2170
  let Q = t.ranges.length - 1;
2171
2171
  Q >= 0 && t.ranges[Q].to == o.from ? t.ranges[Q] = { from: t.ranges[Q].from, to: o.to } : t.ranges.push(o);
2172
2172
  }
@@ -2178,7 +2178,7 @@ class eQ {
2178
2178
  break O;
2179
2179
  if (t && !--t.depth) {
2180
2180
  let Q = Ta(this.ranges, t.ranges);
2181
- Q.length && (fa(Q), this.inner.splice(t.index, 0, new Pa(t.parser, t.parser.startParse(this.input, ga(t.mounts, Q), Q), t.ranges.map(($) => new qO($.from - t.start, $.to - t.start)), t.bracketed, t.target, Q[0].from))), t = t.prev;
2181
+ Q.length && (fa(Q), this.inner.splice(t.index, 0, new Pa(t.parser, t.parser.startParse(this.input, ga(t.mounts, Q), Q), t.ranges.map(($) => new YO($.from - t.start, $.to - t.start)), t.bracketed, t.target, Q[0].from))), t = t.prev;
2182
2182
  }
2183
2183
  i && !--i.depth && (i = i.prev);
2184
2184
  }
@@ -2207,14 +2207,14 @@ function iQ(O) {
2207
2207
  while (!O.tree);
2208
2208
  let r = O.tree, a = r.children.indexOf(i), n = r.children[a], s = n.buffer, o = [a];
2209
2209
  function Q($, c, d, h, f, g) {
2210
- let m = t[g], P = [], y = [];
2211
- Sa(n, $, m, P, y, h);
2212
- let w = s[m + 1], T = s[m + 2];
2210
+ let w = t[g], P = [], R = [];
2211
+ Sa(n, $, w, P, R, h);
2212
+ let m = s[w + 1], T = s[w + 2];
2213
2213
  o.push(P.length);
2214
- let X = g ? Q(m + 4, s[m + 3], n.set.types[s[m]], w, T - w, g - 1) : e.toTree();
2215
- return P.push(X), y.push(w - h), Sa(n, s[m + 3], c, P, y, h), new QO(d, P, y, f);
2214
+ let X = g ? Q(w + 4, s[w + 3], n.set.types[s[w]], m, T - m, g - 1) : e.toTree();
2215
+ return P.push(X), R.push(m - h), Sa(n, s[w + 3], c, P, R, h), new QO(d, P, R, f);
2216
2216
  }
2217
- r.children[a] = Q(0, s.length, LO.none, 0, n.length, t.length - 1);
2217
+ r.children[a] = Q(0, s.length, UO.none, 0, n.length, t.length - 1);
2218
2218
  for (let $ of o) {
2219
2219
  let c = O.tree.children[$], d = O.tree.positions[$];
2220
2220
  O.yield(new TO(c, d + O.from, $, O._tree));
@@ -2297,7 +2297,7 @@ function Ta(O, e) {
2297
2297
  let o = i[a];
2298
2298
  if (o.from >= s)
2299
2299
  break;
2300
- o.to <= n || (t || (i = t = e.slice()), o.from < n ? (t[a] = new qO(o.from, n), o.to > s && t.splice(a + 1, 0, new qO(s, o.to))) : o.to > s ? t[a--] = new qO(s, o.to) : t.splice(a--, 1));
2300
+ o.to <= n || (t || (i = t = e.slice()), o.from < n ? (t[a] = new YO(o.from, n), o.to > s && t.splice(a + 1, 0, new YO(s, o.to))) : o.to > s ? t[a--] = new YO(s, o.to) : t.splice(a--, 1));
2301
2301
  }
2302
2302
  }
2303
2303
  return i;
@@ -2308,7 +2308,7 @@ function aQ(O, e, t, i) {
2308
2308
  let $ = r == O.length ? 1e9 : n ? O[r].to : O[r].from, c = a == e.length ? 1e9 : s ? e[a].to : e[a].from;
2309
2309
  if (n != s) {
2310
2310
  let d = Math.max(o, t), h = Math.min($, c, i);
2311
- d < h && Q.push(new qO(d, h));
2311
+ d < h && Q.push(new YO(d, h));
2312
2312
  }
2313
2313
  if (o = Math.min($, c), o == 1e9)
2314
2314
  break;
@@ -2321,7 +2321,7 @@ function ga(O, e) {
2321
2321
  for (let { pos: i, mount: r, frag: a } of O) {
2322
2322
  let n = i + (r.overlay ? r.overlay[0].from : 0), s = n + r.tree.length, o = Math.max(a.from, n), Q = Math.min(a.to, s);
2323
2323
  if (r.overlay) {
2324
- let $ = r.overlay.map((d) => new qO(d.from + i, d.to + i)), c = aQ(e, $, o, Q);
2324
+ let $ = r.overlay.map((d) => new YO(d.from + i, d.to + i)), c = aQ(e, $, o, Q);
2325
2325
  for (let d = 0, h = o; ; d++) {
2326
2326
  let f = d == c.length, g = f ? Q : c[d].from;
2327
2327
  if (g > h && t.push(new ze(h, g, r.tree, -n, a.from >= h || a.openStart, a.to <= g || a.openEnd)), f)
@@ -2545,15 +2545,15 @@ class uQ {
2545
2545
  return;
2546
2546
  let d = e.tree && e.tree.prop(I.mounted);
2547
2547
  if (d && d.overlay) {
2548
- let h = e.node.enter(d.overlay[0].from + s, 1), f = this.highlighters.filter((m) => !m.scope || m.scope(d.tree.type)), g = e.firstChild();
2549
- for (let m = 0, P = s; ; m++) {
2550
- let y = m < d.overlay.length ? d.overlay[m] : null, w = y ? y.from + s : o, T = Math.max(t, P), X = Math.min(i, w);
2548
+ let h = e.node.enter(d.overlay[0].from + s, 1), f = this.highlighters.filter((w) => !w.scope || w.scope(d.tree.type)), g = e.firstChild();
2549
+ for (let w = 0, P = s; ; w++) {
2550
+ let R = w < d.overlay.length ? d.overlay[w] : null, m = R ? R.from + s : o, T = Math.max(t, P), X = Math.min(i, m);
2551
2551
  if (T < X && g)
2552
- for (; e.from < X && (this.highlightRange(e, T, X, r, a), this.startSpan(Math.min(X, e.to), Q), !(e.to >= w || !e.nextSibling())); )
2552
+ for (; e.from < X && (this.highlightRange(e, T, X, r, a), this.startSpan(Math.min(X, e.to), Q), !(e.to >= m || !e.nextSibling())); )
2553
2553
  ;
2554
- if (!y || w > i)
2554
+ if (!R || m > i)
2555
2555
  break;
2556
- P = y.to + s, P > t && (this.highlightRange(h.cursor(), Math.max(t, y.from + s), Math.min(i, P), "", f), this.startSpan(Math.min(i, P), Q));
2556
+ P = R.to + s, P > t && (this.highlightRange(h.cursor(), Math.max(t, R.from + s), Math.min(i, P), "", f), this.startSpan(Math.min(i, P), Q));
2557
2557
  }
2558
2558
  g && e.parent();
2559
2559
  } else if (e.firstChild()) {
@@ -3062,18 +3062,18 @@ function li(O) {
3062
3062
  O = O.prev;
3063
3063
  }
3064
3064
  }
3065
- function ZO(O) {
3066
- var e = O.statementIndentUnit, t = O.dontAlignCalls, i = O.keywords || {}, r = O.types || {}, a = O.builtin || {}, n = O.blockKeywords || {}, s = O.defKeywords || {}, o = O.atoms || {}, Q = O.hooks || {}, $ = O.multiLineStrings, c = O.indentStatements !== !1, d = O.indentSwitch !== !1, h = O.namespaceSeparator, f = O.isPunctuationChar || /[\[\]{}\(\),;\:\.]/, g = O.numberStart || /[\d\.]/, m = O.number || /^(?:0x[a-f\d]+|0b[01]+|(?:\d+\.?\d*|\.\d+)(?:e[-+]?\d+)?)(u|ll?|l|f)?/i, P = O.isOperatorChar || /[+\-*&%=<>!?|\/]/, y = O.isIdentifierChar || /[\w\$_\xa1-\uffff]/, w = O.isReservedIdentifier || !1, T, X;
3067
- function b(S, x) {
3065
+ function yO(O) {
3066
+ var e = O.statementIndentUnit, t = O.dontAlignCalls, i = O.keywords || {}, r = O.types || {}, a = O.builtin || {}, n = O.blockKeywords || {}, s = O.defKeywords || {}, o = O.atoms || {}, Q = O.hooks || {}, $ = O.multiLineStrings, c = O.indentStatements !== !1, d = O.indentSwitch !== !1, h = O.namespaceSeparator, f = O.isPunctuationChar || /[\[\]{}\(\),;\:\.]/, g = O.numberStart || /[\d\.]/, w = O.number || /^(?:0x[a-f\d]+|0b[01]+|(?:\d+\.?\d*|\.\d+)(?:e[-+]?\d+)?)(u|ll?|l|f)?/i, P = O.isOperatorChar || /[+\-*&%=<>!?|\/]/, R = O.isIdentifierChar || /[\w\$_\xa1-\uffff]/, m = O.isReservedIdentifier || !1, T, X;
3067
+ function y(S, x) {
3068
3068
  var C = S.next();
3069
3069
  if (Q[C]) {
3070
- var R = Q[C](S, x);
3071
- if (R !== !1) return R;
3070
+ var b = Q[C](S, x);
3071
+ if (b !== !1) return b;
3072
3072
  }
3073
3073
  if (C == '"' || C == "'")
3074
3074
  return x.tokenize = V(C), x.tokenize(S, x);
3075
3075
  if (g.test(C)) {
3076
- if (S.backUp(1), S.match(m)) return "number";
3076
+ if (S.backUp(1), S.match(w)) return "number";
3077
3077
  S.next();
3078
3078
  }
3079
3079
  if (f.test(C))
@@ -3089,30 +3089,30 @@ function ZO(O) {
3089
3089
  ;
3090
3090
  return "operator";
3091
3091
  }
3092
- if (S.eatWhile(y), h) for (; S.match(h); )
3093
- S.eatWhile(y);
3092
+ if (S.eatWhile(R), h) for (; S.match(h); )
3093
+ S.eatWhile(R);
3094
3094
  var Y = S.current();
3095
- return h1(i, Y) ? (h1(n, Y) && (T = "newstatement"), h1(s, Y) && (X = !0), "keyword") : h1(r, Y) ? "type" : h1(a, Y) || w && w(Y) ? (h1(n, Y) && (T = "newstatement"), "builtin") : h1(o, Y) ? "atom" : "variable";
3095
+ return h1(i, Y) ? (h1(n, Y) && (T = "newstatement"), h1(s, Y) && (X = !0), "keyword") : h1(r, Y) ? "type" : h1(a, Y) || m && m(Y) ? (h1(n, Y) && (T = "newstatement"), "builtin") : h1(o, Y) ? "atom" : "variable";
3096
3096
  }
3097
3097
  function V(S) {
3098
3098
  return function(x, C) {
3099
- for (var R = !1, Y, N = !1; (Y = x.next()) != null; ) {
3100
- if (Y == S && !R) {
3099
+ for (var b = !1, Y, N = !1; (Y = x.next()) != null; ) {
3100
+ if (Y == S && !b) {
3101
3101
  N = !0;
3102
3102
  break;
3103
3103
  }
3104
- R = !R && Y == "\\";
3104
+ b = !b && Y == "\\";
3105
3105
  }
3106
- return (N || !(R || $)) && (C.tokenize = null), "string";
3106
+ return (N || !(b || $)) && (C.tokenize = null), "string";
3107
3107
  };
3108
3108
  }
3109
3109
  function G(S, x) {
3110
- for (var C = !1, R; R = S.next(); ) {
3111
- if (R == "/" && C) {
3110
+ for (var C = !1, b; b = S.next(); ) {
3111
+ if (b == "/" && C) {
3112
3112
  x.tokenize = null;
3113
3113
  break;
3114
3114
  }
3115
- C = R == "*";
3115
+ C = b == "*";
3116
3116
  }
3117
3117
  return "comment";
3118
3118
  }
@@ -3135,8 +3135,8 @@ function ZO(O) {
3135
3135
  if (S.sol() && (C.align == null && (C.align = !1), x.indented = S.indentation(), x.startOfLine = !0), S.eatSpace())
3136
3136
  return L(S, x), null;
3137
3137
  T = X = null;
3138
- var R = (x.tokenize || b)(S, x);
3139
- if (R == "comment" || R == "meta") return R;
3138
+ var b = (x.tokenize || y)(S, x);
3139
+ if (b == "comment" || b == "meta") return b;
3140
3140
  if (C.align == null && (C.align = !0), T == ";" || T == ":" || T == "," && S.match(/^\s*(?:\/\/.*)?$/, !1))
3141
3141
  for (; x.context.type == "statement"; ) Te(x);
3142
3142
  else if (T == "{") $t(x, S.column(), "}");
@@ -3146,29 +3146,29 @@ function ZO(O) {
3146
3146
  for (; C.type == "statement"; ) C = Te(x);
3147
3147
  for (C.type == "}" && (C = Te(x)); C.type == "statement"; ) C = Te(x);
3148
3148
  } else T == C.type ? Te(x) : c && ((C.type == "}" || C.type == "top") && T != ";" || C.type == "statement" && T == "newstatement") && $t(x, S.column(), "statement", S.current());
3149
- if (R == "variable" && (x.prevToken == "def" || O.typeFirstDefinitions && Ca(S, x, S.start) && li(x.context) && S.match(/^\s*\(/, !1)) && (R = "def"), Q.token) {
3150
- var Y = Q.token(S, x, R);
3151
- Y !== void 0 && (R = Y);
3149
+ if (b == "variable" && (x.prevToken == "def" || O.typeFirstDefinitions && Ca(S, x, S.start) && li(x.context) && S.match(/^\s*\(/, !1)) && (b = "def"), Q.token) {
3150
+ var Y = Q.token(S, x, b);
3151
+ Y !== void 0 && (b = Y);
3152
3152
  }
3153
- return R == "def" && O.styleDefs === !1 && (R = "variable"), x.startOfLine = !1, x.prevToken = X ? "def" : R || T, L(S, x), R;
3153
+ return b == "def" && O.styleDefs === !1 && (b = "variable"), x.startOfLine = !1, x.prevToken = X ? "def" : b || T, L(S, x), b;
3154
3154
  },
3155
3155
  indent: function(S, x, C) {
3156
- if (S.tokenize != b && S.tokenize != null || S.typeAtEndOfLine && li(S.context))
3156
+ if (S.tokenize != y && S.tokenize != null || S.typeAtEndOfLine && li(S.context))
3157
3157
  return null;
3158
- var R = S.context, Y = x && x.charAt(0), N = Y == R.type;
3159
- if (R.type == "statement" && Y == "}" && (R = R.prev), O.dontIndentStatements)
3160
- for (; R.type == "statement" && O.dontIndentStatements.test(R.info); )
3161
- R = R.prev;
3158
+ var b = S.context, Y = x && x.charAt(0), N = Y == b.type;
3159
+ if (b.type == "statement" && Y == "}" && (b = b.prev), O.dontIndentStatements)
3160
+ for (; b.type == "statement" && O.dontIndentStatements.test(b.info); )
3161
+ b = b.prev;
3162
3162
  if (Q.indent) {
3163
- var xO = Q.indent(S, R, x, C.unit);
3163
+ var xO = Q.indent(S, b, x, C.unit);
3164
3164
  if (typeof xO == "number") return xO;
3165
3165
  }
3166
- var Q1 = R.prev && R.prev.info == "switch";
3166
+ var Q1 = b.prev && b.prev.info == "switch";
3167
3167
  if (O.allmanIndentation && /[{(]/.test(Y)) {
3168
- for (; R.type != "top" && R.type != "}"; ) R = R.prev;
3169
- return R.indented;
3168
+ for (; b.type != "top" && b.type != "}"; ) b = b.prev;
3169
+ return b.indented;
3170
3170
  }
3171
- return R.type == "statement" ? R.indented + (Y == "{" ? 0 : e || C.unit) : R.align && (!t || R.type != ")") ? R.column + (N ? 0 : 1) : R.type == ")" && !N ? R.indented + (e || C.unit) : R.indented + (N ? 0 : C.unit) + (!N && Q1 && !/^(?:case|default)\b/.test(x) ? C.unit : 0);
3171
+ return b.type == "statement" ? b.indented + (Y == "{" ? 0 : e || C.unit) : b.align && (!t || b.type != ")") ? b.column + (N ? 0 : 1) : b.type == ")" && !N ? b.indented + (e || C.unit) : b.indented + (N ? 0 : C.unit) + (!N && Q1 && !/^(?:case|default)\b/.test(x) ? C.unit : 0);
3172
3172
  },
3173
3173
  languageData: {
3174
3174
  indentOnInput: d ? /^\s*(?:case .*?:|default:|\{\}?|\})$/ : /^\s*[{}]$/,
@@ -3241,7 +3241,7 @@ function wa(O, e) {
3241
3241
  var t = e.cpp11RawStringDelim.replace(/[^\w\s]/g, "\\$&"), i = O.match(new RegExp(".*?\\)" + t + '"'));
3242
3242
  return i ? e.tokenize = null : O.skipToEnd(), "string";
3243
3243
  }
3244
- ZO({
3244
+ yO({
3245
3245
  name: "c",
3246
3246
  keywords: q(Ne),
3247
3247
  types: Be,
@@ -3255,7 +3255,7 @@ ZO({
3255
3255
  "*": Nt
3256
3256
  }
3257
3257
  });
3258
- ZO({
3258
+ yO({
3259
3259
  name: "cpp",
3260
3260
  keywords: q(Ne + " " + as),
3261
3261
  types: Be,
@@ -3290,7 +3290,7 @@ ZO({
3290
3290
  },
3291
3291
  namespaceSeparator: "::"
3292
3292
  });
3293
- const SQ = ZO({
3293
+ const SQ = yO({
3294
3294
  name: "java",
3295
3295
  keywords: q("abstract assert break case catch class const continue default do else enum extends final finally for goto if implements import instanceof interface native new package private protected public return static strictfp super switch synchronized this throw throws transient try volatile while @interface"),
3296
3296
  types: q("var byte short int long float double boolean char void Boolean Byte Character Double Float Integer Long Number Object Short String StringBuffer StringBuilder Void"),
@@ -3307,7 +3307,7 @@ const SQ = ZO({
3307
3307
  return O.match(/""$/) ? (e.tokenize = ls, e.tokenize(O, e)) : !1;
3308
3308
  }
3309
3309
  }
3310
- }), XQ = ZO({
3310
+ }), XQ = yO({
3311
3311
  name: "csharp",
3312
3312
  keywords: q("abstract as async await base break case catch checked class const continue default delegate do else enum event explicit extern finally fixed for foreach goto if implicit in init interface internal is lock namespace new operator out override params private protected public readonly record ref required return sealed sizeof stackalloc static struct switch this throw try typeof unchecked unsafe using virtual void volatile while add alias ascending descending dynamic from get global group into join let orderby partial remove select set value var yield"),
3313
3313
  types: q("Action Boolean Byte Char DateTime DateTimeOffset Decimal Double Func Guid Int16 Int32 Int64 Object SByte Single String Task TimeSpan UInt16 UInt32 UInt64 bool byte char decimal double short int long object sbyte float string ushort uint ulong"),
@@ -3345,7 +3345,7 @@ function qe(O) {
3345
3345
  return "comment";
3346
3346
  };
3347
3347
  }
3348
- ZO({
3348
+ yO({
3349
3349
  name: "scala",
3350
3350
  keywords: q(
3351
3351
  /* scala */
@@ -3399,7 +3399,7 @@ function TQ(O) {
3399
3399
  return (a || !O) && (t.tokenize = null), "string";
3400
3400
  };
3401
3401
  }
3402
- ZO({
3402
+ yO({
3403
3403
  name: "kotlin",
3404
3404
  keywords: q(
3405
3405
  /*keywords*/
@@ -3442,7 +3442,7 @@ ZO({
3442
3442
  closeBrackets: { brackets: ["(", "[", "{", "'", '"', '"""'] }
3443
3443
  }
3444
3444
  });
3445
- ZO({
3445
+ yO({
3446
3446
  name: "shader",
3447
3447
  keywords: q("sampler1D sampler2D sampler3D samplerCube sampler1DShadow sampler2DShadow const attribute uniform varying break continue discard return for while do if else struct in out inout"),
3448
3448
  types: q("float int bool void vec2 vec3 vec4 ivec2 ivec3 ivec4 bvec2 bvec3 bvec4 mat2 mat3 mat4"),
@@ -3452,7 +3452,7 @@ ZO({
3452
3452
  indentSwitch: !1,
3453
3453
  hooks: { "#": Y1 }
3454
3454
  });
3455
- ZO({
3455
+ yO({
3456
3456
  name: "nesc",
3457
3457
  keywords: q(Ne + " as atomic async call command component components configuration event generic implementation includes interface module new norace nx_struct nx_union post provides signal task uses abstract extends"),
3458
3458
  types: Be,
@@ -3460,7 +3460,7 @@ ZO({
3460
3460
  atoms: q("null true false"),
3461
3461
  hooks: { "#": Y1 }
3462
3462
  });
3463
- ZO({
3463
+ yO({
3464
3464
  name: "objectivec",
3465
3465
  keywords: q(Ne + " " + ns),
3466
3466
  types: os,
@@ -3476,7 +3476,7 @@ ZO({
3476
3476
  "*": Nt
3477
3477
  }
3478
3478
  });
3479
- ZO({
3479
+ yO({
3480
3480
  name: "objectivecpp",
3481
3481
  keywords: q(Ne + " " + ns + " " + as),
3482
3482
  types: os,
@@ -3511,7 +3511,7 @@ ZO({
3511
3511
  },
3512
3512
  namespaceSeparator: "::"
3513
3513
  });
3514
- ZO({
3514
+ yO({
3515
3515
  name: "squirrel",
3516
3516
  keywords: q("base break clone continue const default delete enum extends function in class foreach local resume return this throw typeof yield constructor instanceof static"),
3517
3517
  types: Be,
@@ -3538,7 +3538,7 @@ function $s(O) {
3538
3538
  return a && (t.tokenize = null), "string";
3539
3539
  };
3540
3540
  }
3541
- ZO({
3541
+ yO({
3542
3542
  name: "ceylon",
3543
3543
  keywords: q("abstracts alias assembly assert assign break case catch class continue dynamic else exists extends finally for function given if import in interface is let module new nonempty object of out outer package return satisfies super switch then this throw try value void while"),
3544
3544
  types: function(O) {
@@ -3614,7 +3614,7 @@ function xQ(O, e) {
3614
3614
  function CQ(O, e) {
3615
3615
  return O.eatWhile(/[\w_]/), e.tokenize = cs(e), "variable";
3616
3616
  }
3617
- ZO({
3617
+ yO({
3618
3618
  name: "dart",
3619
3619
  keywords: q("this super static final const abstract class extends external factory implements mixin get native set typedef with enum throw rethrow assert break case continue default in return new deferred async await covariant try catch finally do else for if switch while import library export part of show hide is as extension on yield late required sealed base interface when inline"),
3620
3620
  blockKeywords: q("try catch finally do else for if switch while"),
@@ -4304,10 +4304,10 @@ function us(O, e, t, i, r, a) {
4304
4304
  continue O;
4305
4305
  }
4306
4306
  for (; c < d; ) {
4307
- let h = c + d >> 1, f = Q + h + (h << 1), g = O[f], m = O[f + 1] || 65536;
4307
+ let h = c + d >> 1, f = Q + h + (h << 1), g = O[f], w = O[f + 1] || 65536;
4308
4308
  if ($ < g)
4309
4309
  d = h;
4310
- else if ($ >= m)
4310
+ else if ($ >= w)
4311
4311
  c = h + 1;
4312
4312
  else {
4313
4313
  n = O[f + 2], e.advance();
@@ -4713,7 +4713,7 @@ class wO extends K5 {
4713
4713
  }
4714
4714
  }
4715
4715
  }
4716
- this.nodeSet = new Cr(t.map((s, o) => LO.define({
4716
+ this.nodeSet = new Cr(t.map((s, o) => UO.define({
4717
4717
  name: o >= this.minRepeatTerm ? void 0 : s,
4718
4718
  id: o,
4719
4719
  props: r[o],
@@ -7040,31 +7040,31 @@ const ud = new F((O) => {
7040
7040
  specialized: [{ term: 503, get: (O, e) => cn(O) << 1 | 1, external: cn, extend: !0 }],
7041
7041
  tokenPrec: 15412
7042
7042
  });
7043
- function RO(O) {
7043
+ function _O(O) {
7044
7044
  return Gn.define({ parser: O });
7045
7045
  }
7046
7046
  const tr = /* @__PURE__ */ new Map([
7047
7047
  ["csharp", { name: "C#", lang: na.define(XQ), aliases: ["cs"] }],
7048
- ["rust", { name: "Rust", lang: RO(p0), aliases: ["rs"] }],
7049
- ["javascript", { name: "JavaScript", lang: RO(Ni), aliases: ["js"] }],
7050
- ["typescript", { name: "TypeScript", lang: RO(Ni), aliases: ["ts"] }],
7051
- ["json", { name: "JSON", lang: RO(h$), aliases: [] }],
7052
- ["yaml", { name: "YAML", lang: RO(j0), aliases: [] }],
7048
+ ["rust", { name: "Rust", lang: _O(p0), aliases: ["rs"] }],
7049
+ ["javascript", { name: "JavaScript", lang: _O(Ni), aliases: ["js"] }],
7050
+ ["typescript", { name: "TypeScript", lang: _O(Ni), aliases: ["ts"] }],
7051
+ ["json", { name: "JSON", lang: _O(h$), aliases: [] }],
7052
+ ["yaml", { name: "YAML", lang: _O(j0), aliases: [] }],
7053
7053
  ["java", { name: "Java", lang: na.define(SQ), aliases: [] }],
7054
- ["go", { name: "Go", lang: RO(al), aliases: [] }],
7055
- ["python", { name: "Python", lang: RO(N7), aliases: ["py"] }],
7056
- ["html", { name: "HTML", lang: RO(Wl), aliases: [] }],
7057
- ["cli", { name: "CLI", lang: RO(Ti), aliases: [] }],
7058
- ["php", { name: "PHP", lang: RO(L9.configure({ top: "Program" })), aliases: [] }],
7054
+ ["go", { name: "Go", lang: _O(al), aliases: [] }],
7055
+ ["python", { name: "Python", lang: _O(N7), aliases: ["py"] }],
7056
+ ["html", { name: "HTML", lang: _O(Wl), aliases: [] }],
7057
+ ["cli", { name: "CLI", lang: _O(Ti), aliases: [] }],
7058
+ ["php", { name: "PHP", lang: _O(L9.configure({ top: "Program" })), aliases: [] }],
7059
7059
  [
7060
7060
  "syntax",
7061
- { name: "Syntax", lang: RO(Ti.configure({ top: "Syntax" })), aliases: [] }
7061
+ { name: "Syntax", lang: _O(Ti.configure({ top: "Syntax" })), aliases: [] }
7062
7062
  ],
7063
7063
  [
7064
7064
  "surrealql",
7065
7065
  {
7066
7066
  name: "SurrealQL",
7067
- lang: RO(Ti),
7067
+ lang: _O(Ti),
7068
7068
  aliases: ["surql", "sql"],
7069
7069
  extension: () => R3()
7070
7070
  }
@@ -7374,16 +7374,16 @@ function Gg(O = {}) {
7374
7374
  onChangeDocument: $,
7375
7375
  onChangeSelection: c,
7376
7376
  onChangeState: d
7377
- } = O, { colorScheme: h } = An(), [f, g] = j(!1), m = VO(null), P = VO(null), y = VO(null), w = VO(new oa()), T = VO(new oa()), X = sO((S) => {
7377
+ } = O, { colorScheme: h } = An(), [f, g] = j(!1), w = VO(null), P = VO(null), R = VO(null), m = VO(new oa()), T = VO(new oa()), X = sO((S) => {
7378
7378
  if ($ && S.docChanged && $?.(S.state.doc.toString()), c && S.selectionSet && c?.(S.state.selection), d && (S.docChanged || S.selectionSet)) {
7379
7379
  const x = S.state.toJSON(e);
7380
- d?.(x), y.current = x;
7380
+ d?.(x), R.current = x;
7381
7381
  }
7382
- }), b = tO(
7382
+ }), y = tO(
7383
7383
  () => ({
7384
7384
  extensions: [
7385
7385
  ie.updateListener.of(X),
7386
- w.current.of([]),
7386
+ m.current.of([]),
7387
7387
  T.current.of(n ?? []),
7388
7388
  wd()
7389
7389
  ]
@@ -7393,7 +7393,7 @@ function Gg(O = {}) {
7393
7393
  const S = P.current;
7394
7394
  S && S.dispatch({
7395
7395
  effects: [
7396
- w.current.reconfigure([
7396
+ m.current.reconfigure([
7397
7397
  Ze.readOnly.of(a),
7398
7398
  hQ(i, h),
7399
7399
  Ln({ newGroupDelay: 250 }),
@@ -7402,21 +7402,21 @@ function Gg(O = {}) {
7402
7402
  ]
7403
7403
  });
7404
7404
  }), G = sO((S) => {
7405
- P.current && (xd(y.current, S) || (P.current.setState(Ze.fromJSON(S, b, e)), y.current = S, V()));
7405
+ P.current && (xd(R.current, S) || (P.current.setState(Ze.fromJSON(S, y, e)), R.current = S, V()));
7406
7406
  }), L = sO(() => {
7407
7407
  if (!P.current)
7408
7408
  throw new Error("Editor not initialized");
7409
7409
  return P.current;
7410
7410
  });
7411
7411
  return H(() => {
7412
- if (!m.current) return;
7412
+ if (!w.current) return;
7413
7413
  const S = new ie({
7414
- parent: m.current,
7414
+ parent: w.current,
7415
7415
  scrollTo: ie.scrollIntoView(0),
7416
- state: Ze.create(b)
7416
+ state: Ze.create(y)
7417
7417
  });
7418
7418
  return P.current = S, g(!0), Q?.(S), () => {
7419
- S.destroy(), P.current = null, y.current = null, g(!1);
7419
+ S.destroy(), P.current = null, R.current = null, g(!1);
7420
7420
  };
7421
7421
  }, []), H(() => {
7422
7422
  V();
@@ -7432,7 +7432,7 @@ function Gg(O = {}) {
7432
7432
  }));
7433
7433
  }, [n, s]), tO(
7434
7434
  () => ({
7435
- ref: m,
7435
+ ref: w,
7436
7436
  mounted: f,
7437
7437
  getEditor: L,
7438
7438
  restoreState: G
@@ -7565,7 +7565,7 @@ const ks = ({
7565
7565
  const o = [], Q = Sd(e), $ = t === "auto" ? n : t, c = [];
7566
7566
  let d = [], h = 0;
7567
7567
  const f = (P) => i.some(
7568
- (y) => P >= y.start && P <= y.end
7568
+ (R) => P >= R.start && P <= R.end
7569
7569
  ), g = ({ lineIndex: P }) => r && /* @__PURE__ */ p(
7570
7570
  "span",
7571
7571
  {
@@ -7575,7 +7575,7 @@ const ks = ({
7575
7575
  },
7576
7576
  children: P + 1
7577
7577
  }
7578
- ), m = () => {
7578
+ ), w = () => {
7579
7579
  if (d.length > 0) {
7580
7580
  const P = [...d];
7581
7581
  f(h) ? c.push([
@@ -7649,12 +7649,12 @@ const ks = ({
7649
7649
  O,
7650
7650
  Q.parse(O),
7651
7651
  yd($),
7652
- (P, y) => {
7652
+ (P, R) => {
7653
7653
  d.push(
7654
7654
  /* @__PURE__ */ p(
7655
7655
  "span",
7656
7656
  {
7657
- style: { color: y },
7657
+ style: { color: R },
7658
7658
  children: P
7659
7659
  },
7660
7660
  `span-${h}-${d.length}`
@@ -7662,11 +7662,11 @@ const ks = ({
7662
7662
  );
7663
7663
  },
7664
7664
  () => {
7665
- m();
7665
+ w();
7666
7666
  }
7667
- ), d.length > 0 && m()) : O.split(`
7668
- `).forEach((y, w) => {
7669
- d = [/* @__PURE__ */ p("span", { children: y }, `text-${w}`)], m();
7667
+ ), d.length > 0 && w()) : O.split(`
7668
+ `).forEach((R, m) => {
7669
+ d = [/* @__PURE__ */ p("span", { children: R }, `text-${m}`)], w();
7670
7670
  }), c.forEach((P) => {
7671
7671
  o.push(...P);
7672
7672
  }), o;
@@ -8483,16 +8483,16 @@ function ih({
8483
8483
  ...e
8484
8484
  }), [e, n]), o = M(
8485
8485
  ($, c, d, h) => {
8486
- const f = $.id, g = typeof f == "string" ? f : c, m = () => s[$.type];
8486
+ const f = $.id, g = typeof f == "string" ? f : c, w = () => s[$.type];
8487
8487
  if ($.type === "text")
8488
8488
  return $.value;
8489
8489
  let P = h;
8490
8490
  if ($.type === "table" && (P = { table: $ }), eh($)) {
8491
- const w = m(), T = $, X = T.children[0], b = T.children.slice(1), V = X ? o(X, 0, $, P) : null, G = b.map(
8491
+ const m = w(), T = $, X = T.children[0], y = T.children.slice(1), V = X ? o(X, 0, $, P) : null, G = y.map(
8492
8492
  (L, S) => o(L, S + 1, $, P)
8493
8493
  );
8494
8494
  return /* @__PURE__ */ v(
8495
- w,
8495
+ m,
8496
8496
  {
8497
8497
  node: $,
8498
8498
  children: [
@@ -8504,9 +8504,9 @@ function ih({
8504
8504
  );
8505
8505
  }
8506
8506
  if (th($)) {
8507
- const w = m();
8507
+ const m = w();
8508
8508
  return /* @__PURE__ */ p(
8509
- w,
8509
+ m,
8510
8510
  {
8511
8511
  node: $,
8512
8512
  children: $.children.map((T, X) => o(T, X, $, P))
@@ -8514,9 +8514,9 @@ function ih({
8514
8514
  g
8515
8515
  );
8516
8516
  }
8517
- const y = m();
8517
+ const R = w();
8518
8518
  return /* @__PURE__ */ p(
8519
- y,
8519
+ R,
8520
8520
  {
8521
8521
  node: $
8522
8522
  },
@@ -8656,10 +8656,10 @@ function q1(O, e) {
8656
8656
  var D = function(e, t) {
8657
8657
  t === void 0 && (t = {}), this.label = e, this.keyword = t.keyword, this.beforeExpr = !!t.beforeExpr, this.startsExpr = !!t.startsExpr, this.isLoop = !!t.isLoop, this.isAssign = !!t.isAssign, this.prefix = !!t.prefix, this.postfix = !!t.postfix, this.binop = t.binop || null, this.updateContext = null;
8658
8658
  };
8659
- function _O(O, e) {
8659
+ function vO(O, e) {
8660
8660
  return new D(O, { beforeExpr: !0, binop: e });
8661
8661
  }
8662
- var vO = { beforeExpr: !0 }, XO = { startsExpr: !0 }, Mr = {};
8662
+ var zO = { beforeExpr: !0 }, XO = { startsExpr: !0 }, Mr = {};
8663
8663
  function E(O, e) {
8664
8664
  return e === void 0 && (e = {}), e.keyword = O, Mr[O] = new D(O, e);
8665
8665
  }
@@ -8677,16 +8677,16 @@ var u = {
8677
8677
  braceR: new D("}"),
8678
8678
  parenL: new D("(", { beforeExpr: !0, startsExpr: !0 }),
8679
8679
  parenR: new D(")"),
8680
- comma: new D(",", vO),
8681
- semi: new D(";", vO),
8682
- colon: new D(":", vO),
8680
+ comma: new D(",", zO),
8681
+ semi: new D(";", zO),
8682
+ colon: new D(":", zO),
8683
8683
  dot: new D("."),
8684
- question: new D("?", vO),
8684
+ question: new D("?", zO),
8685
8685
  questionDot: new D("?."),
8686
- arrow: new D("=>", vO),
8686
+ arrow: new D("=>", zO),
8687
8687
  template: new D("template"),
8688
8688
  invalidTemplate: new D("invalidTemplate"),
8689
- ellipsis: new D("...", vO),
8689
+ ellipsis: new D("...", zO),
8690
8690
  backQuote: new D("`", XO),
8691
8691
  dollarBraceL: new D("${", { beforeExpr: !0, startsExpr: !0 }),
8692
8692
  // Operators. These carry several kinds of properties to help the
@@ -8706,36 +8706,36 @@ var u = {
8706
8706
  assign: new D("_=", { beforeExpr: !0, isAssign: !0 }),
8707
8707
  incDec: new D("++/--", { prefix: !0, postfix: !0, startsExpr: !0 }),
8708
8708
  prefix: new D("!/~", { beforeExpr: !0, prefix: !0, startsExpr: !0 }),
8709
- logicalOR: _O("||", 1),
8710
- logicalAND: _O("&&", 2),
8711
- bitwiseOR: _O("|", 3),
8712
- bitwiseXOR: _O("^", 4),
8713
- bitwiseAND: _O("&", 5),
8714
- equality: _O("==/!=/===/!==", 6),
8715
- relational: _O("</>/<=/>=", 7),
8716
- bitShift: _O("<</>>/>>>", 8),
8709
+ logicalOR: vO("||", 1),
8710
+ logicalAND: vO("&&", 2),
8711
+ bitwiseOR: vO("|", 3),
8712
+ bitwiseXOR: vO("^", 4),
8713
+ bitwiseAND: vO("&", 5),
8714
+ equality: vO("==/!=/===/!==", 6),
8715
+ relational: vO("</>/<=/>=", 7),
8716
+ bitShift: vO("<</>>/>>>", 8),
8717
8717
  plusMin: new D("+/-", { beforeExpr: !0, binop: 9, prefix: !0, startsExpr: !0 }),
8718
- modulo: _O("%", 10),
8719
- star: _O("*", 10),
8720
- slash: _O("/", 10),
8718
+ modulo: vO("%", 10),
8719
+ star: vO("*", 10),
8720
+ slash: vO("/", 10),
8721
8721
  starstar: new D("**", { beforeExpr: !0 }),
8722
- coalesce: _O("??", 1),
8722
+ coalesce: vO("??", 1),
8723
8723
  // Keyword token types.
8724
8724
  _break: E("break"),
8725
- _case: E("case", vO),
8725
+ _case: E("case", zO),
8726
8726
  _catch: E("catch"),
8727
8727
  _continue: E("continue"),
8728
8728
  _debugger: E("debugger"),
8729
- _default: E("default", vO),
8729
+ _default: E("default", zO),
8730
8730
  _do: E("do", { isLoop: !0, beforeExpr: !0 }),
8731
- _else: E("else", vO),
8731
+ _else: E("else", zO),
8732
8732
  _finally: E("finally"),
8733
8733
  _for: E("for", { isLoop: !0 }),
8734
8734
  _function: E("function", XO),
8735
8735
  _if: E("if"),
8736
- _return: E("return", vO),
8736
+ _return: E("return", zO),
8737
8737
  _switch: E("switch"),
8738
- _throw: E("throw", vO),
8738
+ _throw: E("throw", zO),
8739
8739
  _try: E("try"),
8740
8740
  _var: E("var"),
8741
8741
  _const: E("const"),
@@ -8745,7 +8745,7 @@ var u = {
8745
8745
  _this: E("this", XO),
8746
8746
  _super: E("super", XO),
8747
8747
  _class: E("class", XO),
8748
- _extends: E("extends", vO),
8748
+ _extends: E("extends", zO),
8749
8749
  _export: E("export"),
8750
8750
  _import: E("import", XO),
8751
8751
  _null: E("null", XO),
@@ -9970,8 +9970,8 @@ W.parseSubscript = function(O, e, t, i, r, a, n) {
9970
9970
  if (r && !o && this.shouldParseAsyncArrow())
9971
9971
  return this.checkPatternErrors(c, !1), this.checkYieldAwaitInDefaultParams(), this.awaitIdentPos > 0 && this.raise(this.awaitIdentPos, "Cannot use 'await' as identifier inside an async function"), this.yieldPos = d, this.awaitPos = h, this.awaitIdentPos = f, this.parseSubscriptAsyncArrow(e, t, g, n);
9972
9972
  this.checkExpressionErrors(c, !0), this.yieldPos = d || this.yieldPos, this.awaitPos = h || this.awaitPos, this.awaitIdentPos = f || this.awaitIdentPos;
9973
- var m = this.startNodeAt(e, t);
9974
- m.callee = O, m.arguments = g, s && (m.optional = o), O = this.finishNode(m, "CallExpression");
9973
+ var w = this.startNodeAt(e, t);
9974
+ w.callee = O, w.arguments = g, s && (w.optional = o), O = this.finishNode(w, "CallExpression");
9975
9975
  } else if (this.type === u.backQuote) {
9976
9976
  (o || a) && this.raise(this.start, "Optional chaining cannot appear in the tag of tagged template expressions");
9977
9977
  var P = this.startNodeAt(e, t);
@@ -10085,10 +10085,10 @@ W.parseParenAndDistinguishExpression = function(O, e) {
10085
10085
  break;
10086
10086
  } else
10087
10087
  o.push(this.parseMaybeAssign(!1, c, this.parseParenItem));
10088
- var g = this.lastTokEnd, m = this.lastTokEndLoc;
10088
+ var g = this.lastTokEnd, w = this.lastTokEndLoc;
10089
10089
  if (this.expect(u.parenR), O && this.shouldParseArrow(o) && this.eat(u.arrow))
10090
10090
  return this.checkPatternErrors(c, !1), this.checkYieldAwaitInDefaultParams(), this.yieldPos = d, this.awaitPos = h, this.parseParenArrowList(t, i, o, e);
10091
- (!o.length || $) && this.unexpected(this.lastTokStart), f && this.unexpected(f), this.checkExpressionErrors(c, !0), this.yieldPos = d || this.yieldPos, this.awaitPos = h || this.awaitPos, o.length > 1 ? (r = this.startNodeAt(n, s), r.expressions = o, this.finishNodeAt(r, "SequenceExpression", g, m)) : r = o[0];
10091
+ (!o.length || $) && this.unexpected(this.lastTokStart), f && this.unexpected(f), this.checkExpressionErrors(c, !0), this.yieldPos = d || this.yieldPos, this.awaitPos = h || this.awaitPos, o.length > 1 ? (r = this.startNodeAt(n, s), r.expressions = o, this.finishNodeAt(r, "SequenceExpression", g, w)) : r = o[0];
10092
10092
  } else
10093
10093
  r = this.parseParenExpression();
10094
10094
  if (this.options.preserveParens) {
@@ -10869,7 +10869,7 @@ z.regexp_eatDecimalEscape = function(O) {
10869
10869
  }
10870
10870
  return !1;
10871
10871
  };
10872
- var fo = 0, C1 = 1, kO = 2;
10872
+ var fo = 0, C1 = 1, qO = 2;
10873
10873
  z.regexp_eatCharacterClassEscape = function(O) {
10874
10874
  var e = O.current();
10875
10875
  if (Hh(e))
@@ -10885,7 +10885,7 @@ z.regexp_eatCharacterClassEscape = function(O) {
10885
10885
  125
10886
10886
  /* } */
10887
10887
  ))
10888
- return t && i === kO && O.raise("Invalid property name"), i;
10888
+ return t && i === qO && O.raise("Invalid property name"), i;
10889
10889
  O.raise("Invalid property name");
10890
10890
  }
10891
10891
  return fo;
@@ -10918,7 +10918,7 @@ z.regexp_validateUnicodePropertyNameOrValue = function(O, e) {
10918
10918
  if (O.unicodeProperties.binary.test(e))
10919
10919
  return C1;
10920
10920
  if (O.switchV && O.unicodeProperties.binaryOfStrings.test(e))
10921
- return kO;
10921
+ return qO;
10922
10922
  O.raise("Invalid property name");
10923
10923
  };
10924
10924
  z.regexp_eatUnicodePropertyName = function(O) {
@@ -10954,7 +10954,7 @@ z.regexp_eatCharacterClass = function(O) {
10954
10954
  return O.eat(
10955
10955
  93
10956
10956
  /* ] */
10957
- ) || O.raise("Unterminated character class"), e && t === kO && O.raise("Negated character class may contain strings"), !0;
10957
+ ) || O.raise("Unterminated character class"), e && t === qO && O.raise("Negated character class may contain strings"), !0;
10958
10958
  }
10959
10959
  return !1;
10960
10960
  };
@@ -11015,13 +11015,13 @@ z.regexp_eatClassEscape = function(O) {
11015
11015
  z.regexp_classSetExpression = function(O) {
11016
11016
  var e = C1, t;
11017
11017
  if (!this.regexp_eatClassSetRange(O)) if (t = this.regexp_eatClassSetOperand(O)) {
11018
- t === kO && (e = kO);
11018
+ t === qO && (e = qO);
11019
11019
  for (var i = O.pos; O.eatChars(
11020
11020
  [38, 38]
11021
11021
  /* && */
11022
11022
  ); ) {
11023
11023
  if (O.current() !== 38 && (t = this.regexp_eatClassSetOperand(O))) {
11024
- t !== kO && (e = C1);
11024
+ t !== qO && (e = C1);
11025
11025
  continue;
11026
11026
  }
11027
11027
  O.raise("Invalid character in character class");
@@ -11041,7 +11041,7 @@ z.regexp_classSetExpression = function(O) {
11041
11041
  if (!this.regexp_eatClassSetRange(O)) {
11042
11042
  if (t = this.regexp_eatClassSetOperand(O), !t)
11043
11043
  return e;
11044
- t === kO && (e = kO);
11044
+ t === qO && (e = qO);
11045
11045
  }
11046
11046
  };
11047
11047
  z.regexp_eatClassSetRange = function(O) {
@@ -11076,7 +11076,7 @@ z.regexp_eatNestedClass = function(O) {
11076
11076
  93
11077
11077
  /* ] */
11078
11078
  ))
11079
- return t && i === kO && O.raise("Negated character class may contain strings"), i;
11079
+ return t && i === qO && O.raise("Negated character class may contain strings"), i;
11080
11080
  O.pos = e;
11081
11081
  }
11082
11082
  if (O.eat(
@@ -11117,13 +11117,13 @@ z.regexp_classStringDisjunctionContents = function(O) {
11117
11117
  124
11118
11118
  /* | */
11119
11119
  ); )
11120
- this.regexp_classString(O) === kO && (e = kO);
11120
+ this.regexp_classString(O) === qO && (e = qO);
11121
11121
  return e;
11122
11122
  };
11123
11123
  z.regexp_classString = function(O) {
11124
11124
  for (var e = 0; this.regexp_eatClassSetCharacter(O); )
11125
11125
  e++;
11126
- return e === 1 ? C1 : kO;
11126
+ return e === 1 ? C1 : qO;
11127
11127
  };
11128
11128
  z.regexp_eatClassSetCharacter = function(O) {
11129
11129
  var e = O.pos;
@@ -11944,7 +11944,7 @@ function cP(O, e) {
11944
11944
  return n.trim().length === 0 ? null : (r++, {
11945
11945
  node: {
11946
11946
  type: "emphasis",
11947
- children: UO(n)
11947
+ children: ZO(n)
11948
11948
  },
11949
11949
  endIndex: r
11950
11950
  });
@@ -12030,9 +12030,9 @@ function pP(O, e, t, i) {
12030
12030
  }
12031
12031
  const c = `</${e}>`;
12032
12032
  if (n !== -1) {
12033
- const g = t.slice(n + 1), m = g.indexOf(c);
12034
- if (m !== -1) {
12035
- const P = g.slice(0, m);
12033
+ const g = t.slice(n + 1), w = g.indexOf(c);
12034
+ if (w !== -1) {
12035
+ const P = g.slice(0, w);
12036
12036
  O.currentIndex = i + 1, P.trim() && ($.children = Cn([P])), $.position = { start: Q, end: i + 1 }, O.currentContainer.push($);
12037
12037
  return;
12038
12038
  }
@@ -12045,12 +12045,12 @@ function pP(O, e, t, i) {
12045
12045
  g.trim() && h.push(g);
12046
12046
  }
12047
12047
  for (; O.currentIndex < O.lines.length && d > 0; ) {
12048
- const g = O.lines[O.currentIndex], m = g.trim();
12049
- if (m.includes(f) && !m.includes(`</${e}`)) {
12048
+ const g = O.lines[O.currentIndex], w = g.trim();
12049
+ if (w.includes(f) && !w.includes(`</${e}`)) {
12050
12050
  d++, h.push(g), O.currentIndex++;
12051
12051
  continue;
12052
12052
  }
12053
- if (m.includes(c) && (d--, d === 0)) {
12053
+ if (w.includes(c) && (d--, d === 0)) {
12054
12054
  O.currentIndex++;
12055
12055
  break;
12056
12056
  }
@@ -12122,7 +12122,7 @@ function hP(O, e) {
12122
12122
  type: "link",
12123
12123
  url: o,
12124
12124
  title: $ || void 0,
12125
- children: UO(a)
12125
+ children: ZO(a)
12126
12126
  },
12127
12127
  endIndex: i
12128
12128
  });
@@ -12152,7 +12152,7 @@ function PP(O, e) {
12152
12152
  return $.trim().length === 0 ? null : {
12153
12153
  node: {
12154
12154
  type: "strong",
12155
- children: UO($)
12155
+ children: ZO($)
12156
12156
  },
12157
12157
  endIndex: s
12158
12158
  };
@@ -12195,7 +12195,7 @@ function SP(O, e) {
12195
12195
  endIndex: t
12196
12196
  };
12197
12197
  }
12198
- function UO(O) {
12198
+ function ZO(O) {
12199
12199
  const e = [], t = O.length;
12200
12200
  let i = 0;
12201
12201
  for (; i < t; ) {
@@ -12259,7 +12259,7 @@ function UO(O) {
12259
12259
  type: "strong",
12260
12260
  children: [{
12261
12261
  type: "emphasis",
12262
- children: UO(c)
12262
+ children: ZO(c)
12263
12263
  }]
12264
12264
  };
12265
12265
  e.push(h), i = Q + 3;
@@ -12313,7 +12313,7 @@ function XP(O, e) {
12313
12313
  }
12314
12314
  const o = `</${t}>`, Q = a + 1, $ = O.indexOf(o, Q);
12315
12315
  if ($ === -1) return null;
12316
- const c = O.slice(Q, $), d = UO(c), h = {
12316
+ const c = O.slice(Q, $), d = ZO(c), h = {
12317
12317
  type: "jsxComponent",
12318
12318
  name: t,
12319
12319
  attributes: n,
@@ -12337,7 +12337,7 @@ function TP(O, e) {
12337
12337
  $ = h === -1 ? O.length : h + 1;
12338
12338
  } else {
12339
12339
  if (Q--, Q === 0) {
12340
- const h = O.slice(o, d), g = { type: "span", children: UO(h) };
12340
+ const h = O.slice(o, d), g = { type: "span", children: ZO(h) };
12341
12341
  return BO(g, n), { node: g, endIndex: d + s.length };
12342
12342
  }
12343
12343
  $ = d + s.length;
@@ -12684,7 +12684,7 @@ function ee(O) {
12684
12684
  t = r + 1;
12685
12685
  } else {
12686
12686
  const r = O.indexOf("<", t), a = r === -1 ? i : r, n = O.substring(t, a);
12687
- n && e.push({ type: "text", value: Ri(n) }), t = a;
12687
+ n && e.push(...ZO(Ri(n))), t = a;
12688
12688
  }
12689
12689
  return e;
12690
12690
  }
@@ -12726,7 +12726,7 @@ function RP(O, e) {
12726
12726
  const o = i.indexOf("</summary>");
12727
12727
  if (o !== -1) {
12728
12728
  const Q = i.slice(a, o);
12729
- t.children = UO(Q), O.currentIndex++, Gt(O, "summary");
12729
+ t.children = ZO(Q), O.currentIndex++, Gt(O, "summary");
12730
12730
  return;
12731
12731
  }
12732
12732
  O.currentIndex++;
@@ -12743,14 +12743,14 @@ function RP(O, e) {
12743
12743
  }
12744
12744
  const s = n.join(`
12745
12745
  `);
12746
- t.children = UO(s), Gt(O, "summary");
12746
+ t.children = ZO(s), Gt(O, "summary");
12747
12747
  }
12748
12748
  function _P(O, e) {
12749
12749
  const t = "</span>", i = O.currentIndex, r = [O.lines[i]];
12750
12750
  let a = i;
12751
12751
  for (; !r.join(" ").includes(t) && a + 1 < O.lines.length; )
12752
12752
  a++, r.push(O.lines[a]);
12753
- const n = r.join(" ").trim(), s = UO(n);
12753
+ const n = r.join(" ").trim(), s = ZO(n);
12754
12754
  O.currentContainer.push({
12755
12755
  type: "paragraph",
12756
12756
  children: s
@@ -12893,7 +12893,7 @@ function LP(O) {
12893
12893
  const i = e.slice(t).trim(), r = {
12894
12894
  type: "heading",
12895
12895
  depth: t,
12896
- children: UO(i),
12896
+ children: ZO(i),
12897
12897
  id: bo.slug(i, !1)
12898
12898
  };
12899
12899
  O.currentContainer.push(r), O.currentIndex++;
@@ -12931,11 +12931,11 @@ function yn(O) {
12931
12931
  let t = "unordered", i;
12932
12932
  const r = O.lines[O.currentIndex].trim(), a = Ro(r);
12933
12933
  for (a.isOrdered && (t = "ordered", i = a.start); O.currentIndex < O.lines.length; ) {
12934
- const o = O.lines[O.currentIndex].trim();
12934
+ const s = O.lines[O.currentIndex], o = s.trim();
12935
12935
  if (o === "") {
12936
12936
  if (O.currentIndex++, O.currentIndex >= O.lines.length) break;
12937
- const y = O.lines[O.currentIndex].trim();
12938
- if (!y.startsWith("-") && !y.startsWith("*") && !y.startsWith("+") && !qt(y))
12937
+ const m = O.lines[O.currentIndex].trim();
12938
+ if (!m.startsWith("-") && !m.startsWith("*") && !m.startsWith("+") && !qt(m))
12939
12939
  break;
12940
12940
  continue;
12941
12941
  }
@@ -12944,26 +12944,27 @@ function yn(O) {
12944
12944
  break;
12945
12945
  const c = [];
12946
12946
  let d, h = O.currentIndex;
12947
+ const f = s.length - s.trimStart().length;
12947
12948
  for (; h < O.lines.length; ) {
12948
- const y = O.lines[h], w = y.trim();
12949
- if (w === "") {
12949
+ const m = O.lines[h], T = m.trim();
12950
+ if (T === "") {
12950
12951
  h++;
12951
12952
  continue;
12952
12953
  }
12953
12954
  if (h === O.currentIndex) {
12954
12955
  if ($)
12955
- c.push(GP(w));
12956
+ c.push(GP(T));
12956
12957
  else {
12957
- const { content: T, checked: X } = UP(w);
12958
- c.push(T), d = X;
12958
+ const { content: X, checked: y } = UP(T);
12959
+ c.push(X), d = y;
12959
12960
  }
12960
12961
  h++;
12961
- } else if (y.length - y.trimStart().length >= 2)
12962
- c.push(y), h++;
12962
+ } else if (m.length - m.trimStart().length > f)
12963
+ c.push(m), h++;
12963
12964
  else
12964
12965
  break;
12965
12966
  }
12966
- const m = {
12967
+ const P = {
12967
12968
  lines: c.join(`
12968
12969
  `).split(`
12969
12970
  `),
@@ -12972,13 +12973,13 @@ function yn(O) {
12972
12973
  root: [],
12973
12974
  currentContainer: []
12974
12975
  };
12975
- for (m.currentContainer = m.root; m.currentIndex < m.lines.length; )
12976
- Se(m);
12977
- const P = {
12976
+ for (P.currentContainer = P.root; P.currentIndex < P.lines.length; )
12977
+ Se(P);
12978
+ const R = {
12978
12979
  type: "listItem",
12979
- children: m.root
12980
+ children: P.root
12980
12981
  };
12981
- d !== void 0 && (P.checked = d, t === "unordered" && (t = "checklist")), e.push(P), O.currentIndex = h;
12982
+ d !== void 0 && (R.checked = d, t === "unordered" && (t = "checklist")), e.push(R), O.currentIndex = h;
12982
12983
  }
12983
12984
  const n = {
12984
12985
  type: "list",
@@ -13006,7 +13007,7 @@ function jP(O) {
13006
13007
  const r = e.join(`
13007
13008
  `), a = {
13008
13009
  type: "paragraph",
13009
- children: UO(r)
13010
+ children: ZO(r)
13010
13011
  };
13011
13012
  O.currentContainer.push(a), O.currentIndex = i;
13012
13013
  }
@@ -13050,7 +13051,7 @@ function bn(O, e = !1) {
13050
13051
  const a = {
13051
13052
  type: "tableCell",
13052
13053
  isHeader: e,
13053
- children: UO(r)
13054
+ children: ZO(r)
13054
13055
  };
13055
13056
  t.push(a);
13056
13057
  }
@@ -13169,17 +13170,17 @@ const lr = {
13169
13170
  s && h.current?.focus();
13170
13171
  }, [s]);
13171
13172
  const f = M(() => {
13172
- const w = Q.trim();
13173
- w !== n.code && KO.updateElement(r, {
13173
+ const m = Q.trim();
13174
+ m !== n.code && KO.updateElement(r, {
13174
13175
  blockId: t,
13175
13176
  type: "brandsafe-image",
13176
- props: { code: w }
13177
+ props: { code: m }
13177
13178
  }), o(!1);
13178
13179
  }, [r, t, Q, n.code]), g = M(() => {
13179
13180
  $(n.code), o(!1);
13180
- }, [n.code]), m = M(
13181
- (w) => {
13182
- w.stopPropagation(), w.key === "Enter" && f(), w.key === "Escape" && g();
13181
+ }, [n.code]), w = M(
13182
+ (m) => {
13183
+ m.stopPropagation(), m.key === "Enter" && f(), m.key === "Escape" && g();
13183
13184
  },
13184
13185
  [f, g]
13185
13186
  ), P = tO(() => n.code ? Ei(n.code) : "", [n.code]);
@@ -13220,7 +13221,7 @@ const lr = {
13220
13221
  {
13221
13222
  type: "button",
13222
13223
  onClick: () => o(!0),
13223
- onMouseDown: (w) => w.stopPropagation(),
13224
+ onMouseDown: (m) => m.stopPropagation(),
13224
13225
  style: {
13225
13226
  position: "absolute",
13226
13227
  inset: 0,
@@ -13238,25 +13239,25 @@ const lr = {
13238
13239
  padding: "var(--mantine-spacing-md)",
13239
13240
  width: "100%"
13240
13241
  },
13241
- onMouseEnter: (w) => {
13242
- w.currentTarget.style.opacity = "1";
13242
+ onMouseEnter: (m) => {
13243
+ m.currentTarget.style.opacity = "1";
13243
13244
  },
13244
- onMouseLeave: (w) => {
13245
- s || (w.currentTarget.style.opacity = "0");
13245
+ onMouseLeave: (m) => {
13246
+ s || (m.currentTarget.style.opacity = "0");
13246
13247
  },
13247
13248
  children: s ? /* @__PURE__ */ p(
13248
- WO,
13249
+ LO,
13249
13250
  {
13250
13251
  ref: h,
13251
13252
  size: "xs",
13252
13253
  label: "Enter a new BrandSafe code",
13253
13254
  placeholder: "BrandSafe image code…",
13254
13255
  value: Q,
13255
- onChange: (w) => $(w.currentTarget.value),
13256
+ onChange: (m) => $(m.currentTarget.value),
13256
13257
  onBlur: f,
13257
- onKeyDown: m,
13258
- onMouseDown: (w) => w.stopPropagation(),
13259
- onClick: (w) => w.stopPropagation(),
13258
+ onKeyDown: w,
13259
+ onMouseDown: (m) => m.stopPropagation(),
13260
+ onClick: (m) => m.stopPropagation(),
13260
13261
  classNames: {
13261
13262
  input: "brandsafe-image-overlay-input",
13262
13263
  label: "brandsafe-image-overlay-label"
@@ -13301,16 +13302,16 @@ const lr = {
13301
13302
  }
13302
13303
  ),
13303
13304
  /* @__PURE__ */ p(
13304
- WO,
13305
+ LO,
13305
13306
  {
13306
13307
  size: "xs",
13307
13308
  variant: "filled",
13308
13309
  placeholder: "e.g. d65ks6dhk7ec73f2k0dg",
13309
13310
  value: Q,
13310
- onChange: (w) => $(w.currentTarget.value),
13311
+ onChange: (m) => $(m.currentTarget.value),
13311
13312
  onBlur: f,
13312
- onKeyDown: m,
13313
- onMouseDown: (w) => w.stopPropagation()
13313
+ onKeyDown: w,
13314
+ onMouseDown: (m) => m.stopPropagation()
13314
13315
  }
13315
13316
  )
13316
13317
  ]
@@ -13380,46 +13381,46 @@ const lr = {
13380
13381
  H(() => {
13381
13382
  const T = O.current;
13382
13383
  if (!T) return;
13383
- const X = () => a(T.currentTime || 0), b = () => i(T.duration || 0);
13384
- return X(), b(), T.addEventListener("timeupdate", X), T.addEventListener("loadedmetadata", b), T.addEventListener("durationchange", b), () => {
13385
- T.removeEventListener("timeupdate", X), T.removeEventListener("loadedmetadata", b), T.removeEventListener("durationchange", b);
13384
+ const X = () => a(T.currentTime || 0), y = () => i(T.duration || 0);
13385
+ return X(), y(), T.addEventListener("timeupdate", X), T.addEventListener("loadedmetadata", y), T.addEventListener("durationchange", y), () => {
13386
+ T.removeEventListener("timeupdate", X), T.removeEventListener("loadedmetadata", y), T.removeEventListener("durationchange", y);
13386
13387
  };
13387
13388
  }, [O]);
13388
13389
  const $ = sO((T) => {
13389
- const X = O.current, b = e.current;
13390
- if (!X || !b || !Number.isFinite(X.duration) || X.duration <= 0)
13390
+ const X = O.current, y = e.current;
13391
+ if (!X || !y || !Number.isFinite(X.duration) || X.duration <= 0)
13391
13392
  return null;
13392
- const V = b.getBoundingClientRect();
13393
+ const V = y.getBoundingClientRect();
13393
13394
  if (!V.width) return null;
13394
13395
  const G = (T - V.left) / V.width;
13395
13396
  return Math.min(X.duration, Math.max(0, G * X.duration));
13396
13397
  }), c = sO((T) => {
13397
13398
  const X = $(T.clientX);
13398
13399
  if (X === null) return;
13399
- const b = O.current;
13400
- b && (b.currentTime = X, a(X));
13400
+ const y = O.current;
13401
+ y && (y.currentTime = X, a(X));
13401
13402
  }), d = sO((T) => {
13402
13403
  if (T.button !== 0) return;
13403
13404
  T.currentTarget.setPointerCapture(T.pointerId), s(!0);
13404
13405
  const X = $(T.clientX);
13405
13406
  if (X === null) return;
13406
- const b = O.current;
13407
- b && (b.currentTime = X, a(X), Q(X));
13407
+ const y = O.current;
13408
+ y && (y.currentTime = X, a(X), Q(X));
13408
13409
  }), h = sO((T) => {
13409
13410
  const X = $(T.clientX);
13410
13411
  if (X === null || (Q(X), !n)) return;
13411
- const b = O.current;
13412
- b && (b.currentTime = X, a(X));
13412
+ const y = O.current;
13413
+ y && (y.currentTime = X, a(X));
13413
13414
  }), f = sO((T) => {
13414
13415
  const X = $(T.clientX);
13415
13416
  X !== null && Q(X);
13416
13417
  }), g = sO((T) => {
13417
13418
  T.currentTarget.hasPointerCapture(T.pointerId) && T.currentTarget.releasePointerCapture(T.pointerId), s(!1);
13418
- }), m = sO(() => {
13419
+ }), w = sO(() => {
13419
13420
  n || Q(null);
13420
- }), P = tO(() => !t || t <= 0 ? 0 : Math.min(100, Math.max(0, r / t * 100)), [r, t]), y = tO(() => o === null || !t || t <= 0 ? null : Math.min(100, Math.max(0, o / t * 100)), [t, o]), w = sO((T) => {
13421
- const X = Math.max(0, Math.floor(T)), b = Math.floor(X / 60), V = X % 60;
13422
- return `${b}:${V.toString().padStart(2, "0")}`;
13421
+ }), P = tO(() => !t || t <= 0 ? 0 : Math.min(100, Math.max(0, r / t * 100)), [r, t]), R = tO(() => o === null || !t || t <= 0 ? null : Math.min(100, Math.max(0, o / t * 100)), [t, o]), m = sO((T) => {
13422
+ const X = Math.max(0, Math.floor(T)), y = Math.floor(X / 60), V = X % 60;
13423
+ return `${y}:${V.toString().padStart(2, "0")}`;
13423
13424
  });
13424
13425
  return /* @__PURE__ */ v(
13425
13426
  aO,
@@ -13434,7 +13435,7 @@ const lr = {
13434
13435
  onPointerMove: h,
13435
13436
  onPointerUp: g,
13436
13437
  onPointerCancel: g,
13437
- onPointerLeave: m,
13438
+ onPointerLeave: w,
13438
13439
  disabled: !t,
13439
13440
  "aria-label": "Seek video",
13440
13441
  "aria-valuemin": 0,
@@ -13442,12 +13443,12 @@ const lr = {
13442
13443
  "aria-valuenow": r,
13443
13444
  "aria-valuetext": t ? `${Math.round(r)} seconds of ${Math.round(t)} seconds` : "Video progress",
13444
13445
  children: [
13445
- y !== null && /* @__PURE__ */ p(
13446
+ R !== null && /* @__PURE__ */ p(
13446
13447
  aO,
13447
13448
  {
13448
13449
  className: NO.progressTooltip,
13449
- style: { left: `${y}%` },
13450
- children: w(o ?? 0)
13450
+ style: { left: `${R}%` },
13451
+ children: m(o ?? 0)
13451
13452
  }
13452
13453
  ),
13453
13454
  /* @__PURE__ */ p(
@@ -13477,18 +13478,18 @@ const lr = {
13477
13478
  videoProps: o,
13478
13479
  ...Q
13479
13480
  }) => {
13480
- const $ = VO(null), [c, d] = j(!1), [h, f] = j(a), [g, m] = j(!1), [P, y] = j(!1), {
13481
- onPlay: w,
13481
+ const $ = VO(null), [c, d] = j(!1), [h, f] = j(a), [g, w] = j(!1), [P, R] = j(!1), {
13482
+ onPlay: m,
13482
13483
  onPause: T,
13483
13484
  onVolumeChange: X,
13484
- onTimeUpdate: b,
13485
+ onTimeUpdate: y,
13485
13486
  onLoadedMetadata: V,
13486
13487
  onCanPlay: G,
13487
13488
  onDurationChange: L,
13488
13489
  onEnded: S,
13489
13490
  onError: x,
13490
13491
  ...C
13491
- } = o ?? {}, R = !!e && (g || !P), Y = sO(() => {
13492
+ } = o ?? {}, b = !!e && (g || !P), Y = sO(() => {
13492
13493
  const U = $.current;
13493
13494
  U && U.play().catch((hO) => console.error("Failed to start video playback:", hO));
13494
13495
  });
@@ -13499,9 +13500,9 @@ const lr = {
13499
13500
  if (!U || !i) return;
13500
13501
  const hO = new IntersectionObserver(
13501
13502
  (it) => {
13502
- const yO = it[0];
13503
- if (yO)
13504
- if (yO.isIntersecting) {
13503
+ const bO = it[0];
13504
+ if (bO)
13505
+ if (bO.isIntersecting) {
13505
13506
  if (!U.paused)
13506
13507
  return;
13507
13508
  Y();
@@ -13537,7 +13538,7 @@ const lr = {
13537
13538
  ...Q,
13538
13539
  style: { overflow: "hidden", ...Q.style },
13539
13540
  children: [
13540
- R && /* @__PURE__ */ p(
13541
+ b && /* @__PURE__ */ p(
13541
13542
  aO,
13542
13543
  {
13543
13544
  component: "img",
@@ -13561,7 +13562,7 @@ const lr = {
13561
13562
  muted: h,
13562
13563
  playsInline: !0,
13563
13564
  onPlay: (U) => {
13564
- d(!0), y(!0), m(!1), w?.(U);
13565
+ d(!0), R(!0), w(!1), m?.(U);
13565
13566
  },
13566
13567
  onPause: (U) => {
13567
13568
  d(!1), T?.(U);
@@ -13570,13 +13571,13 @@ const lr = {
13570
13571
  f(U.currentTarget?.muted ?? !1), X?.(U);
13571
13572
  },
13572
13573
  onTimeUpdate: (U) => {
13573
- b?.(U);
13574
+ y?.(U);
13574
13575
  },
13575
13576
  onLoadedMetadata: (U) => {
13576
- m(!1), V?.(U);
13577
+ w(!1), V?.(U);
13577
13578
  },
13578
13579
  onCanPlay: (U) => {
13579
- m(!1), G?.(U);
13580
+ w(!1), G?.(U);
13580
13581
  },
13581
13582
  onDurationChange: (U) => {
13582
13583
  L?.(U);
@@ -13585,7 +13586,7 @@ const lr = {
13585
13586
  d(!1), S?.(U);
13586
13587
  },
13587
13588
  onError: (U) => {
13588
- m(!0), d(!1), x?.(U);
13589
+ w(!0), d(!1), x?.(U);
13589
13590
  },
13590
13591
  ...C
13591
13592
  }
@@ -13645,7 +13646,7 @@ const lr = {
13645
13646
  { label: "WebM", value: "webm" },
13646
13647
  { label: "MOV", value: "mov" }
13647
13648
  ], $f = ({ blockId: O }) => {
13648
- const e = dO(), r = YO.getBlock(e, { id: O })?.value[0]?.props ?? At, [a, n] = j(r.code), [s, o] = j(r.format);
13649
+ const e = dO(), r = WO.getBlock(e, { id: O })?.value[0]?.props ?? At, [a, n] = j(r.code), [s, o] = j(r.format);
13649
13650
  H(() => {
13650
13651
  n(r.code), o(r.format);
13651
13652
  }, [r.code, r.format]);
@@ -13682,7 +13683,7 @@ const lr = {
13682
13683
  },
13683
13684
  children: [
13684
13685
  /* @__PURE__ */ p(
13685
- WO,
13686
+ LO,
13686
13687
  {
13687
13688
  label: "BrandSafe code",
13688
13689
  size: "xs",
@@ -13837,7 +13838,7 @@ const lr = {
13837
13838
  },
13838
13839
  children: [
13839
13840
  /* @__PURE__ */ p(
13840
- WO,
13841
+ LO,
13841
13842
  {
13842
13843
  size: "xs",
13843
13844
  variant: "filled",
@@ -14001,7 +14002,7 @@ const pf = p5.extend({
14001
14002
  { label: "LG", value: "lg" },
14002
14003
  { label: "XL", value: "xl" }
14003
14004
  ], Pf = ({ blockId: O }) => {
14004
- const e = dO(), r = YO.getBlock(e, { id: O })?.value[0]?.props ?? Et, [a, n] = j(r.label), [s, o] = j(r.url), [, Q] = j(0);
14005
+ const e = dO(), r = WO.getBlock(e, { id: O })?.value[0]?.props ?? Et, [a, n] = j(r.label), [s, o] = j(r.url), [, Q] = j(0);
14005
14006
  H(() => {
14006
14007
  n(r.label), o(r.url);
14007
14008
  }, [r.label, r.url]);
@@ -14020,7 +14021,7 @@ const pf = p5.extend({
14020
14021
  style: { minWidth: 220 },
14021
14022
  children: [
14022
14023
  /* @__PURE__ */ p(
14023
- WO,
14024
+ LO,
14024
14025
  {
14025
14026
  label: "Label",
14026
14027
  size: "xs",
@@ -14029,7 +14030,7 @@ const pf = p5.extend({
14029
14030
  }
14030
14031
  ),
14031
14032
  /* @__PURE__ */ p(
14032
- WO,
14033
+ LO,
14033
14034
  {
14034
14035
  label: "URL",
14035
14036
  size: "xs",
@@ -14198,7 +14199,7 @@ function _i(O) {
14198
14199
  return O.charAt(0).toUpperCase() + O.slice(1);
14199
14200
  }
14200
14201
  const xf = ({ blockId: O }) => {
14201
- const e = dO(), r = YO.getBlock(e, { id: O })?.value[0]?.props?.theme ?? "default", a = M(
14202
+ const e = dO(), r = WO.getBlock(e, { id: O })?.value[0]?.props?.theme ?? "default", a = M(
14202
14203
  (n) => {
14203
14204
  KO.updateElement(e, { blockId: O, type: "callout", props: n });
14204
14205
  },
@@ -14392,7 +14393,7 @@ const wf = qi.TodoList.extend({
14392
14393
  highlightOnHover: !1,
14393
14394
  caption: ""
14394
14395
  }, bf = ({ blockId: O }) => {
14395
- const e = dO(), r = YO.getBlock(e, { id: O })?.value[0]?.props ?? Dt, [a, n] = j(r.caption);
14396
+ const e = dO(), r = WO.getBlock(e, { id: O })?.value[0]?.props ?? Dt, [a, n] = j(r.caption);
14396
14397
  H(() => {
14397
14398
  n(r.caption);
14398
14399
  }, [r.caption]);
@@ -14410,7 +14411,7 @@ const wf = qi.TodoList.extend({
14410
14411
  style: { minWidth: 200 },
14411
14412
  children: [
14412
14413
  /* @__PURE__ */ p(
14413
- WO,
14414
+ LO,
14414
14415
  {
14415
14416
  label: "Caption",
14416
14417
  size: "xs",
@@ -14473,9 +14474,9 @@ const wf = qi.TodoList.extend({
14473
14474
  },
14474
14475
  [r, t]
14475
14476
  ), d = M(
14476
- (T, X, b) => {
14477
+ (T, X, y) => {
14477
14478
  const V = Q.map((G) => [...G]);
14478
- V[T][X] = b, $(V), c(V);
14479
+ V[T][X] = y, $(V), c(V);
14479
14480
  },
14480
14481
  [Q, c]
14481
14482
  ), h = M(() => {
@@ -14484,17 +14485,17 @@ const wf = qi.TodoList.extend({
14484
14485
  }, [Q, o, c]), f = M(
14485
14486
  (T) => {
14486
14487
  if (Q.length <= 1) return;
14487
- const X = Q.filter((b, V) => V !== T);
14488
+ const X = Q.filter((y, V) => V !== T);
14488
14489
  $(X), c(X);
14489
14490
  },
14490
14491
  [Q, c]
14491
14492
  ), g = M(() => {
14492
14493
  const T = Q.map((X) => [...X, ""]);
14493
14494
  $(T), c(T);
14494
- }, [Q, c]), m = M(
14495
+ }, [Q, c]), w = M(
14495
14496
  (T) => {
14496
14497
  if (o <= 1) return;
14497
- const X = Q.map((b) => b.filter((V, G) => G !== T));
14498
+ const X = Q.map((y) => y.filter((V, G) => G !== T));
14498
14499
  $(X), c(X);
14499
14500
  },
14500
14501
  [Q, o, c]
@@ -14516,8 +14517,8 @@ const wf = qi.TodoList.extend({
14516
14517
  withColumnBorders: !0,
14517
14518
  children: [
14518
14519
  n.caption && /* @__PURE__ */ p(K.Caption, { children: n.caption }),
14519
- T && /* @__PURE__ */ p(K.Thead, { children: /* @__PURE__ */ p(K.Tr, { children: T.map((b, V) => /* @__PURE__ */ p(K.Th, { children: b }, V)) }) }),
14520
- /* @__PURE__ */ p(K.Tbody, { children: X.map((b, V) => /* @__PURE__ */ p(K.Tr, { children: b.map((G, L) => /* @__PURE__ */ p(K.Td, { children: G }, L)) }, V)) })
14520
+ T && /* @__PURE__ */ p(K.Thead, { children: /* @__PURE__ */ p(K.Tr, { children: T.map((y, V) => /* @__PURE__ */ p(K.Th, { children: y }, V)) }) }),
14521
+ /* @__PURE__ */ p(K.Tbody, { children: X.map((y, V) => /* @__PURE__ */ p(K.Tr, { children: y.map((G, L) => /* @__PURE__ */ p(K.Td, { children: G }, L)) }, V)) })
14521
14522
  ]
14522
14523
  }
14523
14524
  ),
@@ -14526,7 +14527,7 @@ const wf = qi.TodoList.extend({
14526
14527
  }
14527
14528
  );
14528
14529
  }
14529
- const P = n.withHeaderRow ? Q[0] : void 0, y = n.withHeaderRow ? 1 : 0, w = Q.slice(y);
14530
+ const P = n.withHeaderRow ? Q[0] : void 0, R = n.withHeaderRow ? 1 : 0, m = Q.slice(R);
14530
14531
  return /* @__PURE__ */ v(
14531
14532
  "div",
14532
14533
  {
@@ -14552,9 +14553,9 @@ const wf = qi.TodoList.extend({
14552
14553
  minRows: 1,
14553
14554
  value: T,
14554
14555
  placeholder: `Header ${X + 1}`,
14555
- onChange: (b) => d(0, X, b.currentTarget.value),
14556
- onMouseDown: (b) => b.stopPropagation(),
14557
- onKeyDown: (b) => b.stopPropagation(),
14556
+ onChange: (y) => d(0, X, y.currentTarget.value),
14557
+ onMouseDown: (y) => y.stopPropagation(),
14558
+ onKeyDown: (y) => y.stopPropagation(),
14558
14559
  styles: { input: { fontWeight: 700, resize: "none" } }
14559
14560
  }
14560
14561
  ) }, X)),
@@ -14564,7 +14565,7 @@ const wf = qi.TodoList.extend({
14564
14565
  size: "xs",
14565
14566
  variant: "subtle",
14566
14567
  color: "red",
14567
- onClick: () => m(o - 1),
14568
+ onClick: () => w(o - 1),
14568
14569
  disabled: o <= 1,
14569
14570
  children: /* @__PURE__ */ p(
14570
14571
  rO,
@@ -14576,8 +14577,8 @@ const wf = qi.TodoList.extend({
14576
14577
  }
14577
14578
  ) }) })
14578
14579
  ] }) }),
14579
- /* @__PURE__ */ p(K.Tbody, { children: w.map((T, X) => {
14580
- const b = X + y;
14580
+ /* @__PURE__ */ p(K.Tbody, { children: m.map((T, X) => {
14581
+ const y = X + R;
14581
14582
  return /* @__PURE__ */ v(K.Tr, { children: [
14582
14583
  T.map((V, G) => /* @__PURE__ */ p(K.Td, { children: /* @__PURE__ */ p(
14583
14584
  la,
@@ -14588,7 +14589,7 @@ const wf = qi.TodoList.extend({
14588
14589
  minRows: 1,
14589
14590
  value: V,
14590
14591
  placeholder: "…",
14591
- onChange: (L) => d(b, G, L.currentTarget.value),
14592
+ onChange: (L) => d(y, G, L.currentTarget.value),
14592
14593
  onMouseDown: (L) => L.stopPropagation(),
14593
14594
  onKeyDown: (L) => L.stopPropagation(),
14594
14595
  styles: { input: { resize: "none" } }
@@ -14600,7 +14601,7 @@ const wf = qi.TodoList.extend({
14600
14601
  size: "xs",
14601
14602
  variant: "subtle",
14602
14603
  color: "red",
14603
- onClick: () => f(b),
14604
+ onClick: () => f(y),
14604
14605
  disabled: Q.length <= 1,
14605
14606
  children: /* @__PURE__ */ p(
14606
14607
  rO,
@@ -14611,7 +14612,7 @@ const wf = qi.TodoList.extend({
14611
14612
  )
14612
14613
  }
14613
14614
  ) }) })
14614
- ] }, b);
14615
+ ] }, y);
14615
14616
  }) })
14616
14617
  ]
14617
14618
  }
@@ -14804,29 +14805,29 @@ const zn = {
14804
14805
  c(n.title);
14805
14806
  }, [n.title]);
14806
14807
  const h = M(
14807
- (y) => {
14808
+ (R) => {
14808
14809
  KO.updateElement(r, {
14809
14810
  blockId: t,
14810
14811
  type: "surreal-codeblock",
14811
- props: y
14812
+ props: R
14812
14813
  });
14813
14814
  },
14814
14815
  [r, t]
14815
14816
  ), f = M(
14816
- (y) => {
14817
- Q(y), h({ code: y });
14817
+ (R) => {
14818
+ Q(R), h({ code: R });
14818
14819
  },
14819
14820
  [h]
14820
14821
  ), g = M(
14821
- (y) => {
14822
- f(y.currentTarget.value);
14822
+ (R) => {
14823
+ f(R.currentTarget.value);
14823
14824
  },
14824
14825
  [f]
14825
- ), m = M((y) => {
14826
- if (y.stopPropagation(), y.key === "Tab") {
14827
- y.preventDefault();
14828
- const w = y.currentTarget, T = w.selectionStart, X = w.selectionEnd, b = w.value, V = `${b.substring(0, T)} ${b.substring(X)}`;
14829
- w.value = V, w.selectionStart = w.selectionEnd = T + 1, Q(V);
14826
+ ), w = M((R) => {
14827
+ if (R.stopPropagation(), R.key === "Tab") {
14828
+ R.preventDefault();
14829
+ const m = R.currentTarget, T = m.selectionStart, X = m.selectionEnd, y = m.value, V = `${y.substring(0, T)} ${y.substring(X)}`;
14830
+ m.value = V, m.selectionStart = m.selectionEnd = T + 1, Q(V);
14830
14831
  }
14831
14832
  }, []), P = M(() => {
14832
14833
  f(o);
@@ -14871,20 +14872,20 @@ const zn = {
14871
14872
  py: "xs",
14872
14873
  gap: "xs",
14873
14874
  wrap: "nowrap",
14874
- onMouseDown: (y) => y.stopPropagation(),
14875
- onKeyDown: (y) => y.stopPropagation(),
14875
+ onMouseDown: (R) => R.stopPropagation(),
14876
+ onKeyDown: (R) => R.stopPropagation(),
14876
14877
  style: { background: "var(--surreal-glass-subtle)" },
14877
14878
  children: [
14878
14879
  /* @__PURE__ */ p(
14879
- WO,
14880
+ LO,
14880
14881
  {
14881
14882
  size: "xs",
14882
14883
  variant: "unstyled",
14883
14884
  placeholder: "Untitled",
14884
14885
  value: $,
14885
- onChange: (y) => {
14886
- const w = y.currentTarget.value;
14887
- c(w), h({ title: w });
14886
+ onChange: (R) => {
14887
+ const m = R.currentTarget.value;
14888
+ c(m), h({ title: m });
14888
14889
  },
14889
14890
  styles: {
14890
14891
  input: {
@@ -14903,8 +14904,8 @@ const zn = {
14903
14904
  variant: "filled",
14904
14905
  data: d,
14905
14906
  value: n.language,
14906
- onChange: (y) => {
14907
- y && h({ language: y });
14907
+ onChange: (R) => {
14908
+ R && h({ language: R });
14908
14909
  },
14909
14910
  comboboxProps: { withinPortal: !0 },
14910
14911
  allowDeselect: !1,
@@ -14925,7 +14926,7 @@ const zn = {
14925
14926
  {
14926
14927
  size: "xs",
14927
14928
  checked: n.withLineNumbers,
14928
- onChange: (y) => h({ withLineNumbers: y.currentTarget.checked })
14929
+ onChange: (R) => h({ withLineNumbers: R.currentTarget.checked })
14929
14930
  }
14930
14931
  )
14931
14932
  }
@@ -14961,7 +14962,7 @@ const zn = {
14961
14962
  ref: s,
14962
14963
  value: o,
14963
14964
  onChange: g,
14964
- onKeyDown: m,
14965
+ onKeyDown: w,
14965
14966
  onBlur: P,
14966
14967
  placeholder: "Enter code...",
14967
14968
  spellCheck: !1,
@@ -15221,7 +15222,7 @@ const Lf = ({
15221
15222
  s || (P.currentTarget.style.opacity = "0", P.currentTarget.style.backgroundColor = "transparent");
15222
15223
  },
15223
15224
  children: s ? /* @__PURE__ */ p(
15224
- WO,
15225
+ LO,
15225
15226
  {
15226
15227
  ref: c,
15227
15228
  size: "xs",
@@ -15274,7 +15275,7 @@ const Lf = ({
15274
15275
  }
15275
15276
  ),
15276
15277
  /* @__PURE__ */ p(
15277
- WO,
15278
+ LO,
15278
15279
  {
15279
15280
  size: "xs",
15280
15281
  variant: "filled",
@@ -15431,7 +15432,7 @@ const Df = [
15431
15432
  elements: {
15432
15433
  "numbered-list": {
15433
15434
  render: (O) => {
15434
- const e = dO(), t = YO.getBlock(e, { id: O.blockId }), i = t5(t);
15435
+ const e = dO(), t = WO.getBlock(e, { id: O.blockId }), i = t5(t);
15435
15436
  return /* @__PURE__ */ p(
15436
15437
  "ol",
15437
15438
  {
@@ -15467,7 +15468,7 @@ const Df = [
15467
15468
  "VideoEmbed"
15468
15469
  ]);
15469
15470
  function Mf(O) {
15470
- const e = YO.getBlock(O, { at: O.path.current });
15471
+ const e = WO.getBlock(O, { at: O.path.current });
15471
15472
  if (!e) return !1;
15472
15473
  const t = O.blockEditorsMap[e.id];
15473
15474
  if (!t?.selection) return !1;
@@ -15477,7 +15478,7 @@ function Mf(O) {
15477
15478
  return !!i;
15478
15479
  }
15479
15480
  function kn(O, e) {
15480
- const t = YO.getBlock(O, { at: O.path.current });
15481
+ const t = WO.getBlock(O, { at: O.path.current });
15481
15482
  if (!t) return;
15482
15483
  const i = O.blockEditorsMap[t.id];
15483
15484
  if (!i?.selection || (at.unwrapNodes(i, {
@@ -15531,7 +15532,7 @@ const Ff = ({
15531
15532
  wrap: "nowrap",
15532
15533
  children: [
15533
15534
  /* @__PURE__ */ p(
15534
- WO,
15535
+ LO,
15535
15536
  {
15536
15537
  size: "xs",
15537
15538
  placeholder: "https://...",
@@ -15614,7 +15615,7 @@ const Ff = ({
15614
15615
  )
15615
15616
  ] }) }) });
15616
15617
  }, Bf = ({ blockId: O }) => {
15617
- const e = dO(), t = O ? YO.getBlock(e, { id: O }) : null, i = t ? MP(t.type) : void 0, r = t ? !dr.has(t.type) : !1, a = tO(
15618
+ const e = dO(), t = O ? WO.getBlock(e, { id: O }) : null, i = t ? MP(t.type) : void 0, r = t ? !dr.has(t.type) : !1, a = tO(
15618
15619
  () => Object.values(e.plugins).filter((n) => {
15619
15620
  if (dr.has(n.type)) return !1;
15620
15621
  const s = n.options;
@@ -15648,7 +15649,7 @@ const Ff = ({
15648
15649
  $O.Item,
15649
15650
  {
15650
15651
  onClick: () => {
15651
- O && YO.duplicateBlock(e, { blockId: O });
15652
+ O && WO.duplicateBlock(e, { blockId: O });
15652
15653
  },
15653
15654
  children: /* @__PURE__ */ v(
15654
15655
  z1,
@@ -15674,7 +15675,7 @@ const Ff = ({
15674
15675
  {
15675
15676
  color: "red",
15676
15677
  onClick: () => {
15677
- O && YO.deleteBlock(e, { blockId: O });
15678
+ O && WO.deleteBlock(e, { blockId: O });
15678
15679
  },
15679
15680
  children: /* @__PURE__ */ v(
15680
15681
  z1,
@@ -15699,7 +15700,7 @@ const Ff = ({
15699
15700
  }, Kf = () => {
15700
15701
  const O = dO(), [e, t] = j(!1), i = (r) => {
15701
15702
  if (!r) return;
15702
- const a = YO.getBlock(O, { id: r });
15703
+ const a = WO.getBlock(O, { id: r });
15703
15704
  a && O.insertBlock("Paragraph", { at: a.meta.order + 1, focus: !0 });
15704
15705
  };
15705
15706
  return /* @__PURE__ */ p(
@@ -15733,7 +15734,7 @@ const Ff = ({
15733
15734
  {
15734
15735
  onClick: () => {
15735
15736
  if (r) {
15736
- const a = YO.getBlock(O, {
15737
+ const a = WO.getBlock(O, {
15737
15738
  id: r
15738
15739
  });
15739
15740
  a && O.setPath({ current: a.meta.order });
@@ -16108,7 +16109,7 @@ function ce(O, e) {
16108
16109
  const t = O > 0 ? 1 : -1, i = e > 0 ? 1 : -1, r = t + i !== 0 ? 1 : 0;
16109
16110
  return `a ${_} ${_} 0 0 ${r} ${O} ${e}`;
16110
16111
  }
16111
- const zO = _ * 2;
16112
+ const kO = _ * 2;
16112
16113
  function te(O, e) {
16113
16114
  return `c ${O} 0 0 ${e} ${O} ${e}`;
16114
16115
  }
@@ -16215,7 +16216,7 @@ function TS(O, e, t) {
16215
16216
  /* @__PURE__ */ p(
16216
16217
  "path",
16217
16218
  {
16218
- d: `M ${e} ${t} ${te(zO, zO)}`
16219
+ d: `M ${e} ${t} ${te(kO, kO)}`
16219
16220
  },
16220
16221
  eO()
16221
16222
  )
@@ -16223,7 +16224,7 @@ function TS(O, e, t) {
16223
16224
  /* @__PURE__ */ p(
16224
16225
  "path",
16225
16226
  {
16226
- d: `M ${n + i.width} ${s} ${te(zO, -zO)}`
16227
+ d: `M ${n + i.width} ${s} ${te(kO, -kO)}`
16227
16228
  },
16228
16229
  eO()
16229
16230
  )
@@ -16235,7 +16236,7 @@ function TS(O, e, t) {
16235
16236
  /* @__PURE__ */ p(
16236
16237
  "path",
16237
16238
  {
16238
- d: `M ${e} ${t} ${te(zO, -zO)}`
16239
+ d: `M ${e} ${t} ${te(kO, -kO)}`
16239
16240
  },
16240
16241
  eO()
16241
16242
  )
@@ -16243,7 +16244,7 @@ function TS(O, e, t) {
16243
16244
  /* @__PURE__ */ p(
16244
16245
  "path",
16245
16246
  {
16246
- d: `M ${e + r - _ * 2} ${s} ${te(zO, zO)}`
16247
+ d: `M ${e + r - _ * 2} ${s} ${te(kO, kO)}`
16247
16248
  },
16248
16249
  eO()
16249
16250
  )
@@ -16266,12 +16267,12 @@ function gS(O, e, t) {
16266
16267
  if (s.push(V1(O.children[$], h, c)), $ === r)
16267
16268
  s.push(oO(e, t, h, c)), s.push(oO(f, c, g, t));
16268
16269
  else {
16269
- const m = c - t;
16270
+ const w = c - t;
16270
16271
  s.push(
16271
16272
  /* @__PURE__ */ p(
16272
16273
  "path",
16273
16274
  {
16274
- d: `M ${e} ${t} ${ce(_, m > 0 ? _ : -_)} L ${e + _} ${c - (m > 0 ? _ : -_)} ${ue(_, m > 0 ? _ : -_)}`
16275
+ d: `M ${e} ${t} ${ce(_, w > 0 ? _ : -_)} L ${e + _} ${c - (w > 0 ? _ : -_)} ${ue(_, w > 0 ? _ : -_)}`
16275
16276
  },
16276
16277
  eO()
16277
16278
  )
@@ -16281,7 +16282,7 @@ function gS(O, e, t) {
16281
16282
  /* @__PURE__ */ p(
16282
16283
  "path",
16283
16284
  {
16284
- d: `M ${P} ${c} ${ce(_, m > 0 ? -_ : _)} L ${g - _} ${t + (m > 0 ? _ : -_)} ${ue(_, m > 0 ? -_ : _)}`
16285
+ d: `M ${P} ${c} ${ce(_, w > 0 ? -_ : _)} L ${g - _} ${t + (w > 0 ? _ : -_)} ${ue(_, w > 0 ? -_ : _)}`
16285
16286
  },
16286
16287
  eO()
16287
16288
  )
@@ -16323,7 +16324,7 @@ function xS(O, e, t) {
16323
16324
  /* @__PURE__ */ p(
16324
16325
  "path",
16325
16326
  {
16326
- d: `M ${e} ${t} ${te(zO, -zO)}`
16327
+ d: `M ${e} ${t} ${te(kO, -kO)}`
16327
16328
  },
16328
16329
  eO()
16329
16330
  )
@@ -16331,7 +16332,7 @@ function xS(O, e, t) {
16331
16332
  /* @__PURE__ */ p(
16332
16333
  "path",
16333
16334
  {
16334
- d: `M ${o + a} ${$} ${te(zO, zO)}`
16335
+ d: `M ${o + a} ${$} ${te(kO, kO)}`
16335
16336
  },
16336
16337
  eO()
16337
16338
  )
@@ -16397,7 +16398,7 @@ function tm({
16397
16398
  selectProps: Q,
16398
16399
  ...$
16399
16400
  }) {
16400
- const c = typeof r == "number" ? `${r}px` : r, d = n ?? (a === "above" ? `(min-width: ${c})` : `(max-width: ${c})`), h = P5(d), f = (P) => typeof P.selectLabel == "string" ? P.selectLabel : typeof P.label == "string" || typeof P.label == "number" ? String(P.label) : P.value, [g, m] = f5({
16401
+ const c = typeof r == "number" ? `${r}px` : r, d = n ?? (a === "above" ? `(min-width: ${c})` : `(max-width: ${c})`), h = P5(d), f = (P) => typeof P.selectLabel == "string" ? P.selectLabel : typeof P.label == "string" || typeof P.label == "number" ? String(P.label) : P.value, [g, w] = f5({
16401
16402
  value: e,
16402
16403
  defaultValue: t,
16403
16404
  finalValue: O[0]?.value ?? null,
@@ -16405,11 +16406,11 @@ function tm({
16405
16406
  });
16406
16407
  return H(() => {
16407
16408
  if (O.length === 0) {
16408
- g !== null && m(null);
16409
+ g !== null && w(null);
16409
16410
  return;
16410
16411
  }
16411
- O.some((P) => P.value === g) || m(O[0].value);
16412
- }, [O, g, m]), h ? /* @__PURE__ */ p(
16412
+ O.some((P) => P.value === g) || w(O[0].value);
16413
+ }, [O, g, w]), h ? /* @__PURE__ */ p(
16413
16414
  r1,
16414
16415
  {
16415
16416
  data: O.map((P) => ({
@@ -16417,7 +16418,7 @@ function tm({
16417
16418
  label: f(P)
16418
16419
  })),
16419
16420
  value: g,
16420
- onChange: m,
16421
+ onChange: w,
16421
16422
  allowDeselect: !1,
16422
16423
  miw: 220,
16423
16424
  flex: { base: "1 1 100%", sm: "unset" },
@@ -16427,7 +16428,7 @@ function tm({
16427
16428
  Ve,
16428
16429
  {
16429
16430
  value: g,
16430
- onChange: m,
16431
+ onChange: w,
16431
16432
  ...$,
16432
16433
  children: /* @__PURE__ */ p(Z2, { ...s, children: O.map((P) => /* @__PURE__ */ p(
16433
16434
  y2,
@@ -16647,7 +16648,7 @@ const sm = R2({
16647
16648
  variant: "surreal"
16648
16649
  }
16649
16650
  }),
16650
- TextInput: WO.extend({
16651
+ TextInput: LO.extend({
16651
16652
  defaultProps: {
16652
16653
  spellCheck: !1,
16653
16654
  variant: "surreal"