-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathWeather.html
More file actions
41 lines (38 loc) · 828 Bytes
/
Weather.html
File metadata and controls
41 lines (38 loc) · 828 Bytes
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
<!doctype html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1" />
<style>
html, body {
margin: 0;
padding: 0;
background: transparent;
height: 100%;
}
.ratio {
width: 100%;
aspect-ratio: 2 / 1;
overflow: hidden;
border-radius: 8px;
position: relative;
}
.ratio img {
position: absolute;
inset: 0;
width: 100%;
height: 100%;
object-fit: contain;
display: block;
}
</style>
</head>
<body>
<div class="ratio">
<img id="m" alt="meteogram">
</div>
<script>
const base = "https://www.yr.no/en/content/2-1796236/meteogram.svg";
document.getElementById("m").src = base + "?v=" + Date.now();
</script>
</body>
</html>