« get me outta code hell

color name of track groups in sidebar - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
author(quasar) nebula <towerofnix@gmail.com>2021-05-10 13:49:17 -0300
committer(quasar) nebula <towerofnix@gmail.com>2021-05-10 13:49:17 -0300
commit99d1e39d8a63b2b7007ebaa2cc387663d2117d0f (patch)
tree5db63a1bd6754caa0b08e8ac34ee43ad77a06593 /src
parentf0453b0d5a1089aeb3d50192139f258b455af80b (diff)
color name of track groups in sidebar
very fansey :3
Diffstat (limited to 'src')
-rw-r--r--src/static/site.css5
-rwxr-xr-xsrc/upd8.js5
2 files changed, 8 insertions, 2 deletions
diff --git a/src/static/site.css b/src/static/site.css
index 4728410a..c964c512 100644
--- a/src/static/site.css
+++ b/src/static/site.css
@@ -349,9 +349,14 @@ footer > :last-child {
     user-select: none;
 }
 
+.sidebar > details summary .group-name {
+    color: var(--primary-color);
+}
+
 .sidebar > details summary:hover {
     cursor: pointer;
     text-decoration: underline;
+    text-decoration-color: var(--primary-color);
 }
 
 .sidebar > details ul,
diff --git a/src/upd8.js b/src/upd8.js
index 6eea053a..279b0053 100755
--- a/src/upd8.js
+++ b/src/upd8.js
@@ -5772,13 +5772,14 @@ function generateSidebarForAlbum(album, currentTrack, {strings, to, wikiData}) {
                     class: tracks.includes(currentTrack) && 'current'
                 }, [
                     html.tag('summary',
+                        {style: getLinkThemeString(color)},
                         (listTag === 'ol'
                             ? strings('albumSidebar.trackList.group.withRange', {
-                                group: name,
+                                group: `<span class="group-name">${name}</span>`,
                                 range: `${startIndex + 1}&ndash;${startIndex + tracks.length}`
                             })
                             : strings('albumSidebar.trackList.group', {
-                                group: name
+                                group: `<span class="group-name">${name}</span>`
                             }))
                     ),
                     fixWS`