mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2024-09-20 15:26:15 +08:00
reordered functions to avoid warnings
This commit is contained in:
parent
1c74d7ecb3
commit
1020ed1a1e
|
@ -373,13 +373,6 @@ async function fillSettingsPage() {
|
|||
|
||||
export let settingsFillPromise = fillSettingsPage();
|
||||
|
||||
export function showAccountSection() {
|
||||
$(`.sectionGroupTitle[group='account']`).removeClass("hidden");
|
||||
$(`.settingsGroup.account`).removeClass("hidden");
|
||||
refreshTagsSettingsSection();
|
||||
updateDiscordSection();
|
||||
}
|
||||
|
||||
export function hideAccountSection() {
|
||||
$(`.sectionGroupTitle[group='account']`).addClass("hidden");
|
||||
$(`.settingsGroup.account`).addClass("hidden");
|
||||
|
@ -475,6 +468,13 @@ function refreshTagsSettingsSection() {
|
|||
}
|
||||
}
|
||||
|
||||
export function showAccountSection() {
|
||||
$(`.sectionGroupTitle[group='account']`).removeClass("hidden");
|
||||
$(`.settingsGroup.account`).removeClass("hidden");
|
||||
refreshTagsSettingsSection();
|
||||
updateDiscordSection();
|
||||
}
|
||||
|
||||
export function update() {
|
||||
Object.keys(groups).forEach((group) => {
|
||||
groups[group].updateButton();
|
||||
|
|
|
@ -6,6 +6,13 @@ import * as CommandlineLists from "./commandline-lists";
|
|||
import * as ThemeColors from "./theme-colors";
|
||||
import * as ChartController from "./chart-controller";
|
||||
|
||||
export function updateActiveButton() {
|
||||
$(`.pageSettings .section.themes .theme`).removeClass("active");
|
||||
$(`.pageSettings .section.themes .theme[theme=${Config.theme}]`).addClass(
|
||||
"active"
|
||||
);
|
||||
}
|
||||
|
||||
export function refreshButtons() {
|
||||
let favThemesEl = $(
|
||||
".pageSettings .section.themes .favThemes.buttons"
|
||||
|
@ -91,14 +98,6 @@ function toggleFavourite(themename) {
|
|||
CommandlineLists.updateThemeCommands();
|
||||
}
|
||||
|
||||
export function updateActiveButton() {
|
||||
$(`.pageSettings .section.themes .theme`).removeClass("active");
|
||||
$(`.pageSettings .section.themes .theme[theme=${Config.theme}]`).addClass(
|
||||
"active"
|
||||
);
|
||||
// console.log(`.pageSettings .section.themes .theme[theme=${Config.theme}]`);
|
||||
}
|
||||
|
||||
export function updateActiveTab() {
|
||||
Config.customTheme === true
|
||||
? $(".pageSettings .section.themes .tabs .button[tab='custom']").click()
|
||||
|
|
Loading…
Reference in a new issue