EdsonF / angular-perfect-scrollbar

This is a small directive to allow the use of perfect-scrollbar (https://github.com/noraesae/perfect-scrollbar) in angular

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

angular-perfect-scrollbar

This is a small directive to allow the use of perfect-scrollbar (https://github.com/noraesae/perfect-scrollbar) in angular.

You can just use the file (in the src directory) as is - you only need to pay attention to the other stuff for further development.

Install

Some small installation hints which will help you to set things up.

Install via Bower:

$ bower install angular-perfect-scrollbar --save
```

Include the angular-perfect-scrollbar files in your index.html:

<script src="bower_components/perfect-scrollbar/min/perfect-scrollbar.min.js"></script> <script src="bower_components/perfect-scrollbar/min/perfect-scrollbar.with-mousewheel.min.js"></script> <script src="bower_components/angular-perfect-scrollbar/src/angular-perfect-scrollbar.js"></script> ```

Include some css for your scrollable content:

.scroller {
    white-space: pre-line;
    height: 500px;
    overflow-y: hidden;
    position: relative;
}

Add it as module to your app.js:

['perfect_scrollbar']

Use it wherever you want:

// your content Furhter installation and usage hints you can find here: https://github.com/noraesae/perfect-scrollbar

Additionaly you will find a setup in the example folder of this repository.

About

This is a small directive to allow the use of perfect-scrollbar (https://github.com/noraesae/perfect-scrollbar) in angular


Languages

Language:JavaScript 100.0%