@univerjs/sheets-thread-comment-ui 0.5.3 → 0.5.4-experimental.20250114-7c09c35
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/lib/cjs/index.js +2 -2
- package/lib/es/index.js +194 -194
- package/lib/types/controllers/sheets-thread-comment-hover.controller.d.ts +4 -3
- package/lib/types/controllers/sheets-thread-comment-popup.controller.d.ts +4 -4
- package/lib/umd/index.js +2 -2
- package/package.json +14 -13
- package/LICENSE +0 -176
package/lib/es/index.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
var
|
|
2
|
-
var ke = (o, e, n) => e in o ?
|
|
1
|
+
var Be = Object.defineProperty;
|
|
2
|
+
var ke = (o, e, n) => e in o ? Be(o, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : o[e] = n;
|
|
3
3
|
var E = (o, e, n) => ke(o, typeof e != "symbol" ? e + "" : e, n);
|
|
4
|
-
import { Inject as _, Disposable as $, DisposableCollection as Fe, CommandType as We, IUniverInstanceService as N, InterceptorEffectEnum as Ze, UniverInstanceType as b, Range as ze, ICommandService as
|
|
5
|
-
import { SheetsSelectionsService as Se, getSheetCommandTarget as et, SheetInterceptorService as ge, INTERCEPTOR_POINT as tt, WorkbookCommentPermission as K, WorksheetViewPermission as Q, RangeProtectionPermissionViewPoint as X, SetWorksheetActiveOperation as nt, RemoveSheetCommand as rt } from "@univerjs/sheets";
|
|
4
|
+
import { Inject as _, Disposable as $, DisposableCollection as Fe, CommandType as We, IUniverInstanceService as N, InterceptorEffectEnum as Ze, UniverInstanceType as b, Range as ze, ICommandService as ce, RANGE_TYPE as he, Rectangle as qe, useDependency as R, Tools as Ge, DependentOn as Je, Injector as Ye, Plugin as Ke, merge as Qe, IConfigService as Xe } from "@univerjs/core";
|
|
5
|
+
import { SheetsSelectionsService as Se, getSheetCommandTarget as et, SheetInterceptorService as ge, INTERCEPTOR_POINT as tt, SheetPermissionCheckController as Ie, WorkbookCommentPermission as K, WorksheetViewPermission as Q, RangeProtectionPermissionViewPoint as X, SetWorksheetActiveOperation as nt, RemoveSheetCommand as rt } from "@univerjs/sheets";
|
|
6
6
|
import { SheetsThreadCommentModel as x, UniverSheetsThreadCommentPlugin as ot } from "@univerjs/sheets-thread-comment";
|
|
7
|
-
import { ThreadCommentPanelService as
|
|
7
|
+
import { ThreadCommentPanelService as ae, SetActiveCommentOperation as te, ThreadCommentTree as it, ThreadCommentPanel as st, ToggleSheetCommentPanelOperation as Pe, THREAD_COMMENT_PANEL as ct, UniverThreadCommentUIPlugin as at } from "@univerjs/thread-comment-ui";
|
|
8
8
|
import { UniverThreadCommentUIPlugin as $n } from "@univerjs/thread-comment-ui";
|
|
9
|
-
import { SheetCanvasPopManagerService as
|
|
10
|
-
import { IZenZoneService as
|
|
11
|
-
import { BehaviorSubject as Mt, debounceTime as
|
|
9
|
+
import { SheetCanvasPopManagerService as ut, ISheetClipboardService as dt, COPY_TYPE as mt, HoverManagerService as ht, IMarkSelectionService as Te, IEditorBridgeService as lt, SheetSkeletonManagerService as pt, ScrollToRangeOperation as _t, whenSheetEditorFocused as ft, getCurrentRangeDisable$ as be } from "@univerjs/sheets-ui";
|
|
10
|
+
import { IZenZoneService as vt, useObservable as A, KeyCode as Ct, MetaKeys as le, MenuItemType as Me, getMenuHiddenObservable as we, RibbonStartGroup as St, ContextMenuPosition as gt, ContextMenuGroup as It, ComponentManager as Pt, IMenuManagerService as Tt, IShortcutService as bt } from "@univerjs/ui";
|
|
11
|
+
import { BehaviorSubject as Mt, debounceTime as ue, map as wt } from "rxjs";
|
|
12
12
|
import { IRenderManagerService as ye } from "@univerjs/engine-render";
|
|
13
13
|
import { singleReferenceToGrid as V, serializeRange as yt } from "@univerjs/engine-formula";
|
|
14
14
|
import { IThreadCommentDataSourceService as Ee, DeleteCommentMutation as F, AddCommentMutation as se, ThreadCommentModel as Et } from "@univerjs/thread-comment";
|
|
15
|
-
import { AddCommentCommand as xn, DeleteCommentCommand as Dn, DeleteCommentTreeCommand as jn, IThreadCommentDataSourceService as An, ResolveCommentCommand as Vn, UpdateCommentCommand as
|
|
15
|
+
import { AddCommentCommand as xn, DeleteCommentCommand as Dn, DeleteCommentTreeCommand as jn, IThreadCommentDataSourceService as An, ResolveCommentCommand as Vn, UpdateCommentCommand as Hn } from "@univerjs/thread-comment";
|
|
16
16
|
import Rt, { forwardRef as Re, useRef as Oe, createElement as Ue, useMemo as Ot, useCallback as pe, useEffect as Ut } from "react";
|
|
17
|
-
const $e = "univer.sheet.thread-comment-modal",
|
|
17
|
+
const $e = "univer.sheet.thread-comment-modal", de = "comment-single", Ne = "SHEET_THREAD_COMMENT";
|
|
18
18
|
var $t = Object.defineProperty, Nt = Object.getOwnPropertyDescriptor, xt = (o, e, n, t) => {
|
|
19
19
|
for (var r = t > 1 ? void 0 : t ? Nt(e, n) : e, i = o.length - 1, s; i >= 0; i--)
|
|
20
20
|
(s = o[i]) && (r = (t ? s(e, n, r) : s(r)) || r);
|
|
@@ -40,16 +40,16 @@ let O = class extends $ {
|
|
|
40
40
|
}));
|
|
41
41
|
}
|
|
42
42
|
showPopup(e, n) {
|
|
43
|
-
var
|
|
43
|
+
var m;
|
|
44
44
|
const { row: t, col: r, unitId: i, subUnitId: s } = e;
|
|
45
|
-
if (this._activePopup && t === this._activePopup.row && r === this._activePopup.col && i === this._activePopup.unitId && s === ((
|
|
45
|
+
if (this._activePopup && t === this._activePopup.row && r === this._activePopup.col && i === this._activePopup.unitId && s === ((m = this.activePopup) == null ? void 0 : m.subUnitId)) {
|
|
46
46
|
this._activePopup = e, this._activePopup$.next(e);
|
|
47
47
|
return;
|
|
48
48
|
}
|
|
49
49
|
if (this._lastPopup && this._lastPopup.dispose(), this._zenZoneService.visible)
|
|
50
50
|
return;
|
|
51
51
|
this._activePopup = e, this._activePopup$.next(e);
|
|
52
|
-
const
|
|
52
|
+
const c = this._canvasPopupManagerService.attachPopupToCell(
|
|
53
53
|
t,
|
|
54
54
|
r,
|
|
55
55
|
{
|
|
@@ -64,14 +64,14 @@ let O = class extends $ {
|
|
|
64
64
|
].filter(Boolean)
|
|
65
65
|
}
|
|
66
66
|
);
|
|
67
|
-
if (!
|
|
67
|
+
if (!c)
|
|
68
68
|
throw new Error("[SheetsThreadCommentPopupService]: cannot show popup!");
|
|
69
|
-
const
|
|
70
|
-
|
|
69
|
+
const a = new Fe();
|
|
70
|
+
a.add(c), a.add({
|
|
71
71
|
dispose: () => {
|
|
72
72
|
n == null || n();
|
|
73
73
|
}
|
|
74
|
-
}), this._lastPopup =
|
|
74
|
+
}), this._lastPopup = a;
|
|
75
75
|
}
|
|
76
76
|
hidePopup() {
|
|
77
77
|
this._activePopup && (this._lastPopup && this._lastPopup.dispose(), this._lastPopup = null, this._activePopup = null, this._activePopup$.next(null));
|
|
@@ -84,43 +84,43 @@ let O = class extends $ {
|
|
|
84
84
|
}
|
|
85
85
|
};
|
|
86
86
|
O = xt([
|
|
87
|
-
_e(0, _(
|
|
88
|
-
_e(1,
|
|
87
|
+
_e(0, _(ut)),
|
|
88
|
+
_e(1, vt)
|
|
89
89
|
], O);
|
|
90
|
-
const
|
|
90
|
+
const H = {
|
|
91
91
|
type: We.OPERATION,
|
|
92
92
|
id: "sheets.operation.show-comment-modal",
|
|
93
93
|
handler(o) {
|
|
94
|
-
var
|
|
95
|
-
const e = o.get(Se), n = o.get(N), t = o.get(O), r = o.get(
|
|
94
|
+
var f;
|
|
95
|
+
const e = o.get(Se), n = o.get(N), t = o.get(O), r = o.get(ae), i = (f = e.getCurrentLastSelection()) == null ? void 0 : f.primary, s = o.get(x);
|
|
96
96
|
if (!i)
|
|
97
97
|
return !1;
|
|
98
|
-
const
|
|
99
|
-
if (!
|
|
98
|
+
const c = et(n);
|
|
99
|
+
if (!c)
|
|
100
100
|
return !1;
|
|
101
|
-
const { workbook:
|
|
102
|
-
workbook:
|
|
103
|
-
worksheet:
|
|
104
|
-
unitId:
|
|
105
|
-
subUnitId:
|
|
101
|
+
const { workbook: a, worksheet: m, unitId: u, subUnitId: d } = c, h = {
|
|
102
|
+
workbook: a,
|
|
103
|
+
worksheet: m,
|
|
104
|
+
unitId: u,
|
|
105
|
+
subUnitId: d,
|
|
106
106
|
row: i.startRow,
|
|
107
107
|
col: i.startColumn
|
|
108
108
|
};
|
|
109
109
|
t.showPopup(h);
|
|
110
|
-
const l = s.getByLocation(
|
|
110
|
+
const l = s.getByLocation(u, d, i.startRow, i.startColumn);
|
|
111
111
|
return l && r.setActiveComment({
|
|
112
|
-
unitId:
|
|
113
|
-
subUnitId:
|
|
112
|
+
unitId: u,
|
|
113
|
+
subUnitId: d,
|
|
114
114
|
commentId: l,
|
|
115
115
|
trigger: "context-menu"
|
|
116
116
|
}), !0;
|
|
117
117
|
}
|
|
118
|
-
}, Dt = "sheets-thread-comment.config",
|
|
118
|
+
}, Dt = "sheets-thread-comment.config", fe = {};
|
|
119
119
|
var jt = Object.defineProperty, At = Object.getOwnPropertyDescriptor, Vt = (o, e, n, t) => {
|
|
120
120
|
for (var r = t > 1 ? void 0 : t ? At(e, n) : e, i = o.length - 1, s; i >= 0; i--)
|
|
121
121
|
(s = o[i]) && (r = (t ? s(e, n, r) : s(r)) || r);
|
|
122
122
|
return t && r && jt(e, n, r), r;
|
|
123
|
-
},
|
|
123
|
+
}, L = (o, e) => (n, t) => e(n, t, o);
|
|
124
124
|
let W = class extends $ {
|
|
125
125
|
constructor(o, e, n, t) {
|
|
126
126
|
super(), this._sheetInterceptorService = o, this._sheetsThreadCommentModel = e, this._univerInstanceService = n, this._renderManagerService = t, this._initViewModelIntercept(), this._initSkeletonChange();
|
|
@@ -157,21 +157,21 @@ let W = class extends $ {
|
|
|
157
157
|
const n = e.getUnitId(), t = this._renderManagerService.getRenderById(n);
|
|
158
158
|
(r = t == null ? void 0 : t.mainComponent) == null || r.makeForceDirty();
|
|
159
159
|
};
|
|
160
|
-
this.disposeWithMe(this._sheetsThreadCommentModel.commentUpdate$.pipe(
|
|
160
|
+
this.disposeWithMe(this._sheetsThreadCommentModel.commentUpdate$.pipe(ue(16)).subscribe(() => {
|
|
161
161
|
o();
|
|
162
162
|
}));
|
|
163
163
|
}
|
|
164
164
|
};
|
|
165
165
|
W = Vt([
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
166
|
+
L(0, _(ge)),
|
|
167
|
+
L(1, _(x)),
|
|
168
|
+
L(2, N),
|
|
169
|
+
L(3, ye)
|
|
170
170
|
], W);
|
|
171
|
-
var
|
|
172
|
-
for (var r = t > 1 ? void 0 : t ?
|
|
171
|
+
var Ht = Object.defineProperty, Lt = Object.getOwnPropertyDescriptor, Bt = (o, e, n, t) => {
|
|
172
|
+
for (var r = t > 1 ? void 0 : t ? Lt(e, n) : e, i = o.length - 1, s; i >= 0; i--)
|
|
173
173
|
(s = o[i]) && (r = (t ? s(e, n, r) : s(r)) || r);
|
|
174
|
-
return t && r &&
|
|
174
|
+
return t && r && Ht(e, n, r), r;
|
|
175
175
|
}, ne = (o, e) => (n, t) => e(n, t, o);
|
|
176
176
|
const kt = (o, e, n) => {
|
|
177
177
|
const t = V(o), r = n.row - e.row, i = n.column - e.column, s = {
|
|
@@ -202,31 +202,31 @@ let Z = class extends $ {
|
|
|
202
202
|
},
|
|
203
203
|
// eslint-disable-next-line max-lines-per-function
|
|
204
204
|
onPasteCells: (e, n, t, r) => {
|
|
205
|
-
const { unitId: i, subUnitId: s, range:
|
|
206
|
-
row:
|
|
207
|
-
column:
|
|
205
|
+
const { unitId: i, subUnitId: s, range: c } = n, a = {
|
|
206
|
+
row: c.rows[0],
|
|
207
|
+
column: c.cols[0]
|
|
208
208
|
};
|
|
209
|
-
if (r.copyType ===
|
|
210
|
-
const { range:
|
|
211
|
-
row:
|
|
212
|
-
column:
|
|
209
|
+
if (r.copyType === mt.CUT && this._copyInfo) {
|
|
210
|
+
const { range: m, unitId: u, subUnitId: d } = this._copyInfo, h = {
|
|
211
|
+
row: m.startRow,
|
|
212
|
+
column: m.startColumn
|
|
213
213
|
};
|
|
214
|
-
if (!(i ===
|
|
214
|
+
if (!(i === u && s === d)) {
|
|
215
215
|
const l = [];
|
|
216
|
-
ze.foreach(
|
|
217
|
-
const I = this._sheetsThreadCommentModel.getAllByLocation(
|
|
218
|
-
this._threadCommentDataSourceService.syncUpdateMutationToColla ? I.forEach((
|
|
219
|
-
l.push(
|
|
220
|
-
}) : I.forEach(({ children:
|
|
216
|
+
ze.foreach(m, (g, p) => {
|
|
217
|
+
const I = this._sheetsThreadCommentModel.getAllByLocation(u, d, g, p);
|
|
218
|
+
this._threadCommentDataSourceService.syncUpdateMutationToColla ? I.forEach((v) => {
|
|
219
|
+
l.push(v);
|
|
220
|
+
}) : I.forEach(({ children: v, ...M }) => {
|
|
221
221
|
M.parentId || l.push(M);
|
|
222
222
|
});
|
|
223
223
|
});
|
|
224
|
-
const
|
|
225
|
-
|
|
224
|
+
const f = [], S = [], U = [], D = [], ee = (g) => {
|
|
225
|
+
f.unshift({
|
|
226
226
|
id: F.id,
|
|
227
227
|
params: {
|
|
228
|
-
unitId:
|
|
229
|
-
subUnitId:
|
|
228
|
+
unitId: u,
|
|
229
|
+
subUnitId: d,
|
|
230
230
|
commentId: g.id
|
|
231
231
|
}
|
|
232
232
|
}), U.push({
|
|
@@ -236,7 +236,7 @@ let Z = class extends $ {
|
|
|
236
236
|
subUnitId: s,
|
|
237
237
|
comment: {
|
|
238
238
|
...g,
|
|
239
|
-
ref: kt(g.ref, h,
|
|
239
|
+
ref: kt(g.ref, h, a),
|
|
240
240
|
unitId: i,
|
|
241
241
|
subUnitId: s
|
|
242
242
|
},
|
|
@@ -245,8 +245,8 @@ let Z = class extends $ {
|
|
|
245
245
|
}), S.push({
|
|
246
246
|
id: se.id,
|
|
247
247
|
params: {
|
|
248
|
-
unitId:
|
|
249
|
-
subUnitId:
|
|
248
|
+
unitId: u,
|
|
249
|
+
subUnitId: d,
|
|
250
250
|
comment: g,
|
|
251
251
|
sync: !0
|
|
252
252
|
}
|
|
@@ -262,7 +262,7 @@ let Z = class extends $ {
|
|
|
262
262
|
return l.forEach((g) => {
|
|
263
263
|
ee(g);
|
|
264
264
|
}), {
|
|
265
|
-
redos: [...
|
|
265
|
+
redos: [...f, ...U],
|
|
266
266
|
undos: [...D, ...S]
|
|
267
267
|
};
|
|
268
268
|
}
|
|
@@ -276,8 +276,8 @@ let Z = class extends $ {
|
|
|
276
276
|
);
|
|
277
277
|
}
|
|
278
278
|
};
|
|
279
|
-
Z =
|
|
280
|
-
ne(0, _(
|
|
279
|
+
Z = Bt([
|
|
280
|
+
ne(0, _(dt)),
|
|
281
281
|
ne(1, _(x)),
|
|
282
282
|
ne(2, Ee)
|
|
283
283
|
], Z);
|
|
@@ -285,31 +285,31 @@ var Ft = Object.defineProperty, Wt = Object.getOwnPropertyDescriptor, Zt = (o, e
|
|
|
285
285
|
for (var r = t > 1 ? void 0 : t ? Wt(e, n) : e, i = o.length - 1, s; i >= 0; i--)
|
|
286
286
|
(s = o[i]) && (r = (t ? s(e, n, r) : s(r)) || r);
|
|
287
287
|
return t && r && Ft(e, n, r), r;
|
|
288
|
-
},
|
|
288
|
+
}, B = (o, e) => (n, t) => e(n, t, o);
|
|
289
289
|
let z = class extends $ {
|
|
290
290
|
constructor(o, e, n, t) {
|
|
291
|
-
super(), this._hoverManagerService = o, this._sheetsThreadCommentPopupService = e, this._sheetsThreadCommentModel = n, this.
|
|
291
|
+
super(), this._hoverManagerService = o, this._sheetsThreadCommentPopupService = e, this._sheetsThreadCommentModel = n, this._sheetPermissionCheckController = t, this._initHoverEvent();
|
|
292
292
|
}
|
|
293
293
|
_initHoverEvent() {
|
|
294
294
|
this.disposeWithMe(
|
|
295
|
-
this._hoverManagerService.currentCell$.pipe(
|
|
295
|
+
this._hoverManagerService.currentCell$.pipe(ue(100)).subscribe((o) => {
|
|
296
296
|
const e = this._sheetsThreadCommentPopupService.activePopup;
|
|
297
297
|
if (o && (e && e.temp || !e)) {
|
|
298
|
-
const { location: n } = o, { unitId: t, subUnitId: r, row: i, col: s } = n,
|
|
299
|
-
if (
|
|
300
|
-
if (!this.
|
|
298
|
+
const { location: n } = o, { unitId: t, subUnitId: r, row: i, col: s } = n, c = this._sheetsThreadCommentModel.getByLocation(t, r, i, s);
|
|
299
|
+
if (c) {
|
|
300
|
+
if (!this._sheetPermissionCheckController.permissionCheckWithRanges({
|
|
301
301
|
workbookTypes: [K],
|
|
302
302
|
worksheetTypes: [Q],
|
|
303
303
|
rangeTypes: [X]
|
|
304
304
|
}, [{ startRow: i, startColumn: s, endRow: i, endColumn: s }]))
|
|
305
305
|
return;
|
|
306
|
-
const
|
|
307
|
-
|
|
306
|
+
const m = this._sheetsThreadCommentModel.getComment(t, r, c);
|
|
307
|
+
m && !m.resolved && this._sheetsThreadCommentPopupService.showPopup({
|
|
308
308
|
unitId: t,
|
|
309
309
|
subUnitId: r,
|
|
310
310
|
row: i,
|
|
311
311
|
col: s,
|
|
312
|
-
commentId:
|
|
312
|
+
commentId: c,
|
|
313
313
|
temp: !0
|
|
314
314
|
});
|
|
315
315
|
} else
|
|
@@ -320,10 +320,10 @@ let z = class extends $ {
|
|
|
320
320
|
}
|
|
321
321
|
};
|
|
322
322
|
z = Zt([
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
323
|
+
B(0, _(ht)),
|
|
324
|
+
B(1, _(O)),
|
|
325
|
+
B(2, _(x)),
|
|
326
|
+
B(3, _(Ie))
|
|
327
327
|
], z);
|
|
328
328
|
var zt = Object.defineProperty, qt = Object.getOwnPropertyDescriptor, Gt = (o, e, n, t) => {
|
|
329
329
|
for (var r = t > 1 ? void 0 : t ? qt(e, n) : e, i = o.length - 1, s; i >= 0; i--)
|
|
@@ -331,32 +331,32 @@ var zt = Object.defineProperty, qt = Object.getOwnPropertyDescriptor, Gt = (o, e
|
|
|
331
331
|
return t && r && zt(e, n, r), r;
|
|
332
332
|
}, w = (o, e) => (n, t) => e(n, t, o);
|
|
333
333
|
let q = class extends $ {
|
|
334
|
-
constructor(e, n, t, r, i, s,
|
|
334
|
+
constructor(e, n, t, r, i, s, c, a, m, u) {
|
|
335
335
|
super();
|
|
336
336
|
E(this, "_isSwitchToCommenting", !1);
|
|
337
337
|
E(this, "_selectionShapeInfo", null);
|
|
338
|
-
this._commandService = e, this._sheetsThreadCommentPopupService = n, this._sheetsThreadCommentModel = t, this._threadCommentPanelService = r, this._univerInstanceService = i, this.
|
|
338
|
+
this._commandService = e, this._sheetsThreadCommentPopupService = n, this._sheetsThreadCommentModel = t, this._threadCommentPanelService = r, this._univerInstanceService = i, this._sheetPermissionCheckController = s, this._markSelectionService = c, this._sheetSelectionService = a, this._editorBridgeService = m, this._renderManagerService = u, this._initCommandListener(), this._initPanelListener(), this._initMarkSelection(), this._initSelectionUpdateListener(), this._initEditorBridge();
|
|
339
339
|
}
|
|
340
340
|
_handleSelectionChange(e, n, t) {
|
|
341
|
-
var h, l,
|
|
341
|
+
var h, l, f;
|
|
342
342
|
const r = (h = e[0]) == null ? void 0 : h.range, i = this._renderManagerService.getRenderById(n), s = (l = i == null ? void 0 : i.with(pt).getWorksheetSkeleton(t)) == null ? void 0 : l.skeleton;
|
|
343
343
|
if (!s || !r)
|
|
344
344
|
return;
|
|
345
|
-
const
|
|
346
|
-
if ((((
|
|
345
|
+
const c = s.getCellWithCoordByIndex(r.startRow, r.startColumn);
|
|
346
|
+
if ((((f = r.rangeType) != null ? f : he.NORMAL) !== he.NORMAL || r.endColumn - r.startColumn > 0 || r.endRow - r.startRow > 0) && !((c.isMerged || c.isMergedMainCell) && qe.equals(c.mergeInfo, r))) {
|
|
347
347
|
this._threadCommentPanelService.activeCommentId && this._commandService.executeCommand(te.id);
|
|
348
348
|
return;
|
|
349
349
|
}
|
|
350
|
-
const
|
|
351
|
-
if (!this._sheetsThreadCommentModel.showCommentMarker(n, t,
|
|
350
|
+
const m = c.actualRow, u = c.actualColumn;
|
|
351
|
+
if (!this._sheetsThreadCommentModel.showCommentMarker(n, t, m, u)) {
|
|
352
352
|
this._threadCommentPanelService.activeCommentId && this._commandService.executeCommand(te.id);
|
|
353
353
|
return;
|
|
354
354
|
}
|
|
355
|
-
const
|
|
356
|
-
|
|
355
|
+
const d = this._sheetsThreadCommentModel.getByLocation(n, t, m, u);
|
|
356
|
+
d && this._commandService.executeCommand(te.id, {
|
|
357
357
|
unitId: n,
|
|
358
358
|
subUnitId: t,
|
|
359
|
-
commentId:
|
|
359
|
+
commentId: d
|
|
360
360
|
});
|
|
361
361
|
}
|
|
362
362
|
_initSelectionUpdateListener() {
|
|
@@ -391,18 +391,18 @@ let q = class extends $ {
|
|
|
391
391
|
this.disposeWithMe(this._threadCommentPanelService.activeCommentId$.subscribe(async (e) => {
|
|
392
392
|
var n;
|
|
393
393
|
if (e) {
|
|
394
|
-
const { unitId: t, subUnitId: r, commentId: i, trigger: s } = e,
|
|
395
|
-
if (!
|
|
394
|
+
const { unitId: t, subUnitId: r, commentId: i, trigger: s } = e, c = this._sheetsThreadCommentModel.getComment(t, r, i);
|
|
395
|
+
if (!c || c.resolved)
|
|
396
396
|
return;
|
|
397
|
-
const
|
|
398
|
-
if (!
|
|
397
|
+
const a = this._univerInstanceService.getCurrentUnitForType(b.UNIVER_SHEET);
|
|
398
|
+
if (!a || a.getUnitId() !== t)
|
|
399
399
|
return;
|
|
400
|
-
this._isSwitchToCommenting = !0, ((n =
|
|
400
|
+
this._isSwitchToCommenting = !0, ((n = a.getActiveSheet()) == null ? void 0 : n.getSheetId()) !== r && await this._commandService.executeCommand(nt.id, {
|
|
401
401
|
unitId: t,
|
|
402
402
|
subUnitId: r
|
|
403
403
|
}), this._isSwitchToCommenting = !1;
|
|
404
|
-
const
|
|
405
|
-
if (!this.
|
|
404
|
+
const d = V(c.ref), { row: h, column: l } = d;
|
|
405
|
+
if (!this._sheetPermissionCheckController.permissionCheckWithRanges({
|
|
406
406
|
workbookTypes: [K],
|
|
407
407
|
worksheetTypes: [Q],
|
|
408
408
|
rangeTypes: [X]
|
|
@@ -411,19 +411,19 @@ let q = class extends $ {
|
|
|
411
411
|
const S = 1;
|
|
412
412
|
if (await this._commandService.executeCommand(_t.id, {
|
|
413
413
|
range: {
|
|
414
|
-
startRow: Math.max(
|
|
415
|
-
endRow:
|
|
416
|
-
startColumn: Math.max(
|
|
417
|
-
endColumn:
|
|
414
|
+
startRow: Math.max(d.row - S, 0),
|
|
415
|
+
endRow: d.row + S,
|
|
416
|
+
startColumn: Math.max(d.column - S, 0),
|
|
417
|
+
endColumn: d.column + S
|
|
418
418
|
}
|
|
419
419
|
}), this._editorBridgeService.isVisible().visible)
|
|
420
420
|
return;
|
|
421
421
|
this._sheetsThreadCommentPopupService.showPopup({
|
|
422
422
|
unitId: t,
|
|
423
423
|
subUnitId: r,
|
|
424
|
-
row:
|
|
425
|
-
col:
|
|
426
|
-
commentId:
|
|
424
|
+
row: d.row,
|
|
425
|
+
col: d.column,
|
|
426
|
+
commentId: c.id,
|
|
427
427
|
trigger: s
|
|
428
428
|
});
|
|
429
429
|
} else
|
|
@@ -431,7 +431,7 @@ let q = class extends $ {
|
|
|
431
431
|
}));
|
|
432
432
|
}
|
|
433
433
|
_initMarkSelection() {
|
|
434
|
-
this.disposeWithMe(this._threadCommentPanelService.activeCommentId$.pipe(
|
|
434
|
+
this.disposeWithMe(this._threadCommentPanelService.activeCommentId$.pipe(ue(100)).subscribe((e) => {
|
|
435
435
|
var h, l;
|
|
436
436
|
if (!e) {
|
|
437
437
|
this._selectionShapeInfo && (this._markSelectionService.removeShape(this._selectionShapeInfo.shapeId), this._selectionShapeInfo = null);
|
|
@@ -442,17 +442,17 @@ let q = class extends $ {
|
|
|
442
442
|
const i = this._sheetsThreadCommentModel.getComment(n, t, r);
|
|
443
443
|
if (!i)
|
|
444
444
|
return;
|
|
445
|
-
const s = V(i.ref), { row:
|
|
446
|
-
if (Number.isNaN(
|
|
445
|
+
const s = V(i.ref), { row: c, column: a } = s;
|
|
446
|
+
if (Number.isNaN(c) || Number.isNaN(a))
|
|
447
447
|
return null;
|
|
448
|
-
const
|
|
449
|
-
startColumn:
|
|
450
|
-
endColumn:
|
|
451
|
-
startRow:
|
|
452
|
-
endRow:
|
|
453
|
-
},
|
|
448
|
+
const m = (h = this._univerInstanceService.getCurrentUnitForType(b.UNIVER_SHEET)) == null ? void 0 : h.getSheetBySheetId(t), u = (l = m == null ? void 0 : m.getMergedCell(c, a)) != null ? l : {
|
|
449
|
+
startColumn: a,
|
|
450
|
+
endColumn: a,
|
|
451
|
+
startRow: c,
|
|
452
|
+
endRow: c
|
|
453
|
+
}, d = this._markSelectionService.addShape(
|
|
454
454
|
{
|
|
455
|
-
range:
|
|
455
|
+
range: u,
|
|
456
456
|
style: {
|
|
457
457
|
// hasAutoFill: false,
|
|
458
458
|
fill: "rgb(255, 189, 55, 0.35)",
|
|
@@ -465,20 +465,20 @@ let q = class extends $ {
|
|
|
465
465
|
[],
|
|
466
466
|
-1
|
|
467
467
|
);
|
|
468
|
-
|
|
468
|
+
d && (this._selectionShapeInfo = {
|
|
469
469
|
...e,
|
|
470
|
-
shapeId:
|
|
470
|
+
shapeId: d
|
|
471
471
|
});
|
|
472
472
|
}));
|
|
473
473
|
}
|
|
474
474
|
};
|
|
475
475
|
q = Gt([
|
|
476
|
-
w(0,
|
|
476
|
+
w(0, ce),
|
|
477
477
|
w(1, _(O)),
|
|
478
478
|
w(2, _(x)),
|
|
479
|
-
w(3, _(
|
|
479
|
+
w(3, _(ae)),
|
|
480
480
|
w(4, N),
|
|
481
|
-
w(5, _(
|
|
481
|
+
w(5, _(Ie)),
|
|
482
482
|
w(6, Te),
|
|
483
483
|
w(7, _(Se)),
|
|
484
484
|
w(8, lt),
|
|
@@ -505,26 +505,26 @@ let G = class extends $ {
|
|
|
505
505
|
const r = t.getUnitId(), i = n.subUnitId || ((e = t.getActiveSheet()) == null ? void 0 : e.getSheetId());
|
|
506
506
|
if (!i)
|
|
507
507
|
return { redos: [], undos: [] };
|
|
508
|
-
const s = this._threadCommentModel.ensureMap(r, i),
|
|
508
|
+
const s = this._threadCommentModel.ensureMap(r, i), c = Array.from(s.values()).filter((h) => !h.parentId), a = c.map((h) => h.id), m = this._threadCommentDataSourceService.syncUpdateMutationToColla, u = a.map((h) => ({
|
|
509
509
|
id: F.id,
|
|
510
510
|
params: {
|
|
511
511
|
unitId: r,
|
|
512
512
|
subUnitId: i,
|
|
513
513
|
commentId: h
|
|
514
514
|
}
|
|
515
|
-
})),
|
|
515
|
+
})), d = c.map(({ children: h, ...l }) => ({
|
|
516
516
|
id: se.id,
|
|
517
517
|
params: {
|
|
518
518
|
unitId: r,
|
|
519
519
|
subUnitId: i,
|
|
520
520
|
comment: {
|
|
521
521
|
...l,
|
|
522
|
-
children:
|
|
522
|
+
children: m ? h : void 0
|
|
523
523
|
},
|
|
524
|
-
sync: !
|
|
524
|
+
sync: !m
|
|
525
525
|
}
|
|
526
526
|
}));
|
|
527
|
-
return { redos:
|
|
527
|
+
return { redos: u, undos: d };
|
|
528
528
|
}
|
|
529
529
|
return { redos: [], undos: [] };
|
|
530
530
|
}
|
|
@@ -554,8 +554,8 @@ var P = function() {
|
|
|
554
554
|
e.indexOf(t[r]) < 0 && Object.prototype.propertyIsEnumerable.call(o, t[r]) && (n[t[r]] = o[t[r]]);
|
|
555
555
|
return n;
|
|
556
556
|
}, xe = Re(function(o, e) {
|
|
557
|
-
var n = o.icon, t = o.id, r = o.className, i = o.extend, s = Qt(o, ["icon", "id", "className", "extend"]),
|
|
558
|
-
return De(n, "".concat(t), { defIds: n.defIds, idSuffix:
|
|
557
|
+
var n = o.icon, t = o.id, r = o.className, i = o.extend, s = Qt(o, ["icon", "id", "className", "extend"]), c = "univerjs-icon univerjs-icon-".concat(t, " ").concat(r || "").trim(), a = Oe("_".concat(tn()));
|
|
558
|
+
return De(n, "".concat(t), { defIds: n.defIds, idSuffix: a.current }, P({ ref: e, className: c }, s), i);
|
|
559
559
|
});
|
|
560
560
|
function De(o, e, n, t, r) {
|
|
561
561
|
return Ue(o.tag, P(P({ key: e }, Xt(o, n, r)), t), (en(o, n).children || []).map(function(i, s) {
|
|
@@ -567,8 +567,8 @@ function Xt(o, e, n) {
|
|
|
567
567
|
n != null && n.colorChannel1 && t.fill === "colorChannel1" && (t.fill = n.colorChannel1);
|
|
568
568
|
var r = e.defIds;
|
|
569
569
|
return !r || r.length === 0 || (o.tag === "use" && t["xlink:href"] && (t["xlink:href"] = t["xlink:href"] + e.idSuffix), Object.entries(t).forEach(function(i) {
|
|
570
|
-
var s = i[0],
|
|
571
|
-
typeof
|
|
570
|
+
var s = i[0], c = i[1];
|
|
571
|
+
typeof c == "string" && (t[s] = c.replace(/url\(#(.*)\)/, "url(#$1".concat(e.idSuffix, ")")));
|
|
572
572
|
})), t;
|
|
573
573
|
}
|
|
574
574
|
function en(o, e) {
|
|
@@ -599,17 +599,17 @@ var re = { exports: {} }, j = {};
|
|
|
599
599
|
* This source code is licensed under the MIT license found in the
|
|
600
600
|
* LICENSE file in the root directory of this source tree.
|
|
601
601
|
*/
|
|
602
|
-
var
|
|
602
|
+
var ve;
|
|
603
603
|
function rn() {
|
|
604
|
-
if (
|
|
605
|
-
|
|
604
|
+
if (ve) return j;
|
|
605
|
+
ve = 1;
|
|
606
606
|
var o = Rt, e = Symbol.for("react.element"), n = Symbol.for("react.fragment"), t = Object.prototype.hasOwnProperty, r = o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, i = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
607
|
-
function s(
|
|
608
|
-
var
|
|
609
|
-
|
|
610
|
-
for (
|
|
611
|
-
if (
|
|
612
|
-
return { $$typeof: e, type:
|
|
607
|
+
function s(c, a, m) {
|
|
608
|
+
var u, d = {}, h = null, l = null;
|
|
609
|
+
m !== void 0 && (h = "" + m), a.key !== void 0 && (h = "" + a.key), a.ref !== void 0 && (l = a.ref);
|
|
610
|
+
for (u in a) t.call(a, u) && !i.hasOwnProperty(u) && (d[u] = a[u]);
|
|
611
|
+
if (c && c.defaultProps) for (u in a = c.defaultProps, a) d[u] === void 0 && (d[u] = a[u]);
|
|
612
|
+
return { $$typeof: e, type: c, key: h, ref: l, props: d, _owner: r.current };
|
|
613
613
|
}
|
|
614
614
|
return j.Fragment = n, j.jsx = s, j.jsxs = s, j;
|
|
615
615
|
}
|
|
@@ -622,11 +622,11 @@ const sn = () => {
|
|
|
622
622
|
const o = R(N), e = R(O), n = A(e.activePopup$), t = R(x);
|
|
623
623
|
if (A(t.commentUpdate$), !n)
|
|
624
624
|
return null;
|
|
625
|
-
const { row: r, col: i, unitId: s, subUnitId:
|
|
625
|
+
const { row: r, col: i, unitId: s, subUnitId: c, trigger: a } = n, m = t.getByLocation(s, c, r, i), u = `${Ge.chatAtABC(i)}${r + 1}`, d = () => {
|
|
626
626
|
e.hidePopup();
|
|
627
627
|
}, h = (l) => {
|
|
628
|
-
var
|
|
629
|
-
return (U = (S = (
|
|
628
|
+
var f, S, U;
|
|
629
|
+
return (U = (S = (f = o.getCurrentUnitForType(b.UNIVER_SHEET)) == null ? void 0 : f.getSheetBySheetId(l)) == null ? void 0 : S.getName()) != null ? U : "";
|
|
630
630
|
};
|
|
631
631
|
return /* @__PURE__ */ Ae.jsx(
|
|
632
632
|
it,
|
|
@@ -635,27 +635,27 @@ const sn = () => {
|
|
|
635
635
|
e.persistPopup();
|
|
636
636
|
},
|
|
637
637
|
prefix: "cell",
|
|
638
|
-
id:
|
|
638
|
+
id: m,
|
|
639
639
|
unitId: s,
|
|
640
|
-
subUnitId:
|
|
640
|
+
subUnitId: c,
|
|
641
641
|
type: b.UNIVER_SHEET,
|
|
642
|
-
refStr:
|
|
643
|
-
onClose:
|
|
642
|
+
refStr: u,
|
|
643
|
+
onClose: d,
|
|
644
644
|
getSubUnitName: h,
|
|
645
|
-
autoFocus:
|
|
645
|
+
autoFocus: a === "context-menu"
|
|
646
646
|
}
|
|
647
647
|
);
|
|
648
|
-
},
|
|
648
|
+
}, cn = () => {
|
|
649
649
|
var g;
|
|
650
|
-
const o = R(Te), e = R(N), n = R(O), t = e.getCurrentUnitForType(b.UNIVER_SHEET), r = t.getUnitId(), i = R(
|
|
651
|
-
const I = t.getSheets(),
|
|
650
|
+
const o = R(Te), e = R(N), n = R(O), t = e.getCurrentUnitForType(b.UNIVER_SHEET), r = t.getUnitId(), i = R(ce), s = Ot(() => t.activeSheet$.pipe(wt((p) => p == null ? void 0 : p.getSheetId())), [t.activeSheet$]), c = A(s, (g = t.getActiveSheet()) == null ? void 0 : g.getSheetId()), a = Oe(), m = R(ae), u = A(m.activeCommentId$), d = A(m.panelVisible$, m.panelVisible), h = pe((p) => {
|
|
651
|
+
const I = t.getSheets(), v = {};
|
|
652
652
|
I.forEach((T, C) => {
|
|
653
|
-
|
|
653
|
+
v[T.getSheetId()] = C;
|
|
654
654
|
});
|
|
655
655
|
const M = (T) => T.map((C) => {
|
|
656
|
-
var
|
|
657
|
-
const y = V(C.ref),
|
|
658
|
-
return { ...C, p:
|
|
656
|
+
var me;
|
|
657
|
+
const y = V(C.ref), Le = [(me = v[C.subUnitId]) != null ? me : 0, y.row, y.column];
|
|
658
|
+
return { ...C, p: Le };
|
|
659
659
|
}).sort((C, y) => C.p[0] === y.p[0] ? C.p[1] === y.p[1] ? C.p[2] - y.p[2] : C.p[1] - y.p[1] : C.p[0] - y.p[0]);
|
|
660
660
|
return [
|
|
661
661
|
...M(p.filter((T) => !T.resolved)),
|
|
@@ -663,14 +663,14 @@ const sn = () => {
|
|
|
663
663
|
];
|
|
664
664
|
}, [t]), l = pe((p) => {
|
|
665
665
|
var I;
|
|
666
|
-
if (p.unitId === r && p.subUnitId ===
|
|
667
|
-
const { row:
|
|
666
|
+
if (p.unitId === r && p.subUnitId === c && !p.resolved) {
|
|
667
|
+
const { row: v, column: M } = V(p.ref), T = t.getSheetBySheetId(p.subUnitId), C = (I = T == null ? void 0 : T.getMergedCell(v, M)) != null ? I : {
|
|
668
668
|
startColumn: M,
|
|
669
669
|
endColumn: M,
|
|
670
|
-
startRow:
|
|
671
|
-
endRow:
|
|
670
|
+
startRow: v,
|
|
671
|
+
endRow: v
|
|
672
672
|
};
|
|
673
|
-
if (!Number.isNaN(
|
|
673
|
+
if (!Number.isNaN(v) && !Number.isNaN(M))
|
|
674
674
|
return o.addShape({
|
|
675
675
|
range: C,
|
|
676
676
|
style: {
|
|
@@ -683,28 +683,28 @@ const sn = () => {
|
|
|
683
683
|
primary: null
|
|
684
684
|
});
|
|
685
685
|
}
|
|
686
|
-
}, [o,
|
|
687
|
-
var I,
|
|
688
|
-
return (
|
|
686
|
+
}, [o, c, r]), f = (p) => {
|
|
687
|
+
var I, v;
|
|
688
|
+
return (v = (I = t.getSheetBySheetId(p)) == null ? void 0 : I.getName()) != null ? v : "";
|
|
689
689
|
}, S = () => {
|
|
690
|
-
i.executeCommand(
|
|
690
|
+
i.executeCommand(H.id);
|
|
691
691
|
}, U = (p) => {
|
|
692
|
-
|
|
692
|
+
u && u.unitId === p.unitId && u.subUnitId === p.subUnitId && u.commentId === p.id || (a.current && (o.removeShape(a.current), a.current = null), a.current = l(p));
|
|
693
693
|
}, D = () => {
|
|
694
|
-
|
|
694
|
+
a.current && (o.removeShape(a.current), a.current = null);
|
|
695
695
|
}, ee = (p, I) => {
|
|
696
696
|
I && n.hidePopup();
|
|
697
697
|
};
|
|
698
698
|
return Ut(() => {
|
|
699
|
-
!
|
|
700
|
-
}, [o,
|
|
699
|
+
!d && a.current && o.removeShape(a.current);
|
|
700
|
+
}, [o, d]), /* @__PURE__ */ Ae.jsx(
|
|
701
701
|
st,
|
|
702
702
|
{
|
|
703
703
|
unitId: r,
|
|
704
704
|
subUnitId$: s,
|
|
705
705
|
type: b.UNIVER_SHEET,
|
|
706
706
|
onAdd: S,
|
|
707
|
-
getSubUnitName:
|
|
707
|
+
getSubUnitName: f,
|
|
708
708
|
onResolve: ee,
|
|
709
709
|
sortComments: h,
|
|
710
710
|
onItemEnter: U,
|
|
@@ -712,10 +712,10 @@ const sn = () => {
|
|
|
712
712
|
onDeleteComment: () => (D(), !0)
|
|
713
713
|
}
|
|
714
714
|
);
|
|
715
|
-
},
|
|
716
|
-
id:
|
|
715
|
+
}, an = (o) => ({
|
|
716
|
+
id: H.id,
|
|
717
717
|
type: Me.BUTTON,
|
|
718
|
-
icon:
|
|
718
|
+
icon: de,
|
|
719
719
|
title: "sheetThreadComment.menu.addComment",
|
|
720
720
|
hidden$: we(o, b.UNIVER_SHEET),
|
|
721
721
|
disabled$: be(o, {
|
|
@@ -723,10 +723,10 @@ const sn = () => {
|
|
|
723
723
|
worksheetTypes: [Q],
|
|
724
724
|
rangeTypes: [X]
|
|
725
725
|
})
|
|
726
|
-
}),
|
|
727
|
-
id:
|
|
726
|
+
}), un = (o) => ({
|
|
727
|
+
id: Pe.id,
|
|
728
728
|
type: Me.BUTTON,
|
|
729
|
-
icon:
|
|
729
|
+
icon: de,
|
|
730
730
|
tooltip: "sheetThreadComment.menu.commentManagement",
|
|
731
731
|
disabled$: be(o, {
|
|
732
732
|
workbookTypes: [K],
|
|
@@ -734,22 +734,22 @@ const sn = () => {
|
|
|
734
734
|
rangeTypes: [X]
|
|
735
735
|
}),
|
|
736
736
|
hidden$: we(o, b.UNIVER_SHEET)
|
|
737
|
-
}),
|
|
738
|
-
id:
|
|
737
|
+
}), dn = {
|
|
738
|
+
id: H.id,
|
|
739
739
|
binding: Ct.M | le.CTRL_COMMAND | le.ALT,
|
|
740
|
-
preconditions:
|
|
741
|
-
},
|
|
740
|
+
preconditions: ft
|
|
741
|
+
}, mn = {
|
|
742
742
|
[St.OTHERS]: {
|
|
743
|
-
[
|
|
743
|
+
[Pe.id]: {
|
|
744
744
|
order: 1,
|
|
745
|
-
menuItemFactory:
|
|
745
|
+
menuItemFactory: un
|
|
746
746
|
}
|
|
747
747
|
},
|
|
748
748
|
[gt.MAIN_AREA]: {
|
|
749
749
|
[It.OTHERS]: {
|
|
750
|
-
[
|
|
750
|
+
[H.id]: {
|
|
751
751
|
order: 0,
|
|
752
|
-
menuItemFactory:
|
|
752
|
+
menuItemFactory: an
|
|
753
753
|
}
|
|
754
754
|
}
|
|
755
755
|
}
|
|
@@ -764,16 +764,16 @@ let J = class extends $ {
|
|
|
764
764
|
super(), this._menuManagerService = o, this._componentManager = e, this._shortcutService = n, this._initMenu(), this._initShortcut(), this._initComponent();
|
|
765
765
|
}
|
|
766
766
|
_initShortcut() {
|
|
767
|
-
this._shortcutService.registerShortcut(
|
|
767
|
+
this._shortcutService.registerShortcut(dn);
|
|
768
768
|
}
|
|
769
769
|
_initMenu() {
|
|
770
|
-
this._menuManagerService.mergeMenu(
|
|
770
|
+
this._menuManagerService.mergeMenu(mn);
|
|
771
771
|
}
|
|
772
772
|
_initComponent() {
|
|
773
773
|
[
|
|
774
774
|
[$e, sn],
|
|
775
|
-
[
|
|
776
|
-
[
|
|
775
|
+
[ct, cn],
|
|
776
|
+
[de, je]
|
|
777
777
|
].forEach(([o, e]) => {
|
|
778
778
|
this._componentManager.register(o, e);
|
|
779
779
|
});
|
|
@@ -784,17 +784,17 @@ J = pn([
|
|
|
784
784
|
oe(1, _(Pt)),
|
|
785
785
|
oe(2, bt)
|
|
786
786
|
], J);
|
|
787
|
-
var Ve = Object.defineProperty, _n = Object.getOwnPropertyDescriptor,
|
|
787
|
+
var Ve = Object.defineProperty, _n = Object.getOwnPropertyDescriptor, fn = (o, e, n) => e in o ? Ve(o, e, { enumerable: !0, configurable: !0, writable: !0, value: n }) : o[e] = n, vn = (o, e, n, t) => {
|
|
788
788
|
for (var r = t > 1 ? void 0 : t ? _n(e, n) : e, i = o.length - 1, s; i >= 0; i--)
|
|
789
789
|
(s = o[i]) && (r = (t ? s(e, n, r) : s(r)) || r);
|
|
790
790
|
return t && r && Ve(e, n, r), r;
|
|
791
|
-
}, ie = (o, e) => (n, t) => e(n, t, o),
|
|
791
|
+
}, ie = (o, e) => (n, t) => e(n, t, o), He = (o, e, n) => fn(o, typeof e != "symbol" ? e + "" : e, n);
|
|
792
792
|
let Y = class extends Ke {
|
|
793
|
-
constructor(o =
|
|
793
|
+
constructor(o = fe, e, n, t) {
|
|
794
794
|
super(), this._config = o, this._injector = e, this._commandService = n, this._configService = t;
|
|
795
795
|
const { menu: r, ...i } = Qe(
|
|
796
796
|
{},
|
|
797
|
-
|
|
797
|
+
fe,
|
|
798
798
|
this._config
|
|
799
799
|
);
|
|
800
800
|
r && this._configService.setConfig("menu", r, { merge: !0 }), this._configService.setConfig(Dt, i);
|
|
@@ -810,7 +810,7 @@ let Y = class extends Ke {
|
|
|
810
810
|
[O]
|
|
811
811
|
].forEach((o) => {
|
|
812
812
|
this._injector.add(o);
|
|
813
|
-
}), [
|
|
813
|
+
}), [H].forEach((o) => {
|
|
814
814
|
this._commandService.registerCommand(o);
|
|
815
815
|
}), this._injector.get(J);
|
|
816
816
|
}
|
|
@@ -821,12 +821,12 @@ let Y = class extends Ke {
|
|
|
821
821
|
this._injector.get(Z), this._injector.get(z), this._injector.get(q);
|
|
822
822
|
}
|
|
823
823
|
};
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
Y =
|
|
827
|
-
Je(
|
|
824
|
+
He(Y, "pluginName", Ne);
|
|
825
|
+
He(Y, "type", b.UNIVER_SHEET);
|
|
826
|
+
Y = vn([
|
|
827
|
+
Je(at, ot),
|
|
828
828
|
ie(1, _(Ye)),
|
|
829
|
-
ie(2, _(
|
|
829
|
+
ie(2, _(ce)),
|
|
830
830
|
ie(3, Xe)
|
|
831
831
|
], Y);
|
|
832
832
|
export {
|
|
@@ -837,8 +837,8 @@ export {
|
|
|
837
837
|
Vn as ResolveCommentCommand,
|
|
838
838
|
Ne as SHEETS_THREAD_COMMENT,
|
|
839
839
|
O as SheetsThreadCommentPopupService,
|
|
840
|
-
|
|
840
|
+
H as ShowAddSheetCommentModalOperation,
|
|
841
841
|
Y as UniverSheetsThreadCommentUIPlugin,
|
|
842
842
|
$n as UniverThreadCommentUIPlugin,
|
|
843
|
-
|
|
843
|
+
Hn as UpdateCommentCommand
|
|
844
844
|
};
|