« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--src/misc-templates.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/misc-templates.js b/src/misc-templates.js
index 932b3da..62f41c5 100644
--- a/src/misc-templates.js
+++ b/src/misc-templates.js
@@ -301,6 +301,7 @@ export function getThemeString(color, additionalVariables = []) {
 
 export function getAlbumStylesheet(album, {to}) {
   const hasWallpaper = album.wallpaperArtistContribs.length >= 1;
+  const hasWallpaperStyle = !!album.wallpaperStyle;
   const hasBannerStyle = !!album.bannerStyle;
 
   const wallpaperSource =
@@ -314,7 +315,12 @@ export function getAlbumStylesheet(album, {to}) {
     (hasWallpaper
       ? [
           `body::before {`,
-          `    background-image: url("${wallpaperSource}")`,
+          `    background-image: url("${wallpaperSource}");`,
+          ...html.fragment(
+            hasWallpaperStyle &&
+              album.wallpaperStyle
+              .split('\n')
+              .map(line => `    ${line}`)),
           `}`,
         ]
       : []);