-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathindex.html
345 lines (314 loc) · 12 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
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
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
<!DOCTYPE html>
<html translate="no">
<head>
<title>SuperTunnel Simulator</title>
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"
/>
<meta
name="description"
content="Simulate a hole through Earth and learn where you would end up if you were to dig in that direction"
/>
<link rel="manifest" href="manifest.json" />
<link rel="icon" href="/assets/icons/favicon.ico" />
<link
rel="icon"
type="image/png"
sizes="32x32"
href="/assets/icons/favicon-32x32.png"
/>
<link
rel="icon"
type="image/png"
sizes="16x16"
href="/assets/icons/favicon-16x16.png"
/>
<link
rel="apple-touch-icon"
sizes="180x180"
href="/assets/icons/apple-touch-icon.png"
/>
<link rel="stylesheet" href="css/app.css" />
</head>
<body>
<div
class="app"
data-loading="true"
data-step="1"
data-grabbing="false"
data-search="unsearched"
data-geolocation="unlocated"
data-mode="third-person"
data-record="false"
data-level="hard"
>
<div class="background">
<canvas class="canvas"></canvas>
<span class="label label-origin"></span>
<span class="label label-distance"></span>
<span class="label label-destination"></span>
<span class="label label-destination fixed"></span>
</div>
<div class="foreground">
<header>
<div class="logo">
<img
src="assets/logo.svg"
alt="Symbol consisting of simplified globe that is cut by a tunnel, from east to west"
/>
<h1>
<span>SuperTunnel</span>
<span>Simulator</span>
</h1>
</div>
<nav>
<a
href="https://vsueiro.com/work/supertunnel"
target="_blank"
aria-label="About"
>
<svg
class="icon icon-info"
width="24"
height="24"
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill="currentColor"
fill-rule="evenodd"
clip-rule="evenodd"
d="M13 17V11H11V17H13ZM2 12C2 6.48 6.48 2 12 2C17.52 2 22 6.48 22 12C22 17.52 17.52 22 12 22C6.48 22 2 17.52 2 12ZM4 12C4 16.41 7.59 20 12 20C16.41 20 20 16.41 20 12C20 7.59 16.41 4 12 4C7.59 4 4 7.59 4 12ZM12 9.25C12.6904 9.25 13.25 8.69036 13.25 8C13.25 7.30964 12.6904 6.75 12 6.75C11.3096 6.75 10.75 7.30964 10.75 8C10.75 8.69036 11.3096 9.25 12 9.25Z"
/>
</svg>
</a>
</nav>
</header>
<main>
<section class="origin">
<header>
<h2>
Origin: <span class="label label-coordinates">0°N, 0°S</span>
</h2>
<span class="label label-origin" style="display: none"></span>
</header>
<form>
<label for="address">Enter your address:</label>
<div class="search-container">
<input
type="search"
name="address"
value=""
placeholder="City, Country"
/>
<button type="submit">
<svg
class="icon icon-search"
width="24"
height="24"
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill="currentColor"
fill-rule="evenodd"
clip-rule="evenodd"
d="M4.99995 10.0001C4.99995 7.2387 7.23853 5.00012 9.99995 5.00012C12.7614 5.00012 15 7.2387 15 10.0001C15 12.7615 12.7614 15.0001 9.99995 15.0001C7.23853 15.0001 4.99995 12.7615 4.99995 10.0001ZM9.99995 3.00012C6.13396 3.00012 2.99995 6.13413 2.99995 10.0001C2.99995 13.8661 6.13396 17.0001 9.99995 17.0001C11.5723 17.0001 13.0236 16.4817 14.1922 15.6065L19.7782 21.1925L21.1924 19.7783L15.6064 14.1922C16.4816 13.0237 17 11.5724 17 10.0001C17 6.13413 13.8659 3.00012 9.99995 3.00012Z"
/>
</svg>
</button>
</div>
<div></div>
<p>Or enable geolocation:</p>
<button type="button" class="find">
<svg
class="icon icon-location"
width="24"
height="24"
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill="currentColor"
fill-rule="evenodd"
clip-rule="evenodd"
d="M11 3H13V5.07089C16.0657 5.5094 18.4906 7.93431 18.9291 11H21V13H18.9291C18.4906 16.0657 16.0657 18.4906 13 18.9291V21H11V18.9291C7.93431 18.4906 5.5094 16.0657 5.07089 13H3V11H5.07089C5.5094 7.93431 7.93431 5.5094 11 5.07089V3ZM7 12C7 9.23858 9.23858 7 12 7C14.7614 7 17 9.23858 17 12C17 14.7614 14.7614 17 12 17C9.23858 17 7 14.7614 7 12ZM12 14C13.1046 14 14 13.1046 14 12C14 10.8954 13.1046 10 12 10C10.8954 10 10 10.8954 10 12C10 13.1046 10.8954 14 12 14Z"
/>
</svg>
<span>Get my position</span>
<span>Locating...</span>
<span>Found you</span>
</button>
</form>
<p class="tip">
Simulate a tunnel through Earth, starting from where you are
</p>
</section>
<section class="direction">
<header>
<h2>
Direction: <span class="label label-direction">0°N, 0°S</span>
</h2>
</header>
<div class="rose">
<div class="backlights">
<div class="backlight"></div>
<div class="backlight"></div>
<div class="backlight"></div>
<div class="backlight"></div>
<div class="backlight"></div>
</div>
<div class="directions">
<div class="north-south"></div>
<div class="east-west"></div>
<div class="draggable-area">
<div class="draggable-handle"></div>
</div>
</div>
</div>
<p class="tip">
Drag handle to dig a virtual tunnel towards that angle
</p>
</section>
<ol class="steps">
<li class="step">
<div>
<p>
Simulate a tunnel through Earth, starting from where you are
</p>
<p class="note">Your data is safe, as it is never stored</p>
</div>
<button class="find">
<span>Get my location</span>
<span>Locating...</span>
</button>
</li>
<li class="step">
<div>
<p>
Unable to find your location. <br />Please type in your
address:
</p>
<p class="note">Your data is safe, as it is never stored</p>
</div>
<form action=".">
<div class="search-container">
<input
type="search"
name="address"
value=""
placeholder="City, Country"
/>
<button type="submit">
<svg
class="icon icon-search"
width="24"
height="24"
viewBox="0 0 24 24"
xmlns="http://www.w3.org/2000/svg"
>
<path
fill="currentColor"
fill-rule="evenodd"
clip-rule="evenodd"
d="M4.99995 10.0001C4.99995 7.2387 7.23853 5.00012 9.99995 5.00012C12.7614 5.00012 15 7.2387 15 10.0001C15 12.7615 12.7614 15.0001 9.99995 15.0001C7.23853 15.0001 4.99995 12.7615 4.99995 10.0001ZM9.99995 3.00012C6.13396 3.00012 2.99995 6.13413 2.99995 10.0001C2.99995 13.8661 6.13396 17.0001 9.99995 17.0001C11.5723 17.0001 13.0236 16.4817 14.1922 15.6065L19.7782 21.1925L21.1924 19.7783L15.6064 14.1922C16.4816 13.0237 17 11.5724 17 10.0001C17 6.13413 13.8659 3.00012 9.99995 3.00012Z"
/>
</svg>
</button>
</div>
</form>
</li>
<li class="step">
<button class="next success">
<span>Found you</span>
</button>
</li>
<li class="step">
<div>
<p>
If you were to dig a tunnel straight down, you would reach the
<strong class="water">ocean</strong> on the other side
</p>
<p>
If you were to dig a tunnel straight down, you would reach the
<strong class="land">country</strong> highlighted above
</p>
</div>
<button class="next">
<span>Try other angles</span>
</button>
</li>
<li class="step">
<div>
<figure class="illustrations">
<img src="assets/phone/lock.svg" />
</figure>
<p class="note">Please lock your device to portrait mode</p>
</div>
<div>
<figure class="illustrations">
<div class="placeholder">
<div class="illustration"></div>
<div class="illustration"></div>
<div class="illustration"></div>
<div class="illustration"></div>
</div>
</figure>
<p class="note">Try new angles by moving your phone</p>
</div>
<button class="track">
<span>Enable motion sensor</span>
</button>
</li>
<li class="step">
<div>
<figure>
<div class="compass">
<div class="needle"></div>
</div>
</figure>
<!--<p class="note">Tip: it’s easier when you’re facing North</p>-->
</div>
<button class="track" disabled>
<span class="label label-distance"></span>
</button>
<a class="button" href="#" download>Save motion records</a>
</li>
</ol>
</main>
<footer>
<p>
Created by
<a href="https://vsueiro.com/" target="_blank">Vinicius Sueiro</a>
</p>
<p>
<a
href="http://urn.kb.se/resolve?urn=urn:nbn:se:mau:diva-45767"
target="_blank"
>Thesis project</a
>
for the
<a
href="https://mau.se/en/study-education/programme/taine"
target="_blank"
>Interaction Design</a
>
master’s at
<a href="https://mau.se/en/" target="_blank">Malmö University</a>
</p>
</footer>
</div>
<div class="loader"></div>
</div>
<!-- https://unpkg.com/browse/[email protected]/build/three.min.js -->
<script src="js/three.min.js"></script>
<!-- https://unpkg.com/browse/[email protected]/examples/js/controls/OrbitControls.js -->
<script src="js/OrbitControls.js"></script>
<!-- https://unpkg.com/browse/[email protected]/examples/js/renderers/CSS2DRenderer.js -->
<script src="js/CSS2DRenderer.js"></script>
<!-- Custom -->
<script src="js/app.js"></script>
</body>
</html>