Skip to content

Commit

Permalink
v5.5 updates
Browse files Browse the repository at this point in the history
  • Loading branch information
matthew-shaw committed Aug 27, 2024
1 parent 1a1ba3a commit c6555e7
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{% macro govukBackLink(params) %}
{% from "govuk_frontend_jinja/macros/attributes.html" import govukAttributes -%}

<a href="{% if params.href %}{{ params.href }}{% else %}#{% endif %}" class="govuk-back-link {%- if params.classes %} {{ params.classes }}{% endif %}"
<a href="{{ params.href | default('#', true) }}" class="govuk-back-link {%- if params.classes %} {{ params.classes }}{% endif %}"
{{- govukAttributes(params.attributes) }}>
{{- params.html | safe if params.html else (params.text if params.text else "Back") -}}
{{- params.html | safe if params.html else (params.text | default("Back", true)) -}}
</a>
{% endmacro %}
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
{% set classNames = classNames ~ " govuk-breadcrumbs--collapse-on-mobile" %}
{% endif -%}

<div class="{{ classNames }}" {{- govukAttributes(params.attributes) }}>
<nav class="{{ classNames }}" {{- govukAttributes(params.attributes) }} aria-label="{{ params.labelText | default("Breadcrumb") }}">
<ol class="govuk-breadcrumbs__list">
{% for item in params['items'] %}
{% if item.href %}
Expand All @@ -28,5 +28,5 @@
{% endif %}
{% endfor %}
</ol>
</div>
</nav>
{% endmacro %}
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
<ul class="govuk-task-list {%- if params.classes %} {{ params.classes }}{% endif %}"
{{- govukAttributes(params.attributes) }}>
{% for item in params['items'] %}
{{- _taskListItem(params, item, loop.index) }}
{{- _taskListItem(params, item, loop.index) if item }}
{% endfor %}
</ul>
{% endmacro %}

0 comments on commit c6555e7

Please sign in to comment.