@lugg/maps 0.2.0-alpha.0
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.
- package/LICENSE +20 -0
- package/LuggMaps.podspec +23 -0
- package/README.md +119 -0
- package/android/build.gradle +78 -0
- package/android/gradle.properties +5 -0
- package/android/src/main/AndroidManifest.xml +2 -0
- package/android/src/main/java/com/luggmaps/LuggMapsGoogleMapView.kt +438 -0
- package/android/src/main/java/com/luggmaps/LuggMapsGoogleMapViewManager.kt +144 -0
- package/android/src/main/java/com/luggmaps/LuggMapsMarkerView.kt +134 -0
- package/android/src/main/java/com/luggmaps/LuggMapsMarkerViewManager.kt +69 -0
- package/android/src/main/java/com/luggmaps/LuggMapsPackage.kt +13 -0
- package/android/src/main/java/com/luggmaps/LuggMapsPolylineView.kt +79 -0
- package/android/src/main/java/com/luggmaps/LuggMapsPolylineViewManager.kt +71 -0
- package/android/src/main/java/com/luggmaps/LuggMapsWrapperView.kt +39 -0
- package/android/src/main/java/com/luggmaps/LuggMapsWrapperViewManager.kt +25 -0
- package/android/src/main/java/com/luggmaps/core/PolylineAnimator.kt +180 -0
- package/android/src/main/java/com/luggmaps/events/CameraIdleEvent.kt +21 -0
- package/android/src/main/java/com/luggmaps/events/CameraMoveEvent.kt +28 -0
- package/app.plugin.js +1 -0
- package/ios/LuggMapsAppleMapView.h +16 -0
- package/ios/LuggMapsAppleMapView.mm +544 -0
- package/ios/LuggMapsGoogleMapView.h +13 -0
- package/ios/LuggMapsGoogleMapView.mm +439 -0
- package/ios/LuggMapsMarkerView.h +29 -0
- package/ios/LuggMapsMarkerView.mm +154 -0
- package/ios/LuggMapsPolylineView.h +27 -0
- package/ios/LuggMapsPolylineView.mm +116 -0
- package/ios/LuggMapsWrapperView.h +9 -0
- package/ios/LuggMapsWrapperView.mm +36 -0
- package/ios/core/GMSPolylineAnimator.h +11 -0
- package/ios/core/GMSPolylineAnimator.m +151 -0
- package/ios/core/MKPolylineAnimator.h +12 -0
- package/ios/core/MKPolylineAnimator.m +252 -0
- package/ios/core/PolylineAnimatorBase.h +22 -0
- package/ios/core/PolylineAnimatorBase.m +35 -0
- package/ios/events/CameraIdleEvent.h +24 -0
- package/ios/events/CameraMoveEvent.h +26 -0
- package/ios/extensions/MKMapView+Zoom.h +19 -0
- package/ios/extensions/MKMapView+Zoom.m +45 -0
- package/lib/module/MapView.js +87 -0
- package/lib/module/MapView.js.map +1 -0
- package/lib/module/MapView.types.js +4 -0
- package/lib/module/MapView.types.js.map +1 -0
- package/lib/module/Marker.js +34 -0
- package/lib/module/Marker.js.map +1 -0
- package/lib/module/Marker.types.js +4 -0
- package/lib/module/Marker.types.js.map +1 -0
- package/lib/module/Polyline.js +30 -0
- package/lib/module/Polyline.js.map +1 -0
- package/lib/module/Polyline.types.js +4 -0
- package/lib/module/Polyline.types.js.map +1 -0
- package/lib/module/fabric/LuggMapsAppleMapViewNativeComponent.ts +73 -0
- package/lib/module/fabric/LuggMapsGoogleMapViewNativeComponent.ts +74 -0
- package/lib/module/fabric/LuggMapsMarkerViewNativeComponent.ts +25 -0
- package/lib/module/fabric/LuggMapsPolylineViewNativeComponent.ts +19 -0
- package/lib/module/fabric/LuggMapsWrapperViewNativeComponent.ts +8 -0
- package/lib/module/index.js +6 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/types.js +2 -0
- package/lib/module/types.js.map +1 -0
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/plugin/src/index.d.ts +16 -0
- package/lib/typescript/plugin/src/index.d.ts.map +1 -0
- package/lib/typescript/plugin/src/withMapsAndroid.d.ts +6 -0
- package/lib/typescript/plugin/src/withMapsAndroid.d.ts.map +1 -0
- package/lib/typescript/plugin/src/withMapsIOS.d.ts +6 -0
- package/lib/typescript/plugin/src/withMapsIOS.d.ts.map +1 -0
- package/lib/typescript/src/MapView.d.ts +12 -0
- package/lib/typescript/src/MapView.d.ts.map +1 -0
- package/lib/typescript/src/MapView.types.d.ts +102 -0
- package/lib/typescript/src/MapView.types.d.ts.map +1 -0
- package/lib/typescript/src/Marker.d.ts +6 -0
- package/lib/typescript/src/Marker.d.ts.map +1 -0
- package/lib/typescript/src/Marker.types.d.ts +32 -0
- package/lib/typescript/src/Marker.types.d.ts.map +1 -0
- package/lib/typescript/src/Polyline.d.ts +6 -0
- package/lib/typescript/src/Polyline.d.ts.map +1 -0
- package/lib/typescript/src/Polyline.types.d.ts +24 -0
- package/lib/typescript/src/Polyline.types.d.ts.map +1 -0
- package/lib/typescript/src/fabric/LuggMapsAppleMapViewNativeComponent.d.ts +47 -0
- package/lib/typescript/src/fabric/LuggMapsAppleMapViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/LuggMapsGoogleMapViewNativeComponent.d.ts +48 -0
- package/lib/typescript/src/fabric/LuggMapsGoogleMapViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/LuggMapsMarkerViewNativeComponent.d.ts +20 -0
- package/lib/typescript/src/fabric/LuggMapsMarkerViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/LuggMapsPolylineViewNativeComponent.d.ts +15 -0
- package/lib/typescript/src/fabric/LuggMapsPolylineViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/LuggMapsWrapperViewNativeComponent.d.ts +6 -0
- package/lib/typescript/src/fabric/LuggMapsWrapperViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +8 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/types.d.ts +28 -0
- package/lib/typescript/src/types.d.ts.map +1 -0
- package/package.json +200 -0
- package/plugin/build/index.d.ts +15 -0
- package/plugin/build/index.js +13 -0
- package/plugin/build/withMapsAndroid.d.ts +5 -0
- package/plugin/build/withMapsAndroid.js +15 -0
- package/plugin/build/withMapsIOS.d.ts +5 -0
- package/plugin/build/withMapsIOS.js +27 -0
- package/src/MapView.tsx +111 -0
- package/src/MapView.types.ts +110 -0
- package/src/Marker.tsx +31 -0
- package/src/Marker.types.ts +32 -0
- package/src/Polyline.tsx +32 -0
- package/src/Polyline.types.ts +24 -0
- package/src/fabric/LuggMapsAppleMapViewNativeComponent.ts +73 -0
- package/src/fabric/LuggMapsGoogleMapViewNativeComponent.ts +74 -0
- package/src/fabric/LuggMapsMarkerViewNativeComponent.ts +25 -0
- package/src/fabric/LuggMapsPolylineViewNativeComponent.ts +19 -0
- package/src/fabric/LuggMapsWrapperViewNativeComponent.ts +8 -0
- package/src/index.ts +13 -0
- package/src/types.ts +30 -0
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
#import <MapKit/MapKit.h>
|
|
2
|
+
|
|
3
|
+
NS_ASSUME_NONNULL_BEGIN
|
|
4
|
+
|
|
5
|
+
@interface MKMapView (Zoom)
|
|
6
|
+
|
|
7
|
+
- (void)setCenterCoordinate:(CLLocationCoordinate2D)centerCoordinate
|
|
8
|
+
zoomLevel:(double)zoomLevel
|
|
9
|
+
animated:(BOOL)animated;
|
|
10
|
+
|
|
11
|
+
- (MKCoordinateRegion)regionForCenterCoordinate:
|
|
12
|
+
(CLLocationCoordinate2D)centerCoordinate
|
|
13
|
+
zoomLevel:(double)zoomLevel;
|
|
14
|
+
|
|
15
|
+
- (double)zoomLevel;
|
|
16
|
+
|
|
17
|
+
@end
|
|
18
|
+
|
|
19
|
+
NS_ASSUME_NONNULL_END
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
#import "MKMapView+Zoom.h"
|
|
2
|
+
|
|
3
|
+
@implementation MKMapView (Zoom)
|
|
4
|
+
|
|
5
|
+
- (MKCoordinateSpan)coordinateSpanForZoomLevel:(double)zoomLevel centerCoordinate:(CLLocationCoordinate2D)centerCoordinate
|
|
6
|
+
{
|
|
7
|
+
// Google Maps: zoom level defines how many 256px tiles fit the world
|
|
8
|
+
// At zoom 0, 1 tile = 360 degrees
|
|
9
|
+
// Each zoom level doubles the number of tiles (halves the degrees per tile)
|
|
10
|
+
// Offset of ~0.5 adjusts for difference between Google Maps and MKMapView rendering
|
|
11
|
+
double adjustedZoom = zoomLevel - 0.5;
|
|
12
|
+
double latitudeDelta = 360.0 / pow(2, adjustedZoom);
|
|
13
|
+
|
|
14
|
+
// Adjust longitude delta for latitude (Mercator projection)
|
|
15
|
+
double longitudeDelta = latitudeDelta / cos(centerCoordinate.latitude * M_PI / 180.0);
|
|
16
|
+
|
|
17
|
+
return MKCoordinateSpanMake(latitudeDelta, longitudeDelta);
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
#pragma mark - Public Methods
|
|
21
|
+
|
|
22
|
+
- (void)setCenterCoordinate:(CLLocationCoordinate2D)centerCoordinate
|
|
23
|
+
zoomLevel:(double)zoomLevel
|
|
24
|
+
animated:(BOOL)animated
|
|
25
|
+
{
|
|
26
|
+
MKCoordinateRegion region = [self regionForCenterCoordinate:centerCoordinate zoomLevel:zoomLevel];
|
|
27
|
+
[self setRegion:region animated:animated];
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
- (MKCoordinateRegion)regionForCenterCoordinate:(CLLocationCoordinate2D)centerCoordinate
|
|
31
|
+
zoomLevel:(double)zoomLevel
|
|
32
|
+
{
|
|
33
|
+
zoomLevel = MIN(zoomLevel, 28);
|
|
34
|
+
MKCoordinateSpan span = [self coordinateSpanForZoomLevel:zoomLevel centerCoordinate:centerCoordinate];
|
|
35
|
+
return MKCoordinateRegionMake(centerCoordinate, span);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
- (double)zoomLevel
|
|
39
|
+
{
|
|
40
|
+
MKCoordinateRegion region = self.region;
|
|
41
|
+
double zoomLevel = log2(360.0 / region.span.latitudeDelta) + 0.5;
|
|
42
|
+
return zoomLevel;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
@end
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import { Platform, StyleSheet } from 'react-native';
|
|
5
|
+
import LuggMapsGoogleMapViewNativeComponent, { Commands as GoogleMapCommands } from './fabric/LuggMapsGoogleMapViewNativeComponent';
|
|
6
|
+
import LuggMapsAppleMapViewNativeComponent, { Commands as AppleMapCommands } from './fabric/LuggMapsAppleMapViewNativeComponent';
|
|
7
|
+
import LuggMapsWrapperViewNativeComponent from './fabric/LuggMapsWrapperViewNativeComponent';
|
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
+
export class MapView extends React.Component {
|
|
10
|
+
static defaultProps = {
|
|
11
|
+
provider: Platform.OS === 'ios' ? 'apple' : 'google',
|
|
12
|
+
initialZoom: 10,
|
|
13
|
+
zoomEnabled: true,
|
|
14
|
+
scrollEnabled: true,
|
|
15
|
+
rotateEnabled: true,
|
|
16
|
+
pitchEnabled: true
|
|
17
|
+
};
|
|
18
|
+
nativeRef = /*#__PURE__*/React.createRef();
|
|
19
|
+
get nativeCommands() {
|
|
20
|
+
const provider = this.props.provider ?? MapView.defaultProps.provider;
|
|
21
|
+
const isApple = Platform.OS === 'ios' && provider === 'apple';
|
|
22
|
+
return isApple ? AppleMapCommands : GoogleMapCommands;
|
|
23
|
+
}
|
|
24
|
+
moveCamera(coordinate, options) {
|
|
25
|
+
const ref = this.nativeRef.current;
|
|
26
|
+
if (!ref) return;
|
|
27
|
+
const {
|
|
28
|
+
zoom,
|
|
29
|
+
duration = -1
|
|
30
|
+
} = options;
|
|
31
|
+
this.nativeCommands.moveCamera(ref, coordinate.latitude, coordinate.longitude, zoom, duration);
|
|
32
|
+
}
|
|
33
|
+
fitCoordinates(coordinates, options) {
|
|
34
|
+
const ref = this.nativeRef.current;
|
|
35
|
+
const first = coordinates[0];
|
|
36
|
+
if (!ref || !first) return;
|
|
37
|
+
const {
|
|
38
|
+
padding = 0,
|
|
39
|
+
duration = -1
|
|
40
|
+
} = options ?? {};
|
|
41
|
+
if (coordinates.length === 1) {
|
|
42
|
+
const zoom = this.props.initialZoom ?? 10;
|
|
43
|
+
this.moveCamera(first, {
|
|
44
|
+
zoom,
|
|
45
|
+
duration
|
|
46
|
+
});
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
this.nativeCommands.fitCoordinates(ref, coordinates, padding, duration);
|
|
50
|
+
}
|
|
51
|
+
render() {
|
|
52
|
+
const {
|
|
53
|
+
provider,
|
|
54
|
+
mapId,
|
|
55
|
+
initialCoordinate,
|
|
56
|
+
initialZoom,
|
|
57
|
+
zoomEnabled,
|
|
58
|
+
scrollEnabled,
|
|
59
|
+
rotateEnabled,
|
|
60
|
+
pitchEnabled,
|
|
61
|
+
padding,
|
|
62
|
+
onCameraMove,
|
|
63
|
+
onCameraIdle,
|
|
64
|
+
children,
|
|
65
|
+
...rest
|
|
66
|
+
} = this.props;
|
|
67
|
+
const NativeMapView = Platform.OS === 'ios' && provider === 'apple' ? LuggMapsAppleMapViewNativeComponent : LuggMapsGoogleMapViewNativeComponent;
|
|
68
|
+
return /*#__PURE__*/_jsxs(NativeMapView, {
|
|
69
|
+
ref: this.nativeRef,
|
|
70
|
+
...rest,
|
|
71
|
+
mapId: mapId,
|
|
72
|
+
initialCoordinate: initialCoordinate,
|
|
73
|
+
initialZoom: initialZoom,
|
|
74
|
+
zoomEnabled: zoomEnabled,
|
|
75
|
+
scrollEnabled: scrollEnabled,
|
|
76
|
+
rotateEnabled: rotateEnabled,
|
|
77
|
+
pitchEnabled: pitchEnabled,
|
|
78
|
+
padding: padding,
|
|
79
|
+
onCameraMove: onCameraMove,
|
|
80
|
+
onCameraIdle: onCameraIdle,
|
|
81
|
+
children: [/*#__PURE__*/_jsx(LuggMapsWrapperViewNativeComponent, {
|
|
82
|
+
style: StyleSheet.absoluteFill
|
|
83
|
+
}), children]
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
//# sourceMappingURL=MapView.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","Platform","StyleSheet","LuggMapsGoogleMapViewNativeComponent","Commands","GoogleMapCommands","LuggMapsAppleMapViewNativeComponent","AppleMapCommands","LuggMapsWrapperViewNativeComponent","jsx","_jsx","jsxs","_jsxs","MapView","Component","defaultProps","provider","OS","initialZoom","zoomEnabled","scrollEnabled","rotateEnabled","pitchEnabled","nativeRef","createRef","nativeCommands","props","isApple","moveCamera","coordinate","options","ref","current","zoom","duration","latitude","longitude","fitCoordinates","coordinates","first","padding","length","render","mapId","initialCoordinate","onCameraMove","onCameraIdle","children","rest","NativeMapView","style","absoluteFill"],"sourceRoot":"../../src","sources":["MapView.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,SAASC,QAAQ,EAAEC,UAAU,QAAQ,cAAc;AACnD,OAAOC,oCAAoC,IACzCC,QAAQ,IAAIC,iBAAiB,QACxB,+CAA+C;AACtD,OAAOC,mCAAmC,IACxCF,QAAQ,IAAIG,gBAAgB,QACvB,8CAA8C;AACrD,OAAOC,kCAAkC,MAAM,6CAA6C;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAS7F,OAAO,MAAMC,OAAO,SACVb,KAAK,CAACc,SAAS,CAEzB;EACE,OAAOC,YAAY,GAA0B;IAC3CC,QAAQ,EAAEf,QAAQ,CAACgB,EAAE,KAAK,KAAK,GAAG,OAAO,GAAG,QAAQ;IACpDC,WAAW,EAAE,EAAE;IACfC,WAAW,EAAE,IAAI;IACjBC,aAAa,EAAE,IAAI;IACnBC,aAAa,EAAE,IAAI;IACnBC,YAAY,EAAE;EAChB,CAAC;EAEOC,SAAS,gBAAGvB,KAAK,CAACwB,SAAS,CAAM,CAAC;EAE1C,IAAYC,cAAcA,CAAA,EAAG;IAC3B,MAAMT,QAAQ,GAAG,IAAI,CAACU,KAAK,CAACV,QAAQ,IAAIH,OAAO,CAACE,YAAY,CAACC,QAAQ;IACrE,MAAMW,OAAO,GAAG1B,QAAQ,CAACgB,EAAE,KAAK,KAAK,IAAID,QAAQ,KAAK,OA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;MACR,GAAGC;IACL,CAAC,GAAG,IAAI,CAACtB,KAAK;IAEd,MAAMuB,aAAa,GACjBhD,QAAQ,CAACgB,EAAE,KAAK,KAAK,IAAID,QAAQ,KAAK,OAAO,GACzCV,mCAAmC,GACnCH,oCAAoC;IAE1C,oBACES,KAAA,CAACqC,aAAa;MACZlB,GAAG,EAAE,IAAI,CAACR,SAAU;MAAA,GAChByB,IAAI;MACRL,KAAK,EAAEA,KAAM;MACbC,iBAAiB,EAAEA,iBAAkB;MACrC1B,WAAW,EAAEA,WAAY;MACzBC,WAAW,EAAEA,WAAY;MACzBC,aAAa,EAAEA,aAAc;MAC7BC,aAAa,EAAEA,aAAc;MAC7BC,YAAY,EAAEA,YAAa;MAC3BkB,OAAO,EAAEA,OAAQ;MACjBK,YAAY,EAAEA,YAAa;MAC3BC,YAAY,EAAEA,YAAa;MAAAC,QAAA,gBAE3BrC,IAAA,CAACF,kCAAkC;QAAC0C,KAAK,EAAEhD,UAAU,CAACiD;MAAa,CAAE,CAAC,EACrEJ,QAAQ;IAAA,CACI,CAAC;EAEpB;AACF","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../src","sources":["MapView.types.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import LuggMapsMarkerViewNativeComponent from './fabric/LuggMapsMarkerViewNativeComponent';
|
|
5
|
+
import { StyleSheet } from 'react-native';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
export class Marker extends React.Component {
|
|
8
|
+
render() {
|
|
9
|
+
const {
|
|
10
|
+
name,
|
|
11
|
+
coordinate,
|
|
12
|
+
title,
|
|
13
|
+
description,
|
|
14
|
+
anchor,
|
|
15
|
+
children
|
|
16
|
+
} = this.props;
|
|
17
|
+
return /*#__PURE__*/_jsx(LuggMapsMarkerViewNativeComponent, {
|
|
18
|
+
style: styles.marker,
|
|
19
|
+
name: name,
|
|
20
|
+
coordinate: coordinate,
|
|
21
|
+
title: title,
|
|
22
|
+
description: description,
|
|
23
|
+
anchor: anchor,
|
|
24
|
+
children: children
|
|
25
|
+
});
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
const styles = StyleSheet.create({
|
|
29
|
+
marker: {
|
|
30
|
+
position: 'absolute',
|
|
31
|
+
pointerEvents: 'box-none'
|
|
32
|
+
}
|
|
33
|
+
});
|
|
34
|
+
//# sourceMappingURL=Marker.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","LuggMapsMarkerViewNativeComponent","StyleSheet","jsx","_jsx","Marker","Component","render","name","coordinate","title","description","anchor","children","props","style","styles","marker","create","position","pointerEvents"],"sourceRoot":"../../src","sources":["Marker.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,iCAAiC,MAAM,4CAA4C;AAE1F,SAASC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAE1C,OAAO,MAAMC,MAAM,SAASL,KAAK,CAACM,SAAS,CAAc;EACvDC,MAAMA,CAAA,EAAG;IACP,MAAM;MAAEC,IAAI;MAAEC,UAAU;MAAEC,KAAK;MAAEC,WAAW;MAAEC,MAAM;MAAEC;IAAS,CAAC,GAC9D,IAAI,CAACC,KAAK;IAEZ,oBACEV,IAAA,CAACH,iCAAiC;MAChCc,KAAK,EAAEC,MAAM,CAACC,MAAO;MACrBT,IAAI,EAAEA,IAAK;MACXC,UAAU,EAAEA,UAAW;MACvBC,KAAK,EAAEA,KAAM;MACbC,WAAW,EAAEA,WAAY;MACzBC,MAAM,EAAEA,MAAO;MAAAC,QAAA,EAEdA;IAAQ,CACwB,CAAC;EAExC;AACF;AAEA,MAAMG,MAAM,GAAGd,UAAU,CAACgB,MAAM,CAAC;EAC/BD,MAAM,EAAE;IACNE,QAAQ,EAAE,UAAU;IACpBC,aAAa,EAAE;EACjB;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../src","sources":["Marker.types.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import LuggMapsPolylineViewNativeComponent from './fabric/LuggMapsPolylineViewNativeComponent';
|
|
5
|
+
import { StyleSheet } from 'react-native';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
export class Polyline extends React.Component {
|
|
8
|
+
render() {
|
|
9
|
+
const {
|
|
10
|
+
coordinates,
|
|
11
|
+
strokeColors,
|
|
12
|
+
strokeWidth,
|
|
13
|
+
animated = false
|
|
14
|
+
} = this.props;
|
|
15
|
+
return /*#__PURE__*/_jsx(LuggMapsPolylineViewNativeComponent, {
|
|
16
|
+
style: styles.polyline,
|
|
17
|
+
coordinates: coordinates,
|
|
18
|
+
strokeColors: strokeColors,
|
|
19
|
+
strokeWidth: strokeWidth,
|
|
20
|
+
animated: animated
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
const styles = StyleSheet.create({
|
|
25
|
+
polyline: {
|
|
26
|
+
position: 'absolute',
|
|
27
|
+
pointerEvents: 'none'
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
//# sourceMappingURL=Polyline.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","LuggMapsPolylineViewNativeComponent","StyleSheet","jsx","_jsx","Polyline","Component","render","coordinates","strokeColors","strokeWidth","animated","props","style","styles","polyline","create","position","pointerEvents"],"sourceRoot":"../../src","sources":["Polyline.tsx"],"mappings":";;AAAA,OAAOA,KAAK,MAAM,OAAO;AACzB,OAAOC,mCAAmC,MAAM,8CAA8C;AAE9F,SAASC,UAAU,QAAQ,cAAc;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAE1C,OAAO,MAAMC,QAAQ,SAASL,KAAK,CAACM,SAAS,CAAgB;EAC3DC,MAAMA,CAAA,EAAG;IACP,MAAM;MACJC,WAAW;MACXC,YAAY;MACZC,WAAW;MACXC,QAAQ,GAAG;IACb,CAAC,GAAG,IAAI,CAACC,KAAK;IAEd,oBACER,IAAA,CAACH,mCAAmC;MAClCY,KAAK,EAAEC,MAAM,CAACC,QAAS;MACvBP,WAAW,EAAEA,WAAY;MACzBC,YAAY,EAAEA,YAAa;MAC3BC,WAAW,EAAEA,WAAY;MACzBC,QAAQ,EAAEA;IAAS,CACpB,CAAC;EAEN;AACF;AAEA,MAAMG,MAAM,GAAGZ,UAAU,CAACc,MAAM,CAAC;EAC/BD,QAAQ,EAAE;IACRE,QAAQ,EAAE,UAAU;IACpBC,aAAa,EAAE;EACjB;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../src","sources":["Polyline.types.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { codegenNativeComponent, codegenNativeCommands } from 'react-native';
|
|
2
|
+
import type { ViewProps, HostComponent } from 'react-native';
|
|
3
|
+
import type {
|
|
4
|
+
Double,
|
|
5
|
+
DirectEventHandler,
|
|
6
|
+
} from 'react-native/Libraries/Types/CodegenTypes';
|
|
7
|
+
|
|
8
|
+
export interface Coordinate {
|
|
9
|
+
latitude: Double;
|
|
10
|
+
longitude: Double;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface EdgeInsets {
|
|
14
|
+
top: Double;
|
|
15
|
+
left: Double;
|
|
16
|
+
bottom: Double;
|
|
17
|
+
right: Double;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export interface CameraMoveEvent {
|
|
21
|
+
coordinate: {
|
|
22
|
+
latitude: Double;
|
|
23
|
+
longitude: Double;
|
|
24
|
+
};
|
|
25
|
+
zoom: Double;
|
|
26
|
+
dragging: boolean;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export interface CameraIdleEvent {
|
|
30
|
+
coordinate: {
|
|
31
|
+
latitude: Double;
|
|
32
|
+
longitude: Double;
|
|
33
|
+
};
|
|
34
|
+
zoom: Double;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export interface NativeProps extends ViewProps {
|
|
38
|
+
initialCoordinate?: Coordinate;
|
|
39
|
+
initialZoom?: Double;
|
|
40
|
+
zoomEnabled?: boolean;
|
|
41
|
+
scrollEnabled?: boolean;
|
|
42
|
+
rotateEnabled?: boolean;
|
|
43
|
+
pitchEnabled?: boolean;
|
|
44
|
+
padding?: EdgeInsets;
|
|
45
|
+
onCameraMove?: DirectEventHandler<CameraMoveEvent>;
|
|
46
|
+
onCameraIdle?: DirectEventHandler<CameraIdleEvent>;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
type ComponentType = HostComponent<NativeProps>;
|
|
50
|
+
|
|
51
|
+
interface NativeCommands {
|
|
52
|
+
moveCamera: (
|
|
53
|
+
viewRef: React.ElementRef<ComponentType>,
|
|
54
|
+
latitude: Double,
|
|
55
|
+
longitude: Double,
|
|
56
|
+
zoom: Double,
|
|
57
|
+
duration: Double
|
|
58
|
+
) => void;
|
|
59
|
+
fitCoordinates: (
|
|
60
|
+
viewRef: React.ElementRef<ComponentType>,
|
|
61
|
+
coordinates: Coordinate[],
|
|
62
|
+
padding: Double,
|
|
63
|
+
duration: Double
|
|
64
|
+
) => void;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
export const Commands = codegenNativeCommands<NativeCommands>({
|
|
68
|
+
supportedCommands: ['moveCamera', 'fitCoordinates'],
|
|
69
|
+
});
|
|
70
|
+
|
|
71
|
+
export default codegenNativeComponent<NativeProps>(
|
|
72
|
+
'LuggMapsAppleMapView'
|
|
73
|
+
) as ComponentType;
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { codegenNativeComponent, codegenNativeCommands } from 'react-native';
|
|
2
|
+
import type { ViewProps, HostComponent } from 'react-native';
|
|
3
|
+
import type {
|
|
4
|
+
Double,
|
|
5
|
+
DirectEventHandler,
|
|
6
|
+
} from 'react-native/Libraries/Types/CodegenTypes';
|
|
7
|
+
|
|
8
|
+
export interface Coordinate {
|
|
9
|
+
latitude: Double;
|
|
10
|
+
longitude: Double;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface EdgeInsets {
|
|
14
|
+
top: Double;
|
|
15
|
+
left: Double;
|
|
16
|
+
bottom: Double;
|
|
17
|
+
right: Double;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export interface CameraMoveEvent {
|
|
21
|
+
coordinate: {
|
|
22
|
+
latitude: Double;
|
|
23
|
+
longitude: Double;
|
|
24
|
+
};
|
|
25
|
+
zoom: Double;
|
|
26
|
+
dragging: boolean;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export interface CameraIdleEvent {
|
|
30
|
+
coordinate: {
|
|
31
|
+
latitude: Double;
|
|
32
|
+
longitude: Double;
|
|
33
|
+
};
|
|
34
|
+
zoom: Double;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
export interface NativeProps extends ViewProps {
|
|
38
|
+
mapId?: string;
|
|
39
|
+
initialCoordinate?: Coordinate;
|
|
40
|
+
initialZoom?: Double;
|
|
41
|
+
zoomEnabled?: boolean;
|
|
42
|
+
scrollEnabled?: boolean;
|
|
43
|
+
rotateEnabled?: boolean;
|
|
44
|
+
pitchEnabled?: boolean;
|
|
45
|
+
padding?: EdgeInsets;
|
|
46
|
+
onCameraMove?: DirectEventHandler<CameraMoveEvent>;
|
|
47
|
+
onCameraIdle?: DirectEventHandler<CameraIdleEvent>;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
type ComponentType = HostComponent<NativeProps>;
|
|
51
|
+
|
|
52
|
+
interface NativeCommands {
|
|
53
|
+
moveCamera: (
|
|
54
|
+
viewRef: React.ElementRef<ComponentType>,
|
|
55
|
+
latitude: Double,
|
|
56
|
+
longitude: Double,
|
|
57
|
+
zoom: Double,
|
|
58
|
+
duration: Double
|
|
59
|
+
) => void;
|
|
60
|
+
fitCoordinates: (
|
|
61
|
+
viewRef: React.ElementRef<ComponentType>,
|
|
62
|
+
coordinates: Coordinate[],
|
|
63
|
+
padding: Double,
|
|
64
|
+
duration: Double
|
|
65
|
+
) => void;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export const Commands = codegenNativeCommands<NativeCommands>({
|
|
69
|
+
supportedCommands: ['moveCamera', 'fitCoordinates'],
|
|
70
|
+
});
|
|
71
|
+
|
|
72
|
+
export default codegenNativeComponent<NativeProps>(
|
|
73
|
+
'LuggMapsGoogleMapView'
|
|
74
|
+
) as ComponentType;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { codegenNativeComponent } from 'react-native';
|
|
2
|
+
import type { ViewProps, HostComponent } from 'react-native';
|
|
3
|
+
import type { Double } from 'react-native/Libraries/Types/CodegenTypes';
|
|
4
|
+
|
|
5
|
+
export interface Coordinate {
|
|
6
|
+
latitude: Double;
|
|
7
|
+
longitude: Double;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export interface Point {
|
|
11
|
+
x: Double;
|
|
12
|
+
y: Double;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export interface NativeProps extends ViewProps {
|
|
16
|
+
name?: string;
|
|
17
|
+
coordinate: Coordinate;
|
|
18
|
+
title?: string;
|
|
19
|
+
description?: string;
|
|
20
|
+
anchor?: Point;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
export default codegenNativeComponent<NativeProps>(
|
|
24
|
+
'LuggMapsMarkerView'
|
|
25
|
+
) as HostComponent<NativeProps>;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { codegenNativeComponent } from 'react-native';
|
|
2
|
+
import type { ViewProps, HostComponent, ColorValue } from 'react-native';
|
|
3
|
+
import type { Double } from 'react-native/Libraries/Types/CodegenTypes';
|
|
4
|
+
|
|
5
|
+
export interface Coordinate {
|
|
6
|
+
latitude: Double;
|
|
7
|
+
longitude: Double;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export interface NativeProps extends ViewProps {
|
|
11
|
+
coordinates: ReadonlyArray<Coordinate>;
|
|
12
|
+
strokeColors?: ReadonlyArray<ColorValue>;
|
|
13
|
+
strokeWidth?: Double;
|
|
14
|
+
animated?: boolean;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export default codegenNativeComponent<NativeProps>(
|
|
18
|
+
'LuggMapsPolylineView'
|
|
19
|
+
) as HostComponent<NativeProps>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { codegenNativeComponent } from 'react-native';
|
|
2
|
+
import type { ViewProps, HostComponent } from 'react-native';
|
|
3
|
+
|
|
4
|
+
export interface NativeProps extends ViewProps {}
|
|
5
|
+
|
|
6
|
+
export default codegenNativeComponent<NativeProps>(
|
|
7
|
+
'LuggMapsWrapperView'
|
|
8
|
+
) as HostComponent<NativeProps>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["MapView","Marker","Polyline"],"sourceRoot":"../../src","sources":["index.ts"],"mappings":";;AAAA,SAASA,OAAO,QAAQ,cAAW;AACnC,SAASC,MAAM,QAAQ,aAAU;AACjC,SAASC,QAAQ,QAAQ,eAAY","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"type":"module"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../src","sources":["types.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"type":"module"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type ConfigPlugin } from '@expo/config-plugins';
|
|
2
|
+
export interface MapsPluginProps {
|
|
3
|
+
/**
|
|
4
|
+
* Google Maps API key for iOS.
|
|
5
|
+
* Required if using Google Maps provider on iOS.
|
|
6
|
+
*/
|
|
7
|
+
iosGoogleMapsApiKey?: string;
|
|
8
|
+
/**
|
|
9
|
+
* Google Maps API key for Android.
|
|
10
|
+
* Required for Android as it only supports Google Maps.
|
|
11
|
+
*/
|
|
12
|
+
androidGoogleMapsApiKey?: string;
|
|
13
|
+
}
|
|
14
|
+
declare const _default: ConfigPlugin<void | MapsPluginProps>;
|
|
15
|
+
export default _default;
|
|
16
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../plugin/src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAuB,MAAM,sBAAsB,CAAC;AAO9E,MAAM,WAAW,eAAe;IAC9B;;;OAGG;IACH,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAE7B;;;OAGG;IACH,uBAAuB,CAAC,EAAE,MAAM,CAAC;CAClC;;AAWD,wBAAoE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"withMapsAndroid.d.ts","sourceRoot":"","sources":["../../../../plugin/src/withMapsAndroid.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,KAAK,YAAY,EAElB,MAAM,sBAAsB,CAAC;AAE9B,MAAM,WAAW,sBAAsB;IACrC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,eAAO,MAAM,mBAAmB,EAAE,YAAY,CAAC,sBAAsB,CAqBpE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"withMapsIOS.d.ts","sourceRoot":"","sources":["../../../../plugin/src/withMapsIOS.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,YAAY,EAGlB,MAAM,sBAAsB,CAAC;AAE9B,MAAM,WAAW,kBAAkB;IACjC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,eAAO,MAAM,eAAe,EAAE,YAAY,CAAC,kBAAkB,CAoC5D,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { MapViewProps, MapViewRef, MoveCameraOptions, FitCoordinatesOptions } from './MapView.types';
|
|
3
|
+
import type { Coordinate } from './types';
|
|
4
|
+
export declare class MapView extends React.Component<MapViewProps> implements MapViewRef {
|
|
5
|
+
static defaultProps: Partial<MapViewProps>;
|
|
6
|
+
private nativeRef;
|
|
7
|
+
private get nativeCommands();
|
|
8
|
+
moveCamera(coordinate: Coordinate, options: MoveCameraOptions): void;
|
|
9
|
+
fitCoordinates(coordinates: Coordinate[], options?: FitCoordinatesOptions): void;
|
|
10
|
+
render(): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
}
|
|
12
|
+
//# sourceMappingURL=MapView.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MapView.d.ts","sourceRoot":"","sources":["../../../src/MapView.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAS1B,OAAO,KAAK,EACV,YAAY,EACZ,UAAU,EACV,iBAAiB,EACjB,qBAAqB,EACtB,MAAM,iBAAiB,CAAC;AACzB,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAE1C,qBAAa,OACX,SAAQ,KAAK,CAAC,SAAS,CAAC,YAAY,CACpC,YAAW,UAAU;IAErB,MAAM,CAAC,YAAY,EAAE,OAAO,CAAC,YAAY,CAAC,CAOxC;IAEF,OAAO,CAAC,SAAS,CAA0B;IAE3C,OAAO,KAAK,cAAc,GAIzB;IAED,UAAU,CAAC,UAAU,EAAE,UAAU,EAAE,OAAO,EAAE,iBAAiB;IAc7D,cAAc,CAAC,WAAW,EAAE,UAAU,EAAE,EAAE,OAAO,CAAC,EAAE,qBAAqB;IAgBzE,MAAM;CA0CP"}
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { NativeSyntheticEvent, ViewProps } from 'react-native';
|
|
3
|
+
import type { MapProvider, Coordinate, EdgeInsets } from './types';
|
|
4
|
+
/**
|
|
5
|
+
* Options for moving the camera
|
|
6
|
+
* @default duration -1
|
|
7
|
+
*/
|
|
8
|
+
export interface MoveCameraOptions {
|
|
9
|
+
zoom: number;
|
|
10
|
+
duration?: number;
|
|
11
|
+
}
|
|
12
|
+
/**
|
|
13
|
+
* Options for fitting coordinates in view
|
|
14
|
+
* @default padding 0
|
|
15
|
+
* @default duration -1
|
|
16
|
+
*/
|
|
17
|
+
export interface FitCoordinatesOptions {
|
|
18
|
+
padding?: number;
|
|
19
|
+
duration?: number;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* MapView ref methods
|
|
23
|
+
*/
|
|
24
|
+
export interface MapViewRef {
|
|
25
|
+
moveCamera(coordinate: Coordinate, options: MoveCameraOptions): void;
|
|
26
|
+
fitCoordinates(coordinates: Coordinate[], options?: FitCoordinatesOptions): void;
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* Camera move event data
|
|
30
|
+
*/
|
|
31
|
+
export interface CameraMoveEvent {
|
|
32
|
+
coordinate: Coordinate;
|
|
33
|
+
zoom: number;
|
|
34
|
+
dragging: boolean;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Camera idle event data
|
|
38
|
+
*/
|
|
39
|
+
export interface CameraIdleEvent {
|
|
40
|
+
coordinate: Coordinate;
|
|
41
|
+
zoom: number;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* MapView component props
|
|
45
|
+
*/
|
|
46
|
+
export interface MapViewProps extends ViewProps {
|
|
47
|
+
/**
|
|
48
|
+
* Map provider to use
|
|
49
|
+
* @default 'apple' on iOS, 'google' on Android
|
|
50
|
+
*/
|
|
51
|
+
provider?: MapProvider;
|
|
52
|
+
/**
|
|
53
|
+
* Map style ID (Google Maps) or configuration name (Apple Maps)
|
|
54
|
+
*/
|
|
55
|
+
mapId?: string;
|
|
56
|
+
/**
|
|
57
|
+
* Initial camera coordinate
|
|
58
|
+
*/
|
|
59
|
+
initialCoordinate?: Coordinate;
|
|
60
|
+
/**
|
|
61
|
+
* Initial zoom level
|
|
62
|
+
* @default 10
|
|
63
|
+
*/
|
|
64
|
+
initialZoom?: number;
|
|
65
|
+
/**
|
|
66
|
+
* Enable zoom gestures
|
|
67
|
+
* @default true
|
|
68
|
+
*/
|
|
69
|
+
zoomEnabled?: boolean;
|
|
70
|
+
/**
|
|
71
|
+
* Enable scroll/pan gestures
|
|
72
|
+
* @default true
|
|
73
|
+
*/
|
|
74
|
+
scrollEnabled?: boolean;
|
|
75
|
+
/**
|
|
76
|
+
* Enable rotation gestures
|
|
77
|
+
* @default true
|
|
78
|
+
*/
|
|
79
|
+
rotateEnabled?: boolean;
|
|
80
|
+
/**
|
|
81
|
+
* Enable pitch/tilt gestures
|
|
82
|
+
* @default true
|
|
83
|
+
*/
|
|
84
|
+
pitchEnabled?: boolean;
|
|
85
|
+
/**
|
|
86
|
+
* Map content padding
|
|
87
|
+
*/
|
|
88
|
+
padding?: EdgeInsets;
|
|
89
|
+
/**
|
|
90
|
+
* Called when camera moves
|
|
91
|
+
*/
|
|
92
|
+
onCameraMove?: (event: NativeSyntheticEvent<CameraMoveEvent>) => void;
|
|
93
|
+
/**
|
|
94
|
+
* Called when camera stops moving
|
|
95
|
+
*/
|
|
96
|
+
onCameraIdle?: (event: NativeSyntheticEvent<CameraIdleEvent>) => void;
|
|
97
|
+
/**
|
|
98
|
+
* Map children (markers, polylines, etc.)
|
|
99
|
+
*/
|
|
100
|
+
children?: ReactNode;
|
|
101
|
+
}
|
|
102
|
+
//# sourceMappingURL=MapView.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"MapView.types.d.ts","sourceRoot":"","sources":["../../../src/MapView.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AACvC,OA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