diff options
author | (quasar) nebula <qznebula@protonmail.com> | 2023-06-02 19:37:48 -0300 |
---|---|---|
committer | (quasar) nebula <qznebula@protonmail.com> | 2023-06-02 19:37:48 -0300 |
commit | 0148f49f3e08e6f148e30807669a6c103e3021ff (patch) | |
tree | e18e984c5651df4ff4db284564dd09080fe5b006 /src/content | |
parent | 1ac4ee874047636ed9013350c3db2d5e49d7669a (diff) |
content: generateArtistInfoPage: artist gallery link
Diffstat (limited to 'src/content')
-rw-r--r-- | src/content/dependencies/generateArtistInfoPage.js | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/src/content/dependencies/generateArtistInfoPage.js b/src/content/dependencies/generateArtistInfoPage.js index 06baa961..c319d08b 100644 --- a/src/content/dependencies/generateArtistInfoPage.js +++ b/src/content/dependencies/generateArtistInfoPage.js @@ -11,6 +11,7 @@ export default { 'generatePageLayout', 'linkAlbum', 'linkArtist', + 'linkArtistGallery', 'linkTrack', ], @@ -25,11 +26,13 @@ export default { relations.artistNavLinks = relation('generateArtistNavLinks', artist); - /* - const hasGallery = + if ( !empty(artist.albumsAsCoverArtist) || - !empty(artist.tracksAsCoverArtist); - */ + !empty(artist.tracksAsCoverArtist) + ) { + relations.artistGalleryLink = + relation('linkArtistGallery', artist); + } const processContribs = (...contribArrays) => { const properties = {}; @@ -202,15 +205,13 @@ export default { {id: 'art', class: ['content-heading']}, language.$('artistPage.artList.title')), - /* - hasGallery && + relations.artistGalleryLink && html.tag('p', language.$('artistPage.viewArtGallery.orBrowseList', { - link: link.artistGallery(artist, { - text: language.$('artistPage.viewArtGallery.link'), - }) + link: relations.artistGalleryLink.slots({ + content: language.$('artistPage.viewArtGallery.link'), + }), })), - */ /* !empty(artGroups) && |