在setOption()方法中的series配置中加上itemStyle配置
如下:
series: [{ name: '人數', type: 'bar', data: [], //x軸對應列的值 itemStyle: { //上方顯示數值 normal: { label: { show: true, //開啟顯示 position: 'top', //在上方顯示 textStyle: { //數值樣式 color: 'black', fontSize: 16 } } } } }]
在setOption()方法中的series配置中加上itemStyle配置
如下:
series: [{ name: '人數', type: 'bar', data: [], //x軸對應列的值 itemStyle: { //上方顯示數值 normal: { label: { show: true, //開啟顯示 position: 'top', //在上方顯示 textStyle: { //數值樣式 color: 'black', fontSize: 16 } } } } }]
本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。