superdoc 2.12.0-next.14 → 2.12.0-next.15
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-D3_JSfLV.es.js → create-super-doc-ui-Biwv0tas.es.js} +17 -12
- package/dist/chunks/{create-super-doc-ui-D8QSZN4i.cjs → create-super-doc-ui-BkDVQgqj.cjs} +17 -12
- package/dist/collaboration-upgrade-engine.cjs +1 -1
- package/dist/collaboration-upgrade-engine.es.js +1 -1
- 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/public/ui/types.d.ts +16 -0
- package/dist/superdoc.cjs +4 -4
- package/dist/superdoc.es.js +4 -4
- package/dist-cdn/superdoc.min.js +35 -35
- package/package.json +1 -1
package/dist/chunks/{create-super-doc-ui-D3_JSfLV.es.js → create-super-doc-ui-Biwv0tas.es.js}
RENAMED
|
@@ -4071,8 +4071,11 @@ function createSuperDocUI(options) {
|
|
|
4071
4071
|
const incompleteTrackChangesDirectoryReadTokens = /* @__PURE__ */ new Map();
|
|
4072
4072
|
const postSourceCompletionRefreshTokens = /* @__PURE__ */ new Map();
|
|
4073
4073
|
let sourceCompletionObservedToken = null;
|
|
4074
|
-
|
|
4075
|
-
|
|
4074
|
+
const directoryLeaseCounts = {
|
|
4075
|
+
comments: 0,
|
|
4076
|
+
trackChanges: 0,
|
|
4077
|
+
contentControls: 0
|
|
4078
|
+
};
|
|
4076
4079
|
const demandHeavyDocRead = (key) => {
|
|
4077
4080
|
const token = contentToken();
|
|
4078
4081
|
if (demandedHeavyReads.get(key) === token) return;
|
|
@@ -4107,16 +4110,14 @@ function createSuperDocUI(options) {
|
|
|
4107
4110
|
if (invalidated) scheduleAsyncRefresh();
|
|
4108
4111
|
};
|
|
4109
4112
|
const acquireDirectoryLease = (family) => {
|
|
4110
|
-
|
|
4111
|
-
else trackChangesDirectoryLeaseCount += 1;
|
|
4113
|
+
directoryLeaseCounts[family] += 1;
|
|
4112
4114
|
demandHeavyDocRead(family);
|
|
4113
4115
|
let released = false;
|
|
4114
4116
|
return () => {
|
|
4115
4117
|
if (released) return;
|
|
4116
4118
|
released = true;
|
|
4117
|
-
|
|
4118
|
-
|
|
4119
|
-
if ((family === "comments" ? commentsDirectoryLeaseCount : trackChangesDirectoryLeaseCount) === 0 && demandedHeavyReads.get(family) === contentToken()) demandedHeavyReads.delete(family);
|
|
4119
|
+
directoryLeaseCounts[family] = Math.max(0, directoryLeaseCounts[family] - 1);
|
|
4120
|
+
if (directoryLeaseCounts[family] === 0 && demandedHeavyReads.get(family) === contentToken()) demandedHeavyReads.delete(family);
|
|
4120
4121
|
scheduleAsyncRefresh();
|
|
4121
4122
|
};
|
|
4122
4123
|
};
|
|
@@ -4887,7 +4888,7 @@ function createSuperDocUI(options) {
|
|
|
4887
4888
|
const activeIds = selection.activeCommentIds;
|
|
4888
4889
|
const directory = asyncReads.get("comments");
|
|
4889
4890
|
const directoryItems = directory?.token === contentToken() && directory.hasSettled && Array.isArray(directory.value) ? directory.value : null;
|
|
4890
|
-
const activeValidationItems =
|
|
4891
|
+
const activeValidationItems = directoryLeaseCounts.comments > 0 ? directoryItems : items;
|
|
4891
4892
|
if (explicitActiveCommentId && activeValidationItems && !activeValidationItems.some((item) => readEntityId(item) === explicitActiveCommentId)) explicitActiveCommentId = null;
|
|
4892
4893
|
const activeId = explicitActiveCommentId ?? activeIds[0] ?? null;
|
|
4893
4894
|
return {
|
|
@@ -4962,7 +4963,7 @@ function createSuperDocUI(options) {
|
|
|
4962
4963
|
if (active && !pendingTrackChangeRevealFocuses.has(active)) {
|
|
4963
4964
|
const directory = asyncReads.get("trackChanges");
|
|
4964
4965
|
const directoryItems = directory?.token === token && directory.hasSettled && Array.isArray(directory.value) ? filterPostDecisionTrackChanges(projectTrackChangesItems(directory.value), postDecisionIds) : null;
|
|
4965
|
-
const activeValidationItems =
|
|
4966
|
+
const activeValidationItems = directoryLeaseCounts.trackChanges > 0 ? directoryItems : active.story ? allStoryItems : items;
|
|
4966
4967
|
if (activeValidationItems && !activeValidationItems.some((row) => entityRowMatchesRequest(row, active.id, active.story))) setExplicitActiveChange(null);
|
|
4967
4968
|
}
|
|
4968
4969
|
const publicIdItems = allStoryItems ?? items;
|
|
@@ -9742,12 +9743,16 @@ function createSuperDocUI(options) {
|
|
|
9742
9743
|
const findContentControl = (id) => {
|
|
9743
9744
|
return contentControlsSub.get().items.find((item) => item?.id === id) ?? null;
|
|
9744
9745
|
};
|
|
9745
|
-
const contentControlsSnap =
|
|
9746
|
+
const contentControlsSnap = directorySnapshotHandle(contentControlsSub, select((s) => {
|
|
9747
|
+
if (directoryLeaseCounts.contentControls > 0) demandHeavyDocRead("contentControls");
|
|
9748
|
+
return s.contentControls;
|
|
9749
|
+
}), "contentControls");
|
|
9746
9750
|
const contentControlsGet = ((input) => {
|
|
9747
9751
|
if (input === void 0) return contentControlsSnap.get();
|
|
9748
9752
|
const id = readContentControlRequestId(input);
|
|
9749
9753
|
return id ? findContentControl(id) : null;
|
|
9750
9754
|
});
|
|
9755
|
+
const contentControlsPassiveSnap = snapshotHandle(contentControlsSub);
|
|
9751
9756
|
const contentControls = {
|
|
9752
9757
|
get: ((input) => {
|
|
9753
9758
|
if (input !== void 0) ensureContentControlsCatalog("api");
|
|
@@ -9756,6 +9761,7 @@ function createSuperDocUI(options) {
|
|
|
9756
9761
|
getSnapshot: contentControlsSnap.getSnapshot,
|
|
9757
9762
|
subscribe: contentControlsSnap.subscribe,
|
|
9758
9763
|
observe: contentControlsSnap.observe,
|
|
9764
|
+
observeActivePath: contentControlsPassiveSnap.observe,
|
|
9759
9765
|
list: () => {
|
|
9760
9766
|
ensureContentControlsCatalog("api");
|
|
9761
9767
|
return contentControlsSub.get().items;
|
|
@@ -10859,8 +10865,7 @@ function createSuperDocUI(options) {
|
|
|
10859
10865
|
if (detachSourceLoading) detachSourceLoading();
|
|
10860
10866
|
detachSourceLoading = null;
|
|
10861
10867
|
sourceLoadingSubscriptionHost = null;
|
|
10862
|
-
|
|
10863
|
-
trackChangesDirectoryLeaseCount = 0;
|
|
10868
|
+
for (const family of Object.keys(directoryLeaseCounts)) directoryLeaseCounts[family] = 0;
|
|
10864
10869
|
demandedHeavyReads.clear();
|
|
10865
10870
|
incompleteTrackChangesDirectoryReadTokens.clear();
|
|
10866
10871
|
postSourceCompletionRefreshTokens.clear();
|
|
@@ -4071,8 +4071,11 @@ function createSuperDocUI(options) {
|
|
|
4071
4071
|
const incompleteTrackChangesDirectoryReadTokens = /* @__PURE__ */ new Map();
|
|
4072
4072
|
const postSourceCompletionRefreshTokens = /* @__PURE__ */ new Map();
|
|
4073
4073
|
let sourceCompletionObservedToken = null;
|
|
4074
|
-
|
|
4075
|
-
|
|
4074
|
+
const directoryLeaseCounts = {
|
|
4075
|
+
comments: 0,
|
|
4076
|
+
trackChanges: 0,
|
|
4077
|
+
contentControls: 0
|
|
4078
|
+
};
|
|
4076
4079
|
const demandHeavyDocRead = (key) => {
|
|
4077
4080
|
const token = contentToken();
|
|
4078
4081
|
if (demandedHeavyReads.get(key) === token) return;
|
|
@@ -4107,16 +4110,14 @@ function createSuperDocUI(options) {
|
|
|
4107
4110
|
if (invalidated) scheduleAsyncRefresh();
|
|
4108
4111
|
};
|
|
4109
4112
|
const acquireDirectoryLease = (family) => {
|
|
4110
|
-
|
|
4111
|
-
else trackChangesDirectoryLeaseCount += 1;
|
|
4113
|
+
directoryLeaseCounts[family] += 1;
|
|
4112
4114
|
demandHeavyDocRead(family);
|
|
4113
4115
|
let released = false;
|
|
4114
4116
|
return () => {
|
|
4115
4117
|
if (released) return;
|
|
4116
4118
|
released = true;
|
|
4117
|
-
|
|
4118
|
-
|
|
4119
|
-
if ((family === "comments" ? commentsDirectoryLeaseCount : trackChangesDirectoryLeaseCount) === 0 && demandedHeavyReads.get(family) === contentToken()) demandedHeavyReads.delete(family);
|
|
4119
|
+
directoryLeaseCounts[family] = Math.max(0, directoryLeaseCounts[family] - 1);
|
|
4120
|
+
if (directoryLeaseCounts[family] === 0 && demandedHeavyReads.get(family) === contentToken()) demandedHeavyReads.delete(family);
|
|
4120
4121
|
scheduleAsyncRefresh();
|
|
4121
4122
|
};
|
|
4122
4123
|
};
|
|
@@ -4887,7 +4888,7 @@ function createSuperDocUI(options) {
|
|
|
4887
4888
|
const activeIds = selection.activeCommentIds;
|
|
4888
4889
|
const directory = asyncReads.get("comments");
|
|
4889
4890
|
const directoryItems = directory?.token === contentToken() && directory.hasSettled && Array.isArray(directory.value) ? directory.value : null;
|
|
4890
|
-
const activeValidationItems =
|
|
4891
|
+
const activeValidationItems = directoryLeaseCounts.comments > 0 ? directoryItems : items;
|
|
4891
4892
|
if (explicitActiveCommentId && activeValidationItems && !activeValidationItems.some((item) => readEntityId(item) === explicitActiveCommentId)) explicitActiveCommentId = null;
|
|
4892
4893
|
const activeId = explicitActiveCommentId ?? activeIds[0] ?? null;
|
|
4893
4894
|
return {
|
|
@@ -4962,7 +4963,7 @@ function createSuperDocUI(options) {
|
|
|
4962
4963
|
if (active && !pendingTrackChangeRevealFocuses.has(active)) {
|
|
4963
4964
|
const directory = asyncReads.get("trackChanges");
|
|
4964
4965
|
const directoryItems = directory?.token === token && directory.hasSettled && Array.isArray(directory.value) ? filterPostDecisionTrackChanges(projectTrackChangesItems(directory.value), postDecisionIds) : null;
|
|
4965
|
-
const activeValidationItems =
|
|
4966
|
+
const activeValidationItems = directoryLeaseCounts.trackChanges > 0 ? directoryItems : active.story ? allStoryItems : items;
|
|
4966
4967
|
if (activeValidationItems && !activeValidationItems.some((row) => entityRowMatchesRequest(row, active.id, active.story))) setExplicitActiveChange(null);
|
|
4967
4968
|
}
|
|
4968
4969
|
const publicIdItems = allStoryItems ?? items;
|
|
@@ -9742,12 +9743,16 @@ function createSuperDocUI(options) {
|
|
|
9742
9743
|
const findContentControl = (id) => {
|
|
9743
9744
|
return contentControlsSub.get().items.find((item) => item?.id === id) ?? null;
|
|
9744
9745
|
};
|
|
9745
|
-
const contentControlsSnap =
|
|
9746
|
+
const contentControlsSnap = directorySnapshotHandle(contentControlsSub, select((s) => {
|
|
9747
|
+
if (directoryLeaseCounts.contentControls > 0) demandHeavyDocRead("contentControls");
|
|
9748
|
+
return s.contentControls;
|
|
9749
|
+
}), "contentControls");
|
|
9746
9750
|
const contentControlsGet = ((input) => {
|
|
9747
9751
|
if (input === void 0) return contentControlsSnap.get();
|
|
9748
9752
|
const id = readContentControlRequestId(input);
|
|
9749
9753
|
return id ? findContentControl(id) : null;
|
|
9750
9754
|
});
|
|
9755
|
+
const contentControlsPassiveSnap = snapshotHandle(contentControlsSub);
|
|
9751
9756
|
const contentControls = {
|
|
9752
9757
|
get: ((input) => {
|
|
9753
9758
|
if (input !== void 0) ensureContentControlsCatalog("api");
|
|
@@ -9756,6 +9761,7 @@ function createSuperDocUI(options) {
|
|
|
9756
9761
|
getSnapshot: contentControlsSnap.getSnapshot,
|
|
9757
9762
|
subscribe: contentControlsSnap.subscribe,
|
|
9758
9763
|
observe: contentControlsSnap.observe,
|
|
9764
|
+
observeActivePath: contentControlsPassiveSnap.observe,
|
|
9759
9765
|
list: () => {
|
|
9760
9766
|
ensureContentControlsCatalog("api");
|
|
9761
9767
|
return contentControlsSub.get().items;
|
|
@@ -10859,8 +10865,7 @@ function createSuperDocUI(options) {
|
|
|
10859
10865
|
if (detachSourceLoading) detachSourceLoading();
|
|
10860
10866
|
detachSourceLoading = null;
|
|
10861
10867
|
sourceLoadingSubscriptionHost = null;
|
|
10862
|
-
|
|
10863
|
-
trackChangesDirectoryLeaseCount = 0;
|
|
10868
|
+
for (const family of Object.keys(directoryLeaseCounts)) directoryLeaseCounts[family] = 0;
|
|
10864
10869
|
demandedHeavyReads.clear();
|
|
10865
10870
|
incompleteTrackChangesDirectoryReadTokens.clear();
|
|
10866
10871
|
postSourceCompletionRefreshTokens.clear();
|
|
@@ -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.12.0-next.
|
|
22
|
+
superdocVersion: "2.12.0-next.15",
|
|
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.12.0-next.
|
|
21
|
+
superdocVersion: "2.12.0-next.15",
|
|
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
|
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-BkDVQgqj.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-Biwv0tas.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-BkDVQgqj.cjs");
|
|
3
3
|
const require_slice_source = require("../chunks/slice-source-CFaqq0Vo.cjs");
|
|
4
4
|
let 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-Biwv0tas.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-BkDVQgqj.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 { n as shallowEqual, r as BUILT_IN_COMMAND_IDS, t as createSuperDocUI } from "../chunks/create-super-doc-ui-
|
|
1
|
+
import { n as shallowEqual, r as BUILT_IN_COMMAND_IDS, t as createSuperDocUI } from "../chunks/create-super-doc-ui-Biwv0tas.es.js";
|
|
2
2
|
export { BUILT_IN_COMMAND_IDS, createSuperDocUI, shallowEqual };
|
|
@@ -1032,6 +1032,22 @@ export interface TrackChangesHandle extends SnapshotSubscribable<TrackChangesSli
|
|
|
1032
1032
|
}
|
|
1033
1033
|
/** Content-controls handle. */
|
|
1034
1034
|
export interface ContentControlsHandle extends SnapshotSubscribable<ContentControlsSlice> {
|
|
1035
|
+
/**
|
|
1036
|
+
* Observe the document-wide content-control catalog and active field IDs.
|
|
1037
|
+
* The catalog remains requested until the returned disposer runs.
|
|
1038
|
+
*/
|
|
1039
|
+
observe(listener: (snapshot: ContentControlsSlice) => void): () => void;
|
|
1040
|
+
/**
|
|
1041
|
+
* Observe the passive content-controls slice without requesting the
|
|
1042
|
+
* document-wide catalog. Meant for consumers that only need the active
|
|
1043
|
+
* field path, such as the core active-change event bridge; a field panel
|
|
1044
|
+
* should use {@link observe}.
|
|
1045
|
+
*/
|
|
1046
|
+
observeActivePath(listener: (snapshot: ContentControlsSlice) => void): () => void;
|
|
1047
|
+
/** Event-shaped alias of {@link observe}. */
|
|
1048
|
+
subscribe(listener: (event: {
|
|
1049
|
+
snapshot: ContentControlsSlice;
|
|
1050
|
+
}) => void): () => void;
|
|
1035
1051
|
/** Read the current content-controls snapshot. */
|
|
1036
1052
|
getSnapshot(): ContentControlsSlice;
|
|
1037
1053
|
/** Read the current content-controls snapshot. */
|
package/dist/superdoc.cjs
CHANGED
|
@@ -4,7 +4,7 @@ const require_blank_docx = require("./chunks/blank-docx-BuFAbRjs.cjs");
|
|
|
4
4
|
const require_eventemitter3 = require("./chunks/eventemitter3-C_TAnXOl.cjs");
|
|
5
5
|
const require_uuid = require("./chunks/uuid-BhG0ngwk.cjs");
|
|
6
6
|
const require_jszip = require("./chunks/jszip-D8mAFF-r.cjs");
|
|
7
|
-
const require_create_super_doc_ui = require("./chunks/create-super-doc-ui-
|
|
7
|
+
const require_create_super_doc_ui = require("./chunks/create-super-doc-ui-BkDVQgqj.cjs");
|
|
8
8
|
const require__plugin_vue_export_helper = require("./chunks/_plugin-vue_export-helper-SDR04tiH.cjs");
|
|
9
9
|
const require_constants = require("./chunks/constants-DpXuDx_g.cjs");
|
|
10
10
|
let vue = require("vue");
|
|
@@ -316,7 +316,7 @@ var shuffleArray = (array) => {
|
|
|
316
316
|
var DEFAULT_ENDPOINT = "https://ingest.superdoc.dev/v1/collect";
|
|
317
317
|
function getSuperdocVersion() {
|
|
318
318
|
try {
|
|
319
|
-
return "2.12.0-next.
|
|
319
|
+
return "2.12.0-next.15";
|
|
320
320
|
} catch {
|
|
321
321
|
return "unknown";
|
|
322
322
|
}
|
|
@@ -45328,7 +45328,7 @@ var SuperDoc = class extends require_eventemitter3.import_eventemitter3.default
|
|
|
45328
45328
|
this.config.colors = shuffleArray(this.config.colors);
|
|
45329
45329
|
this.userColorMap = /* @__PURE__ */ new Map();
|
|
45330
45330
|
this.colorIndex = 0;
|
|
45331
|
-
this.version = "2.12.0-next.
|
|
45331
|
+
this.version = "2.12.0-next.15";
|
|
45332
45332
|
this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
|
|
45333
45333
|
this.superdocId = config.superdocId || require_uuid.v4();
|
|
45334
45334
|
this.colors = this.config.colors ?? [];
|
|
@@ -45497,7 +45497,7 @@ var SuperDoc = class extends require_eventemitter3.import_eventemitter3.default
|
|
|
45497
45497
|
this.#pendingContentControlInputSource = null;
|
|
45498
45498
|
this.#pendingContentControlInputExpiresAt = null;
|
|
45499
45499
|
});
|
|
45500
|
-
contentControlsUnsub = this.#ui.contentControls.
|
|
45500
|
+
contentControlsUnsub = this.#ui.contentControls.observeActivePath((snapshot) => {
|
|
45501
45501
|
const editor = this.activeEditor;
|
|
45502
45502
|
const activePath = snapshot.activeIds.map((id) => toContentControlRef(snapshot.items.find((item) => item.id === id)));
|
|
45503
45503
|
if (activePath.some((item) => item === null)) return;
|
package/dist/superdoc.es.js
CHANGED
|
@@ -3,7 +3,7 @@ import { t as blank_default } from "./chunks/blank-docx-DzQccOlW.es.js";
|
|
|
3
3
|
import { t as import_eventemitter3 } from "./chunks/eventemitter3-DEIiXiH2.es.js";
|
|
4
4
|
import { t as v4 } from "./chunks/uuid-H0Xcmmhy.es.js";
|
|
5
5
|
import { a as init_dist$1, i as global, n as init_dist$2, o as Buffer, r as process$1, s as init_dist, t as require_jszip_min } from "./chunks/jszip-BzJ3CyxR.es.js";
|
|
6
|
-
import { a as DOM_CLASS_NAMES, i as getV2TrackedChangeMutationImpact, t as createSuperDocUI } from "./chunks/create-super-doc-ui-
|
|
6
|
+
import { a as DOM_CLASS_NAMES, i as getV2TrackedChangeMutationImpact, t as createSuperDocUI } from "./chunks/create-super-doc-ui-Biwv0tas.es.js";
|
|
7
7
|
import { t as _plugin_vue_export_helper_default } from "./chunks/_plugin-vue_export-helper-BOaGB7Aw.es.js";
|
|
8
8
|
import { t as PDF_TO_CSS_UNITS } from "./chunks/constants-B6VBlmKp.es.js";
|
|
9
9
|
import * as Vue from "vue";
|
|
@@ -315,7 +315,7 @@ var shuffleArray = (array) => {
|
|
|
315
315
|
var DEFAULT_ENDPOINT = "https://ingest.superdoc.dev/v1/collect";
|
|
316
316
|
function getSuperdocVersion() {
|
|
317
317
|
try {
|
|
318
|
-
return "2.12.0-next.
|
|
318
|
+
return "2.12.0-next.15";
|
|
319
319
|
} catch {
|
|
320
320
|
return "unknown";
|
|
321
321
|
}
|
|
@@ -45259,7 +45259,7 @@ var SuperDoc = class extends import_eventemitter3.default {
|
|
|
45259
45259
|
this.config.colors = shuffleArray(this.config.colors);
|
|
45260
45260
|
this.userColorMap = /* @__PURE__ */ new Map();
|
|
45261
45261
|
this.colorIndex = 0;
|
|
45262
|
-
this.version = "2.12.0-next.
|
|
45262
|
+
this.version = "2.12.0-next.15";
|
|
45263
45263
|
this.#log("🦋 [superdoc] Using SuperDoc version:", this.version);
|
|
45264
45264
|
this.superdocId = config.superdocId || v4();
|
|
45265
45265
|
this.colors = this.config.colors ?? [];
|
|
@@ -45428,7 +45428,7 @@ var SuperDoc = class extends import_eventemitter3.default {
|
|
|
45428
45428
|
this.#pendingContentControlInputSource = null;
|
|
45429
45429
|
this.#pendingContentControlInputExpiresAt = null;
|
|
45430
45430
|
});
|
|
45431
|
-
contentControlsUnsub = this.#ui.contentControls.
|
|
45431
|
+
contentControlsUnsub = this.#ui.contentControls.observeActivePath((snapshot) => {
|
|
45432
45432
|
const editor = this.activeEditor;
|
|
45433
45433
|
const activePath = snapshot.activeIds.map((id) => toContentControlRef(snapshot.items.find((item) => item.id === id)));
|
|
45434
45434
|
if (activePath.some((item) => item === null)) return;
|