🎨 插件中不绑定 TEXTAREA 回车事件

This commit is contained in:
Vanessa 2023-11-16 22:32:57 +08:00
parent cbc005119a
commit 8f639fb07f
2 changed files with 6 additions and 15 deletions

View file

@ -70,7 +70,7 @@ export class Setting {
if (["INPUT", "TEXTAREA"].includes(actionElement.tagName)) {
dialog.bindInput(actionElement as HTMLInputElement, () => {
btnsElement[1].dispatchEvent(new CustomEvent("click"));
});
}, actionElement.tagName === "INPUT");
}
if (actionElement.tagName === "TEXTAREA") {
contentElement.lastElementChild.lastElementChild.insertAdjacentElement("beforeend", actionElement);