tvcharts 0.5.76 → 0.5.78
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 +12 -10
- package/dist/echarts.js.map +2 -2
- package/lib/scale/Ordinal.js +1 -7
- package/lib/util/states.js +7 -5
- package/package.json +1 -1
- package/types/src/scale/Ordinal.d.ts +0 -1
- package/types/src/util/states.d.ts +6 -4
package/dist/echarts.js
CHANGED
|
@@ -11759,7 +11759,7 @@ function getAllSelectedIndices(ecModel) {
|
|
|
11759
11759
|
return ret;
|
|
11760
11760
|
}
|
|
11761
11761
|
function getSeriesPointData(ecModel, payload = {}) {
|
|
11762
|
-
const seriesPointData =
|
|
11762
|
+
const seriesPointData = {};
|
|
11763
11763
|
ecModel.eachSeries(function(seriesModel) {
|
|
11764
11764
|
const data = seriesModel.getData();
|
|
11765
11765
|
const index = payload.dataIndex ?? data.count() - 1;
|
|
@@ -11769,13 +11769,15 @@ function getSeriesPointData(ecModel, payload = {}) {
|
|
|
11769
11769
|
const currentValue = data.get(dim, index);
|
|
11770
11770
|
const prevValue = data.get(dim, index - 1);
|
|
11771
11771
|
const changePercent = ((currentValue - prevValue) / prevValue * 100).toFixed(2) + "%";
|
|
11772
|
-
|
|
11773
|
-
|
|
11772
|
+
const seriesId = seriesModel.id;
|
|
11773
|
+
const seriesName = seriesModel.name;
|
|
11774
|
+
seriesPointData[seriesName] = {
|
|
11775
|
+
name: seriesName,
|
|
11774
11776
|
data: values,
|
|
11775
11777
|
color: style.fill,
|
|
11776
|
-
seriesId
|
|
11778
|
+
seriesId,
|
|
11777
11779
|
changePercent
|
|
11778
|
-
}
|
|
11780
|
+
};
|
|
11779
11781
|
});
|
|
11780
11782
|
return seriesPointData;
|
|
11781
11783
|
}
|
|
@@ -23191,8 +23193,7 @@ var ECharts = class extends Eventful_default {
|
|
|
23191
23193
|
warn("There is no specified series model");
|
|
23192
23194
|
}
|
|
23193
23195
|
}
|
|
23194
|
-
const
|
|
23195
|
-
const dataIndex = parsedFinder.hasOwnProperty("dataIndex") ? data.indexOfRawIndex(parsedFinder.dataIndex) : 0;
|
|
23196
|
+
const dataIndex = parsedFinder.hasOwnProperty("dataIndex") ? parsedFinder.dataIndex : 0;
|
|
23196
23197
|
const axis = seriesModel.getBaseAxis();
|
|
23197
23198
|
return axis.scale.getLabel({value: dataIndex});
|
|
23198
23199
|
}
|
|
@@ -67068,9 +67069,9 @@ var MarkLabelView2 = class extends Component_default2 {
|
|
|
67068
67069
|
option.style = Object.assign({}, option.style, {text: formatLabel2});
|
|
67069
67070
|
}
|
|
67070
67071
|
if (el) {
|
|
67071
|
-
updateText({el, gridRect, position: position2, option, ecModel, y});
|
|
67072
|
+
updateText({el, gridRect, position: position2, option, ecModel, y, offset});
|
|
67072
67073
|
} else {
|
|
67073
|
-
el = createText({gridRect, position: position2, option, ecModel, y});
|
|
67074
|
+
el = createText({gridRect, position: position2, option, ecModel, y, offset});
|
|
67074
67075
|
graphLabelGroup.add(el);
|
|
67075
67076
|
graphicLabelElMap.set(option.id, el);
|
|
67076
67077
|
inner21(el).yAxisIndex = yAxisModel.index;
|
|
@@ -67093,12 +67094,13 @@ var MarkLabelView2 = class extends Component_default2 {
|
|
|
67093
67094
|
const gridRect = yAxisModel.grid.getRect();
|
|
67094
67095
|
const position2 = yAxisModel.position;
|
|
67095
67096
|
const y = yAxisModel.toGlobalCoord(yAxisModel.dataToCoord(inner21(el).originalValue)) - 9;
|
|
67097
|
+
const offset = yAxisModel.model.get("offset") || 0;
|
|
67096
67098
|
let style = inner21(el).style;
|
|
67097
67099
|
if (yAxisModel.scale.type === "percentage") {
|
|
67098
67100
|
const formatLabel2 = yAxisModel.scale.getLabel({value: +style.text});
|
|
67099
67101
|
style = Object.assign({}, style, {text: formatLabel2});
|
|
67100
67102
|
}
|
|
67101
|
-
updateText({el, gridRect, position: position2, option: {style}, ecModel, y});
|
|
67103
|
+
updateText({el, gridRect, position: position2, option: {style}, ecModel, y, offset});
|
|
67102
67104
|
});
|
|
67103
67105
|
}
|
|
67104
67106
|
removeGraphicLabels(labelOption) {
|