superdoc 2.23.1-next.1 → 2.23.1-next.3
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/{create-super-doc-ui-B8N_IUG2.es.js → create-super-doc-ui-DFNXiKvQ.es.js} +1 -0
- package/dist/chunks/{create-super-doc-ui-1uZB3O_w.cjs → create-super-doc-ui-D_FbXpOQ.cjs} +1 -0
- package/dist/collaboration-upgrade-engine.cjs +1 -1
- package/dist/collaboration-upgrade-engine.es.js +1 -1
- package/dist/layout-engine/painters/dom/src/runs/formatting-marks.d.ts +1 -0
- package/dist/layout-engine/painters/dom/src/web-flow/types.d.ts +1 -0
- package/dist/public/ui-react.cjs +1 -1
- package/dist/public/ui-react.es.js +1 -1
- package/dist/public/ui-vue.cjs +1 -1
- package/dist/public/ui-vue.es.js +1 -1
- package/dist/public/ui.cjs +1 -1
- package/dist/public/ui.es.js +1 -1
- package/dist/superdoc/src/core/SuperDoc.d.ts +1 -1
- package/dist/superdoc/src/core/editor-runtime/types.d.ts +1 -0
- package/dist/superdoc/src/core/editor-runtime/v2/v2-editor-runtime-adapter.d.ts +1 -0
- package/dist/superdoc.cjs +14 -4
- package/dist/superdoc.es.js +14 -4
- package/dist-cdn/superdoc.min.js +7 -7
- package/package.json +2 -2
|
@@ -19,7 +19,7 @@ var COLLABORATION_UPGRADE_ENGINE_MINIMUM_NODE_MAJOR = 20;
|
|
|
19
19
|
var PRIVATE_ENGINE_INFO = (0, _superdoc_docx_engine_collaboration_upgrade_engine.getCollaborationUpgradeEngineInfo)();
|
|
20
20
|
var ENGINE_INFO = Object.freeze({
|
|
21
21
|
...PRIVATE_ENGINE_INFO,
|
|
22
|
-
superdocVersion: "2.23.1-next.
|
|
22
|
+
superdocVersion: "2.23.1-next.3",
|
|
23
23
|
roomSchemaVersion: Object.freeze({ ...PRIVATE_ENGINE_INFO.roomSchemaVersion }),
|
|
24
24
|
supportedBundleVersions: SUPPORTED_COLLABORATION_UPGRADE_BUNDLE_VERSIONS,
|
|
25
25
|
supportedV1ReaderContractVersions: SUPPORTED_V1_READER_CONTRACT_VERSIONS
|
|
@@ -18,7 +18,7 @@ var COLLABORATION_UPGRADE_ENGINE_MINIMUM_NODE_MAJOR = 20;
|
|
|
18
18
|
var PRIVATE_ENGINE_INFO = getCollaborationUpgradeEngineInfo$1();
|
|
19
19
|
var ENGINE_INFO = Object.freeze({
|
|
20
20
|
...PRIVATE_ENGINE_INFO,
|
|
21
|
-
superdocVersion: "2.23.1-next.
|
|
21
|
+
superdocVersion: "2.23.1-next.3",
|
|
22
22
|
roomSchemaVersion: Object.freeze({ ...PRIVATE_ENGINE_INFO.roomSchemaVersion }),
|
|
23
23
|
supportedBundleVersions: SUPPORTED_COLLABORATION_UPGRADE_BUNDLE_VERSIONS,
|
|
24
24
|
supportedV1ReaderContractVersions: SUPPORTED_V1_READER_CONTRACT_VERSIONS
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import { Line, Run } from '../../../../contracts/src/index.js';
|
|
2
2
|
export declare const setTextContentWithFormattingSpaceMarks: (element: HTMLElement, text: string, doc: Document, showFormattingMarks: boolean) => void;
|
|
3
|
+
export declare const appendFormattingLineBreakMark: (lineEl: HTMLElement, line: Line, runs: Run[], lineIndex: number, leftOffsetPx: number, availableWidth: number, hasExplicitPositioning: boolean, doc: Document, showFormattingMarks: boolean) => void;
|
|
3
4
|
export declare const appendFormattingParagraphMark: (lineEl: HTMLElement, line: Line, runs: Run[], leftOffsetPx: number, availableWidth: number, hasExplicitPositioning: boolean, doc: Document, showFormattingMarks: boolean) => void;
|
|
@@ -8,6 +8,7 @@ export interface WebFlowPaintItem {
|
|
|
8
8
|
readonly layoutEpoch?: number;
|
|
9
9
|
readonly layoutIdentities?: readonly LayoutSourceIdentity[];
|
|
10
10
|
readonly editable?: boolean;
|
|
11
|
+
readonly showFormattingMarks?: boolean;
|
|
11
12
|
}
|
|
12
13
|
export type WebFlowPaintCommand = {
|
|
13
14
|
readonly kind: 'replace-all';
|
package/dist/public/ui-react.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-
|
|
2
|
+
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-D_FbXpOQ.cjs");
|
|
3
3
|
const require_slice_source = require("../chunks/slice-source-CFaqq0Vo.cjs");
|
|
4
4
|
let react = require("react");
|
|
5
5
|
//#region src/public/ui/react.ts
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-
|
|
1
|
+
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-DFNXiKvQ.es.js";
|
|
2
2
|
import { t as toSliceSource } from "../chunks/slice-source-gfOhG2MW.es.js";
|
|
3
3
|
import { createContext, createElement, useCallback, useContext, useEffect, useRef, useState } from "react";
|
|
4
4
|
//#region src/public/ui/react.ts
|
package/dist/public/ui-vue.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-
|
|
2
|
+
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-D_FbXpOQ.cjs");
|
|
3
3
|
const require_slice_source = require("../chunks/slice-source-CFaqq0Vo.cjs");
|
|
4
4
|
let superdoc_entry_vue = require("vue");
|
|
5
5
|
//#region src/public/ui/vue.ts
|
package/dist/public/ui-vue.es.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-
|
|
1
|
+
import { t as createSuperDocUI } from "../chunks/create-super-doc-ui-DFNXiKvQ.es.js";
|
|
2
2
|
import { t as toSliceSource } from "../chunks/slice-source-gfOhG2MW.es.js";
|
|
3
3
|
import { computed, inject, onScopeDispose, provide, shallowRef, toRaw, toValue, watch } from "vue";
|
|
4
4
|
//#region src/public/ui/vue.ts
|
package/dist/public/ui.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-
|
|
2
|
+
const require_create_super_doc_ui = require("../chunks/create-super-doc-ui-D_FbXpOQ.cjs");
|
|
3
3
|
exports.BUILT_IN_COMMAND_IDS = require_create_super_doc_ui.BUILT_IN_COMMAND_IDS;
|
|
4
4
|
exports.createSuperDocUI = require_create_super_doc_ui.createSuperDocUI;
|
|
5
5
|
exports.shallowEqual = require_create_super_doc_ui.shallowEqual;
|
package/dist/public/ui.es.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as BUILT_IN_COMMAND_IDS, t as createSuperDocUI, u as shallowEqual } from "../chunks/create-super-doc-ui-
|
|
1
|
+
import { a as BUILT_IN_COMMAND_IDS, t as createSuperDocUI, u as shallowEqual } from "../chunks/create-super-doc-ui-DFNXiKvQ.es.js";
|
|
2
2
|
export { BUILT_IN_COMMAND_IDS, createSuperDocUI, shallowEqual };
|
|
@@ -571,7 +571,7 @@ export declare class SuperDoc extends EventEmitter<SuperDocEventMap> {
|
|
|
571
571
|
*/
|
|
572
572
|
setShowBookmarks(show?: boolean): void;
|
|
573
573
|
/**
|
|
574
|
-
* Toggle nonprinting formatting marks (spaces, tabs, paragraph marks) in the
|
|
574
|
+
* Toggle nonprinting formatting marks (spaces, tabs, paragraph marks and manual line breaks) in the
|
|
575
575
|
* rendered layout. This is a view-only setting and is not exported to DOCX.
|
|
576
576
|
*/
|
|
577
577
|
setShowFormattingMarks(show?: boolean): void;
|
|
@@ -387,6 +387,7 @@ export interface EditorRuntime {
|
|
|
387
387
|
mode?: 'review' | 'original' | 'final' | 'off';
|
|
388
388
|
enabled?: boolean;
|
|
389
389
|
}): void;
|
|
390
|
+
setShowFormattingMarks(show: boolean): void;
|
|
390
391
|
/**
|
|
391
392
|
* Temporary compatibility path backing `SuperDoc.activeEditor`,
|
|
392
393
|
* `doc.getEditor()`, and existing public-ish callers. The v2 runtime returns
|
|
@@ -162,6 +162,7 @@ interface ModeAwareHostLike {
|
|
|
162
162
|
mode?: 'review' | 'original' | 'final' | 'off';
|
|
163
163
|
enabled?: boolean;
|
|
164
164
|
}): void;
|
|
165
|
+
setShowFormattingMarks(show: boolean): void;
|
|
165
166
|
dispatch(command: HostCommandLike): Promise<HostDispatchResultLike>;
|
|
166
167
|
save(options?: {
|
|
167
168
|
format?: 'docx';
|
package/dist/superdoc.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
2
|
const require_rolldown_runtime = require("./chunks/rolldown-runtime-74VwNCz7.cjs");
|
|
3
3
|
const require_blank_docx = require("./chunks/blank-docx-BuFAbRjs.cjs");
|
|
4
|
-
const require_create_super_doc_ui = require("./chunks/create-super-doc-ui-
|
|
4
|
+
const require_create_super_doc_ui = require("./chunks/create-super-doc-ui-D_FbXpOQ.cjs");
|
|
5
5
|
const require_eventemitter3 = require("./chunks/eventemitter3-C_TAnXOl.cjs");
|
|
6
6
|
const require_uuid = require("./chunks/uuid-BhG0ngwk.cjs");
|
|
7
7
|
const require__plugin_vue_export_helper = require("./chunks/_plugin-vue_export-helper-CYxINHh_.cjs");
|
|
@@ -304,7 +304,7 @@ var awarenessStatesToArray = (context, states) => {
|
|
|
304
304
|
var DEFAULT_ENDPOINT = "https://ingest.superdoc.dev/v1/collect";
|
|
305
305
|
function getSuperdocVersion() {
|
|
306
306
|
try {
|
|
307
|
-
return "2.23.1-next.
|
|
307
|
+
return "2.23.1-next.3";
|
|
308
308
|
} catch {
|
|
309
309
|
return "unknown";
|
|
310
310
|
}
|
|
@@ -20778,6 +20778,9 @@ function createV2EditorRuntimeAdapter(options) {
|
|
|
20778
20778
|
setTrackedChangesRenderOptions(options) {
|
|
20779
20779
|
host.setTrackedChangesRenderOptions(options);
|
|
20780
20780
|
},
|
|
20781
|
+
setShowFormattingMarks(show) {
|
|
20782
|
+
host.setShowFormattingMarks(show);
|
|
20783
|
+
},
|
|
20781
20784
|
getLegacyEditorProjection: () => getLegacyEditorProjection?.() ?? DEFAULT_V2_LEGACY_PROJECTION,
|
|
20782
20785
|
focus,
|
|
20783
20786
|
dispose,
|
|
@@ -46469,7 +46472,7 @@ var SuperDoc = class extends require_eventemitter3.import_eventemitter3.default
|
|
|
46469
46472
|
}
|
|
46470
46473
|
this.userColorMap = /* @__PURE__ */ new Map();
|
|
46471
46474
|
this.colorIndex = 0;
|
|
46472
|
-
this.version = "2.23.1-next.
|
|
46475
|
+
this.version = "2.23.1-next.3";
|
|
46473
46476
|
this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
|
|
46474
46477
|
this.superdocId = config.superdocId || require_uuid.v4();
|
|
46475
46478
|
this.colors = this.config.colors ?? [];
|
|
@@ -47916,6 +47919,8 @@ var SuperDoc = class extends require_eventemitter3.import_eventemitter3.default
|
|
|
47916
47919
|
*/
|
|
47917
47920
|
registerEditorRuntime(runtime) {
|
|
47918
47921
|
this.#editorRuntimeRegistry.register(runtime);
|
|
47922
|
+
const show = this.config.layoutEngineOptions?.showFormattingMarks;
|
|
47923
|
+
if (typeof show === "boolean") runtime.setShowFormattingMarks(show);
|
|
47919
47924
|
}
|
|
47920
47925
|
/**
|
|
47921
47926
|
* Unregister a mounted editor runtime by id. If it was active, active state
|
|
@@ -48160,7 +48165,7 @@ var SuperDoc = class extends require_eventemitter3.import_eventemitter3.default
|
|
|
48160
48165
|
});
|
|
48161
48166
|
}
|
|
48162
48167
|
/**
|
|
48163
|
-
* Toggle nonprinting formatting marks (spaces, tabs, paragraph marks) in the
|
|
48168
|
+
* Toggle nonprinting formatting marks (spaces, tabs, paragraph marks and manual line breaks) in the
|
|
48164
48169
|
* rendered layout. This is a view-only setting and is not exported to DOCX.
|
|
48165
48170
|
*/
|
|
48166
48171
|
setShowFormattingMarks(show = true) {
|
|
@@ -48169,6 +48174,11 @@ var SuperDoc = class extends require_eventemitter3.import_eventemitter3.default
|
|
|
48169
48174
|
if (layoutOptions.showFormattingMarks === nextValue) return;
|
|
48170
48175
|
layoutOptions.showFormattingMarks = nextValue;
|
|
48171
48176
|
this.superdocStore?.documents?.forEach((doc) => {
|
|
48177
|
+
const runtimes = typeof doc.id === "string" ? this.#editorRuntimeRegistry.getAllByDocumentId(doc.id) : [];
|
|
48178
|
+
if (runtimes.length) {
|
|
48179
|
+
for (const runtime of runtimes) runtime.setShowFormattingMarks(nextValue);
|
|
48180
|
+
return;
|
|
48181
|
+
}
|
|
48172
48182
|
(doc.getDocumentRuntime?.())?.setShowFormattingMarks?.(nextValue);
|
|
48173
48183
|
});
|
|
48174
48184
|
this.emit("formatting-marks-change", {
|
package/dist/superdoc.es.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { i as __toESM$2 } from "./chunks/rolldown-runtime-0pSA04fp.es.js";
|
|
2
2
|
import { t as blank_default } from "./chunks/blank-docx-DzQccOlW.es.js";
|
|
3
|
-
import { c as createImageFilePicker, d as DOM_CLASS_NAMES, f as closeInteractionHistory, g as recordInteraction, h as isWorkflowRecordingEnabled, i as registerFirstPartyCommandMutation, l as resolveImageSrc, m as getWorkflowRecording, n as executeFirstPartyCommandAsync, o as applyV2CommentInvalidationFromMutation, p as createInteractionHistory, r as readFirstPartyPageNumbers, s as getV2TrackedChangeMutationImpact, t as createSuperDocUI } from "./chunks/create-super-doc-ui-
|
|
3
|
+
import { c as createImageFilePicker, d as DOM_CLASS_NAMES, f as closeInteractionHistory, g as recordInteraction, h as isWorkflowRecordingEnabled, i as registerFirstPartyCommandMutation, l as resolveImageSrc, m as getWorkflowRecording, n as executeFirstPartyCommandAsync, o as applyV2CommentInvalidationFromMutation, p as createInteractionHistory, r as readFirstPartyPageNumbers, s as getV2TrackedChangeMutationImpact, t as createSuperDocUI } from "./chunks/create-super-doc-ui-DFNXiKvQ.es.js";
|
|
4
4
|
import { t as import_eventemitter3 } from "./chunks/eventemitter3-DEIiXiH2.es.js";
|
|
5
5
|
import { t as v4 } from "./chunks/uuid-H0Xcmmhy.es.js";
|
|
6
6
|
import { $ as watch$1, A as onActivated, B as resolveDirective, C as isRef$1, D as normalizeClass, E as nextTick, F as openBlock, G as toRef, H as shallowRef$1, I as reactive, J as useAttrs, K as toRefs, L as ref, M as onDeactivated, N as onMounted, O as normalizeProps, P as onScopeDispose$1, Q as vModelText, R as renderList, S as isReactive$1, T as mergeProps, U as toDisplayString, V as resolveDynamicComponent, W as toRaw$2, X as vModelCheckbox, Y as useSlots, Z as vModelSelect, _ as getCurrentInstance, a as computed$1, b as hasInjectionContext, c as createCommentVNode, d as createStaticVNode, et as withCtx, f as createTextVNode, g as effectScope, h as defineComponent, i as Transition, j as onBeforeUnmount, k as normalizeStyle, l as createElementBlock, m as defineAsyncComponent, n as Fragment, nt as withKeys, o as createApp, p as createVNode, q as unref, r as Teleport, rt as withModifiers, s as createBlock, t as _plugin_vue_export_helper_default, tt as withDirectives, u as createElementVNode, v as getCurrentScope, w as markRaw, x as inject$1, y as h, z as renderSlot } from "./chunks/_plugin-vue_export-helper-DHiJKCsy.es.js";
|
|
@@ -302,7 +302,7 @@ var awarenessStatesToArray = (context, states) => {
|
|
|
302
302
|
var DEFAULT_ENDPOINT = "https://ingest.superdoc.dev/v1/collect";
|
|
303
303
|
function getSuperdocVersion() {
|
|
304
304
|
try {
|
|
305
|
-
return "2.23.1-next.
|
|
305
|
+
return "2.23.1-next.3";
|
|
306
306
|
} catch {
|
|
307
307
|
return "unknown";
|
|
308
308
|
}
|
|
@@ -20745,6 +20745,9 @@ function createV2EditorRuntimeAdapter(options) {
|
|
|
20745
20745
|
setTrackedChangesRenderOptions(options) {
|
|
20746
20746
|
host.setTrackedChangesRenderOptions(options);
|
|
20747
20747
|
},
|
|
20748
|
+
setShowFormattingMarks(show) {
|
|
20749
|
+
host.setShowFormattingMarks(show);
|
|
20750
|
+
},
|
|
20748
20751
|
getLegacyEditorProjection: () => getLegacyEditorProjection?.() ?? DEFAULT_V2_LEGACY_PROJECTION,
|
|
20749
20752
|
focus,
|
|
20750
20753
|
dispose,
|
|
@@ -46398,7 +46401,7 @@ var SuperDoc = class extends import_eventemitter3.default {
|
|
|
46398
46401
|
}
|
|
46399
46402
|
this.userColorMap = /* @__PURE__ */ new Map();
|
|
46400
46403
|
this.colorIndex = 0;
|
|
46401
|
-
this.version = "2.23.1-next.
|
|
46404
|
+
this.version = "2.23.1-next.3";
|
|
46402
46405
|
this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
|
|
46403
46406
|
this.superdocId = config.superdocId || v4();
|
|
46404
46407
|
this.colors = this.config.colors ?? [];
|
|
@@ -47845,6 +47848,8 @@ var SuperDoc = class extends import_eventemitter3.default {
|
|
|
47845
47848
|
*/
|
|
47846
47849
|
registerEditorRuntime(runtime) {
|
|
47847
47850
|
this.#editorRuntimeRegistry.register(runtime);
|
|
47851
|
+
const show = this.config.layoutEngineOptions?.showFormattingMarks;
|
|
47852
|
+
if (typeof show === "boolean") runtime.setShowFormattingMarks(show);
|
|
47848
47853
|
}
|
|
47849
47854
|
/**
|
|
47850
47855
|
* Unregister a mounted editor runtime by id. If it was active, active state
|
|
@@ -48089,7 +48094,7 @@ var SuperDoc = class extends import_eventemitter3.default {
|
|
|
48089
48094
|
});
|
|
48090
48095
|
}
|
|
48091
48096
|
/**
|
|
48092
|
-
* Toggle nonprinting formatting marks (spaces, tabs, paragraph marks) in the
|
|
48097
|
+
* Toggle nonprinting formatting marks (spaces, tabs, paragraph marks and manual line breaks) in the
|
|
48093
48098
|
* rendered layout. This is a view-only setting and is not exported to DOCX.
|
|
48094
48099
|
*/
|
|
48095
48100
|
setShowFormattingMarks(show = true) {
|
|
@@ -48098,6 +48103,11 @@ var SuperDoc = class extends import_eventemitter3.default {
|
|
|
48098
48103
|
if (layoutOptions.showFormattingMarks === nextValue) return;
|
|
48099
48104
|
layoutOptions.showFormattingMarks = nextValue;
|
|
48100
48105
|
this.superdocStore?.documents?.forEach((doc) => {
|
|
48106
|
+
const runtimes = typeof doc.id === "string" ? this.#editorRuntimeRegistry.getAllByDocumentId(doc.id) : [];
|
|
48107
|
+
if (runtimes.length) {
|
|
48108
|
+
for (const runtime of runtimes) runtime.setShowFormattingMarks(nextValue);
|
|
48109
|
+
return;
|
|
48110
|
+
}
|
|
48101
48111
|
(doc.getDocumentRuntime?.())?.setShowFormattingMarks?.(nextValue);
|
|
48102
48112
|
});
|
|
48103
48113
|
this.emit("formatting-marks-change", {
|