From 1f7a8d71912077df2df5f658c48398c419379a54 Mon Sep 17 00:00:00 2001 From: Jake Lee Date: Thu, 14 Mar 2024 19:18:56 +0000 Subject: [PATCH] Adds ToC default to collapsed option --- _includes/custom/contents.html | 8 ++++++-- _includes/footer.html | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/_includes/custom/contents.html b/_includes/custom/contents.html index fe669c0..a94759d 100644 --- a/_includes/custom/contents.html +++ b/_includes/custom/contents.html @@ -170,8 +170,12 @@ {% assign nodes = jekyll_toc | split: '>' %} {% capture jekyll_toc %}
- {%- if site.table_of_contents_collapsible != false -%} -
+ {%- if site.table_of_contents_collapsible != false %} + {%- if page.table_of_contents_collapsed != false -%} +
+ {%- else %} +
+ {%- endif -%} {%- endif- %} {{ site.table_of_contents_header }} <{{ listModifier }}{{ rootAttributes }}>{{ nodes | shift | join: '>' }}> diff --git a/_includes/footer.html b/_includes/footer.html index 7f800ef..8c38ed6 100644 --- a/_includes/footer.html +++ b/_includes/footer.html @@ -10,7 +10,7 @@