react-native-maps 1.21.0-alpha.14 → 1.21.0-alpha.141

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (258) hide show
  1. package/android/build.gradle +73 -53
  2. package/android/gradlew +1 -2
  3. package/android/src/main/RCTAppDependencyProvider.h +25 -0
  4. package/android/src/main/RCTAppDependencyProvider.mm +55 -0
  5. package/android/src/main/RCTModulesConformingToProtocolsProvider.h +18 -0
  6. package/android/src/main/RCTModulesConformingToProtocolsProvider.mm +33 -0
  7. package/android/src/main/RCTThirdPartyComponentsProvider.h +16 -0
  8. package/android/src/main/RCTThirdPartyComponentsProvider.mm +28 -0
  9. package/android/src/main/ReactAppDependencyProvider.podspec +34 -0
  10. package/android/src/main/java/com/facebook/fbreact/specs/NativeAirMapsModuleSpec.java +63 -0
  11. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsCalloutManagerDelegate.java +35 -0
  12. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsCalloutManagerInterface.java +17 -0
  13. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsCircleManagerDelegate.java +49 -0
  14. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsCircleManagerInterface.java +23 -0
  15. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsGooglePolygonManagerDelegate.java +49 -0
  16. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsGooglePolygonManagerInterface.java +23 -0
  17. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMapViewManagerDelegate.java +209 -0
  18. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMapViewManagerInterface.java +74 -0
  19. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMarkerManagerDelegate.java +104 -0
  20. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsMarkerManagerInterface.java +39 -0
  21. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsOverlayManagerDelegate.java +45 -0
  22. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsOverlayManagerInterface.java +22 -0
  23. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsPolylineManagerDelegate.java +58 -0
  24. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsPolylineManagerInterface.java +26 -0
  25. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsUrlTileManagerDelegate.java +62 -0
  26. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsUrlTileManagerInterface.java +27 -0
  27. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsWMSTileManagerDelegate.java +56 -0
  28. package/android/src/main/java/com/facebook/react/viewmanagers/RNMapsWMSTileManagerInterface.java +25 -0
  29. package/android/src/main/java/com/rnmaps/fabric/CalloutManager.java +77 -0
  30. package/android/src/main/java/com/rnmaps/fabric/CircleManager.java +94 -0
  31. package/android/src/main/java/com/rnmaps/fabric/JSONUtil.java +86 -0
  32. package/android/src/main/java/com/rnmaps/fabric/MapViewManager.java +624 -0
  33. package/android/src/main/java/com/rnmaps/fabric/MarkerManager.java +258 -0
  34. package/android/src/main/java/com/rnmaps/fabric/NativeAirMapsModule.java +235 -2
  35. package/android/src/main/java/com/rnmaps/fabric/OverlayManager.java +101 -0
  36. package/android/src/main/java/com/rnmaps/fabric/PolygonManager.java +89 -0
  37. package/android/src/main/java/com/rnmaps/fabric/PolylineManager.java +121 -0
  38. package/android/src/main/java/com/rnmaps/fabric/UrlTileManager.java +124 -0
  39. package/android/src/main/java/com/rnmaps/fabric/WMSTileManager.java +114 -0
  40. package/android/src/main/java/com/rnmaps/fabric/event/OnCalloutPressEvent.java +25 -0
  41. package/android/src/main/java/com/rnmaps/fabric/event/OnDeselectEvent.java +28 -0
  42. package/android/src/main/java/com/rnmaps/fabric/event/OnDoublePressEvent.java +27 -0
  43. package/android/src/main/java/com/rnmaps/fabric/event/OnDragEndEvent.java +28 -0
  44. package/android/src/main/java/com/rnmaps/fabric/event/OnDragEvent.java +28 -0
  45. package/android/src/main/java/com/rnmaps/fabric/event/OnDragStartEvent.java +28 -0
  46. package/android/src/main/java/com/rnmaps/fabric/event/OnIndoorBuildingFocusedEvent.java +28 -0
  47. package/android/src/main/java/com/rnmaps/fabric/event/OnIndoorLevelActivatedEvent.java +28 -0
  48. package/android/src/main/java/com/rnmaps/fabric/event/OnKmlReadyEvent.java +28 -0
  49. package/android/src/main/java/com/rnmaps/fabric/event/OnLongPressEvent.java +28 -0
  50. package/android/src/main/java/com/rnmaps/fabric/event/OnMapLoadedEvent.java +29 -0
  51. package/android/src/main/java/com/rnmaps/fabric/event/OnMapReadyEvent.java +29 -0
  52. package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDeselectEvent.java +28 -0
  53. package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDragEndEvent.java +28 -0
  54. package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDragEvent.java +28 -0
  55. package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerDragStartEvent.java +28 -0
  56. package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerPressEvent.java +28 -0
  57. package/android/src/main/java/com/rnmaps/fabric/event/OnMarkerSelectEvent.java +28 -0
  58. package/android/src/main/java/com/rnmaps/fabric/event/OnPanDragEvent.java +28 -0
  59. package/android/src/main/java/com/rnmaps/fabric/event/OnPoiClickEvent.java +27 -0
  60. package/android/src/main/java/com/rnmaps/fabric/event/OnPressEvent.java +27 -0
  61. package/android/src/main/java/com/rnmaps/fabric/event/OnRegionChangeCompleteEvent.java +30 -0
  62. package/android/src/main/java/com/rnmaps/fabric/event/OnRegionChangeEvent.java +48 -0
  63. package/android/src/main/java/com/rnmaps/fabric/event/OnRegionChangeStartEvent.java +33 -0
  64. package/android/src/main/java/com/rnmaps/fabric/event/OnSelectEvent.java +28 -0
  65. package/android/src/main/java/com/rnmaps/fabric/event/OnUserLocationChangeEvent.java +28 -0
  66. package/android/src/main/java/com/rnmaps/maps/MapAirModulePackage.java +55 -3
  67. package/android/src/main/java/com/rnmaps/maps/MapCallout.java +18 -0
  68. package/android/src/main/java/com/rnmaps/maps/MapCircle.java +24 -0
  69. package/android/src/main/java/com/rnmaps/maps/MapManager.java +14 -14
  70. package/android/src/main/java/com/rnmaps/maps/MapMarker.java +637 -556
  71. package/android/src/main/java/com/rnmaps/maps/MapMarkerManager.java +3 -3
  72. package/android/src/main/java/com/rnmaps/maps/MapModule.java +206 -206
  73. package/android/src/main/java/com/rnmaps/maps/MapOverlay.java +247 -151
  74. package/android/src/main/java/com/rnmaps/maps/MapOverlayManager.java +23 -1
  75. package/android/src/main/java/com/rnmaps/maps/MapPolygon.java +31 -1
  76. package/android/src/main/java/com/rnmaps/maps/MapPolyline.java +207 -141
  77. package/android/src/main/java/com/rnmaps/maps/MapPolylineManager.java +1 -16
  78. package/android/src/main/java/com/rnmaps/maps/MapUrlTile.java +18 -18
  79. package/android/src/main/java/com/rnmaps/maps/MapUrlTileManager.java +10 -14
  80. package/android/src/main/java/com/rnmaps/maps/MapView.java +1649 -1336
  81. package/android/src/main/java/com/rnmaps/maps/MapWMSTile.java +3 -3
  82. package/android/src/main/java/com/rnmaps/maps/MapWMSTileManager.java +10 -10
  83. package/android/src/main/jni/CMakeLists.txt +36 -0
  84. package/android/src/main/jni/RNMapsSpecs-generated.cpp +68 -0
  85. package/android/src/main/jni/RNMapsSpecs.h +31 -0
  86. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/ComponentDescriptors.cpp +31 -0
  87. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/ComponentDescriptors.h +33 -0
  88. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/EventEmitters.cpp +979 -0
  89. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/EventEmitters.h +860 -0
  90. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/Props.cpp +227 -0
  91. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/Props.h +1297 -0
  92. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/RNMapsSpecsJSI-generated.cpp +74 -0
  93. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/RNMapsSpecsJSI.h +268 -0
  94. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/ShadowNodes.cpp +26 -0
  95. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/ShadowNodes.h +131 -0
  96. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/States.cpp +16 -0
  97. package/android/src/main/jni/react/renderer/components/RNMapsSpecs/States.h +137 -0
  98. package/ios/AirGoogleMaps/AIRGoogleMap.h +10 -11
  99. package/ios/AirGoogleMaps/AIRGoogleMap.m +104 -71
  100. package/ios/AirGoogleMaps/AIRGoogleMapCircle.m +23 -11
  101. package/ios/AirGoogleMaps/AIRGoogleMapManager.h +1 -0
  102. package/ios/AirGoogleMaps/AIRGoogleMapManager.m +254 -250
  103. package/ios/AirGoogleMaps/AIRGoogleMapMarker.m +6 -3
  104. package/ios/AirGoogleMaps/AIRGoogleMapMarkerManager.m +1 -1
  105. package/ios/AirGoogleMaps/AIRGoogleMapPolygon.m +3 -0
  106. package/ios/AirGoogleMaps/AIRGoogleMapPolyline.h +0 -1
  107. package/ios/AirGoogleMaps/AIRGoogleMapPolyline.m +0 -7
  108. package/ios/AirGoogleMaps/AIRGoogleMapUrlTile.m +2 -2
  109. package/ios/AirGoogleMaps/AIRGoogleMapWMSTile.h +1 -1
  110. package/ios/AirGoogleMaps/AIRGoogleMapWMSTile.m +4 -4
  111. package/ios/AirGoogleMaps/RNMapsGoogleMapView.h +1 -1
  112. package/ios/AirGoogleMaps/RNMapsGoogleMapView.mm +123 -43
  113. package/ios/AirGoogleMaps/RNMapsGoogleMapViewManager.mm +16 -1
  114. package/ios/AirGoogleMaps/RNMapsGooglePolygonView.h +26 -0
  115. package/ios/AirGoogleMaps/RNMapsGooglePolygonView.mm +217 -0
  116. package/ios/AirGoogleMaps/RNMapsGooglePolygonViewManager.mm +26 -0
  117. package/ios/AirMaps/AIRMap.h +8 -9
  118. package/ios/AirMaps/AIRMap.m +222 -239
  119. package/ios/AirMaps/AIRMapManager.m +10 -7
  120. package/ios/AirMaps/AIRMapMarker.h +1 -0
  121. package/ios/AirMaps/AIRMapMarker.m +142 -67
  122. package/ios/AirMaps/AIRMapOverlay.m +2 -2
  123. package/ios/AirMaps/Callout/SMCalloutView.m +1 -1
  124. package/ios/AirMaps/FabricPlaceholders/PlaceHolderGoogleMapView.h +28 -0
  125. package/ios/AirMaps/FabricPlaceholders/PlaceHolderGoogleMapView.mm +68 -0
  126. package/ios/AirMaps/FabricPlaceholders/PlaceHolderPolygonView.h +25 -0
  127. package/ios/AirMaps/FabricPlaceholders/PlaceHolderPolygonView.mm +43 -0
  128. package/ios/AirMaps/RNMapsAirModule.h +1 -1
  129. package/ios/AirMaps/RNMapsAirModule.mm +4 -3
  130. package/ios/AirMaps/RNMapsDefines.h +1 -0
  131. package/ios/AirMaps/RNMapsMapView.h +1 -1
  132. package/ios/AirMaps/RNMapsMapView.mm +119 -95
  133. package/ios/AirMaps/RNMapsMapViewManager.mm +19 -1
  134. package/ios/AirMaps/RNMapsMarkerView.h +24 -0
  135. package/ios/AirMaps/RNMapsMarkerView.mm +430 -0
  136. package/ios/AirMaps/RNMapsMarkerViewManager.mm +28 -0
  137. package/ios/AirMaps.xcodeproj/project.pbxproj +20 -0
  138. package/ios/generated/RCTAppDependencyProvider.h +25 -0
  139. package/ios/generated/RCTAppDependencyProvider.mm +55 -0
  140. package/ios/generated/RCTModulesConformingToProtocolsProvider.h +18 -0
  141. package/ios/generated/RCTModulesConformingToProtocolsProvider.mm +33 -0
  142. package/ios/generated/RCTThirdPartyComponentsProvider.h +16 -0
  143. package/ios/generated/RCTThirdPartyComponentsProvider.mm +26 -0
  144. package/ios/{AirMaps → generated}/RNMapsAirModuleDelegate.h +2 -2
  145. package/ios/generated/RNMapsSpecs/ComponentDescriptors.cpp +29 -0
  146. package/ios/generated/RNMapsSpecs/ComponentDescriptors.h +31 -0
  147. package/ios/generated/RNMapsSpecs/EventEmitters.cpp +977 -0
  148. package/ios/generated/RNMapsSpecs/EventEmitters.h +846 -0
  149. package/ios/generated/RNMapsSpecs/Props.cpp +194 -0
  150. package/ios/generated/RNMapsSpecs/Props.h +1224 -0
  151. package/ios/generated/RNMapsSpecs/RCTComponentViewHelpers.h +591 -0
  152. package/ios/generated/RNMapsSpecs/RNMapsSpecs-generated.mm +92 -0
  153. package/ios/generated/RNMapsSpecs/RNMapsSpecs.h +137 -0
  154. package/ios/generated/RNMapsSpecs/ShadowNodes.cpp +24 -0
  155. package/ios/generated/RNMapsSpecs/ShadowNodes.h +109 -0
  156. package/ios/generated/RNMapsSpecs/States.cpp +16 -0
  157. package/ios/generated/RNMapsSpecs/States.h +113 -0
  158. package/ios/generated/RNMapsSpecsJSI-generated.cpp +74 -0
  159. package/ios/generated/RNMapsSpecsJSI.h +268 -0
  160. package/ios/generated/ReactAppDependencyProvider.podspec +34 -0
  161. package/package.json +26 -19
  162. package/react-native-google-maps.podspec +26 -0
  163. package/react-native-maps-generated.podspec +31 -0
  164. package/react-native-maps.podspec +55 -15
  165. package/react-native.config.js +16 -0
  166. package/src/AnimatedRegion.ts +169 -0
  167. package/src/Geojson.tsx +541 -0
  168. package/src/MapCallout.tsx +77 -0
  169. package/src/MapCalloutSubview.tsx +64 -0
  170. package/src/MapCircle.tsx +162 -0
  171. package/src/MapHeatmap.tsx +125 -0
  172. package/src/MapLocalTile.tsx +60 -0
  173. package/src/MapMarker.tsx +531 -0
  174. package/src/MapMarkerNativeComponent.ts +51 -0
  175. package/src/MapOverlay.tsx +178 -0
  176. package/src/MapPolygon.tsx +188 -0
  177. package/src/MapPolygon.types.ts +25 -0
  178. package/src/MapPolyline.tsx +215 -0
  179. package/src/MapUrlTile.tsx +169 -0
  180. package/src/MapView.tsx +1230 -0
  181. package/src/MapView.types.ts +212 -0
  182. package/src/MapView.web.ts +2 -0
  183. package/src/MapViewNativeComponent.ts +86 -0
  184. package/src/MapWMSTile.tsx +148 -0
  185. package/src/ProviderConstants.ts +2 -0
  186. package/src/createFabricMap.tsx +253 -0
  187. package/src/decorateMapComponent.ts +227 -0
  188. package/src/fixImageProp.ts +17 -0
  189. package/src/index.ts +52 -0
  190. package/src/sharedTypes.ts +101 -0
  191. package/src/specs/NativeAirMapsModule.ts +36 -0
  192. package/src/specs/NativeComponentCallout.ts +63 -0
  193. package/src/specs/NativeComponentCircle.ts +93 -0
  194. package/src/specs/NativeComponentGoogleMapView.ts +922 -0
  195. package/src/specs/NativeComponentGooglePolygon.ts +94 -0
  196. package/src/specs/NativeComponentMapView.ts +1100 -0
  197. package/src/specs/NativeComponentMarker.ts +326 -0
  198. package/src/specs/NativeComponentOverlay.ts +98 -0
  199. package/src/specs/NativeComponentPolyline.ts +124 -0
  200. package/src/specs/NativeComponentUrlTile.ts +128 -0
  201. package/src/specs/NativeComponentWMSTile.ts +107 -0
  202. package/lib/AnimatedRegion.d.ts +0 -19
  203. package/lib/AnimatedRegion.js +0 -134
  204. package/lib/Geojson.d.ts +0 -204
  205. package/lib/Geojson.js +0 -166
  206. package/lib/MapCallout.d.ts +0 -40
  207. package/lib/MapCallout.js +0 -51
  208. package/lib/MapCalloutSubview.d.ts +0 -34
  209. package/lib/MapCalloutSubview.js +0 -48
  210. package/lib/MapCircle.d.ts +0 -117
  211. package/lib/MapCircle.js +0 -53
  212. package/lib/MapHeatmap.d.ts +0 -78
  213. package/lib/MapHeatmap.js +0 -59
  214. package/lib/MapLocalTile.d.ts +0 -35
  215. package/lib/MapLocalTile.js +0 -44
  216. package/lib/MapMarker.d.ts +0 -309
  217. package/lib/MapMarker.js +0 -116
  218. package/lib/MapMarkerNativeComponent.d.ts +0 -15
  219. package/lib/MapMarkerNativeComponent.js +0 -17
  220. package/lib/MapOverlay.d.ts +0 -87
  221. package/lib/MapOverlay.js +0 -63
  222. package/lib/MapPolygon.d.ts +0 -140
  223. package/lib/MapPolygon.js +0 -53
  224. package/lib/MapPolygon.types.d.ts +0 -18
  225. package/lib/MapPolygon.types.js +0 -2
  226. package/lib/MapPolyline.d.ts +0 -156
  227. package/lib/MapPolyline.js +0 -53
  228. package/lib/MapUrlTile.d.ts +0 -134
  229. package/lib/MapUrlTile.js +0 -44
  230. package/lib/MapView.d.ts +0 -715
  231. package/lib/MapView.js +0 -447
  232. package/lib/MapView.types.d.ts +0 -161
  233. package/lib/MapView.types.js +0 -2
  234. package/lib/MapView.web.d.ts +0 -1
  235. package/lib/MapView.web.js +0 -9
  236. package/lib/MapViewNativeComponent.d.ts +0 -18
  237. package/lib/MapViewNativeComponent.js +0 -19
  238. package/lib/MapWMSTile.d.ts +0 -116
  239. package/lib/MapWMSTile.js +0 -44
  240. package/lib/ProviderConstants.d.ts +0 -2
  241. package/lib/ProviderConstants.js +0 -5
  242. package/lib/createFabricMap.d.ts +0 -23
  243. package/lib/createFabricMap.js +0 -175
  244. package/lib/decorateMapComponent.d.ts +0 -36
  245. package/lib/decorateMapComponent.js +0 -80
  246. package/lib/index.d.ts +0 -38
  247. package/lib/index.js +0 -81
  248. package/lib/sharedTypes.d.ts +0 -81
  249. package/lib/sharedTypes.js +0 -2
  250. package/lib/sharedTypesInternal.js +0 -2
  251. package/lib/specs/NativeAirMapsModule.d.ts +0 -31
  252. package/lib/specs/NativeAirMapsModule.js +0 -4
  253. package/lib/specs/NativeComponentGoogleMapView.d.ts +0 -713
  254. package/lib/specs/NativeComponentGoogleMapView.js +0 -21
  255. package/lib/specs/NativeComponentMapView.d.ts +0 -855
  256. package/lib/specs/NativeComponentMapView.js +0 -21
  257. /package/ios/{AirMaps → generated}/RNMapsHostVewDelegate.h +0 -0
  258. /package/{lib/sharedTypesInternal.d.ts → src/sharedTypesInternal.ts} +0 -0
@@ -0,0 +1,1100 @@
1
+ import type {HostComponent, ViewProps, ColorValue} from 'react-native';
2
+
3
+ import codegenNativeComponent from 'react-native/Libraries/Utilities/codegenNativeComponent';
4
+ import codegenNativeCommands from 'react-native/Libraries/Utilities/codegenNativeCommands';
5
+ import {
6
+ Double,
7
+ Int32,
8
+ WithDefault,
9
+ Float,
10
+ DirectEventHandler,
11
+ BubblingEventHandler,
12
+ } from 'react-native/Libraries/Types/CodegenTypes';
13
+
14
+ export type EdgePadding = Readonly<{
15
+ top: Double; // Non-nullable Double for top
16
+ right: Double; // Non-nullable Double for right
17
+ bottom: Double; // Non-nullable Double for bottom
18
+ left: Double; // Non-nullable Double for left
19
+ }>;
20
+
21
+ export type ActionType =
22
+ | 'callout-press'
23
+ | 'press'
24
+ | 'marker-press'
25
+ | 'long-press'
26
+ | 'marker-deselect'
27
+ | 'marker-select';
28
+
29
+ export type Frame = Readonly<{
30
+ x: Double;
31
+ y: Double;
32
+ width: Double;
33
+ height: Double;
34
+ }>;
35
+
36
+ export type ClickEvent = DirectEventHandler<
37
+ Readonly<{
38
+ coordinate: {
39
+ latitude: Double; // Inlined LatLng
40
+ longitude: Double;
41
+ };
42
+ position: {
43
+ x: Double; // Inlined Point
44
+ y: Double;
45
+ };
46
+ }>
47
+ >;
48
+
49
+ export type KmlMarker = {
50
+ id: string; // Non-nullable string
51
+ title: string; // Non-nullable string
52
+ description: string; // Non-nullable string
53
+ coordinate: {
54
+ latitude: Double; // Inlined LatLng
55
+ longitude: Double;
56
+ }; // Non-nullable LatLng
57
+ position: {
58
+ x: Double; // Inlined Point
59
+ y: Double;
60
+ }; // Non-nullable Point
61
+ };
62
+
63
+ export type LongPressEventHandler = BubblingEventHandler<
64
+ Readonly<{
65
+ coordinate: {
66
+ latitude: Double; // Inlined LatLng
67
+ longitude: Double;
68
+ };
69
+ position: {
70
+ x: Double; // Inlined Point
71
+ y: Double;
72
+ };
73
+ action?: string;
74
+ }>
75
+ >;
76
+
77
+ export type MarkerDeselectEventHandler = DirectEventHandler<
78
+ Readonly<{
79
+ action?: string;
80
+ id: string;
81
+ coordinate: {
82
+ latitude: Double; // Inlined LatLng
83
+ longitude: Double;
84
+ };
85
+ }>
86
+ >;
87
+
88
+ export type MarkerSelectEventHandler = DirectEventHandler<
89
+ Readonly<{
90
+ action?: string;
91
+ id: string;
92
+ coordinate: {
93
+ latitude: Double; // Inlined LatLng
94
+ longitude: Double;
95
+ };
96
+ }>
97
+ >;
98
+
99
+ export type CalloutPressEvent = DirectEventHandler<{
100
+ action?: string;
101
+
102
+ /**
103
+ * @platform iOS
104
+ */
105
+ frame?: {
106
+ x: Double;
107
+ y: Double;
108
+ width: Double;
109
+ height: Double;
110
+ };
111
+
112
+ /**
113
+ * @platform iOS
114
+ */
115
+ id?: string;
116
+
117
+ /**
118
+ * @platform iOS
119
+ */
120
+ point?: {
121
+ x: Double; // Non-nullable Double for x
122
+ y: Double; // Non-nullable Double for y
123
+ };
124
+
125
+ /**
126
+ * @platform Android
127
+ */
128
+ coordinate?: {
129
+ latitude: Double; // Non-nullable Double for latitude
130
+ longitude: Double; // Non-nullable Double for longitude
131
+ };
132
+
133
+ /**
134
+ * @platform Android
135
+ */
136
+ position?: {
137
+ x: Double; // Non-nullable Double for x
138
+ y: Double; // Non-nullable Double for y
139
+ };
140
+ }>;
141
+
142
+ export type CalloutPressEventHandler = DirectEventHandler<CalloutPressEvent>;
143
+
144
+ export type Camera = Readonly<{
145
+ /**
146
+ * Apple Maps
147
+ */
148
+ altitude?: Double; // Nullable Double for altitude
149
+ center: LatLng; // Non-nullable center
150
+ heading: Double; // Non-nullable Double for heading
151
+ pitch: Double; // Non-nullable Double for pitch
152
+
153
+ /**
154
+ * Google Maps
155
+ */
156
+ zoom?: Float; // Nullable Double for zoom
157
+ }>;
158
+
159
+ export type LatLng = Readonly<{
160
+ latitude: Double; // Non-nullable Double for latitude
161
+ longitude: Double; // Non-nullable Double for longitude
162
+ }>;
163
+
164
+ export type Point = Readonly<{
165
+ x: Double; // Non-nullable Double for x
166
+ y: Double; // Non-nullable Double for y
167
+ }>;
168
+
169
+ export type Region = Readonly<
170
+ LatLng & {
171
+ latitudeDelta: Double; // Non-nullable Double for latitudeDelta
172
+ longitudeDelta: Double; // Non-nullable Double for longitudeDelta
173
+ }
174
+ >;
175
+
176
+ export type IndoorLevel = Readonly<{
177
+ index: Int32; // Int32 for integers
178
+ name: string; // Non-nullable string
179
+ shortName: string; // Non-nullable string
180
+ }>;
181
+
182
+ export type IndoorLevelActivatedEventHandler = DirectEventHandler<
183
+ Readonly<{
184
+ IndoorLevel: {
185
+ activeLevelIndex: Int32; // Int32 for integers
186
+ name: string; // Non-nullable string
187
+ shortName: string; // Non-nullable string
188
+ }; // Nested ActiveIndoorLevel type
189
+ }>
190
+ >;
191
+
192
+ export type IndoorBuilding = Readonly<{
193
+ underground: boolean; // Non-nullable boolean
194
+ activeLevelIndex: Int32; // Int32 for integers
195
+ levels: ReadonlyArray<IndoorLevel>; // Immutable array of IndoorLevel
196
+ }>;
197
+
198
+ export type IndoorBuildingEventHandler = DirectEventHandler<
199
+ Readonly<{
200
+ IndoorBuilding: {
201
+ underground: boolean; // Non-nullable boolean
202
+ activeLevelIndex: Int32; // Int32 for integers
203
+ };
204
+ }>
205
+ >;
206
+
207
+ export type Details = Readonly<{
208
+ isGesture?: boolean; // Optional boolean for gesture detail
209
+ }>;
210
+
211
+ export type MarkerDragEventHandler = DirectEventHandler<
212
+ Readonly<{
213
+ coordinate: {
214
+ latitude: Double; // Inlined LatLng
215
+ longitude: Double;
216
+ };
217
+ position: {
218
+ x: Double; // Inlined Point
219
+ y: Double;
220
+ };
221
+ id?: string; // Optional id for iOS
222
+ }>
223
+ >;
224
+
225
+ export type MarkerDragStartEndEventHandler = DirectEventHandler<
226
+ Readonly<{
227
+ coordinate: {
228
+ latitude: Double; // Inlined LatLng
229
+ longitude: Double;
230
+ };
231
+ id?: string; // Optional id for iOS
232
+ position?: {
233
+ x: Double; // Inlined Point
234
+ y: Double;
235
+ }; // Optional position for Android
236
+ }>
237
+ >;
238
+
239
+ export type MarkerPressEventHandler = DirectEventHandler<
240
+ Readonly<{
241
+ action?: string;
242
+ id: string;
243
+ coordinate: {
244
+ latitude: Double; // Inlined LatLng
245
+ longitude: Double;
246
+ };
247
+ position?: {
248
+ x: Double; // Inlined Point
249
+ y: Double;
250
+ }; // Optional position for Android
251
+ }>
252
+ >;
253
+
254
+ export type PanDragEventHandler = DirectEventHandler<
255
+ Readonly<{
256
+ coordinate: {
257
+ latitude: Double; // Inlined LatLng
258
+ longitude: Double;
259
+ };
260
+ position: {
261
+ x: Double; // Inlined Point
262
+ y: Double;
263
+ };
264
+ }>
265
+ >;
266
+
267
+ export type PoiClickEventHandler = DirectEventHandler<
268
+ Readonly<{
269
+ placeId: string;
270
+ name: string;
271
+ coordinate: {
272
+ latitude: Double; // Inlined LatLng
273
+ longitude: Double;
274
+ };
275
+ position?: {
276
+ x: Double; // Inlined Point
277
+ y: Double;
278
+ }; // Optional position for Android
279
+ }>
280
+ >;
281
+
282
+ export type MapPressEventHandler = BubblingEventHandler<
283
+ Readonly<{
284
+ coordinate: {
285
+ latitude: Double; // Inlined LatLng
286
+ longitude: Double;
287
+ };
288
+ position: {
289
+ x: Double; // Inlined Point
290
+ y: Double;
291
+ };
292
+ action?: string;
293
+ }>
294
+ >;
295
+ export type RegionChangeEvent = Readonly<{
296
+ region: {
297
+ latitude: Double; // Non-nullable Double for latitude
298
+ longitude: Double;
299
+ latitudeDelta: Double; // Non-nullable Double for latitudeDelta
300
+ longitudeDelta: Double; // Non-nullable Double for longitudeDelta
301
+ }; // The region object
302
+ continuous?: boolean;
303
+ }>;
304
+ export type UserLocationChangeEvent = Readonly<{
305
+ coordinate?: {
306
+ latitude: Double; // Non-nullable Double for latitude
307
+ longitude: Double;
308
+ altitude: Double; // Use Double for numeric values
309
+ timestamp: Double;
310
+ accuracy: Float;
311
+ speed: Float;
312
+ heading: Float;
313
+
314
+ /**
315
+ * @platform iOS
316
+ */
317
+ altitudeAccuracy?: Float; // Optional altitude accuracy
318
+
319
+ /**
320
+ * @platform Android
321
+ */
322
+ isFromMockProvider?: boolean; // Optional boolean for mock provider
323
+ };
324
+
325
+ /**
326
+ * @platform iOS
327
+ */
328
+ error?: Readonly<{
329
+ message: string; // Error message as string
330
+ }>;
331
+ }>;
332
+
333
+ export type UserLocationChangeEventHandler =
334
+ DirectEventHandler<UserLocationChangeEvent>;
335
+
336
+ export type CameraZoomRange = Readonly<{
337
+ minCenterCoordinateDistance?: Double; // Use Double for numeric values
338
+ maxCenterCoordinateDistance?: Double; // Use Double for numeric values
339
+ animated?: boolean; // Non-nullable boolean
340
+ }>;
341
+
342
+ export interface MapFabricNativeProps extends ViewProps {
343
+ /**
344
+ * If `true` map will be cached and displayed as an image instead of being interactable, for performance usage.
345
+ *
346
+ * @default false
347
+ * @platform iOS: Apple Maps only
348
+ * @platform Android: Supported
349
+ */
350
+ cacheEnabled?: boolean;
351
+
352
+ /**
353
+ * The camera view the map should display.
354
+ *
355
+ * Use the camera system, instead of the region system, if you need control over
356
+ * the pitch or heading. Using this will ignore the `region` property.
357
+ * @platform iOS: Supported
358
+ * @platform Android: Supported
359
+ */
360
+ camera?: Readonly<{
361
+ /**
362
+ * Apple Maps
363
+ */
364
+ altitude?: Double; // Nullable Double for altitude
365
+ center: {
366
+ latitude: Double; // Inlined LatLng
367
+ longitude: Double;
368
+ }; // Non-nullable center
369
+ heading: Double; // Non-nullable Double for heading
370
+ pitch: Double; // Non-nullable Double for pitch
371
+
372
+ /**
373
+ * Google Maps
374
+ */
375
+ zoom?: Float; // Nullable Double for zoom
376
+ }>;
377
+
378
+ /**
379
+ * If set, changes the position of the compass.
380
+ *
381
+ * @platform iOS: Apple Maps only
382
+ * @platform Android: Not supported
383
+ */
384
+ compassOffset?: Point;
385
+
386
+ /**
387
+ * If `true` the map will focus on the user's location.
388
+ * This only works if `showsUserLocation` is true and the user has shared their location.
389
+ *
390
+ * @default false
391
+ * @platform iOS: Apple Maps only
392
+ * @platform Android: Not supported
393
+ */
394
+ followsUserLocation?: boolean;
395
+
396
+ /**
397
+ * If `false` the map will not capture PoI clicks
398
+ * This can improve click handling on the map for android
399
+ *
400
+ * @default true
401
+ * @platform iOS: Not supported
402
+ * @platform Android: supported
403
+ */
404
+ poiClickEnabled?: boolean;
405
+
406
+ /**
407
+ * The initial camera view the map should use. Use this prop instead of `camera`
408
+ * only if you don't want to control the camera of the map besides the initial view.
409
+ *
410
+ * Use the camera system, instead of the region system, if you need control over
411
+ * the pitch or heading.
412
+ *
413
+ * Changing this prop after the component has mounted will not result in a camera change.
414
+ *
415
+ * This is similar to the `initialValue` prop of a text input.
416
+ *
417
+ * @platform iOS: Supported
418
+ * @platform Android: Supported
419
+ */
420
+ initialCamera?: Readonly<{
421
+ /**
422
+ * Apple Maps
423
+ */
424
+ altitude?: Double; // Nullable Double for altitude
425
+ center: {
426
+ latitude: Double; // Inlined LatLng
427
+ longitude: Double;
428
+ }; // Non-nullable center
429
+ heading: Double; // Non-nullable Double for heading
430
+ pitch: Double; // Non-nullable Double for pitch
431
+
432
+ /**
433
+ * Google Maps
434
+ */
435
+ zoom?: Float; // Nullable Double for zoom
436
+ }>;
437
+
438
+ /**
439
+ * The initial region to be displayed by the map. Use this prop instead of `region`
440
+ * only if you don't want to control the viewport of the map besides the initial region.
441
+ *
442
+ * Changing this prop after the component has mounted will not result in a region change.
443
+ *
444
+ * This is similar to the `initialValue` prop of a text input.
445
+ *
446
+ * @platform iOS: Supported
447
+ * @platform Android: Supported
448
+ */
449
+ initialRegion?: Region;
450
+
451
+ /**
452
+ * The URL for KML file.
453
+ *
454
+ * @platform iOS: Google Maps only
455
+ * @platform Android: Supported
456
+ */
457
+ kmlSrc?: string;
458
+
459
+ /**
460
+ * If set, changes the position of the "Legal" label link in Apple Maps.
461
+ *
462
+ * @platform iOS: Apple Maps only
463
+ * @platform Android: Not supported
464
+ */
465
+ legalLabelInsets?: EdgePadding;
466
+
467
+ /**
468
+ * Enables lite mode on Android
469
+ *
470
+ * @platform iOS: Not supported
471
+ * @platform Android: Supported
472
+ */
473
+ liteMode?: boolean;
474
+
475
+ /**
476
+ * https://developers.google.com/maps/documentation/get-map-id
477
+ * google cloud mapId to enable cloud styling and more
478
+ */
479
+ googleMapId?: string;
480
+
481
+ /**
482
+ * https://developers.google.com/maps/documentation/android-sdk/renderer
483
+ * google maps renderer
484
+ * @default `LATEST`
485
+ * @platform iOS: Not supported
486
+ * @platform Android: Supported
487
+ */
488
+ googleRenderer?: WithDefault<'LATEST' | 'LEGACY', 'LATEST'>;
489
+
490
+ /**
491
+ * Sets loading background color.
492
+ *
493
+ * @default `#FFFFFF`
494
+ * @platform iOS: Supported
495
+ * @platform Android: Supported
496
+ */
497
+ loadingBackgroundColor?: ColorValue;
498
+
499
+ /**
500
+ * If `true` a loading indicator will show while the map is loading.
501
+ *
502
+ * @default false
503
+ * @platform iOS: Apple Maps only
504
+ * @platform Android: Supported
505
+ */
506
+ loadingEnabled?: boolean;
507
+
508
+ /**
509
+ * Sets loading indicator color.
510
+ *
511
+ * @default `#606060`
512
+ * @platform iOS: Apple Maps only
513
+ * @platform Android: Supported
514
+ */
515
+ loadingIndicatorColor?: ColorValue;
516
+
517
+ /**
518
+ * Adds custom padding to each side of the map. Useful when map elements/markers are obscured.
519
+ *
520
+ * @platform iOS: Supported
521
+ * @platform Android: Supported
522
+ */
523
+ mapPadding?: EdgePadding;
524
+
525
+ /**
526
+ * The map type to be displayed
527
+ *
528
+ * @default `standard`
529
+ * @platform iOS: hybrid | mutedStandard | satellite | standard | terrain | hybridFlyover | satelliteFlyover
530
+ * @platform Android: hybrid | none | satellite | standard | terrain
531
+ */
532
+ mapType?: WithDefault<
533
+ | 'hybrid'
534
+ | 'mutedStandard'
535
+ | 'none'
536
+ | 'satellite'
537
+ | 'standard'
538
+ | 'terrain'
539
+ | 'satelliteFlyover'
540
+ | 'hybridFlyover',
541
+ 'standard'
542
+ >;
543
+
544
+ /**
545
+ * TODO: Add documentation
546
+ *
547
+ * @platform iOS: Apple Maps only
548
+ * @platform Android: Not supported
549
+ */
550
+ maxDelta?: Double;
551
+
552
+ /**
553
+ * Maximum zoom value for the map, must be between 0 and 20
554
+ *
555
+ * @default 20
556
+ * @platform iOS: Supported
557
+ * @platform Android: Supported
558
+ * @deprecated on Apple Maps, use `cameraZoomRange` instead
559
+ */
560
+ maxZoom?: Float;
561
+
562
+ /**
563
+ * TODO: Add documentation
564
+ *
565
+ * @platform iOS: Apple Maps only
566
+ * @platform Android: Not supported
567
+ */
568
+ minDelta?: Double;
569
+
570
+ /**
571
+ * Minimum zoom value for the map, must be between 0 and 20
572
+ *
573
+ * @default 0
574
+ * @platform iOS: Supported
575
+ * @platform Android: Supported
576
+ * @deprecated on Apple Maps, use `cameraZoomRange` instead
577
+ */
578
+ minZoom?: Float;
579
+
580
+ /**
581
+ * If `false` the map won't move to the marker when pressed.
582
+ *
583
+ * @default true
584
+ * @platform iOS: Not supported
585
+ * @platform Android: Supported
586
+ */
587
+ moveOnMarkerPress?: WithDefault<boolean, true>;
588
+
589
+ /**
590
+ * Callback that is called when a callout is tapped by the user.
591
+ *
592
+ * @platform iOS: Apple Maps only
593
+ * @platform Android: Supported
594
+ */
595
+ onCalloutPress?: CalloutPressEventHandler;
596
+
597
+ /**
598
+ * Callback that is called when user double taps on the map.
599
+ *
600
+ * @platform iOS: Apple Maps only
601
+ * @platform Android: Supported
602
+ */
603
+ onDoublePress?: ClickEvent;
604
+
605
+ /**
606
+ * Callback that is called when an indoor building is focused/unfocused
607
+ *
608
+ * @platform iOS: Google Maps only
609
+ * @platform Android: Supported
610
+ */
611
+ onIndoorBuildingFocused?: IndoorBuildingEventHandler;
612
+
613
+ /**
614
+ * Callback that is called when a level on indoor building is activated
615
+ *
616
+ * @platform iOS: Google Maps only
617
+ * @platform Android: Supported
618
+ */
619
+ onIndoorLevelActivated?: IndoorLevelActivatedEventHandler;
620
+
621
+ /**
622
+ * Callback that is called once the kml is fully loaded.
623
+ *
624
+ * @platform iOS: Google Maps only
625
+ * @platform Android: Supported
626
+ */
627
+ onKmlReady?: DirectEventHandler<null>;
628
+
629
+ /**
630
+ * Callback that is called when user makes a "long press" somewhere on the map.
631
+ *
632
+ * @platform iOS: Supported
633
+ * @platform Android: Supported
634
+ */
635
+ onLongPress?: LongPressEventHandler;
636
+
637
+ /**
638
+ * Callback that is called when the map has finished rendering all tiles.
639
+ *
640
+ * @platform iOS: Google Maps only
641
+ * @platform Android: Supported
642
+ */
643
+ onMapLoaded?: DirectEventHandler<null>;
644
+
645
+ /**
646
+ * Callback that is called once the map is ready.
647
+ *
648
+ * Event is optional, as the first onMapReady callback is intercepted
649
+ * on Android, and the event is not passed on.
650
+ *
651
+ * @platform iOS: Supported
652
+ * @platform Android: Supported
653
+ */
654
+ onMapReady?: DirectEventHandler<null>;
655
+
656
+ /**
657
+ * Callback that is called when a marker on the map becomes deselected.
658
+ * This will be called when the callout for that marker is about to be hidden.
659
+ *
660
+ * @platform iOS: Supported
661
+ * @platform Android: Supported
662
+ */
663
+ onMarkerDeselect?: MarkerDeselectEventHandler;
664
+
665
+ /**
666
+ * Callback called continuously as a marker is dragged
667
+ *
668
+ * @platform iOS: Apple Maps only
669
+ * @platform Android: Supported
670
+ */
671
+ onMarkerDrag?: MarkerDragEventHandler;
672
+
673
+ /**
674
+ * Callback that is called when a drag on a marker finishes.
675
+ * This is usually the point you will want to setState on the marker's coordinate again
676
+ *
677
+ * @platform iOS: Apple Maps only
678
+ * @platform Android: Supported
679
+ */
680
+ onMarkerDragEnd?: MarkerDragStartEndEventHandler;
681
+
682
+ /**
683
+ * Callback that is called when the user initiates a drag on a marker (if it is draggable)
684
+ *
685
+ * @platform iOS: Apple Maps only
686
+ * @platform Android: Supported
687
+ */
688
+ onMarkerDragStart?: MarkerDragStartEndEventHandler;
689
+
690
+ /**
691
+ * Callback that is called when a marker on the map is tapped by the user.
692
+ *
693
+ * @platform iOS: Supported
694
+ * @platform Android: Supported
695
+ */
696
+ onMarkerPress?: MarkerPressEventHandler;
697
+
698
+ /**
699
+ * Callback that is called when a marker on the map becomes selected.
700
+ * This will be called when the callout for that marker is about to be shown.
701
+ *
702
+ * @platform iOS: Supported.
703
+ * @platform Android: Supported
704
+ */
705
+ onMarkerSelect?: MarkerSelectEventHandler;
706
+
707
+ /**
708
+ * Callback that is called when user presses and drags the map.
709
+ * **NOTE**: for iOS `scrollEnabled` should be set to false to trigger the event
710
+ *
711
+ * @platform iOS: Supported
712
+ * @platform Android: Supported
713
+ */
714
+ onPanDrag?: PanDragEventHandler;
715
+
716
+ /*
717
+ internal flag to enable pan gesture handling on iOS manually
718
+ * see MapView.ts line 1228
719
+ */
720
+ handlePanDrag?: boolean;
721
+
722
+ /**
723
+ * Callback that is called when user click on a POI.
724
+ *
725
+ * @platform iOS: Google Maps only
726
+ * @platform Android: Supported
727
+ */
728
+ onPoiClick?: PoiClickEventHandler;
729
+
730
+ /**
731
+ * Callback that is called when user taps on the map.
732
+ *
733
+ * @platform iOS: Supported
734
+ * @platform Android: Supported
735
+ */
736
+ onPress?: MapPressEventHandler;
737
+
738
+ /**
739
+ * Callback that is called once before the region changes, such as when the user starts moving the map.
740
+ * `isGesture` property indicates if the move was from the user (true) or an animation (false).
741
+ * **Note**: `isGesture` is supported by Google Maps only.
742
+ *
743
+ * @platform iOS: Supported
744
+ * @platform Android: Supported
745
+ */
746
+ onRegionChangeStart?: DirectEventHandler<RegionChangeEvent>;
747
+
748
+ /**
749
+ * Callback that is called continuously when the region changes, such as when a user is dragging the map.
750
+ * `isGesture` property indicates if the move was from the user (true) or an animation (false).
751
+ * **Note**: `isGesture` is supported by Google Maps only.
752
+ *
753
+ * @platform iOS: Supported
754
+ * @platform Android: Supported
755
+ */
756
+ onRegionChange?: DirectEventHandler<RegionChangeEvent>;
757
+
758
+ /**
759
+ * Callback that is called once when the region changes, such as when the user is done moving the map.
760
+ * `isGesture` property indicates if the move was from the user (true) or an animation (false).
761
+ * **Note**: `isGesture` is supported by Google Maps only.
762
+ *
763
+ * @platform iOS: Supported
764
+ * @platform Android: Supported
765
+ */
766
+ onRegionChangeComplete?: DirectEventHandler<RegionChangeEvent>;
767
+
768
+ /**
769
+ * Callback that is called when the underlying map figures our users current location
770
+ * (coordinate also includes isFromMockProvider value for Android API 18 and above).
771
+ * Make sure **showsUserLocation** is set to *true*.
772
+ *
773
+ * @platform iOS: Supported
774
+ * @platform Android: Supported
775
+ */
776
+ onUserLocationChange?: UserLocationChangeEventHandler;
777
+
778
+ /**
779
+ * Indicates how/when to affect padding with safe area insets
780
+ *
781
+ * @platform iOS: Google Maps only
782
+ * @platform Android: Not supported
783
+ */
784
+ paddingAdjustmentBehavior?: WithDefault<
785
+ 'always' | 'automatic' | 'never',
786
+ 'never'
787
+ >;
788
+
789
+ /**
790
+ * If `false` the user won't be able to adjust the camera’s pitch angle.
791
+ *
792
+ * @default true
793
+ * @platform iOS: Google Maps only
794
+ * @platform Android: Supported
795
+ */
796
+ pitchEnabled?: WithDefault<boolean, true>;
797
+
798
+ /**
799
+ * The region to be displayed by the map.
800
+ * The region is defined by the center coordinates and the span of coordinates to display.
801
+ *
802
+ * @platform iOS: Supported
803
+ * @platform Android: Supported
804
+ */
805
+ region?: Region;
806
+
807
+ /**
808
+ * If `false` the user won't be able to adjust the camera’s pitch angle.
809
+ *
810
+ * @default true
811
+ * @platform iOS: Google Maps only
812
+ * @platform Android: Supported
813
+ */
814
+ rotateEnabled?: WithDefault<boolean, true>;
815
+
816
+ /**
817
+ * If `false` the map will stay centered while rotating or zooming.
818
+ *
819
+ * @default true
820
+ * @platform iOS: Google Maps only
821
+ * @platform Android: Supported
822
+ */
823
+ scrollDuringRotateOrZoomEnabled?: WithDefault<boolean, true>;
824
+
825
+ /**
826
+ * If `false` the user won't be able to change the map region being displayed.
827
+ *
828
+ * @default true
829
+ * @platform iOS: Supported
830
+ * @platform Android: Supported
831
+ */
832
+ scrollEnabled?: WithDefault<boolean, true>;
833
+
834
+ /**
835
+ * A Boolean indicating whether the map displays extruded building information.
836
+ *
837
+ * @default true
838
+ * @platform iOS: Not supported
839
+ * @platform Android: Supported
840
+ */
841
+ showsBuildings?: WithDefault<boolean, true>;
842
+
843
+ /**
844
+ * If `false` compass won't be displayed on the map.
845
+ *
846
+ * @default true
847
+ * @platform iOS: Supported
848
+ * @platform Android: Supported
849
+ */
850
+ showsCompass?: WithDefault<boolean, true>;
851
+
852
+ /**
853
+ * A Boolean indicating whether indoor level picker should be enabled.
854
+ *
855
+ * @default false
856
+ * @platform iOS: Google Maps only
857
+ * @platform Android: Supported
858
+ */
859
+ showsIndoorLevelPicker?: boolean;
860
+
861
+ /**
862
+ * A Boolean indicating whether indoor maps should be enabled.
863
+ *
864
+ * @default true
865
+ * @platform iOS: Google Maps only
866
+ * @platform Android: Supported
867
+ */
868
+ showsIndoors?: WithDefault<boolean, true>;
869
+
870
+ /**
871
+ * If `false` hide the button to move map to the current user's location.
872
+ *
873
+ * @default true
874
+ * @platform iOS: Google Maps only
875
+ * @platform Android: Supported
876
+ */
877
+ showsMyLocationButton?: WithDefault<boolean, true>;
878
+
879
+ /**
880
+ * A Boolean indicating whether the map shows scale information.
881
+ *
882
+ * @default false
883
+ * @platform iOS: Apple Maps only
884
+ * @platform Android: Not supported
885
+ */
886
+ showsScale?: boolean;
887
+
888
+ /**
889
+ * If `true` the users location will be displayed on the map.
890
+ *
891
+ * This will cause iOS to ask for location permissions.
892
+ * For iOS see: [DOCS](https://github.com/react-native-maps/react-native-maps/blob/master/docs/installation.md#set-the-usage-description-property)
893
+ * @default false
894
+ * @platform iOS: Supported
895
+ * @platform Android: Supported
896
+ */
897
+ showsUserLocation?: boolean;
898
+
899
+ /**
900
+ * Sets the tint color of the map. (Changes the color of the position indicator)
901
+ *
902
+ * @default System Blue
903
+ * @platform iOS: Apple Maps only
904
+ * @platform Android: Not supported
905
+ */
906
+ tintColor?: ColorValue;
907
+
908
+ /**
909
+ * If `false` will hide 'Navigate' and 'Open in Maps' buttons on marker press
910
+ *
911
+ * @default true
912
+ * @platform iOS: Not supported
913
+ * @platform Android: Supported
914
+ */
915
+ toolbarEnabled?: WithDefault<boolean, true>;
916
+
917
+ /**
918
+ * Sets the map to the style selected.
919
+ *
920
+ * @default System setting
921
+ * @platform iOS: Supported
922
+ * @platform Android: Supported
923
+ */
924
+ userInterfaceStyle?: WithDefault<'system' | 'light' | 'dark', 'system'>;
925
+
926
+ /**
927
+ * Adds custom styling to the map component.
928
+ * See [README](https://github.com/react-native-maps/react-native-maps#customizing-the-map-style) for more information.
929
+ *
930
+ * @platform iOS: Google Maps only
931
+ * @platform Android: Supported
932
+ */
933
+ customMapStyleString?: string;
934
+
935
+ /**
936
+ * The title of the annotation for current user location.
937
+ *
938
+ * This only works if `showsUserLocation` is true.
939
+ *
940
+ * @default `My Location`
941
+ * @platform iOS: Apple Maps only
942
+ * @platform Android: Not supported
943
+ */
944
+ userLocationAnnotationTitle?: string;
945
+
946
+ /**
947
+ * If `true` clicking user location will show the default callout for userLocation annotation.
948
+ *
949
+ * @default false
950
+ * @platform iOS: Apple Maps only
951
+ * @platform Android: Not supported
952
+ */
953
+ userLocationCalloutEnabled?: boolean;
954
+
955
+ /**
956
+ * Fastest interval the application will actively acquire locations.
957
+ *
958
+ * See [Google APIs documentation](https://developers.google.com/android/reference/com/google/android/gms/location/LocationRequest.html)
959
+ *
960
+ * @default 5000
961
+ * @platform iOS: Not supported
962
+ * @platform Android: Supported
963
+ */
964
+ userLocationFastestInterval?: WithDefault<Int32, 5000>;
965
+
966
+ /**
967
+ * Set power priority of user location tracking.
968
+ *
969
+ * See [Google APIs documentation](https://developers.google.com/android/reference/com/google/android/gms/location/LocationRequest.html)
970
+ *
971
+ * @default `high`
972
+ * @platform iOS: Not supported
973
+ * @platform Android: Supported
974
+ */
975
+ userLocationPriority?: WithDefault<
976
+ 'balanced' | 'high' | 'low' | 'passive',
977
+ 'high'
978
+ >;
979
+
980
+ /**
981
+ * Interval of user location updates in milliseconds.
982
+ *
983
+ * See [Google APIs documentation](https://developers.google.com/android/reference/com/google/android/gms/location/LocationRequest.html)
984
+ *
985
+ * @default 5000
986
+ * @platform iOS: Not supported
987
+ * @platform Android: Supported
988
+ */
989
+ userLocationUpdateInterval?: WithDefault<Int32, 5000>;
990
+
991
+ /**
992
+ * If `false` the zoom control at the bottom right of the map won't be visible.
993
+ *
994
+ * @default true
995
+ * @platform iOS: Not supported
996
+ * @platform Android: Supported
997
+ */
998
+ zoomControlEnabled?: WithDefault<boolean, true>;
999
+
1000
+ /**
1001
+ * If `false` the user won't be able to pinch/zoom the map.
1002
+ *
1003
+ * TODO: Why is the Android reactprop defaultvalue set to false?
1004
+ *
1005
+ * @default true
1006
+ * @platform iOS: Supported
1007
+ * @platform Android: Supported
1008
+ */
1009
+ zoomEnabled?: WithDefault<boolean, true>;
1010
+
1011
+ /**
1012
+ * A Boolean value indicating whether the map displays traffic information.
1013
+ *
1014
+ * @default false
1015
+ * @platform iOS: Google Maps only
1016
+ * @platform Android: Supported
1017
+ */
1018
+ showsTraffic?: boolean;
1019
+
1020
+ /**
1021
+ * If `false` the user won't be able to double tap to zoom the map.
1022
+ * **Note:** But it will greatly decrease delay of tap gesture recognition.
1023
+ *
1024
+ * @default true
1025
+ * @platform iOS: Google Maps only
1026
+ * @platform Android: Not supported
1027
+ */
1028
+ zoomTapEnabled?: WithDefault<boolean, true>;
1029
+
1030
+ /**
1031
+ * Map camera distance limits. `minCenterCoordinateDistance` for minimum distance, `maxCenterCoordinateDistance` for maximum.
1032
+ * `animated` for animated zoom changes.
1033
+ * Takes precedence if conflicting with `minZoomLevel`, `maxZoomLevel`.
1034
+ *
1035
+ * @platform iOS: 13.0+
1036
+ * @platform Android: Not supported
1037
+ */
1038
+ cameraZoomRange?: CameraZoomRange;
1039
+ }
1040
+
1041
+ export interface NativeCommands {
1042
+ animateToRegion: (
1043
+ viewRef: React.ElementRef<React.ComponentType>,
1044
+ regionJSON: string,
1045
+ duration: Int32,
1046
+ ) => void;
1047
+
1048
+ setCamera: (
1049
+ viewRef: React.ElementRef<React.ComponentType>,
1050
+ cameraJSON: string,
1051
+ ) => void;
1052
+
1053
+ animateCamera: (
1054
+ viewRef: React.ElementRef<React.ComponentType>,
1055
+ cameraJSON: string,
1056
+ duration: Int32,
1057
+ ) => void;
1058
+
1059
+ fitToElements: (
1060
+ viewRef: React.ElementRef<React.ComponentType>,
1061
+ edgePaddingJSON: string,
1062
+ animated: boolean,
1063
+ ) => void;
1064
+
1065
+ fitToSuppliedMarkers: (
1066
+ viewRef: React.ElementRef<React.ComponentType>,
1067
+ markersJSON: string,
1068
+ edgePaddingJSON: string,
1069
+ animated: boolean,
1070
+ ) => void;
1071
+
1072
+ fitToCoordinates: (
1073
+ viewRef: React.ElementRef<React.ComponentType>,
1074
+ coordinatesJSON: string,
1075
+ edgePaddingJSON: string,
1076
+ animated: boolean,
1077
+ ) => void;
1078
+
1079
+ setIndoorActiveLevelIndex: (
1080
+ viewRef: React.ElementRef<React.ComponentType>,
1081
+ activeLevelIndex: Int32,
1082
+ ) => void;
1083
+ }
1084
+
1085
+ export const Commands: NativeCommands = codegenNativeCommands<NativeCommands>({
1086
+ supportedCommands: [
1087
+ 'animateToRegion',
1088
+ 'setCamera',
1089
+ 'animateCamera',
1090
+ 'fitToElements',
1091
+ 'fitToSuppliedMarkers',
1092
+ 'fitToCoordinates',
1093
+ 'setIndoorActiveLevelIndex',
1094
+ ],
1095
+ });
1096
+
1097
+ export default codegenNativeComponent<MapFabricNativeProps>(
1098
+ 'RNMapsMapView',
1099
+ {},
1100
+ ) as HostComponent<MapFabricNativeProps>;