Commit 22bde795 authored by Tomoaki Hayasaka's avatar Tomoaki Hayasaka
Browse files

Fix "Ctrl+Enter doesn't work when textarea has focus" regression introduced in #491.

parent 74fc7b77
......@@ -5,12 +5,6 @@ app.registerExtension({
name: id,
init() {
const keybindListener = function(event) {
const target = event.composedPath()[0];
if (target.tagName === "INPUT" || target.tagName === "TEXTAREA") {
return;
}
const modifierPressed = event.ctrlKey || event.metaKey;
// Queue prompt using ctrl or command + enter
......@@ -19,6 +13,12 @@ app.registerExtension({
return;
}
const target = event.composedPath()[0];
if (target.tagName === "INPUT" || target.tagName === "TEXTAREA") {
return;
}
const modifierKeyIdMap = {
"s": "#comfy-save-button",
83: "#comfy-save-button",
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment