Category searches drop up to 25 pins (SearchControl._pin). In dense areas the pins overlap heavily, which was visible in Chinatown during testing. Apple clusters nearby results into a numbered bubble and spreads them as you zoom.
Scope
- Cluster result pins by screen distance, re-clustered on zoom.
- A cluster pin shows a count in the category colour; tapping it zooms to its members.
- The selected pin is never clustered.
- Reuse the existing clustering code (
GeoJSONClusterSource) or a light screen-space pass. - Tests for clustering and for selection inside a cluster.