Skip to content

Commit

Permalink
added error message styling
Browse files Browse the repository at this point in the history
  • Loading branch information
5andu committed Oct 27, 2023
1 parent b1ba43b commit 2805bb0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions app/views/devise/shared/_error_messages.html.erb
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<% if resource.errors.any? %>
<div id="error_explanation">
<h2>
<div id="error_explanation" class="bg-red-100 text-red-700 p-4 rounded mb-4">
<h2 class="font-semibold">
<%= I18n.t("errors.messages.not_saved",
count: resource.errors.count,
resource: resource.class.model_name.human.downcase)
%>
</h2>
<ul>
<ul class="list-disc pl-4">
<% resource.errors.full_messages.each do |message| %>
<li><%= message %></li>
<% end %>
Expand Down

0 comments on commit 2805bb0

Please sign in to comment.