This repository has been archived by the owner on May 7, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
friends.html
63 lines (58 loc) · 1.92 KB
/
friends.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
<!DOCTYPE html>
<html class="no-js" lang="en" color-mode="dark">
<head>
<meta charset="utf-8" />
<meta http-equiv="x-ua-compatible" content="ie=edge" />
<title>L's CeroSnapshot</title>
<meta name="description" content="" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<link
rel="stylesheet"
href="https://unpkg.com/leaflet%401.8.0/dist/leaflet.css"
integrity="sha512-hoalWLoI8r4UszCkZ5kL8vayOGVae1oxXe/2A4AO6J9+580uKHDO3JdHb7NzwwzK5xr/Fs0W40kiNHxM9vyTtQ=="
crossorigin=""
/>
<link rel="stylesheet" href="https://unpkg.com/mvp.css%401.10.2/mvp.css" />
<style type="text/css" media="screen">
#map {
height: 360px;
}
</style>
</head>
<body>
<main>
<div id="map"></div>
</main>
<section>
<b>Visitors: </b>@visitors
</section>
<footer>
Made with ♥ with
<a href="https://github.com/vlang/v"
><img
style="height: 1em"
src="https://vlang.io/img/v-logo.png"
/>lang.io</a
>
</footer>
<!-- Make sure you put this AFTER Leaflet's CSS -->
<script
src="https://unpkg.com/leaflet%401.8.0/dist/leaflet.js"
integrity="sha512-BB3hKbKWOc9Ez/TAwyWxNXeoV9c1v6FIeYiBieIWkpLjauysF18NzgR1MBNBXf8/KABdlkX68nAhlwcDFLGPCQ=="
crossorigin=""
></script>
<script type="text/javascript">
var map = L.map("map").setView([45.890008, -10.942383], 3);
L.tileLayer("https://tile.openstreetmap.org/{z}/{x}/{y}.png", {
maxZoom: 12,
attribution: "© OpenStreetMap",
}).addTo(map);
var marker = L.marker([@myself.lat, @myself.lon]).addTo(map);
marker.bindPopup("<b>Hello world!</b><br>Come over for a beer :)").openPopup();
@for friend in located_friends
marker = L.marker([@friend.lat, @friend.lon]).addTo(map);
marker.bindPopup("@friend.name");
@end
</script>
</body>
</html>