mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-01-30 21:09:53 +00:00
Support clicking on library entries to toggle expand/insert node (#511)
* Support clicking on library entries to toggle expand/insert node * Fix type
This commit is contained in:
@@ -2951,6 +2951,11 @@ export class ComfyApp {
|
||||
([p, o1, o2]) => (p - o2) / this.canvas.ds.scale - o1
|
||||
) as Vector2
|
||||
}
|
||||
|
||||
getCanvasCenter() {
|
||||
const [x, y, w, h] = app.canvas.ds.visible_area
|
||||
return [x + w / 2, y + h / 2]
|
||||
}
|
||||
}
|
||||
|
||||
export const app = new ComfyApp()
|
||||
|
||||
Reference in New Issue
Block a user