« get me outta code hell

don't show only-base-contributed tracks - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/upd8.js
diff options
context:
space:
mode:
authorFlorrie <towerofnix@gmail.com>2019-11-19 15:26:04 -0400
committerFlorrie <towerofnix@gmail.com>2019-11-19 15:26:04 -0400
commitc2f9fc44776f1a5cb343963a00a1524e6ff3154f (patch)
treea95a859c74f09501f32569050f9dd9c4350ba6bc /upd8.js
parentd446362bd6046a82446d1fca4e7f2885c98c34fd (diff)
don't show only-base-contributed tracks
i.e, don't show tracks in artist listings to which the artist has only
contributed a based-upon song to; these tracks clutter the list and are
less useful than they were before thanks to each track's list of tracks
that reference it on its page
Diffstat (limited to 'upd8.js')
-rw-r--r--upd8.js6
1 files changed, 2 insertions, 4 deletions
diff --git a/upd8.js b/upd8.js
index d169d82..c2aaad3 100644
--- a/upd8.js
+++ b/upd8.js
@@ -671,8 +671,7 @@ async function writeArtistPage(artistName, albumData) {
     const allTracks = getAllTracks(albumData);
     const tracks = sortByDate(allTracks.filter(track => (
         track.artists.includes(artistName) ||
-        track.contributors.some(({ who }) => who === artistName) ||
-        getTracksReferencedBy(track, allTracks).some(track => track.artists.includes(artistName))
+        track.contributors.some(({ who }) => who === artistName)
     )));
     const artThings = sortByDate(albumData.concat(allTracks).filter(thing => (thing.coverArtists || []).some(({ who }) => who === artistName)));
     const commentaryThings = sortByDate(albumData.concat(allTracks).filter(thing => thing.commentary && thing.commentary.includes('<i>' + artistName + ':</i>')));
@@ -705,7 +704,6 @@ async function writeArtistPage(artistName, albumData) {
                     ].filter(Boolean).join(', ')}</p>
                     ${tracks.length && fixWS`
                         <h2 id="tracks">Tracks</h2>
-                        <p>Dim tracks are tracks that this artist contributed only a based-upon song to.</p>
                         <ol>
                             ${tracks.map(track => {
                                 const contrib = {
@@ -720,7 +718,7 @@ async function writeArtistPage(artistName, albumData) {
                                     contrib.what = nonTracks.join(', ');
                                 }
                                 return fixWS`
-                                    <li class="${!track.artists.includes(artistName) && `contributed ${track.contributors.filter(({ who }) => who === artistName).every(({ what }) => what && what.startsWith('[') && what.endsWith(']')) && 'contributed-only-original'}`}">
+                                    <li class="${!track.artists.includes(artistName) && `contributed`}">
                                         <a href="${TRACK_DIRECTORY}/${track.directory}/index.html">${track.name}</a>
                                         ${track.artists.includes(artistName) && track.artists.length > 1 && `<span="contributed">(with ${getArtistString(track.artists.filter(a => a !== artistName))})</span>`}
                                         ${contrib.what && `<span class="contributed">(${getContributionString(contrib, tracks) || 'contributed'})</span>`}