fix(places): a small place in view comes before a far bigger namesake

findPlace looked at the detail tiles only when no city had the typed name,
so a village called Paris in view lost to Paris, France. With
includeSmallPlaces it now reads the places near the view as well and takes
the nearest place of the name there, city or not. With none near, the
largest city of the name still wins.

Co-authored-by: Manjunath Paparaju <[email protected]>
This commit is contained in:
Sameh KhamisandManjunath Paparaju committed 2026-11-18 22:34:59 -08:00
1 parent ec1fc6bc09
commit f414df97eb
5 files changed
+89 -24

No files matched your search

@@ -40,3 +40,8 @@ well-known cities is missing from the result, or a known grouping gets in.
**Limits:** populations are whatever Wikidata states and differ in date and
definition between places (city proper, municipality, urban district). Some
districts and suburbs appear as their own rows.
**Finding a place by name:** `findPlace` takes the nearest place of the name
within 150 km of the view, else the largest city of the name. When asked,
the smaller places of `../wikidata_places` near the view count too, so a
village in view comes before a bigger namesake far away.