@harbour-enterprises/superdoc 0.22.0-next.5 → 0.22.0-next.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{PdfViewer-dsL5uHg1.es.js → PdfViewer-BMfm6DSP.es.js} +1 -1
- package/dist/chunks/{PdfViewer-Badqoc1e.cjs → PdfViewer-XMDxj-2m.cjs} +1 -1
- package/dist/chunks/{index-DVrbZM76.cjs → index-BlNiELtW.cjs} +2 -2
- package/dist/chunks/{index-DBNzXf1D.es.js → index-Cvi1utmk.es.js} +2 -2
- package/dist/chunks/{super-editor.es-p3eqHXlj.cjs → super-editor.es-BDsfLrnI.cjs} +90 -2
- package/dist/chunks/{super-editor.es-DruRanWK.es.js → super-editor.es-CmQ5GChv.es.js} +90 -2
- package/dist/super-editor/ai-writer.es.js +2 -2
- package/dist/super-editor/chunks/{converter-DujfV3Zn.js → converter-D9kK7Smo.js} +90 -2
- package/dist/super-editor/chunks/{docx-zipper-DccEqL60.js → docx-zipper-D8HnWWpv.js} +1 -1
- package/dist/super-editor/chunks/{editor-Dq3xPdti.js → editor-Ddkz97dH.js} +2 -2
- package/dist/super-editor/chunks/{toolbar-u5oyT_9K.js → toolbar-BxjdbiUf.js} +2 -2
- package/dist/super-editor/converter.es.js +1 -1
- package/dist/super-editor/docx-zipper.es.js +2 -2
- package/dist/super-editor/editor.es.js +3 -3
- package/dist/super-editor/file-zipper.es.js +1 -1
- package/dist/super-editor/src/core/super-converter/helpers/tableFallbackHelpers.d.ts +24 -0
- package/dist/super-editor/super-editor.es.js +6 -6
- package/dist/super-editor/toolbar.es.js +2 -2
- package/dist/super-editor.cjs +1 -1
- package/dist/super-editor.es.js +1 -1
- package/dist/superdoc.cjs +2 -2
- package/dist/superdoc.es.js +2 -2
- package/dist/superdoc.umd.js +90 -2
- package/dist/superdoc.umd.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { m as defineComponent, B as h, O as Transition, $ as process$1, I as watchEffect, d as computed, r as ref, j as onMounted, W as onUnmounted, c as createElementBlock, o as openBlock, a as createBaseVNode, f as createCommentVNode, v as createVNode, x as unref } from "./vue-CXxsqYcP.es.js";
|
|
2
|
-
import { d as derived, c, a as cB, f as fadeInTransition, b as cM, N as NBaseLoading, w as warnOnce, u as useConfig, e as useTheme, p as pxfy, g as createKey, h as useThemeClass, i as useCompitable, _ as _export_sfc, j as useSuperdocStore, s as storeToRefs, k as useSelection } from "./index-
|
|
2
|
+
import { d as derived, c, a as cB, f as fadeInTransition, b as cM, N as NBaseLoading, w as warnOnce, u as useConfig, e as useTheme, p as pxfy, g as createKey, h as useThemeClass, i as useCompitable, _ as _export_sfc, j as useSuperdocStore, s as storeToRefs, k as useSelection } from "./index-Cvi1utmk.es.js";
|
|
3
3
|
function self(vars) {
|
|
4
4
|
const {
|
|
5
5
|
opacityDisabled,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
3
|
const vue = require("./vue-DWle4Cai.cjs");
|
|
4
|
-
const superdoc = require("./index-
|
|
4
|
+
const superdoc = require("./index-BlNiELtW.cjs");
|
|
5
5
|
function self(vars) {
|
|
6
6
|
const {
|
|
7
7
|
opacityDisabled,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
const superEditor_es = require("./super-editor.es-
|
|
2
|
+
const superEditor_es = require("./super-editor.es-BDsfLrnI.cjs");
|
|
3
3
|
const vue = require("./vue-DWle4Cai.cjs");
|
|
4
4
|
const jszip = require("./jszip-b7l8QkfH.cjs");
|
|
5
5
|
const blankDocx = require("./blank-docx-CPqX9RF5.cjs");
|
|
@@ -17409,7 +17409,7 @@ const _sfc_main = {
|
|
|
17409
17409
|
__name: "SuperDoc",
|
|
17410
17410
|
emits: ["selection-update"],
|
|
17411
17411
|
setup(__props, { emit: __emit }) {
|
|
17412
|
-
const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-
|
|
17412
|
+
const PdfViewer = vue.defineAsyncComponent(() => Promise.resolve().then(() => require("./PdfViewer-XMDxj-2m.cjs")));
|
|
17413
17413
|
const superdocStore = useSuperdocStore();
|
|
17414
17414
|
const commentsStore = useCommentsStore();
|
|
17415
17415
|
const {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { q as index$1, C as CommentsPluginKey, h as TrackChangesBasePluginKey, E as Editor, n as getRichTextExtensions, f as SuperInput, e as SuperEditor, A as AIWriter, g as SuperToolbar, i as createZip } from "./super-editor.es-
|
|
1
|
+
import { q as index$1, C as CommentsPluginKey, h as TrackChangesBasePluginKey, E as Editor, n as getRichTextExtensions, f as SuperInput, e as SuperEditor, A as AIWriter, g as SuperToolbar, i as createZip } from "./super-editor.es-CmQ5GChv.es.js";
|
|
2
2
|
import { a0 as effectScope, r as ref, _ as markRaw, $ as process$1, a1 as toRaw, d as computed, a2 as isRef, a3 as isReactive, C as toRef, i as inject, p as getCurrentInstance, l as watch, x as unref, a4 as hasInjectionContext, M as reactive, s as nextTick, a5 as getCurrentScope, a6 as onScopeDispose, a7 as toRefs, g as global$1, J as shallowRef, N as readonly, j as onMounted, k as onBeforeUnmount, h as onBeforeMount, S as onActivated, q as onDeactivated, z as createTextVNode, F as Fragment, Q as Comment, m as defineComponent, D as provide, H as withDirectives, B as h, U as Teleport, R as renderSlot, V as isVNode, I as watchEffect, O as Transition, a8 as TransitionGroup, E as mergeProps, P as vShow, G as cloneVNode, T as Text, c as createElementBlock, o as openBlock, t as toDisplayString, v as createVNode, y as withCtx, a as createBaseVNode, A as normalizeStyle, f as createCommentVNode, u as createBlock, w as withModifiers, n as normalizeClass, a9 as resolveDirective, e as renderList, b as createApp, X as resolveDynamicComponent, aa as defineAsyncComponent } from "./vue-CXxsqYcP.es.js";
|
|
3
3
|
import { B as Buffer$2 } from "./jszip-B8KIZSNe.es.js";
|
|
4
4
|
import { B as BlankDOCX } from "./blank-docx-iwdyG9RH.es.js";
|
|
@@ -17392,7 +17392,7 @@ const _sfc_main = {
|
|
|
17392
17392
|
__name: "SuperDoc",
|
|
17393
17393
|
emits: ["selection-update"],
|
|
17394
17394
|
setup(__props, { emit: __emit }) {
|
|
17395
|
-
const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-
|
|
17395
|
+
const PdfViewer = defineAsyncComponent(() => import("./PdfViewer-BMfm6DSP.es.js"));
|
|
17396
17396
|
const superdocStore = useSuperdocStore();
|
|
17397
17397
|
const commentsStore = useCommentsStore();
|
|
17398
17398
|
const {
|
|
@@ -27177,6 +27177,68 @@ const config$a = {
|
|
|
27177
27177
|
decode: decode$h
|
|
27178
27178
|
};
|
|
27179
27179
|
const translator$a = NodeTranslator.from(config$a);
|
|
27180
|
+
const DEFAULT_PAGE_WIDTH_TWIPS = 12240;
|
|
27181
|
+
const DEFAULT_PAGE_MARGIN_TWIPS = 1440;
|
|
27182
|
+
const DEFAULT_CONTENT_WIDTH_TWIPS = DEFAULT_PAGE_WIDTH_TWIPS - 2 * DEFAULT_PAGE_MARGIN_TWIPS;
|
|
27183
|
+
const MIN_COLUMN_WIDTH_TWIPS = pixelsToTwips(10);
|
|
27184
|
+
const pctToPercent = (value) => {
|
|
27185
|
+
if (value == null) return null;
|
|
27186
|
+
return value / 50;
|
|
27187
|
+
};
|
|
27188
|
+
const resolveContentWidthTwips = () => DEFAULT_CONTENT_WIDTH_TWIPS;
|
|
27189
|
+
const resolveMeasurementWidthPx = (measurement) => {
|
|
27190
|
+
if (!measurement || typeof measurement.value !== "number" || measurement.value <= 0) return null;
|
|
27191
|
+
const { value, type: type2 } = measurement;
|
|
27192
|
+
if (!type2 || type2 === "auto") return null;
|
|
27193
|
+
if (type2 === "dxa") return twipsToPixels(value);
|
|
27194
|
+
if (type2 === "pct") {
|
|
27195
|
+
const percent2 = pctToPercent(value);
|
|
27196
|
+
if (percent2 == null || percent2 <= 0) return null;
|
|
27197
|
+
const widthTwips = resolveContentWidthTwips() * percent2 / 100;
|
|
27198
|
+
return twipsToPixels(widthTwips);
|
|
27199
|
+
}
|
|
27200
|
+
return null;
|
|
27201
|
+
};
|
|
27202
|
+
const countColumnsInRow = (row) => {
|
|
27203
|
+
if (!row?.elements?.length) return 0;
|
|
27204
|
+
return row.elements.reduce((count, element) => {
|
|
27205
|
+
if (element.name !== "w:tc") return count;
|
|
27206
|
+
const tcPr = element.elements?.find((el) => el.name === "w:tcPr");
|
|
27207
|
+
const gridSpan = tcPr?.elements?.find((el) => el.name === "w:gridSpan");
|
|
27208
|
+
const spanValue = parseInt(gridSpan?.attributes?.["w:val"] || "1", 10);
|
|
27209
|
+
return count + (Number.isFinite(spanValue) && spanValue > 0 ? spanValue : 1);
|
|
27210
|
+
}, 0);
|
|
27211
|
+
};
|
|
27212
|
+
const clampColumnWidthTwips = (value) => Math.max(Math.round(value), MIN_COLUMN_WIDTH_TWIPS);
|
|
27213
|
+
const createFallbackGrid = (columnCount, columnWidthTwips) => Array.from({ length: columnCount }, () => ({ col: clampColumnWidthTwips(columnWidthTwips) }));
|
|
27214
|
+
const buildFallbackGridForTable = ({ params: params2, rows, tableWidth, tableWidthMeasurement }) => {
|
|
27215
|
+
const firstRow = rows.find((row) => row.elements?.some((el) => el.name === "w:tc"));
|
|
27216
|
+
const columnCount = countColumnsInRow(firstRow);
|
|
27217
|
+
if (!columnCount) return null;
|
|
27218
|
+
const schemaDefaultPx = getSchemaDefaultColumnWidthPx(
|
|
27219
|
+
/** @type {any} */
|
|
27220
|
+
params2
|
|
27221
|
+
);
|
|
27222
|
+
const minimumColumnWidthPx = Number.isFinite(schemaDefaultPx) && schemaDefaultPx > 0 ? schemaDefaultPx : DEFAULT_COLUMN_WIDTH_PX;
|
|
27223
|
+
let totalWidthPx;
|
|
27224
|
+
if (tableWidthMeasurement) {
|
|
27225
|
+
const resolved = resolveMeasurementWidthPx(tableWidthMeasurement);
|
|
27226
|
+
if (resolved != null) totalWidthPx = resolved;
|
|
27227
|
+
}
|
|
27228
|
+
if (totalWidthPx == null && tableWidth?.width && tableWidth.width > 0) {
|
|
27229
|
+
totalWidthPx = tableWidth.width;
|
|
27230
|
+
}
|
|
27231
|
+
if (totalWidthPx == null) {
|
|
27232
|
+
totalWidthPx = minimumColumnWidthPx * columnCount;
|
|
27233
|
+
}
|
|
27234
|
+
const rawColumnWidthPx = Math.max(totalWidthPx / columnCount, minimumColumnWidthPx);
|
|
27235
|
+
const columnWidthTwips = clampColumnWidthTwips(pixelsToTwips(rawColumnWidthPx));
|
|
27236
|
+
const fallbackColumnWidthPx = twipsToPixels(columnWidthTwips);
|
|
27237
|
+
return {
|
|
27238
|
+
grid: createFallbackGrid(columnCount, columnWidthTwips),
|
|
27239
|
+
columnWidths: Array(columnCount).fill(fallbackColumnWidthPx)
|
|
27240
|
+
};
|
|
27241
|
+
};
|
|
27180
27242
|
const XML_NODE_NAME$9 = "w:tbl";
|
|
27181
27243
|
const SD_NODE_NAME$9 = "table";
|
|
27182
27244
|
const encode$g = (params2, encodedAttrs) => {
|
|
@@ -27196,7 +27258,6 @@ const encode$g = (params2, encodedAttrs) => {
|
|
|
27196
27258
|
"justification",
|
|
27197
27259
|
"tableLayout",
|
|
27198
27260
|
["tableIndent", ({ value, type: type2 }) => ({ width: twipsToPixels(value), type: type2 })],
|
|
27199
|
-
["tableWidth", ({ value, type: type2 }) => ({ width: twipsToPixels(value), type: type2 })],
|
|
27200
27261
|
["tableCellSpacing", ({ value, type: type2 }) => ({ w: String(value), type: type2 })]
|
|
27201
27262
|
].forEach((prop) => {
|
|
27202
27263
|
let key2;
|
|
@@ -27214,6 +27275,21 @@ const encode$g = (params2, encodedAttrs) => {
|
|
|
27214
27275
|
if (encodedAttrs.tableCellSpacing) {
|
|
27215
27276
|
encodedAttrs["borderCollapse"] = "separate";
|
|
27216
27277
|
}
|
|
27278
|
+
if (encodedAttrs.tableProperties?.tableWidth) {
|
|
27279
|
+
const tableWidthMeasurement = encodedAttrs.tableProperties.tableWidth;
|
|
27280
|
+
const widthPx = twipsToPixels(tableWidthMeasurement.value);
|
|
27281
|
+
if (widthPx != null) {
|
|
27282
|
+
encodedAttrs.tableWidth = {
|
|
27283
|
+
width: widthPx,
|
|
27284
|
+
type: tableWidthMeasurement.type
|
|
27285
|
+
};
|
|
27286
|
+
} else if (tableWidthMeasurement.type === "auto") {
|
|
27287
|
+
encodedAttrs.tableWidth = {
|
|
27288
|
+
width: 0,
|
|
27289
|
+
type: tableWidthMeasurement.type
|
|
27290
|
+
};
|
|
27291
|
+
}
|
|
27292
|
+
}
|
|
27217
27293
|
const { borders, rowBorders } = _processTableBorders(encodedAttrs.tableProperties?.borders || {});
|
|
27218
27294
|
const referencedStyles = _getReferencedTableStyles(encodedAttrs.tableStyleId, params2);
|
|
27219
27295
|
if (referencedStyles?.cellMargins && !encodedAttrs.tableProperties?.cellMargins) {
|
|
@@ -27227,7 +27303,19 @@ const encode$g = (params2, encodedAttrs) => {
|
|
|
27227
27303
|
const borderRowData = Object.assign({}, referencedStyles?.rowBorders || {}, rowBorders || {});
|
|
27228
27304
|
encodedAttrs["borders"] = borderData;
|
|
27229
27305
|
const tblStyleTag = tblPr?.elements?.find((el) => el.name === "w:tblStyle");
|
|
27230
|
-
|
|
27306
|
+
let columnWidths = Array.isArray(encodedAttrs["grid"]) ? encodedAttrs["grid"].map((item) => twipsToPixels(item.col)) : [];
|
|
27307
|
+
if (!columnWidths.length) {
|
|
27308
|
+
const fallback = buildFallbackGridForTable({
|
|
27309
|
+
params: params2,
|
|
27310
|
+
rows,
|
|
27311
|
+
tableWidth: encodedAttrs.tableWidth,
|
|
27312
|
+
tableWidthMeasurement: encodedAttrs.tableProperties?.tableWidth
|
|
27313
|
+
});
|
|
27314
|
+
if (fallback) {
|
|
27315
|
+
encodedAttrs.grid = fallback.grid;
|
|
27316
|
+
columnWidths = fallback.columnWidths;
|
|
27317
|
+
}
|
|
27318
|
+
}
|
|
27231
27319
|
const content = [];
|
|
27232
27320
|
rows.forEach((row) => {
|
|
27233
27321
|
const result = translator$G.encode({
|
|
@@ -27160,6 +27160,68 @@ const config$a = {
|
|
|
27160
27160
|
decode: decode$h
|
|
27161
27161
|
};
|
|
27162
27162
|
const translator$a = NodeTranslator.from(config$a);
|
|
27163
|
+
const DEFAULT_PAGE_WIDTH_TWIPS = 12240;
|
|
27164
|
+
const DEFAULT_PAGE_MARGIN_TWIPS = 1440;
|
|
27165
|
+
const DEFAULT_CONTENT_WIDTH_TWIPS = DEFAULT_PAGE_WIDTH_TWIPS - 2 * DEFAULT_PAGE_MARGIN_TWIPS;
|
|
27166
|
+
const MIN_COLUMN_WIDTH_TWIPS = pixelsToTwips(10);
|
|
27167
|
+
const pctToPercent = (value) => {
|
|
27168
|
+
if (value == null) return null;
|
|
27169
|
+
return value / 50;
|
|
27170
|
+
};
|
|
27171
|
+
const resolveContentWidthTwips = () => DEFAULT_CONTENT_WIDTH_TWIPS;
|
|
27172
|
+
const resolveMeasurementWidthPx = (measurement) => {
|
|
27173
|
+
if (!measurement || typeof measurement.value !== "number" || measurement.value <= 0) return null;
|
|
27174
|
+
const { value, type: type2 } = measurement;
|
|
27175
|
+
if (!type2 || type2 === "auto") return null;
|
|
27176
|
+
if (type2 === "dxa") return twipsToPixels(value);
|
|
27177
|
+
if (type2 === "pct") {
|
|
27178
|
+
const percent2 = pctToPercent(value);
|
|
27179
|
+
if (percent2 == null || percent2 <= 0) return null;
|
|
27180
|
+
const widthTwips = resolveContentWidthTwips() * percent2 / 100;
|
|
27181
|
+
return twipsToPixels(widthTwips);
|
|
27182
|
+
}
|
|
27183
|
+
return null;
|
|
27184
|
+
};
|
|
27185
|
+
const countColumnsInRow = (row) => {
|
|
27186
|
+
if (!row?.elements?.length) return 0;
|
|
27187
|
+
return row.elements.reduce((count, element) => {
|
|
27188
|
+
if (element.name !== "w:tc") return count;
|
|
27189
|
+
const tcPr = element.elements?.find((el) => el.name === "w:tcPr");
|
|
27190
|
+
const gridSpan = tcPr?.elements?.find((el) => el.name === "w:gridSpan");
|
|
27191
|
+
const spanValue = parseInt(gridSpan?.attributes?.["w:val"] || "1", 10);
|
|
27192
|
+
return count + (Number.isFinite(spanValue) && spanValue > 0 ? spanValue : 1);
|
|
27193
|
+
}, 0);
|
|
27194
|
+
};
|
|
27195
|
+
const clampColumnWidthTwips = (value) => Math.max(Math.round(value), MIN_COLUMN_WIDTH_TWIPS);
|
|
27196
|
+
const createFallbackGrid = (columnCount, columnWidthTwips) => Array.from({ length: columnCount }, () => ({ col: clampColumnWidthTwips(columnWidthTwips) }));
|
|
27197
|
+
const buildFallbackGridForTable = ({ params: params2, rows, tableWidth, tableWidthMeasurement }) => {
|
|
27198
|
+
const firstRow = rows.find((row) => row.elements?.some((el) => el.name === "w:tc"));
|
|
27199
|
+
const columnCount = countColumnsInRow(firstRow);
|
|
27200
|
+
if (!columnCount) return null;
|
|
27201
|
+
const schemaDefaultPx = getSchemaDefaultColumnWidthPx(
|
|
27202
|
+
/** @type {any} */
|
|
27203
|
+
params2
|
|
27204
|
+
);
|
|
27205
|
+
const minimumColumnWidthPx = Number.isFinite(schemaDefaultPx) && schemaDefaultPx > 0 ? schemaDefaultPx : DEFAULT_COLUMN_WIDTH_PX;
|
|
27206
|
+
let totalWidthPx;
|
|
27207
|
+
if (tableWidthMeasurement) {
|
|
27208
|
+
const resolved = resolveMeasurementWidthPx(tableWidthMeasurement);
|
|
27209
|
+
if (resolved != null) totalWidthPx = resolved;
|
|
27210
|
+
}
|
|
27211
|
+
if (totalWidthPx == null && tableWidth?.width && tableWidth.width > 0) {
|
|
27212
|
+
totalWidthPx = tableWidth.width;
|
|
27213
|
+
}
|
|
27214
|
+
if (totalWidthPx == null) {
|
|
27215
|
+
totalWidthPx = minimumColumnWidthPx * columnCount;
|
|
27216
|
+
}
|
|
27217
|
+
const rawColumnWidthPx = Math.max(totalWidthPx / columnCount, minimumColumnWidthPx);
|
|
27218
|
+
const columnWidthTwips = clampColumnWidthTwips(pixelsToTwips(rawColumnWidthPx));
|
|
27219
|
+
const fallbackColumnWidthPx = twipsToPixels(columnWidthTwips);
|
|
27220
|
+
return {
|
|
27221
|
+
grid: createFallbackGrid(columnCount, columnWidthTwips),
|
|
27222
|
+
columnWidths: Array(columnCount).fill(fallbackColumnWidthPx)
|
|
27223
|
+
};
|
|
27224
|
+
};
|
|
27163
27225
|
const XML_NODE_NAME$9 = "w:tbl";
|
|
27164
27226
|
const SD_NODE_NAME$9 = "table";
|
|
27165
27227
|
const encode$g = (params2, encodedAttrs) => {
|
|
@@ -27179,7 +27241,6 @@ const encode$g = (params2, encodedAttrs) => {
|
|
|
27179
27241
|
"justification",
|
|
27180
27242
|
"tableLayout",
|
|
27181
27243
|
["tableIndent", ({ value, type: type2 }) => ({ width: twipsToPixels(value), type: type2 })],
|
|
27182
|
-
["tableWidth", ({ value, type: type2 }) => ({ width: twipsToPixels(value), type: type2 })],
|
|
27183
27244
|
["tableCellSpacing", ({ value, type: type2 }) => ({ w: String(value), type: type2 })]
|
|
27184
27245
|
].forEach((prop) => {
|
|
27185
27246
|
let key2;
|
|
@@ -27197,6 +27258,21 @@ const encode$g = (params2, encodedAttrs) => {
|
|
|
27197
27258
|
if (encodedAttrs.tableCellSpacing) {
|
|
27198
27259
|
encodedAttrs["borderCollapse"] = "separate";
|
|
27199
27260
|
}
|
|
27261
|
+
if (encodedAttrs.tableProperties?.tableWidth) {
|
|
27262
|
+
const tableWidthMeasurement = encodedAttrs.tableProperties.tableWidth;
|
|
27263
|
+
const widthPx = twipsToPixels(tableWidthMeasurement.value);
|
|
27264
|
+
if (widthPx != null) {
|
|
27265
|
+
encodedAttrs.tableWidth = {
|
|
27266
|
+
width: widthPx,
|
|
27267
|
+
type: tableWidthMeasurement.type
|
|
27268
|
+
};
|
|
27269
|
+
} else if (tableWidthMeasurement.type === "auto") {
|
|
27270
|
+
encodedAttrs.tableWidth = {
|
|
27271
|
+
width: 0,
|
|
27272
|
+
type: tableWidthMeasurement.type
|
|
27273
|
+
};
|
|
27274
|
+
}
|
|
27275
|
+
}
|
|
27200
27276
|
const { borders, rowBorders } = _processTableBorders(encodedAttrs.tableProperties?.borders || {});
|
|
27201
27277
|
const referencedStyles = _getReferencedTableStyles(encodedAttrs.tableStyleId, params2);
|
|
27202
27278
|
if (referencedStyles?.cellMargins && !encodedAttrs.tableProperties?.cellMargins) {
|
|
@@ -27210,7 +27286,19 @@ const encode$g = (params2, encodedAttrs) => {
|
|
|
27210
27286
|
const borderRowData = Object.assign({}, referencedStyles?.rowBorders || {}, rowBorders || {});
|
|
27211
27287
|
encodedAttrs["borders"] = borderData;
|
|
27212
27288
|
const tblStyleTag = tblPr?.elements?.find((el) => el.name === "w:tblStyle");
|
|
27213
|
-
|
|
27289
|
+
let columnWidths = Array.isArray(encodedAttrs["grid"]) ? encodedAttrs["grid"].map((item) => twipsToPixels(item.col)) : [];
|
|
27290
|
+
if (!columnWidths.length) {
|
|
27291
|
+
const fallback = buildFallbackGridForTable({
|
|
27292
|
+
params: params2,
|
|
27293
|
+
rows,
|
|
27294
|
+
tableWidth: encodedAttrs.tableWidth,
|
|
27295
|
+
tableWidthMeasurement: encodedAttrs.tableProperties?.tableWidth
|
|
27296
|
+
});
|
|
27297
|
+
if (fallback) {
|
|
27298
|
+
encodedAttrs.grid = fallback.grid;
|
|
27299
|
+
columnWidths = fallback.columnWidths;
|
|
27300
|
+
}
|
|
27301
|
+
}
|
|
27214
27302
|
const content = [];
|
|
27215
27303
|
rows.forEach((row) => {
|
|
27216
27304
|
const result = translator$G.encode({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ref, onMounted, onUnmounted, computed, createElementBlock, openBlock, withModifiers, createElementVNode, withDirectives, unref, vModelText, createCommentVNode, nextTick } from "vue";
|
|
2
|
-
import { T as TextSelection } from "./chunks/converter-
|
|
3
|
-
import { _ as _export_sfc } from "./chunks/editor-
|
|
2
|
+
import { T as TextSelection } from "./chunks/converter-D9kK7Smo.js";
|
|
3
|
+
import { _ as _export_sfc } from "./chunks/editor-Ddkz97dH.js";
|
|
4
4
|
const DEFAULT_API_ENDPOINT = "https://sd-dev-express-gateway-i6xtm.ondigitalocean.app/insights";
|
|
5
5
|
const SYSTEM_PROMPT = "You are an expert copywriter and you are immersed in a document editor. You are to provide document related text responses based on the user prompts. Only write what is asked for. Do not provide explanations. Try to keep placeholders as short as possible. Do not output your prompt. Your instructions are: ";
|
|
6
6
|
async function baseInsightsFetch(payload, options = {}) {
|
|
@@ -27167,6 +27167,68 @@ const config$a = {
|
|
|
27167
27167
|
decode: decode$h
|
|
27168
27168
|
};
|
|
27169
27169
|
const translator$a = NodeTranslator.from(config$a);
|
|
27170
|
+
const DEFAULT_PAGE_WIDTH_TWIPS = 12240;
|
|
27171
|
+
const DEFAULT_PAGE_MARGIN_TWIPS = 1440;
|
|
27172
|
+
const DEFAULT_CONTENT_WIDTH_TWIPS = DEFAULT_PAGE_WIDTH_TWIPS - 2 * DEFAULT_PAGE_MARGIN_TWIPS;
|
|
27173
|
+
const MIN_COLUMN_WIDTH_TWIPS = pixelsToTwips(10);
|
|
27174
|
+
const pctToPercent = (value) => {
|
|
27175
|
+
if (value == null) return null;
|
|
27176
|
+
return value / 50;
|
|
27177
|
+
};
|
|
27178
|
+
const resolveContentWidthTwips = () => DEFAULT_CONTENT_WIDTH_TWIPS;
|
|
27179
|
+
const resolveMeasurementWidthPx = (measurement) => {
|
|
27180
|
+
if (!measurement || typeof measurement.value !== "number" || measurement.value <= 0) return null;
|
|
27181
|
+
const { value, type: type2 } = measurement;
|
|
27182
|
+
if (!type2 || type2 === "auto") return null;
|
|
27183
|
+
if (type2 === "dxa") return twipsToPixels(value);
|
|
27184
|
+
if (type2 === "pct") {
|
|
27185
|
+
const percent = pctToPercent(value);
|
|
27186
|
+
if (percent == null || percent <= 0) return null;
|
|
27187
|
+
const widthTwips = resolveContentWidthTwips() * percent / 100;
|
|
27188
|
+
return twipsToPixels(widthTwips);
|
|
27189
|
+
}
|
|
27190
|
+
return null;
|
|
27191
|
+
};
|
|
27192
|
+
const countColumnsInRow = (row) => {
|
|
27193
|
+
if (!row?.elements?.length) return 0;
|
|
27194
|
+
return row.elements.reduce((count, element) => {
|
|
27195
|
+
if (element.name !== "w:tc") return count;
|
|
27196
|
+
const tcPr = element.elements?.find((el) => el.name === "w:tcPr");
|
|
27197
|
+
const gridSpan = tcPr?.elements?.find((el) => el.name === "w:gridSpan");
|
|
27198
|
+
const spanValue = parseInt(gridSpan?.attributes?.["w:val"] || "1", 10);
|
|
27199
|
+
return count + (Number.isFinite(spanValue) && spanValue > 0 ? spanValue : 1);
|
|
27200
|
+
}, 0);
|
|
27201
|
+
};
|
|
27202
|
+
const clampColumnWidthTwips = (value) => Math.max(Math.round(value), MIN_COLUMN_WIDTH_TWIPS);
|
|
27203
|
+
const createFallbackGrid = (columnCount, columnWidthTwips) => Array.from({ length: columnCount }, () => ({ col: clampColumnWidthTwips(columnWidthTwips) }));
|
|
27204
|
+
const buildFallbackGridForTable = ({ params, rows, tableWidth, tableWidthMeasurement }) => {
|
|
27205
|
+
const firstRow = rows.find((row) => row.elements?.some((el) => el.name === "w:tc"));
|
|
27206
|
+
const columnCount = countColumnsInRow(firstRow);
|
|
27207
|
+
if (!columnCount) return null;
|
|
27208
|
+
const schemaDefaultPx = getSchemaDefaultColumnWidthPx(
|
|
27209
|
+
/** @type {any} */
|
|
27210
|
+
params
|
|
27211
|
+
);
|
|
27212
|
+
const minimumColumnWidthPx = Number.isFinite(schemaDefaultPx) && schemaDefaultPx > 0 ? schemaDefaultPx : DEFAULT_COLUMN_WIDTH_PX;
|
|
27213
|
+
let totalWidthPx;
|
|
27214
|
+
if (tableWidthMeasurement) {
|
|
27215
|
+
const resolved = resolveMeasurementWidthPx(tableWidthMeasurement);
|
|
27216
|
+
if (resolved != null) totalWidthPx = resolved;
|
|
27217
|
+
}
|
|
27218
|
+
if (totalWidthPx == null && tableWidth?.width && tableWidth.width > 0) {
|
|
27219
|
+
totalWidthPx = tableWidth.width;
|
|
27220
|
+
}
|
|
27221
|
+
if (totalWidthPx == null) {
|
|
27222
|
+
totalWidthPx = minimumColumnWidthPx * columnCount;
|
|
27223
|
+
}
|
|
27224
|
+
const rawColumnWidthPx = Math.max(totalWidthPx / columnCount, minimumColumnWidthPx);
|
|
27225
|
+
const columnWidthTwips = clampColumnWidthTwips(pixelsToTwips(rawColumnWidthPx));
|
|
27226
|
+
const fallbackColumnWidthPx = twipsToPixels(columnWidthTwips);
|
|
27227
|
+
return {
|
|
27228
|
+
grid: createFallbackGrid(columnCount, columnWidthTwips),
|
|
27229
|
+
columnWidths: Array(columnCount).fill(fallbackColumnWidthPx)
|
|
27230
|
+
};
|
|
27231
|
+
};
|
|
27170
27232
|
const XML_NODE_NAME$9 = "w:tbl";
|
|
27171
27233
|
const SD_NODE_NAME$9 = "table";
|
|
27172
27234
|
const encode$g = (params, encodedAttrs) => {
|
|
@@ -27186,7 +27248,6 @@ const encode$g = (params, encodedAttrs) => {
|
|
|
27186
27248
|
"justification",
|
|
27187
27249
|
"tableLayout",
|
|
27188
27250
|
["tableIndent", ({ value, type: type2 }) => ({ width: twipsToPixels(value), type: type2 })],
|
|
27189
|
-
["tableWidth", ({ value, type: type2 }) => ({ width: twipsToPixels(value), type: type2 })],
|
|
27190
27251
|
["tableCellSpacing", ({ value, type: type2 }) => ({ w: String(value), type: type2 })]
|
|
27191
27252
|
].forEach((prop) => {
|
|
27192
27253
|
let key;
|
|
@@ -27204,6 +27265,21 @@ const encode$g = (params, encodedAttrs) => {
|
|
|
27204
27265
|
if (encodedAttrs.tableCellSpacing) {
|
|
27205
27266
|
encodedAttrs["borderCollapse"] = "separate";
|
|
27206
27267
|
}
|
|
27268
|
+
if (encodedAttrs.tableProperties?.tableWidth) {
|
|
27269
|
+
const tableWidthMeasurement = encodedAttrs.tableProperties.tableWidth;
|
|
27270
|
+
const widthPx = twipsToPixels(tableWidthMeasurement.value);
|
|
27271
|
+
if (widthPx != null) {
|
|
27272
|
+
encodedAttrs.tableWidth = {
|
|
27273
|
+
width: widthPx,
|
|
27274
|
+
type: tableWidthMeasurement.type
|
|
27275
|
+
};
|
|
27276
|
+
} else if (tableWidthMeasurement.type === "auto") {
|
|
27277
|
+
encodedAttrs.tableWidth = {
|
|
27278
|
+
width: 0,
|
|
27279
|
+
type: tableWidthMeasurement.type
|
|
27280
|
+
};
|
|
27281
|
+
}
|
|
27282
|
+
}
|
|
27207
27283
|
const { borders, rowBorders } = _processTableBorders(encodedAttrs.tableProperties?.borders || {});
|
|
27208
27284
|
const referencedStyles = _getReferencedTableStyles(encodedAttrs.tableStyleId, params);
|
|
27209
27285
|
if (referencedStyles?.cellMargins && !encodedAttrs.tableProperties?.cellMargins) {
|
|
@@ -27217,7 +27293,19 @@ const encode$g = (params, encodedAttrs) => {
|
|
|
27217
27293
|
const borderRowData = Object.assign({}, referencedStyles?.rowBorders || {}, rowBorders || {});
|
|
27218
27294
|
encodedAttrs["borders"] = borderData;
|
|
27219
27295
|
const tblStyleTag = tblPr?.elements?.find((el) => el.name === "w:tblStyle");
|
|
27220
|
-
|
|
27296
|
+
let columnWidths = Array.isArray(encodedAttrs["grid"]) ? encodedAttrs["grid"].map((item) => twipsToPixels(item.col)) : [];
|
|
27297
|
+
if (!columnWidths.length) {
|
|
27298
|
+
const fallback = buildFallbackGridForTable({
|
|
27299
|
+
params,
|
|
27300
|
+
rows,
|
|
27301
|
+
tableWidth: encodedAttrs.tableWidth,
|
|
27302
|
+
tableWidthMeasurement: encodedAttrs.tableProperties?.tableWidth
|
|
27303
|
+
});
|
|
27304
|
+
if (fallback) {
|
|
27305
|
+
encodedAttrs.grid = fallback.grid;
|
|
27306
|
+
columnWidths = fallback.columnWidths;
|
|
27307
|
+
}
|
|
27308
|
+
}
|
|
27221
27309
|
const content = [];
|
|
27222
27310
|
rows.forEach((row) => {
|
|
27223
27311
|
const result = translator$G.encode({
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { p as process$1, au as commonjsGlobal, B as Buffer, av as getDefaultExportFromCjs, aw as getContentTypesFromXml, ax as xmljs } from "./converter-
|
|
1
|
+
import { p as process$1, au as commonjsGlobal, B as Buffer, av as getDefaultExportFromCjs, aw as getContentTypesFromXml, ax as xmljs } from "./converter-D9kK7Smo.js";
|
|
2
2
|
function commonjsRequire(path) {
|
|
3
3
|
throw new Error('Could not dynamically require "' + path + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.');
|
|
4
4
|
}
|
|
@@ -12,9 +12,9 @@ var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "acce
|
|
|
12
12
|
var _Attribute_static, getGlobalAttributes_fn, getNodeAndMarksAttributes_fn, _Schema_static, createNodesSchema_fn, createMarksSchema_fn, _events, _ExtensionService_instances, setupExtensions_fn, attachEditorEvents_fn, _editor, _stateValidators, _xmlValidators, _requiredNodeTypes, _requiredMarkTypes, _SuperValidator_instances, initializeValidators_fn, collectValidatorRequirements_fn, analyzeDocument_fn, _commandService, _Editor_instances, initContainerElement_fn, init_fn, initRichText_fn, onFocus_fn, checkHeadless_fn, registerCopyHandler_fn, insertNewFileData_fn, registerPluginByNameIfNotExists_fn, createExtensionService_fn, createCommandService_fn, createConverter_fn, initMedia_fn, initFonts_fn, createSchema_fn, generatePmData_fn, createView_fn, onCollaborationReady_fn, initComments_fn, initPagination_fn, dispatchTransaction_fn, handleNodeSelection_fn, prepareDocumentForImport_fn, prepareDocumentForExport_fn, endCollaboration_fn, validateDocumentInit_fn, validateDocumentExport_fn, initDevTools_fn, _ListItemNodeView_instances, init_fn2, _FieldAnnotationView_instances, createAnnotation_fn, _AutoPageNumberNodeView_instances, renderDom_fn, scheduleUpdateNodeStyle_fn, _DocumentSectionView_instances, init_fn3, addToolTip_fn;
|
|
13
13
|
import * as Y from "yjs";
|
|
14
14
|
import { UndoManager, Item as Item$1, ContentType, Text as Text$1, XmlElement, encodeStateAsUpdate } from "yjs";
|
|
15
|
-
import { P as PluginKey, a as Plugin, M as Mapping, N as NodeSelection, S as Selection, T as TextSelection, b as Slice, D as DOMSerializer, F as Fragment, c as DOMParser$1, d as Mark$1, e as dropPoint, A as AllSelection, p as process$1, B as Buffer2, f as callOrGet, g as getExtensionConfigField, h as getMarkType, i as getMarksFromSelection, j as getNodeType, k as getSchemaTypeNameByName, l as Schema$1, m as cleanSchemaItem, n as canSplit, o as defaultBlockAt$1, q as liftTarget, r as canJoin, s as joinPoint, t as replaceStep$1, R as ReplaceAroundStep$1, u as isTextSelection, v as getMarkRange, w as isMarkActive, x as isNodeActive, y as deleteProps, z as processContent, C as ReplaceStep, E as NodeRange, G as findWrapping, L as ListHelpers, H as findParentNode, I as isMacOS, J as isIOS, K as getSchemaTypeByName, O as inputRulesPlugin, Q as TrackDeleteMarkName, U as TrackInsertMarkName, V as v4, W as TrackFormatMarkName, X as comments_module_events, Y as findMark, Z as objectIncludes, _ as AddMarkStep, $ as RemoveMarkStep, a0 as twipsToLines, a1 as pixelsToTwips, a2 as helpers, a3 as posToDOMRect, a4 as CommandService, a5 as SuperConverter, a6 as createDocument, a7 as createDocFromMarkdown, a8 as createDocFromHTML, a9 as EditorState, aa as hasSomeParentWithClass, ab as isActive, ac as unflattenListsInHtml, ad as parseSizeUnit, ae as minMax, af as getLineHeightValueString, ag as InputRule, ah as kebabCase, ai as findParentNodeClosestToPos, aj as getListItemStyleDefinitions, ak as docxNumberigHelpers, al as parseIndentElement, am as combineIndents, an as SelectionRange, ao as Transform, ap as isInTable$1, aq as generateDocxRandomId, ar as insertNewRelationship, as as updateDOMAttributes, at as htmlHandler } from "./converter-
|
|
15
|
+
import { P as PluginKey, a as Plugin, M as Mapping, N as NodeSelection, S as Selection, T as TextSelection, b as Slice, D as DOMSerializer, F as Fragment, c as DOMParser$1, d as Mark$1, e as dropPoint, A as AllSelection, p as process$1, B as Buffer2, f as callOrGet, g as getExtensionConfigField, h as getMarkType, i as getMarksFromSelection, j as getNodeType, k as getSchemaTypeNameByName, l as Schema$1, m as cleanSchemaItem, n as canSplit, o as defaultBlockAt$1, q as liftTarget, r as canJoin, s as joinPoint, t as replaceStep$1, R as ReplaceAroundStep$1, u as isTextSelection, v as getMarkRange, w as isMarkActive, x as isNodeActive, y as deleteProps, z as processContent, C as ReplaceStep, E as NodeRange, G as findWrapping, L as ListHelpers, H as findParentNode, I as isMacOS, J as isIOS, K as getSchemaTypeByName, O as inputRulesPlugin, Q as TrackDeleteMarkName, U as TrackInsertMarkName, V as v4, W as TrackFormatMarkName, X as comments_module_events, Y as findMark, Z as objectIncludes, _ as AddMarkStep, $ as RemoveMarkStep, a0 as twipsToLines, a1 as pixelsToTwips, a2 as helpers, a3 as posToDOMRect, a4 as CommandService, a5 as SuperConverter, a6 as createDocument, a7 as createDocFromMarkdown, a8 as createDocFromHTML, a9 as EditorState, aa as hasSomeParentWithClass, ab as isActive, ac as unflattenListsInHtml, ad as parseSizeUnit, ae as minMax, af as getLineHeightValueString, ag as InputRule, ah as kebabCase, ai as findParentNodeClosestToPos, aj as getListItemStyleDefinitions, ak as docxNumberigHelpers, al as parseIndentElement, am as combineIndents, an as SelectionRange, ao as Transform, ap as isInTable$1, aq as generateDocxRandomId, ar as insertNewRelationship, as as updateDOMAttributes, at as htmlHandler } from "./converter-D9kK7Smo.js";
|
|
16
16
|
import { ref, computed, createElementBlock, openBlock, withModifiers, Fragment as Fragment$1, renderList, normalizeClass, createCommentVNode, toDisplayString, createElementVNode, createApp } from "vue";
|
|
17
|
-
import { D as DocxZipper } from "./docx-zipper-
|
|
17
|
+
import { D as DocxZipper } from "./docx-zipper-D8HnWWpv.js";
|
|
18
18
|
var GOOD_LEAF_SIZE = 200;
|
|
19
19
|
var RopeSequence = function RopeSequence2() {
|
|
20
20
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { computed, createElementBlock, openBlock, createElementVNode, createCommentVNode, normalizeClass, normalizeStyle, ref, withKeys, unref, withModifiers, createBlock, toDisplayString, withDirectives, vModelText, nextTick, getCurrentInstance, createVNode, readonly, watch, onMounted, onBeforeUnmount, reactive, onBeforeMount, inject, onActivated, onDeactivated, createTextVNode, Fragment, Comment, defineComponent, provide, h, Teleport, toRef, renderSlot, isVNode, shallowRef, watchEffect, mergeProps, Transition, vShow, cloneVNode, Text, renderList, withCtx } from "vue";
|
|
2
|
-
import { p as process$1 } from "./converter-
|
|
3
|
-
import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-
|
|
2
|
+
import { p as process$1 } from "./converter-D9kK7Smo.js";
|
|
3
|
+
import { _ as _export_sfc, u as useHighContrastMode, g as global$1 } from "./editor-Ddkz97dH.js";
|
|
4
4
|
const sanitizeNumber = (value, defaultNumber) => {
|
|
5
5
|
let sanitized = value.replace(/[^0-9.]/g, "");
|
|
6
6
|
sanitized = parseFloat(sanitized);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { E } from "./chunks/editor-
|
|
2
|
-
import "./chunks/converter-
|
|
3
|
-
import "./chunks/docx-zipper-
|
|
1
|
+
import { E } from "./chunks/editor-Ddkz97dH.js";
|
|
2
|
+
import "./chunks/converter-D9kK7Smo.js";
|
|
3
|
+
import "./chunks/docx-zipper-D8HnWWpv.js";
|
|
4
4
|
export {
|
|
5
5
|
E as Editor
|
|
6
6
|
};
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export const DEFAULT_PAGE_WIDTH_TWIPS: 12240;
|
|
2
|
+
export const DEFAULT_PAGE_MARGIN_TWIPS: 1440;
|
|
3
|
+
export const DEFAULT_CONTENT_WIDTH_TWIPS: number;
|
|
4
|
+
export const MIN_COLUMN_WIDTH_TWIPS: number;
|
|
5
|
+
export function pctToPercent(value: any): number;
|
|
6
|
+
export function resolveContentWidthTwips(): number;
|
|
7
|
+
export function resolveMeasurementWidthPx(measurement: any): number;
|
|
8
|
+
export function countColumnsInRow(row: any): any;
|
|
9
|
+
export function buildFallbackGridForTable({ params, rows, tableWidth, tableWidthMeasurement }: {
|
|
10
|
+
params: Partial<import("@translator").SCDecoderConfig>;
|
|
11
|
+
rows: any[];
|
|
12
|
+
tableWidth?: {
|
|
13
|
+
width?: number | null;
|
|
14
|
+
};
|
|
15
|
+
tableWidthMeasurement?: {
|
|
16
|
+
value?: number;
|
|
17
|
+
type?: string;
|
|
18
|
+
};
|
|
19
|
+
}): {
|
|
20
|
+
grid: Array<{
|
|
21
|
+
col: number;
|
|
22
|
+
}>;
|
|
23
|
+
columnWidths: number[];
|
|
24
|
+
} | null;
|
|
@@ -9,14 +9,14 @@ var __privateGet = (obj, member, getter) => (__accessCheck(obj, member, "read fr
|
|
|
9
9
|
var __privateAdd = (obj, member, value) => member.has(obj) ? __typeError("Cannot add the same private member more than once") : member instanceof WeakSet ? member.add(obj) : member.set(obj, value);
|
|
10
10
|
var __privateMethod = (obj, member, method) => (__accessCheck(obj, member, "access private method"), method);
|
|
11
11
|
var _SuperToolbar_instances, initToolbarGroups_fn, _interceptedCommands, makeToolbarItems_fn, initDefaultFonts_fn, updateHighlightColors_fn, deactivateAll_fn, updateToolbarHistory_fn, runCommandWithArgumentOnly_fn;
|
|
12
|
-
import { av as getDefaultExportFromCjs, V as v4, T as TextSelection$1, v as getMarkRange, ay as vClickOutside, H as findParentNode, az as getActiveFormatting, ap as isInTable, aA as readFromClipboard, aB as handleClipboardPaste, aC as getFileObject, aD as runPropertyTranslators, aE as translator, aF as translator$1, aG as translator$2, aH as translator$3, aI as translator$4, aJ as translator$5, aK as translator$6, aL as translator$7, aM as translator$8, aN as translator$9, aO as translator$a, aP as translator$b, aQ as translator$c, aR as translator$d, aS as translator$e, aT as translator$f, aU as translator$g, aV as translator$h, aW as translator$i, aX as translator$j, aY as translator$k, aZ as translator$l, a_ as translator$m, a$ as translator$n, b0 as translator$o, b1 as translator$p, b2 as translator$q, b3 as translator$r, b4 as translator$s, b5 as translator$t, b6 as translator$u, b7 as translator$v, b8 as translator$w, b9 as translator$x, ba as translator$y, bb as translator$z, bc as translator$A, bd as translator$B, be as translator$C, bf as translator$D, bg as translator$E, bh as translator$F, bi as translator$G, bj as translator$H, bk as translator$I, bl as translator$J, bm as translator$K, bn as translator$L, bo as translator$M, bp as translator$N, bq as translator$O, br as translator$P, bs as translator$Q, bt as translator$R, bu as translator$S, bv as translator$T, bw as translator$U, bx as translator$V, by as translator$W, bz as translator$X, bA as translator$Y, bB as translator$Z, bC as translator$_, bD as translator$$, bE as translator$10, a as Plugin } from "./chunks/converter-
|
|
13
|
-
import { bF, a5, i, a2 } from "./chunks/converter-
|
|
14
|
-
import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as getFileOpener, d as checkAndProcessImage, r as replaceSelectionWithImagePlaceholder, e as uploadAndInsertImage, y as yUndoPluginKey, f as undoDepth, h as redoDepth, s as shouldBypassContextMenu, S as SlashMenuPluginKey, E as Editor, i as getStarterExtensions, P as Placeholder, j as getRichTextExtensions, M as Mark, k as Extension, A as Attribute, N as Node } from "./chunks/editor-
|
|
15
|
-
import { n, C, o, T, l, p, m } from "./chunks/editor-
|
|
12
|
+
import { av as getDefaultExportFromCjs, V as v4, T as TextSelection$1, v as getMarkRange, ay as vClickOutside, H as findParentNode, az as getActiveFormatting, ap as isInTable, aA as readFromClipboard, aB as handleClipboardPaste, aC as getFileObject, aD as runPropertyTranslators, aE as translator, aF as translator$1, aG as translator$2, aH as translator$3, aI as translator$4, aJ as translator$5, aK as translator$6, aL as translator$7, aM as translator$8, aN as translator$9, aO as translator$a, aP as translator$b, aQ as translator$c, aR as translator$d, aS as translator$e, aT as translator$f, aU as translator$g, aV as translator$h, aW as translator$i, aX as translator$j, aY as translator$k, aZ as translator$l, a_ as translator$m, a$ as translator$n, b0 as translator$o, b1 as translator$p, b2 as translator$q, b3 as translator$r, b4 as translator$s, b5 as translator$t, b6 as translator$u, b7 as translator$v, b8 as translator$w, b9 as translator$x, ba as translator$y, bb as translator$z, bc as translator$A, bd as translator$B, be as translator$C, bf as translator$D, bg as translator$E, bh as translator$F, bi as translator$G, bj as translator$H, bk as translator$I, bl as translator$J, bm as translator$K, bn as translator$L, bo as translator$M, bp as translator$N, bq as translator$O, br as translator$P, bs as translator$Q, bt as translator$R, bu as translator$S, bv as translator$T, bw as translator$U, bx as translator$V, by as translator$W, bz as translator$X, bA as translator$Y, bB as translator$Z, bC as translator$_, bD as translator$$, bE as translator$10, a as Plugin } from "./chunks/converter-D9kK7Smo.js";
|
|
13
|
+
import { bF, a5, i, a2 } from "./chunks/converter-D9kK7Smo.js";
|
|
14
|
+
import { _ as _export_sfc, u as useHighContrastMode, a as getQuickFormatList, b as generateLinkedStyleString, c as getFileOpener, d as checkAndProcessImage, r as replaceSelectionWithImagePlaceholder, e as uploadAndInsertImage, y as yUndoPluginKey, f as undoDepth, h as redoDepth, s as shouldBypassContextMenu, S as SlashMenuPluginKey, E as Editor, i as getStarterExtensions, P as Placeholder, j as getRichTextExtensions, M as Mark, k as Extension, A as Attribute, N as Node } from "./chunks/editor-Ddkz97dH.js";
|
|
15
|
+
import { n, C, o, T, l, p, m } from "./chunks/editor-Ddkz97dH.js";
|
|
16
16
|
import { ref, onMounted, createElementBlock, openBlock, normalizeClass, unref, Fragment, renderList, createElementVNode, withModifiers, toDisplayString, createCommentVNode, normalizeStyle, computed, watch, withDirectives, withKeys, vModelText, createTextVNode, createVNode, h, createApp, markRaw, nextTick, onBeforeUnmount, reactive, onUnmounted, renderSlot, shallowRef, createBlock, withCtx, resolveDynamicComponent, normalizeProps, guardReactiveProps } from "vue";
|
|
17
|
-
import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, m as magicWandIcon, p as plusIconSvg, a as trashIconSvg, l as linkIconSvg, b as tableIconSvg, c as scissorsIconSvg, d as copyIconSvg, e as pasteIconSvg, f as borderNoneIconSvg, g as arrowsToDotIconSvg, h as arrowsLeftRightIconSvg, w as wrenchIconSvg, u as useMessage, N as NSkeleton } from "./chunks/toolbar-
|
|
17
|
+
import { t as toolbarIcons, s as sanitizeNumber, T as Toolbar, m as magicWandIcon, p as plusIconSvg, a as trashIconSvg, l as linkIconSvg, b as tableIconSvg, c as scissorsIconSvg, d as copyIconSvg, e as pasteIconSvg, f as borderNoneIconSvg, g as arrowsToDotIconSvg, h as arrowsLeftRightIconSvg, w as wrenchIconSvg, u as useMessage, N as NSkeleton } from "./chunks/toolbar-BxjdbiUf.js";
|
|
18
18
|
import AIWriter from "./ai-writer.es.js";
|
|
19
|
-
import { D } from "./chunks/docx-zipper-
|
|
19
|
+
import { D } from "./chunks/docx-zipper-D8HnWWpv.js";
|
|
20
20
|
import { createZip } from "./file-zipper.es.js";
|
|
21
21
|
var eventemitter3 = { exports: {} };
|
|
22
22
|
var hasRequiredEventemitter3;
|
package/dist/super-editor.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const superEditor_es = require("./chunks/super-editor.es-
|
|
3
|
+
const superEditor_es = require("./chunks/super-editor.es-BDsfLrnI.cjs");
|
|
4
4
|
require("./chunks/vue-DWle4Cai.cjs");
|
|
5
5
|
exports.AIWriter = superEditor_es.AIWriter;
|
|
6
6
|
exports.AnnotatorHelpers = superEditor_es.AnnotatorHelpers;
|
package/dist/super-editor.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A, a, _, C, D, E, b, S, c, d, e, f, g, T, h, i, j, k, l, m, n, o, p, r, q } from "./chunks/super-editor.es-
|
|
1
|
+
import { A, a, _, C, D, E, b, S, c, d, e, f, g, T, h, i, j, k, l, m, n, o, p, r, q } from "./chunks/super-editor.es-CmQ5GChv.es.js";
|
|
2
2
|
import "./chunks/vue-CXxsqYcP.es.js";
|
|
3
3
|
export {
|
|
4
4
|
A as AIWriter,
|
package/dist/superdoc.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
3
|
-
const superEditor_es = require("./chunks/super-editor.es-
|
|
4
|
-
const superdoc = require("./chunks/index-
|
|
3
|
+
const superEditor_es = require("./chunks/super-editor.es-BDsfLrnI.cjs");
|
|
4
|
+
const superdoc = require("./chunks/index-BlNiELtW.cjs");
|
|
5
5
|
require("./chunks/vue-DWle4Cai.cjs");
|
|
6
6
|
require("./chunks/jszip-b7l8QkfH.cjs");
|
|
7
7
|
const blankDocx = require("./chunks/blank-docx-CPqX9RF5.cjs");
|
package/dist/superdoc.es.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a, E, b, S, d, i, j, n, r, p, q } from "./chunks/super-editor.es-
|
|
2
|
-
import { D, H, P, S as S2, m, l } from "./chunks/index-
|
|
1
|
+
import { a, E, b, S, d, i, j, n, r, p, q } from "./chunks/super-editor.es-CmQ5GChv.es.js";
|
|
2
|
+
import { D, H, P, S as S2, m, l } from "./chunks/index-Cvi1utmk.es.js";
|
|
3
3
|
import "./chunks/vue-CXxsqYcP.es.js";
|
|
4
4
|
import "./chunks/jszip-B8KIZSNe.es.js";
|
|
5
5
|
import { B } from "./chunks/blank-docx-iwdyG9RH.es.js";
|