module SimpleForm::Components::LabelInput
Public Instance Methods
label_input(wrapper_options = nil)
click to toggle source
# File lib/simple_form/components/label_input.rb, line 11 def label_input(wrapper_options = nil) if options[:label] == false deprecated_component(:input, wrapper_options) else deprecated_component(:label, wrapper_options) + deprecated_component(:input, wrapper_options) end end
Private Instance Methods
deprecated_component(namespace, wrapper_options)
click to toggle source
# File lib/simple_form/components/label_input.rb, line 21 def deprecated_component(namespace, wrapper_options) method = method(namespace) if method.arity.zero? SimpleForm.deprecator.warn(SimpleForm::CUSTOM_INPUT_DEPRECATION_WARN % { name: namespace }) method.call else method.call(wrapper_options) end end