superdoc 2.0.0-next.1 → 2.0.0-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.
- package/dist/chunks/{PdfViewer-BDQHgDVD.es.js → PdfViewer-C4xgIIbF.es.js} +1 -1
- package/dist/chunks/{PdfViewer-Cun5Zr8u.cjs → PdfViewer-CWO98Qls.cjs} +1 -1
- package/dist/chunks/{index-if-EH8uU.cjs → index-BY-3Vl72.cjs} +3 -3
- package/dist/chunks/{index-Dq6vXk74-CQD7nLbH.es.js → index-BqPa6D4q-8U4x8RP6.es.js} +1 -1
- package/dist/chunks/{index-Dq6vXk74-Vm-euNb7.cjs → index-BqPa6D4q-Dulj8zfc.cjs} +1 -1
- package/dist/chunks/{index-CGAmeAEK.es.js → index-s9GUR_Gc.es.js} +3 -3
- package/dist/chunks/{super-editor.es-CwNpXZzP.cjs → super-editor.es-BM-ulSRj.cjs} +25 -6
- package/dist/chunks/{super-editor.es-DyaHVXrq.es.js → super-editor.es-CT28vUbx.es.js} +25 -6
- package/dist/packages/superdoc/src/core/SuperDoc.d.ts.map +1 -1
- package/dist/super-editor/ai-writer.es.js +2 -2
- package/dist/super-editor/chunks/{converter-BtoNJWI9.js → converter-CDlAWcRu.js} +1 -1
- package/dist/super-editor/chunks/{docx-zipper-CLkDdGOr.js → docx-zipper-B2VXuf8h.js} +1 -1
- package/dist/super-editor/chunks/{editor-COH8793Z.js → editor-B4Q_tNET.js} +35 -23
- package/dist/super-editor/chunks/{index-Dq6vXk74.js → index-BqPa6D4q.js} +1 -1
- package/dist/super-editor/chunks/{toolbar-Ca-BPuJ2.js → toolbar-BD-lDCLr.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.es.js +28 -14
- 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 +27 -8
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
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-BM-ulSRj.cjs");
|
|
4
4
|
require("./chunks/vue-gvuFr0vx.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, P, 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, P, S, c, d, e, f, g, T, h, i, j, k, l, m, n, o, p, r, q } from "./chunks/super-editor.es-CT28vUbx.es.js";
|
|
2
2
|
import "./chunks/vue-CLFbn_1r.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-BM-ulSRj.cjs");
|
|
4
|
+
const superdoc = require("./chunks/index-BY-3Vl72.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-CT28vUbx.es.js";
|
|
2
|
+
import { D, H, P, S as S2, m, l } from "./chunks/index-s9GUR_Gc.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
|
@@ -42428,7 +42428,7 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
42428
42428
|
static getStoredSuperdocVersion(docx) {
|
|
42429
42429
|
return _SuperConverter2.getStoredCustomProperty(docx, "SuperdocVersion");
|
|
42430
42430
|
}
|
|
42431
|
-
static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "2.0.0-next.
|
|
42431
|
+
static setStoredSuperdocVersion(docx = this.convertedXml, version2 = "2.0.0-next.2") {
|
|
42432
42432
|
return _SuperConverter2.setStoredCustomProperty(docx, "SuperdocVersion", version2, false);
|
|
42433
42433
|
}
|
|
42434
42434
|
/**
|
|
@@ -68384,7 +68384,7 @@ ${err.toString()}`);
|
|
|
68384
68384
|
const shouldSkipNodeView = (editor) => {
|
|
68385
68385
|
return isHeadless(editor);
|
|
68386
68386
|
};
|
|
68387
|
-
const summaryVersion = "2.0.0-next.
|
|
68387
|
+
const summaryVersion = "2.0.0-next.2";
|
|
68388
68388
|
const nodeKeys = ["group", "content", "marks", "inline", "atom", "defining", "code", "tableRole", "summary"];
|
|
68389
68389
|
const markKeys = ["group", "inclusive", "excludes", "spanning", "code"];
|
|
68390
68390
|
function mapAttributes(attrs) {
|
|
@@ -69173,7 +69173,7 @@ ${err.toString()}`);
|
|
|
69173
69173
|
{ default: remarkStringify2 },
|
|
69174
69174
|
{ default: remarkGfm2 }
|
|
69175
69175
|
] = await Promise.all([
|
|
69176
|
-
Promise.resolve().then(() =>
|
|
69176
|
+
Promise.resolve().then(() => indexBqPa6D4q),
|
|
69177
69177
|
Promise.resolve().then(() => indexDRCvimau),
|
|
69178
69178
|
Promise.resolve().then(() => indexC_x_N6Uh),
|
|
69179
69179
|
Promise.resolve().then(() => indexD_sWOSiG),
|
|
@@ -69378,7 +69378,7 @@ ${err.toString()}`);
|
|
|
69378
69378
|
* Process collaboration migrations
|
|
69379
69379
|
*/
|
|
69380
69380
|
processCollaborationMigrations() {
|
|
69381
|
-
console.debug("[checkVersionMigrations] Current editor version", "2.0.0-next.
|
|
69381
|
+
console.debug("[checkVersionMigrations] Current editor version", "2.0.0-next.2");
|
|
69382
69382
|
if (!this.options.ydoc) return;
|
|
69383
69383
|
const metaMap = this.options.ydoc.getMap("meta");
|
|
69384
69384
|
let docVersion = metaMap.get("version");
|
|
@@ -89245,6 +89245,7 @@ ${l}
|
|
|
89245
89245
|
}
|
|
89246
89246
|
return false;
|
|
89247
89247
|
}
|
|
89248
|
+
const SLASH_MENU_HANDLED_FLAG = "__sdHandledBySlashMenu";
|
|
89248
89249
|
class PresentationInputBridge {
|
|
89249
89250
|
/**
|
|
89250
89251
|
* Creates a new PresentationInputBridge that forwards user input events from the visible layout
|
|
@@ -89458,6 +89459,10 @@ ${l}
|
|
|
89458
89459
|
__privateMethod$1(this, _PresentationInputBridge_instances, dispatchToTarget_fn).call(this, event, synthetic);
|
|
89459
89460
|
};
|
|
89460
89461
|
forwardContextMenu_fn = function(event) {
|
|
89462
|
+
const handledBySlashMenu = Boolean(event[SLASH_MENU_HANDLED_FLAG]);
|
|
89463
|
+
if (handledBySlashMenu) {
|
|
89464
|
+
return;
|
|
89465
|
+
}
|
|
89461
89466
|
if (!__privateGet$1(this, _isEditable).call(this)) {
|
|
89462
89467
|
return;
|
|
89463
89468
|
}
|
|
@@ -137570,11 +137575,23 @@ ${style2}
|
|
|
137570
137575
|
closeMenu({ restoreCursor: false });
|
|
137571
137576
|
}
|
|
137572
137577
|
};
|
|
137573
|
-
const
|
|
137578
|
+
const shouldHandleContextMenu = (event) => {
|
|
137574
137579
|
const readOnly = !props.editor?.isEditable;
|
|
137575
137580
|
const contextMenuDisabled = props.editor?.options?.disableContextMenu;
|
|
137576
137581
|
const bypass = shouldBypassContextMenu(event);
|
|
137577
|
-
|
|
137582
|
+
return !readOnly && !contextMenuDisabled && !bypass;
|
|
137583
|
+
};
|
|
137584
|
+
const handleRightClickCapture = (event) => {
|
|
137585
|
+
try {
|
|
137586
|
+
if (shouldHandleContextMenu(event)) {
|
|
137587
|
+
event[SLASH_MENU_HANDLED_FLAG] = true;
|
|
137588
|
+
}
|
|
137589
|
+
} catch (error) {
|
|
137590
|
+
console.warn("[SlashMenu] Error in capture phase context menu handler:", error);
|
|
137591
|
+
}
|
|
137592
|
+
};
|
|
137593
|
+
const handleRightClick = async (event) => {
|
|
137594
|
+
if (!shouldHandleContextMenu(event)) {
|
|
137578
137595
|
return;
|
|
137579
137596
|
}
|
|
137580
137597
|
event.preventDefault();
|
|
@@ -137685,6 +137702,7 @@ ${style2}
|
|
|
137685
137702
|
props.editor.on("slashMenu:open", slashMenuOpenHandler);
|
|
137686
137703
|
contextMenuTarget = getEditorSurfaceElement(props.editor);
|
|
137687
137704
|
if (contextMenuTarget) {
|
|
137705
|
+
contextMenuTarget.addEventListener("contextmenu", handleRightClickCapture, true);
|
|
137688
137706
|
contextMenuTarget.addEventListener("contextmenu", handleRightClick);
|
|
137689
137707
|
}
|
|
137690
137708
|
slashMenuCloseHandler = () => {
|
|
@@ -137708,6 +137726,7 @@ ${style2}
|
|
|
137708
137726
|
props.editor.off("slashMenu:close", slashMenuCloseHandler);
|
|
137709
137727
|
}
|
|
137710
137728
|
props.editor.off("update", handleEditorUpdate);
|
|
137729
|
+
contextMenuTarget?.removeEventListener("contextmenu", handleRightClickCapture, true);
|
|
137711
137730
|
contextMenuTarget?.removeEventListener("contextmenu", handleRightClick);
|
|
137712
137731
|
} catch (error) {
|
|
137713
137732
|
console.warn("[SlashMenu] Error during cleanup:", error);
|
|
@@ -157239,7 +157258,7 @@ ${style2}
|
|
|
157239
157258
|
this.config.colors = shuffleArray(this.config.colors);
|
|
157240
157259
|
this.userColorMap = /* @__PURE__ */ new Map();
|
|
157241
157260
|
this.colorIndex = 0;
|
|
157242
|
-
this.version = "2.0.0-next.
|
|
157261
|
+
this.version = "2.0.0-next.2";
|
|
157243
157262
|
this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
|
|
157244
157263
|
this.superdocId = config2.superdocId || v4();
|
|
157245
157264
|
this.colors = this.config.colors;
|
|
@@ -159712,7 +159731,7 @@ ${style2}
|
|
|
159712
159731
|
value && typeof value === "object" && "byteLength" in value && "byteOffset" in value
|
|
159713
159732
|
);
|
|
159714
159733
|
}
|
|
159715
|
-
const
|
|
159734
|
+
const indexBqPa6D4q = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
159716
159735
|
__proto__: null,
|
|
159717
159736
|
unified
|
|
159718
159737
|
}, Symbol.toStringTag, { value: "Module" }));
|