@harbour-enterprises/superdoc 0.22.0-next.1 → 0.22.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-B3KmcDup.cjs → PdfViewer-Ck3Syakz.cjs} +1 -1
- package/dist/chunks/{PdfViewer-BpwMPbUj.es.js → PdfViewer-OEs-MC5j.es.js} +1 -1
- package/dist/chunks/{index-Cw4YywoD.es.js → index-B4aklZ4_.es.js} +2 -2
- package/dist/chunks/{index-BOf6E2I4.cjs → index-BM732Zfw.cjs} +2 -2
- package/dist/chunks/{super-editor.es-vfoWxyZL.es.js → super-editor.es-Bokezk1E.es.js} +10 -12
- package/dist/chunks/{super-editor.es-DHDx2fsy.cjs → super-editor.es-DwGNbrZq.cjs} +10 -12
- package/dist/super-editor/ai-writer.es.js +1 -1
- package/dist/super-editor/chunks/{editor-BC2sSIVa.js → editor-CTHD3ziL.js} +11 -4
- package/dist/super-editor/chunks/{toolbar-DNTo5DDf.js → toolbar-DLQeMuoQ.js} +1 -1
- package/dist/super-editor/editor.es.js +1 -1
- package/dist/super-editor/src/extensions/custom-selection/custom-selection.d.ts +0 -1
- package/dist/super-editor/src/utils/contextmenu-helpers.d.ts +24 -0
- package/dist/super-editor/super-editor.es.js +3 -11
- 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 +10 -12
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
- package/dist/super-editor/src/components/slash-menu/contextmenu-helpers.d.ts +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const vue = require("./vue-DWle4Cai.cjs");
|
|
4
|
-
const superdoc = require("./index-
|
|
4
|
+
const superdoc = require("./index-BM732Zfw.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-CXxsqYcP.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-B4aklZ4_.es.js";
|
|
3
3
|
function self(vars) {
|
|
4
4
|
const {
|
|
5
5
|
opacityDisabled,
|
|
@@ -1,4 +1,4 @@
|
|
|
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 "./super-editor.es-
|
|
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 "./super-editor.es-Bokezk1E.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-CXxsqYcP.es.js";
|
|
3
3
|
import { B as Buffer$2 } from "./jszip-B8KIZSNe.es.js";
|
|
4
4
|
import { B as BlankDOCX } from "./blank-docx-iwdyG9RH.es.js";
|
|
@@ -17392,7 +17392,7 @@ const _sfc_main = {
|
|
|
17392
17392
|
__name: "SuperDoc",
|
|
17393
17393
|
emits: ["selection-update"],
|
|
17394
17394
|
setup(__props, { emit: __emit }) {
|
|
17395
|
-
const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-
|
|
17395
|
+
const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-OEs-MC5j.es.js"));
|
|
17396
17396
|
const superdocStore = useSuperdocStore();
|
|
17397
17397
|
const commentsStore = useCommentsStore();
|
|
17398
17398
|
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-DwGNbrZq.cjs");
|
|
3
3
|
const vue = require("./vue-DWle4Cai.cjs");
|
|
4
4
|
const jszip = require("./jszip-b7l8QkfH.cjs");
|
|
5
5
|
const blankDocx = require("./blank-docx-CPqX9RF5.cjs");
|
|
@@ -17409,7 +17409,7 @@ const _sfc_main = {
|
|
|
17409
17409
|
__name: "SuperDoc",
|
|
17410
17410
|
emits: ["selection-update"],
|
|
17411
17411
|
setup(__props, { emit: __emit }) {
|
|
17412
|
-
const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-
|
|
17412
|
+
const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-Ck3Syakz.cjs")));
|
|
17413
17413
|
const superdocStore = useSuperdocStore();
|
|
17414
17414
|
const commentsStore = useCommentsStore();
|
|
17415
17415
|
const {
|
|
@@ -53574,15 +53574,21 @@ const intToJapaneseCounting = (num) => {
|
|
|
53574
53574
|
}
|
|
53575
53575
|
return result;
|
|
53576
53576
|
};
|
|
53577
|
-
const
|
|
53578
|
-
|
|
53577
|
+
const isKeyboardInvocation = (event) => {
|
|
53578
|
+
return event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
53579
|
+
};
|
|
53580
|
+
const prefersNativeMenu = (event) => {
|
|
53579
53581
|
if (!event) return false;
|
|
53580
53582
|
if (event.ctrlKey || event.metaKey) {
|
|
53581
53583
|
return true;
|
|
53582
53584
|
}
|
|
53583
|
-
|
|
53584
|
-
return Boolean(isKeyboardInvocation);
|
|
53585
|
+
return isKeyboardInvocation(event);
|
|
53585
53586
|
};
|
|
53587
|
+
const shouldAllowNativeContextMenu = (event) => {
|
|
53588
|
+
return prefersNativeMenu(event);
|
|
53589
|
+
};
|
|
53590
|
+
const shouldBypassContextMenu = shouldAllowNativeContextMenu;
|
|
53591
|
+
const CustomSelectionPluginKey = new PluginKey("CustomSelection");
|
|
53586
53592
|
const handleClickOutside = (event, editor) => {
|
|
53587
53593
|
const editorElem = editor?.options?.element;
|
|
53588
53594
|
if (!editorElem) return;
|
|
@@ -84146,14 +84152,6 @@ function getStructureFromResolvedPos(state2, pos) {
|
|
|
84146
84152
|
return null;
|
|
84147
84153
|
}
|
|
84148
84154
|
}
|
|
84149
|
-
const shouldBypassContextMenu = (event) => {
|
|
84150
|
-
if (!event) return false;
|
|
84151
|
-
if (event.ctrlKey || event.metaKey) {
|
|
84152
|
-
return true;
|
|
84153
|
-
}
|
|
84154
|
-
const isKeyboardInvocation = event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
84155
|
-
return Boolean(isKeyboardInvocation);
|
|
84156
|
-
};
|
|
84157
84155
|
const isModuleEnabled = (editorOptions, moduleName) => {
|
|
84158
84156
|
switch (moduleName) {
|
|
84159
84157
|
case "ai":
|
|
@@ -53591,15 +53591,21 @@ const intToJapaneseCounting = (num) => {
|
|
|
53591
53591
|
}
|
|
53592
53592
|
return result;
|
|
53593
53593
|
};
|
|
53594
|
-
const
|
|
53595
|
-
|
|
53594
|
+
const isKeyboardInvocation = (event) => {
|
|
53595
|
+
return event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
53596
|
+
};
|
|
53597
|
+
const prefersNativeMenu = (event) => {
|
|
53596
53598
|
if (!event) return false;
|
|
53597
53599
|
if (event.ctrlKey || event.metaKey) {
|
|
53598
53600
|
return true;
|
|
53599
53601
|
}
|
|
53600
|
-
|
|
53601
|
-
return Boolean(isKeyboardInvocation);
|
|
53602
|
+
return isKeyboardInvocation(event);
|
|
53602
53603
|
};
|
|
53604
|
+
const shouldAllowNativeContextMenu = (event) => {
|
|
53605
|
+
return prefersNativeMenu(event);
|
|
53606
|
+
};
|
|
53607
|
+
const shouldBypassContextMenu = shouldAllowNativeContextMenu;
|
|
53608
|
+
const CustomSelectionPluginKey = new PluginKey("CustomSelection");
|
|
53603
53609
|
const handleClickOutside = (event, editor) => {
|
|
53604
53610
|
const editorElem = editor?.options?.element;
|
|
53605
53611
|
if (!editorElem) return;
|
|
@@ -84163,14 +84169,6 @@ function getStructureFromResolvedPos(state2, pos) {
|
|
|
84163
84169
|
return null;
|
|
84164
84170
|
}
|
|
84165
84171
|
}
|
|
84166
|
-
const shouldBypassContextMenu = (event) => {
|
|
84167
|
-
if (!event) return false;
|
|
84168
|
-
if (event.ctrlKey || event.metaKey) {
|
|
84169
|
-
return true;
|
|
84170
|
-
}
|
|
84171
|
-
const isKeyboardInvocation = event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
84172
|
-
return Boolean(isKeyboardInvocation);
|
|
84173
|
-
};
|
|
84174
84172
|
const isModuleEnabled = (editorOptions, moduleName) => {
|
|
84175
84173
|
switch (moduleName) {
|
|
84176
84174
|
case "ai":
|
|
@@ -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-BcqEfCTg.js";
|
|
3
|
-
import { _ as _export_sfc } from "./chunks/editor-
|
|
3
|
+
import { _ as _export_sfc } from "./chunks/editor-CTHD3ziL.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 = {}) {
|
|
@@ -17480,15 +17480,21 @@ const intToJapaneseCounting = (num) => {
|
|
|
17480
17480
|
}
|
|
17481
17481
|
return result;
|
|
17482
17482
|
};
|
|
17483
|
-
const
|
|
17484
|
-
|
|
17483
|
+
const isKeyboardInvocation = (event) => {
|
|
17484
|
+
return event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
17485
|
+
};
|
|
17486
|
+
const prefersNativeMenu = (event) => {
|
|
17485
17487
|
if (!event) return false;
|
|
17486
17488
|
if (event.ctrlKey || event.metaKey) {
|
|
17487
17489
|
return true;
|
|
17488
17490
|
}
|
|
17489
|
-
|
|
17490
|
-
return Boolean(isKeyboardInvocation);
|
|
17491
|
+
return isKeyboardInvocation(event);
|
|
17491
17492
|
};
|
|
17493
|
+
const shouldAllowNativeContextMenu = (event) => {
|
|
17494
|
+
return prefersNativeMenu(event);
|
|
17495
|
+
};
|
|
17496
|
+
const shouldBypassContextMenu = shouldAllowNativeContextMenu;
|
|
17497
|
+
const CustomSelectionPluginKey = new PluginKey("CustomSelection");
|
|
17492
17498
|
const handleClickOutside = (event, editor) => {
|
|
17493
17499
|
const editorElem = editor?.options?.element;
|
|
17494
17500
|
if (!editorElem) return;
|
|
@@ -33768,6 +33774,7 @@ export {
|
|
|
33768
33774
|
SectionHelpers as o,
|
|
33769
33775
|
getAllowedImageDimensions as p,
|
|
33770
33776
|
replaceSelectionWithImagePlaceholder as r,
|
|
33777
|
+
shouldBypassContextMenu as s,
|
|
33771
33778
|
useHighContrastMode as u,
|
|
33772
33779
|
yUndoPluginKey as y
|
|
33773
33780
|
};
|
|
@@ -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-BcqEfCTg.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-CTHD3ziL.js";
|
|
4
4
|
const sanitizeNumber = (value, defaultNumber) => {
|
|
5
5
|
let sanitized = value.replace(/[^0-9.]/g, "");
|
|
6
6
|
sanitized = parseFloat(sanitized);
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Determine if the native context menu should be allowed to appear.
|
|
3
|
+
* We bypass the custom menu when the user explicitly requests the system menu
|
|
4
|
+
* via modifier keys or when the event originated from a keyboard invocation.
|
|
5
|
+
* @param {MouseEvent} event
|
|
6
|
+
* @returns {boolean}
|
|
7
|
+
*/
|
|
8
|
+
export function shouldBypassContextMenu(event: MouseEvent): boolean;
|
|
9
|
+
/**
|
|
10
|
+
* Determine if the native context menu should be allowed to appear.
|
|
11
|
+
* We bypass the custom menu when the user explicitly requests the system menu
|
|
12
|
+
* via modifier keys or when the event originated from a keyboard invocation.
|
|
13
|
+
* @param {MouseEvent} event
|
|
14
|
+
* @returns {boolean}
|
|
15
|
+
*/
|
|
16
|
+
export function shouldUseNativeContextMenu(event: MouseEvent): boolean;
|
|
17
|
+
/**
|
|
18
|
+
* Determine if the native context menu should be allowed to appear.
|
|
19
|
+
* We bypass the custom menu when the user explicitly requests the system menu
|
|
20
|
+
* via modifier keys or when the event originated from a keyboard invocation.
|
|
21
|
+
* @param {MouseEvent} event
|
|
22
|
+
* @returns {boolean}
|
|
23
|
+
*/
|
|
24
|
+
export function shouldAllowNativeContextMenu(event: MouseEvent): boolean;
|
|
@@ -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 { av as getDefaultExportFromCjs, V as v4, T as TextSelection$1, v as getMarkRange, ay as vClickOutside, H as findParentNode, az as getActiveFormatting, ap as isInTable, aA as readFromClipboard, aB as handleClipboardPaste, aC as getFileObject, aD as runPropertyTranslators, aE as translator, aF as translator$1, aG as translator$2, aH as translator$3, aI as translator$4, aJ as translator$5, aK as translator$6, aL as translator$7, aM as translator$8, aN as translator$9, aO as translator$a, aP as translator$b, aQ as translator$c, aR as translator$d, aS as translator$e, aT as translator$f, aU as translator$g, aV as translator$h, aW as translator$i, aX as translator$j, aY as translator$k, aZ as translator$l, a_ as translator$m, a$ as translator$n, b0 as translator$o, b1 as translator$p, b2 as translator$q, b3 as translator$r, b4 as translator$s, b5 as translator$t, b6 as translator$u, b7 as translator$v, b8 as translator$w, b9 as translator$x, ba as translator$y, bb as translator$z, bc as translator$A, bd as translator$B, be as translator$C, bf as translator$D, bg as translator$E, bh as translator$F, bi as translator$G, bj as translator$H, bk as translator$I, bl as translator$J, bm as translator$K, bn as translator$L, bo as translator$M, bp as translator$N, bq as translator$O, br as translator$P, bs as translator$Q, bt as translator$R, bu as translator$S, bv as translator$T, bw as translator$U, bx as translator$V, by as translator$W, bz as translator$X, bA as translator$Y, bB as translator$Z, bC as translator$_, bD as translator$$, bE as translator$10, a as Plugin } from "./chunks/converter-BcqEfCTg.js";
|
|
13
13
|
import { bF, a5, i, a2 } from "./chunks/converter-BcqEfCTg.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 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-CTHD3ziL.js";
|
|
15
|
+
import { n, C, o, T, l, p, m } from "./chunks/editor-CTHD3ziL.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-DLQeMuoQ.js";
|
|
18
18
|
import AIWriter from "./ai-writer.es.js";
|
|
19
19
|
import { D } from "./chunks/docx-zipper-DZ9ph0iQ.js";
|
|
20
20
|
import { createZip } from "./file-zipper.es.js";
|
|
@@ -3695,14 +3695,6 @@ function getStructureFromResolvedPos(state, pos) {
|
|
|
3695
3695
|
return null;
|
|
3696
3696
|
}
|
|
3697
3697
|
}
|
|
3698
|
-
const shouldBypassContextMenu = (event) => {
|
|
3699
|
-
if (!event) return false;
|
|
3700
|
-
if (event.ctrlKey || event.metaKey) {
|
|
3701
|
-
return true;
|
|
3702
|
-
}
|
|
3703
|
-
const isKeyboardInvocation = event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
3704
|
-
return Boolean(isKeyboardInvocation);
|
|
3705
|
-
};
|
|
3706
3698
|
const isModuleEnabled = (editorOptions, moduleName) => {
|
|
3707
3699
|
switch (moduleName) {
|
|
3708
3700
|
case "ai":
|
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-DwGNbrZq.cjs");
|
|
4
4
|
require("./chunks/vue-DWle4Cai.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-Bokezk1E.es.js";
|
|
2
2
|
import "./chunks/vue-CXxsqYcP.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-DwGNbrZq.cjs");
|
|
4
|
+
const superdoc = require("./chunks/index-BM732Zfw.cjs");
|
|
5
5
|
require("./chunks/vue-DWle4Cai.cjs");
|
|
6
6
|
require("./chunks/jszip-b7l8QkfH.cjs");
|
|
7
7
|
const blankDocx = require("./chunks/blank-docx-CPqX9RF5.cjs");
|
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-Bokezk1E.es.js";
|
|
2
|
+
import { D, H, P, S as S2, m, l } from "./chunks/index-B4aklZ4_.es.js";
|
|
3
3
|
import "./chunks/vue-CXxsqYcP.es.js";
|
|
4
4
|
import "./chunks/jszip-B8KIZSNe.es.js";
|
|
5
5
|
import { B } from "./chunks/blank-docx-iwdyG9RH.es.js";
|
package/dist/superdoc.umd.js
CHANGED
|
@@ -61289,15 +61289,21 @@ Please report this to https://github.com/markedjs/marked.`, e) {
|
|
|
61289
61289
|
}
|
|
61290
61290
|
return result;
|
|
61291
61291
|
};
|
|
61292
|
-
const
|
|
61293
|
-
|
|
61292
|
+
const isKeyboardInvocation = (event) => {
|
|
61293
|
+
return event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
61294
|
+
};
|
|
61295
|
+
const prefersNativeMenu = (event) => {
|
|
61294
61296
|
if (!event) return false;
|
|
61295
61297
|
if (event.ctrlKey || event.metaKey) {
|
|
61296
61298
|
return true;
|
|
61297
61299
|
}
|
|
61298
|
-
|
|
61299
|
-
return Boolean(isKeyboardInvocation);
|
|
61300
|
+
return isKeyboardInvocation(event);
|
|
61300
61301
|
};
|
|
61302
|
+
const shouldAllowNativeContextMenu = (event) => {
|
|
61303
|
+
return prefersNativeMenu(event);
|
|
61304
|
+
};
|
|
61305
|
+
const shouldBypassContextMenu = shouldAllowNativeContextMenu;
|
|
61306
|
+
const CustomSelectionPluginKey = new PluginKey("CustomSelection");
|
|
61301
61307
|
const handleClickOutside = (event, editor) => {
|
|
61302
61308
|
const editorElem = editor?.options?.element;
|
|
61303
61309
|
if (!editorElem) return;
|
|
@@ -91861,14 +91867,6 @@ ${style2}
|
|
|
91861
91867
|
return null;
|
|
91862
91868
|
}
|
|
91863
91869
|
}
|
|
91864
|
-
const shouldBypassContextMenu = (event) => {
|
|
91865
|
-
if (!event) return false;
|
|
91866
|
-
if (event.ctrlKey || event.metaKey) {
|
|
91867
|
-
return true;
|
|
91868
|
-
}
|
|
91869
|
-
const isKeyboardInvocation = event.type === "contextmenu" && typeof event.detail === "number" && event.detail === 0 && (event.button === 0 || event.button === void 0) && event.clientX === 0 && event.clientY === 0;
|
|
91870
|
-
return Boolean(isKeyboardInvocation);
|
|
91871
|
-
};
|
|
91872
91870
|
const isModuleEnabled = (editorOptions, moduleName) => {
|
|
91873
91871
|
switch (moduleName) {
|
|
91874
91872
|
case "ai":
|