@uva-glass/component-library 3.19.0 → 3.19.2

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.
Files changed (82) hide show
  1. package/dist/{Lexical.prod-qoFV025v.js → Lexical.prod-DcAfce4S.js} +2 -2
  2. package/dist/{Lexical.prod-qoFV025v.js.map → Lexical.prod-DcAfce4S.js.map} +1 -1
  3. package/dist/{LexicalClipboard.prod-BFJoO5qv.js → LexicalClipboard.prod-BktY_t6W.js} +4 -4
  4. package/dist/{LexicalClipboard.prod-BFJoO5qv.js.map → LexicalClipboard.prod-BktY_t6W.js.map} +1 -1
  5. package/dist/{LexicalLink.prod-BIN12UMz.js → LexicalLink.prod-BVtqGtVB.js} +3 -3
  6. package/dist/{LexicalLink.prod-BIN12UMz.js.map → LexicalLink.prod-BVtqGtVB.js.map} +1 -1
  7. package/dist/{LexicalList.prod-WlGaeo0L.js → LexicalList.prod-CZY2UZ4l.js} +5 -5
  8. package/dist/{LexicalList.prod-WlGaeo0L.js.map → LexicalList.prod-CZY2UZ4l.js.map} +1 -1
  9. package/dist/{LexicalSelection.prod-B5grbYgk.js → LexicalSelection.prod-Bbf3tSur.js} +2 -2
  10. package/dist/{LexicalSelection.prod-B5grbYgk.js.map → LexicalSelection.prod-Bbf3tSur.js.map} +1 -1
  11. package/dist/{LexicalTable.prod-osQj1CQX.js → LexicalTable.prod-CphD9tIW.js} +53 -53
  12. package/dist/LexicalTable.prod-CphD9tIW.js.map +1 -0
  13. package/dist/{LexicalUtils.prod-BpZsS7jD.js → LexicalUtils.prod-DGbydHdL.js} +2 -2
  14. package/dist/{LexicalUtils.prod-BpZsS7jD.js.map → LexicalUtils.prod-DGbydHdL.js.map} +1 -1
  15. package/dist/{TablePlugin-6tDdOCQy.js → TablePlugin-CE20cPhW.js} +4 -4
  16. package/dist/{TablePlugin-6tDdOCQy.js.map → TablePlugin-CE20cPhW.js.map} +1 -1
  17. package/dist/assets/Card.css +1 -1
  18. package/dist/assets/Checkbox.css +1 -1
  19. package/dist/assets/CheckboxButton.css +1 -1
  20. package/dist/assets/CheckboxButtonBar.css +1 -1
  21. package/dist/assets/CheckboxTree.css +1 -1
  22. package/dist/assets/Chip.css +1 -1
  23. package/dist/assets/Drawer.css +1 -1
  24. package/dist/assets/EmptyStateDataDisplay.css +1 -1
  25. package/dist/assets/FeedbackBar.css +1 -1
  26. package/dist/assets/FeedbackBox.css +1 -1
  27. package/dist/assets/FormInput.css +1 -1
  28. package/dist/assets/Icon.css +1 -1
  29. package/dist/assets/IconButton.css +1 -1
  30. package/dist/assets/InfoMessage.css +1 -1
  31. package/dist/assets/Input.css +1 -1
  32. package/dist/assets/InputField.css +1 -1
  33. package/dist/assets/Label.css +1 -1
  34. package/dist/components/Card/Card.js +23 -23
  35. package/dist/components/Checkbox/Checkbox.js +3 -3
  36. package/dist/components/CheckboxButton/CheckboxButton.js +21 -21
  37. package/dist/components/CheckboxButtonBar/CheckboxButtonBar.js +20 -20
  38. package/dist/components/CheckboxTree/CheckboxTree.js +41 -41
  39. package/dist/components/Chip/Chip.js +8 -8
  40. package/dist/components/Drawer/Drawer.js +28 -28
  41. package/dist/components/EmptyStateDataDisplay/EmptyStateDataDisplay.js +20 -20
  42. package/dist/components/FeedbackBar/FeedbackBar.js +15 -15
  43. package/dist/components/FeedbackBox/FeedbackBox.js +13 -13
  44. package/dist/components/FormInput/FormInput.js +20 -20
  45. package/dist/components/Icon/Icon.stories.js +9 -9
  46. package/dist/components/IconButton/IconButton.js +10 -10
  47. package/dist/components/InfoMessage/InfoMessage.js +5 -5
  48. package/dist/components/Input/Input.js +14 -14
  49. package/dist/components/InputField/InputField.js +40 -40
  50. package/dist/components/InputField/InputField.stories.js +1 -1
  51. package/dist/components/Label/Label.js +13 -13
  52. package/dist/components/MultiSelect/MultiSelect.js +1 -1
  53. package/dist/components/MultiSelect/MultiSelect.stories.js +1 -1
  54. package/dist/components/MultiSelect/components/MultiSelectHeader.js +1 -1
  55. package/dist/components/MultiSelect/index.js +1 -1
  56. package/dist/components/PeriodSelector/PeriodSelector.js +1 -1
  57. package/dist/components/ProgrammeCard/ProgrammeCard.stories.js +1 -1
  58. package/dist/components/RteEditor/EditorHeader/EditorHeader.js +1 -1
  59. package/dist/components/RteEditor/Plugins/BlockFormatPlugin/BlockFormatPlugin.js +1 -1
  60. package/dist/components/RteEditor/Plugins/HistoryPlugin/HistoryPlugin.js +2 -2
  61. package/dist/components/RteEditor/Plugins/LinkPlugin/AddLinkForm/AddLinkFrom.js +2 -2
  62. package/dist/components/RteEditor/Plugins/LinkPlugin/LinkContextMenu/LinkContextMenu.js +1 -1
  63. package/dist/components/RteEditor/Plugins/LinkPlugin/LinkPlugin.js +4 -4
  64. package/dist/components/RteEditor/Plugins/LinkPlugin/helpers.js +1 -1
  65. package/dist/components/RteEditor/Plugins/ListPlugin/ListPlugin.js +3 -3
  66. package/dist/components/RteEditor/Plugins/PasteHandlerPlugin/PasteHandlerPlugin.js +3 -3
  67. package/dist/components/RteEditor/Plugins/TablePlugin/AddTableFrom.js +1 -1
  68. package/dist/components/RteEditor/Plugins/TablePlugin/TablePlugin.js +3 -3
  69. package/dist/components/RteEditor/Plugins/TablePlugin/helpers.js +2 -2
  70. package/dist/components/RteEditor/Plugins/TablePlugin/index.js +1 -1
  71. package/dist/components/RteEditor/Plugins/ToolbarPlugin/ToolbarPlugin.js +3 -3
  72. package/dist/components/RteEditor/Plugins/index.js +1 -1
  73. package/dist/components/RteEditor/RteEditor.js +196 -190
  74. package/dist/components/RteEditor/RteEditor.js.map +1 -1
  75. package/dist/components/RteEditor/helpers.js +4 -4
  76. package/dist/components/Timeline/Timeline.test.js +1 -1
  77. package/dist/components/index.js +1 -1
  78. package/dist/{helpers-5RvdadYU.js → helpers-Dpx3BPyY.js} +4 -4
  79. package/dist/{helpers-5RvdadYU.js.map → helpers-Dpx3BPyY.js.map} +1 -1
  80. package/dist/index.js +1 -1
  81. package/package.json +13 -13
  82. package/dist/LexicalTable.prod-osQj1CQX.js.map +0 -1
@@ -1,22 +1,22 @@
1
1
  import { jsx as h, jsxs as K, Fragment as Re } from "react/jsx-runtime";
2
2
  import { t as Xe, r as Ye, o as T } from "../../LexicalComposerContext.prod-DLlRM5wP.js";
3
- import { aF as Ie, af as A, P as Me, N as p, aG as de, am as J, d as W, F as Qe, Q as M, c as g, V as Ze, L as m, aH as et, ae as Fe, o as tt, q as Oe, aI as rt, aJ as nt, U as ot, g as P, aC as at, aK as st, aL as it, aM as lt, k as te, aN as ut, aO as ct, a1 as dt, v as ft, y as mt, O as pt, aP as gt, aQ as me, a as pe, H as ht, D as re, G as vt, a2 as Ke, aR as ge, A as Ct, z as yt, t as Et, aS as he, x as wt, aT as bt, aU as _t, aV as St, aB as kt, R as xt, M as Nt, aW as Lt, S as Dt, C as $t, B as Pt, n as Tt, I as ve, aX as Rt, b as It, ar as X, aq as Y, aY as Mt, aZ as Ft, at as Ot, a_ as se, as as Kt, a$ as zt } from "../../Lexical.prod-qoFV025v.js";
3
+ import { aF as Ie, af as A, P as Fe, N as p, aG as de, am as J, d as W, F as Qe, Q as F, c as g, V as Ze, L as m, aH as et, ae as Me, o as tt, q as Oe, aI as rt, aJ as nt, U as ot, g as P, aC as at, aK as st, aL as it, aM as lt, k as te, aN as ut, aO as ct, a1 as dt, v as ft, y as mt, O as pt, aP as gt, aQ as me, a as pe, H as ht, D as re, G as vt, a2 as Ke, aR as ge, A as Ct, z as yt, t as Et, aS as he, x as wt, aT as bt, aU as _t, aV as St, aB as kt, R as xt, M as Nt, aW as Lt, S as Dt, C as $t, B as Pt, n as Tt, I as ve, aX as Rt, b as It, ar as X, aq as Y, aY as Ft, aZ as Mt, at as Ot, a_ as se, as as Kt, a$ as zt } from "../../Lexical.prod-DcAfce4S.js";
4
4
  import * as ne from "react";
5
- import { useMemo as q, useLayoutEffect as U, useEffect as S, useState as F, useRef as ze, Suspense as At, forwardRef as Ae, useCallback as Bt } from "react";
6
- import { j as H, L as z, y as Ut, w as fe } from "../../LexicalUtils.prod-BpZsS7jD.js";
5
+ import { useMemo as q, useLayoutEffect as U, useEffect as S, useState as M, useRef as ze, Suspense as At, forwardRef as Ae, useCallback as Bt } from "react";
6
+ import { j as H, L as z, y as Ut, w as fe } from "../../LexicalUtils.prod-DGbydHdL.js";
7
7
  import { flushSync as Ht, createPortal as jt } from "react-dom";
8
- import { D as Ce, _ as ye, h as Jt, m as Wt } from "../../LexicalClipboard.prod-BFJoO5qv.js";
9
- import { X as Ee, J as we } from "../../LexicalSelection.prod-B5grbYgk.js";
10
- import { r as Be, G as Ue, v as qt, T as Vt } from "../../LexicalList.prod-WlGaeo0L.js";
11
- import { g as He, k as be, N as oe, p as Gt, m as Xt } from "../../LexicalLink.prod-BIN12UMz.js";
12
- import { s as Yt, c as Qt, a as je, b as Zt, w as er, S as tr, y as Je, O as rr } from "../../LexicalTable.prod-osQj1CQX.js";
13
- import { a as nr, w as or, M as ar } from "../../helpers-5RvdadYU.js";
8
+ import { D as Ce, _ as ye, h as Jt, m as Wt } from "../../LexicalClipboard.prod-BktY_t6W.js";
9
+ import { X as Ee, J as we } from "../../LexicalSelection.prod-Bbf3tSur.js";
10
+ import { r as Be, G as Ue, v as qt, T as Vt } from "../../LexicalList.prod-CZY2UZ4l.js";
11
+ import { g as He, k as be, N as oe, p as Gt, m as Xt } from "../../LexicalLink.prod-BVtqGtVB.js";
12
+ import { s as Yt, c as Qt, a as je, b as Zt, w as er, S as tr, y as Je, O as rr } from "../../LexicalTable.prod-CphD9tIW.js";
13
+ import { a as nr, w as or, M as ar } from "../../helpers-Dpx3BPyY.js";
14
14
  import { c as sr } from "../../clsx-OuTLNxxd.js";
15
15
  import { exportMap as ir, isStartingWithHtmlTag as lr, mergeBoldStrongTags as ur } from "./helpers.js";
16
16
  import { s as I } from "../../RteEditor.module-oFMKEW6f.js";
17
17
  import { ToolBarPlugin as cr } from "./Plugins/ToolbarPlugin/ToolbarPlugin.js";
18
18
  import { useTranslation as dr } from "./hooks/useTranslation.js";
19
- import "../../TablePlugin-6tDdOCQy.js";
19
+ import "../../TablePlugin-CE20cPhW.js";
20
20
  import "./Plugins/LinkPlugin/LinkContextMenu/LinkContextMenu.js";
21
21
  import "./hooks/components/Flyout.js";
22
22
  import "../Buttons/Button.js";
@@ -44,13 +44,13 @@ import { PasteHandlerPlugin as vr } from "./Plugins/PasteHandlerPlugin/PasteHand
44
44
  const We = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0, Cr = We ? U : S, Q = { tag: de };
45
45
  function yr({ initialConfig: r, children: e }) {
46
46
  const t = q(() => {
47
- const { theme: n, namespace: a, nodes: o, onError: s, editorState: i, html: l } = r, u = Xe(null, n), c = Ie({ editable: r.editable, html: l, namespace: a, nodes: o, onError: (d) => s(d, c), theme: n });
47
+ const { theme: o, namespace: a, nodes: n, onError: s, editorState: i, html: l } = r, u = Xe(null, o), c = Ie({ editable: r.editable, html: l, namespace: a, nodes: n, onError: (d) => s(d, c), theme: o });
48
48
  return function(d, f) {
49
49
  if (f !== null) {
50
50
  if (f === void 0) d.update(() => {
51
51
  const v = A();
52
52
  if (v.isEmpty()) {
53
- const C = Me();
53
+ const C = Fe();
54
54
  v.append(C);
55
55
  const w = We ? document.activeElement : null;
56
56
  (p() !== null || w !== null && w === d.getRootElement()) && C.select();
@@ -74,8 +74,8 @@ function yr({ initialConfig: r, children: e }) {
74
74
  }(c, i), [c, u];
75
75
  }, []);
76
76
  return Cr(() => {
77
- const n = r.editable, [a] = t;
78
- a.setEditable(n === void 0 || n);
77
+ const o = r.editable, [a] = t;
78
+ a.setEditable(o === void 0 || o);
79
79
  }, []), h(Ye.Provider, { value: t, children: e });
80
80
  }
81
81
  const Er = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? U : S;
@@ -84,13 +84,13 @@ function wr(r) {
84
84
  }
85
85
  function br() {
86
86
  return function(r) {
87
- const [e] = T(), t = q(() => r(e), [e, r]), [n, a] = F(() => t.initialValueFn()), o = ze(n);
87
+ const [e] = T(), t = q(() => r(e), [e, r]), [o, a] = M(() => t.initialValueFn()), n = ze(o);
88
88
  return Er(() => {
89
89
  const { initialValueFn: s, subscribe: i } = t, l = s();
90
- return o.current !== l && (o.current = l, a(l)), i((u) => {
91
- o.current = u, a(u);
90
+ return n.current !== l && (n.current = l, a(l)), i((u) => {
91
+ n.current = u, a(u);
92
92
  });
93
- }, [t, r]), n;
93
+ }, [t, r]), o;
94
94
  }(wr);
95
95
  }
96
96
  function _r() {
@@ -105,15 +105,15 @@ function kr(r) {
105
105
  if (!Sr(r, !1)) return !1;
106
106
  const e = A().getChildren(), t = e.length;
107
107
  if (t > 1) return !1;
108
- for (let n = 0; n < t; n++) {
109
- const a = e[n];
108
+ for (let o = 0; o < t; o++) {
109
+ const a = e[o];
110
110
  if (J(a)) return !1;
111
111
  if (W(a)) {
112
112
  if (!Qe(a) || a.__indent !== 0) return !1;
113
- const o = a.getChildren(), s = o.length;
113
+ const n = a.getChildren(), s = n.length;
114
114
  for (let i = 0; i < s; i++) {
115
- const l = o[n];
116
- if (!M(l)) return !1;
115
+ const l = n[o];
116
+ if (!F(l)) return !1;
117
117
  }
118
118
  }
119
119
  }
@@ -123,15 +123,15 @@ function qe(r) {
123
123
  return () => kr(r);
124
124
  }
125
125
  function xr(r) {
126
- const e = window.location.origin, t = (n) => {
127
- if (n.origin !== e) return;
126
+ const e = window.location.origin, t = (o) => {
127
+ if (o.origin !== e) return;
128
128
  const a = r.getRootElement();
129
129
  if (document.activeElement !== a) return;
130
- const o = n.data;
131
- if (typeof o == "string") {
130
+ const n = o.data;
131
+ if (typeof n == "string") {
132
132
  let s;
133
133
  try {
134
- s = JSON.parse(o);
134
+ s = JSON.parse(n);
135
135
  } catch {
136
136
  return;
137
137
  }
@@ -146,12 +146,12 @@ function xr(r) {
146
146
  if (g(w)) {
147
147
  const x = w.anchor;
148
148
  let y = x.getNode(), E = 0, _ = 0;
149
- if (M(y) && u >= 0 && c >= 0 && (E = u, _ = u + c, w.setTextNodeRange(y, E, y, _)), E === _ && d === "" || (w.insertRawText(d), y = x.getNode()), M(y)) {
149
+ if (F(y) && u >= 0 && c >= 0 && (E = u, _ = u + c, w.setTextNodeRange(y, E, y, _)), E === _ && d === "" || (w.insertRawText(d), y = x.getNode()), F(y)) {
150
150
  E = f, _ = f + v;
151
151
  const N = y.getTextContentSize();
152
152
  E = E > N ? N : E, _ = _ > N ? N : _, w.setTextNodeRange(y, E, y, _);
153
153
  }
154
- n.stopImmediatePropagation();
154
+ o.stopImmediatePropagation();
155
155
  }
156
156
  });
157
157
  }
@@ -178,17 +178,17 @@ const j = typeof window < "u" && window.document !== void 0 && window.document.c
178
178
  function Z(r) {
179
179
  let e = null;
180
180
  if (z(r, DragEvent) ? e = r.dataTransfer : z(r, ClipboardEvent) && (e = r.clipboardData), e === null) return [!1, [], !1];
181
- const t = e.types, n = t.includes("Files"), a = t.includes("text/html") || t.includes("text/plain");
182
- return [n, Array.from(e.files), a];
181
+ const t = e.types, o = t.includes("Files"), a = t.includes("text/html") || t.includes("text/plain");
182
+ return [o, Array.from(e.files), a];
183
183
  }
184
184
  function xe(r) {
185
185
  const e = p();
186
186
  if (!g(e)) return !1;
187
- const t = /* @__PURE__ */ new Set(), n = e.getNodes();
188
- for (let a = 0; a < n.length; a++) {
189
- const o = n[a], s = o.getKey();
187
+ const t = /* @__PURE__ */ new Set(), o = e.getNodes();
188
+ for (let a = 0; a < o.length; a++) {
189
+ const n = o[a], s = n.getKey();
190
190
  if (t.has(s)) continue;
191
- const i = fe(o, (u) => W(u) && !u.isInline());
191
+ const i = fe(n, (u) => W(u) && !u.isInline());
192
192
  if (i === null) continue;
193
193
  const l = i.getKey();
194
194
  i.canIndent() && !t.has(l) && (t.add(l), r(i));
@@ -220,8 +220,8 @@ function Tr(r) {
220
220
  if (typeof e == "string") t !== null && t.insertText(e);
221
221
  else {
222
222
  if (t === null) return !1;
223
- const n = e.dataTransfer;
224
- if (n != null) Ce(n, t, r);
223
+ const o = e.dataTransfer;
224
+ if (o != null) Ce(o, t, r);
225
225
  else if (g(t)) {
226
226
  const a = e.data;
227
227
  return a && t.insertText(a), !0;
@@ -237,10 +237,10 @@ function Tr(r) {
237
237
  }, m), r.registerCommand(xt, (e) => {
238
238
  const t = p();
239
239
  if (!g(t) && !P(t)) return !1;
240
- const n = t.getNodes();
241
- for (const a of n) {
242
- const o = fe(a, (s) => W(s) && !s.isInline());
243
- o !== null && o.setFormat(e);
240
+ const o = t.getNodes();
241
+ for (const a of o) {
242
+ const n = fe(a, (s) => W(s) && !s.isInline());
243
+ n !== null && n.setFormat(e);
244
244
  }
245
245
  return !0;
246
246
  }, m), r.registerCommand(me, (e) => {
@@ -258,37 +258,37 @@ function Tr(r) {
258
258
  }), m), r.registerCommand(wt, (e) => {
259
259
  const t = p();
260
260
  if (P(t)) {
261
- const n = t.getNodes();
262
- if (n.length > 0) return n[0].selectPrevious(), !0;
261
+ const o = t.getNodes();
262
+ if (o.length > 0) return o[0].selectPrevious(), !0;
263
263
  } else if (g(t)) {
264
- const n = he(t.focus, !0);
265
- if (!e.shiftKey && J(n) && !n.isIsolated() && !n.isInline()) return n.selectPrevious(), e.preventDefault(), !0;
264
+ const o = he(t.focus, !0);
265
+ if (!e.shiftKey && J(o) && !o.isIsolated() && !o.isInline()) return o.selectPrevious(), e.preventDefault(), !0;
266
266
  }
267
267
  return !1;
268
268
  }, m), r.registerCommand(Et, (e) => {
269
269
  const t = p();
270
270
  if (P(t)) {
271
- const n = t.getNodes();
272
- if (n.length > 0) return n[0].selectNext(0, 0), !0;
271
+ const o = t.getNodes();
272
+ if (o.length > 0) return o[0].selectNext(0, 0), !0;
273
273
  } else if (g(t)) {
274
274
  if (function(a) {
275
- const o = a.focus;
276
- return o.key === "root" && o.offset === A().getChildrenSize();
275
+ const n = a.focus;
276
+ return n.key === "root" && n.offset === A().getChildrenSize();
277
277
  }(t)) return e.preventDefault(), !0;
278
- const n = he(t.focus, !1);
279
- if (!e.shiftKey && J(n) && !n.isIsolated() && !n.isInline()) return n.selectNext(), e.preventDefault(), !0;
278
+ const o = he(t.focus, !1);
279
+ if (!e.shiftKey && J(o) && !o.isIsolated() && !o.isInline()) return o.selectNext(), e.preventDefault(), !0;
280
280
  }
281
281
  return !1;
282
282
  }, m), r.registerCommand(yt, (e) => {
283
283
  const t = p();
284
284
  if (P(t)) {
285
- const n = t.getNodes();
286
- if (n.length > 0) return e.preventDefault(), n[0].selectPrevious(), !0;
285
+ const o = t.getNodes();
286
+ if (o.length > 0) return e.preventDefault(), o[0].selectPrevious(), !0;
287
287
  }
288
288
  if (!g(t)) return !1;
289
289
  if (Ee(t, !0)) {
290
- const n = e.shiftKey;
291
- return e.preventDefault(), we(t, n, !0), !0;
290
+ const o = e.shiftKey;
291
+ return e.preventDefault(), we(t, o, !0), !0;
292
292
  }
293
293
  return !1;
294
294
  }, m), r.registerCommand(Ct, (e) => {
@@ -298,15 +298,21 @@ function Tr(r) {
298
298
  if (a.length > 0) return e.preventDefault(), a[0].selectNext(0, 0), !0;
299
299
  }
300
300
  if (!g(t)) return !1;
301
- const n = e.shiftKey;
302
- return !!Ee(t, !1) && (e.preventDefault(), we(t, n, !1), !0);
301
+ const o = e.shiftKey;
302
+ return !!Ee(t, !1) && (e.preventDefault(), we(t, o, !1), !0);
303
303
  }, m), r.registerCommand(vt, (e) => {
304
304
  if (Ne(e.target)) return !1;
305
305
  const t = p();
306
306
  if (g(t)) {
307
- const { anchor: n } = t, a = n.getNode();
308
- if (t.isCollapsed() && n.offset === 0 && !Ke(a) && Ut(a).getIndent() > 0)
309
- return e.preventDefault(), r.dispatchCommand(ge, void 0);
307
+ if (function(o) {
308
+ if (!o.isCollapsed()) return !1;
309
+ const { anchor: a } = o;
310
+ if (a.offset !== 0) return !1;
311
+ const n = a.getNode();
312
+ if (Ke(n)) return !1;
313
+ const s = Ut(n);
314
+ return s.getIndent() > 0 && (s.is(n) || n.is(s.getFirstDescendant()));
315
+ }(t)) return e.preventDefault(), r.dispatchCommand(ge, void 0);
310
316
  if (Se && navigator.language === "ko-KR") return !1;
311
317
  } else if (!P(t)) return !1;
312
318
  return e.preventDefault(), r.dispatchCommand(re, !0);
@@ -330,10 +336,10 @@ function Tr(r) {
330
336
  if (t.length > 0) {
331
337
  const a = _e(e.clientX, e.clientY);
332
338
  if (a !== null) {
333
- const { offset: o, node: s } = a, i = te(s);
339
+ const { offset: n, node: s } = a, i = te(s);
334
340
  if (i !== null) {
335
341
  const l = dt();
336
- if (M(i)) l.anchor.set(i.getKey(), o, "text"), l.focus.set(i.getKey(), o, "text");
342
+ if (F(i)) l.anchor.set(i.getKey(), n, "text"), l.focus.set(i.getKey(), n, "text");
337
343
  else {
338
344
  const c = i.getParentOrThrow().getKey(), d = i.getIndexWithinParent() + 1;
339
345
  l.anchor.set(c, d, "element"), l.focus.set(c, d, "element");
@@ -345,31 +351,31 @@ function Tr(r) {
345
351
  }
346
352
  return e.preventDefault(), !0;
347
353
  }
348
- const n = p();
349
- return !!g(n);
354
+ const o = p();
355
+ return !!g(o);
350
356
  }, m), r.registerCommand(ut, (e) => {
351
- const [t] = Z(e), n = p();
352
- return !(t && !g(n));
357
+ const [t] = Z(e), o = p();
358
+ return !(t && !g(o));
353
359
  }, m), r.registerCommand(lt, (e) => {
354
- const [t] = Z(e), n = p();
355
- if (t && !g(n)) return !1;
360
+ const [t] = Z(e), o = p();
361
+ if (t && !g(o)) return !1;
356
362
  const a = _e(e.clientX, e.clientY);
357
363
  if (a !== null) {
358
- const o = te(a.node);
359
- J(o) && e.preventDefault();
364
+ const n = te(a.node);
365
+ J(n) && e.preventDefault();
360
366
  }
361
367
  return !0;
362
- }, m), r.registerCommand(st, () => (it(), !0), m), r.registerCommand(at, (e) => (ye(r, z(e, ClipboardEvent) ? e : null), !0), m), r.registerCommand(ot, (e) => (async function(t, n) {
363
- await ye(n, z(t, ClipboardEvent) ? t : null), n.update(() => {
368
+ }, m), r.registerCommand(st, () => (it(), !0), m), r.registerCommand(at, (e) => (ye(r, z(e, ClipboardEvent) ? e : null), !0), m), r.registerCommand(ot, (e) => (async function(t, o) {
369
+ await ye(o, z(t, ClipboardEvent) ? t : null), o.update(() => {
364
370
  const a = p();
365
- g(a) ? a.removeText() : P(a) && a.getNodes().forEach((o) => o.remove());
371
+ g(a) ? a.removeText() : P(a) && a.getNodes().forEach((n) => n.remove());
366
372
  });
367
- }(e, r), !0), m), r.registerCommand(Fe, (e) => {
368
- const [, t, n] = Z(e);
369
- return t.length > 0 && !n ? (r.dispatchCommand(ke, t), !0) : Oe(e.target) && rt(e.target) ? !1 : p() !== null && (function(a, o) {
370
- a.preventDefault(), o.update(() => {
373
+ }(e, r), !0), m), r.registerCommand(Me, (e) => {
374
+ const [, t, o] = Z(e);
375
+ return t.length > 0 && !o ? (r.dispatchCommand(ke, t), !0) : Oe(e.target) && rt(e.target) ? !1 : p() !== null && (function(a, n) {
376
+ a.preventDefault(), n.update(() => {
371
377
  const s = p(), i = z(a, InputEvent) || z(a, KeyboardEvent) ? null : a.clipboardData;
372
- i != null && s !== null && Ce(i, s, o);
378
+ i != null && s !== null && Ce(i, s, n);
373
379
  }, { tag: nt });
374
380
  }(e, r), !0);
375
381
  }, m), r.registerCommand(et, (e) => {
@@ -385,30 +391,30 @@ function Le(r) {
385
391
  return r.getEditorState().read(qe(r.isComposing()));
386
392
  }
387
393
  function Rr({ contentEditable: r, placeholder: e = null, ErrorBoundary: t }) {
388
- const [n] = T(), a = function(o, s) {
389
- const [i, l] = F(() => o.getDecorators());
390
- return ie(() => o.registerDecoratorListener((u) => {
394
+ const [o] = T(), a = function(n, s) {
395
+ const [i, l] = M(() => n.getDecorators());
396
+ return ie(() => n.registerDecoratorListener((u) => {
391
397
  Ht(() => {
392
398
  l(u);
393
399
  });
394
- }), [o]), S(() => {
395
- l(o.getDecorators());
396
- }, [o]), q(() => {
400
+ }), [n]), S(() => {
401
+ l(n.getDecorators());
402
+ }, [n]), q(() => {
397
403
  const u = [], c = Object.keys(i);
398
404
  for (let d = 0; d < c.length; d++) {
399
- const f = c[d], v = h(s, { onError: (w) => o._onError(w), children: h(At, { fallback: null, children: i[f] }) }), C = o.getElementByKey(f);
405
+ const f = c[d], v = h(s, { onError: (w) => n._onError(w), children: h(At, { fallback: null, children: i[f] }) }), C = n.getElementByKey(f);
400
406
  C !== null && u.push(jt(v, C, f));
401
407
  }
402
408
  return u;
403
- }, [s, i, o]);
404
- }(n, t);
405
- return function(o) {
406
- ie(() => H(Tr(o), xr(o)), [o]);
407
- }(n), K(Re, { children: [r, h(Ir, { content: e }), a] });
409
+ }, [s, i, n]);
410
+ }(o, t);
411
+ return function(n) {
412
+ ie(() => H(Tr(n), xr(n)), [n]);
413
+ }(o), K(Re, { children: [r, h(Ir, { content: e }), a] });
408
414
  }
409
415
  function Ir({ content: r }) {
410
416
  const [e] = T(), t = function(a) {
411
- const [o, s] = F(() => Le(a));
417
+ const [n, s] = M(() => Le(a));
412
418
  return ie(() => {
413
419
  function i() {
414
420
  const l = Le(a);
@@ -419,13 +425,13 @@ function Ir({ content: r }) {
419
425
  }), a.registerEditableListener(() => {
420
426
  i();
421
427
  }));
422
- }, [a]), o;
423
- }(e), n = br();
424
- return t ? typeof r == "function" ? r(n) : r : null;
428
+ }, [a]), n;
429
+ }(e), o = br();
430
+ return t ? typeof r == "function" ? r(o) : r : null;
425
431
  }
426
432
  const Ve = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? U : S;
427
- function Mr({ editor: r, ariaActiveDescendant: e, ariaAutoComplete: t, ariaControls: n, ariaDescribedBy: a, ariaErrorMessage: o, ariaExpanded: s, ariaInvalid: i, ariaLabel: l, ariaLabelledBy: u, ariaMultiline: c, ariaOwns: d, ariaRequired: f, autoCapitalize: v, className: C, id: w, role: x = "textbox", spellCheck: y = !0, style: E, tabIndex: _, "data-testid": N, ...b }, L) {
428
- const [k, R] = F(r.isEditable()), O = Bt((D) => {
433
+ function Fr({ editor: r, ariaActiveDescendant: e, ariaAutoComplete: t, ariaControls: o, ariaDescribedBy: a, ariaErrorMessage: n, ariaExpanded: s, ariaInvalid: i, ariaLabel: l, ariaLabelledBy: u, ariaMultiline: c, ariaOwns: d, ariaRequired: f, autoCapitalize: v, className: C, id: w, role: x = "textbox", spellCheck: y = !0, style: E, tabIndex: _, "data-testid": N, ...b }, L) {
434
+ const [k, R] = M(r.isEditable()), O = Bt((D) => {
429
435
  D && D.ownerDocument && D.ownerDocument.defaultView ? r.setRootElement(D) : r.setRootElement(null);
430
436
  }, [r]), B = q(() => /* @__PURE__ */ function(...D) {
431
437
  return (V) => {
@@ -436,20 +442,20 @@ function Mr({ editor: r, ariaActiveDescendant: e, ariaAutoComplete: t, ariaContr
436
442
  }(L, O), [O, L]);
437
443
  return Ve(() => (R(r.isEditable()), r.registerEditableListener((D) => {
438
444
  R(D);
439
- })), [r]), h("div", { "aria-activedescendant": k ? e : void 0, "aria-autocomplete": k ? t : "none", "aria-controls": k ? n : void 0, "aria-describedby": a, ...o != null ? { "aria-errormessage": o } : {}, "aria-expanded": k && x === "combobox" ? !!s : void 0, ...i != null ? { "aria-invalid": i } : {}, "aria-label": l, "aria-labelledby": u, "aria-multiline": c, "aria-owns": k ? d : void 0, "aria-readonly": !k || void 0, "aria-required": f, autoCapitalize: v, className: C, contentEditable: k, "data-testid": N, id: w, ref: B, role: k ? x : void 0, spellCheck: y, style: E, tabIndex: _, ...b });
445
+ })), [r]), h("div", { "aria-activedescendant": k ? e : void 0, "aria-autocomplete": k ? t : "none", "aria-controls": k ? o : void 0, "aria-describedby": a, ...n != null ? { "aria-errormessage": n } : {}, "aria-expanded": k && x === "combobox" ? !!s : void 0, ...i != null ? { "aria-invalid": i } : {}, "aria-label": l, "aria-labelledby": u, "aria-multiline": c, "aria-owns": k ? d : void 0, "aria-readonly": !k || void 0, "aria-required": f, autoCapitalize: v, className: C, contentEditable: k, "data-testid": N, id: w, ref: B, role: k ? x : void 0, spellCheck: y, style: E, tabIndex: _, ...b });
440
446
  }
441
- const Fr = Ae(Mr);
447
+ const Mr = Ae(Fr);
442
448
  function De(r) {
443
449
  return r.getEditorState().read(qe(r.isComposing()));
444
450
  }
445
451
  const Or = Ae(Kr);
446
452
  function Kr(r, e) {
447
- const { placeholder: t, ...n } = r, [a] = T();
448
- return K(Re, { children: [h(Fr, { editor: a, ...n, ref: e }), t != null && h(zr, { editor: a, content: t })] });
453
+ const { placeholder: t, ...o } = r, [a] = T();
454
+ return K(Re, { children: [h(Mr, { editor: a, ...o, ref: e }), t != null && h(zr, { editor: a, content: t })] });
449
455
  }
450
456
  function zr({ content: r, editor: e }) {
451
457
  const t = function(s) {
452
- const [i, l] = F(() => De(s));
458
+ const [i, l] = M(() => De(s));
453
459
  return Ve(() => {
454
460
  function u() {
455
461
  const c = De(s);
@@ -461,64 +467,64 @@ function zr({ content: r, editor: e }) {
461
467
  u();
462
468
  }));
463
469
  }, [s]), i;
464
- }(e), [n, a] = F(e.isEditable());
470
+ }(e), [o, a] = M(e.isEditable());
465
471
  if (U(() => (a(e.isEditable()), e.registerEditableListener((s) => {
466
472
  a(s);
467
473
  })), [e]), !t) return null;
468
- let o = null;
469
- return typeof r == "function" ? o = r(n) : r !== null && (o = r), o === null ? null : h("div", { "aria-hidden": !0, children: o });
474
+ let n = null;
475
+ return typeof r == "function" ? n = r(o) : r !== null && (n = r), n === null ? null : h("div", { "aria-hidden": !0, children: n });
470
476
  }
471
477
  function le(r, e) {
472
- return le = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t, n) {
473
- return t.__proto__ = n, t;
478
+ return le = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t, o) {
479
+ return t.__proto__ = o, t;
474
480
  }, le(r, e);
475
481
  }
476
482
  var $e = { error: null }, Ar = function(r) {
477
483
  var e, t;
478
- function n() {
479
- for (var o, s = arguments.length, i = new Array(s), l = 0; l < s; l++) i[l] = arguments[l];
480
- return (o = r.call.apply(r, [this].concat(i)) || this).state = $e, o.resetErrorBoundary = function() {
484
+ function o() {
485
+ for (var n, s = arguments.length, i = new Array(s), l = 0; l < s; l++) i[l] = arguments[l];
486
+ return (n = r.call.apply(r, [this].concat(i)) || this).state = $e, n.resetErrorBoundary = function() {
481
487
  for (var u, c = arguments.length, d = new Array(c), f = 0; f < c; f++) d[f] = arguments[f];
482
- o.props.onReset == null || (u = o.props).onReset.apply(u, d), o.reset();
483
- }, o;
488
+ n.props.onReset == null || (u = n.props).onReset.apply(u, d), n.reset();
489
+ }, n;
484
490
  }
485
- t = r, (e = n).prototype = Object.create(t.prototype), e.prototype.constructor = e, le(e, t), n.getDerivedStateFromError = function(o) {
486
- return { error: o };
491
+ t = r, (e = o).prototype = Object.create(t.prototype), e.prototype.constructor = e, le(e, t), o.getDerivedStateFromError = function(n) {
492
+ return { error: n };
487
493
  };
488
- var a = n.prototype;
494
+ var a = o.prototype;
489
495
  return a.reset = function() {
490
496
  this.setState($e);
491
- }, a.componentDidCatch = function(o, s) {
497
+ }, a.componentDidCatch = function(n, s) {
492
498
  var i, l;
493
- (i = (l = this.props).onError) == null || i.call(l, o, s);
494
- }, a.componentDidUpdate = function(o, s) {
499
+ (i = (l = this.props).onError) == null || i.call(l, n, s);
500
+ }, a.componentDidUpdate = function(n, s) {
495
501
  var i, l, u, c, d = this.state.error, f = this.props.resetKeys;
496
- d !== null && s.error !== null && ((u = o.resetKeys) === void 0 && (u = []), (c = f) === void 0 && (c = []), u.length !== c.length || u.some(function(v, C) {
502
+ d !== null && s.error !== null && ((u = n.resetKeys) === void 0 && (u = []), (c = f) === void 0 && (c = []), u.length !== c.length || u.some(function(v, C) {
497
503
  return !Object.is(v, c[C]);
498
- })) && ((i = (l = this.props).onResetKeysChange) == null || i.call(l, o.resetKeys, f), this.reset());
504
+ })) && ((i = (l = this.props).onResetKeysChange) == null || i.call(l, n.resetKeys, f), this.reset());
499
505
  }, a.render = function() {
500
- var o = this.state.error, s = this.props, i = s.fallbackRender, l = s.FallbackComponent, u = s.fallback;
501
- if (o !== null) {
502
- var c = { error: o, resetErrorBoundary: this.resetErrorBoundary };
506
+ var n = this.state.error, s = this.props, i = s.fallbackRender, l = s.FallbackComponent, u = s.fallback;
507
+ if (n !== null) {
508
+ var c = { error: n, resetErrorBoundary: this.resetErrorBoundary };
503
509
  if (ne.isValidElement(u)) return u;
504
510
  if (typeof i == "function") return i(c);
505
511
  if (l) return ne.createElement(l, c);
506
512
  throw new Error("react-error-boundary requires either a fallback, fallbackRender, or FallbackComponent prop");
507
513
  }
508
514
  return this.props.children;
509
- }, n;
515
+ }, o;
510
516
  }(ne.Component);
511
517
  function Br({ children: r, onError: e }) {
512
518
  return h(Ar, { fallback: h("div", { style: { border: "1px solid #f00", color: "#f00", padding: "8px" }, children: "An error was thrown." }), onError: e, children: r });
513
519
  }
514
520
  const Ur = typeof window < "u" && window.document !== void 0 && window.document.createElement !== void 0 ? U : S;
515
521
  function Hr({ ignoreHistoryMergeTagChange: r = !0, ignoreSelectionChange: e = !1, onChange: t }) {
516
- const [n] = T();
522
+ const [o] = T();
517
523
  return Ur(() => {
518
- if (t) return n.registerUpdateListener(({ editorState: a, dirtyElements: o, dirtyLeaves: s, prevEditorState: i, tags: l }) => {
519
- e && o.size === 0 && s.size === 0 || r && l.has(de) || i.isEmpty() || t(a, n, l);
524
+ if (t) return o.registerUpdateListener(({ editorState: a, dirtyElements: n, dirtyLeaves: s, prevEditorState: i, tags: l }) => {
525
+ e && n.size === 0 && s.size === 0 || r && l.has(de) || i.isEmpty() || t(a, o, l);
520
526
  });
521
- }, [n, r, e, t]), null;
527
+ }, [o, r, e, t]), null;
522
528
  }
523
529
  function jr({ hasStrictIndent: r = !1 }) {
524
530
  const [e] = T();
@@ -534,18 +540,18 @@ function Jr({ validateUrl: r, attributes: e }) {
534
540
  const [t] = T();
535
541
  return S(() => {
536
542
  if (!t.hasNodes([He])) throw new Error("LinkPlugin: LinkNode not registered on editor");
537
- return H(t.registerCommand(be, (n) => {
538
- if (n === null) return oe(n), !0;
539
- if (typeof n == "string") return !(r !== void 0 && !r(n)) && (oe(n, e), !0);
543
+ return H(t.registerCommand(be, (o) => {
544
+ if (o === null) return oe(o), !0;
545
+ if (typeof o == "string") return !(r !== void 0 && !r(o)) && (oe(o, e), !0);
540
546
  {
541
- const { url: a, target: o, rel: s, title: i } = n;
542
- return oe(a, { ...e, rel: s, target: o, title: i }), !0;
547
+ const { url: a, target: n, rel: s, title: i } = o;
548
+ return oe(a, { ...e, rel: s, target: n, title: i }), !0;
543
549
  }
544
- }, ve), r !== void 0 ? t.registerCommand(Fe, (n) => {
550
+ }, ve), r !== void 0 ? t.registerCommand(Me, (o) => {
545
551
  const a = p();
546
- if (!g(a) || a.isCollapsed() || !z(n, ClipboardEvent) || n.clipboardData === null) return !1;
547
- const o = n.clipboardData.getData("text");
548
- return !!r(o) && !a.getNodes().some((s) => W(s)) && (t.dispatchCommand(be, { ...e, url: o }), n.preventDefault(), !0);
552
+ if (!g(a) || a.isCollapsed() || !z(o, ClipboardEvent) || o.clipboardData === null) return !1;
553
+ const n = o.clipboardData.getData("text");
554
+ return !!r(n) && !a.getNodes().some((s) => W(s)) && (t.dispatchCommand(be, { ...e, url: n }), o.preventDefault(), !0);
549
555
  }, ve) : () => {
550
556
  });
551
557
  }, [t, r, e]), null;
@@ -553,8 +559,8 @@ function Jr({ validateUrl: r, attributes: e }) {
553
559
  function Wr({ newTab: r = !0, disabled: e = !1 }) {
554
560
  const [t] = T();
555
561
  return S(() => {
556
- const n = (o) => {
557
- const s = o.target;
562
+ const o = (n) => {
563
+ const s = n.target;
558
564
  if (!Oe(s)) return;
559
565
  const i = Rt(s);
560
566
  if (i === null) return;
@@ -578,23 +584,23 @@ function Wr({ newTab: r = !0, disabled: e = !1 }) {
578
584
  }
579
585
  }), l === null || l === "") return;
580
586
  const c = t.getEditorState().read(p);
581
- if (g(c) && !c.isCollapsed()) return void o.preventDefault();
582
- const d = o.type === "auxclick" && o.button === 1;
583
- window.open(l, r || d || o.metaKey || o.ctrlKey || u === "_blank" ? "_blank" : "_self"), o.preventDefault();
584
- }, a = (o) => {
585
- o.button === 1 && n(o);
587
+ if (g(c) && !c.isCollapsed()) return void n.preventDefault();
588
+ const d = n.type === "auxclick" && n.button === 1;
589
+ window.open(l, r || d || n.metaKey || n.ctrlKey || u === "_blank" ? "_blank" : "_self"), n.preventDefault();
590
+ }, a = (n) => {
591
+ n.button === 1 && o(n);
586
592
  };
587
- return t.registerRootListener((o, s) => {
588
- s !== null && (s.removeEventListener("click", n), s.removeEventListener("mouseup", a)), o !== null && (o.addEventListener("click", n), o.addEventListener("mouseup", a));
593
+ return t.registerRootListener((n, s) => {
594
+ s !== null && (s.removeEventListener("click", o), s.removeEventListener("mouseup", a)), n !== null && (n.addEventListener("click", o), n.addEventListener("mouseup", a));
589
595
  });
590
596
  }, [t, r, e]), null;
591
597
  }
592
598
  const ee = 0, ue = 1, ce = 2, $ = 0, qr = 1, Pe = 2, Vr = 3, Gr = 4;
593
- function Xr(r, e, t, n, a) {
594
- if (r === null || t.size === 0 && n.size === 0 && !a) return $;
595
- const o = e._selection, s = r._selection;
599
+ function Xr(r, e, t, o, a) {
600
+ if (r === null || t.size === 0 && o.size === 0 && !a) return $;
601
+ const n = e._selection, s = r._selection;
596
602
  if (a) return qr;
597
- if (!(g(o) && g(s) && s.isCollapsed() && o.isCollapsed())) return $;
603
+ if (!(g(n) && g(s) && s.isCollapsed() && n.isCollapsed())) return $;
598
604
  const i = function(y, E, _) {
599
605
  const N = y._nodeMap, b = [];
600
606
  for (const L of E) {
@@ -607,65 +613,65 @@ function Xr(r, e, t, n, a) {
607
613
  R === void 0 || Ke(R) || b.push(R);
608
614
  }
609
615
  return b;
610
- }(e, t, n);
616
+ }(e, t, o);
611
617
  if (i.length === 0) return $;
612
618
  if (i.length > 1) {
613
- const y = e._nodeMap, E = y.get(o.anchor.key), _ = y.get(s.anchor.key);
614
- return E && _ && !r._nodeMap.has(E.__key) && M(E) && E.__text.length === 1 && o.anchor.offset === 1 ? Pe : $;
619
+ const y = e._nodeMap, E = y.get(n.anchor.key), _ = y.get(s.anchor.key);
620
+ return E && _ && !r._nodeMap.has(E.__key) && F(E) && E.__text.length === 1 && n.anchor.offset === 1 ? Pe : $;
615
621
  }
616
622
  const l = i[0], u = r._nodeMap.get(l.__key);
617
- if (!M(u) || !M(l) || u.__mode !== l.__mode) return $;
623
+ if (!F(u) || !F(l) || u.__mode !== l.__mode) return $;
618
624
  const c = u.__text, d = l.__text;
619
625
  if (c === d) return $;
620
- const f = o.anchor, v = s.anchor;
626
+ const f = n.anchor, v = s.anchor;
621
627
  if (f.key !== v.key || f.type !== "text") return $;
622
628
  const C = f.offset, w = v.offset, x = d.length - c.length;
623
629
  return x === 1 && w === C - 1 ? Pe : x === -1 && w === C + 1 ? Vr : x === -1 && w === C ? Gr : $;
624
630
  }
625
631
  function Yr(r, e) {
626
- let t = Date.now(), n = $;
627
- return (a, o, s, i, l, u) => {
632
+ let t = Date.now(), o = $;
633
+ return (a, n, s, i, l, u) => {
628
634
  const c = Date.now();
629
- if (u.has(se)) return n = $, t = c, ce;
630
- const d = Xr(a, o, i, l, r.isComposing()), f = (() => {
635
+ if (u.has(se)) return o = $, t = c, ce;
636
+ const d = Xr(a, n, i, l, r.isComposing()), f = (() => {
631
637
  const v = s === null || s.editor === r, C = u.has(zt);
632
638
  if (!C && v && u.has(de)) return ee;
633
639
  if (a === null) return ue;
634
- const w = o._selection;
635
- return i.size > 0 || l.size > 0 ? C === !1 && d !== $ && d === n && c < t + e && v || i.size === 1 && function(x, y, E) {
640
+ const w = n._selection;
641
+ return i.size > 0 || l.size > 0 ? C === !1 && d !== $ && d === o && c < t + e && v || i.size === 1 && function(x, y, E) {
636
642
  const _ = y._nodeMap.get(x), N = E._nodeMap.get(x), b = y._selection, L = E._selection;
637
- return !(g(b) && g(L) && b.anchor.type === "element" && b.focus.type === "element" && L.anchor.type === "text" && L.focus.type === "text" || !M(_) || !M(N) || _.__parent !== N.__parent) && JSON.stringify(y.read(() => _.exportJSON())) === JSON.stringify(E.read(() => N.exportJSON()));
638
- }(Array.from(i)[0], a, o) ? ee : ue : w !== null ? ee : ce;
643
+ return !(g(b) && g(L) && b.anchor.type === "element" && b.focus.type === "element" && L.anchor.type === "text" && L.focus.type === "text" || !F(_) || !F(N) || _.__parent !== N.__parent) && JSON.stringify(y.read(() => _.exportJSON())) === JSON.stringify(E.read(() => N.exportJSON()));
644
+ }(Array.from(i)[0], a, n) ? ee : ue : w !== null ? ee : ce;
639
645
  })();
640
- return t = c, n = d, f;
646
+ return t = c, o = d, f;
641
647
  };
642
648
  }
643
649
  function Te(r) {
644
650
  r.undoStack = [], r.redoStack = [], r.current = null;
645
651
  }
646
652
  function Qr(r, e, t) {
647
- const n = Yr(r, t);
648
- return H(r.registerCommand(Kt, () => (function(o, s) {
653
+ const o = Yr(r, t);
654
+ return H(r.registerCommand(Kt, () => (function(n, s) {
649
655
  const i = s.redoStack, l = s.undoStack;
650
656
  if (l.length !== 0) {
651
657
  const u = s.current, c = l.pop();
652
- u !== null && (i.push(u), o.dispatchCommand(X, !0)), l.length === 0 && o.dispatchCommand(Y, !1), s.current = c || null, c && c.editor.setEditorState(c.editorState, { tag: se });
658
+ u !== null && (i.push(u), n.dispatchCommand(X, !0)), l.length === 0 && n.dispatchCommand(Y, !1), s.current = c || null, c && c.editor.setEditorState(c.editorState, { tag: se });
653
659
  }
654
- }(r, e), !0), m), r.registerCommand(Ot, () => (function(o, s) {
660
+ }(r, e), !0), m), r.registerCommand(Ot, () => (function(n, s) {
655
661
  const i = s.redoStack, l = s.undoStack;
656
662
  if (i.length !== 0) {
657
663
  const u = s.current;
658
- u !== null && (l.push(u), o.dispatchCommand(Y, !0));
664
+ u !== null && (l.push(u), n.dispatchCommand(Y, !0));
659
665
  const c = i.pop();
660
- i.length === 0 && o.dispatchCommand(X, !1), s.current = c || null, c && c.editor.setEditorState(c.editorState, { tag: se });
666
+ i.length === 0 && n.dispatchCommand(X, !1), s.current = c || null, c && c.editor.setEditorState(c.editorState, { tag: se });
661
667
  }
662
- }(r, e), !0), m), r.registerCommand(Ft, () => (Te(e), !1), m), r.registerCommand(Mt, () => (Te(e), r.dispatchCommand(X, !1), r.dispatchCommand(Y, !1), !0), m), r.registerUpdateListener(({ editorState: o, prevEditorState: s, dirtyLeaves: i, dirtyElements: l, tags: u }) => {
668
+ }(r, e), !0), m), r.registerCommand(Mt, () => (Te(e), !1), m), r.registerCommand(Ft, () => (Te(e), r.dispatchCommand(X, !1), r.dispatchCommand(Y, !1), !0), m), r.registerUpdateListener(({ editorState: n, prevEditorState: s, dirtyLeaves: i, dirtyElements: l, tags: u }) => {
663
669
  const c = e.current, d = e.redoStack, f = e.undoStack, v = c === null ? null : c.editorState;
664
- if (c !== null && o === v) return;
665
- const C = n(s, o, c, i, l, u);
670
+ if (c !== null && n === v) return;
671
+ const C = o(s, n, c, i, l, u);
666
672
  if (C === ue) d.length !== 0 && (e.redoStack = [], r.dispatchCommand(X, !1)), c !== null && (f.push({ ...c }), r.dispatchCommand(Y, !0));
667
673
  else if (C === ce) return;
668
- e.current = { editor: r, editorState: o };
674
+ e.current = { editor: r, editorState: n };
669
675
  }));
670
676
  }
671
677
  function Zr() {
@@ -673,21 +679,21 @@ function Zr() {
673
679
  }
674
680
  function en({ delay: r, externalHistoryState: e }) {
675
681
  const [t] = T();
676
- return function(n, a, o = 1e3) {
682
+ return function(o, a, n = 1e3) {
677
683
  const s = q(() => a || Zr(), [a]);
678
- S(() => Qr(n, s, o), [o, n, s]);
684
+ S(() => Qr(o, s, n), [n, o, s]);
679
685
  }(t, e, r), null;
680
686
  }
681
- function tn({ hasCellMerge: r = !0, hasCellBackgroundColor: e = !0, hasTabHandler: t = !0, hasHorizontalScroll: n = !1 }) {
687
+ function tn({ hasCellMerge: r = !0, hasCellBackgroundColor: e = !0, hasTabHandler: t = !0, hasHorizontalScroll: o = !1 }) {
682
688
  const [a] = T();
683
689
  return S(() => {
684
- Yt(a) !== n && (Qt(a, n), a.registerNodeTransform(je, () => {
690
+ Yt(a) !== o && (Qt(a, o), a.registerNodeTransform(je, () => {
685
691
  })());
686
- }, [a, n]), S(() => Zt(a), [a]), S(() => er(a, t), [a, t]), S(() => {
692
+ }, [a, o]), S(() => Zt(a), [a]), S(() => er(a, t), [a, t]), S(() => {
687
693
  if (!r) return tr(a);
688
694
  }, [a, r]), S(() => {
689
- if (!e) return a.registerNodeTransform(Je, (o) => {
690
- o.getBackgroundColor() !== null && o.setBackgroundColor(null);
695
+ if (!e) return a.registerNodeTransform(Je, (n) => {
696
+ n.getBackgroundColor() !== null && n.setBackgroundColor(null);
691
697
  });
692
698
  }, [a, e, r]), null;
693
699
  }
@@ -695,15 +701,15 @@ const Ge = 200, rn = ({
695
701
  currentLanguage: r = "NL",
696
702
  initialValue: e = "",
697
703
  placeholder: t = "",
698
- label: n = "",
704
+ label: o = "",
699
705
  info: a = "",
700
- required: o = !1,
706
+ required: n = !1,
701
707
  notValidatedText: s = "",
702
708
  maxHeightInRem: i = "20rem",
703
709
  maxWords: l = Ge,
704
710
  onChange: u
705
711
  }) => {
706
- const { switchLanguage: c } = hr(), d = dr(), [f] = F(() => Ie()), [v, C] = F(0), [w, x] = F(0), y = ze(null), E = {
712
+ const { switchLanguage: c } = hr(), d = dr(), [f] = M(() => Ie()), [v, C] = M(0), [w, x] = M(0), y = ze(null), E = {
707
713
  html: {
708
714
  export: ir
709
715
  },
@@ -721,7 +727,7 @@ const Ge = 200, rn = ({
721
727
  O.append(B);
722
728
  });
723
729
  else {
724
- const B = Me();
730
+ const B = Fe();
725
731
  R.forEach((D, V) => {
726
732
  V === 0 ? (B.append(D), O.append(B)) : O.append(D);
727
733
  });
@@ -740,7 +746,7 @@ const Ge = 200, rn = ({
740
746
  C(_(b));
741
747
  }, []), /* @__PURE__ */ K("div", { className: I.editor__container, children: [
742
748
  /* @__PURE__ */ K("div", { className: I.editor__header, children: [
743
- /* @__PURE__ */ h(pr, { label: n, info: a, required: o }),
749
+ /* @__PURE__ */ h(pr, { label: o, info: a, required: n }),
744
750
  /* @__PURE__ */ K("div", { className: I["editor__header-word-count"], children: [
745
751
  /* @__PURE__ */ h("span", { className: sr({ [I["editor__header-word-count--alert"]]: v > l }), children: v }),
746
752
  " / ",
@@ -788,9 +794,9 @@ const Ge = 200, rn = ({
788
794
  currentLanguage: r = "NL",
789
795
  initialValue: e = "",
790
796
  placeholder: t = "",
791
- label: n = "",
797
+ label: o = "",
792
798
  info: a = "",
793
- required: o = !1,
799
+ required: n = !1,
794
800
  notValidatedText: s = "",
795
801
  maxWords: i = Ge,
796
802
  onChange: l
@@ -800,9 +806,9 @@ const Ge = 200, rn = ({
800
806
  currentLanguage: r,
801
807
  initialValue: e,
802
808
  placeholder: t,
803
- label: n,
809
+ label: o,
804
810
  info: a,
805
- required: o,
811
+ required: n,
806
812
  notValidatedText: s,
807
813
  maxWords: i,
808
814
  onChange: l