Skip to content

Commit

Permalink
Replace strikethrough and use tag pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
CristinaRO committed Feb 14, 2024
1 parent 2f794b6 commit 35d09cb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
3 changes: 1 addition & 2 deletions app/helpers/api_users_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,7 @@ def truncate_access_token(token)
end

def api_user_name(user)
anchor_tag = link_to(user.name, edit_api_user_path(user), class: "govuk-link")
user.suspended? ? content_tag(:del, anchor_tag) : anchor_tag
link_to(user.name, edit_api_user_path(user), class: "govuk-link")
end

def application_list(user)
Expand Down
2 changes: 1 addition & 1 deletion app/views/api_users/index.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
text: application_list(user),
},
{
text: user.suspended? ? "Yes" : "No",
text: user.suspended? ? govuk_tag("Yes", "govuk-tag--grey") : govuk_tag("No", "govuk-tag--green"),
},
]
end,
Expand Down

0 comments on commit 35d09cb

Please sign in to comment.