forked from abergs/listentotheclouds
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy paths.html
More file actions
179 lines (150 loc) · 9.05 KB
/
s.html
File metadata and controls
179 lines (150 loc) · 9.05 KB
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
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>Listen To The Clouds - Live as the world flies</title>
<meta name="description" content="Background noise while you work or relax. Listen to live streamed air traffic radio chatter." />
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta property="og:image" content="http://listentothe.cloud/share4.jpg" />
<meta property="og:type" content="website" />
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/vue/2.2.1/vue.min.js"></script>
<link rel="stylesheet" href="fonts/stylesheet.css">
<link rel="stylesheet" href="styles.css">
<script>
(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-37656767-12', 'auto');
ga('send', 'pageview');
// This will count the number of times the function runs.
pageTimer = 0;
// Periodically run the function
window.setInterval(function () {
// Increment the counter
pageTimer = pageTimer + 1
// Assumes it runs every 30 seconds
theNow = pageTimer * 60
ga('send', {
hitType: 'event',
eventCategory: 'Timer',
eventAction: theNow + ' seconds on page',
eventLabel: $(".current").first().text()
});
}, 60000); // Run every 30 seconds
</script>
</head>
<body>
<div class="video-background">
<div class="video-foreground">
<iframe id="video" src="https://www.youtube.com/embed/YgmIibSnZs0?controls=0&showinfo=0&rel=0&autoplay=1&loop=1&playlist=YgmIibSnZs0&enablejsapi=1"
frameborder="0" allowfullscreen></iframe>
</div>
</div>
<div id="live">
<span class="dot"></span>Live:   <span class="current"> Chicago</span>
</div>
<div id="noise">
Background noise while you work or relax
<p class="mobilewarning">(Works better if you are not on a mobile device... sorry)</p>
</div>
<div id="vidtop-content">
<!-- Load Facebook SDK for JavaScript -->
<div id="fb-root"></div>
<script>
(function (d, s, id) {
var js, fjs = d.getElementsByTagName(s)[0];
if (d.getElementById(id)) return;
js = d.createElement(s); js.id = id;
js.src = "//connect.facebook.net/en_GB/sdk.js#xfbml=1&version=v2.8&appId=1284548061596480";
fjs.parentNode.insertBefore(js, fjs);
}(document, 'script', 'facebook-jssdk'));
</script>
<div id="app">
<div id="vcontrols">
<div class="playpause" :data-state="isPlayingState">
<button class="button js-button">
<svg width="100%" height="100%" viewBox="0 0 36 36" >
<defs>
<path id="pause-icon" data-state="playing" d="M11,10 L17,10 17,26 11,26 M20,10 L26,10 26,26 20,26" />
<path id="play-icon" data-state="paused" d="M11,10 L18,13.74 18,22.28 11,26 M18,13.74 L26,18 26,18 18,22.28" />
</defs>
<use xlink:href="#pause-icon" />
</svg>
</button>
</div>
<button class="button nxt">❱❱</button>
<div class="clearfix"><span>
Airport chatter: </span><input id="vc_radio" type="range" min=0 max=100 value="50" /></div>
<div class="clearfix"><span>Ambient music:</span> <input id="vc_music" type="range" min=0 max=100 value="50" />
</div>
</div>
<div class="ybile">
<h1 class="ybile-r2">Listen to the clouds</h1>
<h1 class="ybile-r3">live, as the world flies</h1>
<div style="text-align:center; margin-top:60px">
<div class="fb-share-button" data-href="http://listentothe.cloud/" data-layout="button_count" data-size="large" data-mobile-iframe="true"><a class="fb-xfbml-parse-ignore" target="_blank" href="https://www.facebook.com/sharer/sharer.php?u=http%3A%2F%2Flistentothe.cloud%2F&src=sdkpreparse">Share</a></div>
</div>
<h1 style="margin-top:60px">Airports</h1>
<p class="airport-info">(This is a live radio transmission, if it's silent, the airports aren't very chatty at the moment)</p>
<div id="airports">
<div v-for="region in regions">
<h3>{{region.name}}</h3>
<ul>
<li v-for="ap in region.airports" :data-code="ap.code" class="airport" v-on:click="listenTo(ap)" v-bind:class="[{'error':ap.error}, (loading && activeCode === ap.code) ? 'loading' :'', activeCode === ap.code ? 'active' : '']">
<span class="airport-name">{{ ap.text }}</span>
<span v-if="ap.error" class="airport-error">(Offline)</span>
<span class="airport-iata">{{ ap.iata }}</span>
<div v-if="loading && activeCode === ap.code" class="borderspin" ></div>
<div v-if="loading && activeCode === ap.code" class="spinner"></div>
</li>
</ul>
</div>
</div>
<ul id="picker">
<li><a target="_blank" href="https://twitter.com/home?status=Hey%20%40andersaberg,%20I%20would%20like%20you%20to%20add%20*your%20missing%20airport*%20%23listentotheclouds">Missing your airport?</a></li>
</ul>
<!--- <p>Live: <span class="current">Chicago</span></p> -->
<audio id="stream" src="http://mtl2.liveatc.net/kord7" autoplay controls volume="0.4" style="visibility: hidden">
<p>Your browser does not support the <code>audio</code> element.</p>
</audio>
<h1 style="margin-top:3rem;">Ambient music</h1>
<p style="text-align:center">Volume: <input id="vc_control" type="range" min="0" max="100" value="100" /></p>
<div style="text-align:center;">
<iframe id="soundcloud_player_iframe" width="480" height="300" scrolling="no" frameborder="no" src=""></iframe>
</div>
<br />
<br />
<!--- <div style="text-align:center">
<p>(Question: Do you want me to add a "sleep mode" button? <a target="_blank" href="https://docs.google.com/forms/d/e/1FAIpQLSdP99Nt0q8cxDThYm-vWe9NAC0R6S_oYntoVTCq9mZK-SAjqQ/viewform">Answer here</a>)</p>
<br /></div>
!-->
<div class="thankyou">
<h1>Thank you</h1>
<p class="thankyoutext">This project was built by <a href="http://andersaberg.com">Anders Åberg</a> (<a href="http://twitter.com/andersaberg">@andersaberg</a>).
If you like this or want me to add more airports, ping me on twitter - it will make me smile. <br
/><br /> It uses a bunch of open API's, all mentioned below. Inspired by <a href=" http://youarelistening.to/">You are listening to</a>.
Thank you <a href="http://www.liveatc.net/">Live ATC</a> for live feeds of flight radio. The video
background is from <a href="https://www.youtube.com/watch?v=YgmIibSnZs0">this youtube clip</a>. Some CSS animations are from the beautiful <a href="http://tobiasahlin.com/spinkit/">SpinKit project</a> by Tobias Ahlin. And
the ambient music playing from soundcloud is linked above. Built with love and whipped cream by Anders.
</div>
<div style="text-align:center" class="donate">
<p>Would you donate to support this?</p>
<div id="supportbtns">
<button id="yesbtn" @click="donateYes">Yes</button><button id="nobtn" @click="donateNo">No</button></div>
<div id="support">
<a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=QESTW8XN5RYTL" target="_blank" class="btn">Thank you - Click here to donate any amount you want</a>
</div>
</div>
</div>
</div>
</div>
<script src="https://w.soundcloud.com/player/api.js"></script>
<script src="app.js"></script>
<script src="http://d3js.org/d3.v3.min.js"></script>
<script src="playbutton.js"></script>
</body>
</html>