incline 0.3.7 → 0.3.8
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 404eac95dd5245f93a10413012dd3757d817232a
|
4
|
+
data.tar.gz: 86a88d8d878eb8b2d3922589431483d3d5f1815f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 31f8747e60f9fc1888642b776f6a940e0891cc4d451c18d33454cb84a8b50115e52155ab076c46656e1a3df9f3aab17cc9d85432ceb3d671445b9f4f382983bf
|
7
|
+
data.tar.gz: 8839b5f95bbb89da70023da2e7a21c612adb99b904542760359964a963b67c45074370bd2237570ab2b6bb34202309faca9aba70c7fcddc7ce254305667aaa06
|
data/Gemfile.lock
CHANGED
data/lib/incline/cli/prepare.rb
CHANGED
@@ -178,13 +178,12 @@ module Incline::Extensions
|
|
178
178
|
# We want each field to have a width specified.
|
179
179
|
remaining_width = 100.0
|
180
180
|
remaining_fields = fields.count
|
181
|
-
|
182
|
-
width_match_2 = /;\s*width:([^;]);/
|
181
|
+
width_match = /(?:^|;)\s*width:\s*([^;]+);/
|
183
182
|
|
184
183
|
# pass 1, compute remaining width.
|
185
184
|
fields.each do |meth, attr|
|
186
|
-
|
187
|
-
|
185
|
+
if attr[:style] =~ width_match
|
186
|
+
width = $1
|
188
187
|
if width[-1] == '%'
|
189
188
|
width = width[0...-1].strip.to_f
|
190
189
|
if width > remaining_width
|
@@ -205,8 +204,7 @@ module Incline::Extensions
|
|
205
204
|
|
206
205
|
# pass 2, fill in missing widths.
|
207
206
|
fields.each do |meth, attr|
|
208
|
-
|
209
|
-
unless width
|
207
|
+
unless attr[:style] =~ width_match
|
210
208
|
width =
|
211
209
|
if remaining_fields > 1
|
212
210
|
(remaining_width / remaining_fields).to_i
|
data/lib/incline/version.rb
CHANGED
@@ -243,7 +243,7 @@ class ActionViewBaseExtensionsTest < ActiveSupport::TestCase
|
|
243
243
|
"<li class=\"alert_52444\" style=\"display: none;\">This is error #9.</li>" +
|
244
244
|
"<li class=\"alert_52444\" style=\"display: none;\">This is error #10.</li>" +
|
245
245
|
"</ul></div>" +
|
246
|
-
"<script type=\"text/javascript\">\n
|
246
|
+
"<script type=\"text/javascript\">\n//<![CDATA[\nfunction show_alert_52444() { $('.alert_52444_show').hide(); $('.alert_52444').show(); }\n\n//]]>\n</script>\n" +
|
247
247
|
"</div></div>"
|
248
248
|
|
249
249
|
val = @view.error_summary(TestModel.new)
|