Skip to content

refactor(recovery-step2): mirror InquiryStep2's spatial-context layout#253

Merged
yorickdewid merged 1 commit into
mainfrom
feat/recovery-step2-spatial-context
Jun 1, 2026
Merged

refactor(recovery-step2): mirror InquiryStep2's spatial-context layout#253
yorickdewid merged 1 commit into
mainfrom
feat/recovery-step2-spatial-context

Conversation

@yorickdewid

Copy link
Copy Markdown
Contributor

Summary

Brings RecoveryStep2 in line with the spatial-context layout shipped on InquiryStep2 in #246 / #247 / #249.

  • 3-col grid at xl+ (addresses list / form / map), stacks below xl so the form isn't squeezed at midsized viewports.
  • Map column with the same sticky positioning + explicit height so Mapbox renders against a real container (not the zero-height landmine from fix(map): make SampleMap actually render (zero-height container) #244).
  • Pin click syncs the selected sample → focuses the matching row in the addresses list and the sample form.

Note on PAND keying

Recovery samples store a BAG PAND id (not a gfm- address id). The geocoder's `/api/geocoder/address/:id` route already handles PAND input and returns a representative address with the building centroid, so pin derivation is the same shape as inquiry. Samples whose building lacks geometry simply don't render a pin — same behavior as on the inquiry side.

Test plan

  • `pnpm type-check` clean
  • `pnpm build` clean
  • Verified end-to-end against local API: PAND `NL.IMBAG.PAND.…` resolves through `/api/geocoder/address/:id` and returns a usable address row (centroid happens to be null on the sanitized dev DB; prod has the geom)
  • Smoke in dev: open a recovery, navigate to Step 2, add a couple of samples — confirm pins render, clicking a pin focuses the row + form, and the layout stacks cleanly below xl

🤖 Generated with Claude Code

Brings RecoveryStep2 in line with InquiryStep2 (#246 / #247 / #249):
- 3-col grid at xl+ (addresses list / form / map), single-column stack
  below xl so the form doesn't get squeezed at midsized viewports.
- Map column with the same sticky positioning and explicit height so
  Mapbox renders against a real container.
- Pin click syncs the selected sample so clicking a marker focuses the
  matching row in the addresses list and form.

Recovery samples key on the BAG PAND id rather than a gfm- address id,
but the geocoder /address/:id route already accepts PAND and returns a
representative address with the building centroid, so pin derivation is
the same shape — samples whose building lacks geometry simply don't
render a pin.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@yorickdewid
yorickdewid merged commit cb5d1da into main Jun 1, 2026
1 check passed
@yorickdewid
yorickdewid deleted the feat/recovery-step2-spatial-context branch June 1, 2026 09:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant