mirror of
https://github.com/wavetermdev/waveterm
synced 2026-05-23 08:48:28 +00:00
use closeNode for eventbus layoutaction
This commit is contained in:
parent
b0a09db4d1
commit
a97b8cca58
1 changed files with 1 additions and 5 deletions
|
|
@ -275,11 +275,7 @@ function handleWSEventMessage(msg: WSEventType) {
|
|||
case LayoutTreeActionType.DeleteNode: {
|
||||
const leaf = layoutModel?.getNodeByBlockId(layoutAction.blockid);
|
||||
if (leaf) {
|
||||
const deleteNodeAction = {
|
||||
type: LayoutTreeActionType.DeleteNode,
|
||||
nodeId: leaf.id,
|
||||
};
|
||||
layoutModel.treeReducer(deleteNodeAction);
|
||||
layoutModel.closeNode(leaf);
|
||||
} else {
|
||||
console.error(
|
||||
"Cannot apply eventbus layout action DeleteNode, could not find leaf node with blockId",
|
||||
|
|
|
|||
Loading…
Reference in a new issue