myChart.dispatchAction({
type: 'downplay', // 取消高亮
seriesIndex: 0
})
myChart.dispatchAction({
type: 'highlight', //高亮
seriesIndex: 0,
dataIndex: index, //数据index,要显示的区域
})
myChart.dispatchAction({
type: 'showTip', //显示提示框
seriesIndex: 0,
dataIndex: index
})
chart.dispatchAction({
type: 'unselect', // 取消高亮
// seriesIndex: 0,
dataIndex: index
})
echarts绘制地图使用dispatchAction方法高亮区域
于 2023-08-10 17:52:52 首次发布