« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content
diff options
context:
space:
mode:
Diffstat (limited to 'src/content')
-rw-r--r--src/content/dependencies/generateAlbumSecondaryNavGroupPart.js2
-rw-r--r--src/content/dependencies/generateAlbumSecondaryNavSeriesPart.js4
-rw-r--r--src/content/dependencies/generateSecondaryNavParentSiblingsPart.js8
3 files changed, 7 insertions, 7 deletions
diff --git a/src/content/dependencies/generateAlbumSecondaryNavGroupPart.js b/src/content/dependencies/generateAlbumSecondaryNavGroupPart.js
index 58a31630..f2c9290c 100644
--- a/src/content/dependencies/generateAlbumSecondaryNavGroupPart.js
+++ b/src/content/dependencies/generateAlbumSecondaryNavGroupPart.js
@@ -67,7 +67,7 @@ export default {
 
   generate: (relations, slots) =>
     relations.parentSiblingsPart.slots({
-      mode: slots.mode,
+      showPreviousNext: slots.mode === 'album',
 
       colorStyle: relations.colorStyle,
       mainLink: relations.groupLink,
diff --git a/src/content/dependencies/generateAlbumSecondaryNavSeriesPart.js b/src/content/dependencies/generateAlbumSecondaryNavSeriesPart.js
index 12c72fd4..91e435ac 100644
--- a/src/content/dependencies/generateAlbumSecondaryNavSeriesPart.js
+++ b/src/content/dependencies/generateAlbumSecondaryNavSeriesPart.js
@@ -62,10 +62,10 @@ export default {
 
   generate: (data, relations, slots, {language}) =>
     relations.parentSiblingsPart.slots({
-      mode: slots.mode,
-
       attributes: {class: 'series-nav-link'},
 
+      showPreviousNext: slots.mode === 'album',
+
       colorStyle: relations.colorStyle,
 
       mainLink:
diff --git a/src/content/dependencies/generateSecondaryNavParentSiblingsPart.js b/src/content/dependencies/generateSecondaryNavParentSiblingsPart.js
index 82b5d151..d52a483f 100644
--- a/src/content/dependencies/generateSecondaryNavParentSiblingsPart.js
+++ b/src/content/dependencies/generateSecondaryNavParentSiblingsPart.js
@@ -22,9 +22,9 @@ export default {
   }),
 
   slots: {
-    mode: {
-      validate: v => v.is('album', 'track'),
-      default: 'album',
+    showPreviousNext: {
+      type: 'boolean',
+      default: true,
     },
 
     attributes: {
@@ -82,7 +82,7 @@ export default {
             : slots.mainLink
                 .slot('color', false));
 
-        if (slots.mode === 'album') addPreviousNext: {
+        if (slots.showPreviousNext) addPreviousNext: {
           if (html.isBlank(slots.previousLink) && html.isBlank(slots.nextLink)) {
             break addPreviousNext;
           }