@maplibre/maplibre-react-native 11.0.0-beta.24 → 11.0.0-beta.26

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 (218) hide show
  1. package/android/src/main/java/org/maplibre/reactnative/components/mapview/MLRNMapView.kt +10 -8
  2. package/ios/modules/offline/MLRNOfflineModule.h +1 -2
  3. package/ios/modules/offline/MLRNOfflineModule.mm +9 -9
  4. package/lib/commonjs/components/annotations/callout/Callout.js +2 -1
  5. package/lib/commonjs/components/annotations/callout/Callout.js.map +1 -1
  6. package/lib/commonjs/components/annotations/marker/Marker.js +4 -2
  7. package/lib/commonjs/components/annotations/marker/Marker.js.map +1 -1
  8. package/lib/commonjs/components/annotations/view-annotation/ViewAnnotation.js +6 -5
  9. package/lib/commonjs/components/annotations/view-annotation/ViewAnnotation.js.map +1 -1
  10. package/lib/commonjs/components/camera/Camera.js.map +1 -1
  11. package/lib/commonjs/components/images/Images.js +2 -2
  12. package/lib/commonjs/components/layer/Layer.js +0 -1
  13. package/lib/commonjs/components/layer/Layer.js.map +1 -1
  14. package/lib/commonjs/components/map/Map.js.map +1 -1
  15. package/lib/commonjs/components/sources/geojson-source/GeoJSONSource.js +2 -2
  16. package/lib/commonjs/components/sources/geojson-source/GeoJSONSource.js.map +1 -1
  17. package/lib/commonjs/components/sources/image-source/ImageSource.js +3 -2
  18. package/lib/commonjs/components/sources/image-source/ImageSource.js.map +1 -1
  19. package/lib/commonjs/components/sources/raster-source/RasterSource.js +4 -3
  20. package/lib/commonjs/components/sources/raster-source/RasterSource.js.map +1 -1
  21. package/lib/commonjs/components/sources/vector-source/VectorSource.js +4 -2
  22. package/lib/commonjs/components/sources/vector-source/VectorSource.js.map +1 -1
  23. package/lib/commonjs/components/user-location/NativeUserLocation.js.map +1 -1
  24. package/lib/commonjs/components/user-location/UserLocation.js.map +1 -1
  25. package/lib/commonjs/modules/log/LogManager.js +5 -4
  26. package/lib/commonjs/modules/log/LogManager.js.map +1 -1
  27. package/lib/commonjs/modules/network/NetworkManager.js +7 -7
  28. package/lib/commonjs/modules/network/NetworkManager.js.map +1 -1
  29. package/lib/commonjs/modules/offline/OfflineManager.js +63 -47
  30. package/lib/commonjs/modules/offline/OfflineManager.js.map +1 -1
  31. package/lib/commonjs/modules/transform-request/TransformRequestManager.js +50 -45
  32. package/lib/commonjs/modules/transform-request/TransformRequestManager.js.map +1 -1
  33. package/lib/commonjs/plugin/ios.js +9 -8
  34. package/lib/commonjs/plugin/ios.js.map +1 -1
  35. package/lib/commonjs/types/Anchor.js +5 -6
  36. package/lib/commonjs/types/Anchor.js.map +1 -1
  37. package/lib/commonjs/utils/animated/AbstractAnimatedCoordinates.js +2 -2
  38. package/lib/commonjs/utils/animated/AnimatedCoordinatesArray.js +6 -6
  39. package/lib/commonjs/utils/animated/AnimatedGeoJSON.js +2 -1
  40. package/lib/commonjs/utils/animated/AnimatedGeoJSON.js.map +1 -1
  41. package/lib/commonjs/utils/animated/AnimatedRouteCoordinatesArray.js +6 -6
  42. package/lib/commonjs/utils/convertStyleSpec.js +4 -4
  43. package/lib/module/components/annotations/callout/Callout.js +2 -1
  44. package/lib/module/components/annotations/callout/Callout.js.map +1 -1
  45. package/lib/module/components/annotations/marker/Marker.js +4 -2
  46. package/lib/module/components/annotations/marker/Marker.js.map +1 -1
  47. package/lib/module/components/annotations/view-annotation/ViewAnnotation.js +6 -5
  48. package/lib/module/components/annotations/view-annotation/ViewAnnotation.js.map +1 -1
  49. package/lib/module/components/camera/Camera.js.map +1 -1
  50. package/lib/module/components/images/Images.js +2 -2
  51. package/lib/module/components/layer/Layer.js +0 -1
  52. package/lib/module/components/layer/Layer.js.map +1 -1
  53. package/lib/module/components/map/Map.js.map +1 -1
  54. package/lib/module/components/sources/geojson-source/GeoJSONSource.js +2 -2
  55. package/lib/module/components/sources/geojson-source/GeoJSONSource.js.map +1 -1
  56. package/lib/module/components/sources/image-source/ImageSource.js +3 -2
  57. package/lib/module/components/sources/image-source/ImageSource.js.map +1 -1
  58. package/lib/module/components/sources/raster-source/RasterSource.js +4 -3
  59. package/lib/module/components/sources/raster-source/RasterSource.js.map +1 -1
  60. package/lib/module/components/sources/vector-source/VectorSource.js +4 -2
  61. package/lib/module/components/sources/vector-source/VectorSource.js.map +1 -1
  62. package/lib/module/components/user-location/NativeUserLocation.js.map +1 -1
  63. package/lib/module/components/user-location/UserLocation.js.map +1 -1
  64. package/lib/module/modules/log/LogManager.js +5 -4
  65. package/lib/module/modules/log/LogManager.js.map +1 -1
  66. package/lib/module/modules/network/NetworkManager.js +7 -7
  67. package/lib/module/modules/network/NetworkManager.js.map +1 -1
  68. package/lib/module/modules/offline/OfflineManager.js +63 -47
  69. package/lib/module/modules/offline/OfflineManager.js.map +1 -1
  70. package/lib/module/modules/transform-request/TransformRequestManager.js +50 -45
  71. package/lib/module/modules/transform-request/TransformRequestManager.js.map +1 -1
  72. package/lib/module/plugin/ios.js +9 -8
  73. package/lib/module/plugin/ios.js.map +1 -1
  74. package/lib/module/types/Anchor.js +5 -6
  75. package/lib/module/types/Anchor.js.map +1 -1
  76. package/lib/module/utils/animated/AbstractAnimatedCoordinates.js +2 -2
  77. package/lib/module/utils/animated/AnimatedCoordinatesArray.js +6 -6
  78. package/lib/module/utils/animated/AnimatedGeoJSON.js +2 -1
  79. package/lib/module/utils/animated/AnimatedGeoJSON.js.map +1 -1
  80. package/lib/module/utils/animated/AnimatedRouteCoordinatesArray.js +6 -6
  81. package/lib/module/utils/convertStyleSpec.js +4 -4
  82. package/lib/typescript/commonjs/components/annotations/callout/Callout.d.ts +3 -2
  83. package/lib/typescript/commonjs/components/annotations/callout/Callout.d.ts.map +1 -1
  84. package/lib/typescript/commonjs/components/annotations/marker/Marker.d.ts +15 -14
  85. package/lib/typescript/commonjs/components/annotations/marker/Marker.d.ts.map +1 -1
  86. package/lib/typescript/commonjs/components/annotations/view-annotation/ViewAnnotation.d.ts +26 -24
  87. package/lib/typescript/commonjs/components/annotations/view-annotation/ViewAnnotation.d.ts.map +1 -1
  88. package/lib/typescript/commonjs/components/camera/Camera.d.ts +10 -24
  89. package/lib/typescript/commonjs/components/camera/Camera.d.ts.map +1 -1
  90. package/lib/typescript/commonjs/components/images/Images.d.ts +12 -12
  91. package/lib/typescript/commonjs/components/layer/Layer.d.ts +0 -1
  92. package/lib/typescript/commonjs/components/layer/Layer.d.ts.map +1 -1
  93. package/lib/typescript/commonjs/components/map/Map.d.ts +54 -51
  94. package/lib/typescript/commonjs/components/map/Map.d.ts.map +1 -1
  95. package/lib/typescript/commonjs/components/sources/geojson-source/GeoJSONSource.d.ts +40 -41
  96. package/lib/typescript/commonjs/components/sources/geojson-source/GeoJSONSource.d.ts.map +1 -1
  97. package/lib/typescript/commonjs/components/sources/image-source/ImageSource.d.ts +5 -3
  98. package/lib/typescript/commonjs/components/sources/image-source/ImageSource.d.ts.map +1 -1
  99. package/lib/typescript/commonjs/components/sources/raster-source/RasterSource.d.ts +20 -15
  100. package/lib/typescript/commonjs/components/sources/raster-source/RasterSource.d.ts.map +1 -1
  101. package/lib/typescript/commonjs/components/sources/vector-source/VectorSource.d.ts +23 -20
  102. package/lib/typescript/commonjs/components/sources/vector-source/VectorSource.d.ts.map +1 -1
  103. package/lib/typescript/commonjs/components/user-location/NativeUserLocation.d.ts +9 -6
  104. package/lib/typescript/commonjs/components/user-location/NativeUserLocation.d.ts.map +1 -1
  105. package/lib/typescript/commonjs/components/user-location/UserLocation.d.ts +4 -2
  106. package/lib/typescript/commonjs/components/user-location/UserLocation.d.ts.map +1 -1
  107. package/lib/typescript/commonjs/hooks/useCurrentPosition.d.ts +2 -2
  108. package/lib/typescript/commonjs/modules/log/LogManager.d.ts +5 -4
  109. package/lib/typescript/commonjs/modules/log/LogManager.d.ts.map +1 -1
  110. package/lib/typescript/commonjs/modules/network/NetworkManager.d.ts +7 -7
  111. package/lib/typescript/commonjs/modules/network/NetworkManager.d.ts.map +1 -1
  112. package/lib/typescript/commonjs/modules/offline/OfflineManager.d.ts +63 -47
  113. package/lib/typescript/commonjs/modules/offline/OfflineManager.d.ts.map +1 -1
  114. package/lib/typescript/commonjs/modules/static-map/StaticMapManager.d.ts +2 -2
  115. package/lib/typescript/commonjs/modules/transform-request/TransformRequestManager.d.ts +56 -49
  116. package/lib/typescript/commonjs/modules/transform-request/TransformRequestManager.d.ts.map +1 -1
  117. package/lib/typescript/commonjs/plugin/MapLibrePluginProps.d.ts +10 -15
  118. package/lib/typescript/commonjs/plugin/MapLibrePluginProps.d.ts.map +1 -1
  119. package/lib/typescript/commonjs/plugin/ios.d.ts +2 -2
  120. package/lib/typescript/commonjs/plugin/ios.d.ts.map +1 -1
  121. package/lib/typescript/commonjs/types/Anchor.d.ts +5 -6
  122. package/lib/typescript/commonjs/types/Anchor.d.ts.map +1 -1
  123. package/lib/typescript/commonjs/types/LngLatBounds.d.ts +2 -1
  124. package/lib/typescript/commonjs/types/LngLatBounds.d.ts.map +1 -1
  125. package/lib/typescript/commonjs/types/MapLibreRNStyles.d.ts +243 -93
  126. package/lib/typescript/commonjs/types/MapLibreRNStyles.d.ts.map +1 -1
  127. package/lib/typescript/commonjs/types/sources/PressableSourceProps.d.ts +1 -2
  128. package/lib/typescript/commonjs/types/sources/PressableSourceProps.d.ts.map +1 -1
  129. package/lib/typescript/commonjs/utils/animated/AbstractAnimatedCoordinates.d.ts +2 -2
  130. package/lib/typescript/commonjs/utils/animated/AnimatedCoordinatesArray.d.ts +6 -6
  131. package/lib/typescript/commonjs/utils/animated/AnimatedGeoJSON.d.ts +2 -1
  132. package/lib/typescript/commonjs/utils/animated/AnimatedGeoJSON.d.ts.map +1 -1
  133. package/lib/typescript/commonjs/utils/animated/AnimatedRouteCoordinatesArray.d.ts +6 -6
  134. package/lib/typescript/commonjs/utils/convertStyleSpec.d.ts +4 -4
  135. package/lib/typescript/module/components/annotations/callout/Callout.d.ts +3 -2
  136. package/lib/typescript/module/components/annotations/callout/Callout.d.ts.map +1 -1
  137. package/lib/typescript/module/components/annotations/marker/Marker.d.ts +15 -14
  138. package/lib/typescript/module/components/annotations/marker/Marker.d.ts.map +1 -1
  139. package/lib/typescript/module/components/annotations/view-annotation/ViewAnnotation.d.ts +26 -24
  140. package/lib/typescript/module/components/annotations/view-annotation/ViewAnnotation.d.ts.map +1 -1
  141. package/lib/typescript/module/components/camera/Camera.d.ts +10 -24
  142. package/lib/typescript/module/components/camera/Camera.d.ts.map +1 -1
  143. package/lib/typescript/module/components/images/Images.d.ts +12 -12
  144. package/lib/typescript/module/components/layer/Layer.d.ts +0 -1
  145. package/lib/typescript/module/components/layer/Layer.d.ts.map +1 -1
  146. package/lib/typescript/module/components/map/Map.d.ts +54 -51
  147. package/lib/typescript/module/components/map/Map.d.ts.map +1 -1
  148. package/lib/typescript/module/components/sources/geojson-source/GeoJSONSource.d.ts +40 -41
  149. package/lib/typescript/module/components/sources/geojson-source/GeoJSONSource.d.ts.map +1 -1
  150. package/lib/typescript/module/components/sources/image-source/ImageSource.d.ts +5 -3
  151. package/lib/typescript/module/components/sources/image-source/ImageSource.d.ts.map +1 -1
  152. package/lib/typescript/module/components/sources/raster-source/RasterSource.d.ts +20 -15
  153. package/lib/typescript/module/components/sources/raster-source/RasterSource.d.ts.map +1 -1
  154. package/lib/typescript/module/components/sources/vector-source/VectorSource.d.ts +23 -20
  155. package/lib/typescript/module/components/sources/vector-source/VectorSource.d.ts.map +1 -1
  156. package/lib/typescript/module/components/user-location/NativeUserLocation.d.ts +9 -6
  157. package/lib/typescript/module/components/user-location/NativeUserLocation.d.ts.map +1 -1
  158. package/lib/typescript/module/components/user-location/UserLocation.d.ts +4 -2
  159. package/lib/typescript/module/components/user-location/UserLocation.d.ts.map +1 -1
  160. package/lib/typescript/module/hooks/useCurrentPosition.d.ts +2 -2
  161. package/lib/typescript/module/modules/log/LogManager.d.ts +5 -4
  162. package/lib/typescript/module/modules/log/LogManager.d.ts.map +1 -1
  163. package/lib/typescript/module/modules/network/NetworkManager.d.ts +7 -7
  164. package/lib/typescript/module/modules/network/NetworkManager.d.ts.map +1 -1
  165. package/lib/typescript/module/modules/offline/OfflineManager.d.ts +63 -47
  166. package/lib/typescript/module/modules/offline/OfflineManager.d.ts.map +1 -1
  167. package/lib/typescript/module/modules/static-map/StaticMapManager.d.ts +2 -2
  168. package/lib/typescript/module/modules/transform-request/TransformRequestManager.d.ts +56 -49
  169. package/lib/typescript/module/modules/transform-request/TransformRequestManager.d.ts.map +1 -1
  170. package/lib/typescript/module/plugin/MapLibrePluginProps.d.ts +10 -15
  171. package/lib/typescript/module/plugin/MapLibrePluginProps.d.ts.map +1 -1
  172. package/lib/typescript/module/plugin/ios.d.ts +2 -2
  173. package/lib/typescript/module/plugin/ios.d.ts.map +1 -1
  174. package/lib/typescript/module/types/Anchor.d.ts +5 -6
  175. package/lib/typescript/module/types/Anchor.d.ts.map +1 -1
  176. package/lib/typescript/module/types/LngLatBounds.d.ts +2 -1
  177. package/lib/typescript/module/types/LngLatBounds.d.ts.map +1 -1
  178. package/lib/typescript/module/types/MapLibreRNStyles.d.ts +243 -93
  179. package/lib/typescript/module/types/MapLibreRNStyles.d.ts.map +1 -1
  180. package/lib/typescript/module/types/sources/PressableSourceProps.d.ts +1 -2
  181. package/lib/typescript/module/types/sources/PressableSourceProps.d.ts.map +1 -1
  182. package/lib/typescript/module/utils/animated/AbstractAnimatedCoordinates.d.ts +2 -2
  183. package/lib/typescript/module/utils/animated/AnimatedCoordinatesArray.d.ts +6 -6
  184. package/lib/typescript/module/utils/animated/AnimatedGeoJSON.d.ts +2 -1
  185. package/lib/typescript/module/utils/animated/AnimatedGeoJSON.d.ts.map +1 -1
  186. package/lib/typescript/module/utils/animated/AnimatedRouteCoordinatesArray.d.ts +6 -6
  187. package/lib/typescript/module/utils/convertStyleSpec.d.ts +4 -4
  188. package/package.json +1 -2
  189. package/src/components/annotations/callout/Callout.tsx +3 -2
  190. package/src/components/annotations/marker/Marker.tsx +15 -14
  191. package/src/components/annotations/view-annotation/ViewAnnotation.tsx +26 -24
  192. package/src/components/camera/Camera.tsx +10 -24
  193. package/src/components/images/Images.tsx +12 -12
  194. package/src/components/layer/Layer.tsx +0 -1
  195. package/src/components/map/Map.tsx +54 -51
  196. package/src/components/sources/geojson-source/GeoJSONSource.tsx +40 -41
  197. package/src/components/sources/image-source/ImageSource.tsx +5 -3
  198. package/src/components/sources/raster-source/RasterSource.tsx +20 -15
  199. package/src/components/sources/vector-source/VectorSource.tsx +23 -20
  200. package/src/components/user-location/NativeUserLocation.tsx +9 -6
  201. package/src/components/user-location/UserLocation.tsx +4 -2
  202. package/src/hooks/useCurrentPosition.ts +2 -2
  203. package/src/modules/log/LogManager.ts +5 -4
  204. package/src/modules/network/NetworkManager.ts +7 -7
  205. package/src/modules/offline/OfflineManager.ts +63 -47
  206. package/src/modules/static-map/StaticMapManager.ts +2 -2
  207. package/src/modules/transform-request/TransformRequestManager.ts +56 -49
  208. package/src/plugin/MapLibrePluginProps.ts +10 -15
  209. package/src/plugin/ios.ts +9 -8
  210. package/src/types/Anchor.ts +5 -6
  211. package/src/types/LngLatBounds.ts +2 -1
  212. package/src/types/MapLibreRNStyles.ts +243 -93
  213. package/src/types/sources/PressableSourceProps.ts +1 -2
  214. package/src/utils/animated/AbstractAnimatedCoordinates.ts +2 -2
  215. package/src/utils/animated/AnimatedCoordinatesArray.ts +6 -6
  216. package/src/utils/animated/AnimatedGeoJSON.ts +2 -1
  217. package/src/utils/animated/AnimatedRouteCoordinatesArray.ts +6 -6
  218. package/src/utils/convertStyleSpec.ts +4 -4
@@ -8,9 +8,10 @@ import { OfflinePack } from "./OfflinePack.js";
8
8
  */
9
9
 
10
10
  /**
11
- * OfflineManager implements a singleton (shared object) that manages offline packs.
12
- * All of this class's instance methods are asynchronous, reflecting the fact that offline resources are stored in a database.
13
- * The shared object maintains a canonical collection of offline packs.
11
+ * OfflineManager implements a singleton (shared object) that manages offline
12
+ * packs. All of this class's instance methods are asynchronous, reflecting the
13
+ * fact that offline resources are stored in a database. The shared object
14
+ * maintains a canonical collection of offline packs.
14
15
  */
15
16
  class OfflineManager {
16
17
  constructor() {
@@ -25,10 +26,18 @@ class OfflineManager {
25
26
  }
26
27
 
27
28
  /**
28
- * Creates and registers an offline pack that downloads the resources needed to use the given region offline.
29
+ * Creates and registers an offline pack that downloads the resources needed to
30
+ * use the given region offline.
29
31
  *
30
- * @example
32
+ * @param options - Create options for offline pack that specifies zoom levels, style url, and
33
+ * the region to download.
34
+ * @param progressListener - Callback that listens for status events while downloading the offline
35
+ * resource.
36
+ * @param errorListener - Callback that listens for status events while downloading the offline
37
+ * resource.
38
+ * @returns The created offline pack with its generated ID.
31
39
  *
40
+ * @example
32
41
  * const progressListener = (offlineRegion, status) => console.log(offlineRegion, status);
33
42
  * const errorListener = (offlineRegion, error) => console.log(offlineRegion, error);
34
43
  *
@@ -39,12 +48,6 @@ class OfflineManager {
39
48
  * bounds: [west, south, east, north],
40
49
  * metadata: { customValue: 'myValue' }
41
50
  * }, progressListener, errorListener)
42
- *
43
- * @param options Create options for offline pack that specifies zoom levels, style url, and the region to download.
44
- * @param progressListener Callback that listens for status events while downloading the offline resource.
45
- * @param errorListener Callback that listens for status events while downloading the offline resource.
46
- *
47
- * @return The created offline pack with its generated ID.
48
51
  */
49
52
  async createPack(options, progressListener, errorListener) {
50
53
  await this.initialize();
@@ -63,14 +66,18 @@ class OfflineManager {
63
66
  }
64
67
 
65
68
  /**
66
- * Invalidates the specified offline pack. This method checks that the tiles in the specified offline pack match those from the server. Local tiles that do not match the latest version on the server are updated.
69
+ * Invalidates the specified offline pack. This method checks that the tiles in
70
+ * the specified offline pack match those from the server. Local tiles that do
71
+ * not match the latest version on the server are updated.
72
+ *
73
+ * This is more efficient than deleting the offline pack and downloading it
74
+ * again. If the data stored locally matches that on the server, new data will
75
+ * not be downloaded.
67
76
  *
68
- * This is more efficient than deleting the offline pack and downloading it again. If the data stored locally matches that on the server, new data will not be downloaded.
77
+ * @param id - ID of the OfflinePack.
69
78
  *
70
79
  * @example
71
80
  * await OfflineManager.invalidatePack(pack.id)
72
- *
73
- * @param id ID of the OfflinePack.
74
81
  */
75
82
  async invalidatePack(id) {
76
83
  await this.initialize();
@@ -79,12 +86,13 @@ class OfflineManager {
79
86
  }
80
87
 
81
88
  /**
82
- * Unregisters the given OfflinePack and allows resources that are no longer required by any remaining packs to be potentially freed.
89
+ * Unregisters the given OfflinePack and allows resources that are no longer
90
+ * required by any remaining packs to be potentially freed.
91
+ *
92
+ * @param id - ID of the OfflinePack.
83
93
  *
84
94
  * @example
85
95
  * await OfflineManager.deletePack(pack.id)
86
- *
87
- * @param id ID of the OfflinePack.
88
96
  */
89
97
  async deletePack(id) {
90
98
  await this.initialize();
@@ -94,10 +102,13 @@ class OfflineManager {
94
102
  }
95
103
 
96
104
  /**
97
- * Forces a revalidation of the tiles in the ambient cache and downloads a fresh version of the tiles from the tile server.
98
- * This is the recommend method for clearing the cache.
99
- * This is the most efficient method because tiles in the ambient cache are re-downloaded to remove outdated data from a device.
100
- * It does not erase resources from the ambient cache or delete the database, which can be computationally expensive operations that may carry unintended side effects.
105
+ * Forces a revalidation of the tiles in the ambient cache and downloads a fresh
106
+ * version of the tiles from the tile server. This is the recommend method for
107
+ * clearing the cache. This is the most efficient method because tiles in the
108
+ * ambient cache are re-downloaded to remove outdated data from a device. It
109
+ * does not erase resources from the ambient cache or delete the database, which
110
+ * can be computationally expensive operations that may carry unintended side
111
+ * effects.
101
112
  *
102
113
  * @example
103
114
  * await OfflineManager.invalidateAmbientCache();
@@ -108,8 +119,8 @@ class OfflineManager {
108
119
  }
109
120
 
110
121
  /**
111
- * Erases resources from the ambient cache.
112
- * This method clears the cache and decreases the amount of space that map resources take up on the device.
122
+ * Erases resources from the ambient cache. This method clears the cache and
123
+ * decreases the amount of space that map resources take up on the device.
113
124
  *
114
125
  * @example
115
126
  * await OfflineManager.clearAmbientCache();
@@ -120,13 +131,14 @@ class OfflineManager {
120
131
  }
121
132
 
122
133
  /**
123
- * Sets the maximum size of the ambient cache in bytes. Disables the ambient cache if set to 0.
124
- * This method may be computationally expensive because it will erase resources from the ambient cache if its size is decreased.
134
+ * Sets the maximum size of the ambient cache in bytes. Disables the ambient
135
+ * cache if set to 0. This method may be computationally expensive because it
136
+ * will erase resources from the ambient cache if its size is decreased.
137
+ *
138
+ * @param size - Size of ambient cache.
125
139
  *
126
140
  * @example
127
141
  * await OfflineManager.setMaximumAmbientCacheSize(5000000);
128
- *
129
- * @param size Size of ambient cache.
130
142
  */
131
143
  async setMaximumAmbientCacheSize(size) {
132
144
  await this.initialize();
@@ -134,7 +146,8 @@ class OfflineManager {
134
146
  }
135
147
 
136
148
  /**
137
- * Deletes the existing database, which includes both the ambient cache and offline packs, then reinitializes it.
149
+ * Deletes the existing database, which includes both the ambient cache and
150
+ * offline packs, then reinitializes it.
138
151
  *
139
152
  * @example
140
153
  * await OfflineManager.resetDatabase();
@@ -173,10 +186,10 @@ class OfflineManager {
173
186
  /**
174
187
  * Sideloads offline db
175
188
  *
189
+ * @param path - Path to offline tile db on file system.
190
+ *
176
191
  * @example
177
192
  * await OfflineManager.mergeOfflineRegions(path);
178
- *
179
- * @param path Path to offline tile db on file system.
180
193
  */
181
194
  async mergeOfflineRegions(path) {
182
195
  await this.initialize();
@@ -184,26 +197,27 @@ class OfflineManager {
184
197
  }
185
198
 
186
199
  /**
187
- * Sets the maximum number of tiles that may be downloaded and stored on the current device.
188
- * Consult the Terms of Service for your map tile host before changing this value.
200
+ * Sets the maximum number of tiles that may be downloaded and stored on the
201
+ * current device. Consult the Terms of Service for your map tile host before
202
+ * changing this value.
203
+ *
204
+ * @param limit - Map tile limit count.
189
205
  *
190
206
  * @example
191
207
  * OfflineManager.setTileCountLimit(1000);
192
- *
193
- * @param limit Map tile limit count.
194
208
  */
195
209
  setTileCountLimit(limit) {
196
210
  NativeOfflineModule.setTileCountLimit(limit);
197
211
  }
198
212
 
199
213
  /**
200
- * Sets the period at which download status events will be sent over the React Native bridge.
201
- * The default is 500ms.
214
+ * Sets the period at which download status events will be sent over the React
215
+ * Native bridge. The default is 500ms.
216
+ *
217
+ * @param throttleValue - Event throttle value in ms.
202
218
  *
203
219
  * @example
204
220
  * OfflineManager.setProgressEventThrottle(500);
205
- *
206
- * @param throttleValue Event throttle value in ms.
207
221
  */
208
222
  setProgressEventThrottle(throttleValue) {
209
223
  NativeOfflineModule.setProgressEventThrottle(throttleValue);
@@ -213,14 +227,16 @@ class OfflineManager {
213
227
  * Subscribe to download status/error events for the requested offline pack.
214
228
  * Note that createPack calls this internally if listeners are provided.
215
229
  *
230
+ * @param id - ID of the offline pack.
231
+ * @param progressListener - Callback that listens for status events while downloading the offline
232
+ * resource.
233
+ * @param errorListener - Callback that listens for status events while downloading the offline
234
+ * resource.
235
+ *
216
236
  * @example
217
237
  * const progressListener = (offlinePack, status) => console.log(offlinePack, status)
218
238
  * const errorListener = (offlinePack, error) => console.log(offlinePack, error)
219
239
  * OfflineManager.addListener(pack.id, progressListener, errorListener)
220
- *
221
- * @param id ID of the offline pack.
222
- * @param progressListener Callback that listens for status events while downloading the offline resource.
223
- * @param errorListener Callback that listens for status events while downloading the offline resource.
224
240
  */
225
241
  async addListener(id, progressListener, errorListener) {
226
242
  const totalProgressListeners = Object.keys(this.progressListeners).length;
@@ -239,8 +255,10 @@ class OfflineManager {
239
255
  }
240
256
 
241
257
  /**
242
- * Unsubscribes any listeners associated with the offline pack.
243
- * Should be called when the component unmounts.
258
+ * Unsubscribes any listeners associated with the offline pack. Should be called
259
+ * when the component unmounts.
260
+ *
261
+ * @param packId - ID of the offline pack.
244
262
  *
245
263
  * @example
246
264
  * useEffect(() => {
@@ -248,8 +266,6 @@ class OfflineManager {
248
266
  * OfflineManager.removeListener(pack.id);
249
267
  * }
250
268
  * }, []);
251
- *
252
- * @param packId ID of the offline pack.
253
269
  */
254
270
  removeListener(packId) {
255
271
  delete this.progressListeners[packId];
@@ -1 +1 @@
1
- {"version":3,"names":["NativeOfflineModule","OfflinePack","OfflineManager","constructor","initialized","offlinePacks","progressListeners","errorListeners","handleProgress","bind","onError","subscriptionProgress","subscriptionError","createPack","options","progressListener","errorListener","initialize","offlinePackOptions","mapStyle","bounds","minZoom","maxZoom","metadata","JSON","stringify","nativeOfflinePack","offlinePack","id","addListener","invalidatePack","getPack","deletePack","invalidateAmbientCache","clearAmbientCache","setMaximumAmbientCacheSize","size","resetDatabase","getPacks","Object","values","Error","mergeOfflineRegions","path","setTileCountLimit","limit","setProgressEventThrottle","throttleValue","totalProgressListeners","keys","length","onProgress","totalErrorListeners","setPackObserver","removeListener","packId","remove","nativeOfflinePacks","event","state","offlineManager"],"sourceRoot":"../../../../src","sources":["modules/offline/OfflineManager.ts"],"mappings":";;AAEA,OAAOA,mBAAmB,MAAM,0BAAuB;AACvD,SAASC,WAAW,QAAgC,kBAAe;;AAenE;AACA;AACA;;AAiBA;AACA;AACA;AACA;AACA;AACA,MAAMC,cAAc,CAAC;EAcnBC,WAAWA,CAAA,EAAG;IACZ,IAAI,CAACC,WAAW,GAAG,KAAK;IAExB,IAAI,CAACC,YAAY,GAAG,CAAC,CAAC;IAEtB,IAAI,CAACC,iBAAiB,GAAG,CAAC,CAAC;IAC3B,IAAI,CAACC,cAAc,GAAG,CAAC,CAAC;IAExB,IAAI,CAACC,cAAc,GAAG,IAAI,CAACA,cAAc,CAACC,IAAI,CAAC,IAAI,CAAC;IACpD,IAAI,CAACC,OAAO,GAAG,IAAI,CAACA,OAAO,CAACD,IAAI,CAAC,IAAI,CAAC;IAEtC,IAAI,CAACE,oBAAoB,GAAG,IAAI;IAChC,IAAI,CAACC,iBAAiB,GAAG,IAAI;EAC/B;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACE,MAAMC,UAAUA,CACdC,OAAiC,EACjCC,gBAA6C,EAC7CC,aAAuC,EACjB;IACtB,MAAM,IAAI,CAACC,UAAU,CAAC,CAAC;IAEvB,MAAMC,kBAAkB,GAA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C,EAAE,CAAC,GAAGD,WAAW,EAAE+B,KAAK,CAAC;IAC9D;IAEA,IAAIC,KAAK,KAAK,UAAU,EAAE;MACxB,IAAI,CAACL,cAAc,CAAC1B,EAAE,CAAC;IACzB;EACF;EAEQlB,OAAOA,CAACgD,KAAuB,EAAE;IACvC,MAAM;MAAE9B;IAAG,CAAC,GAAG8B,KAAK;IAEpB,MAAM/B,WAAW,GAAG,IAAI,CAACtB,YAAY,CAACuB,EAAE,CAAC;IACzC,IAAID,WAAW,EAAE;MACf,IAAI,CAACpB,cAAc,CAACoB,WAAW,CAACC,EAAE,CAAC,GAAGD,WAAW,EAAE+B,KAAK,CAAC;IAC3D;EACF;AACF;AAEA,MAAME,cAAc,GAAG,IAAI1D,cAAc,CAAC,CAAC;AAC3C,SAAS0D,cAAc,IAAI1D,cAAc","ignoreList":[]}
1
+ {"version":3,"names":["NativeOfflineModule","OfflinePack","OfflineManager","constructor","initialized","offlinePacks","progressListeners","errorListeners","handleProgress","bind","onError","subscriptionProgress","subscriptionError","createPack","options","progressListener","errorListener","initialize","offlinePackOptions","mapStyle","bounds","minZoom","maxZoom","metadata","JSON","stringify","nativeOfflinePack","offlinePack","id","addListener","invalidatePack","getPack","deletePack","invalidateAmbientCache","clearAmbientCache","setMaximumAmbientCacheSize","size","resetDatabase","getPacks","Object","values","Error","mergeOfflineRegions","path","setTileCountLimit","limit","setProgressEventThrottle","throttleValue","totalProgressListeners","keys","length","onProgress","totalErrorListeners","setPackObserver","removeListener","packId","remove","nativeOfflinePacks","event","state","offlineManager"],"sourceRoot":"../../../../src","sources":["modules/offline/OfflineManager.ts"],"mappings":";;AAEA,OAAOA,mBAAmB,MAAM,0BAAuB;AACvD,SAASC,WAAW,QAAgC,kBAAe;;AAenE;AACA;AACA;;AAiBA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,cAAc,CAAC;EAcnBC,WAAWA,CAAA,EAAG;IACZ,IAAI,CAACC,WAAW,GAAG,KAAK;IAExB,IAAI,CAAC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estModule from "./NativeTransformRequestModule.js";
5
5
  /**
6
6
  * A serializable transform for rewriting MapLibre request URLs.
7
7
  *
8
- * Transforms are applied as a pipeline in the order they were added: transform N+1 sees
9
- * the URL *after* transform N has possibly changed it.
8
+ * Transforms are applied as a pipeline in the order they were added: transform
9
+ * N+1 sees the URL *after* transform N has possibly changed it.
10
10
  */
11
11
 
12
12
  /**
@@ -18,18 +18,18 @@ import NativeTransformRequestModule from "./NativeTransformRequestModule.js";
18
18
  */
19
19
 
20
20
  /**
21
- * TransformRequestManager provides methods for managing HTTP requests made by MapLibre.
21
+ * TransformRequestManager provides methods for managing HTTP requests made by
22
+ * MapLibre.
22
23
  *
23
24
  * Transformations are possible in three ways:
24
25
  *
25
- * 1. Transforming the URL with search and replace
26
- * 2. Adding URL search params
27
- * 3. Adding HTTP headers
26
+ * - Transforming the URL with search and replace
27
+ * - Adding URL search params
28
+ * - Adding HTTP headers
28
29
  *
29
30
  * Transforms are applied in this order. The `match` conditions are applied to
30
31
  * possibly already transformed URLs.
31
32
  *
32
- * @remarks
33
33
  * To gain insight into which transforms are applied set the log level to
34
34
  * `"debug"` via {@link LogManager}:
35
35
  *
@@ -44,43 +44,44 @@ class TransformRequestManager {
44
44
  * Transforms execute in insertion order. Therefore `match` and `find` regexes
45
45
  * are matched against possibly already modified URL by previous transforms.
46
46
  *
47
- * Re-adding an existing `id` updates the transform
48
- * **in-place**, preserving its position in the pipeline. This makes it safe to
49
- * refresh tokens or swap domains without disrupting the order of other transforms.
47
+ * Re-adding an existing `id` updates the transform **in-place**, preserving its
48
+ * position in the pipeline. This makes it safe to refresh tokens or swap
49
+ * domains without disrupting the order of other transforms.
50
50
  *
51
51
  * URL transforms are applied before `addUrlSearchParam` and `addHeader`.
52
52
  *
53
- * @example
54
- * // Upgrade all requests to HTTPS
53
+ * @param options - The transform. Set {@link TransformOptions.id} to a stable string to enable
54
+ * in-place updates; if omitted an id is auto-generated and returned.
55
+ * @returns The id of the transform (the value of `transform.id` when provided, otherwise the auto-generated one). Pass it to {@link removeUrlTransform} to remove it later.
56
+ *
57
+ * @example Upgrade all requests to HTTPS
58
+ * ```ts
55
59
  * TransformRequestManager.addUrlTransform({
56
60
  * id: "force-https",
57
61
  * find: "^http://",
58
62
  * replace: "https://",
59
63
  * });
64
+ * ```
60
65
  *
61
- * @example
62
- * // Redirect a specific domain through a proxy
66
+ * @example Redirect a specific domain through a proxy
67
+ * ```ts
63
68
  * TransformRequestManager.addUrlTransform({
64
69
  * id: "proxy",
65
70
  * match: "tiles\\.example\\.com",
66
71
  * find: "tiles\\.example\\.com",
67
72
  * replace: "proxy.example.com",
68
73
  * });
74
+ * ```
69
75
  *
70
- * @example
71
- * // Inject an API key into the path using a capture group
76
+ * @example Inject an API key into the path using a capture group
77
+ * ```ts
72
78
  * TransformRequestManager.addUrlTransform({
73
79
  * id: "api-key",
74
80
  * match: "api\\.example\\.com",
75
81
  * find: "(https://api\\.example\\.com/)(.*)",
76
82
  * replace: "$1mySecretKey/$2",
77
83
  * });
78
- *
79
- * @param options The transform. Set {@link TransformOptions.id} to a stable string to
80
- * enable in-place updates; if omitted an id is auto-generated and returned.
81
- *
82
- * @returns The id of the transform (the value of `transform.id` when provided, otherwise
83
- * the auto-generated one). Pass it to {@link removeUrlTransform} to remove it later.
84
+ * ```
84
85
  */
85
86
  addUrlTransform(options) {
86
87
  const id = options.id ?? this.getId();
@@ -89,10 +90,10 @@ class TransformRequestManager {
89
90
  }
90
91
 
91
92
  /**
92
- * Removes the URL transform with the given `id`.
93
- * No-op if the id is not registered.
93
+ * Removes the URL transform with the given `id` . No-op if the id is not
94
+ * registered.
94
95
  *
95
- * @param id The identifier passed to/returned from {@link addUrlTransform}.
96
+ * @param id - The identifier passed to/returned from {@link addUrlTransform}.
96
97
  */
97
98
  removeUrlTransform(id) {
98
99
  NativeTransformRequestModule.removeUrlTransform(id);
@@ -106,24 +107,25 @@ class TransformRequestManager {
106
107
  }
107
108
 
108
109
  /**
109
- * Adds or updates a URL query parameter identified by `id` that will be appended to all
110
- * matching map resource requests. Re-adding an existing `id` updates the param in-place.
110
+ * Adds or updates a URL query parameter identified by `id` that will be
111
+ * appended to all matching map resource requests. Re-adding an existing `id`
112
+ * updates the param in-place.
111
113
  *
112
- * @example
113
- * // Add apiKey to for a specific domain
114
+ * @param options - The options. Set {@link TransformOptions.id} to a stable string to enable
115
+ * in-place updates; if omitted an id is auto-generated and returned.
116
+ * @returns The id of the options. Pass it to {@link removeUrlSearchParam} to remove it later.
117
+ *
118
+ * @example Add apiKey to for a specific domain
119
+ * ```ts
114
120
  * TransformRequestManager.addUrlSearchParam({
115
121
  * match: /tiles\.example\.com/,
116
122
  * name: "apiKey",
117
123
  * value: "your-api-key",
118
124
  * });
125
+ * ```
119
126
  *
120
127
  * // Add apiKey to all requests (no match = applies to all)
121
128
  * TransformRequestManager.addUrlSearchParam({ name: "apiKey", value: "your-api-key" });
122
- *
123
- * @param options The options. Set {@link TransformOptions.id} to a stable string to
124
- * enable in-place updates; if omitted an id is auto-generated and returned.
125
- *
126
- * @returns The id of the options. Pass it to {@link removeUrlSearchParam} to remove it later.
127
129
  */
128
130
  addUrlSearchParam(options) {
129
131
  const id = options.id ?? this.getId();
@@ -134,7 +136,7 @@ class TransformRequestManager {
134
136
  /**
135
137
  * Removes a previously added URL query parameter by its `id`.
136
138
  *
137
- * @param id The identifier passed to/returned from {@link addUrlSearchParam}.
139
+ * @param id - The identifier passed to/returned from {@link addUrlSearchParam}.
138
140
  */
139
141
  removeUrlSearchParam(id) {
140
142
  NativeTransformRequestModule.removeUrlSearchParam(id);
@@ -142,23 +144,26 @@ class TransformRequestManager {
142
144
 
143
145
  /**
144
146
  * Adds or updates an HTTP header identified by `id` that will be sent with all
145
- * matching map resource requests. Re-adding an existing `id` updates the header in-place.
147
+ * matching map resource requests. Re-adding an existing `id` updates the header
148
+ * in-place.
149
+ *
150
+ * @param options - The options. Set {@link TransformOptions.id} to a stable string to enable
151
+ * in-place updates; if omitted an id is auto-generated and returned.
152
+ * @returns The id of the options. Pass it to {@link removeHeader} to remove it later.
146
153
  *
147
- * @example
148
- * // Add header to all requests
154
+ * @example Add header to all requests
155
+ * ```
149
156
  * TransformRequestManager.addHeader({ name: "Authorization", value: "Bearer token123" });
157
+ * ```
150
158
  *
151
- * // Add header only to requests matching a pattern
159
+ * @example Add header only to requests matching a pattern
160
+ * ```ts
152
161
  * TransformRequestManager.addHeader({
153
162
  * name: "X-API-Key",
154
163
  * value: "key123",
155
164
  * match: /https:\/\/api\.example\.com\/tiles\//,
156
165
  * });
157
- *
158
- * @param options The options. Set {@link TransformOptions.id} to a stable string to
159
- * enable in-place updates; if omitted an id is auto-generated and returned.
160
- *
161
- * @returns The id of the options. Pass it to {@link removeHeader} to remove it later.
166
+ * ```
162
167
  */
163
168
  addHeader(options) {
164
169
  const id = options.id ?? this.getId();
@@ -176,7 +181,7 @@ class TransformRequestManager {
176
181
  /**
177
182
  * Removes a previously added HTTP header by its `id`.
178
183
  *
179
- * @param id The identifier passed to/returned from {@link addHeader}.
184
+ * @param id - The identifier passed to/returned from {@link addHeader}.
180
185
  */
181
186
  removeHeader(id) {
182
187
  NativeTransformRequestModule.removeHeader(id);
@@ -1 +1 @@
1
- {"version":3,"names":["NativeTransformRequestModule","TransformRequestManager","addUrlTransform","options","id","getId","toRegexString","match","find","replace","removeUrlTransform","clearUrlTransforms","addUrlSearchParam","name","value","removeUrlSearchParam","addHeader","clearUrlSearchParams","removeHeader","clearHeaders","clear","lastId","result","undefined","RegExp","flags","Error","source","transformRequestManager"],"sourceRoot":"../../../../src","sources":["modules/transform-request/TransformRequestManager.ts"],"mappings":";;AAAA,OAAOA,4BAA4B,MAAM,mCAAgC;;AAkBzE;AACA;AACA;AACA;AACA;AACA;;AAgBA;AACA;AACA;;AASA;AACA;AACA;;AASA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,uBAAuB,CAAC;EAC5B;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACEC,eAAeA,CAACC,OAA4B,EAAU;IACpD,MAAMC,EAAE,GAAGD,OAAO,CAACC,EAAE,IAAI,IAAI,CAACC,KAAK,CAAC,CAAC;IAErCL,4BAA4B,CAACE,eAAe,CAC1CE,EAAE,EACFH,uBAAuB,CAACK,aAAa,CAACH,OAAO,CAACI,KAAK,CAAC,EACpDN,uBAAuB,CAACK,aAAa,CAACH,OAAO,CAACK,IAAI,CAAC,IAAI,EAAE,EACzDL,OAAO,CAACM,OACV,CAAC;IAED,OAAOL,EAAE;EACX;;EAEA;AACF;AACA;AACA;AACA;AACA;EACEM,kBAAkBA,CAACN,EAAU,EAAQ;IACnCJ,4BAA4B,CAACU,kBAAkB,CAACN,EAAE,CAAC;EACrD;;EAEA;AACF;AACA;EACEO,kBAAkBA,CAAA,EAAS;IACzBX,4BAA4B,CAACW,kBAAkB,CAAC,CAAC;EACnD;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACEC,iBAAiBA,CAACT,OAA8B,EAAU;IACxD,MAAMC,EAAE,GAAGD,OAAO,CAACC,EAAE,IAAI,IAAI,CAACC,KAAK,CAAC,CAAC;IAErCL,4BAA4B,CAACY,iBAAiB,CAC5CR,EAAE,EACFH,uBAAuB,CAACK,aAAa,CAACH,OAAO,CAACI,KAAK,CAAC,EACpDJ,OAAO,CAACU,IAAI,EACZV,OAAO,CAACW,KACV,CAAC;IAED,OAAOV,EAAE;EACX;;EAEA;AACF;AACA;AACA;AACA;EACEW,oBAAoBA,CAACX,EAAU,EAAQ;IACrCJ,4BA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CAAC;MAClD;MAEAJ,MAAM,GAAGR,KAAK,CAACa,MAAM;IACvB,CAAC,MAAM;MACLL,MAAM,GAAGR,KAAK;IAChB;IAEA,OAAOQ,MAAM,IAAI,IAAI;EACvB;AACF;AAEA,MAAMM,uBAAuB,GAAG,IAAI3B,uBAAuB,CAAC,CAAC;AAE7D,SAAS2B,uBAAuB,IAAI3B,uBAAuB","ignoreList":[]}
1
+ {"version":3,"names":["NativeTransformRequestModule","TransformRequestManager","addUrlTransform","options","id","getId","toRegexString","match","find","replace","removeUrlTransform","clearUrlTransforms","addUrlSearchParam","name","value","removeUrlSearchParam","addHeader","clearUrlSearchParams","removeHeader","clearHeaders","clear","lastId","result","undefined","RegExp","flags","Error","source","transformRequestManager"],"sourceRoot":"../../../../src","sources":["modules/transform-request/TransformRequestManager.ts"],"mappings":";;AAAA,OAAOA,4BAA4B,MAAM,mCAAgC;;AAmBzE;AACA;AACA;AACA;AACA;AACA;;AAiBA;AACA;AACA;;AASA;AACA;AACA;;AASA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMC,uBAAuB,CAAC;EAC5B;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACEC,eAAeA,CAACC,OAA4B,EAAU;IACpD,MAAMC,EAAE,GAAGD,OAAO,CAACC,EAAE,IAAI,IAAI,CAACC,KAAK,CAAC,CAAC;IAErCL,4BAA4B,CAACE,eAAe,CAC1CE,EAAE,EACFH,uBAAuB,CAACK,aAAa,CAACH,OAAO,CAACI,KAAK,CAAC,EACpDN,uBAAuB,CAACK,aAAa,CAACH,OAAO,CAACK,IAAI,CAAC,IAAI,EAAE,EACzDL,OAAO,CAACM,OACV,CAAC;IAED,OAAOL,EAAE;EACX;;EAEA;AACF;AACA;AACA;AACA;AACA;EACEM,kBAAkBA,CAACN,EAAU,EAAQ;IACnCJ,4BAA4B,CAACU,kBAAkB,CAACN,EAAE,CAAC;EACrD;;EAEA;AACF;AACA;EACEO,kBAAkBA,CAAA,EAAS;IACzBX,4BAA4B,CAACW,kBAAkB,CAAC,CAAC;EACnD;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACEC,iBAAiBA,CAACT,OAA8B,EAAU;IACxD,MAAMC,EAAE,GAAGD,OAAO,CAACC,EAAE,IAAI,IAAI,CAACC,KAAK,CAAC,CAAC;IAErCL,4BAA4B,CAACY,iBAAiB,CAC5CR,EAAE,EACFH,uBAAuB,CAACK,aAAa,CAACH,OAAO,CAACI,KAAK,CAAC,EACpDJ,OAAO,CAACU,IAAI,EACZV,OAAO,CAACW,KACV,CAAC;IAED,OAAOV,EAAE;EACX;;EAEA;AACF;AACA;AACA;AACA;EACEW,oBAAoBA,CAACX,EAAU,EAAQ;IACrCJ,4BAA4B,CAACe,oBAAoB,CAACX,EAAE,CAAC;EACvD;;EAEA;AACF;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;EACEY,SAASA,CAACb,OAAsB,EAAU;IACxC,MAAMC,EAAE,GAAGD,OAAO,CAACC,EAAE,IAAI,IAAI,CAACC,KAAK,CAAC,CAAC;IAErCL,4BAA4B,CAACgB,SAAS,CACpCZ,EAAE,EACFH,uBAAuB,CAACK,aAAa,CAACH,OAAO,CAACI,KAAK,CAAC,EACpDJ,OAAO,CAACU,IAAI,EACZV,OAAO,CAACW,KACV,CAAC;IAED,OAAOV,EAAE;EACX;;EAEA;AACF;AACA;EACEa,oBAAoBA,CAAA,EAAS;IAC3BjB,4BAA4B,CAACiB,oBAAoB,CAAC,CAAC;EACrD;;EAEA;AACF;AACA;AACA;AACA;EACEC,YAAYA,CAACd,EAAU,EAAQ;IAC7BJ,4BAA4B,CAACkB,YAAY,CAACd,EAAE,CAAC;EAC/C;;EAEA;AACF;AACA;EACEe,YAAYA,CAAA,EAAS;IACnBnB,4BAA4B,CAACmB,YAAY,CAAC,CAAC;EAC7C;;EAEA;AACF;AACA;EACEC,KAAKA,CAAA,EAAS;IACZ,IAAI,CAACT,kBAAkB,CAAC,CAAC;IACzB,IAAI,CAACM,oBAAoB,CAAC,CAAC;IAC3B,IAAI,CAACE,YAAY,CAAC,CAAC;EACrB;EAEQE,MAAM,GAAW,CAAC,CAAC;EAEnBhB,KAAKA,CAAA,EAAG;IACd,IAAI,CAACgB,MAAM,EAAE;IAEb,OAAO,oBAAoB,GAAG,IAAI,CAACA,MAAM;EAC3C;EAEA,OAAef,aAAaA,CAC1BQ,KAAkC,EACnB;IACf,IAAIQ,MAA0B,GAAGC,SAAS;IAC1C,IAAIT,KAAK,YAAYU,MAAM,EAAE;MAC3B,IAAIV,KAAK,CAACW,KAAK,EAAE;QACf,MAAM,IAAIC,KAAK,CAAC,+BAA+B,CAAC;MAClD;MAEAJ,MAAM,GAAGR,KAAK,CAACa,MAAM;IACvB,CAAC,MAAM;MACLL,MAAM,GAAGR,KAAK;IAChB;IAEA,OAAOQ,MAAM,IAAI,IAAI;EACvB;AACF;AAEA,MAAMM,uBAAuB,GAAG,IAAI3B,uBAAuB,CAAC,CAAC;AAE7D,SAAS2B,uBAAuB,IAAI3B,uBAAuB","ignoreList":[]}
@@ -5,8 +5,8 @@ import { mergeContents, removeGeneratedContents } from "@expo/config-plugins/bui
5
5
  const TAG_PREFIX = `@maplibre/maplibre-react-native`;
6
6
 
7
7
  /**
8
- * Only the post-install block is required, the post installer block is used for SPM (Swift Package Manager) which Expo
9
- * doesn't currently support.
8
+ * Only the post-install block is required, the post installer block is used for
9
+ * SPM (Swift Package Manager) which Expo doesn't currently support.
10
10
  */
11
11
  export function applyPodfilePostInstall(contents) {
12
12
  const result = mergeContents({
@@ -82,15 +82,16 @@ const withoutSignatures = config => {
82
82
  };
83
83
 
84
84
  /**
85
- * Set the Debug Information Format to DWARF with dSYM File during EAS Build for Managed App
86
- * https://github.com/expo/eas-cli/issues/968
85
+ * Set the Debug Information Format to DWARF with dSYM File during EAS Build for
86
+ * Managed App https://github.com/expo/eas-cli/issues/968
87
87
  *
88
- * Set `artifactPath` in `eas.json`:
89
- * ```json
90
- * "ios": {
88
+ * Set `artifactPath` in `eas.json`:
89
+ *
90
+ * ```json
91
+ * "ios": {
91
92
  * "artifactPath": "ios/build/*"
92
93
  * }
93
- * ```
94
+ * ```
94
95
  */
95
96
  const withDwarfDsym = config => {
96
97
  return withXcodeProject(config, c => {
@@ -1 +1 @@
1
- {"version":3,"names":["withPodfile","withXcodeProject","mergeContents","removeGeneratedContents","TAG_PREFIX","applyPodfilePostInstall","contents","result","tag","src","newSrc","anchor","offset","comment","didMerge","didClear","withPodfilePostInstall","config","c","modResults","applyPodfileGlobalVariables","props","globalVariables","ios","nativeVersion","push","spmSpec","length","join","modified","withPodfileGlobalVariables","withoutSignatures","project","targetName","modRequest","projectName","phaseName","nativeTargetId","findTargetKey","console","warn","buildPhases","pbxNativeTargetSection","alreadyExists","some","phase","addBuildPhase","shellPath","shellScript","withDwarfDsym","debugInformationFormat"],"sourceRoot":"../../../src","sources":["plugin/ios.ts"],"mappings":";;AAAA,SAEEA,WAAW,EACXC,gBAAgB,QACX,sBAAsB;AAC7B,SACEC,aAAa,EACbC,uBAAuB,QAClB,+CAA+C;AAItD,MAAMC,UAAU,GAAG,iCAAiC;;AAEpD;AACA;AACA;AACA;AACA,OAAO,SAASC,uBAAuBA,CAACC,QAAgB,EAAU;EAChE,MAAMC,MAAM,GAAGL,aAAa,CAAC;IAC3BM,GAAG,EAAE,GAAGJ,UAAU,eAAe;IACjCK,GAAG,EAAEH,Q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J,CAAC;;AAED;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAM+B,aAA2B,GAAIhC,MAAM,IAAK;EAC9C,OAAOhB,gBAAgB,CAACgB,MAAM,EAAGC,CAAC,IAAK;IACrCA,CAAC,CAACC,UAAU,CAAC+B,sBAAsB,GAAG,iBAAiB;IAEvD,OAAOhC,CAAC;EACV,CAAC,CAAC;AACJ,CAAC;AAED,OAAO,MAAMK,GAAG,GAAG;EACjBP,sBAAsB;EACtBc,0BAA0B;EAC1BC,iBAAiB;EACjBkB;AACF,CAAC","ignoreList":[]}
1
+ {"version":3,"names":["withPodfile","withXcodeProject","mergeContents","removeGeneratedContents","TAG_PREFIX","applyPodfilePostInstall","contents","result","tag","src","newSrc","anchor","offset","comment","didMerge","didClear","withPodfilePostInstall","config","c","modResults","applyPodfileGlobalVariables","props","globalVariables","ios","nativeVersion","push","spmSpec","length","join","modified","withPodfileGlobalVariables","withoutSignatures","project","targetName","modRequest","projectName","phaseName","nativeTargetId","findTargetKey","console","warn","buildPhases","pbxNativeTargetSection","alreadyExists","some","phase","addBuildPhase","shellPath","shellScript","withDwarfDsym","debugInformationFormat"],"sourceRoot":"../../../src","sources":["plugin/ios.ts"],"mappings":";;AAAA,SAEEA,WAAW,EACXC,gBAAgB,QACX,sBAAsB;AAC7B,SACEC,aAAa,EACbC,uBAAuB,QAClB,+CAA+C;AAItD,MAAMC,UAAU,GAAG,iCAAiC;;AAEpD;AACA;AACA;AACA;AACA,OAAO,SAASC,uBAAuBA,CAACC,QAAgB,EAAU;EAChE,MAAMC,MAAM,GAAGL,aAAa,CAAC;IAC3BM,GAAG,EAAE,GAAGJ,UAAU,eAAe;IACjCK,GAAG,EAAEH,QAAQ;IACbI,MAAM,EAAE,mCAAmC;IAC3CC,MAAM,EAAE,+BAA+B;IACvCC,MAAM,EAAE,CAAC;IACTC,OAAO,EAAE;EACX,CAAC,CAAC;EAEF,IAAIN,MAAM,CAACO,QAAQ,IAAI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,IAAK;IACrCA,CAAC,CAACC,UAAU,CAAC+B,sBAAsB,GAAG,iBAAiB;IAEvD,OAAOhC,CAAC;EACV,CAAC,CAAC;AACJ,CAAC;AAED,OAAO,MAAMK,GAAG,GAAG;EACjBP,sBAAsB;EACtBc,0BAA0B;EAC1BC,iBAAiB;EACjBkB;AACF,CAAC","ignoreList":[]}
@@ -1,16 +1,15 @@
1
1
  "use strict";
2
2
 
3
3
  /**
4
- * Position anchor for markers and annotations.
5
- * Follows MapLibre GL JS PositionAnchor format.
4
+ * Position anchor for markers and annotations. Follows MapLibre GL JS
5
+ * PositionAnchor format.
6
6
  *
7
- * @see https://maplibre.org/maplibre-gl-js/docs/API/type-aliases/PositionAnchor/
7
+ * @see {@link https://maplibre.org/maplibre-gl-js/docs/API/type-aliases/PositionAnchor/}
8
8
  */
9
9
 
10
10
  /**
11
- * Converts an Anchor string to native {x, y} format.
12
- * x: 0 = left, 0.5 = center, 1 = right
13
- * y: 0 = top, 0.5 = center, 1 = bottom
11
+ * Converts an Anchor string to native {x, y} format. x: 0 = left, 0.5 = center,
12
+ * 1 = right y: 0 = top, 0.5 = center, 1 = bottom
14
13
  */
15
14
  export function anchorToNative(anchor) {
16
15
  switch (anchor) {
@@ -1 +1 @@
1
- {"version":3,"names":["anchorToNative","anchor","x","y"],"sourceRoot":"../../../src","sources":["types/Anchor.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;;AAYA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASA,cAAcA,CAACC,MAAc,EAA4B;EACvE,QAAQA,MAAM;IACZ,KAAK,QAAQ;MACX,OAAO;QAAEC,CAAC,EAAE,GAAG;QAAEC,CAAC,EAAE;MAAI,CAAC;IAC3B,KAAK,KAAK;MACR,OAAO;QAAED,CAAC,EAAE,GAAG;QAAEC,CAAC,EAAE;MAAE,CAAC;IACzB,KAAK,QAAQ;MACX,OAAO;QAAED,CAAC,EAAE,GAAG;QAAEC,CAAC,EAAE;MAAE,CAAC;IACzB,KAAK,MAAM;MACT,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAI,CAAC;IACzB,KAAK,OAAO;MACV,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAI,CAAC;IACzB,KAAK,UAAU;MACb,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;IACvB,KAAK,WAAW;MACd,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;IACvB,KAAK,aAAa;MAChB,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;IACvB,KAAK,cAAc;MACjB,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;EACzB;AACF","ignoreList":[]}
1
+ {"version":3,"names":["anchorToNative","anchor","x","y"],"sourceRoot":"../../../src","sources":["types/Anchor.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;;AAYA;AACA;AACA;AACA;AACA,OAAO,SAASA,cAAcA,CAACC,MAAc,EAA4B;EACvE,QAAQA,MAAM;IACZ,KAAK,QAAQ;MACX,OAAO;QAAEC,CAAC,EAAE,GAAG;QAAEC,CAAC,EAAE;MAAI,CAAC;IAC3B,KAAK,KAAK;MACR,OAAO;QAAED,CAAC,EAAE,GAAG;QAAEC,CAAC,EAAE;MAAE,CAAC;IACzB,KAAK,QAAQ;MACX,OAAO;QAAED,CAAC,EAAE,GAAG;QAAEC,CAAC,EAAE;MAAE,CAAC;IACzB,KAAK,MAAM;MACT,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAI,CAAC;IACzB,KAAK,OAAO;MACV,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAI,CAAC;IACzB,KAAK,UAAU;MACb,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;IACvB,KAAK,WAAW;MACd,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;IACvB,KAAK,aAAa;MAChB,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;IACvB,KAAK,cAAc;MACjB,OAAO;QAAED,CAAC,EAAE,CAAC;QAAEC,CAAC,EAAE;MAAE,CAAC;EACzB;AACF","ignoreList":[]}
@@ -26,8 +26,8 @@ export class AbstractAnimatedCoordinates extends AnimatedWithChildren {
26
26
  */
27
27
 
28
28
  /**
29
- * Subclasses can override getValue to calculate value from state.
30
- * Value is typically coordinates array, but can be anything
29
+ * Subclasses can override getValue to calculate value from state. Value is
30
+ * typically coordinates array, but can be anything
31
31
  *
32
32
  * @param state - either state from initialState and/or from calculate
33
33
  */
@@ -5,7 +5,7 @@ export class AnimatedCoordinatesArray extends AbstractAnimatedCoordinates {
5
5
  /**
6
6
  * Subclasses can override to calculate initial state
7
7
  *
8
- * @param {AnimatedCoordinates} coordinatesArray - to value from animate
8
+ * @param coordinatesArray - to value from animate
9
9
  * @returns {object} - the state object
10
10
  */
11
11
  onInitialState(coordinatesArray) {
@@ -16,10 +16,10 @@ export class AnimatedCoordinatesArray extends AbstractAnimatedCoordinates {
16
16
  }
17
17
 
18
18
  /**
19
- * Subclasses can override getValue to calculate value from state.
20
- * Value is typically coordinates array, but can be anything
19
+ * Subclasses can override getValue to calculate value from state. Value is
20
+ * typically coordinates array, but can be anything
21
21
  *
22
- * @param {object} state - either state from initialState and/or from calculate
22
+ * @param state - either state from initialState and/or from calculate
23
23
  * @returns {object}
24
24
  */
25
25
  onGetValue(state) {
@@ -29,8 +29,8 @@ export class AnimatedCoordinatesArray extends AbstractAnimatedCoordinates {
29
29
  /**
30
30
  * Calculates state based on startingState and progress, returns a new state
31
31
  *
32
- * @param {object} state - state object from initialState and/or from calculate
33
- * @param {number} progress - value between 0 and 1
32
+ * @param state - state object from initialState and/or from calculate
33
+ * @param progress - value between 0 and 1
34
34
  * @returns {object} next state
35
35
  */
36
36
  onCalculate(state, progress) {
@@ -3,7 +3,8 @@
3
3
  import { Animated } from "react-native";
4
4
  const AnimatedWithChildren = Object.getPrototypeOf(Animated.ValueXY);
5
5
  /**
6
- * AnimatedGeoJSON can be used to have animated properties inside the data property
6
+ * AnimatedGeoJSON can be used to have animated properties inside the data
7
+ * property
7
8
  *
8
9
  * Equivalent of AnimatedStyle for GeoJSON
9
10
  * https://github.com/facebook/react-native/blob/main/packages/react-native/Libraries/Animated/nodes/AnimatedStyle.js
@@ -1 +1 @@
1
- {"version":3,"names":["Animated","AnimatedWithChildren","Object","getPrototypeOf","ValueXY","AnimatedGeoJSON","constructor","valueIn","geojson","walkGeoJSONAndGetValues","value","Array","isArray","map","i","__getValue","result","key","walkAndProcess","cb","forEach","type","coordinates","length","__attach","v","__addChild","__detach","__removeChild"],"sourceRoot":"../../../../src","sources":["utils/animated/AnimatedGeoJSON.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAAQ,cAAc;AAMvC,MAAMC,oBAAoB,GAAGC,MAAM,CAACC,cAAc,CAACH,QAAQ,CAACI,OAAO,CAAC;AAYpE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,eAAe,SAASJ,oBAAoB,CAAC;EACxDK,WAAWA,CAACC,OAA+B,EAAE;IAC3C,KAAK,CAAC,CAAC;IACP,IAAI,CAACC,OAAO,GAAGD,OAAO;EACxB;EAEQE,uBAAuBA,CAACC,KAAU,EAAO;IAC/C,IAAIC,KAAK,CAACC,OAAO,CAACF,KAAK,CAAC,EAAE;MACxB,OAAOA,KAAK,CAACG,GAAG,CAAEC,CAAC,IAAK,IAAI,CAACL,uBAAuB,CAACK,CAAC,CAAC,CAAC;IAC1D;IAEA,IAAIJ,KAAK,YAAYT,oBAAoB,EAAE;MACzC,OAAQS,KAAK,CAASK,UAAU,CAAC,CAAC;IACpC;IAEA,IAAI,OAAOL,KAAK,KAAK,Q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ACf,IAAI,CAACT,cAAc,CAAC,IAAI,CAACV,OAAO,EAAGiB,CAAC,IAAMA,CAAC,CAASG,aAAa,CAAC,IAAI,CAAC,CAAC;IACxE,KAAK,CAACD,QAAQ,CAAC,CAAC;EAClB;AACF","ignoreList":[]}
1
+ {"version":3,"names":["Animated","AnimatedWithChildren","Object","getPrototypeOf","ValueXY","AnimatedGeoJSON","constructor","valueIn","geojson","walkGeoJSONAndGetValues","value","Array","isArray","map","i","__getValue","result","key","walkAndProcess","cb","forEach","type","coordinates","length","__attach","v","__addChild","__detach","__removeChild"],"sourceRoot":"../../../../src","sources":["utils/animated/AnimatedGeoJSON.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAAQ,cAAc;AAMvC,MAAMC,oBAAoB,GAAGC,MAAM,CAACC,cAAc,CAACH,QAAQ,CAACI,OAAO,CAAC;AAYpE;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,eAAe,SAASJ,oBAAoB,CAAC;EACxDK,WAAWA,CAACC,OAA+B,EAAE;IAC3C,KAAK,CAAC,CAAC;IACP,IAAI,CAACC,OAAO,GAAGD,OAAO;EACxB;EAEQE,uBAAuBA,CAACC,KAAU,EAAO;IAC/C,IAAIC,KAAK,CAACC,OAAO,CAACF,KAAK,CAAC,EAAE;MACxB,OAAOA,KAAK,CAACG,GAAG,CAAEC,CAAC,IAAK,IAAI,CAACL,uBAAuB,CAACK,CAAC,CAAC,CAAC;IAC1D;IAEA,IAAIJ,KAAK,YAAYT,oBAAoB,EAAE;MACzC,OAAQS,KAAK,CAASK,UAAU,CAAC,CAAC;IACpC;IAEA,IAAI,OAAOL,KAAK,KAAK,QAAQ,EAAE;MAC7B,MAAMM,MAA8B,GAAG,CAAC,CAAC;MAEzC,KAAK,MAAMC,GAAG,IAAIP,KAAK,EAAE;QACvBM,MAAM,CAACC,GAAG,CAAC,GAAG,IAAI,CAACR,uBAAuB,CAACC,KAAK,CAACO,GAAG,CAAC,CAAC;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