Class: Navigatrix::Rendering::Strategies::List
- Inherits:
-
Object
- Object
- Navigatrix::Rendering::Strategies::List
- Includes:
- ContentHelpers
- Defined in:
- lib/navigatrix/rendering/strategies/list.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#item_options ⇒ Object
readonly
Returns the value of attribute item_options.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
-
#initialize(items, list_options = {}, item_options = {}) ⇒ List
constructor
A new instance of List.
- #render ⇒ Object
Methods included from ContentHelpers
Constructor Details
#initialize(items, list_options = {}, item_options = {}) ⇒ List
Returns a new instance of List.
14 15 16 17 18 |
# File 'lib/navigatrix/rendering/strategies/list.rb', line 14 def initialize(items, = {}, = {}) @items = items || [] @options = @item_options = end |
Instance Attribute Details
#item_options ⇒ Object (readonly)
Returns the value of attribute item_options.
12 13 14 |
# File 'lib/navigatrix/rendering/strategies/list.rb', line 12 def @item_options end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
12 13 14 |
# File 'lib/navigatrix/rendering/strategies/list.rb', line 12 def @options end |
Instance Method Details
#render ⇒ Object
20 21 22 |
# File 'lib/navigatrix/rendering/strategies/list.rb', line 20 def render content_tag(:ul, render_items, html_attributes) end |