diff --git a/app/views/csv_preview/malformed_csv.html.erb b/app/views/csv_preview/malformed_csv.html.erb
index 39ea5d9aca..7f75320cf4 100644
--- a/app/views/csv_preview/malformed_csv.html.erb
+++ b/app/views/csv_preview/malformed_csv.html.erb
@@ -39,7 +39,6 @@
font_size: "xl",
inverse: true,
margin_bottom: 8,
- margin_top: 8,
} %>
Updated <%= I18n.l(Time.zone.parse(@content_item["public_updated_at"]), format: "%-d %B %Y") %>
diff --git a/app/views/csv_preview/show.html.erb b/app/views/csv_preview/show.html.erb
index 1745446a4e..487c4e1211 100644
--- a/app/views/csv_preview/show.html.erb
+++ b/app/views/csv_preview/show.html.erb
@@ -39,7 +39,6 @@
font_size: "xl",
inverse: true,
margin_bottom: 8,
- margin_top: 8,
} %>
Updated <%= I18n.l(Time.zone.parse(@content_item["public_updated_at"]), format: "%-d %B %Y") %>
diff --git a/app/views/find_local_council/_base_page.html.erb b/app/views/find_local_council/_base_page.html.erb
index 44c739454c..3678a6c0bb 100644
--- a/app/views/find_local_council/_base_page.html.erb
+++ b/app/views/find_local_council/_base_page.html.erb
@@ -6,8 +6,12 @@
- <%= render "govuk_publishing_components/components/title", title: t('formats.local_transaction.find_council'),
- margin_top: 0 %>
+ <%= render "govuk_publishing_components/components/heading", {
+ text: t('formats.local_transaction.find_council'),
+ font_size: "xl",
+ margin_bottom: 8,
+ heading_level: 1,
+ } %>
<%= yield %>
diff --git a/app/views/roadmap/index.html.erb b/app/views/roadmap/index.html.erb
index 64bc344200..b690f67bb1 100644
--- a/app/views/roadmap/index.html.erb
+++ b/app/views/roadmap/index.html.erb
@@ -11,7 +11,12 @@
- <%= render "govuk_publishing_components/components/title", title: t('roadmap.hero.heading'), margin_top: 0 %>
+ <%= render "govuk_publishing_components/components/heading", {
+ text: t('roadmap.hero.heading'),
+ font_size: "xl",
+ margin_bottom: 8,
+ heading_level: 1,
+ } %>
<%= t('roadmap.hero.description') %>
diff --git a/app/views/shared/_base_page.html.erb b/app/views/shared/_base_page.html.erb
index 1c81a43eb0..e36c77bfde 100644
--- a/app/views/shared/_base_page.html.erb
+++ b/app/views/shared/_base_page.html.erb
@@ -3,10 +3,15 @@
>
- <%= render "govuk_publishing_components/components/title",
- context: local_assigns[:context],
- margin_top: 0,
- title: title %>
+ <% if local_assigns[:context] %>
+ <%= local_assigns[:context] %>
+ <% end %>
+ <%= render "govuk_publishing_components/components/heading", {
+ text: title,
+ font_size: "xl",
+ margin_bottom: 8,
+ heading_level: 1,
+ } %>
diff --git a/app/views/simple_smart_answers/_outcome.html.erb b/app/views/simple_smart_answers/_outcome.html.erb
index c95e68ad6c..c6160a2d91 100644
--- a/app/views/simple_smart_answers/_outcome.html.erb
+++ b/app/views/simple_smart_answers/_outcome.html.erb
@@ -16,13 +16,14 @@
data-module="ga4-auto-tracker"
data-ga4-auto="<%= ga4_attributes %>"
>
- <%= render "govuk_publishing_components/components/title", {
- context: content_item.title,
+ <% if content_item.title %>
+ <%= content_item.title %>
+ <% end %>
+ <%= render "govuk_publishing_components/components/heading", {
+ text: outcome.title,
font_size: "l",
margin_bottom: 4,
- margin_top: 0,
- average_title_length: "long",
- title: outcome.title,
+ heading_level: 1,
} %>
<% if outcome.body %>
diff --git a/spec/system/licence_transaction_spec.rb b/spec/system/licence_transaction_spec.rb
index 50587125c8..a66d5fd939 100644
--- a/spec/system/licence_transaction_spec.rb
+++ b/spec/system/licence_transaction_spec.rb
@@ -48,7 +48,7 @@
expect(page).to have_title("Licence to kill - GOV.UK", exact: true)
end
within("#content") do
- within(".gem-c-title") { expect(page).to have_title("Licence to kill") }
+ within("h1.gem-c-heading") { expect(page).to have_title("Licence to kill") }
within(".postcode-search-form") do
expect(page).to have_field("Enter a postcode")
expect(page).to have_css("button", text: "Find")
diff --git a/spec/system/place_spec.rb b/spec/system/place_spec.rb
index 1acbe6159b..a43e707ece 100644
--- a/spec/system/place_spec.rb
+++ b/spec/system/place_spec.rb
@@ -78,7 +78,7 @@
end
within("#content") do
- within(".gem-c-title") do
+ within("h1.gem-c-heading") do
expect(page).to have_title("Find a passport interview office")
end
diff --git a/spec/system/transaction_spec.rb b/spec/system/transaction_spec.rb
index 442d29a7c3..89369c75f5 100644
--- a/spec/system/transaction_spec.rb
+++ b/spec/system/transaction_spec.rb
@@ -43,7 +43,7 @@
end
within("#content") do
- within(".gem-c-title") { expect(page).to have_title("Carrots") }
+ within("h1.gem-c-heading") { expect(page).to have_title("Carrots") }
within(".article-container") do
within("section.intro") do
expect(page).to have_selector(".get-started-intro", text: "This is the introduction to carrots")
@@ -159,7 +159,7 @@
expect(page.status_code).to eq(200)
expect(page).to have_button_as_link("Start now", href: "http://cti-staging.voa.gov.uk/cti/inits.asp")
- within(".gem-c-title") do
+ within("h1.gem-c-heading") do
expect(page).to have_title("Check your Council Tax band (staging)")
end