@univerjs-pro/sheets-sparkline 0.6.3 → 0.6.4
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/facade.js +1 -1
- package/lib/cjs/index.js +1 -1
- package/lib/es/facade.js +1 -1
- package/lib/es/index.js +1 -1
- package/lib/types/facade/f-event.d.ts +5 -2
- package/lib/types/facade/f-sparkline-group.d.ts +49 -19
- package/lib/types/facade/f-sparkline.d.ts +23 -18
- package/lib/types/facade/f-worksheet.d.ts +84 -52
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +1 -1
- package/package.json +5 -5
|
@@ -16,111 +16,143 @@ export interface IFWorksheetSparklineMixin {
|
|
|
16
16
|
*
|
|
17
17
|
* @example
|
|
18
18
|
* ```ts
|
|
19
|
-
* const
|
|
20
|
-
* const
|
|
21
|
-
*
|
|
22
|
-
* const sparkline = worksheet.addSparkline(
|
|
23
|
-
* [{ startRow: 0, endRow: 6, startColumn: 0, endColumn: 0 }],
|
|
24
|
-
* [{ startRow: 9, endRow: 9, startColumn: 0, endColumn: 0 }]
|
|
25
|
-
* );
|
|
19
|
+
* const fWorkbook = univerAPI.getActiveWorkbook();
|
|
20
|
+
* const fWorksheet = fWorkbook.getActiveSheet();
|
|
26
21
|
*
|
|
22
|
+
* // Create a sparkline in the range A10, with the data source in the range A1:A7.
|
|
23
|
+
* const sourceRanges = [fWorksheet.getRange('A1:A7').getRange()];
|
|
24
|
+
* const targetRanges = [fWorksheet.getRange('A10').getRange()];
|
|
25
|
+
* const sparkline = fWorksheet.addSparkline(sourceRanges, targetRanges, univerAPI.Enum.SparklineTypeEnum.LINE_CHART);
|
|
27
26
|
* console.log('sparkline instance', sparkline);
|
|
28
27
|
* ```
|
|
29
28
|
*/
|
|
30
29
|
addSparkline(sourceRanges: IRange[], targetRanges: IRange[], type: SparklineTypeEnum.LINE_CHART): FSparkline | undefined;
|
|
31
30
|
/**
|
|
32
31
|
* @description Get all sparklines in the worksheet.
|
|
33
|
-
* @returns {Map<string, ISparklineGroup> | undefined}
|
|
32
|
+
* @returns {Map<string, ISparklineGroup> | undefined} - The key is sparkline group id.
|
|
34
33
|
*
|
|
35
34
|
* @example
|
|
36
35
|
* ```ts
|
|
37
|
-
* const
|
|
38
|
-
* const
|
|
36
|
+
* const fWorkbook = univerAPI.getActiveWorkbook();
|
|
37
|
+
* const fWorksheet = fWorkbook.getActiveSheet();
|
|
39
38
|
*
|
|
40
|
-
*
|
|
39
|
+
* // Get all sparklines in the current worksheet
|
|
40
|
+
* const allSparkline = fWorksheet.getAllSubSparkline();
|
|
41
41
|
* console.log('allSparkline', allSparkline);
|
|
42
42
|
* ```
|
|
43
43
|
*/
|
|
44
44
|
getAllSubSparkline(): Map<string, ISparklineGroup> | undefined;
|
|
45
45
|
/**
|
|
46
46
|
* @description Group the sparklines in the selection into a new sparkline group
|
|
47
|
-
* @param {IRange[]} ranges
|
|
47
|
+
* @param {IRange[]} ranges - The selection range to be grouped
|
|
48
48
|
* @returns {void}
|
|
49
49
|
*
|
|
50
50
|
* @example
|
|
51
51
|
* ```ts
|
|
52
|
-
* const
|
|
53
|
-
* const
|
|
52
|
+
* const fWorkbook = univerAPI.getActiveWorkbook();
|
|
53
|
+
* const fWorksheet = fWorkbook.getActiveSheet();
|
|
54
54
|
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
* [
|
|
55
|
+
* // Create a sparkline in the range A10, with the data source in the range A1:A7.
|
|
56
|
+
* const firstSparkline = fWorksheet.addSparkline(
|
|
57
|
+
* [fWorksheet.getRange('A1:A7').getRange()],
|
|
58
|
+
* [fWorksheet.getRange('A10').getRange()]
|
|
58
59
|
* );
|
|
59
|
-
*
|
|
60
|
-
* const secondSparkline =
|
|
61
|
-
* [
|
|
62
|
-
* [
|
|
60
|
+
* // Create a sparkline in the range B10, with the data source in the range B1:B7.
|
|
61
|
+
* const secondSparkline = fWorksheet.addSparkline(
|
|
62
|
+
* [fWorksheet.getRange('B1:B7').getRange()],
|
|
63
|
+
* [fWorksheet.getRange('B10').getRange()]
|
|
63
64
|
* );
|
|
65
|
+
* console.log('debugger', fWorksheet.getAllSubSparkline().size); // 2
|
|
64
66
|
*
|
|
65
|
-
* //
|
|
66
|
-
*
|
|
67
|
-
*
|
|
68
|
-
*
|
|
69
|
-
*
|
|
70
|
-
* // After compose, there will only be one sparkline
|
|
71
|
-
* const allSparklineAfterCompose = worksheet.getAllSubSparkline();
|
|
72
|
-
* console.log('debugger', allSparklineBeforeCompose, allSparklineAfterCompose);
|
|
67
|
+
* // Compose the two sparklines into one group after 3 seconds
|
|
68
|
+
* setTimeout(() => {
|
|
69
|
+
* fWorksheet.composeSparkline([fWorksheet.getRange('A10:B10').getRange()]);
|
|
70
|
+
* console.log('debugger', fWorksheet.getAllSubSparkline().size); // 1
|
|
71
|
+
* }, 3000);
|
|
73
72
|
* ```
|
|
74
73
|
*/
|
|
75
74
|
composeSparkline(ranges: IRange[]): void;
|
|
76
75
|
/**
|
|
77
76
|
* @description Split the sparkline group within the current selection
|
|
78
|
-
* @param {IRange[]} ranges
|
|
79
|
-
* @returns {void}
|
|
77
|
+
* @param {IRange[]} ranges - The selection range to be ungrouped
|
|
80
78
|
*
|
|
81
79
|
* @example
|
|
82
80
|
* ```ts
|
|
83
|
-
*
|
|
84
|
-
* const
|
|
85
|
-
* const worksheet = workbook.getActiveSheet();
|
|
81
|
+
* const fWorkbook = univerAPI.getActiveWorkbook();
|
|
82
|
+
* const fWorksheet = fWorkbook.getActiveSheet();
|
|
86
83
|
*
|
|
87
|
-
* //
|
|
88
|
-
* const
|
|
89
|
-
*
|
|
90
|
-
*
|
|
84
|
+
* // Create a sparkline in the range A10, with the data source in the range A1:A7.
|
|
85
|
+
* const firstSparkline = fWorksheet.addSparkline(
|
|
86
|
+
* [fWorksheet.getRange('A1:A7').getRange()],
|
|
87
|
+
* [fWorksheet.getRange('A10').getRange()]
|
|
88
|
+
* );
|
|
89
|
+
* // Create a sparkline in the range B10, with the data source in the range B1:B7.
|
|
90
|
+
* const secondSparkline = fWorksheet.addSparkline(
|
|
91
|
+
* [fWorksheet.getRange('B1:B7').getRange()],
|
|
92
|
+
* [fWorksheet.getRange('B10').getRange()]
|
|
93
|
+
* );
|
|
91
94
|
*
|
|
92
|
-
* //
|
|
93
|
-
*
|
|
95
|
+
* // Compose the two sparklines into one group
|
|
96
|
+
* fWorksheet.composeSparkline([fWorksheet.getRange('A10:B10').getRange()]);
|
|
97
|
+
* console.log('debugger', fWorksheet.getAllSubSparkline().size); // 1
|
|
94
98
|
*
|
|
95
|
-
*
|
|
99
|
+
* // Uncompose the sparkline group after 3 seconds
|
|
100
|
+
* setTimeout(() => {
|
|
101
|
+
* fWorksheet.unComposeSparkline([fWorksheet.getRange('A10:B10').getRange()]);
|
|
102
|
+
* console.log('debugger', fWorksheet.getAllSubSparkline().size); // 2
|
|
103
|
+
* }, 3000);
|
|
96
104
|
* ```
|
|
97
105
|
*/
|
|
98
106
|
unComposeSparkline(ranges: IRange[]): void;
|
|
99
107
|
/**
|
|
100
108
|
* @description Get the sparkline instance of the current cell
|
|
101
|
-
* @param {number} row
|
|
102
|
-
* @param {number} col
|
|
109
|
+
* @param {number} row - The row index of the cell, start at 0.
|
|
110
|
+
* @param {number} col - The column index of the cell, start at 0.
|
|
103
111
|
* @returns {FSparkline | undefined} Returns the sparkline instance for the next call
|
|
104
112
|
*
|
|
105
113
|
* @example
|
|
106
114
|
* ```ts
|
|
107
|
-
* const
|
|
108
|
-
* const
|
|
109
|
-
*
|
|
115
|
+
* const fWorkbook = univerAPI.getActiveWorkbook();
|
|
116
|
+
* const fWorksheet = fWorkbook.getActiveSheet();
|
|
117
|
+
*
|
|
118
|
+
* // Create a sparkline in the range A10, with the data source in the range A1:A7.
|
|
119
|
+
* const sourceRanges = [fWorksheet.getRange('A1:A7').getRange()];
|
|
120
|
+
* const targetRanges = [fWorksheet.getRange('A10').getRange()];
|
|
121
|
+
* const sparkline = fWorksheet.addSparkline(sourceRanges, targetRanges);
|
|
122
|
+
*
|
|
123
|
+
* console.log('Cell A10: ', fWorksheet.getSparklineByCell(9, 0));
|
|
124
|
+
* console.log('Cell A11: ', fWorksheet.getSparklineByCell(10, 0));
|
|
110
125
|
* ```
|
|
111
126
|
*/
|
|
112
127
|
getSparklineByCell(row: number, col: number): FSparkline | undefined;
|
|
113
128
|
/**
|
|
114
129
|
* @description Get the sparkline groups instance of the current cell
|
|
115
|
-
* @param {number} row
|
|
116
|
-
* @param {number} col
|
|
117
|
-
* @returns {FSparklineGroup | undefined}
|
|
130
|
+
* @param {number} row - The row index of the cell, start at 0.
|
|
131
|
+
* @param {number} col - The column index of the cell, start at 0.
|
|
132
|
+
* @returns {FSparklineGroup | undefined} Returns the sparkline group instance for the next call
|
|
118
133
|
*
|
|
119
134
|
* @example
|
|
120
135
|
* ```ts
|
|
121
|
-
* const
|
|
122
|
-
* const
|
|
123
|
-
*
|
|
136
|
+
* const fWorkbook = univerAPI.getActiveWorkbook();
|
|
137
|
+
* const fWorksheet = fWorkbook.getActiveSheet();
|
|
138
|
+
*
|
|
139
|
+
* // Create a sparkline in the range A10, with the data source in the range A1:A7.
|
|
140
|
+
* const firstSparkline = fWorksheet.addSparkline(
|
|
141
|
+
* [fWorksheet.getRange('A1:A7').getRange()],
|
|
142
|
+
* [fWorksheet.getRange('A10').getRange()]
|
|
143
|
+
* );
|
|
144
|
+
* // Create a sparkline in the range B10, with the data source in the range B1:B7.
|
|
145
|
+
* const secondSparkline = fWorksheet.addSparkline(
|
|
146
|
+
* [fWorksheet.getRange('B1:B7').getRange()],
|
|
147
|
+
* [fWorksheet.getRange('B10').getRange()]
|
|
148
|
+
* );
|
|
149
|
+
* console.log('Cell A10: ', fWorksheet.getSparklineGroupByCell(9, 0));
|
|
150
|
+
*
|
|
151
|
+
* // Compose the two sparklines into one group after 3 seconds
|
|
152
|
+
* setTimeout(() => {
|
|
153
|
+
* fWorksheet.composeSparkline([fWorksheet.getRange('A10:B10').getRange()]);
|
|
154
|
+
* console.log('Cell A10: ', fWorksheet.getSparklineGroupByCell(9, 0));
|
|
155
|
+
* }, 3000);
|
|
124
156
|
* ```
|
|
125
157
|
*/
|
|
126
158
|
getSparklineGroupByCell(row: number, col: number): FSparklineGroup | undefined;
|
package/lib/umd/facade.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
function _0x206f(_0x35c59a,_0x254726){const _0x5e14dc=_0x5e14();return _0x206f=function(_0x206f4a,_0x3ca91d){_0x206f4a=_0x206f4a-0x1ac;let _0x54b5fd=_0x5e14dc[_0x206f4a];return _0x54b5fd;},_0x206f(_0x35c59a,_0x254726);}function _0x5e14(){const _0x16d07b=['ICommandService','2plUawQ','SheetsSelectionsService','1341999ZrRGtm','length','getSparklineByCell','SetSheetSparklineCommand','cancel','function','toStringTag','745165KFrhdC','_unitId','_col','syncExecuteCommand','@univerjs-pro/sheets-sparkline','_worksheet','exports','defineProperty','@univerjs/core/facade','Inject','_initialize','getUnitId','_subUnitId','ranges','_injector','76BtmAmL','SheetSparklineChanged','Tools','@univerjs/sheets','range','12772956yINPLC','FWorksheet','getSparkline','getActiveWorkbook','SparklineTypeEnum','FEventName','getSparklineGroupByCell','amd','startRow','_workbook','getSubUnitSparkline','deepClone','UniverCore','FUniver','getOwnPropertyDescriptor','object','UniverProSheetsSparkline','Event','extend','getSparklineById','Injector','FSparklineGroup','RemoveSheetSparklineCommand','56wzXPBm','get','composeSparkline','UniverCoreFacade','AddSheetSparklineCommand','getActiveSheet','removeSparklineGroup','createInstance','SparklineDataSourceModel','FEnum','50iUUoaI','unComposeSparkline','60722yLzKEo','forEach','from','_groupId','Sheet\x20create\x20canceled\x20by\x20facade\x20api.','filter','executeCommand','@univerjs/sheets/facade','18vGOwwV','UniverSheetsFacade','fireEvent','sparklines','_row','changeDataSource','82659LiMaIl','item','startColumn','getSheetId','_commandService','map','getValue','700525XFihDt','1644599OCxFXj','FSparkline','registerEventHandler','@univerjs/core'];_0x5e14=function(){return _0x16d07b;};return _0x5e14();}(function(_0x20cf88,_0x5b1327){const _0x47cc95=_0x206f,_0x2bc95b=_0x20cf88();while(!![]){try{const _0xe6133d=-parseInt(_0x47cc95(0x1fe))/0x1*(-parseInt(_0x47cc95(0x1e3))/0x2)+-parseInt(_0x47cc95(0x1f1))/0x3*(parseInt(_0x47cc95(0x1bb))/0x4)+-parseInt(_0x47cc95(0x1ac))/0x5*(-parseInt(_0x47cc95(0x1eb))/0x6)+-parseInt(_0x47cc95(0x1f8))/0x7*(parseInt(_0x47cc95(0x1d7))/0x8)+-parseInt(_0x47cc95(0x200))/0x9+parseInt(_0x47cc95(0x1e1))/0xa*(parseInt(_0x47cc95(0x1f9))/0xb)+parseInt(_0x47cc95(0x1c0))/0xc;if(_0xe6133d===_0x5b1327)break;else _0x2bc95b['push'](_0x2bc95b['shift']());}catch(_0xff0365){_0x2bc95b['push'](_0x2bc95b['shift']());}}}(_0x5e14,0xe71cc),function(_0x375a42,_0x255993){const _0x554ee5=_0x206f;typeof exports==_0x554ee5(0x1cf)&&typeof module<'u'?_0x255993(exports,require(_0x554ee5(0x1b0)),require(_0x554ee5(0x1fc)),require(_0x554ee5(0x1ea)),require(_0x554ee5(0x1b4)),require('@univerjs/sheets')):typeof define==_0x554ee5(0x205)&&define[_0x554ee5(0x1c7)]?define([_0x554ee5(0x1b2),_0x554ee5(0x1b0),_0x554ee5(0x1fc),_0x554ee5(0x1ea),'@univerjs/core/facade',_0x554ee5(0x1be)],_0x255993):(_0x375a42=typeof globalThis<'u'?globalThis:_0x375a42||self,_0x255993(_0x375a42['UniverProSheetsSparklineFacade']={},_0x375a42[_0x554ee5(0x1d0)],_0x375a42[_0x554ee5(0x1cc)],_0x375a42[_0x554ee5(0x1ec)],_0x375a42[_0x554ee5(0x1da)],_0x375a42['UniverSheets']));}(this,function(_0x4bd2bc,_0x22d1cf,_0x35f1ef,_0x4d7268,_0x2d4f9f,_0xd47051){'use strict';const _0x26ba76=_0x206f;var _0xf0693b=Object[_0x26ba76(0x1ce)],_0x3e5b70=(_0x32ffbe,_0x19c2a3,_0x13a83d,_0x53b683)=>{const _0x5638f9=_0x26ba76;for(var _0x144f54=_0x53b683>0x1?void 0x0:_0x53b683?_0xf0693b(_0x19c2a3,_0x13a83d):_0x19c2a3,_0x358037=_0x32ffbe[_0x5638f9(0x201)]-0x1,_0x3c28f2;_0x358037>=0x0;_0x358037--)(_0x3c28f2=_0x32ffbe[_0x358037])&&(_0x144f54=_0x3c28f2(_0x144f54)||_0x144f54);return _0x144f54;},_0x5d2ec0=(_0xb56159,_0x175f6b)=>(_0x3ef15c,_0x206dec)=>_0x175f6b(_0x3ef15c,_0x206dec,_0xb56159);_0x4bd2bc[_0x26ba76(0x1fa)]=class{constructor(_0x2c65d1,_0x5cc383,_0x5267ce,_0x3c14c8,_0x1bd4b2,_0x33ea6d){const _0x489ef8=_0x26ba76;this[_0x489ef8(0x1ad)]=_0x2c65d1,this['_subUnitId']=_0x5cc383,this[_0x489ef8(0x1e6)]=_0x5267ce,this[_0x489ef8(0x1ef)]=_0x3c14c8,this[_0x489ef8(0x1ae)]=_0x1bd4b2,this[_0x489ef8(0x1ba)]=_0x33ea6d;}[_0x26ba76(0x1f0)](_0x56fe8a,_0x7e1d44){const _0x85b6f1=_0x26ba76,_0x32c3b6=this[_0x85b6f1(0x1ba)][_0x85b6f1(0x1d8)](_0x22d1cf[_0x85b6f1(0x1df)]),_0x981fd=this[_0x85b6f1(0x1ba)][_0x85b6f1(0x1d8)](_0x35f1ef[_0x85b6f1(0x1fd)]),_0x4af48e=_0x32c3b6['getSparklineById'](this[_0x85b6f1(0x1ad)],this[_0x85b6f1(0x1b8)],this[_0x85b6f1(0x1e6)]);if(!_0x4af48e)return;const _0x226ba1={'config':_0x4af48e,'isChangeDataSource':!0x0,'changeDataSourceInfo':{'groupId':this[_0x85b6f1(0x1e6)],'resetType':_0x85b6f1(0x1f2),'sourceRanges':[_0x56fe8a],'targetRanges':[_0x7e1d44],'primary':{'startRow':this[_0x85b6f1(0x1ef)],'startColumn':this[_0x85b6f1(0x1ae)],'endRow':this[_0x85b6f1(0x1ef)],'endColumn':this[_0x85b6f1(0x1ae)],'actualRow':this[_0x85b6f1(0x1ef)],'actualColumn':this[_0x85b6f1(0x1ae)],'isMerged':!0x1,'isMergedMainCell':!0x1}}};return _0x981fd[_0x85b6f1(0x1af)](_0x22d1cf[_0x85b6f1(0x203)]['id'],_0x226ba1),this['_row']=_0x7e1d44[_0x85b6f1(0x1c8)],this[_0x85b6f1(0x1ae)]=_0x7e1d44[_0x85b6f1(0x1f3)],this;}['removeSparkline'](){const _0xb7e788=_0x26ba76,_0x13cb16=this['_injector'][_0xb7e788(0x1d8)](_0x35f1ef[_0xb7e788(0x1fd)]),_0x1d642a={'isSingle':!0x0,'ranges':[{'startRow':this[_0xb7e788(0x1ef)],'startColumn':this['_col'],'endRow':this[_0xb7e788(0x1ef)],'endColumn':this[_0xb7e788(0x1ae)]}]};_0x13cb16[_0xb7e788(0x1af)](_0x22d1cf[_0xb7e788(0x1d6)]['id'],_0x1d642a);}},_0x4bd2bc[_0x26ba76(0x1fa)]=_0x3e5b70([_0x5d2ec0(0x5,_0x35f1ef['Inject'](_0x35f1ef[_0x26ba76(0x1d4)]))],_0x4bd2bc[_0x26ba76(0x1fa)]);var _0x55d97b=Object[_0x26ba76(0x1ce)],_0x57387e=(_0x41f30f,_0x15b9e3,_0x110bb9,_0x45d9c4)=>{const _0x2c49c6=_0x26ba76;for(var _0x14d572=_0x45d9c4>0x1?void 0x0:_0x45d9c4?_0x55d97b(_0x15b9e3,_0x110bb9):_0x15b9e3,_0x1797e7=_0x41f30f[_0x2c49c6(0x201)]-0x1,_0x2af99d;_0x1797e7>=0x0;_0x1797e7--)(_0x2af99d=_0x41f30f[_0x1797e7])&&(_0x14d572=_0x2af99d(_0x14d572)||_0x14d572);return _0x14d572;},_0x53d283=(_0x532ef8,_0x457ff6)=>(_0x316241,_0x2fac43)=>_0x457ff6(_0x316241,_0x2fac43,_0x532ef8);_0x4bd2bc['FSparklineGroup']=class{constructor(_0x18f75b,_0x3df8f5,_0xdeafd5,_0x2699f8,_0x494488,_0x1ad208){const _0x840346=_0x26ba76;this[_0x840346(0x1ad)]=_0x18f75b,this[_0x840346(0x1b8)]=_0x3df8f5,this[_0x840346(0x1e6)]=_0xdeafd5,this['_row']=_0x2699f8,this[_0x840346(0x1ae)]=_0x494488,this[_0x840346(0x1ba)]=_0x1ad208;}[_0x26ba76(0x1f0)](_0x1e3f4d,_0x486d02){const _0x91bb40=_0x26ba76,_0x836f85=this[_0x91bb40(0x1ba)][_0x91bb40(0x1d8)](_0x22d1cf[_0x91bb40(0x1df)]),_0x4afa2d=this[_0x91bb40(0x1ba)][_0x91bb40(0x1d8)](_0x35f1ef[_0x91bb40(0x1fd)]),_0x4cffa0=_0x836f85[_0x91bb40(0x1d3)](this[_0x91bb40(0x1ad)],this[_0x91bb40(0x1b8)],this[_0x91bb40(0x1e6)]);if(!_0x4cffa0)return;const _0x44eff0={'config':_0x4cffa0,'isChangeDataSource':!0x0,'changeDataSourceInfo':{'groupId':this['_groupId'],'resetType':'group','sourceRanges':_0x1e3f4d,'targetRanges':_0x486d02,'primary':{'startRow':this['_row'],'startColumn':this[_0x91bb40(0x1ae)],'endRow':this[_0x91bb40(0x1ef)],'endColumn':this['_col'],'actualRow':this[_0x91bb40(0x1ef)],'actualColumn':this['_col'],'isMerged':!0x1,'isMergedMainCell':!0x1}}};return _0x4afa2d[_0x91bb40(0x1af)](_0x22d1cf['SetSheetSparklineCommand']['id'],_0x44eff0),this[_0x91bb40(0x1ef)]=_0x486d02[0x0][_0x91bb40(0x1c8)],this['_col']=_0x486d02[0x0]['startColumn'],this;}[_0x26ba76(0x1dd)](){const _0x421ff3=_0x26ba76,_0x13c7cd=this[_0x421ff3(0x1ba)][_0x421ff3(0x1d8)](_0x35f1ef[_0x421ff3(0x1fd)]),_0x28495c={'isSingle':!0x1,'ranges':[{'startRow':this[_0x421ff3(0x1ef)],'startColumn':this[_0x421ff3(0x1ae)],'endRow':this['_row'],'endColumn':this['_col']}]};_0x13c7cd[_0x421ff3(0x1af)](_0x22d1cf[_0x421ff3(0x1d6)]['id'],_0x28495c);}['setConfig'](_0x2883ea){const _0x493863=_0x26ba76,_0x6c3a2a=this[_0x493863(0x1ba)]['get'](_0x22d1cf[_0x493863(0x1df)])['getSparklineById'](this['_unitId'],this[_0x493863(0x1b8)],this[_0x493863(0x1e6)]);if(_0x6c3a2a){const _0xbe8831={'config':{'config':_0x2883ea,'sparklines':_0x6c3a2a[_0x493863(0x1ee)]},'isChangeDataSource':!0x1};this[_0x493863(0x1ba)]['get'](_0x35f1ef[_0x493863(0x1fd)])[_0x493863(0x1af)](_0x22d1cf[_0x493863(0x203)]['id'],_0xbe8831);}return this;}},_0x4bd2bc[_0x26ba76(0x1d5)]=_0x57387e([_0x53d283(0x5,_0x35f1ef[_0x26ba76(0x1b5)](_0x35f1ef[_0x26ba76(0x1d4)]))],_0x4bd2bc[_0x26ba76(0x1d5)]);class _0x5b66d9 extends _0x4d7268[_0x26ba76(0x1c1)]{['addSparkline'](_0x31be67,_0x2344b5,_0x473599){const _0x35246c=_0x26ba76;if(this[_0x35246c(0x1f5)][_0x35246c(0x1af)](_0x22d1cf[_0x35246c(0x1db)]['id'],{'sourceRanges':_0x31be67,'targetRanges':_0x2344b5,'targetInfo':{'unitId':this[_0x35246c(0x1c9)]['getUnitId'](),'subUnitId':this['_worksheet']['getSheetId']()},'config':{'type':_0x473599}})){const {startRow:_0x5176f1,startColumn:_0x5cb7fa}=_0x2344b5[0x0];return this[_0x35246c(0x202)](_0x5176f1,_0x5cb7fa);}}['getAllSubSparkline'](){const _0x455f24=_0x26ba76;return this[_0x455f24(0x1ba)]['get'](_0x22d1cf[_0x455f24(0x1df)])[_0x455f24(0x1ca)](this['_workbook'][_0x455f24(0x1b7)](),this['_worksheet'][_0x455f24(0x1f4)]());}[_0x26ba76(0x1d9)](_0x165aa2){const _0x706514=_0x26ba76,_0x59bf3b=this[_0x706514(0x1ba)]['get'](_0x22d1cf[_0x706514(0x1df)]);let _0x305efe;for(let _0x3122da=0x0;_0x3122da<_0x165aa2[_0x706514(0x201)];_0x3122da++){const _0x5d6764=_0x165aa2[_0x3122da],{startRow:_0x21faa8,endRow:_0x72b48d,startColumn:_0xe70bdd,endColumn:_0x572737}=_0x5d6764;for(let _0x626f30=_0x21faa8;_0x626f30<=_0x72b48d;_0x626f30++)for(let _0xd2e5b4=_0xe70bdd;_0xd2e5b4<=_0x572737;_0xd2e5b4++){const _0x55458c=_0x59bf3b[_0x706514(0x1c2)](this[_0x706514(0x1c9)][_0x706514(0x1b7)](),this['_worksheet'][_0x706514(0x1f4)](),_0x626f30,_0xd2e5b4);if(_0x55458c){const _0x5e59f3=_0x59bf3b[_0x706514(0x1d3)](this[_0x706514(0x1c9)][_0x706514(0x1b7)](),this[_0x706514(0x1b1)][_0x706514(0x1f4)](),_0x55458c);if(_0x5e59f3){_0x305efe=_0x35f1ef[_0x706514(0x1bd)][_0x706514(0x1cb)](_0x5e59f3);break;}}}}_0x305efe&&this[_0x706514(0x1f5)]['executeCommand'](_0x22d1cf['SetSheetSparklineCommand']['id'],{'ranges':_0x165aa2,'combine':!0x0,'config':_0x305efe,'isChangeDataSource':!0x1});}[_0x26ba76(0x1e2)](_0x32e5ab){const _0x38ad62=_0x26ba76,_0x3208d2=this[_0x38ad62(0x1ba)][_0x38ad62(0x1d8)](_0x22d1cf['SparklineDataSourceModel']);let _0x209f28;for(let _0x4897eb=0x0;_0x4897eb<_0x32e5ab[_0x38ad62(0x201)];_0x4897eb++){const _0xfe2e7c=_0x32e5ab[_0x4897eb],{startRow:_0xa7cdee,endRow:_0x1ccfdd,startColumn:_0x580d64,endColumn:_0x552fb9}=_0xfe2e7c;for(let _0x24a3bd=_0xa7cdee;_0x24a3bd<=_0x1ccfdd;_0x24a3bd++)for(let _0x188d21=_0x580d64;_0x188d21<=_0x552fb9;_0x188d21++){const _0x4cffe7=_0x3208d2[_0x38ad62(0x1c2)](this[_0x38ad62(0x1c9)]['getUnitId'](),this[_0x38ad62(0x1b1)][_0x38ad62(0x1f4)](),_0x24a3bd,_0x188d21);if(_0x4cffe7){const _0x1e6dad=_0x3208d2[_0x38ad62(0x1d3)](this[_0x38ad62(0x1c9)]['getUnitId'](),this['_worksheet']['getSheetId'](),_0x4cffe7);if(_0x1e6dad){_0x209f28=_0x35f1ef[_0x38ad62(0x1bd)][_0x38ad62(0x1cb)](_0x1e6dad);break;}}}}_0x209f28||this[_0x38ad62(0x1f5)][_0x38ad62(0x1e9)](_0x22d1cf[_0x38ad62(0x203)]['id'],{'ranges':_0x32e5ab,'unCombine':!0x0,'config':_0x209f28,'isChangeDataSource':!0x1});}[_0x26ba76(0x202)](_0x3181eb,_0x102bc8){const _0x4c8c49=_0x26ba76,_0x1e47ce=this[_0x4c8c49(0x1ba)]['get'](_0x22d1cf[_0x4c8c49(0x1df)]),_0xf726e1=this['_workbook']['getUnitId'](),_0x432c59=this[_0x4c8c49(0x1b1)]['getSheetId'](),_0x1e4f48=_0x1e47ce[_0x4c8c49(0x1c2)](_0xf726e1,_0x432c59,_0x3181eb,_0x102bc8);if(_0x1e4f48)return this['_injector'][_0x4c8c49(0x1de)](_0x4bd2bc[_0x4c8c49(0x1fa)],_0xf726e1,_0x432c59,_0x1e4f48,_0x3181eb,_0x102bc8);}[_0x26ba76(0x1c6)](_0x3fc18a,_0x5dc4b4){const _0x5ec58b=_0x26ba76,_0x23b684=this[_0x5ec58b(0x1ba)][_0x5ec58b(0x1d8)](_0x22d1cf['SparklineDataSourceModel']),_0x28bdf0=this[_0x5ec58b(0x1c9)][_0x5ec58b(0x1b7)](),_0x461cef=this[_0x5ec58b(0x1b1)]['getSheetId'](),_0x1dbf97=_0x23b684[_0x5ec58b(0x1c2)](_0x28bdf0,_0x461cef,_0x3fc18a,_0x5dc4b4);if(_0x1dbf97)return this[_0x5ec58b(0x1ba)][_0x5ec58b(0x1de)](_0x4bd2bc[_0x5ec58b(0x1d5)],_0x28bdf0,_0x461cef,_0x1dbf97,_0x3fc18a,_0x5dc4b4);}}_0x4d7268[_0x26ba76(0x1c1)][_0x26ba76(0x1d2)](_0x5b66d9);class _0x2b786e extends _0x2d4f9f[_0x26ba76(0x1e0)]{get['SparklineTypeEnum'](){const _0x207e33=_0x26ba76;return _0x22d1cf[_0x207e33(0x1c4)];}}_0x2d4f9f[_0x26ba76(0x1e0)][_0x26ba76(0x1d2)](_0x2b786e);class _0x19d198 extends _0x2d4f9f[_0x26ba76(0x1c5)]{get[_0x26ba76(0x1bc)](){const _0x47593b=_0x26ba76;return _0x47593b(0x1bc);}}_0x2d4f9f[_0x26ba76(0x1c5)][_0x26ba76(0x1d2)](_0x19d198);class _0x2227aa extends _0x2d4f9f[_0x26ba76(0x1cd)]{[_0x26ba76(0x1b6)](_0x4b218d){const _0x207ef7=_0x26ba76,_0x16ac35=_0x4b218d[_0x207ef7(0x1d8)](_0x35f1ef[_0x207ef7(0x1fd)]);this[_0x207ef7(0x1fb)](this[_0x207ef7(0x1d1)][_0x207ef7(0x1bc)],()=>_0x16ac35['onCommandExecuted'](_0x2ad0b3=>{const _0x572e8a=_0x207ef7;var _0x1929f2,_0x2aea0b;if(_0x2ad0b3['id']===_0x22d1cf[_0x572e8a(0x203)]['id']){const _0x58b333=_0x2ad0b3['params'];if(!_0x58b333['isChangeDataSource']){const _0x1d42ac=this[_0x572e8a(0x1c3)](),_0x15e560=_0x1d42ac==null?void 0x0:_0x1d42ac[_0x572e8a(0x1dc)]();if(!_0x1d42ac||!_0x15e560)return;const _0x4335b0=_0x1d42ac['getId'](),_0x38dc34=_0x15e560[_0x572e8a(0x1f4)](),_0x57d8b2=this['_injector']['get'](_0xd47051[_0x572e8a(0x1ff)]),_0x177047=this[_0x572e8a(0x1ba)][_0x572e8a(0x1d8)](_0x22d1cf['SparklineDataSourceModel']),_0x2e785f=(_0x1929f2=_0x58b333==null?void 0x0:_0x58b333[_0x572e8a(0x1b9)])!=null?_0x1929f2:_0x57d8b2['getCurrentSelections']()[_0x572e8a(0x1f6)](_0x114c33=>_0x114c33[_0x572e8a(0x1bf)]),_0xcc6999=(_0x2aea0b=_0x177047['getSparklineCache']()['sparklineAnchorMap'][_0x572e8a(0x1d8)](_0x4335b0))==null?void 0x0:_0x2aea0b[_0x572e8a(0x1d8)](_0x38dc34),_0x22ba13=new Set();_0x2e785f[_0x572e8a(0x1e4)](_0x30aae1=>{const _0x4d4706=_0x572e8a;var _0x102fd5;const {startRow:_0x7dfe71,endRow:_0x664c12,startColumn:_0x30a63f,endColumn:_0xdf2a60}=_0x30aae1;for(let _0x36d05d=_0x7dfe71;_0x36d05d<=_0x664c12;_0x36d05d++)for(let _0x37814a=_0x30a63f;_0x37814a<=_0xdf2a60;_0x37814a++){const _0x4af7dd=(_0x102fd5=_0xcc6999==null?void 0x0:_0xcc6999['matrix'][_0x4d4706(0x1f7)](_0x36d05d,_0x37814a))==null?void 0x0:_0x102fd5['groupId'];_0x4af7dd&&_0x22ba13['add'](_0x4af7dd);}});const _0x2ca2a0=Array[_0x572e8a(0x1e5)](_0x22ba13)['map'](_0xb9a220=>_0x177047[_0x572e8a(0x1d3)](_0x4335b0,_0x38dc34,_0xb9a220))[_0x572e8a(0x1e8)](_0x547cfa=>!!_0x547cfa),_0x46f03c={'workbook':_0x1d42ac,'worksheet':_0x15e560,'sparklines':_0x2ca2a0};if(this[_0x572e8a(0x1ed)](this['Event']['SheetSparklineChanged'],_0x46f03c),_0x46f03c[_0x572e8a(0x204)])throw new Error(_0x572e8a(0x1e7));}}}));}}_0x2d4f9f[_0x26ba76(0x1cd)][_0x26ba76(0x1d2)](_0x2227aa),Object[_0x26ba76(0x1b3)](_0x4bd2bc,Symbol[_0x26ba76(0x206)],{'value':'Module'});}));
|
|
1
|
+
function _0x8959(){const _0x4ac00f=['1106208CyLLDt','FWorksheet','createInstance','_row','SheetSparklineChanged','function','FEnum','item','UniverSheetsFacade','Event','@univerjs/core/facade','groupId','from','2123VgwwSe','getActiveWorkbook','getSparklineGroupByCell','getSparklineByCell','ICommandService','_initialize','SetSheetSparklineCommand','385kmpDsI','onCommandExecuted','getSubUnitSparkline','Sheet\x20create\x20canceled\x20by\x20facade\x20api.','getUnitId','ranges','_worksheet','sparklineAnchorMap','_unitId','SparklineDataSourceModel','UniverSheets','unComposeSparkline','@univerjs/sheets/facade','startColumn','FSparklineGroup','49616dOAnNc','extend','FUniver','params','startRow','length','RemoveSheetSparklineCommand','registerEventHandler','object','FSparkline','removeSparkline','@univerjs-pro/sheets-sparkline','2933361Vpqzwl','getSparklineById','add','Tools','Injector','1147491pVPFsI','Inject','AddSheetSparklineCommand','_injector','29244dQoSkl','UniverCore','get','getSparkline','16390hETjQP','205yBJuiv','getCurrentSelections','executeCommand','setConfig','SparklineTypeEnum','_workbook','defineProperty','forEach','isChangeDataSource','UniverProSheetsSparklineFacade','_groupId','getSparklineCache','@univerjs/sheets','@univerjs/core','_subUnitId','getSheetId','3433yZxTjM','_col','118XuQZJd','changeDataSource','composeSparkline','getAllSubSparkline','getId','FEventName','deepClone','_commandService','toStringTag','cancel','syncExecuteCommand','getActiveSheet','UniverProSheetsSparkline','range'];_0x8959=function(){return _0x4ac00f;};return _0x8959();}function _0x35c9(_0x1d5bf6,_0x1bd4c6){const _0x895985=_0x8959();return _0x35c9=function(_0x35c919,_0x1c7c9d){_0x35c919=_0x35c919-0x182;let _0x299ce6=_0x895985[_0x35c919];return _0x299ce6;},_0x35c9(_0x1d5bf6,_0x1bd4c6);}(function(_0x32ff67,_0x2b92c9){const _0x1d7b79=_0x35c9,_0x5e559e=_0x32ff67();while(!![]){try{const _0x7e3a40=parseInt(_0x1d7b79(0x19d))/0x1*(parseInt(_0x1d7b79(0x19f))/0x2)+parseInt(_0x1d7b79(0x184))/0x3+-parseInt(_0x1d7b79(0x1ad))/0x4+-parseInt(_0x1d7b79(0x18d))/0x5*(-parseInt(_0x1d7b79(0x188))/0x6)+-parseInt(_0x1d7b79(0x1c1))/0x7*(-parseInt(_0x1d7b79(0x1d0))/0x8)+-parseInt(_0x1d7b79(0x1dc))/0x9+-parseInt(_0x1d7b79(0x18c))/0xa*(parseInt(_0x1d7b79(0x1ba))/0xb);if(_0x7e3a40===_0x2b92c9)break;else _0x5e559e['push'](_0x5e559e['shift']());}catch(_0x563521){_0x5e559e['push'](_0x5e559e['shift']());}}}(_0x8959,0x3294c),function(_0x585618,_0x745c11){const _0x4de48a=_0x35c9;typeof exports==_0x4de48a(0x1d8)&&typeof module<'u'?_0x745c11(exports,require('@univerjs-pro/sheets-sparkline'),require('@univerjs/core'),require(_0x4de48a(0x1cd)),require(_0x4de48a(0x1b7)),require(_0x4de48a(0x199))):typeof define==_0x4de48a(0x1b2)&&define['amd']?define(['exports',_0x4de48a(0x1db),_0x4de48a(0x19a),_0x4de48a(0x1cd),_0x4de48a(0x1b7),_0x4de48a(0x199)],_0x745c11):(_0x585618=typeof globalThis<'u'?globalThis:_0x585618||self,_0x745c11(_0x585618[_0x4de48a(0x196)]={},_0x585618[_0x4de48a(0x1ab)],_0x585618[_0x4de48a(0x189)],_0x585618[_0x4de48a(0x1b5)],_0x585618['UniverCoreFacade'],_0x585618[_0x4de48a(0x1cb)]));}(this,function(_0x3bbb98,_0x5cbdc2,_0xa1d060,_0x706414,_0x4374ca,_0x1353f7){'use strict';const _0xb867dc=_0x35c9;var _0x1051cf=Object['getOwnPropertyDescriptor'],_0x1b10e5=(_0xff9a6c,_0x2bc6d7,_0x42b4db,_0x22c5bb)=>{for(var _0x3814c5=_0x22c5bb>0x1?void 0x0:_0x22c5bb?_0x1051cf(_0x2bc6d7,_0x42b4db):_0x2bc6d7,_0xd226d2=_0xff9a6c['length']-0x1,_0x33372b;_0xd226d2>=0x0;_0xd226d2--)(_0x33372b=_0xff9a6c[_0xd226d2])&&(_0x3814c5=_0x33372b(_0x3814c5)||_0x3814c5);return _0x3814c5;},_0x15f3f6=(_0x2373af,_0x265865)=>(_0x4b5f63,_0x201c72)=>_0x265865(_0x4b5f63,_0x201c72,_0x2373af);_0x3bbb98[_0xb867dc(0x1d9)]=class{constructor(_0x5bafe5,_0x352de7,_0x4ff846,_0x4cfc72,_0x4becf1,_0xe6adf4){const _0x596918=_0xb867dc;this[_0x596918(0x1c9)]=_0x5bafe5,this['_subUnitId']=_0x352de7,this[_0x596918(0x197)]=_0x4ff846,this[_0x596918(0x1b0)]=_0x4cfc72,this['_col']=_0x4becf1,this[_0x596918(0x187)]=_0xe6adf4;}[_0xb867dc(0x1a0)](_0x2893c5,_0x13cd85){const _0x575ab9=_0xb867dc,_0x9fae30=this[_0x575ab9(0x187)][_0x575ab9(0x18a)](_0x5cbdc2[_0x575ab9(0x1ca)]),_0x5d417f=this[_0x575ab9(0x187)]['get'](_0xa1d060[_0x575ab9(0x1be)]),_0x2b1450=_0x9fae30[_0x575ab9(0x1dd)](this['_unitId'],this[_0x575ab9(0x19b)],this['_groupId']);if(!_0x2b1450)return;const _0x5aa2e6={'config':_0x2b1450,'isChangeDataSource':!0x0,'changeDataSourceInfo':{'groupId':this['_groupId'],'resetType':_0x575ab9(0x1b4),'sourceRanges':[_0x2893c5],'targetRanges':[_0x13cd85],'primary':{'startRow':this['_row'],'startColumn':this[_0x575ab9(0x19e)],'endRow':this[_0x575ab9(0x1b0)],'endColumn':this['_col'],'actualRow':this[_0x575ab9(0x1b0)],'actualColumn':this[_0x575ab9(0x19e)],'isMerged':!0x1,'isMergedMainCell':!0x1}}};return _0x5d417f[_0x575ab9(0x1a9)](_0x5cbdc2[_0x575ab9(0x1c0)]['id'],_0x5aa2e6),this['_row']=_0x13cd85['startRow'],this[_0x575ab9(0x19e)]=_0x13cd85[_0x575ab9(0x1ce)],this;}[_0xb867dc(0x1da)](){const _0x861d3e=_0xb867dc,_0x391994=this[_0x861d3e(0x187)][_0x861d3e(0x18a)](_0xa1d060[_0x861d3e(0x1be)]),_0x4e90dc={'isSingle':!0x0,'ranges':[{'startRow':this['_row'],'startColumn':this[_0x861d3e(0x19e)],'endRow':this[_0x861d3e(0x1b0)],'endColumn':this[_0x861d3e(0x19e)]}]};_0x391994[_0x861d3e(0x1a9)](_0x5cbdc2[_0x861d3e(0x1d6)]['id'],_0x4e90dc);}},_0x3bbb98[_0xb867dc(0x1d9)]=_0x1b10e5([_0x15f3f6(0x5,_0xa1d060[_0xb867dc(0x185)](_0xa1d060[_0xb867dc(0x183)]))],_0x3bbb98[_0xb867dc(0x1d9)]);var _0x5c0289=Object['getOwnPropertyDescriptor'],_0x1434de=(_0x3c6a95,_0x3d3744,_0x221b63,_0x4f9316)=>{const _0x4c1409=_0xb867dc;for(var _0x5c96e7=_0x4f9316>0x1?void 0x0:_0x4f9316?_0x5c0289(_0x3d3744,_0x221b63):_0x3d3744,_0x1fb807=_0x3c6a95[_0x4c1409(0x1d5)]-0x1,_0x3dec2a;_0x1fb807>=0x0;_0x1fb807--)(_0x3dec2a=_0x3c6a95[_0x1fb807])&&(_0x5c96e7=_0x3dec2a(_0x5c96e7)||_0x5c96e7);return _0x5c96e7;},_0x3825ee=(_0x501b3a,_0x109137)=>(_0x11efad,_0x2bf7c2)=>_0x109137(_0x11efad,_0x2bf7c2,_0x501b3a);_0x3bbb98['FSparklineGroup']=class{constructor(_0xd6c8f6,_0x5640fb,_0x420b1a,_0x1f5fcb,_0x19cf8c,_0x124119){const _0x465347=_0xb867dc;this['_unitId']=_0xd6c8f6,this[_0x465347(0x19b)]=_0x5640fb,this[_0x465347(0x197)]=_0x420b1a,this[_0x465347(0x1b0)]=_0x1f5fcb,this['_col']=_0x19cf8c,this['_injector']=_0x124119;}[_0xb867dc(0x1a0)](_0x4f56e1,_0x39d061){const _0x3160d5=_0xb867dc,_0xba1108=this['_injector'][_0x3160d5(0x18a)](_0x5cbdc2[_0x3160d5(0x1ca)]),_0x1846d0=this['_injector'][_0x3160d5(0x18a)](_0xa1d060[_0x3160d5(0x1be)]),_0x39ccd3=_0xba1108[_0x3160d5(0x1dd)](this[_0x3160d5(0x1c9)],this['_subUnitId'],this[_0x3160d5(0x197)]);if(!_0x39ccd3)return;const _0x5405ac={'config':_0x39ccd3,'isChangeDataSource':!0x0,'changeDataSourceInfo':{'groupId':this[_0x3160d5(0x197)],'resetType':'group','sourceRanges':_0x4f56e1,'targetRanges':_0x39d061,'primary':{'startRow':this[_0x3160d5(0x1b0)],'startColumn':this['_col'],'endRow':this[_0x3160d5(0x1b0)],'endColumn':this['_col'],'actualRow':this['_row'],'actualColumn':this[_0x3160d5(0x19e)],'isMerged':!0x1,'isMergedMainCell':!0x1}}};return _0x1846d0['syncExecuteCommand'](_0x5cbdc2[_0x3160d5(0x1c0)]['id'],_0x5405ac),this['_row']=_0x39d061[0x0][_0x3160d5(0x1d4)],this[_0x3160d5(0x19e)]=_0x39d061[0x0][_0x3160d5(0x1ce)],this;}['removeSparklineGroup'](){const _0x2b0573=_0xb867dc,_0x2dd1ce=this[_0x2b0573(0x187)][_0x2b0573(0x18a)](_0xa1d060[_0x2b0573(0x1be)]),_0x58743e={'isSingle':!0x1,'ranges':[{'startRow':this['_row'],'startColumn':this[_0x2b0573(0x19e)],'endRow':this[_0x2b0573(0x1b0)],'endColumn':this[_0x2b0573(0x19e)]}]};_0x2dd1ce['syncExecuteCommand'](_0x5cbdc2[_0x2b0573(0x1d6)]['id'],_0x58743e);}[_0xb867dc(0x190)](_0x439912){const _0x2f9909=_0xb867dc,_0x4812ce=this[_0x2f9909(0x187)][_0x2f9909(0x18a)](_0x5cbdc2[_0x2f9909(0x1ca)])[_0x2f9909(0x1dd)](this[_0x2f9909(0x1c9)],this[_0x2f9909(0x19b)],this['_groupId']);if(_0x4812ce){const _0x28e3d0={'config':{'config':_0x439912,'sparklines':_0x4812ce['sparklines']},'isChangeDataSource':!0x1};this['_injector'][_0x2f9909(0x18a)](_0xa1d060['ICommandService'])[_0x2f9909(0x1a9)](_0x5cbdc2[_0x2f9909(0x1c0)]['id'],_0x28e3d0);}return this;}},_0x3bbb98[_0xb867dc(0x1cf)]=_0x1434de([_0x3825ee(0x5,_0xa1d060[_0xb867dc(0x185)](_0xa1d060[_0xb867dc(0x183)]))],_0x3bbb98[_0xb867dc(0x1cf)]);class _0x47ffa7 extends _0x706414[_0xb867dc(0x1ae)]{['addSparkline'](_0x45fbaa,_0x538e84,_0x1ec0e1){const _0xc74ed1=_0xb867dc;if(this[_0xc74ed1(0x1a6)][_0xc74ed1(0x1a9)](_0x5cbdc2[_0xc74ed1(0x186)]['id'],{'sourceRanges':_0x45fbaa,'targetRanges':_0x538e84,'targetInfo':{'unitId':this['_workbook'][_0xc74ed1(0x1c5)](),'subUnitId':this[_0xc74ed1(0x1c7)][_0xc74ed1(0x19c)]()},'config':{'type':_0x1ec0e1}})){const {startRow:_0x575124,startColumn:_0x57b2f9}=_0x538e84[0x0];return this[_0xc74ed1(0x1bd)](_0x575124,_0x57b2f9);}}[_0xb867dc(0x1a2)](){const _0x1046b3=_0xb867dc;return this[_0x1046b3(0x187)][_0x1046b3(0x18a)](_0x5cbdc2[_0x1046b3(0x1ca)])[_0x1046b3(0x1c3)](this[_0x1046b3(0x192)]['getUnitId'](),this[_0x1046b3(0x1c7)][_0x1046b3(0x19c)]());}[_0xb867dc(0x1a1)](_0x205193){const _0x1e6cfa=_0xb867dc,_0x45f900=this[_0x1e6cfa(0x187)][_0x1e6cfa(0x18a)](_0x5cbdc2['SparklineDataSourceModel']);let _0x4b9af5;for(let _0x2b18db=0x0;_0x2b18db<_0x205193[_0x1e6cfa(0x1d5)];_0x2b18db++){const _0x496fd0=_0x205193[_0x2b18db],{startRow:_0x9cae1a,endRow:_0x1cb605,startColumn:_0x1a40a6,endColumn:_0x4b95d7}=_0x496fd0;for(let _0x193034=_0x9cae1a;_0x193034<=_0x1cb605;_0x193034++)for(let _0x184230=_0x1a40a6;_0x184230<=_0x4b95d7;_0x184230++){const _0x4e45ae=_0x45f900[_0x1e6cfa(0x18b)](this[_0x1e6cfa(0x192)]['getUnitId'](),this[_0x1e6cfa(0x1c7)][_0x1e6cfa(0x19c)](),_0x193034,_0x184230);if(_0x4e45ae){const _0x162ae7=_0x45f900[_0x1e6cfa(0x1dd)](this[_0x1e6cfa(0x192)][_0x1e6cfa(0x1c5)](),this['_worksheet'][_0x1e6cfa(0x19c)](),_0x4e45ae);if(_0x162ae7){_0x4b9af5=_0xa1d060[_0x1e6cfa(0x182)][_0x1e6cfa(0x1a5)](_0x162ae7);break;}}}}_0x4b9af5&&this['_commandService'][_0x1e6cfa(0x18f)](_0x5cbdc2[_0x1e6cfa(0x1c0)]['id'],{'ranges':_0x205193,'combine':!0x0,'config':_0x4b9af5,'isChangeDataSource':!0x1});}[_0xb867dc(0x1cc)](_0x45c790){const _0x119de2=_0xb867dc,_0x18800d=this[_0x119de2(0x187)]['get'](_0x5cbdc2[_0x119de2(0x1ca)]);let _0x3bb4a7;for(let _0x457841=0x0;_0x457841<_0x45c790['length'];_0x457841++){const _0xfe216=_0x45c790[_0x457841],{startRow:_0x4c9bba,endRow:_0x2852b4,startColumn:_0x2cc560,endColumn:_0x546939}=_0xfe216;for(let _0x3a354e=_0x4c9bba;_0x3a354e<=_0x2852b4;_0x3a354e++)for(let _0x4a113f=_0x2cc560;_0x4a113f<=_0x546939;_0x4a113f++){const _0x563877=_0x18800d[_0x119de2(0x18b)](this[_0x119de2(0x192)][_0x119de2(0x1c5)](),this['_worksheet'][_0x119de2(0x19c)](),_0x3a354e,_0x4a113f);if(_0x563877){const _0xb5d0ad=_0x18800d[_0x119de2(0x1dd)](this[_0x119de2(0x192)][_0x119de2(0x1c5)](),this[_0x119de2(0x1c7)]['getSheetId'](),_0x563877);if(_0xb5d0ad){_0x3bb4a7=_0xa1d060[_0x119de2(0x182)]['deepClone'](_0xb5d0ad);break;}}}}_0x3bb4a7||this['_commandService'][_0x119de2(0x18f)](_0x5cbdc2[_0x119de2(0x1c0)]['id'],{'ranges':_0x45c790,'unCombine':!0x0,'config':_0x3bb4a7,'isChangeDataSource':!0x1});}[_0xb867dc(0x1bd)](_0x4f18c8,_0x8b8055){const _0x52a080=_0xb867dc,_0x1e927a=this[_0x52a080(0x187)][_0x52a080(0x18a)](_0x5cbdc2[_0x52a080(0x1ca)]),_0x158ddf=this[_0x52a080(0x192)][_0x52a080(0x1c5)](),_0x36ee06=this[_0x52a080(0x1c7)][_0x52a080(0x19c)](),_0x1cd42e=_0x1e927a[_0x52a080(0x18b)](_0x158ddf,_0x36ee06,_0x4f18c8,_0x8b8055);if(_0x1cd42e)return this[_0x52a080(0x187)][_0x52a080(0x1af)](_0x3bbb98[_0x52a080(0x1d9)],_0x158ddf,_0x36ee06,_0x1cd42e,_0x4f18c8,_0x8b8055);}[_0xb867dc(0x1bc)](_0x2b7e91,_0xf14821){const _0x5353a7=_0xb867dc,_0x9eff31=this['_injector'][_0x5353a7(0x18a)](_0x5cbdc2['SparklineDataSourceModel']),_0x48c174=this[_0x5353a7(0x192)][_0x5353a7(0x1c5)](),_0x48ddd2=this['_worksheet'][_0x5353a7(0x19c)](),_0x359bfc=_0x9eff31['getSparkline'](_0x48c174,_0x48ddd2,_0x2b7e91,_0xf14821);if(_0x359bfc)return this['_injector']['createInstance'](_0x3bbb98[_0x5353a7(0x1cf)],_0x48c174,_0x48ddd2,_0x359bfc,_0x2b7e91,_0xf14821);}}_0x706414[_0xb867dc(0x1ae)][_0xb867dc(0x1d1)](_0x47ffa7);class _0x6764cb extends _0x4374ca[_0xb867dc(0x1b3)]{get[_0xb867dc(0x191)](){const _0x56ae9a=_0xb867dc;return _0x5cbdc2[_0x56ae9a(0x191)];}}_0x4374ca[_0xb867dc(0x1b3)][_0xb867dc(0x1d1)](_0x6764cb);class _0x242c17 extends _0x4374ca[_0xb867dc(0x1a4)]{get[_0xb867dc(0x1b1)](){const _0x2f16d1=_0xb867dc;return _0x2f16d1(0x1b1);}}_0x4374ca['FEventName'][_0xb867dc(0x1d1)](_0x242c17);class _0xcf4498 extends _0x4374ca[_0xb867dc(0x1d2)]{[_0xb867dc(0x1bf)](_0x53e14b){const _0x3787d1=_0xb867dc,_0x23b6aa=_0x53e14b['get'](_0xa1d060[_0x3787d1(0x1be)]);this[_0x3787d1(0x1d7)](this[_0x3787d1(0x1b6)]['SheetSparklineChanged'],()=>_0x23b6aa[_0x3787d1(0x1c2)](_0x92393=>{const _0xb857a4=_0x3787d1;var _0x382085,_0x4451be;if(_0x92393['id']===_0x5cbdc2[_0xb857a4(0x1c0)]['id']){const _0x30d66e=_0x92393[_0xb857a4(0x1d3)];if(!_0x30d66e[_0xb857a4(0x195)]){const _0x5e7d3f=this[_0xb857a4(0x1bb)](),_0x4de366=_0x5e7d3f==null?void 0x0:_0x5e7d3f[_0xb857a4(0x1aa)]();if(!_0x5e7d3f||!_0x4de366)return;const _0x59c39d=_0x5e7d3f[_0xb857a4(0x1a3)](),_0x11bc57=_0x4de366['getSheetId'](),_0x197d12=this[_0xb857a4(0x187)]['get'](_0x1353f7['SheetsSelectionsService']),_0x5d4e8e=this[_0xb857a4(0x187)][_0xb857a4(0x18a)](_0x5cbdc2['SparklineDataSourceModel']),_0x4a8807=(_0x382085=_0x30d66e==null?void 0x0:_0x30d66e[_0xb857a4(0x1c6)])!=null?_0x382085:_0x197d12[_0xb857a4(0x18e)]()['map'](_0x41d440=>_0x41d440[_0xb857a4(0x1ac)]),_0x5fffe7=(_0x4451be=_0x5d4e8e[_0xb857a4(0x198)]()[_0xb857a4(0x1c8)][_0xb857a4(0x18a)](_0x59c39d))==null?void 0x0:_0x4451be['get'](_0x11bc57),_0x4ea668=new Set();_0x4a8807[_0xb857a4(0x194)](_0x20b4c5=>{const _0x15dad9=_0xb857a4;var _0x14befb;const {startRow:_0x23afa4,endRow:_0xdc7ff,startColumn:_0x50779d,endColumn:_0x10229e}=_0x20b4c5;for(let _0x38bca5=_0x23afa4;_0x38bca5<=_0xdc7ff;_0x38bca5++)for(let _0x2c0f6f=_0x50779d;_0x2c0f6f<=_0x10229e;_0x2c0f6f++){const _0x26808d=(_0x14befb=_0x5fffe7==null?void 0x0:_0x5fffe7['matrix']['getValue'](_0x38bca5,_0x2c0f6f))==null?void 0x0:_0x14befb[_0x15dad9(0x1b8)];_0x26808d&&_0x4ea668[_0x15dad9(0x1de)](_0x26808d);}});const _0x35fb37=Array[_0xb857a4(0x1b9)](_0x4ea668)['map'](_0x661427=>_0x5d4e8e[_0xb857a4(0x1dd)](_0x59c39d,_0x11bc57,_0x661427))['filter'](_0x2b0db4=>!!_0x2b0db4),_0x25708b={'workbook':_0x5e7d3f,'worksheet':_0x4de366,'sparklines':_0x35fb37};if(this['fireEvent'](this[_0xb857a4(0x1b6)][_0xb857a4(0x1b1)],_0x25708b),_0x25708b[_0xb857a4(0x1a8)])throw new Error(_0xb857a4(0x1c4));}}}));}}_0x4374ca[_0xb867dc(0x1d2)][_0xb867dc(0x1d1)](_0xcf4498),Object[_0xb867dc(0x193)](_0x3bbb98,Symbol[_0xb867dc(0x1a7)],{'value':'Module'});}));
|