Class: JekyllNavigation::NavigationControllerTag
- Inherits:
-
Liquid::Block
- Object
- Liquid::Block
- JekyllNavigation::NavigationControllerTag
- Defined in:
- lib/jekyll-navigation.rb
Instance Method Summary collapse
-
#initialize(tag_name, level, tokens) ⇒ NavigationControllerTag
constructor
A new instance of NavigationControllerTag.
- #render(context) ⇒ Object
Constructor Details
#initialize(tag_name, level, tokens) ⇒ NavigationControllerTag
Returns a new instance of NavigationControllerTag.
8 9 10 11 |
# File 'lib/jekyll-navigation.rb', line 8 def initialize(tag_name, level, tokens) super @level = level.to_s.strip end |
Instance Method Details
#render(context) ⇒ Object
13 14 15 16 17 18 19 20 21 |
# File 'lib/jekyll-navigation.rb', line 13 def render(context) = Navigation.new(context, @level) if .display? super else "" end end |