option = {
color: [
'#0487FF',
'#FAC858',
'#3DC545',
'#46a2ff',
'#f9655e',
'#44c5ff',
'#f97b32',
'#9a60b4',
'#ea7ccc'
],
dataZoom: [
{
id: 'dataZoomX',
type: 'slider',
xAxisIndex: 0,
filterMode: 'filter'
}
],
legend: {
data: ['语文'],
top: '0'
},
tooltip: {
trigger: 'axis',
formatter: '{b0}<br />',
axisPointer: {
animation: true,
type: 'line',
lineStyle: {
type: 'dashed'
}
}
},
grid: {
left: 20,
top: 38,
right: 20,
bottom: 65
},
xAxis: {
type: 'category',
data: [
'第1周',
'第2周',
'第3周',
'第4周',
'第5周',
'第6周',
'第7周',
'第8周',
'第9周',
'第10周',
'第11周',
'第12周',
'第13周',
'第14周',
'第15周',
'第16周',
'第17周',
'第18周',
'第19周',
'第20周',
'第21周',
'第22周'
],
boundaryGap: false
},
yAxis: {
type: 'category',
boundaryGap: false,
name: '等级',
data: ['0', 'D', 'C', 'B', 'A'],
splitLine: {
show: true
}
},
series: [
{
labelLine: { show: true },
symbolSize: 16,
type: 'line',
smooth: true,
name: '语文',
data: [
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'-',
'D',
'-',
'-',
'-',
'-',
'-',
'-',
'-'
]
}
]
};
- OS:window 10
- Browser: Chrome 98.0.4758.81
- Framework: React
Version
5.2.0+
Link to Minimal Reproduction
No response
Steps to Reproduce
公司旧项目使用的是echart4的库,新项目升级echart后发现图标显示异常,设置dataZoom后错位了,在5.2.0以上版本显示异常
具体代码如下:
Current Behavior
缩放组件错位
Expected Behavior
缩放组件正常显示
Environment
Any additional comments?
No response