@dialpad/dialtone 9.172.0 → 9.174.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. package/README.md +8 -8
  2. package/dist/css/dialtone-default-theme.css +14 -8
  3. package/dist/css/dialtone-default-theme.min.css +1 -1
  4. package/dist/css/dialtone.css +14 -8
  5. package/dist/css/dialtone.min.css +1 -1
  6. package/dist/tokens/doc.json +101425 -101425
  7. package/dist/vue3/lib/loader/loader.cjs +10 -2
  8. package/dist/vue3/lib/loader/loader.cjs.map +1 -1
  9. package/dist/vue3/lib/loader/loader.js +34 -16
  10. package/dist/vue3/lib/loader/loader.js.map +1 -1
  11. package/dist/vue3/lib/message-input/message-input.cjs +1 -1
  12. package/dist/vue3/lib/message-input/message-input.cjs.map +1 -1
  13. package/dist/vue3/lib/message-input/message-input.js +2 -1
  14. package/dist/vue3/lib/message-input/message-input.js.map +1 -1
  15. package/dist/vue3/lib/rich-text-editor/rich-text-editor.cjs +4 -4
  16. package/dist/vue3/lib/rich-text-editor/rich-text-editor.cjs.map +1 -1
  17. package/dist/vue3/lib/rich-text-editor/rich-text-editor.js +675 -564
  18. package/dist/vue3/lib/rich-text-editor/rich-text-editor.js.map +1 -1
  19. package/dist/vue3/types/components/loader/loader.vue.d.ts.map +1 -1
  20. package/dist/vue3/types/components/rich_text_editor/extensions/div/div.d.ts.map +1 -1
  21. package/dist/vue3/types/components/rich_text_editor/extensions/table/table.d.ts +5 -0
  22. package/dist/vue3/types/components/rich_text_editor/extensions/table/table.d.ts.map +1 -0
  23. package/dist/vue3/types/components/rich_text_editor/extensions/text_style/text_style.d.ts +2 -0
  24. package/dist/vue3/types/components/rich_text_editor/extensions/text_style/text_style.d.ts.map +1 -0
  25. package/package.json +11 -1
@@ -1,60 +1,60 @@
1
- import { nodeViewProps as ft, NodeViewWrapper as pt, VueRenderer as je, VueNodeViewRenderer as mt, EditorContent as ze, Editor as Fe } from "../../node_modules/@tiptap/vue-3.js";
2
- import { isTextSelection as Ke, posToDOMRect as re, getText as We, getTextSerializersFromSchema as qe, Node as ae, nodePasteRule as Et, InputRule as Xe, mergeAttributes as st, getMarksBetween as Ye, combineTransactionSteps as Ge, getChangedRanges as Je, findChildrenInRange as Ze, Mark as Qe, nodeInputRule as tn, Extension as en } from "@tiptap/core";
3
- import { Plugin as It, PluginKey as rt, NodeSelection as nn } from "@tiptap/pm/state";
4
- import { CellSelection as on } from "@tiptap/pm/tables";
5
- import { defineComponent as le, ref as ce, onMounted as de, nextTick as sn, onBeforeUnmount as ue, h as he, resolveComponent as T, openBlock as _, createBlock as I, withCtx as C, createVNode as M, createElementBlock as et, withDirectives as rn, createElementVNode as nt, Fragment as an, renderList as ln, withModifiers as At, normalizeClass as fe, resolveDynamicComponent as cn, vShow as dn, markRaw as un, createTextVNode as at, toDisplayString as $, createCommentVNode as it, withKeys as hn, mergeProps as pe } from "vue";
6
- import fn from "@tiptap/extension-blockquote";
7
- import pn from "@tiptap/extension-code-block";
8
- import mn from "@tiptap/extension-code";
9
- import gn from "@tiptap/extension-document";
10
- import { UndoRedo as yn, Placeholder as wn, Gapcursor as bn } from "@tiptap/extensions";
11
- import vn from "@tiptap/extension-hard-break";
12
- import me from "@tiptap/extension-paragraph";
13
- import xn from "@tiptap/extension-bold";
14
- import { BulletList as Tn, ListItem as _n, OrderedList as kn } from "@tiptap/extension-list";
15
- import Cn from "@tiptap/extension-italic";
16
- import On from "@tiptap/extension-link";
17
- import En from "@tiptap/extension-strike";
18
- import Sn from "@tiptap/extension-underline";
19
- import Ln from "@tiptap/extension-text";
20
- import In from "@tiptap/extension-text-align";
21
- import { Table as An, TableRow as Dn, TableHeader as Rn, TableCell as Mn } from "@tiptap/extension-table";
22
- import { TextStyleKit as Hn } from "@tiptap/extension-text-style";
23
- import $n from "@tiptap/suggestion";
24
- import { emojiPattern as ge } from "regex-combined-emojis";
1
+ import { nodeViewProps as pt, NodeViewWrapper as mt, VueRenderer as Fe, VueNodeViewRenderer as gt, EditorContent as Ke, Editor as We } from "../../node_modules/@tiptap/vue-3.js";
2
+ import { isTextSelection as qe, posToDOMRect as ae, getText as Xe, getTextSerializersFromSchema as Ye, mergeAttributes as st, Node as le, nodePasteRule as St, InputRule as Ge, getMarksBetween as Je, combineTransactionSteps as Ze, getChangedRanges as Qe, findChildrenInRange as tn, Mark as en, nodeInputRule as nn, Extension as on } from "@tiptap/core";
3
+ import { Plugin as It, PluginKey as at, NodeSelection as sn } from "@tiptap/pm/state";
4
+ import { CellSelection as rn } from "@tiptap/pm/tables";
5
+ import { defineComponent as ce, ref as de, onMounted as ue, nextTick as an, onBeforeUnmount as he, h as fe, resolveComponent as T, openBlock as _, createBlock as A, withCtx as C, createVNode as M, createElementBlock as nt, withDirectives as ln, createElementVNode as ot, Fragment as cn, renderList as dn, withModifiers as Dt, normalizeClass as pe, resolveDynamicComponent as un, vShow as hn, markRaw as fn, createTextVNode as lt, toDisplayString as $, createCommentVNode as rt, withKeys as pn, mergeProps as me } from "vue";
6
+ import mn from "@tiptap/extension-blockquote";
7
+ import gn from "@tiptap/extension-code-block";
8
+ import yn from "@tiptap/extension-code";
9
+ import wn from "@tiptap/extension-document";
10
+ import { UndoRedo as bn, Placeholder as vn, Gapcursor as xn } from "@tiptap/extensions";
11
+ import Tn from "@tiptap/extension-hard-break";
12
+ import ge from "@tiptap/extension-paragraph";
13
+ import _n from "@tiptap/extension-bold";
14
+ import { BulletList as kn, ListItem as Cn, OrderedList as On } from "@tiptap/extension-list";
15
+ import En from "@tiptap/extension-italic";
16
+ import Sn from "@tiptap/extension-link";
17
+ import Ln from "@tiptap/extension-strike";
18
+ import An from "@tiptap/extension-underline";
19
+ import In from "@tiptap/extension-text";
20
+ import Dn from "@tiptap/extension-text-align";
21
+ import { Table as Rn, TableRow as Mn, TableHeader as Hn, TableCell as $n } from "@tiptap/extension-table";
22
+ import { TextStyle as Bn, TextStyleKit as Nn } from "@tiptap/extension-text-style";
23
+ import Pn from "@tiptap/suggestion";
24
+ import { emojiPattern as ye } from "regex-combined-emojis";
25
25
  import { _ as q } from "../../_plugin-vue_export-helper-CHgC5LLL.js";
26
- import ye from "../emoji/emoji.js";
27
- import { getEmojiData as Bn, emojiRegex as Nn, stringToUnicode as Pn, codeToEmojiData as Dt, emojiShortCodeRegex as Un } from "../../common/emoji/index.js";
28
- import Vn from "../list-item/list-item.js";
29
- import gt from "../stack/stack.js";
30
- import { linkRegex as jn, getPhoneNumberRegex as zn, warnIfUnmounted as Fn, returnFirstEl as zt } from "../../common/utils/index.js";
31
- import Kn from "@tiptap/extension-image";
32
- import Rt from "@tiptap/extension-mention";
33
- import we from "../link/link.js";
34
- import { DtIconLock as Wn } from "@dialpad/dialtone-icons/vue3";
35
- import { DialtoneLocalization as be } from "../../localization/index.js";
36
- import qn from "../input/input.js";
37
- import Xn from "../popover/popover.js";
38
- import ve from "../button/button.js";
39
- import Yn from "../badge/badge.js";
40
- import { RICH_TEXT_EDITOR_SUPPORTED_LINK_PROTOCOLS as Ft, RICH_TEXT_EDITOR_OUTPUT_FORMATS as Gn, RICH_TEXT_EDITOR_AUTOFOCUS_TYPES as Jn } from "./rich-text-editor-constants.js";
41
- import Zn from "../avatar/avatar.js";
42
- import Qn from "@dialpad/dialtone-icons/vue3/hash";
43
- import to from "@dialpad/dialtone-icons/vue3/lock";
44
- import eo from "deep-equal";
45
- const xe = ["top", "right", "bottom", "left"], Kt = ["start", "end"], Wt = /* @__PURE__ */ xe.reduce((t, e) => t.concat(e, e + "-" + Kt[0], e + "-" + Kt[1]), []), G = Math.min, R = Math.max, wt = Math.round, Y = (t) => ({
26
+ import we from "../emoji/emoji.js";
27
+ import { getEmojiData as Un, emojiRegex as Vn, stringToUnicode as jn, codeToEmojiData as Rt, emojiShortCodeRegex as zn } from "../../common/emoji/index.js";
28
+ import Fn from "../list-item/list-item.js";
29
+ import yt from "../stack/stack.js";
30
+ import { linkRegex as Kn, getPhoneNumberRegex as Wn, warnIfUnmounted as qn, returnFirstEl as Ft } from "../../common/utils/index.js";
31
+ import Xn from "@tiptap/extension-image";
32
+ import Mt from "@tiptap/extension-mention";
33
+ import be from "../link/link.js";
34
+ import { DtIconLock as Yn } from "@dialpad/dialtone-icons/vue3";
35
+ import { DialtoneLocalization as ve } from "../../localization/index.js";
36
+ import Gn from "../input/input.js";
37
+ import Jn from "../popover/popover.js";
38
+ import xe from "../button/button.js";
39
+ import Zn from "../badge/badge.js";
40
+ import { RICH_TEXT_EDITOR_SUPPORTED_LINK_PROTOCOLS as Kt, RICH_TEXT_EDITOR_OUTPUT_FORMATS as Qn, RICH_TEXT_EDITOR_AUTOFOCUS_TYPES as to } from "./rich-text-editor-constants.js";
41
+ import eo from "../avatar/avatar.js";
42
+ import no from "@dialpad/dialtone-icons/vue3/hash";
43
+ import oo from "@dialpad/dialtone-icons/vue3/lock";
44
+ import io from "deep-equal";
45
+ const Te = ["top", "right", "bottom", "left"], Wt = ["start", "end"], qt = /* @__PURE__ */ Te.reduce((t, e) => t.concat(e, e + "-" + Wt[0], e + "-" + Wt[1]), []), G = Math.min, R = Math.max, bt = Math.round, Y = (t) => ({
46
46
  x: t,
47
47
  y: t
48
- }), no = {
48
+ }), so = {
49
49
  left: "right",
50
50
  right: "left",
51
51
  bottom: "top",
52
52
  top: "bottom"
53
- }, oo = {
53
+ }, ro = {
54
54
  start: "end",
55
55
  end: "start"
56
56
  };
57
- function St(t, e, o) {
57
+ function Lt(t, e, o) {
58
58
  return R(t, G(e, o));
59
59
  }
60
60
  function Z(t, e) {
@@ -66,54 +66,54 @@ function j(t) {
66
66
  function F(t) {
67
67
  return t.split("-")[1];
68
68
  }
69
- function Te(t) {
69
+ function _e(t) {
70
70
  return t === "x" ? "y" : "x";
71
71
  }
72
- function Mt(t) {
72
+ function Ht(t) {
73
73
  return t === "y" ? "height" : "width";
74
74
  }
75
- const io = /* @__PURE__ */ new Set(["top", "bottom"]);
75
+ const ao = /* @__PURE__ */ new Set(["top", "bottom"]);
76
76
  function X(t) {
77
- return io.has(j(t)) ? "y" : "x";
77
+ return ao.has(j(t)) ? "y" : "x";
78
78
  }
79
- function Ht(t) {
80
- return Te(X(t));
79
+ function $t(t) {
80
+ return _e(X(t));
81
81
  }
82
- function _e(t, e, o) {
82
+ function ke(t, e, o) {
83
83
  o === void 0 && (o = !1);
84
- const n = F(t), i = Ht(t), s = Mt(i);
84
+ const n = F(t), i = $t(t), s = Ht(i);
85
85
  let r = i === "x" ? n === (o ? "end" : "start") ? "right" : "left" : n === "start" ? "bottom" : "top";
86
- return e.reference[s] > e.floating[s] && (r = vt(r)), [r, vt(r)];
86
+ return e.reference[s] > e.floating[s] && (r = xt(r)), [r, xt(r)];
87
87
  }
88
- function so(t) {
89
- const e = vt(t);
90
- return [bt(t), e, bt(e)];
88
+ function lo(t) {
89
+ const e = xt(t);
90
+ return [vt(t), e, vt(e)];
91
91
  }
92
- function bt(t) {
93
- return t.replace(/start|end/g, (e) => oo[e]);
92
+ function vt(t) {
93
+ return t.replace(/start|end/g, (e) => ro[e]);
94
94
  }
95
- const qt = ["left", "right"], Xt = ["right", "left"], ro = ["top", "bottom"], ao = ["bottom", "top"];
96
- function lo(t, e, o) {
95
+ const Xt = ["left", "right"], Yt = ["right", "left"], co = ["top", "bottom"], uo = ["bottom", "top"];
96
+ function ho(t, e, o) {
97
97
  switch (t) {
98
98
  case "top":
99
99
  case "bottom":
100
- return o ? e ? Xt : qt : e ? qt : Xt;
100
+ return o ? e ? Yt : Xt : e ? Xt : Yt;
101
101
  case "left":
102
102
  case "right":
103
- return e ? ro : ao;
103
+ return e ? co : uo;
104
104
  default:
105
105
  return [];
106
106
  }
107
107
  }
108
- function co(t, e, o, n) {
108
+ function fo(t, e, o, n) {
109
109
  const i = F(t);
110
- let s = lo(j(t), o === "start", n);
111
- return i && (s = s.map((r) => r + "-" + i), e && (s = s.concat(s.map(bt)))), s;
110
+ let s = ho(j(t), o === "start", n);
111
+ return i && (s = s.map((r) => r + "-" + i), e && (s = s.concat(s.map(vt)))), s;
112
112
  }
113
- function vt(t) {
114
- return t.replace(/left|right|bottom|top/g, (e) => no[e]);
113
+ function xt(t) {
114
+ return t.replace(/left|right|bottom|top/g, (e) => so[e]);
115
115
  }
116
- function uo(t) {
116
+ function po(t) {
117
117
  return {
118
118
  top: 0,
119
119
  right: 0,
@@ -122,15 +122,15 @@ function uo(t) {
122
122
  ...t
123
123
  };
124
124
  }
125
- function $t(t) {
126
- return typeof t != "number" ? uo(t) : {
125
+ function Bt(t) {
126
+ return typeof t != "number" ? po(t) : {
127
127
  top: t,
128
128
  right: t,
129
129
  bottom: t,
130
130
  left: t
131
131
  };
132
132
  }
133
- function ct(t) {
133
+ function dt(t) {
134
134
  const {
135
135
  x: e,
136
136
  y: o,
@@ -148,12 +148,12 @@ function ct(t) {
148
148
  y: o
149
149
  };
150
150
  }
151
- function Yt(t, e, o) {
151
+ function Gt(t, e, o) {
152
152
  let {
153
153
  reference: n,
154
154
  floating: i
155
155
  } = t;
156
- const s = X(e), r = Ht(e), a = Mt(r), l = j(e), u = s === "y", d = n.x + n.width / 2 - i.width / 2, c = n.y + n.height / 2 - i.height / 2, h = n[a] / 2 - i[a] / 2;
156
+ const s = X(e), r = $t(e), a = Ht(r), l = j(e), u = s === "y", d = n.x + n.width / 2 - i.width / 2, c = n.y + n.height / 2 - i.height / 2, h = n[a] / 2 - i[a] / 2;
157
157
  let f;
158
158
  switch (l) {
159
159
  case "top":
@@ -196,7 +196,7 @@ function Yt(t, e, o) {
196
196
  }
197
197
  return f;
198
198
  }
199
- async function ho(t, e) {
199
+ async function mo(t, e) {
200
200
  var o;
201
201
  e === void 0 && (e = {});
202
202
  const {
@@ -212,7 +212,7 @@ async function ho(t, e) {
212
212
  elementContext: c = "floating",
213
213
  altBoundary: h = !1,
214
214
  padding: f = 0
215
- } = Z(e, t), p = $t(f), g = a[h ? c === "floating" ? "reference" : "floating" : c], y = ct(await s.getClippingRect({
215
+ } = Z(e, t), p = Bt(f), g = a[h ? c === "floating" ? "reference" : "floating" : c], y = dt(await s.getClippingRect({
216
216
  element: (o = await (s.isElement == null ? void 0 : s.isElement(g))) == null || o ? g : g.contextElement || await (s.getDocumentElement == null ? void 0 : s.getDocumentElement(a.floating)),
217
217
  boundary: u,
218
218
  rootBoundary: d,
@@ -228,7 +228,7 @@ async function ho(t, e) {
228
228
  } : {
229
229
  x: 1,
230
230
  y: 1
231
- }, O = ct(s.convertOffsetParentRelativeRectToViewportRelativeRect ? await s.convertOffsetParentRelativeRectToViewportRelativeRect({
231
+ }, O = dt(s.convertOffsetParentRelativeRectToViewportRelativeRect ? await s.convertOffsetParentRelativeRectToViewportRelativeRect({
232
232
  elements: a,
233
233
  rect: b,
234
234
  offsetParent: v,
@@ -241,7 +241,7 @@ async function ho(t, e) {
241
241
  right: (O.right - y.right + p.right) / x.x
242
242
  };
243
243
  }
244
- const fo = async (t, e, o) => {
244
+ const go = async (t, e, o) => {
245
245
  const {
246
246
  placement: n = "bottom",
247
247
  strategy: i = "absolute",
@@ -255,7 +255,7 @@ const fo = async (t, e, o) => {
255
255
  }), {
256
256
  x: d,
257
257
  y: c
258
- } = Yt(u, n, l), h = n, f = {}, p = 0;
258
+ } = Gt(u, n, l), h = n, f = {}, p = 0;
259
259
  for (let g = 0; g < a.length; g++) {
260
260
  var m;
261
261
  const {
@@ -276,7 +276,7 @@ const fo = async (t, e, o) => {
276
276
  rects: u,
277
277
  platform: {
278
278
  ...r,
279
- detectOverflow: (m = r.detectOverflow) != null ? m : ho
279
+ detectOverflow: (m = r.detectOverflow) != null ? m : mo
280
280
  },
281
281
  elements: {
282
282
  reference: t,
@@ -296,7 +296,7 @@ const fo = async (t, e, o) => {
296
296
  }) : k.rects), {
297
297
  x: d,
298
298
  y: c
299
- } = Yt(u, h, l)), g = -1);
299
+ } = Gt(u, h, l)), g = -1);
300
300
  }
301
301
  return {
302
302
  x: d,
@@ -305,7 +305,7 @@ const fo = async (t, e, o) => {
305
305
  strategy: i,
306
306
  middlewareData: f
307
307
  };
308
- }, po = (t) => ({
308
+ }, yo = (t) => ({
309
309
  name: "arrow",
310
310
  options: t,
311
311
  async fn(e) {
@@ -323,13 +323,13 @@ const fo = async (t, e, o) => {
323
323
  } = Z(t, e) || {};
324
324
  if (u == null)
325
325
  return {};
326
- const c = $t(d), h = {
326
+ const c = Bt(d), h = {
327
327
  x: o,
328
328
  y: n
329
- }, f = Ht(i), p = Mt(f), m = await r.getDimensions(u), g = f === "y", y = g ? "top" : "left", b = g ? "bottom" : "right", v = g ? "clientHeight" : "clientWidth", x = s.reference[p] + s.reference[f] - h[f] - s.floating[p], O = h[f] - s.reference[f], k = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(u));
329
+ }, f = $t(i), p = Ht(f), m = await r.getDimensions(u), g = f === "y", y = g ? "top" : "left", b = g ? "bottom" : "right", v = g ? "clientHeight" : "clientWidth", x = s.reference[p] + s.reference[f] - h[f] - s.floating[p], O = h[f] - s.reference[f], k = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(u));
330
330
  let L = k ? k[v] : 0;
331
331
  (!L || !await (r.isElement == null ? void 0 : r.isElement(k))) && (L = a.floating[v] || s.floating[p]);
332
- const U = x / 2 - O / 2, A = L / 2 - m[p] / 2 - 1, w = G(c[y], A), E = G(c[b], A), D = w, H = L - m[p] - E, S = L / 2 - m[p] / 2 + U, z = St(D, S, H), V = !l.arrow && F(i) != null && S !== z && s.reference[p] / 2 - (S < D ? w : E) - m[p] / 2 < 0, B = V ? S < D ? S - D : S - H : 0;
332
+ const U = x / 2 - O / 2, I = L / 2 - m[p] / 2 - 1, w = G(c[y], I), E = G(c[b], I), D = w, H = L - m[p] - E, S = L / 2 - m[p] / 2 + U, z = Lt(D, S, H), V = !l.arrow && F(i) != null && S !== z && s.reference[p] / 2 - (S < D ? w : E) - m[p] / 2 < 0, B = V ? S < D ? S - D : S - H : 0;
333
333
  return {
334
334
  [f]: h[f] + B,
335
335
  data: {
@@ -343,10 +343,10 @@ const fo = async (t, e, o) => {
343
343
  };
344
344
  }
345
345
  });
346
- function mo(t, e, o) {
347
- return (t ? [...o.filter((i) => F(i) === t), ...o.filter((i) => F(i) !== t)] : o.filter((i) => j(i) === i)).filter((i) => t ? F(i) === t || (e ? bt(i) !== i : !1) : !0);
346
+ function wo(t, e, o) {
347
+ return (t ? [...o.filter((i) => F(i) === t), ...o.filter((i) => F(i) !== t)] : o.filter((i) => j(i) === i)).filter((i) => t ? F(i) === t || (e ? vt(i) !== i : !1) : !0);
348
348
  }
349
- const go = function(t) {
349
+ const bo = function(t) {
350
350
  return t === void 0 && (t = {}), {
351
351
  name: "autoPlacement",
352
352
  options: t,
@@ -361,13 +361,13 @@ const go = function(t) {
361
361
  } = e, {
362
362
  crossAxis: d = !1,
363
363
  alignment: c,
364
- allowedPlacements: h = Wt,
364
+ allowedPlacements: h = qt,
365
365
  autoAlignment: f = !0,
366
366
  ...p
367
- } = Z(t, e), m = c !== void 0 || h === Wt ? mo(c || null, f, h) : h, g = await l.detectOverflow(e, p), y = ((o = r.autoPlacement) == null ? void 0 : o.index) || 0, b = m[y];
367
+ } = Z(t, e), m = c !== void 0 || h === qt ? wo(c || null, f, h) : h, g = await l.detectOverflow(e, p), y = ((o = r.autoPlacement) == null ? void 0 : o.index) || 0, b = m[y];
368
368
  if (b == null)
369
369
  return {};
370
- const v = _e(b, s, await (l.isRTL == null ? void 0 : l.isRTL(u.floating)));
370
+ const v = ke(b, s, await (l.isRTL == null ? void 0 : l.isRTL(u.floating)));
371
371
  if (a !== b)
372
372
  return {
373
373
  reset: {
@@ -397,24 +397,24 @@ const go = function(t) {
397
397
  // Check only the mainAxis.
398
398
  w.overflows[0]
399
399
  ), w.overflows];
400
- }).sort((w, E) => w[1] - E[1]), A = ((i = L.filter((w) => w[2].slice(
400
+ }).sort((w, E) => w[1] - E[1]), I = ((i = L.filter((w) => w[2].slice(
401
401
  0,
402
402
  // Aligned placements should not check their opposite crossAxis
403
403
  // side.
404
404
  F(w[0]) ? 2 : 3
405
405
  ).every((E) => E <= 0))[0]) == null ? void 0 : i[0]) || L[0][0];
406
- return A !== a ? {
406
+ return I !== a ? {
407
407
  data: {
408
408
  index: y + 1,
409
409
  overflows: O
410
410
  },
411
411
  reset: {
412
- placement: A
412
+ placement: I
413
413
  }
414
414
  } : {};
415
415
  }
416
416
  };
417
- }, yo = function(t) {
417
+ }, vo = function(t) {
418
418
  return t === void 0 && (t = {}), {
419
419
  name: "flip",
420
420
  options: t,
@@ -438,18 +438,18 @@ const go = function(t) {
438
438
  } = Z(t, e);
439
439
  if ((o = s.arrow) != null && o.alignmentOffset)
440
440
  return {};
441
- const y = j(i), b = X(a), v = j(a) === a, x = await (l.isRTL == null ? void 0 : l.isRTL(u.floating)), O = h || (v || !m ? [vt(a)] : so(a)), k = p !== "none";
442
- !h && k && O.push(...co(a, m, p, x));
443
- const L = [a, ...O], U = await l.detectOverflow(e, g), A = [];
441
+ const y = j(i), b = X(a), v = j(a) === a, x = await (l.isRTL == null ? void 0 : l.isRTL(u.floating)), O = h || (v || !m ? [xt(a)] : lo(a)), k = p !== "none";
442
+ !h && k && O.push(...fo(a, m, p, x));
443
+ const L = [a, ...O], U = await l.detectOverflow(e, g), I = [];
444
444
  let w = ((n = s.flip) == null ? void 0 : n.overflows) || [];
445
- if (d && A.push(U[y]), c) {
446
- const S = _e(i, r, x);
447
- A.push(U[S[0]], U[S[1]]);
445
+ if (d && I.push(U[y]), c) {
446
+ const S = ke(i, r, x);
447
+ I.push(U[S[0]], U[S[1]]);
448
448
  }
449
449
  if (w = [...w, {
450
450
  placement: i,
451
- overflows: A
452
- }], !A.every((S) => S <= 0)) {
451
+ overflows: I
452
+ }], !I.every((S) => S <= 0)) {
453
453
  var E, D;
454
454
  const S = (((E = s.flip) == null ? void 0 : E.index) || 0) + 1, z = L[S];
455
455
  if (z && (!(c === "alignment" ? b !== X(z) : !1) || // We leave the current main axis only if every placement on that axis
@@ -477,7 +477,7 @@ const go = function(t) {
477
477
  tt === "y";
478
478
  }
479
479
  return !0;
480
- }).map((N) => [N.placement, N.overflows.filter((tt) => tt > 0).reduce((tt, Ve) => tt + Ve, 0)]).sort((N, tt) => N[1] - tt[1])[0]) == null ? void 0 : H[0];
480
+ }).map((N) => [N.placement, N.overflows.filter((tt) => tt > 0).reduce((tt, ze) => tt + ze, 0)]).sort((N, tt) => N[1] - tt[1])[0]) == null ? void 0 : H[0];
481
481
  B && (V = B);
482
482
  break;
483
483
  }
@@ -496,7 +496,7 @@ const go = function(t) {
496
496
  }
497
497
  };
498
498
  };
499
- function Gt(t, e) {
499
+ function Jt(t, e) {
500
500
  return {
501
501
  top: t.top - e.height,
502
502
  right: t.right - e.width,
@@ -504,10 +504,10 @@ function Gt(t, e) {
504
504
  left: t.left - e.width
505
505
  };
506
506
  }
507
- function Jt(t) {
508
- return xe.some((e) => t[e] >= 0);
507
+ function Zt(t) {
508
+ return Te.some((e) => t[e] >= 0);
509
509
  }
510
- const wo = function(t) {
510
+ const xo = function(t) {
511
511
  return t === void 0 && (t = {}), {
512
512
  name: "hide",
513
513
  options: t,
@@ -524,11 +524,11 @@ const wo = function(t) {
524
524
  const r = await n.detectOverflow(e, {
525
525
  ...s,
526
526
  elementContext: "reference"
527
- }), a = Gt(r, o.reference);
527
+ }), a = Jt(r, o.reference);
528
528
  return {
529
529
  data: {
530
530
  referenceHiddenOffsets: a,
531
- referenceHidden: Jt(a)
531
+ referenceHidden: Zt(a)
532
532
  }
533
533
  };
534
534
  }
@@ -536,11 +536,11 @@ const wo = function(t) {
536
536
  const r = await n.detectOverflow(e, {
537
537
  ...s,
538
538
  altBoundary: !0
539
- }), a = Gt(r, o.floating);
539
+ }), a = Jt(r, o.floating);
540
540
  return {
541
541
  data: {
542
542
  escapedOffsets: a,
543
- escaped: Jt(a)
543
+ escaped: Zt(a)
544
544
  }
545
545
  };
546
546
  }
@@ -550,7 +550,7 @@ const wo = function(t) {
550
550
  }
551
551
  };
552
552
  };
553
- function ke(t) {
553
+ function Ce(t) {
554
554
  const e = G(...t.map((s) => s.left)), o = G(...t.map((s) => s.top)), n = R(...t.map((s) => s.right)), i = R(...t.map((s) => s.bottom));
555
555
  return {
556
556
  x: e,
@@ -559,16 +559,16 @@ function ke(t) {
559
559
  height: i - o
560
560
  };
561
561
  }
562
- function bo(t) {
562
+ function To(t) {
563
563
  const e = t.slice().sort((i, s) => i.y - s.y), o = [];
564
564
  let n = null;
565
565
  for (let i = 0; i < e.length; i++) {
566
566
  const s = e[i];
567
567
  !n || s.y - n.y > n.height / 2 ? o.push([s]) : o[o.length - 1].push(s), n = s;
568
568
  }
569
- return o.map((i) => ct(ke(i)));
569
+ return o.map((i) => dt(Ce(i)));
570
570
  }
571
- const vo = function(t) {
571
+ const _o = function(t) {
572
572
  return t === void 0 && (t = {}), {
573
573
  name: "inline",
574
574
  options: t,
@@ -583,7 +583,7 @@ const vo = function(t) {
583
583
  padding: a = 2,
584
584
  x: l,
585
585
  y: u
586
- } = Z(t, e), d = Array.from(await (s.getClientRects == null ? void 0 : s.getClientRects(n.reference)) || []), c = bo(d), h = ct(ke(d)), f = $t(a);
586
+ } = Z(t, e), d = Array.from(await (s.getClientRects == null ? void 0 : s.getClientRects(n.reference)) || []), c = To(d), h = dt(Ce(d)), f = Bt(a);
587
587
  function p() {
588
588
  if (c.length === 2 && c[0].left > c[1].right && l != null && u != null)
589
589
  return c.find((g) => l > g.left - f.left && l < g.right + f.right && u > g.top - f.top && u < g.bottom + f.bottom) || h;
@@ -601,14 +601,14 @@ const vo = function(t) {
601
601
  y: H
602
602
  };
603
603
  }
604
- const g = j(o) === "left", y = R(...c.map((w) => w.right)), b = G(...c.map((w) => w.left)), v = c.filter((w) => g ? w.left === b : w.right === y), x = v[0].top, O = v[v.length - 1].bottom, k = b, L = y, U = L - k, A = O - x;
604
+ const g = j(o) === "left", y = R(...c.map((w) => w.right)), b = G(...c.map((w) => w.left)), v = c.filter((w) => g ? w.left === b : w.right === y), x = v[0].top, O = v[v.length - 1].bottom, k = b, L = y, U = L - k, I = O - x;
605
605
  return {
606
606
  top: x,
607
607
  bottom: O,
608
608
  left: k,
609
609
  right: L,
610
610
  width: U,
611
- height: A,
611
+ height: I,
612
612
  x: k,
613
613
  y: x
614
614
  };
@@ -629,13 +629,13 @@ const vo = function(t) {
629
629
  } : {};
630
630
  }
631
631
  };
632
- }, xo = /* @__PURE__ */ new Set(["left", "top"]);
633
- async function To(t, e) {
632
+ }, ko = /* @__PURE__ */ new Set(["left", "top"]);
633
+ async function Co(t, e) {
634
634
  const {
635
635
  placement: o,
636
636
  platform: n,
637
637
  elements: i
638
- } = t, s = await (n.isRTL == null ? void 0 : n.isRTL(i.floating)), r = j(o), a = F(o), l = X(o) === "y", u = xo.has(r) ? -1 : 1, d = s && l ? -1 : 1, c = Z(e, t);
638
+ } = t, s = await (n.isRTL == null ? void 0 : n.isRTL(i.floating)), r = j(o), a = F(o), l = X(o) === "y", u = ko.has(r) ? -1 : 1, d = s && l ? -1 : 1, c = Z(e, t);
639
639
  let {
640
640
  mainAxis: h,
641
641
  crossAxis: f,
@@ -657,7 +657,7 @@ async function To(t, e) {
657
657
  y: f * d
658
658
  };
659
659
  }
660
- const _o = function(t) {
660
+ const Oo = function(t) {
661
661
  return t === void 0 && (t = 0), {
662
662
  name: "offset",
663
663
  options: t,
@@ -668,7 +668,7 @@ const _o = function(t) {
668
668
  y: s,
669
669
  placement: r,
670
670
  middlewareData: a
671
- } = e, l = await To(e, t);
671
+ } = e, l = await Co(e, t);
672
672
  return r === ((o = a.offset) == null ? void 0 : o.placement) && (n = a.arrow) != null && n.alignmentOffset ? {} : {
673
673
  x: i + l.x,
674
674
  y: s + l.y,
@@ -679,7 +679,7 @@ const _o = function(t) {
679
679
  };
680
680
  }
681
681
  };
682
- }, ko = function(t) {
682
+ }, Eo = function(t) {
683
683
  return t === void 0 && (t = {}), {
684
684
  name: "shift",
685
685
  options: t,
@@ -708,15 +708,15 @@ const _o = function(t) {
708
708
  } = Z(t, e), d = {
709
709
  x: o,
710
710
  y: n
711
- }, c = await s.detectOverflow(e, u), h = X(j(i)), f = Te(h);
711
+ }, c = await s.detectOverflow(e, u), h = X(j(i)), f = _e(h);
712
712
  let p = d[f], m = d[h];
713
713
  if (r) {
714
714
  const y = f === "y" ? "top" : "left", b = f === "y" ? "bottom" : "right", v = p + c[y], x = p - c[b];
715
- p = St(v, p, x);
715
+ p = Lt(v, p, x);
716
716
  }
717
717
  if (a) {
718
718
  const y = h === "y" ? "top" : "left", b = h === "y" ? "bottom" : "right", v = m + c[y], x = m - c[b];
719
- m = St(v, m, x);
719
+ m = Lt(v, m, x);
720
720
  }
721
721
  const g = l.fn({
722
722
  ...e,
@@ -736,7 +736,7 @@ const _o = function(t) {
736
736
  };
737
737
  }
738
738
  };
739
- }, Co = function(t) {
739
+ }, So = function(t) {
740
740
  return t === void 0 && (t = {}), {
741
741
  name: "size",
742
742
  options: t,
@@ -768,8 +768,8 @@ const _o = function(t) {
768
768
  availableWidth: U,
769
769
  availableHeight: L
770
770
  });
771
- const A = await r.getDimensions(a.floating);
772
- return p !== A.width || m !== A.height ? {
771
+ const I = await r.getDimensions(a.floating);
772
+ return p !== I.width || m !== I.height ? {
773
773
  reset: {
774
774
  rects: !0
775
775
  }
@@ -777,11 +777,11 @@ const _o = function(t) {
777
777
  }
778
778
  };
779
779
  };
780
- function xt() {
780
+ function Tt() {
781
781
  return typeof window < "u";
782
782
  }
783
- function ut(t) {
784
- return Ce(t) ? (t.nodeName || "").toLowerCase() : "#document";
783
+ function ht(t) {
784
+ return Oe(t) ? (t.nodeName || "").toLowerCase() : "#document";
785
785
  }
786
786
  function P(t) {
787
787
  var e;
@@ -789,37 +789,37 @@ function P(t) {
789
789
  }
790
790
  function Q(t) {
791
791
  var e;
792
- return (e = (Ce(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
792
+ return (e = (Oe(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
793
793
  }
794
- function Ce(t) {
795
- return xt() ? t instanceof Node || t instanceof P(t).Node : !1;
794
+ function Oe(t) {
795
+ return Tt() ? t instanceof Node || t instanceof P(t).Node : !1;
796
796
  }
797
797
  function K(t) {
798
- return xt() ? t instanceof Element || t instanceof P(t).Element : !1;
798
+ return Tt() ? t instanceof Element || t instanceof P(t).Element : !1;
799
799
  }
800
800
  function J(t) {
801
- return xt() ? t instanceof HTMLElement || t instanceof P(t).HTMLElement : !1;
801
+ return Tt() ? t instanceof HTMLElement || t instanceof P(t).HTMLElement : !1;
802
802
  }
803
- function Zt(t) {
804
- return !xt() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof P(t).ShadowRoot;
803
+ function Qt(t) {
804
+ return !Tt() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof P(t).ShadowRoot;
805
805
  }
806
- const Oo = /* @__PURE__ */ new Set(["inline", "contents"]);
807
- function yt(t) {
806
+ const Lo = /* @__PURE__ */ new Set(["inline", "contents"]);
807
+ function wt(t) {
808
808
  const {
809
809
  overflow: e,
810
810
  overflowX: o,
811
811
  overflowY: n,
812
812
  display: i
813
813
  } = W(t);
814
- return /auto|scroll|overlay|hidden|clip/.test(e + n + o) && !Oo.has(i);
814
+ return /auto|scroll|overlay|hidden|clip/.test(e + n + o) && !Lo.has(i);
815
815
  }
816
- const Eo = /* @__PURE__ */ new Set(["table", "td", "th"]);
817
- function So(t) {
818
- return Eo.has(ut(t));
816
+ const Ao = /* @__PURE__ */ new Set(["table", "td", "th"]);
817
+ function Io(t) {
818
+ return Ao.has(ht(t));
819
819
  }
820
- const Lo = [":popover-open", ":modal"];
821
- function Tt(t) {
822
- return Lo.some((e) => {
820
+ const Do = [":popover-open", ":modal"];
821
+ function _t(t) {
822
+ return Do.some((e) => {
823
823
  try {
824
824
  return t.matches(e);
825
825
  } catch {
@@ -827,33 +827,33 @@ function Tt(t) {
827
827
  }
828
828
  });
829
829
  }
830
- const Io = ["transform", "translate", "scale", "rotate", "perspective"], Ao = ["transform", "translate", "scale", "rotate", "perspective", "filter"], Do = ["paint", "layout", "strict", "content"];
831
- function Bt(t) {
832
- const e = Nt(), o = K(t) ? W(t) : t;
833
- return Io.some((n) => o[n] ? o[n] !== "none" : !1) || (o.containerType ? o.containerType !== "normal" : !1) || !e && (o.backdropFilter ? o.backdropFilter !== "none" : !1) || !e && (o.filter ? o.filter !== "none" : !1) || Ao.some((n) => (o.willChange || "").includes(n)) || Do.some((n) => (o.contain || "").includes(n));
830
+ const Ro = ["transform", "translate", "scale", "rotate", "perspective"], Mo = ["transform", "translate", "scale", "rotate", "perspective", "filter"], Ho = ["paint", "layout", "strict", "content"];
831
+ function Nt(t) {
832
+ const e = Pt(), o = K(t) ? W(t) : t;
833
+ return Ro.some((n) => o[n] ? o[n] !== "none" : !1) || (o.containerType ? o.containerType !== "normal" : !1) || !e && (o.backdropFilter ? o.backdropFilter !== "none" : !1) || !e && (o.filter ? o.filter !== "none" : !1) || Mo.some((n) => (o.willChange || "").includes(n)) || Ho.some((n) => (o.contain || "").includes(n));
834
834
  }
835
- function Ro(t) {
836
- let e = ot(t);
837
- for (; J(e) && !dt(e); ) {
838
- if (Bt(e))
835
+ function $o(t) {
836
+ let e = it(t);
837
+ for (; J(e) && !ut(e); ) {
838
+ if (Nt(e))
839
839
  return e;
840
- if (Tt(e))
840
+ if (_t(e))
841
841
  return null;
842
- e = ot(e);
842
+ e = it(e);
843
843
  }
844
844
  return null;
845
845
  }
846
- function Nt() {
846
+ function Pt() {
847
847
  return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
848
848
  }
849
- const Mo = /* @__PURE__ */ new Set(["html", "body", "#document"]);
850
- function dt(t) {
851
- return Mo.has(ut(t));
849
+ const Bo = /* @__PURE__ */ new Set(["html", "body", "#document"]);
850
+ function ut(t) {
851
+ return Bo.has(ht(t));
852
852
  }
853
853
  function W(t) {
854
854
  return P(t).getComputedStyle(t);
855
855
  }
856
- function _t(t) {
856
+ function kt(t) {
857
857
  return K(t) ? {
858
858
  scrollLeft: t.scrollLeft,
859
859
  scrollTop: t.scrollTop
@@ -862,111 +862,111 @@ function _t(t) {
862
862
  scrollTop: t.scrollY
863
863
  };
864
864
  }
865
- function ot(t) {
866
- if (ut(t) === "html")
865
+ function it(t) {
866
+ if (ht(t) === "html")
867
867
  return t;
868
868
  const e = (
869
869
  // Step into the shadow DOM of the parent of a slotted node.
870
870
  t.assignedSlot || // DOM Element detected.
871
871
  t.parentNode || // ShadowRoot detected.
872
- Zt(t) && t.host || // Fallback.
872
+ Qt(t) && t.host || // Fallback.
873
873
  Q(t)
874
874
  );
875
- return Zt(e) ? e.host : e;
875
+ return Qt(e) ? e.host : e;
876
876
  }
877
- function Oe(t) {
878
- const e = ot(t);
879
- return dt(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : J(e) && yt(e) ? e : Oe(e);
877
+ function Ee(t) {
878
+ const e = it(t);
879
+ return ut(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : J(e) && wt(e) ? e : Ee(e);
880
880
  }
881
- function Ee(t, e, o) {
881
+ function Se(t, e, o) {
882
882
  var n;
883
883
  e === void 0 && (e = []);
884
- const i = Oe(t), s = i === ((n = t.ownerDocument) == null ? void 0 : n.body), r = P(i);
885
- return s ? e.concat(r, r.visualViewport || [], yt(i) ? i : [], []) : e.concat(i, Ee(i, []));
884
+ const i = Ee(t), s = i === ((n = t.ownerDocument) == null ? void 0 : n.body), r = P(i);
885
+ return s ? e.concat(r, r.visualViewport || [], wt(i) ? i : [], []) : e.concat(i, Se(i, []));
886
886
  }
887
- function Qt(t) {
887
+ function te(t) {
888
888
  return t.parent && Object.getPrototypeOf(t.parent) ? t.frameElement : null;
889
889
  }
890
- function Se(t) {
890
+ function Le(t) {
891
891
  const e = W(t);
892
892
  let o = parseFloat(e.width) || 0, n = parseFloat(e.height) || 0;
893
- const i = J(t), s = i ? t.offsetWidth : o, r = i ? t.offsetHeight : n, a = wt(o) !== s || wt(n) !== r;
893
+ const i = J(t), s = i ? t.offsetWidth : o, r = i ? t.offsetHeight : n, a = bt(o) !== s || bt(n) !== r;
894
894
  return a && (o = s, n = r), {
895
895
  width: o,
896
896
  height: n,
897
897
  $: a
898
898
  };
899
899
  }
900
- function Le(t) {
900
+ function Ae(t) {
901
901
  return K(t) ? t : t.contextElement;
902
902
  }
903
- function lt(t) {
904
- const e = Le(t);
903
+ function ct(t) {
904
+ const e = Ae(t);
905
905
  if (!J(e))
906
906
  return Y(1);
907
907
  const o = e.getBoundingClientRect(), {
908
908
  width: n,
909
909
  height: i,
910
910
  $: s
911
- } = Se(e);
912
- let r = (s ? wt(o.width) : o.width) / n, a = (s ? wt(o.height) : o.height) / i;
911
+ } = Le(e);
912
+ let r = (s ? bt(o.width) : o.width) / n, a = (s ? bt(o.height) : o.height) / i;
913
913
  return (!r || !Number.isFinite(r)) && (r = 1), (!a || !Number.isFinite(a)) && (a = 1), {
914
914
  x: r,
915
915
  y: a
916
916
  };
917
917
  }
918
- const Ho = /* @__PURE__ */ Y(0);
918
+ const No = /* @__PURE__ */ Y(0);
919
919
  function Ie(t) {
920
920
  const e = P(t);
921
- return !Nt() || !e.visualViewport ? Ho : {
921
+ return !Pt() || !e.visualViewport ? No : {
922
922
  x: e.visualViewport.offsetLeft,
923
923
  y: e.visualViewport.offsetTop
924
924
  };
925
925
  }
926
- function $o(t, e, o) {
926
+ function Po(t, e, o) {
927
927
  return e === void 0 && (e = !1), !o || e && o !== P(t) ? !1 : e;
928
928
  }
929
- function ht(t, e, o, n) {
929
+ function ft(t, e, o, n) {
930
930
  e === void 0 && (e = !1), o === void 0 && (o = !1);
931
- const i = t.getBoundingClientRect(), s = Le(t);
931
+ const i = t.getBoundingClientRect(), s = Ae(t);
932
932
  let r = Y(1);
933
- e && (n ? K(n) && (r = lt(n)) : r = lt(t));
934
- const a = $o(s, o, n) ? Ie(s) : Y(0);
933
+ e && (n ? K(n) && (r = ct(n)) : r = ct(t));
934
+ const a = Po(s, o, n) ? Ie(s) : Y(0);
935
935
  let l = (i.left + a.x) / r.x, u = (i.top + a.y) / r.y, d = i.width / r.x, c = i.height / r.y;
936
936
  if (s) {
937
937
  const h = P(s), f = n && K(n) ? P(n) : n;
938
- let p = h, m = Qt(p);
938
+ let p = h, m = te(p);
939
939
  for (; m && n && f !== p; ) {
940
- const g = lt(m), y = m.getBoundingClientRect(), b = W(m), v = y.left + (m.clientLeft + parseFloat(b.paddingLeft)) * g.x, x = y.top + (m.clientTop + parseFloat(b.paddingTop)) * g.y;
941
- l *= g.x, u *= g.y, d *= g.x, c *= g.y, l += v, u += x, p = P(m), m = Qt(p);
940
+ const g = ct(m), y = m.getBoundingClientRect(), b = W(m), v = y.left + (m.clientLeft + parseFloat(b.paddingLeft)) * g.x, x = y.top + (m.clientTop + parseFloat(b.paddingTop)) * g.y;
941
+ l *= g.x, u *= g.y, d *= g.x, c *= g.y, l += v, u += x, p = P(m), m = te(p);
942
942
  }
943
943
  }
944
- return ct({
944
+ return dt({
945
945
  width: d,
946
946
  height: c,
947
947
  x: l,
948
948
  y: u
949
949
  });
950
950
  }
951
- function kt(t, e) {
952
- const o = _t(t).scrollLeft;
953
- return e ? e.left + o : ht(Q(t)).left + o;
951
+ function Ct(t, e) {
952
+ const o = kt(t).scrollLeft;
953
+ return e ? e.left + o : ft(Q(t)).left + o;
954
954
  }
955
- function Ae(t, e) {
956
- const o = t.getBoundingClientRect(), n = o.left + e.scrollLeft - kt(t, o), i = o.top + e.scrollTop;
955
+ function De(t, e) {
956
+ const o = t.getBoundingClientRect(), n = o.left + e.scrollLeft - Ct(t, o), i = o.top + e.scrollTop;
957
957
  return {
958
958
  x: n,
959
959
  y: i
960
960
  };
961
961
  }
962
- function Bo(t) {
962
+ function Uo(t) {
963
963
  let {
964
964
  elements: e,
965
965
  rect: o,
966
966
  offsetParent: n,
967
967
  strategy: i
968
968
  } = t;
969
- const s = i === "fixed", r = Q(n), a = e ? Tt(e.floating) : !1;
969
+ const s = i === "fixed", r = Q(n), a = e ? _t(e.floating) : !1;
970
970
  if (n === r || a && s)
971
971
  return o;
972
972
  let l = {
@@ -974,11 +974,11 @@ function Bo(t) {
974
974
  scrollTop: 0
975
975
  }, u = Y(1);
976
976
  const d = Y(0), c = J(n);
977
- if ((c || !c && !s) && ((ut(n) !== "body" || yt(r)) && (l = _t(n)), J(n))) {
978
- const f = ht(n);
979
- u = lt(n), d.x = f.x + n.clientLeft, d.y = f.y + n.clientTop;
977
+ if ((c || !c && !s) && ((ht(n) !== "body" || wt(r)) && (l = kt(n)), J(n))) {
978
+ const f = ft(n);
979
+ u = ct(n), d.x = f.x + n.clientLeft, d.y = f.y + n.clientTop;
980
980
  }
981
- const h = r && !c && !s ? Ae(r, l) : Y(0);
981
+ const h = r && !c && !s ? De(r, l) : Y(0);
982
982
  return {
983
983
  width: o.width * u.x,
984
984
  height: o.height * u.y,
@@ -986,12 +986,12 @@ function Bo(t) {
986
986
  y: o.y * u.y - l.scrollTop * u.y + d.y + h.y
987
987
  };
988
988
  }
989
- function No(t) {
989
+ function Vo(t) {
990
990
  return Array.from(t.getClientRects());
991
991
  }
992
- function Po(t) {
993
- const e = Q(t), o = _t(t), n = t.ownerDocument.body, i = R(e.scrollWidth, e.clientWidth, n.scrollWidth, n.clientWidth), s = R(e.scrollHeight, e.clientHeight, n.scrollHeight, n.clientHeight);
994
- let r = -o.scrollLeft + kt(t);
992
+ function jo(t) {
993
+ const e = Q(t), o = kt(t), n = t.ownerDocument.body, i = R(e.scrollWidth, e.clientWidth, n.scrollWidth, n.clientWidth), s = R(e.scrollHeight, e.clientHeight, n.scrollHeight, n.clientHeight);
994
+ let r = -o.scrollLeft + Ct(t);
995
995
  const a = -o.scrollTop;
996
996
  return W(n).direction === "rtl" && (r += R(e.clientWidth, n.clientWidth) - i), {
997
997
  width: i,
@@ -1000,20 +1000,20 @@ function Po(t) {
1000
1000
  y: a
1001
1001
  };
1002
1002
  }
1003
- const te = 25;
1004
- function Uo(t, e) {
1003
+ const ee = 25;
1004
+ function zo(t, e) {
1005
1005
  const o = P(t), n = Q(t), i = o.visualViewport;
1006
1006
  let s = n.clientWidth, r = n.clientHeight, a = 0, l = 0;
1007
1007
  if (i) {
1008
1008
  s = i.width, r = i.height;
1009
- const d = Nt();
1009
+ const d = Pt();
1010
1010
  (!d || d && e === "fixed") && (a = i.offsetLeft, l = i.offsetTop);
1011
1011
  }
1012
- const u = kt(n);
1012
+ const u = Ct(n);
1013
1013
  if (u <= 0) {
1014
1014
  const d = n.ownerDocument, c = d.body, h = getComputedStyle(c), f = d.compatMode === "CSS1Compat" && parseFloat(h.marginLeft) + parseFloat(h.marginRight) || 0, p = Math.abs(n.clientWidth - c.clientWidth - f);
1015
- p <= te && (s -= p);
1016
- } else u <= te && (s += u);
1015
+ p <= ee && (s -= p);
1016
+ } else u <= ee && (s += u);
1017
1017
  return {
1018
1018
  width: s,
1019
1019
  height: r,
@@ -1021,9 +1021,9 @@ function Uo(t, e) {
1021
1021
  y: l
1022
1022
  };
1023
1023
  }
1024
- const Vo = /* @__PURE__ */ new Set(["absolute", "fixed"]);
1025
- function jo(t, e) {
1026
- const o = ht(t, !0, e === "fixed"), n = o.top + t.clientTop, i = o.left + t.clientLeft, s = J(t) ? lt(t) : Y(1), r = t.clientWidth * s.x, a = t.clientHeight * s.y, l = i * s.x, u = n * s.y;
1024
+ const Fo = /* @__PURE__ */ new Set(["absolute", "fixed"]);
1025
+ function Ko(t, e) {
1026
+ const o = ft(t, !0, e === "fixed"), n = o.top + t.clientTop, i = o.left + t.clientLeft, s = J(t) ? ct(t) : Y(1), r = t.clientWidth * s.x, a = t.clientHeight * s.y, l = i * s.x, u = n * s.y;
1027
1027
  return {
1028
1028
  width: r,
1029
1029
  height: a,
@@ -1031,14 +1031,14 @@ function jo(t, e) {
1031
1031
  y: u
1032
1032
  };
1033
1033
  }
1034
- function ee(t, e, o) {
1034
+ function ne(t, e, o) {
1035
1035
  let n;
1036
1036
  if (e === "viewport")
1037
- n = Uo(t, o);
1037
+ n = zo(t, o);
1038
1038
  else if (e === "document")
1039
- n = Po(Q(t));
1039
+ n = jo(Q(t));
1040
1040
  else if (K(e))
1041
- n = jo(e, o);
1041
+ n = Ko(e, o);
1042
1042
  else {
1043
1043
  const i = Ie(t);
1044
1044
  n = {
@@ -1048,36 +1048,36 @@ function ee(t, e, o) {
1048
1048
  height: e.height
1049
1049
  };
1050
1050
  }
1051
- return ct(n);
1051
+ return dt(n);
1052
1052
  }
1053
- function De(t, e) {
1054
- const o = ot(t);
1055
- return o === e || !K(o) || dt(o) ? !1 : W(o).position === "fixed" || De(o, e);
1053
+ function Re(t, e) {
1054
+ const o = it(t);
1055
+ return o === e || !K(o) || ut(o) ? !1 : W(o).position === "fixed" || Re(o, e);
1056
1056
  }
1057
- function zo(t, e) {
1057
+ function Wo(t, e) {
1058
1058
  const o = e.get(t);
1059
1059
  if (o)
1060
1060
  return o;
1061
- let n = Ee(t, []).filter((a) => K(a) && ut(a) !== "body"), i = null;
1061
+ let n = Se(t, []).filter((a) => K(a) && ht(a) !== "body"), i = null;
1062
1062
  const s = W(t).position === "fixed";
1063
- let r = s ? ot(t) : t;
1064
- for (; K(r) && !dt(r); ) {
1065
- const a = W(r), l = Bt(r);
1066
- !l && a.position === "fixed" && (i = null), (s ? !l && !i : !l && a.position === "static" && !!i && Vo.has(i.position) || yt(r) && !l && De(t, r)) ? n = n.filter((d) => d !== r) : i = a, r = ot(r);
1063
+ let r = s ? it(t) : t;
1064
+ for (; K(r) && !ut(r); ) {
1065
+ const a = W(r), l = Nt(r);
1066
+ !l && a.position === "fixed" && (i = null), (s ? !l && !i : !l && a.position === "static" && !!i && Fo.has(i.position) || wt(r) && !l && Re(t, r)) ? n = n.filter((d) => d !== r) : i = a, r = it(r);
1067
1067
  }
1068
1068
  return e.set(t, n), n;
1069
1069
  }
1070
- function Fo(t) {
1070
+ function qo(t) {
1071
1071
  let {
1072
1072
  element: e,
1073
1073
  boundary: o,
1074
1074
  rootBoundary: n,
1075
1075
  strategy: i
1076
1076
  } = t;
1077
- const r = [...o === "clippingAncestors" ? Tt(e) ? [] : zo(e, this._c) : [].concat(o), n], a = r[0], l = r.reduce((u, d) => {
1078
- const c = ee(e, d, i);
1077
+ const r = [...o === "clippingAncestors" ? _t(e) ? [] : Wo(e, this._c) : [].concat(o), n], a = r[0], l = r.reduce((u, d) => {
1078
+ const c = ne(e, d, i);
1079
1079
  return u.top = R(c.top, u.top), u.right = G(c.right, u.right), u.bottom = G(c.bottom, u.bottom), u.left = R(c.left, u.left), u;
1080
- }, ee(e, a, i));
1080
+ }, ne(e, a, i));
1081
1081
  return {
1082
1082
  width: l.right - l.left,
1083
1083
  height: l.bottom - l.top,
@@ -1085,33 +1085,33 @@ function Fo(t) {
1085
1085
  y: l.top
1086
1086
  };
1087
1087
  }
1088
- function Ko(t) {
1088
+ function Xo(t) {
1089
1089
  const {
1090
1090
  width: e,
1091
1091
  height: o
1092
- } = Se(t);
1092
+ } = Le(t);
1093
1093
  return {
1094
1094
  width: e,
1095
1095
  height: o
1096
1096
  };
1097
1097
  }
1098
- function Wo(t, e, o) {
1099
- const n = J(e), i = Q(e), s = o === "fixed", r = ht(t, !0, s, e);
1098
+ function Yo(t, e, o) {
1099
+ const n = J(e), i = Q(e), s = o === "fixed", r = ft(t, !0, s, e);
1100
1100
  let a = {
1101
1101
  scrollLeft: 0,
1102
1102
  scrollTop: 0
1103
1103
  };
1104
1104
  const l = Y(0);
1105
1105
  function u() {
1106
- l.x = kt(i);
1106
+ l.x = Ct(i);
1107
1107
  }
1108
1108
  if (n || !n && !s)
1109
- if ((ut(e) !== "body" || yt(i)) && (a = _t(e)), n) {
1110
- const f = ht(e, !0, s, e);
1109
+ if ((ht(e) !== "body" || wt(i)) && (a = kt(e)), n) {
1110
+ const f = ft(e, !0, s, e);
1111
1111
  l.x = f.x + e.clientLeft, l.y = f.y + e.clientTop;
1112
1112
  } else i && u();
1113
1113
  s && !n && i && u();
1114
- const d = i && !n && !s ? Ae(i, a) : Y(0), c = r.left + a.scrollLeft - l.x - d.x, h = r.top + a.scrollTop - l.y - d.y;
1114
+ const d = i && !n && !s ? De(i, a) : Y(0), c = r.left + a.scrollLeft - l.x - d.x, h = r.top + a.scrollTop - l.y - d.y;
1115
1115
  return {
1116
1116
  x: c,
1117
1117
  y: h,
@@ -1119,10 +1119,10 @@ function Wo(t, e, o) {
1119
1119
  height: r.height
1120
1120
  };
1121
1121
  }
1122
- function Ot(t) {
1122
+ function Et(t) {
1123
1123
  return W(t).position === "static";
1124
1124
  }
1125
- function ne(t, e) {
1125
+ function oe(t, e) {
1126
1126
  if (!J(t) || W(t).position === "fixed")
1127
1127
  return null;
1128
1128
  if (e)
@@ -1130,28 +1130,28 @@ function ne(t, e) {
1130
1130
  let o = t.offsetParent;
1131
1131
  return Q(t) === o && (o = o.ownerDocument.body), o;
1132
1132
  }
1133
- function Re(t, e) {
1133
+ function Me(t, e) {
1134
1134
  const o = P(t);
1135
- if (Tt(t))
1135
+ if (_t(t))
1136
1136
  return o;
1137
1137
  if (!J(t)) {
1138
- let i = ot(t);
1139
- for (; i && !dt(i); ) {
1140
- if (K(i) && !Ot(i))
1138
+ let i = it(t);
1139
+ for (; i && !ut(i); ) {
1140
+ if (K(i) && !Et(i))
1141
1141
  return i;
1142
- i = ot(i);
1142
+ i = it(i);
1143
1143
  }
1144
1144
  return o;
1145
1145
  }
1146
- let n = ne(t, e);
1147
- for (; n && So(n) && Ot(n); )
1148
- n = ne(n, e);
1149
- return n && dt(n) && Ot(n) && !Bt(n) ? o : n || Ro(t) || o;
1146
+ let n = oe(t, e);
1147
+ for (; n && Io(n) && Et(n); )
1148
+ n = oe(n, e);
1149
+ return n && ut(n) && Et(n) && !Nt(n) ? o : n || $o(t) || o;
1150
1150
  }
1151
- const qo = async function(t) {
1152
- const e = this.getOffsetParent || Re, o = this.getDimensions, n = await o(t.floating);
1151
+ const Go = async function(t) {
1152
+ const e = this.getOffsetParent || Me, o = this.getDimensions, n = await o(t.floating);
1153
1153
  return {
1154
- reference: Wo(t.reference, await e(t.floating), t.strategy),
1154
+ reference: Yo(t.reference, await e(t.floating), t.strategy),
1155
1155
  floating: {
1156
1156
  x: 0,
1157
1157
  y: 0,
@@ -1160,38 +1160,38 @@ const qo = async function(t) {
1160
1160
  }
1161
1161
  };
1162
1162
  };
1163
- function Xo(t) {
1163
+ function Jo(t) {
1164
1164
  return W(t).direction === "rtl";
1165
1165
  }
1166
- const Yo = {
1167
- convertOffsetParentRelativeRectToViewportRelativeRect: Bo,
1166
+ const Zo = {
1167
+ convertOffsetParentRelativeRectToViewportRelativeRect: Uo,
1168
1168
  getDocumentElement: Q,
1169
- getClippingRect: Fo,
1170
- getOffsetParent: Re,
1171
- getElementRects: qo,
1172
- getClientRects: No,
1173
- getDimensions: Ko,
1174
- getScale: lt,
1169
+ getClippingRect: qo,
1170
+ getOffsetParent: Me,
1171
+ getElementRects: Go,
1172
+ getClientRects: Vo,
1173
+ getDimensions: Xo,
1174
+ getScale: ct,
1175
1175
  isElement: K,
1176
- isRTL: Xo
1177
- }, Pt = _o, Me = go, Ut = ko, Vt = yo, He = Co, $e = wo, Be = po, Ne = vo, jt = (t, e, o) => {
1176
+ isRTL: Jo
1177
+ }, Ut = Oo, He = bo, Vt = Eo, jt = vo, $e = So, Be = xo, Ne = yo, Pe = _o, zt = (t, e, o) => {
1178
1178
  const n = /* @__PURE__ */ new Map(), i = {
1179
- platform: Yo,
1179
+ platform: Zo,
1180
1180
  ...o
1181
1181
  }, s = {
1182
1182
  ...i.platform,
1183
1183
  _c: n
1184
1184
  };
1185
- return fo(t, e, {
1185
+ return go(t, e, {
1186
1186
  ...i,
1187
1187
  platform: s
1188
1188
  });
1189
1189
  };
1190
- function Go(t, e) {
1190
+ function Qo(t, e) {
1191
1191
  const o = Math.min(t.top, e.top), n = Math.max(t.bottom, e.bottom), i = Math.min(t.left, e.left), r = Math.max(t.right, e.right) - i, a = n - o, l = i, u = o;
1192
1192
  return new DOMRect(l, u, r, a);
1193
1193
  }
1194
- var Jo = class {
1194
+ var ti = class {
1195
1195
  constructor({
1196
1196
  editor: t,
1197
1197
  element: e,
@@ -1219,7 +1219,7 @@ var Jo = class {
1219
1219
  onUpdate: void 0,
1220
1220
  onDestroy: void 0
1221
1221
  }, this.shouldShow = ({ view: d, state: c, from: h, to: f }) => {
1222
- const { doc: p, selection: m } = c, { empty: g } = m, y = !p.textBetween(h, f).length && Ke(c.selection), b = this.element.contains(document.activeElement);
1222
+ const { doc: p, selection: m } = c, { empty: g } = m, y = !p.textBetween(h, f).length && qe(c.selection), b = this.element.contains(document.activeElement);
1223
1223
  return !(!(d.hasFocus() || b) || g || y || !this.editor.isEditable);
1224
1224
  }, this.mousedownHandler = () => {
1225
1225
  this.preventHide = !0;
@@ -1268,16 +1268,16 @@ var Jo = class {
1268
1268
  }
1269
1269
  get middlewares() {
1270
1270
  const t = [];
1271
- return this.floatingUIOptions.flip && t.push(Vt(typeof this.floatingUIOptions.flip != "boolean" ? this.floatingUIOptions.flip : void 0)), this.floatingUIOptions.shift && t.push(
1272
- Ut(typeof this.floatingUIOptions.shift != "boolean" ? this.floatingUIOptions.shift : void 0)
1271
+ return this.floatingUIOptions.flip && t.push(jt(typeof this.floatingUIOptions.flip != "boolean" ? this.floatingUIOptions.flip : void 0)), this.floatingUIOptions.shift && t.push(
1272
+ Vt(typeof this.floatingUIOptions.shift != "boolean" ? this.floatingUIOptions.shift : void 0)
1273
1273
  ), this.floatingUIOptions.offset && t.push(
1274
- Pt(typeof this.floatingUIOptions.offset != "boolean" ? this.floatingUIOptions.offset : void 0)
1275
- ), this.floatingUIOptions.arrow && t.push(Be(this.floatingUIOptions.arrow)), this.floatingUIOptions.size && t.push(He(typeof this.floatingUIOptions.size != "boolean" ? this.floatingUIOptions.size : void 0)), this.floatingUIOptions.autoPlacement && t.push(
1276
- Me(
1274
+ Ut(typeof this.floatingUIOptions.offset != "boolean" ? this.floatingUIOptions.offset : void 0)
1275
+ ), this.floatingUIOptions.arrow && t.push(Ne(this.floatingUIOptions.arrow)), this.floatingUIOptions.size && t.push($e(typeof this.floatingUIOptions.size != "boolean" ? this.floatingUIOptions.size : void 0)), this.floatingUIOptions.autoPlacement && t.push(
1276
+ He(
1277
1277
  typeof this.floatingUIOptions.autoPlacement != "boolean" ? this.floatingUIOptions.autoPlacement : void 0
1278
1278
  )
1279
- ), this.floatingUIOptions.hide && t.push($e(typeof this.floatingUIOptions.hide != "boolean" ? this.floatingUIOptions.hide : void 0)), this.floatingUIOptions.inline && t.push(
1280
- Ne(typeof this.floatingUIOptions.inline != "boolean" ? this.floatingUIOptions.inline : void 0)
1279
+ ), this.floatingUIOptions.hide && t.push(Be(typeof this.floatingUIOptions.hide != "boolean" ? this.floatingUIOptions.hide : void 0)), this.floatingUIOptions.inline && t.push(
1280
+ Pe(typeof this.floatingUIOptions.inline != "boolean" ? this.floatingUIOptions.inline : void 0)
1281
1281
  ), t;
1282
1282
  }
1283
1283
  get virtualElement() {
@@ -1287,12 +1287,12 @@ var Jo = class {
1287
1287
  return i;
1288
1288
  if (!((o = (e = this.view) == null ? void 0 : e.dom) != null && o.parentNode))
1289
1289
  return;
1290
- const s = re(this.view, n.from, n.to);
1290
+ const s = ae(this.view, n.from, n.to);
1291
1291
  let r = {
1292
1292
  getBoundingClientRect: () => s,
1293
1293
  getClientRects: () => [s]
1294
1294
  };
1295
- if (n instanceof nn) {
1295
+ if (n instanceof sn) {
1296
1296
  let a = this.view.nodeDOM(n.from);
1297
1297
  const l = a.dataset.nodeViewWrapper ? a : a.querySelector("[data-node-view-wrapper]");
1298
1298
  l && (a = l), a && (r = {
@@ -1300,11 +1300,11 @@ var Jo = class {
1300
1300
  getClientRects: () => [a.getBoundingClientRect()]
1301
1301
  });
1302
1302
  }
1303
- if (n instanceof on) {
1303
+ if (n instanceof rn) {
1304
1304
  const { $anchorCell: a, $headCell: l } = n, u = a ? a.pos : l.pos, d = l ? l.pos : a.pos, c = this.view.nodeDOM(u), h = this.view.nodeDOM(d);
1305
1305
  if (!c || !h)
1306
1306
  return;
1307
- const f = c === h ? c.getBoundingClientRect() : Go(
1307
+ const f = c === h ? c.getBoundingClientRect() : Qo(
1308
1308
  c.getBoundingClientRect(),
1309
1309
  h.getBoundingClientRect()
1310
1310
  );
@@ -1317,7 +1317,7 @@ var Jo = class {
1317
1317
  }
1318
1318
  updatePosition() {
1319
1319
  const t = this.virtualElement;
1320
- t && jt(t, this.element, {
1320
+ t && zt(t, this.element, {
1321
1321
  placement: this.floatingUIOptions.placement,
1322
1322
  strategy: this.floatingUIOptions.strategy,
1323
1323
  middleware: this.middlewares
@@ -1376,10 +1376,10 @@ var Jo = class {
1376
1376
  destroy() {
1377
1377
  this.hide(), this.element.removeEventListener("mousedown", this.mousedownHandler, { capture: !0 }), this.view.dom.removeEventListener("dragstart", this.dragstartHandler), window.removeEventListener("resize", this.resizeHandler), this.scrollTarget.removeEventListener("scroll", this.resizeHandler), this.editor.off("focus", this.focusHandler), this.editor.off("blur", this.blurHandler), this.editor.off("transaction", this.transactionHandler), this.floatingUIOptions.onDestroy && this.floatingUIOptions.onDestroy();
1378
1378
  }
1379
- }, Zo = (t) => new It({
1380
- key: typeof t.pluginKey == "string" ? new rt(t.pluginKey) : t.pluginKey,
1381
- view: (e) => new Jo({ view: e, ...t })
1382
- }), Qo = le({
1379
+ }, ei = (t) => new It({
1380
+ key: typeof t.pluginKey == "string" ? new at(t.pluginKey) : t.pluginKey,
1381
+ view: (e) => new ti({ view: e, ...t })
1382
+ }), ni = ce({
1383
1383
  name: "BubbleMenu",
1384
1384
  inheritAttrs: !1,
1385
1385
  props: {
@@ -1417,8 +1417,8 @@ var Jo = class {
1417
1417
  }
1418
1418
  },
1419
1419
  setup(t, { slots: e, attrs: o }) {
1420
- const n = ce(null);
1421
- return de(() => {
1420
+ const n = de(null);
1421
+ return ue(() => {
1422
1422
  const {
1423
1423
  editor: i,
1424
1424
  options: s,
@@ -1429,9 +1429,9 @@ var Jo = class {
1429
1429
  getReferencedVirtualElement: d,
1430
1430
  updateDelay: c
1431
1431
  } = t, h = n.value;
1432
- h && (h.style.visibility = "hidden", h.style.position = "absolute", h.remove(), sn(() => {
1432
+ h && (h.style.visibility = "hidden", h.style.position = "absolute", h.remove(), an(() => {
1433
1433
  i.registerPlugin(
1434
- Zo({
1434
+ ei({
1435
1435
  editor: i,
1436
1436
  element: h,
1437
1437
  options: s,
@@ -1444,15 +1444,15 @@ var Jo = class {
1444
1444
  })
1445
1445
  );
1446
1446
  }));
1447
- }), ue(() => {
1447
+ }), he(() => {
1448
1448
  const { pluginKey: i, editor: s } = t;
1449
1449
  s.unregisterPlugin(i);
1450
1450
  }), () => {
1451
1451
  var i;
1452
- return he("div", { ref: n, ...o }, (i = e.default) == null ? void 0 : i.call(e));
1452
+ return fe("div", { ref: n, ...o }, (i = e.default) == null ? void 0 : i.call(e));
1453
1453
  };
1454
1454
  }
1455
- }), ti = class {
1455
+ }), oi = class {
1456
1456
  constructor({
1457
1457
  editor: t,
1458
1458
  element: e,
@@ -1512,20 +1512,20 @@ var Jo = class {
1512
1512
  }, this.element.tabIndex = 0, a && (this.shouldShow = a), this.element.addEventListener("mousedown", this.mousedownHandler, { capture: !0 }), this.editor.on("focus", this.focusHandler), this.editor.on("blur", this.blurHandler), this.editor.on("transaction", this.transactionHandler), window.addEventListener("resize", this.resizeHandler), this.scrollTarget.addEventListener("scroll", this.resizeHandler), this.update(o, o.state), this.getShouldShow() && (this.show(), this.updatePosition());
1513
1513
  }
1514
1514
  getTextContent(t) {
1515
- return We(t, { textSerializers: qe(this.editor.schema) });
1515
+ return Xe(t, { textSerializers: Ye(this.editor.schema) });
1516
1516
  }
1517
1517
  get middlewares() {
1518
1518
  const t = [];
1519
- return this.floatingUIOptions.flip && t.push(Vt(typeof this.floatingUIOptions.flip != "boolean" ? this.floatingUIOptions.flip : void 0)), this.floatingUIOptions.shift && t.push(
1520
- Ut(typeof this.floatingUIOptions.shift != "boolean" ? this.floatingUIOptions.shift : void 0)
1519
+ return this.floatingUIOptions.flip && t.push(jt(typeof this.floatingUIOptions.flip != "boolean" ? this.floatingUIOptions.flip : void 0)), this.floatingUIOptions.shift && t.push(
1520
+ Vt(typeof this.floatingUIOptions.shift != "boolean" ? this.floatingUIOptions.shift : void 0)
1521
1521
  ), this.floatingUIOptions.offset && t.push(
1522
- Pt(typeof this.floatingUIOptions.offset != "boolean" ? this.floatingUIOptions.offset : void 0)
1523
- ), this.floatingUIOptions.arrow && t.push(Be(this.floatingUIOptions.arrow)), this.floatingUIOptions.size && t.push(He(typeof this.floatingUIOptions.size != "boolean" ? this.floatingUIOptions.size : void 0)), this.floatingUIOptions.autoPlacement && t.push(
1524
- Me(
1522
+ Ut(typeof this.floatingUIOptions.offset != "boolean" ? this.floatingUIOptions.offset : void 0)
1523
+ ), this.floatingUIOptions.arrow && t.push(Ne(this.floatingUIOptions.arrow)), this.floatingUIOptions.size && t.push($e(typeof this.floatingUIOptions.size != "boolean" ? this.floatingUIOptions.size : void 0)), this.floatingUIOptions.autoPlacement && t.push(
1524
+ He(
1525
1525
  typeof this.floatingUIOptions.autoPlacement != "boolean" ? this.floatingUIOptions.autoPlacement : void 0
1526
1526
  )
1527
- ), this.floatingUIOptions.hide && t.push($e(typeof this.floatingUIOptions.hide != "boolean" ? this.floatingUIOptions.hide : void 0)), this.floatingUIOptions.inline && t.push(
1528
- Ne(typeof this.floatingUIOptions.inline != "boolean" ? this.floatingUIOptions.inline : void 0)
1527
+ ), this.floatingUIOptions.hide && t.push(Be(typeof this.floatingUIOptions.hide != "boolean" ? this.floatingUIOptions.hide : void 0)), this.floatingUIOptions.inline && t.push(
1528
+ Pe(typeof this.floatingUIOptions.inline != "boolean" ? this.floatingUIOptions.inline : void 0)
1529
1529
  ), t;
1530
1530
  }
1531
1531
  getShouldShow(t) {
@@ -1551,8 +1551,8 @@ var Jo = class {
1551
1551
  }
1552
1552
  }
1553
1553
  updatePosition() {
1554
- const { selection: t } = this.editor.state, e = re(this.view, t.from, t.to);
1555
- jt({
1554
+ const { selection: t } = this.editor.state, e = ae(this.view, t.from, t.to);
1555
+ zt({
1556
1556
  getBoundingClientRect: () => e,
1557
1557
  getClientRects: () => [e]
1558
1558
  }, this.element, {
@@ -1586,11 +1586,11 @@ var Jo = class {
1586
1586
  destroy() {
1587
1587
  this.hide(), this.element.removeEventListener("mousedown", this.mousedownHandler, { capture: !0 }), window.removeEventListener("resize", this.resizeHandler), this.scrollTarget.removeEventListener("scroll", this.resizeHandler), this.editor.off("focus", this.focusHandler), this.editor.off("blur", this.blurHandler), this.editor.off("transaction", this.transactionHandler), this.floatingUIOptions.onDestroy && this.floatingUIOptions.onDestroy();
1588
1588
  }
1589
- }, ei = (t) => new It({
1590
- key: typeof t.pluginKey == "string" ? new rt(t.pluginKey) : t.pluginKey,
1591
- view: (e) => new ti({ view: e, ...t })
1589
+ }, ii = (t) => new It({
1590
+ key: typeof t.pluginKey == "string" ? new at(t.pluginKey) : t.pluginKey,
1591
+ view: (e) => new oi({ view: e, ...t })
1592
1592
  });
1593
- le({
1593
+ ce({
1594
1594
  name: "FloatingMenu",
1595
1595
  inheritAttrs: !1,
1596
1596
  props: {
@@ -1626,11 +1626,11 @@ le({
1626
1626
  }
1627
1627
  },
1628
1628
  setup(t, { slots: e, attrs: o }) {
1629
- const n = ce(null);
1630
- return de(() => {
1629
+ const n = de(null);
1630
+ return ue(() => {
1631
1631
  const { pluginKey: i, editor: s, updateDelay: r, resizeDelay: a, options: l, appendTo: u, shouldShow: d } = t, c = n.value;
1632
1632
  c && (c.style.visibility = "hidden", c.style.position = "absolute", c.remove(), s.registerPlugin(
1633
- ei({
1633
+ ii({
1634
1634
  pluginKey: i,
1635
1635
  editor: s,
1636
1636
  element: c,
@@ -1641,27 +1641,90 @@ le({
1641
1641
  shouldShow: d
1642
1642
  })
1643
1643
  ));
1644
- }), ue(() => {
1644
+ }), he(() => {
1645
1645
  const { pluginKey: i, editor: s } = t;
1646
1646
  s.unregisterPlugin(i);
1647
1647
  }), () => {
1648
1648
  var i;
1649
- return he("div", { ref: n, ...o }, (i = e.default) == null ? void 0 : i.call(e));
1649
+ return fe("div", { ref: n, ...o }, (i = e.default) == null ? void 0 : i.call(e));
1650
1650
  };
1651
1651
  }
1652
1652
  });
1653
- const ni = {
1653
+ const et = (t) => ({
1654
+ default: null,
1655
+ parseHTML: (e) => e.getAttribute(t),
1656
+ renderHTML: (e) => e[t] ? { [t]: e[t] } : {}
1657
+ }), si = Rn.extend({
1658
+ addAttributes() {
1659
+ var t;
1660
+ return {
1661
+ ...(t = this.parent) == null ? void 0 : t.call(this),
1662
+ border: et("border"),
1663
+ cellpadding: et("cellpadding"),
1664
+ cellspacing: et("cellspacing"),
1665
+ style: et("style")
1666
+ };
1667
+ },
1668
+ renderHTML({ HTMLAttributes: t }) {
1669
+ return ["table", st(this.options.HTMLAttributes, t), ["tbody", 0]];
1670
+ }
1671
+ }), ri = Mn.extend({
1672
+ addAttributes() {
1673
+ var t;
1674
+ return {
1675
+ ...(t = this.parent) == null ? void 0 : t.call(this),
1676
+ style: et("style")
1677
+ };
1678
+ }
1679
+ }), Ue = {
1680
+ style: et("style"),
1681
+ valign: et("valign"),
1682
+ width: et("width")
1683
+ }, ai = $n.extend({
1684
+ addAttributes() {
1685
+ var t;
1686
+ return {
1687
+ ...(t = this.parent) == null ? void 0 : t.call(this),
1688
+ ...Ue
1689
+ };
1690
+ }
1691
+ }), li = Hn.extend({
1692
+ addAttributes() {
1693
+ var t;
1694
+ return {
1695
+ ...(t = this.parent) == null ? void 0 : t.call(this),
1696
+ ...Ue
1697
+ };
1698
+ }
1699
+ }), ci = Bn.extend({
1700
+ parseHTML() {
1701
+ var t;
1702
+ return [
1703
+ ...((t = this.parent) == null ? void 0 : t.call(this)) || [],
1704
+ {
1705
+ tag: "div",
1706
+ consuming: !1,
1707
+ getAttrs: (e) => e.hasAttribute("style") ? {} : !1
1708
+ },
1709
+ {
1710
+ tag: "a",
1711
+ consuming: !1,
1712
+ getAttrs: (e) => e.hasAttribute("style") ? {} : !1
1713
+ }
1714
+ ];
1715
+ }
1716
+ }), di = {
1654
1717
  compatConfig: { MODE: 3 },
1655
1718
  name: "EmojiComponent",
1656
1719
  components: {
1657
- NodeViewWrapper: pt,
1658
- DtEmoji: ye
1720
+ NodeViewWrapper: mt,
1721
+ DtEmoji: we
1659
1722
  },
1660
- props: ft
1723
+ props: pt
1661
1724
  };
1662
- function oi(t, e, o, n, i, s) {
1725
+ function ui(t, e, o, n, i, s) {
1663
1726
  const r = T("dt-emoji"), a = T("node-view-wrapper");
1664
- return _(), I(a, { class: "d-d-inline-block d-va-bottom d-lh0" }, {
1727
+ return _(), A(a, { class: "d-d-inline-block d-va-bottom d-lh0" }, {
1665
1728
  default: C(() => [
1666
1729
  M(r, {
1667
1730
  size: "500",
@@ -1671,11 +1734,11 @@ function oi(t, e, o, n, i, s) {
1671
1734
  _: 1
1672
1735
  });
1673
1736
  }
1674
- const ii = /* @__PURE__ */ q(ni, [["render", oi]]), si = {
1737
+ const hi = /* @__PURE__ */ q(di, [["render", ui]]), fi = {
1675
1738
  compatConfig: { MODE: 3 },
1676
1739
  name: "SuggestionList",
1677
1740
  components: {
1678
- DtListItem: Vn
1741
+ DtListItem: Fn
1679
1742
  },
1680
1743
  props: {
1681
1744
  items: {
@@ -1744,36 +1807,36 @@ const ii = /* @__PURE__ */ q(ni, [["render", oi]]), si = {
1744
1807
  }
1745
1808
  }
1746
1809
  }
1747
- }, ri = { class: "d-popover__dialog d-suggestion-list__container" }, ai = {
1810
+ }, pi = { class: "d-popover__dialog d-suggestion-list__container" }, mi = {
1748
1811
  ref: "suggestionList",
1749
1812
  class: "d-suggestion-list"
1750
1813
  };
1751
- function li(t, e, o, n, i, s) {
1814
+ function gi(t, e, o, n, i, s) {
1752
1815
  const r = T("dt-list-item");
1753
- return _(), et("div", ri, [
1754
- rn(nt("ul", ai, [
1755
- (_(!0), et(an, null, ln(o.items, (a, l) => (_(), I(r, {
1816
+ return _(), nt("div", pi, [
1817
+ ln(ot("ul", mi, [
1818
+ (_(!0), nt(cn, null, dn(o.items, (a, l) => (_(), A(r, {
1756
1819
  key: a.id,
1757
- class: fe([
1820
+ class: pe([
1758
1821
  "d-suggestion-list__item",
1759
1822
  { "d-list-item--highlighted": l === i.selectedIndex }
1760
1823
  ]),
1761
1824
  "navigation-type": "arrow-keys",
1762
1825
  onClick: (u) => s.selectItem(l),
1763
- onKeydown: At(s.onKeyDown, ["prevent"])
1826
+ onKeydown: Dt(s.onKeyDown, ["prevent"])
1764
1827
  }, {
1765
1828
  default: C(() => [
1766
- (_(), I(cn(o.itemComponent), { item: a }, null, 8, ["item"]))
1829
+ (_(), A(un(o.itemComponent), { item: a }, null, 8, ["item"]))
1767
1830
  ]),
1768
1831
  _: 2
1769
1832
  }, 1032, ["class", "onClick", "onKeydown"]))), 128))
1770
1833
  ], 512), [
1771
- [dn, o.items.length]
1834
+ [hn, o.items.length]
1772
1835
  ])
1773
1836
  ]);
1774
1837
  }
1775
- const ci = /* @__PURE__ */ q(si, [["render", li]]), Pe = "top-start", Ue = "650";
1776
- function di() {
1838
+ const yi = /* @__PURE__ */ q(fi, [["render", gi]]), Ve = "top-start", je = "650";
1839
+ function wi() {
1777
1840
  return {
1778
1841
  getBoundingClientRect: () => ({
1779
1842
  width: 0,
@@ -1787,15 +1850,15 @@ function di() {
1787
1850
  })
1788
1851
  };
1789
1852
  }
1790
- function oe(t) {
1853
+ function ie(t) {
1791
1854
  return { getBoundingClientRect: t };
1792
1855
  }
1793
- async function ui(t, e, o = {}) {
1856
+ async function bi(t, e, o = {}) {
1794
1857
  if (!t || !(e != null && e.getBoundingClientRect)) return;
1795
1858
  const {
1796
- placement: n = Pe,
1797
- middleware: i = [Pt(0), Vt(), Ut({ padding: 8 })]
1798
- } = o, { x: s, y: r } = await jt(e, t, {
1859
+ placement: n = Ve,
1860
+ middleware: i = [Ut(0), jt(), Vt({ padding: 8 })]
1861
+ } = o, { x: s, y: r } = await zt(e, t, {
1799
1862
  placement: n,
1800
1863
  middleware: i
1801
1864
  });
@@ -1804,64 +1867,64 @@ async function ui(t, e, o = {}) {
1804
1867
  top: `${r}px`
1805
1868
  });
1806
1869
  }
1807
- function hi(t, e = {}) {
1808
- const { zIndex: o = Ue } = e;
1870
+ function vi(t, e = {}) {
1871
+ const { zIndex: o = je } = e;
1809
1872
  t.style.position = "absolute", t.style.zIndex = o, t.style.display = "none";
1810
1873
  }
1811
- function fi(t) {
1874
+ function xi(t) {
1812
1875
  t && (t.style.display = "block");
1813
1876
  }
1814
- function pi(t) {
1877
+ function Ti(t) {
1815
1878
  t && (t.style.display = "none");
1816
1879
  }
1817
- function mi(t, e) {
1880
+ function _i(t, e) {
1818
1881
  return (o) => {
1819
1882
  o.key === "Escape" && e() && t();
1820
1883
  };
1821
1884
  }
1822
- function gi(t) {
1885
+ function ki(t) {
1823
1886
  document.addEventListener("keydown", t);
1824
1887
  }
1825
- function yi(t) {
1888
+ function Ci(t) {
1826
1889
  document.removeEventListener("keydown", t);
1827
1890
  }
1828
- function wi(t, e, o, n) {
1829
- return new je(t, {
1891
+ function Oi(t, e, o, n) {
1892
+ return new Fe(t, {
1830
1893
  props: {
1831
- itemComponent: un(e),
1894
+ itemComponent: fn(e),
1832
1895
  itemType: o,
1833
1896
  ...n
1834
1897
  },
1835
1898
  editor: n.editor
1836
1899
  });
1837
1900
  }
1838
- function bi(t) {
1901
+ function Ei(t) {
1839
1902
  var e, o;
1840
- t.escHandler && yi(t.escHandler), (e = t.floatingEl) == null || e.remove(), (o = t.component) == null || o.destroy();
1903
+ t.escHandler && Ci(t.escHandler), (e = t.floatingEl) == null || e.remove(), (o = t.component) == null || o.destroy();
1841
1904
  }
1842
- function Ct(t, e, o = {}) {
1905
+ function Ot(t, e, o = {}) {
1843
1906
  const {
1844
- listComponent: n = ci,
1845
- placement: i = Pe,
1846
- zIndex: s = Ue
1907
+ listComponent: n = yi,
1908
+ placement: i = Ve,
1909
+ zIndex: s = je
1847
1910
  } = o;
1848
1911
  return () => {
1849
- let r = null, a = null, l = !1, u = di(), d = null;
1912
+ let r = null, a = null, l = !1, u = wi(), d = null;
1850
1913
  function c() {
1851
- ui(a, u, { placement: i });
1914
+ bi(a, u, { placement: i });
1852
1915
  }
1853
1916
  function h() {
1854
- a && (fi(a), l = !0, c());
1917
+ a && (xi(a), l = !0, c());
1855
1918
  }
1856
1919
  function f() {
1857
- a && (pi(a), l = !1);
1920
+ a && (Ti(a), l = !1);
1858
1921
  }
1859
1922
  return {
1860
1923
  onStart: (p) => {
1861
- r = wi(n, t, e, p), p.clientRect && (a = r.element, hi(a, { zIndex: s }), document.body.appendChild(a), u = oe(p.clientRect), d = mi(f, () => l), gi(d), p.items.length > 0 && h());
1924
+ r = Oi(n, t, e, p), p.clientRect && (a = r.element, vi(a, { zIndex: s }), document.body.appendChild(a), u = ie(p.clientRect), d = _i(f, () => l), ki(d), p.items.length > 0 && h());
1862
1925
  },
1863
1926
  onUpdate(p) {
1864
- r == null || r.updateProps(p), p.items.length > 0 ? h() : f(), p.clientRect && (u = oe(p.clientRect), c());
1927
+ r == null || r.updateProps(p), p.items.length > 0 ? h() : f(), p.clientRect && (u = ie(p.clientRect), c());
1865
1928
  },
1866
1929
  onKeyDown(p) {
1867
1930
  var m;
@@ -1869,17 +1932,17 @@ function Ct(t, e, o = {}) {
1869
1932
  return (m = r == null ? void 0 : r.ref) == null ? void 0 : m.onKeyDown(p);
1870
1933
  },
1871
1934
  onExit() {
1872
- bi({ escHandler: d, floatingEl: a, component: r }), d = null, a = null, r = null;
1935
+ Ei({ escHandler: d, floatingEl: a, component: r }), d = null, a = null, r = null;
1873
1936
  }
1874
1937
  };
1875
1938
  };
1876
1939
  }
1877
- const vi = {
1940
+ const Si = {
1878
1941
  compatConfig: { MODE: 3 },
1879
1942
  name: "EmojiSuggestion",
1880
1943
  components: {
1881
- DtEmoji: ye,
1882
- DtStack: gt
1944
+ DtEmoji: we,
1945
+ DtStack: yt
1883
1946
  },
1884
1947
  props: {
1885
1948
  item: {
@@ -1888,9 +1951,9 @@ const vi = {
1888
1951
  }
1889
1952
  }
1890
1953
  };
1891
- function xi(t, e, o, n, i, s) {
1954
+ function Li(t, e, o, n, i, s) {
1892
1955
  const r = T("dt-emoji"), a = T("dt-stack");
1893
- return _(), I(a, {
1956
+ return _(), A(a, {
1894
1957
  direction: "row",
1895
1958
  gap: "400"
1896
1959
  }, {
@@ -1899,20 +1962,20 @@ function xi(t, e, o, n, i, s) {
1899
1962
  size: "200",
1900
1963
  code: o.item.code
1901
1964
  }, null, 8, ["code"]),
1902
- at(" " + $(o.item.code), 1)
1965
+ lt(" " + $(o.item.code), 1)
1903
1966
  ]),
1904
1967
  _: 1
1905
1968
  });
1906
1969
  }
1907
- const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
1970
+ const Ai = /* @__PURE__ */ q(Si, [["render", Li]]), Ii = 20, Di = (t, e, o) => {
1908
1971
  var a, l;
1909
1972
  const n = (a = t.shortname) == null ? void 0 : a.replaceAll(":", ""), i = (l = e.shortname) == null ? void 0 : l.replaceAll(":", ""), s = n.startsWith(o), r = i.startsWith(o);
1910
1973
  return s && !r ? -1 : !s && r ? 1 : n.localeCompare(i);
1911
- }, Ci = {
1974
+ }, Ri = {
1912
1975
  items: ({ query: t }) => {
1913
1976
  if (t.length < 2)
1914
1977
  return [];
1915
- const e = Object.values(Bn());
1978
+ const e = Object.values(Un());
1916
1979
  return t = t.toLowerCase(), e.filter(
1917
1980
  (n) => {
1918
1981
  var i;
@@ -1922,7 +1985,7 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
1922
1985
  ...n.keywords || []
1923
1986
  ].some((s) => s && s.startsWith(t));
1924
1987
  }
1925
- ).splice(0, _i).sort((n, i) => ki(n, i, t)).map((n) => ({ code: n.shortname }));
1988
+ ).splice(0, Ii).sort((n, i) => Di(n, i, t)).map((n) => ({ code: n.shortname }));
1926
1989
  },
1927
1990
  command: ({ editor: t, range: e, props: o }) => {
1928
1991
  var s, r;
@@ -1934,15 +1997,15 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
1934
1997
  }
1935
1998
  ]).run(), (r = window.getSelection()) == null || r.collapseToEnd();
1936
1999
  },
1937
- render: Ct(Ti, "emoji")
1938
- }, Oi = /(:\w+:)$/, Ei = new RegExp(ge + "$"), Si = (t) => {
1939
- if (t && Dt(t[0]))
2000
+ render: Ot(Ai, "emoji")
2001
+ }, Mi = /(:\w+:)$/, Hi = new RegExp(ye + "$"), $i = (t) => {
2002
+ if (t && Rt(t[0]))
1940
2003
  return { text: t[2] || t[0] };
1941
- }, Li = (t) => [...t.matchAll(Un)].filter((o) => Dt(o[0])).map((o) => ({
2004
+ }, Bi = (t) => [...t.matchAll(zn)].filter((o) => Rt(o[0])).map((o) => ({
1942
2005
  index: o.index,
1943
2006
  text: o[0],
1944
2007
  match: o
1945
- })), Ii = ae.create({
2008
+ })), Ni = le.create({
1946
2009
  name: "emoji",
1947
2010
  addOptions() {
1948
2011
  return {
@@ -1954,7 +2017,7 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
1954
2017
  selectable: !1,
1955
2018
  atom: !0,
1956
2019
  addNodeView() {
1957
- return mt(ii);
2020
+ return gt(hi);
1958
2021
  },
1959
2022
  addAttributes() {
1960
2023
  return {
@@ -1971,18 +2034,18 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
1971
2034
  ];
1972
2035
  },
1973
2036
  renderText({ node: t }) {
1974
- return Pn(Dt(t.attrs.code).unicode_output);
2037
+ return jn(Rt(t.attrs.code).unicode_output);
1975
2038
  },
1976
2039
  renderHTML({ HTMLAttributes: t }) {
1977
2040
  return ["emoji-component", st(this.options.HTMLAttributes, t)];
1978
2041
  },
1979
2042
  addInputRules() {
1980
2043
  return [
1981
- new Xe({
2044
+ new Ge({
1982
2045
  find: (t) => {
1983
- const e = t.match(Oi) || t.match(Ei);
2046
+ const e = t.match(Mi) || t.match(Hi);
1984
2047
  if (e)
1985
- return Si(e);
2048
+ return $i(e);
1986
2049
  },
1987
2050
  handler: ({ state: t, range: e, match: o }) => {
1988
2051
  const { tr: n } = t, i = e.from, s = e.to;
@@ -1993,8 +2056,8 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
1993
2056
  },
1994
2057
  addPasteRules() {
1995
2058
  return [
1996
- Et({
1997
- find: Li,
2059
+ St({
2060
+ find: Bi,
1998
2061
  type: this.type,
1999
2062
  getAttributes(t) {
2000
2063
  return {
@@ -2002,8 +2065,8 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
2002
2065
  };
2003
2066
  }
2004
2067
  }),
2005
- Et({
2006
- find: Nn,
2068
+ St({
2069
+ find: Vn,
2007
2070
  type: this.type,
2008
2071
  getAttributes(t) {
2009
2072
  return {
@@ -2015,12 +2078,12 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
2015
2078
  },
2016
2079
  addProseMirrorPlugins() {
2017
2080
  return [
2018
- $n({
2081
+ Pn({
2019
2082
  char: ":",
2020
- pluginKey: new rt("emoji"),
2083
+ pluginKey: new at("emoji"),
2021
2084
  editor: this.editor,
2022
2085
  ...this.options.suggestion,
2023
- ...Ci
2086
+ ...Ri
2024
2087
  })
2025
2088
  ];
2026
2089
  },
@@ -2037,7 +2100,7 @@ const Ti = /* @__PURE__ */ q(vi, [["render", xi]]), _i = 20, ki = (t, e, o) => {
2037
2100
  };
2038
2101
  }
2039
2102
  });
2040
- function Ai(t, e, o = () => !0) {
2103
+ function Pi(t, e, o = () => !0) {
2041
2104
  const n = [];
2042
2105
  e.lastIndex = 0;
2043
2106
  let i;
@@ -2045,10 +2108,10 @@ function Ai(t, e, o = () => !0) {
2045
2108
  o(t, i) && n.push(i);
2046
2109
  return n;
2047
2110
  }
2048
- function Di(t, e) {
2111
+ function Ui(t, e) {
2049
2112
  return !["#", "@"].includes(t.charAt(e.index)) && !["#", "@"].includes(t.charAt(e.index - 1));
2050
2113
  }
2051
- function Ri(t) {
2114
+ function Vi(t) {
2052
2115
  const e = new RegExp(
2053
2116
  "(?:" + [
2054
2117
  `[!?.,:;'"]`,
@@ -2058,7 +2121,7 @@ function Ri(t) {
2058
2121
  );
2059
2122
  return t.replace(e, "");
2060
2123
  }
2061
- function Mi(t, e) {
2124
+ function ji(t, e) {
2062
2125
  const o = t.slice(0, e + 1).search(/\S+\s*$/), n = t.slice(e).search(/\s/);
2063
2126
  if (n < 0) {
2064
2127
  const i = t.slice(o);
@@ -2074,61 +2137,61 @@ function Mi(t, e) {
2074
2137
  to: n + e
2075
2138
  };
2076
2139
  }
2077
- function Lt(t, e, o, n) {
2078
- const i = Mi(t, e);
2140
+ function At(t, e, o, n) {
2141
+ const i = ji(t, e);
2079
2142
  if (n.lastIndex = 0, !n.test(i.text))
2080
2143
  return i;
2081
2144
  const s = o === "left" ? i.from - 1 : i.to + 1;
2082
- return s <= 0 || s >= t.length || s === e ? i : Lt(t, s, o, n);
2145
+ return s <= 0 || s >= t.length || s === e ? i : At(t, s, o, n);
2083
2146
  }
2084
- function Hi(t, e, o, n) {
2085
- const i = Math.max(t.from - 1, 0), s = Math.min(t.to + 1, e.content.size), r = Ye(i, s, e);
2147
+ function zi(t, e, o, n) {
2148
+ const i = Math.max(t.from - 1, 0), s = Math.min(t.to + 1, e.content.size), r = Je(i, s, e);
2086
2149
  for (const a of r)
2087
2150
  a.mark.type === n && o.removeMark(a.from, a.to, n);
2088
2151
  }
2089
- const ie = zn(1, 15);
2090
- function se(t, e, o, n, i, s) {
2152
+ const se = Wn(1, 15);
2153
+ function re(t, e, o, n, i, s) {
2091
2154
  if (!t)
2092
2155
  return;
2093
2156
  let r = o - e - 1;
2094
2157
  r = r < 0 ? 0 : r;
2095
- const a = n - e, l = Lt(
2158
+ const a = n - e, l = At(
2096
2159
  t,
2097
2160
  r,
2098
2161
  "left",
2099
- ie
2100
- ), u = Lt(
2162
+ se
2163
+ ), u = At(
2101
2164
  t,
2102
2165
  a,
2103
2166
  "right",
2104
- ie
2167
+ se
2105
2168
  ), d = t.slice(l.from, u.to);
2106
- Ai(d, jn, Di).forEach((h) => {
2107
- const f = Ri(h[0]), p = e + l.from + h.index + 1, m = p + f.length;
2169
+ Pi(d, Kn, Ui).forEach((h) => {
2170
+ const f = Vi(h[0]), p = e + l.from + h.index + 1, m = p + f.length;
2108
2171
  i.addMark(p, m, s.create());
2109
2172
  });
2110
2173
  }
2111
- function $i(t) {
2174
+ function Fi(t) {
2112
2175
  let e = !1;
2113
2176
  return new It({
2114
- key: new rt("autolink"),
2177
+ key: new at("autolink"),
2115
2178
  appendTransaction: (o, n, i) => {
2116
2179
  const s = o.some((d) => d.docChanged) && !n.doc.eq(i.doc);
2117
2180
  if (e && !s)
2118
2181
  return;
2119
2182
  const { tr: r } = i, { textContent: a } = i.doc;
2120
- e || se(a, 0, 0, a.length, r, t.type), e = !0;
2121
- const l = Ge(
2183
+ e || re(a, 0, 0, a.length, r, t.type), e = !0;
2184
+ const l = Ze(
2122
2185
  n.doc,
2123
2186
  [...o]
2124
2187
  );
2125
- return Je(l).forEach(({ oldRange: d, newRange: c }) => {
2126
- Hi(c, i.doc, r, t.type), Ze(
2188
+ return Qe(l).forEach(({ oldRange: d, newRange: c }) => {
2189
+ zi(c, i.doc, r, t.type), tn(
2127
2190
  i.doc,
2128
2191
  c,
2129
2192
  (f) => f.isTextblock
2130
2193
  ).forEach(({ node: f, pos: p }) => {
2131
- se(
2194
+ re(
2132
2195
  f.textContent,
2133
2196
  p,
2134
2197
  d.from,
@@ -2141,10 +2204,10 @@ function $i(t) {
2141
2204
  }
2142
2205
  });
2143
2206
  }
2144
- const Bi = {
2207
+ const Ki = {
2145
2208
  class: "d-link d-c-text d-d-inline-block d-wb-break-all",
2146
2209
  rel: "noopener noreferrer nofollow"
2147
- }, Ni = Qe.create({
2210
+ }, Wi = en.create({
2148
2211
  name: "CustomLink",
2149
2212
  renderHTML({ HTMLAttributes: t }) {
2150
2213
  return [
@@ -2152,7 +2215,7 @@ const Bi = {
2152
2215
  st(
2153
2216
  this.options.HTMLAttributes,
2154
2217
  t,
2155
- Bi
2218
+ Ki
2156
2219
  )
2157
2220
  ];
2158
2221
  },
@@ -2161,10 +2224,10 @@ const Bi = {
2161
2224
  },
2162
2225
  addProseMirrorPlugins() {
2163
2226
  return [
2164
- $i({ type: this.type })
2227
+ Fi({ type: this.type })
2165
2228
  ];
2166
2229
  }
2167
- }), Pi = Kn.extend({
2230
+ }), qi = Xn.extend({
2168
2231
  name: "ConfigurableImage",
2169
2232
  addAttributes() {
2170
2233
  return {
@@ -2188,21 +2251,63 @@ const Bi = {
2188
2251
  }
2189
2252
  };
2190
2253
  }
2191
- }).configure({ inline: !0, allowBase64: !0 }), Ui = me.extend({
2254
+ }).configure({ inline: !0, allowBase64: !0 }), Xi = /* @__PURE__ */ new Set([
2255
+ "address",
2256
+ "article",
2257
+ "aside",
2258
+ "blockquote",
2259
+ "dd",
2260
+ "details",
2261
+ "dialog",
2262
+ "div",
2263
+ "dl",
2264
+ "dt",
2265
+ "fieldset",
2266
+ "figcaption",
2267
+ "figure",
2268
+ "footer",
2269
+ "form",
2270
+ "h1",
2271
+ "h2",
2272
+ "h3",
2273
+ "h4",
2274
+ "h5",
2275
+ "h6",
2276
+ "header",
2277
+ "hgroup",
2278
+ "hr",
2279
+ "li",
2280
+ "main",
2281
+ "nav",
2282
+ "ol",
2283
+ "p",
2284
+ "pre",
2285
+ "section",
2286
+ "table",
2287
+ "ul"
2288
+ ]), Yi = ge.extend({
2192
2289
  parseHTML() {
2193
- return [{ tag: "div" }];
2290
+ return [{
2291
+ tag: "div",
2292
+ getAttrs: (t) => {
2293
+ for (const e of t.children)
2294
+ if (Xi.has(e.tagName.toLowerCase()))
2295
+ return !1;
2296
+ return null;
2297
+ }
2298
+ }];
2194
2299
  },
2195
2300
  renderHTML({ HTMLAttributes: t }) {
2196
2301
  return ["div", st(this.options.HTMLAttributes, t), 0];
2197
2302
  }
2198
- }), Vi = {
2303
+ }), Gi = {
2199
2304
  compatConfig: { MODE: 3 },
2200
2305
  name: "MentionComponent",
2201
2306
  components: {
2202
- NodeViewWrapper: pt,
2203
- DtLink: we
2307
+ NodeViewWrapper: mt,
2308
+ DtLink: be
2204
2309
  },
2205
- props: ft,
2310
+ props: pt,
2206
2311
  computed: {
2207
2312
  text() {
2208
2313
  return "@" + this.$props.node.attrs.name;
@@ -2228,20 +2333,20 @@ const Bi = {
2228
2333
  }
2229
2334
  }
2230
2335
  };
2231
- function ji(t, e, o, n, i, s) {
2336
+ function Ji(t, e, o, n, i, s) {
2232
2337
  const r = T("dt-link"), a = T("node-view-wrapper");
2233
- return _(), I(a, { class: "d-d-inline-block" }, {
2338
+ return _(), A(a, { class: "d-d-inline-block" }, {
2234
2339
  default: C(() => [
2235
2340
  M(r, {
2236
2341
  kind: "mention",
2237
- onClick: At(s.handleClick, ["prevent"]),
2342
+ onClick: Dt(s.handleClick, ["prevent"]),
2238
2343
  onMouseenter: s.handleMouseEnter,
2239
2344
  onMouseleave: s.handleMouseLeave,
2240
2345
  onFocusin: s.handleMouseEnter,
2241
2346
  onFocusout: s.handleMouseLeave
2242
2347
  }, {
2243
2348
  default: C(() => [
2244
- at($(s.text), 1)
2349
+ lt($(s.text), 1)
2245
2350
  ]),
2246
2351
  _: 1
2247
2352
  }, 8, ["onClick", "onMouseenter", "onMouseleave", "onFocusin", "onFocusout"])
@@ -2249,9 +2354,9 @@ function ji(t, e, o, n, i, s) {
2249
2354
  _: 1
2250
2355
  });
2251
2356
  }
2252
- const zi = /* @__PURE__ */ q(Vi, [["render", ji]]), Fi = Rt.extend({
2357
+ const Zi = /* @__PURE__ */ q(Gi, [["render", Ji]]), Qi = Mt.extend({
2253
2358
  addNodeView() {
2254
- return mt(zi);
2359
+ return gt(Zi);
2255
2360
  },
2256
2361
  parseHTML() {
2257
2362
  return [
@@ -2285,18 +2390,18 @@ const zi = /* @__PURE__ */ q(Vi, [["render", ji]]), Fi = Rt.extend({
2285
2390
  }).configure({
2286
2391
  suggestion: {
2287
2392
  char: "@",
2288
- pluginKey: new rt("mentionSuggestion")
2393
+ pluginKey: new at("mentionSuggestion")
2289
2394
  }
2290
- }), Ki = {
2395
+ }), ts = {
2291
2396
  compatConfig: { MODE: 3 },
2292
2397
  name: "ChannelComponent",
2293
2398
  components: {
2294
- NodeViewWrapper: pt,
2295
- DtLink: we,
2296
- DtIconLock: Wn,
2297
- DtStack: gt
2399
+ NodeViewWrapper: mt,
2400
+ DtLink: be,
2401
+ DtIconLock: Yn,
2402
+ DtStack: yt
2298
2403
  },
2299
- props: ft,
2404
+ props: pt,
2300
2405
  computed: {
2301
2406
  text() {
2302
2407
  return this.$props.node.attrs.locked ? this.$props.node.attrs.name : "#" + this.$props.node.attrs.name;
@@ -2314,13 +2419,13 @@ const zi = /* @__PURE__ */ q(Vi, [["render", ji]]), Fi = Rt.extend({
2314
2419
  }
2315
2420
  }
2316
2421
  };
2317
- function Wi(t, e, o, n, i, s) {
2422
+ function es(t, e, o, n, i, s) {
2318
2423
  const r = T("dt-icon-lock"), a = T("dt-stack"), l = T("dt-link"), u = T("node-view-wrapper");
2319
- return _(), I(u, { class: "d-d-inline-block" }, {
2424
+ return _(), A(u, { class: "d-d-inline-block" }, {
2320
2425
  default: C(() => [
2321
2426
  M(l, {
2322
2427
  kind: "mention",
2323
- onClick: At(s.handleClick, ["prevent"])
2428
+ onClick: Dt(s.handleClick, ["prevent"])
2324
2429
  }, {
2325
2430
  default: C(() => [
2326
2431
  M(a, {
@@ -2328,11 +2433,11 @@ function Wi(t, e, o, n, i, s) {
2328
2433
  gap: "0"
2329
2434
  }, {
2330
2435
  default: C(() => [
2331
- t.$props.node.attrs.locked ? (_(), I(r, {
2436
+ t.$props.node.attrs.locked ? (_(), A(r, {
2332
2437
  key: 0,
2333
2438
  size: "200"
2334
- })) : it("", !0),
2335
- nt("span", null, $(s.text), 1)
2439
+ })) : rt("", !0),
2440
+ ot("span", null, $(s.text), 1)
2336
2441
  ]),
2337
2442
  _: 1
2338
2443
  })
@@ -2343,10 +2448,10 @@ function Wi(t, e, o, n, i, s) {
2343
2448
  _: 1
2344
2449
  });
2345
2450
  }
2346
- const qi = /* @__PURE__ */ q(Ki, [["render", Wi]]), Xi = Rt.extend({
2451
+ const ns = /* @__PURE__ */ q(ts, [["render", es]]), os = Mt.extend({
2347
2452
  name: "channel",
2348
2453
  addNodeView() {
2349
- return mt(qi);
2454
+ return gt(ns);
2350
2455
  },
2351
2456
  parseHTML() {
2352
2457
  return [
@@ -2380,16 +2485,16 @@ const qi = /* @__PURE__ */ q(Ki, [["render", Wi]]), Xi = Rt.extend({
2380
2485
  }).configure({
2381
2486
  suggestion: {
2382
2487
  char: "#",
2383
- pluginKey: new rt("channelSuggestion")
2488
+ pluginKey: new at("channelSuggestion")
2384
2489
  }
2385
- }), Yi = {
2490
+ }), is = {
2386
2491
  compatConfig: { MODE: 3 },
2387
2492
  name: "SlashCommandsComponent",
2388
2493
  components: {
2389
- NodeViewWrapper: pt
2494
+ NodeViewWrapper: mt
2390
2495
  },
2391
2496
  props: {
2392
- ...ft
2497
+ ...pt
2393
2498
  },
2394
2499
  emits: ["selected-command"],
2395
2500
  computed: {
@@ -2405,23 +2510,23 @@ const qi = /* @__PURE__ */ q(Ki, [["render", Wi]]), Xi = Rt.extend({
2405
2510
  e && typeof e == "function" && e(t);
2406
2511
  }
2407
2512
  };
2408
- function Gi(t, e, o, n, i, s) {
2513
+ function ss(t, e, o, n, i, s) {
2409
2514
  const r = T("node-view-wrapper");
2410
- return _(), I(r, { class: "d-d-inline-block" }, {
2515
+ return _(), A(r, { class: "d-d-inline-block" }, {
2411
2516
  default: C(() => [
2412
- at($(s.text), 1)
2517
+ lt($(s.text), 1)
2413
2518
  ]),
2414
2519
  _: 1
2415
2520
  });
2416
2521
  }
2417
- const Ji = /* @__PURE__ */ q(Yi, [["render", Gi]]), Zi = (t, e) => [...t.matchAll(e)].map((n) => {
2522
+ const rs = /* @__PURE__ */ q(is, [["render", ss]]), as = (t, e) => [...t.matchAll(e)].map((n) => {
2418
2523
  let i = n[2];
2419
2524
  return i.endsWith(" ") || (i += " "), {
2420
2525
  index: n.index,
2421
2526
  text: i,
2422
2527
  match: n
2423
2528
  };
2424
- }), Qi = Rt.extend({
2529
+ }), ls = Mt.extend({
2425
2530
  name: "slash-commands",
2426
2531
  group: "inline",
2427
2532
  inline: !0,
@@ -2438,7 +2543,7 @@ const Ji = /* @__PURE__ */ q(Yi, [["render", Gi]]), Zi = (t, e) => [...t.matchAl
2438
2543
  };
2439
2544
  },
2440
2545
  addNodeView() {
2441
- return mt(Ji);
2546
+ return gt(rs);
2442
2547
  },
2443
2548
  parseHTML() {
2444
2549
  return [
@@ -2470,7 +2575,7 @@ const Ji = /* @__PURE__ */ q(Yi, [["render", Gi]]), Zi = (t, e) => [...t.matchAl
2470
2575
  var o;
2471
2576
  const t = (o = this.options.suggestion) == null ? void 0 : o.items({ query: "" }).map((n) => n.command), e = new RegExp(`^((?:\\/)(${t.join("|")})) $`);
2472
2577
  return [
2473
- tn({
2578
+ nn({
2474
2579
  find: e,
2475
2580
  type: this.type,
2476
2581
  getAttributes(n) {
@@ -2483,8 +2588,8 @@ const Ji = /* @__PURE__ */ q(Yi, [["render", Gi]]), Zi = (t, e) => [...t.matchAl
2483
2588
  var o;
2484
2589
  const t = (o = this.options.suggestion) == null ? void 0 : o.items({ query: "" }).map((n) => n.command), e = new RegExp(`^((?:\\/)(${t.join("|")})) ?$`, "g");
2485
2590
  return [
2486
- Et({
2487
- find: (n) => Zi(n, e),
2591
+ St({
2592
+ find: (n) => as(n, e),
2488
2593
  type: this.type,
2489
2594
  getAttributes(n) {
2490
2595
  return { command: n[0].trim() };
@@ -2495,22 +2600,22 @@ const Ji = /* @__PURE__ */ q(Yi, [["render", Gi]]), Zi = (t, e) => [...t.matchAl
2495
2600
  }).configure({
2496
2601
  suggestion: {
2497
2602
  char: "/",
2498
- pluginKey: new rt("slashCommandSuggestion")
2603
+ pluginKey: new at("slashCommandSuggestion")
2499
2604
  }
2500
- }), ts = 100, es = {
2605
+ }), cs = 100, ds = {
2501
2606
  name: "VariableComponent",
2502
2607
  components: {
2503
- DtBadge: Yn,
2504
- DtButton: ve,
2505
- DtPopover: Xn,
2506
- DtInput: qn,
2507
- NodeViewWrapper: pt
2608
+ DtBadge: Zn,
2609
+ DtButton: xe,
2610
+ DtPopover: Jn,
2611
+ DtInput: Gn,
2612
+ NodeViewWrapper: mt
2508
2613
  },
2509
- props: ft,
2614
+ props: pt,
2510
2615
  data() {
2511
2616
  return {
2512
- i18n: new be(),
2513
- MAX_VARIABLE_ALT_LENGTH: ts
2617
+ i18n: new ve(),
2618
+ MAX_VARIABLE_ALT_LENGTH: cs
2514
2619
  };
2515
2620
  },
2516
2621
  computed: {
@@ -2550,11 +2655,11 @@ const Ji = /* @__PURE__ */ q(Yi, [["render", Gi]]), Zi = (t, e) => [...t.matchAl
2550
2655
  }
2551
2656
  }
2552
2657
  };
2553
- function ns(t, e, o, n, i, s) {
2658
+ function us(t, e, o, n, i, s) {
2554
2659
  const r = T("dt-badge"), a = T("dt-button"), l = T("dt-input"), u = T("dt-popover"), d = T("node-view-wrapper");
2555
- return _(), I(d, { class: "d-d-inline-block" }, {
2660
+ return _(), A(d, { class: "d-d-inline-block" }, {
2556
2661
  default: C(() => [
2557
- s.enableAltText ? (_(), I(u, {
2662
+ s.enableAltText ? (_(), A(u, {
2558
2663
  key: 0,
2559
2664
  padding: "small",
2560
2665
  "navigation-type": "arrow-keys",
@@ -2562,7 +2667,7 @@ function ns(t, e, o, n, i, s) {
2562
2667
  modal: !1
2563
2668
  }, {
2564
2669
  anchor: C(({ attrs: c }) => [
2565
- M(a, pe(c, { kind: "unstyled" }), {
2670
+ M(a, me(c, { kind: "unstyled" }), {
2566
2671
  default: C(() => [
2567
2672
  M(r, {
2568
2673
  text: s.badgeLabel,
@@ -2588,11 +2693,11 @@ function ns(t, e, o, n, i, s) {
2588
2693
  limitMaxLength: !0
2589
2694
  }
2590
2695
  },
2591
- onKeyup: hn((h) => c(), ["enter"])
2696
+ onKeyup: pn((h) => c(), ["enter"])
2592
2697
  }, null, 8, ["modelValue", "label", "placeholder", "validate", "onKeyup"])
2593
2698
  ]),
2594
2699
  _: 1
2595
- })) : (_(), I(r, {
2700
+ })) : (_(), A(r, {
2596
2701
  key: 1,
2597
2702
  text: s.badgeLabel,
2598
2703
  contenteditable: "false"
@@ -2601,7 +2706,7 @@ function ns(t, e, o, n, i, s) {
2601
2706
  _: 1
2602
2707
  });
2603
2708
  }
2604
- const os = /* @__PURE__ */ q(es, [["render", ns]]), is = ae.create({
2709
+ const hs = /* @__PURE__ */ q(ds, [["render", us]]), fs = le.create({
2605
2710
  name: "variable",
2606
2711
  group: "inline",
2607
2712
  inline: !0,
@@ -2614,7 +2719,7 @@ const os = /* @__PURE__ */ q(es, [["render", ns]]), is = ae.create({
2614
2719
  };
2615
2720
  },
2616
2721
  addNodeView() {
2617
- return mt(os);
2722
+ return gt(hs);
2618
2723
  },
2619
2724
  addAttributes() {
2620
2725
  return {
@@ -2673,12 +2778,12 @@ const os = /* @__PURE__ */ q(es, [["render", ns]]), is = ae.create({
2673
2778
  })
2674
2779
  };
2675
2780
  }
2676
- }), ss = {
2781
+ }), ps = {
2677
2782
  compatConfig: { MODE: 3 },
2678
2783
  name: "MentionSuggestion",
2679
2784
  components: {
2680
- DtAvatar: Zn,
2681
- DtStack: gt
2785
+ DtAvatar: eo,
2786
+ DtStack: yt
2682
2787
  },
2683
2788
  props: {
2684
2789
  item: {
@@ -2714,16 +2819,16 @@ const os = /* @__PURE__ */ q(es, [["render", ns]]), is = ae.create({
2714
2819
  return this.item.showDetails;
2715
2820
  }
2716
2821
  }
2717
- }, rs = { class: "d-mention-suggestion__name" }, as = {
2822
+ }, ms = { class: "d-mention-suggestion__name" }, gs = {
2718
2823
  key: 1,
2719
2824
  class: "d-mention-suggestion__divider"
2720
- }, ls = {
2825
+ }, ys = {
2721
2826
  key: 2,
2722
2827
  class: "d-mention-suggestion__status"
2723
2828
  };
2724
- function cs(t, e, o, n, i, s) {
2829
+ function ws(t, e, o, n, i, s) {
2725
2830
  const r = T("dt-avatar"), a = T("dt-stack");
2726
- return _(), I(a, {
2831
+ return _(), A(a, {
2727
2832
  direction: "row",
2728
2833
  class: "d-mention-suggestion__container",
2729
2834
  gap: "400"
@@ -2742,23 +2847,23 @@ function cs(t, e, o, n, i, s) {
2742
2847
  gap: "100"
2743
2848
  }, {
2744
2849
  default: C(() => [
2745
- nt("span", rs, $(s.name), 1),
2746
- s.showDetails ? (_(), I(a, {
2850
+ ot("span", ms, $(s.name), 1),
2851
+ s.showDetails ? (_(), A(a, {
2747
2852
  key: 0,
2748
2853
  direction: "row",
2749
2854
  gap: "300",
2750
2855
  class: "d-label--sm-plain"
2751
2856
  }, {
2752
2857
  default: C(() => [
2753
- s.presenceText ? (_(), et("span", {
2858
+ s.presenceText ? (_(), nt("span", {
2754
2859
  key: 0,
2755
- class: fe(["d-mention-suggestion__presence", [s.presenceFontColorClass]])
2756
- }, $(s.presenceText), 3)) : it("", !0),
2757
- s.status && s.presenceText ? (_(), et("div", as, " • ")) : it("", !0),
2758
- s.status ? (_(), et("div", ls, $(s.status), 1)) : it("", !0)
2860
+ class: pe(["d-mention-suggestion__presence", [s.presenceFontColorClass]])
2861
+ }, $(s.presenceText), 3)) : rt("", !0),
2862
+ s.status && s.presenceText ? (_(), nt("div", gs, " • ")) : rt("", !0),
2863
+ s.status ? (_(), nt("div", ys, $(s.status), 1)) : rt("", !0)
2759
2864
  ]),
2760
2865
  _: 1
2761
- })) : it("", !0)
2866
+ })) : rt("", !0)
2762
2867
  ]),
2763
2868
  _: 1
2764
2869
  })
@@ -2766,19 +2871,19 @@ function cs(t, e, o, n, i, s) {
2766
2871
  _: 1
2767
2872
  });
2768
2873
  }
2769
- const ds = /* @__PURE__ */ q(ss, [["render", cs]]), us = {
2874
+ const bs = /* @__PURE__ */ q(ps, [["render", ws]]), vs = {
2770
2875
  // This function comes from the user and passed to the editor directly.
2771
2876
  // This will also activate the mention plugin on the editor
2772
2877
  // items: ({ query }) => { return [] },
2773
2878
  allowSpaces: !0,
2774
- render: Ct(ds, "mention")
2775
- }, hs = {
2879
+ render: Ot(bs, "mention")
2880
+ }, xs = {
2776
2881
  compatConfig: { MODE: 3 },
2777
2882
  name: "ChannelSuggestion",
2778
2883
  components: {
2779
- DtStack: gt,
2780
- DtIconHash: Qn,
2781
- DtIconLock: to
2884
+ DtStack: yt,
2885
+ DtIconHash: no,
2886
+ DtIconLock: oo
2782
2887
  },
2783
2888
  props: {
2784
2889
  item: {
@@ -2792,32 +2897,32 @@ const ds = /* @__PURE__ */ q(ss, [["render", cs]]), us = {
2792
2897
  }
2793
2898
  }
2794
2899
  };
2795
- function fs(t, e, o, n, i, s) {
2900
+ function Ts(t, e, o, n, i, s) {
2796
2901
  const r = T("dt-icon-hash"), a = T("dt-icon-lock"), l = T("dt-stack");
2797
- return _(), I(l, {
2902
+ return _(), A(l, {
2798
2903
  direction: "row",
2799
2904
  gap: "400"
2800
2905
  }, {
2801
2906
  default: C(() => [
2802
- o.item.locked ? (_(), I(a, {
2907
+ o.item.locked ? (_(), A(a, {
2803
2908
  key: 1,
2804
2909
  size: "300"
2805
- })) : (_(), I(r, {
2910
+ })) : (_(), A(r, {
2806
2911
  key: 0,
2807
2912
  size: "300"
2808
2913
  })),
2809
- nt("span", null, $(s.name), 1)
2914
+ ot("span", null, $(s.name), 1)
2810
2915
  ]),
2811
2916
  _: 1
2812
2917
  });
2813
2918
  }
2814
- const ps = /* @__PURE__ */ q(hs, [["render", fs]]), ms = {
2919
+ const _s = /* @__PURE__ */ q(xs, [["render", Ts]]), ks = {
2815
2920
  // This function comes from the user and passed to the editor directly.
2816
2921
  // This will also activate the mention plugin on the editor
2817
2922
  // items: ({ query }) => { return [] },
2818
2923
  allowSpaces: !0,
2819
- render: Ct(ps, "channel")
2820
- }, gs = {
2924
+ render: Ot(_s, "channel")
2925
+ }, Cs = {
2821
2926
  compatConfig: { MODE: 3 },
2822
2927
  name: "SlashCommandSuggestion",
2823
2928
  props: {
@@ -2837,31 +2942,31 @@ const ps = /* @__PURE__ */ q(hs, [["render", fs]]), ms = {
2837
2942
  return this.item.parametersExample;
2838
2943
  }
2839
2944
  }
2840
- }, ys = { class: "d-body--md-compact" }, ws = { key: 0 }, bs = { class: "d-body--sm d-fc-tertiary" };
2841
- function vs(t, e, o, n, i, s) {
2842
- return _(), et("div", null, [
2843
- nt("div", ys, [
2844
- nt("span", null, "/" + $(s.command), 1),
2845
- s.parametersExample ? (_(), et("span", ws, $(s.parametersExample), 1)) : it("", !0)
2945
+ }, Os = { class: "d-body--md-compact" }, Es = { key: 0 }, Ss = { class: "d-body--sm d-fc-tertiary" };
2946
+ function Ls(t, e, o, n, i, s) {
2947
+ return _(), nt("div", null, [
2948
+ ot("div", Os, [
2949
+ ot("span", null, "/" + $(s.command), 1),
2950
+ s.parametersExample ? (_(), nt("span", Es, $(s.parametersExample), 1)) : rt("", !0)
2846
2951
  ]),
2847
- nt("div", bs, $(s.description), 1)
2952
+ ot("div", Ss, $(s.description), 1)
2848
2953
  ]);
2849
2954
  }
2850
- const xs = /* @__PURE__ */ q(gs, [["render", vs]]), Ts = {
2955
+ const As = /* @__PURE__ */ q(Cs, [["render", Ls]]), Is = {
2851
2956
  // This function comes from the user and passed to the editor directly.
2852
2957
  // This will also activate the mention plugin on the editor
2853
2958
  // items: ({ query }) => { return [] },
2854
2959
  allowSpaces: !0,
2855
2960
  startOfLine: !0,
2856
- render: Ct(xs, "slash-command")
2857
- }, _s = {
2961
+ render: Ot(As, "slash-command")
2962
+ }, Ds = {
2858
2963
  compatConfig: { MODE: 3 },
2859
2964
  name: "DtRichTextEditor",
2860
2965
  components: {
2861
- EditorContent: ze,
2862
- BubbleMenu: Qo,
2863
- DtButton: ve,
2864
- DtStack: gt
2966
+ EditorContent: Ke,
2967
+ BubbleMenu: ni,
2968
+ DtButton: xe,
2969
+ DtStack: yt
2865
2970
  },
2866
2971
  props: {
2867
2972
  /**
@@ -2933,7 +3038,7 @@ const xs = /* @__PURE__ */ q(gs, [["render", vs]]), Ts = {
2933
3038
  type: [Boolean, String, Number],
2934
3039
  default: !1,
2935
3040
  validator(t) {
2936
- return typeof t == "string" ? Jn.includes(t) : !0;
3041
+ return typeof t == "string" ? to.includes(t) : !0;
2937
3042
  }
2938
3043
  },
2939
3044
  /**
@@ -2946,7 +3051,7 @@ const xs = /* @__PURE__ */ q(gs, [["render", vs]]), Ts = {
2946
3051
  type: String,
2947
3052
  default: "html",
2948
3053
  validator(t) {
2949
- return Gn.includes(t);
3054
+ return Qn.includes(t);
2950
3055
  }
2951
3056
  },
2952
3057
  /**
@@ -3298,12 +3403,12 @@ const xs = /* @__PURE__ */ q(gs, [["render", vs]]), Ts = {
3298
3403
  editor: null,
3299
3404
  appendTo: () => {
3300
3405
  var t;
3301
- return (t = zt(this.$refs.editor.$el).getRootNode()) == null ? void 0 : t.querySelector("body");
3406
+ return (t = Ft(this.$refs.editor.$el).getRootNode()) == null ? void 0 : t.querySelector("body");
3302
3407
  },
3303
3408
  floatingOptions: {
3304
3409
  placement: "top-start"
3305
3410
  },
3306
- i18n: new be(),
3411
+ i18n: new ve(),
3307
3412
  // JSON-to-markdown converter
3308
3413
  jsonToMarkdownConverter: {
3309
3414
  convertToMarkdown(t) {
@@ -3443,15 +3548,15 @@ ${this.processNodeContent(t)}
3443
3548
  },
3444
3549
  // eslint-disable-next-line complexity
3445
3550
  extensions() {
3446
- const t = [gn, Ln, yn, vn];
3447
- t.push(this.useDivTags ? Ui : me), this.allowBold && t.push(xn), this.allowBlockquote && t.push(fn), this.allowBulletList && (t.push(Tn), t.push(_n.extend({
3551
+ const t = [wn, In, bn, Tn];
3552
+ t.push(this.useDivTags ? Yi : ge), this.allowBold && t.push(_n), this.allowBlockquote && t.push(mn), this.allowBulletList && (t.push(kn), t.push(Cn.extend({
3448
3553
  renderText({ node: n }) {
3449
3554
  return n.textContent;
3450
3555
  }
3451
- })), t.push(kn)), this.allowItalic && t.push(Cn), this.allowStrike && t.push(En), this.allowUnderline && t.push(Sn), this.placeholder && t.push(
3452
- wn.configure({ placeholder: this.placeholder })
3556
+ })), t.push(On)), this.allowItalic && t.push(En), this.allowStrike && t.push(Ln), this.allowUnderline && t.push(An), this.placeholder && t.push(
3557
+ vn.configure({ placeholder: this.placeholder })
3453
3558
  );
3454
- const e = this, o = en.create({
3559
+ const e = this, o = on.create({
3455
3560
  addKeyboardShortcuts() {
3456
3561
  return {
3457
3562
  "Shift-Enter": ({ editor: n }) => e.allowLineBreaks ? !1 : (n.commands.first(({ commands: i }) => [
@@ -3465,7 +3570,7 @@ ${this.processNodeContent(t)}
3465
3570
  };
3466
3571
  }
3467
3572
  });
3468
- if (t.push(o), this.link && t.push(On.extend({
3573
+ if (t.push(o), this.link && t.push(Sn.extend({
3469
3574
  inclusive: !1,
3470
3575
  addKeyboardShortcuts() {
3471
3576
  return {
@@ -3478,29 +3583,29 @@ ${this.processNodeContent(t)}
3478
3583
  },
3479
3584
  openOnClick: !1,
3480
3585
  autolink: !0,
3481
- protocols: Ft
3482
- })), this.customLink && t.push(this.getExtension(Ni, this.customLink)), this.mentionSuggestion) {
3483
- const n = { ...this.mentionSuggestion, ...us };
3484
- t.push(Fi.configure({ suggestion: n }));
3586
+ protocols: Kt
3587
+ })), this.customLink && t.push(this.getExtension(Wi, this.customLink)), this.mentionSuggestion) {
3588
+ const n = { ...this.mentionSuggestion, ...vs };
3589
+ t.push(Qi.configure({ suggestion: n }));
3485
3590
  }
3486
3591
  if (this.channelSuggestion) {
3487
- const n = { ...this.channelSuggestion, ...ms };
3488
- t.push(Xi.configure({ suggestion: n }));
3592
+ const n = { ...this.channelSuggestion, ...ks };
3593
+ t.push(os.configure({ suggestion: n }));
3489
3594
  }
3490
3595
  if (this.slashCommandSuggestion) {
3491
- const n = { ...this.slashCommandSuggestion, ...Ts };
3492
- t.push(Qi.configure({
3596
+ const n = { ...this.slashCommandSuggestion, ...Is };
3597
+ t.push(ls.configure({
3493
3598
  suggestion: n,
3494
3599
  onSelectedCommand: (i) => {
3495
3600
  this.$emit("selected-command", i);
3496
3601
  }
3497
3602
  }));
3498
3603
  }
3499
- return this.allowVariable && t.push(is.configure({
3604
+ return this.allowVariable && t.push(fs.configure({
3500
3605
  variableItems: this.variableItems
3501
- })), t.push(Ii), t.push(In.configure({
3606
+ })), t.push(Ni), t.push(Dn.configure({
3502
3607
  types: ["paragraph"]
3503
- })), this.allowCode && t.push(mn), this.allowCodeblock && t.push(pn.extend({
3608
+ })), this.allowCode && t.push(yn), this.allowCodeblock && t.push(gn.extend({
3504
3609
  renderText({ node: n }) {
3505
3610
  return `\`\`\`
3506
3611
  ${n.textContent}
@@ -3510,18 +3615,24 @@ ${n.textContent}
3510
3615
  HTMLAttributes: {
3511
3616
  class: "d-rich-text-editor__code-block"
3512
3617
  }
3513
- })), this.allowInlineImages && t.push(Pi.configure({
3618
+ })), this.allowInlineImages && t.push(qi.configure({
3514
3619
  resize: {
3515
3620
  enabled: this.allowImageResize,
3516
3621
  alwaysPreserveAspectRatio: !0
3517
3622
  }
3518
- })), (this.allowFontFamily || this.allowFontColor || this.allowFontSize || this.allowBackgroundColor || this.allowLineHeight) && t.push(Hn.configure({
3623
+ })), (this.allowFontFamily || this.allowFontColor || this.allowFontSize || this.allowBackgroundColor || this.allowLineHeight) && (t.push(Nn.configure({
3519
3624
  color: this.allowFontColor,
3520
3625
  backgroundColor: this.allowBackgroundColor,
3521
3626
  fontFamily: this.allowFontFamily,
3522
3627
  fontSize: this.allowFontSize,
3523
3628
  lineHeight: this.allowLineHeight
3524
- })), this.additionalExtensions.length && t.push(...this.additionalExtensions), this.allowTables && t.push(An.configure({ resizable: !0 }), Dn, Rn, Mn, bn), t;
3629
+ })), t.push(ci)), this.additionalExtensions.length && t.push(...this.additionalExtensions), this.allowTables && t.push(
3630
+ si.configure({ resizable: !0 }),
3631
+ ri,
3632
+ li,
3633
+ ai,
3634
+ xn
3635
+ ), t;
3525
3636
  },
3526
3637
  inputAttrs() {
3527
3638
  const t = {
@@ -3561,11 +3672,11 @@ ${n.textContent}
3561
3672
  this.destroyEditor();
3562
3673
  },
3563
3674
  mounted() {
3564
- Fn(zt(this.$el), this.$options.name), this.processValue(this.modelValue, !1);
3675
+ qn(Ft(this.$el), this.$options.name), this.processValue(this.modelValue, !1);
3565
3676
  },
3566
3677
  methods: {
3567
3678
  createEditor() {
3568
- this.editor = new Fe({
3679
+ this.editor = new We({
3569
3680
  autofocus: this.autoFocus,
3570
3681
  content: this.modelValue,
3571
3682
  editable: this.editable,
@@ -3626,7 +3737,7 @@ ${n.textContent}
3626
3737
  const t = this.editor.getAttributes("link").href;
3627
3738
  window.open(t, "_blank");
3628
3739
  },
3629
- setLink(t, e, o, n = Ft, i) {
3740
+ setLink(t, e, o, n = Kt, i) {
3630
3741
  var a, l, u;
3631
3742
  if (!t) {
3632
3743
  this.removeLink();
@@ -3639,9 +3750,9 @@ ${n.textContent}
3639
3750
  processValue(t, e = !0) {
3640
3751
  if (!this.editor) return;
3641
3752
  const o = this.getOutput();
3642
- if (!(e && eo(t, o))) {
3753
+ if (!(e && io(t, o))) {
3643
3754
  if (typeof t == "string" && this.outputFormat === "text") {
3644
- const n = new RegExp(`(${ge})`, "g");
3755
+ const n = new RegExp(`(${ye})`, "g");
3645
3756
  t = t == null ? void 0 : t.replace(n, '<emoji-component code="$1"></emoji-component>');
3646
3757
  }
3647
3758
  this.editor.commands.setContent(t, {
@@ -3787,11 +3898,11 @@ ${n.textContent}
3787
3898
  this.editor.commands.focus();
3788
3899
  }
3789
3900
  }
3790
- }, ks = { class: "d-popover__dialog" };
3791
- function Cs(t, e, o, n, i, s) {
3901
+ }, Rs = { class: "d-popover__dialog" };
3902
+ function Ms(t, e, o, n, i, s) {
3792
3903
  const r = T("dt-button"), a = T("dt-stack"), l = T("bubble-menu"), u = T("editor-content");
3793
- return _(), et("div", null, [
3794
- i.editor && o.link && !o.hideLinkBubbleMenu ? (_(), I(l, {
3904
+ return _(), nt("div", null, [
3905
+ i.editor && o.link && !o.hideLinkBubbleMenu ? (_(), A(l, {
3795
3906
  key: 0,
3796
3907
  editor: i.editor,
3797
3908
  "should-show": s.bubbleMenuShouldShow,
@@ -3800,7 +3911,7 @@ function Cs(t, e, o, n, i, s) {
3800
3911
  style: { visibility: "visible" }
3801
3912
  }, {
3802
3913
  default: C(() => [
3803
- nt("div", ks, [
3914
+ ot("div", Rs, [
3804
3915
  M(a, {
3805
3916
  direction: "row",
3806
3917
  class: "d-rich-text-editor-bubble-menu__button-stack",
@@ -3813,7 +3924,7 @@ function Cs(t, e, o, n, i, s) {
3813
3924
  onClick: s.editLink
3814
3925
  }, {
3815
3926
  default: C(() => [
3816
- at($(i.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_EDIT_BUTTON_LABEL")), 1)
3927
+ lt($(i.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_EDIT_BUTTON_LABEL")), 1)
3817
3928
  ]),
3818
3929
  _: 1
3819
3930
  }, 8, ["onClick"]),
@@ -3823,7 +3934,7 @@ function Cs(t, e, o, n, i, s) {
3823
3934
  onClick: s.openLink
3824
3935
  }, {
3825
3936
  default: C(() => [
3826
- at($(i.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_OPEN_LINK_BUTTON_LABEL")), 1)
3937
+ lt($(i.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_OPEN_LINK_BUTTON_LABEL")), 1)
3827
3938
  ]),
3828
3939
  _: 1
3829
3940
  }, 8, ["onClick"]),
@@ -3833,7 +3944,7 @@ function Cs(t, e, o, n, i, s) {
3833
3944
  onClick: s.removeLink
3834
3945
  }, {
3835
3946
  default: C(() => [
3836
- at($(i.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_REMOVE_BUTTON_LABEL")), 1)
3947
+ lt($(i.i18n.$t("DIALTONE_RICH_TEXT_EDITOR_REMOVE_BUTTON_LABEL")), 1)
3837
3948
  ]),
3838
3949
  _: 1
3839
3950
  }, 8, ["onClick"])
@@ -3843,8 +3954,8 @@ function Cs(t, e, o, n, i, s) {
3843
3954
  ])
3844
3955
  ]),
3845
3956
  _: 1
3846
- }, 8, ["editor", "should-show", "options", "append-to"])) : it("", !0),
3847
- M(u, pe({
3957
+ }, 8, ["editor", "should-show", "options", "append-to"])) : rt("", !0),
3958
+ M(u, me({
3848
3959
  ref: "editor",
3849
3960
  editor: i.editor,
3850
3961
  class: "d-rich-text-editor",
@@ -3852,8 +3963,8 @@ function Cs(t, e, o, n, i, s) {
3852
3963
  }, s.attrs), null, 16, ["editor"])
3853
3964
  ]);
3854
3965
  }
3855
- const gr = /* @__PURE__ */ q(_s, [["render", Cs]]);
3966
+ const Cr = /* @__PURE__ */ q(Ds, [["render", Ms]]);
3856
3967
  export {
3857
- gr as default
3968
+ Cr as default
3858
3969
  };
3859
3970
  //# sourceMappingURL=rich-text-editor.js.map