mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-11 10:28:41 -04:00
Merge pull request #3717 from alphagov/fix-nesting-in-content-page-sub-nav
Fix nesting in content page sub nav
This commit is contained in:
@@ -179,6 +179,12 @@
|
|||||||
list-style: none;
|
list-style: none;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
|
|
||||||
|
ol,
|
||||||
|
ul {
|
||||||
|
margin-top: govuk-spacing(2);
|
||||||
|
border-top: 1px $grey-3 solid;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
&__item {
|
&__item {
|
||||||
@@ -199,6 +205,11 @@
|
|||||||
|
|
||||||
ol ol & {
|
ol ol & {
|
||||||
padding-left: govuk-spacing(6);
|
padding-left: govuk-spacing(6);
|
||||||
|
|
||||||
|
&:last-of-type {
|
||||||
|
border-bottom: none;
|
||||||
|
padding-bottom: 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -7,22 +7,32 @@
|
|||||||
<a class="govuk-link govuk-link--no-visited-state" href="{{ url_for(item['link']) }}" itemprop="item">
|
<a class="govuk-link govuk-link--no-visited-state" href="{{ url_for(item['link']) }}" itemprop="item">
|
||||||
<span itemprop="name">{{item['name']}}</span>
|
<span itemprop="name">{{item['name']}}</span>
|
||||||
</a>
|
</a>
|
||||||
|
{% if caller %}
|
||||||
|
{{ caller() }}
|
||||||
|
{% endif %}
|
||||||
</li>
|
</li>
|
||||||
{% endmacro %}
|
{% endmacro %}
|
||||||
|
|
||||||
|
{% macro sub_navigation_item_sub_navigation(item) %}
|
||||||
|
<ol itemscope itemtype="http://schema.org/ItemList">
|
||||||
|
{% for sub_item in item.sub_navigation_items %}
|
||||||
|
{{ sub_navigation_item(sub_item) }}
|
||||||
|
{% endfor %}
|
||||||
|
</ol>
|
||||||
|
{% endmacro %}
|
||||||
|
|
||||||
{% macro sub_navigation(
|
{% macro sub_navigation(
|
||||||
item_set
|
item_set
|
||||||
) %}
|
) %}
|
||||||
<nav class="sub-navigation">
|
<nav class="sub-navigation">
|
||||||
<ol itemscope itemtype="http://schema.org/ItemList">
|
<ol itemscope itemtype="http://schema.org/ItemList">
|
||||||
{% for item in item_set %}
|
{% for item in item_set %}
|
||||||
{{ sub_navigation_item(item) }}
|
|
||||||
{% if item.sub_navigation_items %}
|
{% if item.sub_navigation_items %}
|
||||||
<ol itemscope itemtype="http://schema.org/ItemList">
|
{% call sub_navigation_item(item) %}
|
||||||
{% for sub_item in item.sub_navigation_items %}
|
{{ sub_navigation_item_sub_navigation(item) }}
|
||||||
{{ sub_navigation_item(sub_item) }}
|
{% endcall %}
|
||||||
{% endfor %}
|
{% else %}
|
||||||
</ol>
|
{{ sub_navigation_item(item) }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</ol>
|
</ol>
|
||||||
|
|||||||
Reference in New Issue
Block a user