实现效果
//lenged中的formatter是修改图例样式,返回的函数
legend: [
{
data:weightKanban?.map((item) => {
return item.name
}),
icon: "circle",
itemWidth: 10, // 设置宽度
itemHeight: 10, // 设置高度
itemGap: 15,
left: 50,
bottom: 0,
algin:'center',
lineHeight:12,
padding:[0,0,0,40],
textStyle: {
rich: {
a: {
width: 85,
color: '#888888',
fontSize: 14,
lineHeight:22,
textAlign:'center'
}
},
},
formatter: [
'{a|{name}}'
].join('\n'),
//selectedMode: false,
},
],