Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Empty file added .Rhistory
Empty file.
25 changes: 0 additions & 25 deletions .github/workflows/lint-css-files.yml

This file was deleted.

25 changes: 0 additions & 25 deletions .github/workflows/lint-js-files.yml

This file was deleted.

65 changes: 64 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,64 @@
Add a readme for your engagement tool here. Include content overview, data citations, and any relevant technical details.
# Hangzhou Central District Flood Reporting System

**Resident-Focused Urban Inundation Reporting Tool**
[Project Link](https://haoyu25.github.io/engagement-project/)

An interactive web-based system designed for **residents of Hangzhou’s central districts** to report urban flooding events. This tool empowers residents to actively participate in flood monitoring, providing spatially referenced data for city planners and emergency management.

## Purpose

1. Collect real-time flood data from residents to inform city planning and disaster response.
2. Provide an intuitive platform for residents to report inundation events with detailed information including location, date, time, water depth, and type of situation.
3. Visualize flood patterns across the central districts of Hangzhou through maps, markers, and heatmaps.

## Features

- **Interactive Map**
- Overview of Hangzhou Central Districts with zoom and pan functionality.
- Multiple layers: roads, water bodies, parks, metro stations, amenities, and resident-submitted flood points.
- Dynamic heatmap showing concentration of flood events.

- **Resident Flood Reporting**
- Select a location on the map to report a flooding event.
- Input date, time, water depth, situation type, and optional description.
- Submitted reports are displayed as interactive markers with popups containing details.

- **Filtering and Exploration**
- Filter reports by date range and water depth (shallow, moderate, deep, severe).
- Click on markers to view detailed information about each flood report.
- Statistics display total reports and reports for today.

- **User-Friendly Interface**
- Language toggle (Chinese/English).
- Clear, accessible design suitable for all residents.

## Technologies Used

- Frontend: HTML5, CSS3, JavaScript (ES6 modules)
- Mapping: Leaflet and Leaflet.heat
- Date/Time Selection: Flatpickr
- Data Storage: Firestore (for storing resident flood reports)

## How It Works

1. Residents click on the map to select a location of flooding.
2. They fill in the date, time, water depth, situation type, and optionally add a description.
3. Reports are saved in the backend and displayed on the map as markers.
4. Reports can be filtered and explored to visualize flooding patterns across neighborhoods.
5. Heatmap highlights areas with the highest frequency of flooding reports.

## Intended Users

- Residents: to report real-time flooding events.
- City Planners & Emergency Managers: to use community-sourced data for urban planning, flood mitigation, and emergency response.

## Data Sources

- **Inundation Risk Index:** From one of the author's projects: [Hangzhou Flooding Risk Detection](https://github.com/haoyu25/Hangzhou-Flooding-Risk-Detect)
- **Amenity and Station POIs:** GaoDe Open Platform ([高德开放平台](https://lbs.amap.com/))

## Team Contributions

- **Annie**: Web page framework setup.
- **Haoyu**: Data collection and processing, Firebase integration, heatmap implementation.
- **Meixi**: Accessibility features and visual optimization.
8 changes: 8 additions & 0 deletions data/HZ_Center.geojson
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"type": "FeatureCollection",
"name": "HZ_Center",
"crs": { "type": "name", "properties": { "name": "urn:ogc:def:crs:OGC:1.3:CRS84" } },
"features": [
{ "type": "Feature", "properties": { "name": "杭州中心城区 Central District of Hangzhou" }, "geometry": { "type": "Polygon", "coordinates": [ [ [ 120.610401, 30.171272 ], [ 120.606001, 30.154207 ], [ 120.594664, 30.148139 ], [ 120.546929, 30.159982 ], [ 120.51196, 30.156909 ], [ 120.491672, 30.174433 ], [ 120.456653, 30.16842 ], [ 120.458553, 30.161703 ], [ 120.45493, 30.155441 ], [ 120.446348, 30.151909 ], [ 120.435382, 30.136685 ], [ 120.421978, 30.132702 ], [ 120.421489, 30.146614 ], [ 120.416455, 30.155138 ], [ 120.406275, 30.151896 ], [ 120.406897, 30.134056 ], [ 120.400156, 30.13184 ], [ 120.381266, 30.159711 ], [ 120.3483, 30.153928 ], [ 120.335046, 30.144353 ], [ 120.322965, 30.127202 ], [ 120.312851, 30.131602 ], [ 120.308537, 30.140115 ], [ 120.295217, 30.132434 ], [ 120.293385, 30.129496 ], [ 120.299691, 30.128219 ], [ 120.282664, 30.109688 ], [ 120.283798, 30.104993 ], [ 120.292274, 30.100406 ], [ 120.310751, 30.106876 ], [ 120.319152, 30.10071 ], [ 120.325493, 30.104009 ], [ 120.330776, 30.096378 ], [ 120.327707, 30.0789 ], [ 120.333085, 30.061508 ], [ 120.326795, 30.053988 ], [ 120.320203, 30.052808 ], [ 120.319667, 30.048085 ], [ 120.34359, 30.033297 ], [ 120.355187, 30.00668 ], [ 120.353999, 29.995553 ], [ 120.3598, 29.981876 ], [ 120.357402, 29.976926 ], [ 120.339454, 29.976694 ], [ 120.336205, 29.958818 ], [ 120.32278, 29.948417 ], [ 120.31042, 29.930995 ], [ 120.286816, 29.937009 ], [ 120.277728, 29.923768 ], [ 120.268634, 29.922615 ], [ 120.260507, 29.925183 ], [ 120.260332, 29.93438 ], [ 120.251843, 29.944724 ], [ 120.239265, 29.941203 ], [ 120.218277, 29.94461 ], [ 120.206631, 29.939094 ], [ 120.217125, 29.935901 ], [ 120.215652, 29.93171 ], [ 120.197859, 29.935796 ], [ 120.195207, 29.932565 ], [ 120.200206, 29.924624 ], [ 120.182873, 29.906987 ], [ 120.174035, 29.910633 ], [ 120.169588, 29.917909 ], [ 120.161406, 29.919083 ], [ 120.145432, 29.907574 ], [ 120.142058, 29.897038 ], [ 120.144246, 29.884426 ], [ 120.137183, 29.872903 ], [ 120.128125, 29.861601 ], [ 120.108491, 29.848878 ], [ 120.09931, 29.849054 ], [ 120.072705, 29.890074 ], [ 120.078321, 29.894575 ], [ 120.085051, 29.918522 ], [ 120.091298, 29.922497 ], [ 120.096649, 29.939418 ], [ 120.08911, 29.946749 ], [ 120.088879, 29.953599 ], [ 120.097835, 29.961919 ], [ 120.100466, 29.980846 ], [ 120.120807, 29.996002 ], [ 120.125889, 30.00647 ], [ 120.131942, 30.031085 ], [ 120.129572, 30.046471 ], [ 120.119823, 30.050801 ], [ 120.13172, 30.061302 ], [ 120.129601, 30.082737 ], [ 120.14389, 30.091716 ], [ 120.14058, 30.099979 ], [ 120.124695, 30.101187 ], [ 120.108594, 30.084514 ], [ 120.079598, 30.081555 ], [ 120.055206, 30.095157 ], [ 120.044889, 30.091287 ], [ 120.025797, 30.09875 ], [ 120.007369, 30.118024 ], [ 119.997556, 30.118511 ], [ 120.014479, 30.166084 ], [ 120.010933, 30.182814 ], [ 119.993489, 30.186159 ], [ 119.977829, 30.176784 ], [ 119.951317, 30.172781 ], [ 119.936247, 30.161989 ], [ 119.929492, 30.165381 ], [ 119.9293, 30.18814 ], [ 119.916245, 30.194853 ], [ 119.89861, 30.191159 ], [ 119.891012, 30.196315 ], [ 119.882772, 30.189441 ], [ 119.849554, 30.178647 ], [ 119.831429, 30.201032 ], [ 119.859888, 30.24043 ], [ 119.863558, 30.256317 ], [ 119.858323, 30.263372 ], [ 119.860137, 30.275837 ], [ 119.823324, 30.274027 ], [ 119.824094, 30.28646 ], [ 119.833112, 30.29282 ], [ 119.830596, 30.309713 ], [ 119.821836, 30.309536 ], [ 119.805125, 30.298382 ], [ 119.795525, 30.301958 ], [ 119.804132, 30.335491 ], [ 119.802201, 30.345295 ], [ 119.787716, 30.350523 ], [ 119.787702, 30.360174 ], [ 119.772878, 30.368938 ], [ 119.770957, 30.378628 ], [ 119.764005, 30.382148 ], [ 119.753644, 30.377585 ], [ 119.745772, 30.38655 ], [ 119.749907, 30.388693 ], [ 119.747759, 30.392363 ], [ 119.739503, 30.398103 ], [ 119.728317, 30.401577 ], [ 119.715203, 30.391131 ], [ 119.67726, 30.4111 ], [ 119.688994, 30.427587 ], [ 119.701538, 30.432056 ], [ 119.698786, 30.448895 ], [ 119.690348, 30.455989 ], [ 119.705542, 30.490766 ], [ 119.70543, 30.511722 ], [ 119.68776, 30.559815 ], [ 119.716422, 30.565097 ], [ 119.726085, 30.554764 ], [ 119.74891, 30.553562 ], [ 119.762121, 30.558493 ], [ 119.767239, 30.55224 ], [ 119.762507, 30.52407 ], [ 119.757403, 30.518407 ], [ 119.797237, 30.506477 ], [ 119.816512, 30.512731 ], [ 119.831391, 30.498809 ], [ 119.84607, 30.501365 ], [ 119.871619, 30.475083 ], [ 119.870014, 30.462643 ], [ 119.909225, 30.459942 ], [ 119.915084, 30.463469 ], [ 119.932645, 30.447664 ], [ 119.940195, 30.449933 ], [ 119.959609, 30.432116 ], [ 119.982577, 30.448301 ], [ 119.997988, 30.447524 ], [ 120.009453, 30.4384 ], [ 120.025125, 30.440679 ], [ 120.0337, 30.437615 ], [ 120.033608, 30.428449 ], [ 120.059881, 30.432334 ], [ 120.063521, 30.447606 ], [ 120.054705, 30.460022 ], [ 120.054769, 30.473305 ], [ 120.06401, 30.499846 ], [ 120.095634, 30.49771 ], [ 120.091786, 30.487254 ], [ 120.110076, 30.476698 ], [ 120.136446, 30.485132 ], [ 120.14619, 30.470031 ], [ 120.177983, 30.482461 ], [ 120.173584, 30.490462 ], [ 120.178198, 30.503111 ], [ 120.197365, 30.5118 ], [ 120.225321, 30.511784 ], [ 120.237784, 30.506771 ], [ 120.274242, 30.507672 ], [ 120.295452, 30.522093 ], [ 120.314546, 30.523174 ], [ 120.321958, 30.498689 ], [ 120.322265, 30.472785 ], [ 120.335155, 30.474122 ], [ 120.338677, 30.46647 ], [ 120.332828, 30.466692 ], [ 120.332264, 30.460453 ], [ 120.336537, 30.444041 ], [ 120.327543, 30.427577 ], [ 120.328317, 30.418262 ], [ 120.301763, 30.39987 ], [ 120.301567, 30.395633 ], [ 120.309885, 30.397289 ], [ 120.316605, 30.379611 ], [ 120.337021, 30.378587 ], [ 120.340234, 30.370085 ], [ 120.395342, 30.386253 ], [ 120.396194, 30.375272 ], [ 120.38331, 30.372598 ], [ 120.373061, 30.347126 ], [ 120.408358, 30.318838 ], [ 120.434106, 30.376121 ], [ 120.44115, 30.382382 ], [ 120.502378, 30.392518 ], [ 120.636348, 30.3895 ], [ 120.675744, 30.375304 ], [ 120.702018, 30.356449 ], [ 120.72549, 30.299437 ], [ 120.702871, 30.280665 ], [ 120.688122, 30.261981 ], [ 120.665391, 30.235108 ], [ 120.640252, 30.220153 ], [ 120.610401, 30.171272 ] ] ] } }
]
}
Loading