Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Block search engines and remove redundant <main> element from error pages #795

Merged
merged 2 commits into from
Sep 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 4 additions & 8 deletions templates/400.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,10 @@

{% block content %}

<div class="govuk-width-container">
<main class="govuk-main-wrapper govuk-main-wrapper--l" id="main-content" role="main">
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
</div>
</div>
</main>
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
</div>
</div>

{% endblock content %}
24 changes: 10 additions & 14 deletions templates/404.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,16 @@

{% block content %}

<div class="govuk-width-container">
<main class="govuk-main-wrapper govuk-main-wrapper--l" id="main-content" role="main">
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
<p class="govuk-body">
{% translate "If you typed the web address, check it is correct." %}
</p>
<p class="govuk-body">
{% translate "If you pasted the web address, check you copied the entire address." %}
</p>
</div>
</div>
</main>
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
<p class="govuk-body">
{% translate "If you typed the web address, check it is correct." %}
</p>
<p class="govuk-body">
{% translate "If you pasted the web address, check you copied the entire address." %}
</p>
</div>
</div>

{% endblock content %}
20 changes: 8 additions & 12 deletions templates/500.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,14 @@

{% block content %}

<div class="govuk-width-container">
<main class="govuk-main-wrapper govuk-main-wrapper--l" id="main-content" role="main">
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
<p class="govuk-body">
{% translate "There is a problem with the server." %}
</p>
{% include "partial/contact_team.html" %}
</div>
</div>
</main>
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
<p class="govuk-body">
{% translate "There is a problem with the server." %}
</p>
{% include "partial/contact_team.html" %}
</div>
</div>

{% endblock content %}
21 changes: 8 additions & 13 deletions templates/500_datahub_unavailable.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,14 @@
{% load static %}

{% block content %}

<div class="govuk-width-container">
<main class="govuk-main-wrapper govuk-main-wrapper--l" id="main-content" role="main">
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
<p class="govuk-body">
{% translate "The DataHub catalogue is currently unavailable. Please try again in a few minutes." %}
</p>
{% include "partial/contact_team.html" %}
</div>
</div>
</main>
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<h1 class="govuk-heading-l">{{h1_value}}</h1>
<p class="govuk-body">
{% translate "The DataHub catalogue is currently unavailable. Please try again in a few minutes." %}
</p>
{% include "partial/contact_team.html" %}
</div>
</div>

{% endblock content %}
2 changes: 2 additions & 0 deletions templates/base/head.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{% load static %}
{% load page_title %}

<head>
<meta charset="utf-8">
<title>{{h1_value|render_title}}</title>
Expand All @@ -12,4 +13,5 @@
<link rel="manifest" href="{% static 'assets/manifest.json' %}">
<link rel="stylesheet" type="text/css" href="{% static 'assets/css/base.css' %}">
<meta property="og:image" content="{% static 'assets/images/govuk-opengraph-image.png' %}">
<meta name="robots" content="noindex, nofollow" />
</head>