Module: Bh::Form::LegendHelper

Includes:
BaseHelper
Included in:
Bh::FormBuilder
Defined in:
lib/bh/helpers/form/legend_helper.rb

Instance Method Summary collapse

Methods included from GlyphiconHelper

#glyphicon

Instance Method Details

#legend(value, options = {}) ⇒ Object



8
9
10
11
12
13
14
# File 'lib/bh/helpers/form/legend_helper.rb', line 8

def legend(value, options = {})
  append_class! options, 'sr-only' if inline_form?
  text =  :legend, value, options
  text =  :div, text, class: 'col-sm-12' if horizontal_form?
  text = label_and_field_container(text, :legend) unless inline_form?
  text
end