legend: {
top: 5,
right: 0,
itemWidth: 18,
itemHeight: 12,
icon: 'rect',
textStyle: {
color: '#fff'
}
},
grid: { left: 0, top: 50, bottom: 20, right: 0, containLabel: true },
yAxis: [
{
type: 'value',
axisLine: { show: true, lineStyle: { color: 'D0FFF6' } },
axisLabel: {
show: true,
color: '#D0FFF6',
interval: 'auto',
formatter: '({value})'
},
splitLine: { lineStyle: { color: 'rgba(0,0,0,0)' } }
},
{
min: 0,
max: 100,
position: 'left',
offset: 40,
type: 'value',
boundaryGap: [0, 0.01],
axisLabel: {
show: true,
color: '#D0FFF6',
interval: 'auto',
formatter: '{value}%'
},
splitLine: {
lineStyle: {
type: 'dashed', // 横线类型
color: 'rgba(208, 255, 246, 0.7)'
}
},
axisLine: {
lineStyle: {
type: 'dashed',
color: 'rgba(208, 255, 246, 0.7)'
}
}
}
],
echarts y轴展示百分比和数值
最新推荐文章于 2024-05-05 03:28:17 发布