From bcbc033710812ed9f7639d5460100b2cf2bb3d63 Mon Sep 17 00:00:00 2001 From: Andy Sellick Date: Tue, 14 Nov 2023 13:26:03 +0000 Subject: [PATCH] Fix phase banner left/right spacing on some pages - below the tablet breakpoint (around 1020px) the phase banner at the top of some pages was being padded left and right, which indented it from the rest of the page - caused by the govuk-frontend grid wrapping classes, which were unnecessary - some wrapping divs moved instead to support the phase label, which is similar but does require additional wrapping elements --- app/views/layouts/application.html.erb | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index dd02409d1..a4d2c203c 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -6,18 +6,12 @@ <% content_for :body do %>
- <% if @content_item.show_phase_banner? || @content_item.service_manual? %> + <% if @content_item.show_phase_banner? %> + <%= render 'govuk_publishing_components/components/phase_banner', phase: @content_item.phase %> + <% end %> + <% if @content_item.service_manual? %>
-
-
- <% if @content_item.show_phase_banner? %> - <%= render 'govuk_publishing_components/components/phase_banner', phase: @content_item.phase %> - <% end %> - <% if @content_item.service_manual? %> - <%= render_phase_label @content_item, content_for(:phase_message) %> - <% end %> -
-
+ <%= render_phase_label @content_item, content_for(:phase_message) %>
<% end %>