@yext/pages-components 1.1.4 → 1.1.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,7 @@ var U_ = Object.defineProperty;
2
2
  var G_ = (e, t, n) => t in e ? U_(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
3
3
  var Ie = (e, t, n) => G_(e, typeof t != "symbol" ? t + "" : t, n);
4
4
  import * as Y_ from "react";
5
- import xn, { createElement as V_, createContext as Nc, useRef as od, useState as Nr, useEffect as sr, Suspense as j_, lazy as q_, useContext as co, forwardRef as Z_, Fragment as J_, useMemo as tp } from "react";
5
+ import Cn, { createElement as V_, createContext as Nc, useRef as od, useState as Nr, useEffect as tr, Suspense as j_, lazy as q_, useContext as co, forwardRef as Z_, Fragment as J_, useMemo as tp } from "react";
6
6
  import np, { createPortal as X_ } from "react-dom";
7
7
  var of = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
8
8
  function rp(e) {
@@ -22,7 +22,7 @@ var lf;
22
22
  function Q_() {
23
23
  if (lf) return Ul;
24
24
  lf = 1;
25
- var e = xn, t = Symbol.for("react.element"), n = Symbol.for("react.fragment"), r = Object.prototype.hasOwnProperty, l = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, d = { key: !0, ref: !0, __self: !0, __source: !0 };
25
+ var e = Cn, t = Symbol.for("react.element"), n = Symbol.for("react.fragment"), r = Object.prototype.hasOwnProperty, l = e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, d = { key: !0, ref: !0, __self: !0, __source: !0 };
26
26
  function f(p, _, T) {
27
27
  var E, S = {}, w = null, M = null;
28
28
  T !== void 0 && (w = "" + T), _.key !== void 0 && (w = "" + _.key), _.ref !== void 0 && (M = _.ref);
@@ -45,7 +45,7 @@ var Gl = {};
45
45
  var af;
46
46
  function ey() {
47
47
  return af || (af = 1, process.env.NODE_ENV !== "production" && function() {
48
- var e = xn, t = Symbol.for("react.element"), n = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), l = Symbol.for("react.strict_mode"), d = Symbol.for("react.profiler"), f = Symbol.for("react.provider"), p = Symbol.for("react.context"), _ = Symbol.for("react.forward_ref"), T = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"), S = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), M = Symbol.for("react.offscreen"), m = Symbol.iterator, v = "@@iterator";
48
+ var e = Cn, t = Symbol.for("react.element"), n = Symbol.for("react.portal"), r = Symbol.for("react.fragment"), l = Symbol.for("react.strict_mode"), d = Symbol.for("react.profiler"), f = Symbol.for("react.provider"), p = Symbol.for("react.context"), _ = Symbol.for("react.forward_ref"), T = Symbol.for("react.suspense"), E = Symbol.for("react.suspense_list"), S = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), M = Symbol.for("react.offscreen"), m = Symbol.iterator, v = "@@iterator";
49
49
  function k(pe) {
50
50
  if (pe === null || typeof pe != "object")
51
51
  return null;
@@ -359,7 +359,7 @@ function ey() {
359
359
  return st;
360
360
  }
361
361
  }
362
- function at(pe) {
362
+ function ct(pe) {
363
363
  try {
364
364
  return Dt(pe), !1;
365
365
  } catch {
@@ -370,7 +370,7 @@ function ey() {
370
370
  return "" + pe;
371
371
  }
372
372
  function zt(pe) {
373
- if (at(pe))
373
+ if (ct(pe))
374
374
  return I("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.", Be(pe)), Dt(pe);
375
375
  }
376
376
  var Qt = G.ReactCurrentOwner, Oe = {
@@ -633,7 +633,7 @@ React keys must be passed directly to JSX without using spread:
633
633
  }()), Gl;
634
634
  }
635
635
  process.env.NODE_ENV === "production" ? Hu.exports = Q_() : Hu.exports = ey();
636
- var ft = Hu.exports;
636
+ var at = Hu.exports;
637
637
  function ty(e) {
638
638
  switch (e) {
639
639
  case "AD":
@@ -1050,7 +1050,7 @@ const ny = {
1050
1050
  countryCode: "localizedCountryName"
1051
1051
  }[e];
1052
1052
  return r && t[r];
1053
- }, zS = (e, t = [], n, r = {
1053
+ }, US = (e, t = [], n, r = {
1054
1054
  route: !1
1055
1055
  }, l) => {
1056
1056
  const d = "Failed to construct query for maps service.";
@@ -1128,14 +1128,14 @@ const ny = {
1128
1128
  if (!e.length) return "";
1129
1129
  const t = e.filter(Boolean).join(", ");
1130
1130
  return encodeURI(t);
1131
- }, US = ({
1131
+ }, GS = ({
1132
1132
  address: e,
1133
1133
  lines: t,
1134
1134
  separator: n = ",",
1135
1135
  ...r
1136
1136
  }) => {
1137
1137
  const l = (t || ty(e.countryCode)).map(
1138
- (d) => /* @__PURE__ */ ft.jsx(
1138
+ (d) => /* @__PURE__ */ at.jsx(
1139
1139
  sy,
1140
1140
  {
1141
1141
  address: e,
@@ -1156,7 +1156,7 @@ const ny = {
1156
1156
  for (const d of t) {
1157
1157
  if (d === ",") {
1158
1158
  r.push(
1159
- /* @__PURE__ */ ft.jsx("span", { children: n }, `separator-${l++}`)
1159
+ /* @__PURE__ */ at.jsx("span", { children: n }, `separator-${l++}`)
1160
1160
  );
1161
1161
  continue;
1162
1162
  }
@@ -1166,16 +1166,16 @@ const ny = {
1166
1166
  const p = ry(d, e);
1167
1167
  if (p) {
1168
1168
  r.push(
1169
- /* @__PURE__ */ ft.jsxs(Y_.Fragment, { children: [
1169
+ /* @__PURE__ */ at.jsxs(Y_.Fragment, { children: [
1170
1170
  " ",
1171
- /* @__PURE__ */ ft.jsx("abbr", { title: p, children: f })
1171
+ /* @__PURE__ */ at.jsx("abbr", { title: p, children: f })
1172
1172
  ] }, d)
1173
1173
  );
1174
1174
  continue;
1175
1175
  }
1176
- r.push(/* @__PURE__ */ ft.jsx("span", { children: " " + f }, d));
1176
+ r.push(/* @__PURE__ */ at.jsx("span", { children: " " + f }, d));
1177
1177
  }
1178
- return /* @__PURE__ */ ft.jsx("div", { className: "address-line", children: r });
1178
+ return /* @__PURE__ */ at.jsx("div", { className: "address-line", children: r });
1179
1179
  };
1180
1180
  var tl = {};
1181
1181
  Object.defineProperty(tl, "__esModule", {
@@ -1547,8 +1547,8 @@ const Wy = (e) => {
1547
1547
  default:
1548
1548
  return "";
1549
1549
  }
1550
- }, lp = Nc(null), Ky = q_(() => import("./debugger-BTQVKCwx.js"));
1551
- function GS(e) {
1550
+ }, lp = Nc(null), Ky = q_(() => import("./debugger-7xORzT5W.js"));
1551
+ function YS(e) {
1552
1552
  const {
1553
1553
  children: t,
1554
1554
  apiKey: n,
@@ -1562,7 +1562,7 @@ function GS(e) {
1562
1562
  if (!n)
1563
1563
  throw new Error("API Key is required for AnalyticsProvider");
1564
1564
  const T = od(null), [E, S] = Nr(!1);
1565
- sr(() => {
1565
+ tr(() => {
1566
1566
  S(!0);
1567
1567
  }, []), T.current === null && (T.current = new zy(
1568
1568
  n,
@@ -1574,9 +1574,13 @@ function GS(e) {
1574
1574
  p ?? Uu()
1575
1575
  ));
1576
1576
  const w = T.current;
1577
- return /* @__PURE__ */ ft.jsxs(ft.Fragment, { children: [
1578
- /* @__PURE__ */ ft.jsx(lp.Provider, { value: w, children: t }),
1579
- E && (p || Uu()) && sa().name === "browser" ? /* @__PURE__ */ ft.jsx(j_, { fallback: /* @__PURE__ */ ft.jsx(ft.Fragment, {}), children: /* @__PURE__ */ ft.jsx(Ky, {}) }) : null
1577
+ return tr(() => (window.enableYextAnalytics = () => {
1578
+ w.optIn();
1579
+ }, () => {
1580
+ delete window.enableYextAnalytics;
1581
+ }), [w]), /* @__PURE__ */ at.jsxs(at.Fragment, { children: [
1582
+ /* @__PURE__ */ at.jsx(lp.Provider, { value: w, children: t }),
1583
+ E && (p || Uu()) && sa().name === "browser" ? /* @__PURE__ */ at.jsx(j_, { fallback: /* @__PURE__ */ at.jsx(at.Fragment, {}), children: /* @__PURE__ */ at.jsx(Ky, {}) }) : null
1580
1584
  ] });
1581
1585
  }
1582
1586
  function Uu() {
@@ -1688,14 +1692,14 @@ class zy {
1688
1692
  }
1689
1693
  }
1690
1694
  const Gu = Nc({ name: "" }), ap = () => co(Gu).name;
1691
- function YS(e) {
1695
+ function VS(e) {
1692
1696
  var f;
1693
1697
  const t = ap(), [n] = Nr({
1694
1698
  name: op(t, e.name)
1695
1699
  }), r = (f = ca()) == null ? void 0 : f.getDebugEnabled(), [l, d] = Nr(!1);
1696
- return sr(() => {
1700
+ return tr(() => {
1697
1701
  d(!0);
1698
- }, []), r && l ? /* @__PURE__ */ ft.jsx("section", { "data-ya-scope": n.name, children: /* @__PURE__ */ ft.jsx(Gu.Provider, { value: n, children: e.children }) }) : /* @__PURE__ */ ft.jsx(Gu.Provider, { value: n, children: e.children });
1702
+ }, []), r && l ? /* @__PURE__ */ at.jsx("section", { "data-ya-scope": n.name, children: /* @__PURE__ */ at.jsx(Gu.Provider, { value: n, children: e.children }) }) : /* @__PURE__ */ at.jsx(Gu.Provider, { value: n, children: e.children });
1699
1703
  }
1700
1704
  function ca() {
1701
1705
  const e = co(lp);
@@ -1727,13 +1731,13 @@ function ca() {
1727
1731
  }
1728
1732
  };
1729
1733
  }
1730
- const VS = () => {
1734
+ const jS = () => {
1731
1735
  var e;
1732
1736
  return (e = ca()) == null ? void 0 : e.track;
1733
- }, jS = () => {
1737
+ }, qS = () => {
1734
1738
  var e;
1735
1739
  return (e = ca()) == null ? void 0 : e.pageView;
1736
- }, qS = () => {
1740
+ }, ZS = () => {
1737
1741
  var e;
1738
1742
  return (e = ca()) == null ? void 0 : e.identify;
1739
1743
  }, so = {
@@ -1936,7 +1940,7 @@ const VS = () => {
1936
1940
  return !1;
1937
1941
  }
1938
1942
  return t.protocol === "http:" || t.protocol === "https:";
1939
- }, ZS = ({
1943
+ }, JS = ({
1940
1944
  image: e,
1941
1945
  className: t,
1942
1946
  width: n,
@@ -1949,7 +1953,7 @@ const VS = () => {
1949
1953
  loading: T = "lazy"
1950
1954
  }) => {
1951
1955
  const E = od(null), [S, w] = Nr(!1), M = "image" in e ? e.image : e;
1952
- sr(() => {
1956
+ tr(() => {
1953
1957
  var ce;
1954
1958
  (ce = E.current) != null && ce.complete && w(!0);
1955
1959
  }, []), jy(
@@ -1964,7 +1968,7 @@ const VS = () => {
1964
1968
  m || console.warn("Invalid image width.");
1965
1969
  const v = Math.abs(M.height);
1966
1970
  if (v || console.warn("Invalid image height."), !cp(M.url))
1967
- return console.error(`Invalid image url: ${M.url}`), /* @__PURE__ */ ft.jsx(ft.Fragment, { children: f != null && f });
1971
+ return console.error(`Invalid image url: ${M.url}`), /* @__PURE__ */ at.jsx(at.Fragment, { children: f != null && f });
1968
1972
  const k = n && n > 0 ? n : void 0, G = r && r > 0 ? r : void 0, { src: I, imgStyle: P, widths: H } = qy(
1969
1973
  d,
1970
1974
  m,
@@ -1979,9 +1983,9 @@ const VS = () => {
1979
1983
  ).join(", "), re = [640, 768, 1024, 1280, 1536], te = H.map(
1980
1984
  (ce, j) => j === H.length - 1 ? `${ce}px` : `(max-width: ${re[j]}px) ${ce}px`
1981
1985
  ).join(", ");
1982
- return /* @__PURE__ */ ft.jsxs(ft.Fragment, { children: [
1986
+ return /* @__PURE__ */ at.jsxs(at.Fragment, { children: [
1983
1987
  !S && f != null && f,
1984
- /* @__PURE__ */ ft.jsx(
1988
+ /* @__PURE__ */ at.jsx(
1985
1989
  "img",
1986
1990
  {
1987
1991
  ref: E,
@@ -2190,7 +2194,7 @@ const oa = /* @__PURE__ */ rp(Jy), Xy = "phonecall", Qy = "drivingdirection", yf
2190
2194
  rel: t.target && !t.rel ? "noopener" : void 0,
2191
2195
  ref: n
2192
2196
  };
2193
- return I != null && I.getDebugEnabled() && (re["data-ya-action"] = k, re["data-ya-scopeoverride"] = p, re["data-ya-eventname"] = G), /* @__PURE__ */ ft.jsx("a", { ...m, ...re, suppressHydrationWarning: !0, children: r || v.label || V });
2197
+ return I != null && I.getDebugEnabled() && (re["data-ya-action"] = k, re["data-ya-scopeoverride"] = p, re["data-ya-eventname"] = G), /* @__PURE__ */ at.jsx("a", { ...m, ...re, suppressHydrationWarning: !0, children: r || v.label || V });
2194
2198
  }
2195
2199
  );
2196
2200
  var yn = /* @__PURE__ */ ((e) => (e.DEGREE = "deg", e.KILOMETER = "km", e.MILE = "mi", e.RADIAN = "r", e))(yn || {}), Vr = /* @__PURE__ */ ((e) => (e.MERCATOR = "mercator", e.SPHERICAL = "spherical", e))(Vr || {});
@@ -3597,7 +3601,7 @@ let pp = class {
3597
3601
  }
3598
3602
  };
3599
3603
  const Cc = Nc(null);
3600
- function XS() {
3604
+ function QS() {
3601
3605
  const e = co(Cc);
3602
3606
  if (!e || e.map === void 0)
3603
3607
  throw new Error("Attempted to call useMapContext() outside of <Map>.");
@@ -3623,24 +3627,24 @@ const xN = ({
3623
3627
  const v = od(null), [k, G] = Nr(new fn(f)), [I, P] = Nr(!1), [H, V] = Nr(), [re, te] = Nr(p), ce = (j, z) => {
3624
3628
  E(j, z), z && G(z.getCenter());
3625
3629
  };
3626
- return sr(() => {
3630
+ return tr(() => {
3627
3631
  !I || !H || te(H.getZoom());
3628
- }, [k]), sr(() => {
3632
+ }, [k]), tr(() => {
3629
3633
  if (!t || !I || !H)
3630
3634
  return;
3631
3635
  const j = t.map((z) => new fn(z));
3632
3636
  H.fitCoordinates(j);
3633
- }, [JSON.stringify(t), H]), sr(() => {
3637
+ }, [JSON.stringify(t), H]), tr(() => {
3634
3638
  if (!I || H)
3635
3639
  return;
3636
3640
  const j = new gp().withControlEnabled(d).withDefaultCenter(k).withDefaultZoom(re).withPadding(T).withPanHandler(ce).withPanStartHandler(S).withProvider(w).withProviderOptions(M).withSinglePinZoom(m).withWrapper(v.current).build();
3637
3641
  V(j), _ && (_.current = j);
3638
- }, [I]), sr(() => {
3642
+ }, [I]), tr(() => {
3639
3643
  I || H || !v.current || w.load(e, {
3640
3644
  ...M,
3641
3645
  ...l && { client: l }
3642
3646
  }).then(() => P(!0));
3643
- }, []), /* @__PURE__ */ ft.jsx(
3647
+ }, []), /* @__PURE__ */ at.jsx(
3644
3648
  "div",
3645
3649
  {
3646
3650
  className: oa(
@@ -3652,18 +3656,18 @@ const xN = ({
3652
3656
  id: "map",
3653
3657
  ref: v,
3654
3658
  "data-testid": "map",
3655
- children: H && /* @__PURE__ */ ft.jsx(Cc.Provider, { value: { map: H, provider: w }, children: n })
3659
+ children: H && /* @__PURE__ */ at.jsx(Cc.Provider, { value: { map: H, provider: w }, children: n })
3656
3660
  }
3657
3661
  );
3658
- }, vN = ({ count: e }) => /* @__PURE__ */ ft.jsx(
3662
+ }, vN = ({ count: e }) => /* @__PURE__ */ at.jsx(
3659
3663
  "svg",
3660
3664
  {
3661
3665
  xmlns: "http://www.w3.org/2000/svg",
3662
3666
  width: "22",
3663
3667
  height: "22",
3664
3668
  viewBox: "0 0 22 22",
3665
- children: /* @__PURE__ */ ft.jsxs("g", { fill: "none", fillRule: "evenodd", children: [
3666
- /* @__PURE__ */ ft.jsx(
3669
+ children: /* @__PURE__ */ at.jsxs("g", { fill: "none", fillRule: "evenodd", children: [
3670
+ /* @__PURE__ */ at.jsx(
3667
3671
  "circle",
3668
3672
  {
3669
3673
  fill: "red",
@@ -3674,14 +3678,14 @@ const xN = ({
3674
3678
  r: "11"
3675
3679
  }
3676
3680
  ),
3677
- /* @__PURE__ */ ft.jsx(
3681
+ /* @__PURE__ */ at.jsx(
3678
3682
  "text",
3679
3683
  {
3680
3684
  fill: "white",
3681
3685
  fontFamily: "Arial-BoldMT,Arial",
3682
3686
  fontSize: "12",
3683
3687
  fontWeight: "bold",
3684
- children: /* @__PURE__ */ ft.jsx("tspan", { x: "50%", y: "15", textAnchor: "middle", children: e })
3688
+ children: /* @__PURE__ */ at.jsx("tspan", { x: "50%", y: "15", textAnchor: "middle", children: e })
3685
3689
  }
3686
3690
  )
3687
3691
  ] })
@@ -3689,7 +3693,7 @@ const xN = ({
3689
3693
  ), ud = Nc(
3690
3694
  null
3691
3695
  );
3692
- function QS() {
3696
+ function ew() {
3693
3697
  const e = co(ud);
3694
3698
  if (!e)
3695
3699
  throw new Error(
@@ -3697,15 +3701,15 @@ function QS() {
3697
3701
  );
3698
3702
  return e;
3699
3703
  }
3700
- const ew = ({
3704
+ const tw = ({
3701
3705
  clusterRadius: e = 50,
3702
3706
  children: t,
3703
3707
  ClusterTemplate: n = vN
3704
3708
  }) => {
3705
3709
  const { map: r } = co(Cc), [l, d] = Nr([]), [f, p] = Nr(), [_, T] = Nr([]), [E, S] = Nr([]);
3706
- return sr(() => {
3710
+ return tr(() => {
3707
3711
  p(SN(l, r.getZoom(), e));
3708
- }, [l, r.getZoom()]), sr(() => {
3712
+ }, [l, r.getZoom()]), tr(() => {
3709
3713
  S(() => []), T(() => []), (f == null ? void 0 : f.length) !== 0 && (f == null || f.forEach((w) => {
3710
3714
  if (w.length === 1) {
3711
3715
  w[0].pin.setMap(r);
@@ -3717,7 +3721,7 @@ const ew = ({
3717
3721
  ).getCenter(Vr.MERCATOR), m = `cluster-{${M._lat},${M._lon}}`;
3718
3722
  w.forEach((v) => v.pin.setMap(null)), T((v) => [...v, m]), S((v) => [
3719
3723
  ...v,
3720
- /* @__PURE__ */ ft.jsx(
3724
+ /* @__PURE__ */ at.jsx(
3721
3725
  mp,
3722
3726
  {
3723
3727
  coordinate: M,
@@ -3727,14 +3731,14 @@ const ew = ({
3727
3731
  !0,
3728
3732
  1 / 0
3729
3733
  ),
3730
- children: /* @__PURE__ */ ft.jsx(n, { count: w.length })
3734
+ children: /* @__PURE__ */ at.jsx(n, { count: w.length })
3731
3735
  },
3732
3736
  m
3733
3737
  )
3734
3738
  ]);
3735
3739
  }
3736
3740
  }));
3737
- }, [f]), /* @__PURE__ */ ft.jsx(
3741
+ }, [f]), /* @__PURE__ */ at.jsx(
3738
3742
  ud.Provider,
3739
3743
  {
3740
3744
  value: {
@@ -3742,8 +3746,8 @@ const ew = ({
3742
3746
  clusterIds: _,
3743
3747
  setPinStore: d
3744
3748
  },
3745
- children: /* @__PURE__ */ ft.jsxs(ft.Fragment, { children: [
3746
- E.map((w, M) => /* @__PURE__ */ ft.jsx(J_, { children: w }, M)),
3749
+ children: /* @__PURE__ */ at.jsxs(at.Fragment, { children: [
3750
+ E.map((w, M) => /* @__PURE__ */ at.jsx(J_, { children: w }, M)),
3747
3751
  t
3748
3752
  ] })
3749
3753
  }
@@ -3780,7 +3784,7 @@ const ew = ({
3780
3784
  d.push(T);
3781
3785
  }
3782
3786
  return d;
3783
- }, wN = /* @__PURE__ */ ft.jsx(
3787
+ }, wN = /* @__PURE__ */ at.jsx(
3784
3788
  "svg",
3785
3789
  {
3786
3790
  width: "30",
@@ -3788,7 +3792,7 @@ const ew = ({
3788
3792
  viewBox: "0 0 30 38",
3789
3793
  fill: "none",
3790
3794
  xmlns: "http://www.w3.org/2000/svg",
3791
- children: /* @__PURE__ */ ft.jsx(
3795
+ children: /* @__PURE__ */ at.jsx(
3792
3796
  "path",
3793
3797
  {
3794
3798
  d: "M30 15.0882C30 23.4212 23.3333 30.7353 15 38C7.22222 31.2941 0 23.4212 0 15.0882C0 6.75523 6.71573 0 15 0C23.2843 0 30 6.75523 30 15.0882Z",
@@ -3809,12 +3813,12 @@ const ew = ({
3809
3813
  hasPinUrl: T = !1
3810
3814
  }) => {
3811
3815
  const { map: E, provider: S } = co(Cc), w = co(ud), M = tp(() => new cd().withCoordinate(t).withHideOffscreen(n).withProvider(S).withHasPinUrl(T).build(), []);
3812
- sr(() => {
3816
+ tr(() => {
3813
3817
  if (_ !== 0 && !_)
3814
3818
  return;
3815
3819
  const v = M.getProviderPin().getWrapperElement();
3816
3820
  v && (v.style.zIndex = _.toString());
3817
- }, [_]), sr(() => {
3821
+ }, [_]), tr(() => {
3818
3822
  M.setMap(E), M.setClickHandler(() => d(r)), M.setFocusHandler((k) => f(k, r)), M.setHoverHandler((k) => p(k, r));
3819
3823
  const v = w == null ? void 0 : w.clusterIds.includes(r);
3820
3824
  return w && !v && w.setPinStore((k) => [
@@ -3838,7 +3842,7 @@ const ew = ({
3838
3842
  }), X_(m, v);
3839
3843
  }
3840
3844
  return null;
3841
- }, tw = ({
3845
+ }, nw = ({
3842
3846
  children: e,
3843
3847
  coordinate: t,
3844
3848
  linkSameTab: n,
@@ -3849,7 +3853,7 @@ const ew = ({
3849
3853
  ...p
3850
3854
  }) => {
3851
3855
  var _;
3852
- return /* @__PURE__ */ ft.jsx(xN, { bounds: [t], ...p, children: /* @__PURE__ */ ft.jsx(
3856
+ return /* @__PURE__ */ at.jsx(xN, { bounds: [t], ...p, children: /* @__PURE__ */ at.jsx(
3853
3857
  mp,
3854
3858
  {
3855
3859
  coordinate: t,
@@ -3858,7 +3862,7 @@ const ew = ({
3858
3862
  onHover: d,
3859
3863
  onFocus: f,
3860
3864
  hasPinUrl: ((_ = r || "") == null ? void 0 : _.length) > 0,
3861
- children: r ? /* @__PURE__ */ ft.jsx(
3865
+ children: r ? /* @__PURE__ */ at.jsx(
3862
3866
  cN,
3863
3867
  {
3864
3868
  href: r,
@@ -3874,7 +3878,7 @@ var qc = {}, Yl = {}, xf;
3874
3878
  function ON() {
3875
3879
  if (xf) return Yl;
3876
3880
  xf = 1;
3877
- var e = xn;
3881
+ var e = Cn;
3878
3882
  const t = /* @__PURE__ */ e.createContext(null);
3879
3883
  function n(l, d) {
3880
3884
  let f = null;
@@ -3898,7 +3902,7 @@ var Vl = {}, vf;
3898
3902
  function DN() {
3899
3903
  if (vf) return Vl;
3900
3904
  vf = 1;
3901
- var e = xn;
3905
+ var e = Cn;
3902
3906
  function t(r) {
3903
3907
  let l = new URLSearchParams();
3904
3908
  l.append("code", r);
@@ -3929,7 +3933,7 @@ function AN() {
3929
3933
  type: u
3930
3934
  };
3931
3935
  }
3932
- const t = e("SELECTION_CHANGE_COMMAND"), n = e("SELECTION_INSERT_CLIPBOARD_NODES_COMMAND"), r = e("CLICK_COMMAND"), l = e("DELETE_CHARACTER_COMMAND"), d = e("INSERT_LINE_BREAK_COMMAND"), f = e("INSERT_PARAGRAPH_COMMAND"), p = e("CONTROLLED_TEXT_INSERTION_COMMAND"), _ = e("PASTE_COMMAND"), T = e("REMOVE_TEXT_COMMAND"), E = e("DELETE_WORD_COMMAND"), S = e("DELETE_LINE_COMMAND"), w = e("FORMAT_TEXT_COMMAND"), M = e("UNDO_COMMAND"), m = e("REDO_COMMAND"), v = e("KEYDOWN_COMMAND"), k = e("KEY_ARROW_RIGHT_COMMAND"), G = e("MOVE_TO_END"), I = e("KEY_ARROW_LEFT_COMMAND"), P = e("MOVE_TO_START"), H = e("KEY_ARROW_UP_COMMAND"), V = e("KEY_ARROW_DOWN_COMMAND"), re = e("KEY_ENTER_COMMAND"), te = e("KEY_SPACE_COMMAND"), ce = e("KEY_BACKSPACE_COMMAND"), j = e("KEY_ESCAPE_COMMAND"), z = e("KEY_DELETE_COMMAND"), q = e("KEY_TAB_COMMAND"), Te = e("INSERT_TAB_COMMAND"), Se = e("INDENT_CONTENT_COMMAND"), Ee = e("OUTDENT_CONTENT_COMMAND"), de = e("DROP_COMMAND"), K = e("FORMAT_ELEMENT_COMMAND"), O = e("DRAGSTART_COMMAND"), Z = e("DRAGOVER_COMMAND"), oe = e("DRAGEND_COMMAND"), Y = e("COPY_COMMAND"), W = e("CUT_COMMAND"), J = e("SELECT_ALL_COMMAND"), R = e("CLEAR_EDITOR_COMMAND"), U = e("CLEAR_HISTORY_COMMAND"), X = e("CAN_REDO_COMMAND"), fe = e("CAN_UNDO_COMMAND"), _e = e("FOCUS_COMMAND"), B = e("BLUR_COMMAND"), A = e("KEY_MODIFIER_COMMAND"), F = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u", se = F && "documentMode" in document ? document.documentMode : null, ye = F && /Mac|iPod|iPhone|iPad/.test(navigator.platform), De = F && /^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent), ee = F && "InputEvent" in window && !se ? "getTargetRanges" in new window.InputEvent("input") : !1, ne = F && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), ue = F && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, be = F && /Android/.test(navigator.userAgent), Ne = F && /^(?=.*Chrome).*/i.test(navigator.userAgent), Re = F && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !Ne, ke = 1, Fe = 3, qe = 0, Be = 1, at = 2, Dt = 0, zt = 1, Qt = 2, Oe = 1, ie = 2, le = 4, ve = 8, Le = 16, Me = 32, Ve = 64, nt = 128, rt = Oe | ie | le | ve | Le | Me | Ve | nt, it = 1, xt = 2, Ge = 1, ze = 2, tt = 3, _t = 4, yt = 5, Ct = 6, ht = " ", pt = ne || ue || Re ? ht : "​", Pt = `
3936
+ const t = e("SELECTION_CHANGE_COMMAND"), n = e("SELECTION_INSERT_CLIPBOARD_NODES_COMMAND"), r = e("CLICK_COMMAND"), l = e("DELETE_CHARACTER_COMMAND"), d = e("INSERT_LINE_BREAK_COMMAND"), f = e("INSERT_PARAGRAPH_COMMAND"), p = e("CONTROLLED_TEXT_INSERTION_COMMAND"), _ = e("PASTE_COMMAND"), T = e("REMOVE_TEXT_COMMAND"), E = e("DELETE_WORD_COMMAND"), S = e("DELETE_LINE_COMMAND"), w = e("FORMAT_TEXT_COMMAND"), M = e("UNDO_COMMAND"), m = e("REDO_COMMAND"), v = e("KEYDOWN_COMMAND"), k = e("KEY_ARROW_RIGHT_COMMAND"), G = e("MOVE_TO_END"), I = e("KEY_ARROW_LEFT_COMMAND"), P = e("MOVE_TO_START"), H = e("KEY_ARROW_UP_COMMAND"), V = e("KEY_ARROW_DOWN_COMMAND"), re = e("KEY_ENTER_COMMAND"), te = e("KEY_SPACE_COMMAND"), ce = e("KEY_BACKSPACE_COMMAND"), j = e("KEY_ESCAPE_COMMAND"), z = e("KEY_DELETE_COMMAND"), q = e("KEY_TAB_COMMAND"), Te = e("INSERT_TAB_COMMAND"), Se = e("INDENT_CONTENT_COMMAND"), Ee = e("OUTDENT_CONTENT_COMMAND"), de = e("DROP_COMMAND"), K = e("FORMAT_ELEMENT_COMMAND"), O = e("DRAGSTART_COMMAND"), Z = e("DRAGOVER_COMMAND"), oe = e("DRAGEND_COMMAND"), Y = e("COPY_COMMAND"), W = e("CUT_COMMAND"), J = e("SELECT_ALL_COMMAND"), R = e("CLEAR_EDITOR_COMMAND"), U = e("CLEAR_HISTORY_COMMAND"), X = e("CAN_REDO_COMMAND"), fe = e("CAN_UNDO_COMMAND"), _e = e("FOCUS_COMMAND"), B = e("BLUR_COMMAND"), A = e("KEY_MODIFIER_COMMAND"), F = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u", se = F && "documentMode" in document ? document.documentMode : null, ye = F && /Mac|iPod|iPhone|iPad/.test(navigator.platform), De = F && /^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent), ee = F && "InputEvent" in window && !se ? "getTargetRanges" in new window.InputEvent("input") : !1, ne = F && /Version\/[\d.]+.*Safari/.test(navigator.userAgent), ue = F && /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream, be = F && /Android/.test(navigator.userAgent), Ne = F && /^(?=.*Chrome).*/i.test(navigator.userAgent), Re = F && /AppleWebKit\/[\d.]+/.test(navigator.userAgent) && !Ne, ke = 1, Fe = 3, qe = 0, Be = 1, ct = 2, Dt = 0, zt = 1, Qt = 2, Oe = 1, ie = 2, le = 4, ve = 8, Le = 16, Me = 32, Ve = 64, nt = 128, rt = Oe | ie | le | ve | Le | Me | Ve | nt, it = 1, xt = 2, Ge = 1, ze = 2, tt = 3, _t = 4, yt = 5, Ct = 6, ht = " ", pt = ne || ue || Re ? ht : "​", Pt = `
3933
3937
 
3934
3938
  `, Wt = De ? ht : pt, en = "֑-߿יִ-﷽ﹰ-ﻼ", Lt = "A-Za-zÀ-ÖØ-öø-ʸ̀-֐ࠀ-῿‎Ⰰ-﬜︀-﹯﻽-￿", Yt = new RegExp("^[^" + Lt + "]*[" + en + "]"), Rt = new RegExp("^[^" + en + "]*[" + Lt + "]"), tn = {
3935
3939
  bold: Oe,
@@ -4029,20 +4033,20 @@ function AN() {
4029
4033
  const Ht = Mt[jt], Ot = mo(Ht), ln = Ht.parentNode;
4030
4034
  if (ln != null && Ht !== ae && Ot === null && (Ht.nodeName !== "BR" || !rn(Ht, ln, u))) {
4031
4035
  if (De) {
4032
- const ir = Ht.innerText || Ht.nodeValue;
4033
- ir && (me += ir);
4036
+ const sr = Ht.innerText || Ht.nodeValue;
4037
+ sr && (me += sr);
4034
4038
  }
4035
4039
  ln.removeChild(Ht);
4036
4040
  }
4037
4041
  }
4038
- const Qe = Ce.removedNodes, dt = Qe.length;
4039
- if (dt > 0) {
4042
+ const Qe = Ce.removedNodes, ft = Qe.length;
4043
+ if (ft > 0) {
4040
4044
  let jt = 0;
4041
- for (let Ht = 0; Ht < dt; Ht++) {
4045
+ for (let Ht = 0; Ht < ft; Ht++) {
4042
4046
  const Ot = Qe[Ht];
4043
4047
  (Ot.nodeName === "BR" && rn(Ot, Ue, u) || ae === Ot) && (Ue.appendChild(Ot), jt++);
4044
4048
  }
4045
- dt !== jt && (Ue === b && ($e = gl($)), N.set(Ue, $e));
4049
+ ft !== jt && (Ue === b && ($e = gl($)), N.set(Ue, $e));
4046
4050
  }
4047
4051
  }
4048
4052
  }
@@ -4091,7 +4095,7 @@ function AN() {
4091
4095
  return (c === null || c === N) && (h === null || h === b) && (y === null || y === $);
4092
4096
  }
4093
4097
  function bi(u, s) {
4094
- const c = u.mergeWithSibling(s), h = Tn()._normalizedNodes;
4098
+ const c = u.mergeWithSibling(s), h = xn()._normalizedNodes;
4095
4099
  return h.add(u.__key), h.add(s.__key), c;
4096
4100
  }
4097
4101
  function Er(u) {
@@ -4211,7 +4215,7 @@ function AN() {
4211
4215
  return;
4212
4216
  }
4213
4217
  hr(), Gd();
4214
- const c = Tn(), h = Si(), y = qr();
4218
+ const c = xn(), h = Si(), y = qr();
4215
4219
  h._nodeMap.set(y, u), et(u) ? c._dirtyElements.set(y, !0) : c._dirtyLeaves.add(y), c._cloneNotNeeded.add(y), c._dirtyType = Be, u.__key = y;
4216
4220
  }
4217
4221
  function fl(u, s, c) {
@@ -4264,7 +4268,7 @@ function AN() {
4264
4268
  }
4265
4269
  function Li(u) {
4266
4270
  Gd();
4267
- const s = u.getLatest(), c = s.__parent, h = Si(), y = Tn(), N = h._nodeMap, b = y._dirtyElements;
4271
+ const s = u.getLatest(), c = s.__parent, h = Si(), y = xn(), N = h._nodeMap, b = y._dirtyElements;
4268
4272
  c !== null && fl(c, N, b);
4269
4273
  const $ = s.__key;
4270
4274
  y._dirtyType = Be, et(u) ? b.set($, !0) : y._dirtyLeaves.add($);
@@ -4275,7 +4279,7 @@ function AN() {
4275
4279
  }
4276
4280
  function vn(u) {
4277
4281
  hr();
4278
- const s = Tn(), c = s._compositionKey;
4282
+ const s = xn(), c = s._compositionKey;
4279
4283
  if (u !== c) {
4280
4284
  if (s._compositionKey = u, c !== null) {
4281
4285
  const h = Nn(c);
@@ -4288,14 +4292,14 @@ function AN() {
4288
4292
  }
4289
4293
  }
4290
4294
  function ar() {
4291
- return Wo() ? null : Tn()._compositionKey;
4295
+ return Wo() ? null : xn()._compositionKey;
4292
4296
  }
4293
4297
  function Nn(u, s) {
4294
4298
  const h = (s || Si())._nodeMap.get(u);
4295
4299
  return h === void 0 ? null : h;
4296
4300
  }
4297
4301
  function mo(u, s) {
4298
- const c = Tn(), h = u[`__lexicalKey_${c._key}`];
4302
+ const c = xn(), h = u[`__lexicalKey_${c._key}`];
4299
4303
  return h !== void 0 ? Nn(h, s) : null;
4300
4304
  }
4301
4305
  function oi(u, s) {
@@ -4313,7 +4317,7 @@ function AN() {
4313
4317
  return u._pendingDecorators = c, c;
4314
4318
  }
4315
4319
  function _o(u) {
4316
- return u.read(() => tr().getTextContent());
4320
+ return u.read(() => nr().getTextContent());
4317
4321
  }
4318
4322
  function Ii(u, s) {
4319
4323
  Gr(u, () => {
@@ -4321,7 +4325,7 @@ function AN() {
4321
4325
  if (c.isEmpty())
4322
4326
  return;
4323
4327
  if (s === "root") {
4324
- tr().markDirty();
4328
+ nr().markDirty();
4325
4329
  return;
4326
4330
  }
4327
4331
  const h = c._nodeMap;
@@ -4331,7 +4335,7 @@ function AN() {
4331
4335
  tag: "history-merge"
4332
4336
  } : void 0);
4333
4337
  }
4334
- function tr() {
4338
+ function nr() {
4335
4339
  return gl(Si());
4336
4340
  }
4337
4341
  function gl(u) {
@@ -4349,11 +4353,11 @@ function AN() {
4349
4353
  }
4350
4354
  function pl() {
4351
4355
  hr();
4352
- const u = Tn();
4356
+ const u = xn();
4353
4357
  un(u);
4354
4358
  }
4355
4359
  function ki(u) {
4356
- const s = Tn(), c = ya(u, s);
4360
+ const s = xn(), c = ya(u, s);
4357
4361
  if (c === null) {
4358
4362
  const h = s.getRootElement();
4359
4363
  return u === h ? Nn("root") : null;
@@ -4420,7 +4424,7 @@ function AN() {
4420
4424
  if (y || $ !== ae) {
4421
4425
  if ($ === "") {
4422
4426
  if (vn(null), !ne && !ue && !Re) {
4423
- const Ue = Tn();
4427
+ const Ue = xn();
4424
4428
  setTimeout(() => {
4425
4429
  Ue.update(() => {
4426
4430
  N.isAttached() && N.remove();
@@ -4568,7 +4572,7 @@ function AN() {
4568
4572
  return u === 65 && Jr(s, c);
4569
4573
  }
4570
4574
  function xl() {
4571
- const u = tr(), s = u.select(0, u.getChildrenSize());
4575
+ const u = nr(), s = u.select(0, u.getChildrenSize());
4572
4576
  Tr(Ds(s));
4573
4577
  }
4574
4578
  function Bi(u, s) {
@@ -4624,7 +4628,7 @@ function AN() {
4624
4628
  const s = To(u).event, c = s && s.inputType;
4625
4629
  return c === "insertFromPaste" || c === "insertFromPasteAsQuotation";
4626
4630
  }
4627
- function ct(u, s, c) {
4631
+ function ut(u, s, c) {
4628
4632
  return Zd(u, s, c);
4629
4633
  }
4630
4634
  function Co(u) {
@@ -4672,10 +4676,10 @@ function AN() {
4672
4676
  }
4673
4677
  }
4674
4678
  function Un(u) {
4675
- return Tn()._updateTags.has(u);
4679
+ return xn()._updateTags.has(u);
4676
4680
  }
4677
4681
  function Nt(u) {
4678
- hr(), Tn()._updateTags.add(u);
4682
+ hr(), xn()._updateTags.add(u);
4679
4683
  }
4680
4684
  function ds(u) {
4681
4685
  const s = mn();
@@ -4726,7 +4730,7 @@ function AN() {
4726
4730
  return dl(s, null), s;
4727
4731
  }
4728
4732
  function Mr(u) {
4729
- const s = Tn(), c = u.constructor.getType(), h = s._nodes.get(c);
4733
+ const s = xn(), c = u.constructor.getType(), h = s._nodes.get(c);
4730
4734
  if (h === void 0)
4731
4735
  throw Error('$initializeNode failed. Ensure node has been registered to the editor. You can do this by passing the node class via the "nodes" array in the editor config.');
4732
4736
  const y = h.replace;
@@ -4809,7 +4813,7 @@ function AN() {
4809
4813
  }
4810
4814
  function So(u, s) {
4811
4815
  let c = u;
4812
- for (; c !== tr() && c != null; ) {
4816
+ for (; c !== nr() && c != null; ) {
4813
4817
  if (s(c))
4814
4818
  return c;
4815
4819
  c = c.getParent();
@@ -5031,7 +5035,7 @@ function AN() {
5031
5035
  Ui(b, 0, y - 1, he ? null : c), he && (c.textContent = "");
5032
5036
  }
5033
5037
  } else
5034
- Cn(s, b, $, y, N, c);
5038
+ En(s, b, $, y, N, c);
5035
5039
  }
5036
5040
  Co(s) && (In += Pt), c.__lexicalTextContent = In, In = h + In;
5037
5041
  }
@@ -5095,7 +5099,7 @@ function AN() {
5095
5099
  let s = u.nextSibling;
5096
5100
  return s !== null && s === Hn._blockCursorElement && (s = s.nextSibling), s;
5097
5101
  }
5098
- function Cn(u, s, c, h, y, N) {
5102
+ function En(u, s, c, h, y, N) {
5099
5103
  const b = h - 1, $ = y - 1;
5100
5104
  let ae, he, me = vr(N), xe = 0, we = 0;
5101
5105
  for (; xe <= b && we <= $; ) {
@@ -5110,8 +5114,8 @@ function AN() {
5110
5114
  else if (!Qe)
5111
5115
  dn($e, N, me), we++;
5112
5116
  else {
5113
- const dt = Bs(Hn, $e);
5114
- dt === me ? me = Do(ms($e, N)) : (me != null ? N.insertBefore(dt, me) : N.appendChild(dt), ms($e, N)), xe++, we++;
5117
+ const ft = Bs(Hn, $e);
5118
+ ft === me ? me = Do(ms($e, N)) : (me != null ? N.insertBefore(ft, me) : N.appendChild(ft), ms($e, N)), xe++, we++;
5115
5119
  }
5116
5120
  }
5117
5121
  }
@@ -5122,7 +5126,7 @@ function AN() {
5122
5126
  } else je && !Ce && Ui(s, xe, b, N);
5123
5127
  }
5124
5128
  function Yi(u, s, c, h, y, N) {
5125
- In = "", Vt = "", Gn = "", Pa = h === at, Us = null, Hn = c, xr = c._config, fs = c._nodes, zs = Hn._listeners.mutation, Gs = y, Al = N, zi = u._nodeMap, hn = s._nodeMap, hs = s._readOnly, On = new Map(c._keyToDOMMap);
5129
+ In = "", Vt = "", Gn = "", Pa = h === ct, Us = null, Hn = c, xr = c._config, fs = c._nodes, zs = Hn._listeners.mutation, Gs = y, Al = N, zi = u._nodeMap, hn = s._nodeMap, hs = s._readOnly, On = new Map(c._keyToDOMMap);
5126
5130
  const b = /* @__PURE__ */ new Map();
5127
5131
  return Wn = b, ms("root", null), Hn = void 0, fs = void 0, Gs = void 0, Al = void 0, zi = void 0, hn = void 0, xr = void 0, On = void 0, Wn = void 0, b;
5128
5132
  }
@@ -5136,11 +5140,11 @@ function AN() {
5136
5140
  throw Error(`Reconciliation: could not find DOM element for node key ${u}`);
5137
5141
  return s;
5138
5142
  }
5139
- const ur = Object.freeze({}), nr = 30, Ll = [["keydown", ge], ["pointerdown", $l], ["compositionstart", x], ["compositionend", Q], ["input", C], ["click", Ba], ["cut", ur], ["copy", ur], ["dragstart", ur], ["dragover", ur], ["dragend", ur], ["paste", ur], ["focus", ur], ["blur", ur], ["drop", ur]];
5143
+ const ur = Object.freeze({}), rr = 30, Ll = [["keydown", ge], ["pointerdown", $l], ["compositionstart", x], ["compositionend", Q], ["input", C], ["click", Ba], ["cut", ur], ["copy", ur], ["dragstart", ur], ["dragover", ur], ["dragend", ur], ["paste", ur], ["focus", ur], ["blur", ur], ["drop", ur]];
5140
5144
  ee && Ll.push(["beforeinput", (u, s) => g(u, s)]);
5141
5145
  let Vi = 0, Il = 0, Ys = 0, Kr = null, Vs = 0, zr = !1, Mo = !1, js = !1, qs = !1, Ro = [0, "", 0, "root", 0];
5142
5146
  function ji(u, s, c, h, y) {
5143
- const N = u.anchor, b = u.focus, $ = N.getNode(), ae = Tn(), he = cr(ae._window), me = he !== null ? he.anchorNode : null, xe = N.key, we = ae.getElementByKey(xe), Ce = c.length;
5147
+ const N = u.anchor, b = u.focus, $ = N.getNode(), ae = xn(), he = cr(ae._window), me = he !== null ? he.anchorNode : null, xe = N.key, we = ae.getElementByKey(xe), Ce = c.length;
5144
5148
  return xe !== b.key || // If we're working with a non-text node.
5145
5149
  !mt($) || // If we are replacing a range with a single character or grapheme, and not composing.
5146
5150
  (!y && (!ee || // We check to see if there has been
@@ -5180,7 +5184,7 @@ function AN() {
5180
5184
  const ae = $.anchor, he = ae.getNode();
5181
5185
  if ($.isCollapsed()) {
5182
5186
  u.type === "Range" && u.anchorNode === u.focusNode && ($.dirty = !0);
5183
- const me = To(s).event, xe = me ? me.timeStamp : performance.now(), [we, Ce, je, Ue, $e] = Ro, Mt = tr(), Qe = s.isComposing() === !1 && Mt.getTextContent() === "";
5187
+ const me = To(s).event, xe = me ? me.timeStamp : performance.now(), [we, Ce, je, Ue, $e] = Ro, Mt = nr(), Qe = s.isComposing() === !1 && Mt.getTextContent() === "";
5184
5188
  if (xe < $e + 200 && ae.offset === je && ae.key === Ue)
5185
5189
  $.format = we, $.style = Ce;
5186
5190
  else if (ae.type === "text") {
@@ -5199,7 +5203,7 @@ function AN() {
5199
5203
  $.format = xe ? me : 0;
5200
5204
  }
5201
5205
  }
5202
- ct(s, t, void 0);
5206
+ ut(s, t, void 0);
5203
5207
  });
5204
5208
  }
5205
5209
  function Ba(u, s) {
@@ -5208,7 +5212,7 @@ function AN() {
5208
5212
  if (h) {
5209
5213
  if (Et(c)) {
5210
5214
  const N = c.anchor, b = N.getNode();
5211
- if (N.type === "element" && N.offset === 0 && c.isCollapsed() && !Yr(b) && tr().getChildrenSize() === 1 && b.getTopLevelElementOrThrow().isEmpty() && y !== null && c.is(y))
5215
+ if (N.type === "element" && N.offset === 0 && c.isCollapsed() && !Yr(b) && nr().getChildrenSize() === 1 && b.getTopLevelElementOrThrow().isEmpty() && y !== null && c.is(y))
5212
5216
  h.removeAllRanges(), c.dirty = !0;
5213
5217
  else if (u.detail === 3 && !c.isCollapsed()) {
5214
5218
  const ae = c.focus.getNode();
@@ -5225,7 +5229,7 @@ function AN() {
5225
5229
  }
5226
5230
  }
5227
5231
  }
5228
- ct(s, r, u);
5232
+ ut(s, r, u);
5229
5233
  });
5230
5234
  }
5231
5235
  function $l(u, s) {
@@ -5244,7 +5248,7 @@ function AN() {
5244
5248
  return u !== s || et(u) || et(s) || !u.isToken() || !s.isToken();
5245
5249
  }
5246
5250
  function a(u) {
5247
- return Il === 229 && u < Vi + nr;
5251
+ return Il === 229 && u < Vi + rr;
5248
5252
  }
5249
5253
  function g(u, s) {
5250
5254
  const c = u.inputType, h = o(u);
@@ -5268,15 +5272,15 @@ function AN() {
5268
5272
  Gr(s, () => {
5269
5273
  vn(null);
5270
5274
  });
5271
- }, nr), Et(y)) {
5275
+ }, rr), Et(y)) {
5272
5276
  const xe = y.anchor.getNode();
5273
5277
  if (xe.markDirty(), y.format = xe.getFormat(), !mt(xe))
5274
5278
  throw Error("Anchor node must be a TextNode");
5275
5279
  y.style = xe.getStyle();
5276
5280
  }
5277
- y.anchor.getNode().getTextContent().length <= 1 && (u.preventDefault(), ct(s, l, !0));
5281
+ y.anchor.getNode().getTextContent().length <= 1 && (u.preventDefault(), ut(s, l, !0));
5278
5282
  } else
5279
- vn(null), u.preventDefault(), ct(s, l, !0);
5283
+ vn(null), u.preventDefault(), ut(s, l, !0);
5280
5284
  return;
5281
5285
  }
5282
5286
  }
@@ -5288,13 +5292,13 @@ function AN() {
5288
5292
  if (c === "insertText" || c === "insertTranspose") {
5289
5293
  if (N === `
5290
5294
  `)
5291
- u.preventDefault(), ct(s, d, !1);
5295
+ u.preventDefault(), ut(s, d, !1);
5292
5296
  else if (N === Pt)
5293
- u.preventDefault(), ct(s, f, void 0);
5297
+ u.preventDefault(), ut(s, f, void 0);
5294
5298
  else if (N == null && u.dataTransfer) {
5295
5299
  const me = u.dataTransfer.getData("text/plain");
5296
5300
  u.preventDefault(), y.insertRawText(me);
5297
- } else N != null && ji(y, h, N, u.timeStamp, !0) ? (u.preventDefault(), ct(s, p, N)) : Kr = N;
5301
+ } else N != null && ji(y, h, N, u.timeStamp, !0) ? (u.preventDefault(), ut(s, p, N)) : Kr = N;
5298
5302
  Ys = u.timeStamp;
5299
5303
  return;
5300
5304
  }
@@ -5302,80 +5306,80 @@ function AN() {
5302
5306
  case "insertFromYank":
5303
5307
  case "insertFromDrop":
5304
5308
  case "insertReplacementText": {
5305
- ct(s, p, u);
5309
+ ut(s, p, u);
5306
5310
  break;
5307
5311
  }
5308
5312
  case "insertFromComposition": {
5309
- vn(null), ct(s, p, u);
5313
+ vn(null), ut(s, p, u);
5310
5314
  break;
5311
5315
  }
5312
5316
  case "insertLineBreak": {
5313
- vn(null), ct(s, d, !1);
5317
+ vn(null), ut(s, d, !1);
5314
5318
  break;
5315
5319
  }
5316
5320
  case "insertParagraph": {
5317
- vn(null), js && !ue ? (js = !1, ct(s, d, !1)) : ct(s, f, void 0);
5321
+ vn(null), js && !ue ? (js = !1, ut(s, d, !1)) : ut(s, f, void 0);
5318
5322
  break;
5319
5323
  }
5320
5324
  case "insertFromPaste":
5321
5325
  case "insertFromPasteAsQuotation": {
5322
- ct(s, _, u);
5326
+ ut(s, _, u);
5323
5327
  break;
5324
5328
  }
5325
5329
  case "deleteByComposition": {
5326
- i(ae, he) && ct(s, T, u);
5330
+ i(ae, he) && ut(s, T, u);
5327
5331
  break;
5328
5332
  }
5329
5333
  case "deleteByDrag":
5330
5334
  case "deleteByCut": {
5331
- ct(s, T, u);
5335
+ ut(s, T, u);
5332
5336
  break;
5333
5337
  }
5334
5338
  case "deleteContent": {
5335
- ct(s, l, !1);
5339
+ ut(s, l, !1);
5336
5340
  break;
5337
5341
  }
5338
5342
  case "deleteWordBackward": {
5339
- ct(s, E, !0);
5343
+ ut(s, E, !0);
5340
5344
  break;
5341
5345
  }
5342
5346
  case "deleteWordForward": {
5343
- ct(s, E, !1);
5347
+ ut(s, E, !1);
5344
5348
  break;
5345
5349
  }
5346
5350
  case "deleteHardLineBackward":
5347
5351
  case "deleteSoftLineBackward": {
5348
- ct(s, S, !0);
5352
+ ut(s, S, !0);
5349
5353
  break;
5350
5354
  }
5351
5355
  case "deleteContentForward":
5352
5356
  case "deleteHardLineForward":
5353
5357
  case "deleteSoftLineForward": {
5354
- ct(s, S, !1);
5358
+ ut(s, S, !1);
5355
5359
  break;
5356
5360
  }
5357
5361
  case "formatStrikeThrough": {
5358
- ct(s, w, "strikethrough");
5362
+ ut(s, w, "strikethrough");
5359
5363
  break;
5360
5364
  }
5361
5365
  case "formatBold": {
5362
- ct(s, w, "bold");
5366
+ ut(s, w, "bold");
5363
5367
  break;
5364
5368
  }
5365
5369
  case "formatItalic": {
5366
- ct(s, w, "italic");
5370
+ ut(s, w, "italic");
5367
5371
  break;
5368
5372
  }
5369
5373
  case "formatUnderline": {
5370
- ct(s, w, "underline");
5374
+ ut(s, w, "underline");
5371
5375
  break;
5372
5376
  }
5373
5377
  case "historyUndo": {
5374
- ct(s, M, void 0);
5378
+ ut(s, M, void 0);
5375
5379
  break;
5376
5380
  }
5377
5381
  case "historyRedo": {
5378
- ct(s, m, void 0);
5382
+ ut(s, m, void 0);
5379
5383
  break;
5380
5384
  }
5381
5385
  }
@@ -5390,7 +5394,7 @@ function AN() {
5390
5394
  if ($ === null)
5391
5395
  return;
5392
5396
  const ae = N.offset;
5393
- (!ee || c.isCollapsed() || !mt(b) || $.anchorNode === null || b.getTextContent().slice(0, ae) + h + b.getTextContent().slice(ae + c.focus.offset) !== yo($.anchorNode)) && ct(s, p, h);
5397
+ (!ee || c.isCollapsed() || !mt(b) || $.anchorNode === null || b.getTextContent().slice(0, ae) + h + b.getTextContent().slice(ae + c.focus.offset) !== yo($.anchorNode)) && ut(s, p, h);
5394
5398
  const he = h.length;
5395
5399
  De && he > 1 && u.inputType === "insertCompositionText" && !s.isComposing() && (c.anchor.offset -= he), !ne && !ue && !Re && s.isComposing() && (Vi = 0, vn(null));
5396
5400
  } else
@@ -5406,9 +5410,9 @@ function AN() {
5406
5410
  vn(h.key), // If it has been 30ms since the last keydown, then we should
5407
5411
  // apply the empty space heuristic. We can't do this for Safari,
5408
5412
  // as the keydown fires after composition start.
5409
- (u.timeStamp < Vi + nr || // FF has issues around composing multibyte characters, so we also
5413
+ (u.timeStamp < Vi + rr || // FF has issues around composing multibyte characters, so we also
5410
5414
  // need to invoke the empty space heuristic below.
5411
- h.type === "element" || !c.isCollapsed() || y.getFormat() !== c.format || mt(y) && y.getStyle() !== c.style) && ct(s, p, Wt);
5415
+ h.type === "element" || !c.isCollapsed() || y.getFormat() !== c.format || mt(y) && y.getStyle() !== c.style) && ut(s, p, Wt);
5412
5416
  }
5413
5417
  });
5414
5418
  }
@@ -5425,7 +5429,7 @@ function AN() {
5425
5429
  const h = mn();
5426
5430
  if (Et(h)) {
5427
5431
  const y = h.focus;
5428
- h.anchor.set(y.key, y.offset, y.type), ct(u, re, null);
5432
+ h.anchor.set(y.key, y.offset, y.type), ut(u, re, null);
5429
5433
  return;
5430
5434
  }
5431
5435
  }
@@ -5447,58 +5451,58 @@ function AN() {
5447
5451
  metaKey: N,
5448
5452
  altKey: b
5449
5453
  } = u;
5450
- if (!ct(s, v, u)) {
5454
+ if (!ut(s, v, u)) {
5451
5455
  if (cs(c, y, b, N))
5452
- ct(s, k, u);
5456
+ ut(s, k, u);
5453
5457
  else if (Aa(c, y, h, b, N))
5454
- ct(s, G, u);
5458
+ ut(s, G, u);
5455
5459
  else if (Lc(c, y, b, N))
5456
- ct(s, I, u);
5460
+ ut(s, I, u);
5457
5461
  else if (Da(c, y, h, b, N))
5458
- ct(s, P, u);
5462
+ ut(s, P, u);
5459
5463
  else if (Ic(c, y, N))
5460
- ct(s, H, u);
5464
+ ut(s, H, u);
5461
5465
  else if (Tl(c, y, N))
5462
- ct(s, V, u);
5466
+ ut(s, V, u);
5463
5467
  else if (Cl(c, h))
5464
- js = !0, ct(s, re, u);
5468
+ js = !0, ut(s, re, u);
5465
5469
  else if (kc(c))
5466
- ct(s, te, u);
5470
+ ut(s, te, u);
5467
5471
  else if (Ps(c, y))
5468
- u.preventDefault(), js = !0, ct(s, d, !0);
5472
+ u.preventDefault(), js = !0, ut(s, d, !0);
5469
5473
  else if (Nl(c, h))
5470
- js = !1, ct(s, re, u);
5474
+ js = !1, ut(s, re, u);
5471
5475
  else if (va(c, b, N, y))
5472
- Xr(c) ? ct(s, ce, u) : (u.preventDefault(), ct(s, l, !0));
5476
+ Xr(c) ? ut(s, ce, u) : (u.preventDefault(), ut(s, l, !0));
5473
5477
  else if ($i(c))
5474
- ct(s, j, u);
5478
+ ut(s, j, u);
5475
5479
  else if (Dc(c, y, h, b, N))
5476
- Fi(c) ? ct(s, z, u) : (u.preventDefault(), ct(s, l, !1));
5480
+ Fi(c) ? ut(s, z, u) : (u.preventDefault(), ut(s, l, !1));
5477
5481
  else if ($s(c, b, y))
5478
- u.preventDefault(), ct(s, E, !0);
5482
+ u.preventDefault(), ut(s, E, !0);
5479
5483
  else if (Ea(c, b, y))
5480
- u.preventDefault(), ct(s, E, !1);
5484
+ u.preventDefault(), ut(s, E, !1);
5481
5485
  else if (Ta(c, N))
5482
- u.preventDefault(), ct(s, S, !0);
5486
+ u.preventDefault(), ut(s, S, !0);
5483
5487
  else if (xa(c, N))
5484
- u.preventDefault(), ct(s, S, !1);
5488
+ u.preventDefault(), ut(s, S, !1);
5485
5489
  else if (Ca(c, b, N, y))
5486
- u.preventDefault(), ct(s, w, "bold");
5490
+ u.preventDefault(), ut(s, w, "bold");
5487
5491
  else if (ks(c, b, N, y))
5488
- u.preventDefault(), ct(s, w, "underline");
5492
+ u.preventDefault(), ut(s, w, "underline");
5489
5493
  else if (as(c, b, N, y))
5490
- u.preventDefault(), ct(s, w, "italic");
5494
+ u.preventDefault(), ut(s, w, "italic");
5491
5495
  else if (Na(c, b, y, N))
5492
- ct(s, q, u);
5496
+ ut(s, q, u);
5493
5497
  else if (Ac(c, h, N, y))
5494
- u.preventDefault(), ct(s, M, void 0);
5498
+ u.preventDefault(), ut(s, M, void 0);
5495
5499
  else if (Sa(c, h, N, y))
5496
- u.preventDefault(), ct(s, m, void 0);
5500
+ u.preventDefault(), ut(s, m, void 0);
5497
5501
  else {
5498
5502
  const $ = s._editorState._selection;
5499
- Ur($) ? Mc(c, h, N, y) ? (u.preventDefault(), ct(s, Y, u)) : Rc(c, h, N, y) ? (u.preventDefault(), ct(s, W, u)) : No(c, N, y) && (u.preventDefault(), ct(s, J, u)) : !De && No(c, N, y) && (u.preventDefault(), ct(s, J, u));
5503
+ Ur($) ? Mc(c, h, N, y) ? (u.preventDefault(), ut(s, Y, u)) : Rc(c, h, N, y) ? (u.preventDefault(), ut(s, W, u)) : No(c, N, y) && (u.preventDefault(), ut(s, J, u)) : !De && No(c, N, y) && (u.preventDefault(), ut(s, J, u));
5500
5504
  }
5501
- Fs(y, h, b, N) && ct(s, A, u);
5505
+ Fs(y, h, b, N) && ut(s, A, u);
5502
5506
  }
5503
5507
  }
5504
5508
  function Ae(u) {
@@ -5542,23 +5546,23 @@ function AN() {
5542
5546
  if (!Pe($) && (Ke($), s.isEditable()))
5543
5547
  switch (y) {
5544
5548
  case "cut":
5545
- return ct(s, W, $);
5549
+ return ut(s, W, $);
5546
5550
  case "copy":
5547
- return ct(s, Y, $);
5551
+ return ut(s, Y, $);
5548
5552
  case "paste":
5549
- return ct(s, _, $);
5553
+ return ut(s, _, $);
5550
5554
  case "dragstart":
5551
- return ct(s, O, $);
5555
+ return ut(s, O, $);
5552
5556
  case "dragover":
5553
- return ct(s, Z, $);
5557
+ return ut(s, Z, $);
5554
5558
  case "dragend":
5555
- return ct(s, oe, $);
5559
+ return ut(s, oe, $);
5556
5560
  case "focus":
5557
- return ct(s, _e, $);
5561
+ return ut(s, _e, $);
5558
5562
  case "blur":
5559
- return ct(s, B, $);
5563
+ return ut(s, B, $);
5560
5564
  case "drop":
5561
- return ct(s, de, $);
5565
+ return ut(s, de, $);
5562
5566
  }
5563
5567
  };
5564
5568
  u.addEventListener(y, b), c.push(() => {
@@ -5936,7 +5940,7 @@ function AN() {
5936
5940
  *
5937
5941
  */
5938
5942
  isDirty() {
5939
- const c = Tn()._dirtyLeaves;
5943
+ const c = xn()._dirtyLeaves;
5940
5944
  return c !== null && c.has(this.__key);
5941
5945
  }
5942
5946
  /**
@@ -5957,7 +5961,7 @@ function AN() {
5957
5961
  */
5958
5962
  getWritable() {
5959
5963
  hr();
5960
- const s = Si(), c = Tn(), h = s._nodeMap, y = this.__key, N = this.getLatest(), b = N.__parent, $ = c._cloneNotNeeded, ae = mn();
5964
+ const s = Si(), c = xn(), h = s._nodeMap, y = this.__key, N = this.getLatest(), b = N.__parent, $ = c._cloneNotNeeded, ae = mn();
5961
5965
  if (dr(ae) && ae.setCachedNodes(null), $.has(y))
5962
5966
  return Li(N), N;
5963
5967
  const me = N.constructor.clone(N);
@@ -6234,7 +6238,7 @@ function AN() {
6234
6238
  }
6235
6239
  }
6236
6240
  function ci(u, s) {
6237
- const c = Tn()._nodes.get(u);
6241
+ const c = xn()._nodes.get(u);
6238
6242
  if (c === void 0)
6239
6243
  throw Error(`Create node: Attempted to create node ${s.name} that was not configured to be used on the editor.`);
6240
6244
  const h = c.klass;
@@ -6513,8 +6517,8 @@ function AN() {
6513
6517
  const Qe = c.firstChild;
6514
6518
  if (Qe == null)
6515
6519
  throw Error("updateDOM: prevInnerDOM is null or undefined");
6516
- const dt = document.createElement(me);
6517
- return Bl(dt, this, me, b, y, h), c.replaceChild(dt, Qe), !1;
6520
+ const ft = document.createElement(me);
6521
+ return Bl(ft, this, me, b, y, h), c.replaceChild(ft, Qe), !1;
6518
6522
  }
6519
6523
  let Ce = c;
6520
6524
  if (ae !== null && $ !== null && (Ce = c.firstChild, Ce == null))
@@ -6800,21 +6804,21 @@ function AN() {
6800
6804
  const je = c.getFormat(), Ue = c.getStyle(), $e = c.__detail;
6801
6805
  let Mt = !1;
6802
6806
  c.isSegmented() ? (Ce = Dn(xe), Ce.__format = je, Ce.__style = Ue, Ce.__detail = $e, Mt = !0) : (Ce = c.getWritable(), Ce.__text = xe);
6803
- const Qe = mn(), dt = [Ce];
6807
+ const Qe = mn(), ft = [Ce];
6804
6808
  let jt = xe.length;
6805
6809
  for (let ln = 1; ln < me; ln++) {
6806
- const ir = $[ln], ys = ir.length, gr = Dn(ir).getWritable();
6810
+ const sr = $[ln], ys = sr.length, gr = Dn(sr).getWritable();
6807
6811
  gr.__format = je, gr.__style = Ue, gr.__detail = $e;
6808
6812
  const nn = gr.__key, kn = jt + ys;
6809
6813
  if (Et(Qe)) {
6810
6814
  const fi = Qe.anchor, Xi = Qe.focus;
6811
6815
  fi.key === y && fi.type === "text" && fi.offset > jt && fi.offset <= kn && (fi.key = nn, fi.offset -= jt, Qe.dirty = !0), Xi.key === y && Xi.type === "text" && Xi.offset > jt && Xi.offset <= kn && (Xi.key = nn, Xi.offset -= jt, Qe.dirty = !0);
6812
6816
  }
6813
- N === y && vn(nn), jt = kn, dt.push(gr);
6817
+ N === y && vn(nn), jt = kn, ft.push(gr);
6814
6818
  }
6815
6819
  hl(this);
6816
6820
  const Ht = we.getWritable(), Ot = this.getIndexWithinParent();
6817
- return Mt ? (Ht.splice(Ot, 0, dt), this.remove()) : Ht.splice(Ot, 1, dt), Et(Qe) && Ya(Qe, we, Ot, me - 1), dt;
6821
+ return Mt ? (Ht.splice(Ot, 0, ft), this.remove()) : Ht.splice(Ot, 1, ft), Et(Qe) && Ya(Qe, we, Ot, me - 1), ft;
6818
6822
  }
6819
6823
  /**
6820
6824
  * Merges the target TextNode into this TextNode, removing the target node.
@@ -7084,7 +7088,7 @@ function AN() {
7084
7088
  const y = u.getNode(), N = y.getChildAtIndex(u.offset), b = Dn(), $ = Yr(y) ? Ji().append(b) : b;
7085
7089
  b.setFormat(c), b.setStyle(h), N === null ? y.append($) : N.insertBefore($), u.is(s) && s.set(b.__key, 0, "text"), u.set(b.__key, 0, "text");
7086
7090
  }
7087
- function En(u, s, c, h) {
7091
+ function Tn(u, s, c, h) {
7088
7092
  u.key = s, u.offset = c, u.type = h;
7089
7093
  }
7090
7094
  class Ir {
@@ -7195,7 +7199,7 @@ function AN() {
7195
7199
  }
7196
7200
  }
7197
7201
  function Et(u) {
7198
- return u instanceof rr;
7202
+ return u instanceof ir;
7199
7203
  }
7200
7204
  function dr(u) {
7201
7205
  return u instanceof Ir;
@@ -7226,7 +7230,7 @@ function AN() {
7226
7230
  }
7227
7231
  return null;
7228
7232
  }
7229
- class rr extends Ir {
7233
+ class ir extends Ir {
7230
7234
  constructor(s, c, h, y) {
7231
7235
  super(s, c), this.format = h, this.style = y;
7232
7236
  }
@@ -7281,7 +7285,7 @@ function AN() {
7281
7285
  * @param focusOffset - the focus offset to set on the Selection
7282
7286
  */
7283
7287
  setTextNodeRange(s, c, h, y) {
7284
- En(this.anchor, s.__key, c, "text"), En(this.focus, h.__key, y, "text"), this._cachedNodes = null, this.dirty = !0;
7288
+ Tn(this.anchor, s.__key, c, "text"), Tn(this.focus, h.__key, y, "text"), this._cachedNodes = null, this.dirty = !0;
7285
7289
  }
7286
7290
  /**
7287
7291
  * Gets the (plain) text content of all the nodes in the selection.
@@ -7313,11 +7317,11 @@ function AN() {
7313
7317
  * @param range a DOM Selection range conforming to the StaticRange interface.
7314
7318
  */
7315
7319
  applyDOMRange(s) {
7316
- const c = Tn(), y = c.getEditorState()._selection, N = Bd(s.startContainer, s.startOffset, s.endContainer, s.endOffset, c, y);
7320
+ const c = xn(), y = c.getEditorState()._selection, N = Bd(s.startContainer, s.startOffset, s.endContainer, s.endOffset, c, y);
7317
7321
  if (N === null)
7318
7322
  return;
7319
7323
  const [b, $] = N;
7320
- En(this.anchor, b.key, b.offset, b.type), En(this.focus, $.key, $.offset, $.type), this._cachedNodes = null;
7324
+ Tn(this.anchor, b.key, b.offset, b.type), Tn(this.focus, $.key, $.offset, $.type), this._cachedNodes = null;
7321
7325
  }
7322
7326
  /**
7323
7327
  * Creates a new RangeSelection, copying over all the property values from this one.
@@ -7326,7 +7330,7 @@ function AN() {
7326
7330
  */
7327
7331
  clone() {
7328
7332
  const s = this.anchor, c = this.focus;
7329
- return new rr(Lr(s.key, s.offset, s.type), Lr(c.key, c.offset, c.type), this.format, this.style);
7333
+ return new ir(Lr(s.key, s.offset, s.type), Lr(c.key, c.offset, c.type), this.format, this.style);
7330
7334
  }
7331
7335
  /**
7332
7336
  * Toggles the provided format on all the TextNodes in the Selection.
@@ -7387,23 +7391,23 @@ function AN() {
7387
7391
  const Ue = Ce.getTextContent().length, $e = Ce.getParentOrThrow(), Mt = ae - 1;
7388
7392
  let Qe = $[Mt];
7389
7393
  if (this.isCollapsed() && xe === Ue && (Ce.isSegmented() || Ce.isToken() || !Ce.canInsertTextAfter() || !$e.canInsertTextAfter() && Ce.getNextSibling() === null)) {
7390
- let dt = Ce.getNextSibling();
7391
- if ((!mt(dt) || !dt.canInsertTextBefore() || zn(dt)) && (dt = Dn(), dt.setFormat(N), $e.canInsertTextAfter() ? Ce.insertAfter(dt) : $e.insertAfter(dt)), dt.select(0, 0), Ce = dt, s !== "") {
7394
+ let ft = Ce.getNextSibling();
7395
+ if ((!mt(ft) || !ft.canInsertTextBefore() || zn(ft)) && (ft = Dn(), ft.setFormat(N), $e.canInsertTextAfter() ? Ce.insertAfter(ft) : $e.insertAfter(ft)), ft.select(0, 0), Ce = ft, s !== "") {
7392
7396
  this.insertText(s);
7393
7397
  return;
7394
7398
  }
7395
7399
  } else if (this.isCollapsed() && xe === 0 && (Ce.isSegmented() || Ce.isToken() || !Ce.canInsertTextBefore() || !$e.canInsertTextBefore() && Ce.getPreviousSibling() === null)) {
7396
- let dt = Ce.getPreviousSibling();
7397
- if ((!mt(dt) || zn(dt)) && (dt = Dn(), dt.setFormat(N), $e.canInsertTextBefore() ? Ce.insertBefore(dt) : $e.insertBefore(dt)), dt.select(), Ce = dt, s !== "") {
7400
+ let ft = Ce.getPreviousSibling();
7401
+ if ((!mt(ft) || zn(ft)) && (ft = Dn(), ft.setFormat(N), $e.canInsertTextBefore() ? Ce.insertBefore(ft) : $e.insertBefore(ft)), ft.select(), Ce = ft, s !== "") {
7398
7402
  this.insertText(s);
7399
7403
  return;
7400
7404
  }
7401
7405
  } else if (Ce.isSegmented() && xe !== Ue) {
7402
- const dt = Dn(Ce.getTextContent());
7403
- dt.setFormat(N), Ce.replace(dt), Ce = dt;
7406
+ const ft = Dn(Ce.getTextContent());
7407
+ ft.setFormat(N), Ce.replace(ft), Ce = ft;
7404
7408
  } else if (!this.isCollapsed() && s !== "") {
7405
- const dt = Qe.getParent();
7406
- if (!$e.canInsertTextBefore() || !$e.canInsertTextAfter() || et(dt) && (!dt.canInsertTextBefore() || !dt.canInsertTextAfter())) {
7409
+ const ft = Qe.getParent();
7410
+ if (!$e.canInsertTextBefore() || !$e.canInsertTextAfter() || et(ft) && (!ft.canInsertTextBefore() || !ft.canInsertTextAfter())) {
7407
7411
  this.insertText(""), Fd(this.anchor, this.focus, null), this.insertText(s);
7408
7412
  return;
7409
7413
  }
@@ -7414,8 +7418,8 @@ function AN() {
7414
7418
  Ot.select(), Ce.replace(Ot);
7415
7419
  return;
7416
7420
  }
7417
- const dt = Ce.getFormat(), jt = Ce.getStyle();
7418
- if (xe === we && (dt !== N || jt !== b))
7421
+ const ft = Ce.getFormat(), jt = Ce.getStyle();
7422
+ if (xe === we && (ft !== N || jt !== b))
7419
7423
  if (Ce.getTextContent() === "")
7420
7424
  Ce.setFormat(N), Ce.setStyle(b);
7421
7425
  else {
@@ -7435,9 +7439,9 @@ function AN() {
7435
7439
  return;
7436
7440
  }
7437
7441
  const Ht = we - xe;
7438
- Ce = Ce.spliceText(xe, Ht, s, !0), Ce.getTextContent() === "" ? Ce.remove() : this.anchor.type === "text" && (Ce.isComposing() ? this.anchor.offset -= s.length : (this.format = dt, this.style = jt));
7442
+ Ce = Ce.spliceText(xe, Ht, s, !0), Ce.getTextContent() === "" ? Ce.remove() : this.anchor.type === "text" && (Ce.isComposing() ? this.anchor.offset -= s.length : (this.format = ft, this.style = jt));
7439
7443
  } else {
7440
- const dt = /* @__PURE__ */ new Set([...Ce.getParentKeys(), ...Qe.getParentKeys()]), jt = et(Ce) ? Ce : Ce.getParentOrThrow();
7444
+ const ft = /* @__PURE__ */ new Set([...Ce.getParentKeys(), ...Qe.getParentKeys()]), jt = et(Ce) ? Ce : Ce.getParentOrThrow();
7441
7445
  let Ht = et(Qe) ? Qe : Qe.getParentOrThrow(), Ot = Qe;
7442
7446
  if (!jt.is(Ht) && Ht.isInline())
7443
7447
  do
@@ -7449,25 +7453,25 @@ function AN() {
7449
7453
  const nn = Dn(Qe.getTextContent());
7450
7454
  Qe.replace(nn), Qe = nn;
7451
7455
  }
7452
- !Yr(me.getNode()) && me.type === "text" && (Qe = Qe.spliceText(0, we, "")), dt.add(Qe.__key);
7456
+ !Yr(me.getNode()) && me.type === "text" && (Qe = Qe.spliceText(0, we, "")), ft.add(Qe.__key);
7453
7457
  } else {
7454
7458
  const nn = Qe.getParentOrThrow();
7455
7459
  !nn.canBeEmpty() && nn.getChildrenSize() === 1 ? nn.remove() : Qe.remove();
7456
7460
  }
7457
7461
  else
7458
- dt.add(Qe.__key);
7459
- const ln = Ht.getChildren(), ir = new Set($), ys = jt.is(Ht), gr = jt.isInline() && Ce.getNextSibling() === null ? jt : Ce;
7462
+ ft.add(Qe.__key);
7463
+ const ln = Ht.getChildren(), sr = new Set($), ys = jt.is(Ht), gr = jt.isInline() && Ce.getNextSibling() === null ? jt : Ce;
7460
7464
  for (let nn = ln.length - 1; nn >= 0; nn--) {
7461
7465
  const kn = ln[nn];
7462
7466
  if (kn.is(Ce) || et(kn) && kn.isParentOf(Ce))
7463
7467
  break;
7464
- kn.isAttached() && (!ir.has(kn) || kn.is(Ot) ? ys || gr.insertAfter(kn, !1) : kn.remove());
7468
+ kn.isAttached() && (!sr.has(kn) || kn.is(Ot) ? ys || gr.insertAfter(kn, !1) : kn.remove());
7465
7469
  }
7466
7470
  if (!ys) {
7467
7471
  let nn = Ht, kn = null;
7468
7472
  for (; nn !== null; ) {
7469
7473
  const fi = nn.getChildren(), Xi = fi.length;
7470
- (Xi === 0 || fi[Xi - 1].is(kn)) && (dt.delete(nn.__key), kn = nn), nn = nn.getParent();
7474
+ (Xi === 0 || fi[Xi - 1].is(kn)) && (ft.delete(nn.__key), kn = nn), nn = nn.getParent();
7471
7475
  }
7472
7476
  }
7473
7477
  if (!Ce.isToken())
@@ -7480,7 +7484,7 @@ function AN() {
7480
7484
  }
7481
7485
  for (let nn = 1; nn < ae; nn++) {
7482
7486
  const kn = $[nn], fi = kn.__key;
7483
- dt.has(fi) || kn.remove();
7487
+ ft.has(fi) || kn.remove();
7484
7488
  }
7485
7489
  }
7486
7490
  }
@@ -7522,8 +7526,8 @@ function AN() {
7522
7526
  if (we === 0 && $e === xe.getTextContentSize())
7523
7527
  xe.setFormat(Ce);
7524
7528
  else {
7525
- const Qe = xe.splitText(we, $e), dt = we === 0 ? Qe[0] : Qe[1];
7526
- dt.setFormat(Ce), ae.type === "text" && ae.set(dt.__key, 0, "text"), he.type === "text" && he.set(dt.__key, $e - we, "text");
7529
+ const Qe = xe.splitText(we, $e), ft = we === 0 ? Qe[0] : Qe[1];
7530
+ ft.setFormat(Ce), ae.type === "text" && ae.set(ft.__key, 0, "text"), he.type === "text" && he.set(ft.__key, $e - we, "text");
7527
7531
  }
7528
7532
  this.format = Ce;
7529
7533
  return;
@@ -7532,10 +7536,10 @@ function AN() {
7532
7536
  const Mt = Ue.getFormatFlags(s, Ce);
7533
7537
  $e > 0 && ($e !== Ue.getTextContentSize() && ([Ue] = Ue.splitText($e)), Ue.setFormat(Mt));
7534
7538
  for (let Qe = me + 1; Qe < je; Qe++) {
7535
- const dt = h[Qe];
7536
- if (!dt.isToken()) {
7537
- const jt = dt.getFormatFlags(s, Mt);
7538
- dt.setFormat(jt);
7539
+ const ft = h[Qe];
7540
+ if (!ft.isToken()) {
7541
+ const jt = ft.getFormatFlags(s, Mt);
7542
+ ft.setFormat(jt);
7539
7543
  }
7540
7544
  }
7541
7545
  ae.type === "text" && ae.set(xe.__key, we, "text"), he.type === "text" && he.set(Ue.__key, $e, "text"), this.format = Ce | Mt;
@@ -7596,7 +7600,7 @@ function AN() {
7596
7600
  insertParagraph() {
7597
7601
  if (this.anchor.key === "root") {
7598
7602
  const b = Ji();
7599
- return tr().splice(this.anchor.offset, 0, [b]), b.select(), b;
7603
+ return nr().splice(this.anchor.offset, 0, [b]), b.select(), b;
7600
7604
  }
7601
7605
  const s = Bc(this), c = wo(this.anchor.getNode(), Ki);
7602
7606
  if (!et(c))
@@ -7674,7 +7678,7 @@ function AN() {
7674
7678
  return;
7675
7679
  }
7676
7680
  }
7677
- const ae = Tn(), he = cr(ae._window);
7681
+ const ae = xn(), he = cr(ae._window);
7678
7682
  if (!he)
7679
7683
  return;
7680
7684
  const me = ae._blockCursorElement, xe = ae._rootElement;
@@ -7684,8 +7688,8 @@ function AN() {
7684
7688
  const Ue = this.getNodes(), $e = [];
7685
7689
  let Mt = !1;
7686
7690
  for (let Qe = 0; Qe < Ue.length; Qe++) {
7687
- const dt = Ue[Qe];
7688
- Wi(dt, je) ? $e.push(dt) : Mt = !0;
7691
+ const ft = Ue[Qe];
7692
+ Wi(ft, je) ? $e.push(ft) : Mt = !0;
7689
7693
  }
7690
7694
  if (Mt && $e.length > 0)
7691
7695
  if (c) {
@@ -7723,7 +7727,7 @@ function AN() {
7723
7727
  const $ = $c();
7724
7728
  $.add(b.__key), Tr($);
7725
7729
  } else
7726
- b.remove(), Tn().dispatchCommand(t, void 0);
7730
+ b.remove(), xn().dispatchCommand(t, void 0);
7727
7731
  return;
7728
7732
  } else if (!s && et(b) && et(N) && N.isEmpty()) {
7729
7733
  N.remove(), b.selectStart();
@@ -7790,7 +7794,7 @@ function AN() {
7790
7794
  }
7791
7795
  function Bo(u) {
7792
7796
  const s = u.focus, c = u.anchor, h = c.key, y = c.offset, N = c.type;
7793
- En(c, s.key, s.offset, s.type), En(s, h, y, N), u._cachedNodes = null;
7797
+ Tn(c, s.key, s.offset, s.type), Tn(s, h, y, N), u._cachedNodes = null;
7794
7798
  }
7795
7799
  function Ga(u, s, c, h) {
7796
7800
  u.modify(s, c, h);
@@ -7877,10 +7881,10 @@ function AN() {
7877
7881
  if (u.type === "text" && s.type === "text") {
7878
7882
  const h = u.isBefore(s), y = u.is(s);
7879
7883
  $d(u, h, y), $d(s, !h, y), y && (s.key = u.key, s.offset = u.offset, s.type = u.type);
7880
- const N = Tn();
7884
+ const N = xn();
7881
7885
  if (N.isComposing() && N._compositionKey !== u.key && Et(c)) {
7882
7886
  const b = c.anchor, $ = c.focus;
7883
- En(u, b.key, b.offset, b.type), En(s, $.key, $.offset, $.type);
7887
+ Tn(u, b.key, b.offset, b.type), Tn(s, $.key, $.offset, $.type);
7884
7888
  }
7885
7889
  }
7886
7890
  }
@@ -7904,12 +7908,12 @@ function AN() {
7904
7908
  return et(u) && !u.isInline();
7905
7909
  }
7906
7910
  function Hd(u, s, c, h, y, N) {
7907
- const b = Si(), $ = new rr(Lr(u, s, y), Lr(c, h, N), 0, "");
7911
+ const b = Si(), $ = new ir(Lr(u, s, y), Lr(c, h, N), 0, "");
7908
7912
  return $.dirty = !0, b._selection = $, $;
7909
7913
  }
7910
7914
  function h_() {
7911
7915
  const u = Lr("root", 0, "element"), s = Lr("root", 0, "element");
7912
- return new rr(u, s, 0, "");
7916
+ return new ir(u, s, 0, "");
7913
7917
  }
7914
7918
  function $c() {
7915
7919
  return new vi(/* @__PURE__ */ new Set());
@@ -7935,13 +7939,13 @@ function AN() {
7935
7939
  if (Ce === null)
7936
7940
  return null;
7937
7941
  const [je, Ue] = Ce;
7938
- return new rr(je, Ue, Et(u) ? u.format : 0, Et(u) ? u.style : "");
7942
+ return new ir(je, Ue, Et(u) ? u.format : 0, Et(u) ? u.style : "");
7939
7943
  }
7940
7944
  function mn() {
7941
7945
  return Si()._selection;
7942
7946
  }
7943
7947
  function Ho() {
7944
- return Tn()._editorState._selection;
7948
+ return xn()._editorState._selection;
7945
7949
  }
7946
7950
  function Ya(u, s, c, h = 1) {
7947
7951
  const y = u.anchor, N = u.focus, b = y.getNode(), $ = N.getNode();
@@ -8020,23 +8024,23 @@ function AN() {
8020
8024
  u !== null && ls(c, $, ae) && h.removeAllRanges();
8021
8025
  return;
8022
8026
  }
8023
- const we = s.anchor, Ce = s.focus, je = we.key, Ue = Ce.key, $e = Bs(c, je), Mt = Bs(c, Ue), Qe = we.offset, dt = Ce.offset, jt = s.format, Ht = s.style, Ot = s.isCollapsed();
8024
- let ln = $e, ir = Mt, ys = !1;
8027
+ const we = s.anchor, Ce = s.focus, je = we.key, Ue = Ce.key, $e = Bs(c, je), Mt = Bs(c, Ue), Qe = we.offset, ft = Ce.offset, jt = s.format, Ht = s.style, Ot = s.isCollapsed();
8028
+ let ln = $e, sr = Mt, ys = !1;
8025
8029
  if (we.type === "text") {
8026
8030
  ln = Fr($e);
8027
8031
  const gr = we.getNode();
8028
8032
  ys = gr.getFormat() !== jt || gr.getStyle() !== Ht;
8029
8033
  } else Et(u) && u.anchor.type === "text" && (ys = !0);
8030
- if (Ce.type === "text" && (ir = Fr(Mt)), !(ln === null || ir === null) && (Ot && (u === null || ys || Et(u) && (u.format !== jt || u.style !== Ht)) && Yn(jt, Ht, Qe, je, performance.now()), !(he === Qe && me === dt && $ === ln && ae === ir && // Badly interpreted range selection when collapsed - #1482
8034
+ if (Ce.type === "text" && (sr = Fr(Mt)), !(ln === null || sr === null) && (Ot && (u === null || ys || Et(u) && (u.format !== jt || u.style !== Ht)) && Yn(jt, Ht, Qe, je, performance.now()), !(he === Qe && me === ft && $ === ln && ae === sr && // Badly interpreted range selection when collapsed - #1482
8031
8035
  !(h.type === "Range" && Ot) && ((xe === null || !N.contains(xe)) && N.focus({
8032
8036
  preventScroll: !0
8033
8037
  }), we.type !== "element")))) {
8034
8038
  try {
8035
- h.setBaseAndExtent(ln, Qe, ir, dt);
8039
+ h.setBaseAndExtent(ln, Qe, sr, ft);
8036
8040
  } catch {
8037
8041
  }
8038
8042
  if (!y.has("skip-scroll-into-view") && s.isCollapsed() && N !== null && N === document.activeElement) {
8039
- const gr = s instanceof rr && s.anchor.type === "element" ? ln.childNodes[Qe] || null : h.rangeCount > 0 ? h.getRangeAt(0) : null;
8043
+ const gr = s instanceof ir && s.anchor.type === "element" ? ln.childNodes[Qe] || null : h.rangeCount > 0 ? h.getRangeAt(0) : null;
8040
8044
  if (gr !== null) {
8041
8045
  let nn;
8042
8046
  if (gr instanceof Text) {
@@ -8052,7 +8056,7 @@ function AN() {
8052
8056
  }
8053
8057
  function __(u) {
8054
8058
  let s = mn() || Ho();
8055
- s === null && (s = tr().selectEnd()), s.insertNodes(u);
8059
+ s === null && (s = nr().selectEnd()), s.insertNodes(u);
8056
8060
  }
8057
8061
  function y_() {
8058
8062
  const u = mn();
@@ -8133,7 +8137,7 @@ function AN() {
8133
8137
  const c = u.getParent();
8134
8138
  if (!c) {
8135
8139
  const y = Ji();
8136
- return tr().append(y), y.select(), [tr(), 0];
8140
+ return nr().append(y), y.select(), [nr(), 0];
8137
8141
  }
8138
8142
  if (mt(u)) {
8139
8143
  const y = u.splitText(s);
@@ -8146,7 +8150,7 @@ function AN() {
8146
8150
  return [c, u.getIndexWithinParent()];
8147
8151
  const h = u.getChildAtIndex(s);
8148
8152
  if (h) {
8149
- const y = new rr(Lr(u.__key, s, "element"), Lr(u.__key, s, "element"), 0, ""), N = u.insertNewAfter(y);
8153
+ const y = new ir(Lr(u.__key, s, "element"), Lr(u.__key, s, "element"), 0, ""), N = u.insertNewAfter(y);
8150
8154
  N && N.append(h, ...h.getNextSiblings());
8151
8155
  }
8152
8156
  return [c, u.getIndexWithinParent() + 1];
@@ -8187,7 +8191,7 @@ function AN() {
8187
8191
  throw Error("Unable to find an active editor state. State helpers or node methods can only be used synchronously during the callback of editor.update() or editorState.read().");
8188
8192
  return Qn;
8189
8193
  }
8190
- function Tn() {
8194
+ function xn() {
8191
8195
  if (er === null)
8192
8196
  throw Error("Unable to find an active editor. This method can only be used synchronously during the callback of editor.update().");
8193
8197
  return er;
@@ -8242,7 +8246,7 @@ function AN() {
8242
8246
  s._dirtyLeaves = c, s._dirtyElements = h;
8243
8247
  }
8244
8248
  function S_(u) {
8245
- return Wc(u, Tn()._nodes);
8249
+ return Wc(u, xn()._nodes);
8246
8250
  }
8247
8251
  function Wc(u, s) {
8248
8252
  const c = u.type, h = s.get(c);
@@ -8300,11 +8304,11 @@ function AN() {
8300
8304
  if (u._pendingEditorState = null, u._editorState = c, !y && ae && Ce !== null) {
8301
8305
  er = u, Qn = c, Pr = !1, u._updating = !0;
8302
8306
  try {
8303
- const Ot = u._dirtyType, ln = u._dirtyElements, ir = u._dirtyLeaves;
8304
- Ce.disconnect(), je = Yi(N, c, u, Ot, ln, ir);
8307
+ const Ot = u._dirtyType, ln = u._dirtyElements, sr = u._dirtyLeaves;
8308
+ Ce.disconnect(), je = Yi(N, c, u, Ot, ln, sr);
8305
8309
  } catch (Ot) {
8306
8310
  if (Ot instanceof Error && u._onError(Ot), !Hc)
8307
- tf(u, null, h, c), or(u), u._dirtyType = at, Hc = !0, Xs(u, N), Hc = !1;
8311
+ tf(u, null, h, c), or(u), u._dirtyType = ct, Hc = !0, Xs(u, N), Hc = !1;
8308
8312
  else
8309
8313
  throw Ot;
8310
8314
  return;
@@ -8313,7 +8317,7 @@ function AN() {
8313
8317
  }
8314
8318
  }
8315
8319
  c._readOnly || (c._readOnly = !0, qd(c), Et($) && (Object.freeze($.anchor), Object.freeze($.focus)), Object.freeze($));
8316
- const Ue = u._dirtyLeaves, $e = u._dirtyElements, Mt = u._normalizedNodes, Qe = u._updateTags, dt = u._deferred;
8320
+ const Ue = u._dirtyLeaves, $e = u._dirtyElements, Mt = u._normalizedNodes, Qe = u._updateTags, ft = u._deferred;
8317
8321
  ae && (u._dirtyType = qe, u._cloneNotNeeded.clear(), u._dirtyLeaves = /* @__PURE__ */ new Set(), u._dirtyElements = /* @__PURE__ */ new Map(), u._normalizedNodes = /* @__PURE__ */ new Set(), u._updateTags = /* @__PURE__ */ new Set()), ka(u, c);
8318
8322
  const jt = y ? null : cr(u._window);
8319
8323
  if (u._editable && // domSelection will be null in headless
@@ -8338,7 +8342,7 @@ function AN() {
8338
8342
  normalizedNodes: Mt,
8339
8343
  prevEditorState: s || N,
8340
8344
  tags: Qe
8341
- }), M_(u, dt), A_(u);
8345
+ }), M_(u, ft), A_(u);
8342
8346
  }
8343
8347
  function O_(u, s, c) {
8344
8348
  const h = _o(s), y = _o(c);
@@ -8441,12 +8445,12 @@ function AN() {
8441
8445
  $e !== Mt && (he._flushSync = !0);
8442
8446
  const Qe = he._selection;
8443
8447
  if (Et(Qe)) {
8444
- const dt = he._nodeMap, jt = Qe.anchor.key, Ht = Qe.focus.key;
8445
- if (dt.get(jt) === void 0 || dt.get(Ht) === void 0)
8448
+ const ft = he._nodeMap, jt = Qe.anchor.key, Ht = Qe.focus.key;
8449
+ if (ft.get(jt) === void 0 || ft.get(Ht) === void 0)
8446
8450
  throw Error("updateEditor: selection has been lost because the previously selected nodes have been removed and selection wasn't moved to another node. Ensure selection changes after removing/replacing a selected node.");
8447
8451
  } else Ur(Qe) && Qe._nodes.size === 0 && (he._selection = null);
8448
8452
  } catch ($e) {
8449
- $e instanceof Error && u._onError($e), u._pendingEditorState = ae, u._dirtyType = at, u._cloneNotNeeded.clear(), u._dirtyLeaves = /* @__PURE__ */ new Set(), u._dirtyElements.clear(), Xs(u);
8453
+ $e instanceof Error && u._onError($e), u._pendingEditorState = ae, u._dirtyType = ct, u._cloneNotNeeded.clear(), u._dirtyLeaves = /* @__PURE__ */ new Set(), u._dirtyElements.clear(), Xs(u);
8450
8454
  return;
8451
8455
  } finally {
8452
8456
  Qn = xe, Pr = we, er = Ce, u._updating = je, ja = 0;
@@ -8522,7 +8526,7 @@ function AN() {
8522
8526
  return this.getChildrenSize() === 0;
8523
8527
  }
8524
8528
  isDirty() {
8525
- const c = Tn()._dirtyElements;
8529
+ const c = xn()._dirtyElements;
8526
8530
  return c !== null && c.has(this.__key);
8527
8531
  }
8528
8532
  isLastChild() {
@@ -8851,7 +8855,7 @@ function AN() {
8851
8855
  }
8852
8856
  getTextContent() {
8853
8857
  const s = this.__cachedText;
8854
- return (Wo() || Tn()._dirtyType === qe) && s !== null ? s : super.getTextContent();
8858
+ return (Wo() || xn()._dirtyType === qe) && s !== null ? s : super.getTextContent();
8855
8859
  }
8856
8860
  remove() {
8857
8861
  throw Error("remove: cannot be called on root nodes");
@@ -8879,7 +8883,7 @@ function AN() {
8879
8883
  return super.append(...s);
8880
8884
  }
8881
8885
  static importJSON(s) {
8882
- const c = tr();
8886
+ const c = nr();
8883
8887
  return c.setFormat(s.format), c.setIndent(s.indent), c.setDirection(s.direction), c;
8884
8888
  }
8885
8889
  exportJSON() {
@@ -8949,7 +8953,7 @@ function AN() {
8949
8953
  }
8950
8954
  toJSON() {
8951
8955
  return jd(this, () => ({
8952
- root: ef(tr())
8956
+ root: ef(nr())
8953
8957
  }));
8954
8958
  }
8955
8959
  }
@@ -9080,15 +9084,15 @@ function AN() {
9080
9084
  const Ot = $e.name;
9081
9085
  if (Ot !== "RootNode") {
9082
9086
  const ln = $e.prototype;
9083
- ["getType", "clone"].forEach((ir) => {
9084
- $e.hasOwnProperty(ir) || console.warn(`${Ot} must implement static "${ir}" method`);
9087
+ ["getType", "clone"].forEach((sr) => {
9088
+ $e.hasOwnProperty(sr) || console.warn(`${Ot} must implement static "${sr}" method`);
9085
9089
  }), // eslint-disable-next-line no-prototype-builtins
9086
9090
  !$e.hasOwnProperty("importDOM") && // eslint-disable-next-line no-prototype-builtins
9087
9091
  $e.hasOwnProperty("exportDOM") && console.warn(`${Ot} should implement "importDOM" if using a custom "exportDOM" method to ensure HTML serialization (important for copy & paste) works as expected`), ln instanceof Kc && (ln.hasOwnProperty("decorate") || console.warn(`${ln.constructor.name} must implement "decorate" method`)), $e.hasOwnProperty("importJSON") || console.warn(`${Ot} should implement "importJSON" method to ensure JSON and default HTML serialization works as expected`), ln.hasOwnProperty("exportJSON") || console.warn(`${Ot} should implement "exportJSON" method to ensure JSON and default HTML serialization works as expected`);
9088
9092
  }
9089
9093
  }
9090
- const dt = $e.getType(), jt = $e.transform(), Ht = /* @__PURE__ */ new Set();
9091
- jt !== null && Ht.add(jt), Ce.set(dt, {
9094
+ const ft = $e.getType(), jt = $e.transform(), Ht = /* @__PURE__ */ new Set();
9095
+ jt !== null && Ht.add(jt), Ce.set(ft, {
9092
9096
  exportDOM: xe && xe.export ? xe.export.get($e) : void 0,
9093
9097
  klass: $e,
9094
9098
  replace: Mt,
@@ -9102,7 +9106,7 @@ function AN() {
9102
9106
  namespace: $,
9103
9107
  theme: h
9104
9108
  }, me || console.error, W_(Ce, xe ? xe.import : void 0), we);
9105
- return ae !== void 0 && (je._pendingEditorState = ae, je._dirtyType = at), je;
9109
+ return ae !== void 0 && (je._pendingEditorState = ae, je._dirtyType = ct), je;
9106
9110
  }
9107
9111
  class z_ {
9108
9112
  /** @internal */
@@ -9323,7 +9327,7 @@ function AN() {
9323
9327
  * @param payload - the data to pass as an argument to the command listeners.
9324
9328
  */
9325
9329
  dispatchCommand(s, c) {
9326
- return ct(this, s, c);
9330
+ return ut(this, s, c);
9327
9331
  }
9328
9332
  /**
9329
9333
  * Gets a map of all decorators in the editor.
@@ -9358,7 +9362,7 @@ function AN() {
9358
9362
  const h = Bi(this._config.theme, "root"), y = this._pendingEditorState || this._editorState;
9359
9363
  if (this._rootElement = s, tf(this, c, s, y), c !== null && (this._config.disableEvents || St(c), h != null && c.classList.remove(...h)), s !== null) {
9360
9364
  const N = ba(s), b = s.style;
9361
- b.userSelect = "text", b.whiteSpace = "pre-wrap", b.wordBreak = "break-word", s.setAttribute("data-lexical-editor", "true"), this._window = N, this._dirtyType = at, or(this), this._updateTags.add("history-merge"), Xs(this), this._config.disableEvents || gt(s, this), h != null && s.classList.add(...h);
9365
+ b.userSelect = "text", b.whiteSpace = "pre-wrap", b.wordBreak = "break-word", s.setAttribute("data-lexical-editor", "true"), this._window = N, this._dirtyType = ct, or(this), this._updateTags.add("history-merge"), Xs(this), this._config.disableEvents || gt(s, this), h != null && s.classList.add(...h);
9362
9366
  } else
9363
9367
  this._editorState = y, this._pendingEditorState = null, this._window = null;
9364
9368
  zl("root", this, !1, s, c);
@@ -9389,7 +9393,7 @@ function AN() {
9389
9393
  throw Error("setEditorState: the editor state is empty. Ensure the editor state's root node never becomes empty.");
9390
9394
  un(this);
9391
9395
  const h = this._pendingEditorState, y = this._updateTags, N = c !== void 0 ? c.tag : null;
9392
- h !== null && !h.isEmpty() && (N != null && y.add(N), Xs(this)), this._pendingEditorState = s, this._dirtyType = at, this._dirtyElements.set("root", !1), this._compositionKey = null, N != null && y.add(N), Xs(this);
9396
+ h !== null && !h.isEmpty() && (N != null && y.add(N), Xs(this)), this._pendingEditorState = s, this._dirtyType = ct, this._dirtyElements.set("root", !1), this._compositionKey = null, N != null && y.add(N), Xs(this);
9393
9397
  }
9394
9398
  /**
9395
9399
  * Parses a SerializedEditorState (usually produced by {@link EditorState.toJSON}) and returns
@@ -9430,7 +9434,7 @@ function AN() {
9430
9434
  focus(s, c = {}) {
9431
9435
  const h = this._rootElement;
9432
9436
  h !== null && (h.setAttribute("autocapitalize", "off"), Gr(this, () => {
9433
- const y = mn(), N = tr();
9437
+ const y = mn(), N = nr();
9434
9438
  y !== null ? y.dirty = !0 : N.getChildrenSize() !== 0 && (c.defaultSelection === "rootStart" ? N.selectStart() : N.selectEnd());
9435
9439
  }, {
9436
9440
  onUpdate: () => {
@@ -9516,7 +9520,7 @@ function AN() {
9516
9520
  function Gc(u) {
9517
9521
  return u instanceof sf;
9518
9522
  }
9519
- return He.$INTERNAL_isPointSelection = dr, He.$addUpdateTag = Nt, He.$applyNodeReplacement = Mr, He.$copyNode = wl, He.$createLineBreakNode = _s, He.$createNodeSelection = $c, He.$createParagraphNode = Ji, He.$createPoint = Lr, He.$createRangeSelection = h_, He.$createTabNode = Po, He.$createTextNode = Dn, He.$getAdjacentNode = vl, He.$getNearestNodeFromDOMNode = oi, He.$getNearestRootOrShadowRoot = xo, He.$getNodeByKey = Nn, He.$getPreviousSelection = Ho, He.$getRoot = tr, He.$getSelection = mn, He.$getTextContent = y_, He.$hasAncestor = Wi, He.$hasUpdateTag = Un, He.$insertNodes = __, He.$isBlockElementNode = f_, He.$isDecoratorNode = An, He.$isElementNode = et, He.$isInlineElementOrDecoratorNode = Hr, He.$isLeafNode = Ms, He.$isLineBreakNode = ui, He.$isNodeSelection = Ur, He.$isParagraphNode = k_, He.$isRangeSelection = Et, He.$isRootNode = Yr, He.$isRootOrShadowRoot = li, He.$isTabNode = $o, He.$isTextNode = mt, He.$nodesOfType = Hi, He.$normalizeSelection__EXPERIMENTAL = Ds, He.$parseSerializedNode = S_, He.$selectAll = xl, He.$setCompositionKey = vn, He.$setSelection = Tr, He.$splitNode = La, He.BLUR_COMMAND = B, He.CAN_REDO_COMMAND = X, He.CAN_UNDO_COMMAND = fe, He.CLEAR_EDITOR_COMMAND = R, He.CLEAR_HISTORY_COMMAND = U, He.CLICK_COMMAND = r, He.COMMAND_PRIORITY_CRITICAL = H_, He.COMMAND_PRIORITY_EDITOR = P_, He.COMMAND_PRIORITY_HIGH = B_, He.COMMAND_PRIORITY_LOW = $_, He.COMMAND_PRIORITY_NORMAL = F_, He.CONTROLLED_TEXT_INSERTION_COMMAND = p, He.COPY_COMMAND = Y, He.CUT_COMMAND = W, He.DELETE_CHARACTER_COMMAND = l, He.DELETE_LINE_COMMAND = S, He.DELETE_WORD_COMMAND = E, He.DEPRECATED_$computeGridMap = N_, He.DEPRECATED_$getGridCellNodeRect = kr, He.DEPRECATED_$getNodeTriplet = zd, He.DEPRECATED_$isGridCellNode = Uo, He.DEPRECATED_$isGridNode = rf, He.DEPRECATED_$isGridRowNode = Gc, He.DEPRECATED_GridCellNode = Uc, He.DEPRECATED_GridNode = nf, He.DEPRECATED_GridRowNode = sf, He.DRAGEND_COMMAND = oe, He.DRAGOVER_COMMAND = Z, He.DRAGSTART_COMMAND = O, He.DROP_COMMAND = de, He.DecoratorNode = Kc, He.ElementNode = Qs, He.FOCUS_COMMAND = _e, He.FORMAT_ELEMENT_COMMAND = K, He.FORMAT_TEXT_COMMAND = w, He.INDENT_CONTENT_COMMAND = Se, He.INSERT_LINE_BREAK_COMMAND = d, He.INSERT_PARAGRAPH_COMMAND = f, He.INSERT_TAB_COMMAND = Te, He.INTERNAL_PointSelection = Ir, He.KEY_ARROW_DOWN_COMMAND = V, He.KEY_ARROW_LEFT_COMMAND = I, He.KEY_ARROW_RIGHT_COMMAND = k, He.KEY_ARROW_UP_COMMAND = H, He.KEY_BACKSPACE_COMMAND = ce, He.KEY_DELETE_COMMAND = z, He.KEY_DOWN_COMMAND = v, He.KEY_ENTER_COMMAND = re, He.KEY_ESCAPE_COMMAND = j, He.KEY_MODIFIER_COMMAND = A, He.KEY_SPACE_COMMAND = te, He.KEY_TAB_COMMAND = q, He.LineBreakNode = qi, He.MOVE_TO_END = G, He.MOVE_TO_START = P, He.OUTDENT_CONTENT_COMMAND = Ee, He.PASTE_COMMAND = _, He.ParagraphNode = zo, He.REDO_COMMAND = m, He.REMOVE_TEXT_COMMAND = T, He.RootNode = Ko, He.SELECTION_CHANGE_COMMAND = t, He.SELECTION_INSERT_CLIPBOARD_NODES_COMMAND = n, He.SELECT_ALL_COMMAND = J, He.TabNode = Sr, He.TextNode = Qr, He.UNDO_COMMAND = M, He.createCommand = e, He.createEditor = K_, He.getNearestEditorFromDOMNode = ul, He.isCurrentlyReadOnlyMode = Wo, He.isHTMLAnchorElement = Ia, He.isHTMLElement = Ks, He.isSelectionCapturedInDecoratorInput = As, He.isSelectionWithinEditor = ls, He;
9523
+ return He.$INTERNAL_isPointSelection = dr, He.$addUpdateTag = Nt, He.$applyNodeReplacement = Mr, He.$copyNode = wl, He.$createLineBreakNode = _s, He.$createNodeSelection = $c, He.$createParagraphNode = Ji, He.$createPoint = Lr, He.$createRangeSelection = h_, He.$createTabNode = Po, He.$createTextNode = Dn, He.$getAdjacentNode = vl, He.$getNearestNodeFromDOMNode = oi, He.$getNearestRootOrShadowRoot = xo, He.$getNodeByKey = Nn, He.$getPreviousSelection = Ho, He.$getRoot = nr, He.$getSelection = mn, He.$getTextContent = y_, He.$hasAncestor = Wi, He.$hasUpdateTag = Un, He.$insertNodes = __, He.$isBlockElementNode = f_, He.$isDecoratorNode = An, He.$isElementNode = et, He.$isInlineElementOrDecoratorNode = Hr, He.$isLeafNode = Ms, He.$isLineBreakNode = ui, He.$isNodeSelection = Ur, He.$isParagraphNode = k_, He.$isRangeSelection = Et, He.$isRootNode = Yr, He.$isRootOrShadowRoot = li, He.$isTabNode = $o, He.$isTextNode = mt, He.$nodesOfType = Hi, He.$normalizeSelection__EXPERIMENTAL = Ds, He.$parseSerializedNode = S_, He.$selectAll = xl, He.$setCompositionKey = vn, He.$setSelection = Tr, He.$splitNode = La, He.BLUR_COMMAND = B, He.CAN_REDO_COMMAND = X, He.CAN_UNDO_COMMAND = fe, He.CLEAR_EDITOR_COMMAND = R, He.CLEAR_HISTORY_COMMAND = U, He.CLICK_COMMAND = r, He.COMMAND_PRIORITY_CRITICAL = H_, He.COMMAND_PRIORITY_EDITOR = P_, He.COMMAND_PRIORITY_HIGH = B_, He.COMMAND_PRIORITY_LOW = $_, He.COMMAND_PRIORITY_NORMAL = F_, He.CONTROLLED_TEXT_INSERTION_COMMAND = p, He.COPY_COMMAND = Y, He.CUT_COMMAND = W, He.DELETE_CHARACTER_COMMAND = l, He.DELETE_LINE_COMMAND = S, He.DELETE_WORD_COMMAND = E, He.DEPRECATED_$computeGridMap = N_, He.DEPRECATED_$getGridCellNodeRect = kr, He.DEPRECATED_$getNodeTriplet = zd, He.DEPRECATED_$isGridCellNode = Uo, He.DEPRECATED_$isGridNode = rf, He.DEPRECATED_$isGridRowNode = Gc, He.DEPRECATED_GridCellNode = Uc, He.DEPRECATED_GridNode = nf, He.DEPRECATED_GridRowNode = sf, He.DRAGEND_COMMAND = oe, He.DRAGOVER_COMMAND = Z, He.DRAGSTART_COMMAND = O, He.DROP_COMMAND = de, He.DecoratorNode = Kc, He.ElementNode = Qs, He.FOCUS_COMMAND = _e, He.FORMAT_ELEMENT_COMMAND = K, He.FORMAT_TEXT_COMMAND = w, He.INDENT_CONTENT_COMMAND = Se, He.INSERT_LINE_BREAK_COMMAND = d, He.INSERT_PARAGRAPH_COMMAND = f, He.INSERT_TAB_COMMAND = Te, He.INTERNAL_PointSelection = Ir, He.KEY_ARROW_DOWN_COMMAND = V, He.KEY_ARROW_LEFT_COMMAND = I, He.KEY_ARROW_RIGHT_COMMAND = k, He.KEY_ARROW_UP_COMMAND = H, He.KEY_BACKSPACE_COMMAND = ce, He.KEY_DELETE_COMMAND = z, He.KEY_DOWN_COMMAND = v, He.KEY_ENTER_COMMAND = re, He.KEY_ESCAPE_COMMAND = j, He.KEY_MODIFIER_COMMAND = A, He.KEY_SPACE_COMMAND = te, He.KEY_TAB_COMMAND = q, He.LineBreakNode = qi, He.MOVE_TO_END = G, He.MOVE_TO_START = P, He.OUTDENT_CONTENT_COMMAND = Ee, He.PASTE_COMMAND = _, He.ParagraphNode = zo, He.REDO_COMMAND = m, He.REMOVE_TEXT_COMMAND = T, He.RootNode = Ko, He.SELECTION_CHANGE_COMMAND = t, He.SELECTION_INSERT_CLIPBOARD_NODES_COMMAND = n, He.SELECT_ALL_COMMAND = J, He.TabNode = Sr, He.TextNode = Qr, He.UNDO_COMMAND = M, He.createCommand = e, He.createEditor = K_, He.getNearestEditorFromDOMNode = ul, He.isCurrentlyReadOnlyMode = Wo, He.isHTMLAnchorElement = Ia, He.isHTMLElement = Ks, He.isSelectionCapturedInDecoratorInput = As, He.isSelectionWithinEditor = ls, He;
9520
9524
  }
9521
9525
  var We = {}, Of;
9522
9526
  function MN() {
@@ -9533,7 +9537,7 @@ function MN() {
9533
9537
  function Be(o) {
9534
9538
  qe = o.timeStamp;
9535
9539
  }
9536
- function at(o, i, a) {
9540
+ function ct(o, i, a) {
9537
9541
  return i.__lexicalLineBreak === o || o[`__lexicalKey_${a._key}`] !== void 0;
9538
9542
  }
9539
9543
  function Dt(o) {
@@ -9552,7 +9556,7 @@ function MN() {
9552
9556
  let Ae = !1, Ye = "";
9553
9557
  for (var Xe = 0; Xe < i.length; Xe++) {
9554
9558
  var Ke = i[Xe], Pe = Ke.type, gt = Ke.target, St = Wt(gt, Q);
9555
- if (!(St === null && gt !== D || Cn(St))) {
9559
+ if (!(St === null && gt !== D || En(St))) {
9556
9560
  if (Pe === "characterData") {
9557
9561
  if (Ke = g && Nt(St)) e: {
9558
9562
  Ke = C, Pe = gt;
@@ -9571,10 +9575,10 @@ function MN() {
9571
9575
  for (Ae = !0, Pe = Ke.addedNodes, $t = 0; $t < Pe.length; $t++) {
9572
9576
  Kt = Pe[$t];
9573
9577
  var Yn = Pt(Kt), Rr = Kt.parentNode;
9574
- Rr == null || Kt === ge || Yn !== null || Kt.nodeName === "BR" && at(Kt, Rr, o) || (U && (Yn = Kt.innerText || Kt.nodeValue) && (Ye += Yn), Rr.removeChild(Kt));
9578
+ Rr == null || Kt === ge || Yn !== null || Kt.nodeName === "BR" && ct(Kt, Rr, o) || (U && (Yn = Kt.innerText || Kt.nodeValue) && (Ye += Yn), Rr.removeChild(Kt));
9575
9579
  }
9576
9580
  if (Ke = Ke.removedNodes, Pe = Ke.length, 0 < Pe) {
9577
- for ($t = 0, Kt = 0; Kt < Pe; Kt++) Rr = Ke[Kt], (Rr.nodeName === "BR" && at(Rr, gt, o) || ge === Rr) && (gt.appendChild(Rr), $t++);
9581
+ for ($t = 0, Kt = 0; Kt < Pe; Kt++) Rr = Ke[Kt], (Rr.nodeName === "BR" && ct(Rr, gt, o) || ge === Rr) && (gt.appendChild(Rr), $t++);
9578
9582
  Pe !== $t && (gt === D && (St = Q._nodeMap.get("root")), x.set(gt, St));
9579
9583
  }
9580
9584
  }
@@ -9586,7 +9590,7 @@ function MN() {
9586
9590
  ] of x) if (Je(ci)) for (x = ci.getChildrenKeys(), D = ai.firstChild, Q = 0; Q < x.length; Q++) ge = o.getElementByKey(x[Q]), ge !== null && (D == null ? (ai.appendChild(ge), D = ge) : D !== ge && ai.replaceChild(ge, D), D = D.nextSibling);
9587
9591
  else Nt(ci) && ci.markDirty();
9588
9592
  if (x = a.takeRecords(), 0 < x.length) {
9589
- for (D = 0; D < x.length; D++) for (ge = x[D], Q = ge.addedNodes, ge = ge.target, Xe = 0; Xe < Q.length; Xe++) St = Q[Xe], gt = St.parentNode, gt == null || St.nodeName !== "BR" || at(St, ge, o) || gt.removeChild(St);
9593
+ for (D = 0; D < x.length; D++) for (ge = x[D], Q = ge.addedNodes, ge = ge.target, Xe = 0; Xe < Q.length; Xe++) St = Q[Xe], gt = St.parentNode, gt == null || St.nodeName !== "BR" || ct(St, ge, o) || gt.removeChild(St);
9590
9594
  a.takeRecords();
9591
9595
  }
9592
9596
  C !== null && (Ae && (C.dirty = !0, tn(C)), U && rn(o) && C.insertRawText(Ye));
@@ -9652,7 +9656,7 @@ function MN() {
9652
9656
  let i = document.activeElement;
9653
9657
  if (i === null) return !1;
9654
9658
  let a = i.nodeName;
9655
- return Cn(Wt(o)) && (a === "INPUT" || a === "TEXTAREA" || i.contentEditable === "true" && i.__lexicalEditor == null);
9659
+ return En(Wt(o)) && (a === "INPUT" || a === "TEXTAREA" || i.contentEditable === "true" && i.__lexicalEditor == null);
9656
9660
  }
9657
9661
  function it(o, i, a) {
9658
9662
  let g = o.getRootElement();
@@ -9858,7 +9862,7 @@ function MN() {
9858
9862
  return o = (o = un(o).event) && o.inputType, o === "insertFromPaste" || o === "insertFromPasteAsQuotation";
9859
9863
  }
9860
9864
  function on(o) {
9861
- return !nr(o) && !o.isLastChild() && !o.isInline();
9865
+ return !rr(o) && !o.isLastChild() && !o.isInline();
9862
9866
  }
9863
9867
  function bn(o, i) {
9864
9868
  return o = o._keyToDOMMap.get(i), o === void 0 && Y(75, i), o;
@@ -9881,7 +9885,7 @@ function MN() {
9881
9885
  return o;
9882
9886
  }
9883
9887
  function lr(o) {
9884
- return nr(o) || Je(o) && o.isShadowRoot();
9888
+ return rr(o) || Je(o) && o.isShadowRoot();
9885
9889
  }
9886
9890
  function bi(o) {
9887
9891
  return o = o.constructor.clone(o), _t(o, null), o;
@@ -9892,10 +9896,10 @@ function MN() {
9892
9896
  return i = i._nodes.get(a), i === void 0 && Y(97), i = i.replace, i !== null ? (i = i(o), i instanceof o.constructor || Y(98), i) : o;
9893
9897
  }
9894
9898
  function Ds(o, i) {
9895
- o = o.getParent(), !nr(o) || Je(i) || Cn(i) || Y(99);
9899
+ o = o.getParent(), !rr(o) || Je(i) || En(i) || Y(99);
9896
9900
  }
9897
9901
  function go(o) {
9898
- return (Cn(o) || Je(o) && !o.canBeEmpty()) && !o.isInline();
9902
+ return (En(o) || Je(o) && !o.canBeEmpty()) && !o.isInline();
9899
9903
  }
9900
9904
  function cl(o, i, a) {
9901
9905
  a.style.removeProperty("caret-color"), i._blockCursorElement = null, i = o.parentElement, i !== null && i.removeChild(o);
@@ -9914,7 +9918,7 @@ function MN() {
9914
9918
  return o.nodeType === 1;
9915
9919
  }
9916
9920
  function os(o) {
9917
- if (Cn(o) && !o.isInline()) return !0;
9921
+ if (En(o) && !o.isInline()) return !0;
9918
9922
  if (!Je(o) || lr(o)) return !1;
9919
9923
  var i = o.getFirstChild();
9920
9924
  return i = i === null || $i(i) || Nt(i) || i.isInline(), !o.isInline() && o.canBeEmpty() !== !1 && i;
@@ -9957,7 +9961,7 @@ function MN() {
9957
9961
  function Ii(o, i) {
9958
9962
  o.setProperty("text-align", i);
9959
9963
  }
9960
- function tr(o, i) {
9964
+ function nr(o, i) {
9961
9965
  var a = Fr.theme.indent;
9962
9966
  if (typeof a == "string") {
9963
9967
  let g = o.classList.contains(a);
@@ -9973,8 +9977,8 @@ function MN() {
9973
9977
  g === void 0 && Y(60);
9974
9978
  let C = g.createDOM(Fr, Bn);
9975
9979
  var x = Bn._keyToDOMMap;
9976
- if (C["__lexicalKey_" + Bn._key] = o, x.set(o, C), Nt(g) ? C.setAttribute("data-lexical-text", "true") : Cn(g) && C.setAttribute("data-lexical-decorator", "true"), Je(g)) {
9977
- if (o = g.__indent, x = g.__size, o !== 0 && tr(C, o), x !== 0) {
9980
+ if (C["__lexicalKey_" + Bn._key] = o, x.set(o, C), Nt(g) ? C.setAttribute("data-lexical-text", "true") : En(g) && C.setAttribute("data-lexical-decorator", "true"), Je(g)) {
9981
+ if (o = g.__indent, x = g.__size, o !== 0 && nr(C, o), x !== 0) {
9978
9982
  --x, o = bs(g, Nn);
9979
9983
  var D = zn;
9980
9984
  zn = "", pl(o, g, 0, x, C, null), ya(g, C), zn = D;
@@ -9984,7 +9988,7 @@ function MN() {
9984
9988
  `, si += `
9985
9989
 
9986
9990
  `);
9987
- } else x = g.getTextContent(), Cn(g) ? (D = g.decorate(Bn, Fr), D !== null && _l(o, D), C.contentEditable = "false") : Nt(g) && (g.isDirectionless() || (zn += x)), Ln += x, si += x;
9991
+ } else x = g.getTextContent(), En(g) ? (D = g.decorate(Bn, Fr), D !== null && _l(o, D), C.contentEditable = "false") : Nt(g) && (g.isDirectionless() || (zn += x)), Ln += x, si += x;
9988
9992
  return i !== null && (a != null ? i.insertBefore(C, a) : (a = i.__lexicalLineBreak, a != null ? i.insertBefore(C, a) : i.appendChild(C))), kt(oi, Ms, Zr, g, "created"), C;
9989
9993
  }
9990
9994
  function pl(o, i, a, g, C, x) {
@@ -9995,7 +9999,7 @@ function MN() {
9995
9999
  `), C.__lexicalTextContent = Ln, Ln = D + Ln;
9996
10000
  }
9997
10001
  function ki(o, i) {
9998
- return o = i.get(o), $i(o) || Cn(o) && o.isInline();
10002
+ return o = i.get(o), $i(o) || En(o) && o.isInline();
9999
10003
  }
10000
10004
  function ml(o, i, a) {
10001
10005
  o = o !== null && (o.__size === 0 || ki(o.__last, ar)), i = i.__size === 0 || ki(i.__last, Nn), o ? i || (i = a.__lexicalLineBreak, i != null && a.removeChild(i), a.__lexicalLineBreak = null) : i && (i = document.createElement("br"), a.__lexicalLineBreak = i, a.appendChild(i));
@@ -10031,7 +10035,7 @@ function MN() {
10031
10035
  if (a === g && !C) return Je(a) ? (g = x.__lexicalTextContent, g !== void 0 && (Ln += g, si += g), g = x.__lexicalDirTextContent, g !== void 0 && (zn += g)) : (g = a.getTextContent(), Nt(a) && !a.isDirectionless() && (zn += g), si += g, Ln += g), x;
10032
10036
  if (a !== g && C && kt(oi, Ms, Zr, g, "updated"), g.updateDOM(a, x, Fr)) return g = Tr(o, null, null), i === null && Y(62), i.replaceChild(g, x), Rs(o, null), g;
10033
10037
  if (Je(a) && Je(g)) {
10034
- if (o = g.__indent, o !== a.__indent && tr(x, o), o = g.__format, o !== a.__format && gl(x, o), C) {
10038
+ if (o = g.__indent, o !== a.__indent && nr(x, o), o = g.__format, o !== a.__format && gl(x, o), C) {
10035
10039
  o = zn, zn = "", C = Ln;
10036
10040
  var D = a.__size, Q = g.__size;
10037
10041
  if (Ln = "", D === 1 && Q === 1) {
@@ -10065,15 +10069,15 @@ function MN() {
10065
10069
  }
10066
10070
  on(g) && (Ln += `
10067
10071
 
10068
- `), x.__lexicalTextContent = Ln, Ln = C + Ln, ya(g, x), zn = o, nr(g) || g.isInline() || ml(a, g, x);
10072
+ `), x.__lexicalTextContent = Ln, Ln = C + Ln, ya(g, x), zn = o, rr(g) || g.isInline() || ml(a, g, x);
10069
10073
  }
10070
10074
  on(g) && (Ln += `
10071
10075
 
10072
10076
  `, si += `
10073
10077
 
10074
10078
  `);
10075
- } else a = g.getTextContent(), Cn(g) ? (C = g.decorate(Bn, Fr), C !== null && _l(o, C)) : Nt(g) && !g.isDirectionless() && (zn += a), Ln += a, si += a;
10076
- return !fl && nr(g) && g.__cachedText !== si && (g.getWritable().__cachedText = si), x;
10079
+ } else a = g.getTextContent(), En(g) ? (C = g.decorate(Bn, Fr), C !== null && _l(o, C)) : Nt(g) && !g.isDirectionless() && (zn += a), Ln += a, si += a;
10080
+ return !fl && rr(g) && g.__cachedText !== si && (g.getWritable().__cachedText = si), x;
10077
10081
  }
10078
10082
  function _l(o, i) {
10079
10083
  let a = Bn._pendingDecorators, g = Bn._decorators;
@@ -10144,7 +10148,7 @@ function MN() {
10144
10148
  if (g) if (At(a)) {
10145
10149
  let D = a.anchor;
10146
10150
  var x = D.getNode();
10147
- D.type === "element" && D.offset === 0 && a.isCollapsed() && !nr(x) && Rt().getChildrenSize() === 1 && x.getTopLevelElementOrThrow().isEmpty() && C !== null && a.is(C) ? (g.removeAllRanges(), a.dirty = !0) : o.detail !== 3 || a.isCollapsed() || (g = a.focus.getNode(), x !== g && (Je(x) ? x.select(0) : x.getParentOrThrow().select(0)));
10151
+ D.type === "element" && D.offset === 0 && a.isCollapsed() && !rr(x) && Rt().getChildrenSize() === 1 && x.getTopLevelElementOrThrow().isEmpty() && C !== null && a.is(C) ? (g.removeAllRanges(), a.dirty = !0) : o.detail !== 3 || a.isCollapsed() || (g = a.focus.getNode(), x !== g && (Je(x) ? x.select(0) : x.getParentOrThrow().select(0)));
10148
10152
  } else o.pointerType === "touch" && (x = g.anchorNode, x !== null && (x = x.nodeType, x === 1 || x === 3)) && (g = Gn(C, g, i, o), tn(g));
10149
10153
  lt(i, t, o);
10150
10154
  });
@@ -10152,7 +10156,7 @@ function MN() {
10152
10156
  function Ac(o, i) {
10153
10157
  let a = o.target;
10154
10158
  o = o.pointerType, a instanceof Node && o !== "touch" && vr(i, () => {
10155
- Cn(Wt(a)) || (Cl = !0);
10159
+ En(Wt(a)) || (Cl = !0);
10156
10160
  });
10157
10161
  }
10158
10162
  function Sa(o) {
@@ -10187,7 +10191,7 @@ function MN() {
10187
10191
  }
10188
10192
  }
10189
10193
  if (At(C)) {
10190
- x = o.data, as !== null && st(!1, i, as), C.dirty && as === null || !C.isCollapsed() || nr(C.anchor.getNode()) || g === null || C.applyDOMRange(g), as = null;
10194
+ x = o.data, as !== null && st(!1, i, as), C.dirty && as === null || !C.isCollapsed() || rr(C.anchor.getNode()) || g === null || C.applyDOMRange(g), as = null;
10191
10195
  var D = C.focus, Q = C.anchor.getNode();
10192
10196
  if (D = D.getNode(), a === "insertText" || a === "insertTranspose") x === `
10193
10197
  ` ? (o.preventDefault(), lt(i, r, !1)) : x === `
@@ -10404,7 +10408,7 @@ function MN() {
10404
10408
  let Ye = ge.focus;
10405
10409
  x.key === g && (hs(x, o, C, o.getPreviousSibling(), o.getNextSibling()), Ae = !0), Ye.key === g && (hs(Ye, o, C, o.getPreviousSibling(), o.getNextSibling()), Ae = !0);
10406
10410
  } else cr(ge) && i && o.isSelected() && o.selectPrevious();
10407
- At(ge) && i && !Ae ? (g = o.getIndexWithinParent(), yt(o), Hn(ge, C, g, -1)) : yt(o), a || lr(C) || C.canBeEmpty() || !C.isEmpty() || Tl(C, i), i && nr(C) && C.isEmpty() && C.selectEnd();
10411
+ At(ge) && i && !Ae ? (g = o.getIndexWithinParent(), yt(o), Hn(ge, C, g, -1)) : yt(o), a || lr(C) || C.canBeEmpty() || !C.isEmpty() || Tl(C, i), i && rr(C) && C.isEmpty() && C.selectEnd();
10408
10412
  }
10409
10413
  }
10410
10414
  class Fs {
@@ -10824,7 +10828,7 @@ function MN() {
10824
10828
  }
10825
10829
  static importDOM() {
10826
10830
  return {
10827
- "#text": () => ({ conversion: ct, priority: 0 }),
10831
+ "#text": () => ({ conversion: ut, priority: 0 }),
10828
10832
  b: () => ({ conversion: vl, priority: 0 }),
10829
10833
  code: () => ({ conversion: Ci, priority: 0 }),
10830
10834
  em: () => ({ conversion: Ci, priority: 0 }),
@@ -10968,7 +10972,7 @@ function MN() {
10968
10972
  return { forChild: (a) => (Nt(a) && !i && a.toggleFormat("bold"), a), node: null };
10969
10973
  }
10970
10974
  let Sl = /* @__PURE__ */ new WeakMap();
10971
- function ct(o) {
10975
+ function ut(o) {
10972
10976
  o.parentElement === null && Y(129);
10973
10977
  for (var i = o.textContent || "", a, g = o.parentNode, C = [o]; g !== null && (a = Sl.get(g)) === void 0 && !(g.nodeName === "PRE" || g.nodeType === 1 && g.style !== void 0 && g.style.whiteSpace !== void 0 && g.style.whiteSpace.startsWith("pre")); ) C.push(g), g = g.parentNode;
10974
10978
  for (a = a === void 0 ? g : a, g = 0; g < C.length; g++) Sl.set(C[g], a);
@@ -11102,7 +11106,7 @@ function MN() {
11102
11106
  } else xo(o, i);
11103
11107
  }
11104
11108
  function wl(o, i, a, g) {
11105
- let C = o.getNode(), x = C.getChildAtIndex(o.offset), D = Un(), Q = nr(C) ? zr().append(D) : D;
11109
+ let C = o.getNode(), x = C.getChildAtIndex(o.offset), D = Un(), Q = rr(C) ? zr().append(D) : D;
11106
11110
  D.setFormat(a), D.setStyle(g), x === null ? C.append(Q) : x.insertBefore(Q), o.is(i) && i.set(D.__key, 0, "text"), o.set(D.__key, 0, "text");
11107
11111
  }
11108
11112
  function Mr(o, i, a, g) {
@@ -11234,7 +11238,7 @@ function MN() {
11234
11238
  else if (Ye = !1, Nt(Ke)) {
11235
11239
  let Pe = Ke.getTextContent();
11236
11240
  Ke === a ? Ke === g ? (C.type !== "element" || x.type !== "element" || x.offset === C.offset) && (Pe = Q < ge ? Pe.slice(Q, ge) : Pe.slice(ge, Q)) : Pe = D ? Pe.slice(Q) : Pe.slice(ge) : Ke === g && (Pe = D ? Pe.slice(0, ge) : Pe.slice(0, Q)), Ae += Pe;
11237
- } else !Cn(Ke) && !$i(Ke) || Ke === g && this.isCollapsed() || (Ae += Ke.getTextContent());
11241
+ } else !En(Ke) && !$i(Ke) || Ke === g && this.isCollapsed() || (Ae += Ke.getTextContent());
11238
11242
  }
11239
11243
  return Ae;
11240
11244
  }
@@ -11323,7 +11327,7 @@ function MN() {
11323
11327
  var gt = Un(Ke.getTextContent());
11324
11328
  Ke.replace(gt), Ke = gt;
11325
11329
  }
11326
- nr(Ae.getNode()) || Ae.type !== "text" || (Ke = Ke.spliceText(0, Ye, "")), x.add(Ke.__key);
11330
+ rr(Ae.getNode()) || Ae.type !== "text" || (Ke = Ke.spliceText(0, Ye, "")), x.add(Ke.__key);
11327
11331
  } else Ae = Ke.getParentOrThrow(), Ae.canBeEmpty() || Ae.getChildrenSize() !== 1 ? Ke.remove() : Ae.remove();
11328
11332
  else x.add(Ke.__key);
11329
11333
  for (Ae = D.getChildren(), Ye = new Set(Q), Ke = Pe.is(D), Pe = Pe.isInline() && a.getNextSibling() === null ? Pe : a, gt = Ae.length - 1; 0 <= gt; gt--) {
@@ -11385,7 +11389,7 @@ function MN() {
11385
11389
  var C = Gs(this);
11386
11390
  g.splice(C, 0, i), a.selectEnd();
11387
11391
  }
11388
- else if (i.some((Q) => (Je(Q) || Cn(Q)) && !Q.isInline())) {
11392
+ else if (i.some((Q) => (Je(Q) || En(Q)) && !Q.isInline())) {
11389
11393
  a = zi(i), i = a.getLastDescendant();
11390
11394
  var x = a.getChildren();
11391
11395
  a = Je(g) && g.isEmpty() ? null : this.insertParagraph(), C = x[x.length - 1];
@@ -11423,10 +11427,10 @@ function MN() {
11423
11427
  }
11424
11428
  modify(i, a, g) {
11425
11429
  var C = this.focus, x = this.anchor, D = i === "move", Q = Bt(C, a);
11426
- if (Cn(Q) && !Q.isIsolated()) D && Q.isKeyboardSelectable() ? (a = Dl(), a.add(Q.__key), tn(a)) : (i = a ? Q.getPreviousSibling() : Q.getNextSibling(), Nt(i) ? (Q = i.__key, a = a ? i.getTextContent().length : 0, C.set(Q, a, "text"), D && x.set(Q, a, "text")) : (g = Q.getParentOrThrow(), Je(i) ? (g = i.__key, Q = a ? i.getChildrenSize() : 0) : (Q = Q.getIndexWithinParent(), g = g.__key, a || Q++), C.set(g, Q, "element"), D && x.set(g, Q, "element")));
11430
+ if (En(Q) && !Q.isIsolated()) D && Q.isKeyboardSelectable() ? (a = Dl(), a.add(Q.__key), tn(a)) : (i = a ? Q.getPreviousSibling() : Q.getNextSibling(), Nt(i) ? (Q = i.__key, a = a ? i.getTextContent().length : 0, C.set(Q, a, "text"), D && x.set(Q, a, "text")) : (g = Q.getParentOrThrow(), Je(i) ? (g = i.__key, Q = a ? i.getChildrenSize() : 0) : (Q = Q.getIndexWithinParent(), g = g.__key, a || Q++), C.set(g, Q, "element"), D && x.set(g, Q, "element")));
11427
11431
  else if (x = dn(), C = qr(x._window)) {
11428
11432
  var ge = x._blockCursorElement, Ae = x._rootElement;
11429
- if (Ae === null || ge === null || !Je(Q) || Q.isInline() || Q.canBeEmpty() || cl(ge, x, Ae), C.modify(i, a ? "backward" : "forward", g), 0 < C.rangeCount && (Q = C.getRangeAt(0), x = this.anchor.getNode(), x = nr(x) ? x : or(x), this.applyDOMRange(Q), this.dirty = !0, !D)) {
11433
+ if (Ae === null || ge === null || !Je(Q) || Q.isInline() || Q.canBeEmpty() || cl(ge, x, Ae), C.modify(i, a ? "backward" : "forward", g), 0 < C.rangeCount && (Q = C.getRangeAt(0), x = this.anchor.getNode(), x = rr(x) ? x : or(x), this.applyDOMRange(Q), this.dirty = !0, !D)) {
11430
11434
  for (D = this.getNodes(), i = [], g = !1, ge = 0; ge < D.length; ge++) Ae = D[ge], Zn(Ae, x) ? i.push(Ae) : g = !0;
11431
11435
  g && 0 < i.length && (a ? (a = i[0], Je(a) ? a.selectStart() : a.getParentOrThrow().selectStart()) : (a = i[i.length - 1], Je(a) ? a.selectEnd() : a.getParentOrThrow().selectEnd())), (C.anchorNode !== Q.startContainer || C.anchorOffset !== Q.startOffset) && (a = this.focus, D = this.anchor, C = D.key, Q = D.offset, x = D.type, Mr(D, a.key, a.offset, a.type), Mr(a, C, Q, x), this._cachedNodes = null);
11432
11436
  }
@@ -11440,7 +11444,7 @@ function MN() {
11440
11444
  var D = x.getParent();
11441
11445
  if (D = x.getNextSibling() || (D === null ? null : D.getNextSibling()), Je(D) && D.isShadowRoot()) return;
11442
11446
  }
11443
- if (D = Bt(C, i), Cn(D) && !D.isIsolated()) {
11447
+ if (D = Bt(C, i), En(D) && !D.isIsolated()) {
11444
11448
  D.isKeyboardSelectable() && Je(x) && x.getChildrenSize() === 0 ? (x.remove(), i = Dl(), i.add(D.__key), tn(i)) : (D.remove(), dn().dispatchCommand(e, void 0));
11445
11449
  return;
11446
11450
  }
@@ -11467,7 +11471,7 @@ function MN() {
11467
11471
  }
11468
11472
  }
11469
11473
  }
11470
- this.removeText(), i && !a && this.isCollapsed() && this.anchor.type === "element" && this.anchor.offset === 0 && (i = this.anchor.getNode(), i.isEmpty() && nr(i.getParent()) && i.getIndexWithinParent() === 0 && i.collapseAtStart(this));
11474
+ this.removeText(), i && !a && this.isCollapsed() && this.anchor.type === "element" && this.anchor.offset === 0 && (i = this.anchor.getNode(), i.isEmpty() && rr(i.getParent()) && i.getIndexWithinParent() === 0 && i.collapseAtStart(this));
11471
11475
  }
11472
11476
  deleteLine(i) {
11473
11477
  this.isCollapsed() && (this.anchor.type === "text" && this.modify("extend", i, "lineboundary"), (i ? this.focus : this.anchor).offset === 0 && this.modify(
@@ -11512,7 +11516,7 @@ function MN() {
11512
11516
  if (D = !1, ge === g._blockCursorElement ? (ge = x[C + 1], D = !0) : g._blockCursorElement !== null && C--, g = Ar(ge), Nt(g)) C = Q ? g.getTextContentSize() : 0;
11513
11517
  else {
11514
11518
  if (x = Ar(o), x === null) return null;
11515
- if (Je(x) ? (o = x.getChildAtIndex(C), (i = Je(o)) && (i = o.getParent(), i = a === null || i === null || !i.canBeEmpty() || i !== a.getNode()), i && (a = Q ? o.getLastDescendant() : o.getFirstDescendant(), a === null ? (x = o, C = 0) : (o = a, x = Je(o) ? o : o.getParentOrThrow())), Nt(o) ? (g = o, x = null, C = Q ? o.getTextContentSize() : 0) : o !== x && Q && !D && C++) : (C = x.getIndexWithinParent(), C = i === 0 && Cn(x) && Ar(o) === x ? C : C + 1, x = x.getParentOrThrow()), Je(x)) return Hr(x.__key, C, "element");
11519
+ if (Je(x) ? (o = x.getChildAtIndex(C), (i = Je(o)) && (i = o.getParent(), i = a === null || i === null || !i.canBeEmpty() || i !== a.getNode()), i && (a = Q ? o.getLastDescendant() : o.getFirstDescendant(), a === null ? (x = o, C = 0) : (o = a, x = Je(o) ? o : o.getParentOrThrow())), Nt(o) ? (g = o, x = null, C = Q ? o.getTextContentSize() : 0) : o !== x && Q && !D && C++) : (C = x.getIndexWithinParent(), C = i === 0 && En(x) && Ar(o) === x ? C : C + 1, x = x.getParentOrThrow()), Je(x)) return Hr(x.__key, C, "element");
11516
11520
  }
11517
11521
  } else g = Ar(o);
11518
11522
  return Nt(g) ? Hr(g.__key, C, "text") : null;
@@ -11529,7 +11533,7 @@ function MN() {
11529
11533
  }
11530
11534
  }
11531
11535
  function ka(o, i, a, g, C, x) {
11532
- return o === null || a === null || !it(C, o, a) || (i = Ks(o, i, At(x) ? x.anchor : null, C), i === null) || (g = Ks(a, g, At(x) ? x.focus : null, C), g === null || i.type === "element" && g.type === "element" && (o = Ar(o), a = Ar(a), Cn(o) && Cn(a))) ? null : (wo(i, g, x), [i, g]);
11536
+ return o === null || a === null || !it(C, o, a) || (i = Ks(o, i, At(x) ? x.anchor : null, C), i === null) || (g = Ks(a, g, At(x) ? x.focus : null, C), g === null || i.type === "element" && g.type === "element" && (o = Ar(o), a = Ar(a), En(o) && En(a))) ? null : (wo(i, g, x), [i, g]);
11533
11537
  }
11534
11538
  function Ol(o, i, a, g, C, x) {
11535
11539
  let D = Wr();
@@ -11629,7 +11633,7 @@ function MN() {
11629
11633
  let i = zr(), a = null;
11630
11634
  for (let g = 0; g < o.length; g++) {
11631
11635
  let C = o[g], x = $i(C);
11632
- if (x || Cn(C) && C.isInline() || Je(C) && C.isInline() || Nt(C) || C.isParentRequired()) {
11636
+ if (x || En(C) && C.isInline() || Je(C) && C.isInline() || Nt(C) || C.isParentRequired()) {
11633
11637
  if (a === null && (a = C.createParentElementNode(), i.append(a), x)) continue;
11634
11638
  a !== null && a.append(C);
11635
11639
  } else i.append(C), a = null;
@@ -11703,9 +11707,9 @@ function MN() {
11703
11707
  if (o._pendingEditorState = null, o._editorState = a, !C && ge && Pe !== null) {
11704
11708
  On = o, hn = a, Wn = !1, o._updating = !0;
11705
11709
  try {
11706
- let pn = o._dirtyType, Xn = o._dirtyElements, En = o._dirtyLeaves;
11710
+ let pn = o._dirtyType, Xn = o._dirtyElements, Tn = o._dirtyLeaves;
11707
11711
  Pe.disconnect();
11708
- var St = pn, $t = Xn, Kt = En;
11712
+ var St = pn, $t = Xn, Kt = Tn;
11709
11713
  zn = si = Ln = "", dl = St === 2, Li = null, Bn = o, Fr = o._config, Ms = o._nodes, Zr = Bn._listeners.mutation, hl = $t, vn = Kt, ar = x._nodeMap, Nn = a._nodeMap, fl = a._readOnly, mo = new Map(o._keyToDOMMap);
11710
11714
  let Ir = /* @__PURE__ */ new Map();
11711
11715
  oi = Ir, Pi("root", null), oi = mo = Fr = Nn = ar = vn = hl = Ms = Bn = void 0, gt = Ir;
@@ -11730,7 +11734,7 @@ function MN() {
11730
11734
  let pn = o._blockCursorElement;
11731
11735
  pn !== null && cl(pn, o, g);
11732
11736
  e: {
11733
- let Xn = br.anchorNode, En = br.focusNode, Ir = br.anchorOffset, vi = br.focusOffset, Et = document.activeElement;
11737
+ let Xn = br.anchorNode, Tn = br.focusNode, Ir = br.anchorOffset, vi = br.focusOffset, Et = document.activeElement;
11734
11738
  if (!(ci.has("collaboration") && Et !== g || Et !== null && rt(Et))) if (At(Q)) {
11735
11739
  var Zi = Q.anchor, Lo = Q.focus, Ha = Zi.key, Wa = Lo.key, Bl = bn(o, Ha), Zs = bn(o, Wa), Qr = Zi.offset, Ka = Lo.offset, Hl = Q.format, Io = Q.style, za = Q.isCollapsed(), Js = Bl, ko = Zs, Wl = !1;
11736
11740
  if (Zi.type === "text") {
@@ -11743,7 +11747,7 @@ function MN() {
11743
11747
  var Ua = performance.now();
11744
11748
  Ea = [Hl, Io, Qr, Ha, Ua];
11745
11749
  }
11746
- if (Ir === Qr && vi === Ka && Xn === Js && En === ko && (br.type !== "Range" || !za) && (Et !== null && g.contains(Et) || g.focus({ preventScroll: !0 }), Zi.type !== "element")) break e;
11750
+ if (Ir === Qr && vi === Ka && Xn === Js && Tn === ko && (br.type !== "Range" || !za) && (Et !== null && g.contains(Et) || g.focus({ preventScroll: !0 }), Zi.type !== "element")) break e;
11747
11751
  try {
11748
11752
  br.setBaseAndExtent(Js, Qr, ko, Ka);
11749
11753
  } catch {
@@ -11756,9 +11760,9 @@ function MN() {
11756
11760
  let fr = document.createRange();
11757
11761
  fr.selectNode(dr), kr = fr.getBoundingClientRect();
11758
11762
  } else kr = dr.getBoundingClientRect();
11759
- let rr = g.ownerDocument, Ur = rr.defaultView;
11763
+ let ir = g.ownerDocument, Ur = ir.defaultView;
11760
11764
  if (Ur !== null) for (var { top: Kl, bottom: ei } = kr, Dn, mt, Sr = g; Sr !== null; ) {
11761
- let fr = Sr === rr.body;
11765
+ let fr = Sr === ir.body;
11762
11766
  if (fr) Dn = 0, mt = un(o).innerHeight;
11763
11767
  else {
11764
11768
  let Bo = Sr.getBoundingClientRect();
@@ -11779,33 +11783,33 @@ function MN() {
11779
11783
  }
11780
11784
  Nl = !0;
11781
11785
  }
11782
- } else D !== null && it(o, Xn, En) && br.removeAllRanges();
11786
+ } else D !== null && it(o, Xn, Tn) && br.removeAllRanges();
11783
11787
  }
11784
11788
  }
11785
11789
  e: {
11786
11790
  let pn = o._blockCursorElement;
11787
11791
  if (At(Q) && Q.isCollapsed() && Q.anchor.type === "element" && g.contains(document.activeElement)) {
11788
- let Xn = Q.anchor, En = Xn.getNode(), Ir = Xn.offset, vi = En.getChildrenSize(), Et = !1, dr = null;
11792
+ let Xn = Q.anchor, Tn = Xn.getNode(), Ir = Xn.offset, vi = Tn.getChildrenSize(), Et = !1, dr = null;
11789
11793
  if (Ir === vi) {
11790
- let kr = En.getChildAtIndex(Ir - 1);
11794
+ let kr = Tn.getChildAtIndex(Ir - 1);
11791
11795
  go(kr) && (Et = !0);
11792
11796
  } else {
11793
- let kr = En.getChildAtIndex(Ir);
11797
+ let kr = Tn.getChildAtIndex(Ir);
11794
11798
  if (go(kr)) {
11795
- let rr = kr.getPreviousSibling();
11796
- (rr === null || go(rr)) && (Et = !0, dr = o.getElementByKey(kr.__key));
11799
+ let ir = kr.getPreviousSibling();
11800
+ (ir === null || go(ir)) && (Et = !0, dr = o.getElementByKey(kr.__key));
11797
11801
  }
11798
11802
  }
11799
11803
  if (Et) {
11800
- let kr = o.getElementByKey(En.__key);
11804
+ let kr = o.getElementByKey(Tn.__key);
11801
11805
  if (pn === null) {
11802
- let rr = o._config.theme, Ur = document.createElement("div");
11806
+ let ir = o._config.theme, Ur = document.createElement("div");
11803
11807
  Ur.contentEditable = "false", Ur.setAttribute("data-lexical-cursor", "true");
11804
- let fr = rr.blockCursor;
11808
+ let fr = ir.blockCursor;
11805
11809
  if (fr !== void 0) {
11806
11810
  if (typeof fr == "string") {
11807
11811
  let di = fr.split(" ");
11808
- fr = rr.blockCursor = di;
11812
+ fr = ir.blockCursor = di;
11809
11813
  }
11810
11814
  fr !== void 0 && Ur.classList.add(...fr);
11811
11815
  }
@@ -11825,8 +11829,8 @@ function MN() {
11825
11829
  if (gt !== null) {
11826
11830
  var Po = gt;
11827
11831
  let pn = Array.from(o._listeners.mutation), Xn = pn.length;
11828
- for (let En = 0; En < Xn; En++) {
11829
- let [Ir, vi] = pn[En], Et = Po.get(vi);
11832
+ for (let Tn = 0; Tn < Xn; Tn++) {
11833
+ let [Ir, vi] = pn[Tn], Et = Po.get(vi);
11830
11834
  Et !== void 0 && Ir(Et, { dirtyLeaves: Yn, prevEditorState: x, updateTags: ci });
11831
11835
  }
11832
11836
  }
@@ -11847,8 +11851,8 @@ function MN() {
11847
11851
  if (Fo.length !== 0) {
11848
11852
  let pn = Fo.shift();
11849
11853
  if (pn) {
11850
- let [Xn, En] = pn;
11851
- bl(o, Xn, En);
11854
+ let [Xn, Tn] = pn;
11855
+ bl(o, Xn, Tn);
11852
11856
  }
11853
11857
  }
11854
11858
  }
@@ -11943,7 +11947,7 @@ function MN() {
11943
11947
  return !0;
11944
11948
  }
11945
11949
  }
11946
- function Cn(o) {
11950
+ function En(o) {
11947
11951
  return o instanceof Do;
11948
11952
  }
11949
11953
  class Yi extends Fs {
@@ -12246,7 +12250,7 @@ function MN() {
12246
12250
  append(...i) {
12247
12251
  for (let a = 0; a < i.length; a++) {
12248
12252
  let g = i[a];
12249
- Je(g) || Cn(g) || Y(56);
12253
+ Je(g) || En(g) || Y(56);
12250
12254
  }
12251
12255
  return super.append(...i);
12252
12256
  }
@@ -12261,7 +12265,7 @@ function MN() {
12261
12265
  return !0;
12262
12266
  }
12263
12267
  }
12264
- function nr(o) {
12268
+ function rr(o) {
12265
12269
  return o instanceof ur;
12266
12270
  }
12267
12271
  function Ll(o, i) {
@@ -12579,13 +12583,13 @@ function MN() {
12579
12583
  i === null && (i = Rt().selectEnd()), i.insertNodes(o);
12580
12584
  }, We.$isBlockElementNode = function(o) {
12581
12585
  return Je(o) && !o.isInline();
12582
- }, We.$isDecoratorNode = Cn, We.$isElementNode = Je, We.$isInlineElementOrDecoratorNode = function(o) {
12583
- return Je(o) && o.isInline() || Cn(o) && o.isInline();
12586
+ }, We.$isDecoratorNode = En, We.$isElementNode = Je, We.$isInlineElementOrDecoratorNode = function(o) {
12587
+ return Je(o) && o.isInline() || En(o) && o.isInline();
12584
12588
  }, We.$isLeafNode = function(o) {
12585
- return Nt(o) || $i(o) || Cn(o);
12589
+ return Nt(o) || $i(o) || En(o);
12586
12590
  }, We.$isLineBreakNode = $i, We.$isNodeSelection = cr, We.$isParagraphNode = function(o) {
12587
12591
  return o instanceof Kr;
12588
- }, We.$isRangeSelection = At, We.$isRootNode = nr, We.$isRootOrShadowRoot = lr, We.$isTabNode = ba, We.$isTextNode = Nt, We.$nodesOfType = function(o) {
12592
+ }, We.$isRangeSelection = At, We.$isRootNode = rr, We.$isRootOrShadowRoot = lr, We.$isTabNode = ba, We.$isTextNode = Nt, We.$nodesOfType = function(o) {
12589
12593
  var i = Wr();
12590
12594
  let a = i._readOnly, g = o.getType();
12591
12595
  i = i._nodeMap;
@@ -12680,7 +12684,7 @@ var Af;
12680
12684
  function RN() {
12681
12685
  if (Af) return qc;
12682
12686
  Af = 1;
12683
- var e = qn(), t = Gt(), n = xn;
12687
+ var e = qn(), t = Gt(), n = Cn;
12684
12688
  const r = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u";
12685
12689
  var d = r ? n.useLayoutEffect : n.useEffect;
12686
12690
  const f = {
@@ -12764,7 +12768,7 @@ var Xc = {}, Mf;
12764
12768
  function bN() {
12765
12769
  if (Mf) return Xc;
12766
12770
  Mf = 1;
12767
- var e = qn(), t = Gt(), n = xn;
12771
+ var e = qn(), t = Gt(), n = Cn;
12768
12772
  let r = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u";
12769
12773
  var l = r ? n.useLayoutEffect : n.useEffect;
12770
12774
  let d = { tag: "history-merge" };
@@ -12817,7 +12821,7 @@ var IN = LN, Qc = {}, eu, Rf;
12817
12821
  function kN() {
12818
12822
  if (Rf) return eu;
12819
12823
  Rf = 1;
12820
- var e = qn(), t = xn, l = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? t.useLayoutEffect : t.useEffect;
12824
+ var e = qn(), t = Cn, l = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? t.useLayoutEffect : t.useEffect;
12821
12825
  function d(_) {
12822
12826
  const [T] = e.useLexicalComposerContext(), E = t.useMemo(() => _(T), [T, _]), S = t.useRef(E.initialValueFn()), [w, M] = t.useState(S.current);
12823
12827
  return l(() => {
@@ -12845,7 +12849,7 @@ var tu, bf;
12845
12849
  function PN() {
12846
12850
  if (bf) return tu;
12847
12851
  bf = 1;
12848
- var e = qn(), t = xn, n = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? t.useLayoutEffect : t.useEffect;
12852
+ var e = qn(), t = Cn, n = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? t.useLayoutEffect : t.useEffect;
12849
12853
  function r(d) {
12850
12854
  let [f] = e.useLexicalComposerContext(), p = t.useMemo(() => d(f), [f, d]), _ = t.useRef(p.initialValueFn()), [T, E] = t.useState(_.current);
12851
12855
  return n(() => {
@@ -15664,7 +15668,7 @@ var th;
15664
15668
  function JN() {
15665
15669
  if (th) return Qc;
15666
15670
  th = 1;
15667
- var e = qn(), t = _p(), n = xn, r = yp(), l = gn(), d = np, f = Np(), p = dd(), E = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? n.useLayoutEffect : n.useEffect;
15671
+ var e = qn(), t = _p(), n = Cn, r = yp(), l = gn(), d = np, f = Np(), p = dd(), E = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? n.useLayoutEffect : n.useEffect;
15668
15672
  function S(G) {
15669
15673
  return G.getEditorState().read(r.$canShowPlaceholderCurry(G.isComposing()));
15670
15674
  }
@@ -15728,7 +15732,7 @@ var fu = {}, nh;
15728
15732
  function XN() {
15729
15733
  if (nh) return fu;
15730
15734
  nh = 1;
15731
- var e = qn(), t = _p(), n = xn, r = yp(), l = gn(), d = np, f = Np(), p = dd(), _ = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? n.useLayoutEffect : n.useEffect;
15735
+ var e = qn(), t = _p(), n = Cn, r = yp(), l = gn(), d = np, f = Np(), p = dd(), _ = typeof window < "u" && typeof window.document < "u" && typeof window.document.createElement < "u" ? n.useLayoutEffect : n.useEffect;
15732
15736
  function T(m) {
15733
15737
  return m.getEditorState().read(r.$canShowPlaceholderCurry(m.isComposing()));
15734
15738
  }
@@ -15782,7 +15786,7 @@ var eC = QN, hu = {}, rh;
15782
15786
  function tC() {
15783
15787
  if (rh) return hu;
15784
15788
  rh = 1;
15785
- var e = qn(), t = xn;
15789
+ var e = qn(), t = Cn;
15786
15790
  function n() {
15787
15791
  return n = Object.assign ? Object.assign.bind() : function(p) {
15788
15792
  for (var _ = 1; _ < arguments.length; _++) {
@@ -15850,7 +15854,7 @@ var gu = {}, ih;
15850
15854
  function nC() {
15851
15855
  if (ih) return gu;
15852
15856
  ih = 1;
15853
- var e = qn(), t = xn;
15857
+ var e = qn(), t = Cn;
15854
15858
  function n() {
15855
15859
  return n = Object.assign ? Object.assign.bind() : function(l) {
15856
15860
  for (var d = 1; d < arguments.length; d++) {
@@ -15878,7 +15882,7 @@ var iC = rC, pu, sh;
15878
15882
  function sC() {
15879
15883
  if (sh) return pu;
15880
15884
  sh = 1;
15881
- var e = xn;
15885
+ var e = Cn;
15882
15886
  function t(p, _) {
15883
15887
  return t = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(E, S) {
15884
15888
  return E.__proto__ = S, E;
@@ -15960,7 +15964,7 @@ var mu, oh;
15960
15964
  function oC() {
15961
15965
  if (oh) return mu;
15962
15966
  oh = 1;
15963
- var e = xn;
15967
+ var e = Cn;
15964
15968
  function t(f, p) {
15965
15969
  return t = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(_, T) {
15966
15970
  return _.__proto__ = T, _;
@@ -17178,7 +17182,7 @@ var uh;
17178
17182
  function fC() {
17179
17183
  if (uh) return _u;
17180
17184
  uh = 1;
17181
- var e = fd(), t = qn(), n = xn, r = gn(), l = Gt();
17185
+ var e = fd(), t = qn(), n = Cn, r = gn(), l = Gt();
17182
17186
  function d(p) {
17183
17187
  n.useEffect(() => r.mergeRegister(p.registerCommand(e.INSERT_ORDERED_LIST_COMMAND, () => (e.insertList(p, "number"), !0), l.COMMAND_PRIORITY_LOW), p.registerCommand(e.INSERT_UNORDERED_LIST_COMMAND, () => (e.insertList(p, "bullet"), !0), l.COMMAND_PRIORITY_LOW), p.registerCommand(e.REMOVE_LIST_COMMAND, () => (e.removeList(p), !0), l.COMMAND_PRIORITY_LOW), p.registerCommand(l.INSERT_PARAGRAPH_COMMAND, () => !!e.$handleListInsertParagraph(), l.COMMAND_PRIORITY_LOW)), [p]);
17184
17188
  }
@@ -17195,7 +17199,7 @@ var Nu = {}, dh;
17195
17199
  function hC() {
17196
17200
  if (dh) return Nu;
17197
17201
  dh = 1;
17198
- var e = fd(), t = qn(), n = xn, r = gn(), l = Gt();
17202
+ var e = fd(), t = qn(), n = Cn, r = gn(), l = Gt();
17199
17203
  function d(f) {
17200
17204
  n.useEffect(() => r.mergeRegister(f.registerCommand(e.INSERT_ORDERED_LIST_COMMAND, () => (e.insertList(f, "number"), !0), l.COMMAND_PRIORITY_LOW), f.registerCommand(e.INSERT_UNORDERED_LIST_COMMAND, () => (e.insertList(f, "bullet"), !0), l.COMMAND_PRIORITY_LOW), f.registerCommand(e.REMOVE_LIST_COMMAND, () => (e.removeList(f), !0), l.COMMAND_PRIORITY_LOW), f.registerCommand(l.INSERT_PARAGRAPH_COMMAND, () => !!e.$handleListInsertParagraph(), l.COMMAND_PRIORITY_LOW)), [f]);
17201
17205
  }
@@ -17648,7 +17652,7 @@ var ph;
17648
17652
  function yC() {
17649
17653
  if (ph) return Cu;
17650
17654
  ph = 1;
17651
- var e = hd(), t = qn(), n = gn(), r = Gt(), l = xn;
17655
+ var e = hd(), t = qn(), n = gn(), r = Gt(), l = Cn;
17652
17656
  function d({
17653
17657
  validateUrl: f
17654
17658
  }) {
@@ -17690,7 +17694,7 @@ var Tu = {}, mh;
17690
17694
  function NC() {
17691
17695
  if (mh) return Tu;
17692
17696
  mh = 1;
17693
- var e = hd(), t = qn(), n = gn(), r = Gt(), l = xn;
17697
+ var e = hd(), t = qn(), n = gn(), r = Gt(), l = Cn;
17694
17698
  return Tu.LinkPlugin = function({ validateUrl: d }) {
17695
17699
  let [f] = t.useLexicalComposerContext();
17696
17700
  return l.useEffect(() => {
@@ -18973,7 +18977,7 @@ function TC() {
18973
18977
  } else
18974
18978
  pt.setColSpan(pt.__colSpan + 1);
18975
18979
  }
18976
- _t !== null && at(_t);
18980
+ _t !== null && ct(_t);
18977
18981
  }
18978
18982
  function Fe(Oe, ie) {
18979
18983
  const le = Oe.getChildren();
@@ -19031,12 +19035,12 @@ function TC() {
19031
19035
  const {
19032
19036
  cell: yt
19033
19037
  } = tt[0];
19034
- at(yt);
19038
+ ct(yt);
19035
19039
  } else {
19036
19040
  const yt = Ve[it - 1], {
19037
19041
  cell: Ct
19038
19042
  } = yt[0];
19039
- at(Ct);
19043
+ ct(Ct);
19040
19044
  }
19041
19045
  }
19042
19046
  function Be() {
@@ -19079,15 +19083,15 @@ function TC() {
19079
19083
  const {
19080
19084
  cell: pt
19081
19085
  } = Tt;
19082
- at(pt);
19086
+ ct(pt);
19083
19087
  } else {
19084
19088
  const pt = ht[Ge - 1], {
19085
19089
  cell: Pt
19086
19090
  } = pt;
19087
- at(Pt);
19091
+ ct(Pt);
19088
19092
  }
19089
19093
  }
19090
- function at(Oe) {
19094
+ function ct(Oe) {
19091
19095
  const ie = Oe.getFirstDescendant();
19092
19096
  ie == null ? Oe.selectStart() : ie.getParentOrThrow().selectStart();
19093
19097
  }
@@ -19190,8 +19194,8 @@ function xC() {
19190
19194
  return A = Math.max(A.rowIndex, se.rowIndex), { fromX: Math.min(F, ye), fromY: Math.min(De, A), toX: Math.max(F, ye), toY: Math.max(De, A) };
19191
19195
  }
19192
19196
  getNodes() {
19193
- function A(at) {
19194
- let { cell: Dt, startColumn: zt, startRow: Qt } = at;
19197
+ function A(ct) {
19198
+ let { cell: Dt, startColumn: zt, startRow: Qt } = ct;
19195
19199
  be = Math.min(be, zt), Ne = Math.min(Ne, Qt), Re = Math.max(Re, zt + Dt.__colSpan - 1), ke = Math.max(ke, Qt + Dt.__rowSpan - 1);
19196
19200
  }
19197
19201
  var F = this._cachedNodes;
@@ -19893,10 +19897,10 @@ function xC() {
19893
19897
  }
19894
19898
  let { cell: ke, startColumn: Fe, startRow: qe } = Re[B];
19895
19899
  if (Fe + ke.__colSpan - 1 <= B) {
19896
- let Be = ke, at = qe, Dt = B;
19897
- for (; at !== F && 1 < Be.__rowSpan; ) if (Dt -= ke.__colSpan, 0 <= Dt) {
19900
+ let Be = ke, ct = qe, Dt = B;
19901
+ for (; ct !== F && 1 < Be.__rowSpan; ) if (Dt -= ke.__colSpan, 0 <= Dt) {
19898
19902
  let { cell: zt, startRow: Qt } = Re[Dt];
19899
- Be = zt, at = Qt;
19903
+ Be = zt, ct = Qt;
19900
19904
  } else {
19901
19905
  Ne.append(A());
19902
19906
  continue e;
@@ -19968,8 +19972,8 @@ function xC() {
19968
19972
  ke = (ke || F).getNextSibling(), e.DEPRECATED_$isGridRowNode(ke) || n(125);
19969
19973
  var ne = null;
19970
19974
  for (let qe = 0; qe < Ne; qe++) {
19971
- let Be = Fe[qe], at = Be.cell;
19972
- Be.startRow === ee && (ne = at), 1 < at.__colSpan && (qe += at.__colSpan - 1);
19975
+ let Be = Fe[qe], ct = Be.cell;
19976
+ Be.startRow === ee && (ne = ct), 1 < ct.__colSpan && (qe += ct.__colSpan - 1);
19973
19977
  }
19974
19978
  if (ne === null) for (ne = 0; ne < B; ne++) fe(ke, S(_.NO_STATUS));
19975
19979
  else for (ee = 0; ee < B; ee++) ne.insertAfter(S(_.NO_STATUS));
@@ -20032,7 +20036,7 @@ function xC() {
20032
20036
  if ((Ne === e.DELETE_CHARACTER_COMMAND || Ne === e.DELETE_WORD_COMMAND) && Re.isCollapsed() && Re.anchor.offset === 0 && Fe !== ke) {
20033
20037
  Re = Fe.getChildren();
20034
20038
  const Be = e.$createParagraphNode();
20035
- return Re.forEach((at) => Be.append(at)), Fe.replace(Be), Fe.getWritable().__parent = qe.getKey(), !0;
20039
+ return Re.forEach((ct) => Be.append(ct)), Fe.replace(Be), Fe.getWritable().__parent = qe.getKey(), !0;
20036
20040
  }
20037
20041
  }
20038
20042
  return !1;
@@ -20070,13 +20074,13 @@ function xC() {
20070
20074
  if (Ne = Fe && t.$findMatchingParent(ke.anchor.getNode(), (Le) => e.DEPRECATED_$isGridCellNode(Le)) !== null && t.$findMatchingParent(ke.focus.getNode(), (Le) => e.DEPRECATED_$isGridCellNode(Le)) !== null || Ne && !Fe, Re.length !== 1 || !e.DEPRECATED_$isGridNode(Re[0]) || !Ne) return !1;
20071
20075
  var { anchor: qe } = ke, Be = Re[0];
20072
20076
  Ne = Be.getChildren(), Fe = Be.getFirstChildOrThrow().getChildrenSize(), Be = Be.getChildrenSize();
20073
- var at = t.$findMatchingParent(qe.getNode(), (Le) => e.DEPRECATED_$isGridCellNode(Le)), Dt = (qe = at && t.$findMatchingParent(at, (Le) => e.DEPRECATED_$isGridRowNode(Le))) && t.$findMatchingParent(qe, (Le) => e.DEPRECATED_$isGridNode(Le));
20074
- if (!e.DEPRECATED_$isGridCellNode(at) || !e.DEPRECATED_$isGridRowNode(qe) || !e.DEPRECATED_$isGridNode(Dt)) return !1;
20077
+ var ct = t.$findMatchingParent(qe.getNode(), (Le) => e.DEPRECATED_$isGridCellNode(Le)), Dt = (qe = ct && t.$findMatchingParent(ct, (Le) => e.DEPRECATED_$isGridRowNode(Le))) && t.$findMatchingParent(qe, (Le) => e.DEPRECATED_$isGridNode(Le));
20078
+ if (!e.DEPRECATED_$isGridCellNode(ct) || !e.DEPRECATED_$isGridRowNode(qe) || !e.DEPRECATED_$isGridNode(Dt)) return !1;
20075
20079
  var zt = qe.getIndexWithinParent(), Qt = Math.min(Dt.getChildrenSize() - 1, zt + Be - 1);
20076
- Be = at.getIndexWithinParent(), at = Math.min(qe.getChildrenSize() - 1, Be + Fe - 1), Fe = Math.min(Be, at), qe = Math.min(zt, Qt), Be = Math.max(Be, at), zt = Math.max(zt, Qt), Dt = Dt.getChildren(), Qt = 0;
20080
+ Be = ct.getIndexWithinParent(), ct = Math.min(qe.getChildrenSize() - 1, Be + Fe - 1), Fe = Math.min(Be, ct), qe = Math.min(zt, Qt), Be = Math.max(Be, ct), zt = Math.max(zt, Qt), Dt = Dt.getChildren(), Qt = 0;
20077
20081
  let Oe, ie;
20078
- for (at = qe; at <= zt; at++) {
20079
- var le = Dt[at];
20082
+ for (ct = qe; ct <= zt; ct++) {
20083
+ var le = Dt[ct];
20080
20084
  if (!e.DEPRECATED_$isGridRowNode(le)) return !1;
20081
20085
  var ve = Ne[Qt];
20082
20086
  if (!e.DEPRECATED_$isGridRowNode(ve)) return !1;
@@ -20087,7 +20091,7 @@ function xC() {
20087
20091
  if (!e.DEPRECATED_$isGridCellNode(Ve)) return !1;
20088
20092
  let nt = ve[Le];
20089
20093
  if (!e.DEPRECATED_$isGridCellNode(nt)) return !1;
20090
- at === qe && Me === Fe ? Oe = Ve.getKey() : at === zt && Me === Be && (ie = Ve.getKey());
20094
+ ct === qe && Me === Fe ? Oe = Ve.getKey() : ct === zt && Me === Be && (ie = Ve.getKey());
20091
20095
  let rt = Ve.getChildren();
20092
20096
  nt.getChildren().forEach((it) => {
20093
20097
  e.$isTextNode(it) && e.$createParagraphNode().append(it), Ve.append(it);
@@ -20101,8 +20105,8 @@ function xC() {
20101
20105
  () => {
20102
20106
  let Ne = e.$getSelection(), Re = e.$getPreviousSelection();
20103
20107
  if (e.$isRangeSelection(Ne)) {
20104
- let { anchor: at, focus: Dt } = Ne;
20105
- var ke = at.getNode(), Fe = Dt.getNode();
20108
+ let { anchor: ct, focus: Dt } = Ne;
20109
+ var ke = ct.getNode(), Fe = Dt.getNode();
20106
20110
  ke = Ee(ke), Fe = Ee(Fe);
20107
20111
  var qe = ke && B.is(de(ke)), Be = Fe && B.is(de(Fe));
20108
20112
  let zt = qe !== Be;
@@ -20124,7 +20128,7 @@ var Ch;
20124
20128
  function vC() {
20125
20129
  if (Ch) return xu;
20126
20130
  Ch = 1;
20127
- var e = qn(), t = gd(), n = gn(), r = Gt(), l = xn;
20131
+ var e = qn(), t = gd(), n = gn(), r = Gt(), l = Cn;
20128
20132
  function d({
20129
20133
  hasCellMerge: f = !0,
20130
20134
  hasCellBackgroundColor: p = !0,
@@ -20216,7 +20220,7 @@ var Su = {}, Eh;
20216
20220
  function SC() {
20217
20221
  if (Eh) return Su;
20218
20222
  Eh = 1;
20219
- var e = qn(), t = gd(), n = gn(), r = Gt(), l = xn;
20223
+ var e = qn(), t = gd(), n = gn(), r = Gt(), l = Cn;
20220
20224
  function d(f) {
20221
20225
  let p = new URLSearchParams();
20222
20226
  p.append("code", f);
@@ -22922,22 +22926,22 @@ function DC() {
22922
22926
  } = ne, qe = (Re.isBefore(ke) ? Re : ke).getNode();
22923
22927
  if (n.$isTextNode(qe)) {
22924
22928
  let Be = Se(qe);
22925
- const at = [];
22929
+ const ct = [];
22926
22930
  for (; ; )
22927
22931
  if (n.$isTabNode(Be))
22928
- at.push(n.$createTabNode()), Be = Be.getNextSibling();
22932
+ ct.push(n.$createTabNode()), Be = Be.getNextSibling();
22929
22933
  else if (Te(Be)) {
22930
22934
  let ve = 0;
22931
22935
  const Le = Be.getTextContent(), Me = Be.getTextContentSize();
22932
22936
  for (; ve < Me && Le[ve] === " "; ve++) ;
22933
- if (ve !== 0 && at.push(q(" ".repeat(ve))), ve !== Me)
22937
+ if (ve !== 0 && ct.push(q(" ".repeat(ve))), ve !== Me)
22934
22938
  break;
22935
22939
  Be = Be.getNextSibling();
22936
22940
  } else
22937
22941
  break;
22938
- const Dt = qe.splitText(Re.offset)[0], zt = Re.offset === 0 ? 0 : 1, Qt = Dt.getIndexWithinParent() + zt, Oe = qe.getParentOrThrow(), ie = [n.$createLineBreakNode(), ...at];
22942
+ const Dt = qe.splitText(Re.offset)[0], zt = Re.offset === 0 ? 0 : 1, Qt = Dt.getIndexWithinParent() + zt, Oe = qe.getParentOrThrow(), ie = [n.$createLineBreakNode(), ...ct];
22939
22943
  Oe.splice(Qt, 0, ie);
22940
- const le = at[at.length - 1];
22944
+ const le = ct[ct.length - 1];
22941
22945
  le ? le.select() : Re.offset === 0 ? Dt.selectPrevious() : Dt.getNextSibling().selectNext(0, 0);
22942
22946
  }
22943
22947
  if (_(qe)) {
@@ -23225,10 +23229,10 @@ function DC() {
23225
23229
  return !1;
23226
23230
  const Re = Ne.getTextContent(), ke = ue.tokenize(Re, Ne.getLanguage() || ue.defaultLanguage), Fe = R(ke), qe = X(Ne.getChildren(), Fe), {
23227
23231
  from: Be,
23228
- to: at,
23232
+ to: ct,
23229
23233
  nodesForReplacement: Dt
23230
23234
  } = qe;
23231
- return Be !== at || Dt.length ? (ee.splice(Be, at - Be, Dt), !0) : !1;
23235
+ return Be !== ct || Dt.length ? (ee.splice(Be, ct - Be, Dt), !0) : !1;
23232
23236
  });
23233
23237
  }, {
23234
23238
  onUpdate: () => {
@@ -23269,7 +23273,7 @@ function DC() {
23269
23273
  let Fe = 0;
23270
23274
  if (!ke) {
23271
23275
  const Be = Ne.getNode();
23272
- Fe = Re + Be.getPreviousSiblings().reduce((at, Dt) => at + Dt.getTextContentSize(), 0);
23276
+ Fe = Re + Be.getPreviousSiblings().reduce((ct, Dt) => ct + Dt.getTextContentSize(), 0);
23273
23277
  }
23274
23278
  if (ne()) {
23275
23279
  if (ke) {
@@ -23277,10 +23281,10 @@ function DC() {
23277
23281
  return;
23278
23282
  }
23279
23283
  ue.getChildren().some((Be) => {
23280
- const at = n.$isTextNode(Be);
23281
- if (at || n.$isLineBreakNode(Be)) {
23284
+ const ct = n.$isTextNode(Be);
23285
+ if (ct || n.$isLineBreakNode(Be)) {
23282
23286
  const Dt = Be.getTextContentSize();
23283
- if (at && Dt >= Fe)
23287
+ if (ct && Dt >= Fe)
23284
23288
  return Be.select(Fe, Fe), !0;
23285
23289
  Fe -= Dt;
23286
23290
  }
@@ -23343,9 +23347,9 @@ function DC() {
23343
23347
  throw Error("Expected selection firstNode to be CodeHighlightNode or TabNode");
23344
23348
  if (_(ke))
23345
23349
  return ue;
23346
- const Fe = Se(ke), qe = Ee(ke), Be = ne.anchor, at = ne.focus;
23350
+ const Fe = Se(ke), qe = Ee(ke), Be = ne.anchor, ct = ne.focus;
23347
23351
  let Dt, zt;
23348
- return at.isBefore(Be) ? (Dt = at, zt = Be) : (Dt = Be, zt = at), Fe !== null && qe !== null && Dt.key === Fe.getKey() && Dt.offset === 0 && zt.key === qe.getKey() && zt.offset === qe.getTextContentSize() ? ue : be;
23352
+ return ct.isBefore(Be) ? (Dt = ct, zt = Be) : (Dt = Be, zt = ct), Fe !== null && qe !== null && Dt.key === Fe.getKey() && Dt.offset === 0 && zt.key === qe.getKey() && zt.offset === qe.getTextContentSize() ? ue : be;
23349
23353
  }
23350
23354
  function F(ee) {
23351
23355
  const ne = n.$getSelection();
@@ -23393,17 +23397,17 @@ function DC() {
23393
23397
  }
23394
23398
  return !1;
23395
23399
  }
23396
- let at, Dt;
23397
- if (Fe.isBefore(qe) ? (at = Se(Fe), Dt = Ee(qe)) : (at = Se(qe), Dt = Ee(Fe)), at == null || Dt == null)
23400
+ let ct, Dt;
23401
+ if (Fe.isBefore(qe) ? (ct = Se(Fe), Dt = Ee(qe)) : (ct = Se(qe), Dt = Ee(Fe)), ct == null || Dt == null)
23398
23402
  return !1;
23399
- const zt = at.getNodesBetween(Dt);
23403
+ const zt = ct.getNodesBetween(Dt);
23400
23404
  for (let ve = 0; ve < zt.length; ve++) {
23401
23405
  const Le = zt[ve];
23402
23406
  if (!Te(Le) && !n.$isTabNode(Le) && !n.$isLineBreakNode(Le))
23403
23407
  return !1;
23404
23408
  }
23405
23409
  ne.preventDefault(), ne.stopPropagation();
23406
- const Qt = Be ? at.getPreviousSibling() : Dt.getNextSibling();
23410
+ const Qt = Be ? ct.getPreviousSibling() : Dt.getNextSibling();
23407
23411
  if (!n.$isLineBreakNode(Qt))
23408
23412
  return !0;
23409
23413
  const Oe = Be ? Qt.getPreviousSibling() : Qt.getNextSibling();
@@ -23430,9 +23434,9 @@ function DC() {
23430
23434
  if (qe !== null) {
23431
23435
  const {
23432
23436
  node: Be,
23433
- offset: at
23437
+ offset: ct
23434
23438
  } = qe;
23435
- n.$isLineBreakNode(Be) ? Be.selectNext(0, 0) : ue.setTextNodeRange(Be, at, Be, at);
23439
+ n.$isLineBreakNode(Be) ? Be.selectNext(0, 0) : ue.setTextNodeRange(Be, ct, Be, ct);
23436
23440
  } else
23437
23441
  ke.getParentOrThrow().selectStart();
23438
23442
  } else
@@ -23897,7 +23901,7 @@ const MC = process.env.NODE_ENV === "development" ? DC() : AC();
23897
23901
  var Vu = MC, pd = qn();
23898
23902
  function RC() {
23899
23903
  const [e] = pd.useLexicalComposerContext();
23900
- return sr(() => Vu.registerCodeHighlighting(e), [e]), null;
23904
+ return tr(() => Vu.registerCodeHighlighting(e), [e]), null;
23901
23905
  }
23902
23906
  var Qh = gn(), Fn = Gt();
23903
23907
  function bC({
@@ -23908,7 +23912,7 @@ function bC({
23908
23912
  maxWidth: l
23909
23913
  }) {
23910
23914
  const d = tp(() => ({ height: r, width: n, maxWidth: l }), [r, n, l]);
23911
- return /* @__PURE__ */ ft.jsx("img", { src: e, alt: t, style: d });
23915
+ return /* @__PURE__ */ at.jsx("img", { src: e, alt: t, style: d });
23912
23916
  }
23913
23917
  function $p({
23914
23918
  altText: e,
@@ -23989,7 +23993,7 @@ class il extends Fn.DecoratorNode {
23989
23993
  return !1;
23990
23994
  }
23991
23995
  decorate() {
23992
- return /* @__PURE__ */ ft.jsx(
23996
+ return /* @__PURE__ */ at.jsx(
23993
23997
  bC,
23994
23998
  {
23995
23999
  src: this.__src,
@@ -24006,7 +24010,7 @@ const IC = typeof window < "u" && typeof window.document < "u" && typeof window.
24006
24010
  );
24007
24011
  function PC() {
24008
24012
  const [e] = pd.useLexicalComposerContext();
24009
- return sr(() => {
24013
+ return tr(() => {
24010
24014
  if (!e.hasNodes([il]))
24011
24015
  throw new Error("ImagePlugin: ImageNode not registered on editor");
24012
24016
  return Qh.mergeRegister(
@@ -24138,7 +24142,7 @@ function UC(e) {
24138
24142
  }
24139
24143
  function GC({ maxDepth: e }) {
24140
24144
  const [t] = pd.useLexicalComposerContext();
24141
- return sr(() => t.registerCommand(
24145
+ return tr(() => t.registerCommand(
24142
24146
  Fn.INDENT_CONTENT_COMMAND,
24143
24147
  () => !UC(e || 7),
24144
24148
  zC
@@ -24230,7 +24234,7 @@ function VC() {
24230
24234
  }
24231
24235
  const jC = process.env.NODE_ENV === "development" ? YC() : VC();
24232
24236
  var qC = jC;
24233
- const ut = {
24237
+ const dt = {
24234
24238
  "yext-default-richtextv2-theme__ul1": "_yext-default-richtextv2-theme__ul1_13v3w_17",
24235
24239
  "yext-default-richtextv2-theme__ul2": "_yext-default-richtextv2-theme__ul2_13v3w_25",
24236
24240
  "yext-default-richtextv2-theme__ul3": "_yext-default-richtextv2-theme__ul3_13v3w_33",
@@ -24282,100 +24286,100 @@ const ut = {
24282
24286
  "yext-default-richtextv2-theme__embedBlockFocus": "_yext-default-richtextv2-theme__embedBlockFocus_13v3w_381",
24283
24287
  "yext-default-richtextv2-theme__image": "_yext-default-richtextv2-theme__image_13v3w_385"
24284
24288
  }, ZC = {
24285
- characterLimit: ut["yext-default-richtextv2-theme__characterLimit"],
24286
- code: ut["yext-default-richtextv2-theme__code"],
24289
+ characterLimit: dt["yext-default-richtextv2-theme__characterLimit"],
24290
+ code: dt["yext-default-richtextv2-theme__code"],
24287
24291
  codeHighlight: {
24288
- atrule: ut["yext-default-richtextv2-theme__tokenAttr"],
24289
- attr: ut["yext-default-richtextv2-theme__tokenAttr"],
24290
- boolean: ut["yext-default-richtextv2-theme__tokenProperty"],
24291
- builtin: ut["yext-default-richtextv2-theme__tokenSelector"],
24292
- cdata: ut["yext-default-richtextv2-theme__tokenComment"],
24293
- char: ut["yext-default-richtextv2-theme__tokenSelector"],
24294
- class: ut["yext-default-richtextv2-theme__tokenFunction"],
24295
- "class-name": ut["yext-default-richtextv2-theme__tokenFunction"],
24296
- comment: ut["yext-default-richtextv2-theme__tokenComment"],
24297
- constant: ut["yext-default-richtextv2-theme__tokenProperty"],
24298
- deleted: ut["yext-default-richtextv2-theme__tokenProperty"],
24299
- doctype: ut["yext-default-richtextv2-theme__tokenComment"],
24300
- entity: ut["yext-default-richtextv2-theme__tokenOperator"],
24301
- function: ut["yext-default-richtextv2-theme__tokenFunction"],
24302
- important: ut["yext-default-richtextv2-theme__tokenVariable"],
24303
- inserted: ut["yext-default-richtextv2-theme__tokenSelector"],
24304
- keyword: ut["yext-default-richtextv2-theme__tokenAttr"],
24305
- namespace: ut["yext-default-richtextv2-theme__tokenVariable"],
24306
- number: ut["yext-default-richtextv2-theme__tokenProperty"],
24307
- operator: ut["yext-default-richtextv2-theme__tokenOperator"],
24308
- prolog: ut["yext-default-richtextv2-theme__tokenComment"],
24309
- property: ut["yext-default-richtextv2-theme__tokenProperty"],
24310
- punctuation: ut["yext-default-richtextv2-theme__tokenPunctuation"],
24311
- regex: ut["yext-default-richtextv2-theme__tokenVariable"],
24312
- selector: ut["yext-default-richtextv2-theme__tokenSelector"],
24313
- string: ut["yext-default-richtextv2-theme__tokenSelector"],
24314
- symbol: ut["yext-default-richtextv2-theme__tokenProperty"],
24315
- tag: ut["yext-default-richtextv2-theme__tokenProperty"],
24316
- url: ut["yext-default-richtextv2-theme__tokenOperator"],
24317
- variable: ut["yext-default-richtextv2-theme__tokenVariable"]
24292
+ atrule: dt["yext-default-richtextv2-theme__tokenAttr"],
24293
+ attr: dt["yext-default-richtextv2-theme__tokenAttr"],
24294
+ boolean: dt["yext-default-richtextv2-theme__tokenProperty"],
24295
+ builtin: dt["yext-default-richtextv2-theme__tokenSelector"],
24296
+ cdata: dt["yext-default-richtextv2-theme__tokenComment"],
24297
+ char: dt["yext-default-richtextv2-theme__tokenSelector"],
24298
+ class: dt["yext-default-richtextv2-theme__tokenFunction"],
24299
+ "class-name": dt["yext-default-richtextv2-theme__tokenFunction"],
24300
+ comment: dt["yext-default-richtextv2-theme__tokenComment"],
24301
+ constant: dt["yext-default-richtextv2-theme__tokenProperty"],
24302
+ deleted: dt["yext-default-richtextv2-theme__tokenProperty"],
24303
+ doctype: dt["yext-default-richtextv2-theme__tokenComment"],
24304
+ entity: dt["yext-default-richtextv2-theme__tokenOperator"],
24305
+ function: dt["yext-default-richtextv2-theme__tokenFunction"],
24306
+ important: dt["yext-default-richtextv2-theme__tokenVariable"],
24307
+ inserted: dt["yext-default-richtextv2-theme__tokenSelector"],
24308
+ keyword: dt["yext-default-richtextv2-theme__tokenAttr"],
24309
+ namespace: dt["yext-default-richtextv2-theme__tokenVariable"],
24310
+ number: dt["yext-default-richtextv2-theme__tokenProperty"],
24311
+ operator: dt["yext-default-richtextv2-theme__tokenOperator"],
24312
+ prolog: dt["yext-default-richtextv2-theme__tokenComment"],
24313
+ property: dt["yext-default-richtextv2-theme__tokenProperty"],
24314
+ punctuation: dt["yext-default-richtextv2-theme__tokenPunctuation"],
24315
+ regex: dt["yext-default-richtextv2-theme__tokenVariable"],
24316
+ selector: dt["yext-default-richtextv2-theme__tokenSelector"],
24317
+ string: dt["yext-default-richtextv2-theme__tokenSelector"],
24318
+ symbol: dt["yext-default-richtextv2-theme__tokenProperty"],
24319
+ tag: dt["yext-default-richtextv2-theme__tokenProperty"],
24320
+ url: dt["yext-default-richtextv2-theme__tokenOperator"],
24321
+ variable: dt["yext-default-richtextv2-theme__tokenVariable"]
24318
24322
  },
24319
24323
  embedBlock: {
24320
- base: ut["yext-default-richtextv2-theme__embedBlock"],
24321
- focus: ut["yext-default-richtextv2-theme__embedBlockFocus"]
24324
+ base: dt["yext-default-richtextv2-theme__embedBlock"],
24325
+ focus: dt["yext-default-richtextv2-theme__embedBlockFocus"]
24322
24326
  },
24323
- hashtag: ut["yext-default-richtextv2-theme__hashtag"],
24327
+ hashtag: dt["yext-default-richtextv2-theme__hashtag"],
24324
24328
  heading: {
24325
- h1: ut["yext-default-richtextv2-theme__h1"],
24326
- h2: ut["yext-default-richtextv2-theme__h2"],
24327
- h3: ut["yext-default-richtextv2-theme__h3"],
24328
- h4: ut["yext-default-richtextv2-theme__h4"],
24329
- h5: ut["yext-default-richtextv2-theme__h5"],
24330
- h6: ut["yext-default-richtextv2-theme__h6"]
24329
+ h1: dt["yext-default-richtextv2-theme__h1"],
24330
+ h2: dt["yext-default-richtextv2-theme__h2"],
24331
+ h3: dt["yext-default-richtextv2-theme__h3"],
24332
+ h4: dt["yext-default-richtextv2-theme__h4"],
24333
+ h5: dt["yext-default-richtextv2-theme__h5"],
24334
+ h6: dt["yext-default-richtextv2-theme__h6"]
24331
24335
  },
24332
- image: ut["yext-default-richtextv2-theme__image"],
24333
- link: ut["yext-default-richtextv2-theme__link"],
24336
+ image: dt["yext-default-richtextv2-theme__image"],
24337
+ link: dt["yext-default-richtextv2-theme__link"],
24334
24338
  list: {
24335
- listitem: ut["yext-default-richtextv2-theme__listItem"],
24336
- listitemChecked: ut["yext-default-richtextv2-theme__listItemChecked"],
24337
- listitemUnchecked: ut["yext-default-richtextv2-theme__listItemUnchecked"],
24339
+ listitem: dt["yext-default-richtextv2-theme__listItem"],
24340
+ listitemChecked: dt["yext-default-richtextv2-theme__listItemChecked"],
24341
+ listitemUnchecked: dt["yext-default-richtextv2-theme__listItemUnchecked"],
24338
24342
  nested: {
24339
- listitem: ut["yext-default-richtextv2-theme__nestedListItem"]
24343
+ listitem: dt["yext-default-richtextv2-theme__nestedListItem"]
24340
24344
  },
24341
24345
  olDepth: [
24342
- ut["yext-default-richtextv2-theme__ol1"],
24343
- ut["yext-default-richtextv2-theme__ol2"],
24344
- ut["yext-default-richtextv2-theme__ol3"],
24345
- ut["yext-default-richtextv2-theme__ol4"],
24346
- ut["yext-default-richtextv2-theme__ol5"]
24346
+ dt["yext-default-richtextv2-theme__ol1"],
24347
+ dt["yext-default-richtextv2-theme__ol2"],
24348
+ dt["yext-default-richtextv2-theme__ol3"],
24349
+ dt["yext-default-richtextv2-theme__ol4"],
24350
+ dt["yext-default-richtextv2-theme__ol5"]
24347
24351
  ],
24348
24352
  ulDepth: [
24349
- ut["yext-default-richtextv2-theme__ul1"],
24350
- ut["yext-default-richtextv2-theme__ul2"],
24351
- ut["yext-default-richtextv2-theme__ul3"]
24353
+ dt["yext-default-richtextv2-theme__ul1"],
24354
+ dt["yext-default-richtextv2-theme__ul2"],
24355
+ dt["yext-default-richtextv2-theme__ul3"]
24352
24356
  ]
24353
24357
  },
24354
- ltr: ut["yext-default-richtextv2-theme__ltr"],
24355
- mark: ut["yext-default-richtextv2-theme__mark"],
24356
- markOverlap: ut["yext-default-richtextv2-theme__markOverlap"],
24357
- paragraph: ut["yext-default-richtextv2-theme__paragraph"],
24358
- quote: ut["yext-default-richtextv2-theme__quote"],
24359
- rtl: ut["yext-default-richtextv2-theme__rtl"],
24360
- table: ut["yext-default-richtextv2-theme__table"],
24361
- tableCell: ut["yext-default-richtextv2-theme__tableCell"],
24362
- tableCellHeader: ut["yext-default-richtextv2-theme__tableCellHeader"],
24358
+ ltr: dt["yext-default-richtextv2-theme__ltr"],
24359
+ mark: dt["yext-default-richtextv2-theme__mark"],
24360
+ markOverlap: dt["yext-default-richtextv2-theme__markOverlap"],
24361
+ paragraph: dt["yext-default-richtextv2-theme__paragraph"],
24362
+ quote: dt["yext-default-richtextv2-theme__quote"],
24363
+ rtl: dt["yext-default-richtextv2-theme__rtl"],
24364
+ table: dt["yext-default-richtextv2-theme__table"],
24365
+ tableCell: dt["yext-default-richtextv2-theme__tableCell"],
24366
+ tableCellHeader: dt["yext-default-richtextv2-theme__tableCellHeader"],
24363
24367
  text: {
24364
- bold: ut["yext-default-richtextv2-theme__textBold"],
24365
- code: ut["yext-default-richtextv2-theme__textCode"],
24366
- italic: ut["yext-default-richtextv2-theme__textItalic"],
24367
- strikethrough: ut["yext-default-richtextv2-theme__textStrikethrough"],
24368
- subscript: ut["yext-default-richtextv2-theme__textSubscript"],
24369
- superscript: ut["yext-default-richtextv2-theme__textSuperscript"],
24370
- underline: ut["yext-default-richtextv2-theme__textUnderline"],
24371
- underlineStrikethrough: ut["yext-default-richtextv2-theme__textUnderlineStrikethrough"]
24368
+ bold: dt["yext-default-richtextv2-theme__textBold"],
24369
+ code: dt["yext-default-richtextv2-theme__textCode"],
24370
+ italic: dt["yext-default-richtextv2-theme__textItalic"],
24371
+ strikethrough: dt["yext-default-richtextv2-theme__textStrikethrough"],
24372
+ subscript: dt["yext-default-richtextv2-theme__textSubscript"],
24373
+ superscript: dt["yext-default-richtextv2-theme__textSuperscript"],
24374
+ underline: dt["yext-default-richtextv2-theme__textUnderline"],
24375
+ underlineStrikethrough: dt["yext-default-richtextv2-theme__textUnderlineStrikethrough"]
24372
24376
  }
24373
24377
  };
24374
24378
  var Go = {}, Du = {}, ig;
24375
24379
  function JC() {
24376
24380
  if (ig) return Du;
24377
24381
  ig = 1;
24378
- var e = qn(), t = Gt(), n = xn;
24382
+ var e = qn(), t = Gt(), n = Cn;
24379
24383
  function r(d, f) {
24380
24384
  return d.getEditorState().read(() => {
24381
24385
  const p = t.$getNodeByKey(f);
@@ -24412,7 +24416,7 @@ var Au = {}, sg;
24412
24416
  function XC() {
24413
24417
  if (sg) return Au;
24414
24418
  sg = 1;
24415
- var e = qn(), t = Gt(), n = xn;
24419
+ var e = qn(), t = Gt(), n = Cn;
24416
24420
  function r(l, d) {
24417
24421
  return l.getEditorState().read(() => {
24418
24422
  let f = t.$getNodeByKey(d);
@@ -24454,7 +24458,7 @@ var lg;
24454
24458
  function QC() {
24455
24459
  if (lg) return Go;
24456
24460
  lg = 1;
24457
- var e = qn(), t = Hp(), n = gn(), r = Gt(), l = xn;
24461
+ var e = qn(), t = Hp(), n = gn(), r = Gt(), l = Cn;
24458
24462
  const d = r.createCommand("INSERT_HORIZONTAL_RULE_COMMAND");
24459
24463
  function f({
24460
24464
  nodeKey: S
@@ -24540,7 +24544,7 @@ var Yo = {}, ag;
24540
24544
  function eE() {
24541
24545
  if (ag) return Yo;
24542
24546
  ag = 1;
24543
- var e = qn(), t = Hp(), n = gn(), r = Gt(), l = xn;
24547
+ var e = qn(), t = Hp(), n = gn(), r = Gt(), l = Cn;
24544
24548
  let d = r.createCommand("INSERT_HORIZONTAL_RULE_COMMAND");
24545
24549
  function f({ nodeKey: S }) {
24546
24550
  let [w] = e.useLexicalComposerContext(), [M, m, v] = t.useLexicalNodeSelection(S), k = l.useCallback((G) => (M && r.$isNodeSelection(r.$getSelection()) && (G.preventDefault(), G = r.$getNodeByKey(S), E(G) && G.remove()), !1), [M, S]);
@@ -24636,19 +24640,19 @@ const Ru = {
24636
24640
  "editor-inner": "_editor-inner_1mmqo_6",
24637
24641
  "no-border": "_no-border_1mmqo_10"
24638
24642
  };
24639
- function nw({
24643
+ function rw({
24640
24644
  serializedAST: e,
24641
24645
  nodeClassNames: t
24642
24646
  }) {
24643
- return /* @__PURE__ */ ft.jsx(
24647
+ return /* @__PURE__ */ at.jsx(
24644
24648
  IN.LexicalComposer,
24645
24649
  {
24646
24650
  initialConfig: rE(e, t),
24647
- children: /* @__PURE__ */ ft.jsx("div", { className: `${Ru["editor-inner"]} ${Ru["no-border"]}`, children: /* @__PURE__ */ ft.jsxs("div", { className: Ru["editor-inner"], children: [
24648
- /* @__PURE__ */ ft.jsx(
24651
+ children: /* @__PURE__ */ at.jsx("div", { className: `${Ru["editor-inner"]} ${Ru["no-border"]}`, children: /* @__PURE__ */ at.jsxs("div", { className: Ru["editor-inner"], children: [
24652
+ /* @__PURE__ */ at.jsx(
24649
24653
  eC.RichTextPlugin,
24650
24654
  {
24651
- contentEditable: /* @__PURE__ */ ft.jsx(
24655
+ contentEditable: /* @__PURE__ */ at.jsx(
24652
24656
  iC.ContentEditable,
24653
24657
  {
24654
24658
  className: "editor-input",
@@ -24656,15 +24660,15 @@ function nw({
24656
24660
  }
24657
24661
  ),
24658
24662
  ErrorBoundary: cC,
24659
- placeholder: /* @__PURE__ */ ft.jsx("div", {})
24663
+ placeholder: /* @__PURE__ */ at.jsx("div", {})
24660
24664
  }
24661
24665
  ),
24662
- /* @__PURE__ */ ft.jsx(RC, {}),
24663
- /* @__PURE__ */ ft.jsx(pC.ListPlugin, {}),
24664
- /* @__PURE__ */ ft.jsx(EC.LinkPlugin, {}),
24665
- /* @__PURE__ */ ft.jsx(OC.TablePlugin, {}),
24666
- /* @__PURE__ */ ft.jsx(PC, {}),
24667
- /* @__PURE__ */ ft.jsx(GC, { maxDepth: 7 })
24666
+ /* @__PURE__ */ at.jsx(RC, {}),
24667
+ /* @__PURE__ */ at.jsx(pC.ListPlugin, {}),
24668
+ /* @__PURE__ */ at.jsx(EC.LinkPlugin, {}),
24669
+ /* @__PURE__ */ at.jsx(OC.TablePlugin, {}),
24670
+ /* @__PURE__ */ at.jsx(PC, {}),
24671
+ /* @__PURE__ */ at.jsx(GC, { maxDepth: 7 })
24668
24672
  ] }) })
24669
24673
  }
24670
24674
  );
@@ -25096,22 +25100,22 @@ rs.throws = function(e, t, n) {
25096
25100
  typeof t == "function" ? ii(!t(r), !0, !1, "not.throws", !1, "Expected function not to throw matching exception", n) : t instanceof RegExp ? ii(!t.test(r.message), !0, !1, "not.throws", !1, `Expected function not to throw exception matching \`${String(t)}\` pattern`, n) : t || ii(!1, !0, !1, "not.throws", !1, "Expected function not to throw", n);
25097
25101
  }
25098
25102
  };
25099
- const hE = /[!-\/:-@\[-`\{-~\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/, rw = Os(/[A-Za-z]/), pg = Os(/[\dA-Za-z]/), iw = Os(/[#-'*+\--9=?A-Z^-~]/);
25100
- function sw(e) {
25103
+ const hE = /[!-\/:-@\[-`\{-~\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061D-\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C77\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1B7D\u1B7E\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4F\u2E52-\u2E5D\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/, iw = Os(/[A-Za-z]/), pg = Os(/[\dA-Za-z]/), sw = Os(/[#-'*+\--9=?A-Z^-~]/);
25104
+ function ow(e) {
25101
25105
  return (
25102
25106
  // Special whitespace codes (which have negative values), C0 and Control
25103
25107
  // character DEL
25104
25108
  e !== null && (e < 32 || e === 127)
25105
25109
  );
25106
25110
  }
25107
- const ow = Os(/\d/), lw = Os(/[\dA-Fa-f]/), aw = Os(/[!-/:-@[-`{-~]/);
25108
- function cw(e) {
25111
+ const lw = Os(/\d/), aw = Os(/[\dA-Fa-f]/), cw = Os(/[!-/:-@[-`{-~]/);
25112
+ function uw(e) {
25109
25113
  return e !== null && e < -2;
25110
25114
  }
25111
25115
  function gE(e) {
25112
25116
  return e !== null && (e < 0 || e === 32);
25113
25117
  }
25114
- function uw(e) {
25118
+ function dw(e) {
25115
25119
  return e === -2 || e === -1 || e === 32;
25116
25120
  }
25117
25121
  const pE = Os(hE), mE = Os(/\s/);
@@ -25981,7 +25985,7 @@ function Tg(e) {
25981
25985
  return String(e || "").toUpperCase();
25982
25986
  }
25983
25987
  const gc = {}.hasOwnProperty;
25984
- function dw(e, t) {
25988
+ function fw(e, t) {
25985
25989
  const n = t || {}, r = n.allowDangerousHtml || !1, l = {};
25986
25990
  return f.dangerous = r, f.clobberPrefix = n.clobberPrefix === void 0 || n.clobberPrefix === null ? "user-content-" : n.clobberPrefix, f.footnoteLabel = n.footnoteLabel || "Footnotes", f.footnoteLabelTagName = n.footnoteLabelTagName || "h2", f.footnoteLabelProperties = n.footnoteLabelProperties || {
25987
25991
  className: ["sr-only"]
@@ -26086,14 +26090,14 @@ const bT = (e, t) => e(t, "i", ss(e, t)), LT = (e, t) => e(t, "b", ss(e, t)), IT
26086
26090
  strikethrough: kT,
26087
26091
  subscript: PT,
26088
26092
  superscript: $T
26089
- }, fw = (e) => {
26093
+ }, hw = (e) => {
26090
26094
  const [t, n] = Nr();
26091
26095
  let r;
26092
- return sr(() => {
26096
+ return tr(() => {
26093
26097
  (async () => {
26094
26098
  if (!r)
26095
26099
  try {
26096
- r = (await import("./index-B0QFvm3r.js")).default;
26100
+ r = (await import("./index-Ck_jvPcD.js")).default;
26097
26101
  } catch {
26098
26102
  throw new Error(
26099
26103
  "Failed to import React Markdown, cannot properly render LegacyRichText."
@@ -31737,13 +31741,13 @@ function ma(e) {
31737
31741
  return !e.futureInterval;
31738
31742
  }
31739
31743
  function zv(e) {
31740
- return pa(e) ? /* @__PURE__ */ ft.jsx("span", { className: "HoursStatus-current", children: "Open 24 Hours" }) : ma(e) ? /* @__PURE__ */ ft.jsx("span", { className: "HoursStatus-current", children: "Temporarily Closed" }) : /* @__PURE__ */ ft.jsx("span", { className: "HoursStatus-current", children: e.isOpen ? "Open Now" : "Closed" });
31744
+ return pa(e) ? /* @__PURE__ */ at.jsx("span", { className: "HoursStatus-current", children: "Open 24 Hours" }) : ma(e) ? /* @__PURE__ */ at.jsx("span", { className: "HoursStatus-current", children: "Temporarily Closed" }) : /* @__PURE__ */ at.jsx("span", { className: "HoursStatus-current", children: e.isOpen ? "Open Now" : "Closed" });
31741
31745
  }
31742
31746
  function Uv(e) {
31743
- return pa(e) || ma(e) ? null : /* @__PURE__ */ ft.jsx("span", { className: "HoursStatus-separator", children: " • " });
31747
+ return pa(e) || ma(e) ? null : /* @__PURE__ */ at.jsx("span", { className: "HoursStatus-separator", children: " • " });
31744
31748
  }
31745
31749
  function Gv(e) {
31746
- return pa(e) || ma(e) ? null : /* @__PURE__ */ ft.jsx("span", { className: "HoursStatus-future", children: e.isOpen ? "Closes at" : "Opens at" });
31750
+ return pa(e) || ma(e) ? null : /* @__PURE__ */ at.jsx("span", { className: "HoursStatus-future", children: e.isOpen ? "Closes at" : "Opens at" });
31747
31751
  }
31748
31752
  function Yv(e) {
31749
31753
  if (pa(e) || ma(e))
@@ -31756,7 +31760,7 @@ function Yv(e) {
31756
31760
  const n = e.futureInterval;
31757
31761
  t += n ? n.getStartTime("en-US", e.timeOptions) : "";
31758
31762
  }
31759
- return /* @__PURE__ */ ft.jsxs("span", { className: "HoursStatus-time", children: [
31763
+ return /* @__PURE__ */ at.jsxs("span", { className: "HoursStatus-time", children: [
31760
31764
  " ",
31761
31765
  t
31762
31766
  ] });
@@ -31777,14 +31781,14 @@ function Vv(e) {
31777
31781
  const d = e.futureInterval;
31778
31782
  n += ((l = d == null ? void 0 : d.start) == null ? void 0 : l.setLocale("en-US").toLocaleString(t)) || "";
31779
31783
  }
31780
- return /* @__PURE__ */ ft.jsxs("span", { className: "HoursStatus-dayOfWeek", children: [
31784
+ return /* @__PURE__ */ at.jsxs("span", { className: "HoursStatus-dayOfWeek", children: [
31781
31785
  " ",
31782
31786
  n
31783
31787
  ] });
31784
31788
  }
31785
31789
  function jv(e, t) {
31786
31790
  const n = e.currentTemplate || zv, r = e.separatorTemplate || Uv, l = e.futureTemplate || Gv, d = e.timeTemplate || Yv, f = e.dayOfWeekTemplate || Vv;
31787
- return /* @__PURE__ */ ft.jsxs("div", { className: oa("HoursStatus", (t == null ? void 0 : t.className) || ""), children: [
31791
+ return /* @__PURE__ */ at.jsxs("div", { className: oa("HoursStatus", (t == null ? void 0 : t.className) || ""), children: [
31788
31792
  n(e),
31789
31793
  r(e),
31790
31794
  l(e),
@@ -31792,9 +31796,9 @@ function jv(e, t) {
31792
31796
  f(e)
31793
31797
  ] });
31794
31798
  }
31795
- const hw = (e) => {
31799
+ const qv = { minHeight: `${1.5}em` }, gw = (e) => {
31796
31800
  const [t, n] = Nr(!1), [r, l] = Nr(!1);
31797
- sr(() => {
31801
+ tr(() => {
31798
31802
  l(!0);
31799
31803
  }, []);
31800
31804
  const d = e.statusTemplate || jv, f = new e_(e.hours, e.timezone), p = f.isOpenNow(), _ = f.getCurrentInterval(), T = f.getNextInterval(), E = (_ == null ? void 0 : _.end) || (T == null ? void 0 : T.start);
@@ -31809,9 +31813,9 @@ const hw = (e) => {
31809
31813
  futureInterval: T,
31810
31814
  ...e
31811
31815
  };
31812
- return /* @__PURE__ */ ft.jsx(ft.Fragment, { children: r && d(S, e) });
31816
+ return /* @__PURE__ */ at.jsx(at.Fragment, { children: r ? d(S, e) : /* @__PURE__ */ at.jsx("div", { style: qv }) });
31813
31817
  };
31814
- function qv(e, t) {
31818
+ function Zv(e, t) {
31815
31819
  const n = [];
31816
31820
  return e.forEach((r) => {
31817
31821
  const l = n[n.length - 1];
@@ -31829,14 +31833,14 @@ function qv(e, t) {
31829
31833
  };
31830
31834
  });
31831
31835
  }
31832
- function Zv(e, t) {
31836
+ function Jv(e, t) {
31833
31837
  const n = [], r = e.intervals.length > 0 && e.intervals[0].is24h();
31834
31838
  return e.intervals.length === 0 ? n.push("Closed") : r ? n.push("Open 24 hours") : e.intervals.forEach((l) => {
31835
31839
  const d = l.getStartTime("en-US", t), f = l.getEndTime("en-US", t);
31836
31840
  n.push(`${d} - ${f}`);
31837
31841
  }), n;
31838
31842
  }
31839
- function Jv(e, t, n) {
31843
+ function Xv(e, t, n) {
31840
31844
  const r = [];
31841
31845
  for (let l = 1; l <= 7; l++) {
31842
31846
  const d = wt.fromObject({ weekday: l }), f = bd(d);
@@ -31850,18 +31854,18 @@ function Jv(e, t, n) {
31850
31854
  }
31851
31855
  return r;
31852
31856
  }
31853
- const gw = (e) => {
31857
+ const pw = (e) => {
31854
31858
  const [t, n] = Nr(!1);
31855
- sr(() => {
31859
+ tr(() => {
31856
31860
  n(!0);
31857
31861
  }, []);
31858
31862
  const r = new e_(
31859
31863
  e.hours,
31860
31864
  Intl.DateTimeFormat().resolvedOptions().timeZone
31861
31865
  ), l = wt.now(), d = r.getIntervalsForNDays(7, l);
31862
- let f = Jv(d, l, e.dayOfWeekNames);
31863
- function p(E) {
31864
- return E ? {
31866
+ let f = Xv(d, l, e.dayOfWeekNames);
31867
+ function p(S) {
31868
+ return S ? {
31865
31869
  today: bd(l),
31866
31870
  monday: an.Monday,
31867
31871
  tuesday: an.Tuesday,
@@ -31870,7 +31874,7 @@ const gw = (e) => {
31870
31874
  friday: an.Friday,
31871
31875
  saturday: an.Saturday,
31872
31876
  sunday: an.Sunday
31873
- }[E] : an.Sunday;
31877
+ }[S] : an.Sunday;
31874
31878
  }
31875
31879
  let _ = [
31876
31880
  an.Sunday,
@@ -31884,32 +31888,37 @@ const gw = (e) => {
31884
31888
  const T = _.indexOf(
31885
31889
  p(e.startOfWeek)
31886
31890
  );
31887
- return _ = Wv(_, 7 - T), f.sort(
31888
- (E, S) => _.indexOf(E.startDay) - _.indexOf(S.startDay)
31889
- ), e.collapseDays && (f = qv(f, e.dayOfWeekNames)), /* @__PURE__ */ ft.jsx(ft.Fragment, { children: t && /* @__PURE__ */ ft.jsx("div", { className: oa("HoursTable", e.className), children: f.map((E) => {
31890
- const w = (e.intervalStringsBuilderFn || Zv)(
31891
- E,
31891
+ _ = Wv(_, 7 - T), f.sort(
31892
+ (S, w) => _.indexOf(S.startDay) - _.indexOf(w.startDay)
31893
+ ), e.collapseDays && (f = Zv(f, e.dayOfWeekNames));
31894
+ const E = Cn.useMemo(
31895
+ () => ({ minHeight: `${f.length * 1.5}em` }),
31896
+ [f.length]
31897
+ );
31898
+ return /* @__PURE__ */ at.jsx(at.Fragment, { children: t ? /* @__PURE__ */ at.jsx("div", { className: oa("HoursTable", e.className), children: f.map((S) => {
31899
+ const M = (e.intervalStringsBuilderFn || Jv)(
31900
+ S,
31892
31901
  e.timeOptions
31893
31902
  );
31894
- return /* @__PURE__ */ ft.jsxs(
31903
+ return /* @__PURE__ */ at.jsxs(
31895
31904
  "div",
31896
31905
  {
31897
- className: oa("HoursTable-row", { "is-today": E.isToday }),
31906
+ className: oa("HoursTable-row", { "is-today": S.isToday }),
31898
31907
  children: [
31899
- /* @__PURE__ */ ft.jsx("span", { className: "HoursTable-day", children: E.dayName }),
31900
- /* @__PURE__ */ ft.jsx("span", { className: "HoursTable-intervals", children: w.map((M, m) => /* @__PURE__ */ ft.jsx("span", { className: "HoursTable-interval", children: M }, m)) })
31908
+ /* @__PURE__ */ at.jsx("span", { className: "HoursTable-day", children: S.dayName }),
31909
+ /* @__PURE__ */ at.jsx("span", { className: "HoursTable-intervals", children: M.map((m, v) => /* @__PURE__ */ at.jsx("span", { className: "HoursTable-interval", children: m }, v)) })
31901
31910
  ]
31902
31911
  },
31903
- E.dayName
31912
+ S.dayName
31904
31913
  );
31905
- }) }) });
31906
- }, pw = (e) => `<script type="application/ld+json">
31914
+ }) }) : /* @__PURE__ */ at.jsx("div", { style: E }) });
31915
+ }, mw = (e) => `<script type="application/ld+json">
31907
31916
  ${JSON.stringify(e)}
31908
31917
  <\/script>`, Ld = (e, t) => ({
31909
31918
  "@context": "https://schema.org",
31910
31919
  "@type": t,
31911
31920
  name: e.name
31912
- }), Xv = (e) => typeof e != "object" ? !1 : "name" in e || "address" in e, Qv = (e) => typeof e != "object" ? !1 : "line1" in e || "city" in e || "region" in e || "postalCode" in e || "countryCode" in e, t_ = (e) => Qv(e) && {
31921
+ }), Qv = (e) => typeof e != "object" ? !1 : "name" in e || "address" in e, eS = (e) => typeof e != "object" ? !1 : "line1" in e || "city" in e || "region" in e || "postalCode" in e || "countryCode" in e, t_ = (e) => eS(e) && {
31913
31922
  address: {
31914
31923
  "@type": "PostalAddress",
31915
31924
  streetAddress: e.line1,
@@ -31918,7 +31927,7 @@ const gw = (e) => {
31918
31927
  postalCode: e.postalCode,
31919
31928
  addressCountry: e.countryCode
31920
31929
  }
31921
- }, eS = (e) => Xv(e) && {
31930
+ }, tS = (e) => Qv(e) && {
31922
31931
  "@type": "Place",
31923
31932
  name: e.name,
31924
31933
  ...t_(e.address)
@@ -31931,20 +31940,20 @@ const gw = (e) => {
31931
31940
  return {
31932
31941
  image: t
31933
31942
  };
31934
- }, mw = (e) => n_(e) && {
31943
+ }, _w = (e) => n_(e) && {
31935
31944
  image: e.image.url
31936
- }, tS = (e) => typeof e != "object" ? !1 : "url" in e || "name" in e, nS = (e) => Array.isArray(e), rS = (e) => nS(e) && {
31945
+ }, nS = (e) => typeof e != "object" ? !1 : "url" in e || "name" in e, rS = (e) => Array.isArray(e), iS = (e) => rS(e) && {
31937
31946
  performer: {
31938
31947
  "@type": "PerformingGroup",
31939
31948
  name: e.join(" and ")
31940
31949
  }
31941
- }, iS = (e) => tS(e) && {
31950
+ }, sS = (e) => nS(e) && {
31942
31951
  organizer: {
31943
31952
  "@type": "Organization",
31944
31953
  name: e.name,
31945
31954
  url: e.url
31946
31955
  }
31947
- }, sS = (e) => typeof e != "object" ? !1 : "url" in e || "priceCurrency" in e || "price" in e || "priceValidUntil" in e || "itemCondition" in e || "availability" in e, r_ = (e) => sS(e) && {
31956
+ }, oS = (e) => typeof e != "object" ? !1 : "url" in e || "priceCurrency" in e || "price" in e || "priceValidUntil" in e || "itemCondition" in e || "availability" in e, r_ = (e) => oS(e) && {
31948
31957
  offers: {
31949
31958
  "@type": "Offer",
31950
31959
  url: e.url,
@@ -31954,10 +31963,10 @@ const gw = (e) => {
31954
31963
  itemCondition: e.itemCondition,
31955
31964
  availability: e.availability
31956
31965
  }
31957
- }, _w = (e, t) => ({
31966
+ }, yw = (e, t) => ({
31958
31967
  ...Ld(e, t ?? "Event"),
31959
31968
  ...Id(e.photoGallery),
31960
- ...eS({
31969
+ ...tS({
31961
31970
  name: e.geomodifier,
31962
31971
  address: e.address
31963
31972
  }),
@@ -31966,8 +31975,8 @@ const gw = (e) => {
31966
31975
  description: e.description,
31967
31976
  eventAttendanceMode: e.attendance,
31968
31977
  eventStatus: e.eventStatus,
31969
- ...rS(e.performers),
31970
- ...iS({
31978
+ ...iS(e.performers),
31979
+ ...sS({
31971
31980
  name: e.organizerName
31972
31981
  }),
31973
31982
  ...r_({
@@ -31978,8 +31987,8 @@ const gw = (e) => {
31978
31987
  itemCondition: e.stockStatus,
31979
31988
  availability: e.availabilityDate
31980
31989
  })
31981
- }), oS = (e) => typeof e != "object" ? !1 : "monday" in e || "tuesday" in e || "wednesday" in e || "thursday" in e || "friday" in e || "saturday" in e || "sunday" in e, lS = (e) => typeof e == "object" && "isClosed" in e && Array.isArray(e.openIntervals) ? e.openIntervals.length === 0 ? !0 : e.openIntervals.every((t) => typeof t == "object" && "start" in t && "end" in t) : !1, aS = (e) => {
31982
- if (!oS(e))
31990
+ }), lS = (e) => typeof e != "object" ? !1 : "monday" in e || "tuesday" in e || "wednesday" in e || "thursday" in e || "friday" in e || "saturday" in e || "sunday" in e, aS = (e) => typeof e == "object" && "isClosed" in e && Array.isArray(e.openIntervals) ? e.openIntervals.length === 0 ? !0 : e.openIntervals.every((t) => typeof t == "object" && "start" in t && "end" in t) : !1, cS = (e) => {
31991
+ if (!lS(e))
31983
31992
  return {};
31984
31993
  let t = /* @__PURE__ */ new Map();
31985
31994
  t = no(e.monday, t, "Mo"), t = no(e.tuesday, t, "Tu"), t = no(e.wednesday, t, "We"), t = no(e.thursday, t, "Th"), t = no(e.friday, t, "Fr"), t = no(e.saturday, t, "Sa"), t = no(e.sunday, t, "Su");
@@ -31992,7 +32001,7 @@ const gw = (e) => {
31992
32001
  openingHours: n
31993
32002
  };
31994
32003
  }, no = (e, t, n) => {
31995
- if (!lS(e) || e.isClosed) {
32004
+ if (!aS(e) || e.isClosed) {
31996
32005
  const r = "00:00-00:00", l = t.get(r) ?? [];
31997
32006
  return l.push(n), t.set(r, l), t;
31998
32007
  }
@@ -32001,16 +32010,16 @@ const gw = (e) => {
32001
32010
  d.push(n), t.set(l, d);
32002
32011
  }
32003
32012
  return t;
32004
- }, yw = (e, t) => ({
32013
+ }, Nw = (e, t) => ({
32005
32014
  ...Ld(e, t ?? "LocalBusiness"),
32006
32015
  // default, if schemaType is nil, set to LocalBusiness
32007
32016
  ...t_(e.address),
32008
- ...aS(e.hours),
32017
+ ...cS(e.hours),
32009
32018
  ...Id(e.photoGallery),
32010
32019
  description: e.description,
32011
32020
  telephone: e.mainPhone,
32012
32021
  email: e.email
32013
- }), cS = (e) => typeof e != "object" ? !1 : "ratingValue" in e || "bestRating" in e || "author" in e, uS = (e) => typeof e != "object" ? !1 : "ratingValue" in e || "reviewCount" in e, dS = (e) => cS(e) && {
32022
+ }), uS = (e) => typeof e != "object" ? !1 : "ratingValue" in e || "bestRating" in e || "author" in e, dS = (e) => typeof e != "object" ? !1 : "ratingValue" in e || "reviewCount" in e, fS = (e) => uS(e) && {
32014
32023
  review: {
32015
32024
  "@type": "Review",
32016
32025
  reviewRating: {
@@ -32023,17 +32032,17 @@ const gw = (e) => {
32023
32032
  name: e.author
32024
32033
  }
32025
32034
  }
32026
- }, fS = (e) => uS(e) ? {
32035
+ }, hS = (e) => dS(e) ? {
32027
32036
  aggregateRating: {
32028
32037
  "@type": "AggregateRating",
32029
32038
  ratingValue: e.ratingValue,
32030
32039
  reviewCount: e.reviewCount
32031
32040
  }
32032
- } : void 0, Nw = (e, t) => ({
32041
+ } : void 0, Cw = (e, t) => ({
32033
32042
  ...Ld(e, t ?? "Product"),
32034
32043
  ...Id(e.photoGallery),
32035
- ...dS(e.c_reviews),
32036
- ...fS(e.c_aggregateRating),
32044
+ ...fS(e.c_reviews),
32045
+ ...hS(e.c_aggregateRating),
32037
32046
  ...r_({
32038
32047
  url: "",
32039
32048
  priceCurrency: e.c_currency,
@@ -32049,7 +32058,7 @@ const gw = (e) => {
32049
32058
  "@type": "Brand",
32050
32059
  name: e.brand
32051
32060
  }
32052
- }), hS = (e) => typeof e != "object" ? !1 : "question" in e && "answer" in e, gS = (e) => typeof e != "object" ? !1 : "question" in e && "answerV2" in e ? "json" in e.answerV2 && typeof e.answerV2.json == "object" : !1;
32061
+ }), gS = (e) => typeof e != "object" ? !1 : "question" in e && "answer" in e, pS = (e) => typeof e != "object" ? !1 : "question" in e && "answerV2" in e ? "json" in e.answerV2 && typeof e.answerV2.json == "object" : !1;
32053
32062
  function rd(e, t) {
32054
32063
  for (const n in e)
32055
32064
  if (typeof e[n] == "object")
@@ -32061,33 +32070,33 @@ function rd(e, t) {
32061
32070
  else
32062
32071
  n === "text" && t.push(e[n]);
32063
32072
  }
32064
- function pS(e) {
32073
+ function mS(e) {
32065
32074
  if (e.json) {
32066
32075
  const t = [];
32067
32076
  return rd(e.json, t), t.join("");
32068
32077
  }
32069
32078
  return "";
32070
32079
  }
32071
- const Cw = (e) => ({
32080
+ const Ew = (e) => ({
32072
32081
  "@context": "http://www.schema.org",
32073
32082
  "@type": "FAQPage",
32074
32083
  mainEntity: e.map((t) => {
32075
- if (hS(t) || gS(t))
32084
+ if (gS(t) || pS(t))
32076
32085
  return {
32077
32086
  "@type": "Question",
32078
32087
  name: t.question,
32079
32088
  acceptedAnswer: {
32080
32089
  "@type": "Answer",
32081
- text: "answer" in t ? t.answer : pS(t.answerV2)
32090
+ text: "answer" in t ? t.answer : mS(t.answerV2)
32082
32091
  }
32083
32092
  };
32084
32093
  })
32085
- }), id = Math.log2(1.6745627884839434), mS = 4, _S = 19, sd = "js-baidu-neg-lng-fix";
32094
+ }), id = Math.log2(1.6745627884839434), _S = 4, yS = 19, sd = "js-baidu-neg-lng-fix";
32086
32095
  let i_;
32087
- const yS = new Promise((e) => i_ = e), NS = "https://api.map.baidu.com/geoconv/v1/";
32096
+ const NS = new Promise((e) => i_ = e), CS = "https://api.map.baidu.com/geoconv/v1/";
32088
32097
  let Xl = [];
32089
- const CS = "gcj02ToBD09Callback_b872c21c";
32090
- let ES = 0, Qg;
32098
+ const ES = "gcj02ToBD09Callback_b872c21c";
32099
+ let TS = 0, Qg;
32091
32100
  async function s_(e) {
32092
32101
  return await new Promise((t, n) => {
32093
32102
  Xl.push({ coordinates: e, resolve: t, reject: n }), Xl.length === 1 && (Qg = setTimeout(r, 100)), Xl.length > 40 && (clearTimeout(Qg), r());
@@ -32096,7 +32105,7 @@ async function s_(e) {
32096
32105
  Xl = [];
32097
32106
  const d = [].concat(
32098
32107
  ...l.map((_) => _.coordinates)
32099
- ), f = CS + "_" + ES++, p = document.createElement("script");
32108
+ ), f = ES + "_" + TS++, p = document.createElement("script");
32100
32109
  window[f] = (_) => {
32101
32110
  var S;
32102
32111
  if (_.status) {
@@ -32117,7 +32126,7 @@ async function s_(e) {
32117
32126
  )
32118
32127
  );
32119
32128
  }), delete window[f], (S = p.parentNode) == null || S.removeChild(p);
32120
- }, yS.then((_) => {
32129
+ }, NS.then((_) => {
32121
32130
  const T = {
32122
32131
  ak: _,
32123
32132
  callback: f,
@@ -32127,12 +32136,12 @@ async function s_(e) {
32127
32136
  from: 3,
32128
32137
  to: 5
32129
32138
  };
32130
- p.src = NS + "?" + Object.entries(T).map(([E, S]) => E + "=" + S).join("&"), document.head.appendChild(p);
32139
+ p.src = CS + "?" + Object.entries(T).map(([E, S]) => E + "=" + S).join("&"), document.head.appendChild(p);
32131
32140
  });
32132
32141
  }
32133
32142
  });
32134
32143
  }
32135
- class TS extends nl {
32144
+ class xS extends nl {
32136
32145
  constructor(n) {
32137
32146
  super(n);
32138
32147
  Ie(this, "_wrapper");
@@ -32196,7 +32205,7 @@ class TS extends nl {
32196
32205
  });
32197
32206
  }
32198
32207
  }
32199
- class xS extends rl {
32208
+ class vS extends rl {
32200
32209
  constructor(n) {
32201
32210
  super(n);
32202
32211
  Ie(this, "_wrapper");
@@ -32276,8 +32285,8 @@ class xS extends rl {
32276
32285
  return `${this._originalWrapperClass} ${this._negativeLngFix ? sd : ""} ${this._wrapperClass}`;
32277
32286
  }
32278
32287
  }
32279
- const vS = "https://api.map.baidu.com/getscript";
32280
- function SS(e, t, n, { params: r = {}, version: l = "3.0" } = {}) {
32288
+ const SS = "https://api.map.baidu.com/getscript";
32289
+ function wS(e, t, n, { params: r = {}, version: l = "3.0" } = {}) {
32281
32290
  window.BMAP_PROTOCOL = "https", window.BMap_loadScriptTime = (/* @__PURE__ */ new Date()).getTime();
32282
32291
  const d = n, f = {
32283
32292
  ak: d,
@@ -32286,18 +32295,18 @@ function SS(e, t, n, { params: r = {}, version: l = "3.0" } = {}) {
32286
32295
  };
32287
32296
  i_(d);
32288
32297
  const p = document.createElement("script");
32289
- p.src = vS + "?" + Object.entries(f).map(([E, S]) => E + "=" + S).join("&"), p.onload = () => e(), document.head.appendChild(p);
32298
+ p.src = SS + "?" + Object.entries(f).map(([E, S]) => E + "=" + S).join("&"), p.onload = () => e(), document.head.appendChild(p);
32290
32299
  let _ = "";
32291
- for (let E = mS; E <= _S; E++) {
32300
+ for (let E = _S; E <= yS; E++) {
32292
32301
  const S = 2 ** (E - id + 7);
32293
32302
  _ += `[data-baidu-zoom="${E}"] .${sd}{transform:translateX(-${S}px);}`;
32294
32303
  }
32295
32304
  const T = document.createElement("style");
32296
32305
  T.appendChild(document.createTextNode(_)), document.head.appendChild(T);
32297
32306
  }
32298
- const Ew = new uo().withLoadFunction(SS).withMapClass(TS).withPinClass(xS).withProviderName("Baidu").build();
32307
+ const Tw = new uo().withLoadFunction(wS).withMapClass(xS).withPinClass(vS).withProviderName("Baidu").build();
32299
32308
  let o_;
32300
- function wS() {
32309
+ function OS() {
32301
32310
  class e extends Microsoft.Maps.CustomOverlay {
32302
32311
  constructor() {
32303
32312
  super({ beneathLabels: !1 });
@@ -32342,7 +32351,7 @@ function wS() {
32342
32351
  }
32343
32352
  o_ = e;
32344
32353
  }
32345
- class OS extends nl {
32354
+ class DS extends nl {
32346
32355
  constructor(n) {
32347
32356
  super(n);
32348
32357
  Ie(this, "wrapper");
@@ -32433,10 +32442,10 @@ class l_ extends rl {
32433
32442
  }
32434
32443
  }
32435
32444
  Ie(l_, "_pinId");
32436
- const ep = "BingMapsCallback_593d7d33", DS = "https://www.bing.com/api/maps/mapcontrol";
32437
- function AS(e, t, n, { params: r = {} } = {}) {
32445
+ const ep = "BingMapsCallback_593d7d33", AS = "https://www.bing.com/api/maps/mapcontrol";
32446
+ function MS(e, t, n, { params: r = {} } = {}) {
32438
32447
  window[ep] = () => {
32439
- wS(), e();
32448
+ OS(), e();
32440
32449
  };
32441
32450
  const l = {
32442
32451
  callback: ep,
@@ -32444,11 +32453,11 @@ function AS(e, t, n, { params: r = {} } = {}) {
32444
32453
  ...r
32445
32454
  };
32446
32455
  dp(
32447
- DS + "?" + Object.entries(l).map(([d, f]) => d + "=" + f).join("&")
32456
+ AS + "?" + Object.entries(l).map(([d, f]) => d + "=" + f).join("&")
32448
32457
  );
32449
32458
  }
32450
- const Tw = new uo().withLoadFunction(AS).withMapClass(OS).withPinClass(l_).withProviderName("Bing").build();
32451
- class MS extends nl {
32459
+ const xw = new uo().withLoadFunction(MS).withMapClass(DS).withPinClass(l_).withProviderName("Bing").build();
32460
+ class RS extends nl {
32452
32461
  constructor(n) {
32453
32462
  var r, l, d;
32454
32463
  super(n);
@@ -32507,7 +32516,7 @@ class MS extends nl {
32507
32516
  this.map && this.map[l ? "easeTo" : "jumpTo"]({ center: d, zoom: n - 1 });
32508
32517
  }
32509
32518
  }
32510
- class RS extends rl {
32519
+ class bS extends rl {
32511
32520
  constructor(n) {
32512
32521
  super(n);
32513
32522
  Ie(this, "pin");
@@ -32537,7 +32546,7 @@ class RS extends rl {
32537
32546
  (d = this.pin) == null || d.remove();
32538
32547
  }
32539
32548
  }
32540
- function bS(e, t, n, { version: r = "v1.13.0" } = {}) {
32549
+ function LS(e, t, n, { version: r = "v1.13.0" } = {}) {
32541
32550
  const l = `https://api.mapbox.com/mapbox-gl-js/${r}/mapbox-gl`, d = document.createElement("link");
32542
32551
  d.rel = "stylesheet", d.href = l + ".css";
32543
32552
  const f = document.createElement("script");
@@ -32545,7 +32554,7 @@ function bS(e, t, n, { version: r = "v1.13.0" } = {}) {
32545
32554
  mapboxgl.accessToken = n, e();
32546
32555
  }, document.head.appendChild(d), document.head.appendChild(f);
32547
32556
  }
32548
- const xw = new uo().withLoadFunction(bS).withMapClass(MS).withPinClass(RS).withProviderName("Mapbox").build();
32557
+ const vw = new uo().withLoadFunction(LS).withMapClass(RS).withPinClass(bS).withProviderName("Mapbox").build();
32549
32558
  var ao;
32550
32559
  let a_ = (ao = class extends nl {
32551
32560
  constructor(n) {
@@ -32607,7 +32616,7 @@ let a_ = (ao = class extends nl {
32607
32616
  };
32608
32617
  d.accessToken = ao.apiKey, this.map && L.tileLayer(l, d).addTo(this.map);
32609
32618
  }
32610
- }, Ie(ao, "apiKey"), ao), LS = class extends ad {
32619
+ }, Ie(ao, "apiKey"), ao), IS = class extends ad {
32611
32620
  constructor(n) {
32612
32621
  super(n);
32613
32622
  Ie(this, "pin");
@@ -32645,7 +32654,7 @@ let a_ = (ao = class extends nl {
32645
32654
  ), this.pin.setZIndexOffset(n.getZIndex());
32646
32655
  }
32647
32656
  };
32648
- function IS(e, t, n, { version: r = "1.7.1" } = {}) {
32657
+ function kS(e, t, n, { version: r = "1.7.1" } = {}) {
32649
32658
  const l = `https://unpkg.com/leaflet@${r}/dist/leaflet`;
32650
32659
  a_.apiKey = n;
32651
32660
  const d = document.createElement("link");
@@ -32653,8 +32662,8 @@ function IS(e, t, n, { version: r = "1.7.1" } = {}) {
32653
32662
  const f = document.createElement("script");
32654
32663
  f.src = l + ".js", f.onload = () => e(), document.head.appendChild(d), document.head.appendChild(f);
32655
32664
  }
32656
- const c_ = new uo().withLoadFunction(IS).withMapClass(a_).withPinClass(LS).withProviderName("Leaflet").build(), kS = c_.getMapClass(), PS = c_.getPinClass();
32657
- class $S extends kS {
32665
+ const c_ = new uo().withLoadFunction(kS).withMapClass(a_).withPinClass(IS).withProviderName("Leaflet").build(), PS = c_.getMapClass(), $S = c_.getPinClass();
32666
+ class FS extends PS {
32658
32667
  constructor() {
32659
32668
  super(...arguments);
32660
32669
  Ie(this, "map");
@@ -32676,9 +32685,9 @@ class $S extends kS {
32676
32685
  });
32677
32686
  }
32678
32687
  }
32679
- class FS extends PS {
32688
+ class BS extends $S {
32680
32689
  }
32681
- function BS(e, t, n, { version: r = "v1.3.2" } = {}) {
32690
+ function HS(e, t, n, { version: r = "v1.3.2" } = {}) {
32682
32691
  const l = `https://api.mqcdn.com/sdk/mapquest-js/${r}/mapquest-maps`, d = document.createElement("link");
32683
32692
  d.rel = "stylesheet", d.href = l + ".css";
32684
32693
  const f = document.createElement("script");
@@ -32686,78 +32695,78 @@ function BS(e, t, n, { version: r = "v1.3.2" } = {}) {
32686
32695
  L.mapquest.key = n, e();
32687
32696
  }, document.head.appendChild(d), document.head.appendChild(f);
32688
32697
  }
32689
- const Sw = new uo().withLoadFunction(BS).withMapClass($S).withPinClass(FS).withProviderName("MapQuest").build();
32698
+ const ww = new uo().withLoadFunction(HS).withMapClass(FS).withPinClass(BS).withProviderName("MapQuest").build();
32690
32699
  export {
32691
- yw as $,
32692
- US as A,
32693
- VS as B,
32694
- jS as C,
32695
- qS as D,
32696
- GS as E,
32700
+ Nw as $,
32701
+ GS as A,
32702
+ jS as B,
32703
+ qS as C,
32704
+ ZS as D,
32705
+ YS as E,
32697
32706
  Uu as F,
32698
32707
  ap as G,
32699
- YS as H,
32700
- ZS as I,
32708
+ VS as H,
32709
+ JS as I,
32701
32710
  so as J,
32702
32711
  cN as K,
32703
32712
  ny as L,
32704
32713
  cf as M,
32705
32714
  xN as N,
32706
- XS as O,
32715
+ QS as O,
32707
32716
  mp as P,
32708
- ew as Q,
32709
- QS as R,
32710
- tw as S,
32711
- nw as T,
32712
- fw as U,
32713
- hw as V,
32714
- gw as W,
32717
+ tw as Q,
32718
+ ew as R,
32719
+ nw as S,
32720
+ rw as T,
32721
+ hw as U,
32722
+ gw as V,
32723
+ pw as W,
32715
32724
  an as X,
32716
- pw as Y,
32725
+ mw as Y,
32717
32726
  Ld as Z,
32718
- _w as _,
32719
- dw as a,
32720
- Nw as a0,
32721
- Cw as a1,
32727
+ yw as _,
32728
+ fw as a,
32729
+ Cw as a0,
32730
+ Ew as a1,
32722
32731
  t_ as a2,
32723
- eS as a3,
32724
- aS as a4,
32732
+ tS as a3,
32733
+ cS as a4,
32725
32734
  r_ as a5,
32726
- rS as a6,
32727
- iS as a7,
32735
+ iS as a6,
32736
+ sS as a7,
32728
32737
  Id as a8,
32729
- mw as a9,
32730
- dS as aa,
32731
- fS as ab,
32732
- Ew as ac,
32733
- Tw as ad,
32738
+ _w as a9,
32739
+ fS as aa,
32740
+ hS as ab,
32741
+ Tw as ac,
32742
+ xw as ad,
32734
32743
  CN as ae,
32735
- xw as af,
32744
+ vw as af,
32736
32745
  c_ as ag,
32737
- Sw as ah,
32746
+ ww as ah,
32738
32747
  fn as ai,
32739
32748
  rp as b,
32740
32749
  oa as c,
32741
- cw as d,
32750
+ uw as d,
32742
32751
  fc as e,
32743
- rw as f,
32752
+ iw as f,
32744
32753
  sa as g,
32745
32754
  pg as h,
32746
- sw as i,
32747
- ft as j,
32748
- iw as k,
32749
- aw as l,
32750
- uw as m,
32755
+ ow as i,
32756
+ at as j,
32757
+ sw as k,
32758
+ cw as l,
32759
+ dw as m,
32751
32760
  ua as n,
32752
- lw as o,
32761
+ aw as o,
32753
32762
  Zl as p,
32754
- ow as q,
32763
+ lw as q,
32755
32764
  yE as r,
32756
32765
  _d as s,
32757
32766
  gE as t,
32758
32767
  iE as u,
32759
32768
  Xp as v,
32760
- zS as w,
32769
+ US as w,
32761
32770
  zy as x,
32762
32771
  lp as y,
32763
32772
  ca as z