From fa76ae6b6318639b9d0eeeda52839c92d4d1b887 Mon Sep 17 00:00:00 2001 From: Mat Moore Date: Tue, 3 Apr 2018 16:44:05 +0100 Subject: [PATCH] Set title lang to match locale of content See https://github.com/alphagov/govuk_template/issues/342 Currently we set the html level lang to "en" and add a lang attribute to the "main" element with the locale of the content. This causes screen readers to interpret the page title in english. We should instead markup the title with the same langugage (both the title and main content are in the content item's language). --- app/views/layouts/application.html.erb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 0f0b25d48..c414c46d6 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -1,7 +1,7 @@ - + <title lang="<%= I18n.locale %>"> <%if content_for?(:title) %> <%= yield :title %> - GOV.UK <% else %>