react-native-map4d-map-dtqg 0.1.2 → 0.1.3

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 (195) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +133 -133
  3. package/android/build.gradle +60 -60
  4. package/android/src/main/AndroidManifest.xml +4 -4
  5. package/android/src/main/java/com/reactnativemap4dmap/ImageUtils.java +87 -87
  6. package/android/src/main/java/com/reactnativemap4dmap/Map4dMapModule.java +298 -298
  7. package/android/src/main/java/com/reactnativemap4dmap/Map4dMapPackage.java +35 -35
  8. package/android/src/main/java/com/reactnativemap4dmap/Map4dMapViewManager.java +31 -31
  9. package/android/src/main/java/com/reactnativemap4dmap/RMFBuilding.java +167 -167
  10. package/android/src/main/java/com/reactnativemap4dmap/RMFBuildingManager.java +121 -121
  11. package/android/src/main/java/com/reactnativemap4dmap/RMFCircle.java +105 -105
  12. package/android/src/main/java/com/reactnativemap4dmap/RMFCircleManager.java +121 -121
  13. package/android/src/main/java/com/reactnativemap4dmap/RMFDirectionsRenderer.java +502 -502
  14. package/android/src/main/java/com/reactnativemap4dmap/RMFDirectionsRendererManager.java +143 -143
  15. package/android/src/main/java/com/reactnativemap4dmap/RMFFeature.java +17 -17
  16. package/android/src/main/java/com/reactnativemap4dmap/RMFMapView.java +1172 -1172
  17. package/android/src/main/java/com/reactnativemap4dmap/RMFMapViewManager.java +231 -231
  18. package/android/src/main/java/com/reactnativemap4dmap/RMFMarker.java +412 -412
  19. package/android/src/main/java/com/reactnativemap4dmap/RMFMarkerManager.java +211 -211
  20. package/android/src/main/java/com/reactnativemap4dmap/RMFPOI.java +222 -222
  21. package/android/src/main/java/com/reactnativemap4dmap/RMFPOIManager.java +119 -119
  22. package/android/src/main/java/com/reactnativemap4dmap/RMFPolygon.java +172 -172
  23. package/android/src/main/java/com/reactnativemap4dmap/RMFPolygonManager.java +147 -147
  24. package/android/src/main/java/com/reactnativemap4dmap/RMFPolyline.java +146 -146
  25. package/android/src/main/java/com/reactnativemap4dmap/RMFPolylineManager.java +137 -137
  26. package/android/src/main/java/com/reactnativemap4dmap/RMFTileOverlay.java +95 -95
  27. package/android/src/main/java/com/reactnativemap4dmap/RMFTileOverlayManager.java +64 -64
  28. package/android/src/main/java/com/reactnativemap4dmap/SizeReportingShadowNode.java +31 -31
  29. package/android/src/main/java/com/reactnativemap4dmap/ViewAttacherGroup.java +31 -31
  30. package/android/src/main/java/com/reactnativemap4dmap/ViewChangesTracker.java +70 -70
  31. package/android/src/main/java/vn/map4d/map/annotations/RMFBitmapDescriptor.java +9 -9
  32. package/ios/Map4dMap.h +7 -7
  33. package/ios/Map4dMap.m +14 -14
  34. package/ios/Map4dMap.xcodeproj/project.pbxproj +2 -2
  35. package/ios/Map4dMapViewManager.m +34 -34
  36. package/ios/RCTConvert+Map4dMap.h +33 -33
  37. package/ios/RCTConvert+Map4dMap.m +112 -112
  38. package/ios/RMFCircle.h +37 -37
  39. package/ios/RMFCircle.m +100 -100
  40. package/ios/RMFCircleManager.h +18 -18
  41. package/ios/RMFCircleManager.m +155 -155
  42. package/ios/RMFCircleMap4d.h +23 -23
  43. package/ios/RMFCircleMap4d.m +13 -13
  44. package/ios/RMFCoordinate.h +22 -22
  45. package/ios/RMFCoordinate.m +13 -13
  46. package/ios/RMFDirectionsMarkerOptions.h +24 -24
  47. package/ios/RMFDirectionsMarkerOptions.m +23 -23
  48. package/ios/RMFDirectionsRenderer.h +47 -47
  49. package/ios/RMFDirectionsRenderer.m +182 -182
  50. package/ios/RMFDirectionsRendererManager.h +17 -17
  51. package/ios/RMFDirectionsRendererManager.m +84 -84
  52. package/ios/RMFDirectionsRendererMap4d.h +21 -21
  53. package/ios/RMFDirectionsRendererMap4d.m +12 -12
  54. package/ios/RMFDummyView.h +6 -6
  55. package/ios/RMFDummyView.m +12 -12
  56. package/ios/RMFEventResponse.h +39 -39
  57. package/ios/RMFEventResponse.m +98 -98
  58. package/ios/RMFIcon.h +24 -24
  59. package/ios/RMFIcon.m +35 -35
  60. package/ios/RMFMapView.h +84 -84
  61. package/ios/RMFMapView.m +376 -376
  62. package/ios/RMFMapViewManager.h +17 -17
  63. package/ios/RMFMapViewManager.m +509 -508
  64. package/ios/RMFMarker.h +57 -57
  65. package/ios/RMFMarker.m +267 -267
  66. package/ios/RMFMarkerManager.h +17 -17
  67. package/ios/RMFMarkerManager.m +156 -156
  68. package/ios/RMFMarkerMap4d.h +19 -19
  69. package/ios/RMFMarkerMap4d.m +13 -13
  70. package/ios/RMFPOI.h +38 -38
  71. package/ios/RMFPOI.m +123 -123
  72. package/ios/RMFPOIManager.h +18 -18
  73. package/ios/RMFPOIManager.m +168 -168
  74. package/ios/RMFPOIMap4d.h +22 -22
  75. package/ios/RMFPOIMap4d.m +12 -12
  76. package/ios/RMFPolygon.h +41 -41
  77. package/ios/RMFPolygon.m +106 -106
  78. package/ios/RMFPolygonManager.h +18 -18
  79. package/ios/RMFPolygonManager.m +141 -141
  80. package/ios/RMFPolygonMap4d.h +23 -23
  81. package/ios/RMFPolygonMap4d.m +15 -15
  82. package/ios/RMFPolyline.h +38 -38
  83. package/ios/RMFPolyline.m +101 -101
  84. package/ios/RMFPolylineManager.h +18 -18
  85. package/ios/RMFPolylineManager.m +139 -139
  86. package/ios/RMFPolylineMap4d.h +22 -22
  87. package/ios/RMFPolylineMap4d.m +15 -15
  88. package/ios/building/RMFBuilding.h +41 -41
  89. package/ios/building/RMFBuilding.m +104 -104
  90. package/ios/building/RMFBuildingManager.h +19 -19
  91. package/ios/building/RMFBuildingManager.m +133 -133
  92. package/ios/building/RMFBuildingMap4d.h +23 -23
  93. package/ios/building/RMFBuildingMap4d.m +15 -15
  94. package/ios/overlays/RMFTileOverlay.h +36 -36
  95. package/ios/overlays/RMFTileOverlay.m +64 -64
  96. package/ios/overlays/RMFTileOverlayManager.h +17 -17
  97. package/ios/overlays/RMFTileOverlayManager.m +27 -27
  98. package/lib/commonjs/components/MFBanDoSo.js.map +1 -1
  99. package/lib/commonjs/components/MFBuilding.js +26 -26
  100. package/lib/commonjs/components/MFBuilding.js.map +1 -1
  101. package/lib/commonjs/components/MFCircle.js +20 -20
  102. package/lib/commonjs/components/MFCircle.js.map +1 -1
  103. package/lib/commonjs/components/MFDirectionsRenderer.js +32 -32
  104. package/lib/commonjs/components/MFDirectionsRenderer.js.map +1 -1
  105. package/lib/commonjs/components/MFMapView.js +69 -69
  106. package/lib/commonjs/components/MFMapView.js.map +1 -1
  107. package/lib/commonjs/components/MFMarker.js +35 -35
  108. package/lib/commonjs/components/MFMarker.js.map +1 -1
  109. package/lib/commonjs/components/MFPOI.js +20 -20
  110. package/lib/commonjs/components/MFPOI.js.map +1 -1
  111. package/lib/commonjs/components/MFPolygon.js +22 -22
  112. package/lib/commonjs/components/MFPolygon.js.map +1 -1
  113. package/lib/commonjs/components/MFPolyline.js +18 -18
  114. package/lib/commonjs/components/MFPolyline.js.map +1 -1
  115. package/lib/commonjs/components/MFTileOverlay.js +9 -9
  116. package/lib/commonjs/components/MFTileOverlay.js.map +1 -1
  117. package/lib/commonjs/components/Map4dMapView.js.map +1 -1
  118. package/lib/commonjs/components/extends/AreaFocusManager.js +16 -16
  119. package/lib/commonjs/components/extends/AreaFocusManager.js.map +1 -1
  120. package/lib/commonjs/components/extends/AreaFocuser.js +2 -2
  121. package/lib/commonjs/components/extends/AreaFocuser.js.map +1 -1
  122. package/lib/commonjs/components/extends/BoundHelper.js.map +1 -1
  123. package/lib/commonjs/components/extends/area/AreaFocusAreas.js.map +1 -1
  124. package/lib/commonjs/components/extends/area/AreaFocusGeometryUtils.js.map +1 -1
  125. package/lib/commonjs/components/extends/area/AreaFocusSession.js.map +1 -1
  126. package/lib/commonjs/components/extends/area/AreaFocusTypes.js +18 -18
  127. package/lib/commonjs/components/extends/area/AreaFocusTypes.js.map +1 -1
  128. package/lib/commonjs/components/internal/DefaultRoadmapStyle.js.map +1 -1
  129. package/lib/commonjs/components/internal/GeojsonStyleUtils.js.map +1 -1
  130. package/lib/commonjs/index.js.map +1 -1
  131. package/lib/module/components/MFBanDoSo.js.map +1 -1
  132. package/lib/module/components/MFBuilding.js +26 -26
  133. package/lib/module/components/MFBuilding.js.map +1 -1
  134. package/lib/module/components/MFCircle.js +20 -20
  135. package/lib/module/components/MFCircle.js.map +1 -1
  136. package/lib/module/components/MFDirectionsRenderer.js +32 -32
  137. package/lib/module/components/MFDirectionsRenderer.js.map +1 -1
  138. package/lib/module/components/MFMapView.js +69 -69
  139. package/lib/module/components/MFMapView.js.map +1 -1
  140. package/lib/module/components/MFMarker.js +35 -35
  141. package/lib/module/components/MFMarker.js.map +1 -1
  142. package/lib/module/components/MFPOI.js +20 -20
  143. package/lib/module/components/MFPOI.js.map +1 -1
  144. package/lib/module/components/MFPolygon.js +22 -22
  145. package/lib/module/components/MFPolygon.js.map +1 -1
  146. package/lib/module/components/MFPolyline.js +18 -18
  147. package/lib/module/components/MFPolyline.js.map +1 -1
  148. package/lib/module/components/MFTileOverlay.js +9 -9
  149. package/lib/module/components/MFTileOverlay.js.map +1 -1
  150. package/lib/module/components/Map4dMapView.js.map +1 -1
  151. package/lib/module/components/extends/AreaFocusManager.js +16 -16
  152. package/lib/module/components/extends/AreaFocusManager.js.map +1 -1
  153. package/lib/module/components/extends/AreaFocuser.js +2 -2
  154. package/lib/module/components/extends/AreaFocuser.js.map +1 -1
  155. package/lib/module/components/extends/BoundHelper.js.map +1 -1
  156. package/lib/module/components/extends/area/AreaFocusAreas.js.map +1 -1
  157. package/lib/module/components/extends/area/AreaFocusGeometryUtils.js.map +1 -1
  158. package/lib/module/components/extends/area/AreaFocusSession.js.map +1 -1
  159. package/lib/module/components/extends/area/AreaFocusTypes.js +18 -18
  160. package/lib/module/components/extends/area/AreaFocusTypes.js.map +1 -1
  161. package/lib/module/components/internal/DefaultRoadmapStyle.js.map +1 -1
  162. package/lib/module/components/internal/GeojsonStyleUtils.js.map +1 -1
  163. package/lib/module/index.js.map +1 -1
  164. package/lib/typescript/components/Map4dMapView.d.ts +7 -7
  165. package/package.json +152 -152
  166. package/react-native-map4d-map.podspec +20 -20
  167. package/src/components/MFBanDoSo.js +124 -124
  168. package/src/components/MFBuilding.js +187 -187
  169. package/src/components/MFCircle.js +173 -173
  170. package/src/components/MFDirectionsRenderer.js +237 -237
  171. package/src/components/MFMapView.js +464 -464
  172. package/src/components/MFMarker.js +246 -246
  173. package/src/components/MFPOI.js +184 -184
  174. package/src/components/MFPolygon.js +186 -186
  175. package/src/components/MFPolyline.js +172 -172
  176. package/src/components/MFTileOverlay.js +45 -45
  177. package/src/components/Map4dMapView.tsx +26 -26
  178. package/src/components/extends/AreaFocusManager.js +196 -196
  179. package/src/components/extends/AreaFocuser.js +61 -61
  180. package/src/components/extends/BoundHelper.js +31 -31
  181. package/src/components/extends/area/AreaFocusAreas.js +164 -164
  182. package/src/components/extends/area/AreaFocusGeometryUtils.js +164 -164
  183. package/src/components/extends/area/AreaFocusSession.js +100 -100
  184. package/src/components/extends/area/AreaFocusTypes.js +36 -36
  185. package/src/components/internal/DefaultRoadmapStyle.js +3365 -3365
  186. package/src/components/internal/GeojsonStyleUtils.js +143 -143
  187. package/src/index.js +25 -25
  188. package/android/.gradle/8.9/checksums/checksums.lock +0 -0
  189. package/android/.gradle/8.9/dependencies-accessors/gc.properties +0 -0
  190. package/android/.gradle/8.9/fileChanges/last-build.bin +0 -0
  191. package/android/.gradle/8.9/fileHashes/fileHashes.lock +0 -0
  192. package/android/.gradle/8.9/gc.properties +0 -0
  193. package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
  194. package/android/.gradle/buildOutputCleanup/cache.properties +0 -2
  195. package/android/.gradle/vcs-1/gc.properties +0 -0
@@ -1 +1 @@
1
- {"version":3,"names":["viewPropTypes","ViewPropTypes","View","propTypes","center","PropTypes","shape","latitude","number","isRequired","longitude","radius","strokeWidth","strokeColor","ColorPropType","fillColor","zIndex","visible","bool","userData","object","onPress","func","MFCircle","React","Component","constructor","props","_onPress","bind","_ref","setCenter","_runCommand","setRadius","setFillColor","color","processColor","setStrokeColor","setStrokeWidth","width","setUserData","setZIndex","setVisible","_getHandle","findNodeHandle","circle","name","args","Platform","OS","NativeModules","UIManager","dispatchViewManagerCommand","_uiManagerCommand","_mapManagerCommand","componentName","getViewManagerConfig","Commands","event","stopPropagation","ref","render","RMFCircle","requireNativeComponent"],"sources":["MFCircle.js"],"sourcesContent":["import PropTypes from 'prop-types';\r\nimport React from 'react';\r\nimport {ViewPropTypes, ColorPropType} from 'deprecated-react-native-prop-types';\r\nimport {\r\n requireNativeComponent,\r\n Platform,\r\n NativeModules,\r\n findNodeHandle,\r\n processColor\r\n} from 'react-native';\r\n\r\n// if ViewPropTypes is not defined fall back to View.propType (to support RN < 0.44)\r\nconst viewPropTypes = ViewPropTypes || View.propTypes;\r\n\r\nconst propTypes = {\r\n ...viewPropTypes,\r\n\r\n /**\r\n * The coordinate of the center of the circle\r\n */\r\n center: PropTypes.shape({\r\n /**\r\n * Coordinates for the center of the circle.\r\n */\r\n latitude: PropTypes.number.isRequired,\r\n longitude: PropTypes.number.isRequired,\r\n }).isRequired,\r\n\r\n /**\r\n * The radius of the circle to be drawn (in meters)\r\n */\r\n radius: PropTypes.number.isRequired,\r\n\r\n /**\r\n * The stroke width to use for the circle.\r\n */\r\n strokeWidth: PropTypes.number,\r\n\r\n /**\r\n * The stroke color to use for the circle.\r\n */\r\n strokeColor: ColorPropType,\r\n\r\n /**\r\n * The fill color to use for the circle.\r\n */\r\n fillColor: ColorPropType,\r\n\r\n /**\r\n * zIndex\r\n */\r\n zIndex: PropTypes.number,\r\n\r\n /**\r\n * visible\r\n */\r\n visible: PropTypes.bool,\r\n\r\n /**\r\n * userData\r\n */\r\n userData:PropTypes.object,\r\n\r\n /**\r\n * Callback that is called when the user presses on the circle\r\n */\r\n onPress: PropTypes.func,\r\n};\r\n\r\n// const defaultProps = {\r\n// strokeColor: '#000',\r\n// strokeWidth: 1,\r\n// };\r\n\r\nclass MFCircle extends React.Component {\r\n constructor(props) {\r\n super(props);\r\n this._onPress = this._onPress.bind(this)\r\n this._ref = this._ref.bind(this)\r\n }\r\n\r\n setCenter(center) {\r\n this._runCommand(\"setCenter\", [center])\r\n }\r\n setRadius(radius) {\r\n this._runCommand(\"setRadius\", [radius])\r\n }\r\n setFillColor(color) {\r\n this._runCommand(\"setFillColor\", [processColor(color)])\r\n }\r\n setStrokeColor(color) {\r\n this._runCommand(\"setStrokeColor\", [processColor(color)])\r\n }\r\n setStrokeWidth(width) {\r\n this._runCommand(\"setStrokeWidth\", [width])\r\n }\r\n setUserData(userData) {\r\n this._runCommand(\"setUserData\", [userData])\r\n }\r\n setZIndex(zIndex) {\r\n this._runCommand(\"setZIndex\", [zIndex])\r\n }\r\n setVisible(visible) {\r\n this._runCommand(\"setVisible\", [visible])\r\n }\r\n\r\n _getHandle() {\r\n return findNodeHandle(this.circle);\r\n }\r\n\r\n\r\n _runCommand(name, args) {\r\n switch (Platform.OS) {\r\n case 'android':\r\n NativeModules.UIManager.dispatchViewManagerCommand(\r\n this._getHandle(),\r\n this._uiManagerCommand(name),\r\n args\r\n );\r\n break;\r\n\r\n case 'ios':\r\n this._mapManagerCommand(name)(this._getHandle(), ...args);\r\n break;\r\n\r\n default:\r\n break;\r\n }\r\n }\r\n\r\n _uiManagerCommand(name) {\r\n const UIManager = NativeModules.UIManager;\r\n const componentName = \"RMFCircle\";\r\n\r\n if (!UIManager.getViewManagerConfig) {\r\n // RN < 0.58\r\n return UIManager[componentName].Commands[name];\r\n }\r\n\r\n // RN >= 0.58 \r\n return UIManager.getViewManagerConfig(componentName).Commands[name];\r\n }\r\n \r\n _mapManagerCommand(name) {\r\n return NativeModules[`RMFCircle`][name];\r\n }\r\n\r\n _onPress(event) {\r\n event.stopPropagation();\r\n if (this.props.onPress) {\r\n this.props.onPress(event);\r\n }\r\n }\r\n\r\n _ref(ref) {\r\n this.circle = ref;\r\n }\r\n\r\n render() {\r\n return <RMFCircle\r\n {...this.props}\r\n ref={this._ref}\r\n onPress={this._onPress}\r\n />;\r\n }\r\n}\r\n\r\nMFCircle.propTypes = propTypes;\r\n// MFCircle.defaultProps = defaultProps;\r\n\r\nvar RMFCircle = requireNativeComponent(`RMFCircle`, MFCircle);\r\n\r\nexport {MFCircle}\r\n"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;;;;;AAQA;AACA,MAAMA,aAAa,GAAGC,6CAAA,IAAiBC,IAAI,CAACC,SAA5C;AAEA,MAAMA,SAAS,GAAG,EAChB,GAAGH,aADa;;EAGhB;AACF;AACA;EACEI,MAAM,EAAEC,kBAAA,CAAUC,KAAV,CAAgB;IACtB;AACJ;AACA;IACIC,QAAQ,EAAEF,kBAAA,CAAUG,MAAV,CAAiBC,UAJL;IAKtBC,SAAS,EAAEL,kBAAA,CAAUG,MAAV,CAAiBC;EALN,CAAhB,EAMLA,UAZa;;EAchB;AACF;AACA;EACEE,MAAM,EAAEN,kBAAA,CAAUG,MAAV,CAAiBC,UAjBT;;EAmBhB;AACF;AACA;EACEG,WAAW,EAAEP,kBAAA,CAAUG,MAtBP;;EAwBhB;AACF;AACA;EACEK,WAAW,EAAEC,6CA3BG;;EA6BhB;AACF;AACA;EACEC,SAAS,EAAED,6CAhCK;;EAkChB;AACF;AACA;EACEE,MAAM,EAAEX,kBAAA,CAAUG,MArCF;;EAuChB;AACF;AACA;EACES,OAAO,EAAEZ,kBAAA,CAAUa,IA1CH;;EA4ChB;AACF;AACA;EACEC,QAAQ,EAACd,kBAAA,CAAUe,MA/CH;;EAiDhB;AACF;AACA;EACEC,OAAO,EAAEhB,kBAAA,CAAUiB;AApDH,CAAlB,C,CAuDA;AACA;AACA;AACA;;AAEA,MAAMC,QAAN,SAAuBC,cAAA,CAAMC,SAA7B,CAAuC;EACrCC,WAAW,CAACC,KAAD,EAAQ;IACjB,MAAMA,KAAN;IACA,KAAKC,QAAL,GAAgB,KAAKA,QAAL,CAAcC,IAAd,CAAmB,IAAnB,CAAhB;IACA,KAAKC,IAAL,GAA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AAKO,kBAAL,CAAwBR,IAAxB,EAA8B,KAAKH,UAAL,EAA9B,EAAiD,GAAGI,IAApD;;QACA;;MAEF;QACE;IAdJ;EAgBD;;EAEDM,iBAAiB,CAACP,IAAD,EAAO;IACtB,MAAMK,SAAS,GAAGD,0BAAA,CAAcC,SAAhC;IACA,MAAMI,aAAa,GAAG,WAAtB;;IAEA,IAAI,CAACJ,SAAS,CAACK,oBAAf,EAAqC;MACnC;MACA,OAAOL,SAAS,CAACI,aAAD,CAAT,CAAyBE,QAAzB,CAAkCX,IAAlC,CAAP;IACD,CAPqB,CAStB;;;IACA,OAAOK,SAAS,CAACK,oBAAV,CAA+BD,aAA/B,EAA8CE,QAA9C,CAAuDX,IAAvD,CAAP;EACD;;EAEDQ,kBAAkB,CAACR,IAAD,EAAO;IACvB,OAAOI,0BAAA,CAAe,WAAf,EAA2BJ,IAA3B,CAAP;EACD;;EAEDlB,QAAQ,CAAC8B,KAAD,EAAQ;IACdA,KAAK,CAACC,eAAN;;IACE,IAAI,KAAKhC,KAAL,CAAWN,OAAf,EAAwB;MACtB,KAAKM,KAAL,CAAWN,OAAX,CAAmBqC,KAAnB;IACH;EACF;;EAED5B,IAAI,CAAC8B,GAAD,EAAM;IACR,KAAKf,MAAL,GAAce,GAAd;EACD;;EAEDC,MAAM,GAAG;IACP,oBAAO,6BAAC,SAAD,eACD,KAAKlC,KADJ;MAEL,GAAG,EAAE,KAAKG,IAFL;MAGL,OAAO,EAAE,KAAKF;IAHT,GAAP;EAKD;;AA1FoC;;;AA6FvCL,QAAQ,CAACpB,SAAT,GAAqBA,SAArB,C,CACA;;AAEA,IAAI2D,SAAS,GAAG,IAAAC,mCAAA,EAAwB,WAAxB,EAAoCxC,QAApC,CAAhB"}
1
+ {"version":3,"names":["viewPropTypes","ViewPropTypes","View","propTypes","center","PropTypes","shape","latitude","number","isRequired","longitude","radius","strokeWidth","strokeColor","ColorPropType","fillColor","zIndex","visible","bool","userData","object","onPress","func","MFCircle","React","Component","constructor","props","_onPress","bind","_ref","setCenter","_runCommand","setRadius","setFillColor","color","processColor","setStrokeColor","setStrokeWidth","width","setUserData","setZIndex","setVisible","_getHandle","findNodeHandle","circle","name","args","Platform","OS","NativeModules","UIManager","dispatchViewManagerCommand","_uiManagerCommand","_mapManagerCommand","componentName","getViewManagerConfig","Commands","event","stopPropagation","ref","render","RMFCircle","requireNativeComponent"],"sources":["MFCircle.js"],"sourcesContent":["import PropTypes from 'prop-types';\nimport React from 'react';\nimport {ViewPropTypes, ColorPropType} from 'deprecated-react-native-prop-types';\nimport {\n requireNativeComponent,\n Platform,\n NativeModules,\n findNodeHandle,\n processColor\n} from 'react-native';\n\n// if ViewPropTypes is not defined fall back to View.propType (to support RN < 0.44)\nconst viewPropTypes = ViewPropTypes || View.propTypes;\n\nconst propTypes = {\n ...viewPropTypes,\n\n /**\n * The coordinate of the center of the circle\n */\n center: PropTypes.shape({\n /**\n * Coordinates for the center of the circle.\n */\n latitude: PropTypes.number.isRequired,\n longitude: PropTypes.number.isRequired,\n }).isRequired,\n\n /**\n * The radius of the circle to be drawn (in meters)\n */\n radius: PropTypes.number.isRequired,\n\n /**\n * The stroke width to use for the circle.\n */\n strokeWidth: PropTypes.number,\n\n /**\n * The stroke color to use for the circle.\n */\n strokeColor: ColorPropType,\n\n /**\n * The fill color to use for the circle.\n */\n fillColor: ColorPropType,\n\n /**\n * zIndex\n */\n zIndex: PropTypes.number,\n\n /**\n * visible\n */\n visible: PropTypes.bool,\n\n /**\n * userData\n */\n userData:PropTypes.object,\n\n /**\n * Callback that is called when the user presses on the circle\n */\n onPress: PropTypes.func,\n};\n\n// const defaultProps = {\n// strokeColor: '#000',\n// strokeWidth: 1,\n// };\n\nclass MFCircle extends React.Component {\n constructor(props) {\n super(props);\n this._onPress = this._onPress.bind(this)\n this._ref = this._ref.bind(this)\n }\n\n setCenter(center) {\n this._runCommand(\"setCenter\", [center])\n }\n setRadius(radius) {\n this._runCommand(\"setRadius\", [radius])\n }\n setFillColor(color) {\n this._runCommand(\"setFillColor\", [processColor(color)])\n }\n setStrokeColor(color) {\n this._runCommand(\"setStrokeColor\", [processColor(color)])\n }\n setStrokeWidth(width) {\n this._runCommand(\"setStrokeWidth\", [width])\n }\n setUserData(userData) {\n this._runCommand(\"setUserData\", [userData])\n }\n setZIndex(zIndex) {\n this._runCommand(\"setZIndex\", [zIndex])\n }\n setVisible(visible) {\n this._runCommand(\"setVisible\", [visible])\n }\n\n _getHandle() {\n return findNodeHandle(this.circle);\n }\n\n\n _runCommand(name, args) {\n switch (Platform.OS) {\n case 'android':\n NativeModules.UIManager.dispatchViewManagerCommand(\n this._getHandle(),\n this._uiManagerCommand(name),\n args\n );\n break;\n\n case 'ios':\n this._mapManagerCommand(name)(this._getHandle(), ...args);\n break;\n\n default:\n break;\n }\n }\n\n _uiManagerCommand(name) {\n const UIManager = NativeModules.UIManager;\n const componentName = \"RMFCircle\";\n\n if (!UIManager.getViewManagerConfig) {\n // RN < 0.58\n return UIManager[componentName].Commands[name];\n }\n\n // RN >= 0.58 \n return UIManager.getViewManagerConfig(componentName).Commands[name];\n }\n \n _mapManagerCommand(name) {\n return NativeModules[`RMFCircle`][name];\n }\n\n _onPress(event) {\n event.stopPropagation();\n if (this.props.onPress) {\n this.props.onPress(event);\n }\n }\n\n _ref(ref) {\n this.circle = ref;\n }\n\n render() {\n return <RMFCircle\n {...this.props}\n ref={this._ref}\n onPress={this._onPress}\n />;\n }\n}\n\nMFCircle.propTypes = propTypes;\n// MFCircle.defaultProps = defaultProps;\n\nvar RMFCircle = requireNativeComponent(`RMFCircle`, MFCircle);\n\nexport {MFCircle}\n"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;;;;;AAQA;AACA,MAAMA,aAAa,GAAGC,6CAAA,IAAiBC,IAAI,CAACC,SAA5C;AAEA,MAAMA,SAAS,GAAG,EAChB,GAAGH,aADa;;EAGhB;AACF;AACA;EACEI,MAAM,EAAEC,kBAAA,CAAUC,KAAV,CAAgB;IACtB;A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,oBAAV,CAA+BD,aAA/B,EAA8CE,QAA9C,CAAuDX,IAAvD,CAAP;EACD;;EAEDQ,kBAAkB,CAACR,IAAD,EAAO;IACvB,OAAOI,0BAAA,CAAe,WAAf,EAA2BJ,IAA3B,CAAP;EACD;;EAEDlB,QAAQ,CAAC8B,KAAD,EAAQ;IACdA,KAAK,CAACC,eAAN;;IACE,IAAI,KAAKhC,KAAL,CAAWN,OAAf,EAAwB;MACtB,KAAKM,KAAL,CAAWN,OAAX,CAAmBqC,KAAnB;IACH;EACF;;EAED5B,IAAI,CAAC8B,GAAD,EAAM;IACR,KAAKf,MAAL,GAAce,GAAd;EACD;;EAEDC,MAAM,GAAG;IACP,oBAAO,6BAAC,SAAD,eACD,KAAKlC,KADJ;MAEL,GAAG,EAAE,KAAKG,IAFL;MAGL,OAAO,EAAE,KAAKF;IAHT,GAAP;EAKD;;AA1FoC;;;AA6FvCL,QAAQ,CAACpB,SAAT,GAAqBA,SAArB,C,CACA;;AAEA,IAAI2D,SAAS,GAAG,IAAAC,mCAAA,EAAwB,WAAxB,EAAoCxC,QAApC,CAAhB"}
@@ -20,70 +20,70 @@ function _extends() { _extends = Object.assign || function (target) { for (var i
20
20
  const viewPropTypes = _deprecatedReactNativePropTypes.ViewPropTypes || View.propTypes;
21
21
  const propTypes = { ...viewPropTypes,
22
22
 
23
- /**
24
- * The directions to display on the map,
25
- * retrieved as an array of array of coordinates to describe the routes.
26
- * Similar to directions prop but has higher priority
23
+ /**
24
+ * The directions to display on the map,
25
+ * retrieved as an array of array of coordinates to describe the routes.
26
+ * Similar to directions prop but has higher priority
27
27
  */
28
28
  routes: _propTypes.default.arrayOf(_propTypes.default.arrayOf(_propTypes.default.shape({
29
29
  latitude: _propTypes.default.number.isRequired,
30
30
  longitude: _propTypes.default.number.isRequired
31
31
  }))),
32
32
 
33
- /**
34
- * The directions to display on the map,
35
- * retrieved as a json string from Get route Map4D API (/sdk/route).
36
- * Similar to routes prop but with lower priority
33
+ /**
34
+ * The directions to display on the map,
35
+ * retrieved as a json string from Get route Map4D API (/sdk/route).
36
+ * Similar to routes prop but with lower priority
37
37
  */
38
38
  directions: _propTypes.default.string,
39
39
 
40
- /**
41
- * The index of the main route, default value is 0.
40
+ /**
41
+ * The index of the main route, default value is 0.
42
42
  */
43
43
  activedIndex: _propTypes.default.number,
44
44
 
45
- /**
46
- * The active route stroke width.
45
+ /**
46
+ * The active route stroke width.
47
47
  */
48
48
  activeStrokeWidth: _propTypes.default.number,
49
49
 
50
- /**
51
- * The active route color.
50
+ /**
51
+ * The active route color.
52
52
  */
53
53
  activeStrokeColor: _deprecatedReactNativePropTypes.ColorPropType,
54
54
 
55
- /**
56
- * The active route outline stroke width.
55
+ /**
56
+ * The active route outline stroke width.
57
57
  */
58
58
  activeOutlineWidth: _propTypes.default.number,
59
59
 
60
- /**
61
- * The active route outline color.
60
+ /**
61
+ * The active route outline color.
62
62
  */
63
63
  activeOutlineColor: _deprecatedReactNativePropTypes.ColorPropType,
64
64
 
65
- /**
66
- * The inactive route stroke width.
65
+ /**
66
+ * The inactive route stroke width.
67
67
  */
68
68
  inactiveStrokeWidth: _propTypes.default.number,
69
69
 
70
- /**
71
- * The inactive route color.
70
+ /**
71
+ * The inactive route color.
72
72
  */
73
73
  inactiveStrokeColor: _deprecatedReactNativePropTypes.ColorPropType,
74
74
 
75
- /**
76
- * The inactive route outline stroke width.
75
+ /**
76
+ * The inactive route outline stroke width.
77
77
  */
78
78
  inactiveOutlineWidth: _propTypes.default.number,
79
79
 
80
- /**
81
- * The inactive route outline color.
80
+ /**
81
+ * The inactive route outline color.
82
82
  */
83
83
  inactiveOutlineColor: _deprecatedReactNativePropTypes.ColorPropType,
84
84
 
85
- /**
86
- * The options of the origin POI.
85
+ /**
86
+ * The options of the origin POI.
87
87
  */
88
88
  originPOIOptions: _propTypes.default.shape({
89
89
  coordinate: _propTypes.default.shape({
@@ -98,8 +98,8 @@ const propTypes = { ...viewPropTypes,
98
98
  visible: _propTypes.default.bool
99
99
  }),
100
100
 
101
- /**
102
- * The options of the destination POI.
101
+ /**
102
+ * The options of the destination POI.
103
103
  */
104
104
  destinationPOIOptions: _propTypes.default.shape({
105
105
  coordinate: _propTypes.default.shape({
@@ -114,8 +114,8 @@ const propTypes = { ...viewPropTypes,
114
114
  visible: _propTypes.default.bool
115
115
  }),
116
116
 
117
- /**
118
- * Callback that is called when the user presses on the routes.
117
+ /**
118
+ * Callback that is called when the user presses on the routes.
119
119
  */
120
120
  onPress: _propTypes.default.func
121
121
  };
@@ -1 +1 @@
1
- {"version":3,"names":["viewPropTypes","ViewPropTypes","View","propTypes","routes","PropTypes","arrayOf","shape","latitude","number","isRequired","longitude","directions","string","activedIndex","activeStrokeWidth","activeStrokeColor","ColorPropType","activeOutlineWidth","activeOutlineColor","inactiveStrokeWidth","inactiveStrokeColor","inactiveOutlineWidth","inactiveOutlineColor","originPOIOptions","coordinate","icon","uri","any","title","titleColor","visible","bool","destinationPOIOptions","onPress","func","MFDirectionsRenderer","React","Component","constructor","props","_ref","bind","_onPress","setActivedIndex","index","_runCommand","setRoutes","setDirections","render","processColor","Image","resolveAssetSource","ref","renderer","event","stopPropagation","name","args","Platform","OS","NativeModules","UIManager","dispatchViewManagerCommand","_getHandle","_uiManagerCommand","_mapManagerCommand","findNodeHandle","componentName","getViewManagerConfig","Commands","RMFDirectionsRenderer","requireNativeComponent"],"sources":["MFDirectionsRenderer.js"],"sourcesContent":["import React from 'react';\r\nimport PropTypes from 'prop-types';\r\nimport {ViewPropTypes, ColorPropType} from 'deprecated-react-native-prop-types';\r\nimport {\r\n requireNativeComponent,\r\n Platform,\r\n Image,\r\n NativeModules,\r\n findNodeHandle,\r\n processColor\r\n} from 'react-native';\r\n\r\nconst viewPropTypes = ViewPropTypes || View.propTypes;\r\n\r\nconst propTypes = {\r\n ...viewPropTypes,\r\n\r\n /**\r\n * The directions to display on the map,\r\n * retrieved as an array of array of coordinates to describe the routes.\r\n * Similar to directions prop but has higher priority\r\n */\r\n routes: PropTypes.arrayOf(\r\n PropTypes.arrayOf(\r\n PropTypes.shape({\r\n latitude: PropTypes.number.isRequired,\r\n longitude: PropTypes.number.isRequired,\r\n })\r\n )\r\n ),\r\n\r\n /**\r\n * The directions to display on the map,\r\n * retrieved as a json string from Get route Map4D API (/sdk/route).\r\n * Similar to routes prop but with lower priority\r\n */\r\n directions: PropTypes.string,\r\n\r\n /**\r\n * The index of the main route, default value is 0.\r\n */\r\n activedIndex: PropTypes.number,\r\n\r\n /**\r\n * The active route stroke width.\r\n */\r\n activeStrokeWidth: PropTypes.number,\r\n\r\n /**\r\n * The active route color.\r\n */\r\n activeStrokeColor: ColorPropType,\r\n\r\n /**\r\n * The active route outline stroke width.\r\n */\r\n activeOutlineWidth: PropTypes.number,\r\n\r\n /**\r\n * The active route outline color.\r\n */\r\n activeOutlineColor: ColorPropType,\r\n\r\n /**\r\n * The inactive route stroke width.\r\n */\r\n inactiveStrokeWidth: PropTypes.number,\r\n\r\n /**\r\n * The inactive route color.\r\n */\r\n inactiveStrokeColor: ColorPropType,\r\n\r\n /**\r\n * The inactive route outline stroke width.\r\n */\r\n inactiveOutlineWidth: PropTypes.number,\r\n\r\n /**\r\n * The inactive route outline color.\r\n */\r\n inactiveOutlineColor: ColorPropType,\r\n\r\n /**\r\n * The options of the origin POI.\r\n */\r\n originPOIOptions: PropTypes.shape({\r\n coordinate: PropTypes.shape({\r\n latitude: PropTypes.number.isRequired,\r\n longitude: PropTypes.number.isRequired,\r\n }),\r\n\r\n icon: PropTypes.shape({\r\n uri: PropTypes.any.isRequired\r\n }),\r\n\r\n title: PropTypes.string,\r\n\r\n titleColor: ColorPropType,\r\n\r\n visible: PropTypes.bool,\r\n }),\r\n\r\n /**\r\n * The options of the destination POI.\r\n */\r\n destinationPOIOptions: PropTypes.shape({\r\n coordinate: PropTypes.shape({\r\n latitude: PropTypes.number.isRequired,\r\n longitude: PropTypes.number.isRequired,\r\n }),\r\n\r\n icon: PropTypes.shape({\r\n uri: PropTypes.any.isRequired\r\n }),\r\n\r\n title: PropTypes.string,\r\n\r\n titleColor: ColorPropType,\r\n\r\n visible: PropTypes.bool,\r\n }),\r\n\r\n /**\r\n * Callback that is called when the user presses on the routes.\r\n */\r\n onPress: PropTypes.func,\r\n};\r\n\r\nclass MFDirectionsRenderer extends React.Component {\r\n constructor(props) {\r\n super(props)\r\n this._ref = this._ref.bind(this)\r\n this._onPress = this._onPress.bind(this)\r\n }\r\n\r\n setActivedIndex(index) {\r\n this._runCommand(\"setActivedIndex\", [index])\r\n }\r\n\r\n setRoutes(routes) {\r\n this._runCommand(\"setRoutes\", [routes])\r\n }\r\n\r\n setDirections(directions) {\r\n this._runCommand(\"setDirections\", [directions])\r\n }\r\n\r\n render() {\r\n let originPOIOptions = this.props.originPOIOptions\r\n if (originPOIOptions) {\r\n if (originPOIOptions.titleColor) {\r\n originPOIOptions.titleColor = processColor(originPOIOptions.titleColor)\r\n }\r\n if (originPOIOptions.icon) {\r\n let uri = Image.resolveAssetSource(originPOIOptions.icon.uri) || {uri: originPOIOptions.icon.uri};\r\n originPOIOptions.icon = {uri: uri.uri}\r\n }\r\n }\r\n\r\n let destinationPOIOptions = this.props.destinationPOIOptions\r\n if (destinationPOIOptions) {\r\n if (destinationPOIOptions.titleColor) {\r\n destinationPOIOptions.titleColor = processColor(destinationPOIOptions.titleColor)\r\n }\r\n if (destinationPOIOptions.icon) {\r\n let uri = Image.resolveAssetSource(destinationPOIOptions.icon.uri) || {uri: destinationPOIOptions.icon.uri};\r\n destinationPOIOptions.icon = {uri: uri.uri}\r\n }\r\n }\r\n\r\n return <RMFDirectionsRenderer\r\n {...this.props}\r\n originPOIOptions={originPOIOptions}\r\n destinationPOIOptions={destinationPOIOptions}\r\n ref={this._ref}\r\n onPress={this._onPress}\r\n />;\r\n }\r\n\r\n _ref(ref) {\r\n this.renderer = ref;\r\n }\r\n\r\n _onPress(event) {\r\n event.stopPropagation();\r\n if (this.props.onPress) {\r\n this.props.onPress(event);\r\n }\r\n }\r\n\r\n _runCommand(name, args) {\r\n switch (Platform.OS) {\r\n case 'android':\r\n NativeModules.UIManager.dispatchViewManagerCommand(\r\n this._getHandle(),\r\n this._uiManagerCommand(name),\r\n args\r\n );\r\n break;\r\n\r\n case 'ios':\r\n this._mapManagerCommand(name)(this._getHandle(), ...args);\r\n break;\r\n\r\n default:\r\n break;\r\n }\r\n }\r\n\r\n _getHandle() {\r\n return findNodeHandle(this.renderer);\r\n }\r\n\r\n _uiManagerCommand(name) {\r\n const UIManager = NativeModules.UIManager;\r\n const componentName = \"RMFDirectionsRenderer\";\r\n\r\n if (!UIManager.getViewManagerConfig) {\r\n // RN < 0.58\r\n return UIManager[componentName].Commands[name];\r\n }\r\n\r\n // RN >= 0.58 \r\n return UIManager.getViewManagerConfig(componentName).Commands[name];\r\n }\r\n\r\n _mapManagerCommand(name) {\r\n return NativeModules[`RMFDirectionsRenderer`][name];\r\n }\r\n}\r\n\r\nMFDirectionsRenderer.propTypes = propTypes;\r\n\r\nvar RMFDirectionsRenderer = requireNativeComponent(`RMFDirectionsRenderer`, MFDirectionsRenderer);\r\n\r\nexport { MFDirectionsRenderer }\r\n"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;;;;;AASA,MAAMA,aAAa,GAAGC,6CAAA,IAAiBC,IAAI,CAACC,SAA5C;AAEA,MAAMA,SAAS,GAAG,EAChB,GAAGH,aADa;;EAGhB;AACF;AACA;AACA;AACA;EACEI,MAAM,EAAEC,kBAAA,CAAUC,OAAV,CACND,kBAAA,CAAUC,OAAV,CACED,kBAAA,CAAUE,KAAV,CAAgB;IACdC,QAAQ,EAAEH,kBAAA,CAAUI,MAAV,CAAiBC,UADb;IAEdC,SAAS,EAAEN,kBAAA,CAAUI,MAAV,CAAiBC;EAFd,CAAhB,CADF,CADM,CARQ;;EAiBhB;AACF;AACA;AACA;AACA;EACEE,UAAU,EAAEP,kBAAA,CAAUQ,MAtBN;;EAwBhB;AACF;AACA;EACEC,YAAY,EAAET,kBAAA,CAA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CAAwBC,0BAAxB,CACE,KAAKC,UAAL,EADF,EAEE,KAAKC,iBAAL,CAAuBR,IAAvB,CAFF,EAGEC,IAHF;;QAKA;;MAEF,KAAK,KAAL;QACE,KAAKQ,kBAAL,CAAwBT,IAAxB,EAA8B,KAAKO,UAAL,EAA9B,EAAiD,GAAGN,IAApD;;QACA;;MAEF;QACE;IAdJ;EAgBD;;EAEDM,UAAU,GAAG;IACX,OAAO,IAAAG,2BAAA,EAAe,KAAKb,QAApB,CAAP;EACD;;EAEDW,iBAAiB,CAACR,IAAD,EAAO;IACtB,MAAMK,SAAS,GAAGD,0BAAA,CAAcC,SAAhC;IACA,MAAMM,aAAa,GAAG,uBAAtB;;IAEA,IAAI,CAACN,SAAS,CAACO,oBAAf,EAAqC;MACnC;MACA,OAAOP,SAAS,CAACM,aAAD,CAAT,CAAyBE,QAAzB,CAAkCb,IAAlC,CAAP;IACD,CAPqB,CAStB;;;IACA,OAAOK,SAAS,CAACO,oBAAV,CAA+BD,aAA/B,EAA8CE,QAA9C,CAAuDb,IAAvD,CAAP;EACD;;EAEDS,kBAAkB,CAACT,IAAD,EAAO;IACvB,OAAOI,0BAAA,CAAe,uBAAf,EAAuCJ,IAAvC,CAAP;EACD;;AApGgD;;;AAuGnDrB,oBAAoB,CAACjC,SAArB,GAAiCA,SAAjC;AAEA,IAAIoE,qBAAqB,GAAG,IAAAC,mCAAA,EAAwB,uBAAxB,EAAgDpC,oBAAhD,CAA5B"}
1
+ {"version":3,"names":["viewPropTypes","ViewPropTypes","View","propTypes","routes","PropTypes","arrayOf","shape","latitude","number","isRequired","longitude","directions","string","activedIndex","activeStrokeWidth","activeStrokeColor","ColorPropType","activeOutlineWidth","activeOutlineColor","inactiveStrokeWidth","inactiveStrokeColor","inactiveOutlineWidth","inactiveOutlineColor","originPOIOptions","coordinate","icon","uri","any","title","titleColor","visible","bool","destinationPOIOptions","onPress","func","MFDirectionsRenderer","React","Component","constructor","props","_ref","bind","_onPress","setActivedIndex","index","_runCommand","setRoutes","setDirections","render","processColor","Image","resolveAssetSource","ref","renderer","event","stopPropagation","name","args","Platform","OS","NativeModules","UIManager","dispatchViewManagerCommand","_getHandle","_uiManagerCommand","_mapManagerCommand","findNodeHandle","componentName","getViewManagerConfig","Commands","RMFDirectionsRenderer","requireNativeComponent"],"sources":["MFDirectionsRenderer.js"],"sourcesContent":["import React from 'react';\nimport PropTypes from 'prop-types';\nimport {ViewPropTypes, ColorPropType} from 'deprecated-react-native-prop-types';\nimport {\n requireNativeComponent,\n Platform,\n Image,\n NativeModules,\n findNodeHandle,\n processColor\n} from 'react-native';\n\nconst viewPropTypes = ViewPropTypes || View.propTypes;\n\nconst propTypes = {\n ...viewPropTypes,\n\n /**\n * The directions to display on the map,\n * retrieved as an array of array of coordinates to describe the routes.\n * Similar to directions prop but has higher priority\n */\n routes: PropTypes.arrayOf(\n PropTypes.arrayOf(\n PropTypes.shape({\n latitude: PropTypes.number.isRequired,\n longitude: PropTypes.number.isRequired,\n })\n )\n ),\n\n /**\n * The directions to display on the map,\n * retrieved as a json string from Get route Map4D API (/sdk/route).\n * Similar to routes prop but with lower priority\n */\n directions: PropTypes.string,\n\n /**\n * The index of the main route, default value is 0.\n */\n activedIndex: PropTypes.number,\n\n /**\n * The active route stroke width.\n */\n activeStrokeWidth: PropTypes.number,\n\n /**\n * The active route color.\n */\n activeStrokeColor: ColorPropType,\n\n /**\n * The active route outline stroke width.\n */\n activeOutlineWidth: PropTypes.number,\n\n /**\n * The active route outline color.\n */\n activeOutlineColor: ColorPropType,\n\n /**\n * The inactive route stroke width.\n */\n inactiveStrokeWidth: PropTypes.number,\n\n /**\n * The inactive route color.\n */\n inactiveStrokeColor: ColorPropType,\n\n /**\n * The inactive route outline stroke width.\n */\n inactiveOutlineWidth: PropTypes.number,\n\n /**\n * The inactive route outline color.\n */\n inactiveOutlineColor: ColorPropType,\n\n /**\n * The options of the origin POI.\n */\n originPOIOptions: PropTypes.shape({\n coordinate: PropTypes.shape({\n latitude: PropTypes.number.isRequired,\n longitude: PropTypes.number.isRequired,\n }),\n\n icon: PropTypes.shape({\n uri: PropTypes.any.isRequired\n }),\n\n title: PropTypes.string,\n\n titleColor: ColorPropType,\n\n visible: PropTypes.bool,\n }),\n\n /**\n * The options of the destination POI.\n */\n destinationPOIOptions: PropTypes.shape({\n coordinate: PropTypes.shape({\n latitude: PropTypes.number.isRequired,\n longitude: PropTypes.number.isRequired,\n }),\n\n icon: PropTypes.shape({\n uri: PropTypes.any.isRequired\n }),\n\n title: PropTypes.string,\n\n titleColor: ColorPropType,\n\n visible: PropTypes.bool,\n }),\n\n /**\n * Callback that is called when the user presses on the routes.\n */\n onPress: PropTypes.func,\n};\n\nclass MFDirectionsRenderer extends React.Component {\n constructor(props) {\n super(props)\n this._ref = this._ref.bind(this)\n this._onPress = this._onPress.bind(this)\n }\n\n setActivedIndex(index) {\n this._runCommand(\"setActivedIndex\", [index])\n }\n\n setRoutes(routes) {\n this._runCommand(\"setRoutes\", [routes])\n }\n\n setDirections(directions) {\n this._runCommand(\"setDirections\", [directions])\n }\n\n render() {\n let originPOIOptions = this.props.originPOIOptions\n if (originPOIOptions) {\n if (originPOIOptions.titleColor) {\n originPOIOptions.titleColor = processColor(originPOIOptions.titleColor)\n }\n if (originPOIOptions.icon) {\n let uri = Image.resolveAssetSource(originPOIOptions.icon.uri) || {uri: originPOIOptions.icon.uri};\n originPOIOptions.icon = {uri: uri.uri}\n }\n }\n\n let destinationPOIOptions = this.props.destinationPOIOptions\n if (destinationPOIOptions) {\n if (destinationPOIOptions.titleColor) {\n destinationPOIOptions.titleColor = processColor(destinationPOIOptions.titleColor)\n }\n if (destinationPOIOptions.icon) {\n let uri = Image.resolveAssetSource(destinationPOIOptions.icon.uri) || {uri: destinationPOIOptions.icon.uri};\n destinationPOIOptions.icon = {uri: uri.uri}\n }\n }\n\n return <RMFDirectionsRenderer\n {...this.props}\n originPOIOptions={originPOIOptions}\n destinationPOIOptions={destinationPOIOptions}\n ref={this._ref}\n onPress={this._onPress}\n />;\n }\n\n _ref(ref) {\n this.renderer = ref;\n }\n\n _onPress(event) {\n event.stopPropagation();\n if (this.props.onPress) {\n this.props.onPress(event);\n }\n }\n\n _runCommand(name, args) {\n switch (Platform.OS) {\n case 'android':\n NativeModules.UIManager.dispatchViewManagerCommand(\n this._getHandle(),\n this._uiManagerCommand(name),\n args\n );\n break;\n\n case 'ios':\n this._mapManagerCommand(name)(this._getHandle(), ...args);\n break;\n\n default:\n break;\n }\n }\n\n _getHandle() {\n return findNodeHandle(this.renderer);\n }\n\n _uiManagerCommand(name) {\n const UIManager = NativeModules.UIManager;\n const componentName = \"RMFDirectionsRenderer\";\n\n if (!UIManager.getViewManagerConfig) {\n // RN < 0.58\n return UIManager[componentName].Commands[name];\n }\n\n // RN >= 0.58 \n return UIManager.getViewManagerConfig(componentName).Commands[name];\n }\n\n _mapManagerCommand(name) {\n return NativeModules[`RMFDirectionsRenderer`][name];\n }\n}\n\nMFDirectionsRenderer.propTypes = propTypes;\n\nvar RMFDirectionsRenderer = requireNativeComponent(`RMFDirectionsRenderer`, MFDirectionsRenderer);\n\nexport { MFDirectionsRenderer }\n"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;;;;;AASA,MAAMA,aAAa,GAAGC,6CAAA,IAAiBC,IAAI,CAACC,SAA5C;AAEA,MAAMA,SAAS,GAAG,EAChB,GAAGH,aADa;;EAGhB;AACF;AACA;AACA;AACA;EACEI,MAAM,EAAEC,kBAAA,CAAUC,OAAV,CACND,kBAAA,CAAUC,OAAV,CACED,kBAAA,CAAUE,KAAV,CAAgB;IACdC,QAAQ,EAAEH,kBAAA,CAAUI,MAAV,CAAiBC,UADb;IAEdC,SAAS,EAAEN,kBAAA,CAAUI,MAAV,CAAiBC;EAFd,CAAhB,CADF,CADM,CARQ;;EAiBhB;AACF;AACA;AACA;AACA;EACEE,UAAU,EAAEP,kBAAA,CAAUQ,MAtBN;;EAwBhB;AACF;AACA;EACEC,YAAY,EAAET,kBAAA,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Ad,CAAwBC,0BAAxB,CACE,KAAKC,UAAL,EADF,EAEE,KAAKC,iBAAL,CAAuBR,IAAvB,CAFF,EAGEC,IAHF;;QAKA;;MAEF,KAAK,KAAL;QACE,KAAKQ,kBAAL,CAAwBT,IAAxB,EAA8B,KAAKO,UAAL,EAA9B,EAAiD,GAAGN,IAApD;;QACA;;MAEF;QACE;IAdJ;EAgBD;;EAEDM,UAAU,GAAG;IACX,OAAO,IAAAG,2BAAA,EAAe,KAAKb,QAApB,CAAP;EACD;;EAEDW,iBAAiB,CAACR,IAAD,EAAO;IACtB,MAAMK,SAAS,GAAGD,0BAAA,CAAcC,SAAhC;IACA,MAAMM,aAAa,GAAG,uBAAtB;;IAEA,IAAI,CAACN,SAAS,CAACO,oBAAf,EAAqC;MACnC;MACA,OAAOP,SAAS,CAACM,aAAD,CAAT,CAAyBE,QAAzB,CAAkCb,IAAlC,CAAP;IACD,CAPqB,CAStB;;;IACA,OAAOK,SAAS,CAACO,oBAAV,CAA+BD,aAA/B,EAA8CE,QAA9C,CAAuDb,IAAvD,CAAP;EACD;;EAEDS,kBAAkB,CAACT,IAAD,EAAO;IACvB,OAAOI,0BAAA,CAAe,uBAAf,EAAuCJ,IAAvC,CAAP;EACD;;AApGgD;;;AAuGnDrB,oBAAoB,CAACjC,SAArB,GAAiCA,SAAjC;AAEA,IAAIoE,qBAAqB,GAAG,IAAAC,mCAAA,EAAwB,uBAAxB,EAAgDpC,oBAAhD,CAA5B"}
@@ -37,122 +37,122 @@ const CameraShape = _propTypes.default.shape({
37
37
  const viewPropTypes = _deprecatedReactNativePropTypes.ViewPropTypes || View.propTypes;
38
38
  const propTypes = { ...viewPropTypes,
39
39
 
40
- /**
41
- * An opaque identifier for a custom map configuration.
40
+ /**
41
+ * An opaque identifier for a custom map configuration.
42
42
  */
43
43
  mapID: _propTypes.default.string,
44
44
 
45
- /**
46
- * Map style by string for a custom map configuration.
45
+ /**
46
+ * Map style by string for a custom map configuration.
47
47
  */
48
48
  mapStyle: _propTypes.default.string,
49
49
 
50
- /**
51
- * If `false` hide the button to move map to the current user's location.
52
- * Default value is `false`.
50
+ /**
51
+ * If `false` hide the button to move map to the current user's location.
52
+ * Default value is `false`.
53
53
  */
54
54
  showsMyLocationButton: _propTypes.default.bool,
55
55
 
56
- /**
57
- * If `true` the app will ask for the user's location.
58
- * Default value is `false`.
56
+ /**
57
+ * If `true` the app will ask for the user's location.
58
+ * Default value is `false`.
59
59
  */
60
60
  showsMyLocation: _propTypes.default.bool,
61
61
 
62
- /**
63
- * A Boolean indicating whether the map displays buildings.
64
- * Default value is `true`.
62
+ /**
63
+ * A Boolean indicating whether the map displays buildings.
64
+ * Default value is `true`.
65
65
  */
66
66
  showsBuildings: _propTypes.default.bool,
67
67
 
68
- /**
69
- * A Boolean indicating whether the map displays POIs.
70
- * Default value is `true`.
68
+ /**
69
+ * A Boolean indicating whether the map displays POIs.
70
+ * Default value is `true`.
71
71
  */
72
72
  showsPOIs: _propTypes.default.bool,
73
73
 
74
- /**
75
- * If `false` the user won't be able to zoom the map.
76
- * Default value is `true`.
74
+ /**
75
+ * If `false` the user won't be able to zoom the map.
76
+ * Default value is `true`.
77
77
  */
78
78
  zoomGesturesEnabled: _propTypes.default.bool,
79
79
 
80
- /**
81
- * If `false` the user won't be able to scroll the map.
82
- * Default value is `true`.
80
+ /**
81
+ * If `false` the user won't be able to scroll the map.
82
+ * Default value is `true`.
83
83
  */
84
84
  scrollGesturesEnabled: _propTypes.default.bool,
85
85
 
86
- /**
87
- * If `false` the user won't be able to pinch/rotate the map.
88
- * Default value is `true`.
86
+ /**
87
+ * If `false` the user won't be able to pinch/rotate the map.
88
+ * Default value is `true`.
89
89
  */
90
90
  rotateGesturesEnabled: _propTypes.default.bool,
91
91
 
92
- /**
93
- * If `false` the user won't be able to tilt the map.
94
- * Default value is `true`.
92
+ /**
93
+ * If `false` the user won't be able to tilt the map.
94
+ * Default value is `true`.
95
95
  */
96
96
  tiltGesturesEnabled: _propTypes.default.bool,
97
97
 
98
- /**
99
- * The camera view position.
98
+ /**
99
+ * The camera view position.
100
100
  */
101
101
  camera: CameraShape,
102
102
 
103
- /**
104
- * Type of map tiles to be rendered.
103
+ /**
104
+ * Type of map tiles to be rendered.
105
105
  */
106
106
  mapType: _propTypes.default.oneOf(['roadmap', 'satellite', 'hybrid']),
107
107
 
108
- /**
109
- * Callback that is called once the map is fully loaded.
110
- * @platform android
108
+ /**
109
+ * Callback that is called once the map is fully loaded.
110
+ * @platform android
111
111
  */
112
112
  onMapReady: _propTypes.default.func,
113
113
 
114
- /**
115
- * Callback that is called when user taps on the map.
114
+ /**
115
+ * Callback that is called when user taps on the map.
116
116
  */
117
117
  onPress: _propTypes.default.func,
118
118
 
119
- /**
120
- * Callback that is called when user taps on the POIs
119
+ /**
120
+ * Callback that is called when user taps on the POIs
121
121
  */
122
122
  onPoiPress: _propTypes.default.func,
123
123
 
124
- /**
125
- * Callback that is called when user taps on the Buildings
124
+ /**
125
+ * Callback that is called when user taps on the Buildings
126
126
  */
127
127
  onBuildingPress: _propTypes.default.func,
128
128
 
129
- /**
130
- * Callback that is called when user taps on the Places
129
+ /**
130
+ * Callback that is called when user taps on the Places
131
131
  */
132
132
  onPlacePress: _propTypes.default.func,
133
133
 
134
- /**
135
- * Callback that is called when user taps on the Data Source Features
134
+ /**
135
+ * Callback that is called when user taps on the Data Source Features
136
136
  */
137
137
  onDataSourceFeaturePress: _propTypes.default.func,
138
138
 
139
- /**
140
- * Callback that is called when moving camera
139
+ /**
140
+ * Callback that is called when moving camera
141
141
  */
142
142
  onCameraMove: _propTypes.default.func,
143
143
 
144
- /**
145
- * Callback that is called when camera start moving
144
+ /**
145
+ * Callback that is called when camera start moving
146
146
  */
147
147
  onCameraMoveStart: _propTypes.default.func,
148
148
 
149
- /**
150
- * Callback that is called when camera idle
149
+ /**
150
+ * Callback that is called when camera idle
151
151
  */
152
152
  onCameraIdle: _propTypes.default.func,
153
153
 
154
- /**
155
- * Callback that is called when user taps on location Button
154
+ /**
155
+ * Callback that is called when user taps on location Button
156
156
  */
157
157
  onMyLocationButtonPress: _propTypes.default.func
158
158
  };
@@ -322,14 +322,14 @@ class MFMapView extends _react.default.Component {
322
322
 
323
323
  return Promise.reject('cameraForBounds not supported on this platform');
324
324
  }
325
- /**
326
- * Convert a map coordinate to screen point
327
- *
328
- * @param coordinate Coordinate
329
- * @param [coordinate.latitude] Latitude
330
- * @param [coordinate.longitude] Longitude
331
- *
332
- * @return Promise Promise with the point ({ x: Number, y: Number })
325
+ /**
326
+ * Convert a map coordinate to screen point
327
+ *
328
+ * @param coordinate Coordinate
329
+ * @param [coordinate.latitude] Latitude
330
+ * @param [coordinate.longitude] Longitude
331
+ *
332
+ * @return Promise Promise with the point ({ x: Number, y: Number })
333
333
  */
334
334
 
335
335
 
@@ -342,14 +342,14 @@ class MFMapView extends _react.default.Component {
342
342
 
343
343
  return Promise.reject('pointForCoordinate not supported on this platform');
344
344
  }
345
- /**
346
- * Convert a screen point to a map coordinate
347
- *
348
- * @param point Point
349
- * @param [point.x] X
350
- * @param [point.x] Y
351
- *
352
- * @return Promise Promise with the coordinate ({ latitude: Number, longitude: Number })
345
+ /**
346
+ * Convert a screen point to a map coordinate
347
+ *
348
+ * @param point Point
349
+ * @param [point.x] X
350
+ * @param [point.x] Y
351
+ *
352
+ * @return Promise Promise with the coordinate ({ latitude: Number, longitude: Number })
353
353
  */
354
354
 
355
355
 
@@ -1 +1 @@
1
- {"version":3,"names":["CameraShape","PropTypes","shape","target","latitude","number","isRequired","longitude","zoom","bearing","tilt","viewPropTypes","ViewPropTypes","View","propTypes","mapID","string","mapStyle","showsMyLocationButton","bool","showsMyLocation","showsBuildings","showsPOIs","zoomGesturesEnabled","scrollGesturesEnabled","rotateGesturesEnabled","tiltGesturesEnabled","camera","mapType","oneOf","onMapReady","func","onPress","onPoiPress","onBuildingPress","onPlacePress","onDataSourceFeaturePress","onCameraMove","onCameraMoveStart","onCameraIdle","onMyLocationButtonPress","MFMapView","React","Component","constructor","props","areaFocusManager","AreaFocusManager","areaFocuser","AreaFocuser","state","isReady","Platform","OS","managedPolygons","_onMapReady","bind","_ref","_addPolygon","polygon","id","trim","length","_polygon","setState","prevState","_removePolygon","_clearManagedPolygons","ref","map","getCamera","NativeModules","Map4dMap","_getHandle","_runCommand","Promise","reject","getBounds","getMyLocation","animateCamera","moveCamera","setMyLocationEnabled","enable","setPOIsEnabled","setZoomGesturesEnabled","setScrollGesturesEnabled","setRotateGesturesEnabled","setTiltGesturesEnabled","setAllGesturesEnabled","setTime","time","t","Date","parse","isNaN","console","log","fitBounds","boundsData","cameraForBounds","pointForCoordinate","coordinate","coordinateForPoint","point","focusArea","focusOptions","resolve","focus","clearFocusedArea","clear","findNodeHandle","name","args","UIManager","dispatchViewManagerCommand","_uiManagerCommand","_mapManagerCommand","componentName","getViewManagerConfig","Commands","render","children","restProps","Object","values","style","coordinates","holes","fillColor","strokeColor","strokeWidth","zIndex","RMFMapView","requireNativeComponent"],"sources":["MFMapView.js"],"sourcesContent":["import PropTypes from 'prop-types';\r\nimport React from 'react';\r\nimport {ViewPropTypes, ColorPropType} from 'deprecated-react-native-prop-types';\r\nimport {AreaFocusManager} from './extends/AreaFocusManager';\r\nimport {AreaFocuser} from './extends/AreaFocuser';\r\nimport {MFPolygon} from './MFPolygon';\r\nimport {\r\n requireNativeComponent,\r\n Platform,\r\n NativeModules,\r\n findNodeHandle\r\n} from 'react-native';\r\n\r\nconst CameraShape = PropTypes.shape({\r\n target: PropTypes.shape({\r\n latitude: PropTypes.number.isRequired,\r\n longitude: PropTypes.number.isRequired,\r\n }),\r\n zoom: PropTypes.number.isRequired,\r\n bearing: PropTypes.number.isRequired,\r\n tilt: PropTypes.number.isRequired,\r\n});\r\n\r\n// if ViewPropTypes is not defined fall back to View.propType (to support RN < 0.44)\r\nconst viewPropTypes = ViewPropTypes || View.propTypes;\r\n\r\nconst propTypes = {\r\n ...viewPropTypes,\r\n\r\n /**\r\n * An opaque identifier for a custom map configuration.\r\n */\r\n mapID: PropTypes.string,\r\n\r\n /**\r\n * Map style by string for a custom map configuration.\r\n */\r\n mapStyle: PropTypes.string,\r\n\r\n /**\r\n * If `false` hide the button to move map to the current user's location.\r\n * Default value is `false`.\r\n */\r\n showsMyLocationButton: PropTypes.bool,\r\n\r\n /**\r\n * If `true` the app will ask for the user's location.\r\n * Default value is `false`.\r\n */\r\n showsMyLocation: PropTypes.bool,\r\n\r\n /**\r\n * A Boolean indicating whether the map displays buildings.\r\n * Default value is `true`.\r\n */\r\n showsBuildings: PropTypes.bool,\r\n\r\n /**\r\n * A Boolean indicating whether the map displays POIs.\r\n * Default value is `true`.\r\n */\r\n showsPOIs: PropTypes.bool,\r\n\r\n /**\r\n * If `false` the user won't be able to zoom the map.\r\n * Default value is `true`.\r\n */\r\n zoomGesturesEnabled: PropTypes.bool,\r\n\r\n /**\r\n * If `false` the user won't be able to scroll the map.\r\n * Default value is `true`.\r\n */\r\n scrollGesturesEnabled: PropTypes.bool,\r\n\r\n /**\r\n * If `false` the user won't be able to pinch/rotate the map.\r\n * Default value is `true`.\r\n */\r\n rotateGesturesEnabled: PropTypes.bool,\r\n\r\n /**\r\n * If `false` the user won't be able to tilt the map.\r\n * Default value is `true`.\r\n */\r\n tiltGesturesEnabled: PropTypes.bool,\r\n\r\n /**\r\n * The camera view position.\r\n */\r\n camera: CameraShape,\r\n\r\n /**\r\n * Type of map tiles to be rendered.\r\n */\r\n mapType: PropTypes.oneOf(['roadmap', 'satellite', 'hybrid']),\r\n\r\n /**\r\n * Callback that is called once the map is fully loaded.\r\n * @platform android\r\n */\r\n onMapReady: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when user taps on the map.\r\n */\r\n onPress: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when user taps on the POIs\r\n */\r\n onPoiPress: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when user taps on the Buildings\r\n */\r\n onBuildingPress: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when user taps on the Places\r\n */\r\n onPlacePress: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when user taps on the Data Source Features\r\n */\r\n onDataSourceFeaturePress: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when moving camera\r\n */\r\n onCameraMove: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when camera start moving\r\n */\r\n onCameraMoveStart: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when camera idle\r\n */\r\n onCameraIdle: PropTypes.func,\r\n\r\n /**\r\n * Callback that is called when user taps on location Button\r\n */\r\n onMyLocationButtonPress: PropTypes.func,\r\n\r\n};\r\n\r\n\r\nclass MFMapView extends React.Component {\r\n constructor(props) {\r\n super(props);\r\n this.areaFocusManager = new AreaFocusManager(this);\r\n this.areaFocuser = new AreaFocuser(this.areaFocusManager);\r\n this.state = {\r\n isReady: Platform.OS === 'ios',\r\n managedPolygons: {},\r\n };\r\n\r\n this._onMapReady = this._onMapReady.bind(this);\r\n this._ref = this._ref.bind(this);\r\n }\r\n\r\n _addPolygon(polygon) {\r\n if (polygon == null || typeof polygon !== 'object') {\r\n return null;\r\n }\r\n\r\n const id =\r\n typeof polygon.id === 'string' && polygon.id.trim().length > 0\r\n ? polygon.id\r\n : 'polygon-highlight-id-default';\r\n\r\n const _polygon = {\r\n ...polygon,\r\n id,\r\n };\r\n\r\n this.setState((prevState) => ({\r\n managedPolygons: {\r\n ...prevState.managedPolygons,\r\n [id]: _polygon,\r\n },\r\n }));\r\n\r\n return id;\r\n }\r\n\r\n _removePolygon(id) {\r\n if (typeof id !== 'string' || id.trim().length === 0) {\r\n return;\r\n }\r\n\r\n this.setState((prevState) => {\r\n if (!prevState.managedPolygons[id]) {\r\n return null;\r\n }\r\n\r\n const managedPolygons = {\r\n ...prevState.managedPolygons,\r\n };\r\n delete managedPolygons[id];\r\n\r\n return {\r\n managedPolygons,\r\n };\r\n });\r\n }\r\n\r\n _clearManagedPolygons() {\r\n this.setState({\r\n managedPolygons: {},\r\n });\r\n }\r\n\r\n _onMapReady() {\r\n const { onMapReady } = this.props;\r\n this.setState({ isReady: true }, () => {\r\n if (onMapReady) {\r\n onMapReady();\r\n }\r\n });\r\n }\r\n\r\n _ref(ref) {\r\n this.map = ref;\r\n }\r\n\r\n getCamera() {\r\n if (Platform.OS === 'android') {\r\n return NativeModules.Map4dMap.getCamera(this._getHandle());\r\n } else if (Platform.OS === 'ios') {\r\n return this._runCommand('getCamera', []);\r\n }\r\n return Promise.reject('Function not supported on this platform');\r\n }\r\n\r\n getBounds() {\r\n if (Platform.OS === 'android') {\r\n return NativeModules.Map4dMap.getBounds(this._getHandle());\r\n } else if (Platform.OS === 'ios') {\r\n return this._runCommand('getBounds', []);\r\n }\r\n return Promise.reject('Function not supported on this platform');\r\n }\r\n\r\n getMyLocation() {\r\n if (Platform.OS === 'android') {\r\n return NativeModules.Map4dMap.getMyLocation(this._getHandle());\r\n } else if (Platform.OS === 'ios') {\r\n return this._runCommand('getMyLocation', []);\r\n }\r\n return Promise.reject('Function not supported on this platform');\r\n }\r\n\r\n animateCamera(camera) {\r\n this._runCommand('animateCamera', [camera]);\r\n }\r\n\r\n moveCamera(camera) {\r\n this._runCommand('moveCamera', [camera]);\r\n }\r\n\r\n setMyLocationEnabled(enable) {\r\n this._runCommand('setMyLocationEnabled', [enable]);\r\n }\r\n\r\n showsMyLocationButton(enable) {\r\n this._runCommand('showsMyLocationButton', [enable]);\r\n }\r\n\r\n setPOIsEnabled(enable) {\r\n this._runCommand('setPOIsEnabled', [enable]);\r\n }\r\n\r\n setZoomGesturesEnabled(enable) {\r\n this._runCommand('setZoomGesturesEnabled', [enable]);\r\n }\r\n\r\n setScrollGesturesEnabled(enable) {\r\n this._runCommand('setScrollGesturesEnabled', [enable]);\r\n }\r\n\r\n setRotateGesturesEnabled(enable) {\r\n this._runCommand('setRotateGesturesEnabled', [enable]);\r\n }\r\n\r\n setTiltGesturesEnabled(enable) {\r\n this._runCommand('setTiltGesturesEnabled', [enable]);\r\n }\r\n\r\n setAllGesturesEnabled(enable) {\r\n this._runCommand('setAllGesturesEnabled', [enable]);\r\n }\r\n\r\n setTime(time) {\r\n let t = Date.parse(time)\r\n if (isNaN(t)) {\r\n console.log('time invalid')\r\n }\r\n else {\r\n this._runCommand('setTime', [t]);\r\n }\r\n }\r\n\r\n fitBounds(boundsData) {\r\n this._runCommand(\"fitBounds\", [boundsData])\r\n }\r\n\r\n cameraForBounds(boundsData) {\r\n if (Platform.OS === 'android') {\r\n return NativeModules.Map4dMap.cameraForBounds(\r\n this._getHandle(),\r\n boundsData\r\n );\r\n } else if (Platform.OS === 'ios') {\r\n return this._runCommand('cameraForBounds', [boundsData]);\r\n }\r\n return Promise.reject('cameraForBounds not supported on this platform');\r\n }\r\n\r\n\r\n /**\r\n * Convert a map coordinate to screen point\r\n *\r\n * @param coordinate Coordinate\r\n * @param [coordinate.latitude] Latitude\r\n * @param [coordinate.longitude] Longitude\r\n *\r\n * @return Promise Promise with the point ({ x: Number, y: Number })\r\n */\r\n pointForCoordinate(coordinate) {\r\n if (Platform.OS === 'android') {\r\n return NativeModules.Map4dMap.pointForCoordinate(\r\n this._getHandle(),\r\n coordinate\r\n );\r\n } else if (Platform.OS === 'ios') {\r\n return this._runCommand('pointForCoordinate', [coordinate]);\r\n }\r\n return Promise.reject('pointForCoordinate not supported on this platform');\r\n }\r\n\r\n /**\r\n * Convert a screen point to a map coordinate\r\n *\r\n * @param point Point\r\n * @param [point.x] X\r\n * @param [point.x] Y\r\n *\r\n * @return Promise Promise with the coordinate ({ latitude: Number, longitude: Number })\r\n */\r\n coordinateForPoint(point) {\r\n if (Platform.OS === 'android') {\r\n return NativeModules.Map4dMap.coordinateForPoint(\r\n this._getHandle(),\r\n point\r\n );\r\n } else if (Platform.OS === 'ios') {\r\n return this._runCommand('coordinateForPoint', [point]);\r\n }\r\n return Promise.reject('coordinateForPoint not supported on this platform');\r\n }\r\n\r\n focusArea(focusOptions) {\r\n if (!this.areaFocusManager) {\r\n return Promise.resolve(null)\r\n }\r\n\r\n return this.areaFocusManager.focus(focusOptions)\r\n }\r\n\r\n clearFocusedArea() {\r\n if (!this.areaFocusManager) {\r\n return\r\n }\r\n this.areaFocusManager.clear()\r\n }\r\n\r\n _getHandle() {\r\n return findNodeHandle(this.map);\r\n }\r\n\r\n _runCommand(name, args) {\r\n switch (Platform.OS) {\r\n case 'android':\r\n return NativeModules.UIManager.dispatchViewManagerCommand(\r\n this._getHandle(),\r\n this._uiManagerCommand(name),\r\n args\r\n );\r\n\r\n case 'ios':\r\n return this._mapManagerCommand(name)(this._getHandle(), ...args);\r\n\r\n default:\r\n return Promise.reject(`Invalid platform was passed: ${Platform.OS}`);\r\n }\r\n }\r\n\r\n _uiManagerCommand(name) {\r\n const UIManager = NativeModules.UIManager;\r\n const componentName = \"RMFMapView\";\r\n\r\n if (!UIManager.getViewManagerConfig) {\r\n // RN < 0.58\r\n return UIManager[componentName].Commands[name];\r\n }\r\n\r\n // RN >= 0.58 \r\n return UIManager.getViewManagerConfig(componentName).Commands[name];\r\n }\r\n\r\n _mapManagerCommand(name) {\r\n return NativeModules[`RMFMapView`][name];\r\n }\r\n\r\n render() {\r\n let props;\r\n const { children, ...restProps } = this.props;\r\n const managedPolygons = Object.values(this.state.managedPolygons);\r\n\r\n if (this.state.isReady) {\r\n props = {\r\n style: this.props.style,\r\n onMapReady: this._onMapReady,\r\n ...restProps,\r\n children: (\r\n <React.Fragment>\r\n {children}\r\n {managedPolygons.map((polygon) => (\r\n <MFPolygon\r\n key={polygon.id}\r\n coordinates={polygon.coordinates}\r\n holes={polygon.holes}\r\n fillColor={polygon.fillColor}\r\n strokeColor={polygon.strokeColor}\r\n strokeWidth={polygon.strokeWidth}\r\n zIndex={polygon.zIndex}\r\n />\r\n ))}\r\n </React.Fragment>\r\n ),\r\n };\r\n } else {\r\n props = {\r\n style: this.props.style,\r\n onMapReady: this._onMapReady\r\n };\r\n }\r\n\r\n return <RMFMapView\r\n {...props}\r\n ref={this._ref}\r\n />;\r\n }\r\n}\r\n\r\nMFMapView.propTypes = propTypes;\r\nvar RMFMapView = requireNativeComponent(`RMFMapView`, MFMapView);\r\n\r\n\r\nexport { MFMapView }"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;AAOA,MAAMA,WAAW,GAAGC,kBAAA,CAAUC,KAAV,CAAgB;EAClCC,MAAM,EAAEF,kBAAA,CAAUC,KAAV,CAAgB;IACtBE,QAAQ,EAAEH,kBAAA,CAAUI,MAAV,CAAiBC,UADL;IAEtBC,SAAS,EAAEN,kBAAA,CAAUI,MAAV,CAAiBC;EAFN,CAAhB,CAD0B;EAKlCE,IAAI,EAAEP,kBAAA,CAAUI,MAAV,CAAiBC,UALW;EAMlCG,OAAO,EAAER,kBAAA,CAAUI,MAAV,CAAiBC,UANQ;EAOlCI,IAAI,EAAET,kBAAA,CAAUI,MAAV,CAAiBC;AAPW,CAAhB,CAApB,C,CAUA;;;AACA,MAAMK,aAAa,GAAGC,6CAAA,IAAiBC,IAAI,CAACC,SAA5C;AAEA,MAAMA,SAAS,GAAG,EAChB,GAAGH,aADa;;EAGhB;AACF;AACA;EACEI,KAAK,EAAEd,kBAAA,CAAUe,MAND;;EAQhB;AACF;AACA;EACEC,QAAQ,EAAEhB,kBAAA,CAAUe,MAXJ;;EAahB;AACF;AACA;AACA;EACEE,qBAAqB,EAAEjB,kBAAA,CAAUkB,IAjBjB;;EAmBhB;AACF;AACA;AACA;EACEC,eAAe,EAAEnB,kBAAA,CAAUkB,IAvBX;;EAyBhB;AACF;AACA;AACA;EACEE,cAAc,EAAEpB,kBAAA,CAAUkB,IA7BV;;EA+BhB;AACF;AACA;AACA;EACEG,SAAS,EAAErB,kBAAA,CAAUkB,IAnCL;;EAqChB;AACF;AACA;AACA;EACEI,mBAAmB,EAAEtB,kBAAA,CAAUkB,IAzCf;;EA2ChB;AACF;AACA;AACA;EACEK,qBAAqB,EAAEvB,kBAAA,CAAUkB,IA/CjB;;EAiDhB;AACF;AACA;AACA;EAC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CAAR;IAID;;IAED,oBAAO,6BAAC,UAAD,eACDV,KADC;MAEL,GAAG,EAAE,KAAKY;IAFL,GAAP;EAID;;AAlTqC;;;AAqTxChB,SAAS,CAAC3B,SAAV,GAAsBA,SAAtB;AACA,IAAIsH,UAAU,GAAG,IAAAC,mCAAA,EAAwB,YAAxB,EAAqC5F,SAArC,CAAjB"}
1
+ {"version":3,"names":["CameraShape","PropTypes","shape","target","latitude","number","isRequired","longitude","zoom","bearing","tilt","viewPropTypes","ViewPropTypes","View","propTypes","mapID","string","mapStyle","showsMyLocationButton","bool","showsMyLocation","showsBuildings","showsPOIs","zoomGesturesEnabled","scrollGesturesEnabled","rotateGesturesEnabled","tiltGesturesEnabled","camera","mapType","oneOf","onMapReady","func","onPress","onPoiPress","onBuildingPress","onPlacePress","onDataSourceFeaturePress","onCameraMove","onCameraMoveStart","onCameraIdle","onMyLocationButtonPress","MFMapView","React","Component","constructor","props","areaFocusManager","AreaFocusManager","areaFocuser","AreaFocuser","state","isReady","Platform","OS","managedPolygons","_onMapReady","bind","_ref","_addPolygon","polygon","id","trim","length","_polygon","setState","prevState","_removePolygon","_clearManagedPolygons","ref","map","getCamera","NativeModules","Map4dMap","_getHandle","_runCommand","Promise","reject","getBounds","getMyLocation","animateCamera","moveCamera","setMyLocationEnabled","enable","setPOIsEnabled","setZoomGesturesEnabled","setScrollGesturesEnabled","setRotateGesturesEnabled","setTiltGesturesEnabled","setAllGesturesEnabled","setTime","time","t","Date","parse","isNaN","console","log","fitBounds","boundsData","cameraForBounds","pointForCoordinate","coordinate","coordinateForPoint","point","focusArea","focusOptions","resolve","focus","clearFocusedArea","clear","findNodeHandle","name","args","UIManager","dispatchViewManagerCommand","_uiManagerCommand","_mapManagerCommand","componentName","getViewManagerConfig","Commands","render","children","restProps","Object","values","style","coordinates","holes","fillColor","strokeColor","strokeWidth","zIndex","RMFMapView","requireNativeComponent"],"sources":["MFMapView.js"],"sourcesContent":["import PropTypes from 'prop-types';\nimport React from 'react';\nimport {ViewPropTypes, ColorPropType} from 'deprecated-react-native-prop-types';\nimport {AreaFocusManager} from './extends/AreaFocusManager';\nimport {AreaFocuser} from './extends/AreaFocuser';\nimport {MFPolygon} from './MFPolygon';\nimport {\n requireNativeComponent,\n Platform,\n NativeModules,\n findNodeHandle\n} from 'react-native';\n\nconst CameraShape = PropTypes.shape({\n target: PropTypes.shape({\n latitude: PropTypes.number.isRequired,\n longitude: PropTypes.number.isRequired,\n }),\n zoom: PropTypes.number.isRequired,\n bearing: PropTypes.number.isRequired,\n tilt: PropTypes.number.isRequired,\n});\n\n// if ViewPropTypes is not defined fall back to View.propType (to support RN < 0.44)\nconst viewPropTypes = ViewPropTypes || View.propTypes;\n\nconst propTypes = {\n ...viewPropTypes,\n\n /**\n * An opaque identifier for a custom map configuration.\n */\n mapID: PropTypes.string,\n\n /**\n * Map style by string for a custom map configuration.\n */\n mapStyle: PropTypes.string,\n\n /**\n * If `false` hide the button to move map to the current user's location.\n * Default value is `false`.\n */\n showsMyLocationButton: PropTypes.bool,\n\n /**\n * If `true` the app will ask for the user's location.\n * Default value is `false`.\n */\n showsMyLocation: PropTypes.bool,\n\n /**\n * A Boolean indicating whether the map displays buildings.\n * Default value is `true`.\n */\n showsBuildings: PropTypes.bool,\n\n /**\n * A Boolean indicating whether the map displays POIs.\n * Default value is `true`.\n */\n showsPOIs: PropTypes.bool,\n\n /**\n * If `false` the user won't be able to zoom the map.\n * Default value is `true`.\n */\n zoomGesturesEnabled: PropTypes.bool,\n\n /**\n * If `false` the user won't be able to scroll the map.\n * Default value is `true`.\n */\n scrollGesturesEnabled: PropTypes.bool,\n\n /**\n * If `false` the user won't be able to pinch/rotate the map.\n * Default value is `true`.\n */\n rotateGesturesEnabled: PropTypes.bool,\n\n /**\n * If `false` the user won't be able to tilt the map.\n * Default value is `true`.\n */\n tiltGesturesEnabled: PropTypes.bool,\n\n /**\n * The camera view position.\n */\n camera: CameraShape,\n\n /**\n * Type of map tiles to be rendered.\n */\n mapType: PropTypes.oneOf(['roadmap', 'satellite', 'hybrid']),\n\n /**\n * Callback that is called once the map is fully loaded.\n * @platform android\n */\n onMapReady: PropTypes.func,\n\n /**\n * Callback that is called when user taps on the map.\n */\n onPress: PropTypes.func,\n\n /**\n * Callback that is called when user taps on the POIs\n */\n onPoiPress: PropTypes.func,\n\n /**\n * Callback that is called when user taps on the Buildings\n */\n onBuildingPress: PropTypes.func,\n\n /**\n * Callback that is called when user taps on the Places\n */\n onPlacePress: PropTypes.func,\n\n /**\n * Callback that is called when user taps on the Data Source Features\n */\n onDataSourceFeaturePress: PropTypes.func,\n\n /**\n * Callback that is called when moving camera\n */\n onCameraMove: PropTypes.func,\n\n /**\n * Callback that is called when camera start moving\n */\n onCameraMoveStart: PropTypes.func,\n\n /**\n * Callback that is called when camera idle\n */\n onCameraIdle: PropTypes.func,\n\n /**\n * Callback that is called when user taps on location Button\n */\n onMyLocationButtonPress: PropTypes.func,\n\n};\n\n\nclass MFMapView extends React.Component {\n constructor(props) {\n super(props);\n this.areaFocusManager = new AreaFocusManager(this);\n this.areaFocuser = new AreaFocuser(this.areaFocusManager);\n this.state = {\n isReady: Platform.OS === 'ios',\n managedPolygons: {},\n };\n\n this._onMapReady = this._onMapReady.bind(this);\n this._ref = this._ref.bind(this);\n }\n\n _addPolygon(polygon) {\n if (polygon == null || typeof polygon !== 'object') {\n return null;\n }\n\n const id =\n typeof polygon.id === 'string' && polygon.id.trim().length > 0\n ? polygon.id\n : 'polygon-highlight-id-default';\n\n const _polygon = {\n ...polygon,\n id,\n };\n\n this.setState((prevState) => ({\n managedPolygons: {\n ...prevState.managedPolygons,\n [id]: _polygon,\n },\n }));\n\n return id;\n }\n\n _removePolygon(id) {\n if (typeof id !== 'string' || id.trim().length === 0) {\n return;\n }\n\n this.setState((prevState) => {\n if (!prevState.managedPolygons[id]) {\n return null;\n }\n\n const managedPolygons = {\n ...prevState.managedPolygons,\n };\n delete managedPolygons[id];\n\n return {\n managedPolygons,\n };\n });\n }\n\n _clearManagedPolygons() {\n this.setState({\n managedPolygons: {},\n });\n }\n\n _onMapReady() {\n const { onMapReady } = this.props;\n this.setState({ isReady: true }, () => {\n if (onMapReady) {\n onMapReady();\n }\n });\n }\n\n _ref(ref) {\n this.map = ref;\n }\n\n getCamera() {\n if (Platform.OS === 'android') {\n return NativeModules.Map4dMap.getCamera(this._getHandle());\n } else if (Platform.OS === 'ios') {\n return this._runCommand('getCamera', []);\n }\n return Promise.reject('Function not supported on this platform');\n }\n\n getBounds() {\n if (Platform.OS === 'android') {\n return NativeModules.Map4dMap.getBounds(this._getHandle());\n } else if (Platform.OS === 'ios') {\n return this._runCommand('getBounds', []);\n }\n return Promise.reject('Function not supported on this platform');\n }\n\n getMyLocation() {\n if (Platform.OS === 'android') {\n return NativeModules.Map4dMap.getMyLocation(this._getHandle());\n } else if (Platform.OS === 'ios') {\n return this._runCommand('getMyLocation', []);\n }\n return Promise.reject('Function not supported on this platform');\n }\n\n animateCamera(camera) {\n this._runCommand('animateCamera', [camera]);\n }\n\n moveCamera(camera) {\n this._runCommand('moveCamera', [camera]);\n }\n\n setMyLocationEnabled(enable) {\n this._runCommand('setMyLocationEnabled', [enable]);\n }\n\n showsMyLocationButton(enable) {\n this._runCommand('showsMyLocationButton', [enable]);\n }\n\n setPOIsEnabled(enable) {\n this._runCommand('setPOIsEnabled', [enable]);\n }\n\n setZoomGesturesEnabled(enable) {\n this._runCommand('setZoomGesturesEnabled', [enable]);\n }\n\n setScrollGesturesEnabled(enable) {\n this._runCommand('setScrollGesturesEnabled', [enable]);\n }\n\n setRotateGesturesEnabled(enable) {\n this._runCommand('setRotateGesturesEnabled', [enable]);\n }\n\n setTiltGesturesEnabled(enable) {\n this._runCommand('setTiltGesturesEnabled', [enable]);\n }\n\n setAllGesturesEnabled(enable) {\n this._runCommand('setAllGesturesEnabled', [enable]);\n }\n\n setTime(time) {\n let t = Date.parse(time)\n if (isNaN(t)) {\n console.log('time invalid')\n }\n else {\n this._runCommand('setTime', [t]);\n }\n }\n\n fitBounds(boundsData) {\n this._runCommand(\"fitBounds\", [boundsData])\n }\n\n cameraForBounds(boundsData) {\n if (Platform.OS === 'android') {\n return NativeModules.Map4dMap.cameraForBounds(\n this._getHandle(),\n boundsData\n );\n } else if (Platform.OS === 'ios') {\n return this._runCommand('cameraForBounds', [boundsData]);\n }\n return Promise.reject('cameraForBounds not supported on this platform');\n }\n\n\n /**\n * Convert a map coordinate to screen point\n *\n * @param coordinate Coordinate\n * @param [coordinate.latitude] Latitude\n * @param [coordinate.longitude] Longitude\n *\n * @return Promise Promise with the point ({ x: Number, y: Number })\n */\n pointForCoordinate(coordinate) {\n if (Platform.OS === 'android') {\n return NativeModules.Map4dMap.pointForCoordinate(\n this._getHandle(),\n coordinate\n );\n } else if (Platform.OS === 'ios') {\n return this._runCommand('pointForCoordinate', [coordinate]);\n }\n return Promise.reject('pointForCoordinate not supported on this platform');\n }\n\n /**\n * Convert a screen point to a map coordinate\n *\n * @param point Point\n * @param [point.x] X\n * @param [point.x] Y\n *\n * @return Promise Promise with the coordinate ({ latitude: Number, longitude: Number })\n */\n coordinateForPoint(point) {\n if (Platform.OS === 'android') {\n return NativeModules.Map4dMap.coordinateForPoint(\n this._getHandle(),\n point\n );\n } else if (Platform.OS === 'ios') {\n return this._runCommand('coordinateForPoint', [point]);\n }\n return Promise.reject('coordinateForPoint not supported on this platform');\n }\n\n focusArea(focusOptions) {\n if (!this.areaFocusManager) {\n return Promise.resolve(null)\n }\n\n return this.areaFocusManager.focus(focusOptions)\n }\n\n clearFocusedArea() {\n if (!this.areaFocusManager) {\n return\n }\n this.areaFocusManager.clear()\n }\n\n _getHandle() {\n return findNodeHandle(this.map);\n }\n\n _runCommand(name, args) {\n switch (Platform.OS) {\n case 'android':\n return NativeModules.UIManager.dispatchViewManagerCommand(\n this._getHandle(),\n this._uiManagerCommand(name),\n args\n );\n\n case 'ios':\n return this._mapManagerCommand(name)(this._getHandle(), ...args);\n\n default:\n return Promise.reject(`Invalid platform was passed: ${Platform.OS}`);\n }\n }\n\n _uiManagerCommand(name) {\n const UIManager = NativeModules.UIManager;\n const componentName = \"RMFMapView\";\n\n if (!UIManager.getViewManagerConfig) {\n // RN < 0.58\n return UIManager[componentName].Commands[name];\n }\n\n // RN >= 0.58 \n return UIManager.getViewManagerConfig(componentName).Commands[name];\n }\n\n _mapManagerCommand(name) {\n return NativeModules[`RMFMapView`][name];\n }\n\n render() {\n let props;\n const { children, ...restProps } = this.props;\n const managedPolygons = Object.values(this.state.managedPolygons);\n\n if (this.state.isReady) {\n props = {\n style: this.props.style,\n onMapReady: this._onMapReady,\n ...restProps,\n children: (\n <React.Fragment>\n {children}\n {managedPolygons.map((polygon) => (\n <MFPolygon\n key={polygon.id}\n coordinates={polygon.coordinates}\n holes={polygon.holes}\n fillColor={polygon.fillColor}\n strokeColor={polygon.strokeColor}\n strokeWidth={polygon.strokeWidth}\n zIndex={polygon.zIndex}\n />\n ))}\n </React.Fragment>\n ),\n };\n } else {\n props = {\n style: this.props.style,\n onMapReady: this._onMapReady\n };\n }\n\n return <RMFMapView\n {...props}\n ref={this._ref}\n />;\n }\n}\n\nMFMapView.propTypes = propTypes;\nvar RMFMapView = requireNativeComponent(`RMFMapView`, MFMapView);\n\n\nexport { MFMapView }"],"mappings":";;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;AAOA,MAAMA,WAAW,GAAGC,kBAAA,CAAUC,KAAV,CAAgB;EAClCC,MAAM,EAAEF,kBAAA,CAAUC,KAAV,CAAgB;IACtBE,QAAQ,EAAEH,kBAAA,CAAUI,MAAV,CAAiBC,UADL;IAEtBC,SAAS,EAAEN,kBAAA,CAAUI,MAAV,CAAiBC;EAFN,CAAhB,CAD0B;EAKlCE,IAAI,EAAEP,kBAAA,CAAUI,MAAV,CAAiBC,UALW;EAMlCG,OAAO,EAAER,kBAAA,CAAUI,MAAV,CAAiBC,UANQ;EAOlCI,IAAI,EAAET,kBAAA,CAAUI,MAAV,CAAiBC;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