evui 3.4.146 → 3.4.147

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.
@@ -11227,7 +11227,7 @@ var update = add("9519e5b6", content, true, {"sourceMap":false,"shadowMode":fals
11227
11227
  /***/ "9224":
11228
11228
  /***/ (function(module) {
11229
11229
 
11230
- module.exports = JSON.parse("{\"a\":\"3.4.146\"}");
11230
+ module.exports = JSON.parse("{\"a\":\"3.4.147\"}");
11231
11231
 
11232
11232
  /***/ }),
11233
11233
 
@@ -38456,7 +38456,10 @@ function isNil(value) {
38456
38456
 
38457
38457
 
38458
38458
 
38459
+ // Text Size 측정용 singleton canvas
38459
38460
 
38461
+ var textMeasureCanvas = document.createElement('canvas');
38462
+ var textMeasureCtx = textMeasureCanvas.getContext('2d');
38460
38463
  /* harmony default export */ var helpers_util = ({
38461
38464
  /**
38462
38465
  * Transforming hex to rgb code
@@ -38666,6 +38669,32 @@ function isNil(value) {
38666
38669
  };
38667
38670
  },
38668
38671
 
38672
+ /**
38673
+ * Calculate text size with Canvas
38674
+ * @param {string} text text is needed to check size
38675
+ * @param {string} fontStyle text font style
38676
+ * @returns {{width: number; height: number;}} text size information
38677
+ */
38678
+ calcTextSizeCanvas: function calcTextSizeCanvas(text, fontStyle) {
38679
+ if (!text) {
38680
+ return {
38681
+ width: 2,
38682
+ height: 2
38683
+ };
38684
+ }
38685
+
38686
+ textMeasureCtx.font = fontStyle;
38687
+ var metrics = textMeasureCtx.measureText(text);
38688
+ var fontSizeMatch = fontStyle.match(/(\d+(?:\.\d+)?)px/);
38689
+ var fontSize = fontSizeMatch ? Number(fontSizeMatch[1]) : 14; // DOM 기본 line-height 보정 (대략 1.2 ~ 1.3)
38690
+
38691
+ var lineHeight = fontSize * 1.2;
38692
+ return {
38693
+ width: Math.max(Math.ceil(metrics.width), 2),
38694
+ height: Math.max(Math.ceil(lineHeight), 2)
38695
+ };
38696
+ },
38697
+
38669
38698
  /**
38670
38699
  * Comparing strings
38671
38700
  * @param {array} array compared array
@@ -38694,7 +38723,7 @@ function isNil(value) {
38694
38723
  /**
38695
38724
  * Truncate the long string to short string with ellipsis until fitting maxWidth
38696
38725
  * @param {string} str target string
38697
- * @param {number} maxWidth maximum string width on canvas
38726
+ * @param {number} maxWidth maximum string width on canva
38698
38727
  * @param {Object} ctx canvas context
38699
38728
  * @param {string} direction left or right (default: right)
38700
38729
  */
@@ -38875,6 +38904,11 @@ function isNil(value) {
38875
38904
 
38876
38905
 
38877
38906
 
38907
+
38908
+
38909
+
38910
+
38911
+
38878
38912
 
38879
38913
 
38880
38914
 
@@ -39077,6 +39111,8 @@ var modules = {
39077
39111
  var xAxisTime = Math.floor(_item.x / 1000) * 1000;
39078
39112
 
39079
39113
  if (this.dataSet[key].fromTime <= xAxisTime) {
39114
+ var _item$value;
39115
+
39080
39116
  var index = this.dataSet[key].endIndex - (this.dataSet[key].toTime - xAxisTime) / 1000;
39081
39117
 
39082
39118
  if (index < 0) {
@@ -39086,6 +39122,7 @@ var modules = {
39086
39122
  this.dataSet[key].dataGroup[index].data.push({
39087
39123
  x: _item.x,
39088
39124
  y: _item.y,
39125
+ o: (_item$value = _item.value) !== null && _item$value !== void 0 ? _item$value : _item.y,
39089
39126
  color: _item.color
39090
39127
  });
39091
39128
  this.dataSet[key].dataGroup[index].max = Math.max(this.dataSet[key].dataGroup[index].max, _item.y);
@@ -39343,30 +39380,54 @@ var modules = {
39343
39380
  var _this4 = this;
39344
39381
 
39345
39382
  var sIdx = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 0;
39383
+ var seriesList = this.seriesList;
39346
39384
  var isHorizontal = this.options.horizontal;
39347
39385
  var sdata = [];
39386
+ var basePositionCache = new Map();
39348
39387
 
39349
39388
  var getBaseDataPosition = function getBaseDataPosition(baseIndex, dataIndex) {
39350
- var nextBaseSeriesIndex = baseIndex - 1;
39351
- var baseSeries = _this4.seriesList[bsIds[baseIndex]];
39352
- var baseDataList = baseSeries.data;
39353
- var baseData = baseDataList[dataIndex];
39354
- var position = isHorizontal ? baseData === null || baseData === void 0 ? void 0 : baseData.x : baseData === null || baseData === void 0 ? void 0 : baseData.y;
39355
- var isPassingValue = baseSeries.passingValue === (baseData === null || baseData === void 0 ? void 0 : baseData.o);
39389
+ var key = baseIndex << 20 | dataIndex;
39390
+
39391
+ if (basePositionCache.has(key)) {
39392
+ return basePositionCache.get(key);
39393
+ }
39394
+
39395
+ var result = 0;
39396
+ var idx = baseIndex;
39397
+
39398
+ while (idx >= 0) {
39399
+ var baseSeries = seriesList[bsIds[idx]];
39356
39400
 
39357
- if (isPassingValue || position == null || !baseSeries.show) {
39358
- if (nextBaseSeriesIndex > -1) {
39359
- return getBaseDataPosition(nextBaseSeriesIndex, dataIndex);
39401
+ if (baseSeries !== null && baseSeries !== void 0 && baseSeries.show && Array.isArray(baseSeries === null || baseSeries === void 0 ? void 0 : baseSeries.data)) {
39402
+ var baseData = baseSeries.data[dataIndex];
39403
+
39404
+ var _ref = baseData !== null && baseData !== void 0 ? baseData : {},
39405
+ _ref$x = _ref.x,
39406
+ x = _ref$x === void 0 ? null : _ref$x,
39407
+ _ref$y = _ref.y,
39408
+ y = _ref$y === void 0 ? null : _ref$y,
39409
+ _ref$o = _ref.o,
39410
+ o = _ref$o === void 0 ? null : _ref$o;
39411
+
39412
+ var position = isHorizontal ? x : y;
39413
+ var isPassingValue = helpers_util.isNullOrUndefined(baseSeries.passingValue) === false && (baseSeries === null || baseSeries === void 0 ? void 0 : baseSeries.passingValue) === o;
39414
+
39415
+ if (position != null && !isPassingValue) {
39416
+ result = position;
39417
+ break;
39418
+ }
39360
39419
  }
39361
39420
 
39362
- return 0;
39421
+ idx--;
39363
39422
  }
39364
39423
 
39365
- return position;
39424
+ basePositionCache.set(key, result);
39425
+ return result;
39366
39426
  };
39367
39427
 
39428
+ var lastBaseIndex = bsIds.length - 1;
39368
39429
  data.forEach(function (curr, index) {
39369
- var baseIndex = bsIds.length - 1 < 0 ? 0 : bsIds.length - 1;
39430
+ var baseIndex = Math.max(0, lastBaseIndex);
39370
39431
  var bdata = getBaseDataPosition(baseIndex, index); // base(previous) series data
39371
39432
 
39372
39433
  var odata = curr; // current series original data
@@ -39375,10 +39436,10 @@ var modules = {
39375
39436
 
39376
39437
  var gdata = curr; // current series data which added previous series's value
39377
39438
 
39378
- if (bdata != null && ldata != null) {
39439
+ if (ldata != null) {
39379
39440
  var _odata$value, _odata;
39380
39441
 
39381
- if (gdata && _typeof(gdata) === 'object' && (curr.x || curr.y)) {
39442
+ if (gdata && _typeof(gdata) === 'object' && ('x' in gdata || 'y' in gdata)) {
39382
39443
  odata = isHorizontal ? curr.x : curr.y;
39383
39444
  ldata = isHorizontal ? curr.y : curr.x;
39384
39445
  }
@@ -39461,12 +39522,12 @@ var modules = {
39461
39522
  * @returns {array} data info added position and etc
39462
39523
  */
39463
39524
  addSeriesDSForHeatMap: function addSeriesDSForHeatMap(data) {
39464
- return data.map(function (_ref) {
39465
- var x = _ref.x,
39466
- y = _ref.y,
39467
- value = _ref.value,
39468
- _ref$color = _ref.color,
39469
- color = _ref$color === void 0 ? null : _ref$color;
39525
+ return data.map(function (_ref2) {
39526
+ var x = _ref2.x,
39527
+ y = _ref2.y,
39528
+ value = _ref2.value,
39529
+ _ref2$color = _ref2.color,
39530
+ color = _ref2$color === void 0 ? null : _ref2$color;
39470
39531
  return {
39471
39532
  x: x,
39472
39533
  y: y,
@@ -39617,8 +39678,8 @@ var modules = {
39617
39678
  var minValue;
39618
39679
  var maxValue = 0;
39619
39680
  var isExistError = false;
39620
- data.forEach(function (_ref2) {
39621
- var value = _ref2.o;
39681
+ data.forEach(function (_ref3) {
39682
+ var value = _ref3.o;
39622
39683
 
39623
39684
  if (maxValue < value) {
39624
39685
  maxValue = Math.max(maxValue, value);
@@ -39910,9 +39971,9 @@ var modules = {
39910
39971
  };
39911
39972
  var seriesList = this.data.series;
39912
39973
  var pointSize = (_Object$values$sort$ = (_Object$values$sort$2 = Object.values(seriesList).sort(function (a, b) {
39913
- var _ref3, _b$pointSize;
39974
+ var _ref4, _b$pointSize;
39914
39975
 
39915
- return (_ref3 = (_b$pointSize = b.pointSize) !== null && _b$pointSize !== void 0 ? _b$pointSize : 0 - a.pointSize) !== null && _ref3 !== void 0 ? _ref3 : 0;
39976
+ return (_ref4 = (_b$pointSize = b.pointSize) !== null && _b$pointSize !== void 0 ? _b$pointSize : 0 - a.pointSize) !== null && _ref4 !== void 0 ? _ref4 : 0;
39916
39977
  })[0]) === null || _Object$values$sort$2 === void 0 ? void 0 : _Object$values$sort$2.pointSize) !== null && _Object$values$sort$ !== void 0 ? _Object$values$sort$ : 3; // default pointSize 3
39917
39978
 
39918
39979
  var _this$options = this.options,
@@ -39944,10 +40005,10 @@ var modules = {
39944
40005
  _scrollbarOpt2$interv = _scrollbarOpt2.interval,
39945
40006
  interval = _scrollbarOpt2$interv === void 0 ? 1 : _scrollbarOpt2$interv;
39946
40007
 
39947
- var _ref4 = range !== null && range !== void 0 ? range : [0, scale.labels.length],
39948
- _ref5 = _slicedToArray(_ref4, 2),
39949
- min = _ref5[0],
39950
- max = _ref5[1];
40008
+ var _ref5 = range !== null && range !== void 0 ? range : [0, scale.labels.length],
40009
+ _ref6 = _slicedToArray(_ref5, 2),
40010
+ min = _ref6[0],
40011
+ max = _ref6[1];
39951
40012
 
39952
40013
  var labelCount = Math.floor((+max - +min) / interval) + 1;
39953
40014
  var labelGap = (endPoint - startPoint) / labelCount;
@@ -42380,13 +42441,14 @@ var element_scatter_Scatter = /*#__PURE__*/function () {
42380
42441
 
42381
42442
  ['color', 'pointFill', 'fillColor', 'overflowColor'].forEach(function (colorProp) {
42382
42443
  if (_this[colorProp] === undefined) {
42383
- _this[colorProp] = COLOR[sIdx];
42444
+ _this[colorProp] = COLOR[sIdx % COLOR.length];
42384
42445
  }
42385
42446
  });
42386
42447
  this.sId = sId;
42387
42448
  this.data = [];
42388
42449
  this.type = 'scatter';
42389
42450
  this.realTimeScatter = realTimeScatter;
42451
+ this._rtTotalCount = 0;
42390
42452
  }
42391
42453
  /**
42392
42454
  * Draw series data
@@ -42530,6 +42592,7 @@ var element_scatter_Scatter = /*#__PURE__*/function () {
42530
42592
  var minmaxY = axesSteps.y[this.yAxisIndex];
42531
42593
  var pointStyle = typeof this.pointStyle === 'string' ? this.pointStyle : this.pointStyle.value;
42532
42594
  var pointSize = typeof this.pointSize === 'number' ? this.pointSize : this.pointSize.value;
42595
+ var totalCount = 0;
42533
42596
 
42534
42597
  for (var i = 0; i < ((_this$data$this$sId = this.data[this.sId]) === null || _this$data$this$sId === void 0 ? void 0 : (_this$data$this$sId$d = _this$data$this$sId.dataGroup) === null || _this$data$this$sId$d === void 0 ? void 0 : _this$data$this$sId$d.length); i++) {
42535
42598
  var _this$data$this$sId, _this$data$this$sId$d;
@@ -42538,6 +42601,7 @@ var element_scatter_Scatter = /*#__PURE__*/function () {
42538
42601
  var _this$data$this$sId2, _this$data$this$sId2$, _this$data$this$sId3, _this$data$this$sId3$;
42539
42602
 
42540
42603
  var item = (_this$data$this$sId3 = this.data[this.sId]) === null || _this$data$this$sId3 === void 0 ? void 0 : (_this$data$this$sId3$ = _this$data$this$sId3.dataGroup[i]) === null || _this$data$this$sId3$ === void 0 ? void 0 : _this$data$this$sId3$.data[j];
42604
+ totalCount++;
42541
42605
  var isDedupeOnRT = coordinateDedupe !== false;
42542
42606
  var shouldDraw = void 0;
42543
42607
 
@@ -42564,7 +42628,11 @@ var element_scatter_Scatter = /*#__PURE__*/function () {
42564
42628
  }
42565
42629
  }
42566
42630
  }
42567
- }
42631
+ } // findGraphData(realTimeScatter)에서 역순 탐색 시 global index 계산에 사용한다.
42632
+ // draw 단계에서 이미 전체 순회를 하기 때문에 여기서 캐시하면 mousemove마다 카운트용 1패스를 줄일 수 있다.
42633
+
42634
+
42635
+ this._rtTotalCount = totalCount;
42568
42636
  }
42569
42637
  /**
42570
42638
  * Filters and returns data items based on input coordinates
@@ -42670,7 +42738,6 @@ var element_scatter_Scatter = /*#__PURE__*/function () {
42670
42738
  }, {
42671
42739
  key: "findGraphData",
42672
42740
  value: function findGraphData(offset) {
42673
- if (this.realTimeScatter) return false;
42674
42741
  var xp = offset[0];
42675
42742
  var yp = offset[1];
42676
42743
  var item = {
@@ -42680,6 +42747,46 @@ var element_scatter_Scatter = /*#__PURE__*/function () {
42680
42747
  index: null
42681
42748
  };
42682
42749
  var pointSize = this.pointSize;
42750
+
42751
+ if (this.realTimeScatter) {
42752
+ var _this$data$this$sId4;
42753
+
42754
+ var dataGroup = (_this$data$this$sId4 = this.data[this.sId]) === null || _this$data$this$sId4 === void 0 ? void 0 : _this$data$this$sId4.dataGroup;
42755
+
42756
+ if (!dataGroup) {
42757
+ return item;
42758
+ }
42759
+
42760
+ var totalCount = this._rtTotalCount;
42761
+ var currentIndex = totalCount - 1;
42762
+
42763
+ for (var i = dataGroup.length - 1; i >= 0; i--) {
42764
+ var group = dataGroup[i];
42765
+
42766
+ if (group !== null && group !== void 0 && group.data) {
42767
+ for (var j = group.data.length - 1; j >= 0; j--) {
42768
+ var dataItem = group.data[j];
42769
+
42770
+ if (dataItem.xp !== null && dataItem.yp !== null) {
42771
+ var x = dataItem.xp;
42772
+ var y = dataItem.yp;
42773
+
42774
+ if (x - pointSize <= xp && xp <= x + pointSize && y - pointSize <= yp && yp <= y + pointSize) {
42775
+ item.data = dataItem;
42776
+ item.index = currentIndex;
42777
+ item.hit = true;
42778
+ return item;
42779
+ }
42780
+ }
42781
+
42782
+ currentIndex--;
42783
+ }
42784
+ }
42785
+ }
42786
+
42787
+ return item;
42788
+ }
42789
+
42683
42790
  var gdata = this.data;
42684
42791
  var targetIndex = gdata.findIndex(function (data) {
42685
42792
  var x = data.xp;
@@ -42737,7 +42844,7 @@ var element_bar_Bar = /*#__PURE__*/function () {
42737
42844
  }
42738
42845
 
42739
42846
  if (this.color === undefined) {
42740
- this.color = COLOR[sIdx];
42847
+ this.color = COLOR[sIdx % COLOR.length];
42741
42848
  }
42742
42849
 
42743
42850
  this.type = 'bar';
@@ -43717,7 +43824,7 @@ var element_pie_Pie = /*#__PURE__*/function () {
43717
43824
  }
43718
43825
 
43719
43826
  if (this.color === undefined) {
43720
- this.color = COLOR[sIdx];
43827
+ this.color = COLOR[sIdx % COLOR.length];
43721
43828
  }
43722
43829
 
43723
43830
  this.sId = sId;
@@ -45169,26 +45276,28 @@ var scale_Scale = /*#__PURE__*/function () {
45169
45276
  max: maxValue,
45170
45277
  minLabel: minLabel,
45171
45278
  maxLabel: maxLabel,
45172
- size: helpers_util.calcTextSize(maxLabel, helpers_util.getLabelStyle(this.labelStyle), (_this$labelStyle = this.labelStyle) === null || _this$labelStyle === void 0 ? void 0 : _this$labelStyle.padding)
45279
+ size: helpers_util.calcTextSizeCanvas(maxLabel, helpers_util.getLabelStyle(this.labelStyle), (_this$labelStyle = this.labelStyle) === null || _this$labelStyle === void 0 ? void 0 : _this$labelStyle.padding)
45173
45280
  };
45174
45281
  }
45175
45282
  /**
45176
45283
  * return width what has max length
45177
45284
  * @param {string[]} notFormattedLabels
45285
+ * @param {object} chartRect - unused in base class, used in StepScale override
45178
45286
  * @reutrn number maxWidth
45179
45287
  */
45288
+ // eslint-disable-next-line no-unused-vars
45180
45289
 
45181
45290
  }, {
45182
45291
  key: "getLabelWidthHasMaxLength",
45183
- value: function getLabelWidthHasMaxLength(notFormattedLabels) {
45292
+ value: function getLabelWidthHasMaxLength(notFormattedLabels, chartRect) {
45184
45293
  var _this2 = this;
45185
45294
 
45186
45295
  return (notFormattedLabels !== null && notFormattedLabels !== void 0 ? notFormattedLabels : []).reduce(function (max, label) {
45187
- var _Util$calcTextSize$wi, _Util$calcTextSize;
45296
+ var _Util$calcTextSizeCan, _Util$calcTextSizeCan2;
45188
45297
 
45189
45298
  var formattedLabel = _this2.getLabelFormat(label);
45190
45299
 
45191
- var width = (_Util$calcTextSize$wi = (_Util$calcTextSize = helpers_util.calcTextSize(formattedLabel, helpers_util.getLabelStyle(_this2.labelStyle))) === null || _Util$calcTextSize === void 0 ? void 0 : _Util$calcTextSize.width) !== null && _Util$calcTextSize$wi !== void 0 ? _Util$calcTextSize$wi : 0;
45300
+ var width = (_Util$calcTextSizeCan = (_Util$calcTextSizeCan2 = helpers_util.calcTextSizeCanvas(formattedLabel, helpers_util.getLabelStyle(_this2.labelStyle))) === null || _Util$calcTextSizeCan2 === void 0 ? void 0 : _Util$calcTextSizeCan2.width) !== null && _Util$calcTextSizeCan !== void 0 ? _Util$calcTextSizeCan : 0;
45192
45301
  return Math.max(max, width);
45193
45302
  }, 0);
45194
45303
  }
@@ -46459,6 +46568,7 @@ var scale_logarithmic_LogarithmicScale = /*#__PURE__*/function (_Scale) {
46459
46568
 
46460
46569
 
46461
46570
 
46571
+
46462
46572
  var scale_step_StepScale = /*#__PURE__*/function (_Scale) {
46463
46573
  _inherits(StepScale, _Scale);
46464
46574
 
@@ -46529,7 +46639,7 @@ var scale_step_StepScale = /*#__PURE__*/function (_Scale) {
46529
46639
  maxIndex: maxIndex,
46530
46640
  minLabel: this.getLabelFormat(minValue, maxWidth),
46531
46641
  maxLabel: this.getLabelFormat(maxValue, maxWidth),
46532
- size: helpers_util.calcTextSize(this.getLabelFormat(maxValue, maxWidth), helpers_util.getLabelStyle(this.labelStyle))
46642
+ size: helpers_util.calcTextSizeCanvas(this.getLabelFormat(maxValue, maxWidth), helpers_util.getLabelStyle(this.labelStyle))
46533
46643
  };
46534
46644
  }
46535
46645
  }, {
@@ -46914,6 +47024,36 @@ var scale_step_StepScale = /*#__PURE__*/function (_Scale) {
46914
47024
  var dir = this.labelStyle.fitDir;
46915
47025
  return helpers_util.truncateLabelWithEllipsis(value, maxWidth, ctx, dir);
46916
47026
  }
47027
+ /**
47028
+ * return width what has max length
47029
+ * ellipsis가 적용된 label의 width를 계산 (fontSize 적용)
47030
+ * @param {string[]} notFormattedLabels
47031
+ * @param {object} chartRect
47032
+ * @returns {number} maxWidth
47033
+ */
47034
+
47035
+ }, {
47036
+ key: "getLabelWidthHasMaxLength",
47037
+ value: function getLabelWidthHasMaxLength(notFormattedLabels, chartRect) {
47038
+ var _notFormattedLabels$l,
47039
+ _this$labelStyle$maxW3,
47040
+ _this$labelStyle5,
47041
+ _this3 = this;
47042
+
47043
+ // fontSize를 포함한 labelStyle 가져오기
47044
+ var labelStyle = helpers_util.getLabelStyle(this.labelStyle);
47045
+ var labelCount = (_notFormattedLabels$l = notFormattedLabels === null || notFormattedLabels === void 0 ? void 0 : notFormattedLabels.length) !== null && _notFormattedLabels$l !== void 0 ? _notFormattedLabels$l : 0;
47046
+ var maxWidth = (_this$labelStyle$maxW3 = (_this$labelStyle5 = this.labelStyle) === null || _this$labelStyle5 === void 0 ? void 0 : _this$labelStyle5.maxWidth) !== null && _this$labelStyle$maxW3 !== void 0 ? _this$labelStyle$maxW3 : (chartRect === null || chartRect === void 0 ? void 0 : chartRect.chartWidth) / (labelCount + 2);
47047
+ return (notFormattedLabels !== null && notFormattedLabels !== void 0 ? notFormattedLabels : []).reduce(function (max, label) {
47048
+ var _Util$calcTextSizeCan, _Util$calcTextSizeCan2;
47049
+
47050
+ // ellipsis가 적용된 label의 width를 계산
47051
+ var formattedLabel = _this3.getLabelFormat(label, maxWidth);
47052
+
47053
+ var width = (_Util$calcTextSizeCan = (_Util$calcTextSizeCan2 = helpers_util.calcTextSizeCanvas(formattedLabel, labelStyle)) === null || _Util$calcTextSizeCan2 === void 0 ? void 0 : _Util$calcTextSizeCan2.width) !== null && _Util$calcTextSizeCan !== void 0 ? _Util$calcTextSizeCan : 0;
47054
+ return Math.max(max, width);
47055
+ }, 0);
47056
+ }
46917
47057
  }]);
46918
47058
 
46919
47059
  return StepScale;
@@ -48012,7 +48152,8 @@ var plugins_legend_modules = {
48012
48152
  },
48013
48153
  hitInfo: {
48014
48154
  legend: null
48015
- }
48155
+ },
48156
+ lightUpdate: true
48016
48157
  });
48017
48158
  };
48018
48159
  /**
@@ -48048,7 +48189,8 @@ var plugins_legend_modules = {
48048
48189
  },
48049
48190
  hitInfo: {
48050
48191
  legend: legendHitInfo
48051
- }
48192
+ },
48193
+ lightUpdate: true
48052
48194
  });
48053
48195
  };
48054
48196
 
@@ -48260,7 +48402,8 @@ var plugins_legend_modules = {
48260
48402
  updateSelTip: {
48261
48403
  update: false,
48262
48404
  keepDomain: false
48263
- }
48405
+ },
48406
+ lightUpdate: true
48264
48407
  });
48265
48408
  };
48266
48409
  /**
@@ -48301,7 +48444,8 @@ var plugins_legend_modules = {
48301
48444
  },
48302
48445
  hitInfo: {
48303
48446
  legend: legendHitInfo
48304
- }
48447
+ },
48448
+ lightUpdate: true
48305
48449
  });
48306
48450
  };
48307
48451
 
@@ -50224,7 +50368,9 @@ var plugins_scrollbar_module = {
50224
50368
  updateSelTip: {
50225
50369
  update: false,
50226
50370
  keepDomain: false
50227
- }
50371
+ },
50372
+ updateByScrollbar: true,
50373
+ lightUpdate: minValue > 1
50228
50374
  });
50229
50375
  }
50230
50376
  },
@@ -52346,6 +52492,7 @@ var plugins_interaction_modules = {
52346
52492
  formattedTxt = tooltipValueFormatter({
52347
52493
  x: isHorizontal ? value : itemData === null || itemData === void 0 ? void 0 : itemData.x,
52348
52494
  y: isHorizontal ? itemData === null || itemData === void 0 ? void 0 : itemData.y : value,
52495
+ o: itemData === null || itemData === void 0 ? void 0 : itemData.o,
52349
52496
  name: seriesName,
52350
52497
  seriesId: seriesId,
52351
52498
  dataId: dataId
@@ -55045,7 +55192,6 @@ var element_tip_modules = {
55045
55192
 
55046
55193
 
55047
55194
 
55048
-
55049
55195
 
55050
55196
 
55051
55197
  var chart_core_EvChart = /*#__PURE__*/function () {
@@ -55236,51 +55382,38 @@ var chart_core_EvChart = /*#__PURE__*/function () {
55236
55382
  }, {
55237
55383
  key: "adjustXAndYAxisWidth",
55238
55384
  value: function adjustXAndYAxisWidth() {
55239
- var _this$options$axesX,
55240
- _this$options$axesY,
55241
- _this2 = this,
55242
- _this$axesSteps,
55243
- _this$axesSteps2,
55244
- _this$axesY$,
55245
- _this$axesY$$labelSty,
55246
- _this$axesY$2,
55247
- _this$axesY$2$labelSt,
55248
- _this$axesX$,
55249
- _this$axesX$$labelSty,
55250
- _this$axesX$2,
55251
- _this$axesX$2$labelSt,
55252
- _this$axesX$3,
55253
- _this$axesY$3,
55385
+ var _this2 = this,
55254
55386
  _this$axesRange,
55255
55387
  _this$axesRange$x,
55256
55388
  _this$axesRange2,
55257
- _this$axesRange3,
55258
- _this$axesRange3$y,
55259
- _this$axesRange4;
55260
-
55261
- // fitWidth(maxWidth에 넘을 시 말줄임표 들어가는 기능)을 사용중인 step Axis인 경우에는 적용 제외
55262
- var isStepXAxisUseFitWidth = (_this$options$axesX = this.options.axesX) === null || _this$options$axesX === void 0 ? void 0 : _this$options$axesX.some(function (axisX) {
55263
- var _axisX$labelStyle;
55264
-
55265
- return axisX.type === 'step' && ((_axisX$labelStyle = axisX.labelStyle) === null || _axisX$labelStyle === void 0 ? void 0 : _axisX$labelStyle.fitWidth);
55266
- });
55267
- var isStepYAxisUseFitWidth = (_this$options$axesY = this.options.axesY) === null || _this$options$axesY === void 0 ? void 0 : _this$options$axesY.some(function (axisY) {
55268
- var _axisY$labelStyle;
55389
+ _this$axesRange2$y;
55269
55390
 
55270
- return axisY.type === 'step' && ((_axisY$labelStyle = axisY.labelStyle) === null || _axisY$labelStyle === void 0 ? void 0 : _axisY$labelStyle.fitWidth);
55271
- });
55272
-
55273
- var getNotFormattedLabels = function getNotFormattedLabels(axesSteps) {
55391
+ var getNotFormattedLabels = function getNotFormattedLabels(axesSteps, axisType, axis) {
55274
55392
  var _ref2 = axesSteps !== null && axesSteps !== void 0 ? axesSteps : {},
55275
55393
  interval = _ref2.interval,
55276
55394
  graphMin = _ref2.graphMin,
55277
55395
  graphMax = _ref2.graphMax,
55278
55396
  _ref2$steps = _ref2.steps,
55279
- steps = _ref2$steps === void 0 ? 0 : _ref2$steps;
55397
+ steps = _ref2$steps === void 0 ? 0 : _ref2$steps,
55398
+ minIndex = _ref2.minIndex,
55399
+ maxIndex = _ref2.maxIndex,
55400
+ indexInterval = _ref2.indexInterval;
55280
55401
 
55281
- var result = [];
55402
+ var result = []; // StepScale의 경우 실제로 표시될 모든 라벨들을 포함
55282
55403
 
55283
- if (interval) {
55404
+ if ((axis === null || axis === void 0 ? void 0 : axis.type) === 'step' && minIndex !== undefined && maxIndex !== undefined && indexInterval !== undefined) {
55405
+ var _ref3, _labels$x, _ref4, _labels$y;
55406
+
55407
+ var labels = _this2.data.labels;
55408
+ var axisLabels = axisType === 'x' ? (_ref3 = (_labels$x = labels === null || labels === void 0 ? void 0 : labels.x) !== null && _labels$x !== void 0 ? _labels$x : labels) !== null && _ref3 !== void 0 ? _ref3 : [] : (_ref4 = (_labels$y = labels === null || labels === void 0 ? void 0 : labels.y) !== null && _labels$y !== void 0 ? _labels$y : labels) !== null && _ref4 !== void 0 ? _ref4 : [];
55409
+ result = [];
55410
+
55411
+ for (var i = minIndex; i <= maxIndex; i += indexInterval) {
55412
+ if (axisLabels[i] !== undefined) {
55413
+ result.push(axisLabels[i]);
55414
+ }
55415
+ }
55416
+ } else if (interval) {
55284
55417
  result = Array.from({
55285
55418
  length: steps
55286
55419
  }, function (_, i) {
@@ -55288,38 +55421,46 @@ var chart_core_EvChart = /*#__PURE__*/function () {
55288
55421
  });
55289
55422
  result.push(graphMax);
55290
55423
  } else {
55291
- var _ref3, _labels$y;
55424
+ var _ref5, _labels$x2, _ref6, _labels$y2;
55292
55425
 
55293
- var labels = _this2.data.labels;
55294
- result = (_ref3 = (_labels$y = labels === null || labels === void 0 ? void 0 : labels.y) !== null && _labels$y !== void 0 ? _labels$y : labels) !== null && _ref3 !== void 0 ? _ref3 : [];
55426
+ var _labels = _this2.data.labels;
55427
+ result = axisType === 'x' ? (_ref5 = (_labels$x2 = _labels === null || _labels === void 0 ? void 0 : _labels.x) !== null && _labels$x2 !== void 0 ? _labels$x2 : _labels) !== null && _ref5 !== void 0 ? _ref5 : [] : (_ref6 = (_labels$y2 = _labels === null || _labels === void 0 ? void 0 : _labels.y) !== null && _labels$y2 !== void 0 ? _labels$y2 : _labels) !== null && _ref6 !== void 0 ? _ref6 : [];
55295
55428
  }
55296
55429
 
55297
55430
  return result;
55298
55431
  };
55299
55432
 
55300
- var notFormattedXLabels = getNotFormattedLabels((_this$axesSteps = this.axesSteps) === null || _this$axesSteps === void 0 ? void 0 : _this$axesSteps.x[0]);
55301
- var notFormattedYLabels = getNotFormattedLabels((_this$axesSteps2 = this.axesSteps) === null || _this$axesSteps2 === void 0 ? void 0 : _this$axesSteps2.y[0]);
55302
- var yFixWidth = truthyNumber((_this$axesY$ = this.axesY[0]) === null || _this$axesY$ === void 0 ? void 0 : (_this$axesY$$labelSty = _this$axesY$.labelStyle) === null || _this$axesY$$labelSty === void 0 ? void 0 : _this$axesY$$labelSty.fixWidth) ? (_this$axesY$2 = this.axesY[0]) === null || _this$axesY$2 === void 0 ? void 0 : (_this$axesY$2$labelSt = _this$axesY$2.labelStyle) === null || _this$axesY$2$labelSt === void 0 ? void 0 : _this$axesY$2$labelSt.fixWidth : 0;
55303
- var xFixWidth = truthyNumber((_this$axesX$ = this.axesX[0]) === null || _this$axesX$ === void 0 ? void 0 : (_this$axesX$$labelSty = _this$axesX$.labelStyle) === null || _this$axesX$$labelSty === void 0 ? void 0 : _this$axesX$$labelSty.fixWidth) ? (_this$axesX$2 = this.axesX[0]) === null || _this$axesX$2 === void 0 ? void 0 : (_this$axesX$2$labelSt = _this$axesX$2.labelStyle) === null || _this$axesX$2$labelSt === void 0 ? void 0 : _this$axesX$2$labelSt.fixWidth : 0;
55304
- var xMaxWidth = (_this$axesX$3 = this.axesX[0]) === null || _this$axesX$3 === void 0 ? void 0 : _this$axesX$3.getLabelWidthHasMaxLength(notFormattedXLabels);
55305
- var yMaxWidth = (_this$axesY$3 = this.axesY[0]) === null || _this$axesY$3 === void 0 ? void 0 : _this$axesY$3.getLabelWidthHasMaxLength(notFormattedYLabels);
55306
55433
  var adjustedRange = {
55307
- x: !isStepXAxisUseFitWidth ? (_this$axesRange = this.axesRange) === null || _this$axesRange === void 0 ? void 0 : (_this$axesRange$x = _this$axesRange.x) === null || _this$axesRange$x === void 0 ? void 0 : _this$axesRange$x.map(function (value) {
55434
+ x: (_this$axesRange = this.axesRange) === null || _this$axesRange === void 0 ? void 0 : (_this$axesRange$x = _this$axesRange.x) === null || _this$axesRange$x === void 0 ? void 0 : _this$axesRange$x.map(function (value, index) {
55435
+ var _this2$axesSteps, _axis$labelStyle, _axis$getLabelWidthHa, _axis$getLabelWidthHa2;
55436
+
55437
+ var axis = _this2.axesX[index];
55438
+ var axesSteps = (_this2$axesSteps = _this2.axesSteps) === null || _this2$axesSteps === void 0 ? void 0 : _this2$axesSteps.x[index];
55439
+ var notFormattedLabels = getNotFormattedLabels(axesSteps, 'x', axis);
55440
+ var fixWidth = truthyNumber(axis === null || axis === void 0 ? void 0 : (_axis$labelStyle = axis.labelStyle) === null || _axis$labelStyle === void 0 ? void 0 : _axis$labelStyle.fixWidth) ? axis.labelStyle.fixWidth : 0;
55441
+ var maxWidth = (_axis$getLabelWidthHa = axis === null || axis === void 0 ? void 0 : (_axis$getLabelWidthHa2 = axis.getLabelWidthHasMaxLength) === null || _axis$getLabelWidthHa2 === void 0 ? void 0 : _axis$getLabelWidthHa2.call(axis, notFormattedLabels, _this2.chartRect)) !== null && _axis$getLabelWidthHa !== void 0 ? _axis$getLabelWidthHa : 0;
55308
55442
  return _objectSpread2(_objectSpread2({}, value), {}, {
55309
55443
  size: {
55310
- width: xFixWidth || Math.max(xMaxWidth, value.size.width),
55444
+ width: fixWidth || Math.max(maxWidth, value.size.width),
55311
55445
  height: value.size.height
55312
55446
  }
55313
55447
  });
55314
- }) : (_this$axesRange2 = this.axesRange) === null || _this$axesRange2 === void 0 ? void 0 : _this$axesRange2.x,
55315
- y: !isStepYAxisUseFitWidth ? (_this$axesRange3 = this.axesRange) === null || _this$axesRange3 === void 0 ? void 0 : (_this$axesRange3$y = _this$axesRange3.y) === null || _this$axesRange3$y === void 0 ? void 0 : _this$axesRange3$y.map(function (value) {
55448
+ }),
55449
+ y: (_this$axesRange2 = this.axesRange) === null || _this$axesRange2 === void 0 ? void 0 : (_this$axesRange2$y = _this$axesRange2.y) === null || _this$axesRange2$y === void 0 ? void 0 : _this$axesRange2$y.map(function (value, index) {
55450
+ var _this2$axesSteps2, _axis$labelStyle2, _axis$getLabelWidthHa3, _axis$getLabelWidthHa4;
55451
+
55452
+ var axis = _this2.axesY[index];
55453
+ var axesSteps = (_this2$axesSteps2 = _this2.axesSteps) === null || _this2$axesSteps2 === void 0 ? void 0 : _this2$axesSteps2.y[index];
55454
+ var notFormattedLabels = getNotFormattedLabels(axesSteps, 'y', axis);
55455
+ var fixWidth = truthyNumber(axis === null || axis === void 0 ? void 0 : (_axis$labelStyle2 = axis.labelStyle) === null || _axis$labelStyle2 === void 0 ? void 0 : _axis$labelStyle2.fixWidth) ? axis.labelStyle.fixWidth : 0;
55456
+ var maxWidth = (_axis$getLabelWidthHa3 = axis === null || axis === void 0 ? void 0 : (_axis$getLabelWidthHa4 = axis.getLabelWidthHasMaxLength) === null || _axis$getLabelWidthHa4 === void 0 ? void 0 : _axis$getLabelWidthHa4.call(axis, notFormattedLabels, _this2.chartRect)) !== null && _axis$getLabelWidthHa3 !== void 0 ? _axis$getLabelWidthHa3 : 0;
55316
55457
  return _objectSpread2(_objectSpread2({}, value), {}, {
55317
55458
  size: {
55318
- width: yFixWidth || Math.max(yMaxWidth, value.size.width),
55459
+ width: fixWidth || Math.max(maxWidth, value.size.width),
55319
55460
  height: value.size.height
55320
55461
  }
55321
55462
  });
55322
- }) : (_this$axesRange4 = this.axesRange) === null || _this$axesRange4 === void 0 ? void 0 : _this$axesRange4.y
55463
+ })
55323
55464
  };
55324
55465
  this.axesRange = adjustedRange;
55325
55466
  this.labelOffset = this.getLabelOffset(adjustedRange);
@@ -55813,15 +55954,15 @@ var chart_core_EvChart = /*#__PURE__*/function () {
55813
55954
  }, {
55814
55955
  key: "getChartRect",
55815
55956
  value: function getChartRect() {
55816
- var _this$options$axesX2, _this$options$axesX2$, _this$options$axesY2, _this$options$axesY2$;
55957
+ var _this$options$axesX, _this$options$axesX$, _this$options$axesY, _this$options$axesY$;
55817
55958
 
55818
55959
  var _this$getChartDOMRect = this.getChartDOMRect(),
55819
55960
  width = _this$getChartDOMRect.width,
55820
55961
  height = _this$getChartDOMRect.height;
55821
55962
 
55822
55963
  var padding = this.options.padding;
55823
- var xAxisTitleOpt = (_this$options$axesX2 = this.options.axesX) === null || _this$options$axesX2 === void 0 ? void 0 : (_this$options$axesX2$ = _this$options$axesX2[0]) === null || _this$options$axesX2$ === void 0 ? void 0 : _this$options$axesX2$.title;
55824
- var yAxisTitleOpt = (_this$options$axesY2 = this.options.axesY) === null || _this$options$axesY2 === void 0 ? void 0 : (_this$options$axesY2$ = _this$options$axesY2[0]) === null || _this$options$axesY2$ === void 0 ? void 0 : _this$options$axesY2$.title;
55964
+ var xAxisTitleOpt = (_this$options$axesX = this.options.axesX) === null || _this$options$axesX === void 0 ? void 0 : (_this$options$axesX$ = _this$options$axesX[0]) === null || _this$options$axesX$ === void 0 ? void 0 : _this$options$axesX$.title;
55965
+ var yAxisTitleOpt = (_this$options$axesY = this.options.axesY) === null || _this$options$axesY === void 0 ? void 0 : (_this$options$axesY$ = _this$options$axesY[0]) === null || _this$options$axesY$ === void 0 ? void 0 : _this$options$axesY$.title;
55825
55966
  var titleMargin = 10;
55826
55967
  var xAxisTitleHeight = 0;
55827
55968
 
@@ -55960,9 +56101,9 @@ var chart_core_EvChart = /*#__PURE__*/function () {
55960
56101
  var lw = 0;
55961
56102
  var lh = 0;
55962
56103
  axesX.forEach(function (axis, index) {
55963
- var _axis$labelStyle;
56104
+ var _axis$labelStyle3;
55964
56105
 
55965
- if ((_axis$labelStyle = axis.labelStyle) !== null && _axis$labelStyle !== void 0 && _axis$labelStyle.show) {
56106
+ if ((_axis$labelStyle3 = axis.labelStyle) !== null && _axis$labelStyle3 !== void 0 && _axis$labelStyle3.show) {
55966
56107
  lw = range.x[index].size.width + labelBuffer.width;
55967
56108
  lh = range.x[index].size.height + labelBuffer.height;
55968
56109
 
@@ -55981,9 +56122,9 @@ var chart_core_EvChart = /*#__PURE__*/function () {
55981
56122
  }
55982
56123
  });
55983
56124
  axesY.forEach(function (axis, index) {
55984
- var _axis$labelStyle2;
56125
+ var _axis$labelStyle4;
55985
56126
 
55986
- if ((_axis$labelStyle2 = axis.labelStyle) !== null && _axis$labelStyle2 !== void 0 && _axis$labelStyle2.show) {
56127
+ if ((_axis$labelStyle4 = axis.labelStyle) !== null && _axis$labelStyle4 !== void 0 && _axis$labelStyle4.show) {
55987
56128
  lw = range.y[index].size.width + labelBuffer.width;
55988
56129
 
55989
56130
  if (axis.position === 'left') {
@@ -56012,7 +56153,7 @@ var chart_core_EvChart = /*#__PURE__*/function () {
56012
56153
  }, {
56013
56154
  key: "update",
56014
56155
  value: function update(updateInfo) {
56015
- var _this$updateScrollbar, _this$options$realTim2, _renderHitInfo, _this$legendHover;
56156
+ var _renderHitInfo, _this$legendHover;
56016
56157
 
56017
56158
  var options = this.options;
56018
56159
  var data = this.data.data;
@@ -56023,13 +56164,20 @@ var chart_core_EvChart = /*#__PURE__*/function () {
56023
56164
  updateSelTip = updateInfo.updateSelTip,
56024
56165
  updateLegend = updateInfo.updateLegend,
56025
56166
  updateData = updateInfo.updateData,
56026
- updateTooltip = updateInfo.updateTooltip;
56167
+ updateTooltip = updateInfo.updateTooltip,
56168
+ updateByScrollbar = updateInfo.updateByScrollbar,
56169
+ lightUpdate = updateInfo.lightUpdate;
56027
56170
 
56028
56171
  if (!this.isInit) {
56029
56172
  return;
56030
56173
  }
56031
56174
 
56032
- (_this$updateScrollbar = this.updateScrollbar) === null || _this$updateScrollbar === void 0 ? void 0 : _this$updateScrollbar.call(this, updateData);
56175
+ if (updateByScrollbar) {
56176
+ var _this$updateScrollbar;
56177
+
56178
+ (_this$updateScrollbar = this.updateScrollbar) === null || _this$updateScrollbar === void 0 ? void 0 : _this$updateScrollbar.call(this, updateData);
56179
+ }
56180
+
56033
56181
  this.resetProps();
56034
56182
  this.updateSeries = updateSeries;
56035
56183
 
@@ -56068,54 +56216,60 @@ var chart_core_EvChart = /*#__PURE__*/function () {
56068
56216
  }
56069
56217
  }
56070
56218
 
56071
- if (groups.length) {
56072
- this.addGroupInfo(groups);
56073
- }
56219
+ if (!lightUpdate) {
56220
+ var _this$options$realTim2;
56074
56221
 
56075
- if ((_this$options$realTim2 = this.options.realTimeScatter) !== null && _this$options$realTim2 !== void 0 && _this$options$realTim2.use) {
56076
- if (!this.dataSet) {
56077
- this.dataSet = {};
56078
- }
56222
+ // group update
56223
+ if (groups.length) {
56224
+ this.addGroupInfo(groups);
56225
+ } // dataSet update
56079
56226
 
56080
- this.createRealTimeScatterDataSet(data);
56081
- } else {
56082
- this.createDataSet(data, labels);
56083
- } // title update
56084
56227
 
56228
+ if ((_this$options$realTim2 = this.options.realTimeScatter) !== null && _this$options$realTim2 !== void 0 && _this$options$realTim2.use) {
56229
+ if (!this.dataSet) {
56230
+ this.dataSet = {};
56231
+ }
56085
56232
 
56086
- if (options.title.show) {
56087
- if (!this.isInitTitle) {
56088
- this.initTitle();
56233
+ this.createRealTimeScatterDataSet(data);
56089
56234
  } else {
56090
- this.updateTitle();
56091
- }
56235
+ this.createDataSet(data, labels);
56236
+ } // title update
56092
56237
 
56093
- this.showTitle();
56094
- } else if (this.isInitTitle) {
56095
- this.hideTitle();
56096
- } // legend Update
56097
56238
 
56239
+ if (options.title.show) {
56240
+ if (!this.isInitTitle) {
56241
+ this.initTitle();
56242
+ } else {
56243
+ this.updateTitle();
56244
+ }
56098
56245
 
56099
- if (options.legend.show) {
56100
- var _options$legend, _options$legend$table;
56246
+ this.showTitle();
56247
+ } else if (this.isInitTitle) {
56248
+ this.hideTitle();
56249
+ } // legend Update
56101
56250
 
56102
- var useTable = !!((_options$legend = options.legend) !== null && _options$legend !== void 0 && (_options$legend$table = _options$legend.table) !== null && _options$legend$table !== void 0 && _options$legend$table.use) && options.type !== 'heatMap' && options.type !== 'scatter';
56103
56251
 
56104
- if (!this.isInitLegend) {
56105
- this.initLegend();
56106
- } else if (updateSeries) {
56107
- this.updateLegend();
56108
- } else if (updateLegend) {
56109
- this.forceUpdateLegend();
56110
- } else if (useTable && updateData) {
56111
- this.updateLegendTableValues();
56112
- }
56252
+ if (options.legend.show) {
56253
+ var _options$legend, _options$legend$table;
56113
56254
 
56114
- this.setLegendPosition();
56115
- this.updateLegendContainerSize();
56116
- this.showLegend();
56117
- } else if (this.isInitLegend) {
56118
- this.hideLegend();
56255
+ var useTable = !!((_options$legend = options.legend) !== null && _options$legend !== void 0 && (_options$legend$table = _options$legend.table) !== null && _options$legend$table !== void 0 && _options$legend$table.use) && options.type !== 'heatMap' && options.type !== 'scatter';
56256
+
56257
+ if (!this.isInitLegend) {
56258
+ this.initLegend();
56259
+ } else if (updateSeries) {
56260
+ this.updateLegend();
56261
+ } else if (updateLegend) {
56262
+ this.forceUpdateLegend();
56263
+ } else if (useTable && updateData) {
56264
+ this.updateLegendTableValues();
56265
+ }
56266
+
56267
+ this.setLegendPosition();
56268
+ this.updateLegendContainerSize();
56269
+ this.showLegend();
56270
+ } else if (this.isInitLegend) {
56271
+ this.hideLegend();
56272
+ }
56119
56273
  } // Tooltip Update
56120
56274
 
56121
56275
 
@@ -56133,7 +56287,6 @@ var chart_core_EvChart = /*#__PURE__*/function () {
56133
56287
  }
56134
56288
  }
56135
56289
 
56136
- this.chartRect = this.getChartRect();
56137
56290
  this.minMax = this.getStoreMinMax();
56138
56291
  this.axesX = this.createAxes('x', options.axesX);
56139
56292
  this.axesY = this.createAxes('y', options.axesY);