瀏覽代碼

prevent escape button causing an interrupt when no generation has been made yet

AUTOMATIC1111 1 年之前
父節點
當前提交
4573195894
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      script.js

+ 1 - 1
script.js

@@ -167,7 +167,7 @@ document.addEventListener('keydown', function(e) {
         const lightboxModal = document.querySelector('#lightboxModal');
         if (!globalPopup || globalPopup.style.display === 'none') {
             if (document.activeElement === lightboxModal) return;
-            if (interruptButton.style.display !== 'none') {
+            if (interruptButton.style.display === 'block') {
                 interruptButton.click();
                 e.preventDefault();
             }