@harbour-enterprises/superdoc 0.10.15 → 0.10.16

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.
@@ -6,14 +6,14 @@ var dt = (t, l, o) => l in t ? ct(t, l, { enumerable: !0, configurable: !0, writ
6
6
  var $e = (t, l, o) => dt(t, typeof l != "symbol" ? l + "" : l, o), We = (t, l, o) => l.has(t) || Ve("Cannot " + o);
7
7
  var Ee = (t, l, o) => (We(t, l, "read from private field"), o ? o.call(t) : l.get(t)), He = (t, l, o) => l.has(t) ? Ve("Cannot add the same private member more than once") : l instanceof WeakSet ? l.add(t) : l.set(t, o);
8
8
  var O = (t, l, o) => (We(t, l, "access private method"), o);
9
- import { _ as G, a as Ge, b as ut, I as Be, f as mt, c as je, d as pt, i as ft, u as ht, r as gt, E as Re, e as vt, P as yt, h as bt, j as kt, A as wt, N as Ct } from "./chunks/editor-CQhQmf2I.js";
10
- import { C as _o, T as xo, l as Eo, n as So, k as To, m as Ao } from "./chunks/editor-CQhQmf2I.js";
11
- import { a1 as _t, y as xt, a3 as Et, T as Ke, a as St } from "./chunks/converter-Cy4sh4X1.js";
12
- import { O as Io } from "./chunks/converter-Cy4sh4X1.js";
13
- import { ref as v, createElementBlock as w, openBlock as k, createElementVNode as E, unref as $, getCurrentInstance as Tt, computed as W, watch as At, onMounted as we, createCommentVNode as ne, withDirectives as Ft, withKeys as It, normalizeClass as oe, withModifiers as ke, vModelText as Lt, createTextVNode as Mt, toDisplayString as ie, Fragment as j, renderList as J, normalizeStyle as Y, createVNode as V, h as P, createApp as Dt, reactive as Ue, onUnmounted as $t, shallowRef as Xe, onBeforeUnmount as Ze, createBlock as Ht } from "vue";
14
- import { t as q, s as Bt, T as Rt, N as Z } from "./chunks/toolbar-CpGnl37U.js";
15
- import { D as Mo } from "./chunks/docx-zipper-Y758nVr2.js";
16
- import { createZip as $o } from "./file-zipper.es.js";
9
+ import { _ as G, a as Ge, b as ut, I as Be, f as mt, c as je, d as pt, i as ft, u as ht, r as gt, E as Re, e as vt, P as yt, h as bt, M as kt, j as wt, A as Ct, N as _t } from "./chunks/editor-CRKJwGeZ.js";
10
+ import { C as xo, T as Eo, l as So, n as To, k as Ao, m as Fo } from "./chunks/editor-CRKJwGeZ.js";
11
+ import { a1 as xt, y as Et, a3 as St, T as Ke, a as Tt } from "./chunks/converter-am5lAIyg.js";
12
+ import { O as Lo } from "./chunks/converter-am5lAIyg.js";
13
+ import { ref as v, createElementBlock as w, openBlock as k, createElementVNode as E, unref as $, getCurrentInstance as At, computed as W, watch as Ft, onMounted as we, createCommentVNode as ne, withDirectives as It, withKeys as Lt, normalizeClass as oe, withModifiers as ke, vModelText as Mt, createTextVNode as Dt, toDisplayString as ie, Fragment as j, renderList as J, normalizeStyle as Y, createVNode as V, h as P, createApp as $t, reactive as Ue, onUnmounted as Ht, shallowRef as Xe, onBeforeUnmount as Ze, createBlock as Bt } from "vue";
14
+ import { t as q, s as Rt, T as Ot, N as Z } from "./chunks/toolbar-C0oi9PH4.js";
15
+ import { D as Do } from "./chunks/docx-zipper-DTNfiohr.js";
16
+ import { createZip as Ho } from "./file-zipper.es.js";
17
17
  var Ye = { exports: {} };
18
18
  (function(t) {
19
19
  var l = Object.prototype.hasOwnProperty, o = "~";
@@ -119,9 +119,9 @@ var Ye = { exports: {} };
119
119
  return d ? (u = o ? o + d : d, this._events[u] && c(this, u)) : (this._events = new n(), this._eventsCount = 0), this;
120
120
  }, s.prototype.off = s.prototype.removeListener, s.prototype.addListener = s.prototype.on, s.prefixed = o, s.EventEmitter = s, t.exports = s;
121
121
  })(Ye);
122
- var Ot = Ye.exports;
123
- const Nt = /* @__PURE__ */ _t(Ot);
124
- function zt(t) {
122
+ var Nt = Ye.exports;
123
+ const zt = /* @__PURE__ */ xt(Nt);
124
+ function Pt(t) {
125
125
  let l = t;
126
126
  for (; l; ) {
127
127
  const o = window.getComputedStyle(l).overflowY;
@@ -131,9 +131,9 @@ function zt(t) {
131
131
  }
132
132
  return document.scrollingElement || document.documentElement;
133
133
  }
134
- function Pt(t, l = { behavior: "smooth", block: "start" }) {
134
+ function Vt(t, l = { behavior: "smooth", block: "start" }) {
135
135
  if (!t) return;
136
- const o = zt(t), n = o.getBoundingClientRect(), i = t.getBoundingClientRect().top - n.top + o.scrollTop;
136
+ const o = Pt(t), n = o.getBoundingClientRect(), i = t.getBoundingClientRect().top - n.top + o.scrollTop;
137
137
  o.scrollTo({
138
138
  top: l.block === "start" ? i : i - o.clientHeight + t.offsetHeight,
139
139
  behavior: l.behavior
@@ -146,7 +146,7 @@ const x = (t) => {
146
146
  throw new Error("Toolbar button item needs either icon or label - " + t.name);
147
147
  if (!t.name)
148
148
  throw new Error("Invalid toolbar item name - " + t.name);
149
- const o = v(xt()), n = t.type, e = v(t.name), i = t.command, c = v(t.icon), s = v(t.group || "center"), a = v(t.allowWithoutEditor), d = v(t.attributes || {}), u = t.disabled || !1, r = v(t.disabled), b = v(!1), h = v(!1), y = v(t.style), _ = v(t.isNarrow), g = v(t.isWide), M = v(t.minWidth), D = v(t.suppressActiveHighlight || !1), p = v(t.argument), C = v(null), A = v(null), H = v(t.iconColor), N = v(t.hasCaret), Q = v(t.tooltip), ve = v(t.tooltipVisible), ce = v(t.tooltipTimeout), de = v(t.defaultLabel), se = v(t.label), T = v(t.hideLabel), I = v(t.inlineTextInputVisible), B = v(t.hasInlineTextInput), R = v(t.markName), U = v(t.labelAttr), K = v(t.selectedValue), ue = v(t.dropdownValueKey), le = v([]);
149
+ const o = v(Et()), n = t.type, e = v(t.name), i = t.command, c = v(t.icon), s = v(t.group || "center"), a = v(t.allowWithoutEditor), d = v(t.attributes || {}), u = t.disabled || !1, r = v(t.disabled), b = v(!1), h = v(!1), y = v(t.style), _ = v(t.isNarrow), g = v(t.isWide), M = v(t.minWidth), D = v(t.suppressActiveHighlight || !1), p = v(t.argument), C = v(null), A = v(null), H = v(t.iconColor), N = v(t.hasCaret), Q = v(t.tooltip), ve = v(t.tooltipVisible), ce = v(t.tooltipTimeout), de = v(t.defaultLabel), se = v(t.label), T = v(t.hideLabel), I = v(t.inlineTextInputVisible), B = v(t.hasInlineTextInput), R = v(t.markName), U = v(t.labelAttr), K = v(t.selectedValue), ue = v(t.dropdownValueKey), le = v([]);
150
150
  if (t.options) {
151
151
  if (!Array.isArray(t.options)) throw new Error("Invalid toolbar item options - " + t.options);
152
152
  le.value.push(...t.options);
@@ -209,49 +209,49 @@ const x = (t) => {
209
209
  onActivate: ee,
210
210
  onDeactivate: _e
211
211
  };
212
- }, Vt = { class: "alignment-buttons" }, Wt = ["innerHTML"], jt = ["innerHTML"], Ut = ["innerHTML"], qt = ["innerHTML"], Gt = {
212
+ }, Wt = { class: "alignment-buttons" }, jt = ["innerHTML"], Ut = ["innerHTML"], qt = ["innerHTML"], Gt = ["innerHTML"], Kt = {
213
213
  __name: "AlignmentButtons",
214
214
  emits: ["select"],
215
215
  setup(t, { emit: l }) {
216
216
  const o = l, n = (e) => {
217
217
  o("select", e);
218
218
  };
219
- return (e, i) => (k(), w("div", Vt, [
219
+ return (e, i) => (k(), w("div", Wt, [
220
220
  E("div", {
221
221
  class: "button-icon",
222
222
  onClick: i[0] || (i[0] = (c) => n("left")),
223
223
  innerHTML: $(q).alignLeft
224
- }, null, 8, Wt),
224
+ }, null, 8, jt),
225
225
  E("div", {
226
226
  class: "button-icon",
227
227
  onClick: i[1] || (i[1] = (c) => n("center")),
228
228
  innerHTML: $(q).alignCenter
229
- }, null, 8, jt),
229
+ }, null, 8, Ut),
230
230
  E("div", {
231
231
  class: "button-icon",
232
232
  onClick: i[2] || (i[2] = (c) => n("right")),
233
233
  innerHTML: $(q).alignRight
234
- }, null, 8, Ut),
234
+ }, null, 8, qt),
235
235
  E("div", {
236
236
  class: "button-icon",
237
237
  onClick: i[3] || (i[3] = (c) => n("justify")),
238
238
  innerHTML: $(q).alignJustify
239
- }, null, 8, qt)
239
+ }, null, 8, Gt)
240
240
  ]));
241
241
  }
242
- }, Kt = /* @__PURE__ */ G(Gt, [["__scopeId", "data-v-d6fae878"]]), Xt = { class: "link-input-ctn" }, Zt = {
242
+ }, Xt = /* @__PURE__ */ G(Kt, [["__scopeId", "data-v-d6fae878"]]), Zt = { class: "link-input-ctn" }, Yt = {
243
243
  key: 0,
244
244
  class: "link-title"
245
- }, Yt = {
245
+ }, Jt = {
246
246
  key: 1,
247
247
  class: "link-title"
248
- }, Jt = {
248
+ }, Qt = {
249
249
  key: 2,
250
250
  class: "link-title"
251
- }, Qt = { key: 3 }, en = { class: "input-row" }, tn = ["innerHTML"], nn = ["onKeydown"], on = ["innerHTML"], sn = { class: "input-row link-buttons" }, ln = ["innerHTML"], an = {
251
+ }, en = { key: 3 }, tn = { class: "input-row" }, nn = ["innerHTML"], on = ["onKeydown"], sn = ["innerHTML"], ln = { class: "input-row link-buttons" }, an = ["innerHTML"], rn = {
252
252
  key: 4,
253
253
  class: "input-row go-to-anchor clickable"
254
- }, rn = {
254
+ }, cn = {
255
255
  __name: "LinkInput",
256
256
  props: {
257
257
  initialText: {
@@ -278,7 +278,7 @@ const x = (t) => {
278
278
  },
279
279
  emits: ["submit", "cancel"],
280
280
  setup(t, { emit: l }) {
281
- const o = l, n = t, { proxy: e } = Tt(), i = () => {
281
+ const o = l, n = t, { proxy: e } = At(), i = () => {
282
282
  if (e?.$submit instanceof Function && e.$submit(), d.value && r.value) {
283
283
  o("submit", { text: a.value, href: u.value });
284
284
  return;
@@ -295,7 +295,7 @@ const x = (t) => {
295
295
  }), b = W(() => y.value ? "Apply" : "Remove"), h = W(() => !r.value), y = W(() => !_.value), _ = W(() => n.href && !d.value), g = W(() => n.href.startsWith("#")), M = () => {
296
296
  window.open(u.value, "_blank");
297
297
  };
298
- At(
298
+ Ft(
299
299
  () => n.href,
300
300
  (p) => {
301
301
  d.value = p;
@@ -307,33 +307,33 @@ const x = (t) => {
307
307
  };
308
308
  return we(() => {
309
309
  n.showInput && D();
310
- }), (p, C) => (k(), w("div", Xt, [
311
- t.href ? g.value ? (k(), w("div", Yt, "Page anchor")) : (k(), w("div", Jt, "Edit link")) : (k(), w("div", Zt, "Add link")),
312
- t.showInput && !g.value ? (k(), w("div", Qt, [
313
- E("div", en, [
310
+ }), (p, C) => (k(), w("div", Zt, [
311
+ t.href ? g.value ? (k(), w("div", Jt, "Page anchor")) : (k(), w("div", Qt, "Edit link")) : (k(), w("div", Yt, "Add link")),
312
+ t.showInput && !g.value ? (k(), w("div", en, [
313
+ E("div", tn, [
314
314
  E("div", {
315
315
  class: "input-icon",
316
316
  innerHTML: $(q).linkInput
317
- }, null, 8, tn),
318
- Ft(E("input", {
317
+ }, null, 8, nn),
318
+ It(E("input", {
319
319
  type: "text",
320
320
  placeholder: "Type or paste a link",
321
321
  class: oe({ error: s.value }),
322
322
  "onUpdate:modelValue": C[0] || (C[0] = (A) => d.value = A),
323
323
  onKeydown: [
324
- It(ke(i, ["stop", "prevent"]), ["enter"]),
324
+ Lt(ke(i, ["stop", "prevent"]), ["enter"]),
325
325
  C[1] || (C[1] = (A) => s.value = !1)
326
326
  ]
327
- }, null, 42, nn), [
328
- [Lt, d.value]
327
+ }, null, 42, on), [
328
+ [Mt, d.value]
329
329
  ]),
330
330
  E("div", {
331
331
  class: oe(["open-link-icon", { disabled: !r.value }]),
332
332
  innerHTML: $(q).openLink,
333
333
  onClick: M
334
- }, null, 10, on)
334
+ }, null, 10, sn)
335
335
  ]),
336
- E("div", sn, [
336
+ E("div", ln, [
337
337
  t.href ? (k(), w("button", {
338
338
  key: 0,
339
339
  class: "remove-btn",
@@ -342,8 +342,8 @@ const x = (t) => {
342
342
  E("div", {
343
343
  class: "remove-btn__icon",
344
344
  innerHTML: $(q).removeLink
345
- }, null, 8, ln),
346
- C[3] || (C[3] = Mt(" Remove "))
345
+ }, null, 8, an),
346
+ C[3] || (C[3] = Dt(" Remove "))
347
347
  ])) : ne("", !0),
348
348
  y.value ? (k(), w("button", {
349
349
  key: 1,
@@ -351,14 +351,14 @@ const x = (t) => {
351
351
  onClick: i
352
352
  }, ie(b.value), 3)) : ne("", !0)
353
353
  ])
354
- ])) : g.value ? (k(), w("div", an, [
354
+ ])) : g.value ? (k(), w("div", rn, [
355
355
  E("a", {
356
356
  onClick: C[2] || (C[2] = ke((...A) => t.goToAnchor && t.goToAnchor(...A), ["stop", "prevent"]))
357
357
  }, "Go to " + ie(t.href.startsWith("#_") ? t.href.substring(2) : t.href), 1)
358
358
  ])) : ne("", !0)
359
359
  ]));
360
360
  }
361
- }, cn = /* @__PURE__ */ G(rn, [["__scopeId", "data-v-6990d5b2"]]), dn = { class: "document-mode" }, un = ["onClick"], mn = { class: "document-mode-column icon-column" }, pn = ["innerHTML"], fn = { class: "document-mode-column text-column" }, hn = { class: "document-mode-type" }, gn = { class: "document-mode-description" }, vn = {
361
+ }, dn = /* @__PURE__ */ G(cn, [["__scopeId", "data-v-6990d5b2"]]), un = { class: "document-mode" }, mn = ["onClick"], pn = { class: "document-mode-column icon-column" }, fn = ["innerHTML"], hn = { class: "document-mode-column text-column" }, gn = { class: "document-mode-type" }, vn = { class: "document-mode-description" }, yn = {
362
362
  __name: "DocumentMode",
363
363
  props: {
364
364
  options: {
@@ -370,28 +370,28 @@ const x = (t) => {
370
370
  const o = l, n = (e) => {
371
371
  o("select", e);
372
372
  };
373
- return (e, i) => (k(), w("div", dn, [
373
+ return (e, i) => (k(), w("div", un, [
374
374
  (k(!0), w(j, null, J(t.options, (c) => (k(), w("div", {
375
375
  class: oe(["option-item", { disabled: c.disabled }]),
376
376
  onClick: (s) => n(c)
377
377
  }, [
378
- E("div", mn, [
378
+ E("div", pn, [
379
379
  E("div", {
380
380
  class: "icon-column__icon",
381
381
  innerHTML: c.icon
382
- }, null, 8, pn)
382
+ }, null, 8, fn)
383
383
  ]),
384
- E("div", fn, [
385
- E("div", hn, ie(c.label), 1),
386
- E("div", gn, ie(c.description), 1)
384
+ E("div", hn, [
385
+ E("div", gn, ie(c.label), 1),
386
+ E("div", vn, ie(c.description), 1)
387
387
  ])
388
- ], 10, un))), 256))
388
+ ], 10, mn))), 256))
389
389
  ]));
390
390
  }
391
- }, yn = /* @__PURE__ */ G(vn, [["__scopeId", "data-v-f86e1477"]]), bn = {
391
+ }, bn = /* @__PURE__ */ G(yn, [["__scopeId", "data-v-f86e1477"]]), kn = {
392
392
  key: 0,
393
393
  class: "linked-style-buttons"
394
- }, kn = ["onClick"], wn = {
394
+ }, wn = ["onClick"], Cn = {
395
395
  __name: "LinkedStyle",
396
396
  props: {
397
397
  editor: {
@@ -404,7 +404,7 @@ const x = (t) => {
404
404
  const o = l, n = t, e = (i) => {
405
405
  o("select", i);
406
406
  };
407
- return (i, c) => n.editor ? (k(), w("div", bn, [
407
+ return (i, c) => n.editor ? (k(), w("div", kn, [
408
408
  (k(!0), w(j, null, J($(Ge)(t.editor), (s) => (k(), w("div", {
409
409
  class: "style-item",
410
410
  onClick: (a) => e(s)
@@ -413,10 +413,10 @@ const x = (t) => {
413
413
  class: "style-name",
414
414
  style: Y($(ut)(s, null, !1))
415
415
  }, ie(s.definition.attrs.name), 5)
416
- ], 8, kn))), 256))
416
+ ], 8, wn))), 256))
417
417
  ])) : ne("", !0);
418
418
  }
419
- }, Cn = /* @__PURE__ */ G(wn, [["__scopeId", "data-v-97e3296a"]]), _n = ["onClick"], xn = ["innerHTML"], En = ["innerHTML"], Sn = {
419
+ }, _n = /* @__PURE__ */ G(Cn, [["__scopeId", "data-v-97e3296a"]]), xn = ["onClick"], En = ["innerHTML"], Sn = ["innerHTML"], Tn = {
420
420
  __name: "IconGridRow",
421
421
  props: {
422
422
  icons: {
@@ -448,17 +448,17 @@ const x = (t) => {
448
448
  class: "option__icon",
449
449
  innerHTML: r.icon,
450
450
  style: Y(r.style)
451
- }, null, 12, xn),
451
+ }, null, 12, En),
452
452
  e.value(r) ? (k(), w("div", {
453
453
  key: 0,
454
454
  class: "option__check",
455
455
  innerHTML: $(q).colorOptionCheck,
456
456
  style: Y(i(r.value, b))
457
- }, null, 12, En)) : ne("", !0)
458
- ], 8, _n))), 128))
457
+ }, null, 12, Sn)) : ne("", !0)
458
+ ], 8, xn))), 128))
459
459
  ]))), 128));
460
460
  }
461
- }, qe = /* @__PURE__ */ G(Sn, [["__scopeId", "data-v-6a2a9a40"]]), Tn = { class: "option-grid-ctn" }, An = {
461
+ }, qe = /* @__PURE__ */ G(Tn, [["__scopeId", "data-v-6a2a9a40"]]), An = { class: "option-grid-ctn" }, Fn = {
462
462
  __name: "IconGrid",
463
463
  props: {
464
464
  icons: {
@@ -479,7 +479,7 @@ const x = (t) => {
479
479
  const o = l, n = (e) => {
480
480
  o("select", e);
481
481
  };
482
- return (e, i) => (k(), w("div", Tn, [
482
+ return (e, i) => (k(), w("div", An, [
483
483
  V(qe, {
484
484
  icons: t.icons,
485
485
  "active-color": t.activeColor,
@@ -495,7 +495,7 @@ const x = (t) => {
495
495
  ], 64)) : ne("", !0)
496
496
  ]));
497
497
  }
498
- }, Fn = /* @__PURE__ */ G(An, [["__scopeId", "data-v-fa2949d8"]]), In = (t) => {
498
+ }, In = /* @__PURE__ */ G(Fn, [["__scopeId", "data-v-fa2949d8"]]), Ln = (t) => {
499
499
  t.expand.value = !1;
500
500
  }, f = (t, l = null) => ({
501
501
  label: l,
@@ -508,10 +508,10 @@ const x = (t) => {
508
508
  }
509
509
  }), Oe = (t, l, o = []) => {
510
510
  const n = (e) => {
511
- l.iconColor.value = e, t.emitCommand({ item: l, argument: e }), In(l);
511
+ l.iconColor.value = e, t.emitCommand({ item: l, argument: e }), Ln(l);
512
512
  };
513
513
  return P("div", {}, [
514
- P(Fn, {
514
+ P(In, {
515
515
  icons: Je,
516
516
  customIcons: o,
517
517
  activeColor: l.iconColor,
@@ -591,7 +591,7 @@ const x = (t) => {
591
591
  f("#DFCDF2"),
592
592
  f("#A91DFF")
593
593
  ]
594
- ], Ln = () => Je.flat().map((t) => t.value), Mn = { class: "toolbar-table-grid-wrapper" }, Dn = ["data-cols", "data-rows", "onClick"], $n = { class: "toolbar-table-grid-value" }, Hn = {
594
+ ], Mn = () => Je.flat().map((t) => t.value), Dn = { class: "toolbar-table-grid-wrapper" }, $n = ["data-cols", "data-rows", "onClick"], Hn = { class: "toolbar-table-grid-value" }, Bn = {
595
595
  __name: "TableGrid",
596
596
  emits: ["select", "clickoutside"],
597
597
  setup(t, { emit: l }) {
@@ -608,7 +608,7 @@ const x = (t) => {
608
608
  }, c = ({ cols: s, rows: a }) => {
609
609
  o("select", { cols: s, rows: a });
610
610
  };
611
- return (s, a) => (k(), w("div", Mn, [
611
+ return (s, a) => (k(), w("div", Dn, [
612
612
  E("div", {
613
613
  class: "toolbar-table-grid",
614
614
  onMouseover: i,
@@ -622,13 +622,13 @@ const x = (t) => {
622
622
  "data-rows": d,
623
623
  "data-item": "true",
624
624
  onClick: ke((r) => c({ cols: u, rows: d }), ["stop", "prevent"])
625
- }, null, 8, Dn)), 64))
625
+ }, null, 8, $n)), 64))
626
626
  ], 64))), 64))
627
627
  ], 32),
628
- E("div", $n, ie(n.value) + " x " + ie(e.value), 1)
628
+ E("div", Hn, ie(n.value) + " x " + ie(e.value), 1)
629
629
  ]));
630
630
  }
631
- }, Bn = /* @__PURE__ */ G(Hn, [["__scopeId", "data-v-06352ab9"]]), Rn = { class: "toolbar-table-actions" }, On = ["onClick"], Nn = { class: "toolbar-table-actions__icon" }, zn = ["innerHTML"], Pn = { class: "toolbar-table-actions__label" }, Vn = {
631
+ }, Rn = /* @__PURE__ */ G(Bn, [["__scopeId", "data-v-06352ab9"]]), On = { class: "toolbar-table-actions" }, Nn = ["onClick"], zn = { class: "toolbar-table-actions__icon" }, Pn = ["innerHTML"], Vn = { class: "toolbar-table-actions__label" }, Wn = {
632
632
  __name: "TableActions",
633
633
  props: {
634
634
  options: {
@@ -640,25 +640,25 @@ const x = (t) => {
640
640
  const o = l, n = (e) => {
641
641
  o("select", { command: e.command });
642
642
  };
643
- return (e, i) => (k(), w("div", Rn, [
643
+ return (e, i) => (k(), w("div", On, [
644
644
  (k(!0), w(j, null, J(t.options, (c) => (k(), w("div", {
645
645
  class: oe(["toolbar-table-actions__item", { "toolbar-table-actions__item--border": c.bottomBorder }]),
646
646
  onClick: (s) => n(c)
647
647
  }, [
648
- E("div", Nn, [
648
+ E("div", zn, [
649
649
  E("div", {
650
650
  class: "toolbar-table-actions__icon-wrapper",
651
651
  innerHTML: c.icon
652
- }, null, 8, zn)
652
+ }, null, 8, Pn)
653
653
  ]),
654
- E("div", Pn, ie(c.label), 1)
655
- ], 10, On))), 256))
654
+ E("div", Vn, ie(c.label), 1)
655
+ ], 10, Nn))), 256))
656
656
  ]));
657
657
  }
658
- }, Wn = /* @__PURE__ */ G(Vn, [["__scopeId", "data-v-9a702d7f"]]), jn = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><!--!Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2025 Fonticons, Inc.--><path d="M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"/></svg>
658
+ }, jn = /* @__PURE__ */ G(Wn, [["__scopeId", "data-v-9a702d7f"]]), Un = `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><!--!Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2025 Fonticons, Inc.--><path d="M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"/></svg>
659
659
  `, re = (t) => {
660
660
  t.expand.value = !1;
661
- }, Un = (t, l = !1, o, n, e) => {
661
+ }, qn = (t, l = !1, o, n, e) => {
662
662
  const i = x({
663
663
  type: "button",
664
664
  name: "bold",
@@ -749,7 +749,7 @@ const x = (t) => {
749
749
  ],
750
750
  onActivate: ({ fontSize: m }) => {
751
751
  if (!m) return s.label.value = s.defaultLabel.value;
752
- let S = Bt(m, 12);
752
+ let S = Rt(m, 12);
753
753
  S < 8 && (S = 8), S > 96 && (S = 96), s.label.value = String(S);
754
754
  },
755
755
  onDeactivate: () => s.label.value = s.defaultLabel.value
@@ -833,7 +833,7 @@ const x = (t) => {
833
833
  });
834
834
  function y(m) {
835
835
  return P("div", {}, [
836
- P(cn, {
836
+ P(dn, {
837
837
  onSubmit: ({ href: F }) => {
838
838
  re(m), m.attributes.value.link = { href: F };
839
839
  const X = { ...m, command: "toggleLink" };
@@ -843,7 +843,7 @@ const x = (t) => {
843
843
  goToAnchor: () => {
844
844
  if (re(m), !t.activeEditor || !m.attributes.value?.href) return;
845
845
  const F = m.attributes.value?.href?.slice(1), fe = t.activeEditor.element.querySelector(`a[name='${F}']`);
846
- fe && Pt(fe);
846
+ fe && Vt(fe);
847
847
  }
848
848
  })
849
849
  ]);
@@ -880,7 +880,7 @@ const x = (t) => {
880
880
  });
881
881
  function D(m) {
882
882
  return P("div", {}, [
883
- P(Bn, {
883
+ P(Rn, {
884
884
  onSelect: (F) => {
885
885
  t.emitCommand({ item: m, argument: F }), re(m);
886
886
  }
@@ -960,7 +960,7 @@ const x = (t) => {
960
960
  }
961
961
  ];
962
962
  function A(m) {
963
- return P(Wn, {
963
+ return P(jn, {
964
964
  options: C,
965
965
  onSelect: (S) => {
966
966
  re(m);
@@ -983,7 +983,7 @@ const x = (t) => {
983
983
  {
984
984
  type: "render",
985
985
  render: () => P("div", {}, [
986
- P(Kt, {
986
+ P(Xt, {
987
987
  onSelect: (S) => {
988
988
  re(H);
989
989
  const F = { ...H, command: "setTextAlign" };
@@ -1195,7 +1195,7 @@ const x = (t) => {
1195
1195
  ];
1196
1196
  function Ie(m) {
1197
1197
  const S = Fe(n, _e);
1198
- return P(yn, {
1198
+ return P(bn, {
1199
1199
  options: S,
1200
1200
  onSelect: (F) => {
1201
1201
  re(m);
@@ -1251,7 +1251,7 @@ const x = (t) => {
1251
1251
  t.emitCommand({ item: F, argument: S });
1252
1252
  };
1253
1253
  return P("div", {}, [
1254
- P(Cn, {
1254
+ P(_n, {
1255
1255
  editor: t.activeEditor,
1256
1256
  onSelect: m
1257
1257
  })
@@ -1267,7 +1267,7 @@ const x = (t) => {
1267
1267
  }
1268
1268
  }), pe = (m, S) => {
1269
1269
  if (S.value.toString() === m)
1270
- return P("div", { innerHTML: jn, class: "dropdown-select-icon" });
1270
+ return P("div", { innerHTML: Un, class: "dropdown-select-icon" });
1271
1271
  }, ae = x({
1272
1272
  type: "dropdown",
1273
1273
  name: "lineHeight",
@@ -1368,10 +1368,10 @@ const x = (t) => {
1368
1368
  defaultItems: Me,
1369
1369
  overflowItems: xe.filter((m) => m.type !== "separator")
1370
1370
  };
1371
- }, qn = [".jpg", ".jpeg", ".png", "image/jpeg", "image/png"], Gn = () => {
1371
+ }, Gn = [".jpg", ".jpeg", ".png", "image/jpeg", "image/png"], Kn = () => {
1372
1372
  let t = document.createElement("input");
1373
1373
  t.type = "file";
1374
- let l = qn;
1374
+ let l = Gn;
1375
1375
  return t.accept = l.join(","), () => new Promise((n, e) => {
1376
1376
  t.onchange = async () => {
1377
1377
  const i = t.files;
@@ -1380,13 +1380,13 @@ const x = (t) => {
1380
1380
  return n(c ? { file: c } : null);
1381
1381
  }, t.oncancel = () => n(null), t.onerror = e, t.click();
1382
1382
  });
1383
- }, Kn = (t) => new Promise((l, o) => {
1383
+ }, Xn = (t) => new Promise((l, o) => {
1384
1384
  let n = new FileReader();
1385
1385
  n.onload = (e) => l(e.target.result), n.onerror = o, setTimeout(() => n.readAsDataURL(t), 250);
1386
- }), Xn = (t, l) => new Promise((o, n) => {
1386
+ }), Zn = (t, l) => new Promise((o, n) => {
1387
1387
  const e = new window.Image();
1388
1388
  e.onload = () => {
1389
- const i = document.createElement("canvas"), { width: c, height: s } = Zn(
1389
+ const i = document.createElement("canvas"), { width: c, height: s } = Yn(
1390
1390
  e.width,
1391
1391
  e.height,
1392
1392
  l
@@ -1403,21 +1403,21 @@ const x = (t) => {
1403
1403
  o({ file: u, width: c, height: s });
1404
1404
  });
1405
1405
  }, e.onerror = (i) => n(i), e.src = typeof t == "string" ? t : URL.createObjectURL(t);
1406
- }), Zn = (t, l, o) => {
1406
+ }), Yn = (t, l, o) => {
1407
1407
  const { width: n, height: e } = o.getMaxContentSize();
1408
1408
  if (!n || !e) return { width: t, height: l };
1409
1409
  let i = t, c = l;
1410
1410
  const s = t / l;
1411
1411
  return l > e && (c = e, i = Math.round(e * s)), i > n && (i = n, c = Math.round(n / s)), { width: i, height: c };
1412
- }, Yn = async ({ editor: t, view: l, file: o }) => {
1413
- let n = typeof t.options.handleImageUpload == "function" ? t.options.handleImageUpload : Kn;
1412
+ }, Jn = async ({ editor: t, view: l, file: o }) => {
1413
+ let n = typeof t.options.handleImageUpload == "function" ? t.options.handleImageUpload : Xn;
1414
1414
  if ((o.size / (1024 * 1024)).toFixed(4) > 5) {
1415
1415
  window.alert("Image size must be less than 5MB");
1416
1416
  return;
1417
1417
  }
1418
1418
  let i, c;
1419
1419
  try {
1420
- const r = await Xn(o, t);
1420
+ const r = await Zn(o, t);
1421
1421
  i = r.width, c = r.height, o = r.file;
1422
1422
  } catch (r) {
1423
1423
  console.warn("Error processing image:", r);
@@ -1450,7 +1450,7 @@ const x = (t) => {
1450
1450
  );
1451
1451
  };
1452
1452
  var L, Qe, ge, Ne, et, tt, ze, nt, he;
1453
- class go extends Nt {
1453
+ class vo extends zt {
1454
1454
  constructor(o) {
1455
1455
  super();
1456
1456
  He(this, L);
@@ -1497,8 +1497,8 @@ class go extends Nt {
1497
1497
  this.superdoc.toggleRuler();
1498
1498
  },
1499
1499
  startImageUpload: async ({ item: o, argument: n }) => {
1500
- let i = await Gn()();
1501
- i?.file && Yn({
1500
+ let i = await Kn()();
1501
+ i?.file && Jn({
1502
1502
  editor: this.activeEditor,
1503
1503
  view: this.activeEditor.view,
1504
1504
  file: i.file
@@ -1560,7 +1560,7 @@ class go extends Nt {
1560
1560
  console.warn(`[super-toolbar 🎨] Element not found: ${this.config.selector}`);
1561
1561
  return;
1562
1562
  }
1563
- this.app = Dt(Rt), this.app.directive("click-outside", Et), this.app.config.globalProperties.$toolbar = this, n && (this.toolbar = this.app.mount(n)), this.activeEditor = o.editor || null, this.updateToolbarState();
1563
+ this.app = $t(Ot), this.app.directive("click-outside", St), this.app.config.globalProperties.$toolbar = this, n && (this.toolbar = this.app.mount(n)), this.activeEditor = o.editor || null, this.updateToolbarState();
1564
1564
  }
1565
1565
  log(...o) {
1566
1566
  console.debug("[🎨 super-toolbar]", ...o);
@@ -1625,7 +1625,7 @@ class go extends Nt {
1625
1625
  L = new WeakSet(), Qe = function() {
1626
1626
  this.config.groups && !Array.isArray(this.config.groups) && Object.keys(this.config.groups).length && (this.config.toolbarGroups = Object.keys(this.config.groups));
1627
1627
  }, ge = new WeakMap(), Ne = function(o, n, e = !1) {
1628
- const i = document.documentElement.clientWidth, { defaultItems: c, overflowItems: s } = Un(o, e, i, this.role, n);
1628
+ const i = document.documentElement.clientWidth, { defaultItems: c, overflowItems: s } = qn(o, e, i, this.role, n);
1629
1629
  let a = [
1630
1630
  ...c.map((u) => u.name.value),
1631
1631
  ...s.map((u) => u.name.value)
@@ -1641,7 +1641,7 @@ L = new WeakSet(), Qe = function() {
1641
1641
  i && (i.defaultLabel.value = o);
1642
1642
  }, tt = function() {
1643
1643
  if (!this.activeEditor || !this.activeEditor.converter || !this.activeEditor.converter.docHiglightColors.size) return;
1644
- const o = this.toolbarItems.find((s) => s.name.value === "highlight"), n = Ln(), e = 7, i = Array.from(this.activeEditor.converter.docHiglightColors).reduce((s, a, d) => {
1644
+ const o = this.toolbarItems.find((s) => s.name.value === "highlight"), n = Mn(), e = 7, i = Array.from(this.activeEditor.converter.docHiglightColors).reduce((s, a, d) => {
1645
1645
  const u = Math.floor(d / e);
1646
1646
  return s[u] || (s[u] = []), n.includes(a) || s[u].push(f(a)), s;
1647
1647
  }, []), c = {
@@ -1662,7 +1662,7 @@ L = new WeakSet(), Qe = function() {
1662
1662
  let i = o.command;
1663
1663
  i in this.activeEditor?.commands && (this.activeEditor.commands[i](n), typeof e == "function" && e(n), this.updateToolbarState());
1664
1664
  };
1665
- function Jn(t, l) {
1665
+ function Qn(t, l) {
1666
1666
  if (!t.value || !l?.value?.options?.scale) return;
1667
1667
  const o = l.value.options.scale, n = t.value.getBoundingClientRect(), e = t.value.querySelectorAll(".pagination-break-wrapper");
1668
1668
  let i;
@@ -1674,7 +1674,7 @@ function Jn(t, l) {
1674
1674
  }
1675
1675
  });
1676
1676
  }
1677
- const Qn = (t, l) => {
1677
+ const eo = (t, l) => {
1678
1678
  const o = t.clientY, n = t.clientX, { view: e } = l, i = e.dom.getBoundingClientRect();
1679
1679
  let c = {
1680
1680
  left: 0,
@@ -1693,7 +1693,7 @@ const Qn = (t, l) => {
1693
1693
  );
1694
1694
  e.dispatch(u), e.focus();
1695
1695
  }
1696
- }, eo = { class: "numbering" }, Se = 200, to = "flex-end", no = {
1696
+ }, to = { class: "numbering" }, Se = 200, no = "flex-end", oo = {
1697
1697
  __name: "Ruler",
1698
1698
  props: {
1699
1699
  orientation: {
@@ -1768,13 +1768,13 @@ const Qn = (t, l) => {
1768
1768
  }, ce = () => {
1769
1769
  c.value = "#CCC";
1770
1770
  }, de = () => r.value.side === "left" ? r.value.x / 96 : (a.value.width * 96 - r.value.x) / 96, se = W(() => ({
1771
- "--alignment": to,
1771
+ "--alignment": no,
1772
1772
  "--ruler-handle-color": c.value,
1773
1773
  "--ruler-handle-active-color": s.value
1774
1774
  }));
1775
1775
  return we(() => {
1776
1776
  i.value = M(), window.addEventListener("mousemove", N), window.addEventListener("mouseup", Q);
1777
- }), $t(() => {
1777
+ }), Ht(() => {
1778
1778
  window.removeEventListener("mousemove", N), window.removeEventListener("mouseup", Q);
1779
1779
  }), (T, I) => (k(), w("div", {
1780
1780
  class: "ruler",
@@ -1803,7 +1803,7 @@ const Qn = (t, l) => {
1803
1803
  class: oe(B.className),
1804
1804
  style: Y(p.value(B))
1805
1805
  }, [
1806
- E("div", eo, ie(B.numbering), 1),
1806
+ E("div", to, ie(B.numbering), 1),
1807
1807
  (k(!0), w(j, null, J(B.elements, (R) => (k(), w("div", {
1808
1808
  class: oe(R.className),
1809
1809
  style: Y(p.value(R))
@@ -1816,10 +1816,10 @@ const Qn = (t, l) => {
1816
1816
  ], 6))), 256))
1817
1817
  ], 4));
1818
1818
  }
1819
- }, oo = /* @__PURE__ */ G(no, [["__scopeId", "data-v-ad77036c"]]), io = { class: "super-editor-container" }, so = {
1819
+ }, io = /* @__PURE__ */ G(oo, [["__scopeId", "data-v-ad77036c"]]), so = { class: "super-editor-container" }, lo = {
1820
1820
  key: 1,
1821
1821
  class: "placeholder-editor"
1822
- }, lo = { class: "placeholder-title" }, ao = {
1822
+ }, ao = { class: "placeholder-title" }, ro = {
1823
1823
  __name: "SuperEditor",
1824
1824
  props: {
1825
1825
  documentId: {
@@ -1894,7 +1894,7 @@ const Qn = (t, l) => {
1894
1894
  fonts: H,
1895
1895
  ...n.options
1896
1896
  }), i.value.on("paginationUpdate", () => {
1897
- Jn(s, i);
1897
+ Qn(s, i);
1898
1898
  }), i.value.on("collaborationReady", () => {
1899
1899
  setTimeout(() => {
1900
1900
  e.value = !0;
@@ -1913,7 +1913,7 @@ const Qn = (t, l) => {
1913
1913
  b(), (n.options?.suppressSkeletonLoader || !n.options?.collaborationProvider) && (e.value = !0);
1914
1914
  });
1915
1915
  const M = (p) => {
1916
- p.target.classList.contains("ProseMirror") || Qn(p, i.value);
1916
+ p.target.classList.contains("ProseMirror") || eo(p, i.value);
1917
1917
  }, D = ({ side: p, value: C }) => {
1918
1918
  if (!i.value) return;
1919
1919
  const A = i.value.getPageStyles(), { pageMargins: H } = A, N = { ...H, [p]: C };
@@ -1921,8 +1921,8 @@ const Qn = (t, l) => {
1921
1921
  };
1922
1922
  return Ze(() => {
1923
1923
  d(), i.value?.destroy(), i.value = null;
1924
- }), (p, C) => (k(), w("div", io, [
1925
- t.options.rulers && i.value ? (k(), Ht(oo, {
1924
+ }), (p, C) => (k(), w("div", so, [
1925
+ t.options.rulers && i.value ? (k(), Bt(io, {
1926
1926
  key: 0,
1927
1927
  class: "ruler",
1928
1928
  editor: i.value,
@@ -1942,8 +1942,8 @@ const Qn = (t, l) => {
1942
1942
  class: "editor-element super-editor__element"
1943
1943
  }, null, 512)
1944
1944
  ], 544),
1945
- e.value ? ne("", !0) : (k(), w("div", so, [
1946
- E("div", lo, [
1945
+ e.value ? ne("", !0) : (k(), w("div", lo, [
1946
+ E("div", ao, [
1947
1947
  V($(Z), {
1948
1948
  text: "",
1949
1949
  style: { width: "60%" }
@@ -1989,7 +1989,7 @@ const Qn = (t, l) => {
1989
1989
  ]))
1990
1990
  ]));
1991
1991
  }
1992
- }, vo = /* @__PURE__ */ G(ao, [["__scopeId", "data-v-ff8f86f4"]]), yo = {
1992
+ }, yo = /* @__PURE__ */ G(ro, [["__scopeId", "data-v-ff8f86f4"]]), bo = {
1993
1993
  __name: "BasicUpload",
1994
1994
  emits: ["file-change"],
1995
1995
  setup(t, { emit: l }) {
@@ -2005,7 +2005,7 @@ const Qn = (t, l) => {
2005
2005
  }, null, 32)
2006
2006
  ]));
2007
2007
  }
2008
- }, ro = ["innerHTML"], co = {
2008
+ }, co = ["innerHTML"], uo = {
2009
2009
  __name: "SuperInput",
2010
2010
  props: {
2011
2011
  modelValue: {
@@ -2062,7 +2062,7 @@ const Qn = (t, l) => {
2062
2062
  id: "currentContent",
2063
2063
  style: { display: "none" },
2064
2064
  innerHTML: t.modelValue
2065
- }, null, 8, ro),
2065
+ }, null, 8, co),
2066
2066
  E("div", {
2067
2067
  ref_key: "editorElem",
2068
2068
  ref: i,
@@ -2070,31 +2070,32 @@ const Qn = (t, l) => {
2070
2070
  }, null, 512)
2071
2071
  ], 2));
2072
2072
  }
2073
- }, bo = /* @__PURE__ */ G(co, [["__scopeId", "data-v-4d5cff52"]]), ko = {
2074
- Node: Ct,
2075
- Attribute: wt,
2076
- Extension: kt,
2077
- Plugin: St
2073
+ }, ko = /* @__PURE__ */ G(uo, [["__scopeId", "data-v-4d5cff52"]]), wo = {
2074
+ Node: _t,
2075
+ Attribute: Ct,
2076
+ Extension: wt,
2077
+ Plugin: Tt,
2078
+ Mark: kt
2078
2079
  };
2079
2080
  export {
2080
- yo as BasicUpload,
2081
- _o as CommentsPluginKey,
2082
- Mo as DocxZipper,
2081
+ bo as BasicUpload,
2082
+ xo as CommentsPluginKey,
2083
+ Do as DocxZipper,
2083
2084
  Re as Editor,
2084
- ko as Extensions,
2085
- Io as SuperConverter,
2086
- vo as SuperEditor,
2087
- bo as SuperInput,
2088
- go as SuperToolbar,
2089
- Rt as Toolbar,
2090
- xo as TrackChangesBasePluginKey,
2091
- $o as createZip,
2092
- Eo as fieldAnnotationHelpers,
2085
+ wo as Extensions,
2086
+ Lo as SuperConverter,
2087
+ yo as SuperEditor,
2088
+ ko as SuperInput,
2089
+ vo as SuperToolbar,
2090
+ Ot as Toolbar,
2091
+ Eo as TrackChangesBasePluginKey,
2092
+ Ho as createZip,
2093
+ So as fieldAnnotationHelpers,
2093
2094
  pt as getActiveFormatting,
2094
- Zn as getAllowedImageDimensions,
2095
- So as getMarksFromSelection,
2095
+ Yn as getAllowedImageDimensions,
2096
+ To as getMarksFromSelection,
2096
2097
  bt as getRichTextExtensions,
2097
2098
  vt as getStarterExtensions,
2098
- To as helpers,
2099
- Ao as trackChangesHelpers
2099
+ Ao as helpers,
2100
+ Fo as trackChangesHelpers
2100
2101
  };