@lugg/maps 0.2.0-alpha.0 → 0.2.0-alpha.10
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/README.md +17 -4
- package/android/src/main/java/com/luggmaps/{LuggMapsGoogleMapView.kt → LuggGoogleMapView.kt} +111 -36
- package/android/src/main/java/com/luggmaps/{LuggMapsGoogleMapViewManager.kt → LuggGoogleMapViewManager.kt} +66 -39
- package/android/src/main/java/com/luggmaps/{LuggMapsWrapperView.kt → LuggMapWrapperView.kt} +1 -1
- package/android/src/main/java/com/luggmaps/LuggMapWrapperViewManager.kt +25 -0
- package/android/src/main/java/com/luggmaps/{LuggMapsMarkerView.kt → LuggMarkerView.kt} +13 -7
- package/android/src/main/java/com/luggmaps/{LuggMapsMarkerViewManager.kt → LuggMarkerViewManager.kt} +23 -17
- package/android/src/main/java/com/luggmaps/{LuggMapsPackage.kt → LuggPackage.kt} +2 -2
- package/android/src/main/java/com/luggmaps/{LuggMapsPolylineView.kt → LuggPolylineView.kt} +11 -4
- package/android/src/main/java/com/luggmaps/{LuggMapsPolylineViewManager.kt → LuggPolylineViewManager.kt} +22 -16
- package/android/src/main/java/com/luggmaps/core/PolylineAnimator.kt +89 -43
- package/android/src/main/java/com/luggmaps/events/CameraIdleEvent.kt +10 -2
- package/android/src/main/java/com/luggmaps/events/CameraMoveEvent.kt +6 -5
- package/android/src/main/java/com/luggmaps/events/ReadyEvent.kt +12 -0
- package/android/src/main/java/com/luggmaps/extensions/ViewExtensions.kt +14 -0
- package/ios/{LuggMapsAppleMapView.h → LuggAppleMapView.h} +2 -2
- package/ios/{LuggMapsAppleMapView.mm → LuggAppleMapView.mm} +140 -71
- package/ios/{LuggMapsGoogleMapView.h → LuggGoogleMapView.h} +1 -1
- package/ios/{LuggMapsGoogleMapView.mm → LuggGoogleMapView.mm} +82 -64
- package/ios/{LuggMapsWrapperView.h → LuggMapWrapperView.h} +1 -1
- package/ios/{LuggMapsWrapperView.mm → LuggMapWrapperView.mm} +7 -7
- package/ios/{LuggMapsMarkerView.h → LuggMarkerView.h} +8 -6
- package/ios/{LuggMapsMarkerView.mm → LuggMarkerView.mm} +21 -8
- package/ios/{LuggMapsPolylineView.h → LuggPolylineView.h} +6 -5
- package/ios/{LuggMapsPolylineView.mm → LuggPolylineView.mm} +14 -9
- package/ios/core/GMSPolylineAnimator.m +85 -36
- package/ios/core/MKPolylineAnimator.m +63 -32
- package/ios/events/CameraIdleEvent.h +6 -1
- package/ios/events/CameraMoveEvent.h +6 -3
- package/ios/events/ReadyEvent.h +20 -0
- package/lib/module/MapProvider.js +13 -0
- package/lib/module/MapProvider.js.map +1 -0
- package/lib/module/MapProvider.types.js +4 -0
- package/lib/module/MapProvider.types.js.map +1 -0
- package/lib/module/MapProvider.web.js +14 -0
- package/lib/module/MapProvider.web.js.map +1 -0
- package/lib/module/MapView.js +21 -7
- package/lib/module/MapView.js.map +1 -1
- package/lib/module/MapView.web.js +266 -0
- package/lib/module/MapView.web.js.map +1 -0
- package/lib/module/{Marker.js → components/Marker.js} +6 -3
- package/lib/module/components/Marker.js.map +1 -0
- package/lib/module/components/Marker.web.js +34 -0
- package/lib/module/components/Marker.web.js.map +1 -0
- package/lib/module/{Polyline.js → components/Polyline.js} +7 -4
- package/lib/module/components/Polyline.js.map +1 -0
- package/lib/module/components/Polyline.web.js +177 -0
- package/lib/module/components/Polyline.web.js.map +1 -0
- package/lib/module/components/index.js +5 -0
- package/lib/module/components/index.js.map +1 -0
- package/lib/module/components/index.web.js +5 -0
- package/lib/module/components/index.web.js.map +1 -0
- package/{src/fabric/LuggMapsAppleMapViewNativeComponent.ts → lib/module/fabric/LuggAppleMapViewNativeComponent.ts} +13 -3
- package/lib/module/fabric/{LuggMapsGoogleMapViewNativeComponent.ts → LuggGoogleMapViewNativeComponent.ts} +13 -3
- package/{src/fabric/LuggMapsWrapperViewNativeComponent.ts → lib/module/fabric/LuggMapWrapperViewNativeComponent.ts} +1 -1
- package/lib/module/fabric/{LuggMapsMarkerViewNativeComponent.ts → LuggMarkerViewNativeComponent.ts} +1 -1
- package/{src/fabric/LuggMapsPolylineViewNativeComponent.ts → lib/module/fabric/LuggPolylineViewNativeComponent.ts} +1 -1
- package/lib/module/index.js +3 -3
- package/lib/module/index.js.map +1 -1
- package/lib/module/index.web.js +6 -0
- package/lib/module/index.web.js.map +1 -0
- package/lib/typescript/plugin/src/withLuggMapsAndroid.d.ts +6 -0
- package/lib/typescript/plugin/src/withLuggMapsAndroid.d.ts.map +1 -0
- package/lib/typescript/plugin/src/withLuggMapsIOS.d.ts +6 -0
- package/lib/typescript/plugin/src/withLuggMapsIOS.d.ts.map +1 -0
- package/lib/typescript/src/MapProvider.d.ts +8 -0
- package/lib/typescript/src/MapProvider.d.ts.map +1 -0
- package/lib/typescript/src/MapProvider.types.d.ts +16 -0
- package/lib/typescript/src/MapProvider.types.d.ts.map +1 -0
- package/lib/typescript/src/MapProvider.web.d.ts +3 -0
- package/lib/typescript/src/MapProvider.web.d.ts.map +1 -0
- package/lib/typescript/src/MapView.d.ts.map +1 -1
- package/lib/typescript/src/MapView.types.d.ts +24 -14
- package/lib/typescript/src/MapView.types.d.ts.map +1 -1
- package/lib/typescript/src/MapView.web.d.ts +12 -0
- package/lib/typescript/src/MapView.web.d.ts.map +1 -0
- package/lib/typescript/src/{Marker.types.d.ts → components/Marker.d.ts} +10 -5
- package/lib/typescript/src/components/Marker.d.ts.map +1 -0
- package/lib/typescript/src/{Marker.d.ts → components/Marker.web.d.ts} +2 -2
- package/lib/typescript/src/components/Marker.web.d.ts.map +1 -0
- package/lib/typescript/src/{Polyline.types.d.ts → components/Polyline.d.ts} +10 -5
- package/lib/typescript/src/components/Polyline.d.ts.map +1 -0
- package/lib/typescript/src/components/Polyline.web.d.ts +6 -0
- package/lib/typescript/src/components/Polyline.web.d.ts.map +1 -0
- package/lib/typescript/src/components/index.d.ts +3 -0
- package/lib/typescript/src/components/index.d.ts.map +1 -0
- package/lib/typescript/src/components/index.web.d.ts +5 -0
- package/lib/typescript/src/components/index.web.d.ts.map +1 -0
- package/lib/typescript/src/fabric/{LuggMapsAppleMapViewNativeComponent.d.ts → LuggAppleMapViewNativeComponent.d.ts} +10 -3
- package/lib/typescript/src/fabric/LuggAppleMapViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/{LuggMapsGoogleMapViewNativeComponent.d.ts → LuggGoogleMapViewNativeComponent.d.ts} +10 -3
- package/lib/typescript/src/fabric/LuggGoogleMapViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/{LuggMapsWrapperViewNativeComponent.d.ts → LuggMapWrapperViewNativeComponent.d.ts} +1 -1
- package/lib/typescript/src/fabric/LuggMapWrapperViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/{LuggMapsMarkerViewNativeComponent.d.ts → LuggMarkerViewNativeComponent.d.ts} +1 -1
- package/lib/typescript/src/fabric/LuggMarkerViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/fabric/{LuggMapsPolylineViewNativeComponent.d.ts → LuggPolylineViewNativeComponent.d.ts} +1 -1
- package/lib/typescript/src/fabric/LuggPolylineViewNativeComponent.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +5 -6
- package/lib/typescript/src/index.d.ts.map +1 -1
- package/lib/typescript/src/index.web.d.ts +7 -0
- package/lib/typescript/src/index.web.d.ts.map +1 -0
- package/package.json +20 -7
- package/plugin/build/index.js +4 -4
- package/{lib/typescript/plugin/src/withMapsAndroid.d.ts → plugin/build/withLuggMapsAndroid.d.ts} +0 -1
- package/plugin/build/withLuggMapsAndroid.js +15 -0
- package/{lib/typescript/plugin/src/withMapsIOS.d.ts → plugin/build/withLuggMapsIOS.d.ts} +0 -1
- package/plugin/build/withLuggMapsIOS.js +27 -0
- package/plugin/build/withMapsAndroid.d.ts +1 -1
- package/plugin/build/withMapsIOS.d.ts +1 -1
- package/src/MapProvider.tsx +10 -0
- package/src/MapProvider.types.ts +16 -0
- package/src/MapProvider.web.tsx +6 -0
- package/src/MapView.tsx +27 -10
- package/src/MapView.types.ts +24 -15
- package/src/MapView.web.tsx +319 -0
- package/src/components/Marker.tsx +63 -0
- package/src/components/Marker.web.tsx +32 -0
- package/src/components/Polyline.tsx +57 -0
- package/src/components/Polyline.web.tsx +222 -0
- package/src/components/index.ts +2 -0
- package/src/components/index.web.ts +4 -0
- package/{lib/module/fabric/LuggMapsAppleMapViewNativeComponent.ts → src/fabric/LuggAppleMapViewNativeComponent.ts} +13 -3
- package/src/fabric/{LuggMapsGoogleMapViewNativeComponent.ts → LuggGoogleMapViewNativeComponent.ts} +13 -3
- package/{lib/module/fabric/LuggMapsWrapperViewNativeComponent.ts → src/fabric/LuggMapWrapperViewNativeComponent.ts} +1 -1
- package/src/fabric/{LuggMapsMarkerViewNativeComponent.ts → LuggMarkerViewNativeComponent.ts} +1 -1
- package/{lib/module/fabric/LuggMapsPolylineViewNativeComponent.ts → src/fabric/LuggPolylineViewNativeComponent.ts} +1 -1
- package/src/index.ts +11 -7
- package/src/index.web.ts +17 -0
- package/android/src/main/java/com/luggmaps/LuggMapsWrapperViewManager.kt +0 -25
- package/lib/module/Marker.js.map +0 -1
- package/lib/module/Marker.types.js +0 -4
- package/lib/module/Marker.types.js.map +0 -1
- package/lib/module/Polyline.js.map +0 -1
- package/lib/module/Polyline.types.js +0 -4
- package/lib/module/Polyline.types.js.map +0 -1
- package/lib/typescript/plugin/src/withMapsAndroid.d.ts.map +0 -1
- package/lib/typescript/plugin/src/withMapsIOS.d.ts.map +0 -1
- package/lib/typescript/src/Marker.d.ts.map +0 -1
- package/lib/typescript/src/Marker.types.d.ts.map +0 -1
- package/lib/typescript/src/Polyline.d.ts +0 -6
- package/lib/typescript/src/Polyline.d.ts.map +0 -1
- package/lib/typescript/src/Polyline.types.d.ts.map +0 -1
- package/lib/typescript/src/fabric/LuggMapsAppleMapViewNativeComponent.d.ts.map +0 -1
- package/lib/typescript/src/fabric/LuggMapsGoogleMapViewNativeComponent.d.ts.map +0 -1
- package/lib/typescript/src/fabric/LuggMapsMarkerViewNativeComponent.d.ts.map +0 -1
- package/lib/typescript/src/fabric/LuggMapsPolylineViewNativeComponent.d.ts.map +0 -1
- package/lib/typescript/src/fabric/LuggMapsWrapperViewNativeComponent.d.ts.map +0 -1
- package/src/Marker.tsx +0 -31
- package/src/Marker.types.ts +0 -32
- package/src/Polyline.tsx +0 -32
- package/src/Polyline.types.ts +0 -24
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"LuggMapsWrapperViewNativeComponent.d.ts","sourceRoot":"","sources":["../../../../src/fabric/LuggMapsWrapperViewNativeComponent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,SAAS,EAAE,aAAa,EAAE,MAAM,cAAc,CAAC;AAE7D,MAAM,WAAW,WAAY,SAAQ,SAAS;CAAG;wBAI5C,aAAa,CAAC,WAAW,CAAC;AAF/B,wBAEgC"}
|
package/src/Marker.tsx
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import LuggMapsMarkerViewNativeComponent from './fabric/LuggMapsMarkerViewNativeComponent';
|
|
3
|
-
import type { MarkerProps } from './Marker.types';
|
|
4
|
-
import { StyleSheet } from 'react-native';
|
|
5
|
-
|
|
6
|
-
export class Marker extends React.Component<MarkerProps> {
|
|
7
|
-
render() {
|
|
8
|
-
const { name, coordinate, title, description, anchor, children } =
|
|
9
|
-
this.props;
|
|
10
|
-
|
|
11
|
-
return (
|
|
12
|
-
<LuggMapsMarkerViewNativeComponent
|
|
13
|
-
style={styles.marker}
|
|
14
|
-
name={name}
|
|
15
|
-
coordinate={coordinate}
|
|
16
|
-
title={title}
|
|
17
|
-
description={description}
|
|
18
|
-
anchor={anchor}
|
|
19
|
-
>
|
|
20
|
-
{children}
|
|
21
|
-
</LuggMapsMarkerViewNativeComponent>
|
|
22
|
-
);
|
|
23
|
-
}
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
const styles = StyleSheet.create({
|
|
27
|
-
marker: {
|
|
28
|
-
position: 'absolute',
|
|
29
|
-
pointerEvents: 'box-none',
|
|
30
|
-
},
|
|
31
|
-
});
|
package/src/Marker.types.ts
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import type { ReactNode } from 'react';
|
|
2
|
-
import type { Coordinate, Point } from './types';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Marker component props
|
|
6
|
-
*/
|
|
7
|
-
export interface MarkerProps {
|
|
8
|
-
/**
|
|
9
|
-
* Name used for debugging purposes
|
|
10
|
-
*/
|
|
11
|
-
name?: string;
|
|
12
|
-
/**
|
|
13
|
-
* Marker position
|
|
14
|
-
*/
|
|
15
|
-
coordinate: Coordinate;
|
|
16
|
-
/**
|
|
17
|
-
* Callout title
|
|
18
|
-
*/
|
|
19
|
-
title?: string;
|
|
20
|
-
/**
|
|
21
|
-
* Callout description
|
|
22
|
-
*/
|
|
23
|
-
description?: string;
|
|
24
|
-
/**
|
|
25
|
-
* Anchor point for custom marker views
|
|
26
|
-
*/
|
|
27
|
-
anchor?: Point;
|
|
28
|
-
/**
|
|
29
|
-
* Custom marker view
|
|
30
|
-
*/
|
|
31
|
-
children?: ReactNode;
|
|
32
|
-
}
|
package/src/Polyline.tsx
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import LuggMapsPolylineViewNativeComponent from './fabric/LuggMapsPolylineViewNativeComponent';
|
|
3
|
-
import type { PolylineProps } from './Polyline.types';
|
|
4
|
-
import { StyleSheet } from 'react-native';
|
|
5
|
-
|
|
6
|
-
export class Polyline extends React.Component<PolylineProps> {
|
|
7
|
-
render() {
|
|
8
|
-
const {
|
|
9
|
-
coordinates,
|
|
10
|
-
strokeColors,
|
|
11
|
-
strokeWidth,
|
|
12
|
-
animated = false,
|
|
13
|
-
} = this.props;
|
|
14
|
-
|
|
15
|
-
return (
|
|
16
|
-
<LuggMapsPolylineViewNativeComponent
|
|
17
|
-
style={styles.polyline}
|
|
18
|
-
coordinates={coordinates}
|
|
19
|
-
strokeColors={strokeColors}
|
|
20
|
-
strokeWidth={strokeWidth}
|
|
21
|
-
animated={animated}
|
|
22
|
-
/>
|
|
23
|
-
);
|
|
24
|
-
}
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
const styles = StyleSheet.create({
|
|
28
|
-
polyline: {
|
|
29
|
-
position: 'absolute',
|
|
30
|
-
pointerEvents: 'none',
|
|
31
|
-
},
|
|
32
|
-
});
|
package/src/Polyline.types.ts
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import type { ColorValue } from 'react-native';
|
|
2
|
-
import type { Coordinate } from './types';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Polyline component props
|
|
6
|
-
*/
|
|
7
|
-
export interface PolylineProps {
|
|
8
|
-
/**
|
|
9
|
-
* Array of coordinates forming the polyline
|
|
10
|
-
*/
|
|
11
|
-
coordinates: Coordinate[];
|
|
12
|
-
/**
|
|
13
|
-
* Gradient colors along the polyline
|
|
14
|
-
*/
|
|
15
|
-
strokeColors?: ColorValue[];
|
|
16
|
-
/**
|
|
17
|
-
* Line width in points
|
|
18
|
-
*/
|
|
19
|
-
strokeWidth?: number;
|
|
20
|
-
/**
|
|
21
|
-
* Animate the polyline with a snake effect
|
|
22
|
-
*/
|
|
23
|
-
animated?: boolean;
|
|
24
|
-
}
|