Class: Blogit::Admin::FormsHelper::FormBuilder
- Inherits:
-
ActionView::Helpers::FormBuilder
- Object
- ActionView::Helpers::FormBuilder
- Blogit::Admin::FormsHelper::FormBuilder
- Defined in:
- app/helpers/blogit/admin/forms_helper.rb
Instance Method Summary collapse
- #field(options = {}, &block) ⇒ Object
- #label(method, text = nil, options = {}, &block) ⇒ Object
- #text_area(method, options = {}) ⇒ Object
- #text_field(method, options = {}) ⇒ Object
Instance Method Details
#field(options = {}, &block) ⇒ Object
6 7 8 9 |
# File 'app/helpers/blogit/admin/forms_helper.rb', line 6 def field( = {}, &block) [:class] = Array([:class]) + [ "blogit_admin_form-field_wrapper" ] @template.content_tag(:div, , &block) end |
#label(method, text = nil, options = {}, &block) ⇒ Object
11 12 13 14 |
# File 'app/helpers/blogit/admin/forms_helper.rb', line 11 def label(method, text = nil, = {}, &block) [:class] = Array([:class]) + [ 'blogit_admin_form-label'] super end |
#text_area(method, options = {}) ⇒ Object
21 22 23 24 25 |
# File 'app/helpers/blogit/admin/forms_helper.rb', line 21 def text_area(method, = {}) [:class] = Array([:class]) + [ 'blogit_admin_form-editable_text_area' ] super end |
#text_field(method, options = {}) ⇒ Object
16 17 18 19 |
# File 'app/helpers/blogit/admin/forms_helper.rb', line 16 def text_field(method, = {}) [:class] = Array([:class]) + [ 'blogit_admin_form-field' ] super end |