@univerjs/sheets-conditional-formatting-ui 0.8.0-beta.0 → 0.8.0-beta.1
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 +1 -1
- package/lib/es/index.js +1481 -1430
- package/lib/index.css +1 -1
- package/lib/index.js +1481 -1430
- package/lib/types/components/color-picker/index.d.ts +3 -18
- package/lib/umd/index.js +1 -1
- package/package.json +12 -12
package/lib/index.js
CHANGED
|
@@ -1,125 +1,125 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
import { CommandType as
|
|
5
|
-
import { ConditionalFormattingRuleModel as Q, CFSubRuleType as F, CFRuleType as
|
|
6
|
-
import { getSheetCommandTarget as
|
|
7
|
-
import { useDependency as
|
|
8
|
-
import { jsx as c, jsxs as k, Fragment as
|
|
9
|
-
import { forwardRef as
|
|
10
|
-
import { Dropdown as
|
|
11
|
-
import { serializeRange as
|
|
12
|
-
import { FormulaEditor as Mt, RangeSelector as
|
|
13
|
-
import { useHighlightRange as
|
|
14
|
-
import { Observable as
|
|
15
|
-
import { IRenderManagerService as
|
|
16
|
-
import { bufferTime as
|
|
1
|
+
var lr = Object.defineProperty;
|
|
2
|
+
var cr = (t, e, r) => e in t ? lr(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r;
|
|
3
|
+
var Se = (t, e, r) => cr(t, typeof e != "symbol" ? e + "" : e, r);
|
|
4
|
+
import { CommandType as me, ICommandService as te, IUniverInstanceService as Z, ColorKit as mn, BooleanNumber as le, LocaleService as re, UniverInstanceType as A, Tools as Bt, get as ur, set as dr, createInterceptorKey as fn, InterceptorManager as hr, Inject as P, Disposable as ue, Injector as fe, Rectangle as ye, generateRandomId as vr, ObjectMatrix as Me, Range as be, toDisposable as pn, InterceptorEffectEnum as gr, DependentOn as Cn, IConfigService as yn, Plugin as bn, merge as In, registerDependencies as mr, touchDependencies as kt } from "@univerjs/core";
|
|
5
|
+
import { ConditionalFormattingRuleModel as Q, CFSubRuleType as F, CFRuleType as L, AddConditionalRuleMutation as se, CFNumberOperator as U, getColorScaleFromValue as fr, iconMap as Ve, DEFAULT_BG_COLOR as pr, DEFAULT_FONT_COLOR as Cr, defaultDataBarPositiveColor as Ke, defaultDataBarNativeColor as Xe, CFValueType as D, createDefaultValueByValueType as Je, removeUndefinedAttr as yr, createDefaultValue as mt, CFTextOperator as H, CFTimePeriodOperator as ve, iconGroup as br, getOppositeOperator as Ht, compareWithNumber as Ir, EMPTY_ICON_TYPE as Sr, SetCfCommand as _r, AddCfCommand as Sn, SetConditionalRuleMutation as _e, DeleteConditionalRuleMutation as we, MoveConditionalRuleMutation as _n, ClearWorksheetCfCommand as wn, DeleteCfCommand as Yt, MoveCfCommand as wr, ClearRangeCfCommand as Rr, createDefaultRule as xe, ConditionalFormattingViewModel as it, SHEET_CONDITIONAL_FORMATTING_PLUGIN as st, DeleteConditionalRuleMutationUndoFactory as $e, AddConditionalRuleMutationUndoFactory as Rn, setConditionalRuleMutationUndoFactory as Ae, isRangesEqual as Tr, ConditionalFormattingService as Tn, DEFAULT_PADDING as xr, DEFAULT_WIDTH as Er, UniverSheetsConditionalFormattingPlugin as xn, CONDITIONAL_FORMATTING_VIEWPORT_CACHE_LENGTH as Nr } from "@univerjs/sheets-conditional-formatting";
|
|
6
|
+
import { getSheetCommandTarget as Ie, SheetsSelectionsService as je, RemoveSheetMutation as Mr, SetWorksheetActiveOperation as Wt, setEndForRange as Vr, SetSelectionsOperation as kr, checkRangesEditablePermission as ft, rangeToDiscreteRange as Fr, findAllRectangle as pt, createTopMatrixFromMatrix as Ct, SheetPermissionCheckController as Lr, WorksheetEditPermission as En, WorksheetSetCellStylePermission as Nn, RangeProtectionPermissionEditPoint as Mn, WorkbookEditablePermission as Vn, RefRangeService as Ur, handleDefaultRangeChangeWithEffectRefCommands as Pr, SheetInterceptorService as qt, INTERCEPTOR_POINT as Or, ClearSelectionFormatCommand as Dr, ClearSelectionAllCommand as $r, RangeMergeUtil as Ar, AFTER_CELL_EDIT as Hr } from "@univerjs/sheets";
|
|
7
|
+
import { useDependency as q, useSidebarClick as Nt, ILayoutService as jr, useScrollYOverContainer as Br, ISidebarService as kn, useObservable as Wr, ComponentManager as qr, getMenuHiddenObservable as Gr, MenuItemType as Zr, RibbonDataGroup as zr, IMenuManagerService as Yr } from "@univerjs/ui";
|
|
8
|
+
import { jsx as c, jsxs as k, Fragment as jt } from "react/jsx-runtime";
|
|
9
|
+
import { forwardRef as oe, useRef as ge, createElement as de, useMemo as J, useState as N, useEffect as K } from "react";
|
|
10
|
+
import { Dropdown as Gt, clsx as X, ColorPicker as Kr, borderClassName as Be, Select as ce, InputNumber as ke, RadioGroup as Xr, Radio as Kt, Checkbox as yt, Input as Jr, Button as Xt, Tooltip as Jt, ReactGridLayout as Qr } from "@univerjs/design";
|
|
11
|
+
import { serializeRange as Fn, deserializeRangeWithSheet as ei } from "@univerjs/engine-formula";
|
|
12
|
+
import { FormulaEditor as Mt, RangeSelector as ti } from "@univerjs/sheets-formula-ui";
|
|
13
|
+
import { useHighlightRange as ni, ISheetClipboardService as ri, COPY_TYPE as Qt, PREDEFINED_HOOK_NAME as Ft, virtualizeDiscreteRanges as Ln, getRepeatRange as ii, SheetSkeletonManagerService as Un, IAutoFillService as si, APPLY_TYPE as Lt, getAutoFillRepeatRange as oi, getCurrentRangeDisable$ as ai, IFormatPainterService as li, FormatPainterStatus as Ut } from "@univerjs/sheets-ui";
|
|
14
|
+
import { Observable as Ne, debounceTime as en, merge as Pn } from "rxjs";
|
|
15
|
+
import { IRenderManagerService as On } from "@univerjs/engine-render";
|
|
16
|
+
import { bufferTime as ci, filter as tn, debounceTime as nn } from "rxjs/operators";
|
|
17
17
|
const Dn = {
|
|
18
|
-
type:
|
|
18
|
+
type: me.COMMAND,
|
|
19
19
|
id: "sheet.command.add-average-conditional-rule",
|
|
20
20
|
handler(t, e) {
|
|
21
21
|
if (!e)
|
|
22
22
|
return !1;
|
|
23
|
-
const { ranges: r, style: n, stopIfTrue: i, operator: s } = e, o = t.get(Q),
|
|
23
|
+
const { ranges: r, style: n, stopIfTrue: i, operator: s } = e, o = t.get(Q), u = t.get(te), a = t.get(Z), h = Ie(a);
|
|
24
24
|
if (!h) return !1;
|
|
25
|
-
const { unitId: l, subUnitId:
|
|
25
|
+
const { unitId: l, subUnitId: d } = h, v = o.createCfId(l, d), p = {
|
|
26
26
|
ranges: r,
|
|
27
|
-
cfId:
|
|
27
|
+
cfId: v,
|
|
28
28
|
stopIfTrue: !!i,
|
|
29
29
|
rule: {
|
|
30
|
-
type:
|
|
30
|
+
type: L.highlightCell,
|
|
31
31
|
subType: F.average,
|
|
32
32
|
operator: s,
|
|
33
33
|
style: n
|
|
34
34
|
}
|
|
35
35
|
};
|
|
36
|
-
return
|
|
36
|
+
return u.executeCommand(se.id, { unitId: l, subUnitId: d, rule: p });
|
|
37
37
|
}
|
|
38
38
|
}, $n = {
|
|
39
|
-
type:
|
|
39
|
+
type: me.COMMAND,
|
|
40
40
|
id: "sheet.command.add-color-scale-conditional-rule",
|
|
41
41
|
handler(t, e) {
|
|
42
42
|
if (!e)
|
|
43
43
|
return !1;
|
|
44
|
-
const { ranges: r, config: n, stopIfTrue: i } = e, s = t.get(Q), o = t.get(te),
|
|
44
|
+
const { ranges: r, config: n, stopIfTrue: i } = e, s = t.get(Q), o = t.get(te), u = t.get(Z), a = Ie(u);
|
|
45
45
|
if (!a) return !1;
|
|
46
|
-
const { unitId: h, subUnitId: l } = a,
|
|
46
|
+
const { unitId: h, subUnitId: l } = a, d = s.createCfId(h, l), v = {
|
|
47
47
|
ranges: r,
|
|
48
|
-
cfId:
|
|
48
|
+
cfId: d,
|
|
49
49
|
stopIfTrue: !!i,
|
|
50
50
|
rule: {
|
|
51
|
-
type:
|
|
51
|
+
type: L.colorScale,
|
|
52
52
|
config: n
|
|
53
53
|
}
|
|
54
54
|
};
|
|
55
|
-
return o.executeCommand(se.id, { unitId: h, subUnitId: l, rule:
|
|
55
|
+
return o.executeCommand(se.id, { unitId: h, subUnitId: l, rule: v });
|
|
56
56
|
}
|
|
57
|
-
},
|
|
58
|
-
type:
|
|
57
|
+
}, An = {
|
|
58
|
+
type: me.COMMAND,
|
|
59
59
|
id: "sheet.command.add-data-bar-conditional-rule",
|
|
60
60
|
handler(t, e) {
|
|
61
61
|
if (!e)
|
|
62
62
|
return !1;
|
|
63
|
-
const { ranges: r, min: n, max: i, nativeColor: s, positiveColor: o, isGradient:
|
|
64
|
-
if (!
|
|
65
|
-
const { unitId: p, subUnitId:
|
|
63
|
+
const { ranges: r, min: n, max: i, nativeColor: s, positiveColor: o, isGradient: u, stopIfTrue: a, isShowValue: h } = e, l = t.get(Q), d = t.get(Z), v = Ie(d);
|
|
64
|
+
if (!v) return !1;
|
|
65
|
+
const { unitId: p, subUnitId: y } = v, f = t.get(te), w = l.createCfId(p, y), I = {
|
|
66
66
|
ranges: r,
|
|
67
|
-
cfId:
|
|
67
|
+
cfId: w,
|
|
68
68
|
stopIfTrue: !!a,
|
|
69
69
|
rule: {
|
|
70
|
-
type:
|
|
70
|
+
type: L.dataBar,
|
|
71
71
|
isShowValue: h,
|
|
72
72
|
config: {
|
|
73
73
|
min: n,
|
|
74
74
|
max: i,
|
|
75
75
|
nativeColor: s,
|
|
76
76
|
positiveColor: o,
|
|
77
|
-
isGradient:
|
|
77
|
+
isGradient: u
|
|
78
78
|
}
|
|
79
79
|
}
|
|
80
80
|
};
|
|
81
|
-
return f.executeCommand(se.id, { unitId: p, subUnitId:
|
|
81
|
+
return f.executeCommand(se.id, { unitId: p, subUnitId: y, rule: I });
|
|
82
82
|
}
|
|
83
83
|
}, Hn = {
|
|
84
|
-
type:
|
|
84
|
+
type: me.COMMAND,
|
|
85
85
|
id: "sheet.command.add-duplicate-values-conditional-rule",
|
|
86
86
|
handler(t, e) {
|
|
87
87
|
if (!e)
|
|
88
88
|
return !1;
|
|
89
|
-
const { ranges: r, style: n, stopIfTrue: i } = e, s = t.get(Q), o = t.get(te),
|
|
89
|
+
const { ranges: r, style: n, stopIfTrue: i } = e, s = t.get(Q), o = t.get(te), u = t.get(Z), a = Ie(u);
|
|
90
90
|
if (!a) return !1;
|
|
91
|
-
const { unitId: h, subUnitId: l } = a,
|
|
91
|
+
const { unitId: h, subUnitId: l } = a, d = s.createCfId(h, l), v = {
|
|
92
92
|
ranges: r,
|
|
93
|
-
cfId:
|
|
93
|
+
cfId: d,
|
|
94
94
|
stopIfTrue: !!i,
|
|
95
95
|
rule: {
|
|
96
|
-
type:
|
|
96
|
+
type: L.highlightCell,
|
|
97
97
|
subType: F.duplicateValues,
|
|
98
98
|
style: n
|
|
99
99
|
}
|
|
100
100
|
};
|
|
101
|
-
return o.executeCommand(se.id, { unitId: h, subUnitId: l, rule:
|
|
101
|
+
return o.executeCommand(se.id, { unitId: h, subUnitId: l, rule: v });
|
|
102
102
|
}
|
|
103
|
-
},
|
|
104
|
-
type:
|
|
103
|
+
}, jn = {
|
|
104
|
+
type: me.COMMAND,
|
|
105
105
|
id: "sheet.command.add-number-conditional-rule",
|
|
106
106
|
handler(t, e) {
|
|
107
107
|
if (!e)
|
|
108
108
|
return !1;
|
|
109
|
-
const { ranges: r, style: n, stopIfTrue: i, operator: s, value: o } = e,
|
|
109
|
+
const { ranges: r, style: n, stopIfTrue: i, operator: s, value: o } = e, u = t.get(Q), a = t.get(te), h = t.get(Z), l = Ie(h);
|
|
110
110
|
if (!l) return !1;
|
|
111
|
-
const { unitId:
|
|
112
|
-
let
|
|
113
|
-
if ([
|
|
111
|
+
const { unitId: d, subUnitId: v } = l, p = u.createCfId(d, v);
|
|
112
|
+
let y;
|
|
113
|
+
if ([U.between, U.notBetween].includes(s)) {
|
|
114
114
|
const f = o;
|
|
115
115
|
if (f.length !== 2 || !Array.isArray(f))
|
|
116
116
|
return !1;
|
|
117
|
-
|
|
117
|
+
y = {
|
|
118
118
|
ranges: r,
|
|
119
119
|
cfId: p,
|
|
120
120
|
stopIfTrue: !!i,
|
|
121
121
|
rule: {
|
|
122
|
-
type:
|
|
122
|
+
type: L.highlightCell,
|
|
123
123
|
subType: F.number,
|
|
124
124
|
operator: s,
|
|
125
125
|
style: n,
|
|
@@ -130,12 +130,12 @@ const Dn = {
|
|
|
130
130
|
const f = o;
|
|
131
131
|
if (typeof f != "number")
|
|
132
132
|
return !1;
|
|
133
|
-
|
|
133
|
+
y = {
|
|
134
134
|
ranges: r,
|
|
135
135
|
cfId: p,
|
|
136
136
|
stopIfTrue: !!i,
|
|
137
137
|
rule: {
|
|
138
|
-
type:
|
|
138
|
+
type: L.highlightCell,
|
|
139
139
|
subType: F.number,
|
|
140
140
|
operator: s,
|
|
141
141
|
style: n,
|
|
@@ -143,231 +143,277 @@ const Dn = {
|
|
|
143
143
|
}
|
|
144
144
|
};
|
|
145
145
|
}
|
|
146
|
-
return a.executeCommand(se.id, { unitId:
|
|
146
|
+
return a.executeCommand(se.id, { unitId: d, subUnitId: v, rule: y });
|
|
147
147
|
}
|
|
148
|
-
},
|
|
149
|
-
type:
|
|
148
|
+
}, Bn = {
|
|
149
|
+
type: me.COMMAND,
|
|
150
150
|
id: "sheet.command.add-rank-conditional-rule",
|
|
151
151
|
handler(t, e) {
|
|
152
152
|
if (!e)
|
|
153
153
|
return !1;
|
|
154
|
-
const { ranges: r, style: n, stopIfTrue: i, isPercent: s, isBottom: o, value:
|
|
155
|
-
if (!
|
|
156
|
-
const { unitId:
|
|
154
|
+
const { ranges: r, style: n, stopIfTrue: i, isPercent: s, isBottom: o, value: u } = e, a = t.get(Q), h = t.get(Z), l = t.get(te), d = Ie(h);
|
|
155
|
+
if (!d) return !1;
|
|
156
|
+
const { unitId: v, subUnitId: p } = d, y = a.createCfId(v, p), f = {
|
|
157
157
|
ranges: r,
|
|
158
|
-
cfId:
|
|
158
|
+
cfId: y,
|
|
159
159
|
stopIfTrue: !!i,
|
|
160
160
|
rule: {
|
|
161
|
-
type:
|
|
161
|
+
type: L.highlightCell,
|
|
162
162
|
subType: F.rank,
|
|
163
163
|
isPercent: s,
|
|
164
164
|
isBottom: o,
|
|
165
165
|
style: n,
|
|
166
|
-
value:
|
|
166
|
+
value: u
|
|
167
167
|
}
|
|
168
168
|
};
|
|
169
|
-
return l.executeCommand(se.id, { unitId:
|
|
169
|
+
return l.executeCommand(se.id, { unitId: v, subUnitId: p, rule: f });
|
|
170
170
|
}
|
|
171
|
-
},
|
|
172
|
-
type:
|
|
171
|
+
}, Wn = {
|
|
172
|
+
type: me.COMMAND,
|
|
173
173
|
id: "sheet.command.add-text-conditional-rule",
|
|
174
174
|
handler(t, e) {
|
|
175
175
|
if (!e)
|
|
176
176
|
return !1;
|
|
177
|
-
const { ranges: r, style: n, stopIfTrue: i, operator: s, value: o } = e,
|
|
177
|
+
const { ranges: r, style: n, stopIfTrue: i, operator: s, value: o } = e, u = t.get(Q), a = t.get(Z), h = Ie(a);
|
|
178
178
|
if (!h) return !1;
|
|
179
|
-
const { unitId: l, subUnitId:
|
|
179
|
+
const { unitId: l, subUnitId: d } = h, v = t.get(te), p = u.createCfId(l, d), y = {
|
|
180
180
|
ranges: r,
|
|
181
181
|
cfId: p,
|
|
182
182
|
stopIfTrue: !!i,
|
|
183
183
|
rule: {
|
|
184
|
-
type:
|
|
184
|
+
type: L.highlightCell,
|
|
185
185
|
subType: F.text,
|
|
186
186
|
operator: s,
|
|
187
187
|
style: n,
|
|
188
188
|
value: o
|
|
189
189
|
}
|
|
190
190
|
};
|
|
191
|
-
return
|
|
191
|
+
return v.executeCommand(se.id, { unitId: l, subUnitId: d, rule: y });
|
|
192
192
|
}
|
|
193
|
-
},
|
|
194
|
-
type:
|
|
193
|
+
}, qn = {
|
|
194
|
+
type: me.COMMAND,
|
|
195
195
|
id: "sheet.command.add-time-period-conditional-rule",
|
|
196
196
|
handler(t, e) {
|
|
197
197
|
if (!e)
|
|
198
198
|
return !1;
|
|
199
|
-
const { ranges: r, style: n, stopIfTrue: i, operator: s } = e, o = t.get(Q),
|
|
199
|
+
const { ranges: r, style: n, stopIfTrue: i, operator: s } = e, o = t.get(Q), u = t.get(Z), a = t.get(te), h = Ie(u);
|
|
200
200
|
if (!h) return !1;
|
|
201
|
-
const { unitId: l, subUnitId:
|
|
201
|
+
const { unitId: l, subUnitId: d } = h, v = o.createCfId(l, d), p = {
|
|
202
202
|
ranges: r,
|
|
203
|
-
cfId:
|
|
203
|
+
cfId: v,
|
|
204
204
|
stopIfTrue: !!i,
|
|
205
205
|
rule: {
|
|
206
|
-
type:
|
|
206
|
+
type: L.highlightCell,
|
|
207
207
|
subType: F.timePeriod,
|
|
208
208
|
operator: s,
|
|
209
209
|
style: n
|
|
210
210
|
}
|
|
211
211
|
};
|
|
212
|
-
return a.executeCommand(se.id, { unitId: l, subUnitId:
|
|
212
|
+
return a.executeCommand(se.id, { unitId: l, subUnitId: d, rule: p });
|
|
213
213
|
}
|
|
214
|
-
},
|
|
215
|
-
type:
|
|
214
|
+
}, Gn = {
|
|
215
|
+
type: me.COMMAND,
|
|
216
216
|
id: "sheet.command.add-uniqueValues-conditional-rule",
|
|
217
217
|
handler(t, e) {
|
|
218
218
|
if (!e)
|
|
219
219
|
return !1;
|
|
220
|
-
const { ranges: r, style: n, stopIfTrue: i } = e, s = t.get(Q), o = t.get(
|
|
220
|
+
const { ranges: r, style: n, stopIfTrue: i } = e, s = t.get(Q), o = t.get(Z), u = t.get(te), a = Ie(o);
|
|
221
221
|
if (!a) return !1;
|
|
222
|
-
const { unitId: h, subUnitId: l } = a,
|
|
222
|
+
const { unitId: h, subUnitId: l } = a, d = s.createCfId(h, l), v = {
|
|
223
223
|
ranges: r,
|
|
224
|
-
cfId:
|
|
224
|
+
cfId: d,
|
|
225
225
|
stopIfTrue: !!i,
|
|
226
226
|
rule: {
|
|
227
|
-
type:
|
|
227
|
+
type: L.highlightCell,
|
|
228
228
|
subType: F.uniqueValues,
|
|
229
229
|
style: n
|
|
230
230
|
}
|
|
231
231
|
};
|
|
232
|
-
return
|
|
232
|
+
return u.executeCommand(se.id, { unitId: h, subUnitId: l, rule: v });
|
|
233
233
|
}
|
|
234
234
|
};
|
|
235
|
-
var
|
|
236
|
-
return
|
|
235
|
+
var ae = function() {
|
|
236
|
+
return ae = Object.assign || function(t) {
|
|
237
237
|
for (var e, r = 1, n = arguments.length; r < n; r++) {
|
|
238
238
|
e = arguments[r];
|
|
239
239
|
for (var i in e) Object.prototype.hasOwnProperty.call(e, i) && (t[i] = e[i]);
|
|
240
240
|
}
|
|
241
241
|
return t;
|
|
242
|
-
},
|
|
243
|
-
},
|
|
242
|
+
}, ae.apply(this, arguments);
|
|
243
|
+
}, ui = function(t, e) {
|
|
244
244
|
var r = {};
|
|
245
245
|
for (var n in t) Object.prototype.hasOwnProperty.call(t, n) && e.indexOf(n) < 0 && (r[n] = t[n]);
|
|
246
246
|
if (t != null && typeof Object.getOwnPropertySymbols == "function")
|
|
247
247
|
for (var i = 0, n = Object.getOwnPropertySymbols(t); i < n.length; i++)
|
|
248
248
|
e.indexOf(n[i]) < 0 && Object.prototype.propertyIsEnumerable.call(t, n[i]) && (r[n[i]] = t[n[i]]);
|
|
249
249
|
return r;
|
|
250
|
-
},
|
|
251
|
-
var r = t.icon, n = t.id, i = t.className, s = t.extend, o =
|
|
252
|
-
return Zn(r, "".concat(n), { defIds: r.defIds, idSuffix: a.current },
|
|
250
|
+
}, he = oe(function(t, e) {
|
|
251
|
+
var r = t.icon, n = t.id, i = t.className, s = t.extend, o = ui(t, ["icon", "id", "className", "extend"]), u = "univerjs-icon univerjs-icon-".concat(n, " ").concat(i || "").trim(), a = ge("_".concat(vi()));
|
|
252
|
+
return Zn(r, "".concat(n), { defIds: r.defIds, idSuffix: a.current }, ae({ ref: e, className: u }, o), s);
|
|
253
253
|
});
|
|
254
254
|
function Zn(t, e, r, n, i) {
|
|
255
|
-
return
|
|
255
|
+
return de(t.tag, ae(ae({ key: e }, di(t, r, i)), n), (hi(t, r).children || []).map(function(s, o) {
|
|
256
256
|
return Zn(s, "".concat(e, "-").concat(t.tag, "-").concat(o), r, void 0, i);
|
|
257
257
|
}));
|
|
258
258
|
}
|
|
259
|
-
function
|
|
260
|
-
var n =
|
|
259
|
+
function di(t, e, r) {
|
|
260
|
+
var n = ae({}, t.attrs);
|
|
261
261
|
r != null && r.colorChannel1 && n.fill === "colorChannel1" && (n.fill = r.colorChannel1), t.tag === "mask" && n.id && (n.id = n.id + e.idSuffix), Object.entries(n).forEach(function(s) {
|
|
262
|
-
var o = s[0],
|
|
263
|
-
o === "mask" && typeof
|
|
262
|
+
var o = s[0], u = s[1];
|
|
263
|
+
o === "mask" && typeof u == "string" && (n[o] = u.replace(/url\(#(.*)\)/, "url(#$1".concat(e.idSuffix, ")")));
|
|
264
264
|
});
|
|
265
265
|
var i = e.defIds;
|
|
266
266
|
return !i || i.length === 0 || (t.tag === "use" && n["xlink:href"] && (n["xlink:href"] = n["xlink:href"] + e.idSuffix), Object.entries(n).forEach(function(s) {
|
|
267
|
-
var o = s[0],
|
|
268
|
-
typeof
|
|
267
|
+
var o = s[0], u = s[1];
|
|
268
|
+
typeof u == "string" && (n[o] = u.replace(/url\(#(.*)\)/, "url(#$1".concat(e.idSuffix, ")")));
|
|
269
269
|
})), n;
|
|
270
270
|
}
|
|
271
|
-
function
|
|
271
|
+
function hi(t, e) {
|
|
272
272
|
var r, n = e.defIds;
|
|
273
|
-
return !n || n.length === 0 ? t : t.tag === "defs" && (!((r = t.children) === null || r === void 0) && r.length) ?
|
|
274
|
-
return typeof i.attrs.id == "string" && n && n.
|
|
273
|
+
return !n || n.length === 0 ? t : t.tag === "defs" && (!((r = t.children) === null || r === void 0) && r.length) ? ae(ae({}, t), { children: t.children.map(function(i) {
|
|
274
|
+
return typeof i.attrs.id == "string" && n && n.includes(i.attrs.id) ? ae(ae({}, i), { attrs: ae(ae({}, i.attrs), { id: i.attrs.id + e.idSuffix }) }) : i;
|
|
275
275
|
}) }) : t;
|
|
276
276
|
}
|
|
277
|
-
function
|
|
277
|
+
function vi() {
|
|
278
278
|
return Math.random().toString(36).substring(2, 8);
|
|
279
279
|
}
|
|
280
|
-
|
|
281
|
-
var
|
|
282
|
-
return
|
|
283
|
-
id: "
|
|
280
|
+
he.displayName = "UniverIcon";
|
|
281
|
+
var gi = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M4.65791 1.30005C3.77355 1.30005 3.05664 2.01696 3.05664 2.90132V12.8588C3.05664 13.8755 3.88086 14.6998 4.89759 14.6998H9.1016C11.2233 14.6998 12.9433 12.9798 12.9433 10.8581C12.9433 9.13925 11.8145 7.68407 10.2578 7.1934C10.8806 6.56856 11.2655 5.70659 11.2655 4.75472C11.2655 2.84676 9.71883 1.30005 7.81087 1.30005H4.65791ZM4.25664 2.90132C4.25664 2.6797 4.4363 2.50005 4.65791 2.50005H7.81087C9.05609 2.50005 10.0655 3.5095 10.0655 4.75472C10.0655 5.99993 9.05609 7.00938 7.81087 7.00938H4.25664V2.90132ZM4.25664 12.8588V8.21636H9.1016C10.5606 8.21636 11.7433 9.39909 11.7433 10.8581C11.7433 12.317 10.5606 13.4998 9.1016 13.4998H4.89759C4.5436 13.4998 4.25664 13.2128 4.25664 12.8588Z", fillRule: "evenodd", clipRule: "evenodd" } }] }, zn = oe(function(t, e) {
|
|
282
|
+
return de(he, Object.assign({}, t, {
|
|
283
|
+
id: "bold-icon",
|
|
284
|
+
ref: e,
|
|
285
|
+
icon: gi
|
|
286
|
+
}));
|
|
287
|
+
});
|
|
288
|
+
zn.displayName = "BoldIcon";
|
|
289
|
+
var mi = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M5.3313 1.4667C5.3313 1.13533 5.59993 0.866699 5.9313 0.866699H10.069C10.4004 0.866699 10.669 1.13533 10.669 1.4667C10.669 1.79807 10.4004 2.0667 10.069 2.0667H5.9313C5.59993 2.0667 5.3313 1.79807 5.3313 1.4667Z" } }, { tag: "path", attrs: { fill: "currentColor", d: "M1.09985 3.64443C1.09985 3.31306 1.36848 3.04443 1.69985 3.04443H14.2999C14.6312 3.04443 14.8999 3.31306 14.8999 3.64443C14.8999 3.9758 14.6312 4.24443 14.2999 4.24443H1.69985C1.36848 4.24443 1.09985 3.9758 1.09985 3.64443Z" } }, { tag: "path", attrs: { fill: "currentColor", d: "M6.12398 8.30171C6.35829 8.0674 6.73819 8.0674 6.97251 8.30171L8.00007 9.32928L9.02764 8.30171C9.26195 8.0674 9.64185 8.0674 9.87617 8.30171C10.1105 8.53603 10.1105 8.91593 9.87617 9.15024L8.8486 10.1778L9.87617 11.2054C10.1105 11.4397 10.1105 11.8196 9.87617 12.0539C9.64185 12.2882 9.26195 12.2882 9.02764 12.0539L8.00007 11.0263L6.97251 12.0539C6.73819 12.2882 6.35829 12.2882 6.12398 12.0539C5.88966 11.8196 5.88966 11.4397 6.12398 11.2054L7.15154 10.1778L6.12398 9.15024C5.88966 8.91593 5.88966 8.53603 6.12398 8.30171Z" } }, { tag: "path", attrs: { fill: "currentColor", d: "M4.75332 5.22217C3.86966 5.22217 3.15332 5.93851 3.15332 6.82217V12.5331C3.15332 13.9691 4.31738 15.1332 5.75332 15.1332H10.2465C11.6825 15.1332 12.8465 13.9691 12.8465 12.5331V6.82217C12.8465 5.93851 12.1302 5.22217 11.2465 5.22217H4.75332ZM4.35332 6.82217C4.35332 6.60125 4.53241 6.42217 4.75332 6.42217H11.2465C11.4674 6.42217 11.6465 6.60125 11.6465 6.82217V12.5331C11.6465 13.3063 11.0197 13.9332 10.2465 13.9332H5.75332C4.98012 13.9332 4.35332 13.3063 4.35332 12.5331V6.82217Z", fillRule: "evenodd", clipRule: "evenodd" } }] }, gt = oe(function(t, e) {
|
|
290
|
+
return de(he, Object.assign({}, t, {
|
|
291
|
+
id: "delete-icon",
|
|
292
|
+
ref: e,
|
|
293
|
+
icon: mi
|
|
294
|
+
}));
|
|
295
|
+
});
|
|
296
|
+
gt.displayName = "DeleteIcon";
|
|
297
|
+
var fi = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 17 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "colorChannel1", d: "M1.98682 13.4992C1.98682 12.5603 2.74793 11.7992 3.68682 11.7992H14.2868C15.2257 11.7992 15.9868 12.5603 15.9868 13.4992V13.4992C15.9868 14.4381 15.2257 15.1992 14.2868 15.1992H3.68682C2.74793 15.1992 1.98682 14.4381 1.98682 13.4992V13.4992Z" } }, { tag: "path", attrs: { fill: "currentColor", d: "M10.3014 1.70389C9.85268 0.479568 8.12109 0.479557 7.67238 1.70389L4.72235 9.75326C4.60832 10.0644 4.76811 10.4091 5.07924 10.5231C5.39038 10.6371 5.73504 10.4773 5.84907 10.1662L6.99975 7.02646C7.03588 7.03324 7.07314 7.03679 7.11123 7.03679H10.9778L12.1247 10.1662C12.2387 10.4773 12.5834 10.6371 12.8945 10.5231C13.2057 10.4091 13.3654 10.0644 13.2514 9.75326L10.3014 1.70389ZM10.538 5.83679L9.17467 2.11682C9.11057 1.94192 8.8632 1.94192 8.7991 2.11682L7.43576 5.83679H10.538Z", fillRule: "evenodd", clipRule: "evenodd" } }] }, Yn = oe(function(t, e) {
|
|
298
|
+
return de(he, Object.assign({}, t, {
|
|
299
|
+
id: "font-color-double-icon",
|
|
284
300
|
ref: e,
|
|
285
|
-
icon:
|
|
301
|
+
icon: fi
|
|
286
302
|
}));
|
|
287
303
|
});
|
|
288
|
-
|
|
289
|
-
var
|
|
290
|
-
return
|
|
291
|
-
id: "increase-
|
|
304
|
+
Yn.displayName = "FontColorDoubleIcon";
|
|
305
|
+
var pi = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M8.6 1.99991C8.60001 1.66854 8.33138 1.39991 8.00001 1.3999C7.66864 1.3999 7.40001 1.66853 7.4 1.9999L7.39996 7.3999H1.9999C1.66853 7.3999 1.3999 7.66853 1.3999 7.9999C1.3999 8.33127 1.66853 8.5999 1.9999 8.5999H7.39995L7.3999 13.9999C7.3999 14.3313 7.66853 14.5999 7.9999 14.5999C8.33127 14.5999 8.5999 14.3313 8.5999 13.9999L8.59995 8.5999H13.9999C14.3313 8.5999 14.5999 8.33127 14.5999 7.9999C14.5999 7.66853 14.3313 7.3999 13.9999 7.3999H8.59996L8.6 1.99991Z" } }] }, Kn = oe(function(t, e) {
|
|
306
|
+
return de(he, Object.assign({}, t, {
|
|
307
|
+
id: "increase-icon",
|
|
292
308
|
ref: e,
|
|
293
|
-
icon:
|
|
309
|
+
icon: pi
|
|
294
310
|
}));
|
|
295
311
|
});
|
|
296
|
-
|
|
297
|
-
var
|
|
298
|
-
return
|
|
299
|
-
id: "
|
|
312
|
+
Kn.displayName = "IncreaseIcon";
|
|
313
|
+
var Ci = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M9.80385 1.40005H11.9997C12.3311 1.40005 12.5997 1.66868 12.5997 2.00005C12.5997 2.33143 12.3311 2.60005 11.9997 2.60005H10.1185L7.12251 13.4001H9.33324C9.66461 13.4001 9.93324 13.6687 9.93324 14.0001C9.93324 14.3314 9.66461 14.6001 9.33324 14.6001H6.34785C6.33847 14.6003 6.32905 14.6003 6.31962 14.6001H3.9999C3.66853 14.6001 3.3999 14.3314 3.3999 14.0001C3.3999 13.6687 3.66853 13.4001 3.9999 13.4001H5.87719L8.87322 2.60005H6.66641C6.33504 2.60005 6.06641 2.33143 6.06641 2.00005C6.06641 1.66868 6.33504 1.40005 6.66641 1.40005H9.52916C9.61698 1.37929 9.71064 1.3781 9.80385 1.40005Z" } }] }, Xn = oe(function(t, e) {
|
|
314
|
+
return de(he, Object.assign({}, t, {
|
|
315
|
+
id: "italic-icon",
|
|
300
316
|
ref: e,
|
|
301
|
-
icon:
|
|
317
|
+
icon: Ci
|
|
302
318
|
}));
|
|
303
319
|
});
|
|
304
|
-
|
|
305
|
-
var
|
|
306
|
-
return
|
|
307
|
-
id: "
|
|
320
|
+
Xn.displayName = "ItalicIcon";
|
|
321
|
+
var yi = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M11.3536 6.14645C11.5488 6.34171 11.5488 6.65829 11.3536 6.85355L8.35355 9.85355C8.15829 10.0488 7.84171 10.0488 7.64645 9.85355L4.64645 6.85355C4.45118 6.65829 4.45118 6.34171 4.64645 6.14645C4.84171 5.95118 5.15829 5.95118 5.35355 6.14645L8 8.79289L10.6464 6.14645C10.8417 5.95118 11.1583 5.95118 11.3536 6.14645Z", fillRule: "evenodd", clipRule: "evenodd" } }] }, Zt = oe(function(t, e) {
|
|
322
|
+
return de(he, Object.assign({}, t, {
|
|
323
|
+
id: "more-down-icon",
|
|
308
324
|
ref: e,
|
|
309
|
-
icon:
|
|
325
|
+
icon: yi
|
|
310
326
|
}));
|
|
311
327
|
});
|
|
312
|
-
|
|
313
|
-
var
|
|
314
|
-
return
|
|
315
|
-
id: "
|
|
328
|
+
Zt.displayName = "MoreDownIcon";
|
|
329
|
+
var bi = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 17 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M8.01281 1.36643C8.79386 0.585377 10.0602 0.585378 10.8412 1.36643L12.9223 3.44752C13.7034 4.22857 13.7034 5.4949 12.9223 6.27595L9.36445 9.83383C8.5834 10.6149 7.31707 10.6149 6.53602 9.83383L4.45493 7.75273C3.67388 6.97168 3.67388 5.70535 4.45493 4.9243L8.01281 1.36643ZM9.9927 2.21495C9.68028 1.90253 9.17375 1.90253 8.86133 2.21495L5.30346 5.77283L5.29671 5.77966L10.839 6.66224L12.0738 5.42742C12.3862 5.115 12.3862 4.60847 12.0738 4.29605L9.9927 2.21495Z", fillRule: "evenodd", clipRule: "evenodd" } }, { tag: "path", attrs: { fill: "currentColor", d: "M14.5179 9.48875C14.5179 9.99175 14.1101 10.3995 13.607 10.3995C13.1041 10.3995 12.6963 9.99175 12.6963 9.48875C12.6963 9.1773 13.0455 8.59966 13.3114 8.20487C13.4549 7.99177 13.7591 7.99177 13.9027 8.20486C14.1687 8.59965 14.5179 9.1773 14.5179 9.48875Z" } }, { tag: "path", attrs: { fill: "colorChannel1", d: "M1.98682 13.4992C1.98682 12.5603 2.74793 11.7992 3.68682 11.7992H14.2868C15.2257 11.7992 15.9868 12.5603 15.9868 13.4992V13.4992C15.9868 14.4381 15.2257 15.1992 14.2868 15.1992H3.68682C2.74793 15.1992 1.98682 14.4381 1.98682 13.4992V13.4992Z" } }] }, Jn = oe(function(t, e) {
|
|
330
|
+
return de(he, Object.assign({}, t, {
|
|
331
|
+
id: "paint-bucket-double-icon",
|
|
316
332
|
ref: e,
|
|
317
|
-
icon:
|
|
333
|
+
icon: bi
|
|
318
334
|
}));
|
|
319
335
|
});
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
336
|
+
Jn.displayName = "PaintBucketDoubleIcon";
|
|
337
|
+
var Ii = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "mask", attrs: { id: "mask0_622_8", width: 16, height: 16, x: 0, y: 0, maskUnits: "userSpaceOnUse" }, children: [{ tag: "path", attrs: { fill: "#D9D9D9", d: "M0 0H16V16H0z" } }] }, { tag: "g", attrs: { fill: "currentColor", mask: "url(#mask0_622_8)" }, children: [{ tag: "path", attrs: { d: "M6 5C6.55228 5 7 4.55228 7 4C7 3.44772 6.55228 3 6 3C5.44772 3 5 3.44772 5 4C5 4.55228 5.44772 5 6 5Z" } }, { tag: "path", attrs: { d: "M6 9C6.55228 9 7 8.55229 7 8C7 7.44772 6.55228 7 6 7C5.44772 7 5 7.44772 5 8C5 8.55229 5.44772 9 6 9Z" } }, { tag: "path", attrs: { d: "M7 12C7 12.5523 6.55228 13 6 13C5.44772 13 5 12.5523 5 12C5 11.4477 5.44772 11 6 11C6.55228 11 7 11.4477 7 12Z" } }, { tag: "path", attrs: { d: "M10 5C10.5523 5 11 4.55228 11 4C11 3.44772 10.5523 3 10 3C9.44771 3 9 3.44772 9 4C9 4.55228 9.44771 5 10 5Z" } }, { tag: "path", attrs: { d: "M11 8C11 8.55229 10.5523 9 10 9C9.44771 9 9 8.55229 9 8C9 7.44772 9.44771 7 10 7C10.5523 7 11 7.44772 11 8Z" } }, { tag: "path", attrs: { d: "M10 13C10.5523 13 11 12.5523 11 12C11 11.4477 10.5523 11 10 11C9.44771 11 9 11.4477 9 12C9 12.5523 9.44771 13 10 13Z" } }] }] }, Qn = oe(function(t, e) {
|
|
338
|
+
return de(he, Object.assign({}, t, {
|
|
339
|
+
id: "sequence-icon",
|
|
340
|
+
ref: e,
|
|
341
|
+
icon: Ii
|
|
342
|
+
}));
|
|
343
|
+
});
|
|
344
|
+
Qn.displayName = "SequenceIcon";
|
|
345
|
+
var Si = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 17 17", width: "1em", height: "1em" }, children: [{ tag: "mask", attrs: { id: "mask0_436_41", width: 17, height: 17, x: 0, y: 0, maskUnits: "userSpaceOnUse" }, children: [{ tag: "path", attrs: { fill: "#D9D9D9", d: "M.35.48H16.35V16.48H.35z" } }] }, { tag: "g", attrs: { mask: "url(#mask0_436_41)", fillRule: "evenodd", clipRule: "evenodd" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M2.27177 13.714L13.5855 2.40025L14.434 3.24878L3.1203 14.5625L2.27177 13.714Z" } }, { tag: "path", attrs: { fill: "#E5E5E5", d: "M4.2603 1.82495L2.89617 1.82495C2.23343 1.82495 1.69617 2.36221 1.69617 3.02495L1.69617 4.38908L3.02617 4.38908L3.02617 3.15495L4.2603 3.15495L4.2603 1.82495ZM15.0092 4.38908L15.0092 3.02495C15.0092 2.36221 14.4719 1.82495 13.8092 1.82495L12.4451 1.82495L12.4451 3.15495L13.6792 3.15495L13.6792 4.38908L15.0092 4.38908ZM6.98856 1.82495L6.98856 3.15495L9.71681 3.15495L9.71681 1.82495L6.98856 1.82495ZM15.0092 7.11734L13.6792 7.11734L13.6792 9.84559L15.0092 9.84559L15.0092 7.11734ZM15.0092 12.5739L13.6792 12.5739L13.6792 13.808L12.4451 13.808L12.4451 15.138L13.8092 15.138C14.4719 15.138 15.0092 14.6007 15.0092 13.938L15.0092 12.5739ZM9.71681 15.138L9.71681 13.808L6.98856 13.808L6.98856 15.138L9.71681 15.138ZM4.2603 15.138L4.2603 13.808L3.02617 13.808L3.02617 12.5739L1.69617 12.5739L1.69617 13.938C1.69617 14.6007 2.23343 15.138 2.89617 15.138L4.2603 15.138ZM1.69617 9.8456L3.02617 9.8456L3.02617 7.11734L1.69617 7.11734L1.69617 9.8456Z" } }] }] }, ot = oe(function(t, e) {
|
|
346
|
+
return de(he, Object.assign({}, t, {
|
|
347
|
+
id: "slash-icon",
|
|
348
|
+
ref: e,
|
|
349
|
+
icon: Si
|
|
350
|
+
}));
|
|
351
|
+
});
|
|
352
|
+
ot.displayName = "SlashIcon";
|
|
353
|
+
var _i = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M8.00033 1.20996C6.43345 1.20996 5.23596 1.88077 4.64804 2.94304C4.06338 3.99943 4.15123 5.32084 4.90099 6.47062C5.08199 6.7482 5.45374 6.82648 5.73131 6.64548C6.00888 6.46448 6.08716 6.09273 5.90616 5.81516C5.36418 4.98402 5.35768 4.13897 5.69797 3.52412C6.035 2.91515 6.78176 2.40996 8.00033 2.40996C9.19423 2.40996 10.0017 2.93409 10.5236 3.46755C10.7871 3.73682 10.9756 4.00712 11.0974 4.20903C11.158 4.30951 11.2013 4.39164 11.2284 4.44625C11.2419 4.47351 11.2514 4.49377 11.2568 4.50588L11.2621 4.51771C11.3901 4.82216 11.7407 4.96686 12.046 4.83992C12.3519 4.71267 12.4968 4.36149 12.3695 4.05552L11.8231 4.28278C12.3695 4.05552 12.3697 4.0558 12.3695 4.05552L12.3691 4.05437L12.3685 4.05298L12.367 4.04953L12.3629 4.03993L12.3498 4.01036C12.3388 3.98619 12.3234 3.95326 12.3033 3.91282C12.2632 3.83203 12.2043 3.72072 12.1249 3.58908C11.9666 3.32674 11.7235 2.97805 11.3814 2.62834C10.6921 1.92381 9.59192 1.20996 8.00033 1.20996Z" } }, { tag: "path", attrs: { fill: "currentColor", d: "M2.11953 8.5999H7.88935C10.1109 9.46549 10.5895 10.7649 10.4268 11.6869C10.2475 12.703 9.26939 13.5898 8.00009 13.5898C6.63323 13.5898 5.77631 13.0502 5.25534 12.528C4.99021 12.2623 4.80823 11.9965 4.69365 11.7993C4.63659 11.7011 4.59698 11.6211 4.5727 11.5686C4.56059 11.5424 4.55236 11.5231 4.54774 11.512L4.54352 11.5016C4.4267 11.193 4.0823 11.0363 3.77279 11.1516C3.46228 11.2673 3.30438 11.6129 3.4201 11.9234L3.9649 11.7203C3.4201 11.9234 3.41998 11.9231 3.4201 11.9234L3.4206 11.9247L3.42118 11.9263L3.42262 11.9301L3.42661 11.9403C3.42977 11.9484 3.43394 11.9588 3.43914 11.9713C3.44956 11.9965 3.46418 12.0304 3.48334 12.0719C3.52161 12.1547 3.57828 12.2682 3.65608 12.4021C3.81124 12.6692 4.0534 13.0223 4.40584 13.3756C5.12 14.0914 6.27196 14.7898 8.00009 14.7898C9.82574 14.7898 11.3236 13.5101 11.6085 11.8955C11.812 10.7422 11.3901 9.55402 10.2665 8.5999H13.8804C14.2117 8.5999 14.4803 8.33127 14.4803 7.9999C14.4803 7.66853 14.2117 7.3999 13.8804 7.3999H8.01411C8.0048 7.39968 7.99551 7.39969 7.98625 7.3999H2.11953C1.78816 7.3999 1.51953 7.66853 1.51953 7.9999C1.51953 8.33127 1.78816 8.5999 2.11953 8.5999Z" } }] }, er = oe(function(t, e) {
|
|
354
|
+
return de(he, Object.assign({}, t, {
|
|
355
|
+
id: "strikethrough-icon",
|
|
356
|
+
ref: e,
|
|
357
|
+
icon: _i
|
|
358
|
+
}));
|
|
359
|
+
});
|
|
360
|
+
er.displayName = "StrikethroughIcon";
|
|
361
|
+
var wi = { tag: "svg", attrs: { xmlns: "http://www.w3.org/2000/svg", fill: "none", viewBox: "0 0 16 16", width: "1em", height: "1em" }, children: [{ tag: "path", attrs: { fill: "currentColor", d: "M4.46416 2.03237C4.46416 1.701 4.19553 1.43237 3.86416 1.43237C3.53279 1.43237 3.26416 1.701 3.26416 2.03237V7.33338C3.26416 10.0313 5.35834 12.2667 7.9999 12.2667C10.6415 12.2667 12.7356 10.0313 12.7356 7.33338V2.03237C12.7356 1.701 12.467 1.43237 12.1356 1.43237C11.8043 1.43237 11.5356 1.701 11.5356 2.03237V7.33338C11.5356 9.42194 9.92656 11.0667 7.9999 11.0667C6.07325 11.0667 4.46416 9.42194 4.46416 7.33338V2.03237Z" } }, { tag: "path", attrs: { fill: "currentColor", d: "M2.66641 13.4663C2.33504 13.4663 2.06641 13.7349 2.06641 14.0663C2.06641 14.3977 2.33504 14.6663 2.66641 14.6663H13.3331C13.6644 14.6663 13.9331 14.3977 13.9331 14.0663C13.9331 13.7349 13.6644 13.4663 13.3331 13.4663H2.66641Z" } }] }, tr = oe(function(t, e) {
|
|
362
|
+
return de(he, Object.assign({}, t, {
|
|
363
|
+
id: "underline-icon",
|
|
364
|
+
ref: e,
|
|
365
|
+
icon: wi
|
|
366
|
+
}));
|
|
367
|
+
});
|
|
368
|
+
tr.displayName = "UnderlineIcon";
|
|
369
|
+
const Fe = (t) => {
|
|
370
|
+
const { color: e, onChange: r, disable: n = !1, Icon: i = Jn, className: s } = t, o = J(() => new mn(e), [e]), u = () => {
|
|
371
|
+
const a = {
|
|
372
|
+
className: X("univer-fill-primary-600", n && s),
|
|
373
|
+
extend: { colorChannel1: o.isValid ? e : "" }
|
|
374
|
+
};
|
|
375
|
+
return /* @__PURE__ */ c(i, { ...a });
|
|
376
|
+
};
|
|
377
|
+
return n ? u() : /* @__PURE__ */ c(
|
|
378
|
+
Gt,
|
|
325
379
|
{
|
|
326
|
-
overlay: /* @__PURE__ */ c("div", { className: "univer-rounded-lg univer-p-4", children: /* @__PURE__ */ c(
|
|
327
|
-
children: /* @__PURE__ */
|
|
380
|
+
overlay: /* @__PURE__ */ c("div", { className: "univer-rounded-lg univer-p-4", children: /* @__PURE__ */ c(Kr, { value: e, onChange: r }) }),
|
|
381
|
+
children: /* @__PURE__ */ c(
|
|
328
382
|
"span",
|
|
329
383
|
{
|
|
330
384
|
className: X("univer-flex univer-cursor-pointer univer-items-center univer-rounded univer-p-1 dark:hover:!univer-bg-gray-700 hover:univer-bg-gray-100", s),
|
|
331
|
-
children:
|
|
332
|
-
/* @__PURE__ */ c(h, { className: "univer-fill-primary-600", extend: { colorChannel1: a.isValid ? e : "" } }),
|
|
333
|
-
o && /* @__PURE__ */ c(
|
|
334
|
-
Vt,
|
|
335
|
-
{
|
|
336
|
-
className: "univer-ml-1.5 univer-text-gray-400"
|
|
337
|
-
}
|
|
338
|
-
)
|
|
339
|
-
]
|
|
385
|
+
children: u()
|
|
340
386
|
}
|
|
341
387
|
)
|
|
342
388
|
}
|
|
343
|
-
)
|
|
389
|
+
);
|
|
344
390
|
}, We = (t) => {
|
|
345
|
-
var s, o,
|
|
391
|
+
var s, o, u, a, h;
|
|
346
392
|
const e = t.rule;
|
|
347
393
|
if (!e) return null;
|
|
348
394
|
const r = J(() => {
|
|
349
|
-
if (e.type ===
|
|
350
|
-
const l = e.config.map((p,
|
|
351
|
-
return new Array(5).fill("").map((p,
|
|
395
|
+
if (e.type === L.colorScale) {
|
|
396
|
+
const l = e.config.map((p, y) => ({ color: new mn(p.color), value: y })), d = l.length - 1;
|
|
397
|
+
return new Array(5).fill("").map((p, y, f) => y * d / (f.length - 1)).map((p) => fr(l, p));
|
|
352
398
|
}
|
|
353
399
|
return null;
|
|
354
400
|
}, [e]), n = J(() => {
|
|
355
|
-
if (e.type ===
|
|
401
|
+
if (e.type === L.iconSet)
|
|
356
402
|
return e.config.map((l) => {
|
|
357
|
-
const
|
|
358
|
-
return
|
|
403
|
+
const d = Ve[l.iconType];
|
|
404
|
+
return d && d[Number(l.iconId)];
|
|
359
405
|
});
|
|
360
406
|
}, [e]), i = "univer-pointer-events-none univer-flex univer-h-5 univer-min-w-[72px] univer-items-center univer-justify-center univer-text-xs";
|
|
361
407
|
switch (e.type) {
|
|
362
|
-
case
|
|
363
|
-
const { isGradient: l } = e.config,
|
|
408
|
+
case L.dataBar: {
|
|
409
|
+
const { isGradient: l } = e.config, d = l ? `linear-gradient(to right, ${e.config.positiveColor || Ke}, rgb(255 255 255))` : e.config.positiveColor, v = l ? `linear-gradient(to right, rgb(255 255 255),${e.config.nativeColor || Xe})` : e.config.nativeColor;
|
|
364
410
|
return /* @__PURE__ */ k("div", { className: i, children: [
|
|
365
411
|
/* @__PURE__ */ c(
|
|
366
412
|
"div",
|
|
367
413
|
{
|
|
368
414
|
className: "univer-h-full univer-w-1/2 univer-border univer-border-solid",
|
|
369
415
|
style: {
|
|
370
|
-
background:
|
|
416
|
+
background: v,
|
|
371
417
|
borderColor: (s = e.config.nativeColor) != null ? s : Xe
|
|
372
418
|
}
|
|
373
419
|
}
|
|
@@ -377,122 +423,122 @@ const Me = (t) => {
|
|
|
377
423
|
{
|
|
378
424
|
className: "univer-h-full univer-w-1/2 univer-border univer-border-solid",
|
|
379
425
|
style: {
|
|
380
|
-
background:
|
|
426
|
+
background: d,
|
|
381
427
|
borderColor: (o = e.config.positiveColor) != null ? o : Ke
|
|
382
428
|
}
|
|
383
429
|
}
|
|
384
430
|
)
|
|
385
431
|
] });
|
|
386
432
|
}
|
|
387
|
-
case
|
|
388
|
-
return r && /* @__PURE__ */ c("div", { className: i, children: r.map((l,
|
|
433
|
+
case L.colorScale:
|
|
434
|
+
return r && /* @__PURE__ */ c("div", { className: i, children: r.map((l, d) => /* @__PURE__ */ c(
|
|
389
435
|
"div",
|
|
390
436
|
{
|
|
391
437
|
className: "univer-h-full",
|
|
392
438
|
style: { width: `${100 / r.length}%`, background: l }
|
|
393
439
|
},
|
|
394
|
-
|
|
440
|
+
d
|
|
395
441
|
)) });
|
|
396
|
-
case
|
|
397
|
-
return n && /* @__PURE__ */ c("div", { className: i, children: n.map((l,
|
|
398
|
-
case
|
|
399
|
-
const { ul: l, st:
|
|
400
|
-
textDecoration: (h = `${
|
|
401
|
-
backgroundColor:
|
|
402
|
-
color:
|
|
442
|
+
case L.iconSet:
|
|
443
|
+
return n && /* @__PURE__ */ c("div", { className: i, children: n.map((l, d) => l ? /* @__PURE__ */ c("img", { className: "univer-h-full", src: l, draggable: !1 }, d) : /* @__PURE__ */ c(ot, {}, d)) });
|
|
444
|
+
case L.highlightCell: {
|
|
445
|
+
const { ul: l, st: d, it: v, bl: p, bg: y, cl: f } = e.style, w = (l == null ? void 0 : l.s) === le.TRUE, I = (d == null ? void 0 : d.s) === le.TRUE, R = v === le.TRUE, x = p === le.TRUE, T = (u = y == null ? void 0 : y.rgb) != null ? u : pr, g = (a = f == null ? void 0 : f.rgb) != null ? a : Cr, b = {
|
|
446
|
+
textDecoration: (h = `${w ? "underline" : ""} ${I ? "line-through" : ""}`.replace(/^ /, "")) != null ? h : void 0,
|
|
447
|
+
backgroundColor: T,
|
|
448
|
+
color: g
|
|
403
449
|
};
|
|
404
450
|
return /* @__PURE__ */ c(
|
|
405
451
|
"div",
|
|
406
452
|
{
|
|
407
453
|
className: X(i, {
|
|
408
|
-
"univer-font-bold":
|
|
454
|
+
"univer-font-bold": x,
|
|
409
455
|
"univer-italic": R
|
|
410
456
|
}),
|
|
411
|
-
style:
|
|
457
|
+
style: b,
|
|
412
458
|
children: "123"
|
|
413
459
|
}
|
|
414
460
|
);
|
|
415
461
|
}
|
|
416
462
|
}
|
|
417
|
-
}, at = X("univer-mt-5 univer-px-1 univer-py-2 univer-rounded",
|
|
418
|
-
var
|
|
419
|
-
const { type: e, className: r, onChange: n, id: i, value: s } = t, o =
|
|
463
|
+
}, at = X("univer-mt-5 univer-px-1 univer-py-2 univer-rounded", Be), Ee = (t, e) => ({ label: e.t(`sheet.cf.valueType.${t}`), value: t }), Pt = (t) => {
|
|
464
|
+
var y;
|
|
465
|
+
const { type: e, className: r, onChange: n, id: i, value: s } = t, o = q(Z), u = o.getCurrentUnitForType(A.UNIVER_SHEET).getUnitId(), a = (y = o.getCurrentUnitForType(A.UNIVER_SHEET).getActiveSheet()) == null ? void 0 : y.getSheetId(), h = J(() => String(s).startsWith("=") ? String(s) : "=", [s]), l = J(() => [D.max, D.min, "none"].includes(e) ? { disabled: !0 } : [D.percent, D.percentile].includes(e) ? {
|
|
420
466
|
min: 0,
|
|
421
467
|
max: 100
|
|
422
468
|
} : {
|
|
423
469
|
min: Number.MIN_SAFE_INTEGER,
|
|
424
470
|
max: Number.MAX_SAFE_INTEGER
|
|
425
|
-
}, [e]),
|
|
471
|
+
}, [e]), d = ge(null), [v, p] = N(!1);
|
|
426
472
|
return Nt((f) => {
|
|
427
|
-
var
|
|
428
|
-
((
|
|
429
|
-
}), e ===
|
|
473
|
+
var I;
|
|
474
|
+
((I = d.current) == null ? void 0 : I.isClickOutSide(f)) && p(!1);
|
|
475
|
+
}), e === D.formula ? /* @__PURE__ */ c("div", { className: "univer-ml-1 univer-w-full", children: /* @__PURE__ */ c(
|
|
430
476
|
Mt,
|
|
431
477
|
{
|
|
432
|
-
ref:
|
|
433
|
-
className: X("univer-box-border univer-h-8 univer-w-full univer-cursor-pointer univer-items-center univer-rounded-lg univer-bg-white univer-pt-2 univer-transition-colors [&>div:first-child]:univer-px-2.5 [&>div]:univer-h-5 [&>div]:univer-ring-transparent dark:!univer-bg-gray-700 dark:!univer-text-white hover:univer-border-primary-600",
|
|
478
|
+
ref: d,
|
|
479
|
+
className: X("univer-box-border univer-h-8 univer-w-full univer-cursor-pointer univer-items-center univer-rounded-lg univer-bg-white univer-pt-2 univer-transition-colors [&>div:first-child]:univer-px-2.5 [&>div]:univer-h-5 [&>div]:univer-ring-transparent dark:!univer-bg-gray-700 dark:!univer-text-white hover:univer-border-primary-600", Be),
|
|
434
480
|
initValue: h,
|
|
435
|
-
unitId:
|
|
481
|
+
unitId: u,
|
|
436
482
|
subUnitId: a,
|
|
437
|
-
isFocus:
|
|
483
|
+
isFocus: v,
|
|
438
484
|
onChange: (f = "") => {
|
|
439
485
|
n(f || "");
|
|
440
486
|
},
|
|
441
487
|
onFocus: () => p(!0)
|
|
442
488
|
}
|
|
443
|
-
) }) : /* @__PURE__ */ c(
|
|
444
|
-
},
|
|
445
|
-
var
|
|
446
|
-
const { interceptorManager: e } = t, r =
|
|
447
|
-
var
|
|
448
|
-
const m =
|
|
449
|
-
return n && ((
|
|
450
|
-
}), [l,
|
|
451
|
-
var
|
|
489
|
+
) }) : /* @__PURE__ */ c(ke, { className: r, value: Number(t.value) || 0, onChange: (f) => t.onChange(f || 0), ...l });
|
|
490
|
+
}, Ri = (t) => {
|
|
491
|
+
var O;
|
|
492
|
+
const { interceptorManager: e } = t, r = q(re), n = ((O = t.rule) == null ? void 0 : O.type) === L.colorScale ? t.rule : void 0, i = [Ee(D.num, r), Ee(D.percent, r), Ee(D.percentile, r), Ee(D.formula, r)], s = [Ee(D.min, r), ...i], o = [Ee("none", r), ...i], u = [Ee(D.max, r), ...i], [a, h] = N(() => {
|
|
493
|
+
var _;
|
|
494
|
+
const m = D.min;
|
|
495
|
+
return n && ((_ = n.config[0]) == null ? void 0 : _.value.type) || m;
|
|
496
|
+
}), [l, d] = N(() => {
|
|
497
|
+
var _;
|
|
452
498
|
const m = "none";
|
|
453
|
-
return !n || n.config.length !== 3 ? m : ((
|
|
454
|
-
}), [
|
|
455
|
-
var
|
|
456
|
-
const m =
|
|
457
|
-
return n && ((
|
|
458
|
-
}), [
|
|
499
|
+
return !n || n.config.length !== 3 ? m : ((_ = n.config[1]) == null ? void 0 : _.value.type) || m;
|
|
500
|
+
}), [v, p] = N(() => {
|
|
501
|
+
var _;
|
|
502
|
+
const m = D.max;
|
|
503
|
+
return n && ((_ = n.config[n.config.length - 1]) == null ? void 0 : _.value.type) || m;
|
|
504
|
+
}), [y, f] = N(() => {
|
|
459
505
|
if (!n)
|
|
460
506
|
return 10;
|
|
461
|
-
const
|
|
462
|
-
return (
|
|
463
|
-
}), [
|
|
464
|
-
var
|
|
507
|
+
const _ = n.config[0];
|
|
508
|
+
return (_ == null ? void 0 : _.value.value) === void 0 ? 10 : _ == null ? void 0 : _.value.value;
|
|
509
|
+
}), [w, I] = N(() => {
|
|
510
|
+
var j;
|
|
465
511
|
if (!n || n.config.length !== 3)
|
|
466
512
|
return 50;
|
|
467
|
-
const
|
|
468
|
-
return
|
|
469
|
-
}), [R,
|
|
470
|
-
var
|
|
513
|
+
const _ = (j = n.config[1]) == null ? void 0 : j.value.value;
|
|
514
|
+
return _ === void 0 ? 50 : _;
|
|
515
|
+
}), [R, x] = N(() => {
|
|
516
|
+
var j;
|
|
471
517
|
if (!n)
|
|
472
518
|
return 90;
|
|
473
|
-
const
|
|
474
|
-
return
|
|
475
|
-
}), [
|
|
476
|
-
var
|
|
519
|
+
const _ = (j = n.config[n.config.length - 1]) == null ? void 0 : j.value.value;
|
|
520
|
+
return _ === void 0 ? 90 : _;
|
|
521
|
+
}), [T, g] = N(() => {
|
|
522
|
+
var _;
|
|
477
523
|
const m = "#d0d9fb";
|
|
478
|
-
return n && ((
|
|
479
|
-
}), [
|
|
480
|
-
var
|
|
524
|
+
return n && ((_ = n.config[0]) == null ? void 0 : _.color) || m;
|
|
525
|
+
}), [b, S] = N(() => {
|
|
526
|
+
var _;
|
|
481
527
|
const m = "#7790f3";
|
|
482
|
-
return !n || n.config.length !== 3 ? m : ((
|
|
483
|
-
}), [
|
|
484
|
-
var
|
|
528
|
+
return !n || n.config.length !== 3 ? m : ((_ = n.config[1]) == null ? void 0 : _.color) || m;
|
|
529
|
+
}), [C, M] = N(() => {
|
|
530
|
+
var _;
|
|
485
531
|
const m = "#2e55ef";
|
|
486
|
-
return n && ((
|
|
532
|
+
return n && ((_ = n.config[n.config.length - 1]) == null ? void 0 : _.color) || m;
|
|
487
533
|
}), E = J(() => (m) => {
|
|
488
|
-
const { minType:
|
|
489
|
-
return G.push({ color:
|
|
534
|
+
const { minType: _, medianType: j, maxType: Y, minValue: pe, medianValue: Ce, maxValue: Le, minColor: Ue, medianColor: $, maxColor: B } = m, G = [];
|
|
535
|
+
return G.push({ color: Ue, value: { type: _, value: pe } }), j !== "none" && G.push({ color: $, value: { type: j, value: Ce } }), G.push({ color: B, value: { type: Y, value: Le } }), { config: G.map((ee, ne) => ({ ...ee, index: ne })), type: L.colorScale };
|
|
490
536
|
}, []);
|
|
491
537
|
K(() => e.intercept(e.getInterceptPoints().submit, {
|
|
492
538
|
handler() {
|
|
493
|
-
return E({ minType: a, medianType: l, maxType:
|
|
539
|
+
return E({ minType: a, medianType: l, maxType: v, minValue: y, medianValue: w, maxValue: R, minColor: T, medianColor: b, maxColor: C });
|
|
494
540
|
}
|
|
495
|
-
}), [E, a, l,
|
|
541
|
+
}), [E, a, l, v, y, w, R, T, b, C, e]);
|
|
496
542
|
const V = (m) => {
|
|
497
543
|
t.onChange(E(m));
|
|
498
544
|
};
|
|
@@ -504,7 +550,7 @@ const Me = (t) => {
|
|
|
504
550
|
children: r.t("sheet.cf.panel.styleRule")
|
|
505
551
|
}
|
|
506
552
|
),
|
|
507
|
-
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(We, { rule: E({ minType: a, medianType: l, maxType:
|
|
553
|
+
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(We, { rule: E({ minType: a, medianType: l, maxType: v, minValue: y, medianValue: w, maxValue: R, minColor: T, medianColor: b, maxColor: C }) }) }),
|
|
508
554
|
/* @__PURE__ */ c(
|
|
509
555
|
"div",
|
|
510
556
|
{
|
|
@@ -514,66 +560,66 @@ const Me = (t) => {
|
|
|
514
560
|
),
|
|
515
561
|
/* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-h-8 univer-items-center", children: [
|
|
516
562
|
/* @__PURE__ */ c(
|
|
517
|
-
|
|
563
|
+
ce,
|
|
518
564
|
{
|
|
519
565
|
className: "univer-flex-shrink-0",
|
|
520
566
|
options: s,
|
|
521
567
|
value: a,
|
|
522
568
|
onChange: (m) => {
|
|
523
569
|
h(m);
|
|
524
|
-
const
|
|
525
|
-
f(
|
|
570
|
+
const _ = Je(m, 10);
|
|
571
|
+
f(_), V({
|
|
526
572
|
minType: m,
|
|
527
573
|
medianType: l,
|
|
528
|
-
maxType:
|
|
529
|
-
minValue:
|
|
530
|
-
medianValue:
|
|
574
|
+
maxType: v,
|
|
575
|
+
minValue: _,
|
|
576
|
+
medianValue: w,
|
|
531
577
|
maxValue: R,
|
|
532
|
-
minColor:
|
|
533
|
-
medianColor:
|
|
534
|
-
maxColor:
|
|
578
|
+
minColor: T,
|
|
579
|
+
medianColor: b,
|
|
580
|
+
maxColor: C
|
|
535
581
|
});
|
|
536
582
|
}
|
|
537
583
|
}
|
|
538
584
|
),
|
|
539
585
|
/* @__PURE__ */ c(
|
|
540
|
-
|
|
586
|
+
Pt,
|
|
541
587
|
{
|
|
542
588
|
id: "min",
|
|
543
589
|
className: "univer-ml-1",
|
|
544
|
-
value:
|
|
590
|
+
value: y,
|
|
545
591
|
type: a,
|
|
546
592
|
onChange: (m) => {
|
|
547
593
|
f(m), V({
|
|
548
594
|
minType: a,
|
|
549
595
|
medianType: l,
|
|
550
|
-
maxType:
|
|
596
|
+
maxType: v,
|
|
551
597
|
minValue: m,
|
|
552
|
-
medianValue:
|
|
598
|
+
medianValue: w,
|
|
553
599
|
maxValue: R,
|
|
554
|
-
minColor:
|
|
555
|
-
medianColor:
|
|
556
|
-
maxColor:
|
|
600
|
+
minColor: T,
|
|
601
|
+
medianColor: b,
|
|
602
|
+
maxColor: C
|
|
557
603
|
});
|
|
558
604
|
}
|
|
559
605
|
}
|
|
560
606
|
),
|
|
561
607
|
/* @__PURE__ */ c(
|
|
562
|
-
|
|
608
|
+
Fe,
|
|
563
609
|
{
|
|
564
610
|
className: "univer-ml-1",
|
|
565
|
-
color:
|
|
611
|
+
color: T,
|
|
566
612
|
onChange: (m) => {
|
|
567
|
-
|
|
613
|
+
g(m), V({
|
|
568
614
|
minType: a,
|
|
569
615
|
medianType: l,
|
|
570
|
-
maxType:
|
|
571
|
-
minValue:
|
|
572
|
-
medianValue:
|
|
616
|
+
maxType: v,
|
|
617
|
+
minValue: y,
|
|
618
|
+
medianValue: w,
|
|
573
619
|
maxValue: R,
|
|
574
620
|
minColor: m,
|
|
575
|
-
medianColor:
|
|
576
|
-
maxColor:
|
|
621
|
+
medianColor: b,
|
|
622
|
+
maxColor: C
|
|
577
623
|
});
|
|
578
624
|
}
|
|
579
625
|
}
|
|
@@ -588,66 +634,66 @@ const Me = (t) => {
|
|
|
588
634
|
),
|
|
589
635
|
/* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-h-8 univer-items-center", children: [
|
|
590
636
|
/* @__PURE__ */ c(
|
|
591
|
-
|
|
637
|
+
ce,
|
|
592
638
|
{
|
|
593
639
|
className: "univer-flex-shrink-0",
|
|
594
640
|
options: o,
|
|
595
641
|
value: l,
|
|
596
642
|
onChange: (m) => {
|
|
597
|
-
|
|
598
|
-
const
|
|
599
|
-
_
|
|
643
|
+
d(m);
|
|
644
|
+
const _ = Je(m, 50);
|
|
645
|
+
I(_), V({
|
|
600
646
|
minType: a,
|
|
601
647
|
medianType: m,
|
|
602
|
-
maxType:
|
|
603
|
-
minValue:
|
|
604
|
-
medianValue:
|
|
648
|
+
maxType: v,
|
|
649
|
+
minValue: y,
|
|
650
|
+
medianValue: _,
|
|
605
651
|
maxValue: R,
|
|
606
|
-
minColor:
|
|
607
|
-
medianColor:
|
|
608
|
-
maxColor:
|
|
652
|
+
minColor: T,
|
|
653
|
+
medianColor: b,
|
|
654
|
+
maxColor: C
|
|
609
655
|
});
|
|
610
656
|
}
|
|
611
657
|
}
|
|
612
658
|
),
|
|
613
659
|
/* @__PURE__ */ c(
|
|
614
|
-
|
|
660
|
+
Pt,
|
|
615
661
|
{
|
|
616
662
|
id: "median",
|
|
617
663
|
className: "univer-ml-1",
|
|
618
|
-
value:
|
|
664
|
+
value: w,
|
|
619
665
|
type: l,
|
|
620
666
|
onChange: (m) => {
|
|
621
|
-
|
|
667
|
+
I(m), V({
|
|
622
668
|
minType: a,
|
|
623
669
|
medianType: l,
|
|
624
|
-
maxType:
|
|
625
|
-
minValue:
|
|
670
|
+
maxType: v,
|
|
671
|
+
minValue: y,
|
|
626
672
|
medianValue: m,
|
|
627
673
|
maxValue: R,
|
|
628
|
-
minColor:
|
|
629
|
-
medianColor:
|
|
630
|
-
maxColor:
|
|
674
|
+
minColor: T,
|
|
675
|
+
medianColor: b,
|
|
676
|
+
maxColor: C
|
|
631
677
|
});
|
|
632
678
|
}
|
|
633
679
|
}
|
|
634
680
|
),
|
|
635
681
|
l !== "none" && /* @__PURE__ */ c(
|
|
636
|
-
|
|
682
|
+
Fe,
|
|
637
683
|
{
|
|
638
684
|
className: "univer-ml-1",
|
|
639
|
-
color:
|
|
685
|
+
color: b,
|
|
640
686
|
onChange: (m) => {
|
|
641
|
-
|
|
687
|
+
S(m), V({
|
|
642
688
|
minType: a,
|
|
643
689
|
medianType: l,
|
|
644
|
-
maxType:
|
|
645
|
-
minValue:
|
|
646
|
-
medianValue:
|
|
690
|
+
maxType: v,
|
|
691
|
+
minValue: y,
|
|
692
|
+
medianValue: w,
|
|
647
693
|
maxValue: R,
|
|
648
|
-
minColor:
|
|
694
|
+
minColor: T,
|
|
649
695
|
medianColor: m,
|
|
650
|
-
maxColor:
|
|
696
|
+
maxColor: C
|
|
651
697
|
});
|
|
652
698
|
}
|
|
653
699
|
}
|
|
@@ -662,65 +708,65 @@ const Me = (t) => {
|
|
|
662
708
|
),
|
|
663
709
|
/* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-h-8 univer-items-center", children: [
|
|
664
710
|
/* @__PURE__ */ c(
|
|
665
|
-
|
|
711
|
+
ce,
|
|
666
712
|
{
|
|
667
713
|
className: "univer-flex-shrink-0",
|
|
668
|
-
options:
|
|
669
|
-
value:
|
|
714
|
+
options: u,
|
|
715
|
+
value: v,
|
|
670
716
|
onChange: (m) => {
|
|
671
717
|
p(m);
|
|
672
|
-
const
|
|
673
|
-
|
|
718
|
+
const _ = Je(m, 90);
|
|
719
|
+
x(_), V({
|
|
674
720
|
minType: a,
|
|
675
721
|
medianType: l,
|
|
676
722
|
maxType: m,
|
|
677
|
-
minValue:
|
|
678
|
-
medianValue:
|
|
679
|
-
maxValue:
|
|
680
|
-
minColor:
|
|
681
|
-
medianColor:
|
|
682
|
-
maxColor:
|
|
723
|
+
minValue: y,
|
|
724
|
+
medianValue: w,
|
|
725
|
+
maxValue: _,
|
|
726
|
+
minColor: T,
|
|
727
|
+
medianColor: b,
|
|
728
|
+
maxColor: C
|
|
683
729
|
});
|
|
684
730
|
}
|
|
685
731
|
}
|
|
686
732
|
),
|
|
687
733
|
/* @__PURE__ */ c(
|
|
688
|
-
|
|
734
|
+
Pt,
|
|
689
735
|
{
|
|
690
736
|
id: "max",
|
|
691
737
|
className: "univer-ml-1",
|
|
692
738
|
value: R,
|
|
693
|
-
type:
|
|
739
|
+
type: v,
|
|
694
740
|
onChange: (m) => {
|
|
695
|
-
|
|
741
|
+
x(m), V({
|
|
696
742
|
minType: a,
|
|
697
743
|
medianType: l,
|
|
698
|
-
maxType:
|
|
699
|
-
minValue:
|
|
700
|
-
medianValue:
|
|
744
|
+
maxType: v,
|
|
745
|
+
minValue: y,
|
|
746
|
+
medianValue: w,
|
|
701
747
|
maxValue: m,
|
|
702
|
-
minColor:
|
|
703
|
-
medianColor:
|
|
704
|
-
maxColor:
|
|
748
|
+
minColor: T,
|
|
749
|
+
medianColor: b,
|
|
750
|
+
maxColor: C
|
|
705
751
|
});
|
|
706
752
|
}
|
|
707
753
|
}
|
|
708
754
|
),
|
|
709
755
|
/* @__PURE__ */ c(
|
|
710
|
-
|
|
756
|
+
Fe,
|
|
711
757
|
{
|
|
712
758
|
className: "univer-ml-1",
|
|
713
|
-
color:
|
|
759
|
+
color: C,
|
|
714
760
|
onChange: (m) => {
|
|
715
761
|
M(m), V({
|
|
716
762
|
minType: a,
|
|
717
763
|
medianType: l,
|
|
718
|
-
maxType:
|
|
719
|
-
minValue:
|
|
720
|
-
medianValue:
|
|
764
|
+
maxType: v,
|
|
765
|
+
minValue: y,
|
|
766
|
+
medianValue: w,
|
|
721
767
|
maxValue: R,
|
|
722
|
-
minColor:
|
|
723
|
-
medianColor:
|
|
768
|
+
minColor: T,
|
|
769
|
+
medianColor: b,
|
|
724
770
|
maxColor: m
|
|
725
771
|
});
|
|
726
772
|
}
|
|
@@ -728,119 +774,124 @@ const Me = (t) => {
|
|
|
728
774
|
)
|
|
729
775
|
] })
|
|
730
776
|
] });
|
|
731
|
-
},
|
|
777
|
+
}, Pe = (t, e) => ({ label: e.t(`sheet.cf.valueType.${t}`), value: t }), rn = (t) => {
|
|
732
778
|
var f;
|
|
733
|
-
const { onChange: e, className: r, value: n, type: i, id: s, disabled: o = !1 } = t,
|
|
734
|
-
Nt((
|
|
779
|
+
const { onChange: e, className: r, value: n, type: i, id: s, disabled: o = !1 } = t, u = q(Z), a = u.getCurrentUnitOfType(A.UNIVER_SHEET).getUnitId(), h = (f = u.getCurrentUnitOfType(A.UNIVER_SHEET).getActiveSheet()) == null ? void 0 : f.getSheetId(), l = ge(null), [d, v] = N(!1);
|
|
780
|
+
Nt((w) => {
|
|
735
781
|
var R;
|
|
736
|
-
((R = l.current) == null ? void 0 : R.isClickOutSide(
|
|
782
|
+
((R = l.current) == null ? void 0 : R.isClickOutSide(w)) && v(!1);
|
|
737
783
|
});
|
|
738
|
-
const p =
|
|
784
|
+
const p = ge(n), y = J(() => [D.percentile, D.percent].includes(i) ? {
|
|
739
785
|
max: 100,
|
|
740
786
|
min: 0
|
|
741
787
|
} : {
|
|
742
788
|
min: Number.MIN_SAFE_INTEGER,
|
|
743
789
|
max: Number.MAX_SAFE_INTEGER
|
|
744
790
|
}, [i]);
|
|
745
|
-
if (i ===
|
|
746
|
-
const
|
|
791
|
+
if (i === D.formula) {
|
|
792
|
+
const w = String(p.current).startsWith("=") ? String(p.current) || "" : "=";
|
|
747
793
|
return /* @__PURE__ */ c("div", { className: "univer-ml-3 univer-w-full", children: /* @__PURE__ */ c(
|
|
748
794
|
Mt,
|
|
749
795
|
{
|
|
750
796
|
ref: l,
|
|
751
|
-
className: X("univer-box-border univer-h-8 univer-w-full univer-cursor-pointer univer-items-center univer-rounded-lg univer-bg-white univer-pt-2 univer-transition-colors [&>div:first-child]:univer-px-2.5 [&>div]:univer-h-5 [&>div]:univer-ring-transparent dark:!univer-bg-gray-700 dark:!univer-text-white hover:univer-border-primary-600",
|
|
752
|
-
initValue:
|
|
797
|
+
className: X("univer-box-border univer-h-8 univer-w-full univer-cursor-pointer univer-items-center univer-rounded-lg univer-bg-white univer-pt-2 univer-transition-colors [&>div:first-child]:univer-px-2.5 [&>div]:univer-h-5 [&>div]:univer-ring-transparent dark:!univer-bg-gray-700 dark:!univer-text-white hover:univer-border-primary-600", Be),
|
|
798
|
+
initValue: w,
|
|
753
799
|
unitId: a,
|
|
754
800
|
subUnitId: h,
|
|
755
|
-
isFocus:
|
|
756
|
-
onChange: (
|
|
757
|
-
e(
|
|
801
|
+
isFocus: d,
|
|
802
|
+
onChange: (I = "") => {
|
|
803
|
+
e(I || "");
|
|
758
804
|
},
|
|
759
|
-
onFocus: () =>
|
|
805
|
+
onFocus: () => v(!0)
|
|
760
806
|
}
|
|
761
807
|
) });
|
|
762
808
|
}
|
|
763
809
|
return /* @__PURE__ */ c(
|
|
764
|
-
|
|
810
|
+
ke,
|
|
765
811
|
{
|
|
766
812
|
className: r,
|
|
767
813
|
value: Number(n) || 0,
|
|
768
814
|
disabled: o,
|
|
769
|
-
onChange: (
|
|
770
|
-
e(
|
|
815
|
+
onChange: (w) => {
|
|
816
|
+
e(w || 0);
|
|
771
817
|
},
|
|
772
|
-
...
|
|
818
|
+
...y
|
|
773
819
|
}
|
|
774
820
|
);
|
|
775
|
-
},
|
|
776
|
-
var
|
|
777
|
-
const { interceptorManager: e } = t, r =
|
|
778
|
-
var
|
|
821
|
+
}, Ti = (t) => {
|
|
822
|
+
var O;
|
|
823
|
+
const { interceptorManager: e } = t, r = q(re), n = ((O = t.rule) == null ? void 0 : O.type) === L.dataBar ? t.rule : void 0, [i, s] = N(() => {
|
|
824
|
+
var _;
|
|
779
825
|
const m = "0";
|
|
780
|
-
return n ? (
|
|
781
|
-
}), [o,
|
|
826
|
+
return n ? (_ = n.config) != null && _.isGradient ? "1" : "0" : m;
|
|
827
|
+
}), [o, u] = N(() => {
|
|
782
828
|
var m;
|
|
783
829
|
return n ? ((m = n.config) == null ? void 0 : m.positiveColor) || Ke : Ke;
|
|
784
830
|
}), [a, h] = N(() => {
|
|
785
831
|
var m;
|
|
786
832
|
return n ? ((m = n.config) == null ? void 0 : m.nativeColor) || Xe : Xe;
|
|
787
|
-
}), l = [
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
833
|
+
}), l = [
|
|
834
|
+
Pe(D.num, r),
|
|
835
|
+
Pe(D.percent, r),
|
|
836
|
+
Pe(D.percentile, r),
|
|
837
|
+
Pe(D.formula, r)
|
|
838
|
+
], d = [Pe(D.min, r), ...l], v = [Pe(D.max, r), ...l], [p, y] = N(() => {
|
|
839
|
+
var _;
|
|
840
|
+
const m = d[0].value;
|
|
841
|
+
return n && ((_ = n.config) == null ? void 0 : _.min.type) || m;
|
|
842
|
+
}), [f, w] = N(() => {
|
|
843
|
+
var _;
|
|
844
|
+
const m = v[0].value;
|
|
845
|
+
return n && ((_ = n.config) == null ? void 0 : _.max.type) || m;
|
|
846
|
+
}), [I, R] = N(() => {
|
|
847
|
+
var j;
|
|
797
848
|
if (!n)
|
|
798
849
|
return 0;
|
|
799
|
-
const
|
|
800
|
-
return
|
|
801
|
-
}), [
|
|
802
|
-
var
|
|
850
|
+
const _ = ((j = n.config) == null ? void 0 : j.min) || {};
|
|
851
|
+
return _.type === D.formula ? _.value || "=" : _.value || 0;
|
|
852
|
+
}), [x, T] = N(() => {
|
|
853
|
+
var j;
|
|
803
854
|
if (!n)
|
|
804
855
|
return 100;
|
|
805
|
-
const
|
|
806
|
-
return
|
|
807
|
-
}), [
|
|
856
|
+
const _ = ((j = n.config) == null ? void 0 : j.max) || {};
|
|
857
|
+
return _.type === D.formula ? _.value || "=" : _.value === void 0 ? 100 : _.value;
|
|
858
|
+
}), [g, b] = N(() => n ? n.isShowValue === void 0 ? !0 : !!n.isShowValue : !0), S = (m) => ({ config: {
|
|
808
859
|
min: { type: m.minValueType, value: m.minValue },
|
|
809
860
|
max: { type: m.maxValueType, value: m.maxValue },
|
|
810
861
|
isGradient: m.isGradient === "1",
|
|
811
862
|
positiveColor: m.positiveColor || Ke,
|
|
812
863
|
nativeColor: m.nativeColor || Xe
|
|
813
|
-
}, type:
|
|
864
|
+
}, type: L.dataBar, isShowValue: m.isShowValue });
|
|
814
865
|
K(() => e.intercept(e.getInterceptPoints().submit, {
|
|
815
866
|
handler() {
|
|
816
|
-
return
|
|
867
|
+
return S({ isGradient: i, minValue: I, minValueType: p, maxValue: x, maxValueType: f, positiveColor: o, nativeColor: a, isShowValue: g });
|
|
817
868
|
}
|
|
818
|
-
}), [i,
|
|
819
|
-
const
|
|
820
|
-
t.onChange(
|
|
869
|
+
}), [i, I, p, x, f, o, a, e, g]);
|
|
870
|
+
const C = (m) => {
|
|
871
|
+
t.onChange(S(m));
|
|
821
872
|
}, M = (m) => {
|
|
822
|
-
|
|
873
|
+
u(m), C({
|
|
823
874
|
isGradient: i,
|
|
824
|
-
minValue:
|
|
875
|
+
minValue: I,
|
|
825
876
|
minValueType: p,
|
|
826
|
-
maxValue:
|
|
877
|
+
maxValue: x,
|
|
827
878
|
maxValueType: f,
|
|
828
879
|
positiveColor: m,
|
|
829
880
|
nativeColor: a,
|
|
830
|
-
isShowValue:
|
|
881
|
+
isShowValue: g
|
|
831
882
|
});
|
|
832
883
|
}, E = (m) => {
|
|
833
|
-
h(m),
|
|
884
|
+
h(m), C({
|
|
834
885
|
isGradient: i,
|
|
835
|
-
minValue:
|
|
886
|
+
minValue: I,
|
|
836
887
|
minValueType: p,
|
|
837
|
-
maxValue:
|
|
888
|
+
maxValue: x,
|
|
838
889
|
maxValueType: f,
|
|
839
890
|
positiveColor: o,
|
|
840
891
|
nativeColor: m,
|
|
841
|
-
isShowValue:
|
|
892
|
+
isShowValue: g
|
|
842
893
|
});
|
|
843
|
-
}, V = (m) => l.map((
|
|
894
|
+
}, V = (m) => l.map((_) => _.value).includes(m);
|
|
844
895
|
return /* @__PURE__ */ k("div", { children: [
|
|
845
896
|
/* @__PURE__ */ c(
|
|
846
897
|
"div",
|
|
@@ -852,15 +903,15 @@ const Me = (t) => {
|
|
|
852
903
|
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(
|
|
853
904
|
We,
|
|
854
905
|
{
|
|
855
|
-
rule:
|
|
906
|
+
rule: S({
|
|
856
907
|
isGradient: i,
|
|
857
|
-
minValue:
|
|
908
|
+
minValue: I,
|
|
858
909
|
minValueType: p,
|
|
859
|
-
maxValue:
|
|
910
|
+
maxValue: x,
|
|
860
911
|
maxValueType: f,
|
|
861
912
|
positiveColor: o,
|
|
862
913
|
nativeColor: a,
|
|
863
|
-
isShowValue:
|
|
914
|
+
isShowValue: g
|
|
864
915
|
})
|
|
865
916
|
}
|
|
866
917
|
) }),
|
|
@@ -874,24 +925,24 @@ const Me = (t) => {
|
|
|
874
925
|
),
|
|
875
926
|
/* @__PURE__ */ k("div", { className: "univer-ml-1 univer-mt-3 univer-flex univer-items-center", children: [
|
|
876
927
|
/* @__PURE__ */ k(
|
|
877
|
-
|
|
928
|
+
Xr,
|
|
878
929
|
{
|
|
879
930
|
value: i,
|
|
880
931
|
onChange: (m) => {
|
|
881
|
-
s(m),
|
|
932
|
+
s(m), C({
|
|
882
933
|
isGradient: m,
|
|
883
|
-
minValue:
|
|
934
|
+
minValue: I,
|
|
884
935
|
minValueType: p,
|
|
885
|
-
maxValue:
|
|
936
|
+
maxValue: x,
|
|
886
937
|
maxValueType: f,
|
|
887
938
|
positiveColor: o,
|
|
888
939
|
nativeColor: a,
|
|
889
|
-
isShowValue:
|
|
940
|
+
isShowValue: g
|
|
890
941
|
});
|
|
891
942
|
},
|
|
892
943
|
children: [
|
|
893
|
-
/* @__PURE__ */ c(
|
|
894
|
-
/* @__PURE__ */ c(
|
|
944
|
+
/* @__PURE__ */ c(Kt, { value: "0", children: /* @__PURE__ */ c("span", { className: "univer-text-xs", children: r.t("sheet.cf.panel.pureColor") }) }),
|
|
945
|
+
/* @__PURE__ */ c(Kt, { value: "1", children: /* @__PURE__ */ c("span", { className: "univer-text-xs", children: r.t("sheet.cf.panel.gradient") }) })
|
|
895
946
|
]
|
|
896
947
|
}
|
|
897
948
|
),
|
|
@@ -899,13 +950,13 @@ const Me = (t) => {
|
|
|
899
950
|
/* @__PURE__ */ c(
|
|
900
951
|
yt,
|
|
901
952
|
{
|
|
902
|
-
checked: !
|
|
953
|
+
checked: !g,
|
|
903
954
|
onChange: (m) => {
|
|
904
|
-
|
|
955
|
+
b(!m), C({
|
|
905
956
|
isGradient: m,
|
|
906
|
-
minValue:
|
|
957
|
+
minValue: I,
|
|
907
958
|
minValueType: p,
|
|
908
|
-
maxValue:
|
|
959
|
+
maxValue: x,
|
|
909
960
|
maxValueType: f,
|
|
910
961
|
positiveColor: o,
|
|
911
962
|
nativeColor: a,
|
|
@@ -930,7 +981,7 @@ const Me = (t) => {
|
|
|
930
981
|
/* @__PURE__ */ k("div", { className: "univer-flex univer-items-center", children: [
|
|
931
982
|
/* @__PURE__ */ c("div", { className: "univer-text-xs", children: r.t("sheet.cf.panel.native") }),
|
|
932
983
|
/* @__PURE__ */ c(
|
|
933
|
-
|
|
984
|
+
Fe,
|
|
934
985
|
{
|
|
935
986
|
color: a,
|
|
936
987
|
onChange: E
|
|
@@ -940,7 +991,7 @@ const Me = (t) => {
|
|
|
940
991
|
/* @__PURE__ */ k("div", { className: "univer-ml-3 univer-flex univer-items-center", children: [
|
|
941
992
|
/* @__PURE__ */ c("div", { className: "univer-text-xs", children: r.t("sheet.cf.panel.positive") }),
|
|
942
993
|
/* @__PURE__ */ c(
|
|
943
|
-
|
|
994
|
+
Fe,
|
|
944
995
|
{
|
|
945
996
|
color: o,
|
|
946
997
|
onChange: M
|
|
@@ -959,45 +1010,45 @@ const Me = (t) => {
|
|
|
959
1010
|
),
|
|
960
1011
|
/* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-items-center", children: [
|
|
961
1012
|
/* @__PURE__ */ c(
|
|
962
|
-
|
|
1013
|
+
ce,
|
|
963
1014
|
{
|
|
964
1015
|
className: "univer-w-1/2 univer-flex-shrink-0",
|
|
965
|
-
options:
|
|
1016
|
+
options: d,
|
|
966
1017
|
value: p,
|
|
967
1018
|
onChange: (m) => {
|
|
968
|
-
|
|
969
|
-
const
|
|
970
|
-
R(
|
|
1019
|
+
y(m);
|
|
1020
|
+
const _ = Je(m, 10);
|
|
1021
|
+
R(_), C({
|
|
971
1022
|
isGradient: i,
|
|
972
|
-
minValue:
|
|
1023
|
+
minValue: _,
|
|
973
1024
|
minValueType: m,
|
|
974
|
-
maxValue:
|
|
1025
|
+
maxValue: x,
|
|
975
1026
|
maxValueType: f,
|
|
976
1027
|
positiveColor: o,
|
|
977
1028
|
nativeColor: a,
|
|
978
|
-
isShowValue:
|
|
1029
|
+
isShowValue: g
|
|
979
1030
|
});
|
|
980
1031
|
}
|
|
981
1032
|
}
|
|
982
1033
|
),
|
|
983
1034
|
/* @__PURE__ */ c(
|
|
984
|
-
|
|
1035
|
+
rn,
|
|
985
1036
|
{
|
|
986
1037
|
id: "min",
|
|
987
1038
|
className: "univer-ml-3",
|
|
988
1039
|
disabled: !V(p),
|
|
989
1040
|
type: p,
|
|
990
|
-
value:
|
|
1041
|
+
value: I,
|
|
991
1042
|
onChange: (m) => {
|
|
992
|
-
R(m || 0),
|
|
1043
|
+
R(m || 0), C({
|
|
993
1044
|
isGradient: i,
|
|
994
1045
|
minValue: m || 0,
|
|
995
1046
|
minValueType: p,
|
|
996
|
-
maxValue:
|
|
1047
|
+
maxValue: x,
|
|
997
1048
|
maxValueType: f,
|
|
998
1049
|
positiveColor: o,
|
|
999
1050
|
nativeColor: a,
|
|
1000
|
-
isShowValue:
|
|
1051
|
+
isShowValue: g
|
|
1001
1052
|
});
|
|
1002
1053
|
}
|
|
1003
1054
|
}
|
|
@@ -1012,45 +1063,45 @@ const Me = (t) => {
|
|
|
1012
1063
|
),
|
|
1013
1064
|
/* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-items-center", children: [
|
|
1014
1065
|
/* @__PURE__ */ c(
|
|
1015
|
-
|
|
1066
|
+
ce,
|
|
1016
1067
|
{
|
|
1017
1068
|
className: "univer-w-1/2 univer-flex-shrink-0",
|
|
1018
|
-
options:
|
|
1069
|
+
options: v,
|
|
1019
1070
|
value: f,
|
|
1020
1071
|
onChange: (m) => {
|
|
1021
|
-
|
|
1022
|
-
const
|
|
1023
|
-
|
|
1072
|
+
w(m);
|
|
1073
|
+
const _ = Je(m, 90);
|
|
1074
|
+
T(_), C({
|
|
1024
1075
|
isGradient: i,
|
|
1025
|
-
minValue:
|
|
1076
|
+
minValue: I,
|
|
1026
1077
|
minValueType: p,
|
|
1027
|
-
maxValue:
|
|
1078
|
+
maxValue: _,
|
|
1028
1079
|
maxValueType: m,
|
|
1029
1080
|
positiveColor: o,
|
|
1030
1081
|
nativeColor: a,
|
|
1031
|
-
isShowValue:
|
|
1082
|
+
isShowValue: g
|
|
1032
1083
|
});
|
|
1033
1084
|
}
|
|
1034
1085
|
}
|
|
1035
1086
|
),
|
|
1036
1087
|
/* @__PURE__ */ c(
|
|
1037
|
-
|
|
1088
|
+
rn,
|
|
1038
1089
|
{
|
|
1039
1090
|
className: "univer-ml-3",
|
|
1040
1091
|
disabled: !V(f),
|
|
1041
1092
|
id: "max",
|
|
1042
1093
|
type: f,
|
|
1043
|
-
value:
|
|
1094
|
+
value: x,
|
|
1044
1095
|
onChange: (m) => {
|
|
1045
|
-
|
|
1096
|
+
T(m || 0), C({
|
|
1046
1097
|
isGradient: i,
|
|
1047
|
-
minValue:
|
|
1098
|
+
minValue: I,
|
|
1048
1099
|
minValueType: p,
|
|
1049
1100
|
maxValue: m || 0,
|
|
1050
1101
|
maxValueType: f,
|
|
1051
1102
|
positiveColor: o,
|
|
1052
1103
|
nativeColor: a,
|
|
1053
|
-
isShowValue:
|
|
1104
|
+
isShowValue: g
|
|
1054
1105
|
});
|
|
1055
1106
|
}
|
|
1056
1107
|
}
|
|
@@ -1058,101 +1109,101 @@ const Me = (t) => {
|
|
|
1058
1109
|
] })
|
|
1059
1110
|
] })
|
|
1060
1111
|
] });
|
|
1061
|
-
}, ct = (t) => [
|
|
1062
|
-
const { style: e, onChange: r, className: n } = t, i
|
|
1112
|
+
}, ct = (t) => [le.FALSE, void 0].includes(t) ? le.TRUE : le.FALSE, ut = (t) => t !== le.FALSE, zt = (t) => {
|
|
1113
|
+
const { style: e, onChange: r, className: n } = t, [i, s] = N(() => {
|
|
1063
1114
|
if (e != null && e.bl)
|
|
1064
1115
|
return e.bl;
|
|
1065
|
-
}), [
|
|
1116
|
+
}), [o, u] = N(() => {
|
|
1066
1117
|
if (e != null && e.it)
|
|
1067
1118
|
return e.it;
|
|
1068
|
-
}), [
|
|
1119
|
+
}), [a, h] = N(() => {
|
|
1069
1120
|
if (e != null && e.ul)
|
|
1070
1121
|
return e.ul.s;
|
|
1071
|
-
}), [
|
|
1122
|
+
}), [l, d] = N(() => {
|
|
1072
1123
|
if (e != null && e.st)
|
|
1073
1124
|
return e.st.s;
|
|
1074
|
-
}), [
|
|
1075
|
-
var
|
|
1076
|
-
const
|
|
1077
|
-
return (
|
|
1078
|
-
}), [
|
|
1079
|
-
var
|
|
1080
|
-
const
|
|
1081
|
-
return (
|
|
1082
|
-
})
|
|
1125
|
+
}), [v, p] = N(() => {
|
|
1126
|
+
var R;
|
|
1127
|
+
const I = "#2f56ef";
|
|
1128
|
+
return (R = e == null ? void 0 : e.cl) != null && R.rgb ? e.cl.rgb : I;
|
|
1129
|
+
}), [y, f] = N(() => {
|
|
1130
|
+
var R;
|
|
1131
|
+
const I = "#e8ecfc";
|
|
1132
|
+
return (R = e == null ? void 0 : e.bg) != null && R.rgb ? e.bg.rgb : I;
|
|
1133
|
+
});
|
|
1083
1134
|
K(() => {
|
|
1084
|
-
const
|
|
1085
|
-
bl:
|
|
1086
|
-
it:
|
|
1135
|
+
const I = {
|
|
1136
|
+
bl: i,
|
|
1137
|
+
it: o
|
|
1087
1138
|
};
|
|
1088
|
-
|
|
1089
|
-
}, [
|
|
1090
|
-
const
|
|
1139
|
+
v !== void 0 && (I.cl = { rgb: v }), y !== void 0 && (I.bg = { rgb: y }), l !== void 0 && (I.st = { s: l }), a !== void 0 && (I.ul = { s: a }), r(yr(I));
|
|
1140
|
+
}, [i, o, a, l, v, y]);
|
|
1141
|
+
const w = "univer-flex univer-cursor-pointer univer-items-center univer-rounded univer-px-1";
|
|
1091
1142
|
return /* @__PURE__ */ k("div", { className: X("univer-my-2.5 univer-flex univer-justify-between", n), children: [
|
|
1092
|
-
|
|
1143
|
+
/* @__PURE__ */ c(
|
|
1093
1144
|
"div",
|
|
1094
1145
|
{
|
|
1095
|
-
className: X(
|
|
1096
|
-
"univer-bg-gray-100": ut(
|
|
1146
|
+
className: X(w, {
|
|
1147
|
+
"univer-bg-gray-100 dark:!univer-bg-gray-700": ut(i || le.FALSE)
|
|
1097
1148
|
}),
|
|
1098
|
-
onClick: () =>
|
|
1099
|
-
children: /* @__PURE__ */ c(
|
|
1149
|
+
onClick: () => s(ct(i)),
|
|
1150
|
+
children: /* @__PURE__ */ c(zn, {})
|
|
1100
1151
|
}
|
|
1101
1152
|
),
|
|
1102
|
-
|
|
1153
|
+
/* @__PURE__ */ c(
|
|
1103
1154
|
"div",
|
|
1104
1155
|
{
|
|
1105
|
-
className: X(
|
|
1106
|
-
"univer-bg-gray-100": ut(
|
|
1156
|
+
className: X(w, {
|
|
1157
|
+
"univer-bg-gray-100 dark:!univer-bg-gray-700": ut(o || le.FALSE)
|
|
1107
1158
|
}),
|
|
1108
|
-
onClick: () =>
|
|
1109
|
-
children: /* @__PURE__ */ c(
|
|
1159
|
+
onClick: () => u(ct(o)),
|
|
1160
|
+
children: /* @__PURE__ */ c(Xn, {})
|
|
1110
1161
|
}
|
|
1111
1162
|
),
|
|
1112
|
-
|
|
1163
|
+
/* @__PURE__ */ c(
|
|
1113
1164
|
"div",
|
|
1114
1165
|
{
|
|
1115
|
-
className: X(
|
|
1116
|
-
"univer-bg-gray-100": ut(
|
|
1166
|
+
className: X(w, {
|
|
1167
|
+
"univer-bg-gray-100 dark:!univer-bg-gray-700": ut(a || le.FALSE)
|
|
1117
1168
|
}),
|
|
1118
|
-
onClick: () =>
|
|
1119
|
-
children: /* @__PURE__ */ c(
|
|
1169
|
+
onClick: () => h(ct(a)),
|
|
1170
|
+
children: /* @__PURE__ */ c(tr, {})
|
|
1120
1171
|
}
|
|
1121
1172
|
),
|
|
1122
|
-
|
|
1173
|
+
/* @__PURE__ */ c(
|
|
1123
1174
|
"div",
|
|
1124
1175
|
{
|
|
1125
|
-
className: X(
|
|
1126
|
-
"univer-bg-gray-100": ut(
|
|
1176
|
+
className: X(w, {
|
|
1177
|
+
"univer-bg-gray-100 dark:!univer-bg-gray-700": ut(l || le.FALSE)
|
|
1127
1178
|
}),
|
|
1128
|
-
onClick: () =>
|
|
1129
|
-
children: /* @__PURE__ */ c(
|
|
1179
|
+
onClick: () => d(ct(l)),
|
|
1180
|
+
children: /* @__PURE__ */ c(er, {})
|
|
1130
1181
|
}
|
|
1131
1182
|
),
|
|
1132
|
-
/* @__PURE__ */ c(
|
|
1133
|
-
/* @__PURE__ */ c(
|
|
1183
|
+
/* @__PURE__ */ c(Fe, { color: v, onChange: p, Icon: Yn }),
|
|
1184
|
+
/* @__PURE__ */ c(Fe, { color: y, onChange: f })
|
|
1134
1185
|
] });
|
|
1135
|
-
},
|
|
1136
|
-
var
|
|
1137
|
-
const { onChange: e, interceptorManager: r } = t, n =
|
|
1138
|
-
style:
|
|
1139
|
-
value:
|
|
1140
|
-
type:
|
|
1186
|
+
}, xi = (t) => {
|
|
1187
|
+
var T;
|
|
1188
|
+
const { onChange: e, interceptorManager: r } = t, n = q(re), s = q(Z).getCurrentUnitForType(A.UNIVER_SHEET), o = s.getActiveSheet(), u = ((T = t.rule) == null ? void 0 : T.type) === L.highlightCell ? t.rule : void 0, a = ge(null), [h, l] = N(!1), d = ge(null), [v, p] = N({}), [y, f] = N(() => (u == null ? void 0 : u.subType) === F.formula ? u.value : "="), [w, I] = N(void 0), R = (g) => ({
|
|
1189
|
+
style: g.style,
|
|
1190
|
+
value: y,
|
|
1191
|
+
type: L.highlightCell,
|
|
1141
1192
|
subType: F.formula
|
|
1142
1193
|
});
|
|
1143
1194
|
K(() => r.intercept(r.getInterceptPoints().submit, {
|
|
1144
1195
|
handler() {
|
|
1145
|
-
return R({ style:
|
|
1196
|
+
return R({ style: v });
|
|
1146
1197
|
}
|
|
1147
|
-
}), [
|
|
1148
|
-
handler: (
|
|
1149
|
-
}), [
|
|
1150
|
-
const
|
|
1151
|
-
e(R(
|
|
1198
|
+
}), [v, y, r]), K(() => r.intercept(r.getInterceptPoints().beforeSubmit, {
|
|
1199
|
+
handler: (b, S, C) => w || y.length === 1 || !y.startsWith("=") ? (I(n.t("sheet.cf.errorMessage.formulaError")), !1) : C(b)
|
|
1200
|
+
}), [w, y]);
|
|
1201
|
+
const x = (g) => {
|
|
1202
|
+
e(R(g));
|
|
1152
1203
|
};
|
|
1153
|
-
return Nt((
|
|
1154
|
-
var
|
|
1155
|
-
((
|
|
1204
|
+
return Nt((g) => {
|
|
1205
|
+
var S;
|
|
1206
|
+
((S = d.current) == null ? void 0 : S.isClickOutSide(g)) && l(!1);
|
|
1156
1207
|
}), /* @__PURE__ */ k("div", { ref: a, children: [
|
|
1157
1208
|
/* @__PURE__ */ c(
|
|
1158
1209
|
"div",
|
|
@@ -1164,32 +1215,32 @@ const Me = (t) => {
|
|
|
1164
1215
|
/* @__PURE__ */ c("div", { className: "univer-mt-3", children: /* @__PURE__ */ c(
|
|
1165
1216
|
Mt,
|
|
1166
1217
|
{
|
|
1167
|
-
ref:
|
|
1168
|
-
className: X("univer-box-border univer-h-8 univer-w-full univer-cursor-pointer univer-items-center univer-rounded-lg univer-bg-white univer-pt-2 univer-transition-colors [&>div:first-child]:univer-px-2.5 [&>div]:univer-h-5 [&>div]:univer-ring-transparent dark:!univer-bg-gray-700 dark:!univer-text-white hover:univer-border-primary-600",
|
|
1169
|
-
errorText:
|
|
1218
|
+
ref: d,
|
|
1219
|
+
className: X("univer-box-border univer-h-8 univer-w-full univer-cursor-pointer univer-items-center univer-rounded-lg univer-bg-white univer-pt-2 univer-transition-colors [&>div:first-child]:univer-px-2.5 [&>div]:univer-h-5 [&>div]:univer-ring-transparent dark:!univer-bg-gray-700 dark:!univer-text-white hover:univer-border-primary-600", Be),
|
|
1220
|
+
errorText: w,
|
|
1170
1221
|
isFocus: h,
|
|
1171
|
-
initValue:
|
|
1222
|
+
initValue: y,
|
|
1172
1223
|
unitId: s.getUnitId(),
|
|
1173
1224
|
subUnitId: o == null ? void 0 : o.getSheetId(),
|
|
1174
1225
|
onFocus: () => {
|
|
1175
1226
|
l(!0);
|
|
1176
1227
|
},
|
|
1177
|
-
onChange: (
|
|
1178
|
-
f(
|
|
1228
|
+
onChange: (g) => {
|
|
1229
|
+
f(g), x({ style: v });
|
|
1179
1230
|
},
|
|
1180
|
-
onVerify: (
|
|
1181
|
-
!
|
|
1231
|
+
onVerify: (g, b) => {
|
|
1232
|
+
!g || b.length === 1 ? I(n.t("sheet.cf.errorMessage.formulaError")) : I(void 0);
|
|
1182
1233
|
}
|
|
1183
1234
|
}
|
|
1184
1235
|
) }),
|
|
1185
|
-
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(We, { rule: R({ style:
|
|
1236
|
+
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(We, { rule: R({ style: v }) }) }),
|
|
1186
1237
|
/* @__PURE__ */ c(
|
|
1187
|
-
|
|
1238
|
+
zt,
|
|
1188
1239
|
{
|
|
1189
|
-
style:
|
|
1240
|
+
style: u == null ? void 0 : u.style,
|
|
1190
1241
|
className: "univer-mt-3",
|
|
1191
|
-
onChange: (
|
|
1192
|
-
p(
|
|
1242
|
+
onChange: (g) => {
|
|
1243
|
+
p(g), x({ style: g });
|
|
1193
1244
|
}
|
|
1194
1245
|
}
|
|
1195
1246
|
)
|
|
@@ -1203,45 +1254,45 @@ const Me = (t) => {
|
|
|
1203
1254
|
}
|
|
1204
1255
|
),
|
|
1205
1256
|
t.children
|
|
1206
|
-
] }),
|
|
1207
|
-
const { type: e, operator: r, onChange: n, value: i, interceptorManager: s } = t, o =
|
|
1257
|
+
] }), W = (t, e) => ({ label: e.t(`sheet.cf.operator.${t}`), value: t }), Ei = (t) => {
|
|
1258
|
+
const { type: e, operator: r, onChange: n, value: i, interceptorManager: s } = t, o = q(re), [u, a] = N(() => typeof i == "number" ? i : 0), [h, l] = N(""), [d, v] = N(() => typeof i == "string" ? i : ""), [p, y] = N(""), [f, w] = N(() => Array.isArray(i) ? i[0] === void 0 ? 0 : i[0] : 0), [I, R] = N(""), [x, T] = N(() => Array.isArray(i) ? i[1] === void 0 ? 100 : i[1] : 100), [g, b] = N("");
|
|
1208
1259
|
switch (K(() => {
|
|
1209
1260
|
switch (e) {
|
|
1210
1261
|
case F.text: {
|
|
1211
|
-
[
|
|
1262
|
+
[H.beginsWith, H.endsWith, H.containsText, H.notContainsText, H.equal, H.notEqual].includes(r) && n(d);
|
|
1212
1263
|
break;
|
|
1213
1264
|
}
|
|
1214
1265
|
case F.number: {
|
|
1215
|
-
[
|
|
1266
|
+
[U.equal, U.notEqual, U.greaterThan, U.greaterThanOrEqual, U.lessThan, U.lessThanOrEqual].includes(r) && n(u), [U.between, U.notBetween].includes(r) && n([f, x]);
|
|
1216
1267
|
break;
|
|
1217
1268
|
}
|
|
1218
1269
|
}
|
|
1219
1270
|
}, [e]), K(() => {
|
|
1220
|
-
const
|
|
1221
|
-
handler: (
|
|
1271
|
+
const S = s.intercept(s.getInterceptPoints().beforeSubmit, {
|
|
1272
|
+
handler: (C, M, E) => {
|
|
1222
1273
|
switch (e) {
|
|
1223
1274
|
case F.text:
|
|
1224
|
-
if ([
|
|
1225
|
-
return
|
|
1275
|
+
if ([H.beginsWith, H.containsText, H.endsWith, H.notEqual, H.notContainsText, H.equal].includes(r))
|
|
1276
|
+
return d ? E(C) : (y(o.t("sheet.cf.errorMessage.notBlank")), !1);
|
|
1226
1277
|
}
|
|
1227
|
-
return E(
|
|
1278
|
+
return E(C);
|
|
1228
1279
|
}
|
|
1229
1280
|
});
|
|
1230
1281
|
return () => {
|
|
1231
|
-
|
|
1282
|
+
S();
|
|
1232
1283
|
};
|
|
1233
|
-
}, [e,
|
|
1284
|
+
}, [e, u, d, r]), e) {
|
|
1234
1285
|
case F.text: {
|
|
1235
|
-
if ([
|
|
1236
|
-
const
|
|
1237
|
-
|
|
1286
|
+
if ([H.beginsWith, H.endsWith, H.containsText, H.notContainsText, H.equal, H.notEqual].includes(r)) {
|
|
1287
|
+
const S = (C) => {
|
|
1288
|
+
v(C), n(C);
|
|
1238
1289
|
};
|
|
1239
1290
|
return /* @__PURE__ */ c("div", { className: "univer-mt-3", children: /* @__PURE__ */ c(dt, { errorText: p, children: /* @__PURE__ */ c(
|
|
1240
|
-
|
|
1291
|
+
Jr,
|
|
1241
1292
|
{
|
|
1242
|
-
value:
|
|
1243
|
-
onChange: (
|
|
1244
|
-
|
|
1293
|
+
value: d,
|
|
1294
|
+
onChange: (C) => {
|
|
1295
|
+
y(""), S(C);
|
|
1245
1296
|
}
|
|
1246
1297
|
}
|
|
1247
1298
|
) }) });
|
|
@@ -1249,37 +1300,37 @@ const Me = (t) => {
|
|
|
1249
1300
|
break;
|
|
1250
1301
|
}
|
|
1251
1302
|
case F.number: {
|
|
1252
|
-
if ([
|
|
1253
|
-
const
|
|
1254
|
-
a(
|
|
1303
|
+
if ([U.equal, U.notEqual, U.greaterThan, U.greaterThanOrEqual, U.lessThan, U.lessThanOrEqual].includes(r)) {
|
|
1304
|
+
const S = (C) => {
|
|
1305
|
+
a(C || 0), n(C || 0), l("");
|
|
1255
1306
|
};
|
|
1256
1307
|
return /* @__PURE__ */ c("div", { className: "univer-mt-3", children: /* @__PURE__ */ c(dt, { errorText: h, children: /* @__PURE__ */ c(
|
|
1257
|
-
|
|
1308
|
+
ke,
|
|
1258
1309
|
{
|
|
1259
1310
|
className: "univer-w-full",
|
|
1260
1311
|
min: Number.MIN_SAFE_INTEGER,
|
|
1261
1312
|
max: Number.MAX_SAFE_INTEGER,
|
|
1262
|
-
value:
|
|
1263
|
-
onChange:
|
|
1313
|
+
value: u,
|
|
1314
|
+
onChange: S
|
|
1264
1315
|
}
|
|
1265
1316
|
) }) });
|
|
1266
1317
|
}
|
|
1267
|
-
if ([
|
|
1268
|
-
const
|
|
1269
|
-
|
|
1270
|
-
},
|
|
1271
|
-
|
|
1318
|
+
if ([U.between, U.notBetween].includes(r)) {
|
|
1319
|
+
const S = (M) => {
|
|
1320
|
+
w(M || 0), n([M || 0, x]), R("");
|
|
1321
|
+
}, C = (M) => {
|
|
1322
|
+
T(M || 0), n([f, M || 0]), b("");
|
|
1272
1323
|
};
|
|
1273
1324
|
return /* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-items-center", children: [
|
|
1274
|
-
/* @__PURE__ */ c(dt, { errorText:
|
|
1275
|
-
/* @__PURE__ */ c(dt, { errorText:
|
|
1276
|
-
|
|
1325
|
+
/* @__PURE__ */ c(dt, { errorText: I, children: /* @__PURE__ */ c(ke, { min: Number.MIN_SAFE_INTEGER, max: Number.MAX_SAFE_INTEGER, value: f, onChange: S }) }),
|
|
1326
|
+
/* @__PURE__ */ c(dt, { errorText: g, children: /* @__PURE__ */ c(
|
|
1327
|
+
ke,
|
|
1277
1328
|
{
|
|
1278
1329
|
className: "univer-ml-3",
|
|
1279
1330
|
min: Number.MIN_SAFE_INTEGER,
|
|
1280
1331
|
max: Number.MAX_SAFE_INTEGER,
|
|
1281
|
-
value:
|
|
1282
|
-
onChange:
|
|
1332
|
+
value: x,
|
|
1333
|
+
onChange: C
|
|
1283
1334
|
}
|
|
1284
1335
|
) })
|
|
1285
1336
|
] });
|
|
@@ -1287,52 +1338,52 @@ const Me = (t) => {
|
|
|
1287
1338
|
}
|
|
1288
1339
|
}
|
|
1289
1340
|
return null;
|
|
1290
|
-
},
|
|
1341
|
+
}, sn = (t, e) => {
|
|
1291
1342
|
switch (t) {
|
|
1292
1343
|
case F.text:
|
|
1293
1344
|
return [
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1345
|
+
W(H.containsText, e),
|
|
1346
|
+
W(H.notContainsText, e),
|
|
1347
|
+
W(H.beginsWith, e),
|
|
1348
|
+
W(H.endsWith, e),
|
|
1349
|
+
W(H.equal, e),
|
|
1350
|
+
W(H.notEqual, e),
|
|
1351
|
+
W(H.containsBlanks, e),
|
|
1352
|
+
W(H.notContainsBlanks, e),
|
|
1353
|
+
W(H.containsErrors, e),
|
|
1354
|
+
W(H.notContainsErrors, e)
|
|
1304
1355
|
];
|
|
1305
1356
|
case F.number:
|
|
1306
1357
|
return [
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1358
|
+
W(U.between, e),
|
|
1359
|
+
W(U.notBetween, e),
|
|
1360
|
+
W(U.equal, e),
|
|
1361
|
+
W(U.notEqual, e),
|
|
1362
|
+
W(U.greaterThan, e),
|
|
1363
|
+
W(U.greaterThanOrEqual, e),
|
|
1364
|
+
W(U.lessThan, e),
|
|
1365
|
+
W(U.lessThanOrEqual, e)
|
|
1315
1366
|
];
|
|
1316
1367
|
case F.timePeriod:
|
|
1317
1368
|
return [
|
|
1318
|
-
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1369
|
+
W(ve.yesterday, e),
|
|
1370
|
+
W(ve.today, e),
|
|
1371
|
+
W(ve.tomorrow, e),
|
|
1372
|
+
W(ve.last7Days, e),
|
|
1373
|
+
W(ve.lastWeek, e),
|
|
1374
|
+
W(ve.thisWeek, e),
|
|
1375
|
+
W(ve.nextWeek, e),
|
|
1376
|
+
W(ve.lastMonth, e),
|
|
1377
|
+
W(ve.thisMonth, e),
|
|
1378
|
+
W(ve.nextMonth, e)
|
|
1328
1379
|
];
|
|
1329
1380
|
}
|
|
1330
|
-
},
|
|
1331
|
-
var
|
|
1332
|
-
const { interceptorManager: e, onChange: r } = t, n =
|
|
1333
|
-
const
|
|
1334
|
-
return i && i.subType ||
|
|
1335
|
-
}),
|
|
1381
|
+
}, on = (t) => {
|
|
1382
|
+
var T;
|
|
1383
|
+
const { interceptorManager: e, onChange: r } = t, n = q(re), i = ((T = t.rule) == null ? void 0 : T.type) === L.highlightCell ? t.rule : void 0, [s, o] = N(() => {
|
|
1384
|
+
const g = F.text;
|
|
1385
|
+
return i && i.subType || g;
|
|
1386
|
+
}), u = [{
|
|
1336
1387
|
value: F.text,
|
|
1337
1388
|
label: n.t("sheet.cf.subRuleType.text")
|
|
1338
1389
|
}, {
|
|
@@ -1347,70 +1398,70 @@ const Me = (t) => {
|
|
|
1347
1398
|
}, {
|
|
1348
1399
|
value: F.uniqueValues,
|
|
1349
1400
|
label: n.t("sheet.cf.subRuleType.uniqueValues")
|
|
1350
|
-
}], a = J(() =>
|
|
1351
|
-
const
|
|
1352
|
-
return i && i.operator ||
|
|
1353
|
-
}), [
|
|
1354
|
-
var
|
|
1355
|
-
const
|
|
1356
|
-
return i ? (
|
|
1357
|
-
}), [p,
|
|
1358
|
-
var
|
|
1359
|
-
switch (
|
|
1401
|
+
}], a = J(() => sn(s, n), [s]), [h, l] = N(() => {
|
|
1402
|
+
const g = a ? a[0].value : void 0;
|
|
1403
|
+
return i && i.operator || g;
|
|
1404
|
+
}), [d, v] = N(() => {
|
|
1405
|
+
var S;
|
|
1406
|
+
const g = "";
|
|
1407
|
+
return i ? (S = i.value) != null ? S : mt(i.subType, i.operator) : g;
|
|
1408
|
+
}), [p, y] = N({}), f = J(() => (g) => {
|
|
1409
|
+
var b, S, C, M, E, V, O, m, _, j, Y, pe, Ce, Le, Ue;
|
|
1410
|
+
switch (g.subType || s) {
|
|
1360
1411
|
case F.text: {
|
|
1361
|
-
if ([
|
|
1412
|
+
if ([H.beginsWith, H.endsWith, H.containsText, H.notContainsText, H.equal, H.notEqual].includes(h))
|
|
1362
1413
|
return {
|
|
1363
|
-
type:
|
|
1364
|
-
subType: (
|
|
1365
|
-
operator: (
|
|
1366
|
-
style: (
|
|
1367
|
-
value: (M =
|
|
1414
|
+
type: L.highlightCell,
|
|
1415
|
+
subType: (b = g.subType) != null ? b : s,
|
|
1416
|
+
operator: (S = g.operator) != null ? S : h,
|
|
1417
|
+
style: (C = g.style) != null ? C : p,
|
|
1418
|
+
value: (M = g.value) != null ? M : d
|
|
1368
1419
|
};
|
|
1369
1420
|
break;
|
|
1370
1421
|
}
|
|
1371
1422
|
case F.number: {
|
|
1372
|
-
if ([
|
|
1423
|
+
if ([U.equal, U.notEqual, U.greaterThan, U.greaterThanOrEqual, U.lessThan, U.lessThanOrEqual].includes(h))
|
|
1373
1424
|
return {
|
|
1374
|
-
type:
|
|
1375
|
-
subType: (E =
|
|
1376
|
-
operator: (V =
|
|
1377
|
-
style: (
|
|
1378
|
-
value: (m =
|
|
1425
|
+
type: L.highlightCell,
|
|
1426
|
+
subType: (E = g.subType) != null ? E : s,
|
|
1427
|
+
operator: (V = g.operator) != null ? V : h,
|
|
1428
|
+
style: (O = g.style) != null ? O : p,
|
|
1429
|
+
value: (m = g.value) != null ? m : d
|
|
1379
1430
|
};
|
|
1380
|
-
if ([
|
|
1431
|
+
if ([U.between, U.notBetween].includes(h))
|
|
1381
1432
|
return {
|
|
1382
|
-
type:
|
|
1383
|
-
subType: (
|
|
1384
|
-
operator: (
|
|
1385
|
-
style: (Y =
|
|
1386
|
-
value: (
|
|
1433
|
+
type: L.highlightCell,
|
|
1434
|
+
subType: (_ = g.subType) != null ? _ : s,
|
|
1435
|
+
operator: (j = g.operator) != null ? j : h,
|
|
1436
|
+
style: (Y = g.style) != null ? Y : p,
|
|
1437
|
+
value: (pe = g.value) != null ? pe : d
|
|
1387
1438
|
};
|
|
1388
1439
|
break;
|
|
1389
1440
|
}
|
|
1390
1441
|
}
|
|
1391
1442
|
return {
|
|
1392
|
-
type:
|
|
1393
|
-
subType: (
|
|
1394
|
-
operator: (
|
|
1395
|
-
style: (
|
|
1443
|
+
type: L.highlightCell,
|
|
1444
|
+
subType: (Ce = g.subType) != null ? Ce : s,
|
|
1445
|
+
operator: (Le = g.operator) != null ? Le : h,
|
|
1446
|
+
style: (Ue = g.style) != null ? Ue : p
|
|
1396
1447
|
};
|
|
1397
|
-
}, [s, h,
|
|
1448
|
+
}, [s, h, d, p]);
|
|
1398
1449
|
K(() => e.intercept(e.getInterceptPoints().submit, {
|
|
1399
1450
|
handler() {
|
|
1400
1451
|
return f({});
|
|
1401
1452
|
}
|
|
1402
1453
|
}), [f, e]), K(() => {
|
|
1403
|
-
|
|
1404
|
-
}, [
|
|
1405
|
-
const
|
|
1406
|
-
const
|
|
1407
|
-
o(
|
|
1408
|
-
},
|
|
1409
|
-
const
|
|
1410
|
-
l(
|
|
1411
|
-
}, R = (
|
|
1412
|
-
g
|
|
1413
|
-
},
|
|
1454
|
+
u.some((g) => g.value === s) || o(u[0].value);
|
|
1455
|
+
}, [u]);
|
|
1456
|
+
const w = (g) => {
|
|
1457
|
+
const b = g, S = sn(b, n), C = S && S[0].value;
|
|
1458
|
+
o(b), l(C), C && v(mt(b, C)), r(f({ subType: b, operator: C }));
|
|
1459
|
+
}, I = (g) => {
|
|
1460
|
+
const b = g;
|
|
1461
|
+
l(b), r(f({ operator: b }));
|
|
1462
|
+
}, R = (g) => {
|
|
1463
|
+
v(g), r(f({ value: g }));
|
|
1464
|
+
}, x = J(() => `${s}_${h}_${Math.random()}`, [s, h]);
|
|
1414
1465
|
return /* @__PURE__ */ k("div", { children: [
|
|
1415
1466
|
/* @__PURE__ */ c(
|
|
1416
1467
|
"div",
|
|
@@ -1421,103 +1472,103 @@ const Me = (t) => {
|
|
|
1421
1472
|
),
|
|
1422
1473
|
/* @__PURE__ */ k("div", { className: "univer-flex univer-justify-between univer-gap-4", children: [
|
|
1423
1474
|
/* @__PURE__ */ c(
|
|
1424
|
-
|
|
1475
|
+
ce,
|
|
1425
1476
|
{
|
|
1426
1477
|
className: "univer-mt-3 univer-w-full",
|
|
1427
|
-
onChange:
|
|
1478
|
+
onChange: w,
|
|
1428
1479
|
value: s,
|
|
1429
|
-
options:
|
|
1480
|
+
options: u
|
|
1430
1481
|
}
|
|
1431
1482
|
),
|
|
1432
1483
|
(a == null ? void 0 : a.length) && /* @__PURE__ */ c(
|
|
1433
|
-
|
|
1484
|
+
ce,
|
|
1434
1485
|
{
|
|
1435
1486
|
className: "univer-mt-3 univer-w-full",
|
|
1436
|
-
onChange:
|
|
1487
|
+
onChange: I,
|
|
1437
1488
|
value: h || "",
|
|
1438
1489
|
options: a
|
|
1439
1490
|
}
|
|
1440
1491
|
)
|
|
1441
1492
|
] }),
|
|
1442
1493
|
/* @__PURE__ */ c(
|
|
1443
|
-
|
|
1494
|
+
Ei,
|
|
1444
1495
|
{
|
|
1445
|
-
value:
|
|
1496
|
+
value: d,
|
|
1446
1497
|
interceptorManager: e,
|
|
1447
1498
|
type: s,
|
|
1448
1499
|
operator: h,
|
|
1449
1500
|
rule: i,
|
|
1450
1501
|
onChange: R
|
|
1451
1502
|
},
|
|
1452
|
-
|
|
1503
|
+
x
|
|
1453
1504
|
),
|
|
1454
1505
|
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(We, { rule: f({}) }) }),
|
|
1455
1506
|
/* @__PURE__ */ c(
|
|
1456
|
-
|
|
1507
|
+
zt,
|
|
1457
1508
|
{
|
|
1458
1509
|
style: i == null ? void 0 : i.style,
|
|
1459
1510
|
className: "univer-ml-1",
|
|
1460
|
-
onChange: (
|
|
1461
|
-
|
|
1511
|
+
onChange: (g) => {
|
|
1512
|
+
y(g), r(f({ style: g }));
|
|
1462
1513
|
}
|
|
1463
1514
|
}
|
|
1464
1515
|
)
|
|
1465
1516
|
] });
|
|
1466
|
-
},
|
|
1517
|
+
}, nr = (t, e) => (Ve[t] || [])[Number(e)] || "", Ni = (t) => {
|
|
1467
1518
|
var l;
|
|
1468
|
-
const { error: e, type: r, onChange: n } = t, i =
|
|
1469
|
-
return Nt((
|
|
1519
|
+
const { error: e, type: r, onChange: n } = t, i = q(Z), s = i.getCurrentUnitForType(A.UNIVER_SHEET).getUnitId(), o = (l = i.getCurrentUnitForType(A.UNIVER_SHEET).getActiveSheet()) == null ? void 0 : l.getSheetId(), u = ge(null), [a, h] = N(!1);
|
|
1520
|
+
return Nt((d) => {
|
|
1470
1521
|
var p;
|
|
1471
|
-
((p =
|
|
1472
|
-
}), /* @__PURE__ */ c("div", { className: "univer-relative", children: r !==
|
|
1522
|
+
((p = u.current) == null ? void 0 : p.isClickOutSide(d)) && h(!1);
|
|
1523
|
+
}), /* @__PURE__ */ c("div", { className: "univer-relative", children: r !== D.formula ? /* @__PURE__ */ k(jt, { children: [
|
|
1473
1524
|
/* @__PURE__ */ c(
|
|
1474
|
-
|
|
1525
|
+
ke,
|
|
1475
1526
|
{
|
|
1476
1527
|
className: X({
|
|
1477
1528
|
"univer-border-red-500": e
|
|
1478
1529
|
}),
|
|
1479
1530
|
value: Number(t.value) || 0,
|
|
1480
|
-
onChange: (
|
|
1531
|
+
onChange: (d) => n(d != null ? d : 0)
|
|
1481
1532
|
}
|
|
1482
1533
|
),
|
|
1483
1534
|
e && /* @__PURE__ */ c("div", { className: "univer-absolute univer-text-xs univer-text-red-500", children: e })
|
|
1484
1535
|
] }) : /* @__PURE__ */ c("div", { className: "univer-w-full", children: /* @__PURE__ */ c(
|
|
1485
1536
|
Mt,
|
|
1486
1537
|
{
|
|
1487
|
-
ref:
|
|
1538
|
+
ref: u,
|
|
1488
1539
|
initValue: String(t.value),
|
|
1489
1540
|
unitId: s,
|
|
1490
1541
|
subUnitId: o,
|
|
1491
1542
|
isFocus: a,
|
|
1492
|
-
onChange: (
|
|
1493
|
-
n(
|
|
1543
|
+
onChange: (d = "") => {
|
|
1544
|
+
n(d || "");
|
|
1494
1545
|
},
|
|
1495
1546
|
onFocus: () => h(!0)
|
|
1496
1547
|
}
|
|
1497
1548
|
) }) });
|
|
1498
|
-
},
|
|
1499
|
-
operator:
|
|
1500
|
-
value: { type:
|
|
1549
|
+
}, an = (t, e, r) => ({
|
|
1550
|
+
operator: U.greaterThan,
|
|
1551
|
+
value: { type: D.num, value: (r.length - 1 - e) * 10 },
|
|
1501
1552
|
iconType: t,
|
|
1502
1553
|
iconId: String(e)
|
|
1503
|
-
}),
|
|
1504
|
-
const { onClick: r } = t, n =
|
|
1554
|
+
}), Mi = oe((t, e) => {
|
|
1555
|
+
const { onClick: r } = t, n = q(re), i = (s) => {
|
|
1505
1556
|
r(s);
|
|
1506
1557
|
};
|
|
1507
|
-
return /* @__PURE__ */ c("div", { ref: e, className: "univer-w-80", children:
|
|
1558
|
+
return /* @__PURE__ */ c("div", { ref: e, className: "univer-w-80", children: br.map((s, o) => /* @__PURE__ */ k("div", { className: "univer-mb-3", children: [
|
|
1508
1559
|
/* @__PURE__ */ c("div", { className: "univer-mb-1 univer-text-sm", children: n.t(s.title) }),
|
|
1509
|
-
/* @__PURE__ */ c("div", { className: "univer-flex univer-flex-wrap", children: s.group.map((
|
|
1560
|
+
/* @__PURE__ */ c("div", { className: "univer-flex univer-flex-wrap", children: s.group.map((u) => /* @__PURE__ */ c(
|
|
1510
1561
|
"div",
|
|
1511
1562
|
{
|
|
1512
1563
|
className: "univer-mb-1 univer-flex univer-w-1/2 univer-items-center",
|
|
1513
1564
|
onClick: () => {
|
|
1514
|
-
i(
|
|
1565
|
+
i(u.name);
|
|
1515
1566
|
},
|
|
1516
1567
|
children: /* @__PURE__ */ c(
|
|
1517
1568
|
"a",
|
|
1518
1569
|
{
|
|
1519
1570
|
className: "univer-cursor-pointer univer-rounded dark:hover:!univer-bg-gray-700 hover:univer-bg-gray-100",
|
|
1520
|
-
children:
|
|
1571
|
+
children: u.list.map((a, h) => /* @__PURE__ */ c(
|
|
1521
1572
|
"img",
|
|
1522
1573
|
{
|
|
1523
1574
|
className: "univer-size-5",
|
|
@@ -1529,17 +1580,17 @@ const Me = (t) => {
|
|
|
1529
1580
|
}
|
|
1530
1581
|
)
|
|
1531
1582
|
},
|
|
1532
|
-
|
|
1583
|
+
u.name
|
|
1533
1584
|
)) })
|
|
1534
1585
|
] }, o)) });
|
|
1535
|
-
}),
|
|
1586
|
+
}), Vi = (t) => {
|
|
1536
1587
|
const { onClick: e } = t, r = J(() => {
|
|
1537
1588
|
const i = [];
|
|
1538
|
-
for (const s in
|
|
1539
|
-
const o =
|
|
1589
|
+
for (const s in Ve) {
|
|
1590
|
+
const o = Ve[s], u = s;
|
|
1540
1591
|
o.forEach((a, h) => {
|
|
1541
1592
|
i.push({
|
|
1542
|
-
iconType:
|
|
1593
|
+
iconType: u,
|
|
1543
1594
|
base64: a,
|
|
1544
1595
|
iconId: String(h)
|
|
1545
1596
|
});
|
|
@@ -1554,7 +1605,7 @@ const Me = (t) => {
|
|
|
1554
1605
|
"div",
|
|
1555
1606
|
{
|
|
1556
1607
|
className: "univer-mb-2.5 univer-flex univer-cursor-pointer univer-items-center univer-pl-1",
|
|
1557
|
-
onClick: () => n({ iconType:
|
|
1608
|
+
onClick: () => n({ iconType: Sr, iconId: "" }),
|
|
1558
1609
|
children: [
|
|
1559
1610
|
/* @__PURE__ */ c(ot, { className: "univer-size-5" }),
|
|
1560
1611
|
/* @__PURE__ */ c("span", { className: "univer-ml-2", children: "无单元格图标" })
|
|
@@ -1578,32 +1629,32 @@ const Me = (t) => {
|
|
|
1578
1629
|
`${i.iconType}_${i.iconId}`
|
|
1579
1630
|
)) })
|
|
1580
1631
|
] });
|
|
1581
|
-
},
|
|
1582
|
-
const { onChange: e, configList: r, errorMap: n = {} } = t, i =
|
|
1583
|
-
{ label: i.t(`sheet.cf.valueType.${
|
|
1584
|
-
{ label: i.t(`sheet.cf.valueType.${
|
|
1585
|
-
{ label: i.t(`sheet.cf.valueType.${
|
|
1586
|
-
{ label: i.t(`sheet.cf.valueType.${
|
|
1587
|
-
],
|
|
1588
|
-
e([String(
|
|
1589
|
-
}, a = (
|
|
1590
|
-
e([String(
|
|
1591
|
-
const p = mt(F.number,
|
|
1592
|
-
|
|
1593
|
-
}, h = (
|
|
1594
|
-
e([String(
|
|
1595
|
-
const p = r[
|
|
1596
|
-
|
|
1632
|
+
}, ki = (t) => {
|
|
1633
|
+
const { onChange: e, configList: r, errorMap: n = {} } = t, i = q(re), s = [{ label: i.t(`sheet.cf.symbol.${U.greaterThan}`), value: U.greaterThan }, { label: i.t(`sheet.cf.symbol.${U.greaterThanOrEqual}`), value: U.greaterThanOrEqual }], o = [
|
|
1634
|
+
{ label: i.t(`sheet.cf.valueType.${D.num}`), value: D.num },
|
|
1635
|
+
{ label: i.t(`sheet.cf.valueType.${D.percent}`), value: D.percent },
|
|
1636
|
+
{ label: i.t(`sheet.cf.valueType.${D.percentile}`), value: D.percentile },
|
|
1637
|
+
{ label: i.t(`sheet.cf.valueType.${D.formula}`), value: D.formula }
|
|
1638
|
+
], u = (d, v) => {
|
|
1639
|
+
e([String(v), "value", "value"], d);
|
|
1640
|
+
}, a = (d, v) => {
|
|
1641
|
+
e([String(v), "operator"], d);
|
|
1642
|
+
const p = mt(F.number, d);
|
|
1643
|
+
u(p, v);
|
|
1644
|
+
}, h = (d, v) => {
|
|
1645
|
+
e([String(v), "value", "type"], d);
|
|
1646
|
+
const p = r[v], y = mt(F.number, p.operator);
|
|
1647
|
+
u(y, v);
|
|
1597
1648
|
};
|
|
1598
|
-
return J(() => r.map((
|
|
1599
|
-
const p = n[
|
|
1600
|
-
const
|
|
1601
|
-
e([String(
|
|
1649
|
+
return J(() => r.map((d, v) => {
|
|
1650
|
+
const p = n[v], y = nr(d.iconType, d.iconId), f = v === r.length - 1, w = v === 0, I = r[v - 1], R = (I == null ? void 0 : I.value.type) === D.formula ? i.t("sheet.cf.valueType.formula") : I == null ? void 0 : I.value.value, x = (T, g) => {
|
|
1651
|
+
const b = { ...d, iconId: g, iconType: T };
|
|
1652
|
+
e([String(v)], b);
|
|
1602
1653
|
};
|
|
1603
1654
|
return /* @__PURE__ */ k(
|
|
1604
1655
|
"div",
|
|
1605
1656
|
{
|
|
1606
|
-
className:
|
|
1657
|
+
className: v ? "univer-mt-6" : "univer-mt-3",
|
|
1607
1658
|
children: [
|
|
1608
1659
|
/* @__PURE__ */ k(
|
|
1609
1660
|
"div",
|
|
@@ -1616,20 +1667,20 @@ const Me = (t) => {
|
|
|
1616
1667
|
className: "univer-w-[45%]",
|
|
1617
1668
|
children: [
|
|
1618
1669
|
i.t("sheet.cf.iconSet.icon"),
|
|
1619
|
-
|
|
1670
|
+
v + 1
|
|
1620
1671
|
]
|
|
1621
1672
|
}
|
|
1622
1673
|
),
|
|
1623
|
-
/* @__PURE__ */ c("div", { className: "univer-w-[45%]", children: /* @__PURE__ */ k(
|
|
1624
|
-
!
|
|
1625
|
-
!
|
|
1674
|
+
/* @__PURE__ */ c("div", { className: "univer-w-[45%]", children: /* @__PURE__ */ k(jt, { children: [
|
|
1675
|
+
!w && !f && i.t("sheet.cf.iconSet.rule"),
|
|
1676
|
+
!w && !f && /* @__PURE__ */ k(
|
|
1626
1677
|
"span",
|
|
1627
1678
|
{
|
|
1628
1679
|
className: "univer-font-medium univer-text-gray-600 dark:!univer-text-gray-200",
|
|
1629
1680
|
children: [
|
|
1630
1681
|
"(",
|
|
1631
1682
|
i.t("sheet.cf.iconSet.when"),
|
|
1632
|
-
i.t(`sheet.cf.symbol.${Ht(
|
|
1683
|
+
i.t(`sheet.cf.symbol.${Ht(I.operator)}`),
|
|
1633
1684
|
R,
|
|
1634
1685
|
f ? "" : ` ${i.t("sheet.cf.iconSet.and")} `,
|
|
1635
1686
|
")"
|
|
@@ -1642,21 +1693,21 @@ const Me = (t) => {
|
|
|
1642
1693
|
),
|
|
1643
1694
|
/* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-items-center univer-justify-between univer-gap-4", children: [
|
|
1644
1695
|
/* @__PURE__ */ c("div", { className: "univer-flex univer-items-center", children: /* @__PURE__ */ c(
|
|
1645
|
-
|
|
1696
|
+
Gt,
|
|
1646
1697
|
{
|
|
1647
|
-
overlay: /* @__PURE__ */ c("div", { className: "univer-rounded-lg univer-p-4", children: /* @__PURE__ */ c(
|
|
1698
|
+
overlay: /* @__PURE__ */ c("div", { className: "univer-rounded-lg univer-p-4", children: /* @__PURE__ */ c(Vi, { onClick: x, iconId: d.iconId, iconType: d.iconType }) }),
|
|
1648
1699
|
children: /* @__PURE__ */ k(
|
|
1649
1700
|
"div",
|
|
1650
1701
|
{
|
|
1651
|
-
className: X("univer-box-border univer-flex univer-h-8 univer-w-full univer-items-center univer-justify-between univer-rounded-md univer-bg-white univer-px-4 univer-py-2 univer-text-xs univer-text-gray-600 univer-transition-all dark:!univer-text-gray-200 hover:univer-border-primary-600",
|
|
1702
|
+
className: X("univer-box-border univer-flex univer-h-8 univer-w-full univer-items-center univer-justify-between univer-rounded-md univer-bg-white univer-px-4 univer-py-2 univer-text-xs univer-text-gray-600 univer-transition-all dark:!univer-text-gray-200 hover:univer-border-primary-600", Be),
|
|
1652
1703
|
children: [
|
|
1653
|
-
|
|
1704
|
+
y ? /* @__PURE__ */ c("img", { src: y, className: "univer-size-4", draggable: !1 }) : /* @__PURE__ */ c(
|
|
1654
1705
|
ot,
|
|
1655
1706
|
{
|
|
1656
1707
|
className: "univer-size-4"
|
|
1657
1708
|
}
|
|
1658
1709
|
),
|
|
1659
|
-
/* @__PURE__ */ c(
|
|
1710
|
+
/* @__PURE__ */ c(Zt, {})
|
|
1660
1711
|
]
|
|
1661
1712
|
}
|
|
1662
1713
|
)
|
|
@@ -1670,24 +1721,24 @@ const Me = (t) => {
|
|
|
1670
1721
|
i.t("sheet.cf.iconSet.rule"),
|
|
1671
1722
|
/* @__PURE__ */ k("span", { className: "univer-font-medium", children: [
|
|
1672
1723
|
i.t("sheet.cf.iconSet.when"),
|
|
1673
|
-
i.t(`sheet.cf.symbol.${Ht(
|
|
1724
|
+
i.t(`sheet.cf.symbol.${Ht(I.operator)}`),
|
|
1674
1725
|
R,
|
|
1675
1726
|
f ? "" : ` ${i.t("sheet.cf.iconSet.and")} `
|
|
1676
1727
|
] })
|
|
1677
1728
|
]
|
|
1678
1729
|
}
|
|
1679
1730
|
) : /* @__PURE__ */ c(
|
|
1680
|
-
|
|
1731
|
+
ce,
|
|
1681
1732
|
{
|
|
1682
1733
|
options: s,
|
|
1683
|
-
value:
|
|
1684
|
-
onChange: (
|
|
1685
|
-
a(
|
|
1734
|
+
value: d.operator,
|
|
1735
|
+
onChange: (T) => {
|
|
1736
|
+
a(T, v);
|
|
1686
1737
|
}
|
|
1687
1738
|
}
|
|
1688
1739
|
)
|
|
1689
1740
|
] }),
|
|
1690
|
-
f ? /* @__PURE__ */ c("div", {}) : /* @__PURE__ */ k(
|
|
1741
|
+
f ? /* @__PURE__ */ c("div", {}) : /* @__PURE__ */ k(jt, { children: [
|
|
1691
1742
|
/* @__PURE__ */ k(
|
|
1692
1743
|
"div",
|
|
1693
1744
|
{
|
|
@@ -1704,25 +1755,25 @@ const Me = (t) => {
|
|
|
1704
1755
|
className: "univer-mt-3 univer-flex univer-items-center univer-justify-between univer-gap-4",
|
|
1705
1756
|
children: [
|
|
1706
1757
|
/* @__PURE__ */ c(
|
|
1707
|
-
|
|
1758
|
+
ce,
|
|
1708
1759
|
{
|
|
1709
1760
|
className: "univer-flex-shrink-0",
|
|
1710
1761
|
options: o,
|
|
1711
|
-
value:
|
|
1712
|
-
onChange: (
|
|
1713
|
-
h(
|
|
1762
|
+
value: d.value.type,
|
|
1763
|
+
onChange: (T) => {
|
|
1764
|
+
h(T, v);
|
|
1714
1765
|
}
|
|
1715
1766
|
}
|
|
1716
1767
|
),
|
|
1717
1768
|
/* @__PURE__ */ c("div", { children: /* @__PURE__ */ c(
|
|
1718
|
-
|
|
1769
|
+
Ni,
|
|
1719
1770
|
{
|
|
1720
|
-
id:
|
|
1721
|
-
type:
|
|
1771
|
+
id: v,
|
|
1772
|
+
type: d.value.type,
|
|
1722
1773
|
error: p,
|
|
1723
|
-
value:
|
|
1724
|
-
onChange: (
|
|
1725
|
-
|
|
1774
|
+
value: d.value.value || "",
|
|
1775
|
+
onChange: (T) => {
|
|
1776
|
+
u(T, v);
|
|
1726
1777
|
}
|
|
1727
1778
|
}
|
|
1728
1779
|
) })
|
|
@@ -1732,102 +1783,102 @@ const Me = (t) => {
|
|
|
1732
1783
|
] })
|
|
1733
1784
|
]
|
|
1734
1785
|
},
|
|
1735
|
-
|
|
1786
|
+
v
|
|
1736
1787
|
);
|
|
1737
1788
|
}), [r, n]);
|
|
1738
|
-
},
|
|
1739
|
-
var
|
|
1740
|
-
const { interceptorManager: e } = t, r = ((
|
|
1741
|
-
const
|
|
1789
|
+
}, Fi = (t) => {
|
|
1790
|
+
var T;
|
|
1791
|
+
const { interceptorManager: e } = t, r = ((T = t.rule) == null ? void 0 : T.type) === L.iconSet ? t.rule : void 0, n = q(re), [i, s] = N({}), [o, u] = N(() => {
|
|
1792
|
+
const g = Object.keys(Ve)[0];
|
|
1742
1793
|
if (r && r.config.length) {
|
|
1743
|
-
const
|
|
1744
|
-
if (!r.config.some((
|
|
1745
|
-
return
|
|
1794
|
+
const b = r.config[0].iconType;
|
|
1795
|
+
if (!r.config.some((C) => C.iconType !== b))
|
|
1796
|
+
return b;
|
|
1746
1797
|
}
|
|
1747
|
-
return
|
|
1798
|
+
return g;
|
|
1748
1799
|
}), [a, h] = N(() => {
|
|
1749
1800
|
if (r && r.config.length)
|
|
1750
|
-
return
|
|
1751
|
-
const
|
|
1752
|
-
return new Array(
|
|
1753
|
-
operator:
|
|
1754
|
-
value: { type:
|
|
1801
|
+
return Bt.deepClone(r == null ? void 0 : r.config);
|
|
1802
|
+
const g = Ve[o] || [];
|
|
1803
|
+
return new Array(g.length).fill("").map((b, S, C) => S === C.length - 1 ? {
|
|
1804
|
+
operator: U.lessThanOrEqual,
|
|
1805
|
+
value: { type: D.num, value: Number.MAX_SAFE_INTEGER },
|
|
1755
1806
|
iconType: o,
|
|
1756
|
-
iconId: String(
|
|
1757
|
-
} :
|
|
1758
|
-
}), [l,
|
|
1759
|
-
const
|
|
1760
|
-
return /* @__PURE__ */ c("div", { className: "univer-flex univer-items-center", children:
|
|
1807
|
+
iconId: String(S)
|
|
1808
|
+
} : an(o, S, C));
|
|
1809
|
+
}), [l, d] = N(() => r ? !!r.isShowValue : !0), v = J(() => {
|
|
1810
|
+
const g = a.map((b) => nr(b.iconType, b.iconId));
|
|
1811
|
+
return /* @__PURE__ */ c("div", { className: "univer-flex univer-items-center", children: g.map((b, S) => b ? /* @__PURE__ */ c(
|
|
1761
1812
|
"img",
|
|
1762
1813
|
{
|
|
1763
1814
|
className: "univer-size-5",
|
|
1764
|
-
src:
|
|
1815
|
+
src: b
|
|
1765
1816
|
},
|
|
1766
|
-
|
|
1767
|
-
) : /* @__PURE__ */ c(ot, { className: "univer-size-5" },
|
|
1768
|
-
}, [a]), p = (
|
|
1769
|
-
if (
|
|
1770
|
-
preType:
|
|
1817
|
+
S
|
|
1818
|
+
) : /* @__PURE__ */ c(ot, { className: "univer-size-5" }, S)) });
|
|
1819
|
+
}, [a]), p = (g) => {
|
|
1820
|
+
if (g.reduce((S, C, M) => S.preType && !S.result || g.length - 1 === M ? S : C.value.type === D.formula ? {
|
|
1821
|
+
preType: D.formula,
|
|
1771
1822
|
result: !1
|
|
1772
|
-
} :
|
|
1773
|
-
result:
|
|
1774
|
-
preType:
|
|
1823
|
+
} : S.preType ? {
|
|
1824
|
+
result: S.preType === C.value.type,
|
|
1825
|
+
preType: C.value.type
|
|
1775
1826
|
} : {
|
|
1776
1827
|
result: !0,
|
|
1777
|
-
preType:
|
|
1778
|
-
}, { result: !0, preType: "" }).result && [
|
|
1779
|
-
const
|
|
1780
|
-
return
|
|
1828
|
+
preType: C.value.type
|
|
1829
|
+
}, { result: !0, preType: "" }).result && [D.num, D.percent, D.percentile].includes(g[0].value.type)) {
|
|
1830
|
+
const S = {};
|
|
1831
|
+
return g.forEach((C, M, E) => {
|
|
1781
1832
|
if (M - 1 < 0 || M === E.length - 1)
|
|
1782
1833
|
return;
|
|
1783
|
-
const
|
|
1784
|
-
|
|
1785
|
-
}),
|
|
1834
|
+
const O = g[M - 1], m = Ht(O.operator);
|
|
1835
|
+
Ir({ operator: m, value: O.value.value }, C.value.value) || (S[M] = `${n.t(`sheet.cf.form.${m}`, String(O.value.value))} `);
|
|
1836
|
+
}), S;
|
|
1786
1837
|
}
|
|
1787
1838
|
return {};
|
|
1788
|
-
},
|
|
1789
|
-
|
|
1790
|
-
}, f = (
|
|
1791
|
-
|
|
1792
|
-
const
|
|
1793
|
-
h(
|
|
1839
|
+
}, y = (g, b) => {
|
|
1840
|
+
ur(a, g) !== b && (dr(a, g, b), h([...a]), s(p(a)));
|
|
1841
|
+
}, f = (g) => {
|
|
1842
|
+
u(g);
|
|
1843
|
+
const b = Ve[g] || [], S = new Array(b.length).fill("").map((C, M, E) => an(g, M, E));
|
|
1844
|
+
h(S), s(p(S));
|
|
1794
1845
|
};
|
|
1795
1846
|
K(() => {
|
|
1796
|
-
const
|
|
1847
|
+
const g = e.intercept(e.getInterceptPoints().submit, {
|
|
1797
1848
|
handler() {
|
|
1798
|
-
return { type:
|
|
1849
|
+
return { type: L.iconSet, isShowValue: l, config: a };
|
|
1799
1850
|
}
|
|
1800
1851
|
});
|
|
1801
1852
|
return () => {
|
|
1802
|
-
|
|
1853
|
+
g();
|
|
1803
1854
|
};
|
|
1804
1855
|
}, [l, a, e]), K(() => {
|
|
1805
|
-
const
|
|
1856
|
+
const g = e.intercept(e.getInterceptPoints().beforeSubmit, {
|
|
1806
1857
|
handler() {
|
|
1807
1858
|
return Object.keys(i).length === 0;
|
|
1808
1859
|
}
|
|
1809
1860
|
});
|
|
1810
1861
|
return () => {
|
|
1811
|
-
|
|
1862
|
+
g();
|
|
1812
1863
|
};
|
|
1813
1864
|
}, [l, a, e, i]);
|
|
1814
|
-
const
|
|
1815
|
-
const
|
|
1816
|
-
a.forEach((
|
|
1817
|
-
const
|
|
1818
|
-
|
|
1865
|
+
const w = () => {
|
|
1866
|
+
const g = a.map((b) => ({ ...b }));
|
|
1867
|
+
a.forEach((b, S) => {
|
|
1868
|
+
const C = a.length - 1 - S, M = g[C];
|
|
1869
|
+
b.iconId = M.iconId, b.iconType = M.iconType;
|
|
1819
1870
|
}), h([...a]);
|
|
1820
|
-
},
|
|
1821
|
-
return
|
|
1871
|
+
}, I = q(jr), [R, x] = N();
|
|
1872
|
+
return Br(R, I.rootContainerElement), /* @__PURE__ */ k("div", { children: [
|
|
1822
1873
|
/* @__PURE__ */ c("div", { className: "univer-mt-4 univer-text-sm univer-text-gray-600", children: n.t("sheet.cf.panel.styleRule") }),
|
|
1823
1874
|
/* @__PURE__ */ c("div", { className: "univer-mt-3", children: /* @__PURE__ */ c(
|
|
1824
|
-
|
|
1875
|
+
Gt,
|
|
1825
1876
|
{
|
|
1826
1877
|
overlay: /* @__PURE__ */ c("div", { className: "univer-rounded-lg univer-p-4", children: /* @__PURE__ */ c(
|
|
1827
|
-
|
|
1878
|
+
Mi,
|
|
1828
1879
|
{
|
|
1829
|
-
ref: (
|
|
1830
|
-
!R &&
|
|
1880
|
+
ref: (g) => {
|
|
1881
|
+
!R && g && x(g);
|
|
1831
1882
|
},
|
|
1832
1883
|
iconType: o,
|
|
1833
1884
|
onClick: f
|
|
@@ -1836,10 +1887,10 @@ const Me = (t) => {
|
|
|
1836
1887
|
children: /* @__PURE__ */ k(
|
|
1837
1888
|
"div",
|
|
1838
1889
|
{
|
|
1839
|
-
className: X("univer-box-border univer-flex univer-h-8 univer-w-full univer-items-center univer-justify-between univer-rounded-md univer-bg-white univer-px-4 univer-py-2 univer-text-xs univer-text-gray-600 univer-transition-all hover:univer-border-primary-600",
|
|
1890
|
+
className: X("univer-box-border univer-flex univer-h-8 univer-w-full univer-items-center univer-justify-between univer-rounded-md univer-bg-white univer-px-4 univer-py-2 univer-text-xs univer-text-gray-600 univer-transition-all hover:univer-border-primary-600", Be),
|
|
1840
1891
|
children: [
|
|
1841
|
-
|
|
1842
|
-
/* @__PURE__ */ c(
|
|
1892
|
+
v,
|
|
1893
|
+
/* @__PURE__ */ c(Zt, {})
|
|
1843
1894
|
]
|
|
1844
1895
|
}
|
|
1845
1896
|
)
|
|
@@ -1847,76 +1898,76 @@ const Me = (t) => {
|
|
|
1847
1898
|
) }),
|
|
1848
1899
|
/* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-items-center univer-text-xs", children: [
|
|
1849
1900
|
/* @__PURE__ */ k("div", { className: "univer-flex univer-items-center univer-text-xs", children: [
|
|
1850
|
-
/* @__PURE__ */ c(yt, { onChange:
|
|
1901
|
+
/* @__PURE__ */ c(yt, { onChange: w }),
|
|
1851
1902
|
n.t("sheet.cf.iconSet.reverseIconOrder")
|
|
1852
1903
|
] }),
|
|
1853
1904
|
/* @__PURE__ */ k("div", { className: "univer-ml-6 univer-flex univer-items-center univer-text-xs", children: [
|
|
1854
|
-
/* @__PURE__ */ c(yt, { checked: !l, onChange: (
|
|
1855
|
-
|
|
1905
|
+
/* @__PURE__ */ c(yt, { checked: !l, onChange: (g) => {
|
|
1906
|
+
d(!g);
|
|
1856
1907
|
} }),
|
|
1857
1908
|
n.t("sheet.cf.iconSet.onlyShowIcon")
|
|
1858
1909
|
] })
|
|
1859
1910
|
] }),
|
|
1860
|
-
/* @__PURE__ */ c(
|
|
1911
|
+
/* @__PURE__ */ c(ki, { errorMap: i, onChange: y, configList: a })
|
|
1861
1912
|
] });
|
|
1862
|
-
},
|
|
1863
|
-
var
|
|
1864
|
-
const { onChange: e, interceptorManager: r } = t, n =
|
|
1865
|
-
const
|
|
1913
|
+
}, Li = (t) => {
|
|
1914
|
+
var w;
|
|
1915
|
+
const { onChange: e, interceptorManager: r } = t, n = q(re), i = ((w = t.rule) == null ? void 0 : w.type) === L.highlightCell ? t.rule : void 0, s = [{ label: n.t("sheet.cf.panel.isNotBottom"), value: "isNotBottom" }, { label: n.t("sheet.cf.panel.isBottom"), value: "isBottom" }, { label: n.t("sheet.cf.panel.greaterThanAverage"), value: "greaterThanAverage" }, { label: n.t("sheet.cf.panel.lessThanAverage"), value: "lessThanAverage" }], [o, u] = N(() => {
|
|
1916
|
+
const I = s[0].value, R = i == null ? void 0 : i.type;
|
|
1866
1917
|
if (!i)
|
|
1867
|
-
return
|
|
1918
|
+
return I;
|
|
1868
1919
|
switch (R) {
|
|
1869
|
-
case
|
|
1920
|
+
case L.highlightCell:
|
|
1870
1921
|
switch (i.subType) {
|
|
1871
1922
|
case F.average:
|
|
1872
|
-
return [
|
|
1923
|
+
return [U.greaterThan, U.greaterThanOrEqual].includes(i.operator) ? "greaterThanAverage" : [U.lessThan, U.lessThanOrEqual].includes(i.operator) ? "lessThanAverage" : I;
|
|
1873
1924
|
case F.rank:
|
|
1874
1925
|
return i.isBottom ? "isBottom" : "isNotBottom";
|
|
1875
1926
|
}
|
|
1876
1927
|
}
|
|
1877
|
-
return
|
|
1928
|
+
return I;
|
|
1878
1929
|
}), [a, h] = N(() => {
|
|
1879
1930
|
const R = i == null ? void 0 : i.type;
|
|
1880
1931
|
if (!i)
|
|
1881
1932
|
return 10;
|
|
1882
1933
|
switch (R) {
|
|
1883
|
-
case
|
|
1934
|
+
case L.highlightCell:
|
|
1884
1935
|
switch (i.subType) {
|
|
1885
1936
|
case F.rank:
|
|
1886
1937
|
return i.value || 10;
|
|
1887
1938
|
}
|
|
1888
1939
|
}
|
|
1889
1940
|
return 10;
|
|
1890
|
-
}), [l,
|
|
1941
|
+
}), [l, d] = N(() => {
|
|
1891
1942
|
const R = i == null ? void 0 : i.type;
|
|
1892
1943
|
if (!i)
|
|
1893
1944
|
return !1;
|
|
1894
1945
|
switch (R) {
|
|
1895
|
-
case
|
|
1946
|
+
case L.highlightCell:
|
|
1896
1947
|
switch (i.subType) {
|
|
1897
1948
|
case F.rank:
|
|
1898
1949
|
return i.isPercent || !1;
|
|
1899
1950
|
}
|
|
1900
1951
|
}
|
|
1901
1952
|
return !1;
|
|
1902
|
-
}), [
|
|
1903
|
-
const { type: R, isPercent:
|
|
1953
|
+
}), [v, p] = N({}), y = (I) => {
|
|
1954
|
+
const { type: R, isPercent: x, value: T, style: g } = I;
|
|
1904
1955
|
if (R === "isNotBottom")
|
|
1905
|
-
return { type:
|
|
1956
|
+
return { type: L.highlightCell, subType: F.rank, isPercent: x, isBottom: !1, value: T, style: g };
|
|
1906
1957
|
if (R === "isBottom")
|
|
1907
|
-
return { type:
|
|
1958
|
+
return { type: L.highlightCell, subType: F.rank, isPercent: x, isBottom: !0, value: T, style: g };
|
|
1908
1959
|
if (R === "greaterThanAverage")
|
|
1909
|
-
return { type:
|
|
1960
|
+
return { type: L.highlightCell, subType: F.average, operator: U.greaterThan, style: g };
|
|
1910
1961
|
if (R === "lessThanAverage")
|
|
1911
|
-
return { type:
|
|
1962
|
+
return { type: L.highlightCell, subType: F.average, operator: U.lessThan, style: g };
|
|
1912
1963
|
};
|
|
1913
1964
|
K(() => r.intercept(r.getInterceptPoints().submit, {
|
|
1914
1965
|
handler() {
|
|
1915
|
-
return
|
|
1966
|
+
return y({ type: o, isPercent: l, value: a, style: v });
|
|
1916
1967
|
}
|
|
1917
|
-
}), [o, l, a,
|
|
1918
|
-
const f = (
|
|
1919
|
-
e(
|
|
1968
|
+
}), [o, l, a, v, r]);
|
|
1969
|
+
const f = (I) => {
|
|
1970
|
+
e(y(I));
|
|
1920
1971
|
};
|
|
1921
1972
|
return /* @__PURE__ */ k("div", { children: [
|
|
1922
1973
|
/* @__PURE__ */ c(
|
|
@@ -1927,26 +1978,26 @@ const Me = (t) => {
|
|
|
1927
1978
|
}
|
|
1928
1979
|
),
|
|
1929
1980
|
/* @__PURE__ */ c(
|
|
1930
|
-
|
|
1981
|
+
ce,
|
|
1931
1982
|
{
|
|
1932
1983
|
className: "univer-mt-3 univer-w-full",
|
|
1933
1984
|
value: o,
|
|
1934
1985
|
options: s,
|
|
1935
|
-
onChange: (
|
|
1936
|
-
|
|
1986
|
+
onChange: (I) => {
|
|
1987
|
+
u(I), f({ type: I, isPercent: l, value: a, style: v });
|
|
1937
1988
|
}
|
|
1938
1989
|
}
|
|
1939
1990
|
),
|
|
1940
1991
|
["isNotBottom", "isBottom"].includes(o) && /* @__PURE__ */ k("div", { className: "univer-mt-3 univer-flex univer-items-center", children: [
|
|
1941
1992
|
/* @__PURE__ */ c(
|
|
1942
|
-
|
|
1993
|
+
ke,
|
|
1943
1994
|
{
|
|
1944
1995
|
min: 1,
|
|
1945
1996
|
max: 1e3,
|
|
1946
1997
|
value: a,
|
|
1947
|
-
onChange: (
|
|
1948
|
-
const R =
|
|
1949
|
-
h(R), f({ type: o, isPercent: l, value: R, style:
|
|
1998
|
+
onChange: (I) => {
|
|
1999
|
+
const R = I || 0;
|
|
2000
|
+
h(R), f({ type: o, isPercent: l, value: R, style: v });
|
|
1950
2001
|
}
|
|
1951
2002
|
}
|
|
1952
2003
|
),
|
|
@@ -1959,8 +2010,8 @@ const Me = (t) => {
|
|
|
1959
2010
|
yt,
|
|
1960
2011
|
{
|
|
1961
2012
|
checked: l,
|
|
1962
|
-
onChange: (
|
|
1963
|
-
|
|
2013
|
+
onChange: (I) => {
|
|
2014
|
+
d(!!I), f({ type: o, isPercent: !!I, value: a, style: v });
|
|
1964
2015
|
}
|
|
1965
2016
|
}
|
|
1966
2017
|
),
|
|
@@ -1969,44 +2020,44 @@ const Me = (t) => {
|
|
|
1969
2020
|
}
|
|
1970
2021
|
)
|
|
1971
2022
|
] }),
|
|
1972
|
-
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(We, { rule:
|
|
2023
|
+
/* @__PURE__ */ c("div", { className: at, children: /* @__PURE__ */ c(We, { rule: y({ type: o, isPercent: l, value: a, style: v }) }) }),
|
|
1973
2024
|
/* @__PURE__ */ c(
|
|
1974
|
-
|
|
2025
|
+
zt,
|
|
1975
2026
|
{
|
|
1976
2027
|
style: i == null ? void 0 : i.style,
|
|
1977
2028
|
className: "univer-mt-3",
|
|
1978
|
-
onChange: (
|
|
1979
|
-
p(
|
|
2029
|
+
onChange: (I) => {
|
|
2030
|
+
p(I), f({ type: o, isPercent: l, value: a, style: I });
|
|
1980
2031
|
}
|
|
1981
2032
|
}
|
|
1982
2033
|
)
|
|
1983
2034
|
] });
|
|
1984
|
-
},
|
|
2035
|
+
}, Ui = fn("beforeSubmit"), Pi = fn("submit"), ln = (t) => t.getCurrentUnitForType(A.UNIVER_SHEET).getUnitId(), cn = (t) => {
|
|
1985
2036
|
var e;
|
|
1986
|
-
return (e = t.getCurrentUnitForType(
|
|
1987
|
-
},
|
|
1988
|
-
var
|
|
1989
|
-
const e =
|
|
1990
|
-
var V,
|
|
2037
|
+
return (e = t.getCurrentUnitForType(A.UNIVER_SHEET).getActiveSheet()) == null ? void 0 : e.getSheetId();
|
|
2038
|
+
}, Oi = (t) => {
|
|
2039
|
+
var S, C, M;
|
|
2040
|
+
const e = q(re), r = q(te), n = q(Z), i = q(Q), s = q(je), o = ln(n), u = cn(n), [a, h] = N(void 0), l = ge((C = (S = t.rule) == null ? void 0 : S.ranges) != null ? C : []), d = J(() => {
|
|
2041
|
+
var V, O, m;
|
|
1991
2042
|
let E = (V = t.rule) == null ? void 0 : V.ranges;
|
|
1992
|
-
return E != null && E.length || (E = (m = (
|
|
1993
|
-
const
|
|
1994
|
-
return
|
|
1995
|
-
}).filter((
|
|
1996
|
-
}, [t.rule]),
|
|
2043
|
+
return E != null && E.length || (E = (m = (O = s.getCurrentSelections()) == null ? void 0 : O.map((_) => _.range)) != null ? m : []), l.current = E, E != null && E.length ? E.map((_) => {
|
|
2044
|
+
const j = Fn(_);
|
|
2045
|
+
return j === "NaN" ? "" : j;
|
|
2046
|
+
}).filter((_) => !!_).join(",") : "";
|
|
2047
|
+
}, [t.rule]), v = [
|
|
1997
2048
|
{ label: e.t("sheet.cf.ruleType.highlightCell"), value: "1" },
|
|
1998
2049
|
{ label: e.t("sheet.cf.panel.rankAndAverage"), value: "2" },
|
|
1999
2050
|
{ label: e.t("sheet.cf.ruleType.dataBar"), value: "3" },
|
|
2000
2051
|
{ label: e.t("sheet.cf.ruleType.colorScale"), value: "4" },
|
|
2001
2052
|
{ label: e.t("sheet.cf.ruleType.formula"), value: "5" },
|
|
2002
2053
|
{ label: e.t("sheet.cf.ruleType.iconSet"), value: "6" }
|
|
2003
|
-
], [p,
|
|
2004
|
-
var
|
|
2005
|
-
const E = (
|
|
2054
|
+
], [p, y] = N(() => {
|
|
2055
|
+
var O, m;
|
|
2056
|
+
const E = (O = t.rule) == null ? void 0 : O.rule.type, V = v[0].value;
|
|
2006
2057
|
if (!E)
|
|
2007
2058
|
return V;
|
|
2008
2059
|
switch (E) {
|
|
2009
|
-
case
|
|
2060
|
+
case L.highlightCell: {
|
|
2010
2061
|
switch ((m = t.rule) == null ? void 0 : m.rule.subType) {
|
|
2011
2062
|
case F.number:
|
|
2012
2063
|
case F.text:
|
|
@@ -2022,69 +2073,69 @@ const Me = (t) => {
|
|
|
2022
2073
|
}
|
|
2023
2074
|
break;
|
|
2024
2075
|
}
|
|
2025
|
-
case
|
|
2076
|
+
case L.dataBar:
|
|
2026
2077
|
return "3";
|
|
2027
|
-
case
|
|
2078
|
+
case L.colorScale:
|
|
2028
2079
|
return "4";
|
|
2029
|
-
case
|
|
2080
|
+
case L.iconSet:
|
|
2030
2081
|
return "6";
|
|
2031
2082
|
}
|
|
2032
2083
|
return V;
|
|
2033
|
-
}), f =
|
|
2084
|
+
}), f = ge(void 0), w = J(() => new hr({ beforeSubmit: Ui, submit: Pi }), []), I = J(() => {
|
|
2034
2085
|
switch (p) {
|
|
2035
2086
|
case "1":
|
|
2036
|
-
return
|
|
2087
|
+
return on;
|
|
2037
2088
|
case "2":
|
|
2038
|
-
return
|
|
2089
|
+
return Li;
|
|
2039
2090
|
case "3":
|
|
2040
|
-
return
|
|
2091
|
+
return Ti;
|
|
2041
2092
|
case "4":
|
|
2042
|
-
return
|
|
2093
|
+
return Ri;
|
|
2043
2094
|
case "5":
|
|
2044
|
-
return
|
|
2095
|
+
return xi;
|
|
2045
2096
|
case "6":
|
|
2046
|
-
return
|
|
2097
|
+
return Fi;
|
|
2047
2098
|
default:
|
|
2048
|
-
return
|
|
2099
|
+
return on;
|
|
2049
2100
|
}
|
|
2050
2101
|
}, [p]);
|
|
2051
2102
|
K(() => {
|
|
2052
2103
|
const E = r.onCommandExecuted((V) => {
|
|
2053
|
-
if (V.id ===
|
|
2054
|
-
const
|
|
2055
|
-
|
|
2104
|
+
if (V.id === Mr.id) {
|
|
2105
|
+
const O = V.params;
|
|
2106
|
+
O.subUnitId === u && O.unitId === o && t.onCancel();
|
|
2056
2107
|
}
|
|
2057
|
-
V.id ===
|
|
2108
|
+
V.id === Wt.id && t.onCancel();
|
|
2058
2109
|
});
|
|
2059
2110
|
return () => E.dispose();
|
|
2060
2111
|
}, []);
|
|
2061
2112
|
const R = (E) => {
|
|
2062
2113
|
f.current = E;
|
|
2063
|
-
},
|
|
2064
|
-
const V = E.split(",").filter((
|
|
2114
|
+
}, x = (E) => {
|
|
2115
|
+
const V = E.split(",").filter((O) => !!O).map(ei).map((O) => O.range);
|
|
2065
2116
|
l.current = V;
|
|
2066
|
-
},
|
|
2117
|
+
}, T = () => {
|
|
2067
2118
|
if (a)
|
|
2068
2119
|
return;
|
|
2069
2120
|
const V = (() => {
|
|
2070
|
-
const m = n.getCurrentUnitForType(
|
|
2121
|
+
const m = n.getCurrentUnitForType(A.UNIVER_SHEET).getActiveSheet();
|
|
2071
2122
|
if (!m)
|
|
2072
2123
|
throw new Error("No active sheet found");
|
|
2073
|
-
return l.current.map((Y) =>
|
|
2124
|
+
return l.current.map((Y) => Vr(Y, m.getRowCount(), m.getColumnCount())).filter((Y) => !(Number.isNaN(Y.startRow) || Number.isNaN(Y.startColumn)));
|
|
2074
2125
|
})();
|
|
2075
|
-
if (
|
|
2076
|
-
const m =
|
|
2126
|
+
if (w.fetchThroughInterceptors(w.getInterceptPoints().beforeSubmit)(!0, null)) {
|
|
2127
|
+
const m = w.fetchThroughInterceptors(w.getInterceptPoints().submit)(null, null);
|
|
2077
2128
|
if (m) {
|
|
2078
|
-
const
|
|
2079
|
-
if (!
|
|
2129
|
+
const _ = ln(n), j = cn(n);
|
|
2130
|
+
if (!_ || !j)
|
|
2080
2131
|
throw new Error("No active sheet found");
|
|
2081
2132
|
let Y = {};
|
|
2082
|
-
t.rule && t.rule.cfId ? (Y = { ...t.rule, ranges: V, rule: m }, r.executeCommand(
|
|
2133
|
+
t.rule && t.rule.cfId ? (Y = { ...t.rule, ranges: V, rule: m }, r.executeCommand(_r.id, { unitId: _, subUnitId: j, rule: Y }), t.onCancel()) : (Y = { cfId: i.createCfId(_, j), ranges: V, rule: m, stopIfTrue: !1 }, r.executeCommand(Sn.id, { unitId: _, subUnitId: j, rule: Y }), t.onCancel());
|
|
2083
2134
|
}
|
|
2084
2135
|
}
|
|
2085
|
-
},
|
|
2136
|
+
}, g = () => {
|
|
2086
2137
|
t.onCancel();
|
|
2087
|
-
},
|
|
2138
|
+
}, b = (E, V) => {
|
|
2088
2139
|
E ? V.length < 1 ? h(e.t("sheet.cf.errorMessage.rangeError")) : h(void 0) : h(e.t("sheet.cf.errorMessage.rangeError"));
|
|
2089
2140
|
};
|
|
2090
2141
|
return /* @__PURE__ */ k("div", { children: [
|
|
@@ -2097,13 +2148,13 @@ const Me = (t) => {
|
|
|
2097
2148
|
),
|
|
2098
2149
|
/* @__PURE__ */ k("div", { className: "univer-mt-4", children: [
|
|
2099
2150
|
/* @__PURE__ */ c(
|
|
2100
|
-
|
|
2151
|
+
ti,
|
|
2101
2152
|
{
|
|
2102
2153
|
unitId: o,
|
|
2103
|
-
subUnitId:
|
|
2104
|
-
initialValue:
|
|
2105
|
-
onChange: (E, V) =>
|
|
2106
|
-
onVerify:
|
|
2154
|
+
subUnitId: u,
|
|
2155
|
+
initialValue: d,
|
|
2156
|
+
onChange: (E, V) => x(V),
|
|
2157
|
+
onVerify: b
|
|
2107
2158
|
}
|
|
2108
2159
|
),
|
|
2109
2160
|
a && /* @__PURE__ */ c("div", { className: "univer-mt-1 univer-text-xs univer-text-red-500", children: a })
|
|
@@ -2116,39 +2167,39 @@ const Me = (t) => {
|
|
|
2116
2167
|
}
|
|
2117
2168
|
),
|
|
2118
2169
|
/* @__PURE__ */ c(
|
|
2119
|
-
|
|
2170
|
+
ce,
|
|
2120
2171
|
{
|
|
2121
2172
|
className: "univer-mt-4 univer-w-full",
|
|
2122
2173
|
value: p,
|
|
2123
|
-
options:
|
|
2124
|
-
onChange: (E) =>
|
|
2174
|
+
options: v,
|
|
2175
|
+
onChange: (E) => y(E)
|
|
2125
2176
|
}
|
|
2126
2177
|
),
|
|
2127
2178
|
/* @__PURE__ */ c(
|
|
2128
|
-
|
|
2179
|
+
I,
|
|
2129
2180
|
{
|
|
2130
|
-
interceptorManager:
|
|
2181
|
+
interceptorManager: w,
|
|
2131
2182
|
rule: (M = t.rule) == null ? void 0 : M.rule,
|
|
2132
2183
|
onChange: R
|
|
2133
2184
|
}
|
|
2134
2185
|
),
|
|
2135
2186
|
/* @__PURE__ */ k("div", { className: "univer-mt-4 univer-flex univer-justify-end", children: [
|
|
2136
|
-
/* @__PURE__ */ c(
|
|
2137
|
-
/* @__PURE__ */ c(
|
|
2187
|
+
/* @__PURE__ */ c(Xt, { onClick: g, children: e.t("sheet.cf.panel.cancel") }),
|
|
2188
|
+
/* @__PURE__ */ c(Xt, { className: "univer-ml-3", variant: "primary", onClick: T, children: e.t("sheet.cf.panel.submit") })
|
|
2138
2189
|
] })
|
|
2139
2190
|
] });
|
|
2140
2191
|
};
|
|
2141
|
-
var
|
|
2142
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2192
|
+
var Di = Object.getOwnPropertyDescriptor, $i = (t, e, r, n) => {
|
|
2193
|
+
for (var i = n > 1 ? void 0 : n ? Di(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2143
2194
|
(o = t[s]) && (i = o(i) || i);
|
|
2144
2195
|
return i;
|
|
2145
|
-
},
|
|
2146
|
-
let
|
|
2196
|
+
}, Ai = (t, e) => (r, n) => e(r, n, t);
|
|
2197
|
+
let He = class extends ue {
|
|
2147
2198
|
constructor(e) {
|
|
2148
2199
|
super();
|
|
2149
|
-
|
|
2200
|
+
Se(this, "_initLocal", () => {
|
|
2150
2201
|
});
|
|
2151
|
-
|
|
2202
|
+
Se(this, "_findReplaceIndex", (e) => {
|
|
2152
2203
|
const r = /\{([^}]+)?\}/g, n = [];
|
|
2153
2204
|
let i = r.exec(e);
|
|
2154
2205
|
for (; i; )
|
|
@@ -2165,34 +2216,34 @@ let De = class extends ce {
|
|
|
2165
2216
|
const n = this._localeService.getLocales(), i = e.split("."), s = n && this._localeService.resolveKeyPath(n, i);
|
|
2166
2217
|
if (typeof s == "string") {
|
|
2167
2218
|
const o = [];
|
|
2168
|
-
return this._findReplaceIndex(s).forEach((
|
|
2219
|
+
return this._findReplaceIndex(s).forEach((u, a, h) => {
|
|
2169
2220
|
const l = h[a - 1] || { endIndex: -1 };
|
|
2170
|
-
if (l.endIndex + 1 <
|
|
2171
|
-
const
|
|
2172
|
-
|
|
2221
|
+
if (l.endIndex + 1 < u.startIndex) {
|
|
2222
|
+
const d = s.slice(l.endIndex + 1, u.startIndex);
|
|
2223
|
+
d && o.push(d);
|
|
2173
2224
|
}
|
|
2174
|
-
if (r[
|
|
2175
|
-
const
|
|
2176
|
-
|
|
2225
|
+
if (r[u.key] && o.push(r[u.key]), a === h.length - 1) {
|
|
2226
|
+
const d = s.slice(u.endIndex + 1);
|
|
2227
|
+
d && o.push(d);
|
|
2177
2228
|
}
|
|
2178
2229
|
}), o;
|
|
2179
2230
|
}
|
|
2180
2231
|
return [];
|
|
2181
2232
|
}
|
|
2182
2233
|
};
|
|
2183
|
-
|
|
2184
|
-
|
|
2185
|
-
],
|
|
2186
|
-
const
|
|
2234
|
+
He = $i([
|
|
2235
|
+
Ai(0, P(re))
|
|
2236
|
+
], He);
|
|
2237
|
+
const Hi = (t, e) => {
|
|
2187
2238
|
const r = t.rule;
|
|
2188
2239
|
switch (r.type) {
|
|
2189
|
-
case
|
|
2240
|
+
case L.colorScale:
|
|
2190
2241
|
return e.t("sheet.cf.ruleType.colorScale");
|
|
2191
|
-
case
|
|
2242
|
+
case L.dataBar:
|
|
2192
2243
|
return e.t("sheet.cf.ruleType.dataBar");
|
|
2193
|
-
case
|
|
2244
|
+
case L.iconSet:
|
|
2194
2245
|
return e.t("sheet.cf.ruleType.iconSet");
|
|
2195
|
-
case
|
|
2246
|
+
case L.highlightCell:
|
|
2196
2247
|
switch (r.subType) {
|
|
2197
2248
|
case F.average: {
|
|
2198
2249
|
const n = r.operator;
|
|
@@ -2221,118 +2272,118 @@ const Ni = (t, e) => {
|
|
|
2221
2272
|
}
|
|
2222
2273
|
}
|
|
2223
2274
|
};
|
|
2224
|
-
let
|
|
2225
|
-
const
|
|
2226
|
-
const { onClick: e } = t, r =
|
|
2227
|
-
if (!
|
|
2275
|
+
let un = 0;
|
|
2276
|
+
const ji = (t) => {
|
|
2277
|
+
const { onClick: e } = t, r = q(Q), n = q(Z), i = q(je), s = q(te), o = q(re), u = q(fe), a = q(kn), h = q(He), l = Wr(() => n.getCurrentTypeOfUnit$(A.UNIVER_SHEET), void 0, void 0, []), d = l.getUnitId(), v = l.getActiveSheet();
|
|
2278
|
+
if (!v)
|
|
2228
2279
|
throw new Error("No active sheet found");
|
|
2229
|
-
const p =
|
|
2280
|
+
const p = v.getSheetId(), [y, f] = N([]), [w, I] = N("2"), [R, x] = N(0), [T, g] = N(-1), [b, S] = N(un), C = ge(null), M = [
|
|
2230
2281
|
{ label: o.t("sheet.cf.panel.workSheet"), value: "2" },
|
|
2231
2282
|
{ label: o.t("sheet.cf.panel.selectedRange"), value: "1" }
|
|
2232
2283
|
], E = () => {
|
|
2233
|
-
const
|
|
2234
|
-
if (
|
|
2284
|
+
const $ = r.getSubunitRules(d, p);
|
|
2285
|
+
if (!$ || !$.length)
|
|
2235
2286
|
return [];
|
|
2236
|
-
if (
|
|
2287
|
+
if (w === "1") {
|
|
2237
2288
|
const B = i.getCurrentLastSelection();
|
|
2238
2289
|
if (!B)
|
|
2239
2290
|
return [];
|
|
2240
2291
|
const G = B.range;
|
|
2241
|
-
return
|
|
2242
|
-
} else if (
|
|
2243
|
-
return [
|
|
2292
|
+
return $.filter((ee) => ee.ranges.some((ne) => ye.intersects(ne, G)));
|
|
2293
|
+
} else if (w === "2")
|
|
2294
|
+
return [...$];
|
|
2244
2295
|
return [];
|
|
2245
|
-
}, [V,
|
|
2246
|
-
|
|
2247
|
-
const
|
|
2248
|
-
B.id ===
|
|
2296
|
+
}, [V, O] = N(E);
|
|
2297
|
+
ni(y), K(() => {
|
|
2298
|
+
const $ = s.onCommandExecuted((B) => {
|
|
2299
|
+
B.id === Wt.id && x(Math.random());
|
|
2249
2300
|
});
|
|
2250
|
-
return () =>
|
|
2301
|
+
return () => $.dispose();
|
|
2251
2302
|
}), K(() => {
|
|
2252
|
-
|
|
2253
|
-
}, [
|
|
2254
|
-
if (
|
|
2303
|
+
O(E);
|
|
2304
|
+
}, [w, R, d, p]), K(() => {
|
|
2305
|
+
if (w === "2")
|
|
2255
2306
|
return;
|
|
2256
|
-
const
|
|
2257
|
-
const G = [
|
|
2258
|
-
const { id: ne, params:
|
|
2259
|
-
G.includes(ne) &&
|
|
2307
|
+
const $ = new Ne((B) => {
|
|
2308
|
+
const G = [kr.id, se.id, _e.id, we.id, _n.id], z = s.onCommandExecuted((ee) => {
|
|
2309
|
+
const { id: ne, params: Re } = ee, Te = n.getCurrentUnitOfType(A.UNIVER_SHEET).getUnitId();
|
|
2310
|
+
G.includes(ne) && Re.unitId === Te && B.next(null);
|
|
2260
2311
|
});
|
|
2261
|
-
return () =>
|
|
2262
|
-
}).pipe(
|
|
2263
|
-
|
|
2312
|
+
return () => z.dispose();
|
|
2313
|
+
}).pipe(en(16)).subscribe(() => {
|
|
2314
|
+
O(E);
|
|
2264
2315
|
});
|
|
2265
2316
|
return () => {
|
|
2266
|
-
|
|
2317
|
+
$.unsubscribe();
|
|
2267
2318
|
};
|
|
2268
|
-
}, [n,
|
|
2269
|
-
const
|
|
2270
|
-
|
|
2319
|
+
}, [n, w, d, p]), K(() => {
|
|
2320
|
+
const $ = r.$ruleChange.subscribe(() => {
|
|
2321
|
+
x(Math.random());
|
|
2271
2322
|
});
|
|
2272
|
-
return () =>
|
|
2323
|
+
return () => $.unsubscribe();
|
|
2273
2324
|
}, [r]), K(() => {
|
|
2274
|
-
const
|
|
2325
|
+
const $ = () => {
|
|
2275
2326
|
var ee, ne;
|
|
2276
|
-
const
|
|
2277
|
-
return
|
|
2278
|
-
}, G = new
|
|
2327
|
+
const z = Math.max(0, ((ne = (ee = C.current) == null ? void 0 : ee.getBoundingClientRect().width) != null ? ne : 0) - 8);
|
|
2328
|
+
return un = z, z;
|
|
2329
|
+
}, G = new Ne((z) => {
|
|
2279
2330
|
const ee = a.getContainer();
|
|
2280
2331
|
if (ee) {
|
|
2281
2332
|
let ne = setTimeout(() => {
|
|
2282
|
-
|
|
2333
|
+
z.next(void 0);
|
|
2283
2334
|
}, 150);
|
|
2284
|
-
const
|
|
2335
|
+
const Re = () => {
|
|
2285
2336
|
ne && clearTimeout(ne), ne = null;
|
|
2286
|
-
},
|
|
2287
|
-
lt.propertyName === "width" && (
|
|
2337
|
+
}, Te = (lt) => {
|
|
2338
|
+
lt.propertyName === "width" && (Re(), z.next(void 0));
|
|
2288
2339
|
};
|
|
2289
|
-
return ee.addEventListener("transitionend",
|
|
2290
|
-
|
|
2340
|
+
return ee.addEventListener("transitionend", Te), () => {
|
|
2341
|
+
Re(), ee.removeEventListener("transitionend", Te);
|
|
2291
2342
|
};
|
|
2292
2343
|
}
|
|
2293
|
-
}).pipe(
|
|
2294
|
-
|
|
2344
|
+
}).pipe(en(16)).subscribe(() => {
|
|
2345
|
+
S($());
|
|
2295
2346
|
});
|
|
2296
2347
|
return () => {
|
|
2297
2348
|
G.unsubscribe();
|
|
2298
2349
|
};
|
|
2299
2350
|
}, []);
|
|
2300
|
-
const m = (
|
|
2301
|
-
var
|
|
2302
|
-
const B = n.getCurrentUnitOfType(
|
|
2351
|
+
const m = ($) => {
|
|
2352
|
+
var z;
|
|
2353
|
+
const B = n.getCurrentUnitOfType(A.UNIVER_SHEET).getUnitId(), G = (z = n.getCurrentUnitOfType(A.UNIVER_SHEET).getActiveSheet()) == null ? void 0 : z.getSheetId();
|
|
2303
2354
|
if (!B || !G)
|
|
2304
2355
|
throw new Error("No active sheet found");
|
|
2305
|
-
s.executeCommand(
|
|
2306
|
-
},
|
|
2307
|
-
|
|
2308
|
-
},
|
|
2356
|
+
s.executeCommand(Yt.id, { unitId: B, subUnitId: G, cfId: $.cfId });
|
|
2357
|
+
}, _ = ($, B) => {
|
|
2358
|
+
g(B.y);
|
|
2359
|
+
}, j = ($, B, G) => {
|
|
2309
2360
|
var lt;
|
|
2310
|
-
|
|
2311
|
-
const
|
|
2312
|
-
if (!
|
|
2361
|
+
g(-1);
|
|
2362
|
+
const z = n.getCurrentUnitOfType(A.UNIVER_SHEET).getUnitId(), ee = (lt = n.getCurrentUnitOfType(A.UNIVER_SHEET).getActiveSheet()) == null ? void 0 : lt.getSheetId();
|
|
2363
|
+
if (!z || !ee)
|
|
2313
2364
|
throw new Error("No active sheet found");
|
|
2314
|
-
const ne = (
|
|
2315
|
-
const
|
|
2316
|
-
return Math.min(
|
|
2317
|
-
},
|
|
2318
|
-
|
|
2365
|
+
const ne = (or) => {
|
|
2366
|
+
const ar = V.length;
|
|
2367
|
+
return Math.min(ar - 1, Math.max(0, or));
|
|
2368
|
+
}, Re = V[ne(B.y)].cfId, Te = V[ne(G.y)].cfId;
|
|
2369
|
+
Re !== Te && s.executeCommand(wr.id, { unitId: z, subUnitId: ee, start: { id: Re, type: "self" }, end: { id: Te, type: G.y > B.y ? "after" : "before" } });
|
|
2319
2370
|
}, Y = () => {
|
|
2320
2371
|
t.onCreate();
|
|
2321
|
-
},
|
|
2322
|
-
|
|
2323
|
-
s.executeCommand(
|
|
2372
|
+
}, pe = () => {
|
|
2373
|
+
w === "2" ? s.executeCommand(wn.id) : w === "1" && V.map((B) => ({ unitId: d, subUnitId: p, cfId: B.cfId })).forEach((B) => {
|
|
2374
|
+
s.executeCommand(Yt.id, B);
|
|
2324
2375
|
});
|
|
2325
|
-
},
|
|
2326
|
-
const
|
|
2376
|
+
}, Ce = J(() => {
|
|
2377
|
+
const $ = n.getCurrentUnitOfType(A.UNIVER_SHEET), B = $.getActiveSheet();
|
|
2327
2378
|
return V.filter((G) => {
|
|
2328
|
-
const
|
|
2329
|
-
return ft(
|
|
2379
|
+
const z = G.ranges;
|
|
2380
|
+
return ft(u, $.getUnitId(), B.getSheetId(), z);
|
|
2330
2381
|
});
|
|
2331
|
-
}, [V]),
|
|
2332
|
-
const
|
|
2382
|
+
}, [V]), Le = Ce.map(($, B) => ({ i: $.cfId, x: 0, w: 12, y: B, h: 1, isResizable: !1 })), Ue = J(() => {
|
|
2383
|
+
const $ = n.getCurrentUnitOfType(A.UNIVER_SHEET), B = $.getActiveSheet();
|
|
2333
2384
|
return V.every((G) => {
|
|
2334
|
-
const
|
|
2335
|
-
return ft(
|
|
2385
|
+
const z = G.ranges;
|
|
2386
|
+
return ft(u, $.getUnitId(), B.getSheetId(), z);
|
|
2336
2387
|
});
|
|
2337
2388
|
}, [V]);
|
|
2338
2389
|
return /* @__PURE__ */ k("div", { children: [
|
|
@@ -2340,60 +2391,60 @@ const Mi = (t) => {
|
|
|
2340
2391
|
/* @__PURE__ */ c("div", { className: "univer-flex univer-items-center univer-gap-2", children: h.tWithReactNode(
|
|
2341
2392
|
"sheet.cf.panel.managerRuleSelect",
|
|
2342
2393
|
/* @__PURE__ */ c(
|
|
2343
|
-
|
|
2394
|
+
ce,
|
|
2344
2395
|
{
|
|
2345
2396
|
className: "univer-w-36",
|
|
2346
2397
|
options: M,
|
|
2347
|
-
value:
|
|
2348
|
-
onChange: (
|
|
2349
|
-
|
|
2398
|
+
value: w,
|
|
2399
|
+
onChange: ($) => {
|
|
2400
|
+
I($);
|
|
2350
2401
|
}
|
|
2351
2402
|
}
|
|
2352
2403
|
)
|
|
2353
|
-
).map((
|
|
2404
|
+
).map(($, B) => /* @__PURE__ */ c("span", { children: $ }, B)) }),
|
|
2354
2405
|
/* @__PURE__ */ k("div", { className: "univer-flex univer-justify-end", children: [
|
|
2355
|
-
/* @__PURE__ */ c(
|
|
2406
|
+
/* @__PURE__ */ c(Jt, { title: o.t("sheet.cf.panel.createRule"), placement: "bottom", children: /* @__PURE__ */ c(
|
|
2356
2407
|
"a",
|
|
2357
2408
|
{
|
|
2358
2409
|
className: "univer-size-5 univer-cursor-pointer",
|
|
2359
2410
|
onClick: Y,
|
|
2360
|
-
children: /* @__PURE__ */ c(
|
|
2411
|
+
children: /* @__PURE__ */ c(Kn, {})
|
|
2361
2412
|
}
|
|
2362
2413
|
) }),
|
|
2363
|
-
V.length &&
|
|
2414
|
+
V.length && Ue ? /* @__PURE__ */ c(Jt, { title: o.t("sheet.cf.panel.clear"), placement: "bottom", children: /* @__PURE__ */ c(
|
|
2364
2415
|
"a",
|
|
2365
2416
|
{
|
|
2366
2417
|
className: "univer-size-5 univer-cursor-pointer",
|
|
2367
|
-
onClick:
|
|
2418
|
+
onClick: pe,
|
|
2368
2419
|
children: /* @__PURE__ */ c(gt, { className: "univer-text-red-500" })
|
|
2369
2420
|
}
|
|
2370
2421
|
) }) : /* @__PURE__ */ c("div", { children: /* @__PURE__ */ c(gt, { className: "univer-text-gray-300" }) })
|
|
2371
2422
|
] })
|
|
2372
2423
|
] }),
|
|
2373
|
-
/* @__PURE__ */ c("div", { ref:
|
|
2374
|
-
|
|
2424
|
+
/* @__PURE__ */ c("div", { ref: C, children: b > 0 && /* @__PURE__ */ c(
|
|
2425
|
+
Qr,
|
|
2375
2426
|
{
|
|
2376
2427
|
className: "[&_.react-grid-item]:univer-transition-none [&_.react-grid-placeholder]:univer-rounded [&_.react-grid-placeholder]:!univer-bg-gray-200",
|
|
2377
2428
|
draggableHandle: ".draggableHandle",
|
|
2378
|
-
layout:
|
|
2429
|
+
layout: Le,
|
|
2379
2430
|
cols: 12,
|
|
2380
2431
|
rowHeight: 60,
|
|
2381
|
-
width:
|
|
2432
|
+
width: b,
|
|
2382
2433
|
margin: [0, 10],
|
|
2383
|
-
onDragStop:
|
|
2384
|
-
onDragStart:
|
|
2385
|
-
children:
|
|
2434
|
+
onDragStop: j,
|
|
2435
|
+
onDragStart: _,
|
|
2436
|
+
children: Ce == null ? void 0 : Ce.map(($, B) => /* @__PURE__ */ c("div", { children: /* @__PURE__ */ k(
|
|
2386
2437
|
"div",
|
|
2387
2438
|
{
|
|
2388
2439
|
className: X("univer-group univer-relative univer-flex univer-items-center univer-justify-between univer-rounded univer-py-2 univer-pl-5 univer-pr-8 dark:hover:!univer-bg-gray-700 hover:univer-bg-gray-100", {
|
|
2389
|
-
"univer-bg-gray-100 dark:!univer-bg-gray-700":
|
|
2440
|
+
"univer-bg-gray-100 dark:!univer-bg-gray-700": T === B
|
|
2390
2441
|
}),
|
|
2391
2442
|
onMouseMove: () => {
|
|
2392
|
-
|
|
2443
|
+
$.ranges !== y && f($.ranges);
|
|
2393
2444
|
},
|
|
2394
2445
|
onMouseLeave: () => f([]),
|
|
2395
2446
|
onClick: () => {
|
|
2396
|
-
e(
|
|
2447
|
+
e($);
|
|
2397
2448
|
},
|
|
2398
2449
|
children: [
|
|
2399
2450
|
/* @__PURE__ */ c(
|
|
@@ -2401,7 +2452,7 @@ const Mi = (t) => {
|
|
|
2401
2452
|
{
|
|
2402
2453
|
className: X("univer-absolute univer-left-0 univer-hidden univer-size-5 univer-cursor-grab univer-items-center univer-justify-center univer-rounded group-hover:univer-flex", "draggableHandle"),
|
|
2403
2454
|
onClick: (G) => G.stopPropagation(),
|
|
2404
|
-
children: /* @__PURE__ */ c(
|
|
2455
|
+
children: /* @__PURE__ */ c(Qn, {})
|
|
2405
2456
|
}
|
|
2406
2457
|
),
|
|
2407
2458
|
/* @__PURE__ */ k(
|
|
@@ -2413,56 +2464,56 @@ const Mi = (t) => {
|
|
|
2413
2464
|
"div",
|
|
2414
2465
|
{
|
|
2415
2466
|
className: "univer-text-sm univer-text-gray-900 dark:!univer-text-white",
|
|
2416
|
-
children:
|
|
2467
|
+
children: Hi($, o)
|
|
2417
2468
|
}
|
|
2418
2469
|
),
|
|
2419
|
-
/* @__PURE__ */ c("div", { className: "univer-text-xs univer-text-gray-400", children:
|
|
2470
|
+
/* @__PURE__ */ c("div", { className: "univer-text-xs univer-text-gray-400", children: $.ranges.map((G) => Fn(G)).join(",") })
|
|
2420
2471
|
]
|
|
2421
2472
|
}
|
|
2422
2473
|
),
|
|
2423
|
-
/* @__PURE__ */ c("div", { children: /* @__PURE__ */ c(We, { rule:
|
|
2474
|
+
/* @__PURE__ */ c("div", { children: /* @__PURE__ */ c(We, { rule: $.rule }) }),
|
|
2424
2475
|
/* @__PURE__ */ c(
|
|
2425
2476
|
"div",
|
|
2426
2477
|
{
|
|
2427
2478
|
className: X("univer-absolute univer-right-1 univer-hidden univer-size-6 univer-cursor-pointer univer-items-center univer-justify-center univer-rounded group-hover:univer-flex hover:univer-bg-gray-200", {
|
|
2428
|
-
"univer-flex univer-items-center univer-justify-center":
|
|
2479
|
+
"univer-flex univer-items-center univer-justify-center": T === B
|
|
2429
2480
|
}),
|
|
2430
2481
|
onClick: (G) => {
|
|
2431
|
-
G.stopPropagation(), m(
|
|
2482
|
+
G.stopPropagation(), m($), f([]);
|
|
2432
2483
|
},
|
|
2433
2484
|
children: /* @__PURE__ */ c(gt, {})
|
|
2434
2485
|
}
|
|
2435
2486
|
)
|
|
2436
2487
|
]
|
|
2437
2488
|
}
|
|
2438
|
-
) }, `${
|
|
2489
|
+
) }, `${$.cfId}`))
|
|
2439
2490
|
}
|
|
2440
2491
|
) })
|
|
2441
2492
|
] });
|
|
2442
|
-
},
|
|
2493
|
+
}, Bi = (t) => {
|
|
2443
2494
|
const [e, r] = N(t.rule), [n, i] = N(!!t.rule);
|
|
2444
|
-
return /* @__PURE__ */ c("div", { className: "univer-flex univer-h-full univer-flex-col univer-justify-between", children: n ? /* @__PURE__ */ c(
|
|
2495
|
+
return /* @__PURE__ */ c("div", { className: "univer-flex univer-h-full univer-flex-col univer-justify-between", children: n ? /* @__PURE__ */ c(Oi, { onCancel: () => {
|
|
2445
2496
|
i(!1), r(void 0);
|
|
2446
|
-
}, rule: e }) : /* @__PURE__ */ c(
|
|
2497
|
+
}, rule: e }) : /* @__PURE__ */ c(ji, { onClick: (a) => {
|
|
2447
2498
|
r(a), i(!0);
|
|
2448
2499
|
}, onCreate: () => {
|
|
2449
2500
|
i(!0);
|
|
2450
2501
|
} }) });
|
|
2451
2502
|
};
|
|
2452
|
-
var
|
|
2453
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2503
|
+
var Wi = Object.getOwnPropertyDescriptor, qi = (t, e, r, n) => {
|
|
2504
|
+
for (var i = n > 1 ? void 0 : n ? Wi(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2454
2505
|
(o = t[s]) && (i = o(i) || i);
|
|
2455
2506
|
return i;
|
|
2456
2507
|
}, qe = (t, e) => (r, n) => e(r, n, t);
|
|
2457
2508
|
const ht = "sheet.conditional.formatting.panel";
|
|
2458
|
-
let Qe = class extends
|
|
2509
|
+
let Qe = class extends ue {
|
|
2459
2510
|
constructor(e, r, n, i, s) {
|
|
2460
2511
|
super();
|
|
2461
|
-
|
|
2512
|
+
Se(this, "_sidebarDisposable", null);
|
|
2462
2513
|
this._univerInstanceService = e, this._injector = r, this._componentManager = n, this._sidebarService = i, this._localeService = s, this._initPanel(), this.disposeWithMe(
|
|
2463
|
-
this._univerInstanceService.getCurrentTypeOfUnit$(
|
|
2464
|
-
var
|
|
2465
|
-
o || (
|
|
2514
|
+
this._univerInstanceService.getCurrentTypeOfUnit$(A.UNIVER_SHEET).subscribe((o) => {
|
|
2515
|
+
var u;
|
|
2516
|
+
o || (u = this._sidebarDisposable) == null || u.dispose();
|
|
2466
2517
|
})
|
|
2467
2518
|
), this.disposeWithMe(this._sidebarService.sidebarOptions$.subscribe((o) => {
|
|
2468
2519
|
o.id === ht && (o.visible || setTimeout(() => {
|
|
@@ -2477,7 +2528,7 @@ let Qe = class extends ce {
|
|
|
2477
2528
|
children: {
|
|
2478
2529
|
label: ht,
|
|
2479
2530
|
rule: e,
|
|
2480
|
-
key:
|
|
2531
|
+
key: vr(4)
|
|
2481
2532
|
},
|
|
2482
2533
|
onClose: () => this._sidebarDisposable = null
|
|
2483
2534
|
};
|
|
@@ -2485,35 +2536,35 @@ let Qe = class extends ce {
|
|
|
2485
2536
|
}
|
|
2486
2537
|
_initPanel() {
|
|
2487
2538
|
this.disposeWithMe(
|
|
2488
|
-
this._componentManager.register(ht,
|
|
2539
|
+
this._componentManager.register(ht, Bi)
|
|
2489
2540
|
);
|
|
2490
2541
|
}
|
|
2491
2542
|
};
|
|
2492
|
-
Qe =
|
|
2493
|
-
qe(0,
|
|
2494
|
-
qe(1,
|
|
2495
|
-
qe(2,
|
|
2496
|
-
qe(3,
|
|
2497
|
-
qe(4,
|
|
2543
|
+
Qe = qi([
|
|
2544
|
+
qe(0, Z),
|
|
2545
|
+
qe(1, P(fe)),
|
|
2546
|
+
qe(2, P(qr)),
|
|
2547
|
+
qe(3, P(kn)),
|
|
2548
|
+
qe(4, P(re))
|
|
2498
2549
|
], Qe);
|
|
2499
2550
|
var ie = /* @__PURE__ */ ((t) => (t[t.createRule = 1] = "createRule", t[t.viewRule = 2] = "viewRule", t[t.highlightCell = 3] = "highlightCell", t[t.rank = 4] = "rank", t[t.formula = 5] = "formula", t[t.colorScale = 6] = "colorScale", t[t.dataBar = 7] = "dataBar", t[t.icon = 8] = "icon", t[t.clearRangeRules = 9] = "clearRangeRules", t[t.clearWorkSheetRules = 10] = "clearWorkSheetRules", t))(ie || {});
|
|
2500
|
-
const
|
|
2551
|
+
const Vt = {
|
|
2501
2552
|
id: "sheet.operation.open.conditional.formatting.panel",
|
|
2502
|
-
type:
|
|
2553
|
+
type: me.OPERATION,
|
|
2503
2554
|
handler: (t, e) => {
|
|
2504
|
-
var
|
|
2505
|
-
const r = t.get(Qe), n = t.get(
|
|
2555
|
+
var u;
|
|
2556
|
+
const r = t.get(Qe), n = t.get(je), i = t.get(te), s = ((u = n.getCurrentSelections()) == null ? void 0 : u.map((a) => a.range)) || [];
|
|
2506
2557
|
switch (e.value) {
|
|
2507
2558
|
case 3: {
|
|
2508
|
-
r.openPanel({ ...
|
|
2559
|
+
r.openPanel({ ...xe(), ranges: s });
|
|
2509
2560
|
break;
|
|
2510
2561
|
}
|
|
2511
2562
|
case 4: {
|
|
2512
2563
|
const a = {
|
|
2513
|
-
...
|
|
2564
|
+
...xe,
|
|
2514
2565
|
ranges: s,
|
|
2515
2566
|
rule: {
|
|
2516
|
-
type:
|
|
2567
|
+
type: L.highlightCell,
|
|
2517
2568
|
subType: F.rank
|
|
2518
2569
|
}
|
|
2519
2570
|
};
|
|
@@ -2522,10 +2573,10 @@ const kt = {
|
|
|
2522
2573
|
}
|
|
2523
2574
|
case 5: {
|
|
2524
2575
|
const a = {
|
|
2525
|
-
...
|
|
2576
|
+
...xe,
|
|
2526
2577
|
ranges: s,
|
|
2527
2578
|
rule: {
|
|
2528
|
-
type:
|
|
2579
|
+
type: L.highlightCell,
|
|
2529
2580
|
subType: F.formula,
|
|
2530
2581
|
value: "="
|
|
2531
2582
|
}
|
|
@@ -2535,10 +2586,10 @@ const kt = {
|
|
|
2535
2586
|
}
|
|
2536
2587
|
case 6: {
|
|
2537
2588
|
const a = {
|
|
2538
|
-
...
|
|
2589
|
+
...xe,
|
|
2539
2590
|
ranges: s,
|
|
2540
2591
|
rule: {
|
|
2541
|
-
type:
|
|
2592
|
+
type: L.colorScale,
|
|
2542
2593
|
config: []
|
|
2543
2594
|
}
|
|
2544
2595
|
};
|
|
@@ -2547,10 +2598,10 @@ const kt = {
|
|
|
2547
2598
|
}
|
|
2548
2599
|
case 7: {
|
|
2549
2600
|
const a = {
|
|
2550
|
-
...
|
|
2601
|
+
...xe,
|
|
2551
2602
|
ranges: s,
|
|
2552
2603
|
rule: {
|
|
2553
|
-
type:
|
|
2604
|
+
type: L.dataBar,
|
|
2554
2605
|
isShowValue: !0
|
|
2555
2606
|
}
|
|
2556
2607
|
};
|
|
@@ -2559,10 +2610,10 @@ const kt = {
|
|
|
2559
2610
|
}
|
|
2560
2611
|
case 8: {
|
|
2561
2612
|
const a = {
|
|
2562
|
-
...
|
|
2613
|
+
...xe,
|
|
2563
2614
|
ranges: s,
|
|
2564
2615
|
rule: {
|
|
2565
|
-
type:
|
|
2616
|
+
type: L.iconSet,
|
|
2566
2617
|
config: [],
|
|
2567
2618
|
isShowValue: !0
|
|
2568
2619
|
}
|
|
@@ -2575,30 +2626,30 @@ const kt = {
|
|
|
2575
2626
|
break;
|
|
2576
2627
|
}
|
|
2577
2628
|
case 1: {
|
|
2578
|
-
r.openPanel({ ...
|
|
2629
|
+
r.openPanel({ ...xe(), ranges: s });
|
|
2579
2630
|
break;
|
|
2580
2631
|
}
|
|
2581
2632
|
case 9: {
|
|
2582
|
-
i.executeCommand(
|
|
2633
|
+
i.executeCommand(Rr.id, { ranges: s });
|
|
2583
2634
|
break;
|
|
2584
2635
|
}
|
|
2585
2636
|
case 10: {
|
|
2586
|
-
i.executeCommand(
|
|
2637
|
+
i.executeCommand(wn.id);
|
|
2587
2638
|
break;
|
|
2588
2639
|
}
|
|
2589
2640
|
}
|
|
2590
2641
|
return !0;
|
|
2591
2642
|
}
|
|
2592
2643
|
};
|
|
2593
|
-
var
|
|
2594
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2644
|
+
var Gi = Object.getOwnPropertyDescriptor, Zi = (t, e, r, n) => {
|
|
2645
|
+
for (var i = n > 1 ? void 0 : n ? Gi(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2595
2646
|
(o = t[s]) && (i = o(i) || i);
|
|
2596
2647
|
return i;
|
|
2597
2648
|
}, Ge = (t, e) => (r, n) => e(r, n, t);
|
|
2598
|
-
let et = class extends
|
|
2649
|
+
let et = class extends ue {
|
|
2599
2650
|
constructor(e, r, n, i, s) {
|
|
2600
2651
|
super();
|
|
2601
|
-
|
|
2652
|
+
Se(this, "_copyInfo");
|
|
2602
2653
|
this._sheetClipboardService = e, this._conditionalFormattingRuleModel = r, this._injector = n, this._conditionalFormattingViewModel = i, this._univerInstanceService = s, this._initClipboardHook();
|
|
2603
2654
|
}
|
|
2604
2655
|
_initClipboardHook() {
|
|
@@ -2607,14 +2658,14 @@ let et = class extends ce {
|
|
|
2607
2658
|
id: st,
|
|
2608
2659
|
onBeforeCopy: (e, r, n) => this._collectConditionalRule(e, r, n),
|
|
2609
2660
|
onPasteCells: (e, r, n, i) => {
|
|
2610
|
-
const { copyType: s =
|
|
2611
|
-
return this._generateConditionalFormattingMutations(a, { copyType: s, pasteType: o, copyRange:
|
|
2661
|
+
const { copyType: s = Qt.COPY, pasteType: o } = i, { range: u } = e || {}, { range: a } = r;
|
|
2662
|
+
return this._generateConditionalFormattingMutations(a, { copyType: s, pasteType: o, copyRange: u });
|
|
2612
2663
|
}
|
|
2613
2664
|
})
|
|
2614
2665
|
);
|
|
2615
2666
|
}
|
|
2616
2667
|
_collectConditionalRule(e, r, n) {
|
|
2617
|
-
const i = new
|
|
2668
|
+
const i = new Me(), s = {};
|
|
2618
2669
|
this._copyInfo = {
|
|
2619
2670
|
matrix: i,
|
|
2620
2671
|
info: {
|
|
@@ -2623,196 +2674,196 @@ let et = class extends ce {
|
|
|
2623
2674
|
cfMap: s
|
|
2624
2675
|
}
|
|
2625
2676
|
};
|
|
2626
|
-
const o = this._injector.invoke((l) =>
|
|
2677
|
+
const o = this._injector.invoke((l) => Fr(n, l, e, r));
|
|
2627
2678
|
if (!o)
|
|
2628
2679
|
return;
|
|
2629
|
-
const { rows:
|
|
2630
|
-
|
|
2631
|
-
a.forEach((
|
|
2632
|
-
const
|
|
2633
|
-
|
|
2680
|
+
const { rows: u, cols: a } = o, h = /* @__PURE__ */ new Set();
|
|
2681
|
+
u.forEach((l, d) => {
|
|
2682
|
+
a.forEach((v, p) => {
|
|
2683
|
+
const y = this._conditionalFormattingViewModel.getCellCfs(e, r, l, v);
|
|
2684
|
+
y && (y.forEach((f) => h.add(f.cfId)), i.setValue(d, p, y.map((f) => f.cfId)));
|
|
2634
2685
|
});
|
|
2635
2686
|
}), h.forEach((l) => {
|
|
2636
|
-
const
|
|
2637
|
-
|
|
2687
|
+
const d = this._conditionalFormattingRuleModel.getRule(e, r, l);
|
|
2688
|
+
d && (s[l] = d.rule);
|
|
2638
2689
|
});
|
|
2639
2690
|
}
|
|
2640
2691
|
// eslint-disable-next-line max-lines-per-function
|
|
2641
2692
|
_generateConditionalFormattingMutations(e, r) {
|
|
2642
|
-
const n = this._univerInstanceService.getCurrentUnitForType(
|
|
2693
|
+
const n = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET), i = n.getActiveSheet(), s = n.getUnitId();
|
|
2643
2694
|
if (!i) return { redos: [], undos: [] };
|
|
2644
2695
|
const o = i.getSheetId();
|
|
2645
|
-
if (r.copyType ===
|
|
2696
|
+
if (r.copyType === Qt.CUT)
|
|
2646
2697
|
return this._copyInfo = null, { redos: [], undos: [] };
|
|
2647
2698
|
if (!this._copyInfo || !r.copyRange)
|
|
2648
2699
|
return { redos: [], undos: [] };
|
|
2649
2700
|
if (![
|
|
2650
|
-
|
|
2651
|
-
|
|
2652
|
-
|
|
2701
|
+
Ft.SPECIAL_PASTE_FORMAT,
|
|
2702
|
+
Ft.DEFAULT_PASTE,
|
|
2703
|
+
Ft.SPECIAL_PASTE_BESIDES_BORDER
|
|
2653
2704
|
].includes(
|
|
2654
2705
|
r.pasteType
|
|
2655
2706
|
))
|
|
2656
2707
|
return { redos: [], undos: [] };
|
|
2657
|
-
const { ranges: [a, h], mapFunc: l } =
|
|
2658
|
-
|
|
2659
|
-
const { row:
|
|
2708
|
+
const { ranges: [a, h], mapFunc: l } = Ln([r.copyRange, e]), d = ii(a, h, !0), v = {};
|
|
2709
|
+
be.foreach(h, (g, b) => {
|
|
2710
|
+
const { row: S, col: C } = l(g, b), M = this._conditionalFormattingViewModel.getCellCfs(s, o, S, C);
|
|
2660
2711
|
M && M.forEach((E) => {
|
|
2661
|
-
if (!
|
|
2662
|
-
const V = new
|
|
2663
|
-
|
|
2664
|
-
const
|
|
2665
|
-
|
|
2666
|
-
|
|
2667
|
-
V.setValue(
|
|
2712
|
+
if (!v[E.cfId]) {
|
|
2713
|
+
const V = new Me();
|
|
2714
|
+
v[E.cfId] = V;
|
|
2715
|
+
const O = this._conditionalFormattingRuleModel.getRule(s, o, E.cfId);
|
|
2716
|
+
O == null || O.ranges.forEach((m) => {
|
|
2717
|
+
be.foreach(m, (_, j) => {
|
|
2718
|
+
V.setValue(_, j, 1);
|
|
2668
2719
|
});
|
|
2669
2720
|
});
|
|
2670
2721
|
}
|
|
2671
|
-
|
|
2722
|
+
v[E.cfId].realDeleteValue(S, C);
|
|
2672
2723
|
});
|
|
2673
2724
|
});
|
|
2674
|
-
const { matrix: p, info:
|
|
2675
|
-
let
|
|
2676
|
-
const
|
|
2677
|
-
if (
|
|
2678
|
-
return
|
|
2679
|
-
const
|
|
2680
|
-
if (
|
|
2681
|
-
return
|
|
2725
|
+
const { matrix: p, info: y } = this._copyInfo, f = [];
|
|
2726
|
+
let w = this._conditionalFormattingRuleModel.createCfId(s, o);
|
|
2727
|
+
const I = {}, R = (g) => {
|
|
2728
|
+
if (I[g])
|
|
2729
|
+
return I[g];
|
|
2730
|
+
const b = y == null ? void 0 : y.cfMap[g], S = [...this._conditionalFormattingRuleModel.getSubunitRules(s, o) || [], ...f].find((C) => Bt.diffValue(C.rule, b));
|
|
2731
|
+
if (S)
|
|
2732
|
+
return I[g] = S, S;
|
|
2682
2733
|
{
|
|
2683
|
-
const
|
|
2684
|
-
rule:
|
|
2685
|
-
cfId:
|
|
2734
|
+
const C = {
|
|
2735
|
+
rule: b,
|
|
2736
|
+
cfId: w,
|
|
2686
2737
|
ranges: [],
|
|
2687
2738
|
stopIfTrue: !1
|
|
2688
2739
|
};
|
|
2689
|
-
return
|
|
2740
|
+
return I[g] = C, f.push(C), w = `${Number(w) + 1}`, C;
|
|
2690
2741
|
}
|
|
2691
2742
|
};
|
|
2692
|
-
|
|
2693
|
-
p && p.forValue((
|
|
2694
|
-
const M =
|
|
2743
|
+
d.forEach((g) => {
|
|
2744
|
+
p && p.forValue((b, S, C) => {
|
|
2745
|
+
const M = ye.getPositionRange(
|
|
2695
2746
|
{
|
|
2696
|
-
startRow:
|
|
2697
|
-
endRow:
|
|
2698
|
-
startColumn:
|
|
2699
|
-
endColumn:
|
|
2747
|
+
startRow: b,
|
|
2748
|
+
endRow: b,
|
|
2749
|
+
startColumn: S,
|
|
2750
|
+
endColumn: S
|
|
2700
2751
|
},
|
|
2701
|
-
|
|
2752
|
+
g.startRange
|
|
2702
2753
|
), { row: E, col: V } = l(M.startRow, M.startColumn);
|
|
2703
|
-
|
|
2704
|
-
if (!
|
|
2705
|
-
const m = R(
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2754
|
+
C.forEach((O) => {
|
|
2755
|
+
if (!v[O]) {
|
|
2756
|
+
const m = R(O), _ = new Me();
|
|
2757
|
+
v[O] = _, m.ranges.forEach((j) => {
|
|
2758
|
+
be.foreach(j, (Y, pe) => {
|
|
2759
|
+
_.setValue(Y, pe, 1);
|
|
2709
2760
|
});
|
|
2710
2761
|
});
|
|
2711
2762
|
}
|
|
2712
|
-
|
|
2763
|
+
v[O].setValue(E, V, 1);
|
|
2713
2764
|
});
|
|
2714
2765
|
});
|
|
2715
2766
|
});
|
|
2716
|
-
const
|
|
2717
|
-
for (const
|
|
2718
|
-
const
|
|
2719
|
-
if (!
|
|
2720
|
-
const
|
|
2767
|
+
const x = [], T = [];
|
|
2768
|
+
for (const g in v) {
|
|
2769
|
+
const b = v[g], S = pt(Ct(b));
|
|
2770
|
+
if (!S.length) {
|
|
2771
|
+
const C = {
|
|
2721
2772
|
unitId: s,
|
|
2722
2773
|
subUnitId: o,
|
|
2723
|
-
cfId:
|
|
2774
|
+
cfId: g
|
|
2724
2775
|
};
|
|
2725
|
-
|
|
2776
|
+
x.push({ id: we.id, params: C }), T.push(...$e(this._injector, C));
|
|
2726
2777
|
}
|
|
2727
|
-
if (f.some((
|
|
2728
|
-
const
|
|
2778
|
+
if (f.some((C) => C.cfId === g)) {
|
|
2779
|
+
const C = R(g), M = {
|
|
2729
2780
|
unitId: s,
|
|
2730
2781
|
subUnitId: o,
|
|
2731
|
-
rule: { ...
|
|
2782
|
+
rule: { ...C, ranges: S }
|
|
2732
2783
|
};
|
|
2733
|
-
|
|
2784
|
+
x.push({ id: se.id, params: M }), T.push(Rn(this._injector, M));
|
|
2734
2785
|
} else {
|
|
2735
|
-
const
|
|
2736
|
-
if (!
|
|
2786
|
+
const C = this._conditionalFormattingRuleModel.getRule(s, o, g);
|
|
2787
|
+
if (!C)
|
|
2737
2788
|
continue;
|
|
2738
2789
|
const M = {
|
|
2739
2790
|
unitId: s,
|
|
2740
2791
|
subUnitId: o,
|
|
2741
|
-
rule: { ...
|
|
2792
|
+
rule: { ...C, ranges: S }
|
|
2742
2793
|
};
|
|
2743
|
-
|
|
2794
|
+
x.push({ id: _e.id, params: M }), T.push(...Ae(this._injector, M));
|
|
2744
2795
|
}
|
|
2745
2796
|
}
|
|
2746
2797
|
return {
|
|
2747
|
-
redos:
|
|
2748
|
-
undos:
|
|
2798
|
+
redos: x,
|
|
2799
|
+
undos: T
|
|
2749
2800
|
};
|
|
2750
2801
|
}
|
|
2751
2802
|
};
|
|
2752
|
-
et =
|
|
2753
|
-
Ge(0,
|
|
2754
|
-
Ge(1,
|
|
2755
|
-
Ge(2,
|
|
2756
|
-
Ge(3,
|
|
2757
|
-
Ge(4,
|
|
2803
|
+
et = Zi([
|
|
2804
|
+
Ge(0, P(ri)),
|
|
2805
|
+
Ge(1, P(Q)),
|
|
2806
|
+
Ge(2, P(fe)),
|
|
2807
|
+
Ge(3, P(it)),
|
|
2808
|
+
Ge(4, P(Z))
|
|
2758
2809
|
], et);
|
|
2759
|
-
var
|
|
2760
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2810
|
+
var zi = Object.getOwnPropertyDescriptor, Yi = (t, e, r, n) => {
|
|
2811
|
+
for (var i = n > 1 ? void 0 : n ? zi(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2761
2812
|
(o = t[s]) && (i = o(i) || i);
|
|
2762
2813
|
return i;
|
|
2763
|
-
},
|
|
2764
|
-
let tt = class extends
|
|
2814
|
+
}, Ot = (t, e) => (r, n) => e(r, n, t);
|
|
2815
|
+
let tt = class extends ue {
|
|
2765
2816
|
constructor(t, e, r) {
|
|
2766
2817
|
super(), this._localeService = t, this._commandService = e, this._sheetPermissionCheckController = r, this._commandExecutedListener();
|
|
2767
2818
|
}
|
|
2768
2819
|
_commandExecutedListener() {
|
|
2769
2820
|
this.disposeWithMe(
|
|
2770
2821
|
this._commandService.beforeCommandExecuted((t) => {
|
|
2771
|
-
t.id ===
|
|
2772
|
-
workbookTypes: [
|
|
2773
|
-
rangeTypes: [
|
|
2774
|
-
worksheetTypes: [
|
|
2822
|
+
t.id === Sn.id && (this._sheetPermissionCheckController.permissionCheckWithRanges({
|
|
2823
|
+
workbookTypes: [Vn],
|
|
2824
|
+
rangeTypes: [Mn],
|
|
2825
|
+
worksheetTypes: [En, Nn]
|
|
2775
2826
|
}, t.params.rule.ranges) || this._sheetPermissionCheckController.blockExecuteWithoutPermission(this._localeService.t("permission.dialog.setStyleErr")));
|
|
2776
2827
|
})
|
|
2777
2828
|
);
|
|
2778
2829
|
}
|
|
2779
2830
|
};
|
|
2780
|
-
tt =
|
|
2781
|
-
|
|
2782
|
-
|
|
2783
|
-
|
|
2831
|
+
tt = Yi([
|
|
2832
|
+
Ot(0, P(re)),
|
|
2833
|
+
Ot(1, te),
|
|
2834
|
+
Ot(2, P(Lr))
|
|
2784
2835
|
], tt);
|
|
2785
|
-
var
|
|
2786
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2836
|
+
var Ki = Object.getOwnPropertyDescriptor, Xi = (t, e, r, n) => {
|
|
2837
|
+
for (var i = n > 1 ? void 0 : n ? Ki(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2787
2838
|
(o = t[s]) && (i = o(i) || i);
|
|
2788
2839
|
return i;
|
|
2789
2840
|
}, vt = (t, e) => (r, n) => e(r, n, t);
|
|
2790
|
-
let nt = class extends
|
|
2841
|
+
let nt = class extends ue {
|
|
2791
2842
|
constructor(t, e, r, n) {
|
|
2792
2843
|
super(), this._conditionalFormattingRuleModel = t, this._univerInstanceService = e, this._injector = r, this._refRangeService = n, this._initRefRange();
|
|
2793
2844
|
}
|
|
2794
2845
|
_initRefRange() {
|
|
2795
2846
|
const t = /* @__PURE__ */ new Map(), e = (n, i, s) => `${n}_${i}_${s}`, r = (n, i, s) => {
|
|
2796
2847
|
const o = (a) => {
|
|
2797
|
-
const h = [...s.ranges], l = h.map((
|
|
2798
|
-
if (
|
|
2848
|
+
const h = [...s.ranges], l = h.map((v) => Pr(v, a)).filter((v) => !!v);
|
|
2849
|
+
if (Tr(l, h))
|
|
2799
2850
|
return { redos: [], undos: [] };
|
|
2800
2851
|
if (l.length) {
|
|
2801
|
-
const
|
|
2802
|
-
return { redos: p, undos:
|
|
2852
|
+
const v = { unitId: n, subUnitId: i, rule: { ...s, ranges: l } }, p = [{ id: _e.id, params: v }], y = Ae(this._injector, v);
|
|
2853
|
+
return { redos: p, undos: y };
|
|
2803
2854
|
} else {
|
|
2804
|
-
const
|
|
2805
|
-
return { redos: p, undos:
|
|
2855
|
+
const v = { unitId: n, subUnitId: i, cfId: s.cfId }, p = [{ id: we.id, params: v }], y = $e(this._injector, v);
|
|
2856
|
+
return { redos: p, undos: y };
|
|
2806
2857
|
}
|
|
2807
|
-
},
|
|
2858
|
+
}, u = [];
|
|
2808
2859
|
s.ranges.forEach((a) => {
|
|
2809
2860
|
const h = this._refRangeService.registerRefRange(a, o);
|
|
2810
|
-
|
|
2811
|
-
}), t.set(e(n, i, s.cfId), () =>
|
|
2861
|
+
u.push(() => h.dispose());
|
|
2862
|
+
}), t.set(e(n, i, s.cfId), () => u.forEach((a) => a()));
|
|
2812
2863
|
};
|
|
2813
2864
|
this.disposeWithMe(this._conditionalFormattingRuleModel.$ruleChange.subscribe((n) => {
|
|
2814
|
-
const { unitId: i, subUnitId: s, rule: o } = n,
|
|
2815
|
-
if (!(n.unitId !==
|
|
2865
|
+
const { unitId: i, subUnitId: s, rule: o } = n, u = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET), a = u.getActiveSheet();
|
|
2866
|
+
if (!(n.unitId !== u.getUnitId() || n.subUnitId !== (a == null ? void 0 : a.getSheetId())))
|
|
2816
2867
|
switch (n.type) {
|
|
2817
2868
|
case "add": {
|
|
2818
2869
|
r(n.unitId, n.subUnitId, n.rule);
|
|
@@ -2828,47 +2879,47 @@ let nt = class extends ce {
|
|
|
2828
2879
|
h && h(), r(n.unitId, n.subUnitId, n.rule);
|
|
2829
2880
|
}
|
|
2830
2881
|
}
|
|
2831
|
-
})), this.disposeWithMe(
|
|
2882
|
+
})), this.disposeWithMe(pn(() => {
|
|
2832
2883
|
t.forEach((n) => {
|
|
2833
2884
|
n();
|
|
2834
2885
|
}), t.clear();
|
|
2835
2886
|
}));
|
|
2836
2887
|
}
|
|
2837
2888
|
};
|
|
2838
|
-
nt =
|
|
2839
|
-
vt(0,
|
|
2840
|
-
vt(1,
|
|
2841
|
-
vt(2,
|
|
2842
|
-
vt(3,
|
|
2889
|
+
nt = Xi([
|
|
2890
|
+
vt(0, P(Q)),
|
|
2891
|
+
vt(1, P(Z)),
|
|
2892
|
+
vt(2, P(fe)),
|
|
2893
|
+
vt(3, P(Ur))
|
|
2843
2894
|
], nt);
|
|
2844
|
-
var
|
|
2845
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2895
|
+
var Ji = Object.getOwnPropertyDescriptor, Qi = (t, e, r, n) => {
|
|
2896
|
+
for (var i = n > 1 ? void 0 : n ? Ji(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2846
2897
|
(o = t[s]) && (i = o(i) || i);
|
|
2847
2898
|
return i;
|
|
2848
|
-
},
|
|
2849
|
-
let rt = class extends
|
|
2899
|
+
}, Oe = (t, e) => (r, n) => e(r, n, t);
|
|
2900
|
+
let rt = class extends ue {
|
|
2850
2901
|
constructor(e, r, n, i, s, o) {
|
|
2851
2902
|
super();
|
|
2852
2903
|
/**
|
|
2853
2904
|
* When a set operation is triggered multiple times over a short period of time, it may result in some callbacks not being disposed,and caused a render cache exception.
|
|
2854
2905
|
* The solution here is to store all the asynchronous tasks and focus on processing after the last callback
|
|
2855
2906
|
*/
|
|
2856
|
-
|
|
2907
|
+
Se(this, "_ruleChangeCacheMap", /* @__PURE__ */ new Map());
|
|
2857
2908
|
this._sheetInterceptorService = e, this._conditionalFormattingService = r, this._univerInstanceService = n, this._renderManagerService = i, this._conditionalFormattingViewModel = s, this._conditionalFormattingRuleModel = o, this._initViewModelInterceptor(), this._initSkeleton(), this.disposeWithMe(() => {
|
|
2858
2909
|
this._ruleChangeCacheMap.clear();
|
|
2859
2910
|
});
|
|
2860
2911
|
}
|
|
2861
2912
|
_markDirtySkeleton() {
|
|
2862
2913
|
var r, n, i;
|
|
2863
|
-
const e = this._univerInstanceService.getCurrentUnitForType(
|
|
2864
|
-
(r = this._renderManagerService.getRenderById(e)) == null || r.with(
|
|
2914
|
+
const e = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET).getUnitId();
|
|
2915
|
+
(r = this._renderManagerService.getRenderById(e)) == null || r.with(Un).reCalculate(), (i = (n = this._renderManagerService.getRenderById(e)) == null ? void 0 : n.mainComponent) == null || i.makeDirty();
|
|
2865
2916
|
}
|
|
2866
2917
|
_initSkeleton() {
|
|
2867
|
-
this.disposeWithMe(
|
|
2868
|
-
|
|
2869
|
-
|
|
2870
|
-
|
|
2871
|
-
const r = this._univerInstanceService.getCurrentUnitForType(
|
|
2918
|
+
this.disposeWithMe(Pn(this._conditionalFormattingRuleModel.$ruleChange, this._conditionalFormattingViewModel.markDirty$).pipe(
|
|
2919
|
+
ci(16),
|
|
2920
|
+
tn((e) => !!e.length),
|
|
2921
|
+
tn((e) => {
|
|
2922
|
+
const r = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET);
|
|
2872
2923
|
if (!r) return !1;
|
|
2873
2924
|
const n = r.getActiveSheet();
|
|
2874
2925
|
return n ? e.filter((i) => i.unitId === r.getUnitId() && i.subUnitId === n.getSheetId()).length > 0 : !1;
|
|
@@ -2876,34 +2927,34 @@ let rt = class extends ce {
|
|
|
2876
2927
|
).subscribe(() => this._markDirtySkeleton()));
|
|
2877
2928
|
}
|
|
2878
2929
|
_initViewModelInterceptor() {
|
|
2879
|
-
this.disposeWithMe(this._sheetInterceptorService.intercept(
|
|
2880
|
-
effect:
|
|
2930
|
+
this.disposeWithMe(this._sheetInterceptorService.intercept(Or.CELL_CONTENT, {
|
|
2931
|
+
effect: gr.Style,
|
|
2881
2932
|
handler: (e, r, n) => {
|
|
2882
2933
|
const i = this._conditionalFormattingService.composeStyle(r.unitId, r.subUnitId, r.row, r.col);
|
|
2883
2934
|
if (!i)
|
|
2884
2935
|
return n(e);
|
|
2885
|
-
const s = r.workbook.getStyles(),
|
|
2886
|
-
return i.style && Object.assign(
|
|
2936
|
+
const s = r.workbook.getStyles(), o = (typeof (e == null ? void 0 : e.s) == "string" ? s.get(e == null ? void 0 : e.s) : e == null ? void 0 : e.s) || {}, u = e === r.rawData ? { ...r.rawData } : e;
|
|
2937
|
+
return i.style && Object.assign(u, o), u.fontRenderExtension || (u.fontRenderExtension = {}, i.isShowValue !== void 0 && (u.fontRenderExtension.isSkip = !i.isShowValue)), i.dataBar && (u.dataBar = i.dataBar), i.iconSet && (u.iconSet = i.iconSet, u.fontRenderExtension.leftOffset = xr + Er), n(u);
|
|
2887
2938
|
},
|
|
2888
2939
|
priority: 10
|
|
2889
2940
|
}));
|
|
2890
2941
|
}
|
|
2891
2942
|
};
|
|
2892
|
-
rt =
|
|
2893
|
-
|
|
2894
|
-
|
|
2895
|
-
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2943
|
+
rt = Qi([
|
|
2944
|
+
Oe(0, P(qt)),
|
|
2945
|
+
Oe(1, P(Tn)),
|
|
2946
|
+
Oe(2, P(Z)),
|
|
2947
|
+
Oe(3, P(On)),
|
|
2948
|
+
Oe(4, P(it)),
|
|
2949
|
+
Oe(5, P(Q))
|
|
2899
2950
|
], rt);
|
|
2900
|
-
const
|
|
2901
|
-
var
|
|
2902
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2951
|
+
const rr = "sheets-conditional-formatting-ui.config", bt = {};
|
|
2952
|
+
var es = Object.defineProperty, ts = Object.getOwnPropertyDescriptor, ns = (t, e, r) => e in t ? es(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, rs = (t, e, r, n) => {
|
|
2953
|
+
for (var i = n > 1 ? void 0 : n ? ts(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2903
2954
|
(o = t[s]) && (i = o(i) || i);
|
|
2904
2955
|
return i;
|
|
2905
|
-
}, Dt = (t, e) => (r, n) => e(r, n, t),
|
|
2906
|
-
let
|
|
2956
|
+
}, Dt = (t, e) => (r, n) => e(r, n, t), ir = (t, e, r) => ns(t, typeof e != "symbol" ? e + "" : e, r);
|
|
2957
|
+
let It = class extends bn {
|
|
2907
2958
|
constructor(t = bt, e, r, n) {
|
|
2908
2959
|
super(), this._config = t, this._injector = e, this._commandService = r, this._configService = n;
|
|
2909
2960
|
const { menu: i, ...s } = In(
|
|
@@ -2911,146 +2962,146 @@ let St = class extends Sn {
|
|
|
2911
2962
|
bt,
|
|
2912
2963
|
this._config
|
|
2913
2964
|
);
|
|
2914
|
-
i && this._configService.setConfig("menu", i, { merge: !0 }), this._configService.setConfig(
|
|
2965
|
+
i && this._configService.setConfig("menu", i, { merge: !0 }), this._configService.setConfig(rr, s), this._initCommand(), this._injector.add([rt]), this._injector.add([nt]), this._injector.add([et]), this._injector.add([tt]), this._injector.add([He]);
|
|
2915
2966
|
}
|
|
2916
2967
|
_initCommand() {
|
|
2917
2968
|
[
|
|
2918
2969
|
Dn,
|
|
2919
2970
|
$n,
|
|
2920
|
-
|
|
2971
|
+
An,
|
|
2921
2972
|
Hn,
|
|
2973
|
+
jn,
|
|
2922
2974
|
Bn,
|
|
2923
2975
|
Wn,
|
|
2924
2976
|
qn,
|
|
2925
2977
|
Gn,
|
|
2926
|
-
|
|
2927
|
-
kt
|
|
2978
|
+
Vt
|
|
2928
2979
|
].forEach((t) => {
|
|
2929
2980
|
this._commandService.registerCommand(t);
|
|
2930
2981
|
});
|
|
2931
2982
|
}
|
|
2932
2983
|
};
|
|
2933
|
-
|
|
2934
|
-
|
|
2935
|
-
|
|
2936
|
-
|
|
2937
|
-
Dt(1,
|
|
2938
|
-
Dt(2,
|
|
2939
|
-
Dt(3,
|
|
2940
|
-
],
|
|
2941
|
-
var
|
|
2942
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
2984
|
+
ir(It, "pluginName", `${st}_MOBILE_UI_PLUGIN`);
|
|
2985
|
+
ir(It, "type", A.UNIVER_SHEET);
|
|
2986
|
+
It = rs([
|
|
2987
|
+
Cn(xn),
|
|
2988
|
+
Dt(1, P(fe)),
|
|
2989
|
+
Dt(2, P(te)),
|
|
2990
|
+
Dt(3, yn)
|
|
2991
|
+
], It);
|
|
2992
|
+
var is = Object.getOwnPropertyDescriptor, ss = (t, e, r, n) => {
|
|
2993
|
+
for (var i = n > 1 ? void 0 : n ? is(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
2943
2994
|
(o = t[s]) && (i = o(i) || i);
|
|
2944
2995
|
return i;
|
|
2945
|
-
},
|
|
2946
|
-
let
|
|
2996
|
+
}, Ze = (t, e) => (r, n) => e(r, n, t);
|
|
2997
|
+
let St = class extends ue {
|
|
2947
2998
|
constructor(t, e, r, n, i) {
|
|
2948
2999
|
super(), this._injector = t, this._univerInstanceService = e, this._autoFillService = r, this._conditionalFormattingRuleModel = n, this._conditionalFormattingViewModel = i, this._initAutoFill();
|
|
2949
3000
|
}
|
|
2950
3001
|
// eslint-disable-next-line max-lines-per-function
|
|
2951
3002
|
_initAutoFill() {
|
|
2952
|
-
const t = () => ({ redos: [], undos: [] }), e = (i, s, o,
|
|
3003
|
+
const t = () => ({ redos: [], undos: [] }), e = (i, s, o, u, a) => {
|
|
2953
3004
|
var p;
|
|
2954
|
-
const h = this._univerInstanceService.getCurrentUnitForType(
|
|
3005
|
+
const h = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET).getUnitId(), l = (p = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET).getActiveSheet()) == null ? void 0 : p.getSheetId();
|
|
2955
3006
|
if (!h || !l)
|
|
2956
3007
|
return;
|
|
2957
|
-
const
|
|
3008
|
+
const d = {
|
|
2958
3009
|
startRow: i.row,
|
|
2959
3010
|
startColumn: i.col,
|
|
2960
3011
|
endColumn: i.col,
|
|
2961
3012
|
endRow: i.row
|
|
2962
|
-
},
|
|
3013
|
+
}, v = {
|
|
2963
3014
|
startRow: s.row,
|
|
2964
3015
|
startColumn: s.col,
|
|
2965
3016
|
endColumn: s.col,
|
|
2966
3017
|
endRow: s.row
|
|
2967
3018
|
};
|
|
2968
|
-
|
|
2969
|
-
const
|
|
3019
|
+
be.foreach(o, (y, f) => {
|
|
3020
|
+
const w = ye.getPositionRange(
|
|
2970
3021
|
{
|
|
2971
|
-
startRow:
|
|
3022
|
+
startRow: y,
|
|
2972
3023
|
startColumn: f,
|
|
2973
3024
|
endColumn: f,
|
|
2974
|
-
endRow:
|
|
3025
|
+
endRow: y
|
|
2975
3026
|
},
|
|
2976
|
-
|
|
2977
|
-
),
|
|
3027
|
+
d
|
|
3028
|
+
), I = ye.getPositionRange(
|
|
2978
3029
|
{
|
|
2979
|
-
startRow:
|
|
3030
|
+
startRow: y,
|
|
2980
3031
|
startColumn: f,
|
|
2981
3032
|
endColumn: f,
|
|
2982
|
-
endRow:
|
|
3033
|
+
endRow: y
|
|
2983
3034
|
},
|
|
2984
|
-
|
|
2985
|
-
), { row: R, col:
|
|
3035
|
+
v
|
|
3036
|
+
), { row: R, col: x } = a(w.startRow, w.startColumn), T = this._conditionalFormattingViewModel.getCellCfs(
|
|
2986
3037
|
h,
|
|
2987
3038
|
l,
|
|
2988
3039
|
R,
|
|
2989
|
-
|
|
2990
|
-
), { row:
|
|
3040
|
+
x
|
|
3041
|
+
), { row: g, col: b } = a(I.startRow, I.startColumn), S = this._conditionalFormattingViewModel.getCellCfs(
|
|
2991
3042
|
h,
|
|
2992
3043
|
l,
|
|
2993
|
-
|
|
2994
|
-
|
|
3044
|
+
g,
|
|
3045
|
+
b
|
|
2995
3046
|
);
|
|
2996
|
-
|
|
2997
|
-
let M =
|
|
2998
|
-
if (!
|
|
2999
|
-
const E = this._conditionalFormattingRuleModel.getRule(h, l,
|
|
3047
|
+
S && S.forEach((C) => {
|
|
3048
|
+
let M = u.get(C.cfId);
|
|
3049
|
+
if (!u.get(C.cfId)) {
|
|
3050
|
+
const E = this._conditionalFormattingRuleModel.getRule(h, l, C.cfId);
|
|
3000
3051
|
if (!E)
|
|
3001
3052
|
return;
|
|
3002
|
-
M = new
|
|
3003
|
-
|
|
3004
|
-
M.setValue(
|
|
3053
|
+
M = new Me(), E.ranges.forEach((V) => {
|
|
3054
|
+
be.foreach(V, (O, m) => {
|
|
3055
|
+
M.setValue(O, m, 1);
|
|
3005
3056
|
});
|
|
3006
|
-
}),
|
|
3057
|
+
}), u.set(C.cfId, M);
|
|
3007
3058
|
}
|
|
3008
|
-
M.realDeleteValue(
|
|
3009
|
-
}),
|
|
3010
|
-
let M =
|
|
3011
|
-
if (!
|
|
3012
|
-
const E = this._conditionalFormattingRuleModel.getRule(h, l,
|
|
3059
|
+
M.realDeleteValue(g, b);
|
|
3060
|
+
}), T && T.forEach((C) => {
|
|
3061
|
+
let M = u.get(C.cfId);
|
|
3062
|
+
if (!u.get(C.cfId)) {
|
|
3063
|
+
const E = this._conditionalFormattingRuleModel.getRule(h, l, C.cfId);
|
|
3013
3064
|
if (!E)
|
|
3014
3065
|
return;
|
|
3015
|
-
M = new
|
|
3016
|
-
|
|
3017
|
-
M.setValue(
|
|
3066
|
+
M = new Me(), E.ranges.forEach((V) => {
|
|
3067
|
+
be.foreach(V, (O, m) => {
|
|
3068
|
+
M.setValue(O, m, 1);
|
|
3018
3069
|
});
|
|
3019
|
-
}),
|
|
3070
|
+
}), u.set(C.cfId, M);
|
|
3020
3071
|
}
|
|
3021
|
-
M.setValue(
|
|
3072
|
+
M.setValue(g, b, 1);
|
|
3022
3073
|
});
|
|
3023
3074
|
});
|
|
3024
3075
|
}, r = (i, s) => {
|
|
3025
|
-
var
|
|
3026
|
-
const o = (
|
|
3027
|
-
if (!o || !
|
|
3076
|
+
var I, R, x;
|
|
3077
|
+
const o = (I = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET)) == null ? void 0 : I.getUnitId(), u = (x = (R = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET)) == null ? void 0 : R.getActiveSheet()) == null ? void 0 : x.getSheetId(), a = /* @__PURE__ */ new Map(), h = [], l = [];
|
|
3078
|
+
if (!o || !u)
|
|
3028
3079
|
return t();
|
|
3029
|
-
const
|
|
3030
|
-
row:
|
|
3031
|
-
col:
|
|
3080
|
+
const d = Ln([i, s]), [v, p] = d.ranges, { mapFunc: y } = d, f = {
|
|
3081
|
+
row: v.startRow,
|
|
3082
|
+
col: v.startColumn
|
|
3032
3083
|
};
|
|
3033
|
-
return
|
|
3034
|
-
e(f,
|
|
3035
|
-
}), a.forEach((
|
|
3036
|
-
const
|
|
3037
|
-
if (!
|
|
3084
|
+
return oi(v, p).forEach((T) => {
|
|
3085
|
+
e(f, T.repeatStartCell, T.relativeRange, a, y);
|
|
3086
|
+
}), a.forEach((T, g) => {
|
|
3087
|
+
const b = this._conditionalFormattingRuleModel.getRule(o, u, g);
|
|
3088
|
+
if (!b)
|
|
3038
3089
|
return;
|
|
3039
|
-
const
|
|
3040
|
-
if (
|
|
3041
|
-
const
|
|
3090
|
+
const S = pt(Ct(T));
|
|
3091
|
+
if (S.length) {
|
|
3092
|
+
const C = {
|
|
3042
3093
|
unitId: o,
|
|
3043
|
-
subUnitId:
|
|
3044
|
-
rule: { ...
|
|
3094
|
+
subUnitId: u,
|
|
3095
|
+
rule: { ...b, ranges: S }
|
|
3045
3096
|
};
|
|
3046
|
-
h.push({ id:
|
|
3097
|
+
h.push({ id: _e.id, params: C }), l.push(...Ae(this._injector, C));
|
|
3047
3098
|
} else {
|
|
3048
|
-
const
|
|
3099
|
+
const C = {
|
|
3049
3100
|
unitId: o,
|
|
3050
|
-
subUnitId:
|
|
3051
|
-
cfId:
|
|
3101
|
+
subUnitId: u,
|
|
3102
|
+
cfId: b.cfId
|
|
3052
3103
|
};
|
|
3053
|
-
h.push({ id:
|
|
3104
|
+
h.push({ id: we.id, params: C }), l.push(...$e(this._injector, C));
|
|
3054
3105
|
}
|
|
3055
3106
|
}), {
|
|
3056
3107
|
undos: l,
|
|
@@ -3059,9 +3110,9 @@ let It = class extends ce {
|
|
|
3059
3110
|
}, n = {
|
|
3060
3111
|
id: st,
|
|
3061
3112
|
onFillData: (i, s, o) => {
|
|
3062
|
-
if (o ===
|
|
3063
|
-
const { source:
|
|
3064
|
-
return r(
|
|
3113
|
+
if (o === Lt.COPY || o === Lt.ONLY_FORMAT || o === Lt.SERIES) {
|
|
3114
|
+
const { source: u, target: a } = i;
|
|
3115
|
+
return r(u, a);
|
|
3065
3116
|
}
|
|
3066
3117
|
return t();
|
|
3067
3118
|
}
|
|
@@ -3069,19 +3120,19 @@ let It = class extends ce {
|
|
|
3069
3120
|
this.disposeWithMe(this._autoFillService.addHook(n));
|
|
3070
3121
|
}
|
|
3071
3122
|
};
|
|
3072
|
-
|
|
3073
|
-
|
|
3074
|
-
|
|
3075
|
-
|
|
3076
|
-
|
|
3077
|
-
|
|
3078
|
-
],
|
|
3079
|
-
var
|
|
3080
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
3123
|
+
St = ss([
|
|
3124
|
+
Ze(0, P(fe)),
|
|
3125
|
+
Ze(1, P(Z)),
|
|
3126
|
+
Ze(2, P(si)),
|
|
3127
|
+
Ze(3, P(Q)),
|
|
3128
|
+
Ze(4, P(it))
|
|
3129
|
+
], St);
|
|
3130
|
+
var os = Object.getOwnPropertyDescriptor, as = (t, e, r, n) => {
|
|
3131
|
+
for (var i = n > 1 ? void 0 : n ? os(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
3081
3132
|
(o = t[s]) && (i = o(i) || i);
|
|
3082
3133
|
return i;
|
|
3083
|
-
},
|
|
3084
|
-
let _t = class extends
|
|
3134
|
+
}, ze = (t, e) => (r, n) => e(r, n, t);
|
|
3135
|
+
let _t = class extends ue {
|
|
3085
3136
|
constructor(t, e, r, n, i) {
|
|
3086
3137
|
super(), this._injector = t, this._univerInstanceService = e, this._sheetInterceptorService = r, this._selectionManagerService = n, this._conditionalFormattingRuleModel = i, this._init();
|
|
3087
3138
|
}
|
|
@@ -3090,18 +3141,18 @@ let _t = class extends ce {
|
|
|
3090
3141
|
getMutations: (t) => {
|
|
3091
3142
|
var i;
|
|
3092
3143
|
const e = [], r = [], n = { redos: e, undos: r };
|
|
3093
|
-
if ([
|
|
3144
|
+
if ([Dr.id, $r.id].includes(t.id)) {
|
|
3094
3145
|
const s = (i = this._selectionManagerService.getCurrentSelections()) == null ? void 0 : i.map((p) => p.range);
|
|
3095
3146
|
if (!s)
|
|
3096
3147
|
return n;
|
|
3097
|
-
const o = this._univerInstanceService.getCurrentUnitForType(
|
|
3098
|
-
if (!
|
|
3148
|
+
const o = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET), u = o.getActiveSheet();
|
|
3149
|
+
if (!u)
|
|
3099
3150
|
return n;
|
|
3100
|
-
const a = o.getUnitId(), h =
|
|
3151
|
+
const a = o.getUnitId(), h = u.getSheetId(), l = this._conditionalFormattingRuleModel.getSubunitRules(a, h);
|
|
3101
3152
|
if (!l || !l.length)
|
|
3102
3153
|
return n;
|
|
3103
|
-
const { redos:
|
|
3104
|
-
e.push(...
|
|
3154
|
+
const { redos: d, undos: v } = dn(this._injector, l, s, a, h);
|
|
3155
|
+
e.push(...d), r.push(...v);
|
|
3105
3156
|
}
|
|
3106
3157
|
return n;
|
|
3107
3158
|
}
|
|
@@ -3113,52 +3164,52 @@ let _t = class extends ce {
|
|
|
3113
3164
|
const o = this._conditionalFormattingRuleModel.getSubunitRules(t, e);
|
|
3114
3165
|
if (!o || !o.length)
|
|
3115
3166
|
return s;
|
|
3116
|
-
const { redos:
|
|
3117
|
-
return n.push(...
|
|
3167
|
+
const { redos: u, undos: a } = dn(this._injector, o, r, t, e);
|
|
3168
|
+
return n.push(...u), i.push(...a), s;
|
|
3118
3169
|
}
|
|
3119
3170
|
}));
|
|
3120
3171
|
}
|
|
3121
3172
|
};
|
|
3122
|
-
_t =
|
|
3123
|
-
|
|
3124
|
-
|
|
3125
|
-
|
|
3126
|
-
|
|
3127
|
-
|
|
3173
|
+
_t = as([
|
|
3174
|
+
ze(0, P(fe)),
|
|
3175
|
+
ze(1, P(Z)),
|
|
3176
|
+
ze(2, P(qt)),
|
|
3177
|
+
ze(3, P(je)),
|
|
3178
|
+
ze(4, P(Q))
|
|
3128
3179
|
], _t);
|
|
3129
|
-
function
|
|
3180
|
+
function dn(t, e, r, n, i) {
|
|
3130
3181
|
const s = [], o = [];
|
|
3131
|
-
return e.filter((
|
|
3132
|
-
const h = new
|
|
3182
|
+
return e.filter((u) => r.some((a) => u.ranges.some((h) => ye.getIntersects(h, a)))).forEach((u) => {
|
|
3183
|
+
const h = new Ar().add(...u.ranges).subtract(...r).merge();
|
|
3133
3184
|
if (h.length) {
|
|
3134
3185
|
const l = {
|
|
3135
|
-
id:
|
|
3186
|
+
id: _e.id,
|
|
3136
3187
|
params: {
|
|
3137
3188
|
unitId: n,
|
|
3138
3189
|
subUnitId: i,
|
|
3139
|
-
rule: { ...
|
|
3190
|
+
rule: { ...u, ranges: h }
|
|
3140
3191
|
}
|
|
3141
|
-
},
|
|
3142
|
-
s.push(l), o.push(...
|
|
3192
|
+
}, d = Ae(t, l.params);
|
|
3193
|
+
s.push(l), o.push(...d);
|
|
3143
3194
|
} else {
|
|
3144
3195
|
const l = {
|
|
3145
|
-
id:
|
|
3196
|
+
id: we.id,
|
|
3146
3197
|
params: {
|
|
3147
3198
|
unitId: n,
|
|
3148
3199
|
subUnitId: i,
|
|
3149
|
-
cfId:
|
|
3200
|
+
cfId: u.cfId
|
|
3150
3201
|
}
|
|
3151
|
-
},
|
|
3152
|
-
s.push(l), o.push(...
|
|
3202
|
+
}, d = $e(t, l.params);
|
|
3203
|
+
s.push(l), o.push(...d);
|
|
3153
3204
|
}
|
|
3154
3205
|
}), { redos: s, undos: o };
|
|
3155
3206
|
}
|
|
3156
|
-
var
|
|
3157
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
3207
|
+
var ls = Object.getOwnPropertyDescriptor, cs = (t, e, r, n) => {
|
|
3208
|
+
for (var i = n > 1 ? void 0 : n ? ls(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
3158
3209
|
(o = t[s]) && (i = o(i) || i);
|
|
3159
3210
|
return i;
|
|
3160
|
-
},
|
|
3161
|
-
let
|
|
3211
|
+
}, hn = (t, e) => (r, n) => e(r, n, t);
|
|
3212
|
+
let wt = class extends ue {
|
|
3162
3213
|
constructor(t, e) {
|
|
3163
3214
|
super(), this._sheetInterceptorService = t, this._conditionalFormattingService = e, this._initInterceptorEditorEnd();
|
|
3164
3215
|
}
|
|
@@ -3169,25 +3220,25 @@ let Tt = class extends ce {
|
|
|
3169
3220
|
*/
|
|
3170
3221
|
_initInterceptorEditorEnd() {
|
|
3171
3222
|
this.disposeWithMe(
|
|
3172
|
-
|
|
3223
|
+
pn(
|
|
3173
3224
|
this._sheetInterceptorService.writeCellInterceptor.intercept(
|
|
3174
|
-
|
|
3225
|
+
Hr,
|
|
3175
3226
|
{
|
|
3176
3227
|
handler: (t, e, r) => {
|
|
3177
|
-
var o,
|
|
3228
|
+
var o, u, a;
|
|
3178
3229
|
t || r(t);
|
|
3179
3230
|
const n = this._conditionalFormattingService.composeStyle(e.unitId, e.subUnitId, e.row, e.col), i = (o = n == null ? void 0 : n.style) != null ? o : {}, s = Object.keys(i);
|
|
3180
3231
|
if (t != null && t.p)
|
|
3181
|
-
return (a = (
|
|
3232
|
+
return (a = (u = t.p.body) == null ? void 0 : u.textRuns) == null || a.forEach((h) => {
|
|
3182
3233
|
h.ts && s.forEach((l) => {
|
|
3183
|
-
var
|
|
3184
|
-
(
|
|
3234
|
+
var d;
|
|
3235
|
+
(d = h.ts) == null || delete d[l];
|
|
3185
3236
|
});
|
|
3186
3237
|
}), r(t);
|
|
3187
3238
|
{
|
|
3188
3239
|
const h = { ...(typeof (t == null ? void 0 : t.s) == "string" ? e.workbook.getStyles().get(t.s) : t == null ? void 0 : t.s) || {} };
|
|
3189
|
-
s.forEach((
|
|
3190
|
-
delete h[
|
|
3240
|
+
s.forEach((d) => {
|
|
3241
|
+
delete h[d];
|
|
3191
3242
|
});
|
|
3192
3243
|
const l = { ...t, s: { ...h } };
|
|
3193
3244
|
return r(l);
|
|
@@ -3199,16 +3250,16 @@ let Tt = class extends ce {
|
|
|
3199
3250
|
);
|
|
3200
3251
|
}
|
|
3201
3252
|
};
|
|
3202
|
-
|
|
3203
|
-
|
|
3204
|
-
|
|
3205
|
-
],
|
|
3206
|
-
const
|
|
3207
|
-
|
|
3253
|
+
wt = cs([
|
|
3254
|
+
hn(0, P(qt)),
|
|
3255
|
+
hn(1, P(Tn))
|
|
3256
|
+
], wt);
|
|
3257
|
+
const vn = [
|
|
3258
|
+
Wt.id,
|
|
3208
3259
|
se.id,
|
|
3209
|
-
|
|
3210
|
-
|
|
3211
|
-
|
|
3260
|
+
_e.id,
|
|
3261
|
+
we.id,
|
|
3262
|
+
_n.id
|
|
3212
3263
|
], Ye = [
|
|
3213
3264
|
{
|
|
3214
3265
|
label: {
|
|
@@ -3281,94 +3332,94 @@ const gn = [
|
|
|
3281
3332
|
},
|
|
3282
3333
|
value: ie.clearWorkSheetRules
|
|
3283
3334
|
}
|
|
3284
|
-
],
|
|
3285
|
-
const e = t.get(
|
|
3335
|
+
], us = (t) => {
|
|
3336
|
+
const e = t.get(je), r = t.get(te), n = t.get(Z), i = t.get(Q), s = new Ne((a) => Pn(
|
|
3286
3337
|
e.selectionMoveEnd$,
|
|
3287
3338
|
e.selectionSet$,
|
|
3288
|
-
new
|
|
3289
|
-
const l = r.onCommandExecuted((
|
|
3339
|
+
new Ne((h) => {
|
|
3340
|
+
const l = r.onCommandExecuted((d) => {
|
|
3290
3341
|
var f;
|
|
3291
|
-
const { id:
|
|
3292
|
-
|
|
3342
|
+
const { id: v, params: p } = d, y = (f = n.getCurrentUnitForType(A.UNIVER_SHEET)) == null ? void 0 : f.getUnitId();
|
|
3343
|
+
vn.includes(v) && p.unitId === y && h.next(null);
|
|
3293
3344
|
});
|
|
3294
3345
|
return () => l.dispose();
|
|
3295
3346
|
})
|
|
3296
|
-
).pipe(
|
|
3347
|
+
).pipe(nn(16)).subscribe(() => {
|
|
3297
3348
|
var f;
|
|
3298
|
-
const h = ((f = e.getCurrentSelections()) == null ? void 0 : f.map((
|
|
3349
|
+
const h = ((f = e.getCurrentSelections()) == null ? void 0 : f.map((w) => w.range)) || [], l = n.getCurrentUnitForType(A.UNIVER_SHEET);
|
|
3299
3350
|
if (!l) return;
|
|
3300
|
-
const
|
|
3301
|
-
if (!
|
|
3302
|
-
const
|
|
3303
|
-
a.next(
|
|
3304
|
-
})), o = new
|
|
3305
|
-
(a) => new
|
|
3306
|
-
const l = r.onCommandExecuted((
|
|
3351
|
+
const d = l.getActiveSheet();
|
|
3352
|
+
if (!d) return;
|
|
3353
|
+
const y = (i.getSubunitRules(l.getUnitId(), d.getSheetId()) || []).filter((w) => w.ranges.some((I) => h.some((R) => ye.intersects(R, I)))).map((w) => w.ranges).every((w) => ft(t, l.getUnitId(), d.getSheetId(), w));
|
|
3354
|
+
a.next(y);
|
|
3355
|
+
})), o = new Ne(
|
|
3356
|
+
(a) => new Ne((h) => {
|
|
3357
|
+
const l = r.onCommandExecuted((d) => {
|
|
3307
3358
|
var f;
|
|
3308
|
-
const { id:
|
|
3309
|
-
|
|
3359
|
+
const { id: v, params: p } = d, y = (f = n.getCurrentUnitForType(A.UNIVER_SHEET)) == null ? void 0 : f.getUnitId();
|
|
3360
|
+
vn.includes(v) && p.unitId === y && h.next(null);
|
|
3310
3361
|
});
|
|
3311
3362
|
return () => l.dispose();
|
|
3312
|
-
}).pipe(
|
|
3313
|
-
const h = n.getCurrentUnitForType(
|
|
3363
|
+
}).pipe(nn(16)).subscribe(() => {
|
|
3364
|
+
const h = n.getCurrentUnitForType(A.UNIVER_SHEET);
|
|
3314
3365
|
if (!h) return;
|
|
3315
3366
|
const l = h.getActiveSheet();
|
|
3316
3367
|
if (!l) return;
|
|
3317
|
-
const
|
|
3318
|
-
if (!
|
|
3368
|
+
const d = i.getSubunitRules(h.getUnitId(), l.getSheetId()) || [];
|
|
3369
|
+
if (!d.length)
|
|
3319
3370
|
return a.next(!1), !1;
|
|
3320
|
-
const
|
|
3321
|
-
a.next(
|
|
3371
|
+
const v = d.map((p) => p.ranges).every((p) => ft(t, h.getUnitId(), l.getSheetId(), p));
|
|
3372
|
+
a.next(v);
|
|
3322
3373
|
})
|
|
3323
|
-
),
|
|
3374
|
+
), u = new Ne((a) => {
|
|
3324
3375
|
s.subscribe((h) => {
|
|
3325
|
-
const l = Ye.find((
|
|
3376
|
+
const l = Ye.find((d) => d.value === ie.clearRangeRules);
|
|
3326
3377
|
l && (l.disabled = !h, a.next(Ye));
|
|
3327
3378
|
}), o.subscribe((h) => {
|
|
3328
|
-
const l = Ye.find((
|
|
3379
|
+
const l = Ye.find((d) => d.value === ie.clearWorkSheetRules);
|
|
3329
3380
|
l && (l.disabled = !h, a.next(Ye));
|
|
3330
3381
|
}), a.next(Ye);
|
|
3331
3382
|
});
|
|
3332
3383
|
return {
|
|
3333
|
-
id:
|
|
3334
|
-
type:
|
|
3335
|
-
icon: "
|
|
3384
|
+
id: Vt.id,
|
|
3385
|
+
type: Zr.SELECTOR,
|
|
3386
|
+
icon: "ConditionsDoubleIcon",
|
|
3336
3387
|
tooltip: "sheet.cf.title",
|
|
3337
|
-
selections:
|
|
3338
|
-
hidden$:
|
|
3339
|
-
disabled$:
|
|
3388
|
+
selections: u,
|
|
3389
|
+
hidden$: Gr(t, A.UNIVER_SHEET),
|
|
3390
|
+
disabled$: ai(t, { workbookTypes: [Vn], worksheetTypes: [Nn, En], rangeTypes: [Mn] })
|
|
3340
3391
|
};
|
|
3341
|
-
},
|
|
3342
|
-
[
|
|
3343
|
-
[
|
|
3392
|
+
}, ds = {
|
|
3393
|
+
[zr.RULES]: {
|
|
3394
|
+
[Vt.id]: {
|
|
3344
3395
|
order: 1,
|
|
3345
|
-
menuItemFactory:
|
|
3396
|
+
menuItemFactory: us
|
|
3346
3397
|
}
|
|
3347
3398
|
}
|
|
3348
3399
|
};
|
|
3349
|
-
var
|
|
3350
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
3400
|
+
var hs = Object.getOwnPropertyDescriptor, vs = (t, e, r, n) => {
|
|
3401
|
+
for (var i = n > 1 ? void 0 : n ? hs(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
3351
3402
|
(o = t[s]) && (i = o(i) || i);
|
|
3352
3403
|
return i;
|
|
3353
|
-
},
|
|
3354
|
-
let Rt = class extends
|
|
3404
|
+
}, gn = (t, e) => (r, n) => e(r, n, t);
|
|
3405
|
+
let Rt = class extends ue {
|
|
3355
3406
|
constructor(e, r) {
|
|
3356
3407
|
super();
|
|
3357
|
-
|
|
3358
|
-
this._injector = e, this._menuManagerService = r, this._menuManagerService.mergeMenu(
|
|
3408
|
+
Se(this, "_sidebarDisposable", null);
|
|
3409
|
+
this._injector = e, this._menuManagerService = r, this._menuManagerService.mergeMenu(ds);
|
|
3359
3410
|
}
|
|
3360
3411
|
};
|
|
3361
|
-
Rt =
|
|
3362
|
-
|
|
3363
|
-
|
|
3412
|
+
Rt = vs([
|
|
3413
|
+
gn(0, P(fe)),
|
|
3414
|
+
gn(1, Yr)
|
|
3364
3415
|
], Rt);
|
|
3365
|
-
var
|
|
3366
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
3416
|
+
var gs = Object.getOwnPropertyDescriptor, ms = (t, e, r, n) => {
|
|
3417
|
+
for (var i = n > 1 ? void 0 : n ? gs(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
3367
3418
|
(o = t[s]) && (i = o(i) || i);
|
|
3368
3419
|
return i;
|
|
3369
|
-
},
|
|
3370
|
-
const
|
|
3371
|
-
const r = (l) => l.endRow - l.startRow + 1, n = (l) => l.endColumn - l.startColumn + 1, i = r(e) % r(t), s = n(e) % n(t), o = Math.floor(r(e) / r(t)),
|
|
3420
|
+
}, De = (t, e) => (r, n) => e(r, n, t);
|
|
3421
|
+
const fs = (t, e) => {
|
|
3422
|
+
const r = (l) => l.endRow - l.startRow + 1, n = (l) => l.endColumn - l.startColumn + 1, i = r(e) % r(t), s = n(e) % n(t), o = Math.floor(r(e) / r(t)), u = Math.floor(n(e) / n(t)), a = [], h = {
|
|
3372
3423
|
startRow: 0,
|
|
3373
3424
|
endRow: r(t) - 1,
|
|
3374
3425
|
startColumn: 0,
|
|
@@ -3384,28 +3435,28 @@ const is = (t, e) => {
|
|
|
3384
3435
|
return a.push({ repeatRelativeRange: h, startRange: l }), a;
|
|
3385
3436
|
}
|
|
3386
3437
|
for (let l = 0; l < o + (i ? 0.1 : 0); l++)
|
|
3387
|
-
for (let
|
|
3388
|
-
const
|
|
3389
|
-
startRow:
|
|
3390
|
-
endRow:
|
|
3438
|
+
for (let d = 0; d < u + (s ? 0.1 : 0); d++) {
|
|
3439
|
+
const v = r(t) * l, p = n(t) * d, y = {
|
|
3440
|
+
startRow: v + e.startRow,
|
|
3441
|
+
endRow: v + e.startRow,
|
|
3391
3442
|
startColumn: p + e.startColumn,
|
|
3392
3443
|
endColumn: p + e.startColumn
|
|
3393
3444
|
};
|
|
3394
3445
|
let f = h;
|
|
3395
|
-
l === o && i && (f = { ...f }, f.endRow = f.endRow - (r(t) - i)),
|
|
3446
|
+
l === o && i && (f = { ...f }, f.endRow = f.endRow - (r(t) - i)), d === u && s && (f = { ...f }, f.endColumn = f.endColumn - (n(t) - s)), a.push({ repeatRelativeRange: f, startRange: y });
|
|
3396
3447
|
}
|
|
3397
3448
|
return a;
|
|
3398
3449
|
};
|
|
3399
|
-
let
|
|
3450
|
+
let Tt = class extends ue {
|
|
3400
3451
|
constructor(e, r, n, i, s, o) {
|
|
3401
3452
|
super();
|
|
3402
|
-
|
|
3453
|
+
Se(this, "_painterConfig", null);
|
|
3403
3454
|
this._injector = e, this._univerInstanceService = r, this._formatPainterService = n, this._sheetsSelectionsService = i, this._conditionalFormattingRuleModel = s, this._conditionalFormattingViewModel = o, this._initFormattingPainter();
|
|
3404
3455
|
}
|
|
3405
3456
|
// eslint-disable-next-line max-lines-per-function
|
|
3406
3457
|
_initFormattingPainter() {
|
|
3407
|
-
const e = () => ({ redos: [], undos: [] }), r = (s, o,
|
|
3408
|
-
const { unitId: l, subUnitId:
|
|
3458
|
+
const e = () => ({ redos: [], undos: [] }), r = (s, o, u, a, h) => {
|
|
3459
|
+
const { unitId: l, subUnitId: d } = this._painterConfig, { targetUnitId: v, targetSubUnitId: p } = h, y = {
|
|
3409
3460
|
startRow: s.row,
|
|
3410
3461
|
startColumn: s.col,
|
|
3411
3462
|
endColumn: s.col,
|
|
@@ -3416,152 +3467,152 @@ let xt = class extends ce {
|
|
|
3416
3467
|
endColumn: o.col,
|
|
3417
3468
|
endRow: o.row
|
|
3418
3469
|
};
|
|
3419
|
-
|
|
3420
|
-
const R =
|
|
3470
|
+
be.foreach(u, (w, I) => {
|
|
3471
|
+
const R = ye.getPositionRange(
|
|
3421
3472
|
{
|
|
3422
|
-
startRow:
|
|
3423
|
-
startColumn:
|
|
3424
|
-
endColumn:
|
|
3425
|
-
endRow:
|
|
3473
|
+
startRow: w,
|
|
3474
|
+
startColumn: I,
|
|
3475
|
+
endColumn: I,
|
|
3476
|
+
endRow: w
|
|
3426
3477
|
},
|
|
3427
|
-
|
|
3428
|
-
),
|
|
3478
|
+
y
|
|
3479
|
+
), x = ye.getPositionRange(
|
|
3429
3480
|
{
|
|
3430
|
-
startRow:
|
|
3431
|
-
startColumn:
|
|
3432
|
-
endColumn:
|
|
3433
|
-
endRow:
|
|
3481
|
+
startRow: w,
|
|
3482
|
+
startColumn: I,
|
|
3483
|
+
endColumn: I,
|
|
3484
|
+
endRow: w
|
|
3434
3485
|
},
|
|
3435
3486
|
f
|
|
3436
|
-
),
|
|
3487
|
+
), T = this._conditionalFormattingViewModel.getCellCfs(
|
|
3437
3488
|
l,
|
|
3438
|
-
|
|
3489
|
+
d,
|
|
3439
3490
|
R.startRow,
|
|
3440
3491
|
R.startColumn
|
|
3441
|
-
),
|
|
3442
|
-
|
|
3492
|
+
), g = this._conditionalFormattingViewModel.getCellCfs(
|
|
3493
|
+
v,
|
|
3443
3494
|
p,
|
|
3444
|
-
|
|
3445
|
-
|
|
3495
|
+
x.startRow,
|
|
3496
|
+
x.startColumn
|
|
3446
3497
|
);
|
|
3447
|
-
|
|
3448
|
-
let
|
|
3449
|
-
if (!a.get(
|
|
3450
|
-
const
|
|
3451
|
-
if (!
|
|
3498
|
+
g && g.forEach((b) => {
|
|
3499
|
+
let S = a.get(b.cfId);
|
|
3500
|
+
if (!a.get(b.cfId)) {
|
|
3501
|
+
const C = this._conditionalFormattingRuleModel.getRule(v, p, b.cfId);
|
|
3502
|
+
if (!C)
|
|
3452
3503
|
return;
|
|
3453
|
-
|
|
3454
|
-
|
|
3455
|
-
|
|
3504
|
+
S = new Me(), C.ranges.forEach((M) => {
|
|
3505
|
+
be.foreach(M, (E, V) => {
|
|
3506
|
+
S.setValue(E, V, 1);
|
|
3456
3507
|
});
|
|
3457
|
-
}), a.set(
|
|
3508
|
+
}), a.set(b.cfId, S);
|
|
3458
3509
|
}
|
|
3459
|
-
|
|
3460
|
-
}),
|
|
3461
|
-
const
|
|
3462
|
-
|
|
3510
|
+
S.realDeleteValue(x.startRow, x.startColumn);
|
|
3511
|
+
}), T && T.forEach((b) => {
|
|
3512
|
+
const S = a.get(b.cfId);
|
|
3513
|
+
S && S.setValue(x.startRow, x.startColumn, 1);
|
|
3463
3514
|
});
|
|
3464
3515
|
});
|
|
3465
|
-
}, n = (s, o,
|
|
3516
|
+
}, n = (s, o, u) => {
|
|
3466
3517
|
var R;
|
|
3467
|
-
const { range: a, unitId: h, subUnitId: l } = this._painterConfig,
|
|
3518
|
+
const { range: a, unitId: h, subUnitId: l } = this._painterConfig, d = s !== h || l !== o, v = /* @__PURE__ */ new Map(), p = [], y = [];
|
|
3468
3519
|
if (!s || !o || !h || !l)
|
|
3469
3520
|
return e();
|
|
3470
3521
|
const f = (R = this._conditionalFormattingRuleModel.getSubunitRules(h, l)) != null ? R : [];
|
|
3471
|
-
f == null || f.forEach((
|
|
3472
|
-
const { ranges:
|
|
3473
|
-
if (
|
|
3474
|
-
const
|
|
3475
|
-
|
|
3476
|
-
|
|
3477
|
-
|
|
3522
|
+
f == null || f.forEach((x) => {
|
|
3523
|
+
const { ranges: T, cfId: g } = x;
|
|
3524
|
+
if (T.some((b) => ye.intersects(a, b))) {
|
|
3525
|
+
const b = new Me();
|
|
3526
|
+
d || T.forEach((S) => {
|
|
3527
|
+
be.foreach(S, (C, M) => {
|
|
3528
|
+
b.setValue(C, M, 1);
|
|
3478
3529
|
});
|
|
3479
|
-
}),
|
|
3530
|
+
}), v.set(g, b);
|
|
3480
3531
|
}
|
|
3481
3532
|
});
|
|
3482
|
-
const
|
|
3533
|
+
const w = {
|
|
3483
3534
|
row: a.startRow,
|
|
3484
3535
|
col: a.startColumn
|
|
3485
3536
|
};
|
|
3486
|
-
return
|
|
3487
|
-
r(
|
|
3488
|
-
}),
|
|
3489
|
-
if (
|
|
3490
|
-
const
|
|
3491
|
-
if (
|
|
3492
|
-
if (
|
|
3493
|
-
const
|
|
3537
|
+
return fs(a, u).forEach((x) => {
|
|
3538
|
+
r(w, { row: x.startRange.startRow, col: x.startRange.startColumn }, x.repeatRelativeRange, v, { targetUnitId: s, targetSubUnitId: o });
|
|
3539
|
+
}), v.forEach((x, T) => {
|
|
3540
|
+
if (d) {
|
|
3541
|
+
const g = this._conditionalFormattingRuleModel.getRule(s, o, T), b = pt(Ct(x));
|
|
3542
|
+
if (g)
|
|
3543
|
+
if (b.length) {
|
|
3544
|
+
const S = {
|
|
3494
3545
|
unitId: s,
|
|
3495
3546
|
subUnitId: o,
|
|
3496
|
-
rule: { ...
|
|
3547
|
+
rule: { ...g, ranges: b }
|
|
3497
3548
|
};
|
|
3498
|
-
p.push({ id:
|
|
3549
|
+
p.push({ id: _e.id, params: S }), y.push(...Ae(this._injector, S));
|
|
3499
3550
|
} else {
|
|
3500
|
-
const
|
|
3551
|
+
const S = {
|
|
3501
3552
|
unitId: s,
|
|
3502
3553
|
subUnitId: o,
|
|
3503
|
-
cfId:
|
|
3554
|
+
cfId: g.cfId
|
|
3504
3555
|
};
|
|
3505
|
-
p.push({ id:
|
|
3556
|
+
p.push({ id: we.id, params: S }), y.push(...$e(this._injector, S));
|
|
3506
3557
|
}
|
|
3507
|
-
else if (
|
|
3508
|
-
const
|
|
3509
|
-
if (
|
|
3510
|
-
const
|
|
3558
|
+
else if (b.length) {
|
|
3559
|
+
const S = this._conditionalFormattingRuleModel.getRule(h, l, T);
|
|
3560
|
+
if (S) {
|
|
3561
|
+
const C = {
|
|
3511
3562
|
unitId: s,
|
|
3512
3563
|
subUnitId: o,
|
|
3513
3564
|
rule: {
|
|
3514
|
-
...
|
|
3565
|
+
...Bt.deepClone(S),
|
|
3515
3566
|
cfId: this._conditionalFormattingRuleModel.createCfId(s, o),
|
|
3516
|
-
ranges:
|
|
3567
|
+
ranges: b
|
|
3517
3568
|
}
|
|
3518
3569
|
};
|
|
3519
|
-
p.push({ id: se.id, params:
|
|
3570
|
+
p.push({ id: se.id, params: C }), y.push(Rn(this._injector, C));
|
|
3520
3571
|
}
|
|
3521
3572
|
}
|
|
3522
3573
|
} else {
|
|
3523
|
-
const
|
|
3524
|
-
if (!
|
|
3574
|
+
const g = this._conditionalFormattingRuleModel.getRule(h, l, T);
|
|
3575
|
+
if (!g)
|
|
3525
3576
|
return;
|
|
3526
|
-
const
|
|
3527
|
-
if (
|
|
3528
|
-
const
|
|
3577
|
+
const b = pt(Ct(x));
|
|
3578
|
+
if (b.length) {
|
|
3579
|
+
const S = {
|
|
3529
3580
|
unitId: h,
|
|
3530
3581
|
subUnitId: l,
|
|
3531
|
-
rule: { ...
|
|
3582
|
+
rule: { ...g, ranges: b }
|
|
3532
3583
|
};
|
|
3533
|
-
p.push({ id:
|
|
3584
|
+
p.push({ id: _e.id, params: S }), y.push(...Ae(this._injector, S));
|
|
3534
3585
|
} else {
|
|
3535
|
-
const
|
|
3586
|
+
const S = {
|
|
3536
3587
|
unitId: h,
|
|
3537
3588
|
subUnitId: l,
|
|
3538
|
-
cfId:
|
|
3589
|
+
cfId: g.cfId
|
|
3539
3590
|
};
|
|
3540
|
-
p.push({ id:
|
|
3591
|
+
p.push({ id: we.id, params: S }), y.push(...$e(this._injector, S));
|
|
3541
3592
|
}
|
|
3542
3593
|
}
|
|
3543
3594
|
}), {
|
|
3544
|
-
undos:
|
|
3595
|
+
undos: y,
|
|
3545
3596
|
redos: p
|
|
3546
3597
|
};
|
|
3547
3598
|
}, i = {
|
|
3548
3599
|
id: st,
|
|
3549
3600
|
onStatusChange: (s) => {
|
|
3550
|
-
var o,
|
|
3601
|
+
var o, u, a;
|
|
3551
3602
|
switch (s) {
|
|
3552
|
-
case
|
|
3553
|
-
case
|
|
3554
|
-
const h = (o = this._univerInstanceService.getCurrentUnitForType(
|
|
3555
|
-
h && l &&
|
|
3603
|
+
case Ut.INFINITE:
|
|
3604
|
+
case Ut.ONCE: {
|
|
3605
|
+
const h = (o = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET)) == null ? void 0 : o.getUnitId(), l = (a = (u = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET)) == null ? void 0 : u.getActiveSheet()) == null ? void 0 : a.getSheetId(), d = this._sheetsSelectionsService.getCurrentLastSelection(), v = d == null ? void 0 : d.range;
|
|
3606
|
+
h && l && v && (this._painterConfig = { unitId: h, subUnitId: l, range: v });
|
|
3556
3607
|
break;
|
|
3557
3608
|
}
|
|
3558
|
-
case
|
|
3609
|
+
case Ut.OFF: {
|
|
3559
3610
|
this._painterConfig = null;
|
|
3560
3611
|
break;
|
|
3561
3612
|
}
|
|
3562
3613
|
}
|
|
3563
3614
|
},
|
|
3564
|
-
onApply: (s, o,
|
|
3615
|
+
onApply: (s, o, u) => this._painterConfig ? n(s, o, u) : {
|
|
3565
3616
|
redos: [],
|
|
3566
3617
|
undos: []
|
|
3567
3618
|
}
|
|
@@ -3569,52 +3620,52 @@ let xt = class extends ce {
|
|
|
3569
3620
|
this._formatPainterService.addHook(i);
|
|
3570
3621
|
}
|
|
3571
3622
|
};
|
|
3572
|
-
|
|
3573
|
-
|
|
3574
|
-
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
],
|
|
3580
|
-
var
|
|
3581
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
3623
|
+
Tt = ms([
|
|
3624
|
+
De(0, P(fe)),
|
|
3625
|
+
De(1, P(Z)),
|
|
3626
|
+
De(2, P(li)),
|
|
3627
|
+
De(3, P(je)),
|
|
3628
|
+
De(4, P(Q)),
|
|
3629
|
+
De(5, P(it))
|
|
3630
|
+
], Tt);
|
|
3631
|
+
var ps = Object.getOwnPropertyDescriptor, Cs = (t, e, r, n) => {
|
|
3632
|
+
for (var i = n > 1 ? void 0 : n ? ps(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
3582
3633
|
(o = t[s]) && (i = o(i) || i);
|
|
3583
3634
|
return i;
|
|
3584
3635
|
}, $t = (t, e) => (r, n) => e(r, n, t);
|
|
3585
|
-
let
|
|
3636
|
+
let xt = class extends ue {
|
|
3586
3637
|
constructor(t, e, r) {
|
|
3587
3638
|
super(), this._conditionalFormattingViewModel = t, this._univerInstanceService = e, this._renderManagerService = r, this._init();
|
|
3588
3639
|
}
|
|
3589
3640
|
_init() {
|
|
3590
|
-
const t = this._univerInstanceService.getCurrentUnitForType(
|
|
3641
|
+
const t = this._univerInstanceService.getCurrentUnitForType(A.UNIVER_SHEET), e = (r) => {
|
|
3591
3642
|
const n = r.getUnitId(), i = this._renderManagerService.getRenderById(n);
|
|
3592
3643
|
if (!i)
|
|
3593
3644
|
return;
|
|
3594
|
-
const s = i.with(
|
|
3645
|
+
const s = i.with(Un);
|
|
3595
3646
|
this.disposeWithMe(s.currentSkeleton$.subscribe((o) => {
|
|
3596
3647
|
if (o) {
|
|
3597
|
-
const
|
|
3598
|
-
this._conditionalFormattingViewModel.setCacheLength(
|
|
3648
|
+
const u = o.skeleton.rowColumnSegment, a = u.endColumn - u.startColumn + 1, l = (u.endRow - u.startRow + 1) * a * 9, d = Math.max(Nr, l);
|
|
3649
|
+
this._conditionalFormattingViewModel.setCacheLength(d);
|
|
3599
3650
|
}
|
|
3600
3651
|
}));
|
|
3601
3652
|
};
|
|
3602
|
-
t && e(t), this._univerInstanceService.getCurrentTypeOfUnit$(
|
|
3653
|
+
t && e(t), this._univerInstanceService.getCurrentTypeOfUnit$(A.UNIVER_SHEET).subscribe((r) => {
|
|
3603
3654
|
r && e(r);
|
|
3604
3655
|
});
|
|
3605
3656
|
}
|
|
3606
3657
|
};
|
|
3607
|
-
|
|
3608
|
-
$t(0,
|
|
3609
|
-
$t(1,
|
|
3610
|
-
$t(2,
|
|
3611
|
-
],
|
|
3612
|
-
var
|
|
3613
|
-
for (var i = n > 1 ? void 0 : n ?
|
|
3658
|
+
xt = Cs([
|
|
3659
|
+
$t(0, P(it)),
|
|
3660
|
+
$t(1, Z),
|
|
3661
|
+
$t(2, On)
|
|
3662
|
+
], xt);
|
|
3663
|
+
var ys = Object.defineProperty, bs = Object.getOwnPropertyDescriptor, Is = (t, e, r) => e in t ? ys(t, e, { enumerable: !0, configurable: !0, writable: !0, value: r }) : t[e] = r, Ss = (t, e, r, n) => {
|
|
3664
|
+
for (var i = n > 1 ? void 0 : n ? bs(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
3614
3665
|
(o = t[s]) && (i = o(i) || i);
|
|
3615
3666
|
return i;
|
|
3616
|
-
},
|
|
3617
|
-
let Et = class extends
|
|
3667
|
+
}, At = (t, e) => (r, n) => e(r, n, t), sr = (t, e, r) => Is(t, typeof e != "symbol" ? e + "" : e, r);
|
|
3668
|
+
let Et = class extends bn {
|
|
3618
3669
|
constructor(t = bt, e, r, n) {
|
|
3619
3670
|
super(), this._config = t, this._injector = e, this._commandService = r, this._configService = n;
|
|
3620
3671
|
const { menu: i, ...s } = In(
|
|
@@ -3622,82 +3673,82 @@ let Et = class extends Sn {
|
|
|
3622
3673
|
bt,
|
|
3623
3674
|
this._config
|
|
3624
3675
|
);
|
|
3625
|
-
i && this._configService.setConfig("menu", i, { merge: !0 }), this._configService.setConfig(
|
|
3676
|
+
i && this._configService.setConfig("menu", i, { merge: !0 }), this._configService.setConfig(rr, s), this._initCommand();
|
|
3626
3677
|
}
|
|
3627
3678
|
onStarting() {
|
|
3628
|
-
|
|
3679
|
+
mr(this._injector, [
|
|
3629
3680
|
[rt],
|
|
3630
3681
|
[nt],
|
|
3631
3682
|
[et],
|
|
3632
|
-
[
|
|
3683
|
+
[St],
|
|
3633
3684
|
[tt],
|
|
3634
3685
|
[Qe],
|
|
3635
3686
|
[Rt],
|
|
3636
|
-
[
|
|
3637
|
-
[
|
|
3687
|
+
[He],
|
|
3688
|
+
[wt],
|
|
3638
3689
|
[_t],
|
|
3639
|
-
[
|
|
3640
|
-
[
|
|
3641
|
-
]),
|
|
3690
|
+
[Tt],
|
|
3691
|
+
[xt]
|
|
3692
|
+
]), kt(this._injector, [
|
|
3642
3693
|
[rt]
|
|
3643
3694
|
]);
|
|
3644
3695
|
}
|
|
3645
3696
|
onReady() {
|
|
3646
|
-
|
|
3697
|
+
kt(this._injector, [
|
|
3647
3698
|
[Rt],
|
|
3648
3699
|
[Qe]
|
|
3649
3700
|
]);
|
|
3650
3701
|
}
|
|
3651
3702
|
onRendered() {
|
|
3652
|
-
|
|
3653
|
-
[
|
|
3703
|
+
kt(this._injector, [
|
|
3704
|
+
[St],
|
|
3654
3705
|
[_t],
|
|
3655
3706
|
[et],
|
|
3707
|
+
[wt],
|
|
3708
|
+
[He],
|
|
3656
3709
|
[Tt],
|
|
3657
|
-
[De],
|
|
3658
|
-
[xt],
|
|
3659
3710
|
[tt],
|
|
3660
3711
|
[nt],
|
|
3661
|
-
[
|
|
3712
|
+
[xt]
|
|
3662
3713
|
]);
|
|
3663
3714
|
}
|
|
3664
3715
|
_initCommand() {
|
|
3665
3716
|
[
|
|
3666
3717
|
Dn,
|
|
3667
3718
|
$n,
|
|
3668
|
-
|
|
3719
|
+
An,
|
|
3669
3720
|
Hn,
|
|
3721
|
+
jn,
|
|
3670
3722
|
Bn,
|
|
3671
3723
|
Wn,
|
|
3672
3724
|
qn,
|
|
3673
3725
|
Gn,
|
|
3674
|
-
|
|
3675
|
-
kt
|
|
3726
|
+
Vt
|
|
3676
3727
|
].forEach((t) => {
|
|
3677
3728
|
this._commandService.registerCommand(t);
|
|
3678
3729
|
});
|
|
3679
3730
|
}
|
|
3680
3731
|
};
|
|
3681
|
-
|
|
3682
|
-
|
|
3683
|
-
Et =
|
|
3684
|
-
|
|
3685
|
-
|
|
3686
|
-
|
|
3687
|
-
|
|
3732
|
+
sr(Et, "pluginName", `${st}_UI_PLUGIN`);
|
|
3733
|
+
sr(Et, "type", A.UNIVER_SHEET);
|
|
3734
|
+
Et = Ss([
|
|
3735
|
+
Cn(xn),
|
|
3736
|
+
At(1, P(fe)),
|
|
3737
|
+
At(2, P(te)),
|
|
3738
|
+
At(3, yn)
|
|
3688
3739
|
], Et);
|
|
3689
3740
|
export {
|
|
3690
3741
|
Dn as AddAverageCfCommand,
|
|
3691
3742
|
$n as AddColorScaleConditionalRuleCommand,
|
|
3692
|
-
|
|
3743
|
+
An as AddDataBarConditionalRuleCommand,
|
|
3693
3744
|
Hn as AddDuplicateValuesCfCommand,
|
|
3694
|
-
|
|
3695
|
-
|
|
3696
|
-
|
|
3697
|
-
|
|
3698
|
-
|
|
3745
|
+
jn as AddNumberCfCommand,
|
|
3746
|
+
Bn as AddRankCfCommand,
|
|
3747
|
+
Wn as AddTextCfCommand,
|
|
3748
|
+
qn as AddTimePeriodCfCommand,
|
|
3749
|
+
Gn as AddUniqueValuesCfCommand,
|
|
3699
3750
|
_t as ConditionalFormattingClearController,
|
|
3700
|
-
|
|
3701
|
-
|
|
3751
|
+
Vt as OpenConditionalFormattingOperator,
|
|
3752
|
+
It as UniverSheetsConditionalFormattingMobileUIPlugin,
|
|
3702
3753
|
Et as UniverSheetsConditionalFormattingUIPlugin
|
|
3703
3754
|
};
|