« get me outta code hell

content: pass color directly through slots in various places - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content/dependencies/generateAlbumInfoPage.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2023-08-02 12:45:30 -0300
committer(quasar) nebula <qznebula@protonmail.com>2023-08-02 12:45:30 -0300
commit00644623eb6c99a33b3b08771f4f23841f747b88 (patch)
treeeffb4db5cb5a317adc56614484180552c447cc70 /src/content/dependencies/generateAlbumInfoPage.js
parentc699396105f5aaa2380ab3dee282e1f99f7055fb (diff)
content: pass color directly through slots in various places
Primarily through generateColorStyle{Rules,Variables}, the former
of which is also refactored into generatePageLayout, which now
takes a direct color slot itself as well.
Diffstat (limited to 'src/content/dependencies/generateAlbumInfoPage.js')
-rw-r--r--src/content/dependencies/generateAlbumInfoPage.js9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/content/dependencies/generateAlbumInfoPage.js b/src/content/dependencies/generateAlbumInfoPage.js
index 8fbb81f..8ba5353 100644
--- a/src/content/dependencies/generateAlbumInfoPage.js
+++ b/src/content/dependencies/generateAlbumInfoPage.js
@@ -16,7 +16,6 @@ export default {
     'generateAlbumStyleRules',
     'generateAlbumTrackList',
     'generateChronologyLinks',
-    'generateColorStyleRules',
     'generateContentHeading',
     'generatePageLayout',
     'linkAlbum',
@@ -39,9 +38,6 @@ export default {
     relations.albumStyleRules =
       relation('generateAlbumStyleRules', album);
 
-    relations.colorStyleRules =
-      relation('generateColorStyleRules', album.color);
-
     relations.socialEmbed =
       relation('generateAlbumSocialEmbed', album);
 
@@ -145,6 +141,7 @@ export default {
     const data = {};
 
     data.name = album.name;
+    data.color = album.color;
 
     if (!empty(album.additionalFiles)) {
       data.numAdditionalFiles = album.additionalFiles.length;
@@ -163,8 +160,8 @@ export default {
         title: language.$('albumPage.title', {album: data.name}),
         headingMode: 'sticky',
 
-        colorStyleRules: [relations.colorStyleRules],
-        additionalStyleRules: [relations.albumStyleRules],
+        color: data.color,
+        styleRules: [relations.albumStyleRules],
 
         cover:
           relations.cover