# File lib/simple_form/inputs/base.rb, line 37 def initialize(builder, attribute_name, column, input_type, options = {}) @builder = builder @attribute_name = attribute_name @column = column @input_type = input_type @reflection = options.delete(:reflection) @options = options @required = calculate_required @input_html_options = html_options_for(:input, input_html_classes).tap do |o| o[:required] = true if has_required? o[:disabled] = true if disabled? o[:autofocus] = true if has_autofocus? && SimpleForm.html5 end end