tvcharts 0.6.23 → 0.6.25

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/echarts.js CHANGED
@@ -17742,7 +17742,7 @@ var DefaultDataProvider2 = class {
17742
17742
  appendData(newData) {
17743
17743
  }
17744
17744
  updateData(newData) {
17745
- return {update: 0, append: 0};
17745
+ return {update: 0};
17746
17746
  }
17747
17747
  clean() {
17748
17748
  }
@@ -17864,25 +17864,18 @@ DefaultDataProvider.internalField = function() {
17864
17864
  function updateDataSimply(newData) {
17865
17865
  const data = this._data;
17866
17866
  let lastIndex = data.length - 1;
17867
+ let update = 0;
17867
17868
  for (let i = 0; i < newData.length; i++) {
17868
17869
  const ele = newData[i];
17869
- if (Array.isArray(ele)) {
17870
- if (ele[0] === data[lastIndex][0]) {
17871
- data[lastIndex] = ele;
17872
- lastIndex++;
17873
- continue;
17874
- }
17875
- } else if (typeof ele === "object" && Array.isArray(ele.value) && ele.value[0] == data[lastIndex][0]) {
17870
+ if (!update) {
17876
17871
  data[lastIndex] = ele;
17877
- lastIndex++;
17872
+ update++;
17878
17873
  continue;
17879
17874
  }
17880
- data.push(newData[i]);
17875
+ data.push(ele);
17881
17876
  }
17882
- const update = lastIndex - data.length - 1;
17883
17877
  return {
17884
- update,
17885
- append: newData.length - update
17878
+ update
17886
17879
  };
17887
17880
  }
17888
17881
  }();
@@ -20067,7 +20060,7 @@ var SeriesModel2 = class extends Component_default {
20067
20060
  }
20068
20061
  updateData(params) {
20069
20062
  const data = this.getRawData();
20070
- data.appendData(params.data);
20063
+ data.updateData(params.data);
20071
20064
  }
20072
20065
  getData(dataType) {
20073
20066
  const task = getCurrentTask(this);
@@ -24338,10 +24331,10 @@ var ECharts = class extends Eventful_default {
24338
24331
  const categories = [];
24339
24332
  const data = map(params.data, (item, index2) => {
24340
24333
  const idx = lastIndex + index2;
24341
- seriesModel.option.data[idx] = item;
24342
- if (idx > lastIndex) {
24334
+ if (index2 !== 0) {
24343
24335
  categories.push(item.value[0]);
24344
24336
  }
24337
+ item.value[0] = idx;
24345
24338
  return item;
24346
24339
  });
24347
24340
  if (params.isMainSeries && data.length > 1) {
@@ -24396,7 +24389,7 @@ var ECharts = class extends Eventful_default {
24396
24389
  barSpace: scale4.barSpace,
24397
24390
  lastBarRightSideDiffBarCount: scale4.lastBarRightSideDiffBarCount < 1.5 ? scale4.lastBarRightSideDiffBarCount - 1 : scale4.lastBarRightSideDiffBarCount
24398
24391
  };
24399
- doDispatchAction.call(this, payload, false);
24392
+ doDispatchAction.call(this, payload, true);
24400
24393
  }
24401
24394
  }
24402
24395
  };
@@ -25179,6 +25172,7 @@ ECharts.internalField = function() {
25179
25172
  updateConnectedChartsStatus(otherCharts, CONNECT_STATUS_PENDING);
25180
25173
  each(otherCharts, function(otherChart) {
25181
25174
  if (otherChart[CONNECT_STATUS_KEY] !== CONNECT_STATUS_UPDATING) {
25175
+ action.isConnect = true;
25182
25176
  otherChart.dispatchAction(action);
25183
25177
  }
25184
25178
  });
@@ -55178,7 +55172,6 @@ var linesPlotLayout = {
55178
55172
  }
55179
55173
  const dataModal = lineData.getItemModel(index);
55180
55174
  const symbolColor = dataModal.get("itemStyle")?.color;
55181
- console.log("%c [ dataModal ]-94", "font-size:13px; background:pink; color:#bf2c9f;", dataModal);
55182
55175
  const symbol = dataModal.get("symbol");
55183
55176
  const symbolKey = `${symbol}`;
55184
55177
  const symbolData = symbolPointsByColor[symbolKey] || [];
@@ -60743,6 +60736,9 @@ function axisTrigger(payload, ecModel, api2) {
60743
60736
  const coordSysContainsPoint = isIllegalPoint || coordSys.containPoint(point);
60744
60737
  each(coordSysAxesInfo.coordSysAxesInfo[coordSysKey], function(axisInfo, key) {
60745
60738
  const axis = axisInfo.axis;
60739
+ if (payload.isConnect && axis.dim === "y") {
60740
+ return;
60741
+ }
60746
60742
  const inputAxisInfo = findInputAxisInfo(inputAxesInfo, axisInfo);
60747
60743
  if (!shouldHide && coordSysContainsPoint && (!inputAxesInfo || inputAxisInfo)) {
60748
60744
  let val = inputAxisInfo && inputAxisInfo.value;
@@ -70144,6 +70140,10 @@ var markerTypeCalculator2 = {
70144
70140
  const openValue = seriesData.getByRawIndex("open", lastIndex);
70145
70141
  const sign = openValue > closeValue ? -1 : 1;
70146
70142
  fill = dataItem.get(sign > 0 ? positiveBorderColorQuery : negativeBorderColorQuery);
70143
+ } else if (["linesPlot", "labels"].includes(seriesModel.subType)) {
70144
+ const isLinesPlot = seriesModel.subType === "linesPlot";
70145
+ const dataItem = seriesData.getItemModel(lastIndex, true);
70146
+ fill = dataItem.get([isLinesPlot ? "lineStyle" : "itemStyle", "color"]);
70147
70147
  }
70148
70148
  return {
70149
70149
  value: seriesData.getByRawIndex(item.valueDim, lastIndex),
@@ -70164,7 +70164,12 @@ var markerTypeCalculator2 = {
70164
70164
  }
70165
70165
  const backgroundColor2 = seriesModel.ecModel.get("backgroundColor");
70166
70166
  const lastItem = seriesData.count() - 1;
70167
- const fill = seriesModel.subType === "candlestick" ? seriesData.getItemVisual(lastItem, "style")?.stroke : seriesData.getItemVisual(lastItem, "style")?.fill;
70167
+ let fill = seriesModel.subType === "candlestick" ? seriesData.getItemVisual(lastItem, "style")?.stroke : seriesData.getItemVisual(lastItem, "style")?.fill;
70168
+ if (["linesPlot", "labels"].includes(seriesModel.subType)) {
70169
+ const isLinesPlot = seriesModel.subType === "linesPlot";
70170
+ const dataItem = seriesData.getItemModel(lastItem);
70171
+ fill = dataItem.get([isLinesPlot ? "lineStyle" : "itemStyle", "color"]);
70172
+ }
70168
70173
  return {
70169
70174
  value: seriesData.getByRawIndex(item.valueDim, lastIndex),
70170
70175
  labelTextStyle: {
@@ -70296,7 +70301,7 @@ var MarkLabelView2 = class extends Component_default2 {
70296
70301
  }
70297
70302
  const markLabelData = labelMap.get(seriesName);
70298
70303
  each(markLabelData, (item) => {
70299
- let el = markerGroupMap.get(item.name);
70304
+ const el = markerGroupMap.get(item.name);
70300
70305
  delete markLabelData[item.name];
70301
70306
  if (!el) {
70302
70307
  return;