Fallback to page.id if no page.title

- Fix for #4.
- Hiding pages without titles wasn't really an intended behavior.
This commit is contained in:
Maya McDougall 2021-11-09 09:28:48 -05:00
parent 780b9484f1
commit 7eabd4cfb9

View File

@ -43,9 +43,9 @@
</div> </div>
<div id="nav" role="navigation" tabindex="-1"> <div id="nav" role="navigation" tabindex="-1">
<ul> <ul>
{% for page in pages(depthOffset=-1) if page.title and not page.hidden %} {% for page in pages(depthOffset=-1) if not page.hidden %}
<li{% if page.id == current_page.id %} class="active"{% endif %}> <li{% if page.id == current_page.id %} class="active"{% endif %}>
<a href="{{ page.url }}">{{ page.title }}</a> <a href="{{ page.url }}">{{ page.title ?: page.id }}</a>
</li> </li>
{% endfor %} {% endfor %}
</ul> </ul>