@harbour-enterprises/superdoc 0.13.2 → 0.13.3-next.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18875,13 +18875,13 @@ function exportSchemaToJson(params2) {
18875
18875
  function translateBodyNode(params2) {
18876
18876
  let sectPr = params2.bodyNode?.elements.find((n) => n.name === "w:sectPr") || {};
18877
18877
  if (params2.converter) {
18878
- const hasHeader = sectPr.elements.some((n) => n.name === "w:headerReference");
18878
+ const hasHeader = sectPr?.elements?.some((n) => n.name === "w:headerReference");
18879
18879
  const hasDefaultHeader = params2.converter.headerIds?.default;
18880
18880
  if (!hasHeader && hasDefaultHeader && !params2.editor.options.isHeaderOrFooter) {
18881
18881
  const defaultHeader = generateDefaultHeaderFooter("header", params2.converter.headerIds?.default);
18882
18882
  sectPr.elements.push(defaultHeader);
18883
18883
  }
18884
- const hasFooter = sectPr.elements.some((n) => n.name === "w:footerReference");
18884
+ const hasFooter = sectPr?.elements?.some((n) => n.name === "w:footerReference");
18885
18885
  const hasDefaultFooter = params2.converter.footerIds?.default;
18886
18886
  if (!hasFooter && hasDefaultFooter && !params2.editor.options.isHeaderOrFooter) {
18887
18887
  const defaultFooter = generateDefaultHeaderFooter("footer", params2.converter.footerIds?.default);
@@ -23241,7 +23241,7 @@ function addDefaultStylesIfMissing(styles) {
23241
23241
  });
23242
23242
  return updatedStyles;
23243
23243
  }
23244
- const importHeadersFooters = (docx, converter, editor) => {
23244
+ const importHeadersFooters = (docx, converter, mainEditor) => {
23245
23245
  const rels = docx["word/_rels/document.xml.rels"];
23246
23246
  const relationships = rels.elements.find((el) => el.name === "Relationships");
23247
23247
  const { elements } = relationships;
@@ -23251,6 +23251,9 @@ const importHeadersFooters = (docx, converter, editor) => {
23251
23251
  const footers = elements.filter((el) => el.attributes["Type"] === footerType);
23252
23252
  const sectPr = findSectPr(docx["word/document.xml"]) || [];
23253
23253
  const allSectPrElements = sectPr.flatMap((el) => el.elements);
23254
+ if (!mainEditor) return;
23255
+ const editor = { ...mainEditor };
23256
+ editor.options.annotations = true;
23254
23257
  headers.forEach((header) => {
23255
23258
  const { rId, referenceFile, currentFileName } = getHeaderFooterSectionData(header, docx);
23256
23259
  const sectPrHeader = allSectPrElements.find((el) => el.name === "w:headerReference" && el.attributes["r:id"] === rId);
@@ -23410,7 +23413,7 @@ const _SuperConverter = class _SuperConverter2 {
23410
23413
  return;
23411
23414
  }
23412
23415
  }
23413
- static updateDocumentVersion(docx = this.convertedXml, version2 = "0.13.2") {
23416
+ static updateDocumentVersion(docx = this.convertedXml, version2 = "0.13.3-next.2") {
23414
23417
  const customLocation = "docProps/custom.xml";
23415
23418
  if (!docx[customLocation]) {
23416
23419
  docx[customLocation] = generateCustomXml();
@@ -23877,7 +23880,7 @@ function storeSuperdocVersion(docx) {
23877
23880
  function generateCustomXml() {
23878
23881
  return DEFAULT_CUSTOM_XML;
23879
23882
  }
23880
- function generateSuperdocVersion(pid = 2, version2 = "0.13.2") {
23883
+ function generateSuperdocVersion(pid = 2, version2 = "0.13.3-next.2") {
23881
23884
  return {
23882
23885
  type: "element",
23883
23886
  name: "property",
@@ -41257,7 +41260,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
41257
41260
  * @returns {Object | void} Migration results
41258
41261
  */
41259
41262
  processCollaborationMigrations() {
41260
- console.debug("[checkVersionMigrations] Current editor version", "0.13.2");
41263
+ console.debug("[checkVersionMigrations] Current editor version", "0.13.3-next.2");
41261
41264
  if (!this.options.ydoc) return;
41262
41265
  const metaMap = this.options.ydoc.getMap("meta");
41263
41266
  let docVersion = metaMap.get("version");
@@ -41301,6 +41304,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
41301
41304
  __privateMethod$1(this, _Editor_instances, initMedia_fn).call(this);
41302
41305
  this.initDefaultStyles();
41303
41306
  if (this.options.ydoc && this.options.collaborationProvider) {
41307
+ updateYdocDocxData(this);
41304
41308
  this.initializeCollaborationData(true);
41305
41309
  } else {
41306
41310
  __privateMethod$1(this, _Editor_instances, insertNewFileData_fn).call(this);
@@ -18858,13 +18858,13 @@ function exportSchemaToJson(params2) {
18858
18858
  function translateBodyNode(params2) {
18859
18859
  let sectPr = params2.bodyNode?.elements.find((n) => n.name === "w:sectPr") || {};
18860
18860
  if (params2.converter) {
18861
- const hasHeader = sectPr.elements.some((n) => n.name === "w:headerReference");
18861
+ const hasHeader = sectPr?.elements?.some((n) => n.name === "w:headerReference");
18862
18862
  const hasDefaultHeader = params2.converter.headerIds?.default;
18863
18863
  if (!hasHeader && hasDefaultHeader && !params2.editor.options.isHeaderOrFooter) {
18864
18864
  const defaultHeader = generateDefaultHeaderFooter("header", params2.converter.headerIds?.default);
18865
18865
  sectPr.elements.push(defaultHeader);
18866
18866
  }
18867
- const hasFooter = sectPr.elements.some((n) => n.name === "w:footerReference");
18867
+ const hasFooter = sectPr?.elements?.some((n) => n.name === "w:footerReference");
18868
18868
  const hasDefaultFooter = params2.converter.footerIds?.default;
18869
18869
  if (!hasFooter && hasDefaultFooter && !params2.editor.options.isHeaderOrFooter) {
18870
18870
  const defaultFooter = generateDefaultHeaderFooter("footer", params2.converter.footerIds?.default);
@@ -23224,7 +23224,7 @@ function addDefaultStylesIfMissing(styles) {
23224
23224
  });
23225
23225
  return updatedStyles;
23226
23226
  }
23227
- const importHeadersFooters = (docx, converter, editor) => {
23227
+ const importHeadersFooters = (docx, converter, mainEditor) => {
23228
23228
  const rels = docx["word/_rels/document.xml.rels"];
23229
23229
  const relationships = rels.elements.find((el) => el.name === "Relationships");
23230
23230
  const { elements } = relationships;
@@ -23234,6 +23234,9 @@ const importHeadersFooters = (docx, converter, editor) => {
23234
23234
  const footers = elements.filter((el) => el.attributes["Type"] === footerType);
23235
23235
  const sectPr = findSectPr(docx["word/document.xml"]) || [];
23236
23236
  const allSectPrElements = sectPr.flatMap((el) => el.elements);
23237
+ if (!mainEditor) return;
23238
+ const editor = { ...mainEditor };
23239
+ editor.options.annotations = true;
23237
23240
  headers.forEach((header) => {
23238
23241
  const { rId, referenceFile, currentFileName } = getHeaderFooterSectionData(header, docx);
23239
23242
  const sectPrHeader = allSectPrElements.find((el) => el.name === "w:headerReference" && el.attributes["r:id"] === rId);
@@ -23393,7 +23396,7 @@ const _SuperConverter = class _SuperConverter2 {
23393
23396
  return;
23394
23397
  }
23395
23398
  }
23396
- static updateDocumentVersion(docx = this.convertedXml, version2 = "0.13.2") {
23399
+ static updateDocumentVersion(docx = this.convertedXml, version2 = "0.13.3-next.2") {
23397
23400
  const customLocation = "docProps/custom.xml";
23398
23401
  if (!docx[customLocation]) {
23399
23402
  docx[customLocation] = generateCustomXml();
@@ -23860,7 +23863,7 @@ function storeSuperdocVersion(docx) {
23860
23863
  function generateCustomXml() {
23861
23864
  return DEFAULT_CUSTOM_XML;
23862
23865
  }
23863
- function generateSuperdocVersion(pid = 2, version2 = "0.13.2") {
23866
+ function generateSuperdocVersion(pid = 2, version2 = "0.13.3-next.2") {
23864
23867
  return {
23865
23868
  type: "element",
23866
23869
  name: "property",
@@ -41240,7 +41243,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
41240
41243
  * @returns {Object | void} Migration results
41241
41244
  */
41242
41245
  processCollaborationMigrations() {
41243
- console.debug("[checkVersionMigrations] Current editor version", "0.13.2");
41246
+ console.debug("[checkVersionMigrations] Current editor version", "0.13.3-next.2");
41244
41247
  if (!this.options.ydoc) return;
41245
41248
  const metaMap = this.options.ydoc.getMap("meta");
41246
41249
  let docVersion = metaMap.get("version");
@@ -41284,6 +41287,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
41284
41287
  __privateMethod$1(this, _Editor_instances, initMedia_fn).call(this);
41285
41288
  this.initDefaultStyles();
41286
41289
  if (this.options.ydoc && this.options.collaborationProvider) {
41290
+ updateYdocDocxData(this);
41287
41291
  this.initializeCollaborationData(true);
41288
41292
  } else {
41289
41293
  __privateMethod$1(this, _Editor_instances, insertNewFileData_fn).call(this);
package/dist/style.css CHANGED
@@ -626,6 +626,8 @@ https://github.com/ProseMirror/prosemirror-tables/blob/master/demo/index.html
626
626
 
627
627
  overflow-x: auto;
628
628
  scrollbar-width: thin;
629
+ overflow: hidden;
630
+
629
631
  /*
630
632
  The border width does not need to be multiplied by two,
631
633
  for tables it works differently. */
@@ -635,7 +637,6 @@ https://github.com/ProseMirror/prosemirror-tables/blob/master/demo/index.html
635
637
  border-collapse: collapse;
636
638
  border-spacing: 0;
637
639
  table-layout: fixed;
638
- overflow: hidden;
639
640
  margin: 0;
640
641
  /* width: 100%; */
641
642
  }
@@ -1,6 +1,6 @@
1
1
  import { ref, onMounted, onUnmounted, computed, createElementBlock, openBlock, withModifiers, createElementVNode, withDirectives, unref, vModelText, createCommentVNode, nextTick } from "vue";
2
- import { T as TextSelection } from "./chunks/converter-CsK9KCaL.js";
3
- import { _ as _export_sfc } from "./chunks/editor-Cxb-Zwyu.js";
2
+ import { T as TextSelection } from "./chunks/converter-iJixg7yb.js";
3
+ import { _ as _export_sfc } from "./chunks/editor-0NJKUWk3.js";
4
4
  const DEFAULT_API_ENDPOINT = "https://sd-dev-express-gateway-i6xtm.ondigitalocean.app/insights";
5
5
  const SYSTEM_PROMPT = "You are an expert copywriter and you are immersed in a document editor. You are to provide document related text responses based on the user prompts. Only write what is asked for. Do not provide explanations. Try to keep placeholders as short as possible. Do not output your prompt. Your instructions are: ";
6
6
  async function baseInsightsFetch(payload, options = {}) {
@@ -18877,13 +18877,13 @@ function exportSchemaToJson(params) {
18877
18877
  function translateBodyNode(params) {
18878
18878
  let sectPr = params.bodyNode?.elements.find((n) => n.name === "w:sectPr") || {};
18879
18879
  if (params.converter) {
18880
- const hasHeader = sectPr.elements.some((n) => n.name === "w:headerReference");
18880
+ const hasHeader = sectPr?.elements?.some((n) => n.name === "w:headerReference");
18881
18881
  const hasDefaultHeader = params.converter.headerIds?.default;
18882
18882
  if (!hasHeader && hasDefaultHeader && !params.editor.options.isHeaderOrFooter) {
18883
18883
  const defaultHeader = generateDefaultHeaderFooter("header", params.converter.headerIds?.default);
18884
18884
  sectPr.elements.push(defaultHeader);
18885
18885
  }
18886
- const hasFooter = sectPr.elements.some((n) => n.name === "w:footerReference");
18886
+ const hasFooter = sectPr?.elements?.some((n) => n.name === "w:footerReference");
18887
18887
  const hasDefaultFooter = params.converter.footerIds?.default;
18888
18888
  if (!hasFooter && hasDefaultFooter && !params.editor.options.isHeaderOrFooter) {
18889
18889
  const defaultFooter = generateDefaultHeaderFooter("footer", params.converter.footerIds?.default);
@@ -23243,7 +23243,7 @@ function addDefaultStylesIfMissing(styles) {
23243
23243
  });
23244
23244
  return updatedStyles;
23245
23245
  }
23246
- const importHeadersFooters = (docx, converter, editor) => {
23246
+ const importHeadersFooters = (docx, converter, mainEditor) => {
23247
23247
  const rels = docx["word/_rels/document.xml.rels"];
23248
23248
  const relationships = rels.elements.find((el) => el.name === "Relationships");
23249
23249
  const { elements } = relationships;
@@ -23253,6 +23253,9 @@ const importHeadersFooters = (docx, converter, editor) => {
23253
23253
  const footers = elements.filter((el) => el.attributes["Type"] === footerType);
23254
23254
  const sectPr = findSectPr(docx["word/document.xml"]) || [];
23255
23255
  const allSectPrElements = sectPr.flatMap((el) => el.elements);
23256
+ if (!mainEditor) return;
23257
+ const editor = { ...mainEditor };
23258
+ editor.options.annotations = true;
23256
23259
  headers.forEach((header) => {
23257
23260
  const { rId, referenceFile, currentFileName } = getHeaderFooterSectionData(header, docx);
23258
23261
  const sectPrHeader = allSectPrElements.find((el) => el.name === "w:headerReference" && el.attributes["r:id"] === rId);
@@ -23412,7 +23415,7 @@ const _SuperConverter = class _SuperConverter {
23412
23415
  return;
23413
23416
  }
23414
23417
  }
23415
- static updateDocumentVersion(docx = this.convertedXml, version = "0.13.2") {
23418
+ static updateDocumentVersion(docx = this.convertedXml, version = "0.13.3-next.2") {
23416
23419
  const customLocation = "docProps/custom.xml";
23417
23420
  if (!docx[customLocation]) {
23418
23421
  docx[customLocation] = generateCustomXml();
@@ -23882,7 +23885,7 @@ function storeSuperdocVersion(docx) {
23882
23885
  function generateCustomXml() {
23883
23886
  return DEFAULT_CUSTOM_XML;
23884
23887
  }
23885
- function generateSuperdocVersion(pid = 2, version = "0.13.2") {
23888
+ function generateSuperdocVersion(pid = 2, version = "0.13.3-next.2") {
23886
23889
  return {
23887
23890
  type: "element",
23888
23891
  name: "property",
@@ -1,4 +1,4 @@
1
- import { x as process$1, a1 as commonjsGlobal, B as Buffer, a2 as getDefaultExportFromCjs, a3 as getContentTypesFromXml, a4 as xmljs } from "./converter-CsK9KCaL.js";
1
+ import { x as process$1, a1 as commonjsGlobal, B as Buffer, a2 as getDefaultExportFromCjs, a3 as getContentTypesFromXml, a4 as xmljs } from "./converter-iJixg7yb.js";
2
2
  function commonjsRequire(path) {
3
3
  throw new Error('Could not dynamically require "' + path + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
4
4
  }
@@ -12,9 +12,9 @@ var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "acce
12
12
  var _Attribute_static, getGlobalAttributes_fn, getNodeAndMarksAttributes_fn, _Schema_static, createNodesSchema_fn, createMarksSchema_fn, _events, _ExtensionService_instances, setupExtensions_fn, attachEditorEvents_fn, _commandService, _css, _Editor_instances, initContainerElement_fn, init_fn, initRichText_fn, onFocus_fn, checkHeadless_fn, insertNewFileData_fn, registerPluginByNameIfNotExists_fn, createExtensionService_fn, createCommandService_fn, createConverter_fn, initMedia_fn, initFonts_fn, createSchema_fn, generatePmData_fn, createDocFromHTML_fn, createView_fn, onCollaborationReady_fn, initComments_fn, initPagination_fn, dispatchTransaction_fn, prepareDocumentForImport_fn, prepareDocumentForExport_fn, endCollaboration_fn, _FieldAnnotationView_instances, createAnnotation_fn, _AutoPageNumberNodeView_instances, renderDom_fn, scheduleUpdateNodeStyle_fn;
13
13
  import * as Y from "yjs";
14
14
  import { UndoManager, Item as Item$1, ContentType, Text as Text$1, XmlElement, encodeStateAsUpdate } from "yjs";
15
- import { P as PluginKey, a as Plugin, M as Mapping, c as callOrGet, i as isEmptyObject, S as Schema$1, T as TextSelection, b as canSplit, l as liftTarget, A as AllSelection, d as canJoin, j as joinPoint, N as NodeSelection, r as replaceStep$1, e as Selection, F as Fragment, R as ReplaceAroundStep, f as Slice, o as objectIncludes, g as deleteProps, D as DOMParser$1, h as ReplaceStep, k as NodeRange, m as findWrapping, n as isMacOS, p as isIOS, q as generateDocxRandomId, s as minMax, t as generateRandom32BitHex, u as DOMSerializer, v as Mark$1, w as dropPoint, x as process$1, B as Buffer2, y as isRegExp, z as TrackDeleteMarkName, C as TrackInsertMarkName, E as v4, G as TrackFormatMarkName, H as comments_module_events, I as AddMarkStep, J as RemoveMarkStep, K as twipsToLines, L as pixelsToTwips, O as SuperConverter, Q as EditorState, U as hasSomeParentWithClass, V as parseSizeUnit, W as getLineHeightValueString, X as toKebabCase, Y as kebabCase, Z as getColStyleDeclaration, _ as SelectionRange, $ as Transform, a0 as createColGroup } from "./converter-CsK9KCaL.js";
15
+ import { P as PluginKey, a as Plugin, M as Mapping, c as callOrGet, i as isEmptyObject, S as Schema$1, T as TextSelection, b as canSplit, l as liftTarget, A as AllSelection, d as canJoin, j as joinPoint, N as NodeSelection, r as replaceStep$1, e as Selection, F as Fragment, R as ReplaceAroundStep, f as Slice, o as objectIncludes, g as deleteProps, D as DOMParser$1, h as ReplaceStep, k as NodeRange, m as findWrapping, n as isMacOS, p as isIOS, q as generateDocxRandomId, s as minMax, t as generateRandom32BitHex, u as DOMSerializer, v as Mark$1, w as dropPoint, x as process$1, B as Buffer2, y as isRegExp, z as TrackDeleteMarkName, C as TrackInsertMarkName, E as v4, G as TrackFormatMarkName, H as comments_module_events, I as AddMarkStep, J as RemoveMarkStep, K as twipsToLines, L as pixelsToTwips, O as SuperConverter, Q as EditorState, U as hasSomeParentWithClass, V as parseSizeUnit, W as getLineHeightValueString, X as toKebabCase, Y as kebabCase, Z as getColStyleDeclaration, _ as SelectionRange, $ as Transform, a0 as createColGroup } from "./converter-iJixg7yb.js";
16
16
  import { ref, computed, createElementBlock, openBlock, withModifiers, Fragment as Fragment$1, renderList, normalizeClass, createCommentVNode, toDisplayString, createElementVNode, createApp } from "vue";
17
- import { D as DocxZipper } from "./docx-zipper-6iKmmME2.js";
17
+ import { D as DocxZipper } from "./docx-zipper-CZ29YJni.js";
18
18
  function getMarksFromSelection(state) {
19
19
  const { from: from2, to, empty: empty2 } = state.selection;
20
20
  const marks = [];
@@ -14898,7 +14898,7 @@ const _Editor = class _Editor extends EventEmitter {
14898
14898
  * @returns {Object | void} Migration results
14899
14899
  */
14900
14900
  processCollaborationMigrations() {
14901
- console.debug("[checkVersionMigrations] Current editor version", "0.13.2");
14901
+ console.debug("[checkVersionMigrations] Current editor version", "0.13.3-next.2");
14902
14902
  if (!this.options.ydoc) return;
14903
14903
  const metaMap = this.options.ydoc.getMap("meta");
14904
14904
  let docVersion = metaMap.get("version");
@@ -14942,6 +14942,7 @@ const _Editor = class _Editor extends EventEmitter {
14942
14942
  __privateMethod(this, _Editor_instances, initMedia_fn).call(this);
14943
14943
  this.initDefaultStyles();
14944
14944
  if (this.options.ydoc && this.options.collaborationProvider) {
14945
+ updateYdocDocxData(this);
14945
14946
  this.initializeCollaborationData(true);
14946
14947
  } else {
14947
14948
  __privateMethod(this, _Editor_instances, insertNewFileData_fn).call(this);
@@ -1,6 +1,6 @@
1
1
  import { computed, createElementBlock, openBlock, createElementVNode, createCommentVNode, normalizeClass, normalizeStyle, ref, withKeys, unref, withModifiers, createBlock, toDisplayString, withDirectives, vModelText, getCurrentInstance, createVNode, readonly, watch, onMounted, onBeforeUnmount, reactive, onBeforeMount, inject, onActivated, onDeactivated, createTextVNode, Fragment, Comment, defineComponent, provide, h, Teleport, toRef, nextTick, renderSlot, isVNode, shallowRef, watchEffect, mergeProps, Transition, vShow, cloneVNode, Text, renderList, withCtx } from "vue";
2
- import { x as process$1 } from "./converter-CsK9KCaL.js";
3
- import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-Cxb-Zwyu.js";
2
+ import { x as process$1 } from "./converter-iJixg7yb.js";
3
+ import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-0NJKUWk3.js";
4
4
  const sanitizeNumber = (value, defaultNumber) => {
5
5
  let sanitized = value.replace(/[^0-9.]/g, "");
6
6
  sanitized = parseFloat(sanitized);
@@ -1,4 +1,4 @@
1
- import { O } from "./chunks/converter-CsK9KCaL.js";
1
+ import { O } from "./chunks/converter-iJixg7yb.js";
2
2
  export {
3
3
  O as SuperConverter
4
4
  };
@@ -1 +1 @@
1
- {"version":3,"file":"Editor.d.ts","sourceRoot":"","sources":["../../src/core/Editor.js"],"names":[],"mappings":"AA4BA;;;;GAIG;AAEH;;;;;GAKG;AACH;;;;;EAKE;AACF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2DG;AAEH;;;;GAIG;AACH;IA2qBE;;;;;;;;;;;;OAYG;IACH,+BARW,IAAI,GAAC,IAAI,GAAC,MAAM,WAChB,OAAO,GACL,OAAO,OAAO,CAc1B;IAED;;;;;OAKG;IACH,qCAFa,MAAM,CAKlB;IAED;;;;;;OAMG;IACH,gDAHW,MAAM,OAMhB;IA2qBD;;;;;OAKG;IACH,2CAFa,OAAO,CAOnB;IA9xCD;;;;OAIG;IACH,qBAHW,aAAa,EAwBvB;IAlID;;;OAGG;IACH,sBAAiB;IAEjB;;;OAGG;IACH,sBAAsB;IAEtB;;;OAGG;IACH,YAAO;IAEP;;;OAGG;IACH,UAAK;IAEL;;;OAGG;IACH,WAFU,OAAO,CAEC;IAQlB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAkEE;IA0BA,0CAA8C;IA0IhD;;;;OAIG;IACH,0BAFa,IAAI,CAIhB;IADC,aAAsB;IAsBxB;;;OAGG;IACH,SAFa,IAAI,CAIhB;IAED;;;OAGG;IACH,iBAEC;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
+ import "./chunks/converter-iJixg7yb.js";
2
+ import { D } from "./chunks/docx-zipper-CZ29YJni.js";
3
3
  export {
4
4
  D as default
5
5
  };
@@ -1,6 +1,6 @@
1
- import { E } from "./chunks/editor-Cxb-Zwyu.js";
2
- import "./chunks/converter-CsK9KCaL.js";
3
- import "./chunks/docx-zipper-6iKmmME2.js";
1
+ import { E } from "./chunks/editor-0NJKUWk3.js";
2
+ import "./chunks/converter-iJixg7yb.js";
3
+ import "./chunks/docx-zipper-CZ29YJni.js";
4
4
  export {
5
5
  E as Editor
6
6
  };
@@ -1,4 +1,4 @@
1
- import { J as JSZip } from "./chunks/docx-zipper-6iKmmME2.js";
1
+ import { J as JSZip } from "./chunks/docx-zipper-CZ29YJni.js";
2
2
  async function createZip(blobs, fileNames) {
3
3
  const zip = new JSZip();
4
4
  blobs.forEach((blob, index) => {
@@ -546,6 +546,8 @@ https://github.com/ProseMirror/prosemirror-tables/blob/master/demo/index.html
546
546
 
547
547
  overflow-x: auto;
548
548
  scrollbar-width: thin;
549
+ overflow: hidden;
550
+
549
551
  /*
550
552
  The border width does not need to be multiplied by two,
551
553
  for tables it works differently. */
@@ -555,7 +557,6 @@ https://github.com/ProseMirror/prosemirror-tables/blob/master/demo/index.html
555
557
  border-collapse: collapse;
556
558
  border-spacing: 0;
557
559
  table-layout: fixed;
558
- overflow: hidden;
559
560
  margin: 0;
560
561
  /* width: 100%; */
561
562
  }
@@ -9,14 +9,14 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read fr
9
9
  var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
10
10
  var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "access private method"), method);
11
11
  var _SuperToolbar_instances, initToolbarGroups_fn, _interceptedCommands, makeToolbarItems_fn, initDefaultFonts_fn, updateHighlightColors_fn, deactivateAll_fn, updateToolbarHistory_fn, runCommandWithArgumentOnly_fn;
12
- import { a2 as getDefaultExportFromCjs, E as v4, a5 as vClickOutside, T as TextSelection, a as Plugin } from "./chunks/converter-CsK9KCaL.js";
13
- import { O } from "./chunks/converter-CsK9KCaL.js";
14
- import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, f as findParentNode, c as getFileOpener, s as startImageUpload, d as getActiveFormatting, i as isInTable, e as undoDepth, r as redoDepth, E as Editor, h as getStarterExtensions, P as Placeholder, j as getRichTextExtensions, M as Mark, k as Extension, A as Attribute, N as Node } from "./chunks/editor-Cxb-Zwyu.js";
15
- import { o, C, T, m, q, p, l, n } from "./chunks/editor-Cxb-Zwyu.js";
12
+ import { a2 as getDefaultExportFromCjs, E as v4, a5 as vClickOutside, T as TextSelection, a as Plugin } from "./chunks/converter-iJixg7yb.js";
13
+ import { O } from "./chunks/converter-iJixg7yb.js";
14
+ import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, f as findParentNode, c as getFileOpener, s as startImageUpload, d as getActiveFormatting, i as isInTable, e as undoDepth, r as redoDepth, E as Editor, h as getStarterExtensions, P as Placeholder, j as getRichTextExtensions, M as Mark, k as Extension, A as Attribute, N as Node } from "./chunks/editor-0NJKUWk3.js";
15
+ import { o, C, T, m, q, p, l, n } from "./chunks/editor-0NJKUWk3.js";
16
16
  import { ref, onMounted, createElementBlock, openBlock, normalizeClass, unref, Fragment, renderList, createElementVNode, withModifiers, getCurrentInstance, computed, watch, createCommentVNode, withDirectives, withKeys, vModelText, createTextVNode, toDisplayString, normalizeStyle, createVNode, h, createApp, reactive, onUnmounted, shallowRef, onBeforeUnmount, createBlock } from "vue";
17
- import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, N as NSkeleton } from "./chunks/toolbar-QHIHaeEf.js";
17
+ import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, N as NSkeleton } from "./chunks/toolbar-CK6f1Uy_.js";
18
18
  import AIWriter from "./ai-writer.es.js";
19
- import { D } from "./chunks/docx-zipper-6iKmmME2.js";
19
+ import { D } from "./chunks/docx-zipper-CZ29YJni.js";
20
20
  import { createZip } from "./file-zipper.es.js";
21
21
  var eventemitter3 = { exports: {} };
22
22
  (function(module) {
@@ -1,6 +1,6 @@
1
1
  import "vue";
2
- import { T } from "./chunks/toolbar-QHIHaeEf.js";
3
- import "./chunks/editor-Cxb-Zwyu.js";
2
+ import { T } from "./chunks/toolbar-CK6f1Uy_.js";
3
+ import "./chunks/editor-0NJKUWk3.js";
4
4
  export {
5
5
  T as default
6
6
  };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const superEditor_es = require("./chunks/super-editor.es-BM89AzsN.cjs");
3
+ const superEditor_es = require("./chunks/super-editor.es-BKUxM8uT.cjs");
4
4
  require("./chunks/vue-HIY1g7dm.cjs");
5
5
  exports.AIWriter = superEditor_es.AIWriter;
6
6
  exports.AnnotatorHelpers = superEditor_es.AnnotatorHelpers;
@@ -1,4 +1,4 @@
1
- import { A, a, _, C, D, E, b, S, c, d, e, T, f, g, i, h, j, k, l, m, n, o } from "./chunks/super-editor.es-BNyzbCw0.es.js";
1
+ import { A, a, _, C, D, E, b, S, c, d, e, T, f, g, i, h, j, k, l, m, n, o } from "./chunks/super-editor.es-OQ_nBSHT.es.js";
2
2
  import "./chunks/vue-Bi1uWinj.es.js";
3
3
  export {
4
4
  A as AIWriter,
package/dist/superdoc.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const superEditor_es = require("./chunks/super-editor.es-BM89AzsN.cjs");
3
+ const superEditor_es = require("./chunks/super-editor.es-BKUxM8uT.cjs");
4
4
  const vue = require("./chunks/vue-HIY1g7dm.cjs");
5
5
  const jszip = require("./chunks/jszip-BTAcmbVg.cjs");
6
6
  const blankDocx = require("./chunks/blank-docx-CPqX9RF5.cjs");
@@ -47806,7 +47806,7 @@ class SuperDoc extends eventemitter3.EventEmitter {
47806
47806
  this.config.colors = shuffleArray(this.config.colors);
47807
47807
  this.userColorMap = /* @__PURE__ */ new Map();
47808
47808
  this.colorIndex = 0;
47809
- this.version = "0.13.2";
47809
+ this.version = "0.13.3-next.2";
47810
47810
  console.debug("🦋 [superdoc] Using SuperDoc version:", this.version);
47811
47811
  this.superdocId = config.superdocId || uuid.v4();
47812
47812
  this.colors = this.config.colors;
@@ -1,5 +1,5 @@
1
- import { o as index$1, C as CommentsPluginKey, f as TrackChangesBasePluginKey, E as Editor, l as getRichTextExtensions, d as SuperInput, A as AIWriter, c as SuperEditor, e as SuperToolbar, g as createZip } from "./chunks/super-editor.es-BNyzbCw0.es.js";
2
- import { a, S, i, n } from "./chunks/super-editor.es-BNyzbCw0.es.js";
1
+ import { o as index$1, C as CommentsPluginKey, f as TrackChangesBasePluginKey, E as Editor, l as getRichTextExtensions, d as SuperInput, A as AIWriter, c as SuperEditor, e as SuperToolbar, g as createZip } from "./chunks/super-editor.es-OQ_nBSHT.es.js";
2
+ import { a, S, i, n } from "./chunks/super-editor.es-OQ_nBSHT.es.js";
3
3
  import { Y as effectScope, r as ref, Z as markRaw, p as process$1, _ as toRaw, a as computed, $ as isRef, a0 as isReactive, D as toRef, i as inject, q as getCurrentInstance, l as watch, y as unref, a1 as hasInjectionContext, N as reactive, u as nextTick, a2 as getCurrentScope, a3 as onScopeDispose, a4 as toRefs, g as global$1, K as shallowRef, O as readonly, j as onMounted, k as onBeforeUnmount, h as onBeforeMount, U as onActivated, s as onDeactivated, A as createTextVNode, F as Fragment, R as Comment, m as defineComponent, E as provide, I as withDirectives, C as h, V as Teleport, S as renderSlot, W as isVNode, J as watchEffect, P as Transition, G as mergeProps, Q as vShow, H as cloneVNode, T as Text, b as createElementBlock, o as openBlock, t as toDisplayString, x as createVNode, z as withCtx, f as createBaseVNode, B as normalizeStyle, e as createCommentVNode, v as createBlock, w as withModifiers, n as normalizeClass, a5 as resolveDirective, d as renderList, c as createApp, X as onUnmounted, a6 as resolveDynamicComponent } from "./chunks/vue-Bi1uWinj.es.js";
4
4
  import { B as Buffer$2 } from "./chunks/jszip-DckFs3A7.es.js";
5
5
  import { B as BlankDOCX } from "./chunks/blank-docx-iwdyG9RH.es.js";
@@ -47789,7 +47789,7 @@ class SuperDoc extends EventEmitter {
47789
47789
  this.config.colors = shuffleArray(this.config.colors);
47790
47790
  this.userColorMap = /* @__PURE__ */ new Map();
47791
47791
  this.colorIndex = 0;
47792
- this.version = "0.13.2";
47792
+ this.version = "0.13.3-next.2";
47793
47793
  console.debug("🦋 [superdoc] Using SuperDoc version:", this.version);
47794
47794
  this.superdocId = config.superdocId || v4();
47795
47795
  this.colors = this.config.colors;
@@ -26235,13 +26235,13 @@
26235
26235
  function translateBodyNode(params2) {
26236
26236
  let sectPr = params2.bodyNode?.elements.find((n) => n.name === "w:sectPr") || {};
26237
26237
  if (params2.converter) {
26238
- const hasHeader = sectPr.elements.some((n) => n.name === "w:headerReference");
26238
+ const hasHeader = sectPr?.elements?.some((n) => n.name === "w:headerReference");
26239
26239
  const hasDefaultHeader = params2.converter.headerIds?.default;
26240
26240
  if (!hasHeader && hasDefaultHeader && !params2.editor.options.isHeaderOrFooter) {
26241
26241
  const defaultHeader = generateDefaultHeaderFooter("header", params2.converter.headerIds?.default);
26242
26242
  sectPr.elements.push(defaultHeader);
26243
26243
  }
26244
- const hasFooter = sectPr.elements.some((n) => n.name === "w:footerReference");
26244
+ const hasFooter = sectPr?.elements?.some((n) => n.name === "w:footerReference");
26245
26245
  const hasDefaultFooter = params2.converter.footerIds?.default;
26246
26246
  if (!hasFooter && hasDefaultFooter && !params2.editor.options.isHeaderOrFooter) {
26247
26247
  const defaultFooter = generateDefaultHeaderFooter("footer", params2.converter.footerIds?.default);
@@ -30601,7 +30601,7 @@
30601
30601
  });
30602
30602
  return updatedStyles;
30603
30603
  }
30604
- const importHeadersFooters = (docx, converter, editor) => {
30604
+ const importHeadersFooters = (docx, converter, mainEditor) => {
30605
30605
  const rels = docx["word/_rels/document.xml.rels"];
30606
30606
  const relationships = rels.elements.find((el) => el.name === "Relationships");
30607
30607
  const { elements } = relationships;
@@ -30611,6 +30611,9 @@
30611
30611
  const footers = elements.filter((el) => el.attributes["Type"] === footerType);
30612
30612
  const sectPr = findSectPr(docx["word/document.xml"]) || [];
30613
30613
  const allSectPrElements = sectPr.flatMap((el) => el.elements);
30614
+ if (!mainEditor) return;
30615
+ const editor = { ...mainEditor };
30616
+ editor.options.annotations = true;
30614
30617
  headers.forEach((header) => {
30615
30618
  const { rId, referenceFile, currentFileName } = getHeaderFooterSectionData(header, docx);
30616
30619
  const sectPrHeader = allSectPrElements.find((el) => el.name === "w:headerReference" && el.attributes["r:id"] === rId);
@@ -30770,7 +30773,7 @@
30770
30773
  return;
30771
30774
  }
30772
30775
  }
30773
- static updateDocumentVersion(docx = this.convertedXml, version2 = "0.13.2") {
30776
+ static updateDocumentVersion(docx = this.convertedXml, version2 = "0.13.3-next.2") {
30774
30777
  const customLocation = "docProps/custom.xml";
30775
30778
  if (!docx[customLocation]) {
30776
30779
  docx[customLocation] = generateCustomXml();
@@ -31237,7 +31240,7 @@
31237
31240
  function generateCustomXml() {
31238
31241
  return DEFAULT_CUSTOM_XML;
31239
31242
  }
31240
- function generateSuperdocVersion(pid = 2, version2 = "0.13.2") {
31243
+ function generateSuperdocVersion(pid = 2, version2 = "0.13.3-next.2") {
31241
31244
  return {
31242
31245
  type: "element",
31243
31246
  name: "property",
@@ -48617,7 +48620,7 @@
48617
48620
  * @returns {Object | void} Migration results
48618
48621
  */
48619
48622
  processCollaborationMigrations() {
48620
- console.debug("[checkVersionMigrations] Current editor version", "0.13.2");
48623
+ console.debug("[checkVersionMigrations] Current editor version", "0.13.3-next.2");
48621
48624
  if (!this.options.ydoc) return;
48622
48625
  const metaMap = this.options.ydoc.getMap("meta");
48623
48626
  let docVersion = metaMap.get("version");
@@ -48661,6 +48664,7 @@
48661
48664
  __privateMethod$1(this, _Editor_instances, initMedia_fn).call(this);
48662
48665
  this.initDefaultStyles();
48663
48666
  if (this.options.ydoc && this.options.collaborationProvider) {
48667
+ updateYdocDocxData(this);
48664
48668
  this.initializeCollaborationData(true);
48665
48669
  } else {
48666
48670
  __privateMethod$1(this, _Editor_instances, insertNewFileData_fn).call(this);
@@ -93316,7 +93320,7 @@ ${style2}
93316
93320
  this.config.colors = shuffleArray(this.config.colors);
93317
93321
  this.userColorMap = /* @__PURE__ */ new Map();
93318
93322
  this.colorIndex = 0;
93319
- this.version = "0.13.2";
93323
+ this.version = "0.13.3-next.2";
93320
93324
  console.debug("🦋 [superdoc] Using SuperDoc version:", this.version);
93321
93325
  this.superdocId = config.superdocId || v4();
93322
93326
  this.colors = this.config.colors;