Skip to content

Conversation

wqgs2004214
Copy link

…translateby是node2时,导致node2和组合在一起的node3移动错乱,并且node1移动错误的bug

Description

fix #4491

Motivation and Context

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Enhancement (changes that improvement of current feature or performance)
  • Refactoring (changes that neither fixes a bug nor adds a feature)
  • Test Case (changes that add missing tests or correct existing tests)
  • Code style optimization (changes that do not affect the meaning of the code)
  • Docs (changes that only update documentation)
  • Chore (changes that don't modify src or test files)

Self Check before Merge

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

…translateby是node2时,导致node2和组合在一起的node3移动错乱,并且node1移动错误的bug
const currentCell = this.graph.getCellById(otherOptions.translateBy)
if (currentCell) {
map[currentCell.id] = true
// 问题:开启snapline后,当我们框选圆形组件、node2矩形组件(node2中有一个node3被embedding时),translateby是node2时,导致node2和组合在一起的node3移动错乱,并且node1移动错误的bug
Copy link
Member

@hustcc hustcc Aug 12, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

map[currentCell.id] = true

@wqgs2004214 这行代码知道是用来干啥的嘛?一定是特意需要这么做的,直接删了会带其他更多的问题吧?

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

Successfully merging this pull request may close these issues.

开启snapline后,框选移动BUG

2 participants