Sha256: 9adc11c6e215160de2585ddecf676bbbfa4b546d60b0610e95e7ab0cb6deff8f

Contents?: true

Size: 558 Bytes

Versions: 10

Compression:

Stored size: 558 Bytes

Contents

module MotionPrime
  class PasswordFieldSection < BaseFieldSection
    element :label, type: :label do
      default_label_options
    end
    element :input, type: :text_field, delegate: proc { collection_delegate } do
      {secure_text_entry: true}.merge(options[:input] || {})
    end
    element :error_message, type: :error_message, text: proc { |field| field.all_errors.join("\n") if field.observing_errors? }
    after_element_render :input, :bind_text_input

    def value
      view(:input).text
    end

    def input?
      true
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
motion-prime-1.0.7 motion-prime/sections/form/password_field_section.rb
motion-prime-1.0.6 motion-prime/sections/form/password_field_section.rb
motion-prime-1.0.5 motion-prime/sections/form/password_field_section.rb
motion-prime-1.0.4 motion-prime/sections/form/password_field_section.rb
motion-prime-1.0.3 motion-prime/sections/form/password_field_section.rb
motion-prime-1.0.2 motion-prime/sections/form/password_field_section.rb
motion-prime-1.0.1 motion-prime/sections/form/password_field_section.rb
motion-prime-1.0.0 motion-prime/sections/form/password_field_section.rb
motion-prime-0.9.9.2 motion-prime/sections/form/password_field_section.rb
motion-prime-0.9.9.1 motion-prime/sections/form/password_field_section.rb