From edd9c2ec3e1317ffcb7b154623edc8b658e97c7d Mon Sep 17 00:00:00 2001 From: Kat Date: Mon, 30 May 2022 12:23:05 +0100 Subject: [PATCH] FIx more styling --- app/views/users/show.html.erb | 20 ++++++++++---------- app/views/users/toggle-active.html.erb | 2 +- 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/app/views/users/show.html.erb b/app/views/users/show.html.erb index 9a32b8ea1..3c274e1a7 100644 --- a/app/views/users/show.html.erb +++ b/app/views/users/show.html.erb @@ -5,17 +5,17 @@

<%= content_for(:title) %>

- <% if current_user.can_toggle_active?(@user) %> - <% if @user.active? %> - <%= govuk_link_to "Deactivate user", "/users/#{@user.id}/deactivate" %> - <% else %> -

- - This user has been deactivated. <%= govuk_link_to "Reactivate user", "/users/#{@user.id}/reactivate" %> - -

+

+ <% if current_user.can_toggle_active?(@user) %> + <% if @user.active? %> + <%= govuk_link_to "Deactivate user", "/users/#{@user.id}/deactivate" %> + <% else %> + + This user has been deactivated. <%= govuk_link_to "Reactivate user", "/users/#{@user.id}/reactivate" %> + + <% end %> <% end %> - <% end %> +

Personal details diff --git a/app/views/users/toggle-active.html.erb b/app/views/users/toggle-active.html.erb index c2db46430..eaee4881d 100644 --- a/app/views/users/toggle-active.html.erb +++ b/app/views/users/toggle-active.html.erb @@ -16,7 +16,7 @@ <%= f.govuk_text_field :active, value: active_value %> - <%= f.govuk_submit "I’m sure - #{action} this user" %> + <%= f.govuk_submit "I’m sure - #{action} this user", warning: action == "deactivate" %>

<%= govuk_link_to("No - I’ve changed my mind", user_path(@user)) %>