Class: NavigatorRails::Decorators::Navbar

Inherits:
Object
  • Object
show all
Includes:
Generic
Defined in:
lib/navigator_rails/decorators/navbar.rb

Instance Attribute Summary

Attributes included from Generic

#type

Instance Method Summary collapse

Methods included from Generic

#child_count, #children, #children_except, #children_of, #draw, #draw_children, #has_visible_children, included, #resource

Instance Method Details

#templateObject



5
6
7
8
9
10
11
12
# File 'lib/navigator_rails/decorators/navbar.rb', line 5

def template
  return '' unless has_visible_children
  "    <ul class=\"nav navbar-nav navbar-<%= resource.relative_path %>\">\n      <%= draw_children %>\n    </ul>\n  LINK_DECORATION\nend\n".strip_heredoc