AutocompletionRequest is missing a few params, I added them in because I needed to restrict the search. I also modified findPlaces to pass these params down to the AutocompletionRequest.
I would do a pull request but I have no idea if it is the right way to fix the problem, I just know it works :).
@JS('google.maps.places')
library places;
import 'package:js/js.dart';
/// google.maps.places.AutocompletionRequest interface
///
/// Ref: https://developers.google.com/maps/documentation/javascript/reference/places-autocomplete-service#AutocompletionRequest
@JS()
@anonymous
class AutocompletionRequest {
/// Create an AutocompletionRequest
// added in types and componentRestrictions params
external factory AutocompletionRequest({String input,List<String> types, ComponentRestrictions componentRestrictions});
/// The user entered input string.
external String get input;
// I added these
external List<String> get types;
external ComponentRestrictions get componentRestrictions;
}
// Added component restrictions class.
@JS()
@anonymous
class ComponentRestrictions {
external factory ComponentRestrictions();
external Object get country;
external void set country(Object country);
}
AutocompletionRequest is missing a few params, I added them in because I needed to restrict the search. I also modified findPlaces to pass these params down to the AutocompletionRequest.
I would do a pull request but I have no idea if it is the right way to fix the problem, I just know it works :).