Sha256: 3996e2e8b892ecc8114d9d311bc9e39cbced5352e1da0cf06c12b64b77aaf0da
Contents?: true
Size: 612 Bytes
Versions: 27
Compression:
Stored size: 612 Bytes
Contents
module Alchemy module Forms class Builder < SimpleForm::FormBuilder # Renders a simple_form input, but uses input alchemy_wrapper # def input(attribute_name, options = {}, &block) options[:wrapper] = :alchemy super end # Renders a button tag wrapped in a div with 'submit' class. # def submit(label, options = {}) options = {class: 'submit'}.update(options[:wrapper_html] || {}) template.content_tag('div', options) do template.content_tag('button', label, options[:input_html]) end end end end end
Version data entries
27 entries across 27 versions & 2 rubygems