-
Notifications
You must be signed in to change notification settings - Fork 85
/
index.html
150 lines (139 loc) · 2.73 KB
/
index.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
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
<!DOCTYPE html>
<html lang="en-US">
<head>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0" />
<meta http-equiv="content-type" content="text/html;charset=utf-8">
<meta name="keywords" content="JavaScript,carousel,mobile,touch,slide">
<meta name="description" content="JavaScript touch carousel with zero dependencies">
<title>ItemSlide.js - JavaScript touch carousel</title>
<style>
body {
font-family: calibri, sans-serif;
text-align: center;
margin: 0;
height: 98vh;
background-color: #8601AF;
}
#header {
width: 100%;
padding-top: 5px;
padding-bottom: 5px;
background-color: #FEFE33;
text-align: center;
}
#headertext {
text-decoration: none;
color: #8601AF;
font-size: 6.5vh;
font-weight: 400;
}
#about {
width: 90%;
margin-left: auto;
margin-right: auto;
font-size: 5vh;
color: white;
}
#about a {
font-size: 3.5vh;
color: white;
}
#footer {
position: fixed;
font-size: 2.5vh;
bottom: 0%;
padding: 0.5%;
background-color: #8601AF;
font-weight: 200;
color: white;
right: 0;
left: 0;
}
#footer .hrefs {
color: #FFF;
font-weight: 400;
text-decoration: none;
}
#scrolling {
background: #8601AF;
height: 58%;
width: 100%;
overflow: hidden;
}
#scrolling ul {
user-select: none;
margin: 0;
padding: 0;
margin-top: 3%;
height: 80%;
list-style-type: none;
transform-style: preserve-3d;
}
#scrolling ul li {
font-size: 30vh;
float: left;
width: 55vw;
max-width: 750px;
height: 100%;
color: #8601AF;
font-weight: 300;
text-align: center;
border-radius: 30px;
cursor: pointer;
background: white;
transform: scale(0.95);
}
#scrolling ul .itemslide-active {
transform: scale(1);
}
</style>
<script src="itemslide.js"></script>
<script>
var itemslide;
window.addEventListener("load", function () {
var element = document.querySelector("#scrolling ul");
itemslide = new Itemslide(element, {
swipeOut: true
});
});
window.addEventListener("resize", function () {
itemslide.reload();
});
</script>
</head>
<body>
<div id="header">
<a id="headertext" href="index.html">
ItemSlide.js
</a>
</div>
<div id="about">
<br>
JavaScript Carousel Library
<br>
<br>
<a id="github" href="https://github.com/nir9/itemslide">
Source on Github
</a>
</div>
<div id="scrolling">
<ul>
<li>
1
</li>
<li>
2
</li>
<li>
3
</li>
<li>
4
</li>
</ul>
</div>
<div id="footer">
Created by <a class="hrefs" href="https://github.com/nir9">Nir Lichtman</a>
</div>
</body>
</html>