mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-02-11 00:03:44 +08:00
re-added funbox notification
This commit is contained in:
parent
a2b7aa281c
commit
dde90f829c
2 changed files with 9 additions and 5 deletions
|
@ -162,7 +162,15 @@ export async function activate(funbox, mode) {
|
|||
return true;
|
||||
}
|
||||
export function setFunbox(funbox, mode) {
|
||||
if (TestLogic.active || TestUI.resultVisible) {
|
||||
Notifications.add(
|
||||
"You can only change the funbox before starting a test.",
|
||||
0
|
||||
);
|
||||
return false;
|
||||
}
|
||||
funboxSaved = funbox;
|
||||
modeSaved = mode;
|
||||
active = funbox;
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -314,6 +314,7 @@ export function startTest() {
|
|||
LiveAcc.show();
|
||||
TimerProgress.update(TestTimer.time);
|
||||
TestTimer.clear();
|
||||
|
||||
if (Funbox.active === "memory") {
|
||||
Funbox.resetMemoryTimer();
|
||||
$("#wordsWrapper").addClass("hidden");
|
||||
|
@ -574,14 +575,10 @@ export async function init() {
|
|||
// $("#wordsWrapper").css("height", "auto");
|
||||
// } else {
|
||||
TestUI.showWords();
|
||||
// if($(".page.active").attr("class") === $(".page.pageTest")){
|
||||
// Funbox.activate();
|
||||
// }
|
||||
if ($(".pageTest").hasClass("active")) {
|
||||
Funbox.activate();
|
||||
}
|
||||
|
||||
// }
|
||||
}
|
||||
|
||||
export function restart(withSameWordset = false, nosave = false, event) {
|
||||
|
@ -630,7 +627,6 @@ export function restart(withSameWordset = false, nosave = false, event) {
|
|||
|
||||
// restartCount++;
|
||||
}
|
||||
|
||||
if (Config.mode == "zen") {
|
||||
$("#words").empty();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue