-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
42 lines (42 loc) · 1.38 KB
/
index.html
File metadata and controls
42 lines (42 loc) · 1.38 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<script src='https://api.mapbox.com/mapbox-gl-js/v2.9.1/mapbox-gl.js'></script>
<link href='https://api.mapbox.com/mapbox-gl-js/v2.9.1/mapbox-gl.css' rel='stylesheet' />
<script src="https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-directions/v4.3.1/mapbox-gl-directions.js"></script>
<link rel="stylesheet" href="https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-directions/v4.3.1/mapbox-gl-directions.css" type="text/css">
<title>CleanCommute</title>
<style>
body {
margin: 0;
}
#map {
height: 100vh;
width: 100vw;
}
.eco-score-box {
position: absolute;
top: 10px;
right: 10px;
background-color: #d4edda;
color: #155724;
padding: 10px 15px;
border-radius: 8px;
box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.1);
font-weight: bold;
font-size: 1rem;
z-index: 1000;
display: none;
}
</style>
</head>
<body>
<div id='map'></div>
<div class="eco-score-box" id="eco-score-box">
Eco Score: <span id="eco-score-value">0</span>%
</div>
<script src="script.js" defer></script>
</body>
</html>