-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
135 lines (126 loc) · 3.32 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
<!DOCTYPE html>
<html>
<head>
<title>OLR Loop Viewer</title>
<link rel='icon' href='icon.ico' type='image/x-icon'/ >
<link rel="preconnect" href="https://fonts.gstatic.com" />
<link
href="https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400&display=swap"
rel="stylesheet"
/>
<style>
#legend {
position: absolute;
bottom: -4px;
left: 0;
}
#legendImage {
width: 700px;
}
#diagram {
width: 100%;
}
#note {
font-size: small;
}
h1 {
font-family: "Open Sans", sans-serif;
font-weight: 400;
}
p {
font-family: "Open Sans", sans-serif;
font-weight: 300;
}
.modal {
display: block;
position: fixed;
z-index: 1;
padding-top: 100px;
left: 0;
top: 0;
width: 100%;
height: 100%;
overflow: auto;
background-color: rgb(0, 0, 0);
background-color: rgba(0, 0, 0, 0.4);
}
.modal-content {
background-color: #fefefe;
margin: auto;
padding: 20px;
border: 1px solid #888;
width: 80%;
}
.close {
color: #aaaaaa;
float: right;
font-size: 28px;
font-weight: bold;
}
.close:hover,
.close:focus {
color: #000;
text-decoration: none;
cursor: pointer;
}
@media only screen and (max-device-width: 700px) {
#legendImage {
width: 100vw;
}
}
</style>
</head>
<body style="background-color: black; margin: 0; padding: 0">
<div
id="openseadragon1"
style="width: 100vw; height: 100vh; background: black"
></div>
<div id="legend">
<img id="legendImage" src="Legend.jpg" alt="Legend" />
</div>
<div id="welcomeModal" class="modal">
<div class="modal-content">
<span class="close">×</span>
<h1>Welcome to the OLR Loop Viewer!</h1>
<p>Zoom in to see the individual OLR loops for each location.</p>
<p>
Each loop is labelled with it's coordinates in the form [ latitude,
longitude ] and each month is coloured according to the legend at the
bottom of the screen.
</p>
<img id="diagram" src="diagram.png" alt="Legend" />
<p id="note">
Note: this viewer has been deigned for, and works best on, Google
Chrome.
</p>
</div>
</div>
<script src="./openseadragon/openseadragon.min.js"></script>
<script type="text/javascript">
OpenSeadragon.pixelDensityRatio = 1;
let viewer = OpenSeadragon({
id: "openseadragon1",
prefixUrl: "./openseadragon/images/",
tileSources: {
type: "zoomifytileservice",
height: 24598,
width: 50220,
tilesUrl: "Highres/",
},
showNavigator: true,
});
</script>
<script>
let modal = document.getElementById("welcomeModal");
let span = document.getElementsByClassName("close")[0];
span.onclick = function () {
modal.style.display = "none";
};
window.onclick = function (event) {
if (event.target == modal) {
modal.style.display = "none";
}
};
</script>
</body>
</html>