navigasmic 0.5.0 → 0.5.1
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/builders/html_builder.rb +1 -1
- data/lib/builders/xml_builder.rb +1 -1
- data/lib/navigasmic.rb +1 -1
- data/navigasmic.gemspec +1 -1
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.5.
|
1
|
+
0.5.1
|
@@ -34,7 +34,7 @@ module Navigasmic
|
|
34
34
|
group = template.content_tag(@@group_tag, buffer)
|
35
35
|
label = label_for_group(label) unless label.blank?
|
36
36
|
|
37
|
-
visible = options[:hidden_unless].
|
37
|
+
visible = options[:hidden_unless].nil? ? true : options[:hidden_unless].is_a?(Proc) ? options[:hidden_unless].call : options[:hidden_unless]
|
38
38
|
visible ? template.content_tag(@@item_tag, label.to_s + group, options.delete(:html)) : ''
|
39
39
|
end
|
40
40
|
|
data/lib/builders/xml_builder.rb
CHANGED
@@ -30,7 +30,7 @@ module Navigasmic
|
|
30
30
|
|
31
31
|
buffer = template.capture(self, &proc)
|
32
32
|
|
33
|
-
visible = options[:hidden_unless].
|
33
|
+
visible = options[:hidden_unless].nil? ? true : options[:hidden_unless].is_a?(Proc) ? options[:hidden_unless].call : options[:hidden_unless]
|
34
34
|
visible ? template.concat(template.content_tag(@@group_tag, buffer)) : ''
|
35
35
|
end
|
36
36
|
|
data/lib/navigasmic.rb
CHANGED
@@ -73,7 +73,7 @@ module Navigasmic #:nodoc:
|
|
73
73
|
@link ||= {}
|
74
74
|
|
75
75
|
@disabled_conditions = options[:disabled_if] || proc { false }
|
76
|
-
@visible = options[:hidden_unless].
|
76
|
+
@visible = options[:hidden_unless].nil? ? true : options[:hidden_unless].is_a?(Proc) ? options[:hidden_unless].call : options[:hidden_unless]
|
77
77
|
|
78
78
|
options[:highlights_on] = [options[:highlights_on]] if options[:highlights_on].kind_of?(Hash)
|
79
79
|
@highlights_on = options[:highlights_on] || []
|
data/navigasmic.gemspec
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: navigasmic
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 9
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 5
|
9
|
-
-
|
10
|
-
version: 0.5.
|
9
|
+
- 1
|
10
|
+
version: 0.5.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Jeremy Jackson
|