Sha256: 9a734e970872d8f2587158054c09385f908c4acda527c45c2cdee4d77af47c38

Contents?: true

Size: 1004 Bytes

Versions: 5

Compression:

Stored size: 1004 Bytes

Contents

<%# The container tag
  - available local variables
    current_page:  the page number of currently displayed page
    num_pages:     total number of pages
    per_page:      number of items to fetch per page
    remote:        data-remote
    paginator:     the paginator that renders the pagination tags inside
-%>
<%= paginator.render do -%>
  <nav class='pagination'>
    <%= current_page > 1 ? prev_link_tag : prev_span_tag %>
    <% each_page do |page| -%>
      <% if page.current? -%>
        <%= current_page_tag %>
      <% elsif page.left_outer? || page.right_outer? || page.inside_window? -%>
        <% if page.first? -%>
          <%= first_page_link_tag %>
        <% elsif page.last? -%>
          <%= last_page_link_tag %>
        <% else -%>
          <%= page_link_tag %>
        <% end -%>
      <% elsif !page.was_truncated? -%>
        <%= truncated_span_tag %>
      <% end -%>
    <% end -%>
    <%= num_pages > current_page ? next_link_tag : next_span_tag %>
  </nav>
<% end -%>

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
kaminari-0.10.2 app/views/kaminari/_paginator.html.erb
kaminari-0.10.1 app/views/kaminari/_paginator.html.erb
kaminari-0.10.0 app/views/kaminari/_paginator.html.erb
kaminari-0.9.13 app/views/kaminari/_paginator.html.erb
kaminari-0.9.12 app/views/kaminari/_paginator.html.erb