mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-10-04 12:34:53 +08:00
more file refactoring
This commit is contained in:
parent
84a4beb2ed
commit
ea0b1e4113
4 changed files with 14 additions and 1 deletions
|
@ -98,7 +98,7 @@ const refactoredSrc = [
|
|||
"./src/js/sound.js",
|
||||
"./src/js/custom-text.js",
|
||||
"./src/js/shift-tracker.js",
|
||||
"./src/js/test-stats.js",
|
||||
"./src/js/test/test-stats.js",
|
||||
"./src/js/theme-colors.js",
|
||||
];
|
||||
|
||||
|
|
|
@ -6,6 +6,18 @@ export function hideBackgroundLoader() {
|
|||
$("#backgroundLoader").stop(true, true).fadeOut(125);
|
||||
}
|
||||
|
||||
function accountIconLoading(truefalse) {
|
||||
if (truefalse) {
|
||||
$("#top #menu .account .icon").html(
|
||||
'<i class="fas fa-fw fa-spin fa-circle-notch"></i>'
|
||||
);
|
||||
$("#top #menu .account").css("opacity", 1).css("pointer-events", "none");
|
||||
} else {
|
||||
$("#top #menu .account .icon").html('<i class="fas fa-fw fa-user"></i>');
|
||||
$("#top #menu .account").css("opacity", 1).css("pointer-events", "auto");
|
||||
}
|
||||
}
|
||||
|
||||
export function swapElements(
|
||||
el1,
|
||||
el2,
|
||||
|
|
|
@ -24,6 +24,7 @@ import {
|
|||
showBackgroundLoader,
|
||||
hideBackgroundLoader,
|
||||
swapElements,
|
||||
accountIconLoading,
|
||||
} from "./dom-util";
|
||||
import * as Misc from "./misc";
|
||||
import * as CloudFunctions from "./cloud-functions";
|
||||
|
|
Loading…
Add table
Reference in a new issue