kindy-editor 3.2.1 → 3.2.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-lib/assets/{worker-CHtzL1YW.js → worker-BIFTSRF2.js} +7043 -7021
- package/dist-lib/assets/{worker-_GAJUHf5.js → worker-DO8U44KQ.js} +1 -0
- package/dist-lib/{browser-BxYyzpLt.js → browser-xuRja-pP.js} +2 -2
- package/dist-lib/builder.js +7 -7
- package/dist-lib/changeAggregator-ymKDXGA8.js +376 -0
- package/dist-lib/{editorApp-7-JzxxVn.js → editorApp-zIpjgEaZ.js} +9026 -8276
- package/dist-lib/events.js +119 -43
- package/dist-lib/export.js +1742 -1724
- package/dist-lib/generate-toc.js +5 -5
- package/dist-lib/import.js +2 -2
- package/dist-lib/index-Dd7gMK7l.js +12857 -0
- package/dist-lib/{kindy-editor-DKDwpt09.js → kindy-editor-DuN692fi.js} +133 -83
- package/dist-lib/kindy-editor.js +9 -6
- package/dist-lib/{lists-DpmgbDyt.js → lists-BVCy5dMa.js} +2 -2
- package/dist-lib/measure.js +3 -3
- package/dist-lib/{measureHost-C2NOdNkI.js → measureHost-y37gLU6M.js} +2 -2
- package/dist-lib/{metrics-DHgtBP-R.js → metrics-CdfHD-8y.js} +3 -3
- package/dist-lib/{paintStyle-Cjk9egel.js → paintStyle-Cb7IGKPW.js} +51 -51
- package/dist-lib/{parse-D4RpPrd7.js → parse-DJZd-2A7.js} +20 -20
- package/dist-lib/{pipeline-DhhBcLvV.js → pipeline-DKgBMmw1.js} +301 -301
- package/dist-lib/recalc-docx.js +2 -2
- package/dist-lib/{recalcToc-n50vq4nC.js → recalcToc-DCykIt4o.js} +80 -80
- package/dist-lib/{styleProps-OePkgWnD.js → styleProps-Dg3Wf-ZJ.js} +3 -3
- package/dist-lib/{stylesheet-E5bu1xch.js → stylesheet-EQFx9l5c.js} +3 -3
- package/dist-lib/{toc-DSwkNKls.js → toc-BIj8uQ-W.js} +417 -388
- package/dist-lib/{webmcp-KVT__0GH.js → webmcp-QA5rVg1F.js} +2 -2
- package/docs/http-event-sink.md +7 -0
- package/docs/public-events.md +103 -0
- package/docs/template-variables.md +310 -0
- package/docs/track-changes-events.md +551 -0
- package/package.json +2 -2
- package/types/events.d.ts +67 -1
- package/types/kindy-editor.d.ts +126 -3
- package/dist-lib/eventHub-CZFpTVqe.js +0 -71
- package/dist-lib/events-D_WEQDa6.js +0 -104
- package/dist-lib/index-Brv5TV-9.js +0 -11822
- package/docs/.vitepress/cache/deps/@theme_index.js +0 -275
- package/docs/.vitepress/cache/deps/@theme_index.js.map +0 -7
- package/docs/.vitepress/cache/deps/_metadata.json +0 -40
- package/docs/.vitepress/cache/deps/chunk-FNDFPMRQ.js +0 -13131
- package/docs/.vitepress/cache/deps/chunk-FNDFPMRQ.js.map +0 -7
- package/docs/.vitepress/cache/deps/chunk-IOFLAFGL.js +0 -9719
- package/docs/.vitepress/cache/deps/chunk-IOFLAFGL.js.map +0 -7
- package/docs/.vitepress/cache/deps/package.json +0 -3
- package/docs/.vitepress/cache/deps/vitepress___@vue_devtools-api.js +0 -4483
- package/docs/.vitepress/cache/deps/vitepress___@vue_devtools-api.js.map +0 -7
- package/docs/.vitepress/cache/deps/vitepress___@vueuse_core.js +0 -583
- package/docs/.vitepress/cache/deps/vitepress___@vueuse_core.js.map +0 -7
- package/docs/.vitepress/cache/deps/vue.js +0 -347
- package/docs/.vitepress/cache/deps/vue.js.map +0 -7
- package/docs/.vitepress/config.ts +0 -30
package/dist-lib/events.js
CHANGED
|
@@ -1,46 +1,122 @@
|
|
|
1
|
-
import { E as
|
|
2
|
-
import "./toc-
|
|
3
|
-
|
|
4
|
-
function
|
|
5
|
-
const
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
1
|
+
import { C as l, a as I, E as u, c as h } from "./changeAggregator-ymKDXGA8.js";
|
|
2
|
+
import "./toc-BIj8uQ-W.js";
|
|
3
|
+
const n = "1.0";
|
|
4
|
+
function c(e) {
|
|
5
|
+
const t = /* @__PURE__ */ new Set();
|
|
6
|
+
for (const a of e)
|
|
7
|
+
switch (a.type) {
|
|
8
|
+
case "insertText":
|
|
9
|
+
case "insertRuns":
|
|
10
|
+
case "splitParagraph":
|
|
11
|
+
t.add(a.at.blockId), a.type === "splitParagraph" && t.add(a.newBlockId);
|
|
12
|
+
break;
|
|
13
|
+
case "mergeParagraphs":
|
|
14
|
+
t.add(a.firstBlockId);
|
|
15
|
+
break;
|
|
16
|
+
case "insertBlock":
|
|
17
|
+
t.add(a.block.id);
|
|
18
|
+
break;
|
|
19
|
+
case "setTableRow":
|
|
20
|
+
case "setTableStructure":
|
|
21
|
+
case "setTableStyleRef":
|
|
22
|
+
case "insertTableRow":
|
|
23
|
+
case "removeTableRow":
|
|
24
|
+
case "setRowHeight":
|
|
25
|
+
case "insertTableColumn":
|
|
26
|
+
case "removeTableColumn":
|
|
27
|
+
t.add(a.tableId);
|
|
28
|
+
break;
|
|
29
|
+
case "deleteRange":
|
|
30
|
+
case "setRuns":
|
|
31
|
+
case "setParaStyle":
|
|
32
|
+
case "removeBlock":
|
|
33
|
+
case "setImageProps":
|
|
34
|
+
case "setEquation":
|
|
35
|
+
case "setEquationAlign":
|
|
36
|
+
case "setTableColFractions":
|
|
37
|
+
case "setTableWidthMode":
|
|
38
|
+
case "setTablePreferredWidth":
|
|
39
|
+
case "setTableAlign":
|
|
40
|
+
case "setTableProps":
|
|
41
|
+
t.add(a.blockId);
|
|
42
|
+
break;
|
|
43
|
+
}
|
|
44
|
+
return [...t];
|
|
45
|
+
}
|
|
46
|
+
function i(e, t) {
|
|
47
|
+
const a = { type: "review.operation.applied", data: { operation: e, remote: t } };
|
|
48
|
+
switch (e.type) {
|
|
49
|
+
case "addSuggestion":
|
|
50
|
+
return [a, { type: "review.suggestion.created", data: { suggestionId: e.s.id, kind: e.s.kind, remote: t } }];
|
|
51
|
+
case "removeSuggestion":
|
|
52
|
+
return [a, { type: "review.suggestion.removed", data: { suggestionId: e.id, remote: t } }];
|
|
53
|
+
case "growSuggestion":
|
|
54
|
+
return [a];
|
|
55
|
+
case "addThread": {
|
|
56
|
+
const d = e.t.comments[0];
|
|
57
|
+
return d ? [
|
|
58
|
+
a,
|
|
59
|
+
{ type: "review.thread.created", data: { threadId: e.t.id, remote: t } },
|
|
60
|
+
{
|
|
61
|
+
type: "review.comment.added",
|
|
62
|
+
data: {
|
|
63
|
+
threadId: e.t.id,
|
|
64
|
+
commentId: d.id,
|
|
65
|
+
authorId: d.author.id,
|
|
66
|
+
isReply: !1,
|
|
67
|
+
mentionedUserIds: (d.mentions ?? []).map((s) => s.id),
|
|
68
|
+
remote: t
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
] : [a, { type: "review.thread.created", data: { threadId: e.t.id, remote: t } }];
|
|
72
|
+
}
|
|
73
|
+
case "removeThread":
|
|
74
|
+
return [a, { type: "review.thread.removed", data: { threadId: e.id, remote: t } }];
|
|
75
|
+
case "addComment":
|
|
76
|
+
return [a, {
|
|
77
|
+
type: "review.comment.added",
|
|
78
|
+
data: {
|
|
79
|
+
threadId: e.threadId,
|
|
80
|
+
commentId: e.c.id,
|
|
81
|
+
authorId: e.c.author.id,
|
|
82
|
+
isReply: !0,
|
|
83
|
+
mentionedUserIds: (e.c.mentions ?? []).map((d) => d.id),
|
|
84
|
+
remote: t
|
|
85
|
+
}
|
|
86
|
+
}];
|
|
87
|
+
case "removeComment":
|
|
88
|
+
return [a, { type: "review.comment.removed", data: { threadId: e.threadId, commentId: e.commentId, remote: t } }];
|
|
89
|
+
case "editComment":
|
|
90
|
+
return [a, {
|
|
91
|
+
type: "review.comment.edited",
|
|
92
|
+
data: {
|
|
93
|
+
threadId: e.threadId,
|
|
94
|
+
commentId: e.commentId,
|
|
95
|
+
mentionedUserIds: (e.mentions ?? []).map((d) => d.id),
|
|
96
|
+
newlyMentionedUserIds: e.newlyMentionedUserIds ?? [],
|
|
97
|
+
remote: t
|
|
98
|
+
}
|
|
99
|
+
}];
|
|
100
|
+
case "deleteComment":
|
|
101
|
+
return [a, {
|
|
102
|
+
type: "review.comment.deleted",
|
|
103
|
+
data: {
|
|
104
|
+
threadId: e.threadId,
|
|
105
|
+
commentId: e.commentId,
|
|
106
|
+
deletedByUserId: e.deletedBy.id,
|
|
107
|
+
remote: t
|
|
108
|
+
}
|
|
109
|
+
}];
|
|
110
|
+
case "setThreadStatus":
|
|
111
|
+
return [a, { type: "review.thread.status.changed", data: { threadId: e.threadId, status: e.status, remote: t } }];
|
|
112
|
+
}
|
|
39
113
|
}
|
|
40
114
|
export {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
115
|
+
l as ChangeAggregator,
|
|
116
|
+
I as CommitPolicy,
|
|
117
|
+
n as EDITOR_EVENT_SCHEMA_VERSION,
|
|
118
|
+
u as EditorEvents,
|
|
119
|
+
c as affectedBlockIds,
|
|
120
|
+
h as createHttpEventSink,
|
|
121
|
+
i as projectReviewEvents
|
|
46
122
|
};
|