fix: fix trigger multiple moved event when close movable config
This commit is contained in:
@ -1059,7 +1059,7 @@ export class NodeView<
|
||||
) {
|
||||
const cells = [cell]
|
||||
const selection = this.graph.selection.widget
|
||||
if (selection) {
|
||||
if (selection && selection.options.movable) {
|
||||
const selectedCells = this.graph.getSelectedCells()
|
||||
cells.push(
|
||||
...selectedCells.filter((c: Cell) => c.isNode() && c.id !== cell.id),
|
||||
|
@ -130,7 +130,9 @@ if (graph.isRubberbandEnabled()) {
|
||||
|
||||
### movable
|
||||
|
||||
选中的节点是否可以被移动,设置为 `true` 时,拖动选框触发节点移动,默认为 `true`。
|
||||
在多选情况下,选中的节点是否一起移动,设置为 `true` 时,拖动选框框选的节点一起移动,默认为 `true`。
|
||||
|
||||
<img src="https://gw.alipayobjects.com/mdn/rms_43231b/afts/img/A*MD11S4oxIJIAAAAAAAAAAAAAARQnAQ" width="600px" height="300px" alt="movable"/>
|
||||
|
||||
### content
|
||||
|
||||
|
@ -130,7 +130,9 @@ if (graph.isRubberbandEnabled()) {
|
||||
|
||||
### movable
|
||||
|
||||
选中的节点是否可以被移动,设置为 `true` 时,拖动选框触发节点移动,默认为 `true`。
|
||||
在多选情况下,选中的节点是否一起移动,设置为 `true` 时,拖动选框框选的节点一起移动,默认为 `true`。
|
||||
|
||||
<img src="https://gw.alipayobjects.com/mdn/rms_43231b/afts/img/A*MD11S4oxIJIAAAAAAAAAAAAAARQnAQ" width="600px" height="300px" alt="movable"/>
|
||||
|
||||
### content
|
||||
|
||||
|
Reference in New Issue
Block a user