docs/templates/section.html

36 lines
1 KiB
HTML
Raw Permalink Normal View History

{% extends "index.html" %}
{% block title %} {{ config.title }} | {{ section.title }} {% endblock title %}
{% block content %}
{% if section.word_count > 0 -%}
2022-06-03 06:56:31 +05:30
{{ section.content | safe }}
{% else -%}
<h2 class="title"> {{ section.title }} </h2>
2022-06-03 06:55:00 +05:30
{% if section.subsections -%}
<h3>Subsections:</h3>
<ul>
{% for subsec in section.subsections -%}
{% set sec_ = get_section(path=subsec) -%}
<li><a href="{{ sec_.permalink | safe }}{{ _ugly_url }}">{{ sec_.title }}</a></li>
2022-06-03 06:55:00 +05:30
{% endfor %}
</ul>
{% endif -%}
<h3>Pages:</h3>
<ul>
{% if section.pages -%}
{% for page in section.pages -%}
<li><a href="{{ page.permalink | safe }}{{ _ugly_url }}">{{ page.title }}</a></li>
{% endfor -%}
{% else -%}
<li>No pages</li>
{% endif %}
</ul>
{% endif -%}
{% endblock content %}