Class: UI::PaginationItemComponent

Inherits:
ViewComponent::Base
  • Object
show all
Includes:
PaginationItemBehavior
Defined in:
app/view_components/ui/pagination_item_component.rb

Overview

Pagination Item component (ViewComponent) List item wrapper for pagination elements

Instance Method Summary collapse

Methods included from PaginationItemBehavior

#item_html_attributes

Constructor Details

#initialize(attributes: {}) ⇒ PaginationItemComponent

Returns a new instance of PaginationItemComponent.

Parameters:

  • attributes (Hash) (defaults to: {})

    additional HTML attributes



9
10
11
# File 'app/view_components/ui/pagination_item_component.rb', line 9

def initialize(attributes: {})
  @attributes = attributes
end

Instance Method Details

#callObject



13
14
15
# File 'app/view_components/ui/pagination_item_component.rb', line 13

def call
   :li, content, **item_html_attributes
end