Class: Bemer::SimpleForm::Configuration
- Inherits:
-
Object
- Object
- Bemer::SimpleForm::Configuration
- Includes:
- Singleton
- Defined in:
- lib/bemer/simple_form/configuration.rb
Instance Attribute Summary collapse
-
#bemify_namespaces ⇒ Object
Returns the value of attribute bemify_namespaces.
-
#element_name_transformer ⇒ Object
Returns the value of attribute element_name_transformer.
-
#input_type_modifiers_for_namespaces ⇒ Object
Returns the value of attribute input_type_modifiers_for_namespaces.
Instance Method Summary collapse
- #bemify_suffix_namespaces ⇒ Object
-
#initialize ⇒ Configuration
constructor
A new instance of Configuration.
- #input_type_modifiers_for_suffix_namespaces ⇒ Object
Constructor Details
#initialize ⇒ Configuration
Returns a new instance of Configuration.
14 15 16 17 18 |
# File 'lib/bemer/simple_form/configuration.rb', line 14 def initialize @bemify_namespaces = %i[error hint input wrapper label] @element_name_transformer = nil @input_type_modifiers_for_namespaces = %i[input wrapper label] end |
Instance Attribute Details
#bemify_namespaces ⇒ Object
Returns the value of attribute bemify_namespaces.
11 12 13 |
# File 'lib/bemer/simple_form/configuration.rb', line 11 def bemify_namespaces @bemify_namespaces end |
#element_name_transformer ⇒ Object
Returns the value of attribute element_name_transformer.
11 12 13 |
# File 'lib/bemer/simple_form/configuration.rb', line 11 def element_name_transformer @element_name_transformer end |
#input_type_modifiers_for_namespaces ⇒ Object
Returns the value of attribute input_type_modifiers_for_namespaces.
11 12 13 |
# File 'lib/bemer/simple_form/configuration.rb', line 11 def input_type_modifiers_for_namespaces @input_type_modifiers_for_namespaces end |
Instance Method Details
#bemify_suffix_namespaces ⇒ Object
20 21 22 |
# File 'lib/bemer/simple_form/configuration.rb', line 20 def bemify_suffix_namespaces @bemify_suffix_namespaces ||= Array.wrap(bemify_namespaces).uniq.map { |n| add_sufix(n) } end |
#input_type_modifiers_for_suffix_namespaces ⇒ Object
24 25 26 |
# File 'lib/bemer/simple_form/configuration.rb', line 24 def input_type_modifiers_for_suffix_namespaces @input_type_modifiers_for_suffix_namespaces ||= Array.wrap(input_type_modifiers_for_namespaces).uniq.map { |n| add_sufix(n) } # rubocop:disable Metrics/LineLength end |