G6 icon indicating copy to clipboard operation
G6 copied to clipboard

缩小和放大画布会导致tooltip的定位发生偏移

Open zyh0yh opened this issue 9 months ago • 2 comments

Describe the bug

缩小和放大画布会导致tooltip的定位发生偏移

Your Example Website or App

https://g6-next.antv.antgroup.com/examples/tool/tooltip/#tooltipPlugin

Steps to Reproduce the Bug or Issue

1.打开5.0示例文档中提示框示例 2.在 modes配置中增加 'zoom-canvas','drag-canvas',使示例可缩放和拖拽 3.先不进行任何操作,将鼠标移入节点查看和记录tooltip的postion位置 4.进行缩放,再次鼠标移入节点查看和记录tooltip的postion位置

Expected behavior

tooltip 的 fixtoNode 可以不受画布缩放和拖拽的影响,更灵活的配置,并且希望增加一个topcenter,center等 定位参数

Screenshots or Videos

No response

Platform

  • OS: [e.g. macOS, Windows, Linux]
  • Browser: [e.g. Chrome, Safari, Firefox]
  • Version: [5.0.0-beta.27]

Additional context

No response

zyh0yh avatar Nov 09 '23 01:11 zyh0yh

Hi @zyh0yh, Please star this repo if you find it useful! Thanks :star:! 你好 @zyh0yh。如果该仓库对你有用,可以 star 一下,感谢你的 :star:!

github-actions[bot] avatar Nov 09 '23 01:11 github-actions[bot]

遇到了相似的问题,G6.TreeGraph changeSize api调用后,Tooltip的offset发生偏差,鼠标直接出现在了Tooltip里,导致鼠标一致悬停tooltip不再自动隐藏

fatyrify avatar Nov 20 '23 08:11 fatyrify