- Place details header now keeps the same top gap as the standard 56px
drawer header, so the place name is not crammed against the drag handle.
- Read the sheet inset untracked in the map's pin/center helpers so
updateSelectedPin no longer re-runs on every drag frame. This stops the
selected marker from jittering while a drawer is dragged.
- Re-center the selected place in the resized visible area when a drawer
settles at a new detent, and pan it clear of the sheet on a same-size
settle (restores the auto-pan that untracking removed).
- Commit the sheet's hidden position with the transform transition
disabled so the entrance animates from fully hidden and slides up,
instead of shrinking down from the top.
- Add acceptance tests for the header gap, the per-frame pin recompute,
and the settle recenter/pan behaviour.
The map centering helpers gated their mobile branch on `sheetInsetPx > 0`,
but the inset is published on a deferred animation frame and is briefly 0
during a sheet-to-sheet transition. On mobile that skipped the mobile branch
and fell into the desktop sidebar branch, which shifts the map center left to
make room for the sidebar and pushed the selected pin to the right edge.
Make the mobile and desktop branches mutually exclusive by viewport so the
desktop logic can never run on mobile; with a 0 inset the mobile math is a
no-op and the existing sheet-snap re-pan corrects the vertical position once
the sheet publishes its height.
Mobile sheets (search results, place details, lists, menu, contributions,
activity, new place) become draggable bottom sheets with three detents
(collapsed / medium / expanded), fling-snapping, and swipe-down-to-dismiss.
The sheet is transform-based and content never reflows while dragging.
The map, crosshair, and pin-centering react to the live covered height through
mapUi.sheetInsetPx, replacing the old hardcoded "bottom 50%" assumptions.
Also fixes a backtracking crash that made the drawer disappear when opening a
place from search results: the modifier no longer writes tracked service state
during render. Writes are coalesced into an animation-frame flush and gated by
an ownership token, so a stale sheet can't corrupt the inset.
* Increase sidebar with on desktop to fit more content
* Move sidebar width to CSS variable
* Auto-pan when a selected place would be obstructed by the desktop
sidebar
* Consider the header obscuring selected places, too
* Only autopan when actually necessary