mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-03-13 15:36:42 +08:00
fixed sticky active indicator
This commit is contained in:
parent
f407c7f208
commit
76b0b3b448
1 changed files with 8 additions and 8 deletions
|
@ -33,10 +33,10 @@ export function refreshButtons() {
|
|||
if (Config.favThemes.includes(theme.name)) {
|
||||
let activeTheme = activeThemeName === theme.name ? "active" : "";
|
||||
favThemesEl.append(
|
||||
`<div class="theme button" theme='${theme.name}' style="color:${
|
||||
theme.textColor
|
||||
};background:${theme.bgColor}">
|
||||
<div class="activeIndicator ${activeTheme}"><i class="fas fa-circle"></i></div>
|
||||
`<div class="theme button ${activeTheme}" theme='${
|
||||
theme.name
|
||||
}' style="color:${theme.textColor};background:${theme.bgColor}">
|
||||
<div class="activeIndicator"><i class="fas fa-circle"></i></div>
|
||||
<div class="text">${theme.name.replace(/_/g, " ")}</div>
|
||||
<div class="favButton active"><i class="fas fa-star"></i></div></div>`
|
||||
);
|
||||
|
@ -50,10 +50,10 @@ export function refreshButtons() {
|
|||
if (!Config.favThemes.includes(theme.name)) {
|
||||
let activeTheme = activeThemeName === theme.name ? "active" : "";
|
||||
themesEl.append(
|
||||
`<div class="theme button" theme='${theme.name}' style="color:${
|
||||
theme.textColor
|
||||
};background:${theme.bgColor}">
|
||||
<div class="activeIndicator ${activeTheme}"><i class="fas fa-circle"></i></div>
|
||||
`<div class="theme button ${activeTheme}" theme='${
|
||||
theme.name
|
||||
}' style="color:${theme.textColor};background:${theme.bgColor}">
|
||||
<div class="activeIndicator"><i class="fas fa-circle"></i></div>
|
||||
<div class="text">${theme.name.replace(/_/g, " ")}</div>
|
||||
<div class="favButton"><i class="far fa-star"></i></div></div>`
|
||||
);
|
||||
|
|
Loading…
Reference in a new issue