feat(web): embedding map rev 3 — zoom clustering, solo legend filter, state filter, open-image action (spec 042) #819

Merged
chris merged 2 commits from feat/embedding-map-cluster into main 2026-09-22 21:20:35 +02:00
Owner

User feedback addressed (spec 042 rev 3)

  • True zoom clustering replaces density-rank progressive disclosure: screen-space grid binning (68px cell); each cluster = one marker with the most central member's face (closest to cell centroid, tie-break faceAnnotationId) + '+N' badge. Fewer markers zoomed out, individual faces on zoom-in, no point permanently hidden (max zoom renders all individually). Cluster click zooms +1 centered; recomputed on zoomend/moveend + filter changes (rAF-coalesced).
  • Bigger markers: individual 56px (tentative 60px), cluster 68px. Cluster ring turns amber when it contains tentative members.
  • Legend is now a hard solo filter (was dim-only): 'Alle' + per-person chips; composes AND with the state filter.
  • State filter: 'Alle | Bekræftede | Forslag' pills inside the map — tentative weak-match suggestions can be viewed separately from confirmed faces (data check: Rikke has 729 confirmed faces + 173 pending weak single-face candidates).
  • Åbn billede action on every popover (tentative: Acceptér/Afvis/Åbn billede; accepted: name/distance/Bekræftet + Åbn billede) → existing ?media= overlay.
  • Count hint reflects filtered/total points.

Tests

  • embedding-map.spec.ts rewritten for rev 3: 12 passed (6 × desktop/mobile), incl. clustering merge/split + max-zoom-individual assertions.
  • Test-only stabilization commit: condition-based zoom waits (waitForMarkerSetSettled + per-step re-render proof via node removal + bounded retry on swallowed clicks); proven 3× consecutive clean with --retries=0; combined run 40 passed.
  • svelte-check 0 errors; production build ok; discovery-instance-tentative.spec.ts regression green.

Follow-up to #817. Web-only; no API changes.

## User feedback addressed (spec 042 rev 3) - **True zoom clustering** replaces density-rank progressive disclosure: screen-space grid binning (68px cell); each cluster = one marker with the most central member's face (closest to cell centroid, tie-break faceAnnotationId) + '+N' badge. Fewer markers zoomed out, individual faces on zoom-in, no point permanently hidden (max zoom renders all individually). Cluster click zooms +1 centered; recomputed on zoomend/moveend + filter changes (rAF-coalesced). - **Bigger markers**: individual 56px (tentative 60px), cluster 68px. Cluster ring turns amber when it contains tentative members. - **Legend is now a hard solo filter** (was dim-only): 'Alle' + per-person chips; composes AND with the state filter. - **State filter**: 'Alle | Bekræftede | Forslag' pills inside the map — tentative weak-match suggestions can be viewed separately from confirmed faces (data check: Rikke has 729 confirmed faces + 173 pending weak single-face candidates). - **Åbn billede** action on every popover (tentative: Acceptér/Afvis/Åbn billede; accepted: name/distance/Bekræftet + Åbn billede) → existing ?media= overlay. - Count hint reflects filtered/total points. ## Tests - embedding-map.spec.ts rewritten for rev 3: 12 passed (6 × desktop/mobile), incl. clustering merge/split + max-zoom-individual assertions. - Test-only stabilization commit: condition-based zoom waits (waitForMarkerSetSettled + per-step re-render proof via node removal + bounded retry on swallowed clicks); proven 3× consecutive clean with --retries=0; combined run 40 passed. - svelte-check 0 errors; production build ok; discovery-instance-tentative.spec.ts regression green. Follow-up to #817. Web-only; no API changes.
test(web): stabilize embedding map clustering e2e — condition-based zoom waits
All checks were successful
Build and Deploy / Detect changed services and test scopes (push) Successful in 3s
Build and Deploy / Build plants worker image (push) Has been skipped
Build and Deploy / Build people worker image (push) Has been skipped
Build and Deploy / Build converter worker image (push) Has been skipped
Build and Deploy / Smoke API and media worker (push) Has been skipped
Build and Deploy / Smoke web (push) Has been skipped
Build and Deploy / Smoke ML worker (push) Has been skipped
Build and Deploy / Build ML worker image (push) Has been skipped
Build and Deploy / Build API image (push) Has been skipped
Build and Deploy / Build media worker image (push) Has been skipped
Build and Deploy / Deploy API (push) Has been skipped
Build and Deploy / Build web image (push) Has been skipped
Build and Deploy / Deploy web (push) Has been skipped
Build and Deploy / Deploy media worker (push) Has been skipped
Build and Deploy / Deploy ML worker (push) Has been skipped
Build and Deploy / Deploy plants worker (push) Has been skipped
Build and Deploy / Deploy people worker (push) Has been skipped
Build and Deploy / Deploy converter worker (push) Has been skipped
Build and Deploy / Clean Docker build artifacts (push) Has been skipped
Build and Deploy / Run scoped PR tests (push) Successful in 3m5s
6fa53e4eb9
chris merged commit e35a8591cf into main 2026-09-22 21:20:35 +02:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
chris/memories!819
No description provided.