@rnmapbox/maps 10.0.0-beta.72 → 10.0.0-beta.74
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/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/RCTMGLPackage.java +2 -0
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/annotation/RCTMGLPointAnnotation.kt +0 -1
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/images/RCTMGLImage.kt +74 -0
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/images/RCTMGLImageManager.kt +67 -0
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/images/RCTMGLImages.kt +62 -35
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/images/RCTMGLImagesManager.kt +216 -0
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/location/LocationComponentManager.kt +4 -2
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/styles/layers/RCTLayer.kt +9 -3
- package/index.d.ts +22 -74
- package/javascript/components/AbstractLayer.tsx +2 -1
- package/javascript/components/AbstractSource.tsx +3 -1
- package/javascript/components/Atmosphere.tsx +2 -1
- package/javascript/components/Camera.tsx +6 -4
- package/javascript/components/Image.tsx +12 -4
- package/javascript/components/Images.tsx +1 -1
- package/javascript/components/Light.tsx +60 -0
- package/javascript/components/PointAnnotation.tsx +2 -1
- package/javascript/components/ShapeSource.tsx +1 -11
- package/javascript/components/Terrain.tsx +2 -1
- package/javascript/components/VectorSource.tsx +209 -0
- package/javascript/components/annotations/Annotation.js +9 -10
- package/javascript/modules/location/locationManager.ts +2 -2
- package/javascript/types/BaseProps.ts +3 -0
- package/javascript/types/OnPressEvent.ts +11 -0
- package/javascript/utils/{Logger.js → Logger.ts} +32 -14
- package/javascript/utils/MapboxStyles.d.ts +1 -1
- package/javascript/utils/deprecation.ts +3 -3
- package/javascript/utils/nativeRef.ts +28 -0
- package/lib/commonjs/components/AbstractLayer.js.map +1 -1
- package/lib/commonjs/components/AbstractSource.js.map +1 -1
- package/lib/commonjs/components/Atmosphere.js.map +1 -1
- package/lib/commonjs/components/Camera.js +4 -4
- package/lib/commonjs/components/Camera.js.map +1 -1
- package/lib/commonjs/components/Image.js.map +1 -1
- package/lib/commonjs/components/Images.js +1 -1
- package/lib/commonjs/components/Images.js.map +1 -1
- package/lib/commonjs/components/Light.js +32 -33
- package/lib/commonjs/components/Light.js.map +1 -1
- package/lib/commonjs/components/PointAnnotation.js.map +1 -1
- package/lib/commonjs/components/ShapeSource.js.map +1 -1
- package/lib/commonjs/components/Terrain.js.map +1 -1
- package/lib/commonjs/components/VectorSource.js +15 -74
- package/lib/commonjs/components/VectorSource.js.map +1 -1
- package/lib/commonjs/components/annotations/Annotation.js +6 -9
- package/lib/commonjs/components/annotations/Annotation.js.map +1 -1
- package/lib/commonjs/modules/location/locationManager.js +2 -1
- package/lib/commonjs/modules/location/locationManager.js.map +1 -1
- package/lib/commonjs/types/BaseProps.js +2 -0
- package/lib/commonjs/types/BaseProps.js.map +1 -0
- package/lib/commonjs/types/OnPressEvent.js +2 -0
- package/lib/commonjs/types/OnPressEvent.js.map +1 -0
- package/lib/commonjs/utils/Logger.js +7 -7
- package/lib/commonjs/utils/Logger.js.map +1 -1
- package/lib/commonjs/utils/deprecation.js +2 -2
- package/lib/commonjs/utils/nativeRef.js +27 -0
- package/lib/commonjs/utils/nativeRef.js.map +1 -0
- package/lib/module/components/AbstractLayer.js.map +1 -1
- package/lib/module/components/AbstractSource.js.map +1 -1
- package/lib/module/components/Atmosphere.js.map +1 -1
- package/lib/module/components/Camera.js +4 -4
- package/lib/module/components/Camera.js.map +1 -1
- package/lib/module/components/Image.js.map +1 -1
- package/lib/module/components/Images.js +1 -1
- package/lib/module/components/Images.js.map +1 -1
- package/lib/module/components/Light.js +29 -32
- package/lib/module/components/Light.js.map +1 -1
- package/lib/module/components/PointAnnotation.js.map +1 -1
- package/lib/module/components/ShapeSource.js.map +1 -1
- package/lib/module/components/Terrain.js.map +1 -1
- package/lib/module/components/VectorSource.js +15 -74
- package/lib/module/components/VectorSource.js.map +1 -1
- package/lib/module/components/annotations/Annotation.js +6 -9
- package/lib/module/components/annotations/Annotation.js.map +1 -1
- package/lib/module/modules/location/locationManager.js +1 -1
- package/lib/module/modules/location/locationManager.js.map +1 -1
- package/lib/module/types/BaseProps.js +2 -0
- package/lib/module/types/BaseProps.js.map +1 -0
- package/lib/module/types/OnPressEvent.js +2 -0
- package/lib/module/types/OnPressEvent.js.map +1 -0
- package/lib/module/utils/Logger.js +7 -7
- package/lib/module/utils/Logger.js.map +1 -1
- package/lib/module/utils/deprecation.js +2 -2
- package/lib/module/utils/nativeRef.js +21 -0
- package/lib/module/utils/nativeRef.js.map +1 -0
- package/lib/typescript/components/AbstractLayer.d.ts +2 -1
- package/lib/typescript/components/AbstractLayer.d.ts.map +1 -1
- package/lib/typescript/components/AbstractSource.d.ts +2 -1
- package/lib/typescript/components/AbstractSource.d.ts.map +1 -1
- package/lib/typescript/components/Atmosphere.d.ts +2 -1
- package/lib/typescript/components/Atmosphere.d.ts.map +1 -1
- package/lib/typescript/components/Camera.d.ts.map +1 -1
- package/lib/typescript/components/Image.d.ts +10 -4
- package/lib/typescript/components/Image.d.ts.map +1 -1
- package/lib/typescript/components/Images.d.ts +1 -1
- package/lib/typescript/components/Images.d.ts.map +1 -1
- package/lib/typescript/components/Light.d.ts +17 -0
- package/lib/typescript/components/Light.d.ts.map +1 -0
- package/lib/typescript/components/PointAnnotation.d.ts +2 -1
- package/lib/typescript/components/PointAnnotation.d.ts.map +1 -1
- package/lib/typescript/components/ShapeSource.d.ts +3 -13
- package/lib/typescript/components/ShapeSource.d.ts.map +1 -1
- package/lib/typescript/components/Terrain.d.ts +2 -1
- package/lib/typescript/components/Terrain.d.ts.map +1 -1
- package/lib/typescript/components/VectorSource.d.ts +144 -0
- package/lib/typescript/components/VectorSource.d.ts.map +1 -0
- package/lib/typescript/modules/location/locationManager.d.ts +2 -2
- package/lib/typescript/modules/location/locationManager.d.ts.map +1 -1
- package/lib/typescript/types/BaseProps.d.ts +4 -0
- package/lib/typescript/types/BaseProps.d.ts.map +1 -0
- package/lib/typescript/types/OnPressEvent.d.ts +12 -0
- package/lib/typescript/types/OnPressEvent.d.ts.map +1 -0
- package/lib/typescript/utils/Logger.d.ts +53 -0
- package/lib/typescript/utils/Logger.d.ts.map +1 -0
- package/lib/typescript/utils/deprecation.d.ts +4 -3
- package/lib/typescript/utils/deprecation.d.ts.map +1 -1
- package/lib/typescript/utils/nativeRef.d.ts +21 -0
- package/lib/typescript/utils/nativeRef.d.ts.map +1 -0
- package/package.json +1 -1
- package/android/rctmgl/src/main/java-v10/com/mapbox/rctmgl/components/images/RCTMGLImagesManager.java +0 -103
- package/javascript/components/Light.js +0 -47
- package/javascript/components/VectorSource.js +0 -203
|
@@ -1,14 +1,20 @@
|
|
|
1
1
|
import React, { ReactElement } from 'react';
|
|
2
2
|
interface Props {
|
|
3
|
-
/**
|
|
3
|
+
/** ID of the image */
|
|
4
4
|
name: string;
|
|
5
5
|
/** Make image an sdf optional - see [SDF icons](https://docs.mapbox.com/help/troubleshooting/using-recolorable-images-in-mapbox-maps/) */
|
|
6
6
|
sdf?: boolean;
|
|
7
|
-
/**
|
|
7
|
+
/** An array of two-element arrays, consisting of two numbers that represent, the from position and the to position of areas that can be stretched horizontally. */
|
|
8
8
|
stretchX?: [number, number][];
|
|
9
|
-
/**
|
|
9
|
+
/** An array of two-element arrays, consisting of two numbers that represent, the from position and the to position of areas that can be stretched vertically. */
|
|
10
10
|
stretchY?: [number, number][];
|
|
11
|
-
/**
|
|
11
|
+
/** An array of four numbers, with the first two specifying the left, top
|
|
12
|
+
* corner, and the last two specifying the right, bottom corner. If present, and if the
|
|
13
|
+
* icon uses icon-text-fit, the symbol's text will be fit inside the content box. */
|
|
14
|
+
content?: [number, number, number, number];
|
|
15
|
+
/** Scale factor for the image. */
|
|
16
|
+
scale?: number;
|
|
17
|
+
/** Single react native view rendering the image */
|
|
12
18
|
children: ReactElement;
|
|
13
19
|
}
|
|
14
20
|
interface Ref {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Image.d.ts","sourceRoot":"","sources":["../../../javascript/components/Image.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAoB,YAAY,EAAE,MAAM,OAAO,CAAC;AAG9D,UAAU,KAAK;IACb,
|
|
1
|
+
{"version":3,"file":"Image.d.ts","sourceRoot":"","sources":["../../../javascript/components/Image.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAoB,YAAY,EAAE,MAAM,OAAO,CAAC;AAG9D,UAAU,KAAK;IACb,sBAAsB;IACtB,IAAI,EAAE,MAAM,CAAC;IAEb,0IAA0I;IAC1I,GAAG,CAAC,EAAE,OAAO,CAAC;IAEd,mKAAmK;IACnK,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,CAAC;IAE9B,iKAAiK;IACjK,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,CAAC;IAE9B;;wFAEoF;IACpF,OAAO,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;IAE3C,kCAAkC;IAClC,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf,mDAAmD;IACnD,QAAQ,EAAE,YAAY,CAAC;CACxB;AAED,UAAU,GAAG;IACX,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,QAAA,MAAM,KAAK,8FAcV,CAAC;AAUF,eAAO,MAAM,kBAAkB,gBAAgB,CAAC;AAMhD,eAAe,KAAK,CAAC"}
|
|
@@ -41,7 +41,7 @@ interface Props {
|
|
|
41
41
|
/**
|
|
42
42
|
* Images defines the images used in Symbol etc. layers.
|
|
43
43
|
*/
|
|
44
|
-
declare class Images extends React.
|
|
44
|
+
declare class Images extends React.PureComponent<Props> {
|
|
45
45
|
static NATIVE_ASSETS_KEY: string;
|
|
46
46
|
_getImages(): {
|
|
47
47
|
images?: undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Images.d.ts","sourceRoot":"","sources":["../../../javascript/components/Images.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAa,YAAY,EAAE,MAAM,OAAO,CAAC;AAEvD,OAAO,EAAE,mBAAmB,EAAE,wBAAwB,EAAE,MAAM,cAAc,CAAC;AAG7E,OAAO,KAAK,MAAM,SAAS,CAAC;AAE5B,eAAO,MAAM,kBAAkB,iBAAiB,CAAC;AAEjD,oBAAY,SAAS,CAAC,WAAW,GAAG;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAAA;CAAE,IAAI;IAC/D,OAAO,EAAE,WAAW,CAAC;IACrB,IAAI,EAAE,MAAM,CAAC;CACd,CAAC;AAcF,aAAK,cAAc,CAAC,CAAC,IAAI,YAAY,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC;AAE5E,aAAK,WAAW,GACZ,MAAM,GACN;IACE,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,CAAC;IAC9B,QAAQ,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,CAAC;CAC/B,CAAC;AAQN,UAAU,KAAK;IACb;;;;OAIG;IACH,MAAM,CAAC,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,mBAAmB,CAAA;KAAE,CAAC;IAEhD;;;;OAIG;IACH,iBAAiB,CAAC,EAAE,WAAW,EAAE,CAAC;IAElC;;;OAGG;IACH,cAAc,CAAC,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;IAE5C,EAAE,CAAC,EAAE,MAAM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AC,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,cAAc,CAAC,OAAO,KAAK,CAAC,CAAC;CACzC;AAED;;GAEG;AACH,cAAM,MAAO,SAAQ,KAAK,CAAC,aAAa,CAAC,KAAK,CAAC;IAC7C,MAAM,CAAC,iBAAiB,SAAY;IAEpC,UAAU;;;;;;;;;IAsDV,eAAe,CAAC,KAAK,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,EAAE,SAAS,CAAC;IAM/D,MAAM;CAUP;AAWD,eAAe,MAAM,CAAC"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { LightLayerStyleProps } from '../utils/MapboxStyles';
|
|
3
|
+
import { type BaseProps } from '../types/BaseProps';
|
|
4
|
+
export declare const NATIVE_MODULE_NAME = "RCTMGLLight";
|
|
5
|
+
interface LightMethods {
|
|
6
|
+
setNativeProps(props: {
|
|
7
|
+
[key: string]: unknown;
|
|
8
|
+
}): void;
|
|
9
|
+
}
|
|
10
|
+
declare const _default: React.MemoExoticComponent<React.ForwardRefExoticComponent<BaseProps & {
|
|
11
|
+
/**
|
|
12
|
+
* Customizable style attributes
|
|
13
|
+
*/
|
|
14
|
+
style: LightLayerStyleProps;
|
|
15
|
+
} & React.RefAttributes<LightMethods>>>;
|
|
16
|
+
export default _default;
|
|
17
|
+
//# sourceMappingURL=Light.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Light.d.ts","sourceRoot":"","sources":["../../../javascript/components/Light.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwD,MAAM,OAAO,CAAC;AAG7E,OAAO,EAAE,oBAAoB,EAAE,MAAM,uBAAuB,CAAC;AAE7D,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAIpD,eAAO,MAAM,kBAAkB,gBAAgB,CAAC;AAahD,UAAU,YAAY;IACpB,cAAc,CAAC,KAAK,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAA;KAAE,GAAG,IAAI,CAAC;CACzD;;IAZC;;OAEG;;;AA6CL,wBAAuC"}
|
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import React, { SyntheticEvent, type Component } from 'react';
|
|
2
2
|
import { type ViewProps } from 'react-native';
|
|
3
3
|
import { type Feature } from 'geojson';
|
|
4
|
+
import { type BaseProps } from '../types/BaseProps';
|
|
4
5
|
import { type RNMBEvent } from './NativeBridgeComponent';
|
|
5
6
|
export declare const NATIVE_MODULE_NAME = "RCTMGLPointAnnotation";
|
|
6
7
|
declare type FeaturePayload = {
|
|
7
8
|
feature: Feature;
|
|
8
9
|
};
|
|
9
|
-
declare type Props = {
|
|
10
|
+
declare type Props = BaseProps & {
|
|
10
11
|
/**
|
|
11
12
|
* A string that uniquely identifies the annotation
|
|
12
13
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PointAnnotation.d.ts","sourceRoot":"","sources":["../../../javascript/components/PointAnnotation.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,cAAc,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAC9D,OAAO,EAIL,KAAK,SAAS,EACf,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,SAAS,CAAC;
|
|
1
|
+
{"version":3,"file":"PointAnnotation.d.ts","sourceRoot":"","sources":["../../../javascript/components/PointAnnotation.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,cAAc,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAC9D,OAAO,EAIL,KAAK,SAAS,EACf,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,SAAS,CAAC;AAIvC,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAEpD,OAA8B,EAAE,KAAK,SAAS,EAAE,MAAM,yBAAyB,C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CAAC,YAAY;;;;;;MAGjB;IAEF,UAAU,EAAE,wBAAwB,GAAG,IAAI,CAAQ;gBAEvC,KAAK,EAAE,KAAK;IASxB,WAAW,CAAC,CAAC,EAAE,cAAc,CAAC,OAAO,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC;IAMjE,aAAa,CAAC,CAAC,EAAE,cAAc,CAAC,OAAO,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC;IAMnE,YAAY,CAAC,CAAC,EAAE,cAAc,CAAC,OAAO,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC;IAMlE,OAAO,CAAC,CAAC,EAAE,cAAc,CAAC,OAAO,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC;IAM7D,UAAU,CAAC,CAAC,EAAE,cAAc,CAAC,OAAO,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC;IAMhE,cAAc,IAAI,MAAM,GAAG,SAAS;IAOpC;;;;OAIG;IACH,OAAO;IAQP,aAAa,CAAC,SAAS,EAAE,wBAAwB,GAAG,IAAI;IAKxD,MAAM;CAyBP;AACD,aAAK,WAAW,GAAG,IAAI,CAAC,KAAK,EAAE,YAAY,CAAC,GAAG;IAC7C,UAAU,EAAE,MAAM,GAAG,SAAS,CAAC;CAChC,CAAC;AAEF,aAAK,wBAAwB,GAAG,SAAS,CAAC,WAAW,CAAC,CAAC;AAKvD,eAAe,eAAe,CAAC"}
|
|
@@ -1,18 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { NativeMethods, NativeSyntheticEvent } from 'react-native';
|
|
3
|
+
import { OnPressEvent } from '../types/OnPressEvent';
|
|
3
4
|
import AbstractSource from './AbstractSource';
|
|
4
5
|
export declare const NATIVE_MODULE_NAME = "RCTMGLShapeSource";
|
|
5
|
-
export declare type OnPressEvent = {
|
|
6
|
-
features: Array<GeoJSON.Feature>;
|
|
7
|
-
coordinates: {
|
|
8
|
-
latitude: number;
|
|
9
|
-
longitude: number;
|
|
10
|
-
};
|
|
11
|
-
point: {
|
|
12
|
-
x: number;
|
|
13
|
-
y: number;
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
6
|
export declare type Props = {
|
|
17
7
|
/**
|
|
18
8
|
* A string that uniquely identifies the source.
|
|
@@ -149,8 +139,8 @@ declare const ShapeSource_base: {
|
|
|
149
139
|
UNSAFE_componentWillUpdate?(nextProps: object, nextState: Readonly<{}>, nextContext: any): void;
|
|
150
140
|
};
|
|
151
141
|
} & {
|
|
152
|
-
new (props: Props | Readonly<Props>): AbstractSource<Props, NativeProps>;
|
|
153
|
-
new (props: Props, context: any): AbstractSource<Props, NativeProps>;
|
|
142
|
+
new (props: (Props & import("../types/BaseProps").BaseProps) | Readonly<Props & import("../types/BaseProps").BaseProps>): AbstractSource<Props, NativeProps>;
|
|
143
|
+
new (props: Props & import("../types/BaseProps").BaseProps, context: any): AbstractSource<Props, NativeProps>;
|
|
154
144
|
contextType?: React.Context<any> | undefined;
|
|
155
145
|
};
|
|
156
146
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ShapeSource.d.ts","sourceRoot":"","sources":["../../../javascript/components/ShapeSource.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,aAAa,EAEb,oBAAoB,EAErB,MAAM,cAAc,CAAC;
|
|
1
|
+
{"version":3,"file":"ShapeSource.d.ts","sourceRoot":"","sources":["../../../javascript/components/ShapeSource.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,aAAa,EAEb,oBAAoB,EAErB,MAAM,cAAc,CAAC;AAUtB,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAErD,OAAO,cAAc,MAAM,kBAAkB,CAAC;AAK9C,eAAO,MAAM,kBAAkB,sBAAsB,CAAC;AAMtD,oBAAY,KAAK,GAAG;IAClB;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;I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M,GAAE,KAAK,CAAC,MAAM,CAAM;IAczC;;;;;;;;OAQG;IACG,uBAAuB,CAC3B,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,GAChC,OAAO,CAAC,MAAM,CAAC;IAqBlB;;;;;;;;;;OAUG;IACG,gBAAgB,CACpB,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,EACjC,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM;IAgChB;;;;;;;;OAQG;IACG,kBAAkB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO;IA+B1D,cAAc,CAAC,KAAK,EAAE,WAAW;IAWjC,SAAS;IAOT,OAAO,CACL,KAAK,EAAE,oBAAoB,CAAC;QAC1B,OAAO,EAAE,YAAY,CAAC;KACvB,CAAC;IA+BJ,MAAM;CA+BP;AAED,aAAK,WAAW,GAAG;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB,CAAC"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { TerrainLayerStyleProps, Value } from '../utils/MapboxStyles';
|
|
3
|
+
import type { BaseProps } from '../types/BaseProps';
|
|
3
4
|
export declare const NATIVE_MODULE_NAME = "RCTMGLTerrain";
|
|
4
|
-
declare type Props = {
|
|
5
|
+
declare type Props = BaseProps & {
|
|
5
6
|
/**
|
|
6
7
|
* Name of a source of raster_dem type to be used for terrain elevation.
|
|
7
8
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Terrain.d.ts","sourceRoot":"","sources":["../../../javascript/components/Terrain.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAC;AAG7C,OAAO,KAAK,EAAE,sBAAsB,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"Terrain.d.ts","sourceRoot":"","sources":["../../../javascript/components/Terrain.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAwB,MAAM,OAAO,CAAC;AAG7C,OAAO,KAAK,EAAE,sBAAsB,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAE3E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,oBAAoB,CAAC;AAEpD,eAAO,MAAM,kBAAkB,kBAAkB,CAAC;AAElD,aAAK,KAAK,GAAG,SAAS,GAAG;IACvB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,YAAY,CAAC,EAAE,KAAK,CAAC,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC;IAEvC;;OAEG;IACH,KAAK,EAAE,sBAAsB,CAAC;CAC/B,CAAC;AAEF,eAAO,MAAM,OAAO,oCAAgB,KAAK,iBAoBvC,CAAC"}
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { NativeMethods, NativeSyntheticEvent } from 'react-native';
|
|
3
|
+
import { OnPressEvent } from '../types/OnPressEvent';
|
|
4
|
+
import AbstractSource from './AbstractSource';
|
|
5
|
+
export declare const NATIVE_MODULE_NAME = "RCTMGLVectorSource";
|
|
6
|
+
interface Props {
|
|
7
|
+
/**
|
|
8
|
+
* A string that uniquely identifies the source.
|
|
9
|
+
*/
|
|
10
|
+
id: string;
|
|
11
|
+
/**
|
|
12
|
+
* A URL to a TileJSON configuration file describing the source’s contents and other metadata.
|
|
13
|
+
*/
|
|
14
|
+
url?: string;
|
|
15
|
+
/**
|
|
16
|
+
* An array of tile URL templates. If multiple endpoints are specified, clients may use any combination of endpoints.
|
|
17
|
+
* Example: https://example.com/vector-tiles/{z}/{x}/{y}.pbf
|
|
18
|
+
*/
|
|
19
|
+
tileUrlTemplates?: string[];
|
|
20
|
+
/**
|
|
21
|
+
* An unsigned integer that specifies the minimum zoom level at which to display tiles from the source.
|
|
22
|
+
* The value should be between 0 and 22, inclusive, and less than
|
|
23
|
+
* maxZoomLevel, if specified. The default value for this option is 0.
|
|
24
|
+
*/
|
|
25
|
+
minZoomLevel?: number;
|
|
26
|
+
/**
|
|
27
|
+
* An unsigned integer that specifies the maximum zoom level at which to display tiles from the source.
|
|
28
|
+
* The value should be between 0 and 22, inclusive, and less than
|
|
29
|
+
* minZoomLevel, if specified. The default value for this option is 22.
|
|
30
|
+
*/
|
|
31
|
+
maxZoomLevel?: number;
|
|
32
|
+
/**
|
|
33
|
+
* Influences the y direction of the tile coordinates. (tms inverts y axis)
|
|
34
|
+
*/
|
|
35
|
+
tms?: boolean;
|
|
36
|
+
/**
|
|
37
|
+
* An HTML or literal text string defining the buttons to be displayed in an action sheet when the
|
|
38
|
+
* source is part of a map view’s style and the map view’s attribution button is pressed.
|
|
39
|
+
*/
|
|
40
|
+
attribution?: string;
|
|
41
|
+
/**
|
|
42
|
+
* Source press listener, gets called when a user presses one of the children layers only
|
|
43
|
+
* if that layer has a higher z-index than another source layers
|
|
44
|
+
*
|
|
45
|
+
* @param {Object} event
|
|
46
|
+
* @param {Object[]} event.features - the geojson features that have hit by the press (might be multiple)
|
|
47
|
+
* @param {Object} event.coordinates - the coordinates of the click
|
|
48
|
+
* @param {Object} event.point - the point of the click
|
|
49
|
+
*/
|
|
50
|
+
onPress?: (event: OnPressEvent) => void;
|
|
51
|
+
/**
|
|
52
|
+
* Overrides the default touch hitbox(44x44 pixels) for the source layers
|
|
53
|
+
*/
|
|
54
|
+
hitbox?: {
|
|
55
|
+
/**
|
|
56
|
+
* `width` of hitbox
|
|
57
|
+
*/
|
|
58
|
+
width: number;
|
|
59
|
+
/**
|
|
60
|
+
* `height` of hitbox
|
|
61
|
+
*/
|
|
62
|
+
height: number;
|
|
63
|
+
};
|
|
64
|
+
children: React.ReactElement | React.ReactElement[];
|
|
65
|
+
}
|
|
66
|
+
declare type NativeProps = Props;
|
|
67
|
+
declare const VectorSource_base: {
|
|
68
|
+
new (...args: any[]): {
|
|
69
|
+
_nativeModuleName: string;
|
|
70
|
+
_onAndroidCallback: (e: any) => void;
|
|
71
|
+
_callbackMap: Map<string, any>;
|
|
72
|
+
_preRefMapMethodQueue: {
|
|
73
|
+
method: {
|
|
74
|
+
name: string; /**
|
|
75
|
+
* A string that uniquely identifies the source.
|
|
76
|
+
*/
|
|
77
|
+
args: import("../utils").NativeArg[];
|
|
78
|
+
};
|
|
79
|
+
resolver: (value: import("../utils").NativeArg) => void;
|
|
80
|
+
}[];
|
|
81
|
+
_addAddAndroidCallback<ReturnType_1>(id: string, resolve: (value: ReturnType_1) => void, reject: (error: Error) => void): void;
|
|
82
|
+
_removeAndroidCallback(id: string): void;
|
|
83
|
+
_onAndroidCallbackO(e: React.SyntheticEvent<Element, import("./NativeBridgeComponent").RNMBEvent<{
|
|
84
|
+
[key: string]: string;
|
|
85
|
+
}>>): void;
|
|
86
|
+
_runPendingNativeCommands<RefType>(nativeRef: RefType): Promise<void>;
|
|
87
|
+
_runNativeCommand<RefType_1, ReturnType_2 = import("../utils").NativeArg>(methodName: string, nativeRef: RefType_1, args?: import("../utils").NativeArg[]): Promise<ReturnType_2>;
|
|
88
|
+
context: unknown;
|
|
89
|
+
setState<K extends never>(state: {} | ((prevState: Readonly<{}>, props: object) => {} | Pick<{}, K> | null) | Pick<{}, K> | null, callback?: (() => void) | undefined): void;
|
|
90
|
+
forceUpdate(callback?: (() => void) | undefined): void;
|
|
91
|
+
render(): React.ReactNode;
|
|
92
|
+
readonly props: object;
|
|
93
|
+
state: Readonly<{}>;
|
|
94
|
+
refs: {
|
|
95
|
+
[key: string]: React.ReactInstance;
|
|
96
|
+
};
|
|
97
|
+
componentDidMount?(): void;
|
|
98
|
+
shouldComponentUpdate?(nextProps: object, nextState: Readonly<{}>, nextContext: any): boolean;
|
|
99
|
+
componentWillUnmount?(): void;
|
|
100
|
+
componentDidCatch?(error: Error, errorInfo: React.ErrorInfo): void;
|
|
101
|
+
getSnapshotBeforeUpdate?(prevProps: object, prevState: Readonly<{}>): any;
|
|
102
|
+
componentDidUpdate?(prevProps: object, prevState: Readonly<{}>, snapshot?: any): void;
|
|
103
|
+
componentWillMount?(): void;
|
|
104
|
+
UNSAFE_componentWillMount?(): void;
|
|
105
|
+
componentWillReceiveProps?(nextProps: object, nextContext: any): void;
|
|
106
|
+
UNSAFE_componentWillReceiveProps?(nextProps: object, nextContext: any): void;
|
|
107
|
+
componentWillUpdate?(nextProps: object, nextState: Readonly<{}>, nextContext: any): void;
|
|
108
|
+
UNSAFE_componentWillUpdate?(nextProps: object, nextState: Readonly<{}>, nextContext: any): void;
|
|
109
|
+
};
|
|
110
|
+
} & {
|
|
111
|
+
new (props: (Props & import("../types/BaseProps").BaseProps) | Readonly<Props & import("../types/BaseProps").BaseProps>): AbstractSource<Props, Props>;
|
|
112
|
+
new (props: Props & import("../types/BaseProps").BaseProps, context: any): AbstractSource<Props, Props>;
|
|
113
|
+
contextType?: React.Context<any> | undefined;
|
|
114
|
+
};
|
|
115
|
+
/**
|
|
116
|
+
* VectorSource is a map content source that supplies tiled vector data in Mapbox Vector Tile format to be shown on the map.
|
|
117
|
+
* The location of and metadata about the tiles are defined either by an option dictionary or by an external file that conforms to the TileJSON specification.
|
|
118
|
+
*/
|
|
119
|
+
declare class VectorSource extends VectorSource_base {
|
|
120
|
+
static defaultProps: {
|
|
121
|
+
id: any;
|
|
122
|
+
};
|
|
123
|
+
constructor(props: Props);
|
|
124
|
+
_setNativeRef(nativeRef: (React.Component<NativeProps> & Readonly<NativeMethods>) | null): void;
|
|
125
|
+
/**
|
|
126
|
+
* Returns all features that match the query parameters regardless of whether or not the feature is
|
|
127
|
+
* currently rendered on the map. The domain of the query includes all currently-loaded vector tiles
|
|
128
|
+
* and GeoJSON source tiles. This function does not check tiles outside of the visible viewport.
|
|
129
|
+
*
|
|
130
|
+
* @example
|
|
131
|
+
* vectorSource.features(['id1', 'id2'])
|
|
132
|
+
*
|
|
133
|
+
* @param {Array=} layerIDs - A set of strings that correspond to the names of layers defined in the current style. Only the features contained in these layers are included in the returned array.
|
|
134
|
+
* @param {Array=} filter - an optional filter statement to filter the returned Features.
|
|
135
|
+
* @return {FeatureCollection}
|
|
136
|
+
*/
|
|
137
|
+
features(layerIDs?: never[], filter?: never[]): Promise<any>;
|
|
138
|
+
onPress(event: NativeSyntheticEvent<{
|
|
139
|
+
payload: OnPressEvent;
|
|
140
|
+
}>): void;
|
|
141
|
+
render(): JSX.Element;
|
|
142
|
+
}
|
|
143
|
+
export default VectorSource;
|
|
144
|
+
//# sourceMappingURL=VectorSource.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VectorSource.d.ts","sourceRoot":"","sources":["../../../javascript/components/VectorSource.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EACL,aAAa,EAEb,oBAAoB,EAErB,MAAM,cAAc,CAAC;AAKtB,OAAO,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAErD,OAAO,cAAc,MAAM,kBAAkB,CAAC;AAK9C,eAAO,MAAM,kBAAkB,uBAAuB,CAAC;AAEvD,UAAU,KAAK;IACb;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb;;;OAGG;IACH,gBAAgB,CAAC,EAAE,MAAM,EAAE,CAAC;IAE5B;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;OAEG;IACH,GAAG,CAAC,EAAE,OAAO,CAAC;IAEd;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;;;;;OAQG;IACH,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,IAAI,CAAC;IAExC;;OAEG;IACH,MAAM,CAAC,EAAE;QACP;;WAEG;QACH,KAAK,EAAE,MAAM,CAAC;QACd;;WAEG;QACH,MAAM,EAAE,MAAM,CAAC;KAChB,CAAC;IAEF,QAAQ,EAAE,KAAK,CAAC,YAAY,GAAG,KAAK,CAAC,YAAY,EAAE,CAAC;CACrD;AAGD,aAAK,WAAW,GAAG,KAAK,CAAC;;;;;;;;8BAtEvB;;mBAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqEL;;;GAGG;AACH,cAAM,YAAa,SAAQ,iBAG1B;IACC,MAAM,CAAC,YAAY;;MAEjB;gBAEU,KAAK,EAAE,KAAK;IAIxB,aAAa,CACX,SAAS,EAAE,CAAC,KAAK,CAAC,SAAS,CAAC,WAAW,CAAC,GAAG,QAAQ,CAAC,aAAa,CAAC,CAAC,GAAG,IAAI;IAS5E;;;;;;;;;;;OAWG;IACG,QAAQ,CAAC,QAAQ,UAAK,EAAE,MAAM,UAAK;IAczC,OAAO,CACL,KAAK,EAAE,oBAAoB,CAAC;QAC1B,OAAO,EAAE,YAAY,CAAC;KACvB,CAAC;IAiCJ,MAAM;CAuBP;AAKD,eAAe,YAAY,CAAC"}
|
|
@@ -10,7 +10,7 @@ export interface Location {
|
|
|
10
10
|
/**
|
|
11
11
|
* Coorinates sent by locationManager
|
|
12
12
|
*/
|
|
13
|
-
|
|
13
|
+
interface Coordinates {
|
|
14
14
|
/**
|
|
15
15
|
* The heading (measured in degrees) relative to true north.
|
|
16
16
|
* Heading is used to describe the direction the device is pointing to (the value of the compass).
|
|
@@ -47,7 +47,7 @@ export interface Coordinates {
|
|
|
47
47
|
/**
|
|
48
48
|
* LocationManager is a singleton, see `locationManager`
|
|
49
49
|
*/
|
|
50
|
-
declare class LocationManager {
|
|
50
|
+
export declare class LocationManager {
|
|
51
51
|
_listeners: ((location: Location) => void)[];
|
|
52
52
|
_lastKnownLocation: Location | null;
|
|
53
53
|
_isListening: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"locationManager.d.ts","sourceRoot":"","sources":["../../../../javascript/modules/location/locationManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,kBAAkB,EAElB,uBAAuB,EACvB,mBAAmB,EACnB,KAAK,cAAc,EACpB,MAAM,cAAc,CAAC;AAKtB,eAAO,MAAM,0BAA0B,oBAEtC,CAAC;AAEF;;GAEG;AACH,MAAM,WAAW,QAAQ;IACvB,MAAM,EAAE,WAAW,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,
|
|
1
|
+
{"version":3,"file":"locationManager.d.ts","sourceRoot":"","sources":["../../../../javascript/modules/location/locationManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,kBAAkB,EAElB,uBAAuB,EACvB,mBAAmB,EACnB,KAAK,cAAc,EACpB,MAAM,cAAc,CAAC;AAKtB,eAAO,MAAM,0BAA0B,oBAEtC,CAAC;AAEF;;GAEG;AACH,MAAM,WAAW,QAAQ;IACvB,MAAM,EAAE,WAAW,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;GAEG;AACH,UAAU,WAAW;IACnB;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,qBAAa,eAAe;IAC1B,UAAU,EAAE,CAAC,CAAC,QAAQ,EAAE,QAAQ,KAAK,IAAI,CAAC,EAAE,CAAC;IAC7C,kBAAkB,EAAE,QAAQ,GAAG,IAAI,CAAC;IACpC,YAAY,EAAE,OAAO,CAAC;IACtB,kBAAkB,EAAE,OAAO,CAAC;IAC5B,YAAY,EAAE,mBAAmB,GAAG,IAAI,CAAC;IACzC,iBAAiB,EAAE,uBAAuB,CAAC;IAC3C,gBAAgB,CAAC,EAAE,MAAM,CAAC;;IAgBpB,oBAAoB;IAuB1B,WAAW,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,QAAQ,KAAK,IAAI;IAalD,cAAc,CAAC,QAAQ,EAAE,CAAC,QAAQ,EAAE,QAAQ,KAAK,IAAI;IAOrD,kBAAkB;IAKlB,qBAAqB,CAAC,QAAQ,EAAE,cAAc;IAY9C,KAAK,CAAC,YAAY,SAAK;IAwBvB,IAAI;IAUJ,kBAAkB,CAAC,eAAe,EAAE,MAAM;IAK1C,oBAAoB,CAAC,iBAAiB,EAAE,OAAO;IAK/C,SAAS,CAAC,QAAQ,EAAE,QAAQ;IAM5B;;OAEG;IACH,gBAAgB,CAAC,gBAAgB,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM;IAI5D;;;;;;;;;OASG;IACH,wBAAwB,CAAC,aAAa,EAAE,MAAM;CAG/C;;AAED,wBAAqC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseProps.d.ts","sourceRoot":"","sources":["../../../javascript/types/BaseProps.ts"],"names":[],"mappings":"AAAA,oBAAY,SAAS,GAAG;IACtB,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAC7B,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"OnPressEvent.d.ts","sourceRoot":"","sources":["../../../javascript/types/OnPressEvent.ts"],"names":[],"mappings":"AAAA,oBAAY,YAAY,GAAG;IACzB,QAAQ,EAAE,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;IACjC,WAAW,EAAE;QACX,QAAQ,EAAE,MAAM,CAAC;QACjB,SAAS,EAAE,MAAM,CAAC;KACnB,CAAC;IACF,KAAK,EAAE;QACL,CAAC,EAAE,MAAM,CAAC;QACV,CAAC,EAAE,MAAM,CAAC;KACX,CAAC;CACH,CAAC"}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { EmitterSubscription, NativeEventEmitter } from 'react-native';
|
|
2
|
+
declare type LogLevel = 'error' | 'warning' | 'info' | 'debug' | 'verbose';
|
|
3
|
+
export interface LogObject {
|
|
4
|
+
level: LogLevel;
|
|
5
|
+
message: string;
|
|
6
|
+
tag: string;
|
|
7
|
+
}
|
|
8
|
+
declare type LogCallback = (object: LogObject) => boolean;
|
|
9
|
+
declare class Logger {
|
|
10
|
+
static instance: Logger | null;
|
|
11
|
+
loggerEmitter: NativeEventEmitter;
|
|
12
|
+
startedCount: number;
|
|
13
|
+
logCallback?: LogCallback;
|
|
14
|
+
subscription?: EmitterSubscription;
|
|
15
|
+
static sharedInstance(): Logger;
|
|
16
|
+
constructor();
|
|
17
|
+
/**
|
|
18
|
+
* Set custom logger function.
|
|
19
|
+
* @param {Logger~logCallback} logCallback - callback taking a log object as param. If callback return falsy value then
|
|
20
|
+
* default logging will take place.
|
|
21
|
+
*/
|
|
22
|
+
static setLogCallback(logCallback: LogCallback): void;
|
|
23
|
+
/**
|
|
24
|
+
* Set custom logger function.
|
|
25
|
+
* @param {Logger~logCallback} logCallback - callback taking a log object as param. If callback return falsy value then
|
|
26
|
+
* default logging will take place.
|
|
27
|
+
*/
|
|
28
|
+
setLogCallback(logCallback: LogCallback): void;
|
|
29
|
+
/**
|
|
30
|
+
* This callback is displayed as part of the Requester class.
|
|
31
|
+
* @callback Logger~logCallback
|
|
32
|
+
* @param {object} log
|
|
33
|
+
* @param {string} log.message - the message of the log
|
|
34
|
+
* @param {string} log.level - log level
|
|
35
|
+
* @param {string} log.tag - optional tag used on android
|
|
36
|
+
*/
|
|
37
|
+
/**
|
|
38
|
+
* setLogLevel
|
|
39
|
+
* @param {LogLevel} level
|
|
40
|
+
*/
|
|
41
|
+
static setLogLevel(level: LogLevel): void;
|
|
42
|
+
/**
|
|
43
|
+
* @type {('error'|'warning'|'info'|'debug'|'verbose')} LogLevel - Supported log levels
|
|
44
|
+
*/
|
|
45
|
+
start(): void;
|
|
46
|
+
stop(): void;
|
|
47
|
+
subscribe(): void;
|
|
48
|
+
unsubscribe(): void;
|
|
49
|
+
effectiveLevel(log: LogObject): LogLevel;
|
|
50
|
+
onLog(log: LogObject): void;
|
|
51
|
+
}
|
|
52
|
+
export default Logger;
|
|
53
|
+
//# sourceMappingURL=Logger.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Logger.d.ts","sourceRoot":"","sources":["../../../javascript/utils/Logger.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAEnB,MAAM,cAAc,CAAC;AAGtB,aAAK,QAAQ,GAAG,OAAO,GAAG,SAAS,GAAG,MAAM,GAAG,OAAO,GAAG,SAAS,CAAC;AAEnE,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,QAAQ,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,GAAG,EAAE,MAAM,CAAC;CACb;AAED,aAAK,WAAW,GAAG,CAAC,MAAM,EAAE,SAAS,KAAK,OAAO,CAAC;AAElD,cAAM,MAAM;IACV,MAAM,CAAC,QAAQ,EAAE,MAAM,GAAG,IAAI,CAAQ;IAEtC,aAAa,EAAE,kBAAkB,CAAC;IAClC,YAAY,EAAE,MAAM,CAAC;IACrB,WAAW,CAAC,EAAE,WAAW,CAAC;IAC1B,YAAY,CAAC,EAAE,mBAAmB,CAAC;IAEnC,MAAM,CAAC,cAAc;;IAarB;;;;OAIG;IACH,MAAM,CAAC,cAAc,CAAC,WAAW,EAAE,WAAW;IAI9C;;;;OAIG;IACH,cAAc,CAAC,WAAW,EAAE,WAAW;IAIvC;;;;;;;OAOG;IAEH;;;OAGG;IACH,MAAM,CAAC,WAAW,CAAC,KAAK,EAAE,QAAQ;IAIlC;;OAEG;IACH,KAAK;IAOL,IAAI;IAOJ,SAAS;IAMT,WAAW;IAKX,cAAc,CAAC,GAAG,EAAE,SAAS;IAe7B,KAAK,CAAC,GAAG,EAAE,SAAS;CAarB;AAID,eAAe,MAAM,CAAC"}
|
|
@@ -3,10 +3,11 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export declare function deprecatedClass<C extends new (...args: any[]) => object>(origClass: C, deprecationMessage: string): C;
|
|
5
5
|
/**
|
|
6
|
-
* Copy properties from origObject to newObject, which not exists in newObject
|
|
7
|
-
*
|
|
6
|
+
* Copy properties from origObject to newObject, but only those which not exists in newObject.
|
|
7
|
+
* Calls onDeprecatedCalled callback in case a copied property is invoked.
|
|
8
8
|
*/
|
|
9
|
-
export declare function copyPropertiesAsDeprecated<DeprecatedType extends
|
|
9
|
+
export declare function copyPropertiesAsDeprecated<DeprecatedType extends object, // Record<string, unknown>,
|
|
10
|
+
WithDeprecatedType extends Record<string, unknown>>(origObject: DeprecatedType, newObject: WithDeprecatedType, onDeprecatedCalled: (key: string) => void, accessors?: {
|
|
10
11
|
[key: string]: (value: unknown) => unknown;
|
|
11
12
|
}): WithDeprecatedType;
|
|
12
13
|
//# sourceMappingURL=deprecation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deprecation.d.ts","sourceRoot":"","sources":["../../../javascript/utils/deprecation.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,wBAAgB,eAAe,CAAC,CAAC,SAAS,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,MAAM,EACtE,SAAS,EAAE,CAAC,EACZ,kBAAkB,EAAE,MAAM,GACzB,CAAC,CAQH;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,CACxC,cAAc,SAAS,MAAM,
|
|
1
|
+
{"version":3,"file":"deprecation.d.ts","sourceRoot":"","sources":["../../../javascript/utils/deprecation.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,wBAAgB,eAAe,CAAC,CAAC,SAAS,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,MAAM,EACtE,SAAS,EAAE,CAAC,EACZ,kBAAkB,EAAE,MAAM,GACzB,CAAC,CAQH;AAED;;;GAGG;AACH,wBAAgB,0BAA0B,CACxC,cAAc,SAAS,MAAM,EAAE,2BAA2B;AAC1D,kBAAkB,SAAS,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAElD,UAAU,EAAE,cAAc,EAC1B,SAAS,EAAE,kBAAkB,EAC7B,kBAAkB,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,IAAI,EACzC,SAAS,GAAE;IAAE,CAAC,GAAG,EAAE,MAAM,GAAG,CAAC,KAAK,EAAE,OAAO,KAAK,OAAO,CAAA;CAAO,GAC7D,kBAAkB,CAapB"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { RefObject, type Component, type MutableRefObject } from 'react';
|
|
2
|
+
import { type NativeMethods, type HostComponent } from 'react-native';
|
|
3
|
+
/**
|
|
4
|
+
* Helper for useRef and requireNativeComponent:
|
|
5
|
+
* @example
|
|
6
|
+
* RCTMGLCamera = requireNativeComponent<NativeProps>('RCTMGLCamera');
|
|
7
|
+
* const ref = useRef<typeof RCTMGLCamera)(null) as NativeRefType<NativeProps>;
|
|
8
|
+
* ...
|
|
9
|
+
* <RCTMGLCamera ref={ref} ... />
|
|
10
|
+
*/
|
|
11
|
+
export declare type NativeRefType<P> = MutableRefObject<(Component<P> & Readonly<NativeMethods>) | null>;
|
|
12
|
+
/**
|
|
13
|
+
* Helper for useRef and requireNativeComponent:
|
|
14
|
+
* @example
|
|
15
|
+
* RCTMGLCamera = requireNativeComponent<NativeProps>('RCTMGLCamera');
|
|
16
|
+
* const ref = nativeRef(useRef<typeof RCTMGLCamera)(null));
|
|
17
|
+
* ...
|
|
18
|
+
* <RCTMGLCamera ref={ref} ... />
|
|
19
|
+
*/
|
|
20
|
+
export default function nativeRef<P>(c: RefObject<HostComponent<P> | null>): MutableRefObject<(Component<P> & Readonly<NativeMethods>) | null>;
|
|
21
|
+
//# sourceMappingURL=nativeRef.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nativeRef.d.ts","sourceRoot":"","sources":["../../../javascript/utils/nativeRef.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,KAAK,SAAS,EAAE,KAAK,gBAAgB,EAAE,MAAM,OAAO,CAAC;AACzE,OAAO,EAAE,KAAK,aAAa,EAAE,KAAK,aAAa,EAAE,MAAM,cAAc,CAAC;AAEtE;;;;;;;GAOG;AACH,oBAAY,aAAa,CAAC,CAAC,IAAI,gBAAgB,CAC7C,CAAC,SAAS,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,aAAa,CAAC,CAAC,GAAG,IAAI,CAChD,CAAC;AAEF;;;;;;;GAOG;AACH,MAAM,CAAC,OAAO,UAAU,SAAS,CAAC,CAAC,EACjC,CAAC,EAAE,SAAS,CAAC,aAAa,CAAC,CAAC,CAAC,GAAG,IAAI,CAAC,GACpC,gBAAgB,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,GAAG,QAAQ,CAAC,aAAa,CAAC,CAAC,GAAG,IAAI,CAAC,CAEnE"}
|
package/package.json
CHANGED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
package com.mapbox.rctmgl.components.images;
|
|
2
|
-
|
|
3
|
-
import android.graphics.drawable.BitmapDrawable;
|
|
4
|
-
|
|
5
|
-
import com.facebook.react.bridge.ReactApplicationContext;
|
|
6
|
-
import com.facebook.react.bridge.ReadableArray;
|
|
7
|
-
import com.facebook.react.bridge.ReadableMap;
|
|
8
|
-
import com.facebook.react.bridge.ReadableMapKeySetIterator;
|
|
9
|
-
import com.facebook.react.bridge.ReadableType;
|
|
10
|
-
import com.facebook.react.common.MapBuilder;
|
|
11
|
-
import com.facebook.react.uimanager.ThemedReactContext;
|
|
12
|
-
import com.facebook.react.uimanager.ViewGroupManager;
|
|
13
|
-
import com.facebook.react.uimanager.annotations.ReactProp;
|
|
14
|
-
import com.mapbox.rctmgl.components.AbstractEventEmitter;
|
|
15
|
-
import com.mapbox.rctmgl.components.AbstractMapFeature;
|
|
16
|
-
import com.mapbox.rctmgl.components.styles.sources.RCTMGLShapeSource;
|
|
17
|
-
import com.mapbox.rctmgl.events.constants.EventKeys;
|
|
18
|
-
import com.mapbox.rctmgl.utils.ImageEntry;
|
|
19
|
-
import com.mapbox.rctmgl.utils.ResourceUtils;
|
|
20
|
-
|
|
21
|
-
import java.util.AbstractMap;
|
|
22
|
-
import java.util.ArrayList;
|
|
23
|
-
import java.util.List;
|
|
24
|
-
import java.util.Map;
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
public class RCTMGLImagesManager extends AbstractEventEmitter<RCTMGLImages> {
|
|
28
|
-
public static final String REACT_CLASS = "RCTMGLImages";
|
|
29
|
-
|
|
30
|
-
private ReactApplicationContext mContext;
|
|
31
|
-
|
|
32
|
-
@Override
|
|
33
|
-
public String getName() {
|
|
34
|
-
return "RCTMGLImages";
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
public RCTMGLImagesManager(ReactApplicationContext context) {
|
|
39
|
-
super(context);
|
|
40
|
-
mContext = context;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
@Override
|
|
44
|
-
public RCTMGLImages createViewInstance(ThemedReactContext context) {
|
|
45
|
-
return new RCTMGLImages(context, this);
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
@ReactProp(name = "id")
|
|
49
|
-
public void setId(RCTMGLImages source, String id) {
|
|
50
|
-
source.setID(id);
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
@ReactProp(name = "images")
|
|
54
|
-
public void setImages(RCTMGLImages images, ReadableMap map) {
|
|
55
|
-
List<Map.Entry<String, ImageEntry>> imagesList = new ArrayList<>();
|
|
56
|
-
|
|
57
|
-
ReadableMapKeySetIterator iterator = map.keySetIterator();
|
|
58
|
-
while (iterator.hasNextKey()) {
|
|
59
|
-
String imageName = iterator.nextKey();
|
|
60
|
-
ImageEntry imageEntry = null;
|
|
61
|
-
if (map.getType(imageName) == ReadableType.Map) {
|
|
62
|
-
ReadableMap imageMap = map.getMap(imageName);
|
|
63
|
-
String uri = imageMap.getString("uri");
|
|
64
|
-
boolean hasScale = imageMap.hasKey("scale") && imageMap.getType("scale") == ReadableType.Number;
|
|
65
|
-
double scale = hasScale ? imageMap.getDouble("scale") : ImageEntry.defaultScale;
|
|
66
|
-
imageEntry = new ImageEntry(uri, scale);
|
|
67
|
-
} else {
|
|
68
|
-
imageEntry = new ImageEntry(map.getString(imageName));
|
|
69
|
-
}
|
|
70
|
-
imagesList.add(new AbstractMap.SimpleEntry<String, ImageEntry>(imageName, imageEntry));
|
|
71
|
-
}
|
|
72
|
-
|
|
73
|
-
images.setImages(imagesList);
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
@ReactProp(name = "hasOnImageMissing")
|
|
77
|
-
public void setHasOnImageMissing(RCTMGLImages images, Boolean value) {
|
|
78
|
-
images.setHasOnImageMissing(value);
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
@ReactProp(name = "nativeImages")
|
|
82
|
-
public void setNativeImages(RCTMGLImages images, ReadableArray arr) {
|
|
83
|
-
List<Map.Entry<String, BitmapDrawable>> resources = new ArrayList<>();
|
|
84
|
-
|
|
85
|
-
for (int i = 0; i < arr.size(); i++) {
|
|
86
|
-
String resourceName = arr.getString(i);
|
|
87
|
-
BitmapDrawable drawable = (BitmapDrawable) ResourceUtils.getDrawableByName(mContext, resourceName);
|
|
88
|
-
|
|
89
|
-
if (drawable != null) {
|
|
90
|
-
resources.add(new AbstractMap.SimpleEntry<String, BitmapDrawable>(resourceName, drawable));
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
images.setNativeImages(resources);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
@Override
|
|
98
|
-
public Map<String, String> customEvents() {
|
|
99
|
-
return MapBuilder.<String, String>builder()
|
|
100
|
-
.put(EventKeys.IMAGES_MISSING, "onImageMissing")
|
|
101
|
-
.build();
|
|
102
|
-
}
|
|
103
|
-
}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { requireNativeComponent } from 'react-native';
|
|
3
|
-
|
|
4
|
-
import { viewPropTypes } from '../utils';
|
|
5
|
-
import { LightLayerStyleProp } from '../utils/styleMap';
|
|
6
|
-
|
|
7
|
-
import AbstractLayer from './AbstractLayer';
|
|
8
|
-
|
|
9
|
-
export const NATIVE_MODULE_NAME = 'RCTMGLLight';
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
* Light represents the light source for extruded geometries
|
|
13
|
-
*/
|
|
14
|
-
class Light extends AbstractLayer {
|
|
15
|
-
static propTypes = {
|
|
16
|
-
...viewPropTypes,
|
|
17
|
-
|
|
18
|
-
/**
|
|
19
|
-
* Customizable style attributes
|
|
20
|
-
*/
|
|
21
|
-
style: LightLayerStyleProp,
|
|
22
|
-
};
|
|
23
|
-
|
|
24
|
-
setNativeProps(props) {
|
|
25
|
-
if (this.refs.nativeLight) {
|
|
26
|
-
this.refs.nativeLight.setNativeProps(props);
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
render() {
|
|
31
|
-
return (
|
|
32
|
-
<RCTMGLLight
|
|
33
|
-
ref="nativeLight"
|
|
34
|
-
testID="rctmglLight"
|
|
35
|
-
{...this.props}
|
|
36
|
-
style={undefined}
|
|
37
|
-
reactStyle={this.getStyle(this.props.style)}
|
|
38
|
-
/>
|
|
39
|
-
);
|
|
40
|
-
}
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
const RCTMGLLight = requireNativeComponent(NATIVE_MODULE_NAME, Light, {
|
|
44
|
-
nativeOnly: { reactStyle: true },
|
|
45
|
-
});
|
|
46
|
-
|
|
47
|
-
export default Light;
|