Replace all existing back-links with component

Includes:
- all existing macros
- all imports for the existing macros
This commit is contained in:
Tom Byers
2019-11-29 09:02:16 +00:00
parent ff53b9f34f
commit e5bc33be84
5 changed files with 16 additions and 20 deletions

View File

@@ -1,19 +1,14 @@
{% from "components/back-link/macro.njk" import govukBackLink %}
{% macro page_header(
h1,
back_link=None
) %}
{% if back_link %}
{{ govuk_back_link(back_link) }}
{{ govukBackLink({ "href": back_link }) }}
{% endif %}
<h1 class="heading-large">{{ h1 }}</h1>
{% endmacro %}
{% macro govuk_back_link(back_link) %}
<a class="govuk-back-link" href="{{ back_link }}">Back</a>
{% endmacro %}