Skip to content

Commit

Permalink
chore: focus words earlier to avoid flashing issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Miodec committed Mar 20, 2024
1 parent 0b0fff9 commit 57d9fc3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion frontend/src/ts/test/test-logic.ts
Original file line number Diff line number Diff line change
Expand Up @@ -376,6 +376,7 @@ export function restart(options = {} as RestartOptions): void {

const isWordsFocused = $("#wordsInput").is(":focus");
if (isWordsFocused) OutOfFocus.hide();
TestUI.focusWords();

$("#typingTest")
.css("opacity", 0)
Expand Down Expand Up @@ -405,7 +406,6 @@ export function restart(options = {} as RestartOptions): void {
"0";

TestUI.setTestRestarting(false);
TestUI.focusWords();
TestUI.updatePremid();
ManualRestart.reset();
PageTransition.set(false);
Expand Down

0 comments on commit 57d9fc3

Please sign in to comment.