mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-04 07:00:23 +00:00
[Bug] Fix widget placeholder rendering (#3215)
Co-authored-by: github-actions <github-actions@github.com>
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 36 KiB After Width: | Height: | Size: 36 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 33 KiB After Width: | Height: | Size: 33 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 35 KiB |
@@ -148,12 +148,13 @@ abstract class BaseDOMWidgetImpl<V extends object | string>
|
||||
if (this.options.hideOnZoom && lowQuality) {
|
||||
// Draw a placeholder rectangle
|
||||
const originalFillStyle = ctx.fillStyle
|
||||
ctx.beginPath()
|
||||
ctx.fillStyle = LiteGraph.WIDGET_BGCOLOR
|
||||
ctx.rect(
|
||||
this.margin,
|
||||
y,
|
||||
y + this.margin,
|
||||
widget_width - this.margin * 2,
|
||||
(this.computedHeight ?? widget_height) - this.margin
|
||||
(this.computedHeight ?? widget_height) - 2 * this.margin
|
||||
)
|
||||
ctx.fill()
|
||||
ctx.fillStyle = originalFillStyle
|
||||
|
||||
Reference in New Issue
Block a user