« get me outta code hell

content: generatePageSidebarBox: collapsible slot - hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/content/dependencies/generatePageLayout.js
diff options
context:
space:
mode:
author(quasar) nebula <qznebula@protonmail.com>2024-04-30 17:27:28 -0300
committer(quasar) nebula <qznebula@protonmail.com>2024-05-01 20:22:38 -0300
commit1f1fccde8dee31ac8428d8b991815b170971ccca (patch)
tree2d3200ad2df5a8aa8ebe61a59c923d6809c6d9b6 /src/content/dependencies/generatePageLayout.js
parent97f587966f6239821589bd5c137b9875e7ae29b0 (diff)
content: generatePageSidebarBox: collapsible slot
Makes collapsibility a function of the boxes in a sidebar,
rather than a property of the sidebar (column) itself.
Diffstat (limited to 'src/content/dependencies/generatePageLayout.js')
-rw-r--r--src/content/dependencies/generatePageLayout.js22
1 files changed, 5 insertions, 17 deletions
diff --git a/src/content/dependencies/generatePageLayout.js b/src/content/dependencies/generatePageLayout.js
index 927d45a1..0bf34540 100644
--- a/src/content/dependencies/generatePageLayout.js
+++ b/src/content/dependencies/generatePageLayout.js
@@ -390,14 +390,6 @@ export default {
     const hasSidebarLeft = !html.isBlank(html.resolve(leftSidebar));
     const hasSidebarRight = !html.isBlank(html.resolve(rightSidebar));
 
-    const collapseSidebars =
-      (hasSidebarLeft
-        ? leftSidebar.getSlotValue('collapse')
-        : true) &&
-      (hasSidebarRight
-        ? rightSidebar.getSlotValue('collapse')
-        : true);
-
     const processSkippers = skipperList =>
       skipperList
         .filter(({condition, id}) =>
@@ -509,15 +501,11 @@ export default {
 
       slots.secondaryNav,
 
-      html.tag('div', {class: 'layout-columns'},
-        !collapseSidebars &&
-          {class: 'vertical-when-thin'},
-
-        [
-          leftSidebar,
-          mainHTML,
-          rightSidebar,
-        ]),
+      html.tag('div', {class: 'layout-columns'}, [
+        leftSidebar,
+        mainHTML,
+        rightSidebar,
+      ]),
 
       slots.bannerPosition === 'bottom' &&
         slots.banner,