forked from mdbootstrap/TW-Elements
-
Notifications
You must be signed in to change notification settings - Fork 0
/
options-useBothWheelAxes.html
55 lines (52 loc) · 1.15 KB
/
options-useBothWheelAxes.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<!DOCTYPE html>
<html>
<head>
<link href="../css/perfect-scrollbar.css" rel="stylesheet">
<script src="../dist/perfect-scrollbar.js"></script>
<style>
.container {
position: relative;
margin: 30px auto;
padding: 0px;
width: 600px;
height: 400px;
overflow: auto;
}
.container .content-x {
background-image: url('./assets/azusa.jpg');
width: 1280px;
height: 400px;
color: blue;
font-size: 20px;
}
.container .content-y {
background-image: url('./assets/azusa.jpg');
width: 600px;
height: 720px;
color: blue;
font-size: 20px;
}
</style>
</head>
<body>
<div class="container">
<div class="content-x">
useBothWheelAxes: x
</div>
</div>
<div class="container">
<div class="content-y">
useBothWheelAxes: y
</div>
</div>
<script>
var containers = document.querySelectorAll('.container');
new PerfectScrollbar(containers[0], {
useBothWheelAxes: true
});
new PerfectScrollbar(containers[1], {
useBothWheelAxes: true
});
</script>
</body>
</html>