@harbour-enterprises/superdoc 0.23.0-next.17 → 0.23.0-next.18
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-ytL49tCj.cjs → PdfViewer-CDdQi-IL.cjs} +1 -1
- package/dist/chunks/{PdfViewer-DOQw-QBT.es.js → PdfViewer-DxaT6YJk.es.js} +1 -1
- package/dist/chunks/{index-BjP_ixoM.es.js → index-CASMW4Gt.es.js} +2 -2
- package/dist/chunks/{index-TI9YfKQC.cjs → index-Ua6WmvV9.cjs} +2 -2
- package/dist/chunks/{super-editor.es-DMLpNrBd.cjs → super-editor.es-BHP7saSr.cjs} +18 -4
- package/dist/chunks/{super-editor.es-BIrzz0Is.es.js → super-editor.es-JTB_jHfC.es.js} +18 -4
- package/dist/super-editor/ai-writer.es.js +1 -1
- package/dist/super-editor/chunks/{editor-CXHr0RmK.js → editor-D8ueJVyp.js} +18 -4
- package/dist/super-editor/chunks/{toolbar-BytYAx8O.js → toolbar-CXzGZEvz.js} +1 -1
- package/dist/super-editor/editor.es.js +1 -1
- package/dist/super-editor/super-editor.es.js +3 -3
- 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 +18 -4
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const vue = require("./vue-DKMj1I9B.cjs");
|
|
4
|
-
const superdoc = require("./index-
|
|
4
|
+
const superdoc = require("./index-Ua6WmvV9.cjs");
|
|
5
5
|
function self(vars) {
|
|
6
6
|
const {
|
|
7
7
|
opacityDisabled,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { m as defineComponent, B as h, O as Transition, $ as process$1, I as watchEffect, d as computed, r as ref, j as onMounted, W as onUnmounted, c as createElementBlock, o as openBlock, a as createBaseVNode, f as createCommentVNode, v as createVNode, x as unref } from "./vue-ZWZLQtoU.es.js";
|
|
2
|
-
import { d as derived, c, a as cB, f as fadeInTransition, b as cM, N as NBaseLoading, w as warnOnce, u as useConfig, e as useTheme, p as pxfy, g as createKey, h as useThemeClass, i as useCompitable, _ as _export_sfc, j as useSuperdocStore, s as storeToRefs, k as useSelection } from "./index-
|
|
2
|
+
import { d as derived, c, a as cB, f as fadeInTransition, b as cM, N as NBaseLoading, w as warnOnce, u as useConfig, e as useTheme, p as pxfy, g as createKey, h as useThemeClass, i as useCompitable, _ as _export_sfc, j as useSuperdocStore, s as storeToRefs, k as useSelection } from "./index-CASMW4Gt.es.js";
|
|
3
3
|
function self(vars) {
|
|
4
4
|
const {
|
|
5
5
|
opacityDisabled,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { q as index, 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 "./super-editor.es-
|
|
1
|
+
import { q as index, 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 "./super-editor.es-JTB_jHfC.es.js";
|
|
2
2
|
import { a0 as effectScope, r as ref, _ as markRaw, $ as process$1, a1 as toRaw, d as computed, a2 as isRef, a3 as isReactive, C as toRef, i as inject, p as getCurrentInstance, l as watch, x as unref, a4 as hasInjectionContext, M as reactive, s as nextTick, a5 as getCurrentScope, a6 as onScopeDispose, a7 as toRefs, g as global$1, J as shallowRef, N as readonly, j as onMounted, k as onBeforeUnmount, h as onBeforeMount, S as onActivated, q as onDeactivated, z as createTextVNode, F as Fragment, Q as Comment, m as defineComponent, D as provide, H as withDirectives, B as h, U as Teleport, R as renderSlot, V as isVNode, I as watchEffect, O as Transition, a8 as TransitionGroup, E as mergeProps, P as vShow, G as cloneVNode, T as Text, c as createElementBlock, o as openBlock, t as toDisplayString, v as createVNode, y as withCtx, a as createBaseVNode, A as normalizeStyle, f as createCommentVNode, u as createBlock, w as withModifiers, n as normalizeClass, a9 as resolveDirective, e as renderList, b as createApp, X as resolveDynamicComponent, aa as defineAsyncComponent } from "./vue-ZWZLQtoU.es.js";
|
|
3
3
|
import { B as BlankDOCX } from "./blank-docx-iwdyG9RH.es.js";
|
|
4
4
|
import { E as EventEmitter } from "./eventemitter3-BWEnUdTY.es.js";
|
|
@@ -17099,7 +17099,7 @@ const _sfc_main = {
|
|
|
17099
17099
|
__name: "SuperDoc",
|
|
17100
17100
|
emits: ["selection-update"],
|
|
17101
17101
|
setup(__props, { emit: __emit }) {
|
|
17102
|
-
const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-
|
|
17102
|
+
const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-DxaT6YJk.es.js"));
|
|
17103
17103
|
const superdocStore = useSuperdocStore();
|
|
17104
17104
|
const commentsStore = useCommentsStore();
|
|
17105
17105
|
const {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
const superEditor_es = require("./super-editor.es-
|
|
2
|
+
const superEditor_es = require("./super-editor.es-BHP7saSr.cjs");
|
|
3
3
|
const vue = require("./vue-DKMj1I9B.cjs");
|
|
4
4
|
const blankDocx = require("./blank-docx-CPqX9RF5.cjs");
|
|
5
5
|
const eventemitter3 = require("./eventemitter3-DkXkH2rT.cjs");
|
|
@@ -17116,7 +17116,7 @@ const _sfc_main = {
|
|
|
17116
17116
|
__name: "SuperDoc",
|
|
17117
17117
|
emits: ["selection-update"],
|
|
17118
17118
|
setup(__props, { emit: __emit }) {
|
|
17119
|
-
const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-
|
|
17119
|
+
const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-CDdQi-IL.cjs")));
|
|
17120
17120
|
const superdocStore = useSuperdocStore();
|
|
17121
17121
|
const commentsStore = useCommentsStore();
|
|
17122
17122
|
const {
|
|
@@ -66204,11 +66204,25 @@ const getChangesByIdToResolve = (state2, id) => {
|
|
|
66204
66204
|
const matchingChange = trackedChanges[changeIndex];
|
|
66205
66205
|
const prev = trackedChanges[changeIndex - 1];
|
|
66206
66206
|
const next = trackedChanges[changeIndex + 1];
|
|
66207
|
+
const matchingMarkType = matchingChange.mark.type.name;
|
|
66207
66208
|
let linkedChange;
|
|
66208
|
-
if (prev && matchingChange.
|
|
66209
|
-
|
|
66210
|
-
|
|
66211
|
-
|
|
66209
|
+
if (prev && matchingChange.from === prev.to) {
|
|
66210
|
+
const prevMarkType = prev.mark.type.name;
|
|
66211
|
+
if (matchingMarkType === TrackDeleteMarkName && prevMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && prevMarkType === TrackDeleteMarkName) {
|
|
66212
|
+
const hasContentBetween = state2.doc.textBetween(prev.from, matchingChange.to, "\n").length > prev.to - prev.from + (matchingChange.to - matchingChange.from);
|
|
66213
|
+
if (!hasContentBetween) {
|
|
66214
|
+
linkedChange = prev;
|
|
66215
|
+
}
|
|
66216
|
+
}
|
|
66217
|
+
}
|
|
66218
|
+
if (!linkedChange && next && matchingChange.to === next.from) {
|
|
66219
|
+
const nextMarkType = next.mark.type.name;
|
|
66220
|
+
if (matchingMarkType === TrackDeleteMarkName && nextMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && nextMarkType === TrackDeleteMarkName) {
|
|
66221
|
+
const hasContentBetween = state2.doc.textBetween(matchingChange.from, next.to, "\n").length > matchingChange.to - matchingChange.from + (next.to - next.from);
|
|
66222
|
+
if (!hasContentBetween) {
|
|
66223
|
+
linkedChange = next;
|
|
66224
|
+
}
|
|
66225
|
+
}
|
|
66212
66226
|
}
|
|
66213
66227
|
return [matchingChange, linkedChange].filter(Boolean);
|
|
66214
66228
|
};
|
|
@@ -66187,11 +66187,25 @@ const getChangesByIdToResolve = (state2, id) => {
|
|
|
66187
66187
|
const matchingChange = trackedChanges[changeIndex];
|
|
66188
66188
|
const prev = trackedChanges[changeIndex - 1];
|
|
66189
66189
|
const next = trackedChanges[changeIndex + 1];
|
|
66190
|
+
const matchingMarkType = matchingChange.mark.type.name;
|
|
66190
66191
|
let linkedChange;
|
|
66191
|
-
if (prev && matchingChange.
|
|
66192
|
-
|
|
66193
|
-
|
|
66194
|
-
|
|
66192
|
+
if (prev && matchingChange.from === prev.to) {
|
|
66193
|
+
const prevMarkType = prev.mark.type.name;
|
|
66194
|
+
if (matchingMarkType === TrackDeleteMarkName && prevMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && prevMarkType === TrackDeleteMarkName) {
|
|
66195
|
+
const hasContentBetween = state2.doc.textBetween(prev.from, matchingChange.to, "\n").length > prev.to - prev.from + (matchingChange.to - matchingChange.from);
|
|
66196
|
+
if (!hasContentBetween) {
|
|
66197
|
+
linkedChange = prev;
|
|
66198
|
+
}
|
|
66199
|
+
}
|
|
66200
|
+
}
|
|
66201
|
+
if (!linkedChange && next && matchingChange.to === next.from) {
|
|
66202
|
+
const nextMarkType = next.mark.type.name;
|
|
66203
|
+
if (matchingMarkType === TrackDeleteMarkName && nextMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && nextMarkType === TrackDeleteMarkName) {
|
|
66204
|
+
const hasContentBetween = state2.doc.textBetween(matchingChange.from, next.to, "\n").length > matchingChange.to - matchingChange.from + (next.to - next.from);
|
|
66205
|
+
if (!hasContentBetween) {
|
|
66206
|
+
linkedChange = next;
|
|
66207
|
+
}
|
|
66208
|
+
}
|
|
66195
66209
|
}
|
|
66196
66210
|
return [matchingChange, linkedChange].filter(Boolean);
|
|
66197
66211
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ref, onMounted, onUnmounted, computed, createElementBlock, openBlock, withModifiers, createElementVNode, withDirectives, unref, vModelText, createCommentVNode, nextTick } from "vue";
|
|
2
2
|
import { T as TextSelection } from "./chunks/converter-wrgxIFCy.js";
|
|
3
|
-
import { _ as _export_sfc } from "./chunks/editor-
|
|
3
|
+
import { _ as _export_sfc } from "./chunks/editor-D8ueJVyp.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 = {}) {
|
|
@@ -28866,11 +28866,25 @@ const getChangesByIdToResolve = (state, id) => {
|
|
|
28866
28866
|
const matchingChange = trackedChanges[changeIndex];
|
|
28867
28867
|
const prev = trackedChanges[changeIndex - 1];
|
|
28868
28868
|
const next = trackedChanges[changeIndex + 1];
|
|
28869
|
+
const matchingMarkType = matchingChange.mark.type.name;
|
|
28869
28870
|
let linkedChange;
|
|
28870
|
-
if (prev && matchingChange.
|
|
28871
|
-
|
|
28872
|
-
|
|
28873
|
-
|
|
28871
|
+
if (prev && matchingChange.from === prev.to) {
|
|
28872
|
+
const prevMarkType = prev.mark.type.name;
|
|
28873
|
+
if (matchingMarkType === TrackDeleteMarkName && prevMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && prevMarkType === TrackDeleteMarkName) {
|
|
28874
|
+
const hasContentBetween = state.doc.textBetween(prev.from, matchingChange.to, "\n").length > prev.to - prev.from + (matchingChange.to - matchingChange.from);
|
|
28875
|
+
if (!hasContentBetween) {
|
|
28876
|
+
linkedChange = prev;
|
|
28877
|
+
}
|
|
28878
|
+
}
|
|
28879
|
+
}
|
|
28880
|
+
if (!linkedChange && next && matchingChange.to === next.from) {
|
|
28881
|
+
const nextMarkType = next.mark.type.name;
|
|
28882
|
+
if (matchingMarkType === TrackDeleteMarkName && nextMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && nextMarkType === TrackDeleteMarkName) {
|
|
28883
|
+
const hasContentBetween = state.doc.textBetween(matchingChange.from, next.to, "\n").length > matchingChange.to - matchingChange.from + (next.to - next.from);
|
|
28884
|
+
if (!hasContentBetween) {
|
|
28885
|
+
linkedChange = next;
|
|
28886
|
+
}
|
|
28887
|
+
}
|
|
28874
28888
|
}
|
|
28875
28889
|
return [matchingChange, linkedChange].filter(Boolean);
|
|
28876
28890
|
};
|
|
@@ -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
2
|
import { p as process$1 } from "./converter-wrgxIFCy.js";
|
|
3
|
-
import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-
|
|
3
|
+
import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-D8ueJVyp.js";
|
|
4
4
|
const sanitizeNumber = (value, defaultNumber) => {
|
|
5
5
|
let sanitized = value.replace(/[^0-9.]/g, "");
|
|
6
6
|
sanitized = parseFloat(sanitized);
|
|
@@ -11,10 +11,10 @@ var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "acce
|
|
|
11
11
|
var _SuperToolbar_instances, initToolbarGroups_fn, _interceptedCommands, makeToolbarItems_fn, initDefaultFonts_fn, updateHighlightColors_fn, deactivateAll_fn, updateToolbarHistory_fn, runCommandWithArgumentOnly_fn;
|
|
12
12
|
import { ax as getDefaultExportFromCjs, V as v4, T as TextSelection$1, v as getMarkRange, aA as vClickOutside, H as findParentNode, aB as getActiveFormatting, at as isInTable, aC as readFromClipboard, aD as handleClipboardPaste, aE as getFileObject, aF as runPropertyTranslators, aG as commentRangeEndTranslator, aH as commentRangeStartTranslator, aI as translator, aJ as translator$1, aK as translator$2, aL as translator$3, aM as translator$4, aN as translator$5, aO as translator$6, aP as translator$7, aQ as translator$8, aR as translator$9, aS as translator$a, aT as translator$b, aU as translator$c, aV as translator$d, aW as translator$e, aX as translator$f, aY as translator$g, aZ as translator$h, a_ as translator$i, a$ as translator$j, b0 as translator$k, b1 as translator$l, b2 as translator$m, b3 as translator$n, b4 as translator$o, b5 as translator$p, b6 as translator$q, b7 as translator$r, b8 as translator$s, b9 as translator$t, ba as translator$u, bb as translator$v, bc as translator$w, bd as translator$x, be as translator$y, bf as translator$z, bg as translator$A, bh as translator$B, bi as translator$C, bj as translator$D, bk as translator$E, bl as translator$F, bm as translator$G, bn as translator$H, bo as translator$I, bp as translator$J, bq as translator$K, br as translator$L, bs as translator$M, bt as translator$N, bu as translator$O, bv as translator$P, bw as translator$Q, bx as translator$R, by as translator$S, bz as translator$T, bA as translator$U, bB as translator$V, bC as translator$W, bD as translator$X, bE as translator$Y, bF as translator$Z, bG as translator$_, bH as translator$$, bI as translator$10, bJ as translator$11, bK as translator$12, a as Plugin } from "./chunks/converter-wrgxIFCy.js";
|
|
13
13
|
import { bL, a5, i, a2 } from "./chunks/converter-wrgxIFCy.js";
|
|
14
|
-
import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as getFileOpener, d as checkAndProcessImage, r as replaceSelectionWithImagePlaceholder, e as uploadAndInsertImage, y as yUndoPluginKey, f as undoDepth, h as redoDepth, s as shouldBypassContextMenu, S as SlashMenuPluginKey, E as Editor, i as getStarterExtensions, P as Placeholder, j as getRichTextExtensions, M as Mark, k as Extension, A as Attribute, N as Node } from "./chunks/editor-
|
|
15
|
-
import { n, C, o, T, l, p, m } from "./chunks/editor-
|
|
14
|
+
import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as getFileOpener, d as checkAndProcessImage, r as replaceSelectionWithImagePlaceholder, e as uploadAndInsertImage, y as yUndoPluginKey, f as undoDepth, h as redoDepth, s as shouldBypassContextMenu, S as SlashMenuPluginKey, E as Editor, i as getStarterExtensions, P as Placeholder, j as getRichTextExtensions, M as Mark, k as Extension, A as Attribute, N as Node } from "./chunks/editor-D8ueJVyp.js";
|
|
15
|
+
import { n, C, o, T, l, p, m } from "./chunks/editor-D8ueJVyp.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, u as useMessage, N as NSkeleton } from "./chunks/toolbar-
|
|
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, u as useMessage, N as NSkeleton } from "./chunks/toolbar-CXzGZEvz.js";
|
|
18
18
|
import AIWriter from "./ai-writer.es.js";
|
|
19
19
|
import { D } from "./chunks/docx-zipper-DIilDv93.js";
|
|
20
20
|
import { createZip } from "./file-zipper.es.js";
|
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-BHP7saSr.cjs");
|
|
4
4
|
require("./chunks/vue-DKMj1I9B.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-JTB_jHfC.es.js";
|
|
2
2
|
import "./chunks/vue-ZWZLQtoU.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-BHP7saSr.cjs");
|
|
4
|
+
const superdoc = require("./chunks/index-Ua6WmvV9.cjs");
|
|
5
5
|
require("./chunks/vue-DKMj1I9B.cjs");
|
|
6
6
|
const blankDocx = require("./chunks/blank-docx-CPqX9RF5.cjs");
|
|
7
7
|
exports.AnnotatorHelpers = superEditor_es.AnnotatorHelpers;
|
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-JTB_jHfC.es.js";
|
|
2
|
+
import { D, H, P, S as S2, m, l } from "./chunks/index-CASMW4Gt.es.js";
|
|
3
3
|
import "./chunks/vue-ZWZLQtoU.es.js";
|
|
4
4
|
import { B } from "./chunks/blank-docx-iwdyG9RH.es.js";
|
|
5
5
|
export {
|
package/dist/superdoc.umd.js
CHANGED
|
@@ -73902,11 +73902,25 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
73902
73902
|
const matchingChange = trackedChanges[changeIndex];
|
|
73903
73903
|
const prev = trackedChanges[changeIndex - 1];
|
|
73904
73904
|
const next = trackedChanges[changeIndex + 1];
|
|
73905
|
+
const matchingMarkType = matchingChange.mark.type.name;
|
|
73905
73906
|
let linkedChange;
|
|
73906
|
-
if (prev && matchingChange.
|
|
73907
|
-
|
|
73908
|
-
|
|
73909
|
-
|
|
73907
|
+
if (prev && matchingChange.from === prev.to) {
|
|
73908
|
+
const prevMarkType = prev.mark.type.name;
|
|
73909
|
+
if (matchingMarkType === TrackDeleteMarkName && prevMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && prevMarkType === TrackDeleteMarkName) {
|
|
73910
|
+
const hasContentBetween = state2.doc.textBetween(prev.from, matchingChange.to, "\n").length > prev.to - prev.from + (matchingChange.to - matchingChange.from);
|
|
73911
|
+
if (!hasContentBetween) {
|
|
73912
|
+
linkedChange = prev;
|
|
73913
|
+
}
|
|
73914
|
+
}
|
|
73915
|
+
}
|
|
73916
|
+
if (!linkedChange && next && matchingChange.to === next.from) {
|
|
73917
|
+
const nextMarkType = next.mark.type.name;
|
|
73918
|
+
if (matchingMarkType === TrackDeleteMarkName && nextMarkType === TrackInsertMarkName || matchingMarkType === TrackInsertMarkName && nextMarkType === TrackDeleteMarkName) {
|
|
73919
|
+
const hasContentBetween = state2.doc.textBetween(matchingChange.from, next.to, "\n").length > matchingChange.to - matchingChange.from + (next.to - next.from);
|
|
73920
|
+
if (!hasContentBetween) {
|
|
73921
|
+
linkedChange = next;
|
|
73922
|
+
}
|
|
73923
|
+
}
|
|
73910
73924
|
}
|
|
73911
73925
|
return [matchingChange, linkedChange].filter(Boolean);
|
|
73912
73926
|
};
|