@superdoc-dev/mcp 0.7.0-next.24 → 0.7.0-next.25
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/index.js +61 -6
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -208797,7 +208797,7 @@ var init_remark_gfm_eZN6yzWQ_es = __esm(() => {
|
|
|
208797
208797
|
init_remark_gfm_BhnWr3yf_es();
|
|
208798
208798
|
});
|
|
208799
208799
|
|
|
208800
|
-
// ../../packages/superdoc/dist/chunks/src-
|
|
208800
|
+
// ../../packages/superdoc/dist/chunks/src-Tq4gtGIV.es.js
|
|
208801
208801
|
function deleteProps(obj, propOrProps) {
|
|
208802
208802
|
const props = typeof propOrProps === "string" ? [propOrProps] : propOrProps;
|
|
208803
208803
|
const removeNested = (target, pathParts, index2 = 0) => {
|
|
@@ -225155,6 +225155,15 @@ function listCommentAnchorsSafe(editor) {
|
|
|
225155
225155
|
return [];
|
|
225156
225156
|
}
|
|
225157
225157
|
}
|
|
225158
|
+
function emitCommentLifecycleUpdate(editor, type, comment2) {
|
|
225159
|
+
const emitter = editor.emit;
|
|
225160
|
+
if (typeof emitter !== "function")
|
|
225161
|
+
return;
|
|
225162
|
+
emitter.call(editor, "commentsUpdate", {
|
|
225163
|
+
type,
|
|
225164
|
+
comment: comment2
|
|
225165
|
+
});
|
|
225166
|
+
}
|
|
225158
225167
|
function applyTextSelection(editor, from$1, to) {
|
|
225159
225168
|
const setTextSelection$1 = editor.commands?.setTextSelection;
|
|
225160
225169
|
if (typeof setTextSelection$1 === "function") {
|
|
@@ -225643,17 +225652,20 @@ function resolveCommentHandler(editor, input2, options) {
|
|
|
225643
225652
|
message: "Comment is already resolved."
|
|
225644
225653
|
}
|
|
225645
225654
|
};
|
|
225655
|
+
let resolvedTimestamp = null;
|
|
225646
225656
|
if (executeDomainCommand(editor, () => {
|
|
225647
225657
|
const didResolve = resolveComment({
|
|
225648
225658
|
commentId: identity.commentId,
|
|
225649
225659
|
importedId: identity.importedId
|
|
225650
225660
|
});
|
|
225651
|
-
if (didResolve)
|
|
225661
|
+
if (didResolve) {
|
|
225662
|
+
resolvedTimestamp = Date.now();
|
|
225652
225663
|
upsertCommentEntity(store, identity.commentId, {
|
|
225653
225664
|
importedId: identity.importedId,
|
|
225654
225665
|
isDone: true,
|
|
225655
|
-
resolvedTime:
|
|
225666
|
+
resolvedTime: resolvedTimestamp
|
|
225656
225667
|
});
|
|
225668
|
+
}
|
|
225657
225669
|
return Boolean(didResolve);
|
|
225658
225670
|
}, { expectedRevision: options?.expectedRevision }).steps[0]?.effect !== "changed")
|
|
225659
225671
|
return {
|
|
@@ -225663,6 +225675,12 @@ function resolveCommentHandler(editor, input2, options) {
|
|
|
225663
225675
|
message: "Comment resolve produced no change."
|
|
225664
225676
|
}
|
|
225665
225677
|
};
|
|
225678
|
+
emitCommentLifecycleUpdate(editor, "resolved", {
|
|
225679
|
+
commentId: identity.commentId,
|
|
225680
|
+
importedId: identity.importedId,
|
|
225681
|
+
isDone: true,
|
|
225682
|
+
resolvedTime: resolvedTimestamp
|
|
225683
|
+
});
|
|
225666
225684
|
return {
|
|
225667
225685
|
success: true,
|
|
225668
225686
|
updated: [toCommentAddress(identity.commentId)]
|
|
@@ -225707,6 +225725,12 @@ function reopenCommentHandler(editor, input2, options) {
|
|
|
225707
225725
|
message: "Comment reopen produced no change."
|
|
225708
225726
|
}
|
|
225709
225727
|
};
|
|
225728
|
+
emitCommentLifecycleUpdate(editor, "update", {
|
|
225729
|
+
commentId: identity.commentId,
|
|
225730
|
+
importedId: identity.importedId,
|
|
225731
|
+
isDone: false,
|
|
225732
|
+
resolvedTime: null
|
|
225733
|
+
});
|
|
225710
225734
|
return {
|
|
225711
225735
|
success: true,
|
|
225712
225736
|
updated: [toCommentAddress(identity.commentId)]
|
|
@@ -225741,6 +225765,11 @@ function removeCommentHandler(editor, input2, options) {
|
|
|
225741
225765
|
}
|
|
225742
225766
|
if (!removedIds.size && didRemove)
|
|
225743
225767
|
removedIds.add(identity.commentId);
|
|
225768
|
+
for (const removedId of removedIds)
|
|
225769
|
+
emitCommentLifecycleUpdate(editor, "deleted", {
|
|
225770
|
+
commentId: removedId,
|
|
225771
|
+
importedId: removedId === identity.commentId ? identity.importedId : undefined
|
|
225772
|
+
});
|
|
225744
225773
|
return {
|
|
225745
225774
|
success: true,
|
|
225746
225775
|
removed: Array.from(removedIds).map((id2) => toCommentAddress(id2))
|
|
@@ -297187,7 +297216,7 @@ menclose::after {
|
|
|
297187
297216
|
return;
|
|
297188
297217
|
console.log(...args$1);
|
|
297189
297218
|
}, HEADER_FOOTER_INIT_BUDGET_MS = 200, MAX_ZOOM_WARNING_THRESHOLD = 10, MAX_SELECTION_RECTS_PER_USER = 100, SEMANTIC_RESIZE_DEBOUNCE_MS = 120, MIN_SEMANTIC_CONTENT_WIDTH_PX = 1, GLOBAL_PERFORMANCE, PresentationEditor, ICONS, TEXTS, tableActionsOptions;
|
|
297190
|
-
var
|
|
297219
|
+
var init_src_Tq4gtGIV_es = __esm(() => {
|
|
297191
297220
|
init_rolldown_runtime_Bg48TavK_es();
|
|
297192
297221
|
init_SuperConverter_BptSHzcb_es();
|
|
297193
297222
|
init_jszip_C49i9kUs_es();
|
|
@@ -335012,7 +335041,7 @@ var init_zipper_yaJVJ4z9_es = __esm(() => {
|
|
|
335012
335041
|
|
|
335013
335042
|
// ../../packages/superdoc/dist/super-editor.es.js
|
|
335014
335043
|
var init_super_editor_es = __esm(() => {
|
|
335015
|
-
|
|
335044
|
+
init_src_Tq4gtGIV_es();
|
|
335016
335045
|
init_SuperConverter_BptSHzcb_es();
|
|
335017
335046
|
init_jszip_C49i9kUs_es();
|
|
335018
335047
|
init_xml_js_CqGKpaft_es();
|
|
@@ -442781,6 +442810,12 @@ function listCommentAnchorsSafe2(editor) {
|
|
|
442781
442810
|
return [];
|
|
442782
442811
|
}
|
|
442783
442812
|
}
|
|
442813
|
+
function emitCommentLifecycleUpdate2(editor, type, comment2) {
|
|
442814
|
+
const emitter = editor.emit;
|
|
442815
|
+
if (typeof emitter !== "function")
|
|
442816
|
+
return;
|
|
442817
|
+
emitter.call(editor, "commentsUpdate", { type, comment: comment2 });
|
|
442818
|
+
}
|
|
442784
442819
|
function applyTextSelection2(editor, from4, to) {
|
|
442785
442820
|
const setTextSelection2 = editor.commands?.setTextSelection;
|
|
442786
442821
|
if (typeof setTextSelection2 === "function") {
|
|
@@ -443234,16 +443269,18 @@ function resolveCommentHandler2(editor, input2, options) {
|
|
|
443234
443269
|
failure: { code: "NO_OP", message: "Comment is already resolved." }
|
|
443235
443270
|
};
|
|
443236
443271
|
}
|
|
443272
|
+
let resolvedTimestamp = null;
|
|
443237
443273
|
const receipt2 = executeDomainCommand2(editor, () => {
|
|
443238
443274
|
const didResolve = resolveComment({
|
|
443239
443275
|
commentId: identity.commentId,
|
|
443240
443276
|
importedId: identity.importedId
|
|
443241
443277
|
});
|
|
443242
443278
|
if (didResolve) {
|
|
443279
|
+
resolvedTimestamp = Date.now();
|
|
443243
443280
|
upsertCommentEntity2(store, identity.commentId, {
|
|
443244
443281
|
importedId: identity.importedId,
|
|
443245
443282
|
isDone: true,
|
|
443246
|
-
resolvedTime:
|
|
443283
|
+
resolvedTime: resolvedTimestamp
|
|
443247
443284
|
});
|
|
443248
443285
|
}
|
|
443249
443286
|
return Boolean(didResolve);
|
|
@@ -443254,6 +443291,12 @@ function resolveCommentHandler2(editor, input2, options) {
|
|
|
443254
443291
|
failure: { code: "NO_OP", message: "Comment resolve produced no change." }
|
|
443255
443292
|
};
|
|
443256
443293
|
}
|
|
443294
|
+
emitCommentLifecycleUpdate2(editor, "resolved", {
|
|
443295
|
+
commentId: identity.commentId,
|
|
443296
|
+
importedId: identity.importedId,
|
|
443297
|
+
isDone: true,
|
|
443298
|
+
resolvedTime: resolvedTimestamp
|
|
443299
|
+
});
|
|
443257
443300
|
return { success: true, updated: [toCommentAddress2(identity.commentId)] };
|
|
443258
443301
|
}
|
|
443259
443302
|
function reopenCommentHandler2(editor, input2, options) {
|
|
@@ -443293,6 +443336,12 @@ function reopenCommentHandler2(editor, input2, options) {
|
|
|
443293
443336
|
failure: { code: "NO_OP", message: "Comment reopen produced no change." }
|
|
443294
443337
|
};
|
|
443295
443338
|
}
|
|
443339
|
+
emitCommentLifecycleUpdate2(editor, "update", {
|
|
443340
|
+
commentId: identity.commentId,
|
|
443341
|
+
importedId: identity.importedId,
|
|
443342
|
+
isDone: false,
|
|
443343
|
+
resolvedTime: null
|
|
443344
|
+
});
|
|
443296
443345
|
return { success: true, updated: [toCommentAddress2(identity.commentId)] };
|
|
443297
443346
|
}
|
|
443298
443347
|
function removeCommentHandler2(editor, input2, options) {
|
|
@@ -443322,6 +443371,12 @@ function removeCommentHandler2(editor, input2, options) {
|
|
|
443322
443371
|
if (!removedIds.size && didRemove) {
|
|
443323
443372
|
removedIds.add(identity.commentId);
|
|
443324
443373
|
}
|
|
443374
|
+
for (const removedId of removedIds) {
|
|
443375
|
+
emitCommentLifecycleUpdate2(editor, "deleted", {
|
|
443376
|
+
commentId: removedId,
|
|
443377
|
+
importedId: removedId === identity.commentId ? identity.importedId : undefined
|
|
443378
|
+
});
|
|
443379
|
+
}
|
|
443325
443380
|
return {
|
|
443326
443381
|
success: true,
|
|
443327
443382
|
removed: Array.from(removedIds).map((id2) => toCommentAddress2(id2))
|