Feat: expand sidebar on category index
This commit is contained in:
parent
548aecf9e3
commit
c7ecf06733
@ -1,7 +1,7 @@
|
|||||||
<ul class="toctree">
|
<ul class="toctree">
|
||||||
{% for cat, articles in categories|sort %}
|
{% for cat, articles in categories|sort %}
|
||||||
{% if article and article.category == cat %}
|
{% if (article and article.category == cat) or category == cat %}
|
||||||
<li class="toctree-l1 current"><a href="{{ SITEURL }}/{{ cat.url }}">{{ cat | capitalize }}</a>
|
<li class="toctree-l1 current"><a href="{{ SITEURL }}/{{ cat.url }}">{{ cat | upper }}</a>
|
||||||
<ul>
|
<ul>
|
||||||
{% for art in articles | sort(attribute="date") %}
|
{% for art in articles | sort(attribute="date") %}
|
||||||
{% if article == art %}
|
{% if article == art %}
|
||||||
@ -13,7 +13,7 @@
|
|||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
{% else %}
|
{% else %}
|
||||||
<li class="toctree-l1"><a href="{{ SITEURL }}/{{ cat.url }}">{{ cat | capitalize }}</a>
|
<li class="toctree-l1"><a href="{{ SITEURL }}/{{ cat.url }}">{{ cat | upper }}</a>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</ul>
|
</ul>
|
||||||
|
Loading…
Reference in New Issue
Block a user