Skip to content

Commit

Permalink
change side nav heading structure (#231)
Browse files Browse the repository at this point in the history
  • Loading branch information
davidhunter08 authored Jan 23, 2025
1 parent 902a817 commit 43163f5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions docs/_includes/layouts/partials/side-navigation.njk
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
{% macro appSideNavigation(params) %}
<nav class="app-side-navigation {{- ' ' + params.classes if params.classes }}" {%- if (params.label) %} aria-label="{{ params.label }}"{% endif %} {% for attribute, value in params.attributes %} {{ attribute }}="{{ value }}"{% endfor %}>
<h2 class="nhsuk-u-visually-hidden">Pages in this section</h2>
{%- if params.sections %}
{%- for section in params.sections %}
<h{{ section.heading.headingLevel | default(4) }} class="app-side-navigation__title {{- ' ' + section.heading.classes if section.heading.classes }}"{% for attribute, value in section.heading.attributes %} {{ attribute }}="{{ value }}"{% endfor %}>
<h{{ section.heading.headingLevel | default(3) }} class="app-side-navigation__title {{- ' ' + section.heading.classes if section.heading.classes }}"{% for attribute, value in section.heading.attributes %} {{ attribute }}="{{ value }}"{% endfor %}>
{{- section.heading.html | safe if section.heading.html else section.heading.text -}}
</h{{ section.heading.headingLevel | default(4) }}>
</h{{ section.heading.headingLevel | default(3) }}>
<ul class="app-side-navigation__list">
{%- for item in section.items %}
{% include "./side-navigation-item.njk" %}
Expand Down

0 comments on commit 43163f5

Please sign in to comment.