funky/_includes/site-nav.html

17 lines
638 B
HTML
Executable File

<nav class="nav">
<ul class="list list--nav">
{% for item in site.pages %}
{% unless item.styles == true or item.url contains "/page" or item.url == "/404.html" %}
<li class="item item--nav{% if item[1] == page.url %} item--current{% endif %}">
{% if item.collectionpage %}
{% assign collectiondata = site.collections | where: "label", item.collectionpage | first %}
<a href="{{ item.url }}">{{ collectiondata.title }}</a>
{% else %}
<a href="{{ item.url }}">{{ item.title }}</a>
{% endif %}
</li>
{% endunless %}
{% endfor %}
</ul>
</nav>