feat(map): two-click selection model with precise center dot

Replaces 'every click selects something' with a deliberate two-click
flow:
- First click drops marker (existing circle plus new precise center dot)
  and opens place panel
- Second click INSIDE the marker circle opens the radial menu
- Second click OUTSIDE the circle deselects without selecting the new
  spot — requires another click to select

The 4px filled center dot at exact click coordinates gives precise
visual feedback for GPS-coord readout. The existing circle's radius
defines the same-spot tolerance, visually showing the radial-trigger
hit area.

Right-click radial unchanged. Search-dropdown selection drops a marker
for consistency.
This commit is contained in:
Matt 2026-04-26 07:17:33 +00:00
commit 37a5eb5b1b
4 changed files with 111 additions and 30 deletions

View file

@ -50,6 +50,7 @@ const SearchBar = forwardRef(function SearchBar(_, ref) {
const setAutocompleteOpen = useStore((s) => s.setAutocompleteOpen)
const addStop = useStore((s) => s.addStop)
const setSelectedPlace = useStore((s) => s.setSelectedPlace)
const setClickMarker = useStore((s) => s.setClickMarker)
const setEditingContact = useStore((s) => s.setEditingContact)
const clearPendingDestination = useStore((s) => s.clearPendingDestination)
const mapCenter = useStore((s) => s.mapCenter)
@ -165,6 +166,12 @@ const SearchBar = forwardRef(function SearchBar(_, ref) {
matchCode: result.match_code,
raw: result.raw || {},
})
// Set click marker for two-click model consistency
setClickMarker({
lat: result.lat,
lon: result.lon,
circleRadiusPx: 14, // matches preview marker size
})
}
setQuery('')