A ruby gem that uses the Rails asset pipeline to include the jScrollPane plugin by Kelvin Luck
JavaScript Ruby CSS
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
app/assets tests Jan 16, 2018
lib tests Jan 16, 2018
test tests Jan 16, 2018
.gitignore cleanup Jan 16, 2018
.travis.yml Exclude 2.5 for now Jan 17, 2018
CONTRIBUTING.md tests Jan 16, 2018
Gemfile cleanup Jan 16, 2018
LICENSE bump Jan 16, 2018
README.md cleanup Jan 16, 2018
Rakefile cleanup Jan 16, 2018
jscrollpane-rails.gemspec tests Jan 16, 2018

README.md

jScrollPane plugin for Rails

Gem Version Build Status Dependency Status

A ruby gem that uses the Rails asset pipeline to include the jScrollPane plugin by Kelvin Luck and Tuukka Pasanen:

Installation

Add this line to your application's Gemfile:

gem 'jscrollpane-rails'

And then execute:

$ bundle

Or install it yourself as:

$ gem install jscrollpane-rails

This is a jQuery plugin so you will also need the jquery-rails gem (for instance, Rails 5.1 does not have this gem by default anymore):

It is also recommended (but is optional) to include jQuery MouseWheel plugin by Brandon Aaron (https://github.com/brandonaaron/jquery-mousewheel/) to allow people to scroll your content using their mouse wheel. There is a gem jquery-mousewheel-rails available:

This is totally optional but you can increase the usability of the mousewheel in nested scroll areas by including jQuery MouseWheel Intent plugin by trixta and bodrovis. There is a gem mwheelintent-rails available:

FOR RUSSIAN SPEAKERS: There is a guide available describing basic usage of jScrollPane: http://bodrovis.tech/categories/javascript-css-html/posts/nestandartnaya-polosa-prokrutki-s-pomoschyu-javascript

FOR ENGLISH SPEAKERS: The same guide is now available in English: http://bodrovis.tech/categories/javascript-css-html/posts/creating-custom-scrollpane-using-javascript

Usage

In your application.js you will need to add this line:

//= require jquery.jscrollpane

And in your application.scss you will need to add this line:

@import 'jscrollpane';

Testing

Run

$ bundle install

and then

$ rake test

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

License

This plugin is licensed under the MIT License.

Copyright (c) 2018 Ilya Bodrov