@harbour-enterprises/superdoc 0.12.31 → 0.12.34-next.1
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/{super-editor.es-BxaiA9ut.cjs → super-editor.es-C2uZFYse.cjs} +599 -269
- package/dist/chunks/{super-editor.es-CYH3KblY.es.js → super-editor.es-mtzaNl_I.es.js} +613 -283
- package/dist/composables/use-high-contrast-mode.d.ts +5 -0
- package/dist/composables/use-high-contrast-mode.d.ts.map +1 -0
- package/dist/core/SuperDoc.d.ts +7 -0
- package/dist/core/SuperDoc.d.ts.map +1 -1
- package/dist/core/create-app.d.ts.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/style.css +299 -245
- package/dist/super-editor/ai-writer.es.js +2 -2
- package/dist/super-editor/chunks/{converter-Dm2_Htrh.js → converter-CenRPnts.js} +2 -2
- package/dist/super-editor/chunks/{docx-zipper-CU11jH41.js → docx-zipper-DdgXH9QX.js} +7 -3
- package/dist/super-editor/chunks/{editor-CISWiQkg.js → editor-B44D-Ttm.js} +190 -67
- package/dist/super-editor/chunks/{toolbar-Dgo3wQvN.js → toolbar-DmkQTZha.js} +80 -36
- package/dist/super-editor/components/toolbar/defaultItems.d.ts.map +1 -1
- package/dist/super-editor/composables/use-high-contrast-mode.d.ts +5 -0
- package/dist/super-editor/composables/use-high-contrast-mode.d.ts.map +1 -0
- package/dist/super-editor/converter.es.js +1 -1
- package/dist/super-editor/core/DocxZipper.d.ts +1 -1
- package/dist/super-editor/core/DocxZipper.d.ts.map +1 -1
- package/dist/super-editor/core/Editor.d.ts +2 -1
- package/dist/super-editor/core/Editor.d.ts.map +1 -1
- package/dist/super-editor/core/InputRule.d.ts.map +1 -1
- package/dist/super-editor/core/helpers/annotator.d.ts +17 -3
- package/dist/super-editor/core/helpers/annotator.d.ts.map +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/extensions/ai/ai-nodes.d.ts.map +1 -1
- package/dist/super-editor/extensions/bookmarks/bookmarks.d.ts.map +1 -1
- package/dist/super-editor/extensions/bullet-list/bullet-list.d.ts.map +1 -1
- package/dist/super-editor/extensions/collaboration/collaboration-helpers.d.ts.map +1 -1
- package/dist/super-editor/extensions/comment/comment.d.ts.map +1 -1
- package/dist/super-editor/extensions/document/document.d.ts.map +1 -1
- package/dist/super-editor/extensions/field-annotation/field-annotation.d.ts.map +1 -1
- package/dist/super-editor/extensions/field-annotation/fieldAnnotationHelpers/getHeaderFooterAnnotations.d.ts +2 -0
- package/dist/super-editor/extensions/field-annotation/fieldAnnotationHelpers/getHeaderFooterAnnotations.d.ts.map +1 -0
- package/dist/super-editor/extensions/field-annotation/fieldAnnotationHelpers/index.d.ts +1 -0
- package/dist/super-editor/extensions/heading/heading.d.ts.map +1 -1
- package/dist/super-editor/extensions/image/image.d.ts.map +1 -1
- package/dist/super-editor/extensions/line-break/line-break.d.ts.map +1 -1
- package/dist/super-editor/extensions/list-item/list-item.d.ts.map +1 -1
- package/dist/super-editor/extensions/mention/mention.d.ts.map +1 -1
- package/dist/super-editor/extensions/ordered-list/ordered-list.d.ts.map +1 -1
- package/dist/super-editor/extensions/page-number/page-number.d.ts.map +1 -1
- package/dist/super-editor/extensions/pagination/pagination-helpers.d.ts.map +1 -1
- package/dist/super-editor/extensions/run-item/run-item.d.ts.map +1 -1
- package/dist/super-editor/extensions/shape-container/shape-container.d.ts.map +1 -1
- package/dist/super-editor/extensions/shape-textbox/shape-textbox.d.ts.map +1 -1
- package/dist/super-editor/extensions/structured-content/structured-content.d.ts.map +1 -1
- package/dist/super-editor/extensions/table/table.d.ts.map +1 -1
- package/dist/super-editor/extensions/table-cell/table-cell.d.ts.map +1 -1
- package/dist/super-editor/extensions/table-header/table-header.d.ts.map +1 -1
- package/dist/super-editor/extensions/table-row/table-row.d.ts.map +1 -1
- package/dist/super-editor/file-zipper.es.js +1 -1
- package/dist/super-editor/index.d.ts +1 -1
- package/dist/super-editor/style.css +243 -196
- package/dist/super-editor/super-editor.es.js +335 -174
- package/dist/super-editor/toolbar.es.js +2 -2
- package/dist/super-editor.cjs +2 -1
- package/dist/super-editor.es.js +15 -14
- package/dist/superdoc.cjs +35 -9
- package/dist/superdoc.es.js +233 -207
- package/dist/superdoc.umd.js +636 -281
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as Y from "yjs";
|
|
2
2
|
import { UndoManager, Item as Item$2, ContentType, Text as Text$1, XmlElement, encodeStateAsUpdate } from "yjs";
|
|
3
|
-
import { g as global$2,
|
|
3
|
+
import { g as global$2, r as ref$1, c as createApp, a as computed, b as createElementBlock, o as openBlock, F as Fragment$1, d as renderList, n as normalizeClass, w as withModifiers, e as createCommentVNode, t as toDisplayString, f as createBaseVNode, i as inject, h as onBeforeMount, j as onMounted, k as onBeforeUnmount, l as watch, m as defineComponent, q as getCurrentInstance, s as onDeactivated, u as nextTick, v as createBlock, x as createVNode, y as unref, z as withCtx, A as createTextVNode, B as normalizeStyle, C as h, D as toRef, E as provide, G as mergeProps, H as cloneVNode, T as Text$2, I as withDirectives, J as watchEffect, K as shallowRef, L as vModelText, M as withKeys, N as reactive, O as readonly, P as Transition, Q as vShow, R as Comment, S as renderSlot, U as onActivated, V as Teleport, W as isVNode, X as onUnmounted } from "./vue-IIIZMHTg.es.js";
|
|
4
4
|
var __defProp$2 = Object.defineProperty;
|
|
5
5
|
var __typeError$2 = (msg2) => {
|
|
6
6
|
throw TypeError(msg2);
|
|
@@ -23290,7 +23290,7 @@ const _SuperConverter = class _SuperConverter2 {
|
|
|
23290
23290
|
return;
|
|
23291
23291
|
}
|
|
23292
23292
|
}
|
|
23293
|
-
static updateDocumentVersion(docx = this.convertedXml, version2 = "0.12.
|
|
23293
|
+
static updateDocumentVersion(docx = this.convertedXml, version2 = "0.12.34-next.1") {
|
|
23294
23294
|
const customLocation = "docProps/custom.xml";
|
|
23295
23295
|
if (!docx[customLocation]) {
|
|
23296
23296
|
docx[customLocation] = generateCustomXml();
|
|
@@ -23756,7 +23756,7 @@ function storeSuperdocVersion(docx) {
|
|
|
23756
23756
|
function generateCustomXml() {
|
|
23757
23757
|
return DEFAULT_CUSTOM_XML;
|
|
23758
23758
|
}
|
|
23759
|
-
function generateSuperdocVersion(pid = 2, version2 = "0.12.
|
|
23759
|
+
function generateSuperdocVersion(pid = 2, version2 = "0.12.34-next.1") {
|
|
23760
23760
|
return {
|
|
23761
23761
|
type: "element",
|
|
23762
23762
|
name: "property",
|
|
@@ -26156,12 +26156,15 @@ class DocxZipper {
|
|
|
26156
26156
|
/**
|
|
26157
26157
|
* Update [Content_Types].xml with extensions of new Image annotations
|
|
26158
26158
|
*/
|
|
26159
|
-
async updateContentTypes(docx, media) {
|
|
26159
|
+
async updateContentTypes(docx, media, fromJson) {
|
|
26160
26160
|
const newMediaTypes = Object.keys(media).map((name) => {
|
|
26161
26161
|
return this.getFileExtension(name);
|
|
26162
26162
|
});
|
|
26163
26163
|
const contentTypesPath = "[Content_Types].xml";
|
|
26164
|
-
|
|
26164
|
+
let contentTypesXml;
|
|
26165
|
+
if (fromJson) {
|
|
26166
|
+
contentTypesXml = docx.files.find((file) => file.name === contentTypesPath)?.content || "";
|
|
26167
|
+
} else contentTypesXml = await docx.file(contentTypesPath).async("string");
|
|
26165
26168
|
let typesString = "";
|
|
26166
26169
|
const defaultMediaTypes = getContentTypesFromXml(contentTypesXml);
|
|
26167
26170
|
const seenTypes = /* @__PURE__ */ new Set();
|
|
@@ -26205,6 +26208,7 @@ class DocxZipper {
|
|
|
26205
26208
|
});
|
|
26206
26209
|
const beginningString = '<Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types">';
|
|
26207
26210
|
const updatedContentTypesXml = contentTypesXml.replace(beginningString, `${beginningString}${typesString}`);
|
|
26211
|
+
if (fromJson) return updatedContentTypesXml;
|
|
26208
26212
|
docx.file(contentTypesPath, updatedContentTypesXml);
|
|
26209
26213
|
}
|
|
26210
26214
|
async unzip(file) {
|
|
@@ -38204,6 +38208,10 @@ const inputRulesPlugin = ({ editor, rules }) => {
|
|
|
38204
38208
|
const clipboard = event.clipboardData;
|
|
38205
38209
|
const html = clipboard.getData("text/html");
|
|
38206
38210
|
clipboard.getData("text/plain");
|
|
38211
|
+
const fieldAnnotationContent = slice2.content.content.filter((item) => item.type.name === "fieldAnnotation");
|
|
38212
|
+
if (fieldAnnotationContent.length) {
|
|
38213
|
+
return false;
|
|
38214
|
+
}
|
|
38207
38215
|
let source;
|
|
38208
38216
|
if (!html) {
|
|
38209
38217
|
source = "plain-text";
|
|
@@ -38982,16 +38990,14 @@ const updateYdocDocxData = async (editor) => {
|
|
|
38982
38990
|
const docx = [...metaMap.get("docx")];
|
|
38983
38991
|
const newXml = await editor.exportDocx({ getUpdatedDocs: true });
|
|
38984
38992
|
Object.keys(newXml).forEach((key) => {
|
|
38985
|
-
|
|
38986
|
-
|
|
38987
|
-
|
|
38988
|
-
docx.splice(fileIndex, 1);
|
|
38989
|
-
}
|
|
38990
|
-
docx.push({
|
|
38991
|
-
name: key,
|
|
38992
|
-
content: newXml[key]
|
|
38993
|
-
});
|
|
38993
|
+
const fileIndex = docx.findIndex((item) => item.name === key);
|
|
38994
|
+
if (fileIndex > -1) {
|
|
38995
|
+
docx.splice(fileIndex, 1);
|
|
38994
38996
|
}
|
|
38997
|
+
docx.push({
|
|
38998
|
+
name: key,
|
|
38999
|
+
content: newXml[key]
|
|
39000
|
+
});
|
|
38995
39001
|
});
|
|
38996
39002
|
editor.options.ydoc.transact(() => {
|
|
38997
39003
|
metaMap.set("docx", docx);
|
|
@@ -39101,6 +39107,9 @@ const createHeaderFooterEditor = ({
|
|
|
39101
39107
|
pm.style.minHeight = "100%";
|
|
39102
39108
|
pm.style.outline = "none";
|
|
39103
39109
|
pm.style.border = "none";
|
|
39110
|
+
pm.setAttribute("role", "textbox");
|
|
39111
|
+
pm.setAttribute("aria-multiline", true);
|
|
39112
|
+
pm.setAttribute("aria-label", `${type2} content area. Double click to start typing.`);
|
|
39104
39113
|
return headerFooterEditor;
|
|
39105
39114
|
};
|
|
39106
39115
|
const broadcastEditorEvents = (editor, sectionEditor) => {
|
|
@@ -39122,13 +39131,16 @@ const broadcastEditorEvents = (editor, sectionEditor) => {
|
|
|
39122
39131
|
const toggleHeaderFooterEditMode = (editor, focusedSectionEditor, isEditMode) => {
|
|
39123
39132
|
editor.converter.headerEditors.forEach((item) => {
|
|
39124
39133
|
item.editor.setEditable(isEditMode, false);
|
|
39134
|
+
item.editor.view.dom.setAttribute("aria-readonly", !isEditMode);
|
|
39125
39135
|
});
|
|
39126
39136
|
editor.converter.footerEditors.forEach((item) => {
|
|
39127
39137
|
item.editor.setEditable(isEditMode, false);
|
|
39138
|
+
item.editor.view.dom.setAttribute("aria-readonly", !isEditMode);
|
|
39128
39139
|
});
|
|
39129
39140
|
if (isEditMode) {
|
|
39130
39141
|
const pm = document.querySelector(".ProseMirror");
|
|
39131
39142
|
pm.classList.add("header-footer-edit");
|
|
39143
|
+
pm.setAttribute("aria-readonly", true);
|
|
39132
39144
|
}
|
|
39133
39145
|
if (focusedSectionEditor) {
|
|
39134
39146
|
focusedSectionEditor.view.focus();
|
|
@@ -40047,11 +40059,12 @@ const generateTableIfNecessary = ({ tableNode, annotationValues, tr, state: stat
|
|
|
40047
40059
|
const getAnnotationValue = (id, annotationValues) => {
|
|
40048
40060
|
return annotationValues.find((value) => value.input_id === id)?.input_value || null;
|
|
40049
40061
|
};
|
|
40050
|
-
const
|
|
40062
|
+
const getAllHeaderFooterEditors = (editor) => {
|
|
40051
40063
|
const sections = {
|
|
40052
40064
|
header: editor.converter.headers || {},
|
|
40053
40065
|
footer: editor.converter.footers || {}
|
|
40054
40066
|
};
|
|
40067
|
+
const allEditors = [];
|
|
40055
40068
|
Object.entries(sections).forEach(([type2, items]) => {
|
|
40056
40069
|
const editorsKey = `${type2}Editors`;
|
|
40057
40070
|
Object.entries(items).forEach(([sectionId, data]) => {
|
|
@@ -40069,25 +40082,38 @@ const annotateHeadersAndFooters = ({ editor, annotationValues = [], hiddenFieldI
|
|
|
40069
40082
|
})
|
|
40070
40083
|
};
|
|
40071
40084
|
editor.converter[editorsKey].push(sectionEditor);
|
|
40085
|
+
allEditors.push({
|
|
40086
|
+
...sectionEditor,
|
|
40087
|
+
key: editorsKey,
|
|
40088
|
+
type: type2,
|
|
40089
|
+
sectionId
|
|
40090
|
+
});
|
|
40072
40091
|
}
|
|
40073
|
-
sectionEditor.editor.annotate(annotationValues, hiddenFieldIds);
|
|
40074
|
-
onHeaderFooterDataUpdate(
|
|
40075
|
-
{ editor: sectionEditor.editor },
|
|
40076
|
-
editor,
|
|
40077
|
-
sectionId,
|
|
40078
|
-
type2
|
|
40079
|
-
);
|
|
40080
40092
|
});
|
|
40081
40093
|
});
|
|
40094
|
+
return allEditors;
|
|
40095
|
+
};
|
|
40096
|
+
const annotateHeadersAndFooters = ({ editor, annotationValues = [], hiddenFieldIds = [], removeEmptyFields = false }) => {
|
|
40097
|
+
const allEditors = getAllHeaderFooterEditors(editor);
|
|
40098
|
+
allEditors.forEach(({ sectionId, editor: sectionEditor, type: type2 }) => {
|
|
40099
|
+
sectionEditor.annotate(annotationValues, hiddenFieldIds, removeEmptyFields);
|
|
40100
|
+
onHeaderFooterDataUpdate(
|
|
40101
|
+
{ editor: sectionEditor },
|
|
40102
|
+
editor,
|
|
40103
|
+
sectionId,
|
|
40104
|
+
type2
|
|
40105
|
+
);
|
|
40106
|
+
});
|
|
40082
40107
|
};
|
|
40083
40108
|
const annotateDocument = ({
|
|
40084
40109
|
annotationValues = [],
|
|
40085
40110
|
hiddenFieldIds = [],
|
|
40111
|
+
removeEmptyFields = false,
|
|
40086
40112
|
schema,
|
|
40087
40113
|
tr,
|
|
40088
40114
|
editor
|
|
40089
40115
|
}) => {
|
|
40090
|
-
annotateHeadersAndFooters({ editor, annotationValues, hiddenFieldIds });
|
|
40116
|
+
annotateHeadersAndFooters({ editor, annotationValues, hiddenFieldIds, removeEmptyFields });
|
|
40091
40117
|
const annotations = [];
|
|
40092
40118
|
const FieldType = schema.nodes.fieldAnnotation;
|
|
40093
40119
|
tr.doc.descendants((node2, pos) => {
|
|
@@ -40140,11 +40166,13 @@ const annotateDocument = ({
|
|
|
40140
40166
|
});
|
|
40141
40167
|
}
|
|
40142
40168
|
}
|
|
40143
|
-
|
|
40144
|
-
|
|
40145
|
-
|
|
40146
|
-
|
|
40147
|
-
|
|
40169
|
+
if (removeEmptyFields) {
|
|
40170
|
+
Array.from(toDelete).sort((a, b) => b - a).forEach((pos) => {
|
|
40171
|
+
const ann = annotations.find((a) => a.pos === pos);
|
|
40172
|
+
if (!ann) return;
|
|
40173
|
+
tr = tr.delete(pos, pos + ann.node.nodeSize);
|
|
40174
|
+
});
|
|
40175
|
+
}
|
|
40148
40176
|
return tr;
|
|
40149
40177
|
};
|
|
40150
40178
|
const getFormattedDate = (input = null, format = "") => {
|
|
@@ -40162,11 +40190,40 @@ const getFormattedDate = (input = null, format = "") => {
|
|
|
40162
40190
|
// e.g. “2025”
|
|
40163
40191
|
});
|
|
40164
40192
|
};
|
|
40165
|
-
const
|
|
40193
|
+
const updateHeaderFooterFieldAnnotations = ({ editor, fieldIdOrArray, attrs = {} }) => {
|
|
40194
|
+
if (!editor) return;
|
|
40195
|
+
const sectionEditors = getAllHeaderFooterEditors(editor);
|
|
40196
|
+
sectionEditors.forEach(({ editor: sectionEditor, sectionId, type: type2 }) => {
|
|
40197
|
+
sectionEditor.commands.updateFieldAnnotations(fieldIdOrArray, attrs);
|
|
40198
|
+
onHeaderFooterDataUpdate(
|
|
40199
|
+
{ editor: sectionEditor },
|
|
40200
|
+
editor,
|
|
40201
|
+
sectionId,
|
|
40202
|
+
type2
|
|
40203
|
+
);
|
|
40204
|
+
});
|
|
40205
|
+
};
|
|
40206
|
+
const deleteHeaderFooterFieldAnnotations = ({ editor, fieldIdOrArray }) => {
|
|
40207
|
+
if (!editor) return;
|
|
40208
|
+
const sectionEditors = getAllHeaderFooterEditors(editor);
|
|
40209
|
+
sectionEditors.forEach(({ editor: sectionEditor, sectionId, type: type2 }) => {
|
|
40210
|
+
sectionEditor.commands.deleteFieldAnnotations(fieldIdOrArray);
|
|
40211
|
+
onHeaderFooterDataUpdate(
|
|
40212
|
+
{ editor: sectionEditor },
|
|
40213
|
+
editor,
|
|
40214
|
+
sectionId,
|
|
40215
|
+
type2
|
|
40216
|
+
);
|
|
40217
|
+
});
|
|
40218
|
+
};
|
|
40219
|
+
const AnnotatorHelpers = {
|
|
40166
40220
|
getFieldAttrs,
|
|
40167
40221
|
processTables,
|
|
40168
40222
|
annotateDocument,
|
|
40169
|
-
annotateHeadersAndFooters
|
|
40223
|
+
annotateHeadersAndFooters,
|
|
40224
|
+
getAllHeaderFooterEditors,
|
|
40225
|
+
updateHeaderFooterFieldAnnotations,
|
|
40226
|
+
deleteHeaderFooterFieldAnnotations
|
|
40170
40227
|
};
|
|
40171
40228
|
const CollaborationPluginKey = new PluginKey("collaboration");
|
|
40172
40229
|
const Collaboration = Extension.create({
|
|
@@ -40316,6 +40373,16 @@ const generateCollaborationData = (editor) => {
|
|
|
40316
40373
|
initializeMetaMap(ydoc, editor);
|
|
40317
40374
|
return encodeStateAsUpdate(ydoc);
|
|
40318
40375
|
};
|
|
40376
|
+
const isHighContrastMode = ref$1(false);
|
|
40377
|
+
function useHighContrastMode() {
|
|
40378
|
+
const setHighContrastMode = (value) => {
|
|
40379
|
+
isHighContrastMode.value = value;
|
|
40380
|
+
};
|
|
40381
|
+
return {
|
|
40382
|
+
isHighContrastMode,
|
|
40383
|
+
setHighContrastMode
|
|
40384
|
+
};
|
|
40385
|
+
}
|
|
40319
40386
|
const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
40320
40387
|
/**
|
|
40321
40388
|
* Create a new Editor instance
|
|
@@ -40408,6 +40475,8 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
40408
40475
|
}
|
|
40409
40476
|
};
|
|
40410
40477
|
let initMode = modes[this.options.mode] ?? modes.default;
|
|
40478
|
+
const { setHighContrastMode } = useHighContrastMode();
|
|
40479
|
+
this.setHighContrastMode = setHighContrastMode;
|
|
40411
40480
|
initMode();
|
|
40412
40481
|
}
|
|
40413
40482
|
/**
|
|
@@ -40704,6 +40773,10 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
40704
40773
|
if (!proseMirror || !pageSize || !pageMargins) {
|
|
40705
40774
|
return;
|
|
40706
40775
|
}
|
|
40776
|
+
proseMirror.setAttribute("role", "document");
|
|
40777
|
+
proseMirror.setAttribute("aria-multiline", true);
|
|
40778
|
+
proseMirror.setAttribute("aria-label", "Main content area, start typing to enter text.");
|
|
40779
|
+
proseMirror.setAttribute("aria-description", "");
|
|
40707
40780
|
element.style.width = pageSize.width + "in";
|
|
40708
40781
|
element.style.minWidth = pageSize.width + "in";
|
|
40709
40782
|
element.style.minHeight = pageSize.height + "in";
|
|
@@ -40912,8 +40985,13 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
40912
40985
|
updatedDocs["word/commentsExtensible.xml"] = String(commentsExtensibleXml);
|
|
40913
40986
|
updatedDocs["word/commentsIds.xml"] = String(commentsIdsXml);
|
|
40914
40987
|
}
|
|
40915
|
-
if (getUpdatedDocs) return updatedDocs;
|
|
40916
40988
|
const zipper = new DocxZipper();
|
|
40989
|
+
if (getUpdatedDocs) {
|
|
40990
|
+
updatedDocs["[Content_Types].xml"] = await zipper.updateContentTypes({
|
|
40991
|
+
files: this.options.content
|
|
40992
|
+
}, media, true);
|
|
40993
|
+
return updatedDocs;
|
|
40994
|
+
}
|
|
40917
40995
|
const result = await zipper.updateZip({
|
|
40918
40996
|
docx: this.options.content,
|
|
40919
40997
|
updatedDocs,
|
|
@@ -40955,7 +41033,7 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
40955
41033
|
* @returns {Object | void} Migration results
|
|
40956
41034
|
*/
|
|
40957
41035
|
processCollaborationMigrations() {
|
|
40958
|
-
console.debug("[checkVersionMigrations] Current editor version", "0.12.
|
|
41036
|
+
console.debug("[checkVersionMigrations] Current editor version", "0.12.34-next.1");
|
|
40959
41037
|
if (!this.options.ydoc) return;
|
|
40960
41038
|
const metaMap = this.options.ydoc.getMap("meta");
|
|
40961
41039
|
let docVersion = metaMap.get("version");
|
|
@@ -41044,10 +41122,8 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
41044
41122
|
*/
|
|
41045
41123
|
prepareForAnnotations(annotationValues = []) {
|
|
41046
41124
|
const { tr } = this.state;
|
|
41047
|
-
const
|
|
41048
|
-
const newTr = AnnotatorServices.processTables({ state: this.state, tr, annotationValues });
|
|
41125
|
+
const newTr = AnnotatorHelpers.processTables({ state: this.state, tr, annotationValues });
|
|
41049
41126
|
this.view.dispatch(newTr);
|
|
41050
|
-
AnnotatorServices.annotateHeadersAndFooters({ editor: this, annotationValues });
|
|
41051
41127
|
}
|
|
41052
41128
|
/**
|
|
41053
41129
|
* Annotate the document with the given annotation values.
|
|
@@ -41056,15 +41132,16 @@ const _Editor = class _Editor2 extends EventEmitter$1 {
|
|
|
41056
41132
|
* @param {String[]} hiddenIds List of field ids to remove from the document.
|
|
41057
41133
|
* @returns {void}
|
|
41058
41134
|
*/
|
|
41059
|
-
annotate(annotationValues = [], hiddenIds = []) {
|
|
41135
|
+
annotate(annotationValues = [], hiddenIds = [], removeEmptyFields = false) {
|
|
41060
41136
|
const { state: state2, view, schema } = this;
|
|
41061
41137
|
let tr = state2.tr;
|
|
41062
|
-
tr =
|
|
41063
|
-
tr =
|
|
41138
|
+
tr = AnnotatorHelpers.processTables({ state: this.state, tr, annotationValues });
|
|
41139
|
+
tr = AnnotatorHelpers.annotateDocument({
|
|
41064
41140
|
tr,
|
|
41065
41141
|
schema,
|
|
41066
41142
|
annotationValues,
|
|
41067
41143
|
hiddenFieldIds: hiddenIds,
|
|
41144
|
+
removeEmptyFields,
|
|
41068
41145
|
editor: this
|
|
41069
41146
|
});
|
|
41070
41147
|
if (tr.docChanged) view.dispatch(tr.scrollIntoView());
|
|
@@ -41319,6 +41396,7 @@ createView_fn = function() {
|
|
|
41319
41396
|
toggleHeaderFooterEditMode(this, null, false);
|
|
41320
41397
|
const pm = document.querySelector(".ProseMirror");
|
|
41321
41398
|
pm.classList.remove("header-footer-edit");
|
|
41399
|
+
pm.setAttribute("aria-readonly", false);
|
|
41322
41400
|
}
|
|
41323
41401
|
}
|
|
41324
41402
|
});
|
|
@@ -42291,7 +42369,8 @@ const AiLoaderNode = Node$1.create({
|
|
|
42291
42369
|
return {
|
|
42292
42370
|
htmlAttributes: {
|
|
42293
42371
|
class: "sd-ai-loader",
|
|
42294
|
-
contentEditable: "false"
|
|
42372
|
+
contentEditable: "false",
|
|
42373
|
+
"aria-label": "AI loader node"
|
|
42295
42374
|
}
|
|
42296
42375
|
};
|
|
42297
42376
|
},
|
|
@@ -42487,7 +42566,8 @@ const Document = Node$1.create({
|
|
|
42487
42566
|
addAttributes() {
|
|
42488
42567
|
return {
|
|
42489
42568
|
attributes: {
|
|
42490
|
-
rendered: false
|
|
42569
|
+
rendered: false,
|
|
42570
|
+
"aria-label": "Document node"
|
|
42491
42571
|
}
|
|
42492
42572
|
};
|
|
42493
42573
|
}
|
|
@@ -42511,7 +42591,8 @@ const RunItem = Node$1.create({
|
|
|
42511
42591
|
addAttributes() {
|
|
42512
42592
|
return {
|
|
42513
42593
|
attributes: {
|
|
42514
|
-
rendered: false
|
|
42594
|
+
rendered: false,
|
|
42595
|
+
"aria-label": "Run node"
|
|
42515
42596
|
}
|
|
42516
42597
|
};
|
|
42517
42598
|
}
|
|
@@ -42564,7 +42645,9 @@ const BulletList = Node$1.create({
|
|
|
42564
42645
|
addOptions() {
|
|
42565
42646
|
return {
|
|
42566
42647
|
itemTypeName: "listItem",
|
|
42567
|
-
htmlAttributes: {
|
|
42648
|
+
htmlAttributes: {
|
|
42649
|
+
"aria-label": "Bullet list node"
|
|
42650
|
+
},
|
|
42568
42651
|
keepMarks: true,
|
|
42569
42652
|
keepAttributes: false
|
|
42570
42653
|
};
|
|
@@ -42855,7 +42938,9 @@ const OrderedList = Node$1.create({
|
|
|
42855
42938
|
addOptions() {
|
|
42856
42939
|
return {
|
|
42857
42940
|
itemTypeName: "listItem",
|
|
42858
|
-
htmlAttributes: {
|
|
42941
|
+
htmlAttributes: {
|
|
42942
|
+
"aria-label": "Ordered list node"
|
|
42943
|
+
},
|
|
42859
42944
|
keepMarks: true,
|
|
42860
42945
|
keepAttributes: false,
|
|
42861
42946
|
listStyleTypes: ["decimal", "lowerAlpha", "lowerRoman"]
|
|
@@ -43255,7 +43340,9 @@ const ListItem = Node$1.create({
|
|
|
43255
43340
|
// to run listItem commands first
|
|
43256
43341
|
addOptions() {
|
|
43257
43342
|
return {
|
|
43258
|
-
htmlAttributes: {
|
|
43343
|
+
htmlAttributes: {
|
|
43344
|
+
"aria-label": "List item node"
|
|
43345
|
+
},
|
|
43259
43346
|
bulletListTypeName: "bulletList",
|
|
43260
43347
|
orderedListTypeName: "orderedList"
|
|
43261
43348
|
};
|
|
@@ -43777,7 +43864,9 @@ const Heading = Node$1.create({
|
|
|
43777
43864
|
addOptions() {
|
|
43778
43865
|
return {
|
|
43779
43866
|
levels: [1, 2, 3, 4, 5, 6],
|
|
43780
|
-
htmlAttributes: {
|
|
43867
|
+
htmlAttributes: {
|
|
43868
|
+
"aria-label": "Heading node"
|
|
43869
|
+
}
|
|
43781
43870
|
};
|
|
43782
43871
|
},
|
|
43783
43872
|
addAttributes() {
|
|
@@ -43838,7 +43927,8 @@ const CommentRangeStart = Node$1.create({
|
|
|
43838
43927
|
addOptions() {
|
|
43839
43928
|
return {
|
|
43840
43929
|
htmlAttributes: {
|
|
43841
|
-
contentEditable: "false"
|
|
43930
|
+
contentEditable: "false",
|
|
43931
|
+
"aria-label": "Comment range start node"
|
|
43842
43932
|
}
|
|
43843
43933
|
};
|
|
43844
43934
|
},
|
|
@@ -43867,7 +43957,8 @@ const CommentRangeEnd = Node$1.create({
|
|
|
43867
43957
|
addOptions() {
|
|
43868
43958
|
return {
|
|
43869
43959
|
htmlAttributes: {
|
|
43870
|
-
contentEditable: "false"
|
|
43960
|
+
contentEditable: "false",
|
|
43961
|
+
"aria-label": "Comment range end node"
|
|
43871
43962
|
}
|
|
43872
43963
|
};
|
|
43873
43964
|
},
|
|
@@ -43895,7 +43986,8 @@ const CommentReference = Node$1.create({
|
|
|
43895
43986
|
addOptions() {
|
|
43896
43987
|
return {
|
|
43897
43988
|
htmlAttributes: {
|
|
43898
|
-
contentEditable: "false"
|
|
43989
|
+
contentEditable: "false",
|
|
43990
|
+
"aria-label": "Comment reference node"
|
|
43899
43991
|
}
|
|
43900
43992
|
};
|
|
43901
43993
|
},
|
|
@@ -44070,7 +44162,9 @@ const HardBreak = Node$1.create({
|
|
|
44070
44162
|
return {
|
|
44071
44163
|
htmlAttributes: {
|
|
44072
44164
|
contentEditable: "false",
|
|
44073
|
-
lineBreakType: "page"
|
|
44165
|
+
lineBreakType: "page",
|
|
44166
|
+
"aria-hidden": "true",
|
|
44167
|
+
"aria-label": "Hard break node"
|
|
44074
44168
|
}
|
|
44075
44169
|
};
|
|
44076
44170
|
},
|
|
@@ -46428,7 +46522,9 @@ const Table = Node$1.create({
|
|
|
46428
46522
|
tableRole: "table",
|
|
46429
46523
|
addOptions() {
|
|
46430
46524
|
return {
|
|
46431
|
-
htmlAttributes: {
|
|
46525
|
+
htmlAttributes: {
|
|
46526
|
+
"aria-label": "Table node"
|
|
46527
|
+
},
|
|
46432
46528
|
resizable: true,
|
|
46433
46529
|
handleWidth: 5,
|
|
46434
46530
|
cellMinWidth: 25,
|
|
@@ -46678,7 +46774,9 @@ const TableHeader = Node$1.create({
|
|
|
46678
46774
|
isolating: true,
|
|
46679
46775
|
addOptions() {
|
|
46680
46776
|
return {
|
|
46681
|
-
htmlAttributes: {
|
|
46777
|
+
htmlAttributes: {
|
|
46778
|
+
"aria-label": "Table head node"
|
|
46779
|
+
}
|
|
46682
46780
|
};
|
|
46683
46781
|
},
|
|
46684
46782
|
addAttributes() {
|
|
@@ -46718,7 +46816,9 @@ const TableRow = Node$1.create({
|
|
|
46718
46816
|
tableRole: "row",
|
|
46719
46817
|
addOptions() {
|
|
46720
46818
|
return {
|
|
46721
|
-
htmlAttributes: {
|
|
46819
|
+
htmlAttributes: {
|
|
46820
|
+
"aria-label": "Table row node"
|
|
46821
|
+
}
|
|
46722
46822
|
};
|
|
46723
46823
|
},
|
|
46724
46824
|
addAttributes() {
|
|
@@ -46746,7 +46846,9 @@ const TableCell = Node$1.create({
|
|
|
46746
46846
|
isolating: true,
|
|
46747
46847
|
addOptions() {
|
|
46748
46848
|
return {
|
|
46749
|
-
htmlAttributes: {
|
|
46849
|
+
htmlAttributes: {
|
|
46850
|
+
"aria-label": "Table cell node"
|
|
46851
|
+
}
|
|
46750
46852
|
};
|
|
46751
46853
|
},
|
|
46752
46854
|
addAttributes() {
|
|
@@ -47288,6 +47390,15 @@ function findFieldAnnotationsBetween(from2, to, doc2) {
|
|
|
47288
47390
|
});
|
|
47289
47391
|
return fieldAnnotations;
|
|
47290
47392
|
}
|
|
47393
|
+
const getHeaderFooterAnnotations = (editor) => {
|
|
47394
|
+
const editors = getAllHeaderFooterEditors(editor);
|
|
47395
|
+
const allAnnotations = [];
|
|
47396
|
+
editors.forEach(({ id, editor: editor2 }) => {
|
|
47397
|
+
const annotations = getAllFieldAnnotations(editor2.state);
|
|
47398
|
+
allAnnotations.push(...annotations);
|
|
47399
|
+
});
|
|
47400
|
+
return allAnnotations;
|
|
47401
|
+
};
|
|
47291
47402
|
const index$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
47292
47403
|
__proto__: null,
|
|
47293
47404
|
findFieldAnnotations,
|
|
@@ -47297,6 +47408,7 @@ const index$1 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePrope
|
|
|
47297
47408
|
findRemovedFieldAnnotations,
|
|
47298
47409
|
getAllFieldAnnotations,
|
|
47299
47410
|
getAllFieldAnnotationsWithRect,
|
|
47411
|
+
getHeaderFooterAnnotations,
|
|
47300
47412
|
trackFieldAnnotationsDeletion
|
|
47301
47413
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
47302
47414
|
function guard(low, high, value) {
|
|
@@ -47427,7 +47539,8 @@ const FieldAnnotation = Node$1.create({
|
|
|
47427
47539
|
addOptions() {
|
|
47428
47540
|
return {
|
|
47429
47541
|
htmlAttributes: {
|
|
47430
|
-
class: annotationClass
|
|
47542
|
+
class: annotationClass,
|
|
47543
|
+
"aria-label": "Field annotation node"
|
|
47431
47544
|
},
|
|
47432
47545
|
annotationClass,
|
|
47433
47546
|
annotationContentClass,
|
|
@@ -48369,7 +48482,8 @@ const Image = Node$1.create({
|
|
|
48369
48482
|
return {
|
|
48370
48483
|
allowBase64: true,
|
|
48371
48484
|
htmlAttributes: {
|
|
48372
|
-
style: "display: inline-block;"
|
|
48485
|
+
style: "display: inline-block;",
|
|
48486
|
+
"aria-label": "Image node"
|
|
48373
48487
|
}
|
|
48374
48488
|
};
|
|
48375
48489
|
},
|
|
@@ -48485,7 +48599,11 @@ const BookmarkStart = Node$1.create({
|
|
|
48485
48599
|
inline: true,
|
|
48486
48600
|
addOptions() {
|
|
48487
48601
|
return {
|
|
48488
|
-
htmlAttributes: {
|
|
48602
|
+
htmlAttributes: {
|
|
48603
|
+
style: "height: 0; width: 0;",
|
|
48604
|
+
"aria-label": "Bookmark start node",
|
|
48605
|
+
role: "link"
|
|
48606
|
+
}
|
|
48489
48607
|
};
|
|
48490
48608
|
},
|
|
48491
48609
|
addAttributes() {
|
|
@@ -48519,7 +48637,8 @@ const Mention = Node$1.create({
|
|
|
48519
48637
|
addOptions() {
|
|
48520
48638
|
return {
|
|
48521
48639
|
htmlAttributes: {
|
|
48522
|
-
class: "sd-editor-mention"
|
|
48640
|
+
class: "sd-editor-mention",
|
|
48641
|
+
"aria-label": "Mention node"
|
|
48523
48642
|
}
|
|
48524
48643
|
};
|
|
48525
48644
|
},
|
|
@@ -48557,7 +48676,8 @@ const PageNumber = Node$1.create({
|
|
|
48557
48676
|
addOptions() {
|
|
48558
48677
|
return {
|
|
48559
48678
|
htmlAttributes: {
|
|
48560
|
-
"data-id": "auto-page-number"
|
|
48679
|
+
"data-id": "auto-page-number",
|
|
48680
|
+
"aria-label": "Page number node"
|
|
48561
48681
|
}
|
|
48562
48682
|
};
|
|
48563
48683
|
},
|
|
@@ -48576,7 +48696,8 @@ const TotalPageCount = Node$1.create({
|
|
|
48576
48696
|
addOptions() {
|
|
48577
48697
|
return {
|
|
48578
48698
|
htmlAttributes: {
|
|
48579
|
-
"data-id": "auto-total-pages"
|
|
48699
|
+
"data-id": "auto-total-pages",
|
|
48700
|
+
"aria-label": "Total page count node"
|
|
48580
48701
|
}
|
|
48581
48702
|
};
|
|
48582
48703
|
},
|
|
@@ -48595,7 +48716,8 @@ const ShapeContainer = Node$1.create({
|
|
|
48595
48716
|
addOptions() {
|
|
48596
48717
|
return {
|
|
48597
48718
|
htmlAttributes: {
|
|
48598
|
-
class: "sd-editor-shape-container"
|
|
48719
|
+
class: "sd-editor-shape-container",
|
|
48720
|
+
"aria-label": "Shape container node"
|
|
48599
48721
|
}
|
|
48600
48722
|
};
|
|
48601
48723
|
},
|
|
@@ -48648,7 +48770,8 @@ const ShapeTextbox = Node$1.create({
|
|
|
48648
48770
|
addOptions() {
|
|
48649
48771
|
return {
|
|
48650
48772
|
htmlAttributes: {
|
|
48651
|
-
class: "sd-editor-shape-textbox"
|
|
48773
|
+
class: "sd-editor-shape-textbox",
|
|
48774
|
+
"aria-label": "Shape textbox node"
|
|
48652
48775
|
}
|
|
48653
48776
|
};
|
|
48654
48777
|
},
|
|
@@ -48740,7 +48863,9 @@ const StructuredContent = Node$1.create({
|
|
|
48740
48863
|
addOptions() {
|
|
48741
48864
|
return {
|
|
48742
48865
|
annotationClass: "sd-structured-content-tag",
|
|
48743
|
-
htmlAttributes: {
|
|
48866
|
+
htmlAttributes: {
|
|
48867
|
+
"aria-label": "Structured content node"
|
|
48868
|
+
}
|
|
48744
48869
|
};
|
|
48745
48870
|
},
|
|
48746
48871
|
parseDOM() {
|
|
@@ -52200,9 +52325,9 @@ const _export_sfc = (sfc, props) => {
|
|
|
52200
52325
|
};
|
|
52201
52326
|
const _hoisted_1$e = ["onClick", "onMouseenter"];
|
|
52202
52327
|
const _hoisted_2$c = { key: 0 };
|
|
52203
|
-
const _hoisted_3$
|
|
52328
|
+
const _hoisted_3$a = { key: 0 };
|
|
52204
52329
|
const _hoisted_4$6 = { key: 1 };
|
|
52205
|
-
const _hoisted_5$
|
|
52330
|
+
const _hoisted_5$5 = { key: 1 };
|
|
52206
52331
|
const _sfc_main$f = {
|
|
52207
52332
|
__name: "Mentions",
|
|
52208
52333
|
props: {
|
|
@@ -52275,9 +52400,9 @@ const _sfc_main$f = {
|
|
|
52275
52400
|
class: normalizeClass(["user-row", { selected: activeUserIndex.value === index2 }])
|
|
52276
52401
|
}, [
|
|
52277
52402
|
user.name ? (openBlock(), createElementBlock("div", _hoisted_2$c, [
|
|
52278
|
-
user.name ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
52403
|
+
user.name ? (openBlock(), createElementBlock("span", _hoisted_3$a, toDisplayString(user.name), 1)) : createCommentVNode("", true),
|
|
52279
52404
|
user.name && user.email ? (openBlock(), createElementBlock("span", _hoisted_4$6, " (" + toDisplayString(user.email) + ")", 1)) : createCommentVNode("", true)
|
|
52280
|
-
])) : (openBlock(), createElementBlock("div", _hoisted_5$
|
|
52405
|
+
])) : (openBlock(), createElementBlock("div", _hoisted_5$5, [
|
|
52281
52406
|
createBaseVNode("span", null, toDisplayString(user.email), 1)
|
|
52282
52407
|
]))
|
|
52283
52408
|
], 42, _hoisted_1$e);
|
|
@@ -53588,15 +53713,16 @@ const _sfc_main$5$1 = {
|
|
|
53588
53713
|
}
|
|
53589
53714
|
};
|
|
53590
53715
|
const ToolbarButtonIcon = /* @__PURE__ */ _export_sfc(_sfc_main$5$1, [["__scopeId", "data-v-6d7523ab"]]);
|
|
53591
|
-
const _hoisted_1$3$1 = ["
|
|
53592
|
-
const _hoisted_2$2$1 =
|
|
53716
|
+
const _hoisted_1$3$1 = ["role"];
|
|
53717
|
+
const _hoisted_2$2$1 = ["data-item", "aria-label"];
|
|
53718
|
+
const _hoisted_3$2$1 = {
|
|
53593
53719
|
key: 1,
|
|
53594
53720
|
class: "button-label"
|
|
53595
53721
|
};
|
|
53596
|
-
const
|
|
53597
|
-
const
|
|
53598
|
-
const
|
|
53599
|
-
const
|
|
53722
|
+
const _hoisted_4$5 = { key: 2 };
|
|
53723
|
+
const _hoisted_5$4 = ["placeholder", "onKeydown", "id"];
|
|
53724
|
+
const _hoisted_6$2 = ["placeholder", "onKeydown", "id"];
|
|
53725
|
+
const _hoisted_7$1 = ["innerHTML"];
|
|
53600
53726
|
const _sfc_main$4$1 = {
|
|
53601
53727
|
__name: "ToolbarButton",
|
|
53602
53728
|
props: {
|
|
@@ -53623,6 +53749,10 @@ const _sfc_main$4$1 = {
|
|
|
53623
53749
|
defaultLabel: {
|
|
53624
53750
|
type: String,
|
|
53625
53751
|
default: null
|
|
53752
|
+
},
|
|
53753
|
+
isOverflowItem: {
|
|
53754
|
+
type: Boolean,
|
|
53755
|
+
default: false
|
|
53626
53756
|
}
|
|
53627
53757
|
},
|
|
53628
53758
|
emits: ["buttonClick", "textSubmit"],
|
|
@@ -53646,6 +53776,7 @@ const _sfc_main$4$1 = {
|
|
|
53646
53776
|
} = props.toolbarItem;
|
|
53647
53777
|
const inlineTextInput = ref$1(props.defaultLabel);
|
|
53648
53778
|
const inlineInput = ref$1(null);
|
|
53779
|
+
const { isHighContrastMode: isHighContrastMode2 } = useHighContrastMode();
|
|
53649
53780
|
const handleClick2 = () => {
|
|
53650
53781
|
if (hasInlineTextInput) {
|
|
53651
53782
|
inlineInput.value?.focus();
|
|
@@ -53673,12 +53804,15 @@ const _sfc_main$4$1 = {
|
|
|
53673
53804
|
return (_ctx, _cache) => {
|
|
53674
53805
|
return openBlock(), createElementBlock("div", {
|
|
53675
53806
|
class: normalizeClass(["toolbar-item", unref(attributes).className]),
|
|
53676
|
-
style: normalizeStyle(getStyle.value)
|
|
53807
|
+
style: normalizeStyle(getStyle.value),
|
|
53808
|
+
role: __props.isOverflowItem ? "menuitem" : ""
|
|
53677
53809
|
}, [
|
|
53678
53810
|
createBaseVNode("div", {
|
|
53679
53811
|
onClick: handleClick2,
|
|
53680
|
-
class: normalizeClass(["toolbar-button", { active: unref(active), disabled: unref(disabled), narrow: __props.isNarrow, wide: __props.isWide, "has-inline-text-input": unref(hasInlineTextInput) }]),
|
|
53681
|
-
"data-item": `btn-${unref(name) || ""}
|
|
53812
|
+
class: normalizeClass(["toolbar-button", { active: unref(active), disabled: unref(disabled), narrow: __props.isNarrow, wide: __props.isWide, "has-inline-text-input": unref(hasInlineTextInput), "high-contrast": unref(isHighContrastMode2) }]),
|
|
53813
|
+
"data-item": `btn-${unref(name) || ""}`,
|
|
53814
|
+
"aria-label": unref(attributes).ariaLabel,
|
|
53815
|
+
role: "button"
|
|
53682
53816
|
}, [
|
|
53683
53817
|
unref(icon) ? (openBlock(), createBlock(ToolbarButtonIcon, {
|
|
53684
53818
|
key: 0,
|
|
@@ -53687,8 +53821,8 @@ const _sfc_main$4$1 = {
|
|
|
53687
53821
|
icon: unref(icon),
|
|
53688
53822
|
name: unref(name)
|
|
53689
53823
|
}, null, 8, ["color", "icon", "name"])) : createCommentVNode("", true),
|
|
53690
|
-
unref(label) && !unref(hideLabel) && !unref(inlineTextInputVisible) ? (openBlock(), createElementBlock("div",
|
|
53691
|
-
unref(inlineTextInputVisible) ? (openBlock(), createElementBlock("span",
|
|
53824
|
+
unref(label) && !unref(hideLabel) && !unref(inlineTextInputVisible) ? (openBlock(), createElementBlock("div", _hoisted_3$2$1, toDisplayString(unref(label)), 1)) : createCommentVNode("", true),
|
|
53825
|
+
unref(inlineTextInputVisible) ? (openBlock(), createElementBlock("span", _hoisted_4$5, [
|
|
53692
53826
|
unref(name) === "fontSize" ? withDirectives((openBlock(), createElementBlock("input", {
|
|
53693
53827
|
key: 0,
|
|
53694
53828
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => inlineTextInput.value = $event),
|
|
@@ -53696,12 +53830,12 @@ const _sfc_main$4$1 = {
|
|
|
53696
53830
|
placeholder: unref(label),
|
|
53697
53831
|
onKeydown: withKeys(withModifiers(handleInputSubmit, ["prevent"]), ["enter"]),
|
|
53698
53832
|
type: "text",
|
|
53699
|
-
class: "button-text-input",
|
|
53833
|
+
class: normalizeClass(["button-text-input", { "high-contrast": unref(isHighContrastMode2) }]),
|
|
53700
53834
|
id: "inlineTextInput-" + unref(name),
|
|
53701
53835
|
autoccomplete: "off",
|
|
53702
53836
|
ref_key: "inlineInput",
|
|
53703
53837
|
ref: inlineInput
|
|
53704
|
-
}, null,
|
|
53838
|
+
}, null, 42, _hoisted_5$4)), [
|
|
53705
53839
|
[vModelText, inlineTextInput.value]
|
|
53706
53840
|
]) : withDirectives((openBlock(), createElementBlock("input", {
|
|
53707
53841
|
key: 1,
|
|
@@ -53714,7 +53848,7 @@ const _sfc_main$4$1 = {
|
|
|
53714
53848
|
autoccomplete: "off",
|
|
53715
53849
|
ref_key: "inlineInput",
|
|
53716
53850
|
ref: inlineInput
|
|
53717
|
-
}, null, 40,
|
|
53851
|
+
}, null, 40, _hoisted_6$2)), [
|
|
53718
53852
|
[vModelText, inlineTextInput.value]
|
|
53719
53853
|
])
|
|
53720
53854
|
])) : createCommentVNode("", true),
|
|
@@ -53723,14 +53857,18 @@ const _sfc_main$4$1 = {
|
|
|
53723
53857
|
class: "dropdown-caret",
|
|
53724
53858
|
innerHTML: caretIcon.value,
|
|
53725
53859
|
style: normalizeStyle({ opacity: unref(disabled) ? 0.6 : 1 })
|
|
53726
|
-
}, null, 12,
|
|
53727
|
-
], 10,
|
|
53728
|
-
],
|
|
53860
|
+
}, null, 12, _hoisted_7$1)) : createCommentVNode("", true)
|
|
53861
|
+
], 10, _hoisted_2$2$1)
|
|
53862
|
+
], 14, _hoisted_1$3$1);
|
|
53729
53863
|
};
|
|
53730
53864
|
}
|
|
53731
53865
|
};
|
|
53732
|
-
const ToolbarButton = /* @__PURE__ */ _export_sfc(_sfc_main$4$1, [["__scopeId", "data-v-
|
|
53733
|
-
const _hoisted_1$2$1 = {
|
|
53866
|
+
const ToolbarButton = /* @__PURE__ */ _export_sfc(_sfc_main$4$1, [["__scopeId", "data-v-6eb57404"]]);
|
|
53867
|
+
const _hoisted_1$2$1 = {
|
|
53868
|
+
class: "toolbar-separator",
|
|
53869
|
+
role: "separator",
|
|
53870
|
+
"aria-label": "Toolbar separator"
|
|
53871
|
+
};
|
|
53734
53872
|
const _sfc_main$3$1 = {
|
|
53735
53873
|
__name: "ToolbarSeparator",
|
|
53736
53874
|
props: {
|
|
@@ -53741,19 +53879,30 @@ const _sfc_main$3$1 = {
|
|
|
53741
53879
|
},
|
|
53742
53880
|
emits: ["command"],
|
|
53743
53881
|
setup(__props, { emit: __emit }) {
|
|
53882
|
+
const { isHighContrastMode: isHighContrastMode2 } = useHighContrastMode();
|
|
53883
|
+
const getSeparatorColor = () => {
|
|
53884
|
+
if (isHighContrastMode2.value) {
|
|
53885
|
+
return "#000";
|
|
53886
|
+
}
|
|
53887
|
+
return "#dbdbdb";
|
|
53888
|
+
};
|
|
53744
53889
|
return (_ctx, _cache) => {
|
|
53745
|
-
return openBlock(), createElementBlock("div", _hoisted_1$2$1,
|
|
53746
|
-
createBaseVNode("div", {
|
|
53747
|
-
|
|
53890
|
+
return openBlock(), createElementBlock("div", _hoisted_1$2$1, [
|
|
53891
|
+
createBaseVNode("div", {
|
|
53892
|
+
class: "separator-inner",
|
|
53893
|
+
style: normalizeStyle({ backgroundColor: getSeparatorColor() })
|
|
53894
|
+
}, null, 4)
|
|
53895
|
+
]);
|
|
53748
53896
|
};
|
|
53749
53897
|
}
|
|
53750
53898
|
};
|
|
53751
|
-
const ToolbarSeparator = /* @__PURE__ */ _export_sfc(_sfc_main$3$1, [["__scopeId", "data-v-
|
|
53899
|
+
const ToolbarSeparator = /* @__PURE__ */ _export_sfc(_sfc_main$3$1, [["__scopeId", "data-v-b240fc3a"]]);
|
|
53752
53900
|
const _hoisted_1$1$1 = { class: "overflow-menu" };
|
|
53753
53901
|
const _hoisted_2$1$1 = { class: "overflow-menu-trigger" };
|
|
53754
53902
|
const _hoisted_3$1$1 = {
|
|
53755
53903
|
key: 0,
|
|
53756
|
-
class: "overflow-menu_items"
|
|
53904
|
+
class: "overflow-menu_items",
|
|
53905
|
+
role: "group"
|
|
53757
53906
|
};
|
|
53758
53907
|
const _sfc_main$2$1 = {
|
|
53759
53908
|
__name: "OverflowMenu",
|
|
@@ -53791,16 +53940,17 @@ const _sfc_main$2$1 = {
|
|
|
53791
53940
|
]),
|
|
53792
53941
|
isDropdownOpened.value ? (openBlock(), createElementBlock("div", _hoisted_3$1$1, [
|
|
53793
53942
|
createVNode(ButtonGroup, {
|
|
53943
|
+
class: "superdoc-toolbar-overflow",
|
|
53794
53944
|
"toolbar-items": __props.overflowItems,
|
|
53795
|
-
|
|
53796
|
-
|
|
53945
|
+
"from-overflow": "",
|
|
53946
|
+
onCommand: handleCommand
|
|
53797
53947
|
}, null, 8, ["toolbar-items"])
|
|
53798
53948
|
])) : createCommentVNode("", true)
|
|
53799
53949
|
]);
|
|
53800
53950
|
};
|
|
53801
53951
|
}
|
|
53802
53952
|
};
|
|
53803
|
-
const OverflowMenu = /* @__PURE__ */ _export_sfc(_sfc_main$2$1, [["__scopeId", "data-v-
|
|
53953
|
+
const OverflowMenu = /* @__PURE__ */ _export_sfc(_sfc_main$2$1, [["__scopeId", "data-v-c637209b"]]);
|
|
53804
53954
|
function plugin$1(options2) {
|
|
53805
53955
|
let _bPrefix = ".";
|
|
53806
53956
|
let _ePrefix = "__";
|
|
@@ -63133,7 +63283,7 @@ const NSkeleton = defineComponent({
|
|
|
63133
63283
|
});
|
|
63134
63284
|
const _hoisted_1$d = { key: 0 };
|
|
63135
63285
|
const _hoisted_2$b = { key: 0 };
|
|
63136
|
-
const _hoisted_3$
|
|
63286
|
+
const _hoisted_3$9 = { key: 0 };
|
|
63137
63287
|
const _sfc_main$1$1 = {
|
|
63138
63288
|
__name: "ButtonGroup",
|
|
63139
63289
|
props: {
|
|
@@ -63148,6 +63298,10 @@ const _sfc_main$1$1 = {
|
|
|
63148
63298
|
position: {
|
|
63149
63299
|
type: String,
|
|
63150
63300
|
default: "left"
|
|
63301
|
+
},
|
|
63302
|
+
fromOverflow: {
|
|
63303
|
+
type: Boolean,
|
|
63304
|
+
default: false
|
|
63151
63305
|
}
|
|
63152
63306
|
},
|
|
63153
63307
|
emits: ["command"],
|
|
@@ -63155,6 +63309,7 @@ const _sfc_main$1$1 = {
|
|
|
63155
63309
|
const emit = __emit;
|
|
63156
63310
|
const props = __props;
|
|
63157
63311
|
const currentItem = ref$1(null);
|
|
63312
|
+
const { isHighContrastMode: isHighContrastMode2 } = useHighContrastMode();
|
|
63158
63313
|
const isMobile = window.matchMedia("(max-width: 768px)").matches;
|
|
63159
63314
|
const styleMap = {
|
|
63160
63315
|
left: {
|
|
@@ -63213,13 +63368,20 @@ const _sfc_main$1$1 = {
|
|
|
63213
63368
|
};
|
|
63214
63369
|
});
|
|
63215
63370
|
};
|
|
63371
|
+
const getDropdownAttributes = (option, item) => {
|
|
63372
|
+
return {
|
|
63373
|
+
role: "menuitem",
|
|
63374
|
+
ariaLabel: `${item.attributes.value.ariaLabel} - ${option.label}`
|
|
63375
|
+
};
|
|
63376
|
+
};
|
|
63216
63377
|
const handleClickOutside = (e) => {
|
|
63217
63378
|
closeDropdowns();
|
|
63218
63379
|
};
|
|
63219
63380
|
return (_ctx, _cache) => {
|
|
63220
63381
|
return openBlock(), createElementBlock("div", {
|
|
63221
63382
|
style: normalizeStyle(getPositionStyle.value),
|
|
63222
|
-
class: "button-group"
|
|
63383
|
+
class: "button-group",
|
|
63384
|
+
role: "group"
|
|
63223
63385
|
}, [
|
|
63224
63386
|
(openBlock(true), createElementBlock(Fragment$1, null, renderList(__props.toolbarItems, (item) => {
|
|
63225
63387
|
return openBlock(), createElementBlock("div", {
|
|
@@ -63240,10 +63402,14 @@ const _sfc_main$1$1 = {
|
|
|
63240
63402
|
show: item.expand.value,
|
|
63241
63403
|
size: "medium",
|
|
63242
63404
|
placement: "bottom-start",
|
|
63243
|
-
class: "toolbar-button toolbar-dropdown sd-editor-toolbar-dropdown",
|
|
63405
|
+
class: normalizeClass(["toolbar-button toolbar-dropdown sd-editor-toolbar-dropdown", { "high-contrast": unref(isHighContrastMode2) }]),
|
|
63244
63406
|
onSelect: (key, option) => handleSelect(item, option),
|
|
63245
63407
|
onClickoutside: handleClickOutside,
|
|
63246
|
-
style: normalizeStyle(item.dropdownStyles.value)
|
|
63408
|
+
style: normalizeStyle(item.dropdownStyles.value),
|
|
63409
|
+
"menu-props": () => ({
|
|
63410
|
+
role: "menu"
|
|
63411
|
+
}),
|
|
63412
|
+
"node-props": (option) => getDropdownAttributes(option, item)
|
|
63247
63413
|
}, {
|
|
63248
63414
|
default: withCtx(() => [
|
|
63249
63415
|
createVNode(unref(NTooltip), {
|
|
@@ -63267,7 +63433,7 @@ const _sfc_main$1$1 = {
|
|
|
63267
63433
|
}, 1032, ["disabled"])
|
|
63268
63434
|
]),
|
|
63269
63435
|
_: 2
|
|
63270
|
-
}, 1032, ["options", "trigger", "show", "onSelect", "style"])) : isButton(item) ? (openBlock(), createBlock(unref(NTooltip), {
|
|
63436
|
+
}, 1032, ["options", "trigger", "show", "class", "onSelect", "style", "node-props"])) : isButton(item) ? (openBlock(), createBlock(unref(NTooltip), {
|
|
63271
63437
|
key: 2,
|
|
63272
63438
|
trigger: "hover",
|
|
63273
63439
|
class: "sd-editor-toolbar-tooltip"
|
|
@@ -63275,14 +63441,15 @@ const _sfc_main$1$1 = {
|
|
|
63275
63441
|
trigger: withCtx(() => [
|
|
63276
63442
|
createVNode(ToolbarButton, {
|
|
63277
63443
|
"toolbar-item": item,
|
|
63444
|
+
"is-overflow-item": __props.fromOverflow,
|
|
63278
63445
|
onTextSubmit: ($event) => handleToolbarButtonTextSubmit(item, $event),
|
|
63279
63446
|
onButtonClick: ($event) => handleToolbarButtonClick(item)
|
|
63280
|
-
}, null, 8, ["toolbar-item", "onTextSubmit", "onButtonClick"])
|
|
63447
|
+
}, null, 8, ["toolbar-item", "is-overflow-item", "onTextSubmit", "onButtonClick"])
|
|
63281
63448
|
]),
|
|
63282
63449
|
default: withCtx(() => [
|
|
63283
63450
|
item.tooltip ? (openBlock(), createElementBlock("div", _hoisted_2$b, [
|
|
63284
63451
|
createTextVNode(toDisplayString(item.tooltip) + " ", 1),
|
|
63285
|
-
item.disabled.value ? (openBlock(), createElementBlock("span", _hoisted_3$
|
|
63452
|
+
item.disabled.value ? (openBlock(), createElementBlock("span", _hoisted_3$9, "(disabled)")) : createCommentVNode("", true)
|
|
63286
63453
|
])) : createCommentVNode("", true)
|
|
63287
63454
|
]),
|
|
63288
63455
|
_: 2
|
|
@@ -63298,7 +63465,7 @@ const _sfc_main$1$1 = {
|
|
|
63298
63465
|
};
|
|
63299
63466
|
}
|
|
63300
63467
|
};
|
|
63301
|
-
const ButtonGroup = /* @__PURE__ */ _export_sfc(_sfc_main$1$1, [["__scopeId", "data-v-
|
|
63468
|
+
const ButtonGroup = /* @__PURE__ */ _export_sfc(_sfc_main$1$1, [["__scopeId", "data-v-b09e5a20"]]);
|
|
63302
63469
|
const _sfc_main$e = {
|
|
63303
63470
|
__name: "Toolbar",
|
|
63304
63471
|
emits: ["command", "toggle", "select"],
|
|
@@ -63343,7 +63510,9 @@ const _sfc_main$e = {
|
|
|
63343
63510
|
return (_ctx, _cache) => {
|
|
63344
63511
|
return openBlock(), createElementBlock("div", {
|
|
63345
63512
|
class: "superdoc-toolbar",
|
|
63346
|
-
key: unref(toolbarKey)
|
|
63513
|
+
key: unref(toolbarKey),
|
|
63514
|
+
role: "toolbar",
|
|
63515
|
+
"aria-label": "Toolbar"
|
|
63347
63516
|
}, [
|
|
63348
63517
|
unref(showLeftSide) ? (openBlock(), createBlock(ButtonGroup, {
|
|
63349
63518
|
key: 0,
|
|
@@ -63369,7 +63538,7 @@ const _sfc_main$e = {
|
|
|
63369
63538
|
};
|
|
63370
63539
|
}
|
|
63371
63540
|
};
|
|
63372
|
-
const Toolbar = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__scopeId", "data-v-
|
|
63541
|
+
const Toolbar = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__scopeId", "data-v-2a400574"]]);
|
|
63373
63542
|
const DEFAULT_API_ENDPOINT = "https://sd-dev-express-gateway-i6xtm.ondigitalocean.app/insights";
|
|
63374
63543
|
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: ";
|
|
63375
63544
|
async function baseInsightsFetch(payload, options2 = {}) {
|
|
@@ -63606,9 +63775,9 @@ const edit = '<!-- @note: includes color gradient for inline svg AI Writer -->\n
|
|
|
63606
63775
|
const paperPlane = '<!-- @note: includes color gradient for inline svg AI Writer -->\n<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 512 512"><!--!Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2025 Fonticons, Inc.-->\n <defs>\n <linearGradient id="gradient" x1="125%" y1="50%" x2="-25%" y2="50%">\n <stop offset="-20%" stop-color="rgba(218, 215, 118, 0.5)" />\n <stop offset="30%" stop-color="rgb(191, 100, 100)" />\n <stop offset="60%" stop-color="rgb(77, 82, 217)" />\n <stop offset="150%" stop-color="rgb(255, 219, 102)" />\n </linearGradient>\n </defs>\n <path fill="url(#gradient)" d="M440 6.5L24 246.4c-34.4 19.9-31.1 70.8 5.7 85.9L144 379.6V464c0 46.4 59.2 65.5 86.6 28.6l43.8-59.1 111.9 46.2c5.9 2.4 12.1 3.6 18.3 3.6 8.2 0 16.3-2.1 23.6-6.2 12.8-7.2 21.6-20 23.9-34.5l59.4-387.2c6.1-40.1-36.9-68.8-71.5-48.9zM192 464v-64.6l36.6 15.1L192 464zm212.6-28.7l-153.8-63.5L391 169.5c10.7-15.5-9.5-33.5-23.7-21.2L155.8 332.6 48 288 464 48l-59.4 387.3z"/>\n</svg>';
|
|
63607
63776
|
const _hoisted_1$c = { class: "ai-user-input-field" };
|
|
63608
63777
|
const _hoisted_2$a = ["innerHTML"];
|
|
63609
|
-
const _hoisted_3$
|
|
63778
|
+
const _hoisted_3$8 = ["placeholder"];
|
|
63610
63779
|
const _hoisted_4$4 = { class: "ai-loader" };
|
|
63611
|
-
const _hoisted_5$
|
|
63780
|
+
const _hoisted_5$3 = ["innerHTML"];
|
|
63612
63781
|
const _sfc_main$d = {
|
|
63613
63782
|
__name: "AIWriter",
|
|
63614
63783
|
props: {
|
|
@@ -63884,7 +64053,7 @@ const _sfc_main$d = {
|
|
|
63884
64053
|
onInput: handleInput,
|
|
63885
64054
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => promptText.value = $event),
|
|
63886
64055
|
rows: "4"
|
|
63887
|
-
}, null, 40, _hoisted_3$
|
|
64056
|
+
}, null, 40, _hoisted_3$8), [
|
|
63888
64057
|
[vModelText, promptText.value]
|
|
63889
64058
|
])
|
|
63890
64059
|
]),
|
|
@@ -63894,7 +64063,7 @@ const _sfc_main$d = {
|
|
|
63894
64063
|
class: "ai-textarea-icon ai-submit-button",
|
|
63895
64064
|
onClick: withModifiers(handleSubmit, ["stop"]),
|
|
63896
64065
|
innerHTML: unref(paperPlane)
|
|
63897
|
-
}, null, 8, _hoisted_5$
|
|
64066
|
+
}, null, 8, _hoisted_5$3)) : createCommentVNode("", true)
|
|
63898
64067
|
])
|
|
63899
64068
|
], 544);
|
|
63900
64069
|
};
|
|
@@ -64229,71 +64398,80 @@ const useToolbarItem = (options2) => {
|
|
|
64229
64398
|
onDeactivate
|
|
64230
64399
|
};
|
|
64231
64400
|
};
|
|
64232
|
-
const _hoisted_1$b =
|
|
64401
|
+
const _hoisted_1$b = ["innerHTML"];
|
|
64233
64402
|
const _hoisted_2$9 = ["innerHTML"];
|
|
64234
|
-
const _hoisted_3$
|
|
64403
|
+
const _hoisted_3$7 = ["innerHTML"];
|
|
64235
64404
|
const _hoisted_4$3 = ["innerHTML"];
|
|
64236
|
-
const _hoisted_5$3 = ["innerHTML"];
|
|
64237
64405
|
const _sfc_main$c = {
|
|
64238
64406
|
__name: "AlignmentButtons",
|
|
64239
64407
|
emits: ["select"],
|
|
64240
64408
|
setup(__props, { emit: __emit }) {
|
|
64409
|
+
const { isHighContrastMode: isHighContrastMode2 } = useHighContrastMode();
|
|
64241
64410
|
const emit = __emit;
|
|
64242
64411
|
const select = (alignment2) => {
|
|
64243
64412
|
emit("select", alignment2);
|
|
64244
64413
|
};
|
|
64245
64414
|
return (_ctx, _cache) => {
|
|
64246
|
-
return openBlock(), createElementBlock("div",
|
|
64415
|
+
return openBlock(), createElementBlock("div", {
|
|
64416
|
+
class: normalizeClass(["alignment-buttons", { "high-contrast": unref(isHighContrastMode2) }])
|
|
64417
|
+
}, [
|
|
64247
64418
|
createBaseVNode("div", {
|
|
64248
64419
|
class: "button-icon",
|
|
64249
64420
|
onClick: _cache[0] || (_cache[0] = ($event) => select("left")),
|
|
64250
64421
|
innerHTML: unref(toolbarIcons).alignLeft,
|
|
64251
|
-
"data-item": "btn-textAlign-option"
|
|
64252
|
-
|
|
64422
|
+
"data-item": "btn-textAlign-option",
|
|
64423
|
+
role: "menuitem",
|
|
64424
|
+
"aria-label": "Align left"
|
|
64425
|
+
}, null, 8, _hoisted_1$b),
|
|
64253
64426
|
createBaseVNode("div", {
|
|
64254
64427
|
class: "button-icon",
|
|
64255
64428
|
onClick: _cache[1] || (_cache[1] = ($event) => select("center")),
|
|
64256
64429
|
innerHTML: unref(toolbarIcons).alignCenter,
|
|
64257
|
-
"data-item": "btn-textAlign-option"
|
|
64258
|
-
|
|
64430
|
+
"data-item": "btn-textAlign-option",
|
|
64431
|
+
role: "menuitem",
|
|
64432
|
+
"aria-label": "Align center"
|
|
64433
|
+
}, null, 8, _hoisted_2$9),
|
|
64259
64434
|
createBaseVNode("div", {
|
|
64260
64435
|
class: "button-icon",
|
|
64261
64436
|
onClick: _cache[2] || (_cache[2] = ($event) => select("right")),
|
|
64262
64437
|
innerHTML: unref(toolbarIcons).alignRight,
|
|
64263
|
-
"data-item": "btn-textAlign-option"
|
|
64264
|
-
|
|
64438
|
+
"data-item": "btn-textAlign-option",
|
|
64439
|
+
role: "menuitem",
|
|
64440
|
+
"aria-label": "Align right"
|
|
64441
|
+
}, null, 8, _hoisted_3$7),
|
|
64265
64442
|
createBaseVNode("div", {
|
|
64266
64443
|
class: "button-icon",
|
|
64267
64444
|
onClick: _cache[3] || (_cache[3] = ($event) => select("justify")),
|
|
64268
64445
|
innerHTML: unref(toolbarIcons).alignJustify,
|
|
64269
|
-
"data-item": "btn-textAlign-option"
|
|
64270
|
-
|
|
64271
|
-
|
|
64446
|
+
"data-item": "btn-textAlign-option",
|
|
64447
|
+
role: "menuitem",
|
|
64448
|
+
"aria-label": "Justify"
|
|
64449
|
+
}, null, 8, _hoisted_4$3)
|
|
64450
|
+
], 2);
|
|
64272
64451
|
};
|
|
64273
64452
|
}
|
|
64274
64453
|
};
|
|
64275
|
-
const AlignmentButtons = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["__scopeId", "data-v-
|
|
64276
|
-
const _hoisted_1$a = {
|
|
64277
|
-
const _hoisted_2$8 = {
|
|
64454
|
+
const AlignmentButtons = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["__scopeId", "data-v-58d8a9bb"]]);
|
|
64455
|
+
const _hoisted_1$a = {
|
|
64278
64456
|
key: 0,
|
|
64279
64457
|
class: "link-title"
|
|
64280
64458
|
};
|
|
64281
|
-
const
|
|
64459
|
+
const _hoisted_2$8 = {
|
|
64282
64460
|
key: 1,
|
|
64283
64461
|
class: "link-title"
|
|
64284
64462
|
};
|
|
64285
|
-
const
|
|
64463
|
+
const _hoisted_3$6 = {
|
|
64286
64464
|
key: 2,
|
|
64287
64465
|
class: "link-title"
|
|
64288
64466
|
};
|
|
64289
|
-
const
|
|
64290
|
-
const
|
|
64291
|
-
const
|
|
64292
|
-
const
|
|
64293
|
-
const
|
|
64294
|
-
const
|
|
64295
|
-
const
|
|
64296
|
-
const
|
|
64467
|
+
const _hoisted_4$2 = { key: 3 };
|
|
64468
|
+
const _hoisted_5$2 = { class: "input-row" };
|
|
64469
|
+
const _hoisted_6$1 = ["innerHTML"];
|
|
64470
|
+
const _hoisted_7 = ["onKeydown"];
|
|
64471
|
+
const _hoisted_8 = ["innerHTML"];
|
|
64472
|
+
const _hoisted_9 = { class: "input-row link-buttons" };
|
|
64473
|
+
const _hoisted_10 = ["innerHTML"];
|
|
64474
|
+
const _hoisted_11 = {
|
|
64297
64475
|
key: 4,
|
|
64298
64476
|
class: "input-row go-to-anchor clickable"
|
|
64299
64477
|
};
|
|
@@ -64326,6 +64504,7 @@ const _sfc_main$b = {
|
|
|
64326
64504
|
setup(__props, { emit: __emit }) {
|
|
64327
64505
|
const emit = __emit;
|
|
64328
64506
|
const props = __props;
|
|
64507
|
+
const { isHighContrastMode: isHighContrastMode2 } = useHighContrastMode();
|
|
64329
64508
|
const { proxy } = getCurrentInstance();
|
|
64330
64509
|
const handleSubmit = () => {
|
|
64331
64510
|
if (proxy?.$submit instanceof Function) proxy.$submit();
|
|
@@ -64376,16 +64555,19 @@ const _sfc_main$b = {
|
|
|
64376
64555
|
if (props.showInput) focusInput();
|
|
64377
64556
|
});
|
|
64378
64557
|
return (_ctx, _cache) => {
|
|
64379
|
-
return openBlock(), createElementBlock("div",
|
|
64380
|
-
|
|
64381
|
-
|
|
64382
|
-
|
|
64558
|
+
return openBlock(), createElementBlock("div", {
|
|
64559
|
+
class: normalizeClass(["link-input-ctn", { "high-contrast": unref(isHighContrastMode2) }])
|
|
64560
|
+
}, [
|
|
64561
|
+
!__props.href ? (openBlock(), createElementBlock("div", _hoisted_1$a, "Add link")) : isAnchor.value ? (openBlock(), createElementBlock("div", _hoisted_2$8, "Page anchor")) : (openBlock(), createElementBlock("div", _hoisted_3$6, "Edit link")),
|
|
64562
|
+
__props.showInput && !isAnchor.value ? (openBlock(), createElementBlock("div", _hoisted_4$2, [
|
|
64563
|
+
createBaseVNode("div", _hoisted_5$2, [
|
|
64383
64564
|
createBaseVNode("div", {
|
|
64384
64565
|
class: "input-icon",
|
|
64385
64566
|
innerHTML: unref(toolbarIcons).linkInput
|
|
64386
|
-
}, null, 8,
|
|
64567
|
+
}, null, 8, _hoisted_6$1),
|
|
64387
64568
|
withDirectives(createBaseVNode("input", {
|
|
64388
64569
|
type: "text",
|
|
64570
|
+
name: "link",
|
|
64389
64571
|
placeholder: "Type or paste a link",
|
|
64390
64572
|
class: normalizeClass({ error: urlError.value }),
|
|
64391
64573
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => rawUrl.value = $event),
|
|
@@ -64393,7 +64575,7 @@ const _sfc_main$b = {
|
|
|
64393
64575
|
withKeys(withModifiers(handleSubmit, ["stop", "prevent"]), ["enter"]),
|
|
64394
64576
|
_cache[1] || (_cache[1] = ($event) => urlError.value = false)
|
|
64395
64577
|
]
|
|
64396
|
-
}, null, 42,
|
|
64578
|
+
}, null, 42, _hoisted_7), [
|
|
64397
64579
|
[vModelText, rawUrl.value]
|
|
64398
64580
|
]),
|
|
64399
64581
|
createBaseVNode("div", {
|
|
@@ -64401,9 +64583,9 @@ const _sfc_main$b = {
|
|
|
64401
64583
|
innerHTML: unref(toolbarIcons).openLink,
|
|
64402
64584
|
onClick: openLink,
|
|
64403
64585
|
"data-item": "btn-link-open"
|
|
64404
|
-
}, null, 10,
|
|
64586
|
+
}, null, 10, _hoisted_8)
|
|
64405
64587
|
]),
|
|
64406
|
-
createBaseVNode("div",
|
|
64588
|
+
createBaseVNode("div", _hoisted_9, [
|
|
64407
64589
|
__props.href ? (openBlock(), createElementBlock("button", {
|
|
64408
64590
|
key: 0,
|
|
64409
64591
|
class: "remove-btn",
|
|
@@ -64413,7 +64595,7 @@ const _sfc_main$b = {
|
|
|
64413
64595
|
createBaseVNode("div", {
|
|
64414
64596
|
class: "remove-btn__icon",
|
|
64415
64597
|
innerHTML: unref(toolbarIcons).removeLink
|
|
64416
|
-
}, null, 8,
|
|
64598
|
+
}, null, 8, _hoisted_10),
|
|
64417
64599
|
_cache[3] || (_cache[3] = createTextVNode(" Remove "))
|
|
64418
64600
|
])) : createCommentVNode("", true),
|
|
64419
64601
|
showApply.value ? (openBlock(), createElementBlock("button", {
|
|
@@ -64423,23 +64605,22 @@ const _sfc_main$b = {
|
|
|
64423
64605
|
"data-item": "btn-link-apply"
|
|
64424
64606
|
}, toDisplayString(getApplyText.value), 3)) : createCommentVNode("", true)
|
|
64425
64607
|
])
|
|
64426
|
-
])) : isAnchor.value ? (openBlock(), createElementBlock("div",
|
|
64608
|
+
])) : isAnchor.value ? (openBlock(), createElementBlock("div", _hoisted_11, [
|
|
64427
64609
|
createBaseVNode("a", {
|
|
64428
64610
|
onClick: _cache[2] || (_cache[2] = withModifiers((...args) => __props.goToAnchor && __props.goToAnchor(...args), ["stop", "prevent"]))
|
|
64429
64611
|
}, "Go to " + toDisplayString(__props.href.startsWith("#_") ? __props.href.substring(2) : __props.href), 1)
|
|
64430
64612
|
])) : createCommentVNode("", true)
|
|
64431
|
-
]);
|
|
64613
|
+
], 2);
|
|
64432
64614
|
};
|
|
64433
64615
|
}
|
|
64434
64616
|
};
|
|
64435
|
-
const LinkInput = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["__scopeId", "data-v-
|
|
64436
|
-
const _hoisted_1$9 =
|
|
64437
|
-
const _hoisted_2$7 =
|
|
64438
|
-
const _hoisted_3$
|
|
64439
|
-
const _hoisted_4$1 =
|
|
64440
|
-
const _hoisted_5$1 = { class: "document-mode-
|
|
64441
|
-
const _hoisted_6 = { class: "document-mode-
|
|
64442
|
-
const _hoisted_7 = { class: "document-mode-description" };
|
|
64617
|
+
const LinkInput = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["__scopeId", "data-v-64aa14bc"]]);
|
|
64618
|
+
const _hoisted_1$9 = ["onClick"];
|
|
64619
|
+
const _hoisted_2$7 = { class: "document-mode-column icon-column" };
|
|
64620
|
+
const _hoisted_3$5 = ["innerHTML"];
|
|
64621
|
+
const _hoisted_4$1 = { class: "document-mode-column text-column" };
|
|
64622
|
+
const _hoisted_5$1 = { class: "document-mode-type" };
|
|
64623
|
+
const _hoisted_6 = { class: "document-mode-description" };
|
|
64443
64624
|
const _sfc_main$a = {
|
|
64444
64625
|
__name: "DocumentMode",
|
|
64445
64626
|
props: {
|
|
@@ -64450,34 +64631,38 @@ const _sfc_main$a = {
|
|
|
64450
64631
|
emits: ["select"],
|
|
64451
64632
|
setup(__props, { emit: __emit }) {
|
|
64452
64633
|
const emit = __emit;
|
|
64634
|
+
const { isHighContrastMode: isHighContrastMode2 } = useHighContrastMode();
|
|
64453
64635
|
const handleClick2 = (item) => {
|
|
64454
64636
|
emit("select", item);
|
|
64455
64637
|
};
|
|
64456
64638
|
return (_ctx, _cache) => {
|
|
64457
|
-
return openBlock(), createElementBlock("div",
|
|
64639
|
+
return openBlock(), createElementBlock("div", {
|
|
64640
|
+
class: normalizeClass(["document-mode", { "high-contrast": unref(isHighContrastMode2) }])
|
|
64641
|
+
}, [
|
|
64458
64642
|
(openBlock(true), createElementBlock(Fragment$1, null, renderList(__props.options, (option) => {
|
|
64459
64643
|
return openBlock(), createElementBlock("div", {
|
|
64460
64644
|
class: normalizeClass(["option-item", { disabled: option.disabled }]),
|
|
64461
64645
|
onClick: ($event) => handleClick2(option),
|
|
64462
|
-
"data-item": "btn-documentMode-option"
|
|
64646
|
+
"data-item": "btn-documentMode-option",
|
|
64647
|
+
role: "menuitem"
|
|
64463
64648
|
}, [
|
|
64464
|
-
createBaseVNode("div",
|
|
64649
|
+
createBaseVNode("div", _hoisted_2$7, [
|
|
64465
64650
|
createBaseVNode("div", {
|
|
64466
64651
|
class: "icon-column__icon",
|
|
64467
64652
|
innerHTML: option.icon
|
|
64468
|
-
}, null, 8,
|
|
64653
|
+
}, null, 8, _hoisted_3$5)
|
|
64469
64654
|
]),
|
|
64470
|
-
createBaseVNode("div",
|
|
64471
|
-
createBaseVNode("div",
|
|
64472
|
-
createBaseVNode("div",
|
|
64655
|
+
createBaseVNode("div", _hoisted_4$1, [
|
|
64656
|
+
createBaseVNode("div", _hoisted_5$1, toDisplayString(option.label), 1),
|
|
64657
|
+
createBaseVNode("div", _hoisted_6, toDisplayString(option.description), 1)
|
|
64473
64658
|
])
|
|
64474
|
-
], 10,
|
|
64659
|
+
], 10, _hoisted_1$9);
|
|
64475
64660
|
}), 256))
|
|
64476
|
-
]);
|
|
64661
|
+
], 2);
|
|
64477
64662
|
};
|
|
64478
64663
|
}
|
|
64479
64664
|
};
|
|
64480
|
-
const DocumentMode = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__scopeId", "data-v-
|
|
64665
|
+
const DocumentMode = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__scopeId", "data-v-050d9d49"]]);
|
|
64481
64666
|
const _hoisted_1$8 = {
|
|
64482
64667
|
key: 0,
|
|
64483
64668
|
class: "linked-style-buttons"
|
|
@@ -64520,9 +64705,9 @@ const _sfc_main$9 = {
|
|
|
64520
64705
|
}
|
|
64521
64706
|
};
|
|
64522
64707
|
const LinkedStyle = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__scopeId", "data-v-bf5a8c1e"]]);
|
|
64523
|
-
const _hoisted_1$7 = ["onClick"];
|
|
64708
|
+
const _hoisted_1$7 = ["aria-label", "onClick"];
|
|
64524
64709
|
const _hoisted_2$5 = ["innerHTML"];
|
|
64525
|
-
const _hoisted_3$
|
|
64710
|
+
const _hoisted_3$4 = ["innerHTML"];
|
|
64526
64711
|
const _sfc_main$8 = {
|
|
64527
64712
|
__name: "IconGridRow",
|
|
64528
64713
|
props: {
|
|
@@ -64559,12 +64744,15 @@ const _sfc_main$8 = {
|
|
|
64559
64744
|
return openBlock(true), createElementBlock(Fragment$1, null, renderList(__props.icons, (row, rowIndex) => {
|
|
64560
64745
|
return openBlock(), createElementBlock("div", {
|
|
64561
64746
|
class: "option-row",
|
|
64562
|
-
key: rowIndex
|
|
64747
|
+
key: rowIndex,
|
|
64748
|
+
role: "group"
|
|
64563
64749
|
}, [
|
|
64564
64750
|
(openBlock(true), createElementBlock(Fragment$1, null, renderList(row, (option, optionIndex) => {
|
|
64565
64751
|
return openBlock(), createElementBlock("div", {
|
|
64566
64752
|
class: "option",
|
|
64567
64753
|
key: optionIndex,
|
|
64754
|
+
"aria-label": option.label,
|
|
64755
|
+
role: "menuitem",
|
|
64568
64756
|
onClick: withModifiers(($event) => handleClick2(option), ["stop", "prevent"])
|
|
64569
64757
|
}, [
|
|
64570
64758
|
createBaseVNode("div", {
|
|
@@ -64577,7 +64765,7 @@ const _sfc_main$8 = {
|
|
|
64577
64765
|
class: "option__check",
|
|
64578
64766
|
innerHTML: unref(toolbarIcons).colorOptionCheck,
|
|
64579
64767
|
style: normalizeStyle(getCheckStyle(option.value, optionIndex))
|
|
64580
|
-
}, null, 12, _hoisted_3$
|
|
64768
|
+
}, null, 12, _hoisted_3$4)) : createCommentVNode("", true)
|
|
64581
64769
|
], 8, _hoisted_1$7);
|
|
64582
64770
|
}), 128))
|
|
64583
64771
|
]);
|
|
@@ -64585,11 +64773,11 @@ const _sfc_main$8 = {
|
|
|
64585
64773
|
};
|
|
64586
64774
|
}
|
|
64587
64775
|
};
|
|
64588
|
-
const IconGridRow = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__scopeId", "data-v-
|
|
64776
|
+
const IconGridRow = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__scopeId", "data-v-d96a82fa"]]);
|
|
64589
64777
|
const DropIcon = '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 640 512"><!--!Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2025 Fonticons, Inc.--><path d="M320 512c53.2 0 101.4-21.6 136.1-56.6l-298.3-235C140 257.1 128 292.3 128 320c0 106 86 192 192 192zM505.2 370.7c4.4-16.2 6.8-33.1 6.8-50.7c0-91.2-130.2-262.3-166.6-308.3C339.4 4.2 330.5 0 320.9 0l-1.8 0c-9.6 0-18.5 4.2-24.5 11.7C277.8 33 240.7 81.3 205.8 136L38.8 5.1C28.4-3.1 13.3-1.2 5.1 9.2S-1.2 34.7 9.2 42.9l592 464c10.4 8.2 25.5 6.3 33.7-4.1s6.3-25.5-4.1-33.7L505.2 370.7zM224 336c0 44.2 35.8 80 80 80c8.8 0 16 7.2 16 16s-7.2 16-16 16c-61.9 0-112-50.1-112-112c0-8.8 7.2-16 16-16s16 7.2 16 16z"/></svg>\n';
|
|
64590
64778
|
const _hoisted_1$6 = { class: "options-grid-wrap" };
|
|
64591
64779
|
const _hoisted_2$4 = ["innerHTML"];
|
|
64592
|
-
const _hoisted_3$
|
|
64780
|
+
const _hoisted_3$3 = { class: "option-grid-ctn" };
|
|
64593
64781
|
const _sfc_main$7 = {
|
|
64594
64782
|
__name: "IconGrid",
|
|
64595
64783
|
props: {
|
|
@@ -64621,6 +64809,8 @@ const _sfc_main$7 = {
|
|
|
64621
64809
|
__props.hasNoneIcon ? (openBlock(), createElementBlock("div", {
|
|
64622
64810
|
key: 0,
|
|
64623
64811
|
class: "none-option",
|
|
64812
|
+
role: "menuitem",
|
|
64813
|
+
"aria-label": "Clear color selection",
|
|
64624
64814
|
onClick: _cache[0] || (_cache[0] = ($event) => handleSelect("none"))
|
|
64625
64815
|
}, [
|
|
64626
64816
|
createBaseVNode("span", {
|
|
@@ -64629,7 +64819,7 @@ const _sfc_main$7 = {
|
|
|
64629
64819
|
}, null, 8, _hoisted_2$4),
|
|
64630
64820
|
_cache[1] || (_cache[1] = createTextVNode(" None "))
|
|
64631
64821
|
])) : createCommentVNode("", true),
|
|
64632
|
-
createBaseVNode("div", _hoisted_3$
|
|
64822
|
+
createBaseVNode("div", _hoisted_3$3, [
|
|
64633
64823
|
createVNode(IconGridRow, {
|
|
64634
64824
|
icons: __props.icons,
|
|
64635
64825
|
"active-color": __props.activeColor,
|
|
@@ -64648,7 +64838,7 @@ const _sfc_main$7 = {
|
|
|
64648
64838
|
};
|
|
64649
64839
|
}
|
|
64650
64840
|
};
|
|
64651
|
-
const IconGrid = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__scopeId", "data-v-
|
|
64841
|
+
const IconGrid = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__scopeId", "data-v-9246bdef"]]);
|
|
64652
64842
|
const closeDropdown$1 = (dropdown) => {
|
|
64653
64843
|
dropdown.expand.value = false;
|
|
64654
64844
|
};
|
|
@@ -64682,84 +64872,83 @@ const renderColorOptions = (superToolbar, button, customIcons = [], hasNoneIcon
|
|
|
64682
64872
|
};
|
|
64683
64873
|
const icons = [
|
|
64684
64874
|
[
|
|
64685
|
-
makeColorOption("#111111"),
|
|
64686
|
-
makeColorOption("#333333"),
|
|
64687
|
-
makeColorOption("#5C5C5C"),
|
|
64688
|
-
makeColorOption("#858585"),
|
|
64689
|
-
makeColorOption("#ADADAD"),
|
|
64690
|
-
makeColorOption("#D6D6D6"),
|
|
64691
|
-
makeColorOption("#FFFFFF")
|
|
64875
|
+
makeColorOption("#111111", "black"),
|
|
64876
|
+
makeColorOption("#333333", "dark gray"),
|
|
64877
|
+
makeColorOption("#5C5C5C", "medium gray"),
|
|
64878
|
+
makeColorOption("#858585", "light gray"),
|
|
64879
|
+
makeColorOption("#ADADAD", "very light gray"),
|
|
64880
|
+
makeColorOption("#D6D6D6", "transparent gray"),
|
|
64881
|
+
makeColorOption("#FFFFFF", "white")
|
|
64692
64882
|
],
|
|
64693
64883
|
[
|
|
64694
|
-
makeColorOption("#860028"),
|
|
64695
|
-
makeColorOption("#D2003F"),
|
|
64696
|
-
makeColorOption("#DB3365"),
|
|
64697
|
-
makeColorOption("#E4668C"),
|
|
64698
|
-
makeColorOption("#ED99B2"),
|
|
64699
|
-
makeColorOption("#F6CCD9"),
|
|
64700
|
-
makeColorOption("#FF004D")
|
|
64884
|
+
makeColorOption("#860028", "dark red"),
|
|
64885
|
+
makeColorOption("#D2003F", "red"),
|
|
64886
|
+
makeColorOption("#DB3365", "coral red"),
|
|
64887
|
+
makeColorOption("#E4668C", "light red"),
|
|
64888
|
+
makeColorOption("#ED99B2", "pale pink"),
|
|
64889
|
+
makeColorOption("#F6CCD9", "transparent pink"),
|
|
64890
|
+
makeColorOption("#FF004D", "bright pink")
|
|
64701
64891
|
],
|
|
64702
64892
|
[
|
|
64703
|
-
makeColorOption("#83015E"),
|
|
64704
|
-
makeColorOption("#CD0194"),
|
|
64705
|
-
makeColorOption("#D734A9"),
|
|
64706
|
-
makeColorOption("#E167BF"),
|
|
64707
|
-
makeColorOption("#EB99D4"),
|
|
64708
|
-
makeColorOption("#F5CCEA"),
|
|
64709
|
-
makeColorOption("#FF00A8")
|
|
64893
|
+
makeColorOption("#83015E", "dark purple"),
|
|
64894
|
+
makeColorOption("#CD0194", "purple"),
|
|
64895
|
+
makeColorOption("#D734A9", "orchid"),
|
|
64896
|
+
makeColorOption("#E167BF", "light purple"),
|
|
64897
|
+
makeColorOption("#EB99D4", "lavender"),
|
|
64898
|
+
makeColorOption("#F5CCEA", "transparent pink"),
|
|
64899
|
+
makeColorOption("#FF00A8", "neon pink")
|
|
64710
64900
|
],
|
|
64711
64901
|
[
|
|
64712
|
-
makeColorOption("#8E220A"),
|
|
64713
|
-
makeColorOption("#DD340F"),
|
|
64714
|
-
makeColorOption("#E45C3F"),
|
|
64715
|
-
makeColorOption("#EB856F"),
|
|
64716
|
-
makeColorOption("#F1AE9F"),
|
|
64717
|
-
makeColorOption("#F8D6CF"),
|
|
64718
|
-
makeColorOption("#FF7A00")
|
|
64902
|
+
makeColorOption("#8E220A", "maroon"),
|
|
64903
|
+
makeColorOption("#DD340F", "red-orange"),
|
|
64904
|
+
makeColorOption("#E45C3F", "burnt orange"),
|
|
64905
|
+
makeColorOption("#EB856F", "peach"),
|
|
64906
|
+
makeColorOption("#F1AE9F", "pale peach"),
|
|
64907
|
+
makeColorOption("#F8D6CF", "transparent peach"),
|
|
64908
|
+
makeColorOption("#FF7A00", "orange")
|
|
64719
64909
|
],
|
|
64720
64910
|
[
|
|
64721
|
-
makeColorOption("#947D02"),
|
|
64722
|
-
makeColorOption("#E7C302"),
|
|
64723
|
-
makeColorOption("#ECCF35"),
|
|
64724
|
-
makeColorOption("#F1DB67"),
|
|
64725
|
-
makeColorOption("#F5E79A"),
|
|
64726
|
-
makeColorOption("#FAF3CC"),
|
|
64727
|
-
makeColorOption("#FAFF09")
|
|
64911
|
+
makeColorOption("#947D02", "olive"),
|
|
64912
|
+
makeColorOption("#E7C302", "mustard yellow"),
|
|
64913
|
+
makeColorOption("#ECCF35", "yellow"),
|
|
64914
|
+
makeColorOption("#F1DB67", "light yellow"),
|
|
64915
|
+
makeColorOption("#F5E79A", "very pale yellow"),
|
|
64916
|
+
makeColorOption("#FAF3CC", "transparent yellow"),
|
|
64917
|
+
makeColorOption("#FAFF09", "neon yellow")
|
|
64728
64918
|
],
|
|
64729
64919
|
[
|
|
64730
|
-
makeColorOption("#055432"),
|
|
64731
|
-
makeColorOption("#07834F"),
|
|
64732
|
-
makeColorOption("#399C72"),
|
|
64733
|
-
makeColorOption("#6AB595"),
|
|
64734
|
-
makeColorOption("#9CCDB9"),
|
|
64735
|
-
makeColorOption("#CDE6DC"),
|
|
64736
|
-
makeColorOption("#05F38F")
|
|
64920
|
+
makeColorOption("#055432", "forest green"),
|
|
64921
|
+
makeColorOption("#07834F", "green"),
|
|
64922
|
+
makeColorOption("#399C72", "medium green"),
|
|
64923
|
+
makeColorOption("#6AB595", "light green"),
|
|
64924
|
+
makeColorOption("#9CCDB9", "mint"),
|
|
64925
|
+
makeColorOption("#CDE6DC", "transparent mint"),
|
|
64926
|
+
makeColorOption("#05F38F", "bright teal")
|
|
64737
64927
|
],
|
|
64738
64928
|
[
|
|
64739
|
-
makeColorOption("#063E7E"),
|
|
64740
|
-
makeColorOption("#0A60C5"),
|
|
64741
|
-
makeColorOption("#3B80D1"),
|
|
64742
|
-
makeColorOption("#6CA0DC"),
|
|
64743
|
-
makeColorOption("#9DBFE8"),
|
|
64744
|
-
makeColorOption("#CEDFF3"),
|
|
64745
|
-
makeColorOption("#21c8ce")
|
|
64929
|
+
makeColorOption("#063E7E", "navy blue"),
|
|
64930
|
+
makeColorOption("#0A60C5", "blue"),
|
|
64931
|
+
makeColorOption("#3B80D1", "sky blue"),
|
|
64932
|
+
makeColorOption("#6CA0DC", "cornflower blue"),
|
|
64933
|
+
makeColorOption("#9DBFE8", "light blue"),
|
|
64934
|
+
makeColorOption("#CEDFF3", "very light blue"),
|
|
64935
|
+
makeColorOption("#21c8ce", "cyan")
|
|
64746
64936
|
],
|
|
64747
64937
|
[
|
|
64748
|
-
makeColorOption("#3E027A"),
|
|
64749
|
-
makeColorOption("#6103BF"),
|
|
64750
|
-
makeColorOption("#8136CC"),
|
|
64751
|
-
makeColorOption("#A068D9"),
|
|
64752
|
-
makeColorOption("#C09AE6"),
|
|
64753
|
-
makeColorOption("#DFCDF2"),
|
|
64754
|
-
makeColorOption("#A91DFF")
|
|
64938
|
+
makeColorOption("#3E027A", "deep purple"),
|
|
64939
|
+
makeColorOption("#6103BF", "indigo"),
|
|
64940
|
+
makeColorOption("#8136CC", "violet"),
|
|
64941
|
+
makeColorOption("#A068D9", "lavender pink"),
|
|
64942
|
+
makeColorOption("#C09AE6", "light lilac"),
|
|
64943
|
+
makeColorOption("#DFCDF2", "transparent lilac"),
|
|
64944
|
+
makeColorOption("#A91DFF", "neon purple")
|
|
64755
64945
|
]
|
|
64756
64946
|
];
|
|
64757
64947
|
const getAvailableColorOptions = () => {
|
|
64758
64948
|
return icons.flat().map((item) => item.value);
|
|
64759
64949
|
};
|
|
64760
|
-
const _hoisted_1$5 =
|
|
64761
|
-
const _hoisted_2$3 = ["
|
|
64762
|
-
const _hoisted_3$3 = { class: "toolbar-table-grid-value" };
|
|
64950
|
+
const _hoisted_1$5 = ["data-cols", "data-rows", "onClick"];
|
|
64951
|
+
const _hoisted_2$3 = ["aria-valuetext"];
|
|
64763
64952
|
const _sfc_main$6 = {
|
|
64764
64953
|
__name: "TableGrid",
|
|
64765
64954
|
emits: ["select", "clickoutside"],
|
|
@@ -64767,6 +64956,7 @@ const _sfc_main$6 = {
|
|
|
64767
64956
|
const emit = __emit;
|
|
64768
64957
|
const selectedRows = ref$1(0);
|
|
64769
64958
|
const selectedCols = ref$1(0);
|
|
64959
|
+
const { isHighContrastMode: isHighContrastMode2 } = useHighContrastMode();
|
|
64770
64960
|
const onTableGridMouseOver = (event) => {
|
|
64771
64961
|
let target = event.target;
|
|
64772
64962
|
let isGrid = !!target.dataset.grid;
|
|
@@ -64794,7 +64984,9 @@ const _sfc_main$6 = {
|
|
|
64794
64984
|
emit("select", { cols, rows });
|
|
64795
64985
|
};
|
|
64796
64986
|
return (_ctx, _cache) => {
|
|
64797
|
-
return openBlock(), createElementBlock("div",
|
|
64987
|
+
return openBlock(), createElementBlock("div", {
|
|
64988
|
+
class: normalizeClass(["toolbar-table-grid-wrapper", { "high-contrast": unref(isHighContrastMode2) }])
|
|
64989
|
+
}, [
|
|
64798
64990
|
createBaseVNode("div", {
|
|
64799
64991
|
class: "toolbar-table-grid",
|
|
64800
64992
|
onMouseover: onTableGridMouseOver,
|
|
@@ -64810,19 +65002,22 @@ const _sfc_main$6 = {
|
|
|
64810
65002
|
"data-rows": i,
|
|
64811
65003
|
"data-item": "true",
|
|
64812
65004
|
onClick: withModifiers(($event) => handleClick2({ cols: n2, rows: i }), ["stop", "prevent"])
|
|
64813
|
-
}, null, 8,
|
|
65005
|
+
}, null, 8, _hoisted_1$5);
|
|
64814
65006
|
}), 64))
|
|
64815
65007
|
], 64);
|
|
64816
65008
|
}), 64))
|
|
64817
65009
|
], 32),
|
|
64818
|
-
createBaseVNode("div",
|
|
64819
|
-
|
|
65010
|
+
createBaseVNode("div", {
|
|
65011
|
+
class: "toolbar-table-grid-value",
|
|
65012
|
+
"aria-valuetext": `${selectedRows.value} x ${selectedCols.value}`
|
|
65013
|
+
}, toDisplayString(selectedRows.value) + " x " + toDisplayString(selectedCols.value), 9, _hoisted_2$3)
|
|
65014
|
+
], 2);
|
|
64820
65015
|
};
|
|
64821
65016
|
}
|
|
64822
65017
|
};
|
|
64823
|
-
const TableGrid = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__scopeId", "data-v-
|
|
65018
|
+
const TableGrid = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__scopeId", "data-v-617bf152"]]);
|
|
64824
65019
|
const _hoisted_1$4 = { class: "toolbar-table-actions" };
|
|
64825
|
-
const _hoisted_2$2 = ["onClick", "data-item"];
|
|
65020
|
+
const _hoisted_2$2 = ["onClick", "data-item", "ariaLabel"];
|
|
64826
65021
|
const _hoisted_3$2 = { class: "toolbar-table-actions__icon" };
|
|
64827
65022
|
const _hoisted_4 = ["innerHTML"];
|
|
64828
65023
|
const _hoisted_5 = { class: "toolbar-table-actions__label" };
|
|
@@ -64845,7 +65040,9 @@ const _sfc_main$5 = {
|
|
|
64845
65040
|
return openBlock(), createElementBlock("div", {
|
|
64846
65041
|
class: normalizeClass(["toolbar-table-actions__item", { "toolbar-table-actions__item--border": option.bottomBorder }]),
|
|
64847
65042
|
onClick: ($event) => handleClick2(option),
|
|
64848
|
-
"data-item": option.props?.["data-item"] || ""
|
|
65043
|
+
"data-item": option.props?.["data-item"] || "",
|
|
65044
|
+
ariaLabel: option.props?.ariaLabel,
|
|
65045
|
+
role: "menuitem"
|
|
64849
65046
|
}, [
|
|
64850
65047
|
createBaseVNode("div", _hoisted_3$2, [
|
|
64851
65048
|
createBaseVNode("div", {
|
|
@@ -64860,7 +65057,7 @@ const _sfc_main$5 = {
|
|
|
64860
65057
|
};
|
|
64861
65058
|
}
|
|
64862
65059
|
};
|
|
64863
|
-
const TableActions = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-
|
|
65060
|
+
const TableActions = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-f82e859a"]]);
|
|
64864
65061
|
const checkIconSvg = '<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 448 512"><!--!Font Awesome Free 6.7.2 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free Copyright 2025 Fonticons, Inc.--><path d="M438.6 105.4c12.5 12.5 12.5 32.8 0 45.3l-256 256c-12.5 12.5-32.8 12.5-45.3 0l-128-128c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0L160 338.7 393.4 105.4c12.5-12.5 32.8-12.5 45.3 0z"/></svg>\n';
|
|
64865
65062
|
const _hoisted_1$3 = { class: "search-input-ctn" };
|
|
64866
65063
|
const _hoisted_2$1 = { class: "row" };
|
|
@@ -64961,7 +65158,10 @@ const makeDefaultItems = ({
|
|
|
64961
65158
|
name: "bold",
|
|
64962
65159
|
command: "toggleBold",
|
|
64963
65160
|
icon: toolbarIcons2.bold,
|
|
64964
|
-
tooltip: toolbarTexts2.bold
|
|
65161
|
+
tooltip: toolbarTexts2.bold,
|
|
65162
|
+
attributes: {
|
|
65163
|
+
ariaLabel: "Bold"
|
|
65164
|
+
}
|
|
64965
65165
|
});
|
|
64966
65166
|
const fontButton = useToolbarItem({
|
|
64967
65167
|
type: "dropdown",
|
|
@@ -64976,6 +65176,9 @@ const makeDefaultItems = ({
|
|
|
64976
65176
|
isWide: true,
|
|
64977
65177
|
style: { width: "116px" },
|
|
64978
65178
|
suppressActiveHighlight: true,
|
|
65179
|
+
attributes: {
|
|
65180
|
+
ariaLabel: "Font family"
|
|
65181
|
+
},
|
|
64979
65182
|
options: [...toolbarFonts ? toolbarFonts : TOOLBAR_FONTS],
|
|
64980
65183
|
onActivate: ({ fontFamily: fontFamily2 }) => {
|
|
64981
65184
|
if (!fontFamily2) return;
|
|
@@ -64996,6 +65199,9 @@ const makeDefaultItems = ({
|
|
|
64996
65199
|
hasCaret: false,
|
|
64997
65200
|
isWide: true,
|
|
64998
65201
|
suppressActiveHighlight: true,
|
|
65202
|
+
attributes: {
|
|
65203
|
+
ariaLabel: "AI"
|
|
65204
|
+
},
|
|
64999
65205
|
options: [
|
|
65000
65206
|
{
|
|
65001
65207
|
type: "render",
|
|
@@ -65043,6 +65249,9 @@ const makeDefaultItems = ({
|
|
|
65043
65249
|
suppressActiveHighlight: true,
|
|
65044
65250
|
isWide: true,
|
|
65045
65251
|
command: "setFontSize",
|
|
65252
|
+
attributes: {
|
|
65253
|
+
ariaLabel: "Font size"
|
|
65254
|
+
},
|
|
65046
65255
|
options: [
|
|
65047
65256
|
{ label: "8", key: "8pt", props: { "data-item": "btn-fontSize-option" } },
|
|
65048
65257
|
{ label: "9", key: "9pt", props: { "data-item": "btn-fontSize-option" } },
|
|
@@ -65078,14 +65287,20 @@ const makeDefaultItems = ({
|
|
|
65078
65287
|
name: "italic",
|
|
65079
65288
|
command: "toggleItalic",
|
|
65080
65289
|
icon: toolbarIcons2.italic,
|
|
65081
|
-
tooltip: toolbarTexts2.italic
|
|
65290
|
+
tooltip: toolbarTexts2.italic,
|
|
65291
|
+
attributes: {
|
|
65292
|
+
ariaLabel: "Italic"
|
|
65293
|
+
}
|
|
65082
65294
|
});
|
|
65083
65295
|
const underline = useToolbarItem({
|
|
65084
65296
|
type: "button",
|
|
65085
65297
|
name: "underline",
|
|
65086
65298
|
command: "toggleUnderline",
|
|
65087
65299
|
icon: toolbarIcons2.underline,
|
|
65088
|
-
tooltip: toolbarTexts2.underline
|
|
65300
|
+
tooltip: toolbarTexts2.underline,
|
|
65301
|
+
attributes: {
|
|
65302
|
+
ariaLabel: "Underline"
|
|
65303
|
+
}
|
|
65089
65304
|
});
|
|
65090
65305
|
const highlight = useToolbarItem({
|
|
65091
65306
|
type: "dropdown",
|
|
@@ -65098,6 +65313,9 @@ const makeDefaultItems = ({
|
|
|
65098
65313
|
command: "setHighlight",
|
|
65099
65314
|
noArgumentCommand: "unsetHighlight",
|
|
65100
65315
|
suppressActiveHighlight: true,
|
|
65316
|
+
attributes: {
|
|
65317
|
+
ariaLabel: "Highlight"
|
|
65318
|
+
},
|
|
65101
65319
|
options: [
|
|
65102
65320
|
{
|
|
65103
65321
|
key: "color",
|
|
@@ -65120,6 +65338,9 @@ const makeDefaultItems = ({
|
|
|
65120
65338
|
tooltip: toolbarTexts2.color,
|
|
65121
65339
|
command: "setColor",
|
|
65122
65340
|
suppressActiveHighlight: true,
|
|
65341
|
+
attributes: {
|
|
65342
|
+
ariaLabel: "Color"
|
|
65343
|
+
},
|
|
65123
65344
|
options: [
|
|
65124
65345
|
{
|
|
65125
65346
|
key: "color",
|
|
@@ -65140,6 +65361,9 @@ const makeDefaultItems = ({
|
|
|
65140
65361
|
tooltip: toolbarTexts2.search,
|
|
65141
65362
|
group: "right",
|
|
65142
65363
|
inputRef: searchRef,
|
|
65364
|
+
attributes: {
|
|
65365
|
+
ariaLabel: "Search"
|
|
65366
|
+
},
|
|
65143
65367
|
options: [
|
|
65144
65368
|
{
|
|
65145
65369
|
type: "render",
|
|
@@ -65165,6 +65389,9 @@ const makeDefaultItems = ({
|
|
|
65165
65389
|
markName: "link",
|
|
65166
65390
|
icon: toolbarIcons2.link,
|
|
65167
65391
|
tooltip: toolbarTexts2.link,
|
|
65392
|
+
attributes: {
|
|
65393
|
+
ariaLabel: "Link dropdown"
|
|
65394
|
+
},
|
|
65168
65395
|
options: [
|
|
65169
65396
|
{
|
|
65170
65397
|
type: "render",
|
|
@@ -65218,7 +65445,10 @@ const makeDefaultItems = ({
|
|
|
65218
65445
|
command: "startImageUpload",
|
|
65219
65446
|
icon: toolbarIcons2.image,
|
|
65220
65447
|
tooltip: toolbarTexts2.image,
|
|
65221
|
-
disabled: false
|
|
65448
|
+
disabled: false,
|
|
65449
|
+
attributes: {
|
|
65450
|
+
ariaLabel: "Image"
|
|
65451
|
+
}
|
|
65222
65452
|
});
|
|
65223
65453
|
const tableItem = useToolbarItem({
|
|
65224
65454
|
type: "dropdown",
|
|
@@ -65229,6 +65459,9 @@ const makeDefaultItems = ({
|
|
|
65229
65459
|
tooltip: toolbarTexts2.table,
|
|
65230
65460
|
command: "insertTable",
|
|
65231
65461
|
suppressActiveHighlight: true,
|
|
65462
|
+
attributes: {
|
|
65463
|
+
ariaLabel: "Table"
|
|
65464
|
+
},
|
|
65232
65465
|
options: [
|
|
65233
65466
|
{
|
|
65234
65467
|
key: "table",
|
|
@@ -65255,6 +65488,9 @@ const makeDefaultItems = ({
|
|
|
65255
65488
|
icon: toolbarIcons2.tableActions,
|
|
65256
65489
|
hideLabel: true,
|
|
65257
65490
|
disabled: true,
|
|
65491
|
+
attributes: {
|
|
65492
|
+
ariaLabel: "Table actions"
|
|
65493
|
+
},
|
|
65258
65494
|
options: [
|
|
65259
65495
|
{
|
|
65260
65496
|
type: "render",
|
|
@@ -65267,69 +65503,102 @@ const makeDefaultItems = ({
|
|
|
65267
65503
|
label: toolbarTexts2.addRowBefore,
|
|
65268
65504
|
command: "addRowBefore",
|
|
65269
65505
|
icon: toolbarIcons2.addRowBefore,
|
|
65270
|
-
props: {
|
|
65506
|
+
props: {
|
|
65507
|
+
"data-item": "btn-tableActions-option",
|
|
65508
|
+
ariaLabel: "Add row before"
|
|
65509
|
+
}
|
|
65271
65510
|
},
|
|
65272
65511
|
{
|
|
65273
65512
|
label: toolbarTexts2.addRowAfter,
|
|
65274
65513
|
command: "addRowAfter",
|
|
65275
65514
|
icon: toolbarIcons2.addRowAfter,
|
|
65276
|
-
props: {
|
|
65515
|
+
props: {
|
|
65516
|
+
"data-item": "btn-tableActions-option",
|
|
65517
|
+
ariaLabel: "Add row after"
|
|
65518
|
+
}
|
|
65277
65519
|
},
|
|
65278
65520
|
{
|
|
65279
65521
|
label: toolbarTexts2.addColumnBefore,
|
|
65280
65522
|
command: "addColumnBefore",
|
|
65281
65523
|
icon: toolbarIcons2.addColumnBefore,
|
|
65282
|
-
props: {
|
|
65524
|
+
props: {
|
|
65525
|
+
"data-item": "btn-tableActions-option",
|
|
65526
|
+
ariaLabel: "Add column before"
|
|
65527
|
+
}
|
|
65283
65528
|
},
|
|
65284
65529
|
{
|
|
65285
65530
|
label: toolbarTexts2.addColumnAfter,
|
|
65286
65531
|
command: "addColumnAfter",
|
|
65287
65532
|
icon: toolbarIcons2.addColumnAfter,
|
|
65288
65533
|
bottomBorder: true,
|
|
65289
|
-
props: {
|
|
65534
|
+
props: {
|
|
65535
|
+
"data-item": "btn-tableActions-option",
|
|
65536
|
+
ariaLabel: "Add column after"
|
|
65537
|
+
}
|
|
65290
65538
|
},
|
|
65291
65539
|
{
|
|
65292
65540
|
label: toolbarTexts2.deleteRow,
|
|
65293
65541
|
command: "deleteRow",
|
|
65294
65542
|
icon: toolbarIcons2.deleteRow,
|
|
65295
|
-
props: {
|
|
65543
|
+
props: {
|
|
65544
|
+
"data-item": "btn-tableActions-option",
|
|
65545
|
+
ariaLabel: "Delete row"
|
|
65546
|
+
}
|
|
65296
65547
|
},
|
|
65297
65548
|
{
|
|
65298
65549
|
label: toolbarTexts2.deleteColumn,
|
|
65299
65550
|
command: "deleteColumn",
|
|
65300
65551
|
icon: toolbarIcons2.deleteColumn,
|
|
65301
|
-
props: {
|
|
65552
|
+
props: {
|
|
65553
|
+
"data-item": "btn-tableActions-option",
|
|
65554
|
+
ariaLabel: "Delete column"
|
|
65555
|
+
}
|
|
65302
65556
|
},
|
|
65303
65557
|
{
|
|
65304
65558
|
label: toolbarTexts2.deleteTable,
|
|
65305
65559
|
command: "deleteTable",
|
|
65306
65560
|
icon: toolbarIcons2.deleteTable,
|
|
65307
|
-
props: {
|
|
65561
|
+
props: {
|
|
65562
|
+
"data-item": "btn-tableActions-option",
|
|
65563
|
+
ariaLabel: "Delete table"
|
|
65564
|
+
}
|
|
65308
65565
|
},
|
|
65309
65566
|
{
|
|
65310
65567
|
label: toolbarTexts2.transparentBorders,
|
|
65311
65568
|
command: "deleteCellAndTableBorders",
|
|
65312
65569
|
icon: toolbarIcons2.deleteBorders,
|
|
65313
65570
|
bottomBorder: true,
|
|
65314
|
-
props: {
|
|
65571
|
+
props: {
|
|
65572
|
+
"data-item": "btn-tableActions-option",
|
|
65573
|
+
ariaLabel: "Delete cell and table borders"
|
|
65574
|
+
}
|
|
65315
65575
|
},
|
|
65316
65576
|
{
|
|
65317
65577
|
label: toolbarTexts2.mergeCells,
|
|
65318
65578
|
command: "mergeCells",
|
|
65319
65579
|
icon: toolbarIcons2.mergeCells,
|
|
65320
|
-
props: {
|
|
65580
|
+
props: {
|
|
65581
|
+
"data-item": "btn-tableActions-option",
|
|
65582
|
+
ariaLabel: "Merge cells"
|
|
65583
|
+
}
|
|
65321
65584
|
},
|
|
65322
65585
|
{
|
|
65323
65586
|
label: toolbarTexts2.splitCell,
|
|
65324
65587
|
command: "splitCell",
|
|
65325
65588
|
icon: toolbarIcons2.splitCell,
|
|
65326
|
-
props: {
|
|
65589
|
+
props: {
|
|
65590
|
+
"data-item": "btn-tableActions-option",
|
|
65591
|
+
ariaLabel: "Split cells"
|
|
65592
|
+
}
|
|
65327
65593
|
},
|
|
65328
65594
|
{
|
|
65329
65595
|
label: toolbarTexts2.fixTables,
|
|
65330
65596
|
command: "fixTables",
|
|
65331
65597
|
icon: toolbarIcons2.fixTables,
|
|
65332
|
-
props: {
|
|
65598
|
+
props: {
|
|
65599
|
+
"data-item": "btn-tableActions-option",
|
|
65600
|
+
ariaLabel: "Fix tables"
|
|
65601
|
+
}
|
|
65333
65602
|
}
|
|
65334
65603
|
];
|
|
65335
65604
|
function renderTableActions(tableActionsItem2) {
|
|
@@ -65352,6 +65621,9 @@ const makeDefaultItems = ({
|
|
|
65352
65621
|
markName: "textAlign",
|
|
65353
65622
|
labelAttr: "textAlign",
|
|
65354
65623
|
suppressActiveHighlight: true,
|
|
65624
|
+
attributes: {
|
|
65625
|
+
ariaLabel: "Text align"
|
|
65626
|
+
},
|
|
65355
65627
|
options: [
|
|
65356
65628
|
{
|
|
65357
65629
|
type: "render",
|
|
@@ -65395,14 +65667,20 @@ const makeDefaultItems = ({
|
|
|
65395
65667
|
name: "list",
|
|
65396
65668
|
command: "toggleBulletList",
|
|
65397
65669
|
icon: toolbarIcons2.bulletList,
|
|
65398
|
-
tooltip: toolbarTexts2.bulletList
|
|
65670
|
+
tooltip: toolbarTexts2.bulletList,
|
|
65671
|
+
attributes: {
|
|
65672
|
+
ariaLabel: "Bullet list"
|
|
65673
|
+
}
|
|
65399
65674
|
});
|
|
65400
65675
|
const numberedList = useToolbarItem({
|
|
65401
65676
|
type: "button",
|
|
65402
65677
|
name: "numberedlist",
|
|
65403
65678
|
command: "toggleOrderedList",
|
|
65404
65679
|
icon: toolbarIcons2.numberedList,
|
|
65405
|
-
tooltip: toolbarTexts2.numberedList
|
|
65680
|
+
tooltip: toolbarTexts2.numberedList,
|
|
65681
|
+
attributes: {
|
|
65682
|
+
ariaLabel: "Numbered list"
|
|
65683
|
+
}
|
|
65406
65684
|
});
|
|
65407
65685
|
const indentLeft = useToolbarItem({
|
|
65408
65686
|
type: "button",
|
|
@@ -65410,7 +65688,10 @@ const makeDefaultItems = ({
|
|
|
65410
65688
|
command: "decreaseTextIndent",
|
|
65411
65689
|
icon: toolbarIcons2.indentLeft,
|
|
65412
65690
|
tooltip: toolbarTexts2.indentLeft,
|
|
65413
|
-
disabled: false
|
|
65691
|
+
disabled: false,
|
|
65692
|
+
attributes: {
|
|
65693
|
+
ariaLabel: "Left indent"
|
|
65694
|
+
}
|
|
65414
65695
|
});
|
|
65415
65696
|
const indentRight = useToolbarItem({
|
|
65416
65697
|
type: "button",
|
|
@@ -65418,14 +65699,20 @@ const makeDefaultItems = ({
|
|
|
65418
65699
|
command: "increaseTextIndent",
|
|
65419
65700
|
icon: toolbarIcons2.indentRight,
|
|
65420
65701
|
tooltip: toolbarTexts2.indentRight,
|
|
65421
|
-
disabled: false
|
|
65702
|
+
disabled: false,
|
|
65703
|
+
attributes: {
|
|
65704
|
+
ariaLabel: "Right indent"
|
|
65705
|
+
}
|
|
65422
65706
|
});
|
|
65423
65707
|
const overflow = useToolbarItem({
|
|
65424
65708
|
type: "overflow",
|
|
65425
65709
|
name: "overflow",
|
|
65426
65710
|
command: "toggleOverflow",
|
|
65427
65711
|
icon: toolbarIcons2.overflow,
|
|
65428
|
-
disabled: false
|
|
65712
|
+
disabled: false,
|
|
65713
|
+
attributes: {
|
|
65714
|
+
ariaLabel: "Overflow items"
|
|
65715
|
+
}
|
|
65429
65716
|
});
|
|
65430
65717
|
const zoom = useToolbarItem({
|
|
65431
65718
|
type: "dropdown",
|
|
@@ -65439,6 +65726,9 @@ const makeDefaultItems = ({
|
|
|
65439
65726
|
isWide: true,
|
|
65440
65727
|
inlineTextInputVisible: false,
|
|
65441
65728
|
hasInlineTextInput: true,
|
|
65729
|
+
attributes: {
|
|
65730
|
+
ariaLabel: "Zoom"
|
|
65731
|
+
},
|
|
65442
65732
|
options: [
|
|
65443
65733
|
{ label: "50%", key: 0.5, props: { "data-item": "btn-zoom-option" } },
|
|
65444
65734
|
{ label: "75%", key: 0.75, props: { "data-item": "btn-zoom-option" } },
|
|
@@ -65461,6 +65751,9 @@ const makeDefaultItems = ({
|
|
|
65461
65751
|
command: "undo",
|
|
65462
65752
|
icon: toolbarIcons2.undo,
|
|
65463
65753
|
group: "left",
|
|
65754
|
+
attributes: {
|
|
65755
|
+
ariaLabel: "Undo"
|
|
65756
|
+
},
|
|
65464
65757
|
onDeactivate: () => {
|
|
65465
65758
|
undo2.disabled.value = !superToolbar.undoDepth;
|
|
65466
65759
|
}
|
|
@@ -65473,6 +65766,9 @@ const makeDefaultItems = ({
|
|
|
65473
65766
|
command: "redo",
|
|
65474
65767
|
icon: toolbarIcons2.redo,
|
|
65475
65768
|
group: "left",
|
|
65769
|
+
attributes: {
|
|
65770
|
+
ariaLabel: "Redo"
|
|
65771
|
+
},
|
|
65476
65772
|
onDeactivate: () => {
|
|
65477
65773
|
redo2.disabled.value = !superToolbar.redoDepth;
|
|
65478
65774
|
}
|
|
@@ -65484,7 +65780,10 @@ const makeDefaultItems = ({
|
|
|
65484
65780
|
tooltip: toolbarTexts2.trackChanges,
|
|
65485
65781
|
command: "toggleTrackChanges",
|
|
65486
65782
|
icon: toolbarIcons2.trackChanges,
|
|
65487
|
-
group: "left"
|
|
65783
|
+
group: "left",
|
|
65784
|
+
attributes: {
|
|
65785
|
+
ariaLabel: "Track changes"
|
|
65786
|
+
}
|
|
65488
65787
|
});
|
|
65489
65788
|
const acceptTrackedChangeBySelection = useToolbarItem({
|
|
65490
65789
|
type: "button",
|
|
@@ -65493,7 +65792,10 @@ const makeDefaultItems = ({
|
|
|
65493
65792
|
tooltip: toolbarTexts2.trackChangesAccept,
|
|
65494
65793
|
command: "acceptTrackedChangeBySelection",
|
|
65495
65794
|
icon: toolbarIcons2.trackChangesAccept,
|
|
65496
|
-
group: "left"
|
|
65795
|
+
group: "left",
|
|
65796
|
+
attributes: {
|
|
65797
|
+
ariaLabel: "Accept tracked changes"
|
|
65798
|
+
}
|
|
65497
65799
|
});
|
|
65498
65800
|
const rejectTrackedChangeOnSelection = useToolbarItem({
|
|
65499
65801
|
type: "button",
|
|
@@ -65502,7 +65804,10 @@ const makeDefaultItems = ({
|
|
|
65502
65804
|
tooltip: toolbarTexts2.trackChangesReject,
|
|
65503
65805
|
command: "rejectTrackedChangeOnSelection",
|
|
65504
65806
|
icon: toolbarIcons2.trackChangesReject,
|
|
65505
|
-
group: "left"
|
|
65807
|
+
group: "left",
|
|
65808
|
+
attributes: {
|
|
65809
|
+
ariaLabel: "Reject tracked changes"
|
|
65810
|
+
}
|
|
65506
65811
|
});
|
|
65507
65812
|
const toggleTrackChangesOriginal = useToolbarItem({
|
|
65508
65813
|
type: "button",
|
|
@@ -65511,7 +65816,10 @@ const makeDefaultItems = ({
|
|
|
65511
65816
|
tooltip: toolbarTexts2.trackChangesOriginal,
|
|
65512
65817
|
command: "toggleTrackChangesShowOriginal",
|
|
65513
65818
|
icon: toolbarIcons2.trackChangesOriginal,
|
|
65514
|
-
group: "left"
|
|
65819
|
+
group: "left",
|
|
65820
|
+
attributes: {
|
|
65821
|
+
ariaLabel: "Toggle tracked changes show original"
|
|
65822
|
+
}
|
|
65515
65823
|
});
|
|
65516
65824
|
const toggleTrackChangesFinal = useToolbarItem({
|
|
65517
65825
|
type: "button",
|
|
@@ -65520,14 +65828,20 @@ const makeDefaultItems = ({
|
|
|
65520
65828
|
tooltip: toolbarTexts2.trackChangesFinal,
|
|
65521
65829
|
command: "toggleTrackChangesShowFinal",
|
|
65522
65830
|
icon: toolbarIcons2.trackChangesFinal,
|
|
65523
|
-
group: "left"
|
|
65831
|
+
group: "left",
|
|
65832
|
+
attributes: {
|
|
65833
|
+
ariaLabel: "Toggle tracked changes show final"
|
|
65834
|
+
}
|
|
65524
65835
|
});
|
|
65525
65836
|
const clearFormatting = useToolbarItem({
|
|
65526
65837
|
type: "button",
|
|
65527
65838
|
name: "clearFormatting",
|
|
65528
65839
|
command: "clearFormat",
|
|
65529
65840
|
tooltip: toolbarTexts2.clearFormatting,
|
|
65530
|
-
icon: toolbarIcons2.clearFormatting
|
|
65841
|
+
icon: toolbarIcons2.clearFormatting,
|
|
65842
|
+
attributes: {
|
|
65843
|
+
ariaLabel: "Clear formatting"
|
|
65844
|
+
}
|
|
65531
65845
|
});
|
|
65532
65846
|
[
|
|
65533
65847
|
bold,
|
|
@@ -65543,7 +65857,10 @@ const makeDefaultItems = ({
|
|
|
65543
65857
|
name: "copyFormat",
|
|
65544
65858
|
tooltip: toolbarTexts2.copyFormat,
|
|
65545
65859
|
icon: toolbarIcons2.copyFormat,
|
|
65546
|
-
command: "copyFormat"
|
|
65860
|
+
command: "copyFormat",
|
|
65861
|
+
attributes: {
|
|
65862
|
+
ariaLabel: "Copy formatting"
|
|
65863
|
+
}
|
|
65547
65864
|
});
|
|
65548
65865
|
const getDocumentOptionsAfterRole = (role2, documentOptions2) => {
|
|
65549
65866
|
if (role2 === "editor") return documentOptions2;
|
|
@@ -65572,7 +65889,8 @@ const makeDefaultItems = ({
|
|
|
65572
65889
|
disabled: role !== "editor",
|
|
65573
65890
|
attributes: {
|
|
65574
65891
|
dropdownPosition: "right",
|
|
65575
|
-
className: "toolbar-item--doc-mode"
|
|
65892
|
+
className: "toolbar-item--doc-mode",
|
|
65893
|
+
ariaLabel: "Document mode"
|
|
65576
65894
|
},
|
|
65577
65895
|
options: [
|
|
65578
65896
|
{
|
|
@@ -65619,7 +65937,10 @@ const makeDefaultItems = ({
|
|
|
65619
65937
|
name: "pageBreakTool",
|
|
65620
65938
|
command: "insertPageBreak",
|
|
65621
65939
|
icon: toolbarIcons2.pageBreak,
|
|
65622
|
-
tooltip: toolbarTexts2.pageBreak
|
|
65940
|
+
tooltip: toolbarTexts2.pageBreak,
|
|
65941
|
+
attributes: {
|
|
65942
|
+
ariaLabel: "Page break"
|
|
65943
|
+
}
|
|
65623
65944
|
});
|
|
65624
65945
|
const controlSizes = /* @__PURE__ */ new Map([
|
|
65625
65946
|
["separator", 20],
|
|
@@ -65637,7 +65958,10 @@ const makeDefaultItems = ({
|
|
|
65637
65958
|
name: "ruler",
|
|
65638
65959
|
command: "toggleRuler",
|
|
65639
65960
|
icon: toolbarIcons2.ruler,
|
|
65640
|
-
tooltip: toolbarTexts2.ruler
|
|
65961
|
+
tooltip: toolbarTexts2.ruler,
|
|
65962
|
+
attributes: {
|
|
65963
|
+
ariaLabel: "Ruler"
|
|
65964
|
+
}
|
|
65641
65965
|
});
|
|
65642
65966
|
const selectedLinkedStyle = ref$1(null);
|
|
65643
65967
|
const linkedStyles = useToolbarItem({
|
|
@@ -65653,7 +65977,8 @@ const makeDefaultItems = ({
|
|
|
65653
65977
|
suppressActiveHighlight: true,
|
|
65654
65978
|
disabled: false,
|
|
65655
65979
|
attributes: {
|
|
65656
|
-
className: "toolbar-item--linked-styles"
|
|
65980
|
+
className: "toolbar-item--linked-styles",
|
|
65981
|
+
ariaLabel: "Linked styles"
|
|
65657
65982
|
},
|
|
65658
65983
|
options: [
|
|
65659
65984
|
{
|
|
@@ -65700,6 +66025,9 @@ const makeDefaultItems = ({
|
|
|
65700
66025
|
command: "setLineHeight",
|
|
65701
66026
|
dropdownValueKey: "key",
|
|
65702
66027
|
selectedValue: "1",
|
|
66028
|
+
attributes: {
|
|
66029
|
+
ariaLabel: "Line height"
|
|
66030
|
+
},
|
|
65703
66031
|
options: [
|
|
65704
66032
|
{ label: "1,0", key: "1", icon: () => renderIcon("1", lineHeight2.selectedValue), props: { "data-item": "btn-lineHeight-option" } },
|
|
65705
66033
|
{ label: "1,15", key: "1.15", icon: () => renderIcon("1.15", lineHeight2.selectedValue), props: { "data-item": "btn-lineHeight-option" } },
|
|
@@ -67017,7 +67345,8 @@ const _sfc_main$2 = {
|
|
|
67017
67345
|
createBaseVNode("div", {
|
|
67018
67346
|
ref_key: "editorElem",
|
|
67019
67347
|
ref: editorElem,
|
|
67020
|
-
class: "editor-element super-editor__element"
|
|
67348
|
+
class: "editor-element super-editor__element",
|
|
67349
|
+
role: "presentation"
|
|
67021
67350
|
}, null, 512)
|
|
67022
67351
|
], 544),
|
|
67023
67352
|
!editorReady.value ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
@@ -67069,7 +67398,7 @@ const _sfc_main$2 = {
|
|
|
67069
67398
|
};
|
|
67070
67399
|
}
|
|
67071
67400
|
};
|
|
67072
|
-
const SuperEditor = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-
|
|
67401
|
+
const SuperEditor = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-f27b7c30"]]);
|
|
67073
67402
|
const _sfc_main$1 = {
|
|
67074
67403
|
__name: "BasicUpload",
|
|
67075
67404
|
emits: ["file-change"],
|
|
@@ -67196,18 +67525,19 @@ export {
|
|
|
67196
67525
|
SuperConverter as S,
|
|
67197
67526
|
Toolbar as T,
|
|
67198
67527
|
_sfc_main$1 as _,
|
|
67199
|
-
|
|
67200
|
-
|
|
67201
|
-
|
|
67202
|
-
|
|
67203
|
-
|
|
67204
|
-
|
|
67205
|
-
|
|
67206
|
-
|
|
67528
|
+
AnnotatorHelpers as a,
|
|
67529
|
+
Extensions as b,
|
|
67530
|
+
SuperEditor as c,
|
|
67531
|
+
SuperInput as d,
|
|
67532
|
+
SuperToolbar as e,
|
|
67533
|
+
TrackChangesBasePluginKey as f,
|
|
67534
|
+
createZip as g,
|
|
67535
|
+
getActiveFormatting as h,
|
|
67207
67536
|
index$1 as i,
|
|
67208
|
-
|
|
67209
|
-
|
|
67210
|
-
|
|
67211
|
-
|
|
67212
|
-
|
|
67537
|
+
getAllowedImageDimensions as j,
|
|
67538
|
+
getMarksFromSelection as k,
|
|
67539
|
+
getRichTextExtensions as l,
|
|
67540
|
+
getStarterExtensions as m,
|
|
67541
|
+
helpers as n,
|
|
67542
|
+
index as o
|
|
67213
67543
|
};
|