@maplibre/maplibre-react-native 11.0.0-alpha.14 → 11.0.0-alpha.16

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.
@@ -22,9 +22,9 @@ def $MLRN._add_spm_to_target(project, target, url, requirement, product_name)
22
22
  if !pkg
23
23
  pkg = project.new(pkg_class)
24
24
  pkg.repositoryURL = url
25
- pkg.requirement = requirement
26
25
  project.root_object.package_references << pkg
27
26
  end
27
+ pkg.requirement = requirement
28
28
  ref = target.package_product_dependencies.find { |r| r.class == ref_class && r.package == pkg && r.product_name == product_name }
29
29
  if !ref
30
30
  ref = project.new(ref_class)
@@ -115,11 +115,13 @@
115
115
  coordinate:(JS::NativeMapViewModule::SpecProjectCoordinate &)coordinate
116
116
  resolve:(RCTPromiseResolveBlock)resolve
117
117
  reject:(RCTPromiseRejectBlock)reject {
118
+ CLLocationCoordinate2D transformedCoordinate =
119
+ CLLocationCoordinate2DMake(coordinate.latitude(), coordinate.longitude());
120
+
118
121
  [self withMapView:reactTag
119
122
  block:^(MLRNMapView *view) {
120
123
  [MLRNMapViewManager project:view
121
- coordinate:CLLocationCoordinate2DMake(coordinate.latitude(),
122
- coordinate.longitude())
124
+ coordinate:transformedCoordinate
123
125
  resolve:resolve
124
126
  reject:reject];
125
127
  }
@@ -131,10 +133,12 @@
131
133
  point:(JS::NativeMapViewModule::SpecUnprojectPoint &)point
132
134
  resolve:(RCTPromiseResolveBlock)resolve
133
135
  reject:(RCTPromiseRejectBlock)reject {
136
+ CGPoint transformedPoint = CGPointMake(point.locationX(), point.locationY());
137
+
134
138
  [self withMapView:reactTag
135
139
  block:^(MLRNMapView *view) {
136
140
  [MLRNMapViewManager unproject:view
137
- point:CGPointMake(point.locationX(), point.locationY())
141
+ point:transformedPoint
138
142
  resolve:resolve
139
143
  reject:reject];
140
144
  }
@@ -166,6 +170,9 @@
166
170
  filter:(nonnull NSArray *)filter
167
171
  resolve:(nonnull RCTPromiseResolveBlock)resolve
168
172
  reject:(nonnull RCTPromiseRejectBlock)reject {
173
+ CLLocationCoordinate2D transformedCoordinate =
174
+ CLLocationCoordinate2DMake(coordinate.latitude(), coordinate.longitude());
175
+
169
176
  [self withMapView:reactTag
170
177
  block:^(MLRNMapView *view) {
171
178
  NSSet *layerIdSet = nil;
@@ -176,9 +183,7 @@
176
183
  NSPredicate *predicate = [FilterParser parse:filter];
177
184
 
178
185
  [MLRNMapViewManager queryRenderedFeaturesWithCoordinate:view
179
- coordinate:CLLocationCoordinate2D(
180
- coordinate.latitude(),
181
- coordinate.longitude())
186
+ coordinate:transformedCoordinate
182
187
  layerIds:layerIdSet
183
188
  predicate:predicate
184
189
  resolve:resolve
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@maplibre/maplibre-react-native",
3
3
  "description": "React Native library for creating maps with MapLibre Native for Android & iOS",
4
- "version": "11.0.0-alpha.14",
4
+ "version": "11.0.0-alpha.16",
5
5
  "publishConfig": {
6
6
  "access": "public",
7
7
  "provenance": true