We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
使用了green主题,发现了一个bug:鼠标从图表的最左端hover进来时,在x轴的第一个grid,tooltip的function拿到的参数值中的data为undefined。经过追踪,发现green主题设置了grid的border为0,在执行
subPixelOptimize: function(position, lineWidth) { if (lineWidth % 2 == 1) { //position += position == Math.ceil(position) ? 0.5 : 0; position = Math.floor(position) + 0.5; } else { position = Math.round(position); } return position; }
后postion不变,导致_getNearestDataIndex函数中的:
var curCoord = categoryAxis.getCoordByIndex(dataIndex); while (curCoord < xEnd) { if (curCoord <= x) { left = curCoord; } if (curCoord >= x) { break; } curCoord = categoryAxis.getCoordByIndex(++dataIndex); right = curCoord; }
执行后dataIndex为-2,没有拿到具体的数据。
The text was updated successfully, but these errors were encountered:
什么例子?这还能跟主题有关系?
Sorry, something went wrong.
@kener
只是说这个主题中 gird 设置为0后触发了这个 bug: http://jsfiddle.net/6wtvc53g/
把主题的 gird border 改为1就没问题了。
赞代码分析,跟主题没关,是个通用计算的bug,thx~
b7ffbbd
No branches or pull requests
使用了green主题,发现了一个bug:鼠标从图表的最左端hover进来时,在x轴的第一个grid,tooltip的function拿到的参数值中的data为undefined。经过追踪,发现green主题设置了grid的border为0,在执行
后postion不变,导致_getNearestDataIndex函数中的:
执行后dataIndex为-2,没有拿到具体的数据。
The text was updated successfully, but these errors were encountered: