From 281a17ff707b68989efd76e2ce186c1a78f5f04c Mon Sep 17 00:00:00 2001 From: Alan Cruikshanks Date: Wed, 1 Apr 2020 16:22:26 +0100 Subject: [PATCH] Fix W3C fail with tel. no. on reg. complete page (#770) https://eaflood.atlassian.net/browse/RUBY-918 During the QA of adding a new registration completion page we spotted a W3C validation error being reported. Specifically it doesn't like that there are spaces in the `tel:` attribute of the **href** element we use to display NCCC's telephone number. This fix resolves the issue. --- .../registration_completed_forms/new.html.erb | 2 +- config/locales/forms/registration_completed_forms/en.yml | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/app/views/waste_carriers_engine/registration_completed_forms/new.html.erb b/app/views/waste_carriers_engine/registration_completed_forms/new.html.erb index cda07fc9d..475e75fcd 100644 --- a/app/views/waste_carriers_engine/registration_completed_forms/new.html.erb +++ b/app/views/waste_carriers_engine/registration_completed_forms/new.html.erb @@ -30,7 +30,7 @@

<%= t(".telephone.heading") %>
- "><%= t(".telephone.value") %> + "><%= t(".telephone.value.display") %>

<%= t(".subheading_3") %>

diff --git a/config/locales/forms/registration_completed_forms/en.yml b/config/locales/forms/registration_completed_forms/en.yml index d30fe8b83..45758dbcd 100644 --- a/config/locales/forms/registration_completed_forms/en.yml +++ b/config/locales/forms/registration_completed_forms/en.yml @@ -20,7 +20,9 @@ en: value: "nccc-carrierbroker@environment-agency.gov.uk" telephone: heading: "Telephone" - value: "03708 506 506" + value: + display: "03708 506 506" + href: "03708506506" subheading_2: "If your details change" paragraph_2: "If any of the details you've given us change, you must update them within 28 days by contacting the Environment Agency." subheading_3: "Registration checks"