-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
82 lines (72 loc) · 3.01 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
<!DOCTYPE html>
<html>
<head>
<title>untz club</title>
<link rel="icon" href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>🪩</text></svg>">
<link rel="stylesheet" type="text/css" href="style.css">
<meta name="viewport" content="width=device-width, minimum-scale=1.0">
<meta property='og:title' content='untz.club'/>
<meta property='og:image' content='./img/thumbnail.png'/>
<meta property='og:description' content='listen to untzes 🪩'/>
<meta property='og:url' content='https://untz.club'/>
<meta property='og:image:width' content='1200'/>
<meta property='og:image:height' content='627'/>
<meta property='og:type' content='website'/>
</head>
<body>
<h2 class="title" id="title">untz untz untz</h2>
<div id="loading"></div>
<div class="btn-container">
<div class="btn" id="playBtn"></div>
<div class="btn" id="pauseBtn"></div>
</div>
<script type="jquery" src="https://code.jquery.com/jquery-1.11.2.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/howler/2.2.4/howler.min.js"></script>
<script>
playBtn = document.getElementById('playBtn');
pauseBtn = document.getElementById('pauseBtn');
title = document.getElementById('title');
loading = document.getElementById('loading');
var sound = new Howl({
src: ['https://stream-relay-geo.ntslive.net/stream'],
html5: true,
preload: true,
onload: function() {
loading.style.display = 'none';
pauseBtn.style.display = 'block';
title.style['-webkit-animation-play-state'] = 'running';
title.style['animation-play-state'] = 'running';
},
onplay: function() {
loading.style.display = 'none';
pauseBtn.style.display = 'block';
title.style['-webkit-animation-play-state'] = 'running';
title.style['animation-play-state'] = 'running';
},
onpause: function() {
playBtn.style.display = 'block';
pauseBtn.style.display = 'none';
title.style['-webkit-animation-play-state'] = 'paused';
title.style['animation-play-state'] = 'paused';
}
});
playBtn.addEventListener('click', function() {
playBtn.style.display = 'none';
loading.style.display = 'block';
sound.play();
});
pauseBtn.addEventListener('click', function() {
sound.pause();
});
</script>
<!-- Google analytics -->
<script type="google-analytics">
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','https://www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-53076324-1', 'auto');
ga('send', 'pageview');
</script>
</body>
</html>