echarts: legend自定义icon

1.引入图片
import iconUrl from '../assets/gas_station.png';

2.在legend里面定义icon

legend: {
			data: ['审批完成', '待审批', '驳回'],
			icon: ('image://' + iconUrl + ''),
			itemWidth: 20,
			itemHeight: 20
					},
     
posted @ 2025-02-25 16:51  刘酸酸sour  阅读(215)  评论(0)    收藏  举报