tvcharts 0.6.8 → 0.6.10

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 (34) hide show
  1. package/dist/echarts.js +257 -103
  2. package/dist/echarts.js.map +3 -3
  3. package/index.js +2 -2
  4. package/lib/chart/bgColor/BgColorLayout.js +90 -0
  5. package/lib/chart/bgColor/BgColorSeries.js +94 -0
  6. package/lib/chart/bgColor/BgColorView.js +89 -0
  7. package/lib/chart/bgColor/install.js +73 -0
  8. package/lib/chart/hlines/HLinesSeries.js +135 -0
  9. package/lib/chart/hlines/HLinesView.js +89 -0
  10. package/lib/chart/hlines/hLinesLayout.js +90 -0
  11. package/lib/chart/hlines/install.js +73 -0
  12. package/lib/chart/hlines.js +46 -0
  13. package/lib/component/dataZoom/AxisProxy.js +5 -1
  14. package/lib/component/marker/MarkLabelView.js +13 -2
  15. package/lib/export/charts.js +1 -0
  16. package/lib/model/Global.js +1 -0
  17. package/lib/util/states.js +14 -1
  18. package/package.json +1 -1
  19. package/types/dist/charts.d.ts +1 -1
  20. package/types/dist/components.d.ts +1 -1
  21. package/types/dist/echarts.d.ts +3 -0
  22. package/types/dist/renderers.d.ts +1 -1
  23. package/types/dist/shared.d.ts +9 -4
  24. package/types/src/chart/bgColor/BgColorLayout.d.ts +3 -0
  25. package/types/src/chart/bgColor/BgColorSeries.d.ts +49 -0
  26. package/types/src/chart/bgColor/BgColorView.d.ts +18 -0
  27. package/types/src/chart/bgColor/install.d.ts +2 -0
  28. package/types/src/chart/hlines/HLinesSeries.d.ts +49 -0
  29. package/types/src/chart/hlines/HLinesView.d.ts +18 -0
  30. package/types/src/chart/hlines/hLinesLayout.d.ts +3 -0
  31. package/types/src/chart/hlines/install.d.ts +2 -0
  32. package/types/src/chart/hlines.d.ts +1 -0
  33. package/types/src/export/charts.d.ts +1 -0
  34. package/types/src/util/types.d.ts +3 -0
package/dist/echarts.js CHANGED
@@ -225,16 +225,16 @@ var OFFSET = 20;
225
225
  var SCALE = 100;
226
226
  var defaultWidthMapStr = `007LLmW'55;N0500LLLLLLLLLL00NNNLzWW\\\\WQb\\0FWLg\\bWb\\WQ\\WrWWQ000CL5LLFLL0LL**F*gLLLL5F0LF\\FFF5.5N`;
227
227
  function getTextWidthMap(mapStr) {
228
- const map3 = {};
228
+ const map4 = {};
229
229
  if (typeof JSON === "undefined") {
230
- return map3;
230
+ return map4;
231
231
  }
232
232
  for (let i = 0; i < mapStr.length; i++) {
233
233
  const char = String.fromCharCode(i + 32);
234
234
  const size = (mapStr.charCodeAt(i) - OFFSET) / SCALE;
235
- map3[char] = size;
235
+ map4[char] = size;
236
236
  }
237
- return map3;
237
+ return map4;
238
238
  }
239
239
  var DEFAULT_TEXT_WIDTH_MAP = getTextWidthMap(defaultWidthMapStr);
240
240
  var platformApi = {
@@ -3503,15 +3503,15 @@ var LRU = class {
3503
3503
  }
3504
3504
  put(key, value) {
3505
3505
  const list = this._list;
3506
- const map3 = this._map;
3506
+ const map4 = this._map;
3507
3507
  let removed = null;
3508
- if (map3[key] == null) {
3508
+ if (map4[key] == null) {
3509
3509
  const len2 = list.len();
3510
3510
  let entry = this._lastRemovedEntry;
3511
3511
  if (len2 >= this._maxSize && len2 > 0) {
3512
3512
  const leastUsedEntry = list.head;
3513
3513
  list.remove(leastUsedEntry);
3514
- delete map3[leastUsedEntry.key];
3514
+ delete map4[leastUsedEntry.key];
3515
3515
  removed = leastUsedEntry.value;
3516
3516
  this._lastRemovedEntry = leastUsedEntry;
3517
3517
  }
@@ -3522,7 +3522,7 @@ var LRU = class {
3522
3522
  }
3523
3523
  entry.key = key;
3524
3524
  list.insertEntry(entry);
3525
- map3[key] = entry;
3525
+ map4[key] = entry;
3526
3526
  }
3527
3527
  return removed;
3528
3528
  }
@@ -7778,7 +7778,7 @@ function compressBatches(batchA, batchB) {
7778
7778
  makeMap(batchA || [], mapA);
7779
7779
  makeMap(batchB || [], mapB, mapA);
7780
7780
  return [mapToArray(mapA), mapToArray(mapB)];
7781
- function makeMap(sourceBatch, map3, otherMap) {
7781
+ function makeMap(sourceBatch, map4, otherMap) {
7782
7782
  for (let i = 0, len2 = sourceBatch.length; i < len2; i++) {
7783
7783
  const seriesId = convertOptionIdName(sourceBatch[i].seriesId, null);
7784
7784
  if (seriesId == null) {
@@ -7791,19 +7791,19 @@ function compressBatches(batchA, batchB) {
7791
7791
  if (otherDataIndices && otherDataIndices[dataIndex]) {
7792
7792
  otherDataIndices[dataIndex] = null;
7793
7793
  } else {
7794
- (map3[seriesId] || (map3[seriesId] = {}))[dataIndex] = 1;
7794
+ (map4[seriesId] || (map4[seriesId] = {}))[dataIndex] = 1;
7795
7795
  }
7796
7796
  }
7797
7797
  }
7798
7798
  }
7799
- function mapToArray(map3, isData) {
7799
+ function mapToArray(map4, isData) {
7800
7800
  const result = [];
7801
- for (const i in map3) {
7802
- if (map3.hasOwnProperty(i) && map3[i] != null) {
7801
+ for (const i in map4) {
7802
+ if (map4.hasOwnProperty(i) && map4[i] != null) {
7803
7803
  if (isData) {
7804
7804
  result.push(+i);
7805
7805
  } else {
7806
- const dataIndices = mapToArray(map3[i], true);
7806
+ const dataIndices = mapToArray(map4[i], true);
7807
7807
  dataIndices.length && result.push({seriesId: i, dataIndex: dataIndices});
7808
7808
  }
7809
7809
  }
@@ -11816,12 +11816,17 @@ function getAllSelectedIndices(ecModel) {
11816
11816
  function getSeriesPointData(ecModel, payload = {}) {
11817
11817
  const seriesPointData = {};
11818
11818
  ecModel.eachSeries(function(seriesModel) {
11819
+ if (seriesModel.get("statusLineInvisible")) {
11820
+ return;
11821
+ }
11822
+ const formatter = seriesModel.get("formatter");
11819
11823
  const data = seriesModel.getData();
11820
11824
  const isRaw = !payload.dataIndex;
11821
11825
  const index = payload.dataIndex ?? data.count(isRaw) - 1;
11822
11826
  const values = isRaw ? data.getValuesByRawIndex(index) : data.getValues(index);
11823
11827
  let color2 = data.getItemVisual(index, "style").fill;
11824
11828
  const isCandlesStick = seriesModel.subType === "candlestick";
11829
+ const isLinesPlot = seriesModel.subType === "linesPlot";
11825
11830
  const dim = seriesModel.subType === "candlestick" ? "close" : "y";
11826
11831
  const fnKey = isRaw ? "getByRawIndex" : "get";
11827
11832
  if (isCandlesStick) {
@@ -11833,6 +11838,12 @@ function getSeriesPointData(ecModel, payload = {}) {
11833
11838
  if (fill) {
11834
11839
  color2 = fill;
11835
11840
  }
11841
+ } else if (isLinesPlot) {
11842
+ const dataItem = data.getItemModel(index, isRaw);
11843
+ const fill = dataItem.get(["lineStyle", "color"]);
11844
+ if (fill) {
11845
+ color2 = fill;
11846
+ }
11836
11847
  } else {
11837
11848
  const closeValue = data[fnKey]("y", index);
11838
11849
  const openValue = data[fnKey]("y", index - 1);
@@ -11851,7 +11862,9 @@ function getSeriesPointData(ecModel, payload = {}) {
11851
11862
  const seriesName = seriesModel.name;
11852
11863
  seriesPointData[seriesName] = {
11853
11864
  name: seriesName,
11854
- data: values,
11865
+ data: values.map((item, index2) => {
11866
+ return formatter && index2 !== 0 ? formatter(item) : item;
11867
+ }),
11855
11868
  color: color2,
11856
11869
  seriesId,
11857
11870
  changePercent,
@@ -16112,6 +16125,7 @@ var BUILTIN_CHARTS_MAP = {
16112
16125
  effectScatter: "EffectScatterChart",
16113
16126
  lines: "LinesChart",
16114
16127
  linesPlot: "LinesPlotChart",
16128
+ hlines: "HLinesChart",
16115
16129
  heatmap: "HeatmapChart",
16116
16130
  pictorialBar: "PictorialBarChart",
16117
16131
  themeRiver: "ThemeRiverChart",
@@ -24875,25 +24889,25 @@ var DataDiffer = class {
24875
24889
  newDataIndexMap[newKey] = null;
24876
24890
  }
24877
24891
  }
24878
- _initIndexMap(arr, map3, keyArr, keyGetterName) {
24892
+ _initIndexMap(arr, map4, keyArr, keyGetterName) {
24879
24893
  const cbModeMultiple = this._diffModeMultiple;
24880
24894
  for (let i = 0; i < arr.length; i++) {
24881
24895
  const key = "_ec_" + this[keyGetterName](arr[i], i);
24882
24896
  if (!cbModeMultiple) {
24883
24897
  keyArr[i] = key;
24884
24898
  }
24885
- if (!map3) {
24899
+ if (!map4) {
24886
24900
  continue;
24887
24901
  }
24888
- const idxMapVal = map3[key];
24902
+ const idxMapVal = map4[key];
24889
24903
  const idxMapValLen = dataIndexMapValueLength(idxMapVal);
24890
24904
  if (idxMapValLen === 0) {
24891
- map3[key] = i;
24905
+ map4[key] = i;
24892
24906
  if (cbModeMultiple) {
24893
24907
  keyArr.push(key);
24894
24908
  }
24895
24909
  } else if (idxMapValLen === 1) {
24896
- map3[key] = [idxMapVal, i];
24910
+ map4[key] = [idxMapVal, i];
24897
24911
  } else {
24898
24912
  idxMapVal.push(i);
24899
24913
  }
@@ -26004,15 +26018,15 @@ function getDimCount(source, sysDims, dimsDef, optDimCount) {
26004
26018
  });
26005
26019
  return dimCount;
26006
26020
  }
26007
- function genCoordDimName(name, map3, fromZero) {
26008
- if (fromZero || map3.hasKey(name)) {
26021
+ function genCoordDimName(name, map4, fromZero) {
26022
+ if (fromZero || map4.hasKey(name)) {
26009
26023
  let i = 0;
26010
- while (map3.hasKey(name + i)) {
26024
+ while (map4.hasKey(name + i)) {
26011
26025
  i++;
26012
26026
  }
26013
26027
  name += i;
26014
26028
  }
26015
- map3.set(name, true);
26029
+ map4.set(name, true);
26016
26030
  return name;
26017
26031
  }
26018
26032
 
@@ -26579,13 +26593,13 @@ var OrdinalMeta = class {
26579
26593
  this.categories[index] = category;
26580
26594
  return index;
26581
26595
  }
26582
- const map3 = this._getOrCreateMap();
26583
- index = map3.get(category);
26596
+ const map4 = this._getOrCreateMap();
26597
+ index = map4.get(category);
26584
26598
  if (index == null) {
26585
26599
  if (needCollect) {
26586
26600
  index = this.categories.length;
26587
26601
  this.categories[index] = category;
26588
- map3.set(category, index);
26602
+ map4.set(category, index);
26589
26603
  } else {
26590
26604
  index = NaN;
26591
26605
  }
@@ -31301,19 +31315,19 @@ function isDef(s) {
31301
31315
  return s !== void 0;
31302
31316
  }
31303
31317
  function createKeyToOldIdx(children, beginIdx, endIdx) {
31304
- const map3 = {};
31318
+ const map4 = {};
31305
31319
  for (let i = beginIdx; i <= endIdx; ++i) {
31306
31320
  const key = children[i].key;
31307
31321
  if (key !== void 0) {
31308
31322
  if (true) {
31309
- if (map3[key] != null) {
31323
+ if (map4[key] != null) {
31310
31324
  console.error(`Duplicate key ${key}`);
31311
31325
  }
31312
31326
  }
31313
- map3[key] = i;
31327
+ map4[key] = i;
31314
31328
  }
31315
31329
  }
31316
- return map3;
31330
+ return map4;
31317
31331
  }
31318
31332
  function sameVnode(vnode1, vnode2) {
31319
31333
  const isSameKey = vnode1.key === vnode2.key;
@@ -35627,7 +35641,6 @@ var isValidLayout = {
35627
35641
  var getLayout = {
35628
35642
  cartesian2d(data, dataIndex, itemModel) {
35629
35643
  const layout18 = data.getItemLayout(dataIndex);
35630
- console.log("%c [ layout ]-930", "font-size:13px; background:pink; color:#bf2c9f;", layout18);
35631
35644
  const fixedLineWidth = itemModel ? getLineWidth(itemModel, layout18) : 0;
35632
35645
  const signX = layout18.width > 0 ? 1 : -1;
35633
35646
  const signY = layout18.height > 0 ? 1 : -1;
@@ -42125,15 +42138,15 @@ var GEO_DEFAULT_PARAMS = {
42125
42138
  };
42126
42139
  var geo2DDimensions = ["lng", "lat"];
42127
42140
  var Geo = class extends View_default {
42128
- constructor(name, map3, opt) {
42141
+ constructor(name, map4, opt) {
42129
42142
  super(name);
42130
42143
  this.dimensions = geo2DDimensions;
42131
42144
  this.type = "geo";
42132
42145
  this._nameCoordMap = createHashMap();
42133
- this.map = map3;
42146
+ this.map = map4;
42134
42147
  let projection = opt.projection;
42135
- const source = geoSourceManager_default.load(map3, opt.nameMap, opt.nameProperty);
42136
- const resource = geoSourceManager_default.getGeoResource(map3);
42148
+ const source = geoSourceManager_default.load(map4, opt.nameMap, opt.nameProperty);
42149
+ const resource = geoSourceManager_default.getGeoResource(map4);
42137
42150
  const resourceType = this.resourceType = resource ? resource.type : null;
42138
42151
  const regions = this.regions = source.regions;
42139
42152
  const defaultParams = GEO_DEFAULT_PARAMS[resource.type];
@@ -42142,7 +42155,7 @@ var Geo = class extends View_default {
42142
42155
  if (projection) {
42143
42156
  if (resourceType === "geoSVG") {
42144
42157
  if (true) {
42145
- warn(`Map ${map3} with SVG source can't use projection. Only GeoJSON source supports projection.`);
42158
+ warn(`Map ${map4} with SVG source can't use projection. Only GeoJSON source supports projection.`);
42146
42159
  }
42147
42160
  projection = null;
42148
42161
  }
@@ -50421,9 +50434,9 @@ function getTransform2(controller) {
50421
50434
  return getTransform(controller.group);
50422
50435
  }
50423
50436
  function getGlobalDirection1(controller, localDirName) {
50424
- const map3 = {w: "left", e: "right", n: "top", s: "bottom"};
50437
+ const map4 = {w: "left", e: "right", n: "top", s: "bottom"};
50425
50438
  const inverseMap = {left: "w", right: "e", top: "n", bottom: "s"};
50426
- const dir3 = transformDirection(map3[localDirName], getTransform2(controller));
50439
+ const dir3 = transformDirection(map4[localDirName], getTransform2(controller));
50427
50440
  return inverseMap[dir3];
50428
50441
  }
50429
50442
  function getGlobalDirection2(controller, localDirNameSeq) {
@@ -53991,7 +54004,7 @@ var BarPlotPath = class extends Path_default {
53991
54004
  continue;
53992
54005
  }
53993
54006
  const [x, y] = point;
53994
- ctx.rect(x - offset, Math.min(y, baseY), width, Math.abs(y - baseY));
54007
+ ctx.rect(x - offset - 0.5, Math.min(y, baseY), width, Math.abs(y - baseY));
53995
54008
  }
53996
54009
  }
53997
54010
  };
@@ -54155,7 +54168,6 @@ var LinesPlotView2 = class extends Chart_default {
54155
54168
  const histbase = seriesModel.get("histbase") || 0;
54156
54169
  const barSpace = seriesModel.coordinateSystem.getAxesByScale("ordinal")[0].scale.barSpace;
54157
54170
  const width = Math.floor(barSpace * 0.8);
54158
- console.log("%c [ width ]-273", "font-size:13px; background:pink; color:#bf2c9f;", width);
54159
54171
  const baseY = seriesModel.coordinateSystem.dataToPoint([0, histbase])[1];
54160
54172
  if (width <= 1) {
54161
54173
  each(linePointsByKey, function(item, key) {
@@ -54182,8 +54194,7 @@ var LinesPlotView2 = class extends Chart_default {
54182
54194
  width
54183
54195
  },
54184
54196
  style: {
54185
- fill: stroke,
54186
- stroke
54197
+ fill: stroke
54187
54198
  }
54188
54199
  });
54189
54200
  barGroup.add(el);
@@ -54420,6 +54431,136 @@ function install24(registers) {
54420
54431
  registers.registerLayout(linesPlotLayout_default);
54421
54432
  }
54422
54433
 
54434
+ // src/chart/hlines/HLinesSeries.ts
54435
+ var HLineSeriesModel2 = class extends Series_default {
54436
+ constructor() {
54437
+ super(...arguments);
54438
+ this.type = HLineSeriesModel2.type;
54439
+ }
54440
+ getInitialData(option) {
54441
+ if (true) {
54442
+ const coordSys = option.coordinateSystem;
54443
+ if (coordSys !== "cartesian2d") {
54444
+ throw new Error("Line not support coordinateSystem besides cartesian");
54445
+ }
54446
+ }
54447
+ return createSeriesData_default(null, this, {
54448
+ useEncodeDefaulter: true
54449
+ });
54450
+ }
54451
+ };
54452
+ var HLineSeriesModel = HLineSeriesModel2;
54453
+ HLineSeriesModel.type = "series.hlines";
54454
+ HLineSeriesModel.dependencies = ["grid"];
54455
+ HLineSeriesModel.defaultOption = {
54456
+ z: 3,
54457
+ coordinateSystem: "cartesian2d",
54458
+ legendHoverLink: true,
54459
+ clip: true,
54460
+ lineStyle: {
54461
+ width: 2,
54462
+ type: "solid"
54463
+ },
54464
+ emphasis: {
54465
+ scale: true
54466
+ },
54467
+ animationEasing: "linear",
54468
+ progressive: 0,
54469
+ hoverLayerThreshold: Infinity,
54470
+ universalTransition: {
54471
+ divideShape: "clone"
54472
+ },
54473
+ triggerLineEvent: false
54474
+ };
54475
+ var HLinesSeries_default = HLineSeriesModel;
54476
+
54477
+ // src/chart/hlines/HLinesView.ts
54478
+ var HLinesView2 = class extends Chart_default {
54479
+ constructor() {
54480
+ super(...arguments);
54481
+ this.type = HLinesView2.type;
54482
+ }
54483
+ init(ecModel, api2) {
54484
+ this._lineDraw = new LineDraw_default(Line_default2);
54485
+ this.group.add(this._lineDraw.group);
54486
+ }
54487
+ render(seriesModel, ecModel, api2) {
54488
+ const data = seriesModel.getData();
54489
+ const lineDraw = this._lineDraw;
54490
+ lineDraw.updateData(data);
54491
+ const clipPath = seriesModel.get("clip", true) && createClipPath(seriesModel.coordinateSystem, false, seriesModel);
54492
+ if (clipPath) {
54493
+ this.group.setClipPath(clipPath);
54494
+ } else {
54495
+ this.group.removeClipPath();
54496
+ }
54497
+ this._finished = true;
54498
+ }
54499
+ eachRendered(cb) {
54500
+ this._lineDraw && this._lineDraw.eachRendered(cb);
54501
+ }
54502
+ remove(ecModel, api2) {
54503
+ this._lineDraw && this._lineDraw.remove();
54504
+ this._lineDraw = null;
54505
+ }
54506
+ dispose(ecModel, api2) {
54507
+ this.remove(ecModel, api2);
54508
+ }
54509
+ };
54510
+ var HLinesView = HLinesView2;
54511
+ HLinesView.type = "hlines";
54512
+ var HLinesView_default = HLinesView;
54513
+
54514
+ // src/chart/hlines/hLinesLayout.ts
54515
+ function getHLinePoints(seriesModel, value) {
54516
+ const coordSys = seriesModel.coordinateSystem;
54517
+ const xAxis = coordSys.getAxis("x");
54518
+ const y = coordSys.dataToPoint([0, value])[1];
54519
+ const [startX, endX] = xAxis.getExtent();
54520
+ return [
54521
+ [xAxis.toGlobalCoord(startX), y],
54522
+ [xAxis.toGlobalCoord(endX), y]
54523
+ ];
54524
+ }
54525
+ var hLinesLayout = {
54526
+ seriesType: "hlines",
54527
+ plan: createRenderPlanner(),
54528
+ reset: function(seriesModel) {
54529
+ const coordSys = seriesModel.coordinateSystem;
54530
+ if (!coordSys) {
54531
+ if (true) {
54532
+ error("The lines series must have a coordinate system.");
54533
+ }
54534
+ return;
54535
+ }
54536
+ return {
54537
+ progress(params, lineData) {
54538
+ const data = seriesModel.get("data");
54539
+ each(data, function(item, index) {
54540
+ if (item.invisible) {
54541
+ return;
54542
+ }
54543
+ const points4 = getHLinePoints(seriesModel, item.value);
54544
+ lineData.setItemLayout(index, points4);
54545
+ const lineStyle = lineData.getItemModel(index).getModel("lineStyle").getLineStyle();
54546
+ lineData.setItemVisual(index, {
54547
+ style: lineStyle
54548
+ });
54549
+ });
54550
+ }
54551
+ };
54552
+ }
54553
+ };
54554
+ var hLinesLayout_default = hLinesLayout;
54555
+
54556
+ // src/chart/hlines/install.ts
54557
+ function install25(registers) {
54558
+ registers.registerChartView(HLinesView_default);
54559
+ registers.registerSeriesModel(HLinesSeries_default);
54560
+ registers.registerLayout(hLinesLayout_default);
54561
+ console.log("chart install");
54562
+ }
54563
+
54423
54564
  // src/chart/heatmap/HeatmapLayer.ts
54424
54565
  var GRADIENT_LEVELS = 256;
54425
54566
  var HeatmapLayer = class {
@@ -54812,7 +54953,7 @@ HeatmapSeriesModel.defaultOption = {
54812
54953
  var HeatmapSeries_default = HeatmapSeriesModel;
54813
54954
 
54814
54955
  // src/chart/heatmap/install.ts
54815
- function install25(registers) {
54956
+ function install26(registers) {
54816
54957
  registers.registerChartView(HeatmapView_default);
54817
54958
  registers.registerSeriesModel(HeatmapSeries_default);
54818
54959
  }
@@ -55375,7 +55516,7 @@ PictorialBarSeriesModel.defaultOption = inheritDefaultOption(BaseBarSeries_defau
55375
55516
  var PictorialBarSeries_default = PictorialBarSeriesModel;
55376
55517
 
55377
55518
  // src/chart/bar/installPictorialBar.ts
55378
- function install26(registers) {
55519
+ function install27(registers) {
55379
55520
  registers.registerChartView(PictorialBarView_default);
55380
55521
  registers.registerSeriesModel(PictorialBarSeries_default);
55381
55522
  registers.registerLayout(registers.PRIORITY.VISUAL.LAYOUT, curry(layout2, "pictorialBar"));
@@ -55776,7 +55917,7 @@ function computeBaseline(data) {
55776
55917
  }
55777
55918
 
55778
55919
  // src/chart/themeRiver/install.ts
55779
- function install27(registers) {
55920
+ function install28(registers) {
55780
55921
  registers.registerChartView(ThemeRiverView_default);
55781
55922
  registers.registerSeriesModel(ThemeRiverSeries_default);
55782
55923
  registers.registerLayout(themeRiverLayout);
@@ -56414,7 +56555,7 @@ function sunburstVisual(ecModel) {
56414
56555
  }
56415
56556
 
56416
56557
  // src/chart/sunburst/install.ts
56417
- function install28(registers) {
56558
+ function install29(registers) {
56418
56559
  registers.registerChartView(SunburstView_default);
56419
56560
  registers.registerSeriesModel(SunburstSeries_default);
56420
56561
  registers.registerLayout(curry(sunburstLayout, "sunburst"));
@@ -57862,7 +58003,7 @@ function hasOwnPathData(shape) {
57862
58003
  }
57863
58004
 
57864
58005
  // src/chart/custom/install.ts
57865
- function install29(registers) {
58006
+ function install30(registers) {
57866
58007
  registers.registerChartView(CustomView_default);
57867
58008
  registers.registerSeriesModel(CustomSeries_default);
57868
58009
  }
@@ -59080,7 +59221,7 @@ function illegalPoint(point) {
59080
59221
  }
59081
59222
 
59082
59223
  // src/component/axisPointer/install.ts
59083
- function install30(registers) {
59224
+ function install31(registers) {
59084
59225
  AxisView_default.registerAxisPointerClass("CartesianAxisPointer", CartesianAxisPointer_default);
59085
59226
  registers.registerComponentModel(AxisPointerModel_default);
59086
59227
  registers.registerComponentView(AxisPointerView_default);
@@ -59109,9 +59250,9 @@ function install30(registers) {
59109
59250
  }
59110
59251
 
59111
59252
  // src/component/grid/install.ts
59112
- function install31(registers) {
59253
+ function install32(registers) {
59113
59254
  use(install6);
59114
- use(install30);
59255
+ use(install31);
59115
59256
  }
59116
59257
 
59117
59258
  // src/component/axisPointer/PolarAxisPointer.ts
@@ -60165,8 +60306,8 @@ var PolarView2 = class extends Component_default2 {
60165
60306
  };
60166
60307
  var PolarView = PolarView2;
60167
60308
  PolarView.type = "polar";
60168
- function install32(registers) {
60169
- use(install30);
60309
+ function install33(registers) {
60310
+ use(install31);
60170
60311
  AxisView_default.registerAxisPointerClass("PolarAxisPointer", PolarAxisPointer_default);
60171
60312
  registers.registerCoordinateSystem("polar", polarCreator_default);
60172
60313
  registers.registerComponentModel(PolarModel_default);
@@ -60629,8 +60770,8 @@ var SingleView2 = class extends Component_default2 {
60629
60770
  };
60630
60771
  var SingleView = SingleView2;
60631
60772
  SingleView.type = "single";
60632
- function install33(registers) {
60633
- use(install30);
60773
+ function install34(registers) {
60774
+ use(install31);
60634
60775
  AxisView_default.registerAxisPointerClass("SingleAxisPointer", SingleAxisPointer_default);
60635
60776
  registers.registerComponentView(SingleView);
60636
60777
  registers.registerComponentView(SingleAxisView_default);
@@ -61320,7 +61461,7 @@ function getCoordSys5(finder) {
61320
61461
  var Calendar_default = Calendar;
61321
61462
 
61322
61463
  // src/component/calendar/install.ts
61323
- function install34(registers) {
61464
+ function install35(registers) {
61324
61465
  registers.registerComponentModel(CalendarModel_default);
61325
61466
  registers.registerComponentView(CalendarView_default);
61326
61467
  registers.registerCoordinateSystem("calendar", Calendar_default);
@@ -61709,7 +61850,7 @@ function setEventData(el, graphicModel, elOption) {
61709
61850
  }
61710
61851
 
61711
61852
  // src/component/graphic/install.ts
61712
- function install35(registers) {
61853
+ function install36(registers) {
61713
61854
  registers.registerComponentModel(GraphicComponentModel);
61714
61855
  registers.registerComponentView(GraphicComponentView);
61715
61856
  registers.registerPreprocessor(function(option) {
@@ -62332,7 +62473,7 @@ var AxisProxy = class {
62332
62473
  each9(seriesModels, function(seriesModel) {
62333
62474
  let seriesData = seriesModel.getData();
62334
62475
  const dataDims = seriesData.mapDimensionsAll(axisDim);
62335
- if (!dataDims.length) {
62476
+ if (!dataDims.length || seriesModel.get("notFilterData")) {
62336
62477
  return;
62337
62478
  }
62338
62479
  const filterDataDims = seriesModel.getFilterDataDims?.();
@@ -62358,6 +62499,7 @@ var AxisProxy = class {
62358
62499
  return hasValue && leftOut && rightOut;
62359
62500
  });
62360
62501
  } else {
62502
+ const offset = seriesModel.get("offset");
62361
62503
  each9(dataDims, function(dim) {
62362
62504
  if (filterMode === "empty") {
62363
62505
  seriesModel.setData(seriesData = seriesData.map(dim, function(value) {
@@ -62373,6 +62515,9 @@ var AxisProxy = class {
62373
62515
  }
62374
62516
  return;
62375
62517
  }
62518
+ if (dim === "x" && offset) {
62519
+ range[dim][0] = range[dim][0] - offset;
62520
+ }
62376
62521
  seriesData.selectRange(range);
62377
62522
  }
62378
62523
  });
@@ -62559,7 +62704,7 @@ function installCommon(registers) {
62559
62704
  }
62560
62705
 
62561
62706
  // src/component/dataZoom/installDataZoomSelect.ts
62562
- function install36(registers) {
62707
+ function install37(registers) {
62563
62708
  registers.registerComponentModel(SelectZoomModel_default);
62564
62709
  registers.registerComponentView(SelectZoomView_default);
62565
62710
  installCommon(registers);
@@ -63959,7 +64104,7 @@ registerInternalOptionCreator("dataZoom", function(ecModel) {
63959
64104
  var DataZoom_default = DataZoomFeature;
63960
64105
 
63961
64106
  // src/component/toolbox/install.ts
63962
- function install37(registers) {
64107
+ function install38(registers) {
63963
64108
  registers.registerComponentModel(ToolboxModel_default);
63964
64109
  registers.registerComponentView(ToolboxView_default);
63965
64110
  registerFeature("saveAsImage", SaveAsImage_default);
@@ -63967,7 +64112,7 @@ function install37(registers) {
63967
64112
  registerFeature("dataView", DataView_default);
63968
64113
  registerFeature("dataZoom", DataZoom_default);
63969
64114
  registerFeature("restore", Restore_default);
63970
- use(install36);
64115
+ use(install37);
63971
64116
  }
63972
64117
 
63973
64118
  // src/component/tooltip/TooltipModel.ts
@@ -65135,8 +65280,8 @@ function findComponentReference(payload, ecModel, api2) {
65135
65280
  var TooltipView_default = TooltipView;
65136
65281
 
65137
65282
  // src/component/tooltip/install.ts
65138
- function install38(registers) {
65139
- use(install30);
65283
+ function install39(registers) {
65284
+ use(install31);
65140
65285
  registers.registerComponentModel(TooltipModel_default);
65141
65286
  registers.registerComponentView(TooltipView_default);
65142
65287
  registers.registerAction({
@@ -65183,12 +65328,12 @@ function brushPreprocessor(option, isNew) {
65183
65328
  }
65184
65329
  }
65185
65330
  function removeDuplicate(arr) {
65186
- const map3 = {};
65331
+ const map4 = {};
65187
65332
  each(arr, function(val) {
65188
- map3[val] = 1;
65333
+ map4[val] = 1;
65189
65334
  });
65190
65335
  arr.length = 0;
65191
- each(map3, function(flag, val) {
65336
+ each(map4, function(flag, val) {
65192
65337
  arr.push(val);
65193
65338
  });
65194
65339
  }
@@ -65752,7 +65897,7 @@ var BrushFeature = class extends ToolboxFeature {
65752
65897
  var Brush_default = BrushFeature;
65753
65898
 
65754
65899
  // src/component/brush/install.ts
65755
- function install39(registers) {
65900
+ function install40(registers) {
65756
65901
  registers.registerComponentView(BrushView_default);
65757
65902
  registers.registerComponentModel(BrushModel_default);
65758
65903
  registers.registerPreprocessor(brushPreprocessor);
@@ -65899,7 +66044,7 @@ var TitleView2 = class extends Component_default2 {
65899
66044
  };
65900
66045
  var TitleView = TitleView2;
65901
66046
  TitleView.type = "title";
65902
- function install40(registers) {
66047
+ function install41(registers) {
65903
66048
  registers.registerComponentModel(TitleModel);
65904
66049
  registers.registerComponentView(TitleView);
65905
66050
  }
@@ -66753,7 +66898,7 @@ function has(obj, attr) {
66753
66898
  }
66754
66899
 
66755
66900
  // src/component/timeline/install.ts
66756
- function install41(registers) {
66901
+ function install42(registers) {
66757
66902
  registers.registerComponentModel(SliderTimelineModel_default);
66758
66903
  registers.registerComponentView(SliderTimelineView_default);
66759
66904
  registers.registerSubTypeDefaulter("timeline", function() {
@@ -67194,7 +67339,7 @@ function createData(coordSys, seriesModel, mpModel) {
67194
67339
  var MarkPointView_default = MarkPointView;
67195
67340
 
67196
67341
  // src/component/marker/installMarkPoint.ts
67197
- function install42(registers) {
67342
+ function install43(registers) {
67198
67343
  registers.registerComponentModel(MarkPointModel_default);
67199
67344
  registers.registerComponentView(MarkPointView_default);
67200
67345
  registers.registerPreprocessor(function(opt) {
@@ -67512,7 +67657,7 @@ function createList2(coordSys, seriesModel, mlModel) {
67512
67657
  var MarkLineView_default = MarkLineView;
67513
67658
 
67514
67659
  // src/component/marker/installMarkLine.ts
67515
- function install43(registers) {
67660
+ function install44(registers) {
67516
67661
  registers.registerComponentModel(MarkLineModel_default);
67517
67662
  registers.registerComponentView(MarkLineView_default);
67518
67663
  registers.registerPreprocessor(function(opt) {
@@ -67826,7 +67971,7 @@ function createList3(coordSys, seriesModel, maModel) {
67826
67971
  var MarkAreaView_default = MarkAreaView;
67827
67972
 
67828
67973
  // src/component/marker/installMarkArea.ts
67829
- function install44(registers) {
67974
+ function install45(registers) {
67830
67975
  registers.registerComponentModel(MarkAreaModel_default);
67831
67976
  registers.registerComponentView(MarkAreaView_default);
67832
67977
  registers.registerPreprocessor(function(opt) {
@@ -68031,6 +68176,7 @@ var MarkLabelView2 = class extends Component_default2 {
68031
68176
  const gridRect = coordSys.master.getRect();
68032
68177
  const yAxisModel = coordSys.getAxis("y");
68033
68178
  const offset = yAxisModel.model.get("offset") || 0;
68179
+ const formatter = seriesModel.get("formatter") || yAxisModel.model.get(["axisLabel", "formatter"]);
68034
68180
  const x = yAxisModel.position === "right" ? gridRect.x + gridRect.width + offset : gridRect.x - offset;
68035
68181
  updatedSeriesByName[seriesName] = 1;
68036
68182
  each(markLabelData, (item) => {
@@ -68053,7 +68199,7 @@ var MarkLabelView2 = class extends Component_default2 {
68053
68199
  return;
68054
68200
  }
68055
68201
  const baseValue = coordSys.getBaseValue();
68056
- item.text = ["last", "allLast"].includes(item.type) ? yAxisModel.scale.getLabel({value}, {precision: item.precision, baseValue}) : value.toFixed(item.precision);
68202
+ item.text = ["last", "allLast"].includes(item.type) && yAxisModel.scale.type === "percentage" ? yAxisModel.scale.getLabel({value}, {precision: item.precision, baseValue}) : formatter ? formatter(value) : value.toFixed(item.precision);
68057
68203
  const y = coordSys.dataToPoint([0, value])[1];
68058
68204
  const fontSize = yAxisModel.getLabelModel().option.fontSize;
68059
68205
  if (el) {
@@ -68143,6 +68289,7 @@ var MarkLabelView2 = class extends Component_default2 {
68143
68289
  const yAxisModel = coordSys.getAxis("y");
68144
68290
  const position2 = yAxisModel.position;
68145
68291
  const offset = yAxisModel.model.get("offset") || 0;
68292
+ const formatter = yAxisModel.model.get(["axisLabel", "formatter"]);
68146
68293
  each(labels, (label) => {
68147
68294
  if (!label.children) {
68148
68295
  return;
@@ -68155,6 +68302,8 @@ var MarkLabelView2 = class extends Component_default2 {
68155
68302
  if (yAxisModel.scale.type === "percentage") {
68156
68303
  const formatLabel2 = yAxisModel.scale.getLabel({value: +option.style.text});
68157
68304
  option.style = Object.assign({}, option.style, {text: formatLabel2});
68305
+ } else if (formatter) {
68306
+ option.style = Object.assign({}, option.style, {text: formatter(+option.style.text)});
68158
68307
  }
68159
68308
  const fontSize = yAxisModel.getLabelModel().option.fontSize;
68160
68309
  if (el) {
@@ -68184,10 +68333,13 @@ var MarkLabelView2 = class extends Component_default2 {
68184
68333
  const position2 = yAxisModel.position;
68185
68334
  const y = yAxisModel.toGlobalCoord(yAxisModel.dataToCoord(inner21(el).originalValue));
68186
68335
  const offset = yAxisModel.model.get("offset") || 0;
68336
+ const formatter = yAxisModel.model.get(["axisLabel", "formatter"]);
68187
68337
  let style = inner21(el).style;
68188
68338
  if (yAxisModel.scale.type === "percentage") {
68189
68339
  const formatLabel2 = yAxisModel.scale.getLabel({value: +style.text});
68190
68340
  style = Object.assign({}, style, {text: formatLabel2});
68341
+ } else if (formatter) {
68342
+ style = Object.assign({}, style, {text: formatter(+style.text)});
68191
68343
  }
68192
68344
  updateText({el, gridRect, position: position2, option: {style}, ecModel, y, offset});
68193
68345
  });
@@ -68415,7 +68567,7 @@ function updateLabel({x, y, labelData, markerModel, gridRect, position: position
68415
68567
  var MarkLabelView_default = MarkLabelView;
68416
68568
 
68417
68569
  // src/component/marker/installMarkLabel.ts
68418
- function install45(registers) {
68570
+ function install46(registers) {
68419
68571
  registers.registerComponentModel(MarkLabelModal_default);
68420
68572
  registers.registerComponentView(MarkLabelView_default);
68421
68573
  registers.registerPreprocessor(function(opt) {
@@ -69097,7 +69249,7 @@ function installLegendAction(registers) {
69097
69249
  }
69098
69250
 
69099
69251
  // src/component/legend/installLegendPlain.ts
69100
- function install46(registers) {
69252
+ function install47(registers) {
69101
69253
  registers.registerComponentModel(LegendModel_default);
69102
69254
  registers.registerComponentView(LegendView_default);
69103
69255
  registers.registerProcessor(registers.PRIORITY.PROCESSOR.SERIES_FILTER, legendFilter);
@@ -69427,17 +69579,17 @@ function installScrollableLegendAction(registers) {
69427
69579
  }
69428
69580
 
69429
69581
  // src/component/legend/installLegendScroll.ts
69430
- function install47(registers) {
69431
- use(install46);
69582
+ function install48(registers) {
69583
+ use(install47);
69432
69584
  registers.registerComponentModel(ScrollableLegendModel_default);
69433
69585
  registers.registerComponentView(ScrollableLegendView_default);
69434
69586
  installScrollableLegendAction(registers);
69435
69587
  }
69436
69588
 
69437
69589
  // src/component/legend/install.ts
69438
- function install48(registers) {
69439
- use(install46);
69590
+ function install49(registers) {
69440
69591
  use(install47);
69592
+ use(install48);
69441
69593
  }
69442
69594
 
69443
69595
  // src/component/dataZoom/InsideZoomModel.ts
@@ -69853,7 +70005,7 @@ var getDirectionInfo = {
69853
70005
  var InsideZoomView_default = InsideZoomView;
69854
70006
 
69855
70007
  // src/component/dataZoom/installDataZoomInside.ts
69856
- function install49(registers) {
70008
+ function install50(registers) {
69857
70009
  installCommon(registers);
69858
70010
  registers.registerComponentModel(InsideZoomModel_default);
69859
70011
  registers.registerComponentView(InsideZoomView_default);
@@ -70600,8 +70752,8 @@ var SliderZoomView2 = class extends DataZoomView_default {
70600
70752
  var SliderZoomView = SliderZoomView2;
70601
70753
  SliderZoomView.type = "dataZoom.slider";
70602
70754
  function getOtherDim(thisDim) {
70603
- const map3 = {x: "y", y: "x", radius: "angle", angle: "radius"};
70604
- return map3[thisDim];
70755
+ const map4 = {x: "y", y: "x", radius: "angle", angle: "radius"};
70756
+ return map4[thisDim];
70605
70757
  }
70606
70758
  function getCursor(orient) {
70607
70759
  return orient === "vertical" ? "ns-resize" : "ew-resize";
@@ -70609,16 +70761,17 @@ function getCursor(orient) {
70609
70761
  var SliderZoomView_default = SliderZoomView;
70610
70762
 
70611
70763
  // src/component/dataZoom/installDataZoomSlider.ts
70612
- function install50(registers) {
70764
+ function install51(registers) {
70613
70765
  registers.registerComponentModel(SliderZoomModel_default);
70614
70766
  registers.registerComponentView(SliderZoomView_default);
70615
70767
  installCommon(registers);
70616
70768
  }
70617
70769
 
70618
70770
  // src/component/dataZoom/install.ts
70619
- function install51(registers) {
70620
- use(install49);
70771
+ function install52(registers) {
70621
70772
  use(install50);
70773
+ use(install51);
70774
+ console.log("component install");
70622
70775
  }
70623
70776
 
70624
70777
  // src/visual/visualDefault.ts
@@ -71883,7 +72036,7 @@ function installCommon2(registers) {
71883
72036
  }
71884
72037
 
71885
72038
  // src/component/visualMap/installVisualMapContinuous.ts
71886
- function install52(registers) {
72039
+ function install53(registers) {
71887
72040
  registers.registerComponentModel(ContinuousModel_default);
71888
72041
  registers.registerComponentView(ContinuousView_default);
71889
72042
  installCommon2(registers);
@@ -72323,16 +72476,16 @@ PiecewiseVisualMapView.type = "visualMap.piecewise";
72323
72476
  var PiecewiseView_default = PiecewiseVisualMapView;
72324
72477
 
72325
72478
  // src/component/visualMap/installVisualMapPiecewise.ts
72326
- function install53(registers) {
72479
+ function install54(registers) {
72327
72480
  registers.registerComponentModel(PiecewiseModel_default);
72328
72481
  registers.registerComponentView(PiecewiseView_default);
72329
72482
  installCommon2(registers);
72330
72483
  }
72331
72484
 
72332
72485
  // src/component/visualMap/install.ts
72333
- function install54(registers) {
72334
- use(install52);
72486
+ function install55(registers) {
72335
72487
  use(install53);
72488
+ use(install54);
72336
72489
  }
72337
72490
 
72338
72491
  // src/visual/aria.ts
@@ -72528,7 +72681,7 @@ function ariaPreprocessor(option) {
72528
72681
  }
72529
72682
 
72530
72683
  // src/component/aria/install.ts
72531
- function install55(registers) {
72684
+ function install56(registers) {
72532
72685
  registers.registerPreprocessor(ariaPreprocessor);
72533
72686
  registers.registerVisual(registers.PRIORITY.VISUAL.ARIA, ariaVisual);
72534
72687
  }
@@ -72866,7 +73019,7 @@ var sortTransform = {
72866
73019
  };
72867
73020
 
72868
73021
  // src/component/transform/install.ts
72869
- function install56(registers) {
73022
+ function install57(registers) {
72870
73023
  registers.registerTransform(filterTransform);
72871
73024
  registers.registerTransform(sortTransform);
72872
73025
  }
@@ -72904,7 +73057,7 @@ var DatasetView = class extends Component_default2 {
72904
73057
  }
72905
73058
  };
72906
73059
  DatasetView.type = "dataset";
72907
- function install57(registers) {
73060
+ function install58(registers) {
72908
73061
  registers.registerComponentModel(DatasetModel);
72909
73062
  registers.registerComponentView(DatasetView);
72910
73063
  }
@@ -74624,35 +74777,36 @@ use([
74624
74777
  install26,
74625
74778
  install27,
74626
74779
  install28,
74627
- install29
74780
+ install29,
74781
+ install30
74628
74782
  ]);
74629
- use(install31);
74630
74783
  use(install32);
74631
- use(install10);
74632
74784
  use(install33);
74633
- use(install17);
74785
+ use(install10);
74634
74786
  use(install34);
74787
+ use(install17);
74635
74788
  use(install35);
74636
- use(install37);
74789
+ use(install36);
74637
74790
  use(install38);
74638
- use(install30);
74639
74791
  use(install39);
74792
+ use(install31);
74640
74793
  use(install40);
74641
74794
  use(install41);
74642
74795
  use(install42);
74643
74796
  use(install43);
74644
74797
  use(install44);
74645
74798
  use(install45);
74646
- use(install48);
74647
- use(install51);
74799
+ use(install46);
74648
74800
  use(install49);
74649
- use(install50);
74650
- use(install54);
74651
74801
  use(install52);
74652
- use(install53);
74802
+ use(install50);
74803
+ use(install51);
74653
74804
  use(install55);
74805
+ use(install53);
74806
+ use(install54);
74654
74807
  use(install56);
74655
74808
  use(install57);
74809
+ use(install58);
74656
74810
  use(installUniversalTransition);
74657
74811
  use(installLabelLayout);
74658
74812