diff options
-rw-r--r-- | src/content/dependencies/generateAlbumInfoPage.js | 9 | ||||
-rw-r--r-- | src/content/dependencies/generatePageLayout.js | 12 |
2 files changed, 10 insertions, 11 deletions
diff --git a/src/content/dependencies/generateAlbumInfoPage.js b/src/content/dependencies/generateAlbumInfoPage.js index f0a23259..5c575cb2 100644 --- a/src/content/dependencies/generateAlbumInfoPage.js +++ b/src/content/dependencies/generateAlbumInfoPage.js @@ -38,14 +38,13 @@ export default { }) { // page.themeColor = data.color; - // page.styleRules = [ - // relations.albumStyleRules, - // relations.colorStyleRules, - // ]; - return relations.layout .slots({ title: language.$('albumPage.title', {album: data.name}), + styleRules: [ + relations.albumStyleRules, + relations.colorStyleRules, + ], cover: relations.content.cover, mainContent: relations.content.main.content, diff --git a/src/content/dependencies/generatePageLayout.js b/src/content/dependencies/generatePageLayout.js index f36a7bb5..9abac0a2 100644 --- a/src/content/dependencies/generatePageLayout.js +++ b/src/content/dependencies/generatePageLayout.js @@ -26,6 +26,11 @@ export default { default: 'static', }, + styleRules: { + validate: v => v.arrayOf(v.isString), + default: [], + }, + mainClasses: { validate: v => v.arrayOf(v.isString), default: [], @@ -162,14 +167,9 @@ export default { href: to('shared.staticFile', `site3.css?${cachebust}`), }), - /* html.tag('style', {[html.onlyIfContent]: true}, - [ - theme, - stylesheet, - ]), - */ + slots.styleRules), html.tag('script', { src: to('shared.staticFile', `lazy-loading.js?${cachebust}`), |