mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-03 06:47:33 +00:00
[BugFix] Auto grow node if widgets need more space (#556)
This commit is contained in:
@@ -3374,6 +3374,15 @@ export class LGraphNode implements Positionable, IPinnable, IColorable {
|
||||
w.y = y
|
||||
y += w.computedHeight
|
||||
}
|
||||
|
||||
// Grow the node if necessary.
|
||||
// Ref: https://github.com/Comfy-Org/ComfyUI_frontend/issues/2652
|
||||
// TODO: Move the layout logic before drawing of the node shape, so we don't
|
||||
// need to trigger extra round of rendering.
|
||||
if (y > bodyHeight) {
|
||||
this.setSize([this.size[0], y])
|
||||
this.graph.setDirtyCanvas(false, true)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user