根據業務需求,特殊標記點設置特殊提示
在color:function()中進行判斷,同理如果顯示label自定義在formatter中進行
yAxis:{
{
type: 'value',
name: '溫度',
min: 0,
max: 25,
position: 'left',
axisLine: {
lineStyle: {
color: '#675bba'
}
},
axisLabel: {
formatter: '{value} °C',
color:function(v){
if(v==20){
return '#e61717'
}else{
return '#675bba'
}
}
}
}
}