* Proper node width/height calculation

* 0.7.71
This commit is contained in:
Chenlei Hu
2024-09-12 17:00:13 +09:00
committed by GitHub
parent 7dbe6400bb
commit 0f1b72ce94
4 changed files with 9 additions and 5 deletions

View File

@@ -4820,11 +4820,11 @@ const globalExport = {};
}
get width() {
return this.size[0];
return this.collapsed ? this._collapsed_width || LiteGraph.NODE_COLLAPSED_WIDTH : this.size[0];
}
get height() {
return this.size[1];
return this.collapsed ? LiteGraph.NODE_COLLAPSED_HEIGHT : this.size[1];
}
drawBadges(ctx, {gap = 2} = {}) {