mirror of
https://github.com/snachodog/just-the-docs.git
synced 2025-04-22 02:52:23 -06:00
Merge pull request #282 from blawqchain/patch-1
Update nav.html for handling nav_exclude
This commit is contained in:
commit
8d54896986
@ -13,6 +13,7 @@
|
|||||||
{%- assign children_list = site.html_pages | where: "parent", node.title | sort:"nav_order" -%}
|
{%- assign children_list = site.html_pages | where: "parent", node.title | sort:"nav_order" -%}
|
||||||
<ul class="navigation-list-child-list ">
|
<ul class="navigation-list-child-list ">
|
||||||
{%- for child in children_list -%}
|
{%- for child in children_list -%}
|
||||||
|
{%- unless child.nav_exclude -%}
|
||||||
<li class="navigation-list-item {% if page.url == child.url or page.parent == child.title %} active{% endif %}">
|
<li class="navigation-list-item {% if page.url == child.url or page.parent == child.title %} active{% endif %}">
|
||||||
{%- if page.url == child.url or page.parent == child.title -%}
|
{%- if page.url == child.url or page.parent == child.title -%}
|
||||||
{%- assign second_level_url = child.url | absolute_url -%}
|
{%- assign second_level_url = child.url | absolute_url -%}
|
||||||
@ -22,13 +23,16 @@
|
|||||||
{%- assign grand_children_list = site.html_pages | where: "parent", child.title | sort:"nav_order" -%}
|
{%- assign grand_children_list = site.html_pages | where: "parent", child.title | sort:"nav_order" -%}
|
||||||
<ul class="navigation-list-child-list">
|
<ul class="navigation-list-child-list">
|
||||||
{%- for grand_child in grand_children_list -%}
|
{%- for grand_child in grand_children_list -%}
|
||||||
|
{%- unless grand_child.nav_exclude -%}
|
||||||
<li class="navigation-list-item {% if page.url == grand_child.url %} active{% endif %}">
|
<li class="navigation-list-item {% if page.url == grand_child.url %} active{% endif %}">
|
||||||
<a href="{{ grand_child.url | absolute_url }}" class="navigation-list-link{% if page.url == grand_child.url %} active{% endif %}">{{ grand_child.title }}</a>
|
<a href="{{ grand_child.url | absolute_url }}" class="navigation-list-link{% if page.url == grand_child.url %} active{% endif %}">{{ grand_child.title }}</a>
|
||||||
</li>
|
</li>
|
||||||
|
{%- endunless -%}
|
||||||
{%- endfor -%}
|
{%- endfor -%}
|
||||||
</ul>
|
</ul>
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
</li>
|
</li>
|
||||||
|
{%- endunless -%}
|
||||||
{%- endfor -%}
|
{%- endfor -%}
|
||||||
</ul>
|
</ul>
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user