app/helpers/binco/bootstrap_form_builder.rb in binco-3.1.1 vs app/helpers/binco/bootstrap_form_builder.rb in binco-3.1.2
- old
+ new
@@ -12,10 +12,12 @@
ERROR_PROC = Proc.new do |html_tag, instance|
if instance.respond_to?(:error_message) && instance.class.to_s != 'ActionView::Helpers::Tags::Label'
error_messages = instance.error_message.collect{ |error| "<div class=\"invalid-feedback\">#{error}</div>" }.join
- "<div class=\"field_with_errors\">#{html_tag} #{error_messages}</div>".html_safe
+ Rails.logger.debug html_tag.inspect
+
+ "#{html_tag.gsub(/class="/, 'class="is-invalid ')} #{error_messages}".html_safe
else
html_tag
end
end