seamless-scroll
js seamless-scroll plugin
🌾 sample demo | 📘 中文文档
Browser support
IE |
Firefox |
Chrome |
Safari |
iOS |
Android |
---|---|---|---|---|---|
IE7+ | ✓ | ✓ | ✓ | ✓ | ✓ |
- mobile gestures are not supported.
Installation
NPM
npm install seamscroll --save
CDN
https://cdn.jsdelivr.net/npm/seamscroll@0.0.11/build/seamscroll.min.js
Usage
const seamless = `or` seamless //script tag<script src="seamscroll.min.js"></script><script>seamless</script>
Demo
1 2 3 4 5 6
<script src="seamscroll.min.js"></script>seamscroll
Configure
*Required parameters(dom)
key | description | default | val |
---|---|---|---|
*dom |
the role of the element | null |
dom |
step |
step,the faster the rolling speed is faster | 1 |
Number |
hoverStop |
mouse hover control is enabled | true |
Boolean |
direction |
0 down 1 up 2 left 3 right | 1 |
Number |
singleHeight |
one single stop height(default zero is seamless) => direction 0/1 | 0 |
Number |
singleWidth |
one single stop width(default zero is seamless) => direction 2/3 | 0 |
Number |
waitTime |
one single data stop wait time(1s) | 1000 |
Number |
Changelog
See the GitHub release history.
License
seamless-scroll is open source and released under the MIT License.