老师的示例里就是填满的,我照搬的却右边长度不够
chart.setOption({
xAxis: {
type: 'value',
show: false
},
yAxis: {
type: 'category',
show: false
},
series: [{
type: 'bar',
stack: 'total',
data: [200],
barWidth: 10,
itemStyle: {
color: '#45c946'
}
}, {
type: 'bar',
stack: 'total',
data: [250],
itemStyle: {
color: '#eee'
}
}],
grid: {
top: 0,
right: 0,
bottom: 0,
left: 0
}
})
登录后可查看更多问答,登录/注册