Skip to content
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

antv-dagre layout, after resetting the data and rendering, the node order is not as expected #6490

Open
majinkai opened this issue Nov 8, 2024 · 2 comments

Comments

@majinkai
Copy link

majinkai commented Nov 8, 2024

Describe the bug / 问题描述

动态添加了一个节点,然后重新设置布局,给出了nodeOrder顺序,但是没有按照预期顺序自上而下排列,预期节点顺序是44在4上面,如果是destroy之后重新初始化,是没问题的。

Reproduction link / 重现链接

https://codesandbox.io/p/sandbox/red-rgb-wzszl5

Steps to Reproduce the Bug or Issue / 重现步骤

No response

G6 Version / G6 版本

🆕 5.x

Operating System / 操作系统

macOS

Browser / 浏览器

Chrome

Additional context / 补充说明

No response

@github-actions github-actions bot changed the title antv-dagre布局,重新设置数据并render后,节点顺序与预期不符 antv-dagre layout, after resetting the data and rendering, the node order is not as expected Nov 8, 2024
@Aarebecca
Copy link
Contributor

节点的顺序是基于 dagre 算法计算的,与在数据中的关系并没有关系。
图数据中的数据项顺序不具有任何含义

@majinkai
Copy link
Author

nodeOrder不起作用了,并且destroy之后重新初始化,是没问题的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants