@@ -5,8 +5,13 @@ import type {
55 GoogleMapsViewRef ,
66 RNCamera ,
77 RNGoogleMapsPlusViewProps ,
8+ RNInitialProps ,
89 RNLatLng ,
910 RNLocation ,
11+ RNLocationConfig ,
12+ RNMapPadding ,
13+ RNMapUiSettings ,
14+ RNMapZoomConfig ,
1015 RNRegion ,
1116} from 'react-native-google-maps-plus' ;
1217import {
@@ -47,7 +52,7 @@ export default function MapWrapper(props: Props) {
4752 const layout = useSafeAreaInsets ( ) ;
4853
4954 const [ mapLoaded , setMapLoaded ] = React . useState ( false ) ;
50- const initialProps = useMemo (
55+ const initialProps : RNInitialProps = useMemo (
5156 ( ) => ( {
5257 camera : {
5358 center : { latitude : 37.7749 , longitude : - 122.4194 } ,
@@ -57,7 +62,7 @@ export default function MapWrapper(props: Props) {
5762 [ ]
5863 ) ;
5964
60- const uiSettings = useMemo (
65+ const uiSettings : RNMapUiSettings = useMemo (
6166 ( ) => ( {
6267 allGesturesEnabled : true ,
6368 compassEnabled : true ,
@@ -70,19 +75,24 @@ export default function MapWrapper(props: Props) {
7075 tiltEnabled : true ,
7176 zoomControlsEnabled : true ,
7277 zoomGesturesEnabled : true ,
78+ consumeOnMarkerPress : false ,
79+ consumeOnMyLocationButtonPress : false ,
7380 } ) ,
7481 [ ]
7582 ) ;
7683
77- const mapPadding = useMemo ( ( ) => {
84+ const mapPadding : RNMapPadding = useMemo ( ( ) => {
7885 return props . children
7986 ? { top : 20 , left : 20 , bottom : layout . bottom + 80 , right : 20 }
8087 : { top : 20 , left : 20 , bottom : layout . bottom , right : 20 } ;
8188 } , [ layout . bottom , props . children ] ) ;
8289
83- const mapZoomConfig = useMemo ( ( ) => ( { min : 0 , max : 20 } ) , [ ] ) ;
90+ const mapZoomConfig : RNMapZoomConfig = useMemo (
91+ ( ) => ( { min : 0 , max : 20 } ) ,
92+ [ ]
93+ ) ;
8494
85- const locationConfig = useMemo (
95+ const locationConfig : RNLocationConfig = useMemo (
8696 ( ) => ( {
8797 android : {
8898 priority : RNAndroidLocationPriority . PRIORITY_HIGH_ACCURACY ,
0 commit comments