-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
64 lines (63 loc) · 1.81 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>touch</title>
<meta name="viewport" content="width=device-width,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0,user-scalable=no">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
<meta content="telephone=no" name="format-detection">
<meta name="apple-touch-fullscreen" content="yes">
<script>
var calculate_size = function () {
var BASE_FONT_SIZE = 100, docEl = document.documentElement, clientWidth = docEl.clientWidth;
if (clientWidth) {
docEl.style.fontSize = BASE_FONT_SIZE * (clientWidth / 750) + 'px';
}
};
// Abort if browser does not support addEventListener
if (document.addEventListener) {
var resizeEvt = 'orientationchange' in window ? 'orientationchange' : 'resize';
window.addEventListener(resizeEvt, calculate_size, false);
document.addEventListener('DOMContentLoaded', calculate_size, false);
calculate_size();
}
</script>
</head>
<body>
<div id="fullscreen">
</div>
</body>
<script src="./index.js"></script>
<script>
new Touchtab({
wrap: document.getElementById('fullscreen'),
list: [
'img/1.jpg',
'img/2.jpg',
'img/3.jpg',
'img/4.jpg',
'img/5.jpg',
'img/6.jpg',
'img/7.jpg'
]
})
</script>
<style>
*{margin: 0; padding: 0}
html, body {
height: 100%; background: #000;
}
#fullscreen {
height: 100%; overflow: hidden; width: 100%;
}
ul,li {
list-style: none;
}
.outer {
display: flex; height: 100%;flex-wrap:nowrap; transition: transform .2s ease-out;
}
.outer li {
display: flex; align-items:center;
}
</style>
</html>