Class: PhlexUI::Pagination::Item
- Defined in:
- lib/phlex_ui/pagination/item.rb
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize(href: "#", active: false, **attrs) ⇒ Item
constructor
A new instance of Item.
- #view_template(&block) ⇒ Object
Methods inherited from Base
Constructor Details
#initialize(href: "#", active: false, **attrs) ⇒ Item
Returns a new instance of Item.
5 6 7 8 9 |
# File 'lib/phlex_ui/pagination/item.rb', line 5 def initialize(href: "#", active: false, **attrs) @href = href @active = active super(**attrs) end |
Instance Method Details
#view_template(&block) ⇒ Object
11 12 13 14 15 |
# File 'lib/phlex_ui/pagination/item.rb', line 11 def view_template(&block) li do a(href: @href, **attrs, &block) end end |