echarts
echarts copied to clipboard
Y轴在特定情况下显示超长的刻度值
问题简述 (One-line summary)
Y轴在特定情况下显示超长的刻度值
版本及环境 (Version & Environment)
- ECharts 版本 (ECharts version):
- 浏览器类型和版本 (Browser version):
- 操作系统类型和版本 (OS Version):
重现步骤 (Steps to reproduce)
期望结果 (Expected behaviour)
可能哪里有问题 (What went wrong)
正常显示
ECharts配置项 (ECharts option)
app.title = '坐标轴刻度与标签对齐';
option = {
color: ['#3398DB'],
tooltip : {
trigger: 'axis',
axisPointer : { // 坐标轴指示器,坐标轴触发有效
type : 'shadow' // 默认为直线,可选为:'line' | 'shadow'
}
},
grid: {
left: '3%',
right: '4%',
bottom: '3%',
containLabel: true
},
xAxis : [
{
type : 'category',
data : ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'],
axisTick: {
alignWithLabel: true
}
}
],
yAxis : [
{
type : 'value',
boundaryGap : [0, 0.01]
}
],
series : [
{
name:'直接访问',
type:'bar',
barWidth: '60%',
data:[1.2,1.3,1.7]
}
]
};
其他信息 (Other comments)

可使用 http://echarts.baidu.com/option.html#yAxis.axisLabel.formatter