Sha256: d4f19638484948274e9764cd3fb101546dd11950ced015417a7f610db9a019c6
Contents?: true
Size: 461 Bytes
Versions: 1
Compression:
Stored size: 461 Bytes
Contents
module MotionPrime class SubmitFieldSection < BaseFieldSection element :submit, type: :button do {title: options[:name].to_s.titleize}.merge(options[:button] || {}) end element :error_message, type: :error_message, text: proc { all_errors.join("\n") if observing_errors? } after_render :bind_submit def bind_submit view(:submit).on :touch do form.send(options[:action]) if options[:action] end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
motion-prime-0.8.0 | motion-prime/sections/form/submit_field_section.rb |