mirror of
https://github.com/picocms/pico-theme.git
synced 2025-08-04 15:57:53 +02:00
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:
@@ -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>
|
||||||
|
Reference in New Issue
Block a user