@rnmapbox/maps 10.0.0-beta.67 → 10.0.0-beta.69

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.
@@ -130,8 +130,8 @@ dependencies {
130
130
  implementation 'com.mapbox.mapboxsdk:mapbox-sdk-turf:5.1.0'
131
131
  }
132
132
  else if (safeExtGet("RNMapboxMapsImpl", defaultMapboxMapsImpl) == "mapbox") {
133
- implementation 'com.mapbox.maps:android:10.10.0'
134
- implementation 'com.mapbox.mapboxsdk:mapbox-sdk-turf:6.8.0'
133
+ implementation 'com.mapbox.maps:android:10.11.0'
134
+ implementation 'com.mapbox.mapboxsdk:mapbox-sdk-turf:6.10.0'
135
135
  implementation 'androidx.asynclayoutinflater:asynclayoutinflater:1.0.0'
136
136
  }
137
137
  }
@@ -151,6 +151,7 @@ class RCTMGLMarkerView(context: Context?, private val mManager: RCTMGLMarkerView
151
151
  if (removed == false) {
152
152
  Logger.w("RCTMGLMarkerView", "Unable to remove view")
153
153
  }
154
+ didAddToMap = false
154
155
  }
155
156
  }
156
157
 
@@ -11,6 +11,7 @@ object CustomHttpHeaders : HttpServiceInterceptorInterface {
11
11
  HttpServiceFactory.getInstance().setInterceptor(
12
12
  this
13
13
  )
14
+ map.put(headerName, headerValue)
14
15
  }
15
16
 
16
17
  fun removeCustomHeader(headerName: String) {
@@ -36,6 +36,10 @@ class RCTMGLOfflineModule: RCTEventEmitter {
36
36
  return OfflineManager(resourceOptions: .init(accessToken: MGLModule.accessToken!))
37
37
  }()
38
38
 
39
+ lazy var offlineRegionManager: OfflineRegionManager = {
40
+ return OfflineRegionManager(resourceOptions: .init(accessToken: MGLModule.accessToken!))
41
+ }()
42
+
39
43
  lazy var tileStore : TileStore = {
40
44
  return TileStore.default
41
45
  }()
@@ -51,13 +55,13 @@ class RCTMGLOfflineModule: RCTEventEmitter {
51
55
  if let styleURI = rnMetadata["styleURI"] as? String {
52
56
  self.styleURI = StyleURI(rawValue: styleURI)
53
57
  }
54
- if let bounds = rnMetadata["bounds"] as? JSONObject {
58
+ if let bounds = rnMetadata["bounds"] as? [String:Any] {
55
59
  self.bounds = logged("RCTMGLOfflineModule.TileRegionPack: cannot decode bounds") {
56
60
  let jsonData = try JSONSerialization.data(withJSONObject: bounds)
57
61
  return try JSONDecoder().decode(Geometry.self, from: jsonData)
58
62
  }
59
63
  }
60
- if let zoomRange = rnMetadata["zoomRange"] as? JSONObject {
64
+ if let zoomRange = rnMetadata["zoomRange"] as? Any {
61
65
  self.zoomRange = logged("RCTMGLOfflineModule.TileRegionPack: cannot decode zoomRange") {
62
66
  let jsonData = try JSONSerialization.data(withJSONObject: zoomRange)
63
67
  return try JSONDecoder().decode(ClosedRange<UInt8>.self, from: jsonData)
@@ -528,7 +532,7 @@ class RCTMGLOfflineModule: RCTEventEmitter {
528
532
 
529
533
  @objc
530
534
  func setTileCountLimit(_ limit: NSNumber) {
531
- RCTMGLLogWarn("setTileCountLimit is not yet implemented on v10")
535
+ self.offlineRegionManager.setOfflineMapboxTileCountLimitForLimit(limit.uint64Value)
532
536
  }
533
537
 
534
538
 
package/ios/install.md CHANGED
@@ -60,7 +60,7 @@ You can also override the version to use. *Warning:* if you set a version, then
60
60
 
61
61
  ```ruby
62
62
  # Warning: only for advanced use cases, only do this if you know what you're doing.
63
- # $RNMapboxMapsVersion = '~> 10.9.0'
63
+ # $RNMapboxMapsVersion = '~> 10.11.0'
64
64
  ```
65
65
 
66
66
  You will need to authorize your download of the Maps SDK with a secret access token with the `DOWNLOADS:READ` scope. This [guide](https://docs.mapbox.com/ios/maps/guides/install/#configure-credentials) explains how to configure the secret token under section `Configure your secret token`.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@rnmapbox/maps",
3
3
  "description": "A Mapbox react native module for creating custom maps",
4
- "version": "10.0.0-beta.67",
4
+ "version": "10.0.0-beta.69",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -20,7 +20,7 @@ require 'json'
20
20
  package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
21
21
 
22
22
  ## Warning: these lines are scanned by autogenerate.js
23
- rnMapboxMapsDefaultMapboxVersion = '~> 10.10.0'
23
+ rnMapboxMapsDefaultMapboxVersion = '~> 10.11.0'
24
24
  rnMapboxMapsDefaultMapboxGLVersion = '~> 5.9.0'
25
25
  rnMapboxMapsDefaultMapLibreVersion = 'exactVersion 5.12.1'
26
26