Class: Brightcontent::PaginationRenderer
- Inherits:
-
WillPaginate::ActionView::LinkRenderer
- Object
- WillPaginate::ActionView::LinkRenderer
- Brightcontent::PaginationRenderer
- Defined in:
- lib/brightcontent/pagination_renderer.rb
Constant Summary collapse
- ELLIPSIS =
"…"
Instance Method Summary collapse
Instance Method Details
#container_attributes ⇒ Object
20 21 22 |
# File 'lib/brightcontent/pagination_renderer.rb', line 20 def container_attributes super.except(*[:link_options]) end |
#to_html ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 |
# File 'lib/brightcontent/pagination_renderer.rb', line 7 def to_html list_items = pagination.map do |item| case item when Integer page_number(item) else send(item) end end.join([:link_separator]) tag("ul", list_items, container_attributes.merge(class: ul_class)) end |