site_opytex/theme/templates/partial/toctree.html
Bertrand Benjamin 6060a52717
All checks were successful
continuous-integration/drone/push Build is passing
Feat: filter article in pagetree.
If "Semaine" in tags, it does not show up
2020-12-05 06:53:01 +01:00

24 lines
813 B
HTML

<ul class="toctree">
{% for cat, articles in categories|sort %}
{% if (article and article.category == cat) or category == cat %}
<li class="toctree-l1 current"><a href="{{ SITEURL }}/{{ cat.url }}">{{ cat | upper }}</a>
<ul>
{% for art in articles | sort(attribute="date") %}
{% if "Semaine" not in art.tags%}
{% if article == art %}
<li class="toctree-l2 current"><span>{{ art.title }}</span></li>
{% else %}
<li class="toctree-l2"><a href="{{ SITEURL }}/{{ art.url }}">{{ art.title }}</a></li>
{% endif %}
{% endif %}
{% endfor %}
</ul>
</li>
{% else %}
<li class="toctree-l1"><a href="{{ SITEURL }}/{{ cat.url }}">{{ cat | upper }}</a>
{% endif %}
{% endfor %}
</ul>