-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
189 lines (171 loc) · 7.91 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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Water Around the World</title>
<!-- Bulma.io for CSS -->
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/bulma/0.7.2/css/bulma.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma-extensions@4.0.0/bulma-slider/dist/css/bulma-slider.min.css">
<script src="js/bulmaextension.js"></script>
<!-- Font Awesome Icons -->
<script defer src="https://use.fontawesome.com/releases/v5.6.1/js/all.js" integrity="sha384-R5JkiUweZpJjELPWqttAYmYM1P3SNEJRM6ecTQF05pFFtxmCO+Y1CiUhvuDzgSVZ" crossorigin="anonymous"></script>
<!-- D3.js for visualizations -->
<script src="https://d3js.org/d3.v4.js"></script>
<script src="https://d3js.org/d3-scale-chromatic.v1.min.js"></script>
<!-- Custom CSS -->
<link rel="stylesheet" href="css/style.css">
</head>
<body>
<!-- Hero with title and subtitle -->
<section class="hero is-info is-medium">
<div class="hero-body">
<div class="columns">
<div class="column is-12">
<div class="container content has-text-centered">
<h1 class="title is-size-1">Water Around the World</h1>
<h2 class="subtitle is-size-2">Disparities in Urban and Rural Areas</h2>
</div>
</div>
</div>
</div>
</section>
<!-- Hero with Background and Purpose -->
<section class="hero is-light">
<div class="hero-body">
<div class="container">
<div class="columns">
<div class="column is-offset-2 is-8">
<h3 class="title is-size-3">Background and Purpose</h3>
<p>With the use data from the AQUASTAT Database, this visualization aims to inform people of the disparities in drinking water around the world. Although clean drinking water is a necessity in life, not everyone has access to it, and there is an even clearer distinction between those living in urban and rural areas. This project uses a choropleth to geographically show the percentage of the population with clean drinking water for both urban and rural areas, which provides a better understanding of where the regions of water disparity are located. It also uses bar charts to help show the water disparity for selected countries of interest.</p>
</div>
</div>
</div>
</div>
</section>
<!-- Hero with choropleth -->
<section class="hero">
<div class="hero-body">
<div class="container has-text-centered">
<div class="columns">
<div class="column is-offset-2 is-8">
<h3 class="title is-size-3 has-text-left">Choropleth Map of Water Disparities Worldwide</h3>
</div>
</div>
<div class="columns">
<div class="column is-offset-3 is is-6">
<article class="message is-info">
<div class="message-header">
<p>Filter Options</p>>
</div>
<div class="message-body">
<!-- Radio buttons to select data -->
<label class="radio">
<input class="map-filter" type="radio" name="population" value="total" checked>
Total Population
</label>
<label class="radio">
<input class="map-filter" type="radio" name="population" value="urban">
Urban Population
</label>
<label class="radio">
<input class="map-filter" type="radio" name="population" value="rural">
Rural Population
</label>
</div>
</article>
</div>
</div>
<div class="vis">
<svg id="svgMap" width="1000" height="550"></svg>
</div>
</div>
</div>
</section>
<!-- Hero with bar chart -->
<section class="hero is-light">
<div class="hero-body">
<div class="container has-text-centered">
<div class="columns">
<div class="column is-offset-2 is-8">
<h3 class="title is-size-3 has-text-left">Water Disparities in Selected Countries</h3>
</div>
</div>
<div class="columns">
<div class="column is-offset-1 is-4">
<div class="vis">
<svg id="svgBarChart" width="500" height="600"></svg>
</div>
</div>
<!-- Display options box -->
<div class="column is-offset-2 is-4">
<article class="message is-info">
<div class="message-header">
<p>Display Options</p>
</div>
<div class="message-body">
<p class="is-size-5">Sort Order</p>
<label class="radio">
<input class="chart-filter" type="radio" name="sort" value="ascending" checked>
Ascending
</label>
<label class="radio">
<input class="chart-filter" type="radio" name="sort" value="descending">
Descending
</label>
<br><br>
<p class="is-size-5">Max Number of Countries</p>
<div class="columns">
<div class="column is-2">
<p>Max: <output for="num-countries">25</output></p>
</div>
<div class="column">
<input id="num-countries" class="slider is-fullwidth chart-filter" step="1" min="5" max="45" value="25" type="range">
</div>
</div>
<p class="is-size-5">Population Type</p>
<label class="radio">
<input class="chart-filter" type="radio" name="population-type" value="total" checked>
Total
</label>
<label class="radio">
<input class="chart-filter" type="radio" name="population-type" value="urban">
Urban
</label>
<label class="radio">
<input class="chart-filter" type="radio" name="population-type" value="rural">
Rural
</label>
<br><br>
<p class="is-size-5">Percentage Range</p>
<div class="columns">
<div class="column is-2">
<p>Min: <output for="min">0</output></p>
</div>
<div class="column">
<input id="min" class="slider is-fullwidth chart-filter" step="1" min="0" max="100" value="0" type="range">
</div>
</div>
<div class="columns">
<div class="column is-2">
<p>Max: <output for="max">100</output></p>
</div>
<div class="column">
<input id="max" class="slider is-fullwidth chart-filter" step="1" min="0" max="100" value="100" type="range">
</div>
</div>
<label class="checkbox">
<input class="chart-filter" type="checkbox" name="100-percent" checked>
Include countries with 100% access to safe drinking water
</label>
<br><br>
</div>
</article>
</div>
</div>
</div>
</div>
</section>
<script src="js/visuals.js"></script>
</body>
</html>