nav.html 1.4 KB

12345678910111213141516171819202122232425262728293031323334
  1. {% include base.html %}
  2. <nav class="row navbar" role="navigation">
  3. <!-- Brand and toggle get grouped for better mobile display -->
  4. <div class="navbar-header">
  5. <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#jb-navbar-collapse">
  6. <span class="sr-only">Toggle navigation</span>
  7. <span class="icon-bar"></span>
  8. <span class="icon-spacer"></span>
  9. <span class="icon-bar"></span>
  10. <span class="icon-spacer"></span>
  11. <span class="icon-bar"></span>
  12. <span class="icon-spacer"></span>
  13. <br/>
  14. </button>
  15. </div>
  16. <!-- Collect the nav links, forms, and other content for toggling -->
  17. <div class="collapse navbar-collapse" id="jb-navbar-collapse">
  18. <ul class="nav navbar-nav">
  19. {% assign sorted_pages = site.pages | sort:"order" %}
  20. {% for node in sorted_pages %}
  21. {% if node.group == "navigation" %}
  22. {% unless node.exclude_from_nav %}
  23. {% if page.url == node.url %}
  24. <li class="active"><a href="{{ base }}{{node.url}}" class="active">{{node.title}}</a></li>
  25. {% else %}
  26. <li><a href="{{ base }}{{node.url}}">{{node.title}}</a></li>
  27. {% endif %}
  28. {% endunless %}
  29. {% endif %}
  30. {% endfor %}
  31. </ul>
  32. </div><!-- /.navbar-collapse -->
  33. </nav>