Class: BootsyInput
- Inherits:
-
SimpleForm::Inputs::Base
- Object
- SimpleForm::Inputs::Base
- BootsyInput
- Defined in:
- lib/bootsy/simple_form/bootsy_input.rb
Overview
Public: A SimpleForm Input to wrap Bootsy areas
Instance Method Summary collapse
Instance Method Details
#input(wrapper_options = nil) ⇒ Object
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/bootsy/simple_form/bootsy_input.rb', line 8 def input( = nil) bootsy_params = [:editor_options, :container, :uploader] .merge!( .select { |key, _| bootsy_params.include?(key) } ) # Check presence of `merge_wrapper_options` to keep # compatibility with both Simple Form 3.0 and 3.1. = if respond_to?(:merge_wrapper_options, true) (, ) else end @builder.bootsy_area(attribute_name, ) end |