generic_form_builder 0.4.3 → 0.4.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +1,7 @@
1
1
  # -*- encoding: utf-8 -*-
2
2
  Gem::Specification.new do |s|
3
3
  s.name = "generic_form_builder"
4
- s.version = '0.4.3'
4
+ s.version = '0.4.4'
5
5
  s.platform = Gem::Platform::RUBY
6
6
  s.authors = ["Elliot Crosby-McCullough", "George Brocklehurst", "Elise Huard", "Tom Stuart"]
7
7
  s.email = ["elliot.cm@gmail.com"]
@@ -41,8 +41,8 @@ class GenericFormBuilder < ActionView::Helpers::FormBuilder
41
41
  def radio_button(field, value, options = {})
42
42
  return super if options[:default_builder]
43
43
  label_text = options.delete(:label) || field.to_s.humanize
44
- options[:tag_type] ||= :li
45
- content_tag(options[:tag_type], label("#{field}_#{value}", super + " #{label_text} #{errors_text(field)}"))
44
+ tag_type = options.delete(:tag_type) || :li
45
+ content_tag(tag_type, label("#{field}_#{value.to_s.downcase.gsub(' ', '_')}", super + " #{label_text} #{errors_text(field)}", :class => 'radio'))
46
46
  end
47
47
 
48
48
  def buttons(options = {})
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: generic_form_builder
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.3
4
+ version: 0.4.4
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2012-03-21 00:00:00.000000000Z
15
+ date: 2012-03-22 00:00:00.000000000Z
16
16
  dependencies: []
17
17
  description:
18
18
  email: