martin-braun-net / google_maps_place_picker_mb

Place picker on Google Maps for Flutter
https://pub.dev/packages/google_maps_place_picker_mb
MIT License
34 stars 94 forks source link

Expose the new style property of GoogleMap with version 2.6 #83

Open giorgio79 opened 6 months ago

giorgio79 commented 6 months ago

Previously, we could call

 PlacePicker(
        onMapCreated: (mapController) {
          mapController.setMapStyle(globals.gMapsMonochrome);
        },

Now as per https://pub.dev/packages/google_maps_flutter/changelog#260

"Adds style to the GoogleMap widget constructor. This allows setting the map style during creation, avoiding the possibility of the default style being displayed briefly. Deprecates GoogleMapController.setMapStyle in favor of setting the style via the new widget style parameter."

Eg if someone had a dark theme with Google Maps: https://github.com/flutter/flutter/issues/144524