superdoc 0.34.4 → 0.34.6
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.
- package/dist/chunks/{PdfViewer-CL_-YyBC.es.js → PdfViewer-BrE01k0i.es.js} +1 -1
- package/dist/chunks/{PdfViewer-CcDvbfeP.cjs → PdfViewer-BrSBsHiz.cjs} +1 -1
- package/dist/chunks/{index-DPjn4rpi-Bs9-iTbY.cjs → index-DD7_Re-5-B48aEbZz.cjs} +1 -1
- package/dist/chunks/{index-DPjn4rpi-BwmVppCt.es.js → index-DD7_Re-5-CzvmaphZ.es.js} +1 -1
- package/dist/chunks/{index-Cp_Yy4vP.cjs → index-GFozhkXc.cjs} +3 -3
- package/dist/chunks/{index-oLU8CBCH.es.js → index-ZlsBnxiE.es.js} +3 -3
- package/dist/chunks/{super-editor.es-C350__qM.es.js → super-editor.es-DyBhGWdJ.es.js} +55 -16
- package/dist/chunks/{super-editor.es-C2FJLfJa.cjs → super-editor.es-k87Y2gby.cjs} +55 -16
- package/dist/super-editor/ai-writer.es.js +2 -2
- package/dist/super-editor/chunks/{converter-KW3z-Mzc.js → converter-DW2wtoOn.js} +23 -6
- package/dist/super-editor/chunks/{docx-zipper-CYtxqNuc.js → docx-zipper-Bo5xY0tG.js} +1 -1
- package/dist/super-editor/chunks/{editor-CTHJwQNA.js → editor-VFipfW_y.js} +34 -12
- package/dist/super-editor/chunks/{index-DPjn4rpi.js → index-DD7_Re-5.js} +1 -1
- package/dist/super-editor/chunks/{toolbar-BUz0UuKQ.js → toolbar-B1x6Bp3N.js} +2 -2
- package/dist/super-editor/converter.es.js +1 -1
- package/dist/super-editor/docx-zipper.es.js +2 -2
- package/dist/super-editor/editor.es.js +3 -3
- package/dist/super-editor/file-zipper.es.js +1 -1
- package/dist/super-editor/super-editor/src/core/super-converter/helpers.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/core/super-converter/v3/handlers/w/del/del-translator.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/core/super-converter/v3/handlers/w/ins/ins-translator.d.ts.map +1 -1
- package/dist/super-editor/super-editor/src/extensions/structured-content/structured-content-commands.d.ts +5 -0
- package/dist/super-editor/super-editor/src/extensions/structured-content/structured-content-commands.d.ts.map +1 -1
- package/dist/super-editor/super-editor.es.js +6 -6
- package/dist/super-editor/toolbar.es.js +2 -2
- package/dist/super-editor.cjs +1 -1
- package/dist/super-editor.es.js +1 -1
- package/dist/superdoc.cjs +2 -2
- package/dist/superdoc.es.js +2 -2
- package/dist/superdoc.umd.js +57 -18
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { E } from "./chunks/editor-
|
|
2
|
-
import "./chunks/converter-
|
|
3
|
-
import "./chunks/docx-zipper-
|
|
1
|
+
import { E } from "./chunks/editor-VFipfW_y.js";
|
|
2
|
+
import "./chunks/converter-DW2wtoOn.js";
|
|
3
|
+
import "./chunks/docx-zipper-Bo5xY0tG.js";
|
|
4
4
|
export {
|
|
5
5
|
E as Editor
|
|
6
6
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/core/super-converter/helpers.js"],"names":[],"mappings":"AAGA,8BAAwB,EAAE,CAAC;AAE3B,mDAIC;AAED,kDAKC;AAED,kDAIC;AAED,mDAGC;AAQD,oDAIC;AAVD,oDAIC;AAQD,iDAGC;AAED,iDAGC;AAED,2DAGC;AAOD,8CAKC;AAED,6CAIC;AAED,wDAGC;AArBD,2DAGC;AAoBD,gEAKC;AAED,yDAGC;AAYD,+CAGC;AAED,mDAGC;AAgDD;;;;;;;GAOG;AACH,qCAHW,KAAK,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,GACrB,MAAO,IAAI,CAyCvB;AA7ED;;;;;;;GAOG;AACH,gDAFa,KAAK,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,GAAC,IAAI,CAsBxC;AAsED,4FAyDC;AAED,uEAKC;AAmCD,kEAGC;AAED,mEASC;AA5BD,iDAYC;AAkBD,qDAaC;AAOD,2CAEC;AA1QD,2CAGC;AARD,8CAGC;AA8QD;;;;
|
|
1
|
+
{"version":3,"file":"helpers.d.ts","sourceRoot":"","sources":["../../../../../src/core/super-converter/helpers.js"],"names":[],"mappings":"AAGA,8BAAwB,EAAE,CAAC;AAE3B,mDAIC;AAED,kDAKC;AAED,kDAIC;AAED,mDAGC;AAQD,oDAIC;AAVD,oDAIC;AAQD,iDAGC;AAED,iDAGC;AAED,2DAGC;AAOD,8CAKC;AAED,6CAIC;AAED,wDAGC;AArBD,2DAGC;AAoBD,gEAKC;AAED,yDAGC;AAYD,+CAGC;AAED,mDAGC;AAgDD;;;;;;;GAOG;AACH,qCAHW,KAAK,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,GACrB,MAAO,IAAI,CAyCvB;AA7ED;;;;;;;GAOG;AACH,gDAFa,KAAK,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC,GAAC,IAAI,CAsBxC;AAsED,4FAyDC;AAED,uEAKC;AAmCD,kEAGC;AAED,mEASC;AA5BD,iDAYC;AAkBD,qDAaC;AAOD,2CAEC;AA1QD,2CAGC;AARD,8CAGC;AA8QD;;;;EAUC;AAED,qEAuBC;AAED,0EAGC;AAtMD;;;;GAIG;AACH,iDAHW,MAAM,GAAC,MAAM,GACX,MAAM,CAWlB;AApGD,sDAKC;AAdD,0DAOC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"del-translator.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/core/super-converter/v3/handlers/w/del/del-translator.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"del-translator.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/core/super-converter/v3/handlers/w/del/del-translator.js"],"names":[],"mappings":"AAyFA,yDAAyD;AACzD,qBADW,OAAO,aAAa,EAAE,oBAAoB,CAQnD;AAEF;;;GAGG;AACH,yBAFU,OAAO,aAAa,EAAE,cAAc,CAEQ"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ins-translator.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/core/super-converter/v3/handlers/w/ins/ins-translator.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ins-translator.d.ts","sourceRoot":"","sources":["../../../../../../../../../src/core/super-converter/v3/handlers/w/ins/ins-translator.js"],"names":[],"mappings":"AAsFA,yDAAyD;AACzD,qBADW,OAAO,aAAa,EAAE,oBAAoB,CAQnD;AAEF;;;GAGG;AACH,yBAFU,OAAO,aAAa,EAAE,cAAc,CAEQ"}
|
|
@@ -18,6 +18,7 @@
|
|
|
18
18
|
* @property {string} [html] - Replace content with HTML (only for structured content block)
|
|
19
19
|
* @property {Object} [json] - Replace content with ProseMirror JSON (overrides html)
|
|
20
20
|
* @property {Object} [attrs] - Update attributes only (preserves content)
|
|
21
|
+
* @property {boolean} [keepTextNodeStyles] - When true, preserves marks from the first text node (only applies with text option)
|
|
21
22
|
*/
|
|
22
23
|
/**
|
|
23
24
|
* @typedef {Object} StructuredContentTableAppendRowsOptions
|
|
@@ -76,6 +77,10 @@ export type StructuredContentUpdate = {
|
|
|
76
77
|
* - Update attributes only (preserves content)
|
|
77
78
|
*/
|
|
78
79
|
attrs?: any;
|
|
80
|
+
/**
|
|
81
|
+
* - When true, preserves marks from the first text node (only applies with text option)
|
|
82
|
+
*/
|
|
83
|
+
keepTextNodeStyles?: boolean;
|
|
79
84
|
};
|
|
80
85
|
export type StructuredContentTableAppendRowsOptions = {
|
|
81
86
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"structured-content-commands.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/structured-content/structured-content-commands.js"],"names":[],"mappings":"AAYA;;;;;;GAMG;AAEH;;;;;;GAMG;AAEH
|
|
1
|
+
{"version":3,"file":"structured-content-commands.d.ts","sourceRoot":"","sources":["../../../../../src/extensions/structured-content/structured-content-commands.js"],"names":[],"mappings":"AAYA;;;;;;GAMG;AAEH;;;;;;GAMG;AAEH;;;;;;;GAOG;AAEH;;;;;;GAMG;AAEH,kDAgfG;;;;;WA/gBW,MAAM;;;;;;;;YAGjB;QAA0B,KAAK,GAApB,MAAM;KACnB;;;;;;WAIa,MAAM;;;;;;;;YAGjB;QAA0B,KAAK,GAApB,MAAM;KACnB;;;;;;WAIa,MAAM;;;;WACN,MAAM;;;;;;;;;;;;yBAGN,OAAO;;;;;;QAKP,MAAM;;;;iBACN,MAAM;;;;UACN,KAAK,CAAC,MAAM,EAAE,CAAC,GAAC,KAAK,CAAC,MAAM,CAAC;;;;mBAC7B,OAAO;;0BAzCK,aAAa"}
|
|
@@ -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, enrichTrackedChanges_fn, runCommandWithArgumentOnly_fn;
|
|
12
|
-
import { aA as getDefaultExportFromCjs, V as v4, T as TextSelection$1, v as getMarkRange, aD as vClickOutside, aE as getActiveFormatting, av as isInTable, aF as readFromClipboard, aG as handleClipboardPaste, aH as getFileObject, aI as runPropertyTranslators, aJ as translator, aK as translator$1, aL as translator$2, aM as translator$3, aN as translator$4, aO as translator$5, aP as translator$6, aQ as translator$7, aR as translator$8, aS as translator$9, aT as translator$a, aU as translator$b, aV as translator$c, aW as translator$d, aX as translator$e, aY as commentRangeEndTranslator, aZ as commentRangeStartTranslator, a_ as translator$f, a$ as translator$g, b0 as translator$h, b1 as translator$i, b2 as translator$j, b3 as translator$k, b4 as translator$l, b5 as translator$m, b6 as translator$n, b7 as translator$o, b8 as translator$p, b9 as translator$q, ba as translator$r, bb as translator$s, bc as translator$t, bd as translator$u, be as translator$v, bf as translator$w, bg as translator$x, bh as translator$y, bi as translator$z, bj as translator$A, bk as translator$B, bl as translator$C, bm as translator$D, bn as translator$E, bo as translator$F, bp as translator$G, bq as translator$H, br as translator$I, bs as translator$J, bt as translator$K, bu as translator$L, bv as translator$M, bw as translator$N, bx as translator$O, by as translator$P, bz as translator$Q, bA as translator$R, bB as translator$S, bC as translator$T, bD as translator$U, bE as translator$V, bF as translator$W, bG as translator$X, bH as translator$Y, bI as translator$Z, bJ as translator$_, bK as translator$$, bL as translator$10, bM as translator$11, bN as translator$12, bO as translator$13, bP as translator$14, bQ as translator$15, bR as translator$16, bS as translator$17, bT as translator$18, bU as translator$19, bV as translator$1a, bW as translator$1b, bX as translator$1c, bY as translator$1d, bZ as translator$1e, b_ as translator$1f, b$ as translator$1g, c0 as translator$1h, P as PluginKey, a as Plugin } from "./chunks/converter-
|
|
13
|
-
import { a5, i, a2 } from "./chunks/converter-
|
|
14
|
-
import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as collectTargetListItemPositions, d as getFileOpener, e as checkAndProcessImage, r as replaceSelectionWithImagePlaceholder, f as uploadAndInsertImage, h as collectTrackedChanges, i as isTrackedChangeActionAllowed, y as yUndoPluginKey, j as undoDepth, k as redoDepth, l as collectTrackedChangesForContext, s as shouldBypassContextMenu, S as SlashMenuPluginKey, m as isHeadless, E as Editor, n as getStarterExtensions, P as Placeholder, o as getRichTextExtensions, D as DecorationSet, p as Decoration, M as Mark, q as Extension, A as Attribute, N as Node } from "./chunks/editor-
|
|
15
|
-
import { w, C, x, T, t, z, v } from "./chunks/editor-
|
|
12
|
+
import { aA as getDefaultExportFromCjs, V as v4, T as TextSelection$1, v as getMarkRange, aD as vClickOutside, aE as getActiveFormatting, av as isInTable, aF as readFromClipboard, aG as handleClipboardPaste, aH as getFileObject, aI as runPropertyTranslators, aJ as translator, aK as translator$1, aL as translator$2, aM as translator$3, aN as translator$4, aO as translator$5, aP as translator$6, aQ as translator$7, aR as translator$8, aS as translator$9, aT as translator$a, aU as translator$b, aV as translator$c, aW as translator$d, aX as translator$e, aY as commentRangeEndTranslator, aZ as commentRangeStartTranslator, a_ as translator$f, a$ as translator$g, b0 as translator$h, b1 as translator$i, b2 as translator$j, b3 as translator$k, b4 as translator$l, b5 as translator$m, b6 as translator$n, b7 as translator$o, b8 as translator$p, b9 as translator$q, ba as translator$r, bb as translator$s, bc as translator$t, bd as translator$u, be as translator$v, bf as translator$w, bg as translator$x, bh as translator$y, bi as translator$z, bj as translator$A, bk as translator$B, bl as translator$C, bm as translator$D, bn as translator$E, bo as translator$F, bp as translator$G, bq as translator$H, br as translator$I, bs as translator$J, bt as translator$K, bu as translator$L, bv as translator$M, bw as translator$N, bx as translator$O, by as translator$P, bz as translator$Q, bA as translator$R, bB as translator$S, bC as translator$T, bD as translator$U, bE as translator$V, bF as translator$W, bG as translator$X, bH as translator$Y, bI as translator$Z, bJ as translator$_, bK as translator$$, bL as translator$10, bM as translator$11, bN as translator$12, bO as translator$13, bP as translator$14, bQ as translator$15, bR as translator$16, bS as translator$17, bT as translator$18, bU as translator$19, bV as translator$1a, bW as translator$1b, bX as translator$1c, bY as translator$1d, bZ as translator$1e, b_ as translator$1f, b$ as translator$1g, c0 as translator$1h, P as PluginKey, a as Plugin } from "./chunks/converter-DW2wtoOn.js";
|
|
13
|
+
import { a5, i, a2 } from "./chunks/converter-DW2wtoOn.js";
|
|
14
|
+
import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as collectTargetListItemPositions, d as getFileOpener, e as checkAndProcessImage, r as replaceSelectionWithImagePlaceholder, f as uploadAndInsertImage, h as collectTrackedChanges, i as isTrackedChangeActionAllowed, y as yUndoPluginKey, j as undoDepth, k as redoDepth, l as collectTrackedChangesForContext, s as shouldBypassContextMenu, S as SlashMenuPluginKey, m as isHeadless, E as Editor, n as getStarterExtensions, P as Placeholder, o as getRichTextExtensions, D as DecorationSet, p as Decoration, M as Mark, q as Extension, A as Attribute, N as Node } from "./chunks/editor-VFipfW_y.js";
|
|
15
|
+
import { w, C, x, T, t, z, v } from "./chunks/editor-VFipfW_y.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, defineComponent, reactive, onUnmounted, renderSlot, shallowRef, createBlock, withCtx, resolveDynamicComponent, normalizeProps, guardReactiveProps } from "vue";
|
|
17
|
-
import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, p as plusIconSvg, a as trashIconSvg, b as borderNoneIconSvg, c as arrowsToDotIconSvg, d as arrowsLeftRightIconSvg, w as wrenchIconSvg, m as magicWandIcon, e as checkIconSvg$1, x as xMarkIconSvg, l as linkIconSvg, f as tableIconSvg, g as scissorsIconSvg, h as copyIconSvg, i as pasteIconSvg, u as useMessage, N as NSkeleton } from "./chunks/toolbar-
|
|
17
|
+
import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, p as plusIconSvg, a as trashIconSvg, b as borderNoneIconSvg, c as arrowsToDotIconSvg, d as arrowsLeftRightIconSvg, w as wrenchIconSvg, m as magicWandIcon, e as checkIconSvg$1, x as xMarkIconSvg, l as linkIconSvg, f as tableIconSvg, g as scissorsIconSvg, h as copyIconSvg, i as pasteIconSvg, u as useMessage, N as NSkeleton } from "./chunks/toolbar-B1x6Bp3N.js";
|
|
18
18
|
import AIWriter from "./ai-writer.es.js";
|
|
19
|
-
import { D } from "./chunks/docx-zipper-
|
|
19
|
+
import { D } from "./chunks/docx-zipper-Bo5xY0tG.js";
|
|
20
20
|
import { createZip } from "./file-zipper.es.js";
|
|
21
21
|
var eventemitter3 = { exports: {} };
|
|
22
22
|
var hasRequiredEventemitter3;
|
package/dist/super-editor.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-
|
|
3
|
+
const superEditor_es = require("./chunks/super-editor.es-k87Y2gby.cjs");
|
|
4
4
|
require("./chunks/vue-Cwv-wUpm.cjs");
|
|
5
5
|
exports.AIWriter = superEditor_es.AIWriter;
|
|
6
6
|
exports.AnnotatorHelpers = superEditor_es.AnnotatorHelpers;
|
package/dist/super-editor.es.js
CHANGED
|
@@ -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, r, q } from "./chunks/super-editor.es-
|
|
1
|
+
import { A, a, _, C, D, E, b, S, c, d, e, f, g, T, h, i, j, k, l, m, n, o, p, r, q } from "./chunks/super-editor.es-DyBhGWdJ.es.js";
|
|
2
2
|
import "./chunks/vue-CKmzTNVs.es.js";
|
|
3
3
|
export {
|
|
4
4
|
A as AIWriter,
|
package/dist/superdoc.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const superEditor_es = require("./chunks/super-editor.es-
|
|
4
|
-
const superdoc = require("./chunks/index-
|
|
3
|
+
const superEditor_es = require("./chunks/super-editor.es-k87Y2gby.cjs");
|
|
4
|
+
const superdoc = require("./chunks/index-GFozhkXc.cjs");
|
|
5
5
|
const blankDocx = require("./chunks/blank-docx-DfW3Eeh2.cjs");
|
|
6
6
|
exports.AnnotatorHelpers = superEditor_es.AnnotatorHelpers;
|
|
7
7
|
exports.Editor = superEditor_es.Editor;
|
package/dist/superdoc.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a, E, b, S, d, i, j, n, r, p, q } from "./chunks/super-editor.es-
|
|
2
|
-
import { D, H, P, S as S2, m, l } from "./chunks/index-
|
|
1
|
+
import { a, E, b, S, d, i, j, n, r, p, q } from "./chunks/super-editor.es-DyBhGWdJ.es.js";
|
|
2
|
+
import { D, H, P, S as S2, m, l } from "./chunks/index-ZlsBnxiE.es.js";
|
|
3
3
|
import { B } from "./chunks/blank-docx-ABm6XYAA.es.js";
|
|
4
4
|
export {
|
|
5
5
|
a as AnnotatorHelpers,
|
package/dist/superdoc.umd.js
CHANGED
|
@@ -15398,6 +15398,9 @@
|
|
|
15398
15398
|
let [value, unit] = parseSizeUnit(lineHeight2);
|
|
15399
15399
|
if (Number.isNaN(value) || value === 0) return {};
|
|
15400
15400
|
if (lineRule === "atLeast" && value < 1) return {};
|
|
15401
|
+
if (!unit && value < 1) {
|
|
15402
|
+
value = 1;
|
|
15403
|
+
}
|
|
15401
15404
|
unit = unit ? unit : defaultUnit;
|
|
15402
15405
|
return isObject2 ? { ["line-height"]: `${value}${unit}` } : `line-height: ${value}${unit}`;
|
|
15403
15406
|
};
|
|
@@ -32359,8 +32362,15 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
32359
32362
|
});
|
|
32360
32363
|
encodedAttrs.importedAuthor = `${encodedAttrs.author} (imported)`;
|
|
32361
32364
|
subs.forEach((subElement) => {
|
|
32362
|
-
|
|
32363
|
-
subElement
|
|
32365
|
+
subElement.marks = [];
|
|
32366
|
+
if (subElement?.content?.[0]) {
|
|
32367
|
+
if (subElement.content[0].marks === void 0) {
|
|
32368
|
+
subElement.content[0].marks = [];
|
|
32369
|
+
}
|
|
32370
|
+
if (subElement.content[0].type === "text") {
|
|
32371
|
+
subElement.content[0].marks.push({ type: "trackDelete", attrs: encodedAttrs });
|
|
32372
|
+
}
|
|
32373
|
+
}
|
|
32364
32374
|
});
|
|
32365
32375
|
return subs;
|
|
32366
32376
|
};
|
|
@@ -32419,8 +32429,15 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
32419
32429
|
});
|
|
32420
32430
|
encodedAttrs.importedAuthor = `${encodedAttrs.author} (imported)`;
|
|
32421
32431
|
subs.forEach((subElement) => {
|
|
32422
|
-
|
|
32423
|
-
subElement
|
|
32432
|
+
subElement.marks = [];
|
|
32433
|
+
if (subElement?.content?.[0]) {
|
|
32434
|
+
if (subElement.content[0].marks === void 0) {
|
|
32435
|
+
subElement.content[0].marks = [];
|
|
32436
|
+
}
|
|
32437
|
+
if (subElement.content[0].type === "text") {
|
|
32438
|
+
subElement.content[0].marks.push({ type: "trackInsert", attrs: encodedAttrs });
|
|
32439
|
+
}
|
|
32440
|
+
}
|
|
32424
32441
|
});
|
|
32425
32442
|
return subs;
|
|
32426
32443
|
};
|
|
@@ -35463,7 +35480,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
35463
35480
|
name: "w16cex:commentExtensible",
|
|
35464
35481
|
attributes: {
|
|
35465
35482
|
"w16cex:durableId": newDurableId,
|
|
35466
|
-
"w16cex:dateUtc": toIsoNoFractional()
|
|
35483
|
+
"w16cex:dateUtc": toIsoNoFractional(comment2.createdTime)
|
|
35467
35484
|
}
|
|
35468
35485
|
};
|
|
35469
35486
|
extensibleUpdated.elements[0].elements.push(newExtensible);
|
|
@@ -35776,7 +35793,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
35776
35793
|
static getStoredSuperdocVersion(docx) {
|
|
35777
35794
|
return _SuperConverter2.getStoredCustomProperty(docx, "SuperdocVersion");
|
|
35778
35795
|
}
|
|
35779
|
-
static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "0.34.
|
|
35796
|
+
static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "0.34.6") {
|
|
35780
35797
|
return _SuperConverter2.setStoredCustomProperty(docx, "SuperdocVersion", version2, false);
|
|
35781
35798
|
}
|
|
35782
35799
|
/**
|
|
@@ -61813,7 +61830,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
61813
61830
|
{ default: remarkStringify2 },
|
|
61814
61831
|
{ default: remarkGfm2 }
|
|
61815
61832
|
] = await Promise.all([
|
|
61816
|
-
Promise.resolve().then(() =>
|
|
61833
|
+
Promise.resolve().then(() => indexDD7_Re5),
|
|
61817
61834
|
Promise.resolve().then(() => indexDRCvimau),
|
|
61818
61835
|
Promise.resolve().then(() => indexC_x_N6Uh),
|
|
61819
61836
|
Promise.resolve().then(() => indexD_sWOSiG),
|
|
@@ -62031,7 +62048,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
62031
62048
|
* @returns {Object | void} Migration results
|
|
62032
62049
|
*/
|
|
62033
62050
|
processCollaborationMigrations() {
|
|
62034
|
-
console.debug("[checkVersionMigrations] Current editor version", "0.34.
|
|
62051
|
+
console.debug("[checkVersionMigrations] Current editor version", "0.34.6");
|
|
62035
62052
|
if (!this.options.ydoc) return;
|
|
62036
62053
|
const metaMap = this.options.ydoc.getMap("meta");
|
|
62037
62054
|
let docVersion = metaMap.get("version");
|
|
@@ -64668,7 +64685,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
64668
64685
|
* @param {string} id - Unique identifier of the field
|
|
64669
64686
|
* @param {StructuredContentUpdate} options
|
|
64670
64687
|
* @example
|
|
64671
|
-
* editor.commands.updateStructuredContentById('123', { text: 'Jane Doe' });
|
|
64688
|
+
* editor.commands.updateStructuredContentById('123', { text: 'Jane Doe', keepTextNodeStyles: true });
|
|
64672
64689
|
* editor.commands.updateStructuredContentById('123', {
|
|
64673
64690
|
* json: { type: 'text', text: 'Jane Doe' },
|
|
64674
64691
|
* });
|
|
@@ -64689,7 +64706,9 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
64689
64706
|
const posTo = pos + node2.nodeSize;
|
|
64690
64707
|
let content2 = null;
|
|
64691
64708
|
if (options.text) {
|
|
64692
|
-
|
|
64709
|
+
const firstTextNode = options.keepTextNodeStyles === true ? node2.content.content.find((n) => n.type.name === "text") : null;
|
|
64710
|
+
const textMarks = firstTextNode ? firstTextNode.marks : [];
|
|
64711
|
+
content2 = schema.text(options.text, textMarks);
|
|
64693
64712
|
}
|
|
64694
64713
|
if (options.html) {
|
|
64695
64714
|
const html2 = htmlHandler(options.html, editor);
|
|
@@ -64703,6 +64722,13 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
64703
64722
|
content2 = node2.content;
|
|
64704
64723
|
}
|
|
64705
64724
|
const updatedNode = node2.type.create({ ...node2.attrs, ...options.attrs }, content2, node2.marks);
|
|
64725
|
+
try {
|
|
64726
|
+
const nodeForValidation = editor.validateJSON(updatedNode.toJSON());
|
|
64727
|
+
nodeForValidation.check();
|
|
64728
|
+
} catch (error) {
|
|
64729
|
+
console.error("Invalid content.", "Passed value:", content2, "Error:", error);
|
|
64730
|
+
return false;
|
|
64731
|
+
}
|
|
64706
64732
|
tr.replaceWith(posFrom, posTo, updatedNode);
|
|
64707
64733
|
}
|
|
64708
64734
|
return true;
|
|
@@ -64787,7 +64813,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
64787
64813
|
* @param {StructuredContentUpdate} options
|
|
64788
64814
|
* @example
|
|
64789
64815
|
* // Update all fields in the customer-info group
|
|
64790
|
-
* editor.commands.updateStructuredContentByGroup('customer-info', { text: 'Jane Doe' });
|
|
64816
|
+
* editor.commands.updateStructuredContentByGroup('customer-info', { text: 'Jane Doe', keepTextNodeStyles: true });
|
|
64791
64817
|
*
|
|
64792
64818
|
* // Update block content in a group
|
|
64793
64819
|
* editor.commands.updateStructuredContentByGroup('terms-section', {
|
|
@@ -64801,13 +64827,14 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
64801
64827
|
}
|
|
64802
64828
|
const { schema } = editor;
|
|
64803
64829
|
if (dispatch) {
|
|
64804
|
-
|
|
64830
|
+
const updates = [];
|
|
64831
|
+
for (const structuredContent of structuredContentTags) {
|
|
64805
64832
|
const { pos, node: node2 } = structuredContent;
|
|
64806
|
-
const posFrom = tr.mapping.map(pos);
|
|
64807
|
-
const posTo = tr.mapping.map(pos + node2.nodeSize);
|
|
64808
64833
|
let content2 = null;
|
|
64809
64834
|
if (options.text) {
|
|
64810
|
-
|
|
64835
|
+
const firstTextNode = options.keepTextNodeStyles === true ? node2.content.content.find((n) => n.type.name === "text") : null;
|
|
64836
|
+
const textMarks = firstTextNode ? firstTextNode.marks : [];
|
|
64837
|
+
content2 = schema.text(options.text, textMarks);
|
|
64811
64838
|
}
|
|
64812
64839
|
if (options.html) {
|
|
64813
64840
|
const html2 = htmlHandler(options.html, editor);
|
|
@@ -64821,11 +64848,23 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
64821
64848
|
content2 = node2.content;
|
|
64822
64849
|
}
|
|
64823
64850
|
const updatedNode = node2.type.create({ ...node2.attrs, ...options.attrs }, content2, node2.marks);
|
|
64851
|
+
try {
|
|
64852
|
+
const nodeForValidation = editor.validateJSON(updatedNode.toJSON());
|
|
64853
|
+
nodeForValidation.check();
|
|
64854
|
+
} catch (error) {
|
|
64855
|
+
console.error("Invalid content.", "Passed value:", content2, "Error:", error);
|
|
64856
|
+
return false;
|
|
64857
|
+
}
|
|
64858
|
+
updates.push({ pos, node: node2, updatedNode });
|
|
64859
|
+
}
|
|
64860
|
+
for (const { pos, node: node2, updatedNode } of updates) {
|
|
64861
|
+
const posFrom = tr.mapping.map(pos);
|
|
64862
|
+
const posTo = tr.mapping.map(pos + node2.nodeSize);
|
|
64824
64863
|
const currentNode = tr.doc.nodeAt(posFrom);
|
|
64825
64864
|
if (currentNode && node2.eq(currentNode)) {
|
|
64826
64865
|
tr.replaceWith(posFrom, posTo, updatedNode);
|
|
64827
64866
|
}
|
|
64828
|
-
}
|
|
64867
|
+
}
|
|
64829
64868
|
}
|
|
64830
64869
|
return true;
|
|
64831
64870
|
},
|
|
@@ -118478,7 +118517,7 @@ ${style2}
|
|
|
118478
118517
|
this.config.colors = shuffleArray(this.config.colors);
|
|
118479
118518
|
this.userColorMap = /* @__PURE__ */ new Map();
|
|
118480
118519
|
this.colorIndex = 0;
|
|
118481
|
-
this.version = "0.34.
|
|
118520
|
+
this.version = "0.34.6";
|
|
118482
118521
|
this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
|
|
118483
118522
|
this.superdocId = config2.superdocId || v4();
|
|
118484
118523
|
this.colors = this.config.colors;
|
|
@@ -120878,7 +120917,7 @@ ${style2}
|
|
|
120878
120917
|
value && typeof value === "object" && "byteLength" in value && "byteOffset" in value
|
|
120879
120918
|
);
|
|
120880
120919
|
}
|
|
120881
|
-
const
|
|
120920
|
+
const indexDD7_Re5 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
120882
120921
|
__proto__: null,
|
|
120883
120922
|
unified
|
|
120884
120923
|
}, Symbol.toStringTag, { value: "Module" }));
|