-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
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
当页面发生滚动后,dnd中的节点拖拽到画布中会延迟一会儿才显示 #4461
Comments
Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. |
楼主解决了吗 |
这个问题是否有解决办法?应该不是dnd的问题,因为我是自定义的拖拽面板也复现了问题。 |
我也遇到这个问题了,当鼠标滚轮滚动后,针对元素的修改方法会延迟生效。但是拖动滚动条没问题 |
没人解决啊😂
…---- 回复的原邮件 ----
| 发件人 | ***@***.***> |
| 发送日期 | 2024年11月04日 14:57 |
| 收件人 | ***@***.***> |
| 抄送人 | zlecheng ***@***.***>,
Comment ***@***.***> |
| 主题 | Re: [antvis/X6] 当页面发生滚动后,dnd中的节点拖拽到画布中会延迟一会儿才显示 (Issue #4461) |
我也遇到这个问题了,当鼠标滚轮滚动后,针对元素的修改方法会延迟生效。但是拖动滚动条没问题
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you commented.Message ID: ***@***.***>
|
@zlecheng 难顶,我就算把滚动条隐藏了,只要用了鼠标滚动就能复现 |
是的
…---- 回复的原邮件 ----
| 发件人 | ***@***.***> |
| 发送日期 | 2024年11月04日 15:06 |
| 收件人 | antvis/X6 ***@***.***> |
| 抄送人 | zlecheng ***@***.***>,
Mention ***@***.***> |
| 主题 | Re: [antvis/X6] 当页面发生滚动后,dnd中的节点拖拽到画布中会延迟一会儿才显示 (Issue #4461) |
@zlecheng 难顶,我就算把滚动条隐藏了,只要用了鼠标滚动就能复现
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
换成1.x版本可以解决 |
那这也不现实啊 |
这个库似乎已经不再维护了,使用1.x和2.x区别不大,都存在一些历史遗留问题,我只是随手试了一下1.x发现能用,就没再在2.x上测试解决方案了😂 |
只能两个版本都测试一下了,哪个版本影响小就用哪个吧
…------------------ 原始邮件 ------------------
发件人: ***@***.***>;
发送时间: 2024年11月4日(星期一) 晚上10:28
收件人: ***@***.***>;
抄送: ***@***.***>; ***@***.***>;
主题: Re: [antvis/X6] 当页面发生滚动后,dnd中的节点拖拽到画布中会延迟一会儿才显示 (Issue #4461)
换成1.x版本可以解决
那这也不现实啊
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you commented.Message ID: ***@***.***>
|
似乎是异步渲染导致的。 |
async:false似乎可以解决这个问题(未充分测试),但是会引发其它问题,比如自定义vue节点拖拽渲染时,在mounted中获取node.attr()中绑定的自定义数据为undefined |
问题描述
当页面发生滚动后(不是画布滚动,是整个网页页面上下滚动),dnd中的节点立即拖拽到画布中会延迟一会儿才显示。
补充1:如果滚动之后,过两三秒再拖拽节点,则没有延迟。
补充2:如果滚动后,立即拖拽到页面中,然后迅速手动再滚动一次页面,则会立即渲染该节点。
重现链接
https://x6.antv.antgroup.com/tutorial/plugins/dnd
重现步骤
1.进入上述官方示例网页
2.用鼠标滑轮滚动页面后,迅速拖拽一个节点到画布中,就可以看到延迟的现象
3.滚动后静置2-3s,再拖拽节点到画布中,则没有延迟
注意,每次滚动后,只有首次拖拽会出现这个现象。
预期行为
我期望页面滚动后,立即拖拽节点到画布中时,不要延迟长达2s左右,而是控制在1s以内
平台
屏幕截图或视频(可选)
No response
补充说明(可选)
No response
The text was updated successfully, but these errors were encountered: