Sha256: d216d69cec7f045412c18d8d765031d48230002a479e46600f4f5a5c8d313675
Contents?: true
Size: 592 Bytes
Versions: 8
Compression:
Stored size: 592 Bytes
Contents
module Effective module FormInputs class FormGroup < Effective::FormInput def input_html_options if layout == :horizontal { class: 'form-group col-sm-10' } else { class: 'form-group' } end end def to_html(&block) case layout when :horizontal build_wrapper do content_tag(:div, '', class: 'col-sm-2') + content_tag(:div, capture(&block), options[:input]) end else content_tag(:div, capture(&block), options[:input]) end end end end end
Version data entries
8 entries across 8 versions & 1 rubygems