Merge pull request #2984 from alphagov/fix-double-heading-letter-branding

Fix duplicated H1 on ‘New letter branding’ page
This commit is contained in:
Chris Hill-Scott
2019-05-23 10:36:08 +01:00
committed by GitHub
5 changed files with 14 additions and 11 deletions

View File

@@ -3,9 +3,10 @@
service_id,
template_type,
current_user,
link_current_item=False
link_current_item=False,
root_element='h1'
) %}
<h1 class="heading-medium folder-heading">
<{{ root_element }} class="heading-medium folder-heading">
{% for folder in folders %}
{% if loop.last and not link_current_item %}
{% if folder.template_type or not folder.id %}
@@ -26,7 +27,7 @@
{% if not loop.last %}{{ folder_path_separator() }}{% endif %}
{% endif %}
{% endfor %}
</h1>
</{{ root_element }}>
{% endmacro %}

View File

@@ -11,7 +11,6 @@
{% block platform_admin_content %}
<h1 class="heading-large">{{ '{} letter branding'.format('Update' if is_update else 'Add')}}</h1>
{{ page_header(
'{} letter branding'.format('Update' if is_update else 'Add'),
back_link=url_for('main.letter_branding')

View File

@@ -14,7 +14,7 @@
<div class="bottom-gutter-1-2">
<h1 class="heading-large">Choose a template</h1>
{{ folder_path(template_folder_path, current_service.id, template_type, current_user) }}
{{ folder_path(template_folder_path, current_service.id, template_type, current_user, root_element='h2') }}
</div>
{% if not templates_and_folders.templates_to_show %}