-
Notifications
You must be signed in to change notification settings - Fork 1
/
index.html
80 lines (68 loc) · 1.86 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
<html>
<head>
<style type="text/css">
@import url('https://fonts.googleapis.com/css?family=Roboto+Condensed:400,400i');
html, body {
margin: 0;
padding: 0;
width: 1920px;
height: 1080px;
overflow: hidden;
}
main {
width: 1920px;
height: 1080px;
border: solid 1px grey;
position: relative;
margin: 0;
}
logo {
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 970px;
}
logo img {
margin: 0 auto;
display: block;
}
.navigation {
transition: opacity 0.5s ease-in-out;
opacity: 0;
position: absolute;
top: 0;
left: 0;
}
.navigation.visible {
opacity: 1 !important;
}
</style>
<script language="javascript">
var interval = 4200;
var languages = ['en', 'fr'];
var langIdx = 0
document.addEventListener('DOMContentLoaded', function(event) {
setInterval(function(){
langIdx++;
if (langIdx >= languages.length) {
langIdx = 0;
}
var elements = document.querySelectorAll('.navigation');
for (var i=0; i<elements.length; i++) {
elements[i].classList.remove('visible');
}
var element = document.querySelector('#navigation-' + languages[langIdx]);
element.classList.add('visible');
}, interval);
});
</script>
</head>
<body>
<main>
<logo><img src="./images/logo.png" /></logo>
<div id="navigation-fr" class="navigation"><object data="./images/navigation-fr.svg" type="image/svg+xml"></object></div>
<div id="navigation-en" class="navigation"><object data="./images/navigation-en.svg" type="image/svg+xml"></object></div>
</main>
</body>
</html>