5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-07-03 06:56:08 +00:00

siempre faltan cinco para el ser

This commit is contained in:
f 2020-08-03 17:13:53 -03:00
parent 09b8e50545
commit 036ac78690

View file

@ -0,0 +1,9 @@
# Adaptar la renderización de campos con error de Rails para que sea
# compatible con Bootstrap4. La forma actual rompe los inputs
# personalizados.
ActionView::Base.field_error_proc = proc do |html_tag, _|
html = Nokogiri::HTML::DocumentFragment.parse html_tag
html.children.first.attributes['class'].value += ' is-invalid'
html.to_s.html_safe
end