Add 6.png image (storm outlook) support for the themes
Some checks are pending
build-docker / Build Image (push) Waiting to run

This commit is contained in:
mrkmntal 2026-04-09 22:35:27 -04:00
commit 2e304d41c6
10 changed files with 9 additions and 3 deletions

View file

@ -10,6 +10,7 @@ const BUILTIN_ASSETS = {
background3: 'images/backgrounds/3.png',
background4: 'images/backgrounds/4.png',
background5: 'images/backgrounds/5.png',
background6: 'images/backgrounds/6.png',
logoCorner: 'images/logos/logo-corner.png',
};
@ -44,6 +45,8 @@ const getThemeAssetUrl = (themeName, assetKey) => {
return withBasePath(`themes/${themeName}/4.png`);
case 'background5':
return withBasePath(`themes/${themeName}/5.png`);
case 'background6':
return withBasePath(`themes/${themeName}/6.png`);
case 'logoCorner':
return withBasePath(`themes/${themeName}/logo-corner.png`);
default:
@ -61,6 +64,7 @@ const applyTheme = (themeName) => {
document.documentElement.style.setProperty('--theme-background-3', `url('${getThemeAssetUrl(selectedTheme, 'background3')}')`);
document.documentElement.style.setProperty('--theme-background-4', `url('${getThemeAssetUrl(selectedTheme, 'background4')}')`);
document.documentElement.style.setProperty('--theme-background-5', `url('${getThemeAssetUrl(selectedTheme, 'background5')}')`);
document.documentElement.style.setProperty('--theme-background-6', `url('${getThemeAssetUrl(selectedTheme, 'background6')}')`);
document.querySelectorAll('.theme-logo').forEach((img) => {
img.src = getThemeAssetUrl(selectedTheme, 'logoCorner');

View file

@ -335,6 +335,7 @@ body {
--theme-background-3: url('../images/backgrounds/3.png');
--theme-background-4: url('../images/backgrounds/4.png');
--theme-background-5: url('../images/backgrounds/5.png');
--theme-background-6: url('../images/backgrounds/6.png');
}
#display {

View file

@ -2,7 +2,7 @@
@use 'shared/_utils'as u;
#spc-outlook-html.weather-display {
background-image: url('../images/backgrounds/6.png');
background-image: var(--theme-background-6);
}
.weather-display .spc-outlook {
@ -83,4 +83,4 @@
}
}
}
}
}

File diff suppressed because one or more lines are too long