群组节点嵌入重复的id的children,能否限制一下。
问题描述
场景是做协同导致的。 用户A创建了一个组节点。此时把组节点数据同步至B用户,B用户把群组内的一个元素,拖拽出群组后,应该是脱离了嵌套关系的,但是群组节点的children数据并未移除拖出的元素。然后把拖拽出去的节点重新拖入到组内,就出现了children中重复id的数据。
重现链接
https://codesandbox.io/s/new
重现步骤
协同操作 1.A用户画板中有两个元素,框选后,点击群组按钮进行分组。 2.把群组的数据同步至B用户。B用户把群组节点中的一个元素拖拽出分组后。群组节点的children中并未移除拖出去的元素。 3.把拖出去的元素重新拖入群组,children中就出现了重复的cell
预期行为
拖出后应解除嵌套关系。重新放入群组不应重复。
平台
- 操作系统: [macOS, Windows, Linux, React Native ...]
- 网页浏览器: [Google Chrome, Safari, Firefox ...]
- X6 版本: [2.11.1 ...]
屏幕截图或视频(可选)
补充说明(可选)
No response
👋 @guicicode
Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. To help make it easier for us to investigate your issue, please follow the contributing guidelines. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.
sanbox的地址不正确,看看帮忙更改下
📝 To help us better understand and address your issue, please provide more information, or use the standard format, otherwise we will not process this issue.
Reference document:
📝 为了帮助我们更好地理解和解决你的问题,请提供更多信息,或者使用规范的格式,否则我们不会处理这个 issue。
参考文档:
⚠️ This issue has been automatically closed due to inactivity.
- If the issue is still relevant and important to you, feel free to:
- Reopen with additional information
- Create a new issue with updated context
- Reference any related issues or discussions
We close inactive issues to keep our backlog manageable and focused on active issues.
Your contribution makes our project better! 🌟
⚠️ 由于长期无活动,此 issue 已被自动关闭。
- 如果这个问题对您来说仍然重要,您可以:
- 重新打开并提供补充信息
- 创建一个新的 issue 并更新相关背景
- 关联相关的 issue 或讨论
为了更好地维护项目,我们需要定期清理不活跃的问题。
感谢您为开源添砖加瓦!🌟