我在 react使用echarts配置中国地图 当前选中项无法高亮
<ReactEcharts
option={{
title: false,
tooltip: {
trigger: 'item',
},
legend: false,
visualMap: {
min: 0,
max: maxData,
left: 'left',
top: 'bottom',
calculable: true,
inRange: {
color: ['#CCEDF8', '#99DCF1', '#33B9E2']
},
},
toolbox: {
show: false,
},
series: [
{
name: '',
type: 'map',
mapType: 'china',
roam: false,
zoom: 1.2, // 改变地图大小
showLengendSymbol: false, // 去掉地图上的指示点
label: {
normal: {
show: false,
color: '#fff',
},
emphasis: {
show: true,
color: '#fff',
areaColor: '#00A7DB',
},
},
itemStyle: {
borderWidth: 0,
},
emphasis: {
label: {
show: true,
color: '#fff',
},
itemStyle: {
show: true,
areaColor: '#00A7DB',
},
},
data: dataLst
}
]
}}
onEvents={onEvents}
style={{ height: '295px', width: '100%' }}
className="react_for_echarts"
/>
let onEvents = {
click: this.onChartClick,
}
我配置了地图高亮颜色但是点击的时候页面刷新选中省份没有高亮显示,