Class: SimpleNavigation::Renderer::Sidebar

Inherits:
Base
  • Object
show all
Defined in:
lib/simple_navigation/renderer/sidebar.rb

Instance Method Summary collapse

Instance Method Details

#render(item_container) ⇒ Object



4
5
6
7
8
9
10
11
12
# File 'lib/simple_navigation/renderer/sidebar.rb', line 4

def render(item_container)
  if skip_if_empty? && item_container.empty?
    ''
  else
    tag = options[:ordered] ? :ol : :ul
    content = list_content(item_container)
    (tag, content, item_container.dom_attributes)
  end
end