ugh come ON
This commit is contained in:
parent
84aaec63a0
commit
68ad4e4bcd
1 changed files with 44 additions and 0 deletions
44
templates/toc.html
Normal file
44
templates/toc.html
Normal file
|
@ -0,0 +1,44 @@
|
||||||
|
{% extends "base.html" %}
|
||||||
|
|
||||||
|
{% block content %}
|
||||||
|
<h2>{{ page.title }}</h2>
|
||||||
|
|
||||||
|
{% if page.toc and page.extra.toc %}
|
||||||
|
<div class="toc-list">
|
||||||
|
<h3>Table of contents</h3>
|
||||||
|
<ul>
|
||||||
|
{% for h1 in page.toc %}
|
||||||
|
<li>
|
||||||
|
<a href="{{ h1.permalink | safe }}">{{ h1.title }}</a>
|
||||||
|
{% if h1.children %}
|
||||||
|
<ul>
|
||||||
|
{% for h2 in h1.children %}
|
||||||
|
<li>
|
||||||
|
<a href="{{ h2.permalink | safe }}">{{ h2.title }}</a>
|
||||||
|
<ul>
|
||||||
|
{% for h3 in h2.children %}
|
||||||
|
<li>
|
||||||
|
<a href="{{ h3.permalink | safe }}">{{ h3.title }}</a>
|
||||||
|
</li>
|
||||||
|
{% endfor %}
|
||||||
|
</ul>
|
||||||
|
</li>
|
||||||
|
{% endfor %}
|
||||||
|
</ul>
|
||||||
|
{% endif %}
|
||||||
|
</li>
|
||||||
|
{% endfor %}
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
{% endif %}
|
||||||
|
|
||||||
|
{{ page.content | safe }}
|
||||||
|
|
||||||
|
<p class="tagsData">
|
||||||
|
{% if page.taxonomies.tags %}
|
||||||
|
{% for tag in page.taxonomies.tags %}
|
||||||
|
<a href="/tags/{{ tag | slugify }}">/{{ tag }}/</a>
|
||||||
|
{% endfor %}
|
||||||
|
{% endif %}
|
||||||
|
</p>
|
||||||
|
{% endblock content %}
|
Loading…
Add table
Reference in a new issue