Skip to content

Commit

Permalink
Merge pull request #1056 from alphagov/fix-notice-spacing-consultations
Browse files Browse the repository at this point in the history
Fix spacing for notices in consultations
  • Loading branch information
Vanita Barrett authored Aug 16, 2018
2 parents 0956a2f + 36f1057 commit 1ef4036
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
4 changes: 4 additions & 0 deletions app/presenters/consultation_presenter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,10 @@ def attachment_url
ways_to_respond["attachment_url"]
end

def add_margin?
final_outcome? || public_feedback_detail || public_feedback_documents?
end

private

def display_date_and_time(date, rollback_midnight = false)
Expand Down
6 changes: 5 additions & 1 deletion app/views/content_items/consultation.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,11 @@
<% content_item_final_outcome = capture do %>
Visit this page again soon to download the outcome to this public&nbsp;feedback.
<% end %>
<%= render 'govuk_publishing_components/components/notice', title: 'We are analysing your feedback', description_text: content_item_final_outcome, margin_bottom: 0 %>
<%= render 'govuk_publishing_components/components/notice',
title: 'We are analysing your feedback',
description_text: content_item_final_outcome,
margin_bottom:(0 unless @content_item.add_margin?)
%>

<% elsif @content_item.final_outcome? %>
<%= render 'govuk_publishing_components/components/notice', title: 'This consultation has concluded' %>
Expand Down

0 comments on commit 1ef4036

Please sign in to comment.