@antv/s2-vue 1.0.0 → 1.1.0-alpha.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.
Files changed (79) hide show
  1. package/README.md +26 -55
  2. package/dist/index.min.js +1 -1
  3. package/dist/index.min.js.map +1 -1
  4. package/dist/style.min.css +1 -1
  5. package/esm/index.d.ts +4366 -4
  6. package/esm/index.js +824 -150
  7. package/esm/index.js.map +1 -1
  8. package/esm/style.css +123 -21
  9. package/lib/index.js +821 -147
  10. package/lib/index.js.map +1 -1
  11. package/lib/style.css +123 -21
  12. package/package.json +11 -8
  13. package/esm/common/constant/index.d.ts +0 -3
  14. package/esm/common/constant/index.d.ts.map +0 -1
  15. package/esm/common/constant/options.d.ts +0 -3
  16. package/esm/common/constant/options.d.ts.map +0 -1
  17. package/esm/common/constant/sort.d.ts +0 -15
  18. package/esm/common/constant/sort.d.ts.map +0 -1
  19. package/esm/components/index.d.ts +0 -5
  20. package/esm/components/index.d.ts.map +0 -1
  21. package/esm/components/pagination/index.vue.d.ts +0 -43
  22. package/esm/components/pagination/index.vue.d.ts.map +0 -1
  23. package/esm/components/sheets/base-sheet.vue.d.ts +0 -287
  24. package/esm/components/sheets/base-sheet.vue.d.ts.map +0 -1
  25. package/esm/components/sheets/index.vue.d.ts +0 -432
  26. package/esm/components/sheets/index.vue.d.ts.map +0 -1
  27. package/esm/components/sheets/pivot-sheet.vue.d.ts +0 -217
  28. package/esm/components/sheets/pivot-sheet.vue.d.ts.map +0 -1
  29. package/esm/components/sheets/table-sheet.vue.d.ts +0 -217
  30. package/esm/components/sheets/table-sheet.vue.d.ts.map +0 -1
  31. package/esm/components/tooltip/components/detail.vue.d.ts +0 -7
  32. package/esm/components/tooltip/components/detail.vue.d.ts.map +0 -1
  33. package/esm/components/tooltip/components/head-info.vue.d.ts +0 -7
  34. package/esm/components/tooltip/components/head-info.vue.d.ts.map +0 -1
  35. package/esm/components/tooltip/components/infos.vue.d.ts +0 -7
  36. package/esm/components/tooltip/components/infos.vue.d.ts.map +0 -1
  37. package/esm/components/tooltip/components/operator/index.d.ts +0 -4
  38. package/esm/components/tooltip/components/operator/index.d.ts.map +0 -1
  39. package/esm/components/tooltip/components/operator/index.vue.d.ts +0 -11
  40. package/esm/components/tooltip/components/operator/index.vue.d.ts.map +0 -1
  41. package/esm/components/tooltip/components/operator/menu.vue.d.ts +0 -12
  42. package/esm/components/tooltip/components/operator/menu.vue.d.ts.map +0 -1
  43. package/esm/components/tooltip/components/operator/title.vue.d.ts +0 -11
  44. package/esm/components/tooltip/components/operator/title.vue.d.ts.map +0 -1
  45. package/esm/components/tooltip/components/simple-tips.vue.d.ts +0 -7
  46. package/esm/components/tooltip/components/simple-tips.vue.d.ts.map +0 -1
  47. package/esm/components/tooltip/components/summary.vue.d.ts +0 -9
  48. package/esm/components/tooltip/components/summary.vue.d.ts.map +0 -1
  49. package/esm/components/tooltip/custom-tooltip.d.ts +0 -7
  50. package/esm/components/tooltip/custom-tooltip.d.ts.map +0 -1
  51. package/esm/components/tooltip/index.vue.d.ts +0 -8
  52. package/esm/components/tooltip/index.vue.d.ts.map +0 -1
  53. package/esm/components/tooltip/interface.d.ts +0 -9
  54. package/esm/components/tooltip/interface.d.ts.map +0 -1
  55. package/esm/hooks/useEvents.d.ts +0 -5
  56. package/esm/hooks/useEvents.d.ts.map +0 -1
  57. package/esm/hooks/useExpose.d.ts +0 -6
  58. package/esm/hooks/useExpose.d.ts.map +0 -1
  59. package/esm/hooks/useLoading.d.ts +0 -7
  60. package/esm/hooks/useLoading.d.ts.map +0 -1
  61. package/esm/hooks/usePagination.d.ts +0 -14
  62. package/esm/hooks/usePagination.d.ts.map +0 -1
  63. package/esm/hooks/useResize.d.ts +0 -8
  64. package/esm/hooks/useResize.d.ts.map +0 -1
  65. package/esm/hooks/useSheetUpdate.d.ts +0 -5
  66. package/esm/hooks/useSheetUpdate.d.ts.map +0 -1
  67. package/esm/hooks/useSpreadSheet.d.ts +0 -19
  68. package/esm/hooks/useSpreadSheet.d.ts.map +0 -1
  69. package/esm/index.d.ts.map +0 -1
  70. package/esm/interface.d.ts +0 -36
  71. package/esm/interface.d.ts.map +0 -1
  72. package/esm/utils/extendLocale.d.ts +0 -2
  73. package/esm/utils/extendLocale.d.ts.map +0 -1
  74. package/esm/utils/initPropAndEmits.d.ts +0 -137
  75. package/esm/utils/initPropAndEmits.d.ts.map +0 -1
  76. package/esm/utils/options.d.ts +0 -3
  77. package/esm/utils/options.d.ts.map +0 -1
  78. package/esm/utils/traverse.d.ts +0 -2
  79. package/esm/utils/traverse.d.ts.map +0 -1
package/lib/index.js CHANGED
@@ -42,12 +42,12 @@ var root = freeGlobal$1 || freeSelf || Function("return this")();
42
42
  var root$1 = root;
43
43
  var Symbol$1 = root$1.Symbol;
44
44
  var Symbol$2 = Symbol$1;
45
- var objectProto$c = Object.prototype;
46
- var hasOwnProperty$9 = objectProto$c.hasOwnProperty;
47
- var nativeObjectToString$1 = objectProto$c.toString;
45
+ var objectProto$f = Object.prototype;
46
+ var hasOwnProperty$c = objectProto$f.hasOwnProperty;
47
+ var nativeObjectToString$1 = objectProto$f.toString;
48
48
  var symToStringTag$1 = Symbol$2 ? Symbol$2.toStringTag : void 0;
49
49
  function getRawTag(value) {
50
- var isOwn = hasOwnProperty$9.call(value, symToStringTag$1), tag = value[symToStringTag$1];
50
+ var isOwn = hasOwnProperty$c.call(value, symToStringTag$1), tag = value[symToStringTag$1];
51
51
  try {
52
52
  value[symToStringTag$1] = void 0;
53
53
  var unmasked = true;
@@ -63,8 +63,8 @@ function getRawTag(value) {
63
63
  }
64
64
  return result;
65
65
  }
66
- var objectProto$b = Object.prototype;
67
- var nativeObjectToString = objectProto$b.toString;
66
+ var objectProto$e = Object.prototype;
67
+ var nativeObjectToString = objectProto$e.toString;
68
68
  function objectToString(value) {
69
69
  return nativeObjectToString.call(value);
70
70
  }
@@ -79,9 +79,9 @@ function baseGetTag(value) {
79
79
  function isObjectLike(value) {
80
80
  return value != null && typeof value == "object";
81
81
  }
82
- var symbolTag$1 = "[object Symbol]";
82
+ var symbolTag$3 = "[object Symbol]";
83
83
  function isSymbol(value) {
84
- return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag$1;
84
+ return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag$3;
85
85
  }
86
86
  function arrayMap(array, iteratee) {
87
87
  var index2 = -1, length = array == null ? 0 : array.length, result = Array(length);
@@ -93,7 +93,7 @@ function arrayMap(array, iteratee) {
93
93
  var isArray = Array.isArray;
94
94
  var isArray$1 = isArray;
95
95
  var INFINITY$1 = 1 / 0;
96
- var symbolProto$1 = Symbol$2 ? Symbol$2.prototype : void 0, symbolToString = symbolProto$1 ? symbolProto$1.toString : void 0;
96
+ var symbolProto$2 = Symbol$2 ? Symbol$2.prototype : void 0, symbolToString = symbolProto$2 ? symbolProto$2.toString : void 0;
97
97
  function baseToString(value) {
98
98
  if (typeof value == "string") {
99
99
  return value;
@@ -148,13 +148,13 @@ function toNumber(value) {
148
148
  function identity(value) {
149
149
  return value;
150
150
  }
151
- var asyncTag = "[object AsyncFunction]", funcTag$1 = "[object Function]", genTag = "[object GeneratorFunction]", proxyTag = "[object Proxy]";
151
+ var asyncTag = "[object AsyncFunction]", funcTag$2 = "[object Function]", genTag$1 = "[object GeneratorFunction]", proxyTag = "[object Proxy]";
152
152
  function isFunction(value) {
153
153
  if (!isObject(value)) {
154
154
  return false;
155
155
  }
156
156
  var tag = baseGetTag(value);
157
- return tag == funcTag$1 || tag == genTag || tag == asyncTag || tag == proxyTag;
157
+ return tag == funcTag$2 || tag == genTag$1 || tag == asyncTag || tag == proxyTag;
158
158
  }
159
159
  var coreJsData = root$1["__core-js_shared__"];
160
160
  var coreJsData$1 = coreJsData;
@@ -182,10 +182,10 @@ function toSource(func) {
182
182
  }
183
183
  var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
184
184
  var reIsHostCtor = /^\[object .+?Constructor\]$/;
185
- var funcProto = Function.prototype, objectProto$a = Object.prototype;
185
+ var funcProto = Function.prototype, objectProto$d = Object.prototype;
186
186
  var funcToString = funcProto.toString;
187
- var hasOwnProperty$8 = objectProto$a.hasOwnProperty;
188
- var reIsNative = RegExp("^" + funcToString.call(hasOwnProperty$8).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$");
187
+ var hasOwnProperty$b = objectProto$d.hasOwnProperty;
188
+ var reIsNative = RegExp("^" + funcToString.call(hasOwnProperty$b).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$");
189
189
  function baseIsNative(value) {
190
190
  if (!isObject(value) || isMasked(value)) {
191
191
  return false;
@@ -202,6 +202,50 @@ function getNative(object, key) {
202
202
  }
203
203
  var WeakMap = getNative(root$1, "WeakMap");
204
204
  var WeakMap$1 = WeakMap;
205
+ var objectCreate = Object.create;
206
+ var baseCreate = function() {
207
+ function object() {
208
+ }
209
+ return function(proto) {
210
+ if (!isObject(proto)) {
211
+ return {};
212
+ }
213
+ if (objectCreate) {
214
+ return objectCreate(proto);
215
+ }
216
+ object.prototype = proto;
217
+ var result = new object();
218
+ object.prototype = void 0;
219
+ return result;
220
+ };
221
+ }();
222
+ var baseCreate$1 = baseCreate;
223
+ function copyArray(source, array) {
224
+ var index2 = -1, length = source.length;
225
+ array || (array = Array(length));
226
+ while (++index2 < length) {
227
+ array[index2] = source[index2];
228
+ }
229
+ return array;
230
+ }
231
+ var defineProperty = function() {
232
+ try {
233
+ var func = getNative(Object, "defineProperty");
234
+ func({}, "", {});
235
+ return func;
236
+ } catch (e) {
237
+ }
238
+ }();
239
+ var defineProperty$1 = defineProperty;
240
+ function arrayEach(array, iteratee) {
241
+ var index2 = -1, length = array == null ? 0 : array.length;
242
+ while (++index2 < length) {
243
+ if (iteratee(array[index2], index2, array) === false) {
244
+ break;
245
+ }
246
+ }
247
+ return array;
248
+ }
205
249
  var MAX_SAFE_INTEGER$1 = 9007199254740991;
206
250
  var reIsUint = /^(?:0|[1-9]\d*)$/;
207
251
  function isIndex(value, length) {
@@ -209,9 +253,47 @@ function isIndex(value, length) {
209
253
  length = length == null ? MAX_SAFE_INTEGER$1 : length;
210
254
  return !!length && (type == "number" || type != "symbol" && reIsUint.test(value)) && (value > -1 && value % 1 == 0 && value < length);
211
255
  }
256
+ function baseAssignValue(object, key, value) {
257
+ if (key == "__proto__" && defineProperty$1) {
258
+ defineProperty$1(object, key, {
259
+ "configurable": true,
260
+ "enumerable": true,
261
+ "value": value,
262
+ "writable": true
263
+ });
264
+ } else {
265
+ object[key] = value;
266
+ }
267
+ }
212
268
  function eq(value, other) {
213
269
  return value === other || value !== value && other !== other;
214
270
  }
271
+ var objectProto$c = Object.prototype;
272
+ var hasOwnProperty$a = objectProto$c.hasOwnProperty;
273
+ function assignValue(object, key, value) {
274
+ var objValue = object[key];
275
+ if (!(hasOwnProperty$a.call(object, key) && eq(objValue, value)) || value === void 0 && !(key in object)) {
276
+ baseAssignValue(object, key, value);
277
+ }
278
+ }
279
+ function copyObject(source, props, object, customizer) {
280
+ var isNew = !object;
281
+ object || (object = {});
282
+ var index2 = -1, length = props.length;
283
+ while (++index2 < length) {
284
+ var key = props[index2];
285
+ var newValue = customizer ? customizer(object[key], source[key], key, object, source) : void 0;
286
+ if (newValue === void 0) {
287
+ newValue = source[key];
288
+ }
289
+ if (isNew) {
290
+ baseAssignValue(object, key, newValue);
291
+ } else {
292
+ assignValue(object, key, newValue);
293
+ }
294
+ }
295
+ return object;
296
+ }
215
297
  var MAX_SAFE_INTEGER = 9007199254740991;
216
298
  function isLength(value) {
217
299
  return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
@@ -219,9 +301,9 @@ function isLength(value) {
219
301
  function isArrayLike(value) {
220
302
  return value != null && isLength(value.length) && !isFunction(value);
221
303
  }
222
- var objectProto$9 = Object.prototype;
304
+ var objectProto$b = Object.prototype;
223
305
  function isPrototype(value) {
224
- var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto$9;
306
+ var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto$b;
225
307
  return value === proto;
226
308
  }
227
309
  function baseTimes(n, iteratee) {
@@ -231,34 +313,34 @@ function baseTimes(n, iteratee) {
231
313
  }
232
314
  return result;
233
315
  }
234
- var argsTag$2 = "[object Arguments]";
316
+ var argsTag$3 = "[object Arguments]";
235
317
  function baseIsArguments(value) {
236
- return isObjectLike(value) && baseGetTag(value) == argsTag$2;
318
+ return isObjectLike(value) && baseGetTag(value) == argsTag$3;
237
319
  }
238
- var objectProto$8 = Object.prototype;
239
- var hasOwnProperty$7 = objectProto$8.hasOwnProperty;
240
- var propertyIsEnumerable$1 = objectProto$8.propertyIsEnumerable;
320
+ var objectProto$a = Object.prototype;
321
+ var hasOwnProperty$9 = objectProto$a.hasOwnProperty;
322
+ var propertyIsEnumerable$1 = objectProto$a.propertyIsEnumerable;
241
323
  var isArguments = baseIsArguments(function() {
242
324
  return arguments;
243
325
  }()) ? baseIsArguments : function(value) {
244
- return isObjectLike(value) && hasOwnProperty$7.call(value, "callee") && !propertyIsEnumerable$1.call(value, "callee");
326
+ return isObjectLike(value) && hasOwnProperty$9.call(value, "callee") && !propertyIsEnumerable$1.call(value, "callee");
245
327
  };
246
328
  var isArguments$1 = isArguments;
247
329
  function stubFalse() {
248
330
  return false;
249
331
  }
250
- var freeExports$1 = typeof exports == "object" && exports && !exports.nodeType && exports;
251
- var freeModule$1 = freeExports$1 && typeof module == "object" && module && !module.nodeType && module;
252
- var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1;
253
- var Buffer = moduleExports$1 ? root$1.Buffer : void 0;
254
- var nativeIsBuffer = Buffer ? Buffer.isBuffer : void 0;
332
+ var freeExports$2 = typeof exports == "object" && exports && !exports.nodeType && exports;
333
+ var freeModule$2 = freeExports$2 && typeof module == "object" && module && !module.nodeType && module;
334
+ var moduleExports$2 = freeModule$2 && freeModule$2.exports === freeExports$2;
335
+ var Buffer$1 = moduleExports$2 ? root$1.Buffer : void 0;
336
+ var nativeIsBuffer = Buffer$1 ? Buffer$1.isBuffer : void 0;
255
337
  var isBuffer = nativeIsBuffer || stubFalse;
256
338
  var isBuffer$1 = isBuffer;
257
- var argsTag$1 = "[object Arguments]", arrayTag$1 = "[object Array]", boolTag$2 = "[object Boolean]", dateTag$1 = "[object Date]", errorTag$1 = "[object Error]", funcTag = "[object Function]", mapTag$4 = "[object Map]", numberTag$1 = "[object Number]", objectTag$2 = "[object Object]", regexpTag$1 = "[object RegExp]", setTag$4 = "[object Set]", stringTag$2 = "[object String]", weakMapTag$1 = "[object WeakMap]";
258
- var arrayBufferTag$1 = "[object ArrayBuffer]", dataViewTag$2 = "[object DataView]", float32Tag = "[object Float32Array]", float64Tag = "[object Float64Array]", int8Tag = "[object Int8Array]", int16Tag = "[object Int16Array]", int32Tag = "[object Int32Array]", uint8Tag = "[object Uint8Array]", uint8ClampedTag = "[object Uint8ClampedArray]", uint16Tag = "[object Uint16Array]", uint32Tag = "[object Uint32Array]";
339
+ var argsTag$2 = "[object Arguments]", arrayTag$2 = "[object Array]", boolTag$4 = "[object Boolean]", dateTag$3 = "[object Date]", errorTag$2 = "[object Error]", funcTag$1 = "[object Function]", mapTag$7 = "[object Map]", numberTag$3 = "[object Number]", objectTag$3 = "[object Object]", regexpTag$3 = "[object RegExp]", setTag$7 = "[object Set]", stringTag$4 = "[object String]", weakMapTag$2 = "[object WeakMap]";
340
+ var arrayBufferTag$3 = "[object ArrayBuffer]", dataViewTag$4 = "[object DataView]", float32Tag$2 = "[object Float32Array]", float64Tag$2 = "[object Float64Array]", int8Tag$2 = "[object Int8Array]", int16Tag$2 = "[object Int16Array]", int32Tag$2 = "[object Int32Array]", uint8Tag$2 = "[object Uint8Array]", uint8ClampedTag$2 = "[object Uint8ClampedArray]", uint16Tag$2 = "[object Uint16Array]", uint32Tag$2 = "[object Uint32Array]";
259
341
  var typedArrayTags = {};
260
- typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = typedArrayTags[uint32Tag] = true;
261
- typedArrayTags[argsTag$1] = typedArrayTags[arrayTag$1] = typedArrayTags[arrayBufferTag$1] = typedArrayTags[boolTag$2] = typedArrayTags[dataViewTag$2] = typedArrayTags[dateTag$1] = typedArrayTags[errorTag$1] = typedArrayTags[funcTag] = typedArrayTags[mapTag$4] = typedArrayTags[numberTag$1] = typedArrayTags[objectTag$2] = typedArrayTags[regexpTag$1] = typedArrayTags[setTag$4] = typedArrayTags[stringTag$2] = typedArrayTags[weakMapTag$1] = false;
342
+ typedArrayTags[float32Tag$2] = typedArrayTags[float64Tag$2] = typedArrayTags[int8Tag$2] = typedArrayTags[int16Tag$2] = typedArrayTags[int32Tag$2] = typedArrayTags[uint8Tag$2] = typedArrayTags[uint8ClampedTag$2] = typedArrayTags[uint16Tag$2] = typedArrayTags[uint32Tag$2] = true;
343
+ typedArrayTags[argsTag$2] = typedArrayTags[arrayTag$2] = typedArrayTags[arrayBufferTag$3] = typedArrayTags[boolTag$4] = typedArrayTags[dataViewTag$4] = typedArrayTags[dateTag$3] = typedArrayTags[errorTag$2] = typedArrayTags[funcTag$1] = typedArrayTags[mapTag$7] = typedArrayTags[numberTag$3] = typedArrayTags[objectTag$3] = typedArrayTags[regexpTag$3] = typedArrayTags[setTag$7] = typedArrayTags[stringTag$4] = typedArrayTags[weakMapTag$2] = false;
262
344
  function baseIsTypedArray(value) {
263
345
  return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
264
346
  }
@@ -267,13 +349,13 @@ function baseUnary(func) {
267
349
  return func(value);
268
350
  };
269
351
  }
270
- var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
271
- var freeModule = freeExports && typeof module == "object" && module && !module.nodeType && module;
272
- var moduleExports = freeModule && freeModule.exports === freeExports;
273
- var freeProcess = moduleExports && freeGlobal$1.process;
352
+ var freeExports$1 = typeof exports == "object" && exports && !exports.nodeType && exports;
353
+ var freeModule$1 = freeExports$1 && typeof module == "object" && module && !module.nodeType && module;
354
+ var moduleExports$1 = freeModule$1 && freeModule$1.exports === freeExports$1;
355
+ var freeProcess = moduleExports$1 && freeGlobal$1.process;
274
356
  var nodeUtil = function() {
275
357
  try {
276
- var types = freeModule && freeModule.require && freeModule.require("util").types;
358
+ var types = freeModule$1 && freeModule$1.require && freeModule$1.require("util").types;
277
359
  if (types) {
278
360
  return types;
279
361
  }
@@ -285,12 +367,12 @@ var nodeUtil$1 = nodeUtil;
285
367
  var nodeIsTypedArray = nodeUtil$1 && nodeUtil$1.isTypedArray;
286
368
  var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
287
369
  var isTypedArray$1 = isTypedArray;
288
- var objectProto$7 = Object.prototype;
289
- var hasOwnProperty$6 = objectProto$7.hasOwnProperty;
370
+ var objectProto$9 = Object.prototype;
371
+ var hasOwnProperty$8 = objectProto$9.hasOwnProperty;
290
372
  function arrayLikeKeys(value, inherited) {
291
373
  var isArr = isArray$1(value), isArg = !isArr && isArguments$1(value), isBuff = !isArr && !isArg && isBuffer$1(value), isType = !isArr && !isArg && !isBuff && isTypedArray$1(value), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? baseTimes(value.length, String) : [], length = result.length;
292
374
  for (var key in value) {
293
- if ((inherited || hasOwnProperty$6.call(value, key)) && !(skipIndexes && (key == "length" || isBuff && (key == "offset" || key == "parent") || isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || isIndex(key, length)))) {
375
+ if ((inherited || hasOwnProperty$8.call(value, key)) && !(skipIndexes && (key == "length" || isBuff && (key == "offset" || key == "parent") || isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || isIndex(key, length)))) {
294
376
  result.push(key);
295
377
  }
296
378
  }
@@ -303,15 +385,15 @@ function overArg(func, transform) {
303
385
  }
304
386
  var nativeKeys = overArg(Object.keys, Object);
305
387
  var nativeKeys$1 = nativeKeys;
306
- var objectProto$6 = Object.prototype;
307
- var hasOwnProperty$5 = objectProto$6.hasOwnProperty;
388
+ var objectProto$8 = Object.prototype;
389
+ var hasOwnProperty$7 = objectProto$8.hasOwnProperty;
308
390
  function baseKeys(object) {
309
391
  if (!isPrototype(object)) {
310
392
  return nativeKeys$1(object);
311
393
  }
312
394
  var result = [];
313
395
  for (var key in Object(object)) {
314
- if (hasOwnProperty$5.call(object, key) && key != "constructor") {
396
+ if (hasOwnProperty$7.call(object, key) && key != "constructor") {
315
397
  result.push(key);
316
398
  }
317
399
  }
@@ -320,6 +402,32 @@ function baseKeys(object) {
320
402
  function keys(object) {
321
403
  return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
322
404
  }
405
+ function nativeKeysIn(object) {
406
+ var result = [];
407
+ if (object != null) {
408
+ for (var key in Object(object)) {
409
+ result.push(key);
410
+ }
411
+ }
412
+ return result;
413
+ }
414
+ var objectProto$7 = Object.prototype;
415
+ var hasOwnProperty$6 = objectProto$7.hasOwnProperty;
416
+ function baseKeysIn(object) {
417
+ if (!isObject(object)) {
418
+ return nativeKeysIn(object);
419
+ }
420
+ var isProto = isPrototype(object), result = [];
421
+ for (var key in object) {
422
+ if (!(key == "constructor" && (isProto || !hasOwnProperty$6.call(object, key)))) {
423
+ result.push(key);
424
+ }
425
+ }
426
+ return result;
427
+ }
428
+ function keysIn(object) {
429
+ return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);
430
+ }
323
431
  var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/, reIsPlainProp = /^\w*$/;
324
432
  function isKey(value, object) {
325
433
  if (isArray$1(value)) {
@@ -343,21 +451,21 @@ function hashDelete(key) {
343
451
  return result;
344
452
  }
345
453
  var HASH_UNDEFINED$2 = "__lodash_hash_undefined__";
346
- var objectProto$5 = Object.prototype;
347
- var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
454
+ var objectProto$6 = Object.prototype;
455
+ var hasOwnProperty$5 = objectProto$6.hasOwnProperty;
348
456
  function hashGet(key) {
349
457
  var data = this.__data__;
350
458
  if (nativeCreate$1) {
351
459
  var result = data[key];
352
460
  return result === HASH_UNDEFINED$2 ? void 0 : result;
353
461
  }
354
- return hasOwnProperty$4.call(data, key) ? data[key] : void 0;
462
+ return hasOwnProperty$5.call(data, key) ? data[key] : void 0;
355
463
  }
356
- var objectProto$4 = Object.prototype;
357
- var hasOwnProperty$3 = objectProto$4.hasOwnProperty;
464
+ var objectProto$5 = Object.prototype;
465
+ var hasOwnProperty$4 = objectProto$5.hasOwnProperty;
358
466
  function hashHas(key) {
359
467
  var data = this.__data__;
360
- return nativeCreate$1 ? data[key] !== void 0 : hasOwnProperty$3.call(data, key);
468
+ return nativeCreate$1 ? data[key] !== void 0 : hasOwnProperty$4.call(data, key);
361
469
  }
362
470
  var HASH_UNDEFINED$1 = "__lodash_hash_undefined__";
363
471
  function hashSet(key, value) {
@@ -564,6 +672,8 @@ function arrayPush(array, values) {
564
672
  }
565
673
  return array;
566
674
  }
675
+ var getPrototype = overArg(Object.getPrototypeOf, Object);
676
+ var getPrototype$1 = getPrototype;
567
677
  var rsAstralRange$1 = "\\ud800-\\udfff", rsComboMarksRange$1 = "\\u0300-\\u036f", reComboHalfMarksRange$1 = "\\ufe20-\\ufe2f", rsComboSymbolsRange$1 = "\\u20d0-\\u20ff", rsComboRange$1 = rsComboMarksRange$1 + reComboHalfMarksRange$1 + rsComboSymbolsRange$1, rsVarRange$1 = "\\ufe0e\\ufe0f";
568
678
  var rsZWJ$1 = "\\u200d";
569
679
  var reHasUnicode = RegExp("[" + rsZWJ$1 + rsAstralRange$1 + rsComboRange$1 + rsVarRange$1 + "]");
@@ -620,6 +730,24 @@ Stack.prototype["delete"] = stackDelete;
620
730
  Stack.prototype.get = stackGet;
621
731
  Stack.prototype.has = stackHas;
622
732
  Stack.prototype.set = stackSet;
733
+ function baseAssign(object, source) {
734
+ return object && copyObject(source, keys(source), object);
735
+ }
736
+ function baseAssignIn(object, source) {
737
+ return object && copyObject(source, keysIn(source), object);
738
+ }
739
+ var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
740
+ var freeModule = freeExports && typeof module == "object" && module && !module.nodeType && module;
741
+ var moduleExports = freeModule && freeModule.exports === freeExports;
742
+ var Buffer = moduleExports ? root$1.Buffer : void 0, allocUnsafe = Buffer ? Buffer.allocUnsafe : void 0;
743
+ function cloneBuffer(buffer, isDeep) {
744
+ if (isDeep) {
745
+ return buffer.slice();
746
+ }
747
+ var length = buffer.length, result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);
748
+ buffer.copy(result);
749
+ return result;
750
+ }
623
751
  function arrayFilter(array, predicate) {
624
752
  var index2 = -1, length = array == null ? 0 : array.length, resIndex = 0, result = [];
625
753
  while (++index2 < length) {
@@ -633,19 +761,35 @@ function arrayFilter(array, predicate) {
633
761
  function stubArray() {
634
762
  return [];
635
763
  }
636
- var objectProto$3 = Object.prototype;
637
- var propertyIsEnumerable = objectProto$3.propertyIsEnumerable;
638
- var nativeGetSymbols = Object.getOwnPropertySymbols;
639
- var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
764
+ var objectProto$4 = Object.prototype;
765
+ var propertyIsEnumerable = objectProto$4.propertyIsEnumerable;
766
+ var nativeGetSymbols$1 = Object.getOwnPropertySymbols;
767
+ var getSymbols = !nativeGetSymbols$1 ? stubArray : function(object) {
640
768
  if (object == null) {
641
769
  return [];
642
770
  }
643
771
  object = Object(object);
644
- return arrayFilter(nativeGetSymbols(object), function(symbol) {
772
+ return arrayFilter(nativeGetSymbols$1(object), function(symbol) {
645
773
  return propertyIsEnumerable.call(object, symbol);
646
774
  });
647
775
  };
648
776
  var getSymbols$1 = getSymbols;
777
+ function copySymbols(source, object) {
778
+ return copyObject(source, getSymbols$1(source), object);
779
+ }
780
+ var nativeGetSymbols = Object.getOwnPropertySymbols;
781
+ var getSymbolsIn = !nativeGetSymbols ? stubArray : function(object) {
782
+ var result = [];
783
+ while (object) {
784
+ arrayPush(result, getSymbols$1(object));
785
+ object = getPrototype$1(object);
786
+ }
787
+ return result;
788
+ };
789
+ var getSymbolsIn$1 = getSymbolsIn;
790
+ function copySymbolsIn(source, object) {
791
+ return copyObject(source, getSymbolsIn$1(source), object);
792
+ }
649
793
  function baseGetAllKeys(object, keysFunc, symbolsFunc) {
650
794
  var result = keysFunc(object);
651
795
  return isArray$1(object) ? result : arrayPush(result, symbolsFunc(object));
@@ -653,39 +797,197 @@ function baseGetAllKeys(object, keysFunc, symbolsFunc) {
653
797
  function getAllKeys(object) {
654
798
  return baseGetAllKeys(object, keys, getSymbols$1);
655
799
  }
800
+ function getAllKeysIn(object) {
801
+ return baseGetAllKeys(object, keysIn, getSymbolsIn$1);
802
+ }
656
803
  var DataView = getNative(root$1, "DataView");
657
804
  var DataView$1 = DataView;
658
805
  var Promise$1 = getNative(root$1, "Promise");
659
806
  var Promise$2 = Promise$1;
660
807
  var Set = getNative(root$1, "Set");
661
808
  var Set$1 = Set;
662
- var mapTag$3 = "[object Map]", objectTag$1 = "[object Object]", promiseTag = "[object Promise]", setTag$3 = "[object Set]", weakMapTag = "[object WeakMap]";
663
- var dataViewTag$1 = "[object DataView]";
809
+ var mapTag$6 = "[object Map]", objectTag$2 = "[object Object]", promiseTag = "[object Promise]", setTag$6 = "[object Set]", weakMapTag$1 = "[object WeakMap]";
810
+ var dataViewTag$3 = "[object DataView]";
664
811
  var dataViewCtorString = toSource(DataView$1), mapCtorString = toSource(Map$1), promiseCtorString = toSource(Promise$2), setCtorString = toSource(Set$1), weakMapCtorString = toSource(WeakMap$1);
665
812
  var getTag = baseGetTag;
666
- if (DataView$1 && getTag(new DataView$1(new ArrayBuffer(1))) != dataViewTag$1 || Map$1 && getTag(new Map$1()) != mapTag$3 || Promise$2 && getTag(Promise$2.resolve()) != promiseTag || Set$1 && getTag(new Set$1()) != setTag$3 || WeakMap$1 && getTag(new WeakMap$1()) != weakMapTag) {
813
+ if (DataView$1 && getTag(new DataView$1(new ArrayBuffer(1))) != dataViewTag$3 || Map$1 && getTag(new Map$1()) != mapTag$6 || Promise$2 && getTag(Promise$2.resolve()) != promiseTag || Set$1 && getTag(new Set$1()) != setTag$6 || WeakMap$1 && getTag(new WeakMap$1()) != weakMapTag$1) {
667
814
  getTag = function(value) {
668
- var result = baseGetTag(value), Ctor = result == objectTag$1 ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
815
+ var result = baseGetTag(value), Ctor = result == objectTag$2 ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
669
816
  if (ctorString) {
670
817
  switch (ctorString) {
671
818
  case dataViewCtorString:
672
- return dataViewTag$1;
819
+ return dataViewTag$3;
673
820
  case mapCtorString:
674
- return mapTag$3;
821
+ return mapTag$6;
675
822
  case promiseCtorString:
676
823
  return promiseTag;
677
824
  case setCtorString:
678
- return setTag$3;
825
+ return setTag$6;
679
826
  case weakMapCtorString:
680
- return weakMapTag;
827
+ return weakMapTag$1;
681
828
  }
682
829
  }
683
830
  return result;
684
831
  };
685
832
  }
686
833
  var getTag$1 = getTag;
834
+ var objectProto$3 = Object.prototype;
835
+ var hasOwnProperty$3 = objectProto$3.hasOwnProperty;
836
+ function initCloneArray(array) {
837
+ var length = array.length, result = new array.constructor(length);
838
+ if (length && typeof array[0] == "string" && hasOwnProperty$3.call(array, "index")) {
839
+ result.index = array.index;
840
+ result.input = array.input;
841
+ }
842
+ return result;
843
+ }
687
844
  var Uint8Array = root$1.Uint8Array;
688
845
  var Uint8Array$1 = Uint8Array;
846
+ function cloneArrayBuffer(arrayBuffer) {
847
+ var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
848
+ new Uint8Array$1(result).set(new Uint8Array$1(arrayBuffer));
849
+ return result;
850
+ }
851
+ function cloneDataView(dataView, isDeep) {
852
+ var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer;
853
+ return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);
854
+ }
855
+ var reFlags = /\w*$/;
856
+ function cloneRegExp(regexp) {
857
+ var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));
858
+ result.lastIndex = regexp.lastIndex;
859
+ return result;
860
+ }
861
+ var symbolProto$1 = Symbol$2 ? Symbol$2.prototype : void 0, symbolValueOf$1 = symbolProto$1 ? symbolProto$1.valueOf : void 0;
862
+ function cloneSymbol(symbol) {
863
+ return symbolValueOf$1 ? Object(symbolValueOf$1.call(symbol)) : {};
864
+ }
865
+ function cloneTypedArray(typedArray, isDeep) {
866
+ var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;
867
+ return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
868
+ }
869
+ var boolTag$3 = "[object Boolean]", dateTag$2 = "[object Date]", mapTag$5 = "[object Map]", numberTag$2 = "[object Number]", regexpTag$2 = "[object RegExp]", setTag$5 = "[object Set]", stringTag$3 = "[object String]", symbolTag$2 = "[object Symbol]";
870
+ var arrayBufferTag$2 = "[object ArrayBuffer]", dataViewTag$2 = "[object DataView]", float32Tag$1 = "[object Float32Array]", float64Tag$1 = "[object Float64Array]", int8Tag$1 = "[object Int8Array]", int16Tag$1 = "[object Int16Array]", int32Tag$1 = "[object Int32Array]", uint8Tag$1 = "[object Uint8Array]", uint8ClampedTag$1 = "[object Uint8ClampedArray]", uint16Tag$1 = "[object Uint16Array]", uint32Tag$1 = "[object Uint32Array]";
871
+ function initCloneByTag(object, tag, isDeep) {
872
+ var Ctor = object.constructor;
873
+ switch (tag) {
874
+ case arrayBufferTag$2:
875
+ return cloneArrayBuffer(object);
876
+ case boolTag$3:
877
+ case dateTag$2:
878
+ return new Ctor(+object);
879
+ case dataViewTag$2:
880
+ return cloneDataView(object, isDeep);
881
+ case float32Tag$1:
882
+ case float64Tag$1:
883
+ case int8Tag$1:
884
+ case int16Tag$1:
885
+ case int32Tag$1:
886
+ case uint8Tag$1:
887
+ case uint8ClampedTag$1:
888
+ case uint16Tag$1:
889
+ case uint32Tag$1:
890
+ return cloneTypedArray(object, isDeep);
891
+ case mapTag$5:
892
+ return new Ctor();
893
+ case numberTag$2:
894
+ case stringTag$3:
895
+ return new Ctor(object);
896
+ case regexpTag$2:
897
+ return cloneRegExp(object);
898
+ case setTag$5:
899
+ return new Ctor();
900
+ case symbolTag$2:
901
+ return cloneSymbol(object);
902
+ }
903
+ }
904
+ function initCloneObject(object) {
905
+ return typeof object.constructor == "function" && !isPrototype(object) ? baseCreate$1(getPrototype$1(object)) : {};
906
+ }
907
+ var mapTag$4 = "[object Map]";
908
+ function baseIsMap(value) {
909
+ return isObjectLike(value) && getTag$1(value) == mapTag$4;
910
+ }
911
+ var nodeIsMap = nodeUtil$1 && nodeUtil$1.isMap;
912
+ var isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;
913
+ var isMap$1 = isMap;
914
+ var setTag$4 = "[object Set]";
915
+ function baseIsSet(value) {
916
+ return isObjectLike(value) && getTag$1(value) == setTag$4;
917
+ }
918
+ var nodeIsSet = nodeUtil$1 && nodeUtil$1.isSet;
919
+ var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;
920
+ var isSet$1 = isSet;
921
+ var CLONE_DEEP_FLAG = 1, CLONE_FLAT_FLAG = 2, CLONE_SYMBOLS_FLAG$1 = 4;
922
+ var argsTag$1 = "[object Arguments]", arrayTag$1 = "[object Array]", boolTag$2 = "[object Boolean]", dateTag$1 = "[object Date]", errorTag$1 = "[object Error]", funcTag = "[object Function]", genTag = "[object GeneratorFunction]", mapTag$3 = "[object Map]", numberTag$1 = "[object Number]", objectTag$1 = "[object Object]", regexpTag$1 = "[object RegExp]", setTag$3 = "[object Set]", stringTag$2 = "[object String]", symbolTag$1 = "[object Symbol]", weakMapTag = "[object WeakMap]";
923
+ var arrayBufferTag$1 = "[object ArrayBuffer]", dataViewTag$1 = "[object DataView]", float32Tag = "[object Float32Array]", float64Tag = "[object Float64Array]", int8Tag = "[object Int8Array]", int16Tag = "[object Int16Array]", int32Tag = "[object Int32Array]", uint8Tag = "[object Uint8Array]", uint8ClampedTag = "[object Uint8ClampedArray]", uint16Tag = "[object Uint16Array]", uint32Tag = "[object Uint32Array]";
924
+ var cloneableTags = {};
925
+ cloneableTags[argsTag$1] = cloneableTags[arrayTag$1] = cloneableTags[arrayBufferTag$1] = cloneableTags[dataViewTag$1] = cloneableTags[boolTag$2] = cloneableTags[dateTag$1] = cloneableTags[float32Tag] = cloneableTags[float64Tag] = cloneableTags[int8Tag] = cloneableTags[int16Tag] = cloneableTags[int32Tag] = cloneableTags[mapTag$3] = cloneableTags[numberTag$1] = cloneableTags[objectTag$1] = cloneableTags[regexpTag$1] = cloneableTags[setTag$3] = cloneableTags[stringTag$2] = cloneableTags[symbolTag$1] = cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] = cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;
926
+ cloneableTags[errorTag$1] = cloneableTags[funcTag] = cloneableTags[weakMapTag] = false;
927
+ function baseClone(value, bitmask, customizer, key, object, stack) {
928
+ var result, isDeep = bitmask & CLONE_DEEP_FLAG, isFlat = bitmask & CLONE_FLAT_FLAG, isFull = bitmask & CLONE_SYMBOLS_FLAG$1;
929
+ if (customizer) {
930
+ result = object ? customizer(value, key, object, stack) : customizer(value);
931
+ }
932
+ if (result !== void 0) {
933
+ return result;
934
+ }
935
+ if (!isObject(value)) {
936
+ return value;
937
+ }
938
+ var isArr = isArray$1(value);
939
+ if (isArr) {
940
+ result = initCloneArray(value);
941
+ if (!isDeep) {
942
+ return copyArray(value, result);
943
+ }
944
+ } else {
945
+ var tag = getTag$1(value), isFunc = tag == funcTag || tag == genTag;
946
+ if (isBuffer$1(value)) {
947
+ return cloneBuffer(value, isDeep);
948
+ }
949
+ if (tag == objectTag$1 || tag == argsTag$1 || isFunc && !object) {
950
+ result = isFlat || isFunc ? {} : initCloneObject(value);
951
+ if (!isDeep) {
952
+ return isFlat ? copySymbolsIn(value, baseAssignIn(result, value)) : copySymbols(value, baseAssign(result, value));
953
+ }
954
+ } else {
955
+ if (!cloneableTags[tag]) {
956
+ return object ? value : {};
957
+ }
958
+ result = initCloneByTag(value, tag, isDeep);
959
+ }
960
+ }
961
+ stack || (stack = new Stack());
962
+ var stacked = stack.get(value);
963
+ if (stacked) {
964
+ return stacked;
965
+ }
966
+ stack.set(value, result);
967
+ if (isSet$1(value)) {
968
+ value.forEach(function(subValue) {
969
+ result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));
970
+ });
971
+ } else if (isMap$1(value)) {
972
+ value.forEach(function(subValue, key2) {
973
+ result.set(key2, baseClone(subValue, bitmask, customizer, key2, value, stack));
974
+ });
975
+ }
976
+ var keysFunc = isFull ? isFlat ? getAllKeysIn : getAllKeys : isFlat ? keysIn : keys;
977
+ var props = isArr ? void 0 : keysFunc(value);
978
+ arrayEach(props || value, function(subValue, key2) {
979
+ if (props) {
980
+ key2 = subValue;
981
+ subValue = value[key2];
982
+ }
983
+ assignValue(result, key2, baseClone(subValue, bitmask, customizer, key2, value, stack));
984
+ });
985
+ return result;
986
+ }
987
+ var CLONE_SYMBOLS_FLAG = 4;
988
+ function clone(value) {
989
+ return baseClone(value, CLONE_SYMBOLS_FLAG);
990
+ }
689
991
  var HASH_UNDEFINED = "__lodash_hash_undefined__";
690
992
  function setCacheAdd(value) {
691
993
  this.__data__.set(value, HASH_UNDEFINED);
@@ -1152,6 +1454,19 @@ function debounce(func, wait, options) {
1152
1454
  debounced.flush = flush;
1153
1455
  return debounced;
1154
1456
  }
1457
+ function baseFilter(collection, predicate) {
1458
+ var result = [];
1459
+ baseEach$1(collection, function(value, index2, collection2) {
1460
+ if (predicate(value, index2, collection2)) {
1461
+ result.push(value);
1462
+ }
1463
+ });
1464
+ return result;
1465
+ }
1466
+ function filter(collection, predicate) {
1467
+ var func = isArray$1(collection) ? arrayFilter : baseFilter;
1468
+ return func(collection, baseIteratee(predicate));
1469
+ }
1155
1470
  var stringTag = "[object String]";
1156
1471
  function isString(value) {
1157
1472
  return typeof value == "string" || !isArray$1(value) && isObjectLike(value) && baseGetTag(value) == stringTag;
@@ -1248,20 +1563,20 @@ const createResizeObserver = (params) => {
1248
1563
  if (!actualWrapper || !container || !adaptive || !s22) {
1249
1564
  return;
1250
1565
  }
1251
- const render = (width, height) => {
1566
+ const render2 = (width, height) => {
1252
1567
  s22 == null ? void 0 : s22.changeSheetSize(width, height);
1253
1568
  s22 == null ? void 0 : s22.render(false);
1254
1569
  };
1255
- const debounceRender = debounce(render, RESIZE_RENDER_DELAY);
1570
+ const debounceRender = debounce(render2, RESIZE_RENDER_DELAY);
1256
1571
  const onResize = () => {
1257
- const { width: nodeWidth, height: nodeHeight } = container == null ? void 0 : container.getBoundingClientRect();
1258
- const width = adaptiveWidth ? Math.floor(nodeWidth != null ? nodeWidth : s22.options.width) : s22.options.width;
1259
- const height = adaptiveHeight ? Math.floor(nodeHeight != null ? nodeHeight : s22.options.height) : s22.options.height;
1572
+ const { clientWidth: containerWidth, clientHeight: containerHeight } = container;
1573
+ const width = adaptiveWidth ? Math.floor(containerWidth != null ? containerWidth : s22.options.width) : s22.options.width;
1574
+ const height = adaptiveHeight ? Math.floor(containerHeight != null ? containerHeight : s22.options.height) : s22.options.height;
1260
1575
  if (!adaptiveWidth && !adaptiveHeight) {
1261
1576
  return;
1262
1577
  }
1263
1578
  if (isFirstRender) {
1264
- render(width, height);
1579
+ render2(width, height);
1265
1580
  isFirstRender = false;
1266
1581
  return;
1267
1582
  }
@@ -1279,6 +1594,99 @@ const createResizeObserver = (params) => {
1279
1594
  resizeObserver.unobserve(actualWrapper);
1280
1595
  };
1281
1596
  };
1597
+ const getDrillDownCache = (spreadsheet, meta) => {
1598
+ const drillDownDataCache = spreadsheet.store.get("drillDownDataCache", []);
1599
+ const cache = drillDownDataCache.find((dc) => dc.rowId === meta.id);
1600
+ return {
1601
+ drillDownDataCache,
1602
+ drillDownCurrentCache: cache
1603
+ };
1604
+ };
1605
+ const handleActionIconClick = (params) => {
1606
+ const { meta, event, callback } = params;
1607
+ const { spreadsheet } = meta;
1608
+ spreadsheet.store.set("drillDownNode", meta);
1609
+ const { drillDownDataCache, drillDownCurrentCache } = getDrillDownCache(spreadsheet, meta);
1610
+ const cache = (drillDownCurrentCache == null ? void 0 : drillDownCurrentCache.drillField) ? [drillDownCurrentCache == null ? void 0 : drillDownCurrentCache.drillField] : [];
1611
+ const disabled = [];
1612
+ drillDownDataCache.forEach((val) => {
1613
+ if (meta.id.includes(val.rowId) && meta.id !== val.rowId) {
1614
+ disabled.push(val.drillField);
1615
+ }
1616
+ });
1617
+ if (event) {
1618
+ spreadsheet.emit(s2.S2Event.GLOBAL_ACTION_ICON_CLICK, event);
1619
+ }
1620
+ callback({
1621
+ sheetInstance: spreadsheet,
1622
+ cacheDrillFields: cache,
1623
+ disabledFields: disabled,
1624
+ event
1625
+ });
1626
+ };
1627
+ const defaultDisplayCondition = (meta) => {
1628
+ const iconLevel = get(meta, "spreadsheet.dataCfg.fields.rows.length") - 1;
1629
+ return iconLevel <= meta.level && meta.spreadsheet.options.hierarchyType === "tree" && meta.spreadsheet.isValueInCols() && meta.label !== s2.i18n("\u603B\u8BA1");
1630
+ };
1631
+ const buildDrillDownOptions = (options, partDrillDown, callback) => {
1632
+ var _a;
1633
+ const nextHeaderIcons = ((_a = options.headerActionIcons) == null ? void 0 : _a.length) ? [...options.headerActionIcons] : [];
1634
+ if (!isEmpty(partDrillDown)) {
1635
+ const drillDownActionIcon = {
1636
+ belongsCell: "rowCell",
1637
+ iconNames: ["DrillDownIcon"],
1638
+ defaultHide: true,
1639
+ displayCondition: partDrillDown.displayCondition || defaultDisplayCondition,
1640
+ action: (actionIconProps) => {
1641
+ const { iconName, meta, event } = actionIconProps;
1642
+ if (iconName === "DrillDownIcon") {
1643
+ meta.spreadsheet.store.set("drillDownNode", meta);
1644
+ handleActionIconClick({
1645
+ meta,
1646
+ event,
1647
+ callback
1648
+ });
1649
+ }
1650
+ }
1651
+ };
1652
+ nextHeaderIcons.push(drillDownActionIcon);
1653
+ }
1654
+ return __spreadProps(__spreadValues({}, options), {
1655
+ headerActionIcons: nextHeaderIcons
1656
+ });
1657
+ };
1658
+ const handleDrillDown = (params) => {
1659
+ const { fetchData, spreadsheet, drillFields, drillItemsNum } = params;
1660
+ if (drillItemsNum) {
1661
+ spreadsheet.store.set("drillItemsNum", drillItemsNum);
1662
+ }
1663
+ const meta = spreadsheet.store.get("drillDownNode");
1664
+ const { drillDownDataCache, drillDownCurrentCache } = getDrillDownCache(spreadsheet, meta);
1665
+ let newDrillDownDataCache = clone(drillDownDataCache);
1666
+ if (drillDownCurrentCache) {
1667
+ newDrillDownDataCache = filter(drillDownDataCache, (cache) => cache.rowId !== meta.id);
1668
+ }
1669
+ if (!fetchData) {
1670
+ return;
1671
+ }
1672
+ fetchData(meta, drillFields).then((info) => {
1673
+ const { drillData, drillField } = info;
1674
+ spreadsheet.dataSet.transformDrillDownData(drillField, drillData, meta);
1675
+ if (!isEmpty(drillData)) {
1676
+ const drillLevel = meta.level + 1;
1677
+ const newDrillDownData = {
1678
+ rowId: meta.id,
1679
+ drillLevel,
1680
+ drillData,
1681
+ drillField
1682
+ };
1683
+ newDrillDownDataCache.push(newDrillDownData);
1684
+ spreadsheet.store.set("drillDownDataCache", newDrillDownDataCache);
1685
+ }
1686
+ spreadsheet.interaction.reset();
1687
+ spreadsheet.render(false);
1688
+ });
1689
+ };
1282
1690
  const EN_US = {
1283
1691
  \u9009\u62E9\u5206\u6790\u4FE1\u606F: "Select Analysis Information",
1284
1692
  \u5207\u6362\u6307\u6807: "Switch indicator",
@@ -1306,7 +1714,16 @@ const EN_US = {
1306
1714
  \u53EF\u9009\u5B57\u6BB5: "Fields",
1307
1715
  "\u6309\u4EE5\u4E0B\u89C4\u5219\u8FDB\u884C\u6392\u5E8F\uFF08\u4F18\u5148\u7EA7\u7531\u4F4E\u5230\u9AD8\uFF09": "Order according to the following rules (from low to high priority)",
1308
1716
  \u6309: "By",
1309
- \u8BF4\u660E: "Description"
1717
+ \u8BF4\u660E: "Description",
1718
+ \u590D\u5236\u539F\u59CB\u6570\u636E: "Copy raw data",
1719
+ \u590D\u5236\u683C\u5F0F\u5316\u6570\u636E: "Copy formatted data",
1720
+ \u4E0B\u8F7D\u539F\u59CB\u6570\u636E: "Download raw data",
1721
+ \u4E0B\u8F7D\u683C\u5F0F\u5316\u6570\u636E: "Download formatted data",
1722
+ \u64CD\u4F5C\u6210\u529F: "Operation successful",
1723
+ \u64CD\u4F5C\u5931\u8D25: "Operation failed",
1724
+ \u65F6\u95F4: "Date",
1725
+ \u6307\u6807: "Measure",
1726
+ \u76EE\u6807\u503C: "Target Value"
1310
1727
  };
1311
1728
  const ZH_CN = {
1312
1729
  \u9009\u62E9\u5206\u6790\u4FE1\u606F: "\u9009\u62E9\u5206\u6790\u4FE1\u606F",
@@ -1335,12 +1752,22 @@ const ZH_CN = {
1335
1752
  \u53EF\u9009\u5B57\u6BB5: "\u53EF\u9009\u5B57\u6BB5",
1336
1753
  "\u6309\u4EE5\u4E0B\u89C4\u5219\u8FDB\u884C\u6392\u5E8F\uFF08\u4F18\u5148\u7EA7\u7531\u4F4E\u5230\u9AD8\uFF09": "\u6309\u4EE5\u4E0B\u89C4\u5219\u8FDB\u884C\u6392\u5E8F\uFF08\u4F18\u5148\u7EA7\u7531\u4F4E\u5230\u9AD8\uFF09",
1337
1754
  \u6309: "\u6309",
1338
- \u8BF4\u660E: "\u8BF4\u660E"
1755
+ \u8BF4\u660E: "\u8BF4\u660E",
1756
+ \u590D\u5236\u539F\u59CB\u6570\u636E: "\u590D\u5236\u539F\u59CB\u6570\u636E",
1757
+ \u590D\u5236\u683C\u5F0F\u5316\u6570\u636E: "\u590D\u5236\u683C\u5F0F\u5316\u6570\u636E",
1758
+ \u4E0B\u8F7D\u539F\u59CB\u6570\u636E: "\u4E0B\u8F7D\u539F\u59CB\u6570\u636E",
1759
+ \u4E0B\u8F7D\u683C\u5F0F\u5316\u6570\u636E: "\u4E0B\u8F7D\u683C\u5F0F\u5316\u6570\u636E",
1760
+ \u64CD\u4F5C\u6210\u529F: "\u64CD\u4F5C\u6210\u529F",
1761
+ \u64CD\u4F5C\u5931\u8D25: "\u64CD\u4F5C\u5931\u8D25",
1762
+ \u65F6\u95F4: "\u65F6\u95F4",
1763
+ \u6307\u6807: "\u6307\u6807",
1764
+ \u76EE\u6807\u503C: "\u76EE\u6807\u503C"
1339
1765
  };
1340
1766
  const Locale = {
1341
1767
  zh_CN: ZH_CN,
1342
1768
  en_US: EN_US
1343
1769
  };
1770
+ const DRILL_DOWN_PRE_CLASS = "s2-drill-down";
1344
1771
  s2.extendLocale(Locale);
1345
1772
  const useExpose = (expose) => {
1346
1773
  const s2Ref = vue.shallowRef();
@@ -1426,7 +1853,7 @@ var _export_sfc = (sfc, props) => {
1426
1853
  return target;
1427
1854
  };
1428
1855
  const PRE_CLASS = `${s2.S2_PREFIX_CLS}-pagination`;
1429
- const _sfc_main$d = vue.defineComponent({
1856
+ const _sfc_main$e = vue.defineComponent({
1430
1857
  name: "s2-pagination",
1431
1858
  props: {
1432
1859
  current: {
@@ -1457,7 +1884,7 @@ const _sfc_main$d = vue.defineComponent({
1457
1884
  AntDPagination: antDesignVue.Pagination
1458
1885
  }
1459
1886
  });
1460
- function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
1887
+ function _sfc_render$e(_ctx, _cache, $props, $setup, $data, $options) {
1461
1888
  const _component_AntDPagination = vue.resolveComponent("AntDPagination");
1462
1889
  return vue.openBlock(), vue.createElementBlock("div", {
1463
1890
  class: vue.normalizeClass(_ctx.PRE_CLASS)
@@ -1478,8 +1905,8 @@ function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
1478
1905
  }, vue.toDisplayString(_ctx.i18n("\u5171\u8BA1")) + " " + vue.toDisplayString(_ctx.total || " - ") + " " + vue.toDisplayString(_ctx.i18n("\u6761")), 3)
1479
1906
  ], 2);
1480
1907
  }
1481
- var S2Pagination = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["render", _sfc_render$d]]);
1482
- const _sfc_main$c = vue.defineComponent({
1908
+ var S2Pagination = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["render", _sfc_render$e]]);
1909
+ const _sfc_main$d = vue.defineComponent({
1483
1910
  name: "TooltipDetail",
1484
1911
  props: ["list"],
1485
1912
  setup() {
@@ -1488,7 +1915,7 @@ const _sfc_main$c = vue.defineComponent({
1488
1915
  };
1489
1916
  }
1490
1917
  });
1491
- function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
1918
+ function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
1492
1919
  return vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.list, (item, index2) => {
1493
1920
  return vue.openBlock(), vue.createElementBlock("div", {
1494
1921
  key: `${item.value}-${index2}`,
@@ -1507,8 +1934,8 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
1507
1934
  ], 2);
1508
1935
  }), 128);
1509
1936
  }
1510
- var TooltipDetail = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["render", _sfc_render$c]]);
1511
- const _sfc_main$b = vue.defineComponent({
1937
+ var TooltipDetail = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["render", _sfc_render$d]]);
1938
+ const _sfc_main$c = vue.defineComponent({
1512
1939
  name: "TooltipHeadInfo",
1513
1940
  props: ["rows", "cols"],
1514
1941
  setup() {
@@ -1518,8 +1945,8 @@ const _sfc_main$b = vue.defineComponent({
1518
1945
  },
1519
1946
  components: {}
1520
1947
  });
1521
- const _hoisted_1$1 = { key: 0 };
1522
- function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
1948
+ const _hoisted_1$4 = { key: 0 };
1949
+ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
1523
1950
  var _a, _b, _c, _d;
1524
1951
  return ((_a = _ctx.cols) == null ? void 0 : _a.length) || ((_b = _ctx.rows) == null ? void 0 : _b.length) ? (vue.openBlock(), vue.createElementBlock("div", {
1525
1952
  key: 0,
@@ -1530,7 +1957,7 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
1530
1957
  key: col.value
1531
1958
  }, vue.toDisplayString(col.value) + "/", 1);
1532
1959
  }), 128)),
1533
- ((_c = _ctx.cols) == null ? void 0 : _c.length) > 0 && ((_d = _ctx.rows) == null ? void 0 : _d.length) > 0 ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$1, "\uFF0C")) : vue.createCommentVNode("", true),
1960
+ ((_c = _ctx.cols) == null ? void 0 : _c.length) > 0 && ((_d = _ctx.rows) == null ? void 0 : _d.length) > 0 ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$4, "\uFF0C")) : vue.createCommentVNode("", true),
1534
1961
  (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.rows, (row) => {
1535
1962
  return vue.openBlock(), vue.createElementBlock("span", {
1536
1963
  key: row.value
@@ -1538,8 +1965,8 @@ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
1538
1965
  }), 128))
1539
1966
  ], 2)) : vue.createCommentVNode("", true);
1540
1967
  }
1541
- var TooltipHeadInfo = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$b]]);
1542
- const _sfc_main$a = vue.defineComponent({
1968
+ var TooltipHeadInfo = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["render", _sfc_render$c]]);
1969
+ const _sfc_main$b = vue.defineComponent({
1543
1970
  name: "TooltipInfos",
1544
1971
  props: ["infos"],
1545
1972
  setup() {
@@ -1549,13 +1976,13 @@ const _sfc_main$a = vue.defineComponent({
1549
1976
  },
1550
1977
  components: {}
1551
1978
  });
1552
- function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) {
1979
+ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
1553
1980
  return vue.openBlock(), vue.createElementBlock("div", {
1554
1981
  class: vue.normalizeClass(`${_ctx.TOOLTIP_PREFIX_CLS}-infos`)
1555
1982
  }, vue.toDisplayString(_ctx.infos), 3);
1556
1983
  }
1557
- var TooltipInfos = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$a]]);
1558
- const _sfc_main$9 = vue.defineComponent({
1984
+ var TooltipInfos = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$b]]);
1985
+ const _sfc_main$a = vue.defineComponent({
1559
1986
  name: "TooltipSimpleTips",
1560
1987
  props: ["name", "tips"],
1561
1988
  setup() {
@@ -1565,7 +1992,7 @@ const _sfc_main$9 = vue.defineComponent({
1565
1992
  },
1566
1993
  components: {}
1567
1994
  });
1568
- function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
1995
+ function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) {
1569
1996
  return vue.openBlock(), vue.createElementBlock(vue.Fragment, null, [
1570
1997
  _ctx.name ? (vue.openBlock(), vue.createElementBlock("div", {
1571
1998
  key: 0,
@@ -1577,8 +2004,8 @@ function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
1577
2004
  }, vue.toDisplayString(_ctx.tips), 3)) : vue.createCommentVNode("", true)
1578
2005
  ], 64);
1579
2006
  }
1580
- var TooltipSimpleTips = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$9]]);
1581
- const _sfc_main$8 = vue.defineComponent({
2007
+ var TooltipSimpleTips = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$a]]);
2008
+ const _sfc_main$9 = vue.defineComponent({
1582
2009
  name: "TooltipSummary",
1583
2010
  props: ["summaries"],
1584
2011
  setup(props) {
@@ -1591,7 +2018,7 @@ const _sfc_main$8 = vue.defineComponent({
1591
2018
  },
1592
2019
  components: {}
1593
2020
  });
1594
- function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
2021
+ function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
1595
2022
  return vue.openBlock(), vue.createElementBlock("div", {
1596
2023
  class: vue.normalizeClass(`${_ctx.TOOLTIP_PREFIX_CLS}-summary`)
1597
2024
  }, [
@@ -1618,8 +2045,8 @@ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
1618
2045
  }), 128))
1619
2046
  ], 2);
1620
2047
  }
1621
- var TooltipSummary = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$8]]);
1622
- const _sfc_main$7 = vue.defineComponent({
2048
+ var TooltipSummary = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$9]]);
2049
+ const _sfc_main$8 = vue.defineComponent({
1623
2050
  name: "TooltipOperatorTitle",
1624
2051
  props: ["menu"],
1625
2052
  setup(props) {
@@ -1630,21 +2057,21 @@ const _sfc_main$7 = vue.defineComponent({
1630
2057
  };
1631
2058
  }
1632
2059
  });
1633
- const _hoisted_1 = ["innerHTML"];
1634
- function _sfc_render$7(_ctx, _cache, $props, $setup, $data, $options) {
2060
+ const _hoisted_1$3 = ["innerHTML"];
2061
+ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
1635
2062
  return vue.openBlock(), vue.createElementBlock("span", null, [
1636
2063
  _ctx.icon ? (vue.openBlock(), vue.createElementBlock("span", {
1637
2064
  key: 0,
1638
2065
  innerHTML: _ctx.icon,
1639
2066
  class: vue.normalizeClass(`${_ctx.TOOLTIP_PREFIX_CLS}-operator-icon`)
1640
- }, null, 10, _hoisted_1)) : vue.createCommentVNode("", true),
2067
+ }, null, 10, _hoisted_1$3)) : vue.createCommentVNode("", true),
1641
2068
  vue.createElementVNode("span", {
1642
2069
  class: vue.normalizeClass(`${_ctx.TOOLTIP_PREFIX_CLS}-operator-text`)
1643
2070
  }, vue.toDisplayString(_ctx.menu.text), 3)
1644
2071
  ]);
1645
2072
  }
1646
- var TooltipOperatorTitle = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$7]]);
1647
- const _sfc_main$6 = vue.defineComponent({
2073
+ var TooltipOperatorTitle = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$8]]);
2074
+ const _sfc_main$7 = vue.defineComponent({
1648
2075
  name: "TooltipOperatorMenu",
1649
2076
  props: ["menu", "cell"],
1650
2077
  setup(props) {
@@ -1663,7 +2090,7 @@ const _sfc_main$6 = vue.defineComponent({
1663
2090
  TooltipOperatorTitle
1664
2091
  }
1665
2092
  });
1666
- function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
2093
+ function _sfc_render$7(_ctx, _cache, $props, $setup, $data, $options) {
1667
2094
  const _component_TooltipOperatorTitle = vue.resolveComponent("TooltipOperatorTitle");
1668
2095
  const _component_TooltipOperatorMenu = vue.resolveComponent("TooltipOperatorMenu");
1669
2096
  const _component_MenuItem = vue.resolveComponent("MenuItem");
@@ -1707,9 +2134,9 @@ function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
1707
2134
  _: 1
1708
2135
  }, 8, ["popupClassName", "onTitleClick"]);
1709
2136
  }
1710
- var TooltipOperatorMenu = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["render", _sfc_render$6]]);
2137
+ var TooltipOperatorMenu = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$7]]);
1711
2138
  var index_vue_vue_type_style_index_0_lang$1 = "";
1712
- const _sfc_main$5 = vue.defineComponent({
2139
+ const _sfc_main$6 = vue.defineComponent({
1713
2140
  name: "TooltipOperator",
1714
2141
  props: [
1715
2142
  "menus",
@@ -1729,7 +2156,7 @@ const _sfc_main$5 = vue.defineComponent({
1729
2156
  TooltipOperatorMenu
1730
2157
  }
1731
2158
  });
1732
- function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
2159
+ function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
1733
2160
  const _component_TooltipOperatorMenu = vue.resolveComponent("TooltipOperatorMenu");
1734
2161
  const _component_Menu = vue.resolveComponent("Menu");
1735
2162
  const _component_TooltipOperatorTitle = vue.resolveComponent("TooltipOperatorTitle");
@@ -1792,17 +2219,17 @@ function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
1792
2219
  }), 128))
1793
2220
  ], 2);
1794
2221
  }
1795
- var TooltipOperator = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["render", _sfc_render$5]]);
2222
+ var TooltipOperator = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["render", _sfc_render$6]]);
1796
2223
  var index_vue_vue_type_style_index_0_lang = "";
1797
- const _sfc_main$4 = vue.defineComponent({
2224
+ const _sfc_main$5 = vue.defineComponent({
1798
2225
  name: "TooltipComponent",
1799
2226
  props: [
1800
- "content",
1801
2227
  "data",
1802
2228
  "options",
1803
2229
  "cell",
1804
2230
  "position",
1805
- "event"
2231
+ "event",
2232
+ "content"
1806
2233
  ],
1807
2234
  setup(props) {
1808
2235
  const { operator, onlyMenu } = s2.getTooltipDefaultOptions(props.options);
@@ -1820,7 +2247,7 @@ const _sfc_main$4 = vue.defineComponent({
1820
2247
  TooltipOperator
1821
2248
  }
1822
2249
  });
1823
- function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
2250
+ function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
1824
2251
  var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
1825
2252
  const _component_TooltipOperator = vue.resolveComponent("TooltipOperator");
1826
2253
  const _component_TooltipSimpleTips = vue.resolveComponent("TooltipSimpleTips");
@@ -1841,9 +2268,7 @@ function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
1841
2268
  cell: _ctx.cell,
1842
2269
  onClick: (_d = _ctx.operator) == null ? void 0 : _d.onClick
1843
2270
  }, null, 8, ["menus", "cell", "onClick"]),
1844
- _ctx.content ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
1845
- vue.createTextVNode(vue.toDisplayString(_ctx.content), 1)
1846
- ], 64)) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
2271
+ _ctx.content ? vue.renderSlot(_ctx.$slots, "content", { key: 0 }) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
1847
2272
  vue.createVNode(_component_TooltipSimpleTips, {
1848
2273
  name: (_e = _ctx.data) == null ? void 0 : _e.name,
1849
2274
  tips: (_f = _ctx.data) == null ? void 0 : _f.tips
@@ -1866,7 +2291,7 @@ function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
1866
2291
  ], 64))
1867
2292
  ], 64));
1868
2293
  }
1869
- var TooltipComponent = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["render", _sfc_render$4]]);
2294
+ var TooltipComponent = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["render", _sfc_render$5]]);
1870
2295
  class CustomTooltip extends s2.BaseTooltip {
1871
2296
  constructor(spreadsheet) {
1872
2297
  super(spreadsheet);
@@ -1881,7 +2306,9 @@ class CustomTooltip extends s2.BaseTooltip {
1881
2306
  cell,
1882
2307
  content
1883
2308
  });
1884
- const tooltipVNode = vue.createVNode(TooltipComponent, tooltipProps);
2309
+ const tooltipVNode = vue.createVNode(TooltipComponent, tooltipProps, {
2310
+ content: () => content
2311
+ });
1885
2312
  vue.render(null, this.container);
1886
2313
  vue.render(tooltipVNode, this.container);
1887
2314
  }
@@ -1897,31 +2324,6 @@ const RENDER_TOOLTIP_OPTION = {
1897
2324
  renderTooltip: (spreadsheet) => new CustomTooltip(spreadsheet)
1898
2325
  }
1899
2326
  };
1900
- [
1901
- {
1902
- name: s2.i18n("\u5347\u5E8F"),
1903
- value: "ASC"
1904
- },
1905
- {
1906
- name: s2.i18n("\u964D\u5E8F"),
1907
- value: "DESC"
1908
- }
1909
- ];
1910
- [
1911
- {
1912
- label: s2.i18n("\u9996\u5B57\u6BCD"),
1913
- value: "sortMethod"
1914
- },
1915
- {
1916
- label: s2.i18n("\u624B\u52A8\u6392\u5E8F"),
1917
- value: "sortBy"
1918
- },
1919
- {
1920
- label: s2.i18n("\u5176\u4ED6\u5B57\u6BB5"),
1921
- value: "sortByMeasure",
1922
- children: []
1923
- }
1924
- ];
1925
2327
  const getSheetComponentOptions = (...options) => getBaseSheetComponentOptions(RENDER_TOOLTIP_OPTION, ...options);
1926
2328
  const useCellEvent = (s2Ref, emit, eventName, emitName) => {
1927
2329
  var _a;
@@ -1967,6 +2369,7 @@ const useEvents = (s2Ref, emit) => {
1967
2369
  useCellEvent(s2Ref, emit, s2.S2Event.DATA_CELL_MOUSE_MOVE, "dataCellMouseMove");
1968
2370
  useS2Event(s2Ref, emit, s2.S2Event.DATA_CELL_TREND_ICON_CLICK, "dataCellTrendIconClick");
1969
2371
  useS2Event(s2Ref, emit, s2.S2Event.DATE_CELL_BRUSH_SELECTION, "dataCellBrushSelection");
2372
+ useS2Event(s2Ref, emit, s2.S2Event.DATE_CELL_SELECT_MOVE, "dataCellSelectMove");
1970
2373
  useCellEvent(s2Ref, emit, s2.S2Event.CORNER_CELL_HOVER, "cornerCellHover");
1971
2374
  useCellEvent(s2Ref, emit, s2.S2Event.CORNER_CELL_CLICK, "cornerCellClick");
1972
2375
  useCellEvent(s2Ref, emit, s2.S2Event.CORNER_CELL_DOUBLE_CLICK, "cornerCellDoubleClick");
@@ -2051,11 +2454,14 @@ const useSheetUpdate = (s2Ref, props) => {
2051
2454
  (_a = s2Ref.value) == null ? void 0 : _a.setOptions(options);
2052
2455
  (_b = s2Ref.value) == null ? void 0 : _b.changeSheetSize(options == null ? void 0 : options.width, options == null ? void 0 : options.height);
2053
2456
  }, { deep: vue.isProxy(props.options) });
2054
- vue.watch(() => props.dataCfg, (dataCfg) => {
2055
- var _a;
2457
+ vue.watch(() => props.dataCfg, (dataCfg, prevDataCfg) => {
2458
+ var _a, _b, _c, _d, _e, _f;
2459
+ if (((_b = (_a = prevDataCfg == null ? void 0 : prevDataCfg.fields) == null ? void 0 : _a.columns) == null ? void 0 : _b.length) !== ((_d = (_c = dataCfg == null ? void 0 : dataCfg.fields) == null ? void 0 : _c.columns) == null ? void 0 : _d.length)) {
2460
+ (_e = s2Ref.value) == null ? void 0 : _e.clearColumnLeafNodes();
2461
+ }
2056
2462
  updateFlag.rerender = true;
2057
2463
  updateFlag.reloadData = true;
2058
- (_a = s2Ref.value) == null ? void 0 : _a.setDataCfg(dataCfg);
2464
+ (_f = s2Ref.value) == null ? void 0 : _f.setDataCfg(dataCfg);
2059
2465
  }, { deep: vue.isProxy(props.dataCfg) });
2060
2466
  vue.watch(() => props.themeCfg, (themeCfg) => {
2061
2467
  var _a;
@@ -2114,9 +2520,8 @@ function useSpreadSheet(props, emit) {
2114
2520
  const rawDataCfg = vue.toRaw(dataCfg);
2115
2521
  const rawOptions = vue.toRaw(options);
2116
2522
  const s2Options = getSheetComponentOptions(rawOptions);
2117
- const s2Constructor = [container, rawDataCfg, s2Options];
2118
2523
  if (onSpreadsheet) {
2119
- return onSpreadsheet(...s2Constructor);
2524
+ return onSpreadsheet(container, rawDataCfg, s2Options);
2120
2525
  }
2121
2526
  if (sheetType === "table") {
2122
2527
  return new s2.TableSheet(container, rawDataCfg, s2Options);
@@ -2170,6 +2575,34 @@ const initBaseSheetProps = () => ({
2170
2575
  onSpreadsheet: Function,
2171
2576
  onGetSpreadSheet: Function
2172
2577
  });
2578
+ const initDrillDownProps = () => ({
2579
+ className: String,
2580
+ titleText: {
2581
+ type: String,
2582
+ default: s2.i18n("\u9009\u62E9\u4E0B\u94BB\u7EF4\u5EA6")
2583
+ },
2584
+ searchText: {
2585
+ type: String,
2586
+ default: s2.i18n("\u641C\u7D22\u5B57\u6BB5")
2587
+ },
2588
+ clearButtonText: {
2589
+ type: String,
2590
+ default: s2.i18n("\u6062\u590D\u9ED8\u8BA4")
2591
+ },
2592
+ extra: Node,
2593
+ dataSet: {
2594
+ type: Array,
2595
+ default: []
2596
+ },
2597
+ drillFields: Array,
2598
+ disabledFields: Array,
2599
+ getDrillFields: Function,
2600
+ setDrillFields: Function
2601
+ });
2602
+ const initDrillDownEmits = () => {
2603
+ const keys2 = ["getDrillFields", "setDrillFields"];
2604
+ return keys2;
2605
+ };
2173
2606
  const initBaseSheetEmits = () => {
2174
2607
  const keys2 = [
2175
2608
  "spreadsheet",
@@ -2195,6 +2628,7 @@ const initBaseSheetEmits = () => {
2195
2628
  "dataCellMouseMove",
2196
2629
  "dataCellTrendIconClick",
2197
2630
  "dataCellBrushSelection",
2631
+ "dataCellSelectMove",
2198
2632
  "cornerCellHover",
2199
2633
  "cornerCellClick",
2200
2634
  "cornerCellDoubleClick",
@@ -2246,7 +2680,7 @@ const initBaseSheetEmits = () => {
2246
2680
  return keys2;
2247
2681
  };
2248
2682
  var baseSheet_vue_vue_type_style_index_0_lang = "";
2249
- const _sfc_main$3 = vue.defineComponent({
2683
+ const _sfc_main$4 = vue.defineComponent({
2250
2684
  name: "BaseSheet",
2251
2685
  props: initBaseSheetProps(),
2252
2686
  emits: initBaseSheetEmits(),
@@ -2287,7 +2721,7 @@ const _sfc_main$3 = vue.defineComponent({
2287
2721
  S2Pagination
2288
2722
  }
2289
2723
  });
2290
- function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
2724
+ function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
2291
2725
  const _component_S2Pagination = vue.resolveComponent("S2Pagination");
2292
2726
  const _component_Spin = vue.resolveComponent("Spin");
2293
2727
  return vue.openBlock(), vue.createBlock(_component_Spin, {
@@ -2316,14 +2750,251 @@ function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
2316
2750
  _: 1
2317
2751
  }, 8, ["wrapperClassName", "spinning"]);
2318
2752
  }
2319
- var BaseSheet = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$3]]);
2753
+ var BaseSheet = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["render", _sfc_render$4]]);
2754
+ const _hoisted_1$2 = {
2755
+ class: "antv-s2-icon",
2756
+ viewBox: "0 0 1024 1024",
2757
+ xmlns: "http://www.w3.org/2000/svg",
2758
+ width: "12.6",
2759
+ height: "12.6"
2760
+ };
2761
+ const _hoisted_2$2 = /* @__PURE__ */ vue.createElementVNode("path", {
2762
+ d: "M511.804 222.338c-57.117 0-105.737 20.061-145.86 60.184-40.122 40.123-60.184 88.569-60.184 145.337 0 56.769 20.062 105.214 60.185 145.337 40.122 40.123 88.742 60.185 145.859 60.185 57.116 0 105.736-20.062 145.859-60.185 40.123-40.123 60.184-88.568 60.184-145.337 0-56.768-20.061-105.214-60.184-145.337-40.123-40.123-88.743-60.184-145.86-60.184zm0 338.619c-36.729 0-68.007-12.925-93.835-38.774-25.827-25.85-38.752-57.127-38.773-93.834-.022-36.707 12.902-68.16 38.773-94.357 25.872-26.197 57.15-39.285 93.835-39.263 36.685.022 67.963 13.11 93.834 39.263 25.871 26.154 38.796 57.606 38.774 94.357-.022 36.75-12.946 68.028-38.774 93.834-25.828 25.806-57.106 38.73-93.834 38.774zm366.165-295.766c-21.084-42.168-50.327-79.223-87.73-111.165-37.404-31.941-79.898-57.105-127.484-75.491C614.472 60.845 564.155 52 511.804 52c-52.352 0-103.006 8.845-151.963 26.535-46.911 18.364-89.069 43.528-126.472 75.491-37.403 31.964-66.647 69.019-87.731 111.165C123.879 308.71 113 353.923 113 400.835c0 65.95 15.982 132.924 47.945 200.92 26.524 56.441 63.58 112.198 111.165 167.27 62.556 73.435 134.632 138.71 216.227 195.827 6.81 4.765 14.459 7.148 22.945 7.148 8.485 0 16.47-2.383 23.956-7.148 81.595-57.79 153.67-123.067 216.227-195.828 47.608-55.767 84.663-111.524 111.165-167.27 31.963-67.995 47.945-134.969 47.945-200.919 0-46.912-10.88-92.126-32.638-135.644h.032zm-40.797 136.656c0 55.07-13.6 111.513-40.798 169.326-23.129 49.631-56.452 99.948-99.97 150.95-52.351 61.208-113.885 117.65-184.6 169.326-70.716-51.676-132.25-108.118-184.6-169.326-42.844-51.002-76.167-101.319-99.971-150.95-27.198-57.791-40.797-114.57-40.797-170.338 0-36.032 8.159-70.716 24.478-104.05 16.994-32.638 40.45-61.882 70.368-87.73 30.592-26.525 65.276-47.26 104.05-62.209 40.797-14.97 82.954-22.455 126.472-22.455 43.517 0 85.675 7.485 126.472 22.455 38.752 14.97 73.436 35.706 104.05 62.208 30.593 25.85 54.048 55.093 70.367 87.731 16.32 34.009 24.479 69.03 24.479 105.062z",
2763
+ fill: "currentColor"
2764
+ }, null, -1);
2765
+ const _hoisted_3$2 = [
2766
+ _hoisted_2$2
2767
+ ];
2768
+ function render$2(_ctx, _cache) {
2769
+ return vue.openBlock(), vue.createElementBlock("svg", _hoisted_1$2, _hoisted_3$2);
2770
+ }
2771
+ var LocationIcon = { render: render$2 };
2772
+ const _hoisted_1$1 = {
2773
+ class: "antv-s2-icon",
2774
+ viewBox: "0 0 1024 1024",
2775
+ xmlns: "http://www.w3.org/2000/svg",
2776
+ width: "12.6",
2777
+ height: "12.6"
2778
+ };
2779
+ const _hoisted_2$1 = /* @__PURE__ */ vue.createElementVNode("path", {
2780
+ d: "M86.016 805.888H0l143.872-529.92h79.36l144.896 529.92h-91.136l-29.696-109.056H115.2S85.504 805.888 86.016 805.888zM225.28 613.376 181.248 455.68 138.24 613.376h87.04zM519.168 430.08c24.576-16.384 47.616-25.088 69.12-25.088 30.72 0 58.368 14.848 81.92 44.032 24.064 29.184 35.328 72.192 35.328 128.512 0 44.032-7.168 83.456-22.528 118.272-14.848 34.816-35.328 62.976-60.416 83.456-26.112 20.992-57.856 31.232-95.232 31.232-15.36-.512-31.232-1.536-46.592-3.584-4.096-.512-8.704-1.024-12.8-1.536h-66.56V256h81.92v206.336c11.264-12.8 23.04-23.552 35.84-32.256zM483.84 587.264v135.168c13.824 3.072 26.112 4.608 37.376 4.608 27.648 0 50.176-11.776 69.12-36.352 19.456-25.088 28.672-59.392 28.672-104.96 0-32.256-5.12-55.296-14.848-70.144-9.216-13.824-18.432-19.968-28.672-19.968-12.288 0-27.136 7.68-44.544 24.064-16.896 16.896-32.768 39.424-47.104 67.584zm529.92 207.36c-36.864 14.336-71.68 20.992-104.96 20.992-32.768.512-64.512-9.216-91.648-27.136-27.136-18.432-48.64-44.032-62.464-73.728-14.848-30.72-22.528-65.536-22.528-104.448 0-58.88 16.896-108.032 51.2-146.944 33.792-38.912 75.264-58.88 123.392-58.88 34.304 0 70.144 7.168 108.032 21.504l10.24 4.096v95.232l-20.992-10.752c-34.816-17.92-65.536-26.624-92.16-26.624-16.896 0-32.768 4.608-47.104 13.824-13.824 8.704-25.088 23.04-32.768 42.496-8.192 19.968-12.288 41.472-12.288 63.488 0 28.672 7.68 55.808 24.064 82.432 14.848 24.576 37.888 36.352 71.168 36.352 10.752 0 21.504-1.024 31.744-2.56 9.728-1.536 29.696-8.192 58.88-18.944l19.456-7.68v92.672l-11.264 4.608z",
2781
+ fill: "currentColor"
2782
+ }, null, -1);
2783
+ const _hoisted_3$1 = [
2784
+ _hoisted_2$1
2785
+ ];
2786
+ function render$1(_ctx, _cache) {
2787
+ return vue.openBlock(), vue.createElementBlock("svg", _hoisted_1$1, _hoisted_3$1);
2788
+ }
2789
+ var TextIcon = { render: render$1 };
2790
+ const _hoisted_1 = {
2791
+ class: "antv-s2-icon",
2792
+ viewBox: "0 0 1024 1024",
2793
+ xmlns: "http://www.w3.org/2000/svg",
2794
+ width: "12.6",
2795
+ height: "12.6"
2796
+ };
2797
+ const _hoisted_2 = /* @__PURE__ */ vue.createElementVNode("path", {
2798
+ d: "M950.016 898.016 744 693.024q88-107.008 88-244.992 0-159.008-112.512-271.488T448 64.032 176.512 176.544 64 448.032 176.512 719.52 448 832.032q138.016 0 244.992-88l206.016 206.016q10.016 10.016 24.992 10.016t26.016-10.016q10.016-11.008 10.016-26.016t-10.016-26.016zM568.992 736Q512 760 448 760t-120.992-24q-56-24-99.488-67.488t-66.496-99.488q-24.992-56.992-24.992-120.992t24.992-120.992q23.008-56 66.496-99.488t99.488-67.488q56.992-24 120.992-24t120.992 24q56 24 99.488 67.488t67.488 99.488q24 56.992 24 120.992t-24 120.992q-24 56-67.488 99.488T568.992 736z",
2799
+ fill: "currentColor"
2800
+ }, null, -1);
2801
+ const _hoisted_3 = [
2802
+ _hoisted_2
2803
+ ];
2804
+ function render(_ctx, _cache) {
2805
+ return vue.openBlock(), vue.createElementBlock("svg", _hoisted_1, _hoisted_3);
2806
+ }
2807
+ var CalendarIcon = { render };
2808
+ var index_vue_vue_type_style_index_0_scoped_true_lang = "";
2809
+ const _sfc_main$3 = vue.defineComponent({
2810
+ name: "DrillDown",
2811
+ props: initDrillDownProps(),
2812
+ emits: initDrillDownEmits(),
2813
+ methods: {},
2814
+ components: {
2815
+ Button: antDesignVue.Button,
2816
+ Input: antDesignVue.Input,
2817
+ Empty: antDesignVue.Empty,
2818
+ Menu: antDesignVue.Menu,
2819
+ MenuItem: antDesignVue.MenuItem,
2820
+ LocationIcon,
2821
+ TextIcon,
2822
+ CalendarIcon
2823
+ },
2824
+ setup(props) {
2825
+ const {
2826
+ dataSet,
2827
+ disabledFields,
2828
+ getDrillFields,
2829
+ setDrillFields,
2830
+ className
2831
+ } = props;
2832
+ const getOptions = () => {
2833
+ return dataSet.map((val) => {
2834
+ val.disabled = !!(disabledFields && disabledFields.includes(val.value));
2835
+ return val;
2836
+ });
2837
+ };
2838
+ const options = vue.ref(getOptions());
2839
+ const selected = vue.ref([]);
2840
+ const handleSearch = (e) => {
2841
+ const { value } = e.target;
2842
+ if (!value) {
2843
+ options.value = [...dataSet];
2844
+ } else {
2845
+ const reg = new RegExp(value, "gi");
2846
+ const result = dataSet.filter((item) => reg.test(item.name));
2847
+ options.value = [...result];
2848
+ }
2849
+ };
2850
+ const handleSelect = (value) => {
2851
+ const key = value == null ? void 0 : value.selectedKeys;
2852
+ selected.value = key;
2853
+ if (getDrillFields) {
2854
+ getDrillFields(key);
2855
+ }
2856
+ if (setDrillFields)
2857
+ setDrillFields(key);
2858
+ };
2859
+ const handleClear = (e) => {
2860
+ e.stopPropagation();
2861
+ selected.value = [];
2862
+ if (getDrillFields)
2863
+ getDrillFields([]);
2864
+ if (setDrillFields)
2865
+ setDrillFields([]);
2866
+ };
2867
+ return {
2868
+ options,
2869
+ handleSearch,
2870
+ handleSelect,
2871
+ handleClear,
2872
+ className,
2873
+ selected,
2874
+ isEmpty,
2875
+ DRILL_DOWN_PRE_CLASS
2876
+ };
2877
+ }
2878
+ });
2879
+ function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
2880
+ const _component_Button = vue.resolveComponent("Button");
2881
+ const _component_Input = vue.resolveComponent("Input");
2882
+ const _component_Empty = vue.resolveComponent("Empty");
2883
+ const _component_text_icon = vue.resolveComponent("text-icon");
2884
+ const _component_calendar_icon = vue.resolveComponent("calendar-icon");
2885
+ const _component_location_icon = vue.resolveComponent("location-icon");
2886
+ const _component_MenuItem = vue.resolveComponent("MenuItem");
2887
+ const _component_Menu = vue.resolveComponent("Menu");
2888
+ return vue.openBlock(), vue.createElementBlock("div", {
2889
+ class: vue.normalizeClass([_ctx.DRILL_DOWN_PRE_CLASS, _ctx.className])
2890
+ }, [
2891
+ vue.createElementVNode("header", {
2892
+ class: vue.normalizeClass(`${_ctx.DRILL_DOWN_PRE_CLASS}-header`)
2893
+ }, [
2894
+ vue.createElementVNode("div", null, vue.toDisplayString(_ctx.titleText), 1),
2895
+ vue.createVNode(_component_Button, {
2896
+ type: "link",
2897
+ onClick: _ctx.handleClear
2898
+ }, {
2899
+ default: vue.withCtx(() => [
2900
+ vue.createTextVNode(vue.toDisplayString(_ctx.clearButtonText), 1)
2901
+ ]),
2902
+ _: 1
2903
+ }, 8, ["onClick"])
2904
+ ], 2),
2905
+ vue.createVNode(_component_Input, {
2906
+ class: vue.normalizeClass(`${_ctx.DRILL_DOWN_PRE_CLASS}-search`),
2907
+ placeholder: _ctx.searchText,
2908
+ onChange: _ctx.handleSearch,
2909
+ onPressEnter: _ctx.handleSearch,
2910
+ allowClear: true
2911
+ }, null, 8, ["class", "placeholder", "onChange", "onPressEnter"]),
2912
+ _ctx.isEmpty(_ctx.options) ? (vue.openBlock(), vue.createBlock(_component_Empty, {
2913
+ key: 0,
2914
+ imageStyle: { height: "64px" },
2915
+ class: vue.normalizeClass(`${_ctx.DRILL_DOWN_PRE_CLASS}-empty`)
2916
+ }, null, 8, ["class"])) : vue.createCommentVNode("", true),
2917
+ vue.createVNode(_component_Menu, {
2918
+ class: "`${DRILL_DOWN_PRE_CLASS}-menu`",
2919
+ selectedKeys: _ctx.selected,
2920
+ "onUpdate:selectedKeys": _cache[0] || (_cache[0] = ($event) => _ctx.selected = $event),
2921
+ onSelect: _ctx.handleSelect
2922
+ }, {
2923
+ default: vue.withCtx(() => [
2924
+ (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.options, (option) => {
2925
+ return vue.openBlock(), vue.createBlock(_component_MenuItem, {
2926
+ key: option.value,
2927
+ disabled: option.disabled,
2928
+ class: vue.normalizeClass(`${_ctx.DRILL_DOWN_PRE_CLASS}-menu-item`)
2929
+ }, {
2930
+ icon: vue.withCtx(() => [
2931
+ option.type === "text" ? (vue.openBlock(), vue.createBlock(_component_text_icon, { key: 0 })) : vue.createCommentVNode("", true),
2932
+ option.type === "date" ? (vue.openBlock(), vue.createBlock(_component_calendar_icon, { key: 1 })) : vue.createCommentVNode("", true),
2933
+ option.type === "location" ? (vue.openBlock(), vue.createBlock(_component_location_icon, { key: 2 })) : vue.createCommentVNode("", true)
2934
+ ]),
2935
+ default: vue.withCtx(() => [
2936
+ vue.createTextVNode(" " + vue.toDisplayString(option == null ? void 0 : option.name), 1)
2937
+ ]),
2938
+ _: 2
2939
+ }, 1032, ["disabled", "class"]);
2940
+ }), 128))
2941
+ ]),
2942
+ _: 1
2943
+ }, 8, ["selectedKeys", "onSelect"])
2944
+ ], 2);
2945
+ }
2946
+ var DrillDown = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$3], ["__scopeId", "data-v-6eb1ccd0"]]);
2320
2947
  const _sfc_main$2 = vue.defineComponent({
2321
2948
  name: "PivotSheet",
2322
- props: [],
2323
- emits: [],
2949
+ props: initBaseSheetProps(),
2950
+ emits: initBaseSheetEmits(),
2324
2951
  setup(props, ctx) {
2325
2952
  const s2Ref = useExpose(ctx.expose);
2326
- return { s2Ref };
2953
+ const { options: pivotOptions } = vue.toRefs(props);
2954
+ const { dataCfg, partDrillDown } = vue.toRefs(props);
2955
+ const drillFields = vue.ref([]);
2956
+ const setDrillFields = (fields) => {
2957
+ var _a, _b, _c, _d, _e, _f;
2958
+ const instance = (_a = s2Ref == null ? void 0 : s2Ref.value) == null ? void 0 : _a.instance;
2959
+ drillFields.value = fields;
2960
+ instance == null ? void 0 : instance.hideTooltip();
2961
+ if (isEmpty(fields)) {
2962
+ instance == null ? void 0 : instance.clearDrillDownData((_b = instance == null ? void 0 : instance.store.get("drillDownNode")) == null ? void 0 : _b.id);
2963
+ } else {
2964
+ handleDrillDown({
2965
+ rows: (_d = (_c = dataCfg.value) == null ? void 0 : _c.fields.rows) != null ? _d : [],
2966
+ drillFields: fields,
2967
+ fetchData: (_e = partDrillDown.value) == null ? void 0 : _e.fetchData,
2968
+ drillItemsNum: (_f = partDrillDown.value) == null ? void 0 : _f.drillItemsNum,
2969
+ spreadsheet: instance
2970
+ });
2971
+ }
2972
+ };
2973
+ const onDrillDownIconClick = (params) => {
2974
+ var _a, _b;
2975
+ const { event, disabledFields } = params;
2976
+ if (event) {
2977
+ const instance = (_a = s2Ref == null ? void 0 : s2Ref.value) == null ? void 0 : _a.instance;
2978
+ const drillDownNode = vue.createVNode(DrillDown, __spreadProps(__spreadValues({}, (_b = partDrillDown.value) == null ? void 0 : _b.drillConfig), {
2979
+ setDrillFields,
2980
+ drillFields: drillFields.value,
2981
+ disabledFields
2982
+ }));
2983
+ instance == null ? void 0 : instance.showTooltip({
2984
+ position: {
2985
+ x: event.clientX,
2986
+ y: event.clientY
2987
+ },
2988
+ event,
2989
+ content: drillDownNode
2990
+ });
2991
+ }
2992
+ };
2993
+ const options = vue.computed(() => buildDrillDownOptions(pivotOptions.value, partDrillDown.value, (params) => onDrillDownIconClick(params)));
2994
+ return {
2995
+ s2Ref,
2996
+ options
2997
+ };
2327
2998
  },
2328
2999
  components: {
2329
3000
  BaseSheet
@@ -2331,7 +3002,10 @@ const _sfc_main$2 = vue.defineComponent({
2331
3002
  });
2332
3003
  function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
2333
3004
  const _component_BaseSheet = vue.resolveComponent("BaseSheet");
2334
- return vue.openBlock(), vue.createBlock(_component_BaseSheet, { ref: "s2Ref" }, null, 512);
3005
+ return vue.openBlock(), vue.createBlock(_component_BaseSheet, vue.mergeProps(_ctx.$props, {
3006
+ ref: "s2Ref",
3007
+ options: _ctx.options
3008
+ }), null, 16, ["options"]);
2335
3009
  }
2336
3010
  var PivotSheet = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$2]]);
2337
3011
  const _sfc_main$1 = vue.defineComponent({
@@ -2379,7 +3053,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
2379
3053
  var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
2380
3054
  exports.BaseSheet = BaseSheet;
2381
3055
  exports.PivotSheet = PivotSheet;
2382
- exports.Sheet = index;
3056
+ exports.SheetComponent = index;
2383
3057
  exports.TableSheet = TableSheet;
2384
3058
  exports.useExpose = useExpose;
2385
3059
  //# sourceMappingURL=index.js.map