Created
October 22, 2013 11:43
-
-
Save thisislawatts/7099166 to your computer and use it in GitHub Desktop.
Remove hardcoded dependency on 'Catalog'
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- Full navigation | |
============================================= --> | |
<nav class="full {{ settings.mobile-navigation-colour-scheme }}"> | |
<!-- Main nav | |
++++++++++++++++++++++++++++ --> | |
<ul> | |
{% for link in linklists.main-menu.links %}<li class="nav-item {% include 'for-looper' %} {% if link.title == settings.catalog-label-override and settings.enable-mega-nav %}has-mega-nav{% endif %} {% capture link_handle %}{{ link.title | handle }}{% endcapture %} {% if linklists[link_handle] and linklists[link_handle].links.size > 0 %}dropdown{% endif %}"> | |
{% assign meganav = false %} | |
{% if link.title == settings.catalog-label-override and settings.enable-mega-nav %} {% assign meganav = true %} {% endif %} | |
{% assign dropdown = false %} | |
{% if meganav == false and linklists[link_handle] and linklists[link_handle].links.size > 0 %} {% assign dropdown = true %} {% endif %} | |
{% if dropdown or meganav %}<span class="border"></span>{% endif %} | |
<a class="label" href="{{ link.url }}">{{ link.title }}{% if dropdown or meganav %}<span class="icon"><</span>{% endif %}</a> | |
{% if dropdown %} | |
<!-- Simple dropdown: primary | |
++++++++++++++++++++++++++++ --> | |
<ul class="dropdown-wrap primary"> | |
{% for link_primary in linklists[link_handle].links %} | |
{% capture link_handle_primary %}{{ link_primary.title | handle }}{% endcapture %} | |
{% assign dropdown = false %} | |
{% if linklists[link_handle_primary] and linklists[link_handle_primary].links.size > 0 %} {% assign dropdown = true %} {% endif %} | |
<li class="dropdown-item {% include 'for-looper' %}"> | |
<a href="{{ link_primary.url }}"><span class="label">{{ link_primary.title }}</span>{% if dropdown %}<span class="icon">></span>{% endif %}</a> | |
{% if dropdown %} | |
<!-- Simple dropdown: secondary | |
++++++++++++++++++++++++++++ --> | |
<ul class="dropdown-wrap child secondary right"> | |
{% for link_secondary in linklists[link_handle_primary].links %} | |
{% capture link_handle_secondary %}{{ link_secondary.title | handle }}{% endcapture %} | |
{% assign dropdown = false %} | |
{% if linklists[link_handle_secondary] and linklists[link_handle_secondary].links.size > 0 %} {% assign dropdown = true %} {% endif %} | |
<li class="dropdown-item {% include 'for-looper' %}"> | |
<a href="{{ link_secondary.url }}"><span class="label">{{ link_secondary.title }}</span>{% if dropdown %}<span class="icon">></span>{% endif %}</a> | |
{% if dropdown %} | |
<!-- Simple dropdown: tertiary | |
++++++++++++++++++++++++++++ --> | |
<ul class="dropdown-wrap child tertiary right"> | |
{% for link_tertiary in linklists[link_handle_secondary].links %} | |
<li class="dropdown-item {% include 'for-looper' %}"><a href="{{ link_tertiary.url }}"><span class="label">{{ link_tertiary.title }}</span></a></li> | |
{% endfor %} | |
</ul> | |
<!-- ++++++++++++++++++++++++++++ --> | |
{% endif %} | |
</li> | |
{% endfor %} | |
</ul> | |
<!-- ++++++++++++++++++++++++++++ --> | |
{% endif %} | |
</li> | |
{% endfor %} | |
</ul> | |
<!-- ++++++++++++++++++++++++++++ --> | |
{% endif %} | |
</li>{% endfor %} | |
</ul> | |
<!-- ++++++++++++++++++++++++++++ --> | |
</nav> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment