-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathindex.html
executable file
·193 lines (184 loc) · 6.2 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
<!DOCTYPE html>
<html lang="en">
<head>
<title>Crash Model: Home</title>
<!-- METADATA -->
<meta charset="utf-8" />
<meta
name="viewport"
content="width=device-width, initial-scale=1, shrink-to-fit=no"
/>
<!-- STYLESHEETS -->
<link href="vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet" />
<link href="css/style.css" rel="stylesheet" />
<link href="css/the-big-picture.css" rel="stylesheet" />
<link
rel="stylesheet"
href="https://unpkg.com/[email protected]/dist/leaflet.css"
integrity="sha512-Rksm5RenBEKSKFjgI3a41vrjkw4EVPlJ3+OiI65vTjIdo9brlAacEuKOiQ5OFh7cOI1bkDwLqdLw3Zg0cRJAAQ=="
crossorigin=""
/>
<link
rel="stylesheet"
href="https://unpkg.com/[email protected]/dist/MarkerCluster.css"
/>
<link
rel="stylesheet"
href="https://unpkg.com/[email protected]/dist/MarkerCluster.Default.css"
/>
<!-- JS FILES -->
<script
src="https://unpkg.com/[email protected]/dist/leaflet.js"
integrity="sha512-/Nsx9X4HebavoBvEBuyp3I7od5tA0UzAxs+j83KgC8PU0kgB4XiK4Lfe4y4cgBtaRJQEIFCW+oC506aPT2L1zw=="
crossorigin=""
></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://unpkg.com/[email protected]/dist/leaflet.markercluster.js"></script>
<script src="vendor/jquery/jquery.min.js"></script>
<script src="vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
</head>
<body>
<!-- Navigation -->
<nav class="navbar navbar-expand-lg navbar-dark bg-dark fixed-bottom">
<div class="container">
<a class="navbar-brand" href="#">Crash Model</a>
<button
class="navbar-toggler"
type="button"
data-toggle="collapse"
data-target="#navbarResponsive"
aria-controls="navbarResponsive"
aria-expanded="false"
aria-label="Toggle navigation"
>
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarResponsive">
<ul class="navbar-nav ml-auto">
<li class="nav-item active">
<a class="nav-link" href="index.html"
>Home <span class="sr-only">(current)</span>
</a>
</li>
<li class="nav-item"><a class="nav-link" href="#">About</a></li>
<li class="nav-item"><a class="nav-link" href="#">Services</a></li>
<li class="nav-item">
<a class="nav-link" href="contact.html">Contact</a>
</li>
<li class="nav-item">
<a class="nav-link" id="locations" href="javascript:;"
>Locations</a
>
</li>
</ul>
</div>
</div>
</nav>
<!-- Page Content -->
<section>
<div class="container">
<div class="row" style="font-size: 0.7em; background: black;">
<div
class="col-lg-9"
style="right: 0px; height: 100%; position: fixed;"
>
<div id="mapid"></div>
</div>
<div
class="col-lg-3"
style="background: white; height: 100%; position: fixed; left: 0px; "
>
<h1 class="mt-5">Crash Model</h1>
<p>
The most dangerous traffic signals based on the number of
pedestrian and bike crashes.
</p>
<h3>Legend</h3>
<table>
<tr>
<td>
<input
type="checkbox"
id="trafficSignalToggle"
checked="checked"
/>
<img
style="padding-right:10px"
src="img/traffic-light-256.png"
width="30"
/>
</td>
<td>Traffic Signal</td>
</tr>
<tr>
<td>
<input
type="checkbox"
id="bikeCrashesToggle"
checked="checked"
/>
<img
style="padding-right:10px"
src="img/map-marker-2-xxl.png"
width="30"
/>
</td>
<td>Bike Crash</td>
</tr>
<tr>
<td>
<input
type="checkbox"
id="pedestrianCrashesToggle"
checked="checked"
/>
<img
style="padding-right:10px"
src="img/map-marker-2-xxl 2.png"
width="30"
/>
</td>
<td>Pedestrian Crash</td>
</tr>
<tr>
<td>
<input
type="checkbox"
id="redCirclesToggle"
checked="checked"
/>
<img
style="padding-right:10px"
src="img/radius.png"
width="30"
/>
</td>
<td>Num Crashes within 0.2km (radius = num)</td>
</tr>
</table>
<h3>Instructions</h3>
<p>
Use the mouse and scroll wheel to navigate the map. Double click
on a cluster to zoom into it. Single click on cluster to see
makers within it.
</p>
</div>
</div>
</div>
</section>
<div id="loader">Loading. Please wait.</div>
<div id="sidebar" class="card" style="width: 18rem;">
<div class="card-body" id="traffic_locations">
<h5 class="card-title">Top Accident Locations</h5>
<h6 style="margin-top: -10px; padding-bottom: 15px;">(Sorted Highest to Lowest Risk)</h6>
</div>
</div>
<script src="js/global_variables.js"></script>
<script src="js/geo_functions.js"></script>
<script src="js/crash_model.js"></script>
<script src="js/event_handlers.js"></script>
<script>
startApp();
</script>
</body>
</html>