Update taxonomylist partial template

This commit is contained in:
pmoreno.rodriguez 2024-05-15 15:49:04 +02:00
parent 2b75b91297
commit a4ae56c25d
2 changed files with 23 additions and 22 deletions

View file

@ -37,17 +37,8 @@
{% include 'partials/relatedpages.html.twig' %}
</div>
{% endif %}
{% if config.plugins.taxonomylist.enabled %}
{% set taxlist = children_only is defined ? taxonomylist.getChildPagesTags() : taxonomylist.get() %}
{% if taxlist %}
<!-- Taxonomy list -->
<div class="sidebar-content">
<header>
<h3>{{ 'FUTURE.SIDEBAR.TAGS.HEADLINE'|t }}</h3>
</header>
{% include 'partials/taxonomylist.html.twig' with {'base_url':new_base_url, 'taxonomy':'tag'} %}
</div>
{% endif %}
{% if config.plugins.taxonomylist.enabled and page.template == 'blog' %}
{% include 'partials/taxonomylist.html.twig' with {'base_url':new_base_url, 'taxonomy':'tag', children_only: true, of_page: page.blog} %}
{% endif %}
{% if config.plugins.feed.enabled %}
<!-- Syndicate -->
@ -73,7 +64,7 @@
</ul>
</div>
{% endif %}
{% if config.plugins.login.enabled and icon_login%}
{% if config.plugins.login.enabled and icon_login %}
<!-- Login button -->
<div>
<ul class="actions stacked">

View file

@ -1,3 +1,11 @@
<!-- Taxonomy list -->
{% set taxlist = children_only is defined ? taxonomylist.getChildPagesTags(of_page) : taxonomylist.get() %}
{% if taxlist %}
<div class="sidebar-content">
<header>
<h3>{{ 'FUTURE.SIDEBAR.TAGS.HEADLINE'|t }}</h3>
</header>
<ul class="menulink">
<li>
{% for tax,value in taxlist[taxonomy] %}
@ -8,3 +16,5 @@
{% endfor %}
</li>
</ul>
</div>
{% endif %}