G6 icon indicating copy to clipboard operation
G6 copied to clipboard

plugin menu异步加载数据

Open gtx-titanx opened this issue 1 year ago • 4 comments

问题描述

您好,想请问下需求是右键点击节点展示菜单,菜单数据是通过ajax获取,第一次点击时发出请求获取到数据,但是菜单没能加载到数据,再点击一次才能正确的加载刚刚获取的菜单数据,这种情况要怎么解决

重现链接

重现步骤

预期行为

希望右击节点调取ajax数据能正确加载到菜单上

平台

  • 操作系统: [macOS, Windows, Linux, React Native ...]
  • 网页浏览器: [Google Chrome, Safari, Firefox]
  • G6 版本: [4.5.1 ... ]

屏幕截图或视频(可选)

https://github.com/antvis/G6/assets/50905648/feb87535-13b7-4753-a944-c5aa243194c2

补充说明(可选)

No response

gtx-titanx avatar Oct 25 '23 02:10 gtx-titanx

hi @gtx-titanx, welcome!

github-actions[bot] avatar Oct 25 '23 02:10 github-actions[bot]

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

github-actions[bot] avatar Oct 25 '23 02:10 github-actions[bot]

v4 不支持~ v5 支持,v5 正在 beta 中,欢迎试用:https://g6-next.antv.antgroup.com/zh/examples/tool/contextMenu/#contextMenu image

当然也欢迎社区朋友给 v4 提 PR 共建~

Yanyan-Wang avatar Nov 02 '23 08:11 Yanyan-Wang

我也出现同样的问题,我返回了一个带有slot的 div外层盒子,并给slot 传递了节点的data,第一次点击菜单拿不到传递的data,第二次才生效,beat:v5

zyh0yh avatar Nov 08 '23 02:11 zyh0yh

This issue has been closed because it has been outdate for a long time. Please open a new issue if you still need help.

这个 issue 已经被关闭,因为 它已经过期很久了。 如果你仍然需要帮助,请创建一个新的 issue。

github-actions[bot] avatar Jul 05 '24 05:07 github-actions[bot]