simple_navigation_bootstrap 1.0.0 → 1.0.1
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.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2a6633edeb432c97870733fb53da5fda50bcd8ad
|
4
|
+
data.tar.gz: d93611b08e3f7f6a7d06c1ae8cf9cd1ec27deb1b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 006b8cb0ac831e77a791a6c81d14728105cdb4b6b100e0136c06f250e4ede96cfd68f22afcc359fb773b3b9d26f476cfdbfa5fd4555957eb9d6a0fec5f6fbe6b
|
7
|
+
data.tar.gz: f05c668425e610ad4c783b34c339d372e68d050f305ae3c09da0e9fbd146634c89f2db65abaaefe5ea4d2ea71fb242419a316562632920bb40b1e4b4b44e1646
|
data/.gitignore
CHANGED
data/CHANGELOG.md
ADDED
@@ -71,7 +71,7 @@ module SimpleNavigationBootstrap
|
|
71
71
|
|
72
72
|
if name[:icon]
|
73
73
|
icon_options = { class: name[:icon], title: name[:title] }.reject { |_, v| v.nil? }
|
74
|
-
content_tag(:
|
74
|
+
content_tag(:i, '', icon_options) + ' ' + (name[:text] || '')
|
75
75
|
else
|
76
76
|
name[:text] || (raise SimpleNavigationBootstrap::InvalidHash)
|
77
77
|
end
|
@@ -171,20 +171,20 @@ describe SimpleNavigationBootstrap::Bootstrap3 do
|
|
171
171
|
|
172
172
|
context "when 'hash' provided in place of 'name'" do
|
173
173
|
context "with ':icon' parameter" do
|
174
|
-
it "adds
|
175
|
-
check_selector build_menu(version: 3), 'ul > li > a >
|
174
|
+
it "adds i-tag with classes from the parameter" do
|
175
|
+
check_selector build_menu(version: 3), 'ul > li > a > i.fa.fa-fw.fa-bullhorn'
|
176
176
|
end
|
177
177
|
end
|
178
178
|
|
179
179
|
context "with ':title' parameter" do
|
180
|
-
it "sets up 'title' attribute on icon's
|
181
|
-
check_selector build_menu(version: 3), 'ul > li > a >
|
180
|
+
it "sets up 'title' attribute on icon's i-tag to the parameter value" do
|
181
|
+
check_selector build_menu(version: 3), 'ul > li > a > i.fa.fa-fw.fa-book[title="Info"]'
|
182
182
|
end
|
183
183
|
end
|
184
184
|
|
185
185
|
context "with ':text' parameter" do
|
186
186
|
it "uses the parameter value as 'name' of the item" do
|
187
|
-
expect(build_menu(version: 3).css('ul > li > a >
|
187
|
+
expect(build_menu(version: 3).css('ul > li > a > i.fa.fa-fw.fa-bullhorn')[0].parent.children[1].to_s).to eq ' News'
|
188
188
|
end
|
189
189
|
end
|
190
190
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: simple_navigation_bootstrap
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Pavel Shpak
|
@@ -123,6 +123,7 @@ files:
|
|
123
123
|
- ".rubocop.yml"
|
124
124
|
- ".travis.yml"
|
125
125
|
- AUTHORS
|
126
|
+
- CHANGELOG.md
|
126
127
|
- Gemfile
|
127
128
|
- LICENSE
|
128
129
|
- README.md
|