mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-10-05 21:15:26 +08:00
fixed word config highlighting not working
This commit is contained in:
parent
d5fae40187
commit
fff83ac61e
1 changed files with 4 additions and 3 deletions
|
@ -1081,10 +1081,11 @@ export function setWordCount(wordCount, nosave) {
|
|||
config.words = wordCount;
|
||||
$("#top .config .wordCount .text-button").removeClass("active");
|
||||
if (![10, 25, 50, 100, 200].includes(wordCount)) {
|
||||
$("#top .config .wordCount .text-button[wordCount='custom']").addClass(
|
||||
"active"
|
||||
);
|
||||
wordCount = "custom";
|
||||
}
|
||||
$(`#top .config .wordCount .text-button[wordCount='${wordCount}']`).addClass(
|
||||
"active"
|
||||
);
|
||||
ChallengeContoller.clearActive();
|
||||
if (!nosave) saveToLocalStorage();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue