improves consistency of error messages [#110]
This commit is contained in:
2
app/views/comments/_errors.html.erb
Normal file
2
app/views/comments/_errors.html.erb
Normal file
@@ -0,0 +1,2 @@
|
||||
<div><%= t("errors.messages.blank").capitalize %></div>
|
||||
|
||||
2
app/views/comments/new.js.erb
Normal file
2
app/views/comments/new.js.erb
Normal file
@@ -0,0 +1,2 @@
|
||||
var field_with_errors = "#js-comment-form-<%= dom_id(@parent) %> #comment_body";
|
||||
App.Comments.display_error(field_with_errors, "<%= j render('comments/errors') %>");
|
||||
Reference in New Issue
Block a user