feat(web): POI visibility checkbox in terrain popup (ET-002) #5

Merged
admin merged 11 commits from feature/ET-002-poi-toggle into main 2026-05-21 19:36:21 +03:00
Owner

Summary

  • Adds a «POI» checkbox to the terrain popup toggling the poi-circles / poi-labels layers via map.setLayoutProperty.
  • State persisted in localStorage (poi-visible) and restored on load / style change; kept consistent with runtime layerState.poi per ADR-0001.
  • Pure client-side change (src/web/index.html, src/web/app.js) — no backend/DB/infra impact.

Tests

  • 7 behavioral JS unit tests (TP-01..TP-04 + extras) run via node --test, wrapped by tests/unit/test_poi_toggle.py (9 static structure checks) so they execute under the existing pytest tests/ CI step.
  • ruff check src/ · pytest tests/ (14 passed, 4 skipped) · docker build

Test plan

  • Open terrain popup → «POI» checkbox visible after «Тропы», separated by <hr>
  • Uncheck → POI markers disappear; check → reappear
  • Reload page → checkbox state and POI visibility preserved
  • Toggling other terrain/trails checkboxes unaffected

Notes

  • e2e scenarios TP-05..TP-09 need Playwright infra absent from the repo (new npm packages forbidden by 07-infra-requirements.md); their behavioral core is covered by the JS unit tests + static checks.

Refs: ET-002

## Summary - Adds a «POI» checkbox to the terrain popup toggling the `poi-circles` / `poi-labels` layers via `map.setLayoutProperty`. - State persisted in `localStorage` (`poi-visible`) and restored on load / style change; kept consistent with runtime `layerState.poi` per ADR-0001. - Pure client-side change (`src/web/index.html`, `src/web/app.js`) — no backend/DB/infra impact. ## Tests - 7 behavioral JS unit tests (TP-01..TP-04 + extras) run via `node --test`, wrapped by `tests/unit/test_poi_toggle.py` (9 static structure checks) so they execute under the existing `pytest tests/` CI step. - `ruff check src/` ✅ · `pytest tests/` ✅ (14 passed, 4 skipped) · `docker build` ✅ ## Test plan - [ ] Open terrain popup → «POI» checkbox visible after «Тропы», separated by `<hr>` - [ ] Uncheck → POI markers disappear; check → reappear - [ ] Reload page → checkbox state and POI visibility preserved - [ ] Toggling other terrain/trails checkboxes unaffected ## Notes - e2e scenarios TP-05..TP-09 need Playwright infra absent from the repo (new npm packages forbidden by `07-infra-requirements.md`); their behavioral core is covered by the JS unit tests + static checks. Refs: ET-002
admin added 8 commits 2026-05-21 18:51:30 +03:00
fix: restore UI to phase 5.4 (terrain, scale bar, zoom controls)
All checks were successful
CI / lint (push) Successful in 5s
CI / test (push) Successful in 9s
CI / build (push) Successful in 18s
CI / lint (pull_request) Successful in 5s
CI / test (pull_request) Successful in 9s
CI / build (pull_request) Successful in 2s
8d36f38be6
Fixes trails/tracks not rendering after theme switch.
The issue was that map.setStyle(url) caused MapLibre to resolve
relative tile paths without /enduro/ prefix, resulting in 404s.
docs(ET-002): add ADR-0001 and infra requirements for POI toggle
All checks were successful
CI / lint (push) Successful in 4s
CI / test (push) Successful in 4s
CI / build (push) Successful in 3s
af579f7f2a
Record architecture decision to implement POI visibility toggling
client-side (setLayoutProperty + localStorage), reusing the existing
layerState model, with no backend, DB or infrastructure changes.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
feat(web): add POI visibility checkbox to terrain popup
All checks were successful
CI / lint (push) Successful in 4s
CI / test (push) Successful in 5s
CI / build (push) Successful in 15s
CI / lint (pull_request) Successful in 4s
CI / test (pull_request) Successful in 4s
CI / build (pull_request) Successful in 3s
8c17a4f508
Adds a «POI» checkbox to the terrain popup that toggles the
poi-circles and poi-labels layers via map.setLayoutProperty. The
choice is persisted in localStorage (key `poi-visible`) and restored
on page load and after style changes, kept consistent with the
runtime layerState.poi per ADR-0001.

Tests: behavioral JS unit tests (TP-01..TP-04) run via `node --test`,
wrapped by tests/unit/test_poi_toggle.py with static structure checks
so they execute under the existing `pytest tests/` CI step.

Refs: ET-002

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
admin added 1 commit 2026-05-21 19:19:44 +03:00
docs(ET-002): code review APPROVED - no P0/P1 findings
All checks were successful
CI / lint (push) Successful in 4s
CI / test (push) Successful in 5s
CI / lint (pull_request) Successful in 4s
CI / test (pull_request) Successful in 4s
CI / build (push) Successful in 3s
CI / build (pull_request) Successful in 3s
a4a0aabfc3
claude-bot approved these changes 2026-05-21 19:23:45 +03:00
Dismissed
claude-bot left a comment
Collaborator

Code review APPROVED - no P0/P1 findings. POI checkbox implementation matches TRZ and ADR.

Code review APPROVED - no P0/P1 findings. POI checkbox implementation matches TRZ and ADR.
admin added 1 commit 2026-05-21 19:29:42 +03:00
test(ET-002): test report PASS - all tests green, ready to deploy
All checks were successful
CI / lint (push) Successful in 4s
CI / test (push) Successful in 5s
CI / lint (pull_request) Successful in 3s
CI / test (pull_request) Successful in 4s
CI / build (push) Successful in 3s
CI / build (pull_request) Successful in 1s
c36ee9d39e
admin dismissed claude-bot's review 2026-05-21 19:29:42 +03:00
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

claude-bot approved these changes 2026-05-21 19:31:34 +03:00
Dismissed
claude-bot left a comment
Collaborator

Re-approve after test report commit. All tests PASS, ready to merge.

Re-approve after test report commit. All tests PASS, ready to merge.
admin added 1 commit 2026-05-21 19:33:43 +03:00
Merge branch 'main' into feature/ET-002-poi-toggle
All checks were successful
CI / lint (push) Successful in 3s
CI / test (push) Successful in 4s
CI / lint (pull_request) Successful in 3s
CI / build (push) Successful in 2s
CI / test (pull_request) Successful in 4s
CI / build (pull_request) Successful in 3s
9ffd6f4b7e
claude-bot approved these changes 2026-05-21 19:36:13 +03:00
claude-bot left a comment
Collaborator

Final approve for merge.

Final approve for merge.
admin merged commit b725810404 into main 2026-05-21 19:36:21 +03:00
Sign in to join this conversation.
No Reviewers
No Label
2 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: admin/enduro-trails#5