Filter autocomplete suggestions by selected country

Created on 27 January 2022, almost 3 years ago
Updated 22 March 2023, over 1 year ago

Problem/Motivation

Autocomplete suggestions include all addresses world-wide even when a country has been selected. This results in a poor experience with autocomplete providers that work internationally.

Proposed resolution

Include the country in the address query and ensure suggestions are filtered

โœจ Feature request
Status

Needs work

Version

1.0

Component

Code

Created by

๐Ÿ‡บ๐Ÿ‡ธUnited States rhovland Oregon

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • ๐Ÿ‡บ๐Ÿ‡ธUnited States rhovland Oregon

    @granik This is expected because the patch is implicitly setting the country based on what is currently selected. So an autocomplete provider with no suggestions would only suggest the country if it can't match anything else.

    This probably needs to be fixed in the autocomplete provider you're using so it doesn't return any results where only a country is offered as a result.
    Which autocomplete provider are you seeing this result in?

  • ๐Ÿ‡บ๐Ÿ‡ฆUkraine gilmord ๐Ÿ‡บ๐Ÿ‡ฆUkraine

    If you check how Geolocation + Address works - once you set the point on the map - address country is updated
    Looks like this is the best option - instead of forcing the user to handle address it should be handled based on provider response

Production build 0.71.5 2024