Skip to content

Commit

Permalink
Move TOC header to TOC generation
Browse files Browse the repository at this point in the history
Will this remove the header from TOC-less pages?
  • Loading branch information
snomos committed Sep 3, 2024
1 parent ef64537 commit e589dfd
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 1 deletion.
1 change: 1 addition & 0 deletions _includes/toc.html
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@
{% endfor %}

{% if jekyll_toc != '' %}
<h2 class="tocheader">Page Content</h2>
{% assign rootAttributes = '' %}
{% if include.class and include.class != blank %}
{% capture rootAttributes %} class="{{ include.class | split: '.' | join: ' ' }}"{% endcapture %}
Expand Down
1 change: 0 additions & 1 deletion _layouts/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ <h1><a href="{{ "/" | absolute_url }}">{{ site.title | default: site.github.repo
<li><a href="{{ site.github.repository_url }}">View On <strong>GitHub</strong></a></li>
</ul>
{% endif %}
<h2 class="tocheader">Page Content</h2>
{% include toc.html html=content sanitize=true class="left_toc" id="left_toc" h_min=2 %}
</header>
<section>
Expand Down

0 comments on commit e589dfd

Please sign in to comment.