@harbour-enterprises/superdoc 0.15.7-next.1 → 0.15.7-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.
@@ -26083,7 +26083,7 @@ function generateTableCellProperties(node2) {
26083
26083
  const cellBordersElement = {
26084
26084
  name: "w:tcBorders",
26085
26085
  elements: Object.entries(borders).map(([key, value]) => {
26086
- if (!value.size) {
26086
+ if (!value.size || value.val === "none") {
26087
26087
  return {
26088
26088
  name: `w:${key}`,
26089
26089
  attributes: {
@@ -28903,7 +28903,7 @@ const _SuperConverter = class _SuperConverter2 {
28903
28903
  return;
28904
28904
  }
28905
28905
  }
28906
- static updateDocumentVersion(docx = this.convertedXml, version2 = "0.15.7-next.1") {
28906
+ static updateDocumentVersion(docx = this.convertedXml, version2 = "0.15.7-next.2") {
28907
28907
  const customLocation = "docProps/custom.xml";
28908
28908
  if (!docx[customLocation]) {
28909
28909
  docx[customLocation] = generateCustomXml();
@@ -29382,7 +29382,7 @@ function storeSuperdocVersion(docx) {
29382
29382
  function generateCustomXml() {
29383
29383
  return DEFAULT_CUSTOM_XML;
29384
29384
  }
29385
- function generateSuperdocVersion(pid = 2, version2 = "0.15.7-next.1") {
29385
+ function generateSuperdocVersion(pid = 2, version2 = "0.15.7-next.2") {
29386
29386
  return {
29387
29387
  type: "element",
29388
29388
  name: "property",
@@ -45709,7 +45709,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
45709
45709
  * @returns {Object | void} Migration results
45710
45710
  */
45711
45711
  processCollaborationMigrations() {
45712
- console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.1");
45712
+ console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.2");
45713
45713
  if (!this.options.ydoc) return;
45714
45714
  const metaMap = this.options.ydoc.getMap("meta");
45715
45715
  let docVersion = metaMap.get("version");
@@ -26100,7 +26100,7 @@ function generateTableCellProperties(node2) {
26100
26100
  const cellBordersElement = {
26101
26101
  name: "w:tcBorders",
26102
26102
  elements: Object.entries(borders).map(([key, value]) => {
26103
- if (!value.size) {
26103
+ if (!value.size || value.val === "none") {
26104
26104
  return {
26105
26105
  name: `w:${key}`,
26106
26106
  attributes: {
@@ -28920,7 +28920,7 @@ const _SuperConverter = class _SuperConverter2 {
28920
28920
  return;
28921
28921
  }
28922
28922
  }
28923
- static updateDocumentVersion(docx = this.convertedXml, version2 = "0.15.7-next.1") {
28923
+ static updateDocumentVersion(docx = this.convertedXml, version2 = "0.15.7-next.2") {
28924
28924
  const customLocation = "docProps/custom.xml";
28925
28925
  if (!docx[customLocation]) {
28926
28926
  docx[customLocation] = generateCustomXml();
@@ -29399,7 +29399,7 @@ function storeSuperdocVersion(docx) {
29399
29399
  function generateCustomXml() {
29400
29400
  return DEFAULT_CUSTOM_XML;
29401
29401
  }
29402
- function generateSuperdocVersion(pid = 2, version2 = "0.15.7-next.1") {
29402
+ function generateSuperdocVersion(pid = 2, version2 = "0.15.7-next.2") {
29403
29403
  return {
29404
29404
  type: "element",
29405
29405
  name: "property",
@@ -45726,7 +45726,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
45726
45726
  * @returns {Object | void} Migration results
45727
45727
  */
45728
45728
  processCollaborationMigrations() {
45729
- console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.1");
45729
+ console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.2");
45730
45730
  if (!this.options.ydoc) return;
45731
45731
  const metaMap = this.options.ydoc.getMap("meta");
45732
45732
  let docVersion = metaMap.get("version");
@@ -192,7 +192,6 @@ export class SuperDoc extends EventEmitter<string | symbol, any> {
192
192
  * @param {boolean} isOpened
193
193
  */
194
194
  broadcastSidebarToggle(isOpened: boolean): void;
195
- log(...args: any[]): void;
196
195
  /**
197
196
  * Set the active editor
198
197
  * @param {Editor} editor The editor to set as active
@@ -1 +1 @@
1
- {"version":3,"file":"SuperDoc.d.ts","sourceRoot":"","sources":["../../src/core/SuperDoc.js"],"names":[],"mappings":"AAeA;;;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AAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAC,KAAK,IAAI;;;;wBAC/C,CAAC,MAAM,EAAE;QAAE,OAAO,EAAE,QAAQ,CAAC;QAAC,MAAM,QAAO;KAAE,KAAK,IAAI;;;;eACtD,CAAC,MAAM,EAAE;QAAE,QAAQ,EAAE,OAAO,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE,KAAK,IAAI;;;;yBACvD,MAAM,IAAI;;;;sBACV,CAAC,QAAQ,EAAE,OAAO,KAAK,IAAI;;;;2BAC3B,CAAC,MAAM,EAAE;QAAE,MAAM,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI;;;;qBACpC,CAAC,MAAM,EAAE;QAAE,MAAM,EAAE,MAAM,CAAA;KAAE,KAAK,IAAI;;;;kBACpC,CAAC,MAAM,EAAE;QAAE,KAAK,EAAE,KAAK,CAAA;KAAE,KAAK,IAAI;;;;2BAClC,CAAC,MAAM,EAAE;QAAE,UAAU,EAAE,OAAO,CAAA;KAAE,KAAK,IAAI;;;;8BACzC,CAAC,MAAM,EAAE,EAAE,KAAC,GAAA;;;;aACZ,MAAM;;;;uBACN,KAAQ;;;;iBACR,OAAO;;;;YACP,MAAM;;;;oBACN,KAAQ;;;;eACR,OAAO;;;;;;;;wBAEP,CAAS,IAAI,EAAJ,IAAI,KAAG,OAAO,CAAC,MAAM,CAAC;;;;eAC/B,IAAI;;;;aACJ,OAAO;;;;gCACP,OAAO;;;;mBACP,OAAO;;;;yBACP,OAAO;;6BAzGQ,eAAe;0BASlB,0CAA0C;6BAJ5B,mCAAmC;8BAC7C,iEAAiE"}
@@ -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-DeJTqjPR.js";
3
- import { _ as _export_sfc } from "./chunks/editor-Dd9HYASE.js";
2
+ import { T as TextSelection } from "./chunks/converter-BZEnzKq4.js";
3
+ import { _ as _export_sfc } from "./chunks/editor-BQwbteiR.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 = {}) {
@@ -26081,7 +26081,7 @@ function generateTableCellProperties(node2) {
26081
26081
  const cellBordersElement = {
26082
26082
  name: "w:tcBorders",
26083
26083
  elements: Object.entries(borders).map(([key, value]) => {
26084
- if (!value.size) {
26084
+ if (!value.size || value.val === "none") {
26085
26085
  return {
26086
26086
  name: `w:${key}`,
26087
26087
  attributes: {
@@ -28901,7 +28901,7 @@ const _SuperConverter = class _SuperConverter {
28901
28901
  return;
28902
28902
  }
28903
28903
  }
28904
- static updateDocumentVersion(docx = this.convertedXml, version = "0.15.7-next.1") {
28904
+ static updateDocumentVersion(docx = this.convertedXml, version = "0.15.7-next.2") {
28905
28905
  const customLocation = "docProps/custom.xml";
28906
28906
  if (!docx[customLocation]) {
28907
28907
  docx[customLocation] = generateCustomXml();
@@ -29383,7 +29383,7 @@ function storeSuperdocVersion(docx) {
29383
29383
  function generateCustomXml() {
29384
29384
  return DEFAULT_CUSTOM_XML;
29385
29385
  }
29386
- function generateSuperdocVersion(pid = 2, version = "0.15.7-next.1") {
29386
+ function generateSuperdocVersion(pid = 2, version = "0.15.7-next.2") {
29387
29387
  return {
29388
29388
  type: "element",
29389
29389
  name: "property",
@@ -1,4 +1,4 @@
1
- import { H as process$1, at as commonjsGlobal, I as Buffer, au as getDefaultExportFromCjs, av as getContentTypesFromXml, aw as xmljs } from "./converter-DeJTqjPR.js";
1
+ import { H as process$1, at as commonjsGlobal, I as Buffer, au as getDefaultExportFromCjs, av as getContentTypesFromXml, aw as xmljs } from "./converter-BZEnzKq4.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, _editor, _stateValidators, _requiredNodeTypes, _requiredMarkTypes, _SuperValidator_instances, initializeValidators_fn, collectValidatorRequirements_fn, analyzeDocument_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, dispatchTransaction_fn, handleNodeSelection_fn, prepareDocumentForImport_fn, prepareDocumentForExport_fn, endCollaboration_fn, validateDocumentInit_fn, _ListItemNodeView_instances, init_fn2, _FieldAnnotationView_instances, createAnnotation_fn, _AutoPageNumberNodeView_instances, renderDom_fn, scheduleUpdateNodeStyle_fn, _DocumentSectionView_instances, init_fn3, addToolTip_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, g as getExtensionConfigField, b as getMarkType, d as getMarksFromSelection, e as getNodeType, f as getSchemaTypeNameByName, S as Schema$1, h as cleanSchemaItem, T as TextSelection, i as canSplit, l as liftTarget, A as AllSelection, j as canJoin, k as joinPoint, N as NodeSelection, m as Selection, r as replaceStep$1, F as Fragment, R as ReplaceAroundStep$1, n as Slice, o as defaultBlockAt$1, p as isTextSelection, q as getMarkRange, s as isMarkActive, t as isNodeActive, u as deleteProps, D as DOMParser$1, v as ReplaceStep, w as NodeRange, x as findWrapping, y as findParentNode, L as ListHelpers, z as isMacOS, B as isIOS, C as DOMSerializer, E as Mark$1, G as dropPoint, H as process$1, I as Buffer2, J as getSchemaTypeByName, K as inputRulesPlugin, O as TrackDeleteMarkName, Q as TrackInsertMarkName, U as v4, V as TrackFormatMarkName, W as comments_module_events, X as findMark, Y as objectIncludes, Z as AddMarkStep, _ as RemoveMarkStep, $ as twipsToLines, a0 as pixelsToTwips, a1 as helpers, a2 as posToDOMRect, a3 as CommandService, a4 as SuperConverter, a5 as createDocument, a6 as EditorState, a7 as hasSomeParentWithClass, a8 as isActive, a9 as unflattenListsInHtml, aa as parseSizeUnit, ab as minMax, ac as getLineHeightValueString, ad as InputRule, ae as kebabCase, af as generateOrderedListIndex, ag as getListItemStyleDefinitions, ah as docxNumberigHelpers, ai as parseIndentElement, aj as combineIndents, ak as getColStyleDeclaration, al as SelectionRange, am as Transform, an as findParentNodeClosestToPos, ao as isInTable$1, ap as createColGroup, aq as generateDocxRandomId, ar as SectionHelpers, as as htmlHandler } from "./converter-DeJTqjPR.js";
15
+ import { P as PluginKey, a as Plugin, M as Mapping, c as callOrGet, g as getExtensionConfigField, b as getMarkType, d as getMarksFromSelection, e as getNodeType, f as getSchemaTypeNameByName, S as Schema$1, h as cleanSchemaItem, T as TextSelection, i as canSplit, l as liftTarget, A as AllSelection, j as canJoin, k as joinPoint, N as NodeSelection, m as Selection, r as replaceStep$1, F as Fragment, R as ReplaceAroundStep$1, n as Slice, o as defaultBlockAt$1, p as isTextSelection, q as getMarkRange, s as isMarkActive, t as isNodeActive, u as deleteProps, D as DOMParser$1, v as ReplaceStep, w as NodeRange, x as findWrapping, y as findParentNode, L as ListHelpers, z as isMacOS, B as isIOS, C as DOMSerializer, E as Mark$1, G as dropPoint, H as process$1, I as Buffer2, J as getSchemaTypeByName, K as inputRulesPlugin, O as TrackDeleteMarkName, Q as TrackInsertMarkName, U as v4, V as TrackFormatMarkName, W as comments_module_events, X as findMark, Y as objectIncludes, Z as AddMarkStep, _ as RemoveMarkStep, $ as twipsToLines, a0 as pixelsToTwips, a1 as helpers, a2 as posToDOMRect, a3 as CommandService, a4 as SuperConverter, a5 as createDocument, a6 as EditorState, a7 as hasSomeParentWithClass, a8 as isActive, a9 as unflattenListsInHtml, aa as parseSizeUnit, ab as minMax, ac as getLineHeightValueString, ad as InputRule, ae as kebabCase, af as generateOrderedListIndex, ag as getListItemStyleDefinitions, ah as docxNumberigHelpers, ai as parseIndentElement, aj as combineIndents, ak as getColStyleDeclaration, al as SelectionRange, am as Transform, an as findParentNodeClosestToPos, ao as isInTable$1, ap as createColGroup, aq as generateDocxRandomId, ar as SectionHelpers, as as htmlHandler } from "./converter-BZEnzKq4.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-vN19SPa8.js";
17
+ import { D as DocxZipper } from "./docx-zipper-D-LQtmTY.js";
18
18
  var GOOD_LEAF_SIZE = 200;
19
19
  var RopeSequence = function RopeSequence2() {
20
20
  };
@@ -13845,7 +13845,7 @@ const _Editor = class _Editor extends EventEmitter {
13845
13845
  * @returns {Object | void} Migration results
13846
13846
  */
13847
13847
  processCollaborationMigrations() {
13848
- console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.1");
13848
+ console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.2");
13849
13849
  if (!this.options.ydoc) return;
13850
13850
  const metaMap = this.options.ydoc.getMap("meta");
13851
13851
  let docVersion = metaMap.get("version");
@@ -1,6 +1,6 @@
1
1
  import { computed, createElementBlock, openBlock, createElementVNode, createCommentVNode, normalizeClass, normalizeStyle, ref, withKeys, unref, withModifiers, createBlock, toDisplayString, withDirectives, vModelText, nextTick, getCurrentInstance, createVNode, readonly, watch, onMounted, onBeforeUnmount, reactive, onBeforeMount, inject, onActivated, onDeactivated, createTextVNode, Fragment, Comment, defineComponent, provide, h, Teleport, toRef, renderSlot, isVNode, shallowRef, watchEffect, mergeProps, Transition, vShow, cloneVNode, Text, renderList, withCtx } from "vue";
2
- import { H as process$1 } from "./converter-DeJTqjPR.js";
3
- import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-Dd9HYASE.js";
2
+ import { H as process$1 } from "./converter-BZEnzKq4.js";
3
+ import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-BQwbteiR.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 { a4 } from "./chunks/converter-DeJTqjPR.js";
1
+ import { a4 } from "./chunks/converter-BZEnzKq4.js";
2
2
  export {
3
3
  a4 as SuperConverter
4
4
  };
@@ -1,5 +1,5 @@
1
- import "./chunks/converter-DeJTqjPR.js";
2
- import { D } from "./chunks/docx-zipper-vN19SPa8.js";
1
+ import "./chunks/converter-BZEnzKq4.js";
2
+ import { D } from "./chunks/docx-zipper-D-LQtmTY.js";
3
3
  export {
4
4
  D as default
5
5
  };
@@ -1,6 +1,6 @@
1
- import { E } from "./chunks/editor-Dd9HYASE.js";
2
- import "./chunks/converter-DeJTqjPR.js";
3
- import "./chunks/docx-zipper-vN19SPa8.js";
1
+ import { E } from "./chunks/editor-BQwbteiR.js";
2
+ import "./chunks/converter-BZEnzKq4.js";
3
+ import "./chunks/docx-zipper-D-LQtmTY.js";
4
4
  export {
5
5
  E as Editor
6
6
  };
@@ -1,4 +1,4 @@
1
- import { J as JSZip } from "./chunks/docx-zipper-vN19SPa8.js";
1
+ import { J as JSZip } from "./chunks/docx-zipper-D-LQtmTY.js";
2
2
  async function createZip(blobs, fileNames) {
3
3
  const zip = new JSZip();
4
4
  blobs.forEach((blob, index) => {
@@ -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 { au as getDefaultExportFromCjs, U as v4, T as TextSelection$1, q as getMarkRange, ax as vClickOutside, y as findParentNode, ay as getActiveFormatting, ao as isInTable, az as readFromClipboard, aA as handleClipboardPaste, a as Plugin } from "./chunks/converter-DeJTqjPR.js";
13
- import { ar, a4, d, a1 } from "./chunks/converter-DeJTqjPR.js";
14
- import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as getFileOpener, s as startImageUpload, y as yUndoPluginKey, d as undoDepth, r as redoDepth, S as SlashMenuPluginKey, E as Editor, e as getStarterExtensions, P as Placeholder, f as getRichTextExtensions, M as Mark, h as Extension, A as Attribute, N as Node } from "./chunks/editor-Dd9HYASE.js";
15
- import { k, C, T, i, l, j } from "./chunks/editor-Dd9HYASE.js";
12
+ import { au as getDefaultExportFromCjs, U as v4, T as TextSelection$1, q as getMarkRange, ax as vClickOutside, y as findParentNode, ay as getActiveFormatting, ao as isInTable, az as readFromClipboard, aA as handleClipboardPaste, a as Plugin } from "./chunks/converter-BZEnzKq4.js";
13
+ import { ar, a4, d, a1 } from "./chunks/converter-BZEnzKq4.js";
14
+ import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as getFileOpener, s as startImageUpload, y as yUndoPluginKey, d as undoDepth, r as redoDepth, S as SlashMenuPluginKey, E as Editor, e as getStarterExtensions, P as Placeholder, f as getRichTextExtensions, M as Mark, h as Extension, A as Attribute, N as Node } from "./chunks/editor-BQwbteiR.js";
15
+ import { k, C, T, i, l, j } from "./chunks/editor-BQwbteiR.js";
16
16
  import { ref, onMounted, createElementBlock, openBlock, normalizeClass, unref, Fragment, renderList, createElementVNode, withModifiers, toDisplayString, createCommentVNode, normalizeStyle, computed, watch, withDirectives, withKeys, vModelText, createTextVNode, createVNode, h, createApp, markRaw, nextTick, onBeforeUnmount, reactive, onUnmounted, renderSlot, shallowRef, createBlock, withCtx, resolveDynamicComponent, normalizeProps, guardReactiveProps } from "vue";
17
- import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, m as magicWandIcon, p as plusIconSvg, a as trashIconSvg, l as linkIconSvg, b as tableIconSvg, c as scissorsIconSvg, d as copyIconSvg, e as pasteIconSvg, f as borderNoneIconSvg, g as arrowsToDotIconSvg, h as arrowsLeftRightIconSvg, w as wrenchIconSvg, N as NSkeleton } from "./chunks/toolbar-D0DQ38PV.js";
17
+ import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, m as magicWandIcon, p as plusIconSvg, a as trashIconSvg, l as linkIconSvg, b as tableIconSvg, c as scissorsIconSvg, d as copyIconSvg, e as pasteIconSvg, f as borderNoneIconSvg, g as arrowsToDotIconSvg, h as arrowsLeftRightIconSvg, w as wrenchIconSvg, N as NSkeleton } from "./chunks/toolbar-DqErzAFu.js";
18
18
  import AIWriter from "./ai-writer.es.js";
19
- import { D } from "./chunks/docx-zipper-vN19SPa8.js";
19
+ import { D } from "./chunks/docx-zipper-D-LQtmTY.js";
20
20
  import { createZip } from "./file-zipper.es.js";
21
21
  var eventemitter3 = { exports: {} };
22
22
  var hasRequiredEventemitter3;
@@ -1,6 +1,6 @@
1
1
  import "vue";
2
- import { T } from "./chunks/toolbar-D0DQ38PV.js";
3
- import "./chunks/editor-Dd9HYASE.js";
2
+ import { T } from "./chunks/toolbar-DqErzAFu.js";
3
+ import "./chunks/editor-BQwbteiR.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-wYUD2FbG.cjs");
3
+ const superEditor_es = require("./chunks/super-editor.es-BiHIRDPY.cjs");
4
4
  require("./chunks/vue-CfKg12kH.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, f, g, T, h, i, j, k, l, m, n, o, p, q } from "./chunks/super-editor.es-DK_jRQOE.es.js";
1
+ import { A, a, _, C, D, E, b, S, c, d, e, f, g, T, h, i, j, k, l, m, n, o, p, q } from "./chunks/super-editor.es-7kc2uX7G.es.js";
2
2
  import "./chunks/vue-B_OPNNfX.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-wYUD2FbG.cjs");
3
+ const superEditor_es = require("./chunks/super-editor.es-BiHIRDPY.cjs");
4
4
  const vue = require("./chunks/vue-CfKg12kH.cjs");
5
5
  const jszip = require("./chunks/jszip-DWfnW2xV.cjs");
6
6
  const blankDocx = require("./chunks/blank-docx-CPqX9RF5.cjs");
@@ -47847,8 +47847,8 @@ class SuperDoc extends eventemitter3.EventEmitter {
47847
47847
  this.config.colors = shuffleArray(this.config.colors);
47848
47848
  this.userColorMap = /* @__PURE__ */ new Map();
47849
47849
  this.colorIndex = 0;
47850
- this.version = "0.15.7-next.1";
47851
- console.debug("🦋 [superdoc] Using SuperDoc version:", this.version);
47850
+ this.version = "0.15.7-next.2";
47851
+ this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
47852
47852
  this.superdocId = config.superdocId || uuid.v4();
47853
47853
  this.colors = this.config.colors;
47854
47854
  this.#initDocuments();
@@ -48065,8 +48065,8 @@ class SuperDoc extends eventemitter3.EventEmitter {
48065
48065
  broadcastSidebarToggle(isOpened) {
48066
48066
  this.emit("sidebar-toggle", isOpened);
48067
48067
  }
48068
- log(...args) {
48069
- console.debug("🦋 🦸‍♀️ [superdoc]", ...args);
48068
+ #log(...args) {
48069
+ (console.debug ? console.debug : console.log)("🦋 🦸‍♀️ [superdoc]", ...args);
48070
48070
  }
48071
48071
  /**
48072
48072
  * Set the active editor
@@ -48137,7 +48137,7 @@ class SuperDoc extends eventemitter3.EventEmitter {
48137
48137
  */
48138
48138
  addCommentsList(element) {
48139
48139
  if (!this.config?.modules?.comments || this.config.role === "viewer") return;
48140
- console.debug("🦋 [superdoc] Adding comments list to:", element);
48140
+ this.#log("🦋 [superdoc] Adding comments list to:", element);
48141
48141
  if (element) this.config.modules.comments.element = element;
48142
48142
  this.commentsList = new SuperComments(this.config.modules?.comments, this);
48143
48143
  if (this.config.onCommentsListChange) this.config.onCommentsListChange({ isRendered: true });
@@ -48277,7 +48277,7 @@ class SuperDoc extends eventemitter3.EventEmitter {
48277
48277
  lockSuperdoc(isLocked = false, lockedBy) {
48278
48278
  this.isLocked = isLocked;
48279
48279
  this.lockedBy = lockedBy;
48280
- console.debug("🦋 [superdoc] Locking superdoc:", isLocked, lockedBy, "\n\n\n");
48280
+ this.#log("🦋 [superdoc] Locking superdoc:", isLocked, lockedBy, "\n\n\n");
48281
48281
  this.emit("locked", { isLocked, lockedBy });
48282
48282
  }
48283
48283
  /**
@@ -48347,7 +48347,7 @@ class SuperDoc extends eventemitter3.EventEmitter {
48347
48347
  * @returns {Promise<void>} Resolves when all documents have saved
48348
48348
  */
48349
48349
  async #triggerCollaborationSaves() {
48350
- console.debug("🦋 [superdoc] Triggering collaboration saves");
48350
+ this.#log("🦋 [superdoc] Triggering collaboration saves");
48351
48351
  return new Promise((resolve, reject) => {
48352
48352
  this.superdocStore.documents.forEach((doc) => {
48353
48353
  this.pendingCollaborationSaves = 0;
@@ -48376,9 +48376,9 @@ class SuperDoc extends eventemitter3.EventEmitter {
48376
48376
  this.#triggerCollaborationSaves()
48377
48377
  // this.exportEditorsToDOCX(),
48378
48378
  ];
48379
- console.debug("🦋 [superdoc] Saving superdoc");
48379
+ this.#log("🦋 [superdoc] Saving superdoc");
48380
48380
  const result = await Promise.all(savePromises);
48381
- console.debug("🦋 [superdoc] Save complete:", result);
48381
+ this.#log("🦋 [superdoc] Save complete:", result);
48382
48382
  return result;
48383
48383
  }
48384
48384
  /**
@@ -48389,7 +48389,7 @@ class SuperDoc extends eventemitter3.EventEmitter {
48389
48389
  if (!this.app) {
48390
48390
  return;
48391
48391
  }
48392
- this.log("[superdoc] Unmounting app");
48392
+ this.#log("[superdoc] Unmounting app");
48393
48393
  this.config.socket?.cancelWebsocketRetry();
48394
48394
  this.config.socket?.disconnect();
48395
48395
  this.config.socket?.destroy();
@@ -1,5 +1,5 @@
1
- import { q as index$1, C as CommentsPluginKey, h as TrackChangesBasePluginKey, E as Editor, n as getRichTextExtensions, f as SuperInput, e as SuperEditor, A as AIWriter, g as SuperToolbar, i as createZip } from "./chunks/super-editor.es-DK_jRQOE.es.js";
2
- import { a, S, d, j, p } from "./chunks/super-editor.es-DK_jRQOE.es.js";
1
+ import { q as index$1, C as CommentsPluginKey, h as TrackChangesBasePluginKey, E as Editor, n as getRichTextExtensions, f as SuperInput, e as SuperEditor, A as AIWriter, g as SuperToolbar, i as createZip } from "./chunks/super-editor.es-7kc2uX7G.es.js";
2
+ import { a, S, d, j, p } from "./chunks/super-editor.es-7kc2uX7G.es.js";
3
3
  import { a0 as effectScope, r as ref, $ as markRaw, p as process$1, a1 as toRaw, a as computed, a2 as isRef, a3 as isReactive, D as toRef, i as inject, q as getCurrentInstance, l as watch, y as unref, a4 as hasInjectionContext, N as reactive, u as nextTick, a5 as getCurrentScope, a6 as onScopeDispose, a7 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, a8 as resolveDirective, d as renderList, c as createApp, X as onUnmounted, Y as resolveDynamicComponent } from "./chunks/vue-B_OPNNfX.es.js";
4
4
  import { B as Buffer$2 } from "./chunks/jszip-BwJb6_S5.es.js";
5
5
  import { B as BlankDOCX } from "./chunks/blank-docx-iwdyG9RH.es.js";
@@ -47830,8 +47830,8 @@ class SuperDoc extends EventEmitter {
47830
47830
  this.config.colors = shuffleArray(this.config.colors);
47831
47831
  this.userColorMap = /* @__PURE__ */ new Map();
47832
47832
  this.colorIndex = 0;
47833
- this.version = "0.15.7-next.1";
47834
- console.debug("🦋 [superdoc] Using SuperDoc version:", this.version);
47833
+ this.version = "0.15.7-next.2";
47834
+ this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
47835
47835
  this.superdocId = config.superdocId || v4();
47836
47836
  this.colors = this.config.colors;
47837
47837
  this.#initDocuments();
@@ -48048,8 +48048,8 @@ class SuperDoc extends EventEmitter {
48048
48048
  broadcastSidebarToggle(isOpened) {
48049
48049
  this.emit("sidebar-toggle", isOpened);
48050
48050
  }
48051
- log(...args) {
48052
- console.debug("🦋 🦸‍♀️ [superdoc]", ...args);
48051
+ #log(...args) {
48052
+ (console.debug ? console.debug : console.log)("🦋 🦸‍♀️ [superdoc]", ...args);
48053
48053
  }
48054
48054
  /**
48055
48055
  * Set the active editor
@@ -48120,7 +48120,7 @@ class SuperDoc extends EventEmitter {
48120
48120
  */
48121
48121
  addCommentsList(element) {
48122
48122
  if (!this.config?.modules?.comments || this.config.role === "viewer") return;
48123
- console.debug("🦋 [superdoc] Adding comments list to:", element);
48123
+ this.#log("🦋 [superdoc] Adding comments list to:", element);
48124
48124
  if (element) this.config.modules.comments.element = element;
48125
48125
  this.commentsList = new SuperComments(this.config.modules?.comments, this);
48126
48126
  if (this.config.onCommentsListChange) this.config.onCommentsListChange({ isRendered: true });
@@ -48260,7 +48260,7 @@ class SuperDoc extends EventEmitter {
48260
48260
  lockSuperdoc(isLocked = false, lockedBy) {
48261
48261
  this.isLocked = isLocked;
48262
48262
  this.lockedBy = lockedBy;
48263
- console.debug("🦋 [superdoc] Locking superdoc:", isLocked, lockedBy, "\n\n\n");
48263
+ this.#log("🦋 [superdoc] Locking superdoc:", isLocked, lockedBy, "\n\n\n");
48264
48264
  this.emit("locked", { isLocked, lockedBy });
48265
48265
  }
48266
48266
  /**
@@ -48330,7 +48330,7 @@ class SuperDoc extends EventEmitter {
48330
48330
  * @returns {Promise<void>} Resolves when all documents have saved
48331
48331
  */
48332
48332
  async #triggerCollaborationSaves() {
48333
- console.debug("🦋 [superdoc] Triggering collaboration saves");
48333
+ this.#log("🦋 [superdoc] Triggering collaboration saves");
48334
48334
  return new Promise((resolve, reject) => {
48335
48335
  this.superdocStore.documents.forEach((doc) => {
48336
48336
  this.pendingCollaborationSaves = 0;
@@ -48359,9 +48359,9 @@ class SuperDoc extends EventEmitter {
48359
48359
  this.#triggerCollaborationSaves()
48360
48360
  // this.exportEditorsToDOCX(),
48361
48361
  ];
48362
- console.debug("🦋 [superdoc] Saving superdoc");
48362
+ this.#log("🦋 [superdoc] Saving superdoc");
48363
48363
  const result = await Promise.all(savePromises);
48364
- console.debug("🦋 [superdoc] Save complete:", result);
48364
+ this.#log("🦋 [superdoc] Save complete:", result);
48365
48365
  return result;
48366
48366
  }
48367
48367
  /**
@@ -48372,7 +48372,7 @@ class SuperDoc extends EventEmitter {
48372
48372
  if (!this.app) {
48373
48373
  return;
48374
48374
  }
48375
- this.log("[superdoc] Unmounting app");
48375
+ this.#log("[superdoc] Unmounting app");
48376
48376
  this.config.socket?.cancelWebsocketRetry();
48377
48377
  this.config.socket?.disconnect();
48378
48378
  this.config.socket?.destroy();
@@ -33478,7 +33478,7 @@
33478
33478
  const cellBordersElement = {
33479
33479
  name: "w:tcBorders",
33480
33480
  elements: Object.entries(borders).map(([key, value]) => {
33481
- if (!value.size) {
33481
+ if (!value.size || value.val === "none") {
33482
33482
  return {
33483
33483
  name: `w:${key}`,
33484
33484
  attributes: {
@@ -36298,7 +36298,7 @@
36298
36298
  return;
36299
36299
  }
36300
36300
  }
36301
- static updateDocumentVersion(docx = this.convertedXml, version2 = "0.15.7-next.1") {
36301
+ static updateDocumentVersion(docx = this.convertedXml, version2 = "0.15.7-next.2") {
36302
36302
  const customLocation = "docProps/custom.xml";
36303
36303
  if (!docx[customLocation]) {
36304
36304
  docx[customLocation] = generateCustomXml();
@@ -36777,7 +36777,7 @@
36777
36777
  function generateCustomXml() {
36778
36778
  return DEFAULT_CUSTOM_XML;
36779
36779
  }
36780
- function generateSuperdocVersion(pid = 2, version2 = "0.15.7-next.1") {
36780
+ function generateSuperdocVersion(pid = 2, version2 = "0.15.7-next.2") {
36781
36781
  return {
36782
36782
  type: "element",
36783
36783
  name: "property",
@@ -53104,7 +53104,7 @@
53104
53104
  * @returns {Object | void} Migration results
53105
53105
  */
53106
53106
  processCollaborationMigrations() {
53107
- console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.1");
53107
+ console.debug("[checkVersionMigrations] Current editor version", "0.15.7-next.2");
53108
53108
  if (!this.options.ydoc) return;
53109
53109
  const metaMap = this.options.ydoc.getMap("meta");
53110
53110
  let docVersion = metaMap.get("version");
@@ -99926,8 +99926,8 @@ ${style2}
99926
99926
  this.config.colors = shuffleArray(this.config.colors);
99927
99927
  this.userColorMap = /* @__PURE__ */ new Map();
99928
99928
  this.colorIndex = 0;
99929
- this.version = "0.15.7-next.1";
99930
- console.debug("🦋 [superdoc] Using SuperDoc version:", this.version);
99929
+ this.version = "0.15.7-next.2";
99930
+ this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
99931
99931
  this.superdocId = config.superdocId || v4();
99932
99932
  this.colors = this.config.colors;
99933
99933
  this.#initDocuments();
@@ -100144,8 +100144,8 @@ ${style2}
100144
100144
  broadcastSidebarToggle(isOpened) {
100145
100145
  this.emit("sidebar-toggle", isOpened);
100146
100146
  }
100147
- log(...args) {
100148
- console.debug("🦋 🦸‍♀️ [superdoc]", ...args);
100147
+ #log(...args) {
100148
+ (console.debug ? console.debug : console.log)("🦋 🦸‍♀️ [superdoc]", ...args);
100149
100149
  }
100150
100150
  /**
100151
100151
  * Set the active editor
@@ -100216,7 +100216,7 @@ ${style2}
100216
100216
  */
100217
100217
  addCommentsList(element) {
100218
100218
  if (!this.config?.modules?.comments || this.config.role === "viewer") return;
100219
- console.debug("🦋 [superdoc] Adding comments list to:", element);
100219
+ this.#log("🦋 [superdoc] Adding comments list to:", element);
100220
100220
  if (element) this.config.modules.comments.element = element;
100221
100221
  this.commentsList = new SuperComments(this.config.modules?.comments, this);
100222
100222
  if (this.config.onCommentsListChange) this.config.onCommentsListChange({ isRendered: true });
@@ -100356,7 +100356,7 @@ ${style2}
100356
100356
  lockSuperdoc(isLocked = false, lockedBy) {
100357
100357
  this.isLocked = isLocked;
100358
100358
  this.lockedBy = lockedBy;
100359
- console.debug("🦋 [superdoc] Locking superdoc:", isLocked, lockedBy, "\n\n\n");
100359
+ this.#log("🦋 [superdoc] Locking superdoc:", isLocked, lockedBy, "\n\n\n");
100360
100360
  this.emit("locked", { isLocked, lockedBy });
100361
100361
  }
100362
100362
  /**
@@ -100426,7 +100426,7 @@ ${style2}
100426
100426
  * @returns {Promise<void>} Resolves when all documents have saved
100427
100427
  */
100428
100428
  async #triggerCollaborationSaves() {
100429
- console.debug("🦋 [superdoc] Triggering collaboration saves");
100429
+ this.#log("🦋 [superdoc] Triggering collaboration saves");
100430
100430
  return new Promise((resolve2, reject) => {
100431
100431
  this.superdocStore.documents.forEach((doc2) => {
100432
100432
  this.pendingCollaborationSaves = 0;
@@ -100455,9 +100455,9 @@ ${style2}
100455
100455
  this.#triggerCollaborationSaves()
100456
100456
  // this.exportEditorsToDOCX(),
100457
100457
  ];
100458
- console.debug("🦋 [superdoc] Saving superdoc");
100458
+ this.#log("🦋 [superdoc] Saving superdoc");
100459
100459
  const result = await Promise.all(savePromises);
100460
- console.debug("🦋 [superdoc] Save complete:", result);
100460
+ this.#log("🦋 [superdoc] Save complete:", result);
100461
100461
  return result;
100462
100462
  }
100463
100463
  /**
@@ -100468,7 +100468,7 @@ ${style2}
100468
100468
  if (!this.app) {
100469
100469
  return;
100470
100470
  }
100471
- this.log("[superdoc] Unmounting app");
100471
+ this.#log("[superdoc] Unmounting app");
100472
100472
  this.config.socket?.cancelWebsocketRetry();
100473
100473
  this.config.socket?.disconnect();
100474
100474
  this.config.socket?.destroy();