diff options
author | (quasar) nebula <qznebula@protonmail.com> | 2023-06-08 10:27:42 -0300 |
---|---|---|
committer | (quasar) nebula <qznebula@protonmail.com> | 2023-06-08 10:27:42 -0300 |
commit | e1f8beeb384ad4a1a30f2654e17008ae730adf56 (patch) | |
tree | 29bc8d9f1266d9fec51b24f174f62c60338f7db3 /src/content/dependencies/generateAlbumInfoPage.js | |
parent | af6f7e78c5c148ac3b194170ee65a30f75ad5413 (diff) |
content: compute "needs reveal" class only on client
Diffstat (limited to 'src/content/dependencies/generateAlbumInfoPage.js')
-rw-r--r-- | src/content/dependencies/generateAlbumInfoPage.js | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/content/dependencies/generateAlbumInfoPage.js b/src/content/dependencies/generateAlbumInfoPage.js index 42f4646f..b049f90e 100644 --- a/src/content/dependencies/generateAlbumInfoPage.js +++ b/src/content/dependencies/generateAlbumInfoPage.js @@ -173,12 +173,8 @@ export default { data.duration = accumulateSum(album.tracks, track => track.duration); data.durationApproximate = album.tracks.length > 1; - if (album.hasCoverArt) { - data.coverNeedsReveal = album.artTags.some(t => t.isContentWarning); - - if (album.coverArtDate && +album.coverArtDate !== +album.date) { - data.coverArtDate = album.coverArtDate; - } + if (album.coverArtDate && +album.coverArtDate !== +album.date) { + data.coverArtDate = album.coverArtDate; } if (!empty(album.additionalFiles)) { @@ -216,7 +212,6 @@ export default { ?.slots({ alt: language.$('misc.alt.albumCover'), }), - coverNeedsReveal: relations.content.coverNeedsReveal, mainContent: [ html.tag('p', |