Giter VIP home page Giter VIP logo

will_paginate-bootstrap's People

Contributors

abloom avatar acrogenesis avatar edatrix avatar f3ndot avatar foobear avatar juniorz avatar kalmanh avatar manuelmeurer avatar nickpad avatar sigmike avatar tkrajcar avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

will_paginate-bootstrap's Issues

Anyway to change the size of the pagination?

Bootstrap has different sizes for their pagiantor, can will_paginate-bootstrap take advantage of them?

<ul class="pagination pagination-lg">...</ul>
<ul class="pagination">...</ul>
<ul class="pagination pagination-sm">...</ul>

Limiting number of pages in links using will_paginate

Hi.. I am using the following gems

gem 'will_paginate', '~> 3.0.6'
gem 'will_paginate-bootstrap'

:inner_window and outer_window properties doesnot showing me any changes in my page.. I have tried like,

my views,

<%= will_paginate @issue, page_links: true, inner_window: 2, outer_window: 1 %>

my controller,

@issue = Issue.all.paginate(page: params[:page], per_page: 5).order("issue_slip_no DESC")
..
How should I correct it?

Very many pages

Is there a way to introduce a disabled gap in the middle if there are many pages?

Error: Uninitialized Constant

Hello, I got everthing to work locally, but when I push it to the production server, I get this error:

ActionView::Template::Error (uninitialized constant ActionView::CompiledTemplates::BootstrapPagination):

Do you know a possible solution?

Responsive pagination

Currently when I access the site from mobile, pagination is not responsive - it shows up in two rows instead of a single row. Is it possible to make this responsive?

Thanks.

Move to central organisation?

Hi!

I am the maintainer of three gems similar to this one that make it easier to use Twitter Bootstrap in Ruby projects (https://github.com/krautcomputing/rails-bootstrap-navbar, https://github.com/krautcomputing/bootstrap-navbar, https://github.com/krautcomputing/middleman-bootstrap-navbar).

I was thinking about moving all those gems to a separate organisation (like "bootstrap-ruby") and wanted to get some feedback from other maintainers of similar gems (and the community at large) if that makes sense and if we could use this to make it easier for people to find gems to work with Bootstrap in Ruby (Rails, Sinatra, etc.)
I think it would also invite other people to contribute to those projects if they were united in a central organisation.

What do you think?
Would you be willing to move this repo to such an organisation as well?

pagination-centered class

Works great! Very easy to integrate.

Is there a way I could center the pagination block with pagination-centered?

Is it possible to remove the default class of `.pagination`?

I'm removing the page numbers, and adding a class of .pager like this:

<%= will_paginate @posts, 
  renderer: BootstrapPagination::Rails, 
  page_links: false, class: :pager %>

However, because it's automatically adding the .pagination class as well, I'm getting some funkiness.

I don't have a live example, but here's how it looks with first .pager .pagination and second with just .pager

screen shot 2013-10-20 at 20 53 24

Thanks in advance :)

Size control?

It would be awesome if your gem could support the additional sizes, to make the pagination links smaller or bigger.

Add .pagination-lg or .pagination-sm for those additional sizes

For no I use JS to add the additional class...
Cheers
Juergen

Mongoid Support

Hi,

Can anyone help me on how to use this gem with Mongoid.

Thanks in advance.

Bootstrap 3 RC1 is out

...so maybe there should be a 3 branch or something. There are a couple of changes: docs. As far as I can tell you just need to move the pagination class to the ul element.

Supporting Screen Readers

Currently, from a screen reader perspective, the pages are not obviously labeled as such. Bootstrap 3.0 provides the 'sr-only' class to allow bits of html to only be shown to screen readers. The pages should really have a span which includes "Page " in front of them to make things easier on screen readers. The result for a screen reader list of links goes from "1", "2", "3 to "Page 1" "Page 2", "Page 3".

I used your existing renderer code for rails and made this addition and it seems to work fine. Perhaps in the gem this should be the default behavior with a will_paginate option to disable it?

I can do a pull request with the changes, if needed.

i18n support?

Is there any i18n support? If there is, pls document it! :)

License missing from gemspec

RubyGems.org doesn't report a license for your gem. This is because it is not specified in the gemspec of your last release.

via e.g.

spec.license = 'MIT'
# or
spec.licenses = ['MIT', 'GPL-2']

Including a license in your gemspec is an easy way for rubygems.org and other tools to check how your gem is licensed. As you can imagine, scanning your repository for a LICENSE file or parsing the README, and then attempting to identify the license or licenses is much more difficult and more error prone. So, even for projects that already specify a license, including a license in your gemspec is a good practice. See, for example, how rubygems.org uses the gemspec to display the rails gem license.

There is even a License Finder gem to help companies/individuals ensure all gems they use meet their licensing needs. This tool depends on license information being available in the gemspec. This is an important enough issue that even Bundler now generates gems with a default 'MIT' license.

I hope you'll consider specifying a license in your gemspec. If not, please just close the issue with a nice message. In either case, I'll follow up. Thanks for your time!

Appendix:

If you need help choosing a license (sorry, I haven't checked your readme or looked for a license file), GitHub has created a license picker tool. Code without a license specified defaults to 'All rights reserved'-- denying others all rights to use of the code.
Here's a list of the license names I've found and their frequencies

p.s. In case you're wondering how I found you and why I made this issue, it's because I'm collecting stats on gems (I was originally looking for download data) and decided to collect license metadata,too, and make issues for gemspecs not specifying a license as a public service :). See the previous link or my blog post about this project for more information.

Current page

Hi.
What I have:
ruby 1.9.3p125
rails (3.2.8)
twitter-bootstrap-rails (2.1.6)
will_paginate (3.0.3)
will_paginate-bootstrap (0.2.1)

In my view(haml): = will_paginate @articles, :renderer => BootstrapPagination::Rails

Everything works fine... but one thing makes me sad: current page don't have correct class name. Tag "li" has only word "class", instead of class="active". What am I doing wrong?

Thanx for your help!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.