diff --git a/src/litegraph.js b/src/litegraph.js index e61b781c7c..043df4d886 100755 --- a/src/litegraph.js +++ b/src/litegraph.js @@ -12977,7 +12977,6 @@ LGraphNode.prototype.executeAction = function(action) callback: LGraphCanvas.onMenuAdd }, { content: "Add Group", callback: LGraphCanvas.onGroupAdd }, - { content: "Align", has_submenu: true, callback: LGraphCanvas.onGroupAlign }, //{ content: "Arrange", callback: that.graph.arrange }, //{content:"Collapse All", callback: LGraphCanvas.onMenuCollapseAll } ]; @@ -12985,6 +12984,14 @@ LGraphNode.prototype.executeAction = function(action) options.push({ content: "Options", callback: that.showShowGraphOptionsPanel }); }*/ + if (Object.keys(this.selected_nodes).length > 1) { + options.push({ + content: "Align", + has_submenu: true, + callback: LGraphCanvas.onGroupAlign, + }) + } + if (this._graph_stack && this._graph_stack.length > 0) { options.push(null, { content: "Close subgraph",