diff --git a/script.user.js b/script.user.js index 4406f38..782181e 100644 --- a/script.user.js +++ b/script.user.js @@ -1,7 +1,7 @@ // ==UserScript== // @name JPDB Userscript (6a67) // @namespace http://tampermonkey.net/ -// @version 0.1.103 +// @version 0.1.104 // @description Script for JPDB that adds some styling and functionality // @match https://jpdb.io/* // @grant GM_addStyle @@ -1197,7 +1197,7 @@ } const answerBox = document.querySelector('.answer-box'); const target = - answerBox?.querySelector('.plain') || document.querySelector('.result.kanji')?.querySelector('.plain').firstElementChild; + answerBox || document.querySelector('.result.kanji')?.querySelector('.plain').firstElementChild; const rect = target.getBoundingClientRect(); if (target) { @@ -1275,9 +1275,9 @@ await playButtonSound(button); } const form = button.closest('form'); - // if (form) { - // form.submit(); - // } + if (form) { + form.submit(); + } }, };