You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by GitBox <gi...@apache.org> on 2021/05/22 00:35:21 UTC

[GitHub] [echarts] plainheart edited a comment on issue #14695: Connected tooltip lags and glitches on paired chart

plainheart edited a comment on issue #14695:
URL: https://github.com/apache/echarts/issues/14695#issuecomment-826274009


   @pissang To find out why the tooltip is lagged and shakes from side to side, especially in the connected charts, I dug slightly into the related source code. Currently, I'm thinking it may be for the method `TooltipView#_updatePosition` will be very frequently called when `mousemove`. Only in `4ms`, it seems to be called many times. The normal chart can work smoothly, but in the connected chart, it will become worse. So far, I tried to throttle the `_updatePosition` function in `50ms`(the tested result may need to validate), it's working better in both Chrome(with the devtools open) and Firefox even if we use the previous way `left/top`.
   
   Here is the demo using the ECharts lib based on this temporary solution, it seems to be working well in Firefox and Chrome with the devtools open. https://codepen.io/plainheart/pen/KKarOZb
   
   The branch for this change is https://github.com/apache/echarts/tree/fix-tooltip. The related test case is `tooltip-lag-glitch.html`.
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org