v-charts bug All In One
v-charts bug All In One
one point data, no symbol bug
chartExtend () {
const type = this.options.settings.type;
return {
...UtilChart.chartExtend(type),
grid: {
bottom: 0,
},
legend: {
show: this.options.settings.type !== 'pie',
},
series (v) {
return v.map((i) => ({
...i,
barMaxWidth: 12,
symbol: 'none',
}));
},
};
},
solution
chartExtend () {
const type = this.options.settings.type;
return {
...UtilChart.chartExtend(type),
grid: {
bottom: 0,
},
legend: {
show: this.options.settings.type !== 'pie',
},
series (v) {
return v.map((i) => ({
...i,
barMaxWidth: 12,
// symbol: 'none',
// ?? 为什么要隐藏 symbol 呀!
}));
},
};
},
demo
echarts
https://echarts.apache.org/examples/zh/editor.html?c=line-stack
option = {
title: {
text: 'Stacked Line'
},
tooltip: {
trigger: 'axis'
},
legend: {
data: ['Email', 'Union Ads', 'Video Ads']
},
grid: {
left: '3%',
right: '4%',
bottom: '3%',
containLabel: true
},
toolbox: {
feature: {
saveAsImage: {}
}
},
xAxis: {
type: 'category',
boundaryGap: false,
data: ['Mon']
},
yAxis: {
type: 'value'
},
series: [
{
name: 'Email',
type: 'line',
stack: 'Total',
data: [1,]
},
{
name: 'Union Ads',
type: 'line',
stack: 'Total',
data: [220]
},
{
name: 'Video Ads',
type: 'line',
stack: 'Total',
data: ['']
},
]
};
refs
https://v-charts.xgqfrms.xyz/#/props-demo2
?xgqfrms 2012-2020
www.cnblogs.com/xgqfrms 发布文章使用:只允许注册用户才可以访问!
原创文章,版权所有??xgqfrms, 禁止转载 ???,侵权必究??!