bootstrap-kaminari-views-reload 0.0.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/MIT-LICENSE +20 -0
- data/README.rdoc +52 -0
- data/Rakefile +38 -0
- data/app/views/kaminari/twitter-bootstrap-3/_first_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-3/_gap.html.erb +8 -0
- data/app/views/kaminari/twitter-bootstrap-3/_last_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-3/_next_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-3/_page.html.erb +12 -0
- data/app/views/kaminari/twitter-bootstrap-3/_paginator.html.erb +26 -0
- data/app/views/kaminari/twitter-bootstrap-3/_prev_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-4/_first_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-4/_gap.html.erb +10 -0
- data/app/views/kaminari/twitter-bootstrap-4/_last_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-4/_next_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap-4/_page.html.erb +12 -0
- data/app/views/kaminari/twitter-bootstrap-4/_paginator.html.erb +26 -0
- data/app/views/kaminari/twitter-bootstrap-4/_prev_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap/_first_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap/_gap.html.erb +8 -0
- data/app/views/kaminari/twitter-bootstrap/_last_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap/_next_page.html.erb +13 -0
- data/app/views/kaminari/twitter-bootstrap/_page.html.erb +12 -0
- data/app/views/kaminari/twitter-bootstrap/_paginator.html.erb +27 -0
- data/app/views/kaminari/twitter-bootstrap/_prev_page.html.erb +13 -0
- data/lib/bootstrap-kaminari-views.rb +4 -0
- data/lib/bootstrap-kaminari-views/version.rb +3 -0
- data/lib/tasks/bootstrap-kaminari-views_tasks.rake +4 -0
- metadata +113 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 74db0c4926f60e419c7152c23691ecb880b7b671c54da66878e8680d88fa42c3
|
4
|
+
data.tar.gz: fce44437bf0b3c0de05cfead823c760c5b7a03487c1da30abc8cf89be15581fc
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: 2411f642fa79cdabb7d6c909e595963d6f0f499762cb63044982de238a165977da45ce17f8355c4201e151502d38470c377ab7e3355310aad485dfe28fb70254
|
7
|
+
data.tar.gz: d371e46b0d5b5bdc23237d3fa1c86c6e47dadae26c97dea088a352aacc2e35f5d8ec20e1477c56c06d83fff9c9e2f989024f3d04124cc689d1759f4131b07fd0
|
data/MIT-LICENSE
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
Copyright 2012 YOURNAME
|
2
|
+
|
3
|
+
Permission is hereby granted, free of charge, to any person obtaining
|
4
|
+
a copy of this software and associated documentation files (the
|
5
|
+
"Software"), to deal in the Software without restriction, including
|
6
|
+
without limitation the rights to use, copy, modify, merge, publish,
|
7
|
+
distribute, sublicense, and/or sell copies of the Software, and to
|
8
|
+
permit persons to whom the Software is furnished to do so, subject to
|
9
|
+
the following conditions:
|
10
|
+
|
11
|
+
The above copyright notice and this permission notice shall be
|
12
|
+
included in all copies or substantial portions of the Software.
|
13
|
+
|
14
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
15
|
+
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
16
|
+
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
17
|
+
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
|
18
|
+
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
19
|
+
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
|
20
|
+
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
data/README.rdoc
ADDED
@@ -0,0 +1,52 @@
|
|
1
|
+
= Bootstrap Kaminari Views
|
2
|
+
|
3
|
+
{<img src="https://badge.fury.io/rb/bootstrap-kaminari-views.svg" alt="Gem Version" />}[http://badge.fury.io/rb/bootstrap-kaminari-views]
|
4
|
+
|
5
|
+
Basic Gem for quick default inclusion of {Kaminari}[https://github.com/amatsuda/kaminari] theme compatible with {Twitter Bootstrap 2.0}[http://getbootstrap.com/2.3.2/], {Twitter Bootstrap 3.0}[http://getbootstrap.com] and {Twitter Bootstrap 4.0}[https://v4-alpha.getbootstrap.com]
|
6
|
+
|
7
|
+
= Usage
|
8
|
+
|
9
|
+
Ensure your gemfile contains
|
10
|
+
|
11
|
+
gem 'kaminari'
|
12
|
+
gem 'bootstrap-kaminari-views'
|
13
|
+
|
14
|
+
Render Pagination with a theme
|
15
|
+
|
16
|
+
= paginate @posts, :theme => 'twitter-bootstrap'
|
17
|
+
|
18
|
+
= paginate @posts, :theme => 'twitter-bootstrap-3'
|
19
|
+
|
20
|
+
= paginate @posts, :theme => 'twitter-bootstrap-4'
|
21
|
+
|
22
|
+
Render with specific pagination classes
|
23
|
+
|
24
|
+
= paginate @posts, :theme => 'twitter-bootstrap-3',
|
25
|
+
:pagination_class => "pagination-sm"
|
26
|
+
|
27
|
+
Render with specific pagination classes
|
28
|
+
|
29
|
+
= paginate @posts, :theme => 'twitter-bootstrap',
|
30
|
+
:pagination_class => "pagination-small pagination-centered"
|
31
|
+
|
32
|
+
== Default Options
|
33
|
+
|
34
|
+
If you want to use one or more options as the default across your app, you can override the helper method in your +application_helper.rb+ file:
|
35
|
+
|
36
|
+
|
37
|
+
module ApplicationHelper
|
38
|
+
|
39
|
+
def paginate objects, options = {}
|
40
|
+
options.reverse_merge!( theme: 'twitter-bootstrap' )
|
41
|
+
|
42
|
+
super( objects, options )
|
43
|
+
end
|
44
|
+
|
45
|
+
end
|
46
|
+
|
47
|
+
|
48
|
+
= Credits
|
49
|
+
|
50
|
+
{Kaminari}[https://github.com/amatsuda/kaminari] - For making an awesome gem
|
51
|
+
|
52
|
+
{twitter-bootstrap-kaminari-views}[https://github.com/gabetax/twitter-bootstrap-kaminari-views] - Non Gemified Implementation
|
data/Rakefile
ADDED
@@ -0,0 +1,38 @@
|
|
1
|
+
#!/usr/bin/env rake
|
2
|
+
begin
|
3
|
+
require 'bundler/setup'
|
4
|
+
rescue LoadError
|
5
|
+
puts 'You must `gem install bundler` and `bundle install` to run rake tasks'
|
6
|
+
end
|
7
|
+
begin
|
8
|
+
require 'rdoc/task'
|
9
|
+
rescue LoadError
|
10
|
+
require 'rdoc/rdoc'
|
11
|
+
require 'rake/rdoctask'
|
12
|
+
RDoc::Task = Rake::RDocTask
|
13
|
+
end
|
14
|
+
|
15
|
+
RDoc::Task.new(:rdoc) do |rdoc|
|
16
|
+
rdoc.rdoc_dir = 'rdoc'
|
17
|
+
rdoc.title = 'BootstrapKaminariViews'
|
18
|
+
rdoc.options << '--line-numbers'
|
19
|
+
rdoc.rdoc_files.include('README.rdoc')
|
20
|
+
rdoc.rdoc_files.include('lib/**/*.rb')
|
21
|
+
end
|
22
|
+
|
23
|
+
|
24
|
+
|
25
|
+
|
26
|
+
Bundler::GemHelper.install_tasks
|
27
|
+
|
28
|
+
require 'rake/testtask'
|
29
|
+
|
30
|
+
Rake::TestTask.new(:test) do |t|
|
31
|
+
t.libs << 'lib'
|
32
|
+
t.libs << 'test'
|
33
|
+
t.pattern = 'test/**/*_test.rb'
|
34
|
+
t.verbose = false
|
35
|
+
end
|
36
|
+
|
37
|
+
|
38
|
+
task :default => :test
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "First" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the first page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.first? %>
|
10
|
+
<li class="first">
|
11
|
+
<%= link_to_unless current_page.first?, raw(t 'views.pagination.first'), url, :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,8 @@
|
|
1
|
+
<%# Non-link tag that stands for skipped pages...
|
2
|
+
- available local variables
|
3
|
+
current_page: a page object for the currently displayed page
|
4
|
+
num_pages: total number of pages
|
5
|
+
per_page: number of items to fetch per page
|
6
|
+
remote: data-remote
|
7
|
+
-%>
|
8
|
+
<li class="page gap disabled"><a href="#" onclick="return false;"><%= raw(t 'views.pagination.truncate') %></a></li>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Last" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the last page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.last? %>
|
10
|
+
<li class="last next"><%# "next" class present for border styling in twitter bootstrap %>
|
11
|
+
<%= link_to_unless current_page.last?, raw(t 'views.pagination.last'), url, {:remote => remote} %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Next" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the next page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.last? %>
|
10
|
+
<li class="next_page">
|
11
|
+
<%= link_to_unless current_page.last?, raw(t 'views.pagination.next'), url, :rel => 'next', :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<%# Link showing page number
|
2
|
+
- available local variables
|
3
|
+
page: a page object for "this" page
|
4
|
+
url: url to this page
|
5
|
+
current_page: a page object for the currently displayed page
|
6
|
+
num_pages: total number of pages
|
7
|
+
per_page: number of items to fetch per page
|
8
|
+
remote: data-remote
|
9
|
+
-%>
|
10
|
+
<li class="page<%= ' active' if page.current? %>">
|
11
|
+
<%= link_to page, url, opts = {:remote => remote, :rel => page.next? ? 'next' : page.prev? ? 'prev' : nil} %>
|
12
|
+
</li>
|
@@ -0,0 +1,26 @@
|
|
1
|
+
<%# The container tag
|
2
|
+
- available local variables
|
3
|
+
current_page: a page object for the currently displayed page
|
4
|
+
num_pages: total number of pages
|
5
|
+
per_page: number of items to fetch per page
|
6
|
+
remote: data-remote
|
7
|
+
paginator: the paginator that renders the pagination tags inside
|
8
|
+
-%>
|
9
|
+
<%- pagination_class ||= '' %>
|
10
|
+
<%= paginator.render do -%>
|
11
|
+
<nav>
|
12
|
+
<ul class="pagination <%= pagination_class %>">
|
13
|
+
<%= first_page_tag unless current_page.first? %>
|
14
|
+
<%= prev_page_tag unless current_page.first? %>
|
15
|
+
<% each_page do |page| -%>
|
16
|
+
<% if page.left_outer? || page.right_outer? || page.inside_window? -%>
|
17
|
+
<%= page_tag page %>
|
18
|
+
<% elsif !page.was_truncated? -%>
|
19
|
+
<%= gap_tag %>
|
20
|
+
<% end -%>
|
21
|
+
<% end -%>
|
22
|
+
<%= next_page_tag unless current_page.last? %>
|
23
|
+
<%= last_page_tag unless current_page.last? %>
|
24
|
+
</ul>
|
25
|
+
</nav>
|
26
|
+
<% end -%>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Previous" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the previous page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.first? %>
|
10
|
+
<li class="prev">
|
11
|
+
<%= link_to_unless current_page.first?, raw(t 'views.pagination.previous'), url, :rel => 'prev', :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "First" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the first page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.first? %>
|
10
|
+
<li class="page-item first">
|
11
|
+
<%= link_to_unless current_page.first?, raw(t 'views.pagination.first'), url, :remote => remote, class: 'page-link' %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,10 @@
|
|
1
|
+
<%# Non-link tag that stands for skipped pages...
|
2
|
+
- available local variables
|
3
|
+
current_page: a page object for the currently displayed page
|
4
|
+
num_pages: total number of pages
|
5
|
+
per_page: number of items to fetch per page
|
6
|
+
remote: data-remote
|
7
|
+
-%>
|
8
|
+
<li class="page-item page gap disabled">
|
9
|
+
<a class="page-link" href="#" onclick="return false;"><%= raw(t 'views.pagination.truncate') %></a>
|
10
|
+
</li>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Last" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the last page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.last? %>
|
10
|
+
<li class="page-item last next"><%# "next" class present for border styling in twitter bootstrap %>
|
11
|
+
<%= link_to_unless current_page.last?, raw(t 'views.pagination.last'), url, {class: 'page-link', :remote => remote} %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Next" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the next page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.last? %>
|
10
|
+
<li class="page-item next_page">
|
11
|
+
<%= link_to_unless current_page.last?, raw(t 'views.pagination.next'), url, class: 'page-link', :rel => 'next', :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<%# Link showing page number
|
2
|
+
- available local variables
|
3
|
+
page: a page object for "this" page
|
4
|
+
url: url to this page
|
5
|
+
current_page: a page object for the currently displayed page
|
6
|
+
num_pages: total number of pages
|
7
|
+
per_page: number of items to fetch per page
|
8
|
+
remote: data-remote
|
9
|
+
-%>
|
10
|
+
<li class="page-item page-item<%= ' active' if page.current? %>">
|
11
|
+
<%= link_to page, url, opts = {class: 'page-link', :remote => remote, :rel => page.next? ? 'next' : page.prev? ? 'prev' : nil} %>
|
12
|
+
</li>
|
@@ -0,0 +1,26 @@
|
|
1
|
+
<%# The container tag
|
2
|
+
- available local variables
|
3
|
+
current_page: a page object for the currently displayed page
|
4
|
+
num_pages: total number of pages
|
5
|
+
per_page: number of items to fetch per page
|
6
|
+
remote: data-remote
|
7
|
+
paginator: the paginator that renders the pagination tags inside
|
8
|
+
-%>
|
9
|
+
<%- pagination_class ||= '' %>
|
10
|
+
<%= paginator.render do -%>
|
11
|
+
<nav>
|
12
|
+
<ul class="pagination <%= pagination_class %>">
|
13
|
+
<%= first_page_tag unless current_page.first? %>
|
14
|
+
<%= prev_page_tag unless current_page.first? %>
|
15
|
+
<% each_page do |page| -%>
|
16
|
+
<% if page.left_outer? || page.right_outer? || page.inside_window? -%>
|
17
|
+
<%= page_tag page %>
|
18
|
+
<% elsif !page.was_truncated? -%>
|
19
|
+
<%= gap_tag %>
|
20
|
+
<% end -%>
|
21
|
+
<% end -%>
|
22
|
+
<%= next_page_tag unless current_page.last? %>
|
23
|
+
<%= last_page_tag unless current_page.last? %>
|
24
|
+
</ul>
|
25
|
+
</nav>
|
26
|
+
<% end -%>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Previous" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the previous page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.first? %>
|
10
|
+
<li class="page-item prev">
|
11
|
+
<%= link_to_unless current_page.first?, raw(t 'views.pagination.previous'), url, class: 'page-link', :rel => 'prev', :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "First" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the first page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.first? %>
|
10
|
+
<li class="first">
|
11
|
+
<%= link_to_unless current_page.first?, raw(t 'views.pagination.first'), url, :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,8 @@
|
|
1
|
+
<%# Non-link tag that stands for skipped pages...
|
2
|
+
- available local variables
|
3
|
+
current_page: a page object for the currently displayed page
|
4
|
+
num_pages: total number of pages
|
5
|
+
per_page: number of items to fetch per page
|
6
|
+
remote: data-remote
|
7
|
+
-%>
|
8
|
+
<li class="page gap disabled"><a href="#" onclick="return false;"><%= raw(t 'views.pagination.truncate') %></a></li>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Last" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the last page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.last? %>
|
10
|
+
<li class="last next"><%# "next" class present for border styling in twitter bootstrap %>
|
11
|
+
<%= link_to_unless current_page.last?, raw(t 'views.pagination.last'), url, {:remote => remote} %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Next" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the next page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.last? %>
|
10
|
+
<li class="next_page">
|
11
|
+
<%= link_to_unless current_page.last?, raw(t 'views.pagination.next'), url, :rel => 'next', :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<%# Link showing page number
|
2
|
+
- available local variables
|
3
|
+
page: a page object for "this" page
|
4
|
+
url: url to this page
|
5
|
+
current_page: a page object for the currently displayed page
|
6
|
+
num_pages: total number of pages
|
7
|
+
per_page: number of items to fetch per page
|
8
|
+
remote: data-remote
|
9
|
+
-%>
|
10
|
+
<li class="page<%= ' active' if page.current? %>">
|
11
|
+
<%= link_to page, url, opts = {:remote => remote, :rel => page.next? ? 'next' : page.prev? ? 'prev' : nil} %>
|
12
|
+
</li>
|
@@ -0,0 +1,27 @@
|
|
1
|
+
<%# The container tag
|
2
|
+
- available local variables
|
3
|
+
current_page: a page object for the currently displayed page
|
4
|
+
num_pages: total number of pages
|
5
|
+
per_page: number of items to fetch per page
|
6
|
+
remote: data-remote
|
7
|
+
paginator: the paginator that renders the pagination tags inside
|
8
|
+
-%>
|
9
|
+
<% pagination_class ||= "" %>
|
10
|
+
|
11
|
+
<%= paginator.render do -%>
|
12
|
+
<div class="pagination <%= pagination_class %>">
|
13
|
+
<ul>
|
14
|
+
<%= first_page_tag unless current_page.first? %>
|
15
|
+
<%= prev_page_tag unless current_page.first? %>
|
16
|
+
<% each_page do |page| -%>
|
17
|
+
<% if page.left_outer? || page.right_outer? || page.inside_window? -%>
|
18
|
+
<%= page_tag page %>
|
19
|
+
<% elsif !page.was_truncated? -%>
|
20
|
+
<%= gap_tag %>
|
21
|
+
<% end -%>
|
22
|
+
<% end -%>
|
23
|
+
<%= next_page_tag unless current_page.last? %>
|
24
|
+
<%= last_page_tag unless current_page.last? %>
|
25
|
+
</ul>
|
26
|
+
</div>
|
27
|
+
<% end -%>
|
@@ -0,0 +1,13 @@
|
|
1
|
+
<%# Link to the "Previous" page
|
2
|
+
- available local variables
|
3
|
+
url: url to the previous page
|
4
|
+
current_page: a page object for the currently displayed page
|
5
|
+
num_pages: total number of pages
|
6
|
+
per_page: number of items to fetch per page
|
7
|
+
remote: data-remote
|
8
|
+
-%>
|
9
|
+
<% unless current_page.first? %>
|
10
|
+
<li class="prev">
|
11
|
+
<%= link_to_unless current_page.first?, raw(t 'views.pagination.previous'), url, :rel => 'prev', :remote => remote %>
|
12
|
+
</li>
|
13
|
+
<% end %>
|
metadata
ADDED
@@ -0,0 +1,113 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: bootstrap-kaminari-views-reload
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.0.5
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Matenia Rossides
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2018-04-25 00:00:00.000000000 Z
|
12
|
+
dependencies:
|
13
|
+
- !ruby/object:Gem::Dependency
|
14
|
+
name: rails
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - ">="
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '3.1'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ">="
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '3.1'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: kaminari
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0.13'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0.13'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: sqlite3
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
description: Bootstrap-ify pagination with Kaminari - Compatible with Bootstrap 2.x,
|
56
|
+
3.x
|
57
|
+
email:
|
58
|
+
- matenia@gmail.com
|
59
|
+
executables: []
|
60
|
+
extensions: []
|
61
|
+
extra_rdoc_files: []
|
62
|
+
files:
|
63
|
+
- MIT-LICENSE
|
64
|
+
- README.rdoc
|
65
|
+
- Rakefile
|
66
|
+
- app/views/kaminari/twitter-bootstrap-3/_first_page.html.erb
|
67
|
+
- app/views/kaminari/twitter-bootstrap-3/_gap.html.erb
|
68
|
+
- app/views/kaminari/twitter-bootstrap-3/_last_page.html.erb
|
69
|
+
- app/views/kaminari/twitter-bootstrap-3/_next_page.html.erb
|
70
|
+
- app/views/kaminari/twitter-bootstrap-3/_page.html.erb
|
71
|
+
- app/views/kaminari/twitter-bootstrap-3/_paginator.html.erb
|
72
|
+
- app/views/kaminari/twitter-bootstrap-3/_prev_page.html.erb
|
73
|
+
- app/views/kaminari/twitter-bootstrap-4/_first_page.html.erb
|
74
|
+
- app/views/kaminari/twitter-bootstrap-4/_gap.html.erb
|
75
|
+
- app/views/kaminari/twitter-bootstrap-4/_last_page.html.erb
|
76
|
+
- app/views/kaminari/twitter-bootstrap-4/_next_page.html.erb
|
77
|
+
- app/views/kaminari/twitter-bootstrap-4/_page.html.erb
|
78
|
+
- app/views/kaminari/twitter-bootstrap-4/_paginator.html.erb
|
79
|
+
- app/views/kaminari/twitter-bootstrap-4/_prev_page.html.erb
|
80
|
+
- app/views/kaminari/twitter-bootstrap/_first_page.html.erb
|
81
|
+
- app/views/kaminari/twitter-bootstrap/_gap.html.erb
|
82
|
+
- app/views/kaminari/twitter-bootstrap/_last_page.html.erb
|
83
|
+
- app/views/kaminari/twitter-bootstrap/_next_page.html.erb
|
84
|
+
- app/views/kaminari/twitter-bootstrap/_page.html.erb
|
85
|
+
- app/views/kaminari/twitter-bootstrap/_paginator.html.erb
|
86
|
+
- app/views/kaminari/twitter-bootstrap/_prev_page.html.erb
|
87
|
+
- lib/bootstrap-kaminari-views.rb
|
88
|
+
- lib/bootstrap-kaminari-views/version.rb
|
89
|
+
- lib/tasks/bootstrap-kaminari-views_tasks.rake
|
90
|
+
homepage: http://github.com/matenia/bootstrap-kaminari-views
|
91
|
+
licenses: []
|
92
|
+
metadata: {}
|
93
|
+
post_install_message:
|
94
|
+
rdoc_options: []
|
95
|
+
require_paths:
|
96
|
+
- lib
|
97
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
98
|
+
requirements:
|
99
|
+
- - ">="
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: '0'
|
102
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
103
|
+
requirements:
|
104
|
+
- - ">="
|
105
|
+
- !ruby/object:Gem::Version
|
106
|
+
version: '0'
|
107
|
+
requirements: []
|
108
|
+
rubyforge_project:
|
109
|
+
rubygems_version: 2.7.6
|
110
|
+
signing_key:
|
111
|
+
specification_version: 4
|
112
|
+
summary: Bootstrap-ify pagination with Kaminari
|
113
|
+
test_files: []
|