@harbour-enterprises/superdoc 1.3.0-next.10 → 1.3.0-next.11

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.
@@ -1,6 +1,6 @@
1
1
  import { d as defineComponent, h, T as Transition, p as process$1, w as watchEffect, c as computed, r as ref, f as onMounted, X as onUnmounted, E as createElementBlock, G as openBlock, K as createBaseVNode, M as createCommentVNode, I as createVNode, v as unref } from "./vue-BnBKJwCW.es.js";
2
- import { N as NBaseLoading, u as useSuperdocStore, s as storeToRefs, a as useSelection } from "./index-yNMvRgm_.es.js";
3
- import { C as derived, r as c, q as cB, aF as fadeInTransition, y as cM, I as warnOnce, J as useConfig, N as useTheme, aG as pxfy, P as createKey, Q as useThemeClass, aH as useCompitable, ai as _export_sfc } from "./index-Bv9MbOsf.es.js";
2
+ import { N as NBaseLoading, u as useSuperdocStore, s as storeToRefs, a as useSelection } from "./index-D2CRfjhH.es.js";
3
+ import { C as derived, r as c, q as cB, aF as fadeInTransition, y as cM, I as warnOnce, J as useConfig, N as useTheme, aG as pxfy, P as createKey, Q as useThemeClass, aH as useCompitable, ai as _export_sfc } from "./index-CE0fU2k7.es.js";
4
4
  function self(vars) {
5
5
  const {
6
6
  opacityDisabled,
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  const vue = require("./vue-De9wkgLl.cjs");
4
- const superdoc = require("./index-D9yb-45i.cjs");
5
- const index = require("./index-B045iT2T.cjs");
4
+ const superdoc = require("./index-CTQjsYpZ.cjs");
5
+ const index = require("./index-BClM7AjD.cjs");
6
6
  function self(vars) {
7
7
  const {
8
8
  opacityDisabled,
@@ -31007,7 +31007,7 @@ class SuperConverter {
31007
31007
  static getStoredSuperdocVersion(docx) {
31008
31008
  return SuperConverter.getStoredCustomProperty(docx, "SuperdocVersion");
31009
31009
  }
31010
- static setStoredSuperdocVersion(docx = this.convertedXml, version = "1.3.0-next.10") {
31010
+ static setStoredSuperdocVersion(docx = this.convertedXml, version = "1.3.0-next.11") {
31011
31011
  return SuperConverter.setStoredCustomProperty(docx, "SuperdocVersion", version, false);
31012
31012
  }
31013
31013
  /**
@@ -31008,7 +31008,7 @@ class SuperConverter {
31008
31008
  static getStoredSuperdocVersion(docx) {
31009
31009
  return SuperConverter.getStoredCustomProperty(docx, "SuperdocVersion");
31010
31010
  }
31011
- static setStoredSuperdocVersion(docx = this.convertedXml, version = "1.3.0-next.10") {
31011
+ static setStoredSuperdocVersion(docx = this.convertedXml, version = "1.3.0-next.11") {
31012
31012
  return SuperConverter.setStoredCustomProperty(docx, "SuperdocVersion", version, false);
31013
31013
  }
31014
31014
  /**
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  const jszip = require("./jszip-C8_CqJxM.cjs");
3
3
  const helpers$1 = require("./helpers-nOdwpmwb.cjs");
4
- const superEditor_converter = require("./SuperConverter-BIATaPlu.cjs");
4
+ const superEditor_converter = require("./SuperConverter-DgyRPhnD.cjs");
5
5
  const vue = require("./vue-De9wkgLl.cjs");
6
6
  require("./jszip.min-BPh2MMAa.cjs");
7
7
  const eventemitter3 = require("./eventemitter3-BQuRcMPI.cjs");
@@ -15351,7 +15351,7 @@ const canUseDOM = () => {
15351
15351
  return false;
15352
15352
  }
15353
15353
  };
15354
- const summaryVersion = "1.3.0-next.10";
15354
+ const summaryVersion = "1.3.0-next.11";
15355
15355
  const nodeKeys = ["group", "content", "marks", "inline", "atom", "defining", "code", "tableRole", "summary"];
15356
15356
  const markKeys = ["group", "inclusive", "excludes", "spanning", "code"];
15357
15357
  function mapAttributes(attrs) {
@@ -17984,7 +17984,7 @@ class Editor extends EventEmitter {
17984
17984
  * Process collaboration migrations
17985
17985
  */
17986
17986
  processCollaborationMigrations() {
17987
- console.debug("[checkVersionMigrations] Current editor version", "1.3.0-next.10");
17987
+ console.debug("[checkVersionMigrations] Current editor version", "1.3.0-next.11");
17988
17988
  if (!this.options.ydoc) return;
17989
17989
  const metaMap = this.options.ydoc.getMap("meta");
17990
17990
  let docVersion = metaMap.get("version");
@@ -40283,6 +40283,13 @@ const applyTrackedChangesModeToRuns = (runs, config, hyperlinkConfig, applyMarks
40283
40283
  );
40284
40284
  }
40285
40285
  });
40286
+ if ((config.mode === "original" || config.mode === "final") && config.enabled) {
40287
+ filtered.forEach((run) => {
40288
+ if (isTextRun$1(run) && run.trackedChange && (run.trackedChange.kind === "insert" || run.trackedChange.kind === "delete")) {
40289
+ delete run.trackedChange;
40290
+ }
40291
+ });
40292
+ }
40286
40293
  }
40287
40294
  return filtered;
40288
40295
  };
@@ -50771,9 +50778,10 @@ class PresentationEditor extends EventEmitter {
50771
50778
  throw new TypeError("[PresentationEditor] setTrackedChangesOverrides expects an object or undefined");
50772
50779
  }
50773
50780
  if (overrides !== void 0) {
50774
- if (overrides.mode !== void 0 && !["review", "simple", "original"].includes(overrides.mode)) {
50781
+ const validModes = ["review", "original", "final", "off"];
50782
+ if (overrides.mode !== void 0 && !validModes.includes(overrides.mode)) {
50775
50783
  throw new TypeError(
50776
- `[PresentationEditor] Invalid tracked changes mode "${overrides.mode}". Must be one of: review, simple, original`
50784
+ `[PresentationEditor] Invalid tracked changes mode "${overrides.mode}". Must be one of: ${validModes.join(", ")}`
50777
50785
  );
50778
50786
  }
50779
50787
  if (overrides.enabled !== void 0 && typeof overrides.enabled !== "boolean") {
@@ -1,6 +1,6 @@
1
1
  import { B as Buffer$2 } from "./jszip-B1fkPkPJ.es.js";
2
2
  import { t as twipsToInches, i as inchesToTwips, p as ptToTwips, l as linesToTwips, a as twipsToLines, b as pixelsToTwips, h as halfPointToPoints, c as twipsToPixels$2, d as convertSizeToCSS, e as inchesToPixels } from "./helpers-C8e9wR5l.es.js";
3
- import { g as generateDocxRandomId, T as TextSelection$1, o as objectIncludes, w as wrapTextsInRuns, D as DOMParser$1, c as createDocFromMarkdown, a as createDocFromHTML, b as chainableEditorState, d as convertMarkdownToHTML, f as findParentNode, e as findParentNodeClosestToPos, h as generateRandom32BitHex, i as generateRandomSigned32BitIntStrId, P as PluginKey, j as Plugin, M as Mapping, N as NodeSelection, k as Selection, l as Slice, m as DOMSerializer, F as Fragment, n as Mark$1, p as dropPoint, A as AllSelection, q as Schema$1, s as canSplit, t as resolveRunProperties, u as encodeMarksFromRPr, v as liftTarget, x as canJoin, y as joinPoint, z as replaceStep$1, R as ReplaceAroundStep$1, B as htmlHandler, C as ReplaceStep, E as getResolvedParagraphProperties, G as changeListLevel, H as isList$1, I as updateNumberingProperties, L as ListHelpers, J as inputRulesPlugin, K as TrackDeleteMarkName$1, O as TrackInsertMarkName$1, Q as TrackFormatMarkName$1, U as AddMarkStep, V as RemoveMarkStep, W as CommandService, S as SuperConverter, X as EditorState, Y as unflattenListsInHtml, Z as SelectionRange, _ as Transform, $ as createOoxmlResolver, a0 as translator, a1 as translator$1, a2 as resolveDocxFontFamily, a3 as _getReferencedTableStyles, a4 as decodeRPrFromMarks, a5 as calculateResolvedParagraphProperties, a6 as encodeCSSFromPPr, a7 as encodeCSSFromRPr, a8 as generateOrderedListIndex, a9 as docxNumberingHelpers, aa as InputRule, ab as insertNewRelationship, ac as kebabCase$1, ad as getUnderlineCssString } from "./SuperConverter-BO5wIcsr.es.js";
3
+ import { g as generateDocxRandomId, T as TextSelection$1, o as objectIncludes, w as wrapTextsInRuns, D as DOMParser$1, c as createDocFromMarkdown, a as createDocFromHTML, b as chainableEditorState, d as convertMarkdownToHTML, f as findParentNode, e as findParentNodeClosestToPos, h as generateRandom32BitHex, i as generateRandomSigned32BitIntStrId, P as PluginKey, j as Plugin, M as Mapping, N as NodeSelection, k as Selection, l as Slice, m as DOMSerializer, F as Fragment, n as Mark$1, p as dropPoint, A as AllSelection, q as Schema$1, s as canSplit, t as resolveRunProperties, u as encodeMarksFromRPr, v as liftTarget, x as canJoin, y as joinPoint, z as replaceStep$1, R as ReplaceAroundStep$1, B as htmlHandler, C as ReplaceStep, E as getResolvedParagraphProperties, G as changeListLevel, H as isList$1, I as updateNumberingProperties, L as ListHelpers, J as inputRulesPlugin, K as TrackDeleteMarkName$1, O as TrackInsertMarkName$1, Q as TrackFormatMarkName$1, U as AddMarkStep, V as RemoveMarkStep, W as CommandService, S as SuperConverter, X as EditorState, Y as unflattenListsInHtml, Z as SelectionRange, _ as Transform, $ as createOoxmlResolver, a0 as translator, a1 as translator$1, a2 as resolveDocxFontFamily, a3 as _getReferencedTableStyles, a4 as decodeRPrFromMarks, a5 as calculateResolvedParagraphProperties, a6 as encodeCSSFromPPr, a7 as encodeCSSFromRPr, a8 as generateOrderedListIndex, a9 as docxNumberingHelpers, aa as InputRule, ab as insertNewRelationship, ac as kebabCase$1, ad as getUnderlineCssString } from "./SuperConverter-Caxoktb7.es.js";
4
4
  import { p as process$1, r as ref, C as global$1, c as computed, E as createElementBlock, F as Fragment$1, S as renderList, O as withModifiers, G as openBlock, P as normalizeClass, M as createCommentVNode, H as toDisplayString, K as createBaseVNode, U as createApp, f as onMounted, X as onUnmounted, R as withDirectives, v as unref, Y as vModelText, y as nextTick, L as normalizeStyle, u as watch, Z as withKeys, _ as createTextVNode, I as createVNode, h, $ as readonly, s as getCurrentInstance, o as onBeforeUnmount, j as reactive, b as onBeforeMount, i as inject, a0 as onActivated, a1 as onDeactivated, a2 as Comment, d as defineComponent, a as provide, g as Teleport, t as toRef, a3 as renderSlot, a4 as isVNode, D as shallowRef, w as watchEffect, T as Transition, a5 as mergeProps, a6 as vShow, a7 as cloneVNode, a8 as Text$2, m as markRaw, N as createBlock, J as withCtx, a9 as useCssVars, V as resolveDynamicComponent, aa as normalizeProps, ab as guardReactiveProps } from "./vue-BnBKJwCW.es.js";
5
5
  import "./jszip.min-DCl8qkFO.es.js";
6
6
  import { E as EventEmitter$1 } from "./eventemitter3-CwrdEv8r.es.js";
@@ -15334,7 +15334,7 @@ const canUseDOM = () => {
15334
15334
  return false;
15335
15335
  }
15336
15336
  };
15337
- const summaryVersion = "1.3.0-next.10";
15337
+ const summaryVersion = "1.3.0-next.11";
15338
15338
  const nodeKeys = ["group", "content", "marks", "inline", "atom", "defining", "code", "tableRole", "summary"];
15339
15339
  const markKeys = ["group", "inclusive", "excludes", "spanning", "code"];
15340
15340
  function mapAttributes(attrs) {
@@ -17967,7 +17967,7 @@ class Editor extends EventEmitter {
17967
17967
  * Process collaboration migrations
17968
17968
  */
17969
17969
  processCollaborationMigrations() {
17970
- console.debug("[checkVersionMigrations] Current editor version", "1.3.0-next.10");
17970
+ console.debug("[checkVersionMigrations] Current editor version", "1.3.0-next.11");
17971
17971
  if (!this.options.ydoc) return;
17972
17972
  const metaMap = this.options.ydoc.getMap("meta");
17973
17973
  let docVersion = metaMap.get("version");
@@ -40266,6 +40266,13 @@ const applyTrackedChangesModeToRuns = (runs, config, hyperlinkConfig, applyMarks
40266
40266
  );
40267
40267
  }
40268
40268
  });
40269
+ if ((config.mode === "original" || config.mode === "final") && config.enabled) {
40270
+ filtered.forEach((run) => {
40271
+ if (isTextRun$1(run) && run.trackedChange && (run.trackedChange.kind === "insert" || run.trackedChange.kind === "delete")) {
40272
+ delete run.trackedChange;
40273
+ }
40274
+ });
40275
+ }
40269
40276
  }
40270
40277
  return filtered;
40271
40278
  };
@@ -50754,9 +50761,10 @@ class PresentationEditor extends EventEmitter {
50754
50761
  throw new TypeError("[PresentationEditor] setTrackedChangesOverrides expects an object or undefined");
50755
50762
  }
50756
50763
  if (overrides !== void 0) {
50757
- if (overrides.mode !== void 0 && !["review", "simple", "original"].includes(overrides.mode)) {
50764
+ const validModes = ["review", "original", "final", "off"];
50765
+ if (overrides.mode !== void 0 && !validModes.includes(overrides.mode)) {
50758
50766
  throw new TypeError(
50759
- `[PresentationEditor] Invalid tracked changes mode "${overrides.mode}". Must be one of: review, simple, original`
50767
+ `[PresentationEditor] Invalid tracked changes mode "${overrides.mode}". Must be one of: ${validModes.join(", ")}`
50760
50768
  );
50761
50769
  }
50762
50770
  if (overrides.enabled !== void 0 && typeof overrides.enabled !== "boolean") {
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
- const index = require("./index-B045iT2T.cjs");
3
- require("./SuperConverter-BIATaPlu.cjs");
2
+ const index = require("./index-BClM7AjD.cjs");
3
+ require("./SuperConverter-DgyRPhnD.cjs");
4
4
  const blankDocx = require("./blank-docx-DfW3Eeh2.cjs");
5
5
  const eventemitter3 = require("./eventemitter3-BQuRcMPI.cjs");
6
6
  const provider = require("@hocuspocus/provider");
@@ -7465,7 +7465,7 @@ const _sfc_main = {
7465
7465
  __name: "SuperDoc",
7466
7466
  emits: ["selection-update"],
7467
7467
  setup(__props, { emit: __emit }) {
7468
- const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-BBQ-ukct.cjs")));
7468
+ const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-DxthqP0q.cjs")));
7469
7469
  const superdocStore = useSuperdocStore();
7470
7470
  const commentsStore = useCommentsStore();
7471
7471
  const {
@@ -8371,7 +8371,7 @@ class SuperDoc extends eventemitter3.EventEmitter {
8371
8371
  this.config.colors = shuffleArray(this.config.colors);
8372
8372
  this.userColorMap = /* @__PURE__ */ new Map();
8373
8373
  this.colorIndex = 0;
8374
- this.version = "1.3.0-next.10";
8374
+ this.version = "1.3.0-next.11";
8375
8375
  this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
8376
8376
  this.superdocId = config.superdocId || uuid.v4();
8377
8377
  this.colors = this.config.colors;
@@ -1,5 +1,5 @@
1
- import { B as BIT8, M as MAX_SAFE_INTEGER, c as create, a as BITS7, u as utf8TextDecoder, b as create$1, s as setIfUndefined, d as create$2, f as from, e as floor$1, g as equalityDeep, w as writeVarUint, h as writeVarString, t as toUint8Array, i as createEncoder, j as createInjectionKey, k as toString, l as throwError, m as useSsrAdapter, n as configProviderInjectionKey, o as cssrAnchorMetaName, p as globalStyle, q as cB, r as c, v as isMounted, x as commonVariables$2, y as cM, z as cNotM, A as cE, C as derived, D as changeColor, E as insideModal, F as insidePopover, G as resolveWrappedSlot, H as on, I as warnOnce, J as useConfig, K as useMergedState, L as useMemo, N as useTheme, O as useRtl, P as createKey, Q as useThemeClass, R as createId, S as call, T as render, U as messageProviderInjectionKey, V as messageApiInjectionKey, W as fromBase64, X as onChange, Y as varStorage, Z as toBase64, _ as createUint8ArrayFromArrayBuffer, $ as offChange, a0 as writeVarUint8Array, a1 as map, a2 as length, a3 as isNode, a4 as min, a5 as pow, a6 as comments_module_events, a7 as getFileObject, a8 as getTrackChanges, a9 as CommentsPluginKey, aa as TrackChangesBasePluginKey, ab as Editor, ac as getRichTextExtensions, ad as ellipsisVerticalSvg, ae as xmarkIconSvg, af as checkIconSvg, ag as caretDownIconSvg, ah as commentIconSvg, ai as _export_sfc, aj as NDropdown, ak as SuperInput, al as vClickOutside, am as PresentationEditor, an as SuperEditor, ao as AIWriter, ap as NConfigProvider, aq as SuperToolbar } from "./index-Bv9MbOsf.es.js";
2
- import "./SuperConverter-BO5wIcsr.es.js";
1
+ import { B as BIT8, M as MAX_SAFE_INTEGER, c as create, a as BITS7, u as utf8TextDecoder, b as create$1, s as setIfUndefined, d as create$2, f as from, e as floor$1, g as equalityDeep, w as writeVarUint, h as writeVarString, t as toUint8Array, i as createEncoder, j as createInjectionKey, k as toString, l as throwError, m as useSsrAdapter, n as configProviderInjectionKey, o as cssrAnchorMetaName, p as globalStyle, q as cB, r as c, v as isMounted, x as commonVariables$2, y as cM, z as cNotM, A as cE, C as derived, D as changeColor, E as insideModal, F as insidePopover, G as resolveWrappedSlot, H as on, I as warnOnce, J as useConfig, K as useMergedState, L as useMemo, N as useTheme, O as useRtl, P as createKey, Q as useThemeClass, R as createId, S as call, T as render, U as messageProviderInjectionKey, V as messageApiInjectionKey, W as fromBase64, X as onChange, Y as varStorage, Z as toBase64, _ as createUint8ArrayFromArrayBuffer, $ as offChange, a0 as writeVarUint8Array, a1 as map, a2 as length, a3 as isNode, a4 as min, a5 as pow, a6 as comments_module_events, a7 as getFileObject, a8 as getTrackChanges, a9 as CommentsPluginKey, aa as TrackChangesBasePluginKey, ab as Editor, ac as getRichTextExtensions, ad as ellipsisVerticalSvg, ae as xmarkIconSvg, af as checkIconSvg, ag as caretDownIconSvg, ah as commentIconSvg, ai as _export_sfc, aj as NDropdown, ak as SuperInput, al as vClickOutside, am as PresentationEditor, an as SuperEditor, ao as AIWriter, ap as NConfigProvider, aq as SuperToolbar } from "./index-CE0fU2k7.es.js";
2
+ import "./SuperConverter-Caxoktb7.es.js";
3
3
  import { B as BlankDOCX } from "./blank-docx-ABm6XYAA.es.js";
4
4
  import { E as EventEmitter } from "./eventemitter3-CwrdEv8r.es.js";
5
5
  import { HocuspocusProvider, HocuspocusProviderWebsocket } from "@hocuspocus/provider";
@@ -7448,7 +7448,7 @@ const _sfc_main = {
7448
7448
  __name: "SuperDoc",
7449
7449
  emits: ["selection-update"],
7450
7450
  setup(__props, { emit: __emit }) {
7451
- const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-CgwCQZZ6.es.js"));
7451
+ const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-Dsxwbxdh.es.js"));
7452
7452
  const superdocStore = useSuperdocStore();
7453
7453
  const commentsStore = useCommentsStore();
7454
7454
  const {
@@ -8354,7 +8354,7 @@ class SuperDoc extends EventEmitter {
8354
8354
  this.config.colors = shuffleArray(this.config.colors);
8355
8355
  this.userColorMap = /* @__PURE__ */ new Map();
8356
8356
  this.colorIndex = 0;
8357
- this.version = "1.3.0-next.10";
8357
+ this.version = "1.3.0-next.11";
8358
8358
  this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
8359
8359
  this.superdocId = config.superdocId || v4();
8360
8360
  this.colors = this.config.colors;
@@ -2,6 +2,6 @@
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
3
  require("../chunks/jszip-C8_CqJxM.cjs");
4
4
  require("../chunks/helpers-nOdwpmwb.cjs");
5
- const superEditor_converter = require("../chunks/SuperConverter-BIATaPlu.cjs");
5
+ const superEditor_converter = require("../chunks/SuperConverter-DgyRPhnD.cjs");
6
6
  require("../chunks/uuid-R7L08bOx.cjs");
7
7
  exports.SuperConverter = superEditor_converter.SuperConverter;
@@ -1,6 +1,6 @@
1
1
  import "../chunks/jszip-B1fkPkPJ.es.js";
2
2
  import "../chunks/helpers-C8e9wR5l.es.js";
3
- import { S } from "../chunks/SuperConverter-BO5wIcsr.es.js";
3
+ import { S } from "../chunks/SuperConverter-Caxoktb7.es.js";
4
4
  import "../chunks/uuid-CjlX8hrF.es.js";
5
5
  export {
6
6
  S as SuperConverter
@@ -1,10 +1,10 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const index = require("./chunks/index-B045iT2T.cjs");
3
+ const index = require("./chunks/index-BClM7AjD.cjs");
4
4
  const superEditor_docxZipper = require("./super-editor/docx-zipper.cjs");
5
5
  const superEditor_fileZipper = require("./super-editor/file-zipper.cjs");
6
6
  const vue = require("./chunks/vue-De9wkgLl.cjs");
7
- const superEditor_converter = require("./chunks/SuperConverter-BIATaPlu.cjs");
7
+ const superEditor_converter = require("./chunks/SuperConverter-DgyRPhnD.cjs");
8
8
  function isNodeType(node, name) {
9
9
  return node.type.name === name;
10
10
  }
@@ -1,9 +1,9 @@
1
- import { ax as Node, ay as Mark } from "./chunks/index-Bv9MbOsf.es.js";
2
- import { ao, au, a9, ab, aw, am, av, aA, an, ak, aq, az, aa, as, aC, aE, aB, ac, aD, ar, at } from "./chunks/index-Bv9MbOsf.es.js";
1
+ import { ax as Node, ay as Mark } from "./chunks/index-CE0fU2k7.es.js";
2
+ import { ao, au, a9, ab, aw, am, av, aA, an, ak, aq, az, aa, as, aC, aE, aB, ac, aD, ar, at } from "./chunks/index-CE0fU2k7.es.js";
3
3
  import { default as default2 } from "./super-editor/docx-zipper.es.js";
4
4
  import { createZip } from "./super-editor/file-zipper.es.js";
5
5
  import { d as defineComponent, E as createElementBlock, G as openBlock, K as createBaseVNode } from "./chunks/vue-BnBKJwCW.es.js";
6
- import { S, r } from "./chunks/SuperConverter-BO5wIcsr.es.js";
6
+ import { S, r } from "./chunks/SuperConverter-Caxoktb7.es.js";
7
7
  function isNodeType(node, name) {
8
8
  return node.type.name === name;
9
9
  }
package/dist/superdoc.cjs CHANGED
@@ -1,8 +1,8 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const index = require("./chunks/index-B045iT2T.cjs");
4
- const superdoc = require("./chunks/index-D9yb-45i.cjs");
5
- const superEditor_converter = require("./chunks/SuperConverter-BIATaPlu.cjs");
3
+ const index = require("./chunks/index-BClM7AjD.cjs");
4
+ const superdoc = require("./chunks/index-CTQjsYpZ.cjs");
5
+ const superEditor_converter = require("./chunks/SuperConverter-DgyRPhnD.cjs");
6
6
  const blankDocx = require("./chunks/blank-docx-DfW3Eeh2.cjs");
7
7
  require("./chunks/jszip-C8_CqJxM.cjs");
8
8
  require("./chunks/helpers-nOdwpmwb.cjs");
@@ -1,6 +1,6 @@
1
- import { au, ab, aw, av, as, a7, ac, ar, at } from "./chunks/index-Bv9MbOsf.es.js";
2
- import { D, H, P, S, c } from "./chunks/index-yNMvRgm_.es.js";
3
- import { S as S2, r } from "./chunks/SuperConverter-BO5wIcsr.es.js";
1
+ import { au, ab, aw, av, as, a7, ac, ar, at } from "./chunks/index-CE0fU2k7.es.js";
2
+ import { D, H, P, S, c } from "./chunks/index-D2CRfjhH.es.js";
3
+ import { S as S2, r } from "./chunks/SuperConverter-Caxoktb7.es.js";
4
4
  import { B } from "./chunks/blank-docx-ABm6XYAA.es.js";
5
5
  import "./chunks/jszip-B1fkPkPJ.es.js";
6
6
  import "./chunks/helpers-C8e9wR5l.es.js";
@@ -36435,7 +36435,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
36435
36435
  static getStoredSuperdocVersion(docx) {
36436
36436
  return SuperConverter.getStoredCustomProperty(docx, "SuperdocVersion");
36437
36437
  }
36438
- static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "1.3.0-next.10") {
36438
+ static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "1.3.0-next.11") {
36439
36439
  return SuperConverter.setStoredCustomProperty(docx, "SuperdocVersion", version2, false);
36440
36440
  }
36441
36441
  /**
@@ -62145,7 +62145,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
62145
62145
  return false;
62146
62146
  }
62147
62147
  };
62148
- const summaryVersion = "1.3.0-next.10";
62148
+ const summaryVersion = "1.3.0-next.11";
62149
62149
  const nodeKeys = ["group", "content", "marks", "inline", "atom", "defining", "code", "tableRole", "summary"];
62150
62150
  const markKeys = ["group", "inclusive", "excludes", "spanning", "code"];
62151
62151
  function mapAttributes(attrs) {
@@ -64779,7 +64779,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
64779
64779
  * Process collaboration migrations
64780
64780
  */
64781
64781
  processCollaborationMigrations() {
64782
- console.debug("[checkVersionMigrations] Current editor version", "1.3.0-next.10");
64782
+ console.debug("[checkVersionMigrations] Current editor version", "1.3.0-next.11");
64783
64783
  if (!this.options.ydoc) return;
64784
64784
  const metaMap = this.options.ydoc.getMap("meta");
64785
64785
  let docVersion = metaMap.get("version");
@@ -87066,6 +87066,13 @@ ${l}
87066
87066
  );
87067
87067
  }
87068
87068
  });
87069
+ if ((config2.mode === "original" || config2.mode === "final") && config2.enabled) {
87070
+ filtered.forEach((run2) => {
87071
+ if (isTextRun$1(run2) && run2.trackedChange && (run2.trackedChange.kind === "insert" || run2.trackedChange.kind === "delete")) {
87072
+ delete run2.trackedChange;
87073
+ }
87074
+ });
87075
+ }
87069
87076
  }
87070
87077
  return filtered;
87071
87078
  };
@@ -97514,9 +97521,10 @@ ${l}
97514
97521
  throw new TypeError("[PresentationEditor] setTrackedChangesOverrides expects an object or undefined");
97515
97522
  }
97516
97523
  if (overrides !== void 0) {
97517
- if (overrides.mode !== void 0 && !["review", "simple", "original"].includes(overrides.mode)) {
97524
+ const validModes = ["review", "original", "final", "off"];
97525
+ if (overrides.mode !== void 0 && !validModes.includes(overrides.mode)) {
97518
97526
  throw new TypeError(
97519
- `[PresentationEditor] Invalid tracked changes mode "${overrides.mode}". Must be one of: review, simple, original`
97527
+ `[PresentationEditor] Invalid tracked changes mode "${overrides.mode}". Must be one of: ${validModes.join(", ")}`
97520
97528
  );
97521
97529
  }
97522
97530
  if (overrides.enabled !== void 0 && typeof overrides.enabled !== "boolean") {
@@ -144178,7 +144186,7 @@ ${reason}`);
144178
144186
  this.config.colors = shuffleArray(this.config.colors);
144179
144187
  this.userColorMap = /* @__PURE__ */ new Map();
144180
144188
  this.colorIndex = 0;
144181
- this.version = "1.3.0-next.10";
144189
+ this.version = "1.3.0-next.11";
144182
144190
  this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
144183
144191
  this.superdocId = config2.superdocId || v4();
144184
144192
  this.colors = this.config.colors;