mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-02-02 14:27:40 +00:00
Cancel link connection by pressing Esc (#811)
Cancels connecting links if the escape key is pressed.
This commit is contained in:
@@ -2917,6 +2917,11 @@ export class LGraphCanvas implements ConnectionColorContext {
|
||||
block_default = true
|
||||
} else if (e.key === "Escape") {
|
||||
// esc
|
||||
if (this.linkConnector.isConnecting) {
|
||||
this.linkConnector.reset()
|
||||
e.preventDefault()
|
||||
return
|
||||
}
|
||||
this.node_panel?.close()
|
||||
this.options_panel?.close()
|
||||
block_default = true
|
||||
|
||||
Reference in New Issue
Block a user