simple-navigation 4.1.0 → 4.2.0

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
- SHA1:
3
- metadata.gz: 80fdb7f2e02862d983ad05c0fdfc0abba3e702e8
4
- data.tar.gz: 8b61d65bd217b32bea405141a7e5f5e212d79159
2
+ SHA256:
3
+ metadata.gz: 9df430bc691baeee7336fcfbbf5b6702b89440da2d61a2d7cf9e654e04241f09
4
+ data.tar.gz: '059b49e4ac9536964aff8678c86dea636bdc29f3ceeeb51d661e4b0b3df02733'
5
5
  SHA512:
6
- metadata.gz: 8171a0a34b62e9ca31f1c1d7fb6ab9ca838be0d566243cd0d11c106797d8279f2e53aeb634eeae79b01e9007da24b47bb706a776580ec010859bc9b74751d0e5
7
- data.tar.gz: 9cff271a844731db1151e6031dac06351d8592b3038327e92e0f7b245045f523974c741f9dd33332baeeb492cea9d474fd29f54fe6318517596d02222d5115fc
6
+ metadata.gz: 6a5b51b3afcc9f5324335d7064bcc12cd417d151384b219ad1b2db10d3d161a9517cbcd9a9c766555c93e7b343d3ca233ab50663459670fc6b4804216fc57534
7
+ data.tar.gz: 98417524e1562117207ca2f9c5eddc77328e8d0d5ef3da1ef42f52c420634c7e011931622d5f642d869d265f4b4ffda9c3477a31ea03b2cf3d200f7c2d7d1ca4
data/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Changelog
2
2
 
3
+ ## 4.2.0
4
+
5
+ * improvements to generator template. Credits to mgrunberg.
6
+ * be able to run 'rake spec:rails-6-0-stable'. Credits to mgrunberg.
7
+
3
8
  ## 4.1.0
4
9
 
5
10
  * Delay rails6 initialization using on_load (getting rid of deprecation warnings in rails 6). Credits to Markus Benning.
data/README.md CHANGED
@@ -60,4 +60,4 @@ In this situation `/Users/username/.rubies/ruby-2.2.3/bin/rake` is the command y
60
60
 
61
61
  ## License
62
62
 
63
- Copyright (c) 2019 codeplant GmbH, released under the MIT license
63
+ Copyright (c) 2021 codeplant GmbH, released under the MIT license
data/Rakefile CHANGED
@@ -16,6 +16,7 @@ namespace :spec do
16
16
  rails-4-1-stable
17
17
  rails-4-2-stable
18
18
  rails-5-2-stable
19
+ rails-6-0-stable
19
20
  ]
20
21
 
21
22
  mappers.each do |gemfile|
@@ -3,8 +3,7 @@ source 'https://rubygems.org'
3
3
  gem 'rake', '< 11.0'
4
4
 
5
5
  # not yet
6
- #gem 'railties', '~> 6.0.0'
7
- gem 'railties', '6.0.0.rc2'
6
+ gem 'railties', '~> 6.0.0'
8
7
  gem 'rspec-rails', '~> 3.8.2'
9
8
 
10
9
  gemspec path: '../'
@@ -24,7 +24,7 @@ SimpleNavigation::Configuration.run do |navigation|
24
24
  # If you need to add custom html around item names, you can define a proc that
25
25
  # will be called with the name you pass in to the navigation.
26
26
  # The example below shows how to wrap items spans.
27
- #navigation.name_generator = Proc.new {|name, item| "<span>#{name}</span>"}
27
+ #navigation.name_generator = Proc.new {|name, item| tag.span(name) }
28
28
 
29
29
  # Specify if the auto highlight feature is turned on (globally, for the whole navigation). Defaults to true
30
30
  #navigation.auto_highlight = true
@@ -45,6 +45,7 @@ SimpleNavigation::Configuration.run do |navigation|
45
45
  # url - the address that the generated item links to. You can also use url_helpers (named routes, restful routes helper, url_for etc.)
46
46
  # options - can be used to specify attributes that will be included in the rendered navigation item (e.g. id, class etc.)
47
47
  # some special options that can be set:
48
+ # :html - Specifies html attributes that will be included in the rendered navigation item
48
49
  # :if - Specifies a proc to call to determine if the item should
49
50
  # be rendered (e.g. <tt>if: -> { current_user.admin? }</tt>). The
50
51
  # proc should evaluate to a true or false value and is evaluated in the context of the view.
@@ -67,7 +68,7 @@ SimpleNavigation::Configuration.run do |navigation|
67
68
  # You can also specify a condition-proc that needs to be fullfilled to display an item.
68
69
  # Conditions are part of the options. They are evaluated in the context of the views,
69
70
  # thus you can use all the methods and vars you have available in the views.
70
- primary.item :key_3, 'Admin', url, class: 'special', if: -> { current_user.admin? }
71
+ primary.item :key_3, 'Admin', url, html: { class: 'special' }, if: -> { current_user.admin? }
71
72
  primary.item :key_4, 'Account', url, unless: -> { logged_in? }
72
73
 
73
74
  # you can also specify html attributes to attach to this particular level
@@ -1,3 +1,3 @@
1
1
  module SimpleNavigation
2
- VERSION = '4.1.0'
2
+ VERSION = '4.2.0'
3
3
  end
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: simple-navigation
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.1.0
4
+ version: 4.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andi Schacke
8
8
  - Mark J. Titorenko
9
9
  - Simon Courtois
10
- autorequire:
10
+ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2019-08-17 00:00:00.000000000 Z
13
+ date: 2021-05-11 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: activesupport
@@ -241,7 +241,7 @@ homepage: http://github.com/codeplant/simple-navigation
241
241
  licenses:
242
242
  - MIT
243
243
  metadata: {}
244
- post_install_message:
244
+ post_install_message:
245
245
  rdoc_options:
246
246
  - "--inline-source"
247
247
  - "--charset=UTF-8"
@@ -258,9 +258,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
258
258
  - !ruby/object:Gem::Version
259
259
  version: '0'
260
260
  requirements: []
261
- rubyforge_project:
262
- rubygems_version: 2.6.14
263
- signing_key:
261
+ rubygems_version: 3.0.9
262
+ signing_key:
264
263
  specification_version: 4
265
264
  summary: simple-navigation is a ruby library for creating navigations (with multiple
266
265
  levels) for your Rails, Sinatra or Padrino application.