@harbour-enterprises/superdoc 0.11.57 → 0.11.58

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 (29) hide show
  1. package/dist/chunks/{index-Dw-Q9hD6.cjs → index-BWoN1jpL.cjs} +1 -1
  2. package/dist/chunks/{index-CWj8iOm4.es.js → index-Bu0Qz4_D.es.js} +1 -1
  3. package/dist/chunks/{index-CVyuWad2.es.js → index-CsjnTatF.es.js} +2 -2
  4. package/dist/chunks/{index-Dnm6LcB6.cjs → index-DLLQ5PJZ.cjs} +1 -1
  5. package/dist/chunks/{super-editor.es-kMbvFzrR.cjs → super-editor.es-D4v1tv4j.cjs} +41 -41
  6. package/dist/chunks/{super-editor.es-BuT2FFqD.es.js → super-editor.es-qCwVvR8-.es.js} +1958 -1978
  7. package/dist/chunks/{url-NtSPOzqh.es.js → url-D8ItQPzc.es.js} +1 -1
  8. package/dist/chunks/{url-BV2RvrTf.cjs → url-DRW8x74x.cjs} +1 -1
  9. package/dist/chunks/xml-js-DrlOWTO_.cjs +10 -0
  10. package/dist/chunks/{xml-js-BvgqUvJ5.es.js → xml-js-yTXP6usI.es.js} +638 -616
  11. package/dist/super-editor/ai-writer.es.js +2 -2
  12. package/dist/super-editor/chunks/{converter-D3X034CV.js → converter-BIFb-l0C.js} +269 -289
  13. package/dist/super-editor/chunks/{docx-zipper-CczfH-Gl.js → docx-zipper-Bf04SHvT.js} +1 -1
  14. package/dist/super-editor/chunks/{editor-CMO-734F.js → editor-BZ4VbwzA.js} +3 -3
  15. package/dist/super-editor/chunks/{toolbar-d1TvqceK.js → toolbar-mC-hpKkm.js} +2 -2
  16. package/dist/super-editor/converter.es.js +1 -1
  17. package/dist/super-editor/docx-zipper.es.js +2 -2
  18. package/dist/super-editor/editor.es.js +3 -3
  19. package/dist/super-editor/file-zipper.es.js +1 -1
  20. package/dist/super-editor/super-editor.es.js +6 -6
  21. package/dist/super-editor/toolbar.es.js +2 -2
  22. package/dist/super-editor.cjs +1 -1
  23. package/dist/super-editor.es.js +1 -1
  24. package/dist/superdoc.cjs +3 -3
  25. package/dist/superdoc.es.js +6 -6
  26. package/dist/superdoc.umd.js +378 -398
  27. package/dist/superdoc.umd.js.map +1 -1
  28. package/package.json +1 -1
  29. package/dist/chunks/xml-js-CCvZbbr7.cjs +0 -10
@@ -15231,7 +15231,7 @@ Actual: ` + p3.attribValue
15231
15231
  return this.excluded.indexOf(e) > -1;
15232
15232
  }
15233
15233
  };
15234
- let Op$1 = class Op {
15234
+ let Pp$1 = class Pp {
15235
15235
  /**
15236
15236
  Construct a schema from a schema [specification](https://prosemirror.net/docs/ref/#model.SchemaSpec).
15237
15237
  */
@@ -16694,7 +16694,7 @@ Actual: ` + p3.attribValue
16694
16694
  function lf$2(r22, e, t) {
16695
16695
  return (e == 0 || r22.canReplace(e, r22.childCount)) && (t == r22.childCount || r22.canReplace(0, t));
16696
16696
  }
16697
- function _p$1(r22) {
16697
+ function Lp$1(r22) {
16698
16698
  let t = r22.parent.content.cutByIndex(r22.startIndex, r22.endIndex);
16699
16699
  for (let n = r22.depth; ; --n) {
16700
16700
  let i3 = r22.$from.node(n), s = r22.$from.index(n), o = r22.$to.indexAfter(n);
@@ -16714,7 +16714,7 @@ Actual: ` + p3.attribValue
16714
16714
  v || i3.after(A3 + 1) < i3.end(A3) ? (v = true, g = Q$1.from(i3.node(A3).copy(g)), E3++) : c3++;
16715
16715
  r22.step(new $e$2(u, c3, o, a, new ae$4(l.append(g), h3, E3), l.size - h3, true));
16716
16716
  }
16717
- function qp$1(r22, e, t = null, n = r22) {
16717
+ function _p$1(r22, e, t = null, n = r22) {
16718
16718
  let i3 = ff$2(r22, e), s = i3 && df$2(n, e);
16719
16719
  return s ? i3.map(wo$3).concat({ type: e, attrs: t }).concat(s.map(wo$3)) : null;
16720
16720
  }
@@ -16804,7 +16804,7 @@ Actual: ` + p3.attribValue
16804
16804
  throw new RangeError("Invalid content for node type " + t.name);
16805
16805
  r22.step(new $e$2(e, e + s.nodeSize, e + 1, e + s.nodeSize - 1, new ae$4(Q$1.from(o), 0, 0), 1, true));
16806
16806
  }
16807
- function Mp$1(r22, e, t = 1, n) {
16807
+ function qp$1(r22, e, t = 1, n) {
16808
16808
  let i3 = r22.resolve(e), s = i3.depth - t, o = n && n[n.length - 1] || i3.parent;
16809
16809
  if (s < 0 || i3.parent.type.spec.isolating || !i3.parent.canReplace(i3.index(), i3.parent.childCount) || !o.type.validContent(i3.parent.content.cutByIndex(i3.index(), i3.parent.childCount)))
16810
16810
  return false;
@@ -16830,7 +16830,7 @@ Actual: ` + p3.attribValue
16830
16830
  }
16831
16831
  r22.step(new Ie$2(e, e, new ae$4(s.append(o), t, t), true));
16832
16832
  }
16833
- function Up$1(r22, e) {
16833
+ function Mp$1(r22, e) {
16834
16834
  let t = r22.resolve(e), n = t.index();
16835
16835
  return Ga$2(t.nodeBefore, t.nodeAfter) && t.parent.canReplace(n, n + 1);
16836
16836
  }
@@ -16847,7 +16847,7 @@ Actual: ` + p3.attribValue
16847
16847
  function Ga$2(r22, e) {
16848
16848
  return !!(r22 && e && !r22.isLeaf && yf$2(r22, e));
16849
16849
  }
16850
- function jp$1(r22, e, t = -1) {
16850
+ function Up$1(r22, e, t = -1) {
16851
16851
  let n = r22.resolve(e);
16852
16852
  for (let i3 = n.depth; ; i3--) {
16853
16853
  let s, o, a = n.index(i3);
@@ -16899,7 +16899,7 @@ Actual: ` + p3.attribValue
16899
16899
  }
16900
16900
  return null;
16901
16901
  }
16902
- function Hp$1(r22, e, t) {
16902
+ function jp$1(r22, e, t) {
16903
16903
  let n = r22.resolve(e);
16904
16904
  if (!t.content.size)
16905
16905
  return e;
@@ -18274,7 +18274,7 @@ Actual: ` + p3.attribValue
18274
18274
  }
18275
18275
  return t;
18276
18276
  }
18277
- let Vp$1 = class Vp {
18277
+ let Hp$1 = class Hp {
18278
18278
  /**
18279
18279
  Create a plugin.
18280
18280
  */
@@ -18292,7 +18292,7 @@ Actual: ` + p3.attribValue
18292
18292
  function Ya$2(r22) {
18293
18293
  return r22 in oi ? r22 + "$" + ++oi[r22] : (oi[r22] = 0, r22 + "$");
18294
18294
  }
18295
- let zp$1 = class zp {
18295
+ let Vp$1 = class Vp {
18296
18296
  /**
18297
18297
  Create a plugin key.
18298
18298
  */
@@ -18313,7 +18313,7 @@ Actual: ` + p3.attribValue
18313
18313
  return e[this.key];
18314
18314
  }
18315
18315
  };
18316
- const Za$2 = (r22) => r22.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`), Gp$1 = (r22) => Za$2(r22), Wp$1 = Object.freeze({
18316
+ const Za$2 = (r22) => r22.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`), zp$1 = (r22) => Za$2(r22), Gp$1 = Object.freeze({
18317
18317
  RESOLVED: "resolved",
18318
18318
  NEW: "new",
18319
18319
  ADD: "add",
@@ -18326,7 +18326,7 @@ Actual: ` + p3.attribValue
18326
18326
  // Tracked changes
18327
18327
  CHANGE_ACCEPTED: "change-accepted",
18328
18328
  CHANGE_REJECTED: "change-rejected"
18329
- }), Jp$1 = {
18329
+ }), Wp$1 = {
18330
18330
  mounted(r22, e, t) {
18331
18331
  const n = (i3) => {
18332
18332
  r22.contains(i3.target) || e.value(i3);
@@ -18337,20 +18337,20 @@ Actual: ` + p3.attribValue
18337
18337
  document.removeEventListener("click", r22.__clickOutsideHandler), delete r22.__clickOutsideHandler;
18338
18338
  }
18339
18339
  };
18340
- function $p$1(r22, e = null, ...t) {
18340
+ function Jp$1(r22, e = null, ...t) {
18341
18341
  return typeof r22 == "function" ? e ? r22.bind(e)(...t) : r22(...t) : r22;
18342
18342
  }
18343
- function Kp$1(r22 = {}) {
18343
+ function $p$1(r22 = {}) {
18344
18344
  return Object.keys(r22).length === 0 && r22.constructor === Object;
18345
18345
  }
18346
- const Xp$1 = () => typeof navigator < "u" ? /Mac/.test(navigator.platform) : false, Yp$1 = () => ["iPad Simulator", "iPhone Simulator", "iPod Simulator", "iPad", "iPhone", "iPod"].includes(
18346
+ const Kp$1 = () => typeof navigator < "u" ? /Mac/.test(navigator.platform) : false, Xp$1 = () => ["iPad Simulator", "iPhone Simulator", "iPod Simulator", "iPad", "iPhone", "iPod"].includes(
18347
18347
  navigator.platform
18348
18348
  ), Rf$1 = (r22) => Object.prototype.toString.call(r22) === "[object RegExp]";
18349
18349
  function Pf$1(r22, e, t = { strict: true }) {
18350
18350
  const n = Object.keys(e);
18351
18351
  return n.length ? n.every((i3) => t.strict ? e[i3] === r22[i3] : Rf$1(e[i3]) ? e[i3].test(r22[i3]) : e[i3] === r22[i3]) : true;
18352
18352
  }
18353
- function Zp$1(r22, e) {
18353
+ function Yp$1(r22, e) {
18354
18354
  const n = typeof e == "string" ? [e] : e;
18355
18355
  return Object.keys(r22).reduce((i3, s) => (n.includes(s) || (i3[s] = r22[s]), i3), {});
18356
18356
  }
@@ -18359,7 +18359,7 @@ Actual: ` + p3.attribValue
18359
18359
  const e = r22.toString() || "0", t = Number.parseFloat(e), i3 = (e.match(Of$2)?.[1] ?? "").toLowerCase();
18360
18360
  return [t, Lf$1.includes(i3) ? i3 : null];
18361
18361
  }
18362
- function Qp$1(r22 = 0, e = 0, t = 0) {
18362
+ function Zp$1(r22 = 0, e = 0, t = 0) {
18363
18363
  return Math.min(Math.max(r22, e), t);
18364
18364
  }
18365
18365
  function It$2(r22) {
@@ -18435,7 +18435,7 @@ Actual: ` + p3.attribValue
18435
18435
  }
18436
18436
  const i3 = St$2.from(n, "base64");
18437
18437
  return i3.buffer.slice(i3.byteOffset, i3.byteOffset + i3.byteLength);
18438
- }, eh$2 = (r22) => {
18438
+ }, Qp$1 = (r22) => {
18439
18439
  const n = new window.DOMParser().parseFromString(r22, "text/xml").querySelectorAll("Default");
18440
18440
  return Array.from(n).map((i3) => i3.getAttribute("Extension"));
18441
18441
  }, jf$1 = (r22) => (/* @__PURE__ */ new Map([
@@ -18471,7 +18471,7 @@ Actual: ` + p3.attribValue
18471
18471
  const Vf$1 = (r22) => {
18472
18472
  const e = Number(r22).toString(16);
18473
18473
  return e.length === 1 ? "0" + e : e;
18474
- }, zf$2 = (r22) => "#" + r22.match(/\d+/g).map(Vf$1).join(""), th$2 = (r22, e, t = "", n = false) => {
18474
+ }, zf$2 = (r22) => "#" + r22.match(/\d+/g).map(Vf$1).join(""), eh$2 = (r22, e, t = "", n = false) => {
18475
18475
  let [i3, s] = _f$1(r22);
18476
18476
  return Number.isNaN(i3) || i3 === 0 ? {} : t === "atLeast" && i3 < 1 ? {} : (s = s || e, i3 += s ? 4 : 0.2, n ? { "line-height": `${i3}${s}` } : `line-height: ${i3}${s}`);
18477
18477
  }, Gf$1 = (r22, e) => {
@@ -21135,25 +21135,25 @@ Actual: ` + p3.attribValue
21135
21135
  doc: yd$2,
21136
21136
  body: gd$2,
21137
21137
  paragraph: su$2,
21138
- text: xd$2,
21138
+ text: bd$2,
21139
21139
  bulletList: Fo$2,
21140
21140
  orderedList: Fo$2,
21141
- lineBreak: Fd$2,
21142
- table: Bd$2,
21143
- tableRow: Od$2,
21144
- tableCell: _d$2,
21145
- bookmarkStart: Ud$2,
21146
- fieldAnnotation: Jd$2,
21147
- tab: Nd$2,
21141
+ lineBreak: Td$2,
21142
+ table: Fd$2,
21143
+ tableRow: Pd$2,
21144
+ tableCell: Ld$2,
21145
+ bookmarkStart: Md$2,
21146
+ fieldAnnotation: Wd$2,
21147
+ tab: kd$2,
21148
21148
  image: lu$2,
21149
- hardBreak: $d$2,
21149
+ hardBreak: Jd$2,
21150
21150
  commentRangeStart: () => So$1(r22, "Start"),
21151
21151
  commentRangeEnd: () => So$1(r22, "End"),
21152
21152
  commentReference: () => null,
21153
- shapeContainer: Kd$2,
21154
- shapeTextbox: Xd$2,
21155
- contentBlock: Yd$2,
21156
- structuredContent: em$1
21153
+ shapeContainer: $d$2,
21154
+ shapeTextbox: Kd$2,
21155
+ contentBlock: Xd$2,
21156
+ structuredContent: Qd$2
21157
21157
  };
21158
21158
  return t[e] ? t[e](r22) : (console.error("No translation function found for node type:", e), null);
21159
21159
  }
@@ -21273,29 +21273,9 @@ Actual: ` + p3.attribValue
21273
21273
  const t = [];
21274
21274
  return e.forEach((n) => {
21275
21275
  let i3 = qt$2({ ...r22, node: n });
21276
- (i3?.name || i3?.type) !== "w:sdt" && (i3 = bd$2(i3)), i3 instanceof Array ? t.push(...i3) : t.push(i3);
21276
+ i3?.name || i3?.type, i3 instanceof Array ? t.push(...i3) : t.push(i3);
21277
21277
  }), t.filter((n) => n);
21278
21278
  }
21279
- const bd$2 = (r22) => {
21280
- if (!r22) return r22;
21281
- const e = r22.elements?.some((a) => a.name === "w:r"), t = r22.elements?.some((a) => a.name === "w:sdt");
21282
- if (!r22.elements?.find((a) => a.name === "w:sdt")?.elements?.find((a) => a.name === "w:sdtPr")?.elements?.some((a) => a.name === "w:alias")) return r22;
21283
- let o = r22;
21284
- if (e && t) {
21285
- const a = r22.elements.filter((l) => l.name === "w:sdt"), u = r22.elements.filter((l) => l.name !== "w:sdt");
21286
- o = [
21287
- ...u.filter((l) => l.name === "w:r").every((l) => l.elements.filter((g) => g.name === "w:t")?.every((g) => g.elements[0].text.trim().length > 0)) ? [{
21288
- ...r22,
21289
- elements: u
21290
- }] : [],
21291
- {
21292
- name: "w:p",
21293
- elements: a
21294
- }
21295
- ];
21296
- }
21297
- return o;
21298
- };
21299
21279
  function Br$2(r22, e, t) {
21300
21280
  const i3 = /^\s|\s$/.test(r22) ? "preserve" : null, s = i3 ? { "xml:space": i3 } : null, o = [], a = kr$1(e);
21301
21281
  if (o.push({
@@ -21331,14 +21311,14 @@ Actual: ` + p3.attribValue
21331
21311
  }
21332
21312
  return Zt$3(o, a);
21333
21313
  }
21334
- function xd$2(r22) {
21314
+ function bd$2(r22) {
21335
21315
  const { node: e } = r22, t = [xr$2, Pi$2];
21336
- if (e.marks?.some((a) => t.includes(a.type))) return Dd$2(r22);
21337
- if (e.marks?.some((a) => a.type === "link")) return vd$2(r22);
21316
+ if (e.marks?.some((a) => t.includes(a.type))) return Ad$2(r22);
21317
+ if (e.marks?.some((a) => a.type === "link")) return Dd$2(r22);
21338
21318
  const { text: s, marks: o = [] } = e;
21339
21319
  return Br$2(s, o, r22);
21340
21320
  }
21341
- function Ad$2(r22) {
21321
+ function xd$2(r22) {
21342
21322
  const e = r22.find((t) => t.type === Oi$2);
21343
21323
  if (e)
21344
21324
  return {
@@ -21353,8 +21333,8 @@ Actual: ` + p3.attribValue
21353
21333
  elements: e.attrs.before.map((n) => kr$1([n])).filter((n) => n !== void 0)
21354
21334
  };
21355
21335
  }
21356
- function Dd$2(r22) {
21357
- const { node: e } = r22, t = e.marks, n = [xr$2, Pi$2, Oi$2], i3 = t.find((c3) => n.includes(c3.type)), s = i3.type === xr$2, o = Ad$2(t);
21336
+ function Ad$2(r22) {
21337
+ const { node: e } = r22, t = e.marks, n = [xr$2, Pi$2, Oi$2], i3 = t.find((c3) => n.includes(c3.type)), s = i3.type === xr$2, o = xd$2(t);
21358
21338
  e.marks = t.filter((c3) => !n.includes(c3.type)), o && e.marks.push(o);
21359
21339
  const a = qt$2({ ...r22, node: e });
21360
21340
  if (!s) {
@@ -21392,7 +21372,7 @@ Actual: ` + p3.attribValue
21392
21372
  return Bo$2(i3);
21393
21373
  }) : Bo$2(e));
21394
21374
  }
21395
- function vd$2(r22) {
21375
+ function Dd$2(r22) {
21396
21376
  const { node: e } = r22, t = e.marks.find((u) => u.type === "link"), n = t.attrs.href;
21397
21377
  let i3 = t.attrs.rId;
21398
21378
  i3 || (i3 = uu$2(r22, n)), e.marks = e.marks.filter((u) => u.type !== "link");
@@ -21461,9 +21441,9 @@ Actual: ` + p3.attribValue
21461
21441
  return r22.relationships.push(n), t;
21462
21442
  }
21463
21443
  function Fo$2(r22) {
21464
- const { type: e } = r22.node, t = Td$2(r22), n = [];
21444
+ const { type: e } = r22.node, t = Sd$2(r22), n = [];
21465
21445
  return t.forEach((i3) => {
21466
- const { level: s, listType: o, pPrs: a, content: u, attrs: c3 = {} } = i3, g = (i3.attrs.numId || i3.listId) ?? Ed$2(r22, o), E3 = Sd$2(s, g, a);
21446
+ const { level: s, listType: o, pPrs: a, content: u, attrs: c3 = {} } = i3, g = (i3.attrs.numId || i3.listId) ?? vd$2(r22, o), E3 = Cd$2(s, g, a);
21467
21447
  u.forEach((A3, v) => {
21468
21448
  const F = Object.assign({}, A3);
21469
21449
  F.attrs = {
@@ -21499,8 +21479,8 @@ Actual: ` + p3.attribValue
21499
21479
  });
21500
21480
  }), n;
21501
21481
  }
21502
- function Ed$2(r22, e) {
21503
- const t = Cd$2(r22.converter?.numbering?.definitions), n = e === "bullet" ? nd$2 : rd$2, i3 = t, s = n.attributes["w:abstractNumId"], o = {
21482
+ function vd$2(r22, e) {
21483
+ const t = Ed$2(r22.converter?.numbering?.definitions), n = e === "bullet" ? nd$2 : rd$2, i3 = t, s = n.attributes["w:abstractNumId"], o = {
21504
21484
  type: "element",
21505
21485
  name: "w:num",
21506
21486
  attributes: {
@@ -21513,8 +21493,8 @@ Actual: ` + p3.attribValue
21513
21493
  };
21514
21494
  return r22.converter.numbering.definitions[i3] = o, i3;
21515
21495
  }
21516
- const Cd$2 = (r22) => !r22 || !Object.keys(r22).length ? 0 : Math.max(...Object.keys(r22).map((t) => parseInt(t, 10))) + 1;
21517
- function Sd$2(r22, e, t = []) {
21496
+ const Ed$2 = (r22) => !r22 || !Object.keys(r22).length ? 0 : Math.max(...Object.keys(r22).map((t) => parseInt(t, 10))) + 1;
21497
+ function Cd$2(r22, e, t = []) {
21518
21498
  return {
21519
21499
  name: "w:pPr",
21520
21500
  type: "element",
@@ -21539,7 +21519,7 @@ Actual: ` + p3.attribValue
21539
21519
  ]
21540
21520
  };
21541
21521
  }
21542
- function Td$2({ node: r22 }) {
21522
+ function Sd$2({ node: r22 }) {
21543
21523
  const { content: e, attrs: t = {} } = r22, { listId: n, syncId: i3 } = r22.attrs || {}, s = r22.attrs["list-style-type"], { attributes: o = {} } = t, a = o?.parentAttributes?.paragraphProperties?.elements?.filter((l) => l.name !== "w:numPr") || [], u = [];
21544
21524
  function c3(l, h3 = 0) {
21545
21525
  !l || !l.length || l.forEach((g) => {
@@ -21560,22 +21540,22 @@ Actual: ` + p3.attribValue
21560
21540
  }
21561
21541
  return c3(e), u;
21562
21542
  }
21563
- function Fd$2(r22) {
21543
+ function Td$2(r22) {
21564
21544
  const e = {}, { lineBreakType: t } = r22.node?.attrs || {};
21565
21545
  return t && (e["w:type"] = t), {
21566
21546
  name: "w:br",
21567
21547
  attributes: e
21568
21548
  };
21569
21549
  }
21570
- function Bd$2(r22) {
21571
- r22.node = kd$2(r22.node, r22);
21572
- const e = lt$3(r22), t = Id$2(r22.node), n = Pd$2(r22.node, r22);
21550
+ function Fd$2(r22) {
21551
+ r22.node = Bd$2(r22.node, r22);
21552
+ const e = lt$3(r22), t = Nd$2(r22.node), n = Rd$2(r22.node, r22);
21573
21553
  return e.unshift(t), e.unshift(n), {
21574
21554
  name: "w:tbl",
21575
21555
  elements: e
21576
21556
  };
21577
21557
  }
21578
- function kd$2(r22, { editorSchema: e }) {
21558
+ function Bd$2(r22, { editorSchema: e }) {
21579
21559
  const { content: t } = r22;
21580
21560
  for (let n = 0; n < t.length; n++) {
21581
21561
  const i3 = t[n];
@@ -21611,13 +21591,13 @@ Actual: ` + p3.attribValue
21611
21591
  }
21612
21592
  return r22;
21613
21593
  }
21614
- function Nd$2(r22) {
21594
+ function kd$2(r22) {
21615
21595
  const { marks: e = [] } = r22.node, t = kr$1(e);
21616
21596
  return Zt$3({
21617
21597
  name: "w:tab"
21618
21598
  }, t);
21619
21599
  }
21620
- function Id$2(r22) {
21600
+ function Nd$2(r22) {
21621
21601
  const e = [], { attrs: t } = r22, { tableWidth: n, tableWidthType: i3, tableStyleId: s, borders: o, tableIndent: a, tableLayout: u, tableCellSpacing: c3 } = t;
21622
21602
  if (s) {
21623
21603
  const l = {
@@ -21627,7 +21607,7 @@ Actual: ` + p3.attribValue
21627
21607
  e.push(l);
21628
21608
  }
21629
21609
  if (o) {
21630
- const l = Rd$2(r22);
21610
+ const l = Id$2(r22);
21631
21611
  e.push(l);
21632
21612
  }
21633
21613
  if (a) {
@@ -21662,7 +21642,7 @@ Actual: ` + p3.attribValue
21662
21642
  elements: e
21663
21643
  };
21664
21644
  }
21665
- function Rd$2(r22) {
21645
+ function Id$2(r22) {
21666
21646
  const { borders: e } = r22.attrs, t = [];
21667
21647
  return e ? (["top", "bottom", "left", "right", "insideH", "insideV"].forEach((i3) => {
21668
21648
  const s = e[i3];
@@ -21686,7 +21666,7 @@ Actual: ` + p3.attribValue
21686
21666
  elements: t
21687
21667
  }) : void 0;
21688
21668
  }
21689
- function Pd$2(r22, e) {
21669
+ function Rd$2(r22, e) {
21690
21670
  const { editorSchema: t } = e;
21691
21671
  let n = [];
21692
21672
  try {
@@ -21709,14 +21689,14 @@ Actual: ` + p3.attribValue
21709
21689
  elements: i3
21710
21690
  };
21711
21691
  }
21712
- function Od$2(r22) {
21713
- const e = lt$3(r22), t = Ld$2(r22.node);
21692
+ function Pd$2(r22) {
21693
+ const e = lt$3(r22), t = Od$2(r22.node);
21714
21694
  return t.elements.length && e.unshift(t), {
21715
21695
  name: "w:tr",
21716
21696
  elements: e
21717
21697
  };
21718
21698
  }
21719
- function Ld$2(r22) {
21699
+ function Od$2(r22) {
21720
21700
  const { attrs: e } = r22, t = [], { rowHeight: n, rowHeightType: i3 } = e;
21721
21701
  if (n) {
21722
21702
  const s = { "w:val": Te$2(n) };
@@ -21732,17 +21712,17 @@ Actual: ` + p3.attribValue
21732
21712
  elements: t
21733
21713
  };
21734
21714
  }
21735
- function _d$2(r22) {
21715
+ function Ld$2(r22) {
21736
21716
  const e = lt$3({
21737
21717
  ...r22,
21738
21718
  tableCell: r22.node
21739
- }), t = qd$2(r22.node);
21719
+ }), t = _d$2(r22.node);
21740
21720
  return e.unshift(t), {
21741
21721
  name: "w:tc",
21742
21722
  elements: e
21743
21723
  };
21744
21724
  }
21745
- function qd$2(r22) {
21725
+ function _d$2(r22) {
21746
21726
  const e = [], { attrs: t } = r22, { colwidth: n = [], cellWidthType: i3 = "dxa", background: s = {}, colspan: o, rowspan: a, widthUnit: u } = t, c3 = n.reduce((v, F) => v + F, 0), l = {
21747
21727
  name: "w:tcW",
21748
21728
  attributes: { "w:w": u === "px" ? Te$2(c3) : It$2(c3), "w:type": i3 }
@@ -21766,7 +21746,7 @@ Actual: ` + p3.attribValue
21766
21746
  if (g) {
21767
21747
  const v = {
21768
21748
  name: "w:tcMar",
21769
- elements: Md$2(g)
21749
+ elements: qd$2(g)
21770
21750
  };
21771
21751
  e.push(v);
21772
21752
  }
@@ -21818,11 +21798,11 @@ Actual: ` + p3.attribValue
21818
21798
  elements: e
21819
21799
  };
21820
21800
  }
21821
- function Md$2(r22) {
21801
+ function qd$2(r22) {
21822
21802
  const e = [], { top: t, right: n, bottom: i3, left: s } = r22;
21823
21803
  return t != null && e.push({ name: "w:top", attributes: { "w:w": Te$2(t) } }), n != null && e.push({ name: "w:right", attributes: { "w:w": Te$2(n) } }), i3 != null && e.push({ name: "w:bottom", attributes: { "w:w": Te$2(i3) } }), s != null && e.push({ name: "w:left", attributes: { "w:w": Te$2(s) } }), e;
21824
21804
  }
21825
- function Ud$2(r22) {
21805
+ function Md$2(r22) {
21826
21806
  const e = {
21827
21807
  name: "w:bookmarkStart",
21828
21808
  attributes: {
@@ -21879,7 +21859,7 @@ Actual: ` + p3.attribValue
21879
21859
  }
21880
21860
  return t;
21881
21861
  }
21882
- function jd$2(r22) {
21862
+ function Ud$2(r22) {
21883
21863
  if (!r22) return {};
21884
21864
  const e = r22.split(";")[0].split("/")[1];
21885
21865
  if (!r22 || e !== "png")
@@ -21893,7 +21873,7 @@ Actual: ` + p3.attribValue
21893
21873
  originalHeight: i3.getInt32(20)
21894
21874
  };
21895
21875
  }
21896
- function Hd$2(r22, e, t, n) {
21876
+ function jd$2(r22, e, t, n) {
21897
21877
  let i3 = r22, s = e, o = Math.min(t / r22, n / e);
21898
21878
  return i3 = Math.round(i3 * o), s = Math.round(s * o), { scaledWidth: i3, scaledHeight: s };
21899
21879
  }
@@ -21903,20 +21883,20 @@ Actual: ` + p3.attribValue
21903
21883
  tableCell: i3
21904
21884
  } = r22;
21905
21885
  let s = t.rId;
21906
- const o = t.src || t.imageSrc, { originalWidth: a, originalHeight: u } = jd$2(o);
21886
+ const o = t.src || t.imageSrc, { originalWidth: a, originalHeight: u } = Ud$2(o);
21907
21887
  let c3 = t.size ? {
21908
21888
  w: mt$1(t.size.width),
21909
21889
  h: mt$1(t.size.height)
21910
21890
  } : e;
21911
21891
  if (a && u) {
21912
- const F = Me$2(c3.w), w = Me$2(c3.h), { scaledWidth: B3, scaledHeight: R } = Hd$2(a, u, F, w);
21892
+ const F = Me$2(c3.w), w = Me$2(c3.h), { scaledWidth: B3, scaledHeight: R } = jd$2(a, u, F, w);
21913
21893
  c3 = {
21914
21894
  w: mt$1(B3),
21915
21895
  h: mt$1(R)
21916
21896
  };
21917
21897
  }
21918
21898
  if (i3) {
21919
- const F = i3.attrs.colwidth.reduce((N3, M) => N3 + M, 0), w = i3.attrs.cellMargins?.left || 8, B3 = i3.attrs.cellMargins?.right || 8, R = mt$1(F - (w + B3)), { width: D, height: k } = Zd$2(c3.w, c3.h, R);
21899
+ const F = i3.attrs.colwidth.reduce((N3, M) => N3 + M, 0), w = i3.attrs.cellMargins?.left || 8, B3 = i3.attrs.cellMargins?.right || 8, R = mt$1(F - (w + B3)), { width: D, height: k } = Yd$2(c3.w, c3.h, R);
21920
21900
  D && k && (c3 = { w: D, h: k });
21921
21901
  }
21922
21902
  if (r22.node.type === "image" && !s) {
@@ -22157,13 +22137,13 @@ Actual: ` + p3.attribValue
22157
22137
  } = r22, n = fu$2(e);
22158
22138
  return Br$2(e.displayLabel, [...t, ...n], r22);
22159
22139
  }
22160
- function Vd$2(r22) {
22140
+ function Hd$2(r22) {
22161
22141
  const {
22162
22142
  node: { attrs: e = {}, marks: t = [] }
22163
22143
  } = r22, n = Rc$2.decode(e.displayLabel);
22164
22144
  return Br$2(n, t, r22);
22165
22145
  }
22166
- function zd$2(r22) {
22146
+ function Vd$2(r22) {
22167
22147
  const {
22168
22148
  node: { attrs: e = {}, marks: t = [] },
22169
22149
  editorSchema: n
@@ -22171,7 +22151,7 @@ Actual: ` + p3.attribValue
22171
22151
  let u = Ct$2.create({
22172
22152
  doc: yr$2.fromSchema(n).parse(s)
22173
22153
  });
22174
- a.length && (u = Qd$2(u, a));
22154
+ a.length && (u = Zd$2(u, a));
22175
22155
  const c3 = u.doc.toJSON();
22176
22156
  return {
22177
22157
  name: "htmlAnnotation",
@@ -22184,7 +22164,7 @@ Actual: ` + p3.attribValue
22184
22164
  function ko$3(r22, e) {
22185
22165
  return lu$2(r22, e);
22186
22166
  }
22187
- function Gd$2(r22) {
22167
+ function zd$2(r22) {
22188
22168
  const {
22189
22169
  node: { attrs: e = {}, marks: t = [] }
22190
22170
  } = r22, n = uu$2(r22, e.linkUrl), i3 = Br$2(e.linkUrl, t, r22), s = au$2(i3);
@@ -22198,7 +22178,7 @@ Actual: ` + p3.attribValue
22198
22178
  elements: [s]
22199
22179
  };
22200
22180
  }
22201
- function Wd$2(r22) {
22181
+ function Gd$2(r22) {
22202
22182
  const e = {
22203
22183
  w: 4286250,
22204
22184
  h: 4286250
@@ -22210,9 +22190,9 @@ Actual: ` + p3.attribValue
22210
22190
  text: cu$2,
22211
22191
  image: (i3) => ko$3(i3, e),
22212
22192
  signature: (i3) => ko$3(i3, t),
22213
- checkbox: Vd$2,
22214
- html: zd$2,
22215
- link: Gd$2
22193
+ checkbox: Hd$2,
22194
+ html: Vd$2,
22195
+ link: zd$2
22216
22196
  }[r22];
22217
22197
  }
22218
22198
  const fu$2 = (r22 = {}) => {
@@ -22227,8 +22207,8 @@ Actual: ` + p3.attribValue
22227
22207
  } = r22, u = [];
22228
22208
  return e && u.push({ type: "fontFamily", attrs: { fontFamily: e } }), t && u.push({ type: "fontSize", attrs: { fontSize: t } }), n && u.push({ type: "bold", attrs: {} }), i3 && u.push({ type: "underline", attrs: {} }), s && u.push({ type: "italic", attrs: {} }), o && u.push({ type: "color", attrs: { color: o } }), a && u.push({ type: "highlight", attrs: { color: a } }), u;
22229
22209
  };
22230
- function Jd$2(r22) {
22231
- const { node: e, isFinalDoc: t } = r22, { attrs: n = {} } = e, i3 = Wd$2(n.type);
22210
+ function Wd$2(r22) {
22211
+ const { node: e, isFinalDoc: t } = r22, { attrs: n = {} } = e, i3 = Gd$2(n.type);
22232
22212
  if (!i3) return {};
22233
22213
  let s, o;
22234
22214
  if (t)
@@ -22308,7 +22288,7 @@ Actual: ` + p3.attribValue
22308
22288
  ]
22309
22289
  };
22310
22290
  }
22311
- function $d$2(r22) {
22291
+ function Jd$2(r22) {
22312
22292
  const { node: e = {} } = r22, { attrs: t = {} } = e, { pageBreakSource: n } = t;
22313
22293
  return n === "sectPr" ? null : {
22314
22294
  name: "w:r",
@@ -22319,7 +22299,7 @@ Actual: ` + p3.attribValue
22319
22299
  }]
22320
22300
  };
22321
22301
  }
22322
- function Kd$2(r22) {
22302
+ function $d$2(r22) {
22323
22303
  const { node: e } = r22, t = lt$3(r22), n = {
22324
22304
  name: "v:shape",
22325
22305
  attributes: {
@@ -22345,7 +22325,7 @@ Actual: ` + p3.attribValue
22345
22325
  elements: [Zt$3(i3)]
22346
22326
  };
22347
22327
  }
22348
- function Xd$2(r22) {
22328
+ function Kd$2(r22) {
22349
22329
  const { node: e } = r22, n = {
22350
22330
  name: "w:txbxContent",
22351
22331
  elements: lt$3(r22)
@@ -22358,7 +22338,7 @@ Actual: ` + p3.attribValue
22358
22338
  elements: [n]
22359
22339
  };
22360
22340
  }
22361
- function Yd$2(r22) {
22341
+ function Xd$2(r22) {
22362
22342
  const { node: e } = r22, { drawingContent: t } = e.attrs, n = {
22363
22343
  name: "w:drawing",
22364
22344
  elements: [
@@ -22425,14 +22405,14 @@ Actual: ` + p3.attribValue
22425
22405
  }
22426
22406
  return a || u.push(`</${n}>`), u;
22427
22407
  };
22428
- function Zd$2(r22, e, t) {
22408
+ function Yd$2(r22, e, t) {
22429
22409
  if (r22 > t) {
22430
22410
  let n = t / r22, i3 = Math.round(e * n);
22431
22411
  return { width: t, height: i3 };
22432
22412
  }
22433
22413
  return { width: r22, height: e };
22434
22414
  }
22435
- function Qd$2(r22, e) {
22415
+ function Zd$2(r22, e) {
22436
22416
  const { tr: t, doc: n, schema: i3 } = r22, s = ["fontFamily", "fontSize", "highlight"];
22437
22417
  if (!e.some((h3) => s.includes(h3.type)))
22438
22418
  return r22;
@@ -22454,7 +22434,7 @@ Actual: ` + p3.attribValue
22454
22434
  }));
22455
22435
  }), r22.apply(t);
22456
22436
  }
22457
- function em$1(r22) {
22437
+ function Qd$2(r22) {
22458
22438
  const { node: e } = r22, { attrs: t = {} } = e, i3 = [
22459
22439
  {
22460
22440
  name: "w:sdtContent",
@@ -22466,21 +22446,21 @@ Actual: ` + p3.attribValue
22466
22446
  elements: i3
22467
22447
  };
22468
22448
  }
22469
- const tm$1 = '<w:document xmlns:wpc="http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas" xmlns:cx="http://schemas.microsoft.com/office/drawing/2014/chartex" xmlns:cx1="http://schemas.microsoft.com/office/drawing/2015/9/8/chartex" xmlns:cx2="http://schemas.microsoft.com/office/drawing/2015/10/21/chartex" xmlns:cx3="http://schemas.microsoft.com/office/drawing/2016/5/9/chartex" xmlns:cx4="http://schemas.microsoft.com/office/drawing/2016/5/10/chartex" xmlns:cx5="http://schemas.microsoft.com/office/drawing/2016/5/11/chartex" xmlns:cx6="http://schemas.microsoft.com/office/drawing/2016/5/12/chartex" xmlns:cx7="http://schemas.microsoft.com/office/drawing/2016/5/13/chartex" xmlns:cx8="http://schemas.microsoft.com/office/drawing/2016/5/14/chartex" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:aink="http://schemas.microsoft.com/office/drawing/2016/ink" xmlns:am3d="http://schemas.microsoft.com/office/drawing/2017/model3d" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:oel="http://schemas.microsoft.com/office/2019/extlst" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:m="http://schemas.openxmlformats.org/officeDocument/2006/math" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:wp14="http://schemas.microsoft.com/office/word/2010/wordprocessingDrawing" xmlns:wp="http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawing" xmlns:w10="urn:schemas-microsoft-com:office:word" xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main" xmlns:w14="http://schemas.microsoft.com/office/word/2010/wordml" xmlns:w15="http://schemas.microsoft.com/office/word/2012/wordml" xmlns:w16cex="http://schemas.microsoft.com/office/word/2018/wordml/cex" xmlns:w16cid="http://schemas.microsoft.com/office/word/2016/wordml/cid" xmlns:w16="http://schemas.microsoft.com/office/word/2018/wordml" xmlns:w16sdtdh="http://schemas.microsoft.com/office/word/2020/wordml/sdtdatahash" xmlns:w16se="http://schemas.microsoft.com/office/word/2015/wordml/symex" xmlns:wpg="http://schemas.microsoft.com/office/word/2010/wordprocessingGroup" xmlns:wpi="http://schemas.microsoft.com/office/word/2010/wordprocessingInk" xmlns:wne="http://schemas.microsoft.com/office/word/2006/wordml" xmlns:wps="http://schemas.microsoft.com/office/word/2010/wordprocessingShape" mc:Ignorable="w14 w15 w16se w16cid w16 w16cex w16sdtdh wp14"><w:body></w:body></w:document>', rm$1 = (r22) => JSON.parse(ba$2.xml2json(r22, null, 2)), nm$1 = (r22, e = tm$1) => r22["word/document.xml"] || rm$1(e), im$1 = (r22) => {
22449
+ const em$1 = '<w:document xmlns:wpc="http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas" xmlns:cx="http://schemas.microsoft.com/office/drawing/2014/chartex" xmlns:cx1="http://schemas.microsoft.com/office/drawing/2015/9/8/chartex" xmlns:cx2="http://schemas.microsoft.com/office/drawing/2015/10/21/chartex" xmlns:cx3="http://schemas.microsoft.com/office/drawing/2016/5/9/chartex" xmlns:cx4="http://schemas.microsoft.com/office/drawing/2016/5/10/chartex" xmlns:cx5="http://schemas.microsoft.com/office/drawing/2016/5/11/chartex" xmlns:cx6="http://schemas.microsoft.com/office/drawing/2016/5/12/chartex" xmlns:cx7="http://schemas.microsoft.com/office/drawing/2016/5/13/chartex" xmlns:cx8="http://schemas.microsoft.com/office/drawing/2016/5/14/chartex" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:aink="http://schemas.microsoft.com/office/drawing/2016/ink" xmlns:am3d="http://schemas.microsoft.com/office/drawing/2017/model3d" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:oel="http://schemas.microsoft.com/office/2019/extlst" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:m="http://schemas.openxmlformats.org/officeDocument/2006/math" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:wp14="http://schemas.microsoft.com/office/word/2010/wordprocessingDrawing" xmlns:wp="http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawing" xmlns:w10="urn:schemas-microsoft-com:office:word" xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main" xmlns:w14="http://schemas.microsoft.com/office/word/2010/wordml" xmlns:w15="http://schemas.microsoft.com/office/word/2012/wordml" xmlns:w16cex="http://schemas.microsoft.com/office/word/2018/wordml/cex" xmlns:w16cid="http://schemas.microsoft.com/office/word/2016/wordml/cid" xmlns:w16="http://schemas.microsoft.com/office/word/2018/wordml" xmlns:w16sdtdh="http://schemas.microsoft.com/office/word/2020/wordml/sdtdatahash" xmlns:w16se="http://schemas.microsoft.com/office/word/2015/wordml/symex" xmlns:wpg="http://schemas.microsoft.com/office/word/2010/wordprocessingGroup" xmlns:wpi="http://schemas.microsoft.com/office/word/2010/wordprocessingInk" xmlns:wne="http://schemas.microsoft.com/office/word/2006/wordml" xmlns:wps="http://schemas.microsoft.com/office/word/2010/wordprocessingShape" mc:Ignorable="w14 w15 w16se w16cid w16 w16cex w16sdtdh wp14"><w:body></w:body></w:document>', tm$1 = (r22) => JSON.parse(ba$2.xml2json(r22, null, 2)), rm$1 = (r22, e = em$1) => r22["word/document.xml"] || tm$1(e), nm$1 = (r22) => {
22470
22450
  const { nodes: e } = r22;
22471
22451
  if (e.length === 0)
22472
22452
  return { nodes: [], consumed: 0 };
22473
22453
  const t = e[0];
22474
22454
  switch (t.name) {
22475
22455
  case "w:tbl":
22476
- return { nodes: [om$1(t, r22)], consumed: 1 };
22456
+ return { nodes: [sm$1(t, r22)], consumed: 1 };
22477
22457
  }
22478
22458
  return { nodes: [], consumed: 0 };
22479
- }, sm$1 = {
22459
+ }, im$1 = {
22480
22460
  handlerName: "tableNodeHandler",
22481
- handler: im$1
22461
+ handler: nm$1
22482
22462
  };
22483
- function om$1(r22, e) {
22463
+ function sm$1(r22, e) {
22484
22464
  const { docx: t, nodeListHandler: n } = e, i3 = r22.elements.find((k) => k.name === "w:tblPr"), o = i3.elements.find((k) => k.name === "w:tblBorders")?.elements || [], { borders: a, rowBorders: u } = pu$2(o), c3 = i3.elements.find((k) => k.name === "w:tblStyle"), h3 = { tableStyleId: c3?.attributes["w:val"] }, g = i3?.elements.find((k) => k.name === "w:tblInd");
22485
22465
  if (g) {
22486
22466
  const { "w:w": k, "w:type": N3 } = g.attributes;
@@ -22505,7 +22485,7 @@ Actual: ` + p3.attribValue
22505
22485
  h3.borders = B3;
22506
22486
  const D = [];
22507
22487
  return w.forEach((k) => {
22508
- const N3 = lm$1(k, r22, R, c3, e);
22488
+ const N3 = um$1(k, r22, R, c3, e);
22509
22489
  N3.content?.length && D.push(N3);
22510
22490
  }), {
22511
22491
  type: "table",
@@ -22513,15 +22493,15 @@ Actual: ` + p3.attribValue
22513
22493
  attrs: h3
22514
22494
  };
22515
22495
  }
22516
- function am$1(r22, e, t, n, i3 = null, s, o, a) {
22517
- const { docx: u, nodeListHandler: c3 } = o, l = r22.elements.find((se2) => se2.name === "w:tcPr"), h3 = l?.elements?.find((se2) => se2.name === "w:tcBorders"), g = um$1(h3, n), E3 = hu$2(t), A3 = l?.elements?.find((se2) => se2.name === "w:tcW");
22496
+ function om$1(r22, e, t, n, i3 = null, s, o, a) {
22497
+ const { docx: u, nodeListHandler: c3 } = o, l = r22.elements.find((se2) => se2.name === "w:tcPr"), h3 = l?.elements?.find((se2) => se2.name === "w:tcBorders"), g = am$1(h3, n), E3 = hu$2(t), A3 = l?.elements?.find((se2) => se2.name === "w:tcW");
22518
22498
  let v = A3 ? be$2(A3.attributes["w:w"]) : null;
22519
22499
  const F = A3?.attributes["w:type"];
22520
22500
  !v && i3 && (v = i3);
22521
22501
  const w = Io$2(r22), { attributes: B3 } = w || {}, D = {
22522
22502
  color: l?.elements?.find((se2) => se2.name === "w:shd")?.attributes["w:fill"]
22523
22503
  }, N3 = l?.elements?.find((se2) => se2.name === "w:gridSpan")?.attributes["w:val"], M = l?.elements?.find((se2) => se2.name === "w:tcMar"), C = l?.elements?.find((se2) => se2.name === "w:vAlign")?.attributes["w:val"] || "top", J3 = {}, oe2 = mu$2(s, u) || {};
22524
- J3.cellMargins = cm$1(M, oe2);
22504
+ J3.cellMargins = lm$1(M, oe2);
22525
22505
  const { fontSize: Z3, fonts: fe2 = {} } = oe2, de2 = fe2.ascii;
22526
22506
  if (v) {
22527
22507
  J3.colwidth = [v], J3.widthUnit = "px";
@@ -22567,7 +22547,7 @@ Actual: ` + p3.attribValue
22567
22547
  return Object.keys(i3) ? (i3.val = "none", i3) : null;
22568
22548
  }
22569
22549
  return null;
22570
- }, um$1 = (r22, e) => {
22550
+ }, am$1 = (r22, e) => {
22571
22551
  if (!r22) return null;
22572
22552
  const t = {}, n = or$2(r22, "bottom", e);
22573
22553
  n && (t.bottom = n);
@@ -22635,7 +22615,7 @@ Actual: ` + p3.attribValue
22635
22615
  rowBorders: t
22636
22616
  };
22637
22617
  }
22638
- function lm$1(r22, e, t, n, i3) {
22618
+ function um$1(r22, e, t, n, i3) {
22639
22619
  const s = {}, a = r22.elements.find((A3) => A3.name === "w:trPr")?.elements?.find((A3) => A3.name === "w:trHeight"), u = a?.attributes["w:val"];
22640
22620
  a?.attributes["w:hRule"];
22641
22621
  const c3 = {};
@@ -22645,12 +22625,12 @@ Actual: ` + p3.attribValue
22645
22625
  type: "tableRow",
22646
22626
  content: h3?.map((A3, v) => {
22647
22627
  const F = h3.length > 1 ? l[v] : null;
22648
- return am$1(A3, r22, e, c3, F, n, i3, v);
22628
+ return om$1(A3, r22, e, c3, F, n, i3, v);
22649
22629
  }) || [],
22650
22630
  attrs: s
22651
22631
  };
22652
22632
  }
22653
- const cm$1 = (r22, e) => {
22633
+ const lm$1 = (r22, e) => {
22654
22634
  const t = r22?.elements?.find((F) => F.name === "w:left"), n = r22?.elements?.find((F) => F.name === "w:right"), i3 = r22?.elements?.find((F) => F.name === "w:top"), s = r22?.elements?.find((F) => F.name === "w:bottom"), o = t?.attributes["w:w"], a = n?.attributes["w:w"], u = i3?.attributes["w:w"], c3 = s?.attributes["w:w"], { cellMargins: l = {} } = e, {
22655
22635
  marginLeft: h3,
22656
22636
  marginRight: g,
@@ -22663,7 +22643,7 @@ Actual: ` + p3.attribValue
22663
22643
  top: be$2(u ?? E3),
22664
22644
  bottom: be$2(c3 ?? A3)
22665
22645
  };
22666
- }, hu$2 = (r22) => r22.elements.find((t) => t.name === "w:tblGrid")?.elements?.flatMap((t) => t.name !== "w:gridCol" ? [] : be$2(t.attributes["w:w"])) || [], fm$1 = (r22) => {
22646
+ }, hu$2 = (r22) => r22.elements.find((t) => t.name === "w:tblGrid")?.elements?.flatMap((t) => t.name !== "w:gridCol" ? [] : be$2(t.attributes["w:w"])) || [], cm$1 = (r22) => {
22667
22647
  const { nodes: e, filename: t } = r22, n = ["w:drawing", "w:p"];
22668
22648
  if (e.length === 0 || !n.includes(e[0].name))
22669
22649
  return { nodes: [], consumed: 0 };
@@ -22687,7 +22667,7 @@ Actual: ` + p3.attribValue
22687
22667
  height: Me$2(o.attributes?.cy)
22688
22668
  }, c3 = r22.elements.find((q3) => q3.name === "a:graphic").elements.find((q3) => q3.name === "a:graphicData"), { uri: l } = c3?.attributes;
22689
22669
  if (l && l === "http://schemas.microsoft.com/office/word/2010/wordprocessingShape")
22690
- return dm$1(t, r22, c3);
22670
+ return fm$1(t, r22, c3);
22691
22671
  const g = c3.elements.find((q3) => q3.name === "pic:pic");
22692
22672
  if (!g || !g.elements) return null;
22693
22673
  const A3 = g.elements.find((q3) => q3.name === "pic:blipFill").elements.find((q3) => q3.name === "a:blip"), v = r22.elements.find((q3) => q3.name === "wp:positionH"), F = v?.elements.find((q3) => q3.name === "wp:posOffset"), w = Me$2(F?.elements[0]?.text), B3 = v?.attributes.relativeFrom, R = v?.elements.find((q3) => q3.name === "wp:align")?.elements[0]?.text, D = r22.elements.find((q3) => q3.name === "wp:positionV"), k = D?.elements.find((q3) => q3.name === "wp:posOffset"), N3 = Me$2(k?.elements[0]?.text), M = D?.attributes.relativeFrom, _3 = D?.elements.find((q3) => q3.name === "wp:align")?.elements[0]?.text, C = r22.elements.find((q3) => q3.name === "wp:simplePos"), J3 = r22.elements.find((q3) => q3.name === "wp:wrapSquare"), oe2 = r22.elements.find((q3) => q3.name === "wp:wrapTopAndBottom"), Z3 = r22.elements.find((q3) => q3.name === "wp:docPr");
@@ -22738,12 +22718,12 @@ Actual: ` + p3.attribValue
22738
22718
  }
22739
22719
  };
22740
22720
  }
22741
- const dm$1 = (r22, e, t) => {
22721
+ const fm$1 = (r22, e, t) => {
22742
22722
  const n = t.elements.find((l) => l.name === "wps:wsp"), s = n.elements.find((l) => l.name === "wps:txbx")?.elements?.find((l) => l.name === "w:txbxContent");
22743
22723
  e.elements.find((l) => l.name === "wp:docPr");
22744
22724
  const o = n.elements.find((l) => l.name === "wps:spPr"), a = o?.elements.find((l) => l.name === "a:prstGeom");
22745
22725
  if (a && a.attributes.prst === "rect")
22746
- return mm$1(r22, o);
22726
+ return dm$1(r22, o);
22747
22727
  if (!s)
22748
22728
  return null;
22749
22729
  const { nodeListHandler: u } = r22;
@@ -22752,7 +22732,7 @@ Actual: ` + p3.attribValue
22752
22732
  node: s.elements[0],
22753
22733
  nodes: s.elements
22754
22734
  })[0];
22755
- }, mm$1 = (r22, e) => {
22735
+ }, dm$1 = (r22, e) => {
22756
22736
  const t = {}, [n] = r22.nodes;
22757
22737
  n?.name === "w:drawing" && (t.drawingContent = n);
22758
22738
  const i3 = e.elements.find((l) => l.name === "a:xfrm"), s = i3.elements.find((l) => l.name === "a:off"), o = i3.elements.find((l) => l.name === "a:ext");
@@ -22769,9 +22749,9 @@ Actual: ` + p3.attribValue
22769
22749
  type: "contentBlock",
22770
22750
  attrs: t
22771
22751
  };
22772
- }, pm$1 = {
22752
+ }, mm$1 = {
22773
22753
  handlerName: "drawingNodeHandler",
22774
- handler: fm$1
22754
+ handler: cm$1
22775
22755
  };
22776
22756
  function Rt(r22, e = [], t = null) {
22777
22757
  const n = [], i3 = /* @__PURE__ */ new Set();
@@ -22796,7 +22776,7 @@ Actual: ` + p3.attribValue
22796
22776
  const { attributes: u = {} } = s, c3 = { type: a.type };
22797
22777
  if (!(u["w:val"] == "0" || u["w:val"] === "none")) {
22798
22778
  if (a.mark && (c3.type = a.mark), Object.keys(u).length) {
22799
- const l = gm$1(a.type, u, t);
22779
+ const l = hm$1(a.type, u, t);
22800
22780
  if (l == null) return;
22801
22781
  c3.attrs = {}, c3.attrs[a.property] = l;
22802
22782
  }
@@ -22805,7 +22785,7 @@ Actual: ` + p3.attribValue
22805
22785
  });
22806
22786
  }), wi$2(n);
22807
22787
  }
22808
- function hm$1(r22, e) {
22788
+ function pm$1(r22, e) {
22809
22789
  const t = r22.elements?.find((o) => o.name === "w:rPrChange");
22810
22790
  if (!t)
22811
22791
  return [];
@@ -22826,25 +22806,25 @@ Actual: ` + p3.attribValue
22826
22806
  });
22827
22807
  }), [...t, { type: "textStyle", attrs: n }];
22828
22808
  }
22829
- function gm$1(r22, e, t) {
22809
+ function hm$1(r22, e, t) {
22830
22810
  r22 === "tabs" && (r22 = "textIndent");
22831
22811
  const n = {
22832
22812
  color: () => `#${e["w:val"]}`,
22833
22813
  fontSize: () => `${e["w:val"] / 2}pt`,
22834
- textIndent: () => ym$1(e),
22835
- fontFamily: () => wm$1(e, t),
22836
- lineHeight: () => bm$1(e),
22814
+ textIndent: () => wm$1(e),
22815
+ fontFamily: () => gm$1(e, t),
22816
+ lineHeight: () => ym$1(e),
22837
22817
  textAlign: () => e["w:val"],
22838
22818
  link: () => e.href,
22839
22819
  underline: () => e["w:val"],
22840
22820
  bold: () => e?.["w:val"] || null,
22841
22821
  italic: () => e?.["w:val"] || null,
22842
- highlight: () => xm$1(e)
22822
+ highlight: () => bm$1(e)
22843
22823
  };
22844
22824
  if (r22 in n || console.debug("❗️❗️ No value mapper for:", r22, "Attributes:", e), r22 in n)
22845
22825
  return n[r22], n[r22]();
22846
22826
  }
22847
- function wm$1(r22, e) {
22827
+ function gm$1(r22, e) {
22848
22828
  const t = r22["w:ascii"], n = r22["w:asciiTheme"];
22849
22829
  if (!e || !n) return t;
22850
22830
  const i3 = e["word/theme/theme1.xml"];
@@ -22852,21 +22832,21 @@ Actual: ` + p3.attribValue
22852
22832
  const { elements: s } = i3, { elements: o } = s[0];
22853
22833
  return o.find((g) => g.name === "a:themeElements").elements.find((g) => g.name === "a:fontScheme").elements.find((g) => g.name === "a:majorFont").elements.find((g) => g.name === "a:latin").attributes.typeface;
22854
22834
  }
22855
- function ym$1(r22) {
22835
+ function wm$1(r22) {
22856
22836
  let e = r22["w:left"];
22857
22837
  return e ? `${qe$3(e)}in` : null;
22858
22838
  }
22859
- function bm$1(r22) {
22839
+ function ym$1(r22) {
22860
22840
  const e = r22["w:line"], t = r22["w:lineRule"];
22861
22841
  return !e || e === "0" ? null : t === "exact" ? `${tu$2(e)}pt` : `${Ii$2(e)}`;
22862
22842
  }
22863
- function xm$1(r22) {
22843
+ function bm$1(r22) {
22864
22844
  const e = r22["w:fill"];
22865
22845
  return e && e !== "auto" ? `#${e}` : Hf$1(r22?.["w:val"]) ? `#${r22["w:val"]}` : jf$1(r22?.["w:val"]) || null;
22866
22846
  }
22867
22847
  function xt$1(r22, e) {
22868
- const t = [], n = [], { attributes: i3 = {}, elements: s = [] } = r22, { nodes: o, paragraphProperties: a = {}, runProperties: u = {} } = Am$1(s);
22869
- return s.find((l) => l.name === "w:r") && (a.elements = a?.elements?.filter((l) => l.name !== "w:rPr")), u && u?.elements?.length && t.push(...Rt(u, n)), a && a.elements?.length && t.push(...Rt(a, n)), t.push(...hm$1(u, t)), a && a.elements?.length && (i3.paragraphProperties = a), t && r22.name === "w:p" && t.forEach((l) => {
22848
+ const t = [], n = [], { attributes: i3 = {}, elements: s = [] } = r22, { nodes: o, paragraphProperties: a = {}, runProperties: u = {} } = xm$1(s);
22849
+ return s.find((l) => l.name === "w:r") && (a.elements = a?.elements?.filter((l) => l.name !== "w:rPr")), u && u?.elements?.length && t.push(...Rt(u, n)), a && a.elements?.length && t.push(...Rt(a, n)), t.push(...pm$1(u, t)), a && a.elements?.length && (i3.paragraphProperties = a), t && r22.name === "w:p" && t.forEach((l) => {
22870
22850
  const h3 = Object.keys(l.attrs ?? {})[0];
22871
22851
  if (h3) {
22872
22852
  const g = l.attrs[h3];
@@ -22874,7 +22854,7 @@ Actual: ` + p3.attribValue
22874
22854
  }
22875
22855
  }), { elements: o, attributes: i3, marks: t, unknownMarks: n };
22876
22856
  }
22877
- function Am$1(r22) {
22857
+ function xm$1(r22) {
22878
22858
  const e = r22.find((s) => s.name === "w:pPr"), t = r22.find((s) => s.name === "w:rPr"), n = r22.find((s) => s.name === "w:sectPr");
22879
22859
  return {
22880
22860
  nodes: r22.filter((s) => s.name !== "w:pPr" && s.name !== "w:rPr" && s.name !== "w:sectPr"),
@@ -22886,11 +22866,11 @@ Actual: ` + p3.attribValue
22886
22866
  function fr$1(r22) {
22887
22867
  return Ot$1.allowedElements[r22.name || r22.type];
22888
22868
  }
22889
- const Dm$1 = (r22) => !!Ot$1.propertyTypes[r22.name || r22.type];
22869
+ const Am$1 = (r22) => !!Ot$1.propertyTypes[r22.name || r22.type];
22890
22870
  function gu$2(r22) {
22891
22871
  return r22.filter((n) => n.name === "w:r").some((n) => n.elements.some((i3) => i3.name === "w:t"));
22892
22872
  }
22893
- const vm$1 = (r22) => {
22873
+ const Dm$1 = (r22) => {
22894
22874
  const { nodes: e, nodeListHandler: t } = r22;
22895
22875
  if (e.length === 0 || !(e[0].name === "w:del" || e[0].name === "w:ins" || e[0].name === "w:sdt"))
22896
22876
  return { nodes: [], consumed: 0 };
@@ -22913,10 +22893,10 @@ Actual: ` + p3.attribValue
22913
22893
  return u.forEach((h3) => {
22914
22894
  h3.marks === void 0 && (h3.marks = []), h3.marks.push({ type: c3, attrs: l });
22915
22895
  }), { nodes: u, consumed: 1 };
22916
- }, Em$1 = {
22896
+ }, vm$1 = {
22917
22897
  handlerName: "trackChangeNodeHandler",
22918
- handler: vm$1
22919
- }, Cm$1 = (r22) => {
22898
+ handler: Dm$1
22899
+ }, Em$1 = (r22) => {
22920
22900
  const { nodes: e, docx: t, nodeListHandler: n } = r22;
22921
22901
  if (e.length === 0 || e[0].name !== "w:hyperlink")
22922
22902
  return { nodes: [], consumed: 0 };
@@ -22935,16 +22915,16 @@ Actual: ` + p3.attribValue
22935
22915
  }
22936
22916
  }
22937
22917
  return { nodes: n.handler({ ...r22, nodes: A3 }), consumed: 1 };
22938
- }, Sm$1 = {
22918
+ }, Cm$1 = {
22939
22919
  handlerName: "hyperlinkNodeHandler",
22940
- handler: Cm$1
22941
- }, Tm$1 = (r22) => {
22920
+ handler: Em$1
22921
+ }, Sm$1 = (r22) => {
22942
22922
  const { nodes: e, nodeListHandler: t, parentStyleId: n, docx: i3 } = r22;
22943
22923
  if (e.length === 0 || e[0].name !== "w:r")
22944
22924
  return { nodes: [], consumed: 0 };
22945
22925
  const s = e[0], o = { ...r22, nodes: s.elements };
22946
22926
  let a = t.handler(o)?.filter((l) => l) || [];
22947
- const u = s.elements?.some((l) => l.name === "w:rPr"), c3 = Fm$1(i3, n);
22927
+ const u = s.elements?.some((l) => l.name === "w:rPr"), c3 = Tm$1(i3, n);
22948
22928
  if (u) {
22949
22929
  const { marks: l = [], attributes: h3 = {} } = xt$1(s), g = l.find((v) => v.type === "textStyle"), E3 = g && Object.keys(g.attrs).length > 0;
22950
22930
  c3.marks && !E3 && l.push(...c3.marks), s.marks && l.push(...s.marks);
@@ -22955,16 +22935,16 @@ Actual: ` + p3.attribValue
22955
22935
  });
22956
22936
  } else c3.marks && (a = a.map((l) => ({ ...l, marks: wi$2(c3.marks) })));
22957
22937
  return { nodes: a, consumed: 1 };
22958
- }, Fm$1 = (r22, e) => {
22938
+ }, Tm$1 = (r22, e) => {
22959
22939
  const t = r22?.["word/styles.xml"];
22960
22940
  if (!t)
22961
22941
  return {};
22962
22942
  const i3 = t.elements[0].elements.filter((s) => s.name === "w:style").find((s) => s.attributes["w:styleId"] === e) || {};
22963
22943
  return i3 ? xt$1(i3) : {};
22964
- }, Bm$1 = {
22944
+ }, Fm$1 = {
22965
22945
  handlerName: "runNodeHandler",
22966
- handler: Tm$1
22967
- }, km$1 = (r22) => {
22946
+ handler: Sm$1
22947
+ }, Bm$1 = (r22) => {
22968
22948
  const { nodes: e, insideTrackChange: t } = r22;
22969
22949
  if (e.length === 0 || !(e[0].name === "w:t" || t && e[0].name === "w:delText"))
22970
22950
  return { nodes: [], consumed: 0 };
@@ -22985,29 +22965,29 @@ Actual: ` + p3.attribValue
22985
22965
  ],
22986
22966
  consumed: 1
22987
22967
  };
22988
- }, Nm$1 = {
22968
+ }, km$1 = {
22989
22969
  handlerName: "textNodeHandler",
22990
- handler: km$1
22970
+ handler: Bm$1
22991
22971
  }, wu$2 = (r22) => {
22992
22972
  if (!r22 || !Array.isArray(r22))
22993
22973
  return r22;
22994
22974
  let e = [], t = null;
22995
22975
  for (let n of r22)
22996
- n.type === "text" ? t && Im$1(t, n) ? t = {
22976
+ n.type === "text" ? t && Nm$1(t, n) ? t = {
22997
22977
  ...t,
22998
22978
  text: t.text += n.text
22999
22979
  } : (t && e.push(t), t = { ...n }) : (t && (e.push(t), t = null), e.push(n));
23000
22980
  return t && e.push(t), e;
23001
- }, Im$1 = (r22, e) => {
22981
+ }, Nm$1 = (r22, e) => {
23002
22982
  if (!r22 || !e) return false;
23003
22983
  let t = r22.marks ?? [], n = e.marks ?? [];
23004
22984
  if (t.length !== n.length)
23005
22985
  return false;
23006
22986
  for (let i3 = 0; i3 < t.length; i3++)
23007
- if (t[i3].attrs || (t[i3].attrs = {}), n[i3].attrs || (n[i3].attrs = {}), t[i3].type !== n[i3].type || Object.keys(t[i3].attrs).length !== Object.keys(n[i3].attrs).length || !Rm$1(t[i3].attrs, n[i3].attrs))
22987
+ if (t[i3].attrs || (t[i3].attrs = {}), n[i3].attrs || (n[i3].attrs = {}), t[i3].type !== n[i3].type || Object.keys(t[i3].attrs).length !== Object.keys(n[i3].attrs).length || !Im$1(t[i3].attrs, n[i3].attrs))
23008
22988
  return false;
23009
22989
  return true;
23010
- }, Rm$1 = (r22 = {}, e = {}) => Pf$1(r22, e), Pm$1 = (r22) => {
22990
+ }, Im$1 = (r22 = {}, e = {}) => Pf$1(r22, e), Rm$1 = (r22) => {
23011
22991
  const { nodes: e, lists: t, docx: n } = r22;
23012
22992
  if (e.length === 0 || e[0].name !== "w:p")
23013
22993
  return { nodes: [], consumed: 0 };
@@ -23026,9 +23006,9 @@ Actual: ` + p3.attribValue
23026
23006
  };
23027
23007
  } else
23028
23008
  return { nodes: [], consumed: 0, lists: t };
23029
- }, Om$1 = {
23009
+ }, Pm$1 = {
23030
23010
  handlerName: "listHandler",
23031
- handler: Pm$1
23011
+ handler: Rm$1
23032
23012
  };
23033
23013
  function yu$2({
23034
23014
  listItems: r22,
@@ -23067,9 +23047,9 @@ Actual: ` + p3.attribValue
23067
23047
  lvlText: re2,
23068
23048
  lvlJc: ie2,
23069
23049
  numId: L3
23070
- } = Mm$1(N3, n, u);
23050
+ } = qm$1(N3, n, u);
23071
23051
  E3 = se2;
23072
- const V3 = parseInt(ne2), q3 = i3 === V3 && L3 === s, K3 = qm$1({
23052
+ const V3 = parseInt(ne2), q3 = i3 === V3 && L3 === s, K3 = _m$1({
23073
23053
  firstListId: L3,
23074
23054
  secondListId: s,
23075
23055
  level: V3,
@@ -23193,7 +23173,7 @@ Actual: ` + p3.attribValue
23193
23173
  marks: t
23194
23174
  };
23195
23175
  }
23196
- const Lm$1 = [
23176
+ const Om$1 = [
23197
23177
  "decimal",
23198
23178
  // eg: 1, 2, 3, 4, 5, ...
23199
23179
  "decimalZero",
@@ -23218,7 +23198,7 @@ Actual: ` + p3.attribValue
23218
23198
  // eg: (0, 1, 2, ..., 9, 10, 11, 12, ..., 19, 1A, 1B, 1C, ..., 1Z, 20, 21, ..., 2Z)
23219
23199
  "none"
23220
23200
  // No bullet
23221
- ], _m$1 = [
23201
+ ], Lm$1 = [
23222
23202
  "bullet",
23223
23203
  // A standard bullet point (•)
23224
23204
  "square",
@@ -23227,7 +23207,7 @@ Actual: ` + p3.attribValue
23227
23207
  // Circle bullets (◦)
23228
23208
  "disc"
23229
23209
  // Disc bullets (●)
23230
- ], qm$1 = ({ firstListId: r22, secondListId: e, level: t, pStyleId: n, docx: i3 }) => {
23210
+ ], _m$1 = ({ firstListId: r22, secondListId: e, level: t, pStyleId: n, docx: i3 }) => {
23231
23211
  const { numFmt: s, lvlText: o, lvlJc: a } = Ar$2(r22, t, n, i3), {
23232
23212
  numFmt: u,
23233
23213
  lvlText: c3,
@@ -23257,7 +23237,7 @@ Actual: ` + p3.attribValue
23257
23237
  }
23258
23238
  const a = o.elements, u = a.filter((N3) => N3.name === "w:abstractNum"), h3 = a.filter((N3) => N3.name === "w:num").find((N3) => N3.attributes["w:numId"] === r22)?.elements[0].attributes["w:val"], g = u?.find(
23259
23239
  (N3) => N3.attributes["w:abstractNumId"] === h3
23260
- ), E3 = Um$1(g, e), v = g?.elements?.find((N3) => N3.name === "w:numStyleLink")?.attributes["w:val"];
23240
+ ), E3 = Mm$1(g, e), v = g?.elements?.find((N3) => N3.name === "w:numStyleLink")?.attributes["w:val"];
23261
23241
  if (v) {
23262
23242
  const N3 = Oo$2(v, n);
23263
23243
  return Ar$2(N3.numId, e, null, n);
@@ -23265,7 +23245,7 @@ Actual: ` + p3.attribValue
23265
23245
  const F = E3?.elements?.find((N3) => N3.name === "w:start")?.attributes["w:val"], w = E3?.elements?.find((N3) => N3.name === "w:numFmt")?.attributes["w:val"], B3 = E3?.elements?.find((N3) => N3.name === "w:lvlText").attributes["w:val"], R = E3?.elements?.find((N3) => N3.name === "w:lvlJc").attributes["w:val"], D = E3?.elements?.find((N3) => N3.name === "w:pPr"), k = E3?.elements?.find((N3) => N3.name === "w:rPr");
23266
23246
  return { start: F, numFmt: w, lvlText: B3, lvlJc: R, pPr: D, rPr: k };
23267
23247
  };
23268
- function Mm$1(r22, e, t) {
23248
+ function qm$1(r22, e, t) {
23269
23249
  if (!r22) return;
23270
23250
  const { attributes: n = {} } = r22, { paragraphProperties: i3 = {} } = n, { elements: s = [] } = i3, u = r22.elements.find((C) => C.name === "w:pPr")?.elements?.find((C) => C.name === "w:pStyle")?.attributes["w:val"], c3 = Nr$1({ node: r22, styleId: u, docx: t });
23271
23251
  if (!c3) return {};
@@ -23278,17 +23258,17 @@ Actual: ` + p3.attribValue
23278
23258
  rPr: k
23279
23259
  } = Ar$2(h3, e, v, t);
23280
23260
  let N3, M;
23281
- D && (N3 = jm$1(D)), k && (M = Hm$1(k));
23261
+ D && (N3 = Um$1(D)), k && (M = jm$1(k));
23282
23262
  let _3;
23283
- if (_m$1.includes(w?.toLowerCase())) _3 = "bulletList";
23284
- else if (Lm$1.includes(w)) _3 = "orderedList";
23263
+ if (Lm$1.includes(w?.toLowerCase())) _3 = "bulletList";
23264
+ else if (Om$1.includes(w)) _3 = "orderedList";
23285
23265
  else return {};
23286
23266
  return { listType: _3, listOrderingType: w, ilvl: E3, numId: h3, listrPrs: M, listpPrs: N3, start: F, lvlText: B3, lvlJc: R };
23287
23267
  }
23288
- function Um$1(r22, e) {
23268
+ function Mm$1(r22, e) {
23289
23269
  return r22?.elements?.find((t) => Number(t.attributes["w:ilvl"]) === e);
23290
23270
  }
23291
- function jm$1(r22) {
23271
+ function Um$1(r22) {
23292
23272
  const { elements: e } = r22, t = ["w:ind", "w:jc", "w:tabs"], n = {};
23293
23273
  return e && e.forEach((i3) => {
23294
23274
  t.includes(i3.name);
@@ -23298,7 +23278,7 @@ Actual: ` + p3.attribValue
23298
23278
  });
23299
23279
  }), n;
23300
23280
  }
23301
- function Hm$1(r22) {
23281
+ function jm$1(r22) {
23302
23282
  const { elements: e } = r22, t = [
23303
23283
  "w:rFonts",
23304
23284
  "w:b",
@@ -23355,7 +23335,7 @@ Actual: ` + p3.attribValue
23355
23335
  }
23356
23336
  let v;
23357
23337
  if (g && (v = g.attributes["w:val"], o.attrs.styleId = v), t) {
23358
- const D = Vm$1(s, t, v);
23338
+ const D = Hm$1(s, t, v);
23359
23339
  o.attrs.indent || (o.attrs.indent = {}), (D.left || D.left === 0) && (o.attrs.indent.left = D.left), (D.right || D.right === 0) && (o.attrs.indent.right = D.right), (D.firstLine || D.firstLine === 0) && (o.attrs.indent.firstLine = D.firstLine), (D.hanging || D.hanging === 0) && (o.attrs.indent.hanging = D.hanging), (D.textIndent || D.textIndent === 0) && (o.attrs.textIndent = `${D.textIndent}in`);
23360
23340
  }
23361
23341
  const F = h3?.elements?.find((D) => D.name === "w:jc");
@@ -23379,7 +23359,7 @@ Actual: ` + p3.attribValue
23379
23359
  });
23380
23360
  const R = h3?.elements?.find((D) => D.name === "w:sectPr");
23381
23361
  return R && (o.attrs.paragraphProperties || (o.attrs.paragraphProperties = {}), o.attrs.paragraphProperties.sectPr = R, o.attrs.pageBreakSource = "sectPr"), { nodes: o ? [o] : [], consumed: 1 };
23382
- }, Vm$1 = (r22, e, t = "") => {
23362
+ }, Hm$1 = (r22, e, t = "") => {
23383
23363
  const n = {
23384
23364
  left: 0,
23385
23365
  right: 0,
@@ -23422,11 +23402,11 @@ Actual: ` + p3.attribValue
23422
23402
  indent: k || R || D,
23423
23403
  justify: B3
23424
23404
  };
23425
- }, zm$1 = {
23405
+ }, Vm$1 = {
23426
23406
  handlerName: "paragraphNodeHandler",
23427
23407
  handler: xu$2
23428
23408
  };
23429
- function Gm$1(r22, e) {
23409
+ function zm$1(r22, e) {
23430
23410
  const t = { lineSpaceBefore: null, lineSpaceAfter: null };
23431
23411
  if (!r22) return t;
23432
23412
  const n = e["word/styles.xml"];
@@ -23490,14 +23470,14 @@ Actual: ` + p3.attribValue
23490
23470
  continue;
23491
23471
  }
23492
23472
  if (o === "end" && n) {
23493
- t.push(i3), e.push(...Wm$1(t)), t = [], n = false;
23473
+ t.push(i3), e.push(...Gm$1(t)), t = [], n = false;
23494
23474
  continue;
23495
23475
  }
23496
23476
  n ? t.push(i3) : e.push(i3);
23497
23477
  }
23498
23478
  return t.length && e.push(...t), e;
23499
23479
  }
23500
- const Wm$1 = (r22 = []) => {
23480
+ const Gm$1 = (r22 = []) => {
23501
23481
  let e = [], t = false, n = false;
23502
23482
  const i3 = r22.findIndex(
23503
23483
  (h3) => h3.elements?.some((g) => g.name === "w:fldChar" && g.attributes["w:fldCharType"] === "separate")
@@ -23534,7 +23514,7 @@ Actual: ` + p3.attribValue
23534
23514
  });
23535
23515
  }
23536
23516
  return e;
23537
- }, Jm$1 = (r22) => nodeListHandler.handler({ ...r22, nodes: node.elements }), $m$1 = (r22) => {
23517
+ }, Wm$1 = (r22) => nodeListHandler.handler({ ...r22, nodes: node.elements }), Jm$1 = (r22) => {
23538
23518
  const { nodes: e } = r22;
23539
23519
  if (e.length === 0 || e[0].name !== "w:sdt")
23540
23520
  return { nodes: [], consumed: 0 };
@@ -23549,14 +23529,14 @@ Actual: ` + p3.attribValue
23549
23529
  consumed: 1
23550
23530
  };
23551
23531
  }, Lo$2 = {
23552
- "Table of Contents": Jm$1
23553
- }, Km$1 = (r22) => {
23532
+ "Table of Contents": Wm$1
23533
+ }, $m$1 = (r22) => {
23554
23534
  const { nodes: e, docx: t, nodeListHandler: n, insideTrackChange: i3 } = r22;
23555
23535
  if (e.length === 0 || e[0].name !== "w:sdt")
23556
23536
  return { nodes: [], consumed: 0 };
23557
23537
  const s = e[0], o = s.elements.find((_3) => _3.name === "w:sdtPr"), a = s.elements.find((_3) => _3.name === "w:sdtContent"), u = o?.elements.find((_3) => _3.name === "w:fieldTypeShort")?.attributes["w:val"], { attrs: c3, marks: l } = Eu$2(a);
23558
23538
  if (o?.elements.find((_3) => _3.name === "w:docPartObj"))
23559
- return $m$1({ nodes: e, docx: t, nodeListHandler: n, insideTrackChange: i3 });
23539
+ return Jm$1({ nodes: e, docx: t, nodeListHandler: n, insideTrackChange: i3 });
23560
23540
  const g = o?.elements.find((_3) => _3.name === "w:alias"), E3 = o?.elements.find((_3) => _3.name === "w:tag"), A3 = o?.elements.find((_3) => _3.name === "w:fieldType")?.attributes["w:val"], v = o?.elements.find((_3) => _3.name === "w:fieldColor")?.attributes["w:val"], F = o?.elements.find((_3) => _3.name === "w:fieldMultipleImage")?.attributes["w:val"], w = o?.elements.find((_3) => _3.name === "w:fieldFontFamily")?.attributes["w:val"], B3 = o?.elements.find((_3) => _3.name === "w:fieldFontSize")?.attributes["w:val"], R = o?.elements.find((_3) => _3.name === "w:fieldTextColor")?.attributes["w:val"], D = o?.elements.find((_3) => _3.name === "w:fieldTextHighlight")?.attributes["w:val"], k = {
23561
23541
  type: u,
23562
23542
  fieldId: E3?.attributes["w:val"],
@@ -23606,10 +23586,10 @@ Actual: ` + p3.attribValue
23606
23586
  attrs: u,
23607
23587
  marks: o
23608
23588
  };
23609
- }, Xm$1 = {
23589
+ }, Km$1 = {
23610
23590
  handlerName: "annotationNodeHandler",
23611
- handler: Km$1
23612
- }, Ym$1 = (r22) => {
23591
+ handler: $m$1
23592
+ }, Xm$1 = (r22) => {
23613
23593
  const { nodes: e, nodeListHandler: t } = r22;
23614
23594
  if (e.length === 0 || e[0].name !== "w:sdt")
23615
23595
  return { nodes: [], consumed: 0 };
@@ -23625,17 +23605,17 @@ Actual: ` + p3.attribValue
23625
23605
  }],
23626
23606
  consumed: 1
23627
23607
  };
23628
- }, Zm$1 = {
23608
+ }, Ym$1 = {
23629
23609
  handlerName: "sdtNodeHandler",
23630
- handler: Ym$1
23631
- }, Qm$1 = (r22) => {
23610
+ handler: Xm$1
23611
+ }, Zm$1 = (r22) => {
23632
23612
  const { nodes: e, docx: t, nodeListHandler: n } = r22;
23633
23613
  if (!e || e.length === 0)
23634
23614
  return { nodes: [], consumed: 0 };
23635
23615
  const i3 = e[0], { name: s } = i3, { attributes: o, elements: a, marks: u = [] } = xt$1(i3);
23636
23616
  if (s === "w:sdt")
23637
23617
  return { nodes: [], consumed: 0 };
23638
- if (Dm$1(i3))
23618
+ if (Am$1(i3))
23639
23619
  return {
23640
23620
  nodes: [{
23641
23621
  type: fr$1(i3),
@@ -23655,7 +23635,7 @@ Actual: ` + p3.attribValue
23655
23635
  consumed: 0,
23656
23636
  unhandled: true
23657
23637
  };
23658
- const c3 = [], l = ep(i3);
23638
+ const c3 = [], l = Qm$1(i3);
23659
23639
  if (a && a.length) {
23660
23640
  const g = a.map((v) => (v.marks || (v.marks = []), v.marks.push(...u), v)), E3 = { ...r22, nodes: g, parentStyleId: l }, A3 = n.handler(E3);
23661
23641
  c3.push(...A3);
@@ -23666,13 +23646,13 @@ Actual: ` + p3.attribValue
23666
23646
  attrs: { ...o },
23667
23647
  marks: []
23668
23648
  }], consumed: 1 };
23669
- }, ep = (r22) => {
23649
+ }, Qm$1 = (r22) => {
23670
23650
  const t = r22.elements?.find((n) => n.name === "w:pPr")?.elements?.find((n) => n.name === "w:pStyle");
23671
23651
  return t ? t.attributes["w:val"] : null;
23672
- }, tp = {
23652
+ }, ep = {
23673
23653
  handlerName: "standardNodeHandler",
23674
- handler: Qm$1
23675
- }, rp = (r22) => {
23654
+ handler: Zm$1
23655
+ }, tp = (r22) => {
23676
23656
  const { nodes: e } = r22;
23677
23657
  return e.length === 0 || e[0].name !== "w:br" ? { nodes: [], consumed: 0 } : {
23678
23658
  nodes: [{
@@ -23680,10 +23660,10 @@ Actual: ` + p3.attribValue
23680
23660
  }],
23681
23661
  consumed: 1
23682
23662
  };
23683
- }, np = {
23663
+ }, rp = {
23684
23664
  handlerName: "lineBreakNodeHandler",
23685
- handler: rp
23686
- }, ip = (r22) => {
23665
+ handler: tp
23666
+ }, np = (r22) => {
23687
23667
  const { nodes: e, nodeListHandler: t, editor: n } = r22;
23688
23668
  if (e.length === 0 || e[0].name !== "w:bookmarkStart")
23689
23669
  return { nodes: [], consumed: 0 };
@@ -23712,10 +23692,10 @@ Actual: ` + p3.attribValue
23712
23692
  }
23713
23693
  const c3 = { ...r22, nodes: [i3] }, l = s(c3);
23714
23694
  return l.nodes.length === 1 && (l.nodes[0].attrs.name = i3.attributes["w:name"], l.nodes[0].attrs.id = i3.attributes["w:id"]), l;
23715
- }, sp = {
23695
+ }, ip = {
23716
23696
  handlerName: "bookmarkNodeHandler",
23717
- handler: ip
23718
- }, op = (r22) => {
23697
+ handler: np
23698
+ }, sp = (r22) => {
23719
23699
  const e = { nodes: [], consumed: 0 }, { nodes: t, nodeListHandler: n, parentStyleId: i3, docx: s } = r22;
23720
23700
  if (t.length === 0 || t[0].name !== "w:p")
23721
23701
  return e;
@@ -23734,26 +23714,26 @@ Actual: ` + p3.attribValue
23734
23714
  ...r22,
23735
23715
  nodes: g
23736
23716
  }), consumed: 1 };
23737
- }, ap$1 = {
23717
+ }, op = {
23738
23718
  handlerName: "alternateChoiceHandler",
23739
- handler: op
23740
- }, up$1 = (r22) => {
23719
+ handler: sp
23720
+ }, ap$1 = (r22) => {
23741
23721
  const { nodes: e } = r22;
23742
23722
  return e.length === 0 || e[0].name !== "sd:autoPageNumber" ? { nodes: [], consumed: 0 } : { nodes: [{
23743
23723
  type: "page-number"
23744
23724
  }], consumed: 1 };
23745
- }, lp$1 = {
23725
+ }, up$1 = {
23746
23726
  handlerName: "autoPageNumberHandler",
23747
- handler: up$1
23748
- }, cp$1 = (r22) => {
23727
+ handler: ap$1
23728
+ }, lp$1 = (r22) => {
23749
23729
  const { nodes: e } = r22;
23750
23730
  return e.length === 0 || e[0].name !== "sd:totalPageNumber" ? { nodes: [], consumed: 0 } : { nodes: [{
23751
23731
  type: "total-page-number"
23752
23732
  }], consumed: 1 };
23753
- }, fp$1 = {
23733
+ }, cp$1 = {
23754
23734
  handlerName: "autoTotalPageCountEntity",
23755
- handler: cp$1
23756
- }, dp$1 = (r22) => {
23735
+ handler: lp$1
23736
+ }, fp$1 = (r22) => {
23757
23737
  const { nodes: e, docx: t, parentStyleId: n } = r22;
23758
23738
  if (e.length === 0 || e[0].name !== "w:tab")
23759
23739
  return { nodes: [], consumed: 0 };
@@ -23770,10 +23750,10 @@ Actual: ` + p3.attribValue
23770
23750
  },
23771
23751
  content: []
23772
23752
  }], consumed: 1 };
23773
- }, mp$1 = {
23753
+ }, dp$1 = {
23774
23754
  handlerName: "tabNodeHandler",
23775
- handler: dp$1
23776
- }, pp$1 = (r22) => {
23755
+ handler: fp$1
23756
+ }, mp$1 = (r22) => {
23777
23757
  const { nodes: e } = r22;
23778
23758
  if (!e.length || e[0].name !== "w:p")
23779
23759
  return { nodes: [], consumed: 0 };
@@ -23786,14 +23766,14 @@ Actual: ` + p3.attribValue
23786
23766
  if (!o && !a)
23787
23767
  return { nodes: [], consumed: 0 };
23788
23768
  let u = null;
23789
- return a && !o ? u = null : o.elements?.find((h3) => h3.name === "v:textbox") && (u = hp$1({
23769
+ return a && !o ? u = null : o.elements?.find((h3) => h3.name === "v:textbox") && (u = pp$1({
23790
23770
  pict: i3,
23791
23771
  pNode: t,
23792
23772
  shape: o,
23793
23773
  params: r22
23794
23774
  })), { nodes: u ? [u] : [], consumed: 1 };
23795
23775
  };
23796
- function hp$1({
23776
+ function pp$1({
23797
23777
  pict: r22,
23798
23778
  pNode: e,
23799
23779
  shape: t,
@@ -23801,7 +23781,7 @@ Actual: ` + p3.attribValue
23801
23781
  }) {
23802
23782
  const i3 = {}, s = {}, o = t.attributes || {};
23803
23783
  i3.attributes = o, o.fillcolor && (i3.fillcolor = o.fillcolor);
23804
- const a = gp$1(o.style), u = wp$1(a);
23784
+ const a = hp$1(o.style), u = gp$1(a);
23805
23785
  u && (i3.style = u);
23806
23786
  const c3 = t.elements?.find((w) => w.name === "v:textbox"), l = t.elements?.find((w) => w.name === "w10:wrap");
23807
23787
  l?.attributes && (i3.wrapAttributes = l.attributes), c3?.attributes && (s.attributes = c3.attributes);
@@ -23820,13 +23800,13 @@ Actual: ` + p3.attribValue
23820
23800
  }]
23821
23801
  };
23822
23802
  }
23823
- function gp$1(r22) {
23803
+ function hp$1(r22) {
23824
23804
  return r22 ? r22.split(";").filter((e) => !!e.trim()).reduce((e, t) => {
23825
23805
  const [n, i3] = t.split(":").map((s) => s.trim());
23826
23806
  return n && i3 && (e[n] = i3), e;
23827
23807
  }, {}) : {};
23828
23808
  }
23829
- function wp$1(r22) {
23809
+ function gp$1(r22) {
23830
23810
  const e = [
23831
23811
  "width",
23832
23812
  "height"
@@ -23844,11 +23824,11 @@ Actual: ` + p3.attribValue
23844
23824
  e.includes(n) && (t += `${n}: ${i3};`);
23845
23825
  return t;
23846
23826
  }
23847
- const yp$1 = {
23827
+ const wp$1 = {
23848
23828
  handlerName: "handlePictNode",
23849
- handler: pp$1
23829
+ handler: mp$1
23850
23830
  };
23851
- function bp$1({ docx: r22 }) {
23831
+ function yp$1({ docx: r22 }) {
23852
23832
  const e = Jt$2(), t = r22["word/comments.xml"];
23853
23833
  if (!t) return;
23854
23834
  const { elements: n } = t;
@@ -23874,16 +23854,16 @@ Actual: ` + p3.attribValue
23874
23854
  trackedDeletedText: B3
23875
23855
  };
23876
23856
  });
23877
- return xp$1({ docx: r22, comments: s });
23857
+ return bp$1({ docx: r22, comments: s });
23878
23858
  }
23879
- const xp$1 = ({ docx: r22, comments: e }) => {
23859
+ const bp$1 = ({ docx: r22, comments: e }) => {
23880
23860
  const t = r22["word/commentsExtended.xml"];
23881
23861
  if (!t) return [];
23882
23862
  const { elements: n } = t, { elements: i3 } = n[0], s = i3.filter((o) => o.name === "w15:commentEx");
23883
23863
  return e.map((o) => {
23884
23864
  const a = s.find((g) => g.attributes["w15:paraId"] === o.paraId);
23885
23865
  if (!a) return { ...o };
23886
- const { isDone: u, paraIdParent: c3 } = Ap$1(a);
23866
+ const { isDone: u, paraIdParent: c3 } = xp$1(a);
23887
23867
  let l;
23888
23868
  return c3 && (l = e.find((g) => g.paraId === c3)), {
23889
23869
  ...o,
@@ -23891,11 +23871,11 @@ Actual: ` + p3.attribValue
23891
23871
  parentCommentId: l?.commentId
23892
23872
  };
23893
23873
  });
23894
- }, Ap$1 = (r22) => {
23874
+ }, xp$1 = (r22) => {
23895
23875
  const { attributes: e } = r22, t = e["w15:paraId"], n = e["w15:done"] === "1", i3 = e["w15:paraIdParent"];
23896
23876
  return { paraId: t, isDone: n, paraIdParent: i3 };
23897
- }, Dp$1 = (r22, e, t) => {
23898
- const n = Ue$2(nm$1(r22));
23877
+ }, Ap$1 = (r22, e, t) => {
23878
+ const n = Ue$2(rm$1(r22));
23899
23879
  if (!n) return null;
23900
23880
  if (e?.telemetry) {
23901
23881
  const o = Object.keys(r22).map((a) => {
@@ -23920,7 +23900,7 @@ Actual: ` + p3.attribValue
23920
23900
  }
23921
23901
  const i3 = Jt$2(), s = n.elements[0].elements.find((o) => o.name === "w:body");
23922
23902
  if (s) {
23923
- const o = s, a = ["w:sectPr"], u = o.elements?.filter((E3) => !a.includes(E3.name)) ?? [], c3 = bp$1({ docx: r22 }), l = {}, g = {
23903
+ const o = s, a = ["w:sectPr"], u = o.elements?.filter((E3) => !a.includes(E3.name)) ?? [], c3 = yp$1({ docx: r22 }), l = {}, g = {
23924
23904
  type: "doc",
23925
23905
  content: i3.handler({
23926
23906
  nodes: u,
@@ -23943,40 +23923,40 @@ Actual: ` + p3.attribValue
23943
23923
  ), {
23944
23924
  pmDoc: g,
23945
23925
  savedTagsToRestore: o,
23946
- pageStyles: Ep$1(o, r22, e, t),
23926
+ pageStyles: vp$1(o, r22, e, t),
23947
23927
  comments: c3,
23948
- linkedStyles: Cp$1(r22),
23949
- numbering: Fp$1(r22)
23928
+ linkedStyles: Ep$1(r22),
23929
+ numbering: Tp$1(r22)
23950
23930
  };
23951
23931
  }
23952
23932
  return null;
23953
23933
  }, Jt$2 = () => {
23954
23934
  const r22 = [
23955
- ap$1,
23956
- Bm$1,
23957
- yp$1,
23958
- zm$1,
23959
- Om$1,
23960
- Nm$1,
23961
- np,
23962
- Xm$1,
23963
- Zm$1,
23964
- sp,
23965
- Sm$1,
23966
- pm$1,
23967
- Em$1,
23968
- sm$1,
23969
- mp$1,
23970
- lp$1,
23971
- fp$1,
23972
- tp
23935
+ op,
23936
+ Fm$1,
23937
+ wp$1,
23938
+ Vm$1,
23939
+ Pm$1,
23940
+ km$1,
23941
+ rp,
23942
+ Km$1,
23943
+ Ym$1,
23944
+ ip,
23945
+ Cm$1,
23946
+ mm$1,
23947
+ vm$1,
23948
+ im$1,
23949
+ dp$1,
23950
+ up$1,
23951
+ cp$1,
23952
+ ep
23973
23953
  //this should be the last one, bcs this parses everything!!!
23974
23954
  ];
23975
23955
  return {
23976
- handler: vp$1(r22),
23956
+ handler: Dp$1(r22),
23977
23957
  handlerEntities: r22
23978
23958
  };
23979
- }, vp$1 = (r22) => {
23959
+ }, Dp$1 = (r22) => {
23980
23960
  const e = (n, i3, s, o) => !n || i3 < 0 || i3 >= n.length ? {
23981
23961
  elementIndex: i3,
23982
23962
  error: "index_out_of_bounds",
@@ -24061,7 +24041,7 @@ Actual: ` + p3.attribValue
24061
24041
  };
24062
24042
  return t;
24063
24043
  };
24064
- function Ep$1(r22, e, t, n) {
24044
+ function vp$1(r22, e, t, n) {
24065
24045
  const i3 = r22.elements?.find((o) => o.name === "w:sectPr"), s = {};
24066
24046
  return i3?.elements?.forEach((o) => {
24067
24047
  const { name: a, attributes: u } = o;
@@ -24099,9 +24079,9 @@ Actual: ` + p3.attribValue
24099
24079
  case "w:titlePg":
24100
24080
  t.headerIds.titlePg = true;
24101
24081
  }
24102
- }), Tp$1(e, t, n), s.alternateHeaders = Bp$1(e), s;
24082
+ }), Sp$1(e, t, n), s.alternateHeaders = Fp$1(e), s;
24103
24083
  }
24104
- function Cp$1(r22) {
24084
+ function Ep$1(r22) {
24105
24085
  const e = r22["word/styles.xml"];
24106
24086
  if (!e) return [];
24107
24087
  const { elements: t } = e.elements[0], n = t.filter((o) => o.name === "w:style");
@@ -24111,7 +24091,7 @@ Actual: ` + p3.attribValue
24111
24091
  });
24112
24092
  const s = [];
24113
24093
  return n.forEach((o) => {
24114
- const a = o.attributes["w:styleId"], u = Gm$1(a, r22), c3 = {
24094
+ const a = o.attributes["w:styleId"], u = zm$1(a, r22), c3 = {
24115
24095
  id: o.attributes["w:styleId"],
24116
24096
  type: o.attributes["w:type"],
24117
24097
  definition: u,
@@ -24120,7 +24100,7 @@ Actual: ` + p3.attribValue
24120
24100
  s.push(c3);
24121
24101
  }), s;
24122
24102
  }
24123
- function Sp$1(r22) {
24103
+ function Cp$1(r22) {
24124
24104
  if (!r22) return null;
24125
24105
  const e = Ue$2(r22), { elements: t } = e.elements[0];
24126
24106
  return Object.keys(Co$3).forEach((n) => {
@@ -24130,7 +24110,7 @@ Actual: ` + p3.attribValue
24130
24110
  }
24131
24111
  }), e;
24132
24112
  }
24133
- const Tp$1 = (r22, e, t) => {
24113
+ const Sp$1 = (r22, e, t) => {
24134
24114
  const i3 = r22["word/_rels/document.xml.rels"].elements.find((g) => g.name === "Relationships"), { elements: s } = i3, o = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/header", a = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/footer", u = s.filter((g) => g.attributes.Type === o), c3 = s.filter((g) => g.attributes.Type === a), h3 = (Cu$2(r22["word/document.xml"]) || []).flatMap((g) => g.elements);
24135
24115
  u.forEach((g) => {
24136
24116
  const { rId: E3, referenceFile: A3, currentFileName: v } = _o$3(g, r22);
@@ -24168,7 +24148,7 @@ Actual: ` + p3.attribValue
24168
24148
  currentFileName: n
24169
24149
  };
24170
24150
  };
24171
- function Fp$1(r22) {
24151
+ function Tp$1(r22) {
24172
24152
  let e = r22["word/numbering.xml"];
24173
24153
  (!e || !e.elements?.length || !e.elements[0].elements?.length) && (e = nu$2);
24174
24154
  const t = e.elements[0].elements, n = t.filter((a) => a.name === "w:abstractNum"), i3 = t.filter((a) => a.name === "w:num"), s = {};
@@ -24185,12 +24165,12 @@ Actual: ` + p3.attribValue
24185
24165
  definitions: o
24186
24166
  };
24187
24167
  }
24188
- const Bp$1 = (r22) => {
24168
+ const Fp$1 = (r22) => {
24189
24169
  const e = r22["word/settings.xml"];
24190
24170
  if (!e || !e.elements?.length) return false;
24191
24171
  const { elements: t = [] } = e.elements[0];
24192
24172
  return !!t.find((i3) => i3.name === "w:evenAndOddHeaders");
24193
- }, kp$1 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink";
24173
+ }, Bp$1 = "http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink";
24194
24174
  var it$2, Su$2, Tu$2, Fu$2, Bu$2;
24195
24175
  const pt$1 = class pt2 {
24196
24176
  constructor(e = null) {
@@ -24199,7 +24179,7 @@ Actual: ` + p3.attribValue
24199
24179
  }
24200
24180
  parseFromXml() {
24201
24181
  this.docx?.forEach((e) => {
24202
- this.convertedXml[e.name] = this.parseXmlToJson(e.content), e.name === "word/document.xml" && (this.documentAttributes = this.convertedXml[e.name].elements[0]?.attributes), e.name === "word/styles.xml" && (this.convertedXml[e.name] = Sp$1(this.convertedXml[e.name]));
24182
+ this.convertedXml[e.name] = this.parseXmlToJson(e.content), e.name === "word/document.xml" && (this.documentAttributes = this.convertedXml[e.name].elements[0]?.attributes), e.name === "word/styles.xml" && (this.convertedXml[e.name] = Cp$1(this.convertedXml[e.name]));
24203
24183
  }), this.initialJSON = this.convertedXml["word/document.xml"], this.initialJSON || (this.initialJSON = this.parseXmlToJson(this.xml)), this.declaration = this.initialJSON?.declaration;
24204
24184
  }
24205
24185
  parseXmlToJson(e) {
@@ -24218,7 +24198,7 @@ Actual: ` + p3.attribValue
24218
24198
  return;
24219
24199
  }
24220
24200
  }
24221
- static updateDocumentVersion(e = this.convertedXml, t = "0.11.57") {
24201
+ static updateDocumentVersion(e = this.convertedXml, t = "0.11.58") {
24222
24202
  const n = "docProps/custom.xml";
24223
24203
  e[n] || (e[n] = ku$2());
24224
24204
  const i3 = e["docProps/custom.xml"];
@@ -24320,7 +24300,7 @@ Actual: ` + p3.attribValue
24320
24300
  }
24321
24301
  getSchema(e) {
24322
24302
  this.getDocumentInternalId();
24323
- const t = Dp$1({ ...this.convertedXml, media: this.media }, this, e);
24303
+ const t = Ap$1({ ...this.convertedXml, media: this.media }, this, e);
24324
24304
  return t ? (this.savedTagsToRestore.push({ ...t.savedTagsToRestore }), this.pageStyles = t.pageStyles, this.numbering = t.numbering, this.comments = t.comments, this.linkedStyles = t.linkedStyles, t.pmDoc) : null;
24325
24305
  }
24326
24306
  schemaToXml(e, t = false) {
@@ -24350,7 +24330,7 @@ Actual: ` + p3.attribValue
24350
24330
  });
24351
24331
  A3 = { ...F }, v = w;
24352
24332
  }
24353
- return this.convertedXml = { ...this.convertedXml, ...A3 }, Ke(this, it$2, Fu$2).call(this, [...h3.relationships, ...v]), Np$1(this.convertedXml), Ke(this, it$2, Su$2).call(this, h3), E3;
24333
+ return this.convertedXml = { ...this.convertedXml, ...A3 }, Ke(this, it$2, Fu$2).call(this, [...h3.relationships, ...v]), kp$1(this.convertedXml), Ke(this, it$2, Su$2).call(this, h3), E3;
24354
24334
  }
24355
24335
  exportToXmlJson({
24356
24336
  data: e,
@@ -24402,7 +24382,7 @@ Actual: ` + p3.attribValue
24402
24382
  const t = this.convertedXml["word/_rels/document.xml.rels"], n = t.elements.find((a) => a.name === "Relationships"), i3 = [], s = /rId|mi/g;
24403
24383
  let o = Math.max(...n.elements.map((a) => Number(a.attributes.Id.replace(s, ""))));
24404
24384
  e.forEach((a) => {
24405
- const u = a.attributes.Id, c3 = n.elements.find((g) => g.attributes.Target === a.attributes.Target), l = a.attributes.Target?.startsWith("media/") && u.length > 6, h3 = a.attributes.Type === kp$1 && u.length > 6;
24385
+ const u = a.attributes.Id, c3 = n.elements.find((g) => g.attributes.Target === a.attributes.Target), l = a.attributes.Target?.startsWith("media/") && u.length > 6, h3 = a.attributes.Type === Bp$1 && u.length > 6;
24406
24386
  c3 && !l && !h3 || (a.attributes.Target = a.attributes?.Target?.replace(/&/g, "&amp;"), a.attributes.Id = u.length > 6 ? u : `rId${++o}`, i3.push(a));
24407
24387
  }), n.elements = [...n.elements, ...i3], this.convertedXml["word/_rels/document.xml.rels"] = t;
24408
24388
  }, Bu$2 = async function(e, t) {
@@ -24462,7 +24442,7 @@ Actual: ` + p3.attribValue
24462
24442
  "w:tcPr": "tableCellProperties"
24463
24443
  })), Mt$1(pt$1, "elements", /* @__PURE__ */ new Set(["w:document", "w:body", "w:p", "w:r", "w:t", "w:delText"]));
24464
24444
  let Ot$1 = pt$1;
24465
- function Np$1(r22) {
24445
+ function kp$1(r22) {
24466
24446
  const e = "docProps/custom.xml";
24467
24447
  r22[e] || (r22[e] = ku$2());
24468
24448
  const n = r22[e].elements.find((a) => a.name === "Properties");
@@ -24481,7 +24461,7 @@ Actual: ` + p3.attribValue
24481
24461
  function ku$2() {
24482
24462
  return Jf$1;
24483
24463
  }
24484
- function Nu$2(r22 = 2, e = "0.11.57") {
24464
+ function Nu$2(r22 = 2, e = "0.11.58") {
24485
24465
  return {
24486
24466
  type: "element",
24487
24467
  name: "property",
@@ -26868,7 +26848,7 @@ Actual: ` + p3.attribValue
26868
26848
  async updateContentTypes(nt2, _3) {
26869
26849
  const R = Object.keys(_3).map((i3) => this.getFileExtension(i3)), y = "[Content_Types].xml", l = await nt2.file(y).async("string");
26870
26850
  let a = "";
26871
- const r = eh$2(l), h3 = /* @__PURE__ */ new Set();
26851
+ const r = Qp$1(l), h3 = /* @__PURE__ */ new Set();
26872
26852
  for (let i3 of R) {
26873
26853
  if (r.includes(i3) || h3.has(i3)) continue;
26874
26854
  const d = `<Default Extension="${i3}" ContentType="image/${i3}"/>`;
@@ -27305,12 +27285,12 @@ Actual: ` + p3.attribValue
27305
27285
  }
27306
27286
  return ai$1;
27307
27287
  }
27308
- const vt$1 = new zp$1("history"), gp = new zp$1("closeHistory");
27288
+ const vt$1 = new Vp$1("history"), gp = new Vp$1("closeHistory");
27309
27289
  function yp(t = {}) {
27310
27290
  return t = {
27311
27291
  depth: t.depth || 100,
27312
27292
  newGroupDelay: t.newGroupDelay || 500
27313
- }, new Vp$1({
27293
+ }, new Hp$1({
27314
27294
  key: vt$1,
27315
27295
  state: {
27316
27296
  init() {
@@ -27367,11 +27347,11 @@ Actual: ` + p3.attribValue
27367
27347
  this.config = {
27368
27348
  ...this.config,
27369
27349
  ...e
27370
- }, this.name = this.config.name, this.config.addOptions && (this.options = $p$1(
27350
+ }, this.name = this.config.name, this.config.addOptions && (this.options = Jp$1(
27371
27351
  I$1(this, "addOptions", {
27372
27352
  name: this.name
27373
27353
  })
27374
- )), this.storage = $p$1(
27354
+ )), this.storage = Jp$1(
27375
27355
  I$1(this, "addStorage", {
27376
27356
  name: this.name,
27377
27357
  options: this.options
@@ -27424,11 +27404,11 @@ Actual: ` + p3.attribValue
27424
27404
  this.config = {
27425
27405
  ...this.config,
27426
27406
  ...e
27427
- }, this.name = this.config.name, this.config.addOptions && (this.options = $p$1(
27407
+ }, this.name = this.config.name, this.config.addOptions && (this.options = Jp$1(
27428
27408
  I$1(this, "addOptions", {
27429
27409
  name: this.name
27430
27410
  })
27431
- )), this.storage = $p$1(
27411
+ )), this.storage = Jp$1(
27432
27412
  I$1(this, "addStorage", {
27433
27413
  name: this.name,
27434
27414
  options: this.options
@@ -27456,11 +27436,11 @@ Actual: ` + p3.attribValue
27456
27436
  this.config = {
27457
27437
  ...this.config,
27458
27438
  ...e
27459
- }, this.name = this.config.name, this.isExternal = !!this.config.isExternal, this.config.addOptions && (this.options = $p$1(
27439
+ }, this.name = this.config.name, this.isExternal = !!this.config.isExternal, this.config.addOptions && (this.options = Jp$1(
27460
27440
  I$1(this, "addOptions", {
27461
27441
  name: this.name
27462
27442
  })
27463
- )), this.storage = $p$1(
27443
+ )), this.storage = Jp$1(
27464
27444
  I$1(this, "addStorage", {
27465
27445
  name: this.name,
27466
27446
  options: this.options
@@ -27675,7 +27655,7 @@ Actual: ` + p3.attribValue
27675
27655
  return r;
27676
27656
  }, ft(T, Vn$2);
27677
27657
  function Pi$1(t) {
27678
- const e = Object.entries(t).filter(([n, r]) => n === "attrs" && Kp$1(r) ? false : r != null);
27658
+ const e = Object.entries(t).filter(([n, r]) => n === "attrs" && $p$1(r) ? false : r != null);
27679
27659
  return Object.fromEntries(e);
27680
27660
  }
27681
27661
  var Hn$2, Dc$1, Nc$1;
@@ -27689,7 +27669,7 @@ Actual: ` + p3.attribValue
27689
27669
  static createSchemaByExtensions(e, n) {
27690
27670
  var c3, d;
27691
27671
  const r = e.filter((u) => u.type === "node"), o = e.filter((u) => u.type === "mark"), i3 = r.find((u) => I$1(u, "topNode"))?.name, s = T.getAttributesFromExtensions(e), a = E(c3 = pr2, Hn$2, Dc$1).call(c3, r, s, n), l = E(d = pr2, Hn$2, Nc$1).call(d, o, s, n);
27692
- return new Op$1({ topNode: i3, nodes: a, marks: l });
27672
+ return new Pp$1({ topNode: i3, nodes: a, marks: l });
27693
27673
  }
27694
27674
  };
27695
27675
  Hn$2 = /* @__PURE__ */ new WeakSet(), Dc$1 = function(e, n, r) {
@@ -27708,19 +27688,19 @@ Actual: ` + p3.attribValue
27708
27688
  ...g ? g(i3) : {}
27709
27689
  };
27710
27690
  }, {}), d = Pi$1({
27711
- content: $p$1(I$1(i3, "content", a)),
27712
- group: $p$1(I$1(i3, "group", a)),
27713
- marks: $p$1(I$1(i3, "marks", a)),
27714
- inline: $p$1(I$1(i3, "inline", a)),
27715
- atom: $p$1(I$1(i3, "atom", a)),
27716
- selectable: $p$1(I$1(i3, "selectable", a)),
27717
- draggable: $p$1(I$1(i3, "draggable", a)),
27718
- code: $p$1(I$1(i3, "code", a)),
27719
- defining: $p$1(I$1(i3, "defining", a)),
27720
- isolating: $p$1(I$1(i3, "isolating", a)),
27691
+ content: Jp$1(I$1(i3, "content", a)),
27692
+ group: Jp$1(I$1(i3, "group", a)),
27693
+ marks: Jp$1(I$1(i3, "marks", a)),
27694
+ inline: Jp$1(I$1(i3, "inline", a)),
27695
+ atom: Jp$1(I$1(i3, "atom", a)),
27696
+ selectable: Jp$1(I$1(i3, "selectable", a)),
27697
+ draggable: Jp$1(I$1(i3, "draggable", a)),
27698
+ code: Jp$1(I$1(i3, "code", a)),
27699
+ defining: Jp$1(I$1(i3, "defining", a)),
27700
+ isolating: Jp$1(I$1(i3, "isolating", a)),
27721
27701
  attrs: l,
27722
27702
  ...c3
27723
- }), u = $p$1(I$1(i3, "parseDOM", a));
27703
+ }), u = Jp$1(I$1(i3, "parseDOM", a));
27724
27704
  u && (d.parseDOM = u.map((h3) => T.insertExtensionAttrsToParseRule(h3, s)));
27725
27705
  const f = I$1(i3, "renderDOM", a);
27726
27706
  f && (d.toDOM = (h3) => f({
@@ -27741,13 +27721,13 @@ Actual: ` + p3.attribValue
27741
27721
  }, l = Object.fromEntries(
27742
27722
  s.map((f) => [f.name, { default: f?.attribute?.default }])
27743
27723
  ), c3 = Pi$1({
27744
- group: $p$1(I$1(i3, "group", a)),
27745
- inclusive: $p$1(I$1(i3, "inclusive", a)),
27746
- excludes: $p$1(I$1(i3, "excludes", a)),
27747
- spanning: $p$1(I$1(i3, "spanning", a)),
27748
- code: $p$1(I$1(i3, "code", a)),
27724
+ group: Jp$1(I$1(i3, "group", a)),
27725
+ inclusive: Jp$1(I$1(i3, "inclusive", a)),
27726
+ excludes: Jp$1(I$1(i3, "excludes", a)),
27727
+ spanning: Jp$1(I$1(i3, "spanning", a)),
27728
+ code: Jp$1(I$1(i3, "code", a)),
27749
27729
  attrs: l
27750
- }), d = $p$1(I$1(i3, "parseDOM", a));
27730
+ }), d = Jp$1(I$1(i3, "parseDOM", a));
27751
27731
  d && (c3.parseDOM = d.map((f) => T.insertExtensionAttrsToParseRule(f, s)));
27752
27732
  const u = I$1(i3, "renderDOM", a);
27753
27733
  return u && (c3.toDOM = (f) => u({
@@ -27896,7 +27876,7 @@ Actual: ` + p3.attribValue
27896
27876
  return false;
27897
27877
  let o = Ic$1(r);
27898
27878
  if (!o) {
27899
- let s = r.blockRange(), a = s && _p$1(s);
27879
+ let s = r.blockRange(), a = s && Lp$1(s);
27900
27880
  return a == null ? false : (e && e(t.tr.lift(s, a).scrollIntoView()), true);
27901
27881
  }
27902
27882
  let i3 = o.nodeBefore;
@@ -27999,10 +27979,10 @@ Actual: ` + p3.attribValue
27999
27979
  const Cp = (t, e) => {
28000
27980
  let n = t.selection, r = n instanceof We$3, o;
28001
27981
  if (r) {
28002
- if (n.node.isTextblock || !Up$1(t.doc, n.from))
27982
+ if (n.node.isTextblock || !Mp$1(t.doc, n.from))
28003
27983
  return false;
28004
27984
  o = n.from;
28005
- } else if (o = jp$1(t.doc, n.from, -1), o == null)
27985
+ } else if (o = Up$1(t.doc, n.from, -1), o == null)
28006
27986
  return false;
28007
27987
  if (e) {
28008
27988
  let i3 = t.tr.join(o);
@@ -28012,10 +27992,10 @@ Actual: ` + p3.attribValue
28012
27992
  }, Ap = (t, e) => {
28013
27993
  let n = t.selection, r;
28014
27994
  if (n instanceof We$3) {
28015
- if (n.node.isTextblock || !Up$1(t.doc, n.to))
27995
+ if (n.node.isTextblock || !Mp$1(t.doc, n.to))
28016
27996
  return false;
28017
27997
  r = n.to;
28018
- } else if (r = jp$1(t.doc, n.to, 1), r == null)
27998
+ } else if (r = Up$1(t.doc, n.to, 1), r == null)
28019
27999
  return false;
28020
28000
  return e && e(t.tr.join(r).scrollIntoView()), true;
28021
28001
  }, Bc$1 = (t, e) => {
@@ -28061,17 +28041,17 @@ Actual: ` + p3.attribValue
28061
28041
  return false;
28062
28042
  if (n.depth > 1 && n.after() != n.end(-1)) {
28063
28043
  let i3 = n.before();
28064
- if (Mp$1(t.doc, i3))
28044
+ if (qp$1(t.doc, i3))
28065
28045
  return e && e(t.tr.split(i3).scrollIntoView()), true;
28066
28046
  }
28067
- let r = n.blockRange(), o = r && _p$1(r);
28047
+ let r = n.blockRange(), o = r && Lp$1(r);
28068
28048
  return o == null ? false : (e && e(t.tr.lift(r, o).scrollIntoView()), true);
28069
28049
  };
28070
28050
  function Tp(t) {
28071
28051
  return (e, n) => {
28072
28052
  let { $from: r, $to: o } = e.selection;
28073
28053
  if (e.selection instanceof We$3 && e.selection.node.isBlock)
28074
- return !r.parentOffset || !Mp$1(e.doc, r.pos) ? false : (n && n(e.tr.split(r.pos).scrollIntoView()), true);
28054
+ return !r.parentOffset || !qp$1(e.doc, r.pos) ? false : (n && n(e.tr.split(r.pos).scrollIntoView()), true);
28075
28055
  if (!r.depth)
28076
28056
  return false;
28077
28057
  let i3 = [], s, a, l = false, c3 = false;
@@ -28086,8 +28066,8 @@ Actual: ` + p3.attribValue
28086
28066
  }
28087
28067
  let d = e.tr;
28088
28068
  (e.selection instanceof tt$2 || e.selection instanceof at$3) && d.deleteSelection();
28089
- let u = d.mapping.map(r.pos), f = Mp$1(d.doc, u, i3.length, i3);
28090
- if (f || (i3[0] = a ? { type: a } : null, f = Mp$1(d.doc, u, i3.length, i3)), !f)
28069
+ let u = d.mapping.map(r.pos), f = qp$1(d.doc, u, i3.length, i3);
28070
+ if (f || (i3[0] = a ? { type: a } : null, f = qp$1(d.doc, u, i3.length, i3)), !f)
28091
28071
  return false;
28092
28072
  if (d.split(u, i3.length, i3), !l && c3 && r.node(s).type != a) {
28093
28073
  let p3 = d.mapping.map(r.before(s)), h3 = d.doc.resolve(p3);
@@ -28099,7 +28079,7 @@ Actual: ` + p3.attribValue
28099
28079
  const Dp = Tp(), Np = (t, e) => (e && e(t.tr.setSelection(new at$3(t.doc))), true);
28100
28080
  function Ep(t, e, n) {
28101
28081
  let r = e.nodeBefore, o = e.nodeAfter, i3 = e.index();
28102
- return !r || !o || !r.type.compatibleContent(o.type) ? false : !r.content.size && e.parent.canReplace(i3 - 1, i3) ? (n && n(t.tr.delete(e.pos - r.nodeSize, e.pos).scrollIntoView()), true) : !e.parent.canReplace(i3, i3 + 1) || !(o.isTextblock || Up$1(t.doc, e.pos)) ? false : (n && n(t.tr.join(e.pos).scrollIntoView()), true);
28082
+ return !r || !o || !r.type.compatibleContent(o.type) ? false : !r.content.size && e.parent.canReplace(i3 - 1, i3) ? (n && n(t.tr.delete(e.pos - r.nodeSize, e.pos).scrollIntoView()), true) : !e.parent.canReplace(i3, i3 + 1) || !(o.isTextblock || Mp$1(t.doc, e.pos)) ? false : (n && n(t.tr.join(e.pos).scrollIntoView()), true);
28103
28083
  }
28104
28084
  function $c$1(t, e, n, r) {
28105
28085
  let o = e.nodeBefore, i3 = e.nodeAfter, s, a, l = o.type.spec.isolating || i3.type.spec.isolating;
@@ -28113,11 +28093,11 @@ Actual: ` + p3.attribValue
28113
28093
  h3 = Q$1.from(s[b].create(null, h3));
28114
28094
  h3 = Q$1.from(o.copy(h3));
28115
28095
  let m = t.tr.step(new $e$2(e.pos - 1, p3, e.pos, p3, new ae$4(h3, 1, 0), s.length, true)), g = m.doc.resolve(p3 + 2 * s.length);
28116
- g.nodeAfter && g.nodeAfter.type == o.type && Up$1(m.doc, g.pos) && m.join(g.pos), n(m.scrollIntoView());
28096
+ g.nodeAfter && g.nodeAfter.type == o.type && Mp$1(m.doc, g.pos) && m.join(g.pos), n(m.scrollIntoView());
28117
28097
  }
28118
28098
  return true;
28119
28099
  }
28120
- let d = i3.type.spec.isolating || r > 0 && l ? null : Ee$2.findFrom(e, 1), u = d && d.$from.blockRange(d.$to), f = u && _p$1(u);
28100
+ let d = i3.type.spec.isolating || r > 0 && l ? null : Ee$2.findFrom(e, 1), u = d && d.$from.blockRange(d.$to), f = u && Lp$1(u);
28121
28101
  if (f != null && f >= e.depth)
28122
28102
  return n && n(t.tr.lift(u, f).scrollIntoView()), true;
28123
28103
  if (c3 && En$1(i3, "start", true) && En$1(o, "end")) {
@@ -28210,14 +28190,14 @@ Actual: ` + p3.attribValue
28210
28190
  }, Rp = ({ keepMarks: t = true } = {}) => (e) => {
28211
28191
  const { tr: n, state: r, dispatch: o, editor: i3 } = e, { selection: s, doc: a } = n, { $from: l, $to: c3 } = s, d = i3.extensionService.attributes, u = T.getSplittedAttributes(d, l.node().type.name, l.node().attrs);
28212
28192
  if (s instanceof We$3 && s.node.isBlock)
28213
- return !l.parentOffset || !Mp$1(a, l.pos) ? false : (o && (t && xa$1(r, i3.extensionService.splittableMarks), n.split(l.pos).scrollIntoView()), true);
28193
+ return !l.parentOffset || !qp$1(a, l.pos) ? false : (o && (t && xa$1(r, i3.extensionService.splittableMarks), n.split(l.pos).scrollIntoView()), true);
28214
28194
  if (!l.parent.isBlock) return false;
28215
28195
  if (o) {
28216
28196
  const f = c3.parentOffset === c3.parent.content.size;
28217
28197
  s instanceof tt$2 && n.deleteSelection();
28218
28198
  const p3 = l.depth === 0 ? null : Hc$1(l.node(-1).contentMatchAt(l.indexAfter(-1)));
28219
- let h3 = f && p3 ? [{ type: p3, attrs: u }] : void 0, m = Mp$1(n.doc, n.mapping.map(l.pos), 1, h3);
28220
- if (!h3 && !m && Mp$1(n.doc, n.mapping.map(l.pos), 1, p3 ? [{ type: p3 }] : void 0) && (m = true, h3 = p3 ? [{ type: p3, attrs: u }] : void 0), m && (n.split(n.mapping.map(l.pos), 1, h3), p3 && !f && !l.parentOffset && l.parent.type !== p3)) {
28199
+ let h3 = f && p3 ? [{ type: p3, attrs: u }] : void 0, m = qp$1(n.doc, n.mapping.map(l.pos), 1, h3);
28200
+ if (!h3 && !m && qp$1(n.doc, n.mapping.map(l.pos), 1, p3 ? [{ type: p3 }] : void 0) && (m = true, h3 = p3 ? [{ type: p3, attrs: u }] : void 0), m && (n.split(n.mapping.map(l.pos), 1, h3), p3 && !f && !l.parentOffset && l.parent.type !== p3)) {
28221
28201
  const g = n.mapping.map(l.before()), b = n.doc.resolve(g);
28222
28202
  l.node(-1).canReplaceWith(b.index(), b.index() + 1, p3) && n.setNodeMarkup(n.mapping.map(l.before()), p3);
28223
28203
  }
@@ -28345,7 +28325,7 @@ Actual: ` + p3.attribValue
28345
28325
  if (a.type.isText) return;
28346
28326
  const { doc: c3, mapping: d } = e, u = c3.resolve(d.map(l)), f = c3.resolve(d.map(l + a.nodeSize)), p3 = u.blockRange(f);
28347
28327
  if (!p3) return;
28348
- const h3 = _p$1(p3);
28328
+ const h3 = Lp$1(p3);
28349
28329
  if (a.type.isTextblock) {
28350
28330
  const { defaultType: m } = u.parent.contentMatchAt(u.index());
28351
28331
  e.setNodeMarkup(p3.start, m);
@@ -28399,8 +28379,8 @@ Actual: ` + p3.attribValue
28399
28379
  );
28400
28380
  return a ? (a === "node" && (i3 = ae$3(t, r.schema)), a === "mark" && (s = St$1(t, r.schema)), o && n.selection.ranges.forEach((l) => {
28401
28381
  r.doc.nodesBetween(l.$from.pos, l.$to.pos, (c3, d) => {
28402
- i3 && i3 === c3.type && n.setNodeMarkup(d, void 0, Zp$1(c3.attrs, e)), s && c3.marks.length && c3.marks.forEach((u) => {
28403
- s === u.type && n.addMark(d, d + c3.nodeSize, s.create(Zp$1(u.attrs, e)));
28382
+ i3 && i3 === c3.type && n.setNodeMarkup(d, void 0, Yp$1(c3.attrs, e)), s && c3.marks.length && c3.marks.forEach((u) => {
28383
+ s === u.type && n.addMark(d, d + c3.nodeSize, s.create(Yp$1(u.attrs, e)));
28404
28384
  });
28405
28385
  });
28406
28386
  }), true) : false;
@@ -28437,7 +28417,7 @@ Actual: ` + p3.attribValue
28437
28417
  if (o) {
28438
28418
  if (n.errorOnInvalidContent) {
28439
28419
  let s = false, a = "";
28440
- const l = new Op$1({
28420
+ const l = new Pp$1({
28441
28421
  topNode: e.spec.topNode,
28442
28422
  marks: e.spec.marks,
28443
28423
  // Prosemirror's schemas are executed such that: the last to execute, matches last
@@ -28554,7 +28534,7 @@ Actual: ` + p3.attribValue
28554
28534
  let l = s.resolve(e.start - 2);
28555
28535
  i3 = new qc$2(l, l, e.depth), e.endIndex < e.parent.childCount && (e = new qc$2(e.$from, s.resolve(e.$to.end(e.depth)), e.depth)), o = true;
28556
28536
  }
28557
- let a = qp$1(i3, n, r, e);
28537
+ let a = _p$1(i3, n, r, e);
28558
28538
  return a ? (t && ph$1(t, e, a, o, n), true) : false;
28559
28539
  }
28560
28540
  function ph$1(t, e, n, r, o) {
@@ -28567,7 +28547,7 @@ Actual: ` + p3.attribValue
28567
28547
  n[d].type == o && (s = d + 1);
28568
28548
  let a = n.length - s, l = e.start + n.length - (r ? 2 : 0), c3 = e.parent;
28569
28549
  for (let d = e.startIndex, u = e.endIndex, f = true; d < u; d++, f = false)
28570
- !f && Mp$1(t.doc, l, a) && (t.split(l, a), l += 2 * a), l += c3.child(d).nodeSize;
28550
+ !f && qp$1(t.doc, l, a) && (t.split(l, a), l += 2 * a), l += c3.child(d).nodeSize;
28571
28551
  return t;
28572
28552
  }
28573
28553
  function hh$1(t) {
@@ -28579,12 +28559,12 @@ Actual: ` + p3.attribValue
28579
28559
  function mh$1(t, e, n, r) {
28580
28560
  let o = t.tr, i3 = r.end, s = r.$to.end(r.depth);
28581
28561
  i3 < s && (o.step(new $e$2(i3 - 1, s, i3, s, new ae$4(Q$1.from(n.create(null, r.parent.copy())), 1, 0), 1, true)), r = new qc$2(o.doc.resolve(r.$from.pos), o.doc.resolve(s), r.depth));
28582
- const a = _p$1(r);
28562
+ const a = Lp$1(r);
28583
28563
  if (a == null)
28584
28564
  return false;
28585
28565
  o.lift(r, a);
28586
28566
  let l = o.doc.resolve(o.mapping.map(i3, -1) - 1);
28587
- return Up$1(o.doc, l.pos) && l.nodeBefore.type == l.nodeAfter.type && o.join(l.pos), e(o.scrollIntoView()), true;
28567
+ return Mp$1(o.doc, l.pos) && l.nodeBefore.type == l.nodeAfter.type && o.join(l.pos), e(o.scrollIntoView()), true;
28588
28568
  }
28589
28569
  function gh$1(t, e, n) {
28590
28570
  let r = t.tr, o = n.parent;
@@ -28638,7 +28618,7 @@ Actual: ` + p3.attribValue
28638
28618
  name: r.name,
28639
28619
  options: r.options,
28640
28620
  storage: r.storage
28641
- }, i3 = $p$1(I$1(r, "group", o));
28621
+ }, i3 = Jp$1(I$1(r, "group", o));
28642
28622
  return typeof i3 != "string" ? false : i3.split(" ").includes("list");
28643
28623
  }, wh$1 = {
28644
28624
  type: "element",
@@ -29789,14 +29769,14 @@ Actual: ` + p3.attribValue
29789
29769
  const r = t.doc.resolve(Math.max(0, n.pos - 1)).before(n.depth);
29790
29770
  if (r === void 0) return true;
29791
29771
  const o = t.doc.nodeAt(r);
29792
- return n.node.type === o?.type && Up$1(t.doc, n.pos) && t.join(n.pos), true;
29772
+ return n.node.type === o?.type && Mp$1(t.doc, n.pos) && t.join(n.pos), true;
29793
29773
  }, ci$1 = (t, e) => {
29794
29774
  const n = He$1((s) => s.type === e)(t.selection);
29795
29775
  if (!n) return true;
29796
29776
  const r = t.doc.resolve(n.start).after(n.depth);
29797
29777
  if (r === void 0) return true;
29798
29778
  const o = t.doc.nodeAt(r);
29799
- return n.node.type === o?.type && Up$1(t.doc, r) && t.join(r), true;
29779
+ return n.node.type === o?.type && Mp$1(t.doc, r) && t.join(r), true;
29800
29780
  }, kh$1 = (t, e, n, r = {}) => (o) => {
29801
29781
  const { editor: i3, tr: s, state: a, dispatch: l, chain: c3, can: d, commands: u } = o, { extensions: f, splittableMarks: p3 } = i3.extensionService, h3 = ae$3(t, a.schema), m = ae$3(e, a.schema), { selection: g, storedMarks: b } = a, { $from: w, $to: x } = g, y = w.blockRange(x), S = b || g.$to.parentOffset && g.$from.marks();
29802
29782
  if (!y) return false;
@@ -29885,7 +29865,7 @@ Actual: ` + p3.attribValue
29885
29865
  { type: s, attrs: p3 },
29886
29866
  { type: f, attrs: h3 }
29887
29867
  ] : [{ type: s, attrs: p3 }];
29888
- if (!Mp$1(n.doc, a.pos, 2))
29868
+ if (!qp$1(n.doc, a.pos, 2))
29889
29869
  return false;
29890
29870
  if (o) {
29891
29871
  const { selection: g, storedMarks: b } = r, { splittableMarks: w } = i3.extensionService, x = b || g.$to.parentOffset && g.$from.marks();
@@ -29986,13 +29966,13 @@ Actual: ` + p3.attribValue
29986
29966
  "Ctrl-e": () => this.editor.commands.selectTextblockEnd(),
29987
29967
  "Ctrl-t": () => this.editor.commands.insertTabChar()
29988
29968
  };
29989
- return Xp$1() || Yp$1() ? n : e;
29969
+ return Kp$1() || Xp$1() ? n : e;
29990
29970
  }
29991
29971
  }), Eh$1 = Z.create({
29992
29972
  name: "editable",
29993
29973
  addPmPlugins() {
29994
- return [new Vp$1({
29995
- key: new zp$1("editable"),
29974
+ return [new Hp$1({
29975
+ key: new Vp$1("editable"),
29996
29976
  props: {
29997
29977
  editable: () => this.editor.options.editable
29998
29978
  }
@@ -30002,8 +29982,8 @@ Actual: ` + p3.attribValue
30002
29982
  name: "editorFocus",
30003
29983
  addPmPlugins() {
30004
29984
  const t = this.editor;
30005
- return [new Vp$1({
30006
- key: new zp$1("editorFocus"),
29985
+ return [new Hp$1({
29986
+ key: new Vp$1("editorFocus"),
30007
29987
  props: {
30008
29988
  handleDOMEvents: {
30009
29989
  focus: (n, r) => {
@@ -30116,7 +30096,7 @@ Actual: ` + p3.attribValue
30116
30096
  }), n;
30117
30097
  }
30118
30098
  function Xc$1(t, e, n) {
30119
- const o = t.state.doc.content.size, i3 = Qp$1(e, 0, o), s = Qp$1(n, 0, o), a = t.coordsAtPos(i3), l = t.coordsAtPos(s, -1), c3 = Math.min(a.top, l.top), d = Math.max(a.bottom, l.bottom), u = Math.min(a.left, l.left), f = Math.max(a.right, l.right), p3 = f - u, h3 = d - c3, b = {
30099
+ const o = t.state.doc.content.size, i3 = Zp$1(e, 0, o), s = Zp$1(n, 0, o), a = t.coordsAtPos(i3), l = t.coordsAtPos(s, -1), c3 = Math.min(a.top, l.top), d = Math.max(a.bottom, l.bottom), u = Math.min(a.left, l.left), f = Math.max(a.right, l.right), p3 = f - u, h3 = d - c3, b = {
30120
30100
  top: c3,
30121
30101
  bottom: d,
30122
30102
  left: u,
@@ -32576,7 +32556,7 @@ Actual: ` + p3.attribValue
32576
32556
  if (!s)
32577
32557
  return;
32578
32558
  n.preventDefault();
32579
- let l = s ? Hp$1(t.state.doc, i3.pos, s) : i3.pos;
32559
+ let l = s ? jp$1(t.state.doc, i3.pos, s) : i3.pos;
32580
32560
  l == null && (l = i3.pos);
32581
32561
  let c3 = t.state.tr;
32582
32562
  if (a) {
@@ -34048,7 +34028,7 @@ Actual: ` + p3.attribValue
34048
34028
  remove: t.length - n - r,
34049
34029
  insert: e.slice(n, e.length - r)
34050
34030
  };
34051
- }, ey = Qg, te$1 = new zp$1("y-sync"), _t$1 = new zp$1("y-undo"), Qr$1 = new zp$1("yjs-cursor"), ty = Math.random, ny = (t) => t[wr$1(ty() * t.length)], sl$1 = (t) => t === void 0 ? null : t;
34031
+ }, ey = Qg, te$1 = new Vp$1("y-sync"), _t$1 = new Vp$1("y-undo"), Qr$1 = new Vp$1("yjs-cursor"), ty = Math.random, ny = (t) => t[wr$1(ty() * t.length)], sl$1 = (t) => t === void 0 ? null : t;
34052
34032
  class ry {
34053
34033
  constructor() {
34054
34034
  this.map = /* @__PURE__ */ new Map();
@@ -34267,7 +34247,7 @@ Actual: ` + p3.attribValue
34267
34247
  mapping: i3
34268
34248
  } = {}) => {
34269
34249
  let s = false;
34270
- const a = new Ny(t, i3), l = new Vp$1({
34250
+ const a = new Ny(t, i3), l = new Hp$1({
34271
34251
  props: {
34272
34252
  editable: (c3) => {
34273
34253
  const d = te$1.getState(c3);
@@ -35072,7 +35052,7 @@ Actual: ` + p3.attribValue
35072
35052
  cursorBuilder: n = Wy,
35073
35053
  selectionBuilder: r = Uy,
35074
35054
  getSelection: o = (s) => s.selection
35075
- } = {}, i3 = "cursor") => new Vp$1({
35055
+ } = {}, i3 = "cursor") => new Hp$1({
35076
35056
  key: Qr$1,
35077
35057
  state: {
35078
35058
  init(s, a) {
@@ -35137,7 +35117,7 @@ Actual: ` + p3.attribValue
35137
35117
  }
35138
35118
  };
35139
35119
  }
35140
- }), Xy = (t) => _t$1.getState(t)?.undoManager?.undo() != null, Jy = (t) => _t$1.getState(t)?.undoManager?.redo() != null, Yy = /* @__PURE__ */ new Set(["paragraph"]), Gy = (t, e) => !(t instanceof N.Item) || !(t.content instanceof N.ContentType) || !(t.content.type instanceof N.Text || t.content.type instanceof N.XmlElement && e.has(t.content.type.nodeName)) || t.content.type._length === 0, Zy = ({ protectedNodes: t = Yy, trackedOrigins: e = [], undoManager: n = null } = {}) => new Vp$1({
35120
+ }), Xy = (t) => _t$1.getState(t)?.undoManager?.undo() != null, Jy = (t) => _t$1.getState(t)?.undoManager?.redo() != null, Yy = /* @__PURE__ */ new Set(["paragraph"]), Gy = (t, e) => !(t instanceof N.Item) || !(t.content instanceof N.ContentType) || !(t.content.type instanceof N.Text || t.content.type instanceof N.XmlElement && e.has(t.content.type.nodeName)) || t.content.type._length === 0, Zy = ({ protectedNodes: t = Yy, trackedOrigins: e = [], undoManager: n = null } = {}) => new Hp$1({
35141
35121
  key: _t$1,
35142
35122
  state: {
35143
35123
  init: (r, o) => {
@@ -35347,7 +35327,7 @@ Actual: ` + p3.attribValue
35347
35327
  return e.altKey && (t = "Alt-" + t), e.ctrlKey && (t = "Ctrl-" + t), e.metaKey && (t = "Meta-" + t), n && e.shiftKey && (t = "Shift-" + t), t;
35348
35328
  }
35349
35329
  function ab(t) {
35350
- return new Vp$1({ props: { handleKeyDown: Ks(t) } });
35330
+ return new Hp$1({ props: { handleKeyDown: Ks(t) } });
35351
35331
  }
35352
35332
  function Ks(t) {
35353
35333
  let e = sb(t);
@@ -35456,8 +35436,8 @@ Actual: ` + p3.attribValue
35456
35436
  }), a.dispatch(p3), c3 = true);
35457
35437
  }), c3;
35458
35438
  }, pb = ({ editor: t, rules: e }) => {
35459
- const n = new Vp$1({
35460
- key: new zp$1("inputRulesPlugin"),
35439
+ const n = new Hp$1({
35440
+ key: new Vp$1("inputRulesPlugin"),
35461
35441
  state: {
35462
35442
  init() {
35463
35443
  return null;
@@ -35693,7 +35673,7 @@ Actual: ` + p3.attribValue
35693
35673
  editor: this.editor,
35694
35674
  type: er$1(e.name, this.schema)
35695
35675
  };
35696
- e.type === "mark" && ($p$1(I$1(e, "keepOnSplit", n)) ?? true) && this.splittableMarks.push(e.name), E(this, jn$2, Hd$1).call(this, e);
35676
+ e.type === "mark" && (Jp$1(I$1(e, "keepOnSplit", n)) ?? true) && this.splittableMarks.push(e.name), E(this, jn$2, Hd$1).call(this, e);
35697
35677
  }
35698
35678
  }, /**
35699
35679
  * Attach editor events to extension
@@ -35835,7 +35815,7 @@ Actual: ` + p3.attribValue
35835
35815
  });
35836
35816
  });
35837
35817
  }), e ? n.filter(({ mark: o }) => o.attrs.id === e) : n) : n;
35838
- }, ce$2 = new zp$1("TrackChangesBase"), bb = (t = {}) => new Vp$1({
35818
+ }, ce$2 = new Vp$1("TrackChangesBase"), bb = (t = {}) => new Hp$1({
35839
35819
  key: ce$2,
35840
35820
  state: {
35841
35821
  init(e, n) {
@@ -36064,7 +36044,7 @@ Actual: ` + p3.attribValue
36064
36044
  if (!r.options.isInternal && n) return "transparent";
36065
36045
  const o = ge.getState(r.state), i3 = n ? o.internalColor : o.externalColor, s = t == e ? "44" : "22";
36066
36046
  return `${i3}${s}`;
36067
- }, $t$1 = new zp$1("paginationPlugin"), Mb = async (t) => {
36047
+ }, $t$1 = new Vp$1("paginationPlugin"), Mb = async (t) => {
36068
36048
  if (!t.converter) return;
36069
36049
  const e = { headers: {}, footers: {} }, n = t.converter.headerIds.ids, r = t.converter.footerIds.ids;
36070
36050
  for (let o in n) {
@@ -36130,7 +36110,7 @@ Actual: ` + p3.attribValue
36130
36110
  }), n({ height: d, sectionEditor: c3, sectionContainer: r });
36131
36111
  });
36132
36112
  });
36133
- }) : {}, Ys = [xr$2, Pi$2, Oi$2], ge = new zp$1("comments"), Cb = Z.create({
36113
+ }) : {}, Ys = [xr$2, Pi$2, Oi$2], ge = new Vp$1("comments"), Cb = Z.create({
36134
36114
  name: "comments",
36135
36115
  addCommands() {
36136
36116
  return {
@@ -36179,7 +36159,7 @@ Actual: ` + p3.attribValue
36179
36159
  addPmPlugins() {
36180
36160
  const t = this.editor;
36181
36161
  let e, n;
36182
- return t.options.isHeadless ? [] : [new Vp$1({
36162
+ return t.options.isHeadless ? [] : [new Hp$1({
36183
36163
  key: ge,
36184
36164
  state: {
36185
36165
  init() {
@@ -36218,7 +36198,7 @@ Actual: ` + p3.attribValue
36218
36198
  if (h3 && (g = d.activeThreadId), n !== g) {
36219
36199
  n = g;
36220
36200
  const w = {
36221
- type: Wp$1.SELECTED,
36201
+ type: Gp$1.SELECTED,
36222
36202
  activeCommentId: n || null
36223
36203
  };
36224
36204
  e = true, t.emit("commentsUpdate", w);
@@ -36448,7 +36428,7 @@ Actual: ` + p3.attribValue
36448
36428
  if (!b && !w)
36449
36429
  return;
36450
36430
  const x = {
36451
- event: Wp$1.ADD,
36431
+ event: Gp$1.ADD,
36452
36432
  type: "trackedChange",
36453
36433
  documentId: i3,
36454
36434
  changeId: p3,
@@ -36459,7 +36439,7 @@ Actual: ` + p3.attribValue
36459
36439
  authorEmail: u,
36460
36440
  date: f
36461
36441
  };
36462
- return t === "add" ? x.event = Wp$1.ADD : t === "update" && (x.event = Wp$1.UPDATE), x;
36442
+ return t === "add" ? x.event = Gp$1.ADD : t === "update" && (x.event = Gp$1.UPDATE), x;
36463
36443
  };
36464
36444
  function Nb(t, e) {
36465
36445
  let n = null;
@@ -37266,7 +37246,7 @@ Actual: ` + p3.attribValue
37266
37246
  * @returns {Object | void} Migration results
37267
37247
  */
37268
37248
  processCollaborationMigrations() {
37269
- if (console.debug("[checkVersionMigrations] Current editor version", "0.11.57"), !this.options.ydoc) return;
37249
+ if (console.debug("[checkVersionMigrations] Current editor version", "0.11.58"), !this.options.ydoc) return;
37270
37250
  let r = this.options.ydoc.getMap("meta").get("version");
37271
37251
  r || (r = "initial"), console.debug("[checkVersionMigrations] Document version", r);
37272
37252
  const o = hl$1(r) || [], s = this.state.plugins.find((c3) => c3.key.startsWith("y-sync"));
@@ -37742,7 +37722,7 @@ Actual: ` + p3.attribValue
37742
37722
  if (Number.isNaN(n))
37743
37723
  return false;
37744
37724
  let { min: o, max: i3, unit: s } = this.options.defaults;
37745
- return n = Qp$1(n, o, i3), r = r || s, e().setMark("textStyle", { fontSize: `${n}${r}` }).run();
37725
+ return n = Zp$1(n, o, i3), r = r || s, e().setMark("textStyle", { fontSize: `${n}${r}` }).run();
37746
37726
  },
37747
37727
  unsetFontSize: () => ({ chain: t }) => t().setMark("textStyle", { fontSize: null }).removeEmptyTextStyle().run()
37748
37728
  };
@@ -37864,7 +37844,7 @@ Actual: ` + p3.attribValue
37864
37844
  lineHeight: {
37865
37845
  default: null,
37866
37846
  parseDOM: (t) => t.style.lineHeight,
37867
- renderDOM: (t) => t.lineHeight ? { style: th$2(t.lineHeight, this.options.defaults.unit, t.spacing?.lineRule) } : {}
37847
+ renderDOM: (t) => t.lineHeight ? { style: eh$2(t.lineHeight, this.options.defaults.unit, t.spacing?.lineRule) } : {}
37868
37848
  }
37869
37849
  }
37870
37850
  }
@@ -37931,7 +37911,7 @@ Actual: ` + p3.attribValue
37931
37911
  }
37932
37912
  });
37933
37913
  function qb(t = {}) {
37934
- return new Vp$1({
37914
+ return new Hp$1({
37935
37915
  view(e) {
37936
37916
  return new Kb(e, t);
37937
37917
  }
@@ -37995,7 +37975,7 @@ Actual: ` + p3.attribValue
37995
37975
  if (n && !i3) {
37996
37976
  let s = n.pos;
37997
37977
  if (this.editorView.dragging && this.editorView.dragging.slice) {
37998
- let a = Hp$1(this.editorView.state.doc, s, this.editorView.dragging.slice);
37978
+ let a = jp$1(this.editorView.state.doc, s, this.editorView.dragging.slice);
37999
37979
  a != null && (s = a);
38000
37980
  }
38001
37981
  this.setCursor(s), this.scheduleRemoval(5e3);
@@ -38159,7 +38139,7 @@ Actual: ` + p3.attribValue
38159
38139
  return true;
38160
38140
  }
38161
38141
  function Yb() {
38162
- return new Vp$1({
38142
+ return new Hp$1({
38163
38143
  props: {
38164
38144
  decorations: e0$1,
38165
38145
  createSelectionBetween(t, e, n) {
@@ -38226,14 +38206,14 @@ Actual: ` + p3.attribValue
38226
38206
  },
38227
38207
  extendNodeSchema(t) {
38228
38208
  return {
38229
- allowGapCursor: $p$1(I$1(t, "allowGapCursor", {
38209
+ allowGapCursor: Jp$1(I$1(t, "allowGapCursor", {
38230
38210
  name: t.name,
38231
38211
  options: t.options,
38232
38212
  storage: t.storage
38233
38213
  })) ?? null
38234
38214
  };
38235
38215
  }
38236
- }), n0$1 = new zp$1("collaboration"), r0$1 = Z.create({
38216
+ }), n0$1 = new Vp$1("collaboration"), r0$1 = Z.create({
38237
38217
  name: "collaboration",
38238
38218
  priority: 1e3,
38239
38219
  addOptions() {
@@ -38412,7 +38392,7 @@ Actual: ` + p3.attribValue
38412
38392
  const n = document.createElement("img");
38413
38393
  return n.src = f0$1, n.alt = "loading...", n.width = 100, n.height = 50, e.appendChild(n), e;
38414
38394
  }
38415
- }), no$2 = new zp$1("ai"), yu$1 = Z.create({
38395
+ }), no$2 = new Vp$1("ai"), yu$1 = Z.create({
38416
38396
  name: "ai",
38417
38397
  addCommands() {
38418
38398
  return {
@@ -38470,7 +38450,7 @@ Actual: ` + p3.attribValue
38470
38450
  },
38471
38451
  addPmPlugins() {
38472
38452
  const t = this.editor;
38473
- return [new Vp$1({
38453
+ return [new Hp$1({
38474
38454
  key: no$2,
38475
38455
  state: {
38476
38456
  init() {
@@ -38575,7 +38555,7 @@ Actual: ` + p3.attribValue
38575
38555
  match: r,
38576
38556
  chain: o
38577
38557
  }) => {
38578
- const i3 = $p$1(t.getAttributes, null, r) || {}, s = e.tr.delete(n.from, n.to), l = s.doc.resolve(n.from).blockRange(), c3 = l && qp$1(l, t.type, i3);
38558
+ const i3 = Jp$1(t.getAttributes, null, r) || {}, s = e.tr.delete(n.from, n.to), l = s.doc.resolve(n.from).blockRange(), c3 = l && _p$1(l, t.type, i3);
38579
38559
  if (!c3)
38580
38560
  return null;
38581
38561
  if (s.wrap(l, c3), t.keepMarks && t.editor) {
@@ -38590,7 +38570,7 @@ Actual: ` + p3.attribValue
38590
38570
  o().updateAttributes(u, i3).run();
38591
38571
  }
38592
38572
  const d = s.doc.resolve(n.from - 1).nodeBefore;
38593
- d && d.type === t.type && Up$1(s.doc, n.from - 1) && (!t.joinPredicate || t.joinPredicate(r, d)) && s.join(n.from - 1);
38573
+ d && d.type === t.type && Mp$1(s.doc, n.from - 1) && (!t.joinPredicate || t.joinPredicate(r, d)) && s.join(n.from - 1);
38594
38574
  }
38595
38575
  });
38596
38576
  }
@@ -38661,8 +38641,8 @@ Actual: ` + p3.attribValue
38661
38641
  }
38662
38642
  });
38663
38643
  function g0$1(t = {}) {
38664
- return new Vp$1({
38665
- key: new zp$1("orderedListSync"),
38644
+ return new Hp$1({
38645
+ key: new Vp$1("orderedListSync"),
38666
38646
  appendTransaction: (e, n, r) => {
38667
38647
  if (!(e.some((d) => d.docChanged) && !n.doc.eq(r.doc)))
38668
38648
  return;
@@ -38701,8 +38681,8 @@ Actual: ` + p3.attribValue
38701
38681
  return Math.floor(Math.random() * 4294967295).toString();
38702
38682
  }
38703
38683
  function b0$1(t) {
38704
- return new Vp$1({
38705
- key: new zp$1("orderedListMarker"),
38684
+ return new Hp$1({
38685
+ key: new Vp$1("orderedListMarker"),
38706
38686
  appendTransaction: (e, n, r) => {
38707
38687
  if (!(e.some((c3) => c3.docChanged) && !n.doc.eq(r.doc)))
38708
38688
  return;
@@ -38850,7 +38830,7 @@ Actual: ` + p3.attribValue
38850
38830
  renderDOM: (t) => {
38851
38831
  let e = t["list-style-type"];
38852
38832
  return e ? (e === "lowerLetter" && (e = "lowerAlpha"), {
38853
- style: `list-style-type: ${Gp$1(e)};`
38833
+ style: `list-style-type: ${zp$1(e)};`
38854
38834
  }) : {};
38855
38835
  }
38856
38836
  },
@@ -39012,8 +38992,8 @@ Actual: ` + p3.attribValue
39012
38992
  return e;
39013
38993
  };
39014
38994
  function E0$1(t = {}) {
39015
- return new Vp$1({
39016
- key: new zp$1("styledListMarker"),
38995
+ return new Hp$1({
38996
+ key: new Vp$1("styledListMarker"),
39017
38997
  state: {
39018
38998
  init(e, n) {
39019
38999
  const r = [
@@ -39078,7 +39058,7 @@ Actual: ` + p3.attribValue
39078
39058
  style: `
39079
39059
  ${l ? `margin-top: ${l}px;` : ""}
39080
39060
  ${c3 ? `margin-bottom: ${c3}px;` : ""}
39081
- ${d ? th$2(d, "") : ""}
39061
+ ${d ? eh$2(d, "") : ""}
39082
39062
  `.trim()
39083
39063
  };
39084
39064
  }
@@ -39223,7 +39203,7 @@ Actual: ` + p3.attribValue
39223
39203
  addPmPlugins() {
39224
39204
  return [E0$1()];
39225
39205
  }
39226
- }), bo$2 = new zp$1("linkedStyles"), R0 = Z.create({
39206
+ }), bo$2 = new Vp$1("linkedStyles"), R0 = Z.create({
39227
39207
  name: "linkedStyles",
39228
39208
  addPmPlugins() {
39229
39209
  return [L0$1(this.editor)];
@@ -39246,7 +39226,7 @@ Actual: ` + p3.attribValue
39246
39226
  }
39247
39227
  };
39248
39228
  }
39249
- }), L0$1 = (t) => new Vp$1({
39229
+ }), L0$1 = (t) => new Hp$1({
39250
39230
  key: bo$2,
39251
39231
  state: {
39252
39232
  init(e, { doc: n, selection: r }) {
@@ -39318,14 +39298,14 @@ Actual: ` + p3.attribValue
39318
39298
  return {
39319
39299
  "margin-top": e + "px",
39320
39300
  "margin-bottom": n + "px",
39321
- ...th$2(r, "", o, true)
39301
+ ...eh$2(r, "", o, true)
39322
39302
  };
39323
39303
  }, _0 = (t) => {
39324
39304
  const { lineSpaceBefore: e, lineSpaceAfter: n, line: r } = t;
39325
39305
  return `
39326
39306
  ${e ? `margin-top: ${e}px;` : ""}
39327
39307
  ${n ? `margin-bottom: ${n}px;` : ""}
39328
- ${r ? th$2(r, "") : ""}
39308
+ ${r ? eh$2(r, "") : ""}
39329
39309
  `.trim();
39330
39310
  }, $0$1 = (t) => {
39331
39311
  let e = "";
@@ -39435,9 +39415,9 @@ Actual: ` + p3.attribValue
39435
39415
  },
39436
39416
  addPmPlugins() {
39437
39417
  const { view: t } = this.editor;
39438
- return [new Vp$1({
39418
+ return [new Hp$1({
39439
39419
  name: "dropcapPlugin",
39440
- key: new zp$1("dropcapPlugin"),
39420
+ key: new Vp$1("dropcapPlugin"),
39441
39421
  state: {
39442
39422
  init(n, r) {
39443
39423
  let o = kl$1(r, t);
@@ -39661,9 +39641,9 @@ Actual: ` + p3.attribValue
39661
39641
  },
39662
39642
  addPmPlugins() {
39663
39643
  const { view: t } = this.editor;
39664
- return [new Vp$1({
39644
+ return [new Hp$1({
39665
39645
  name: "tabPlugin",
39666
- key: new zp$1("tabPlugin"),
39646
+ key: new Vp$1("tabPlugin"),
39667
39647
  state: {
39668
39648
  init(n, r) {
39669
39649
  let o = xl$1(r, t);
@@ -40071,7 +40051,7 @@ Actual: ` + p3.attribValue
40071
40051
  }
40072
40052
  return e;
40073
40053
  }
40074
- var Et$1 = new zp$1("selectingCells");
40054
+ var Et$1 = new Vp$1("selectingCells");
40075
40055
  function Un$2(t) {
40076
40056
  for (let e = t.depth - 1; e > 0; e--)
40077
40057
  if (t.node(e).type.spec.tableRole == "row")
@@ -40375,7 +40355,7 @@ Actual: ` + p3.attribValue
40375
40355
  } else r instanceof tt$2 && lw(r) ? i3 = tt$2.create(o, r.from) : r instanceof tt$2 && cw(r) && (i3 = tt$2.create(o, r.$from.start(), r.$from.end()));
40376
40356
  return i3 && (e || (e = t.tr)).setSelection(i3), e;
40377
40357
  }
40378
- var uw = new zp$1("fix-tables");
40358
+ var uw = new Vp$1("fix-tables");
40379
40359
  function Iu$1(t, e, n, r) {
40380
40360
  const o = t.childCount, i3 = e.childCount;
40381
40361
  e: for (let s = 0, a = 0; s < i3; s++) {
@@ -41289,7 +41269,7 @@ Actual: ` + p3.attribValue
41289
41269
  l ? (n.style.width = a + "px", n.style.minWidth = "") : (n.style.width = "", n.style.minWidth = a + "px");
41290
41270
  }
41291
41271
  }
41292
- var Ie$1 = new zp$1(
41272
+ var Ie$1 = new Vp$1(
41293
41273
  "tableColumnResizing"
41294
41274
  );
41295
41275
  function zw({
@@ -41299,7 +41279,7 @@ Actual: ` + p3.attribValue
41299
41279
  View: r = Bw,
41300
41280
  lastColumnResizable: o = true
41301
41281
  } = {}) {
41302
- const i3 = new Vp$1({
41282
+ const i3 = new Hp$1({
41303
41283
  key: Ie$1,
41304
41284
  state: {
41305
41285
  init(s, a) {
@@ -41513,7 +41493,7 @@ Actual: ` + p3.attribValue
41513
41493
  function Xw({
41514
41494
  allowTableNodeSelection: t = false
41515
41495
  } = {}) {
41516
- return new Vp$1({
41496
+ return new Hp$1({
41517
41497
  key: Et$1,
41518
41498
  // This piece of state is used to remember when a mouse-drag
41519
41499
  // cell-selection is happening, so that it can continue even as
@@ -41736,7 +41716,7 @@ Actual: ` + p3.attribValue
41736
41716
  },
41737
41717
  extendNodeSchema(t) {
41738
41718
  return {
41739
- tableRole: $p$1(I$1(t, "tableRole", {
41719
+ tableRole: Jp$1(I$1(t, "tableRole", {
41740
41720
  name: t.name,
41741
41721
  options: t.options,
41742
41722
  storage: t.storage
@@ -42064,8 +42044,8 @@ Actual: ` + p3.attribValue
42064
42044
  }
42065
42045
  const Gw = (t = {}) => {
42066
42046
  let { editor: e, annotationClass: n } = t;
42067
- return new Vp$1({
42068
- key: new zp$1("fieldAnnotation"),
42047
+ return new Hp$1({
42048
+ key: new Vp$1("fieldAnnotation"),
42069
42049
  state: {
42070
42050
  init() {
42071
42051
  return null;
@@ -42779,7 +42759,7 @@ Actual: ` + p3.attribValue
42779
42759
  if (!c3.length)
42780
42760
  return true;
42781
42761
  let [d, u] = _f$1(t), f = 8, p3 = 96, h3 = "pt";
42782
- return Number.isNaN(d) ? false : (d = Qp$1(d, f, p3), u = u || h3, n && (c3.forEach((m) => {
42762
+ return Number.isNaN(d) ? false : (d = Zp$1(d, f, p3), u = u || h3, n && (c3.forEach((m) => {
42783
42763
  i3.updateFieldAnnotationsAttributes([m], {
42784
42764
  fontSize: `${d}${u}`
42785
42765
  });
@@ -42839,7 +42819,7 @@ Actual: ` + p3.attribValue
42839
42819
  }
42840
42820
  return e;
42841
42821
  }
42842
- const Bo$1 = new zp$1("ImagePlaceholder"), yv = (t = {}) => new Vp$1({
42822
+ const Bo$1 = new Vp$1("ImagePlaceholder"), yv = (t = {}) => new Hp$1({
42843
42823
  key: Bo$1,
42844
42824
  state: {
42845
42825
  init() {
@@ -42865,10 +42845,10 @@ Actual: ` + p3.attribValue
42865
42845
  }), Yx = (t, e) => {
42866
42846
  let r = Bo$1.getState(t)?.find(null, null, (o) => o.id === e);
42867
42847
  return r?.length ? r[0].from : null;
42868
- }, Vl$1 = new zp$1("ImagePosition"), bv = ({ editor: t }) => {
42848
+ }, Vl$1 = new Vp$1("ImagePosition"), bv = ({ editor: t }) => {
42869
42849
  const { view: e } = t;
42870
42850
  let n = false;
42871
- return new Vp$1({
42851
+ return new Hp$1({
42872
42852
  name: "ImagePositionPlugin",
42873
42853
  key: Vl$1,
42874
42854
  state: {
@@ -43931,8 +43911,8 @@ Actual: ` + p3.attribValue
43931
43911
  });
43932
43912
  return P.create(n.doc, [i3]);
43933
43913
  };
43934
- return [new Vp$1({
43935
- key: new zp$1("placeholder"),
43914
+ return [new Hp$1({
43915
+ key: new Vp$1("placeholder"),
43936
43916
  state: {
43937
43917
  init: (n, r) => t(r),
43938
43918
  apply: (n, r, o, i3) => t(i3)
@@ -45719,10 +45699,10 @@ Actual: ` + p3.attribValue
45719
45699
  ], 42, px))), 128))
45720
45700
  ], 544));
45721
45701
  }
45722
- }, wx = /* @__PURE__ */ fx(bx, [["__scopeId", "data-v-0a2a8b4e"]]), dc$1 = new zp$1("popoverPlugin"), vx = Z.create({
45702
+ }, wx = /* @__PURE__ */ fx(bx, [["__scopeId", "data-v-0a2a8b4e"]]), dc$1 = new Vp$1("popoverPlugin"), vx = Z.create({
45723
45703
  name: "popoverPlugin",
45724
45704
  addPmPlugins() {
45725
- return [new Vp$1({
45705
+ return [new Hp$1({
45726
45706
  key: dc$1,
45727
45707
  state: {
45728
45708
  init: () => ({}),
@@ -45850,7 +45830,7 @@ Actual: ` + p3.attribValue
45850
45830
  addPmPlugins() {
45851
45831
  const t = this.editor;
45852
45832
  let e = false, n = false, r = false, o = false;
45853
- return [new Vp$1({
45833
+ return [new Hp$1({
45854
45834
  key: $t$1,
45855
45835
  state: {
45856
45836
  isReadyToInit: false,
@@ -46293,9 +46273,9 @@ Actual: ` + p3.attribValue
46293
46273
  }
46294
46274
  return P.create(t.doc, r);
46295
46275
  }
46296
- const fr = new zp$1("search");
46276
+ const fr = new Vp$1("search");
46297
46277
  function Rx(t = {}) {
46298
- return new Vp$1({
46278
+ return new Hp$1({
46299
46279
  key: fr,
46300
46280
  state: {
46301
46281
  init(e, n) {
@@ -46336,8 +46316,8 @@ Actual: ` + p3.attribValue
46336
46316
  };
46337
46317
  },
46338
46318
  addPmPlugins() {
46339
- const t = this.editor, e = this.storage, n = new Vp$1({
46340
- key: new zp$1("customSearchHighlights"),
46319
+ const t = this.editor, e = this.storage, n = new Hp$1({
46320
+ key: new Vp$1("customSearchHighlights"),
46341
46321
  props: {
46342
46322
  decorations(r) {
46343
46323
  if (!t) return null;
@@ -56018,7 +55998,7 @@ ${t}
56018
55998
  console.warn(`[super-toolbar 🎨] Element not found: ${this.config.selector}`);
56019
55999
  return;
56020
56000
  }
56021
- this.app = createApp(P0), this.app.directive("click-outside", Jp$1), this.app.config.globalProperties.$toolbar = this, n && (this.toolbar = this.app.mount(n)), this.activeEditor = o.editor || null, this.updateToolbarState();
56001
+ this.app = createApp(P0), this.app.directive("click-outside", Wp$1), this.app.config.globalProperties.$toolbar = this, n && (this.toolbar = this.app.mount(n)), this.activeEditor = o.editor || null, this.updateToolbarState();
56022
56002
  }
56023
56003
  /**
56024
56004
  * Log debug information to the console
@@ -71604,7 +71584,7 @@ ${style2}
71604
71584
  this.config.colors = shuffleArray(this.config.colors);
71605
71585
  this.userColorMap = /* @__PURE__ */ new Map();
71606
71586
  this.colorIndex = 0;
71607
- this.version = "0.11.57";
71587
+ this.version = "0.11.58";
71608
71588
  console.debug("🦋 [superdoc] Using SuperDoc version:", this.version);
71609
71589
  this.superdocId = config.superdocId || v4();
71610
71590
  this.colors = this.config.colors;