Add Kaohsiung parking static site with data loading, filters and card list#1
Add Kaohsiung parking static site with data loading, filters and card list#1
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| const DATA_SOURCES = [ | ||
| "./kaohsiung_parking_lots_2025-12-25_schema_placephoto_fallback.json", | ||
| "./kaohsiung_parking_lots_2025-12-25_curated.json", |
There was a problem hiding this comment.
Remove or add missing curated JSON fallback
The fallback source ./kaohsiung_parking_lots_2025-12-25_curated.json is referenced here, but the repo only contains the schema JSON and the curated CSV (no curated JSON file). That means the fallback will always 404 if the primary schema file fails to load (e.g., file renamed or missing on the host), and users cannot actually fetch the intended backup dataset. Either add the curated JSON file or remove the fallback so the UI can reliably recover when the primary source is unavailable.
Useful? React with 👍 / 👎.
Motivation
schema_placephoto_fallbackJSON by default and fallback to the curated JSON when needed.Description
index.htmlfor the page layout,assets/styles.cssfor styling, andassets/app.jsimplementing the app logic.assets/app.js:loadData(),normalizeItem(),getThumbnailUrl(),applyFilters(), andrenderList()to keep code readable and maintainable.thumbnail.place_photo.url, thenphoto_reference(usingclassic_photoreference_url_template) orphoto_resource_name(usingnew_photo_resource_url_template) and finallythumbnail.street_view.url, leavingYOUR_API_KEYin templates for later replacement.有平假日差異,含月租/上限), sorting (name / weekday price), district grouping, card details (name, address with copy button, vehicle types, weekday/weekend pricing, Google rating text), and footer download links for CSV/JSON.Testing
python -m http.serverand used Playwright to openindex.htmland capture a full-page screenshot, which loaded successfully and produced an artifact.Codex Task