fluttercommunity / flutter_google_places

Google Places - Google places autocomplete widgets for flutter. No wrapper, use https://pub.dev/packages/google_maps_webservice. Maintainer: @juliansteenbakker
https://pub.dev/packages/flutter_google_places
Other
303 stars 415 forks source link

Autocomplete language parameter is not working as expected #169

Closed atelog closed 3 years ago

atelog commented 3 years ago

By providing the language parameter to PlacesAutocomplete it still shows results in different languages.

Reproduction:

  1. Provide it value to language parameter.
Prediction p = await PlacesAutocomplete.show(
    types: ['(cities)'],
    region: "it",
    context: context,
    apiKey: kGoogleApiKey,
    language: "it",
    components: [Component(Component.country, "it")],
  );
  1. Try to search in English, and you will still get valid results. Ex. "Rome" which is in english image or "Florența” which is in romanian image
atelog commented 3 years ago

This is Google Places API behavior.