mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-11-09 21:51:29 +08:00
fix(commandline): blur active element after closing the modal to hide balloons
closes #6320
This commit is contained in:
parent
02c48fc50d
commit
25dada50eb
1 changed files with 7 additions and 3 deletions
|
|
@ -130,9 +130,13 @@ function hide(clearModalChain = false): void {
|
|||
clearModalChain,
|
||||
afterAnimation: async () => {
|
||||
addCommandlineBackground();
|
||||
const isWordsFocused = $("#wordsInput").is(":focus");
|
||||
if (ActivePage.get() === "test" && !isWordsFocused) {
|
||||
focusWords();
|
||||
if (ActivePage.get() === "test") {
|
||||
const isWordsFocused = $("#wordsInput").is(":focus");
|
||||
if (ActivePage.get() === "test" && !isWordsFocused) {
|
||||
focusWords();
|
||||
}
|
||||
} else {
|
||||
(document.activeElement as HTMLElement | undefined)?.blur();
|
||||
}
|
||||
isAnimating = false;
|
||||
},
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue