Have an edge point to the centre of another edge #2938
andreasnett posted onGitHub
<!-- ⚠️ ⚠️ ⚠️ 注意:请使用下面的链接来新建 issue: ⚠️ ⚠️ ⚠️ https://antv-issue-helper.surge.sh 不是用上面的链接创建的 issue 会被立即关闭。 -->
<!-- ⚠️ ⚠️ ⚠️ IMPORTANT: Please use the following link to create a new issue: ⚠️ ⚠️ ⚠️ https://antv-issue-helper.surge.sh If your issue was not created by using the link above, it will be closed immediately. -->
I assume this can be done by calling graph.updateItem and set the target to an {x, y} that is the center of the edge. The center of the edge can be calculated by having access to the target edge, which can be done at click events. However, I am not sure where I should do this to have access to both the graph, to call updateItem, as well as the target edge. When the edge is clicked, a event is fired in my app that adds this relation to the redux store. I think it should be done with afterDraw, but here I can't access graph.updateItem