simple-form-builder 0.0.6.rails3 → 0.0.7.rails3
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.
|
@@ -208,15 +208,19 @@ module SimpleFormBuilder
|
|
|
208
208
|
|
|
209
209
|
dom_class = sfb_options[:label_class] || method
|
|
210
210
|
|
|
211
|
-
|
|
211
|
+
tag = ActionView::Helpers::InstanceTag.new(
|
|
212
|
+
object_name, method, self, object
|
|
213
|
+
)
|
|
214
|
+
|
|
215
|
+
label_options = { :class => dom_class }
|
|
216
|
+
|
|
212
217
|
if @options[:index].present?
|
|
213
218
|
# We're making our own label for attribute
|
|
214
|
-
label_options[:for] =
|
|
219
|
+
label_options[:for] = tag.send(:tag_id_with_index, @options[:index])
|
|
215
220
|
end
|
|
221
|
+
|
|
222
|
+
tag = tag.to_label_tag(text.html_safe, label_options)
|
|
216
223
|
|
|
217
|
-
tag = ActionView::Helpers::InstanceTag.new(
|
|
218
|
-
object_name, method, self, object
|
|
219
|
-
).to_label_tag(text.html_safe, label_options)
|
|
220
224
|
|
|
221
225
|
if hint = sfb_options[:hint]
|
|
222
226
|
tag + " <span class='hint'>#{hint}</span>".html_safe
|
metadata
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: simple-form-builder
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
hash:
|
|
4
|
+
hash: 708262365
|
|
5
5
|
prerelease: 6
|
|
6
6
|
segments:
|
|
7
7
|
- 0
|
|
8
8
|
- 0
|
|
9
|
-
-
|
|
9
|
+
- 7
|
|
10
10
|
- rails
|
|
11
11
|
- 3
|
|
12
|
-
version: 0.0.
|
|
12
|
+
version: 0.0.7.rails3
|
|
13
13
|
platform: ruby
|
|
14
14
|
authors:
|
|
15
15
|
- Ben Askins
|
|
@@ -17,7 +17,7 @@ autorequire:
|
|
|
17
17
|
bindir: bin
|
|
18
18
|
cert_chain: []
|
|
19
19
|
|
|
20
|
-
date: 2011-
|
|
20
|
+
date: 2011-05-31 00:00:00 +10:00
|
|
21
21
|
default_executable:
|
|
22
22
|
dependencies: []
|
|
23
23
|
|