Replace the static housing map with Google Maps #99
Labels
No labels
backend
beginner friendly
bug
chore
documentation
enhancement
frontend
needs-triage
no-stale
priority/high
priority/low
priority/medium
size/L
size/M
size/S
size/XL
size/XS
stage/backlog
stage/done
stage/in progress
stage/in-progress
stage/ready
stale
wontfix
needs/docs
needs/research
needs/upstream
type/bug
type/external
type/feature
type/refactor
urgency
high
urgency
immediate
urgency
low
urgency
medium
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
ScottyLabs/housing#99
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Overall Objective
Replace the static image on
/mapwith an interactive Google Map showing our dorms. Users should be able to pan, zoom, and select a dorm marker to open its existing building-details page.No new Figma design is required!
Suggested Approach
Use Google's React Maps tutorial as guidance. Follow sections 3–6 for the map and markers, then 8 for clicks. The setup has already been taken care of.
Open
apps/frontend/src/app/map-page.tsx. Follow the tutorial'sAPIProviderandMapexamples to replace the static image.Use the settings from issue #94 instead of pasting the tutorial's key. Request
/api/config/mapsthroughapps/frontend/src/api/client.ts, then pass itsapiKeytoAPIProviderandmapIdtoMapwhenenabledis true.Replace the tutorial's Sydney locations with CMU dorms. Use the coordinates added in Issue #97 :
location.latitudebecomeslat, andlocation.longitudebecomeslng. Give each marker the dorm's name and skip any record without valid coordinates.Follow the tutorial's marker-click example, but open the dorm's existing page instead of moving the map. Use React Router's
useNavigate()to go to/building/${building.id}. No popup or new details page is needed.Choose an initial view that shows the dorms around CMU. Give the map a visible height, keep the current page heading, and change the instructions to “Select a dorm marker to view building details.” Make sure it fits on both phones and desktops.
Show a loading message while the map starts, and an unavailable message with building links if settings are missing or loading fails.
Help & Resources
No activity here for 21 days. If this is still live, drop a comment or push something and I'll clear the label. Otherwise it'll be unassigned on the next sweep.
work in progress
No activity here for 21 days. If this is still live, drop a comment or push something and I'll clear the label. Otherwise it'll be unassigned on the next sweep.