Skip to content

Commit 57794a3

Browse files
committed
Added test file for autoscroll invert option
1 parent bb06c8e commit 57794a3

File tree

1 file changed

+53
-0
lines changed

1 file changed

+53
-0
lines changed
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
2+
<script src="../js/jquery-1.6.2.js"></script>
3+
<script src="../../src/scrollable/scrollable.js"></script>
4+
<script src="../../src/scrollable/scrollable.autoscroll.js"></script>
5+
6+
<link rel="stylesheet" type="text/css" href="style.css"/>
7+
8+
<script>
9+
$(function() {
10+
$(".scrollable").scrollable({
11+
circular: true,
12+
13+
onSeek: function() {
14+
// console.info(this.getIndex());
15+
}
16+
17+
}).autoscroll({autoplay: true, interval: 1000, invert: true});
18+
19+
window.api = $(".scrollable").data("scrollable");
20+
});
21+
</script>
22+
23+
24+
<div>
25+
26+
<a class="prev">prev</a>
27+
28+
<div class="navi"></div>
29+
30+
<div class="scrollable" style="width:130px">
31+
32+
<div class="items">
33+
<div>0</div>
34+
<div>1</div>
35+
<div>2</div>
36+
<div>3</div>
37+
<div>4</div>
38+
<div>5</div>
39+
<div>6</div>
40+
</div>
41+
42+
</div>
43+
44+
<a class="next">next</a>
45+
46+
</div>
47+
48+
<p>
49+
<button onclick='api.stop();'>stop</button>
50+
<button onclick='api.pause();'>pause</button>
51+
<button onclick='api.play();'>play</button>
52+
</p>
53+

0 commit comments

Comments
 (0)