From 0ac4610d29fd68f3c04030c8e6b214d518a0ef32 Mon Sep 17 00:00:00 2001 From: Miodec Date: Tue, 2 Feb 2021 19:31:33 +0000 Subject: [PATCH] fixed some test modes notices not reacting to clicks properly --- src/js/script.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/js/script.js b/src/js/script.js index 01c9b5363..8c723574d 100644 --- a/src/js/script.js +++ b/src/js/script.js @@ -3760,7 +3760,7 @@ function updateTestModesNotice() { if (sameWordset) { $(".pageTest #testModesNotice").append( - `
repeated
` + `
repeated
` ); } @@ -3793,7 +3793,7 @@ function updateTestModesNotice() { if (config.blindMode) { $(".pageTest #testModesNotice").append( - `
blind
` + `
blind
` ); } @@ -4805,12 +4805,15 @@ $(document).mousemove(function (event) { $(document).on("click", "#testModesNotice .text-button", (event) => { let commands = eval($(event.currentTarget).attr("commands")); + let func = $(event.currentTarget).attr("function"); if (commands !== undefined) { if ($(event.currentTarget).attr("commands") === "commandsTags") { updateCommandsTagsList(); } currentCommands.push(commands); showCommandLine(); + } else if (func != undefined) { + eval(func); } });