Don’t allow paragraphs without class attribute

All paragraphs should have class="govuk-body", or be otherwise
custom-styled. This commit adds some extra checks to our test fixture
that looks for paragraphs that don’t have any styling. Our test coverage
is pretty good, so this should check almost all pages, and prevent
regressions.

I’ve done this in such a way that it can be extended for other elements
(e.g. links) in the future.
This commit is contained in:
Chris Hill-Scott
2020-05-29 17:11:01 +01:00
parent 82ec03e263
commit 4df99bd27f
134 changed files with 517 additions and 497 deletions

View File

@@ -7,9 +7,9 @@
{% block content_column_content %}
<h1 class="heading-large">Documentation</h1>
<p>This documentation is for developers who want to integrate the GOV.UK Notify API with a web application or back office system.</p>
<p class="govuk-body">This documentation is for developers who want to integrate the GOV.UK Notify API with a web application or back office system.</p>
<h2 class="heading-medium">Client libraries</h2>
<p>Links to documentation open in a new tab.</p>
<p class="govuk-body">Links to documentation open in a new tab.</p>
<ul class="list list-bullet">
{% for key, label in [
('java', 'Java'),
@@ -22,9 +22,9 @@
<li><a class="govuk-link govuk-link--no-visited-state" href="https://docs.notifications.service.gov.uk/{{ key }}.html" target="_blank" rel="noopener">{{ label }}</a></li>
{% endfor %}
</ul>
<p>A developer should be able to set up the API client and start sending test messages in around 30 minutes. A full integration can take a few days, depending on the other systems youre using.</p>
<p class="govuk-body">A developer should be able to set up the API client and start sending test messages in around 30 minutes. A full integration can take a few days, depending on the other systems youre using.</p>
<h2 class="heading-medium">Integrate directly with the API</h2>
<p>If you cannot use the client libraries, you can integrate directly with the API instead.</p>
<p>Read the <a class="govuk-link govuk-link--no-visited-state" href="https://docs.notifications.service.gov.uk/rest-api.html" target="_blank" rel="noopener">REST API documentation</a> (this link opens in a new tab).</p>
<p class="govuk-body">If you cannot use the client libraries, you can integrate directly with the API instead.</p>
<p class="govuk-body">Read the <a class="govuk-link govuk-link--no-visited-state" href="https://docs.notifications.service.gov.uk/rest-api.html" target="_blank" rel="noopener">REST API documentation</a> (this link opens in a new tab).</p>
{% endblock %}