This commit is contained in:
Daniel Hladek 2020-10-03 10:53:23 +02:00
parent b96c768ca3
commit 7b4a270078

View File

@ -11,10 +11,12 @@
{% if config.get('plugins.page-toc.active') or attribute(page.header, 'page-toc').active %} {% if config.get('plugins.page-toc.active') or attribute(page.header, 'page-toc').active %}
<div class="page-toc"> <div class="page-toc">
{% set table_of_contents = toc(page.content) %} {% if page.content is not empty %}
{% if table_of_contents is not empty %} {% set table_of_contents = toc(page.content) %}
<h4>Obsah</h4> {% if table_of_contents is not empty %}
{{ table_of_contents }} <h4>Obsah</h4>
{{ table_of_contents }}
{% endif %}
{% endif %} {% endif %}
</div> </div>
{% endif %} {% endif %}