扫码关注官方订阅号
RT。
已用echart实现柱状图,但是不需要鼠标hover时的提示与Y轴的数字。(Y轴横线还是要的)
认证0级讲师
测试地址
app.title = '坐标轴刻度与标签对齐'; option = { color: ['#3398DB'], tooltip : { show:false }, grid: { left: '3%', right: '4%', bottom: '3%', containLabel: true }, xAxis : [ { type : 'category', data : ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun'], axisTick: { alignWithLabel: true } } ], yAxis : [ { axisLabel: { show: false } } ], series : [ { name:'直接访问', type:'bar', barWidth: '60%', data:[10, 52, 200, 334, 390, 330, 220] } ] };
将上面的代码copy进去看效果吧。hover不显示是由tooltip.show来控制,不显示Y轴的值由yAxis..axisLabel.show控制。
copy
hover
tooltip.show
Y
yAxis..axisLabel.show
微信扫码关注PHP中文网服务号
QQ扫码加入技术交流群
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
PHP学习
技术支持
返回顶部
测试地址
将上面的代码
copy进去看效果吧。hover不显示是由tooltip.show来控制,不显示Y轴的值由yAxis..axisLabel.show控制。