@mappedin/react-native-sdk 4.1.0-beta.2 → 4.1.2
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 +81 -20
- package/dist/browser-FCICONUM.js +1 -0
- package/dist/chunk-MJIJTBP6.js +1 -0
- package/dist/index.d.ts +1729 -778
- package/dist/index.js +1286 -1203
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -5,9 +5,8 @@
|
|
|
5
5
|
// ../react-native-webview/lib/WebViewTypes
|
|
6
6
|
// ../three
|
|
7
7
|
// ../@tweenjs/tween.js
|
|
8
|
-
// ../
|
|
9
|
-
// ../
|
|
10
|
-
// ../three/src/math/Vector3
|
|
8
|
+
// ../minisearch
|
|
9
|
+
// ../geojson
|
|
11
10
|
|
|
12
11
|
declare module '@mappedin/react-native-sdk' {
|
|
13
12
|
export { MiMapView } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView';
|
|
@@ -16,19 +15,21 @@ declare module '@mappedin/react-native-sdk' {
|
|
|
16
15
|
export type { TMiMiniMapProps } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMiniMap';
|
|
17
16
|
export type { MapViewStore } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store';
|
|
18
17
|
export { getVenue, getVenueBundle } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
19
|
-
export type { TGetVenueOptions, TGetVenueBundleOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
18
|
+
export type { TGetVenueOptions, TGetVenueBundleOptions, TMappedinOfflineSearchResult, TMappedinOfflineSearchSuggestions, TMappedinOfflineSearchOptions, TMappedinOfflineSearchAllOptions, TMappedinOfflineAllSearchMatch } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
20
19
|
export { STATE } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
21
|
-
export { COLLISION_RANKING_TIERS, MARKER_ANCHOR, E_BLUEDOT_STATE, MappedinCoordinate, labelThemes, E_BLUEDOT_MARKER_STATE, E_BLUEDOT_STATE_REASON } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
20
|
+
export { COLLISION_RANKING_TIERS, MARKER_ANCHOR, E_BLUEDOT_STATE, MappedinCoordinate, labelThemes, E_BLUEDOT_MARKER_STATE, E_BLUEDOT_STATE_REASON, MAP_RENDER_MODE } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
22
21
|
export type { TSerializableJourneyOptions, TMiMapViewOptions } from '@mappedin/react-native-sdk/wrappers/common';
|
|
23
22
|
import type { TEnableBlueDotOptions as TEnableBlueDotOptionsBase, TLabelAllLocationCommonOptions as TLabelAllLocationCommonOptionsBase } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
24
|
-
export type { TJourneyOptions, TGeolocationObject, TPathOptions, TFlatLabelPolygonOptions, TFloatingLabelPolygonOptions, TLabelAllLocationFlatLabelOptions, TLabelAllLocationFloatingLabelOptions, TFlatLabelAppearance, TFloatingLabelAppearance, TFocusOnCameraOptions, TFocusOnTargets, TCommonLabelOptions, TCameraAnimationOptions, TFocusOnOptions, TAnimatePositionOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
23
|
+
export type { TJourneyOptions, TGeolocationObject, TPathOptions, TFlatLabelPolygonOptions, TFloatingLabelPolygonOptions, TLabelAllLocationFlatLabelOptions, TLabelAllLocationFloatingLabelOptions, TFlatLabelAppearance, TFloatingLabelAppearance, TFocusOnCameraOptions, TFocusOnTargets, TCommonLabelOptions, TCameraAnimationOptions, TFocusOnOptions, TAnimatePositionOptions, TBlueDotPositionUpdate, TBlueDotStateChange } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
25
24
|
export type { TEnableBlueDotOptionsBase, TLabelAllLocationCommonOptionsBase };
|
|
26
25
|
export type TEnableBlueDotOptions = Omit<TEnableBlueDotOptionsBase, 'positionUpdater' | 'geolocationSource'>;
|
|
27
26
|
export type TLabelAllLocationCommonOptions = Omit<TLabelAllLocationCommonOptionsBase, 'sortFunction' | 'translationMap'>;
|
|
27
|
+
export type { TMapViewRNOptions } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store.types';
|
|
28
|
+
export type { TMiMapViewVenueOptions } from '@mappedin/react-native-sdk/wrappers/common';
|
|
28
29
|
export type { IDirectionsResult, MappedinDirections, TMappedinDirective } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
29
|
-
export type { TShowVenueOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
30
|
+
export type { TShowVenueOptions, E_GET_DIRECTIONS_MESSAGES } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
30
31
|
export { ERROR, ERROR_MESSAGES } from '@mappedin/react-native-sdk/wrappers/common/errors';
|
|
31
|
-
export {
|
|
32
|
+
export { BEARING_TYPE, ACTION_TYPE, MappedinLocation, Mappedin, MappedinPolygon, MappedinNode, MappedinCategory, MappedinMap, MappedinEvent, MappedinMapGroup, MappedinVenue, MappedinVortex, MappedinRankings, MappedinDestinationSet } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
32
33
|
}
|
|
33
34
|
|
|
34
35
|
declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView' {
|
|
@@ -38,6 +39,7 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapVi
|
|
|
38
39
|
import { MapViewStore } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store';
|
|
39
40
|
import type { TBlueDotPositionUpdate, TBlueDotStateChange, MappedinPolygon, MappedinMap, Mappedin } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
40
41
|
import { ERROR, ERROR_MESSAGES } from '@mappedin/react-native-sdk/wrappers/common/errors';
|
|
42
|
+
import { TMapViewRNOptions } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store.types';
|
|
41
43
|
export type TMiMapViewProps = {
|
|
42
44
|
/**
|
|
43
45
|
* The MapViewStore instance will be returned here
|
|
@@ -46,18 +48,12 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapVi
|
|
|
46
48
|
/**
|
|
47
49
|
* Options to initialze MiMapView with
|
|
48
50
|
*/
|
|
49
|
-
options: TMiMapViewOptions &
|
|
50
|
-
/**
|
|
51
|
-
* Use a bundle for venue loading and cache it for faster subsequent loading
|
|
52
|
-
* @beta
|
|
53
|
-
*/
|
|
54
|
-
useBundle?: boolean;
|
|
55
|
-
};
|
|
51
|
+
options: TMiMapViewOptions & TMapViewRNOptions;
|
|
56
52
|
/**
|
|
57
53
|
* Venue Data to render inside the MapView. This is returned by {@link getVenue} or {@link getVenueBundle}
|
|
58
54
|
*/
|
|
59
55
|
venueData?: Mappedin;
|
|
60
|
-
style?:
|
|
56
|
+
style?: React.CSSProperties;
|
|
61
57
|
/**
|
|
62
58
|
* Called when an interactive polygon is clicked
|
|
63
59
|
*/
|
|
@@ -120,7 +116,7 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapVi
|
|
|
120
116
|
/**
|
|
121
117
|
* @category Component
|
|
122
118
|
*/
|
|
123
|
-
export const MiMapView: React.MemoExoticComponent<React.ForwardRefExoticComponent<Pick<TMiMapViewProps, "
|
|
119
|
+
export const MiMapView: React.MemoExoticComponent<React.ForwardRefExoticComponent<Pick<TMiMapViewProps, "style" | "options" | "onFirstMapLoaded" | "onDataLoaded" | "venueData" | "onPolygonClicked" | "onBlueDotStateChanged" | "onBlueDotPositionUpdated" | "onNothingClicked" | "onMapChanged" | "onStateChanged" | "onVenueLoadError"> & React.RefAttributes<MapViewStore>>>;
|
|
124
120
|
}
|
|
125
121
|
|
|
126
122
|
declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMiniMap' {
|
|
@@ -171,8 +167,8 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMiniM
|
|
|
171
167
|
declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store' {
|
|
172
168
|
import { RNMappedinController } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MappedinController';
|
|
173
169
|
import { TReactNativeFlatLabelAllLocations, TReactNativeFlatLabelAllLocationsLegacy, TReactNativeFlatLabelPolygonOptions, TReactNativeFloatingLabelPolygonOptions, TSerializableJourneyOptions } from '@mappedin/react-native-sdk/wrappers/common';
|
|
174
|
-
import type { TGeolocationObject, TEnableBlueDotOptions, TPathOptions, TFocusOnOptions, TAnimatePositionOptions, TLabelAllLocationFloatingLabelOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
175
|
-
import { STATE, Mappedin, MappedinNode, MappedinMap, MappedinLocation, MappedinDirections, MappedinPolygon, TGetVenueOptions, TShowVenueOptions, MappedinCoordinate, MappedinDestinationSet, TCreateMarkerOptions, E_BLUEDOT_STATE } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
170
|
+
import type { TGeolocationObject, TEnableBlueDotOptions, TPathOptions, TFocusOnOptions, TAnimatePositionOptions, TLabelAllLocationFloatingLabelOptions, TMappedinOfflineSearchOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
171
|
+
import { STATE, Mappedin, MappedinNode, MappedinMap, MappedinLocation, MappedinDirections, MappedinCategory, MappedinPolygon, TGetVenueOptions, TShowVenueOptions, MappedinCoordinate, MappedinDestinationSet, TCreateMarkerOptions, E_BLUEDOT_STATE, TMappedinOfflineSearchResult, TMappedinOfflineSearchSuggestions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
176
172
|
import { TFocusOptionsLegacy } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store.types';
|
|
177
173
|
export class MapViewStore extends RNMappedinController {
|
|
178
174
|
#private;
|
|
@@ -193,12 +189,18 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapVi
|
|
|
193
189
|
/**
|
|
194
190
|
* @hidden
|
|
195
191
|
*/
|
|
196
|
-
loadVenue(options: TGetVenueOptions, showVenueOptions: TShowVenueOptions
|
|
192
|
+
loadVenue(options: TGetVenueOptions, showVenueOptions: TShowVenueOptions & {
|
|
193
|
+
prepareSearch?: boolean;
|
|
194
|
+
searchOptions?: TMappedinOfflineSearchOptions;
|
|
195
|
+
}): Promise<unknown>;
|
|
197
196
|
/**
|
|
198
197
|
*
|
|
199
198
|
* @hidden
|
|
200
199
|
*/
|
|
201
|
-
showVenue(venueData: Mappedin, showVenueOptions: TShowVenueOptions
|
|
200
|
+
showVenue(venueData: Mappedin, showVenueOptions: TShowVenueOptions & {
|
|
201
|
+
prepareSearch?: boolean;
|
|
202
|
+
searchOptions?: TMappedinOfflineSearchOptions;
|
|
203
|
+
}): Promise<unknown>;
|
|
202
204
|
/**
|
|
203
205
|
* Clear any cached venue bundles that were downloaded as part of LOAD_VENUE with useBundle: true
|
|
204
206
|
* This ensure that the next time keys are passed in, we get a fresh bundle
|
|
@@ -387,6 +389,32 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapVi
|
|
|
387
389
|
* Draw a path based on a list of Nodes
|
|
388
390
|
*/
|
|
389
391
|
drawPath(pathNodesOrNodeIds: (MappedinNode | MappedinNode['id'])[], pathOptions: TPathOptions): Promise<unknown>;
|
|
392
|
+
OfflineSearch: {
|
|
393
|
+
/**
|
|
394
|
+
*
|
|
395
|
+
* @param query String to search for
|
|
396
|
+
*/
|
|
397
|
+
search: (query: string) => Promise<TMappedinOfflineSearchResult[]>;
|
|
398
|
+
/**
|
|
399
|
+
*
|
|
400
|
+
* @param query Get a list of suggestions for query
|
|
401
|
+
*/
|
|
402
|
+
suggest: (query: string) => Promise<TMappedinOfflineSearchSuggestions>;
|
|
403
|
+
addQuery: (params: {
|
|
404
|
+
/**
|
|
405
|
+
* Query string to match for this object
|
|
406
|
+
*/
|
|
407
|
+
query: string;
|
|
408
|
+
/**
|
|
409
|
+
* Object that is returned when query matches
|
|
410
|
+
*/
|
|
411
|
+
object: MappedinLocation | MappedinCategory | Record<string, unknown>;
|
|
412
|
+
/**
|
|
413
|
+
* Optional weight to multiply by the score
|
|
414
|
+
*/
|
|
415
|
+
weight?: number;
|
|
416
|
+
}) => Promise<unknown>;
|
|
417
|
+
};
|
|
390
418
|
/**
|
|
391
419
|
* @hidden
|
|
392
420
|
*/
|
|
@@ -396,15 +424,16 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapVi
|
|
|
396
424
|
|
|
397
425
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/index.rn' {
|
|
398
426
|
import { getVenue, getVenueBundle, Mappedin, MappedinDestinationSet } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
427
|
+
import { randomId } from '@mappedin/react-native-sdk/core/packages/renderer/internal/random-id';
|
|
399
428
|
export * from '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums';
|
|
400
|
-
export { getVenue, getVenueBundle, MappedinDestinationSet, Mappedin };
|
|
429
|
+
export { getVenue, getVenueBundle, MappedinDestinationSet, Mappedin, randomId };
|
|
401
430
|
export { GEOLOCATION_STATUS, COLLISION_RANKING_TIERS, E_BLUEDOT_STATE_REASON, E_BLUEDOT_STATE, E_BLUEDOT_MARKER_STATE, STATE, MARKER_ANCHOR, E_SDK_EVENT, E_BLUEDOT_EVENT, E_CAMERA_EVENT } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums';
|
|
402
431
|
export { labelThemes } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.types';
|
|
403
432
|
export type { TBlueDotPositionUpdate, TBlueDotStateChange, TJourneyOptions, TMapViewOptions, TCreateMarkerOptions, TGeolocationObject, TPathOptions, TCommonLabelOptions, TFlatLabelOptions, TFlatLabelPolygonOptions, TFloatingLabelPolygonOptions, TLabelAllLocationCommonOptions, TLabelAllLocationFloatingLabelOptions, TLabelAllLocationFlatLabelOptions, TEnableBlueDotOptions, TFloatingLabelAppearance, TFlatLabelAppearance } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.types';
|
|
404
433
|
export { BEARING_TYPE, ACTION_TYPE } from '@mappedin/react-native-sdk/core/packages/navigator';
|
|
405
434
|
export type { IDirectionsResult, E_MESSAGES as E_GET_DIRECTIONS_MESSAGES } from '@mappedin/react-native-sdk/core/packages/navigator';
|
|
406
|
-
export type { TGetVenueBundleOptions, TGetVenueOptions, TMappedinDirective, TShowVenueOptions } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
407
|
-
export { MappedinLocation, MappedinPolygon, MappedinNode, MappedinCategory, MappedinMap, MappedinEvent, MappedinMapGroup, MappedinVenue, MappedinVortex, MappedinDirections, MappedinNavigatable, MappedinCoordinate, MappedinRankings } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
435
|
+
export type { TGetVenueBundleOptions, TGetVenueOptions, TMappedinDirective, TShowVenueOptions, TMappedinOfflineSearchOptions, TMappedinOfflineSearchResult, TMappedinOfflineSearchSuggestions, TMappedinOfflineSearchAllOptions, TMappedinOfflineAllSearchMatch } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
436
|
+
export { MappedinLocation, MappedinPolygon, MappedinNode, MappedinCategory, MappedinMap, MappedinEvent, MappedinMapGroup, MappedinVenue, MappedinVortex, MappedinDirections, MappedinNavigatable, MappedinCoordinate, MappedinRankings, MAP_RENDER_MODE, OfflineSearch, MappedinCollectionType } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
408
437
|
export type { TSafeAreaInsets, TFocusOnTargets, TFocusOnCameraOptions, TAnimatePositionOptions, TCameraAnimationOptions, TFocusOnOptions } from '@mappedin/react-native-sdk/core/packages/renderer/Camera';
|
|
409
438
|
export { SAFE_AREA_INSET_TYPE, ANIMATION_TWEENS, CAMERA_EASING_MODE } from '@mappedin/react-native-sdk/core/packages/renderer/Camera';
|
|
410
439
|
}
|
|
@@ -416,6 +445,53 @@ declare module '@mappedin/react-native-sdk/wrappers/common' {
|
|
|
416
445
|
export { PubSub } from '@mappedin/react-native-sdk/wrappers/common/pub-sub';
|
|
417
446
|
}
|
|
418
447
|
|
|
448
|
+
declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store.types' {
|
|
449
|
+
import { MappedinNode, MappedinPolygon } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src';
|
|
450
|
+
import { MAP_RENDER_MODE } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
451
|
+
import type { MappedinCategory, MappedinLocation, TMappedinOfflineSearchOptions, TMappedinOfflineSearchResult } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
452
|
+
import { TFocusOptionsLegacy } from '@mappedin/react-native-sdk/core/packages/renderer/Core.interface';
|
|
453
|
+
export type TPolygonColorOptions = {
|
|
454
|
+
color: string;
|
|
455
|
+
opacity?: number;
|
|
456
|
+
textColor?: string;
|
|
457
|
+
};
|
|
458
|
+
export type { TFocusOptionsLegacy };
|
|
459
|
+
export type TFocusOptionsLegacySerializable = Omit<TFocusOptionsLegacy, 'nodes' | 'polygons'> & {
|
|
460
|
+
nodes: (MappedinNode | MappedinNode['id'])[];
|
|
461
|
+
polygons: (MappedinPolygon['id'] | MappedinPolygon)[];
|
|
462
|
+
};
|
|
463
|
+
export type TMapViewRNOptions = {
|
|
464
|
+
/**
|
|
465
|
+
* Use a bundle for venue loading and cache it for faster subsequent loading
|
|
466
|
+
* @beta
|
|
467
|
+
*/
|
|
468
|
+
useBundle?: boolean;
|
|
469
|
+
loadOptions?: {
|
|
470
|
+
/**
|
|
471
|
+
* By default, the SDK will merge all geometries by material to reduce the number of draw calls to the GPU
|
|
472
|
+
* To rever back to using a single geometry for every polygon, pass `MAP_RENDER_MODE.MULTI_GEOMETRY`
|
|
473
|
+
*/
|
|
474
|
+
mapRenderStrategy?: MAP_RENDER_MODE;
|
|
475
|
+
};
|
|
476
|
+
/**
|
|
477
|
+
* Generate a search index for venue when rendering map, instead of deferring to when the first search occurs.
|
|
478
|
+
* @default false
|
|
479
|
+
*/
|
|
480
|
+
prepareSearch?: boolean;
|
|
481
|
+
/**
|
|
482
|
+
* Customize search weights
|
|
483
|
+
*/
|
|
484
|
+
searchOptions?: TMappedinOfflineSearchOptions;
|
|
485
|
+
};
|
|
486
|
+
export type TMappedinOfflineSearchBridgeResult = Omit<TMappedinOfflineSearchResult, 'object'> & {
|
|
487
|
+
object: {
|
|
488
|
+
type: 'MappedinLocation' | 'MappedinCategory' | 'Custom';
|
|
489
|
+
id: string;
|
|
490
|
+
};
|
|
491
|
+
};
|
|
492
|
+
export type TMappedinCustomSearchObject = MappedinLocation | MappedinCategory | Record<string, unknown>;
|
|
493
|
+
}
|
|
494
|
+
|
|
419
495
|
declare module '@mappedin/react-native-sdk/wrappers/common/errors' {
|
|
420
496
|
export enum ERROR {
|
|
421
497
|
LOAD_VENUE_FAILED = "LOAD_VENUE_FAILED",
|
|
@@ -437,19 +513,21 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src' {
|
|
|
437
513
|
export type { TMiMiniMapProps } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMiniMap';
|
|
438
514
|
export type { MapViewStore } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store';
|
|
439
515
|
export { getVenue, getVenueBundle } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
440
|
-
export type { TGetVenueOptions, TGetVenueBundleOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
516
|
+
export type { TGetVenueOptions, TGetVenueBundleOptions, TMappedinOfflineSearchResult, TMappedinOfflineSearchSuggestions, TMappedinOfflineSearchOptions, TMappedinOfflineSearchAllOptions, TMappedinOfflineAllSearchMatch } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
441
517
|
export { STATE } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
442
|
-
export { COLLISION_RANKING_TIERS, MARKER_ANCHOR, E_BLUEDOT_STATE, MappedinCoordinate, labelThemes, E_BLUEDOT_MARKER_STATE, E_BLUEDOT_STATE_REASON } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
518
|
+
export { COLLISION_RANKING_TIERS, MARKER_ANCHOR, E_BLUEDOT_STATE, MappedinCoordinate, labelThemes, E_BLUEDOT_MARKER_STATE, E_BLUEDOT_STATE_REASON, MAP_RENDER_MODE } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
443
519
|
export type { TSerializableJourneyOptions, TMiMapViewOptions } from '@mappedin/react-native-sdk/wrappers/common';
|
|
444
520
|
import type { TEnableBlueDotOptions as TEnableBlueDotOptionsBase, TLabelAllLocationCommonOptions as TLabelAllLocationCommonOptionsBase } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
445
|
-
export type { TJourneyOptions, TGeolocationObject, TPathOptions, TFlatLabelPolygonOptions, TFloatingLabelPolygonOptions, TLabelAllLocationFlatLabelOptions, TLabelAllLocationFloatingLabelOptions, TFlatLabelAppearance, TFloatingLabelAppearance, TFocusOnCameraOptions, TFocusOnTargets, TCommonLabelOptions, TCameraAnimationOptions, TFocusOnOptions, TAnimatePositionOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
521
|
+
export type { TJourneyOptions, TGeolocationObject, TPathOptions, TFlatLabelPolygonOptions, TFloatingLabelPolygonOptions, TLabelAllLocationFlatLabelOptions, TLabelAllLocationFloatingLabelOptions, TFlatLabelAppearance, TFloatingLabelAppearance, TFocusOnCameraOptions, TFocusOnTargets, TCommonLabelOptions, TCameraAnimationOptions, TFocusOnOptions, TAnimatePositionOptions, TBlueDotPositionUpdate, TBlueDotStateChange } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
446
522
|
export type { TEnableBlueDotOptionsBase, TLabelAllLocationCommonOptionsBase };
|
|
447
523
|
export type TEnableBlueDotOptions = Omit<TEnableBlueDotOptionsBase, 'positionUpdater' | 'geolocationSource'>;
|
|
448
524
|
export type TLabelAllLocationCommonOptions = Omit<TLabelAllLocationCommonOptionsBase, 'sortFunction' | 'translationMap'>;
|
|
525
|
+
export type { TMapViewRNOptions } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store.types';
|
|
526
|
+
export type { TMiMapViewVenueOptions } from '@mappedin/react-native-sdk/wrappers/common';
|
|
449
527
|
export type { IDirectionsResult, MappedinDirections, TMappedinDirective } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
450
|
-
export type { TShowVenueOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
528
|
+
export type { TShowVenueOptions, E_GET_DIRECTIONS_MESSAGES } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
451
529
|
export { ERROR, ERROR_MESSAGES } from '@mappedin/react-native-sdk/wrappers/common/errors';
|
|
452
|
-
export {
|
|
530
|
+
export { BEARING_TYPE, ACTION_TYPE, MappedinLocation, Mappedin, MappedinPolygon, MappedinNode, MappedinCategory, MappedinMap, MappedinEvent, MappedinMapGroup, MappedinVenue, MappedinVortex, MappedinRankings, MappedinDestinationSet } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
453
531
|
}
|
|
454
532
|
|
|
455
533
|
declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MappedinController' {
|
|
@@ -496,26 +574,24 @@ declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/Mappedi
|
|
|
496
574
|
}
|
|
497
575
|
}
|
|
498
576
|
|
|
499
|
-
declare module '@mappedin/react-native-sdk/wrappers/react-native-sdk/src/MiMapView.store.types' {
|
|
500
|
-
import { MappedinNode, MappedinPolygon } from '@mappedin/react-native-sdk/wrappers/react-native-sdk/src';
|
|
501
|
-
import { TFocusOptionsLegacy } from '@mappedin/react-native-sdk/core/packages/renderer/Core.interface';
|
|
502
|
-
export type TPolygonColorOptions = {
|
|
503
|
-
color: string;
|
|
504
|
-
opacity?: number;
|
|
505
|
-
textColor?: string;
|
|
506
|
-
};
|
|
507
|
-
export type { TFocusOptionsLegacy };
|
|
508
|
-
export type TFocusOptionsLegacySerializable = Omit<TFocusOptionsLegacy, 'nodes' | 'polygons'> & {
|
|
509
|
-
nodes: (MappedinNode | MappedinNode['id'])[];
|
|
510
|
-
polygons: (MappedinPolygon['id'] | MappedinPolygon)[];
|
|
511
|
-
};
|
|
512
|
-
}
|
|
513
|
-
|
|
514
577
|
declare module '@mappedin/react-native-sdk/core/packages/get-venue' {
|
|
515
578
|
import type { TGetVenueOptions } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.types';
|
|
516
579
|
import { Mappedin } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin';
|
|
580
|
+
/**
|
|
581
|
+
* This is how we can avoid bundling in node-fetch (via isomorphic fetch),
|
|
582
|
+
* which keeps popping up in security advisories
|
|
583
|
+
* This is a pattern that most isomorphic libraries appear to use,
|
|
584
|
+
* where when running in node, you can pass your own fetch function
|
|
585
|
+
* as one is not provided by Node.js.
|
|
586
|
+
*
|
|
587
|
+
*/
|
|
588
|
+
export function isomorphicFetch(): Window['fetch'];
|
|
589
|
+
/**
|
|
590
|
+
* Overwrite the internal `fetch` function with your own. Typically for use in Node.js and Jest
|
|
591
|
+
*/
|
|
592
|
+
export function setFetchFn(fetchFn: any): void;
|
|
517
593
|
/** Classes */
|
|
518
|
-
export { Mappedin } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin';
|
|
594
|
+
export { Mappedin, MappedinCollectionType } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin';
|
|
519
595
|
export { MappedinLocation } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinLocation';
|
|
520
596
|
export { MappedinPolygon } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinPolygon';
|
|
521
597
|
export { MappedinNode } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinNode';
|
|
@@ -535,9 +611,12 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue' {
|
|
|
535
611
|
export type { IDirectionsResult } from '@mappedin/react-native-sdk/core/packages/navigator';
|
|
536
612
|
export type { TOperationHoursMap } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinLocation';
|
|
537
613
|
export type { TDirectionToOptions } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinNavigatable';
|
|
614
|
+
export { OfflineSearch } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.OfflineSearch';
|
|
615
|
+
export type { TMappedinOfflineSearchOptions, TMappedinOfflineSearchResult, TMappedinOfflineSearchSuggestions, TMappedinOfflineAllSearchMatch, TMappedinOfflineSearchAllOptions } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.OfflineSearch';
|
|
538
616
|
/** API data types */
|
|
539
617
|
export type { TLocationType, TNode, TImage, TLogo, TGalleryImage, TPhone, TSocial, TColor, TVortex, TPicture, TOpeningHours, TSiblingGroup, TState, TCategory, TEvent, TGeoReference, TMap, TMapGroup, TBuilding, TLocation, TPolygon, TPolygonRanking, TVenue, TMappedinAPI } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.API.types';
|
|
540
618
|
export type { TGetVenueOptions } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.types';
|
|
619
|
+
import { MAP_RENDER_MODE } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.types';
|
|
541
620
|
export type TShowVenueOptions = {
|
|
542
621
|
/**
|
|
543
622
|
* Sets the initial background color of the map, including while loading.
|
|
@@ -549,14 +628,24 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue' {
|
|
|
549
628
|
*/
|
|
550
629
|
backgroundAlpha?: number;
|
|
551
630
|
/**
|
|
552
|
-
* Whether or not to display
|
|
631
|
+
* Whether or not to display default styled Floating Labels initially
|
|
553
632
|
*/
|
|
554
633
|
labelAllLocationsOnInit?: boolean;
|
|
555
634
|
/**
|
|
556
635
|
* The id of the first map to show on map load
|
|
557
636
|
*/
|
|
558
637
|
firstMapId?: string;
|
|
638
|
+
loadOptions?: {
|
|
639
|
+
/**
|
|
640
|
+
* Set the map render strategy in order to optimize FPS
|
|
641
|
+
*
|
|
642
|
+
* @beta
|
|
643
|
+
*/
|
|
644
|
+
mapRenderStrategy?: MAP_RENDER_MODE;
|
|
645
|
+
};
|
|
559
646
|
};
|
|
647
|
+
export { MAP_RENDER_MODE };
|
|
648
|
+
export function getVenueMVF(userOptions: TGetVenueBundleOptions): Promise<Mappedin>;
|
|
560
649
|
/**
|
|
561
650
|
* Get Venue Data for a Mappedin Venue
|
|
562
651
|
*/
|
|
@@ -593,6 +682,31 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue' {
|
|
|
593
682
|
url: any;
|
|
594
683
|
updated_at: any;
|
|
595
684
|
}): Promise<Mappedin>;
|
|
685
|
+
/**
|
|
686
|
+
* Get the bundle URL and updated_at time.
|
|
687
|
+
* @internal
|
|
688
|
+
*/
|
|
689
|
+
export function getVenueMVFURL(userOptions: TGetVenueBundleOptions): Promise<{
|
|
690
|
+
url: string;
|
|
691
|
+
updated_at: string;
|
|
692
|
+
}>;
|
|
693
|
+
/**
|
|
694
|
+
* @internal
|
|
695
|
+
*/
|
|
696
|
+
export function downloadVenueBundleMVF(options: TGetVenueBundleOptions,
|
|
697
|
+
/**
|
|
698
|
+
* use Web Workers to speed up MVF parsing. This is likely only benefitial for larger venues,
|
|
699
|
+
* and may be determental to smaller ones, hence it is off by default
|
|
700
|
+
*/
|
|
701
|
+
useWorker?: boolean): Promise<unknown>;
|
|
702
|
+
}
|
|
703
|
+
|
|
704
|
+
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/random-id' {
|
|
705
|
+
/**
|
|
706
|
+
* Returns a UUIDv4-like ID without relying on a CSPRNG as we don't need it for these purposes.
|
|
707
|
+
* @hidden
|
|
708
|
+
*/
|
|
709
|
+
export const randomId: () => string;
|
|
596
710
|
}
|
|
597
711
|
|
|
598
712
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums' {
|
|
@@ -625,30 +739,30 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums'
|
|
|
625
739
|
CUSTOM_GEOLOCATION_PROVIDER_ERROR = 3
|
|
626
740
|
}
|
|
627
741
|
/**
|
|
628
|
-
What we currently know about the user's position
|
|
742
|
+
What we currently know about the user's position and how confident we are.
|
|
629
743
|
*/
|
|
630
744
|
export enum E_BLUEDOT_STATE {
|
|
631
745
|
/**
|
|
632
|
-
*
|
|
746
|
+
* Not listening to Blue Dot position updates
|
|
633
747
|
*/
|
|
634
748
|
NOT_LISTENING = 0,
|
|
635
749
|
/**
|
|
636
|
-
*
|
|
750
|
+
* Listenign for listening to position updates but have not yet received a position
|
|
637
751
|
*/
|
|
638
752
|
LISTENING = 1,
|
|
639
753
|
/**
|
|
640
|
-
*
|
|
754
|
+
* Received relevant positions and user is in the venue
|
|
641
755
|
*/
|
|
642
756
|
HAS_POSITION = 2,
|
|
643
757
|
/**
|
|
644
758
|
* We've received a relevant position, and we have enough information to determine
|
|
645
759
|
* which floor the user is on - either because we received a floor level, the venue
|
|
646
|
-
* only has one floor
|
|
760
|
+
* only has one floor or we're allowing implicit floor level detection.
|
|
647
761
|
*/
|
|
648
762
|
HAS_INDOOR_POSITION = 3,
|
|
649
763
|
/**
|
|
650
764
|
* We are uncertain about the user's position, likely because we haven't received
|
|
651
|
-
* a relevant position in a while
|
|
765
|
+
* a relevant position in a while. Blue Dot will be rendered grey to indicate uncertainty of the actual position.
|
|
652
766
|
*/
|
|
653
767
|
LOCATION_UNCERTAIN = 4
|
|
654
768
|
}
|
|
@@ -657,26 +771,29 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums'
|
|
|
657
771
|
*/
|
|
658
772
|
export enum E_BLUEDOT_MARKER_STATE {
|
|
659
773
|
/**
|
|
660
|
-
*
|
|
774
|
+
* Blue Dot is hidden
|
|
661
775
|
*/
|
|
662
776
|
HIDDEN = 0,
|
|
663
777
|
/**
|
|
664
|
-
*
|
|
778
|
+
* Blue Dot is transparent indicating the position is on a different floor
|
|
665
779
|
*/
|
|
666
780
|
GHOST = 1,
|
|
667
781
|
/**
|
|
668
|
-
*
|
|
782
|
+
* Blue Dot is visible and opaque indicating accurate positioning on the current floor
|
|
669
783
|
*/
|
|
670
784
|
NORMAL = 2,
|
|
671
785
|
/**
|
|
672
|
-
*
|
|
786
|
+
* Blue Dot is grayed out due to uncertainty about user's location, most likely due to not receiving recent position updates.
|
|
673
787
|
*/
|
|
674
788
|
UNCERTAIN = 3
|
|
675
789
|
}
|
|
676
790
|
export enum STATE {
|
|
791
|
+
/**
|
|
792
|
+
* The map is in exploration mode where the user controls the camera position.
|
|
793
|
+
*/
|
|
677
794
|
EXPLORE = "explore",
|
|
678
795
|
/**
|
|
679
|
-
*
|
|
796
|
+
* Follows user's current location by keeping the camera centered on the Blue Dot.
|
|
680
797
|
*/
|
|
681
798
|
FOLLOW = "follow"
|
|
682
799
|
/**
|
|
@@ -692,19 +809,19 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums'
|
|
|
692
809
|
}
|
|
693
810
|
export enum E_SDK_EVENT {
|
|
694
811
|
/**
|
|
695
|
-
* Emitted when the map is clicked
|
|
812
|
+
* Emitted when the map is clicked or tapped on a touch screen.
|
|
696
813
|
*/
|
|
697
814
|
CLICK = "CLICK",
|
|
698
815
|
/**
|
|
699
|
-
* Emitted when the {@link STATE | SDK state} changes
|
|
816
|
+
* Emitted when the {@link STATE | SDK state} changes.
|
|
700
817
|
*/
|
|
701
818
|
STATE_CHANGE = "STATE_CHANGE",
|
|
702
819
|
/**
|
|
703
|
-
* Emitted when
|
|
820
|
+
* Emitted when an interactive {@link MappedinPolygon | polygon} is clicked
|
|
704
821
|
*/
|
|
705
822
|
POLYGON_CLICKED = "POLYGON_CLICKED",
|
|
706
823
|
/**
|
|
707
|
-
* Emitted when nothing is clicked
|
|
824
|
+
* Emitted when nothing (outside of interactive polygons) is clicked
|
|
708
825
|
*/
|
|
709
826
|
NOTHING_CLICKED = "NOTHING_CLICKED",
|
|
710
827
|
/**
|
|
@@ -725,6 +842,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums'
|
|
|
725
842
|
ROTATION_CHANGED = "ROTATION_CHANGED",
|
|
726
843
|
TILT_CHANGED = "TILT_CHANGED"
|
|
727
844
|
}
|
|
845
|
+
export { MAP_RENDER_MODE } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
728
846
|
}
|
|
729
847
|
|
|
730
848
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types' {
|
|
@@ -734,7 +852,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
734
852
|
import { TBlueDotPositionUpdate, TBlueDotStateChange } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.BlueDot/Mappedin.BlueDot.core';
|
|
735
853
|
import { TOOLTIP_ANCHOR } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartTooltip';
|
|
736
854
|
import type { Euler, Object3D, Vector3 } from 'three';
|
|
737
|
-
import { GEOLOCATION_STATUS, COLLISION_RANKING_TIERS, STATE, MARKER_ANCHOR, E_SDK_EVENT, E_BLUEDOT_EVENT, E_CAMERA_EVENT } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums';
|
|
855
|
+
import { GEOLOCATION_STATUS, COLLISION_RANKING_TIERS, STATE, MARKER_ANCHOR, E_SDK_EVENT, E_BLUEDOT_EVENT, E_CAMERA_EVENT, MAP_RENDER_MODE } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums';
|
|
738
856
|
export type { TEnableBlueDotOptions, TFloatingLabelAppearance };
|
|
739
857
|
/**
|
|
740
858
|
An extension of the GeolocationPosition type.
|
|
@@ -1004,19 +1122,27 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1004
1122
|
scale?: Vector3;
|
|
1005
1123
|
};
|
|
1006
1124
|
export type TMapViewOptions = {
|
|
1125
|
+
/**
|
|
1126
|
+
* Background color of the map in hex number or string e.g. `0x2e2e2e` or `#2e2e2e`.
|
|
1127
|
+
*/
|
|
1007
1128
|
backgroundColor?: number | string;
|
|
1008
1129
|
/**
|
|
1009
1130
|
* The opacity of the initial background color.
|
|
1010
1131
|
*/
|
|
1011
1132
|
backgroundAlpha?: number;
|
|
1012
1133
|
/**
|
|
1013
|
-
* Controls whether antialiasing is on. Defaults to true
|
|
1134
|
+
* Controls whether antialiasing is on. Defaults to `true`, as long as devicePixelRatio is 1. This is very expensive on high resolution screens.
|
|
1014
1135
|
* @default true
|
|
1015
1136
|
*/
|
|
1016
1137
|
antialias?: boolean;
|
|
1017
1138
|
disableHover?: boolean;
|
|
1018
1139
|
disableZoomOnMapSizeChange?: boolean;
|
|
1019
1140
|
loadOptions?: {
|
|
1141
|
+
/**
|
|
1142
|
+
* By default, the SDK will merge all geometries by material to reduce the number of draw calls to the GPU
|
|
1143
|
+
* To rever back to using a single geometry for every polygon, pass `MAP_RENDER_MODE.MULTI_GEOMETRY`
|
|
1144
|
+
*/
|
|
1145
|
+
mapRenderStrategy?: MAP_RENDER_MODE;
|
|
1020
1146
|
async?: boolean;
|
|
1021
1147
|
zoomOverrides?: {
|
|
1022
1148
|
zoomMultiplier?: number;
|
|
@@ -1025,7 +1151,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1025
1151
|
};
|
|
1026
1152
|
};
|
|
1027
1153
|
/**
|
|
1028
|
-
*
|
|
1154
|
+
* First map to be rendered
|
|
1029
1155
|
*/
|
|
1030
1156
|
firstMap?: MappedinMap | string;
|
|
1031
1157
|
/**
|
|
@@ -1044,6 +1170,9 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1044
1170
|
onWebGLRendererError?: () => void;
|
|
1045
1171
|
};
|
|
1046
1172
|
export type TMapViewOptionsLegacy = {
|
|
1173
|
+
/**
|
|
1174
|
+
* Background color of the map in hex number or string e.g. `0x2e2e2e` or `#2e2e2e`.
|
|
1175
|
+
*/
|
|
1047
1176
|
backgroundColor?: number | string;
|
|
1048
1177
|
/**
|
|
1049
1178
|
* The opacity of the initial background color.
|
|
@@ -1077,7 +1206,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1077
1206
|
};
|
|
1078
1207
|
};
|
|
1079
1208
|
/**
|
|
1080
|
-
*
|
|
1209
|
+
* First map to be rendered
|
|
1081
1210
|
*/
|
|
1082
1211
|
firstMap?: MappedinMap | string;
|
|
1083
1212
|
/**
|
|
@@ -1147,21 +1276,21 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1147
1276
|
*/
|
|
1148
1277
|
height?: number;
|
|
1149
1278
|
/**
|
|
1150
|
-
* The amount of space to leave before starting the text
|
|
1279
|
+
* The amount of space to leave before starting the text in pixels
|
|
1151
1280
|
* @default 5
|
|
1152
1281
|
*/
|
|
1153
1282
|
margin?: number;
|
|
1154
1283
|
/**
|
|
1155
|
-
*
|
|
1284
|
+
* Optional color in hexadecimal string e.g. `#2e2e2e`.
|
|
1156
1285
|
*/
|
|
1157
1286
|
color?: string;
|
|
1158
1287
|
/**
|
|
1159
|
-
*
|
|
1288
|
+
* Size of the font in pixels.
|
|
1160
1289
|
* @default 12
|
|
1161
1290
|
*/
|
|
1162
1291
|
fontSize?: number;
|
|
1163
1292
|
/**
|
|
1164
|
-
* A CSS style string font.
|
|
1293
|
+
* A CSS style string font, e.g. "sans-serif". You can specify your own font via @font-face rule with a font family, and then include that here.
|
|
1165
1294
|
*/
|
|
1166
1295
|
font?: string;
|
|
1167
1296
|
/**
|
|
@@ -1170,7 +1299,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1170
1299
|
*/
|
|
1171
1300
|
scaleMin?: number;
|
|
1172
1301
|
/**
|
|
1173
|
-
* How much to decrement the scale each time it doesn't fit, so we don't end up with too many different font sizes on screen at once. If
|
|
1302
|
+
* How much to decrement the scale each time it doesn't fit, so we don't end up with too many different font sizes on screen at once. If you are only labeling a few {@link MappedinPolygon}s rather than everything,
|
|
1174
1303
|
* you can set this and and scaleMin to 0.1 to fit everything except really long names perfectly.
|
|
1175
1304
|
* @default 0.25
|
|
1176
1305
|
*/
|
|
@@ -1180,7 +1309,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1180
1309
|
scale?: number;
|
|
1181
1310
|
flatLabels?: false | undefined;
|
|
1182
1311
|
/**
|
|
1183
|
-
*
|
|
1312
|
+
* Ranking tier to determine how likely a {@link FloatingLabel} will appear
|
|
1184
1313
|
*/
|
|
1185
1314
|
rank?: COLLISION_RANKING_TIERS | number;
|
|
1186
1315
|
/**
|
|
@@ -1215,7 +1344,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1215
1344
|
[key in string]: string;
|
|
1216
1345
|
};
|
|
1217
1346
|
/**
|
|
1218
|
-
* Display label despite the
|
|
1347
|
+
* Display label despite the {@link MappedinPolygon} having an image on it. Often these images represent store logos.
|
|
1219
1348
|
* @default false
|
|
1220
1349
|
*/
|
|
1221
1350
|
createDespiteImage?: boolean;
|
|
@@ -1250,7 +1379,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView.types'
|
|
|
1250
1379
|
longitude: number;
|
|
1251
1380
|
};
|
|
1252
1381
|
/**
|
|
1253
|
-
* A list of
|
|
1382
|
+
* A list of {@link MappedinPolygon}s corresponding to every polygon that a user's
|
|
1254
1383
|
* click passed through. These are in order of first to last intersected.
|
|
1255
1384
|
* Will be empty if no interactive polygons were clicked.
|
|
1256
1385
|
*/
|
|
@@ -1340,6 +1469,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/Camera' {
|
|
|
1340
1469
|
zoom?: number;
|
|
1341
1470
|
tilt?: number;
|
|
1342
1471
|
rotation?: number;
|
|
1472
|
+
position?: MappedinCoordinate | MappedinNode;
|
|
1343
1473
|
};
|
|
1344
1474
|
export const ANIMATION_TWEENS: {
|
|
1345
1475
|
linear: any;
|
|
@@ -1354,6 +1484,9 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/Camera' {
|
|
|
1354
1484
|
EASE_IN_OUT = "ease-in-out"
|
|
1355
1485
|
}
|
|
1356
1486
|
export type TCameraAnimationOptions = {
|
|
1487
|
+
/**
|
|
1488
|
+
* Animation duration in milliseconds
|
|
1489
|
+
*/
|
|
1357
1490
|
duration?: number;
|
|
1358
1491
|
easing?: CAMERA_EASING_MODE;
|
|
1359
1492
|
};
|
|
@@ -1390,29 +1523,66 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/Camera' {
|
|
|
1390
1523
|
*/
|
|
1391
1524
|
get zoom(): number;
|
|
1392
1525
|
/**
|
|
1393
|
-
* Current Camera rotation (in radians)
|
|
1526
|
+
* Current Camera rotation (in radians) from north
|
|
1394
1527
|
*/
|
|
1395
1528
|
get rotation(): number;
|
|
1396
1529
|
/**
|
|
1397
|
-
* Current
|
|
1530
|
+
* Current camera tilt angle (in radians), relative to a top-down view.
|
|
1531
|
+
*
|
|
1532
|
+
* ex: 0 means the camera is facing top-down, π/2 means the camera is
|
|
1533
|
+
* facing directly from the side.
|
|
1398
1534
|
*/
|
|
1399
1535
|
get tilt(): number;
|
|
1400
1536
|
/**
|
|
1401
|
-
*
|
|
1537
|
+
* Get the minimum distance (in meters) the camera is allowed to get to the ground.
|
|
1402
1538
|
*/
|
|
1403
1539
|
get minZoom(): number;
|
|
1404
1540
|
/**
|
|
1405
|
-
*
|
|
1541
|
+
* Set the minimum distance (in meters) the camera is allowed to get to the ground.
|
|
1406
1542
|
*/
|
|
1407
1543
|
set minZoom(meters: number);
|
|
1408
1544
|
/**
|
|
1409
|
-
*
|
|
1545
|
+
* Get the maximum distance (in meters) the camera is allowed to get from the ground.
|
|
1410
1546
|
*/
|
|
1411
1547
|
get maxZoom(): number;
|
|
1412
1548
|
/**
|
|
1413
|
-
*
|
|
1549
|
+
* Set the maximum distance (in meters) the camera is allowed to get from the ground.
|
|
1414
1550
|
*/
|
|
1415
1551
|
set maxZoom(meters: number);
|
|
1552
|
+
/**
|
|
1553
|
+
* Get the current maximum tilt angle (in radians) the camera is allowed to use.
|
|
1554
|
+
*/
|
|
1555
|
+
get maxTilt(): number;
|
|
1556
|
+
/**
|
|
1557
|
+
* Sets the maximum tilt angle (in radians) the camera is allowed to use.
|
|
1558
|
+
*
|
|
1559
|
+
* Tilt angle must be between 0 and π/2 radians. It will be clamped within
|
|
1560
|
+
* this range if it exceeds it on either end.
|
|
1561
|
+
*
|
|
1562
|
+
* As tilt angle approaches π/2 radians, this will impact overall touch controls
|
|
1563
|
+
* and should be used sparingly.
|
|
1564
|
+
*/
|
|
1565
|
+
set maxTilt(radians: number);
|
|
1566
|
+
/**
|
|
1567
|
+
* Get the current camera position, which is at the center of the map.
|
|
1568
|
+
* @returns the position as a coordinate
|
|
1569
|
+
*/
|
|
1570
|
+
get position(): MappedinCoordinate;
|
|
1571
|
+
/**
|
|
1572
|
+
* User camera interactions
|
|
1573
|
+
*/
|
|
1574
|
+
interactions: {
|
|
1575
|
+
/**
|
|
1576
|
+
* Enable all user interactions. This does not affect programmatic
|
|
1577
|
+
* Camera controls, such as `set` and `focusOn`
|
|
1578
|
+
*/
|
|
1579
|
+
enable: () => void;
|
|
1580
|
+
/**
|
|
1581
|
+
* Disable all user interactions. This does not affect programmatic
|
|
1582
|
+
* Camera controls, such as `set` and `focusOn`
|
|
1583
|
+
*/
|
|
1584
|
+
disable: () => void;
|
|
1585
|
+
};
|
|
1416
1586
|
setSafeAreaInsets(insets: {
|
|
1417
1587
|
top: number;
|
|
1418
1588
|
left: number;
|
|
@@ -1421,7 +1591,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/Camera' {
|
|
|
1421
1591
|
}): void;
|
|
1422
1592
|
getSafeAreaInsets(): any;
|
|
1423
1593
|
/**
|
|
1424
|
-
*
|
|
1594
|
+
* Focus the Camera view on a collection of targets and animate to that state.
|
|
1425
1595
|
* @returns a Promise that resolves when the animation finishes, or rejects when it is cancelled.
|
|
1426
1596
|
*/
|
|
1427
1597
|
focusOn(options: TFocusOnOptions): Promise<any>;
|
|
@@ -1431,7 +1601,6 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/Camera' {
|
|
|
1431
1601
|
set(positionOptions?: TAnimatePositionOptions): void;
|
|
1432
1602
|
/**
|
|
1433
1603
|
* Animate the Camera's view to smoothly transition to a new state over time.
|
|
1434
|
-
* Returns a promise that resolves when the animation completes and gets rejected if the animation is cancelled.
|
|
1435
1604
|
*
|
|
1436
1605
|
* @returns a Promise that resolves when the animation finishes, or rejects when it is cancelled.
|
|
1437
1606
|
*/
|
|
@@ -1520,7 +1689,10 @@ declare module '@mappedin/react-native-sdk/wrappers/common/events' {
|
|
|
1520
1689
|
CLEAR_JOURNEY = "CLEAR_JOURNEY",
|
|
1521
1690
|
SET_COOKIE = "SET_COOKIE",
|
|
1522
1691
|
GET_NEAREST_NODE_BY_SCREEN_COORDINATES = "GET_NEAREST_NODE_BY_SCREEN_COORDINATES",
|
|
1523
|
-
CLEAR_BUNDLE_CACHE = "CLEAR_BUNDLE_CACHE"
|
|
1692
|
+
CLEAR_BUNDLE_CACHE = "CLEAR_BUNDLE_CACHE",
|
|
1693
|
+
SEARCH = "SEARCH",
|
|
1694
|
+
SUGGEST = "SUGGEST",
|
|
1695
|
+
ADD_SEARCH_QUERY = "ADD_SEARCH_QUERY"
|
|
1524
1696
|
}
|
|
1525
1697
|
export enum WAYFINDING_EVENT {
|
|
1526
1698
|
GET_MAPS_IN_NAVIGATION = "GET_MAPS_IN_NAVIGATION",
|
|
@@ -1550,7 +1722,7 @@ declare module '@mappedin/react-native-sdk/wrappers/common/events' {
|
|
|
1550
1722
|
}
|
|
1551
1723
|
|
|
1552
1724
|
declare module '@mappedin/react-native-sdk/wrappers/common/payloads' {
|
|
1553
|
-
import { IDirectionsResult, MappedinMap, MappedinNode, TBlueDotPositionUpdate, TBlueDotStateChange, TGetVenueOptions, TFloatingLabelPolygonOptions, TFlatLabelPolygonOptions, TAnimatePositionOptions, TPathOptions, TShowVenueOptions, STATE, TGeolocationObject, TEnableBlueDotOptions, MappedinLocation, TLabelAllLocationFloatingLabelOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
1725
|
+
import { IDirectionsResult, MappedinMap, MappedinNode, TBlueDotPositionUpdate, TBlueDotStateChange, TGetVenueOptions, TFloatingLabelPolygonOptions, TFlatLabelPolygonOptions, TAnimatePositionOptions, TPathOptions, TShowVenueOptions, STATE, TGeolocationObject, TEnableBlueDotOptions, MappedinLocation, TLabelAllLocationFloatingLabelOptions, TMappedinOfflineSearchOptions } from '@mappedin/react-native-sdk/core/packages/renderer/index.rn';
|
|
1554
1726
|
import { TMiMapViewOptions } from '@mappedin/react-native-sdk/wrappers/common/types';
|
|
1555
1727
|
import { BRIDGE_EVENT, EVENT, MINIMAP_EVENT, TFocusOnOptionsLegacySerializable, TReactNativeFlatLabelAllLocationsLegacy, TReactNativeFlatLabelAllLocations, NATIVE_EVENT } from '@mappedin/react-native-sdk/wrappers/common';
|
|
1556
1728
|
import { TSerializableJourneyOptions, TFocusOnOptionsSerializable, TSerializedLocation, TSerializedNode, TSerializedPolygon } from '@mappedin/react-native-sdk/wrappers/common/types';
|
|
@@ -1624,12 +1796,32 @@ declare module '@mappedin/react-native-sdk/wrappers/common/payloads' {
|
|
|
1624
1796
|
options: TGetVenueOptions & {
|
|
1625
1797
|
useBundle?: boolean;
|
|
1626
1798
|
};
|
|
1627
|
-
showVenueOptions: TShowVenueOptions
|
|
1799
|
+
showVenueOptions: TShowVenueOptions & {
|
|
1800
|
+
/**
|
|
1801
|
+
* Generate a search index for venue when rendering map, instead of deferring to when the first search occurs.
|
|
1802
|
+
* @default false
|
|
1803
|
+
*/
|
|
1804
|
+
prepareSearch?: boolean;
|
|
1805
|
+
/**
|
|
1806
|
+
* Customize search weights
|
|
1807
|
+
*/
|
|
1808
|
+
searchOptions?: TMappedinOfflineSearchOptions;
|
|
1809
|
+
};
|
|
1628
1810
|
};
|
|
1629
1811
|
[EVENT.SHOW_VENUE]: {
|
|
1630
1812
|
venueData: string;
|
|
1631
1813
|
format: 'jsonstring';
|
|
1632
|
-
showVenueOptions: TShowVenueOptions
|
|
1814
|
+
showVenueOptions: TShowVenueOptions & {
|
|
1815
|
+
/**
|
|
1816
|
+
* Generate a search index for venue when rendering map, instead of deferring to when the first search occurs.
|
|
1817
|
+
* @default false
|
|
1818
|
+
*/
|
|
1819
|
+
prepareSearch?: boolean;
|
|
1820
|
+
/**
|
|
1821
|
+
* Customize search weights
|
|
1822
|
+
*/
|
|
1823
|
+
searchOptions?: TMappedinOfflineSearchOptions;
|
|
1824
|
+
};
|
|
1633
1825
|
};
|
|
1634
1826
|
[EVENT.SET_MAP]: {
|
|
1635
1827
|
mapId: string;
|
|
@@ -1756,6 +1948,20 @@ declare module '@mappedin/react-native-sdk/wrappers/common/payloads' {
|
|
|
1756
1948
|
y: number;
|
|
1757
1949
|
map?: MappedinMap['id'];
|
|
1758
1950
|
};
|
|
1951
|
+
[EVENT.SEARCH]: {
|
|
1952
|
+
query: string;
|
|
1953
|
+
};
|
|
1954
|
+
[EVENT.SUGGEST]: {
|
|
1955
|
+
query: string;
|
|
1956
|
+
};
|
|
1957
|
+
[EVENT.ADD_SEARCH_QUERY]: {
|
|
1958
|
+
query: string;
|
|
1959
|
+
object: {
|
|
1960
|
+
type: 'MappedinLocation' | 'MappedinCategory' | 'Custom';
|
|
1961
|
+
id: string;
|
|
1962
|
+
};
|
|
1963
|
+
weight?: number;
|
|
1964
|
+
};
|
|
1759
1965
|
};
|
|
1760
1966
|
}
|
|
1761
1967
|
|
|
@@ -1790,7 +1996,7 @@ declare module '@mappedin/react-native-sdk/wrappers/common/types' {
|
|
|
1790
1996
|
departureMarkerTemplateString?: string;
|
|
1791
1997
|
color?: string;
|
|
1792
1998
|
};
|
|
1793
|
-
export type
|
|
1999
|
+
export type TMiMapViewVenueOptions = {
|
|
1794
2000
|
/**
|
|
1795
2001
|
* Client ID
|
|
1796
2002
|
*/
|
|
@@ -1811,6 +2017,7 @@ declare module '@mappedin/react-native-sdk/wrappers/common/types' {
|
|
|
1811
2017
|
noAuth?: boolean;
|
|
1812
2018
|
language?: string;
|
|
1813
2019
|
};
|
|
2020
|
+
export type TMiMapViewOptions = TShowVenueOptions & TMiMapViewVenueOptions;
|
|
1814
2021
|
export type TReactNativeFloatingLabelPolygonOptions = TFloatingLabelPolygonOptions & {
|
|
1815
2022
|
/**
|
|
1816
2023
|
* @deprecated
|
|
@@ -1847,142 +2054,363 @@ declare module '@mappedin/react-native-sdk/wrappers/common/pub-sub' {
|
|
|
1847
2054
|
}
|
|
1848
2055
|
}
|
|
1849
2056
|
|
|
1850
|
-
declare module '@mappedin/react-native-sdk/
|
|
1851
|
-
import {
|
|
1852
|
-
import {
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1856
|
-
|
|
1857
|
-
|
|
1858
|
-
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1866
|
-
|
|
1867
|
-
|
|
1868
|
-
|
|
1869
|
-
|
|
1870
|
-
|
|
1871
|
-
|
|
1872
|
-
|
|
1873
|
-
|
|
1874
|
-
|
|
1875
|
-
|
|
1876
|
-
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
|
|
1884
|
-
|
|
1885
|
-
|
|
1886
|
-
|
|
1887
|
-
|
|
1888
|
-
|
|
1889
|
-
|
|
1890
|
-
|
|
1891
|
-
|
|
1892
|
-
|
|
1893
|
-
|
|
1894
|
-
|
|
1895
|
-
|
|
1896
|
-
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
|
|
1914
|
-
|
|
1915
|
-
|
|
1916
|
-
|
|
1917
|
-
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1926
|
-
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1933
|
-
|
|
1934
|
-
|
|
1935
|
-
|
|
1936
|
-
|
|
1937
|
-
|
|
1938
|
-
|
|
1939
|
-
|
|
1940
|
-
|
|
1941
|
-
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
-
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1952
|
-
|
|
1953
|
-
|
|
1954
|
-
|
|
1955
|
-
|
|
1956
|
-
|
|
1957
|
-
|
|
1958
|
-
|
|
1959
|
-
|
|
1960
|
-
|
|
1961
|
-
|
|
1962
|
-
|
|
1963
|
-
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
1968
|
-
|
|
1969
|
-
|
|
1970
|
-
|
|
1971
|
-
|
|
1972
|
-
|
|
1973
|
-
|
|
1974
|
-
|
|
1975
|
-
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
1980
|
-
|
|
1981
|
-
|
|
1982
|
-
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
|
|
2057
|
+
declare module '@mappedin/react-native-sdk/core/packages/renderer/Core.interface' {
|
|
2058
|
+
import { MappedinMap, Mappedin, MappedinCoordinate, MappedinPolygon, MappedinNode } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
2059
|
+
import { Vector2, Vector3 } from 'three';
|
|
2060
|
+
import { changeListenerFn, TMapViewOptions } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.types';
|
|
2061
|
+
import RENDER from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.RenderTasks';
|
|
2062
|
+
import { INTERNAL_EVENT_PAYLOAD } from '@mappedin/react-native-sdk/core/packages/renderer/MapView';
|
|
2063
|
+
import { TPadding } from '@mappedin/react-native-sdk/core/packages/renderer';
|
|
2064
|
+
import Tween, { Easing } from '@tweenjs/tween.js';
|
|
2065
|
+
export type TFocusOptionsLegacy = {
|
|
2066
|
+
/**
|
|
2067
|
+
* An array of Nodes to focus in on
|
|
2068
|
+
*/
|
|
2069
|
+
nodes?: (MappedinNode | MappedinNode['id'])[];
|
|
2070
|
+
/**
|
|
2071
|
+
* An array of Polygons to focus on. It's the center of the bounds of all Polygons, designed to fit everything into view.
|
|
2072
|
+
*/
|
|
2073
|
+
polygons?: (MappedinPolygon | MappedinPolygon['id'])[];
|
|
2074
|
+
/**
|
|
2075
|
+
* The duration (in ms) the focus animation should last for.
|
|
2076
|
+
* @defaultValue `100`
|
|
2077
|
+
*/
|
|
2078
|
+
duration?: number;
|
|
2079
|
+
/**
|
|
2080
|
+
* Whether to zoom the camera in or out, or just pan it.
|
|
2081
|
+
* @defaultValue `true`
|
|
2082
|
+
*/
|
|
2083
|
+
changeZoom?: boolean;
|
|
2084
|
+
/**
|
|
2085
|
+
* The animation curve to use for zooming in. Uses the animateCamera one by default.
|
|
2086
|
+
*/
|
|
2087
|
+
curve?: typeof Easing;
|
|
2088
|
+
/**
|
|
2089
|
+
* Camera tilt between 0 (top-down) to 1 (from the side)
|
|
2090
|
+
*/
|
|
2091
|
+
tilt?: number;
|
|
2092
|
+
/**
|
|
2093
|
+
* Rotation in degrees
|
|
2094
|
+
*/
|
|
2095
|
+
rotation?: number;
|
|
2096
|
+
/**
|
|
2097
|
+
* You can overide the {{#crossLink "MapView/focusZoomFactor:property"}}{{/crossLink}} for a specific {{#crossLink "MapView/focusOn:method"}}{{/crossLink}} call, rather than globally, if you like.
|
|
2098
|
+
*/
|
|
2099
|
+
focusZoomFactor?: number;
|
|
2100
|
+
/**
|
|
2101
|
+
* Sets a floor for how close you can zoom in on the scene. If it's lower than mapView.controls.minZoom, it's ignored.
|
|
2102
|
+
* @defaultValue: 0
|
|
2103
|
+
*/
|
|
2104
|
+
minZoom?: number;
|
|
2105
|
+
padding?: TPadding;
|
|
2106
|
+
points?: any[];
|
|
2107
|
+
};
|
|
2108
|
+
export interface ICore {
|
|
2109
|
+
new (container: HTMLElement, venue: Mappedin, options?: TMapViewOptions): ICore;
|
|
2110
|
+
/**
|
|
2111
|
+
* @internal
|
|
2112
|
+
*/
|
|
2113
|
+
currentScale: number;
|
|
2114
|
+
loadOptions?: TMapViewOptions['loadOptions'];
|
|
2115
|
+
imageFlippingEnabled: boolean;
|
|
2116
|
+
imageFlippingCache: any;
|
|
2117
|
+
cachedPadding: any;
|
|
2118
|
+
polygonMeshesById: any;
|
|
2119
|
+
textLabelsByPolygonId: any;
|
|
2120
|
+
renderer: any;
|
|
2121
|
+
scene: any;
|
|
2122
|
+
cameraParameters: Vector2;
|
|
2123
|
+
resolution: Vector2;
|
|
2124
|
+
determineNewLabelSize: any;
|
|
2125
|
+
on<EVENT_NAME extends keyof INTERNAL_EVENT_PAYLOAD>(eventName: EVENT_NAME, fn: changeListenerFn<INTERNAL_EVENT_PAYLOAD[EVENT_NAME]>): void;
|
|
2126
|
+
off<EVENT_NAME extends keyof INTERNAL_EVENT_PAYLOAD>(eventName: EVENT_NAME, fn: changeListenerFn<INTERNAL_EVENT_PAYLOAD[EVENT_NAME]>): void;
|
|
2127
|
+
publish<EVENT_NAME extends keyof INTERNAL_EVENT_PAYLOAD>(eventName: EVENT_NAME, payload?: INTERNAL_EVENT_PAYLOAD[EVENT_NAME]): void;
|
|
2128
|
+
/**
|
|
2129
|
+
* Manual camera controls for MapView. Generally you should be using the functions on MapView like {{#crossLink "MapView/focusOn:method"}}{{/crossLink}},
|
|
2130
|
+
* but if you have some cool animations in mind, you can do it with the {{#crossLink "CameraControls"}}{{/crossLink}}.
|
|
2131
|
+
* Some of the functions don't do anything in 2D.
|
|
2132
|
+
*
|
|
2133
|
+
*/
|
|
2134
|
+
controls: any;
|
|
2135
|
+
/**
|
|
2136
|
+
* The Venue data this MapView is using.
|
|
2137
|
+
*
|
|
2138
|
+
* @property venue {MappedinVenue}
|
|
2139
|
+
* @final
|
|
2140
|
+
*/
|
|
2141
|
+
readonly venue: Mappedin;
|
|
2142
|
+
/**
|
|
2143
|
+
* The div MapView is using.
|
|
2144
|
+
*
|
|
2145
|
+
* @property container {Div}
|
|
2146
|
+
* @final
|
|
2147
|
+
*/
|
|
2148
|
+
readonly container: HTMLElement;
|
|
2149
|
+
/**
|
|
2150
|
+
* The ID of the Map currently being displayed.
|
|
2151
|
+
*
|
|
2152
|
+
*/
|
|
2153
|
+
readonly currentMap: string;
|
|
2154
|
+
/**
|
|
2155
|
+
* Change this factor to influence how much the camera zooms in on a {@link IMapView3D.focusOn} call.
|
|
2156
|
+
*
|
|
2157
|
+
* @property focusZoomFactor {Integer}
|
|
2158
|
+
* @default 3
|
|
2159
|
+
*/
|
|
2160
|
+
focusZoomFactor: number;
|
|
2161
|
+
/**
|
|
2162
|
+
* Returns the value you should call {@link CameraControls.setZoom} on to fit the Polygon exactly.
|
|
2163
|
+
*
|
|
2164
|
+
* @return The zoom level that will fit the Polygon
|
|
2165
|
+
*/
|
|
2166
|
+
getZoomLevelForPolygon(props: {
|
|
2167
|
+
/**
|
|
2168
|
+
* The Polygon or Polygon ID to get the zoom level for
|
|
2169
|
+
*/
|
|
2170
|
+
polygonOrPolygonId: MappedinPolygon | string;
|
|
2171
|
+
}): number;
|
|
2172
|
+
/**
|
|
2173
|
+
* Returns the value you should call {@link CameraControls.setZoom} on to fit the {@link IMapView3D.currentMap} exactly.
|
|
2174
|
+
*
|
|
2175
|
+
* @return The zoom level that will fit the {@link IMapView3D.currentMap}.
|
|
2176
|
+
*/
|
|
2177
|
+
getZoomLevelForCurrentMap(): number;
|
|
2178
|
+
/**
|
|
2179
|
+
* Returns the angle that points to north, in radians, from the default orientation.
|
|
2180
|
+
*
|
|
2181
|
+
* @return The angle to north from the default orientation, in radians.
|
|
2182
|
+
*/
|
|
2183
|
+
getNorth(): number;
|
|
2184
|
+
/**
|
|
2185
|
+
* Takes an element on the DOM and rotates it such that the top is pointing north. It will rotate with the camera, staying locked
|
|
2186
|
+
* on north. If you would like to align it do a different direction, or a different side of the element, pass in an offset. This
|
|
2187
|
+
* is how you would do a compass rose.
|
|
2188
|
+
*
|
|
2189
|
+
* This will modify your element's transform.
|
|
2190
|
+
*
|
|
2191
|
+
* @param element The element on the page to rotate.
|
|
2192
|
+
* @param offset The amount to offset the rotation by, in radians.
|
|
2193
|
+
*
|
|
2194
|
+
*/
|
|
2195
|
+
lockNorth(element: HTMLElement, offset?: number): void;
|
|
2196
|
+
/**
|
|
2197
|
+
* Stops the MapView from trying to rotate your element with the camera. Do this if you remove the element, or want to stop it from rotating.
|
|
2198
|
+
* @param element The node to stop rotating. It won't reset the transform, just leave it as is.
|
|
2199
|
+
*/
|
|
2200
|
+
unlockNorth(element: HTMLElement): void;
|
|
2201
|
+
currentInteractionEvent: string;
|
|
2202
|
+
interactivePolygons: any;
|
|
2203
|
+
highlightedPolygons: any;
|
|
2204
|
+
cameraPlane: any;
|
|
2205
|
+
/**
|
|
2206
|
+
* Called any time a user touches or clicks the map. Only fires on "single" touches/clicks.
|
|
2207
|
+
*
|
|
2208
|
+
* @param position Object containing the latitude & longitude of the location touched on the map
|
|
2209
|
+
* @param polygons Array of polygon IDs that were touched, in order of front to back.
|
|
2210
|
+
* @param nearBlueDot Whether the touch was close enough to the Blue Dot to be considered a touch on the Blue Dot.
|
|
2211
|
+
*/
|
|
2212
|
+
onMapClicked(position: {
|
|
2213
|
+
latitude: number;
|
|
2214
|
+
longitude: number;
|
|
2215
|
+
}, polygons: string[], nearBlueDot: boolean): void;
|
|
2216
|
+
/**
|
|
2217
|
+
* This is called when an interactive Polygon is clicked on.
|
|
2218
|
+
* You will almost certainly want to replace this with your own function in your client app.
|
|
2219
|
+
* Return "false" if you have consumed the event and it shouldn't bubble down to other Polygons beneath this one.
|
|
2220
|
+
*
|
|
2221
|
+
* @param polygonId polygonId passed in when tapping an interactive polygon
|
|
2222
|
+
*/
|
|
2223
|
+
onPolygonClicked(polygonId: string): boolean | void;
|
|
2224
|
+
onMapChanged(map: string): void;
|
|
2225
|
+
getPositionLatLon(lat: number, lon: number, map?: MappedinMap | string): Vector3;
|
|
2226
|
+
getPositionPolygon(polygon: MappedinPolygon | string): Vector3;
|
|
2227
|
+
/**
|
|
2228
|
+
* Takes an x/y pair in Mappedin coordinate space and gives you a Vector3 in scene space
|
|
2229
|
+
* @param nodeOrCoordinate a node or coordinate
|
|
2230
|
+
*/
|
|
2231
|
+
convertTo3DMapPosition(nodeOrCoordinate: MappedinCoordinate | MappedinNode): Vector3;
|
|
2232
|
+
/**
|
|
2233
|
+
* Converts a Vector-like object into a MappedinCoordinate for a map.
|
|
2234
|
+
* @param position an object with x and y, like a Vector3
|
|
2235
|
+
* @param mapClass An optional map; otherwise, the current map will be used.
|
|
2236
|
+
*/
|
|
2237
|
+
convert3DMapPositionToCoordinate(position: {
|
|
2238
|
+
x: number;
|
|
2239
|
+
y: number;
|
|
2240
|
+
}, mapClass?: MappedinMap): MappedinCoordinate;
|
|
2241
|
+
setPadding(padding: {
|
|
2242
|
+
top: number;
|
|
2243
|
+
left: number;
|
|
2244
|
+
bottom: number;
|
|
2245
|
+
right: number;
|
|
2246
|
+
}): void;
|
|
2247
|
+
/**
|
|
2248
|
+
* This is fired when the user taps/clicks on the MapView without hitting an interactive Polygon.
|
|
2249
|
+
* You will almost certainly want to replace this with your own function in your client app.
|
|
2250
|
+
* You would probably use this to clear any Polygon highlighting, in certain situations.
|
|
2251
|
+
*/
|
|
2252
|
+
onNothingClicked(): void;
|
|
2253
|
+
smartCollisionEngine: any;
|
|
2254
|
+
mapObjects: any;
|
|
2255
|
+
/**
|
|
2256
|
+
* The scene only renders when something has changed. This should be something a 3rd party developer doesn't need to worry about,
|
|
2257
|
+
* but if you are doing something weird, or have your own special tween for something, you will want to call this function.
|
|
2258
|
+
* You can call it as often as you want, it just sets a flag that we need to render again, and renders a few frames if we weren't already doing that.
|
|
2259
|
+
* Ignored in 2D.
|
|
2260
|
+
*/
|
|
2261
|
+
tryRendering(renderMode?: typeof RENDER): void;
|
|
2262
|
+
setMap(mapOrMapId: MappedinMap | string): Promise<null>;
|
|
2263
|
+
getPositionNode(node: MappedinNode): Vector3;
|
|
2264
|
+
cameraObject: any;
|
|
2265
|
+
setBackgroundColor(color: number | string, alpha?: number): void;
|
|
2266
|
+
mapManager: any;
|
|
2267
|
+
focusOn(focusOptions: TFocusOptionsLegacy): Tween;
|
|
2268
|
+
canvasWidth: number;
|
|
2269
|
+
canvasHeight: number;
|
|
2270
|
+
/**
|
|
2271
|
+
* Resets the MapView to the default state.
|
|
2272
|
+
*/
|
|
2273
|
+
resetState(): void;
|
|
2274
|
+
destroy(): void;
|
|
2275
|
+
}
|
|
2276
|
+
}
|
|
2277
|
+
|
|
2278
|
+
declare module '@mappedin/react-native-sdk/wrappers/common/controller' {
|
|
2279
|
+
import { BRIDGE_EVENT, BRIDGE_EVENT_PAYLOADS } from '@mappedin/react-native-sdk/wrappers/common';
|
|
2280
|
+
import { PubSub } from '@mappedin/react-native-sdk/wrappers/common';
|
|
2281
|
+
export function uuid(): string;
|
|
2282
|
+
export class MappedinController {
|
|
2283
|
+
#private;
|
|
2284
|
+
privateEventBus: PubSub<{
|
|
2285
|
+
REJECT: {
|
|
2286
|
+
msgID?: string | undefined;
|
|
2287
|
+
data: any;
|
|
2288
|
+
};
|
|
2289
|
+
RESOLVE: {
|
|
2290
|
+
msgID?: string | undefined;
|
|
2291
|
+
data: any;
|
|
2292
|
+
};
|
|
2293
|
+
READY: {
|
|
2294
|
+
msgID?: string | undefined;
|
|
2295
|
+
data: null;
|
|
2296
|
+
};
|
|
2297
|
+
LOG: {
|
|
2298
|
+
msgID?: string | undefined;
|
|
2299
|
+
data: string;
|
|
2300
|
+
};
|
|
2301
|
+
GET_IMAGE: {
|
|
2302
|
+
msgID?: string | undefined;
|
|
2303
|
+
data: {
|
|
2304
|
+
fileName: string;
|
|
2305
|
+
};
|
|
2306
|
+
};
|
|
2307
|
+
GET_MAP_POLYGONS: {
|
|
2308
|
+
msgID?: string | undefined;
|
|
2309
|
+
data: {
|
|
2310
|
+
mapId: string;
|
|
2311
|
+
};
|
|
2312
|
+
};
|
|
2313
|
+
MINIMAP_READY: {
|
|
2314
|
+
msgID?: string | undefined;
|
|
2315
|
+
data: null;
|
|
2316
|
+
};
|
|
2317
|
+
SHOW_MINIMAP: {
|
|
2318
|
+
msgID?: string | undefined;
|
|
2319
|
+
data: {
|
|
2320
|
+
format: "jsonstring";
|
|
2321
|
+
venueData: string;
|
|
2322
|
+
options: import("./types").TMiMapViewOptions;
|
|
2323
|
+
};
|
|
2324
|
+
};
|
|
2325
|
+
LOAD_MINIMAP: {
|
|
2326
|
+
msgID?: string | undefined;
|
|
2327
|
+
data: {
|
|
2328
|
+
options: import("../react-native-sdk/src").TGetVenueOptions;
|
|
2329
|
+
};
|
|
2330
|
+
};
|
|
2331
|
+
CACHE_IMAGE: {
|
|
2332
|
+
msgID?: string | undefined;
|
|
2333
|
+
data: {
|
|
2334
|
+
url?: string | undefined;
|
|
2335
|
+
options: import("../react-native-sdk/src").TGetVenueOptions;
|
|
2336
|
+
locationId: string;
|
|
2337
|
+
polygonHighlightColor?: string | undefined;
|
|
2338
|
+
focusOptions?: Omit<import("./types").TFocusOnOptionsSerializable, "targets"> | undefined;
|
|
2339
|
+
};
|
|
2340
|
+
};
|
|
2341
|
+
CLEAR_BUNDLE_CACHE: {
|
|
2342
|
+
msgID?: string | undefined;
|
|
2343
|
+
data: null;
|
|
2344
|
+
};
|
|
2345
|
+
NOTHING_CLICKED: {
|
|
2346
|
+
msgID?: string | undefined;
|
|
2347
|
+
data: null;
|
|
2348
|
+
};
|
|
2349
|
+
STATE_CHANGED: {
|
|
2350
|
+
msgID?: string | undefined;
|
|
2351
|
+
data: {
|
|
2352
|
+
state: import("../react-native-sdk/src").STATE;
|
|
2353
|
+
};
|
|
2354
|
+
};
|
|
2355
|
+
DATA_LOADED: {
|
|
2356
|
+
msgID?: string | undefined;
|
|
2357
|
+
data: {
|
|
2358
|
+
venueData: any;
|
|
2359
|
+
};
|
|
2360
|
+
};
|
|
2361
|
+
FIRST_MAP_LOADED: {
|
|
2362
|
+
msgID?: string | undefined;
|
|
2363
|
+
data: {
|
|
2364
|
+
venueData?: any;
|
|
2365
|
+
};
|
|
2366
|
+
};
|
|
2367
|
+
MAP_CHANGED: {
|
|
2368
|
+
msgID?: string | undefined;
|
|
2369
|
+
data: {
|
|
2370
|
+
mapId: string;
|
|
2371
|
+
};
|
|
2372
|
+
};
|
|
2373
|
+
POLYGON_CLICKED: {
|
|
2374
|
+
msgID?: string | undefined;
|
|
2375
|
+
data: {
|
|
2376
|
+
polygonId: string;
|
|
2377
|
+
};
|
|
2378
|
+
};
|
|
2379
|
+
ROTATION_CHANGED: {
|
|
2380
|
+
msgID?: string | undefined;
|
|
2381
|
+
data: {
|
|
2382
|
+
rotation: number;
|
|
2383
|
+
};
|
|
2384
|
+
};
|
|
2385
|
+
TILT_CHANGED: {
|
|
2386
|
+
msgID?: string | undefined;
|
|
2387
|
+
data: {
|
|
2388
|
+
tilt: number;
|
|
2389
|
+
};
|
|
2390
|
+
};
|
|
2391
|
+
UPDATE_GEOLOCATION: {
|
|
2392
|
+
msgID?: string | undefined;
|
|
2393
|
+
data: {
|
|
2394
|
+
msgID: undefined;
|
|
2395
|
+
data: unknown;
|
|
2396
|
+
};
|
|
2397
|
+
};
|
|
2398
|
+
BLUEDOT_STATE_CHANGE: {
|
|
2399
|
+
msgID?: string | undefined;
|
|
2400
|
+
data: {
|
|
2401
|
+
stateChange: import("../react-native-sdk/src").TBlueDotStateChange;
|
|
2402
|
+
};
|
|
2403
|
+
};
|
|
2404
|
+
BLUEDOT_POSITION_UPDATE: {
|
|
2405
|
+
msgID?: string | undefined;
|
|
2406
|
+
data: {
|
|
2407
|
+
update: Omit<import("../react-native-sdk/src").TBlueDotPositionUpdate, "map" | "nearestNode"> & {
|
|
2408
|
+
nearestNode?: string | undefined;
|
|
2409
|
+
map?: string | undefined;
|
|
2410
|
+
};
|
|
2411
|
+
};
|
|
2412
|
+
};
|
|
2413
|
+
SET_JOURNEY_STEP: {
|
|
1986
2414
|
msgID?: string | undefined;
|
|
1987
2415
|
data: {
|
|
1988
2416
|
step: number;
|
|
@@ -1994,7 +2422,10 @@ declare module '@mappedin/react-native-sdk/wrappers/common/controller' {
|
|
|
1994
2422
|
options: import("../react-native-sdk/src").TGetVenueOptions & {
|
|
1995
2423
|
useBundle?: boolean | undefined;
|
|
1996
2424
|
};
|
|
1997
|
-
showVenueOptions: import("../react-native-sdk/src").TShowVenueOptions
|
|
2425
|
+
showVenueOptions: import("../react-native-sdk/src").TShowVenueOptions & {
|
|
2426
|
+
prepareSearch?: boolean | undefined;
|
|
2427
|
+
searchOptions?: Partial<import("../react-native-sdk/src").TMappedinOfflineSearchAllOptions> | undefined;
|
|
2428
|
+
};
|
|
1998
2429
|
};
|
|
1999
2430
|
};
|
|
2000
2431
|
SHOW_VENUE: {
|
|
@@ -2002,7 +2433,10 @@ declare module '@mappedin/react-native-sdk/wrappers/common/controller' {
|
|
|
2002
2433
|
data: {
|
|
2003
2434
|
venueData: string;
|
|
2004
2435
|
format: "jsonstring";
|
|
2005
|
-
showVenueOptions: import("../react-native-sdk/src").TShowVenueOptions
|
|
2436
|
+
showVenueOptions: import("../react-native-sdk/src").TShowVenueOptions & {
|
|
2437
|
+
prepareSearch?: boolean | undefined;
|
|
2438
|
+
searchOptions?: Partial<import("../react-native-sdk/src").TMappedinOfflineSearchAllOptions> | undefined;
|
|
2439
|
+
};
|
|
2006
2440
|
};
|
|
2007
2441
|
};
|
|
2008
2442
|
SET_MAP: {
|
|
@@ -2232,6 +2666,29 @@ declare module '@mappedin/react-native-sdk/wrappers/common/controller' {
|
|
|
2232
2666
|
map?: string | undefined;
|
|
2233
2667
|
};
|
|
2234
2668
|
};
|
|
2669
|
+
SEARCH: {
|
|
2670
|
+
msgID?: string | undefined;
|
|
2671
|
+
data: {
|
|
2672
|
+
query: string;
|
|
2673
|
+
};
|
|
2674
|
+
};
|
|
2675
|
+
SUGGEST: {
|
|
2676
|
+
msgID?: string | undefined;
|
|
2677
|
+
data: {
|
|
2678
|
+
query: string;
|
|
2679
|
+
};
|
|
2680
|
+
};
|
|
2681
|
+
ADD_SEARCH_QUERY: {
|
|
2682
|
+
msgID?: string | undefined;
|
|
2683
|
+
data: {
|
|
2684
|
+
query: string;
|
|
2685
|
+
object: {
|
|
2686
|
+
type: "MappedinLocation" | "MappedinCategory" | "Custom";
|
|
2687
|
+
id: string;
|
|
2688
|
+
};
|
|
2689
|
+
weight?: number | undefined;
|
|
2690
|
+
};
|
|
2691
|
+
};
|
|
2235
2692
|
}>;
|
|
2236
2693
|
/**
|
|
2237
2694
|
* Message received from the other side of the bridge
|
|
@@ -2263,268 +2720,73 @@ declare module '@mappedin/react-native-sdk/wrappers/common/controller' {
|
|
|
2263
2720
|
/**
|
|
2264
2721
|
* Handle rejection from the other side, typically when the request results in an error
|
|
2265
2722
|
* @hidden
|
|
2266
|
-
*/
|
|
2267
|
-
protected handleRejection: <EVENT_NAME extends BRIDGE_EVENT>(payload: {
|
|
2268
|
-
msgID: string;
|
|
2269
|
-
data: {
|
|
2270
|
-
payload: BRIDGE_EVENT_PAYLOADS[EVENT_NAME];
|
|
2271
|
-
};
|
|
2272
|
-
}) => void;
|
|
2273
|
-
/**
|
|
2274
|
-
* Emitting a message without expecting a response
|
|
2275
|
-
* @hidden
|
|
2276
|
-
*/
|
|
2277
|
-
emit<EVENT_NAME extends keyof BRIDGE_EVENT_PAYLOADS>(eventName: EVENT_NAME, payload?: BRIDGE_EVENT_PAYLOADS[EVENT_NAME], msgID?: string): void;
|
|
2278
|
-
/**
|
|
2279
|
-
* Emitting a message and waiting for a reponse, via a promise
|
|
2280
|
-
* @hidden
|
|
2281
|
-
*/
|
|
2282
|
-
emitAsync<T, EVENT_NAME extends keyof BRIDGE_EVENT_PAYLOADS>(eventName: EVENT_NAME, payload?: BRIDGE_EVENT_PAYLOADS[EVENT_NAME], msgID?: string): Promise<T>;
|
|
2283
|
-
}
|
|
2284
|
-
}
|
|
2285
|
-
|
|
2286
|
-
declare module '@mappedin/react-native-sdk/core/packages/renderer/Core.interface' {
|
|
2287
|
-
import { MappedinMap, Mappedin, MappedinCoordinate, MappedinPolygon, MappedinNode } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
2288
|
-
import CameraControls from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.CameraControls';
|
|
2289
|
-
import { Vector2, Vector3 } from 'three';
|
|
2290
|
-
import { changeListenerFn, TMapViewOptions } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.types';
|
|
2291
|
-
import RENDER from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.RenderTasks';
|
|
2292
|
-
import { INTERNAL_EVENT_PAYLOAD } from '@mappedin/react-native-sdk/core/packages/renderer/MapView';
|
|
2293
|
-
import { TPadding } from '@mappedin/react-native-sdk/core/packages/renderer';
|
|
2294
|
-
import Tween, { Easing } from '@tweenjs/tween.js';
|
|
2295
|
-
export type TFocusOptionsLegacy = {
|
|
2296
|
-
/**
|
|
2297
|
-
* An array of Nodes to focus in on
|
|
2298
|
-
*/
|
|
2299
|
-
nodes?: (MappedinNode | MappedinNode['id'])[];
|
|
2300
|
-
/**
|
|
2301
|
-
* An array of Polygons to focus on. It's the center of the bounds of all Polygons, designed to fit everything into view.
|
|
2302
|
-
*/
|
|
2303
|
-
polygons?: (MappedinPolygon | MappedinPolygon['id'])[];
|
|
2304
|
-
/**
|
|
2305
|
-
* The duration the focus animation should last for.
|
|
2306
|
-
* @defaultValue `100`
|
|
2307
|
-
*/
|
|
2308
|
-
duration?: number;
|
|
2309
|
-
/**
|
|
2310
|
-
* Whether to zoom the camera in or out, or just pan it.
|
|
2311
|
-
* @defaultValue `true`
|
|
2312
|
-
*/
|
|
2313
|
-
changeZoom?: boolean;
|
|
2314
|
-
/**
|
|
2315
|
-
* The animation curve to use for zooming in. Uses the animateCamera one by default.
|
|
2316
|
-
*/
|
|
2317
|
-
curve?: typeof Easing;
|
|
2318
|
-
/**
|
|
2319
|
-
* Camera tilt between 0 (top-down) to 1 (from the side)
|
|
2320
|
-
*/
|
|
2321
|
-
tilt?: number;
|
|
2322
|
-
/**
|
|
2323
|
-
* Rotation in degrees
|
|
2324
|
-
*/
|
|
2325
|
-
rotation?: number;
|
|
2326
|
-
/**
|
|
2327
|
-
* You can overide the {{#crossLink "MapView/focusZoomFactor:property"}}{{/crossLink}} for a specific {{#crossLink "MapView/focusOn:method"}}{{/crossLink}} call, rather than globally, if you like.
|
|
2328
|
-
*/
|
|
2329
|
-
focusZoomFactor?: number;
|
|
2330
|
-
/**
|
|
2331
|
-
* Sets a floor for how close you can zoom in on the scene. If it's lower than mapView.controls.minZoom, it's ignored.
|
|
2332
|
-
* @defaultValue: 0
|
|
2333
|
-
*/
|
|
2334
|
-
minZoom?: number;
|
|
2335
|
-
padding?: TPadding;
|
|
2336
|
-
points?: any[];
|
|
2337
|
-
};
|
|
2338
|
-
export interface ICore {
|
|
2339
|
-
new (container: HTMLElement, venue: Mappedin, options?: TMapViewOptions): ICore;
|
|
2340
|
-
/**
|
|
2341
|
-
* @internal
|
|
2342
|
-
*/
|
|
2343
|
-
currentScale: number;
|
|
2344
|
-
imageFlippingEnabled: boolean;
|
|
2345
|
-
imageFlippingCache: any;
|
|
2346
|
-
cachedPadding: any;
|
|
2347
|
-
polygonMeshesById: any;
|
|
2348
|
-
textLabelsByPolygonId: any;
|
|
2349
|
-
renderer: any;
|
|
2350
|
-
scene: any;
|
|
2351
|
-
cameraParameters: Vector2;
|
|
2352
|
-
resolution: Vector2;
|
|
2353
|
-
determineNewLabelSize: any;
|
|
2354
|
-
on<EVENT_NAME extends keyof INTERNAL_EVENT_PAYLOAD>(eventName: EVENT_NAME, fn: changeListenerFn<INTERNAL_EVENT_PAYLOAD[EVENT_NAME]>): void;
|
|
2355
|
-
off<EVENT_NAME extends keyof INTERNAL_EVENT_PAYLOAD>(eventName: EVENT_NAME, fn: changeListenerFn<INTERNAL_EVENT_PAYLOAD[EVENT_NAME]>): void;
|
|
2356
|
-
publish<EVENT_NAME extends keyof INTERNAL_EVENT_PAYLOAD>(eventName: EVENT_NAME, payload?: INTERNAL_EVENT_PAYLOAD[EVENT_NAME]): void;
|
|
2357
|
-
/**
|
|
2358
|
-
* Manual camera controls for MapView. Generally you should be using the functions on MapView like {{#crossLink "MapView/focusOn:method"}}{{/crossLink}},
|
|
2359
|
-
* but if you have some cool animations in mind, you can do it with the {{#crossLink "CameraControls"}}{{/crossLink}}.
|
|
2360
|
-
* Some of the functions don't do anything in 2D.
|
|
2361
|
-
*
|
|
2362
|
-
*/
|
|
2363
|
-
controls?: typeof CameraControls;
|
|
2364
|
-
/**
|
|
2365
|
-
* The Venue data this MapView is using.
|
|
2366
|
-
*
|
|
2367
|
-
* @property venue {MappedinVenue}
|
|
2368
|
-
* @final
|
|
2369
|
-
*/
|
|
2370
|
-
readonly venue: Mappedin;
|
|
2371
|
-
/**
|
|
2372
|
-
* The div MapView is using.
|
|
2373
|
-
*
|
|
2374
|
-
* @property container {Div}
|
|
2375
|
-
* @final
|
|
2376
|
-
*/
|
|
2377
|
-
readonly container: HTMLElement;
|
|
2378
|
-
/**
|
|
2379
|
-
* The ID of the Map currently being displayed.
|
|
2380
|
-
*
|
|
2381
|
-
*/
|
|
2382
|
-
readonly currentMap: string;
|
|
2383
|
-
/**
|
|
2384
|
-
* Change this factor to influence how much the camera zooms in on a {@link IMapView3D.focusOn} call.
|
|
2385
|
-
*
|
|
2386
|
-
* @property focusZoomFactor {Integer}
|
|
2387
|
-
* @default 3
|
|
2388
|
-
*/
|
|
2389
|
-
focusZoomFactor: number;
|
|
2390
|
-
/**
|
|
2391
|
-
* Returns the value you should call {@link CameraControls.setZoom} on to fit the Polygon exactly.
|
|
2392
|
-
*
|
|
2393
|
-
* @return The zoom level that will fit the Polygon
|
|
2394
|
-
*/
|
|
2395
|
-
getZoomLevelForPolygon(props: {
|
|
2396
|
-
/**
|
|
2397
|
-
* The Polygon or Polygon ID to get the zoom level for
|
|
2398
|
-
*/
|
|
2399
|
-
polygonOrPolygonId: MappedinPolygon | string;
|
|
2400
|
-
}): number;
|
|
2401
|
-
/**
|
|
2402
|
-
* Returns the value you should call {@link CameraControls.setZoom} on to fit the {@link IMapView3D.currentMap} exactly.
|
|
2403
|
-
*
|
|
2404
|
-
* @return The zoom level that will fit the {@link IMapView3D.currentMap}.
|
|
2405
|
-
*/
|
|
2406
|
-
getZoomLevelForCurrentMap(): number;
|
|
2407
|
-
/**
|
|
2408
|
-
* Returns the angle that points to north, in radians, from the default orientation.
|
|
2409
|
-
*
|
|
2410
|
-
* @return The angle to north from the default orientation, in radians.
|
|
2411
|
-
*/
|
|
2412
|
-
getNorth(): number;
|
|
2413
|
-
/**
|
|
2414
|
-
* Takes an element on the DOM and rotates it such that the top is pointing north. It will rotate with the camera, staying locked
|
|
2415
|
-
* on north. If you would like to align it do a different direction, or a different side of the element, pass in an offset. This
|
|
2416
|
-
* is how you would do a compass rose.
|
|
2417
|
-
*
|
|
2418
|
-
* This will modify your element's transform.
|
|
2419
|
-
*
|
|
2420
|
-
* @param element The element on the page to rotate.
|
|
2421
|
-
* @param offset The amount to offset the rotation by, in radians.
|
|
2422
|
-
*
|
|
2423
|
-
*/
|
|
2424
|
-
lockNorth(element: HTMLElement, offset?: number): void;
|
|
2425
|
-
/**
|
|
2426
|
-
* Stops the MapView from trying to rotate your element with the camera. Do this if you remove the element, or want to stop it from rotating.
|
|
2427
|
-
* @param element The node to stop rotating. It won't reset the transform, just leave it as is.
|
|
2428
|
-
*/
|
|
2429
|
-
unlockNorth(element: HTMLElement): void;
|
|
2430
|
-
currentInteractionEvent: string;
|
|
2431
|
-
interactivePolygons: any;
|
|
2432
|
-
highlightedPolygons: any;
|
|
2433
|
-
cameraPlane: any;
|
|
2434
|
-
/**
|
|
2435
|
-
* Called any time a user touches or clicks the map. Only fires on "single" touches/clicks.
|
|
2436
|
-
*
|
|
2437
|
-
* @param position Object containing the latitude & longitude of the location touched on the map
|
|
2438
|
-
* @param polygons Array of polygon IDs that were touched, in order of front to back.
|
|
2439
|
-
* @param nearBlueDot Whether the touch was close enough to the Blue Dot to be considered a touch on the Blue Dot.
|
|
2440
|
-
*/
|
|
2441
|
-
onMapClicked(position: {
|
|
2442
|
-
latitude: number;
|
|
2443
|
-
longitude: number;
|
|
2444
|
-
}, polygons: string[], nearBlueDot: boolean): void;
|
|
2445
|
-
/**
|
|
2446
|
-
* This is called when an interactive Polygon is clicked on.
|
|
2447
|
-
* You will almost certainly want to replace this with your own function in your client app.
|
|
2448
|
-
* Return "false" if you have consumed the event and it shouldn't bubble down to other Polygons beneath this one.
|
|
2449
|
-
*
|
|
2450
|
-
* @param polygonId polygonId passed in when tapping an interactive polygon
|
|
2451
|
-
*/
|
|
2452
|
-
onPolygonClicked(polygonId: string): boolean | void;
|
|
2453
|
-
onMapChanged(map: string): void;
|
|
2454
|
-
getPositionLatLon(lat: number, lon: number, map?: MappedinMap | string): Vector3;
|
|
2455
|
-
getPositionPolygon(polygon: MappedinPolygon | string): Vector3;
|
|
2456
|
-
convertTo3DMapPosition(nodeOrCoordinate: MappedinCoordinate | MappedinNode): Vector3;
|
|
2457
|
-
setPadding(padding: {
|
|
2458
|
-
top: number;
|
|
2459
|
-
left: number;
|
|
2460
|
-
bottom: number;
|
|
2461
|
-
right: number;
|
|
2462
|
-
}): void;
|
|
2463
|
-
/**
|
|
2464
|
-
* This is fired when the user taps/clicks on the MapView without hitting an interactive Polygon.
|
|
2465
|
-
* You will almost certainly want to replace this with your own function in your client app.
|
|
2466
|
-
* You would probably use this to clear any Polygon highlighting, in certain situations.
|
|
2467
|
-
*/
|
|
2468
|
-
onNothingClicked(): void;
|
|
2469
|
-
smartCollisionEngine: any;
|
|
2470
|
-
mapObjects: any;
|
|
2723
|
+
*/
|
|
2724
|
+
protected handleRejection: <EVENT_NAME extends BRIDGE_EVENT>(payload: {
|
|
2725
|
+
msgID: string;
|
|
2726
|
+
data: {
|
|
2727
|
+
payload: BRIDGE_EVENT_PAYLOADS[EVENT_NAME];
|
|
2728
|
+
};
|
|
2729
|
+
}) => void;
|
|
2471
2730
|
/**
|
|
2472
|
-
*
|
|
2473
|
-
*
|
|
2474
|
-
* You can call it as often as you want, it just sets a flag that we need to render again, and renders a few frames if we weren't already doing that.
|
|
2475
|
-
* Ignored in 2D.
|
|
2731
|
+
* Emitting a message without expecting a response
|
|
2732
|
+
* @hidden
|
|
2476
2733
|
*/
|
|
2477
|
-
|
|
2478
|
-
setMap(mapOrMapId: MappedinMap | string): Promise<null>;
|
|
2479
|
-
getPositionNode(node: MappedinNode): Vector3;
|
|
2480
|
-
cameraObject: any;
|
|
2481
|
-
setBackgroundColor(color: number | string, alpha?: number): void;
|
|
2482
|
-
mapManager: any;
|
|
2483
|
-
focusOn(focusOptions: TFocusOptionsLegacy): Tween;
|
|
2484
|
-
canvasWidth: number;
|
|
2485
|
-
canvasHeight: number;
|
|
2734
|
+
emit<EVENT_NAME extends keyof BRIDGE_EVENT_PAYLOADS>(eventName: EVENT_NAME, payload?: BRIDGE_EVENT_PAYLOADS[EVENT_NAME], msgID?: string): void;
|
|
2486
2735
|
/**
|
|
2487
|
-
*
|
|
2736
|
+
* Emitting a message and waiting for a reponse, via a promise
|
|
2737
|
+
* @hidden
|
|
2488
2738
|
*/
|
|
2489
|
-
|
|
2490
|
-
destroy(): void;
|
|
2739
|
+
emitAsync<T, EVENT_NAME extends keyof BRIDGE_EVENT_PAYLOADS>(eventName: EVENT_NAME, payload?: BRIDGE_EVENT_PAYLOADS[EVENT_NAME], msgID?: string): Promise<T>;
|
|
2491
2740
|
}
|
|
2492
2741
|
}
|
|
2493
2742
|
|
|
2494
2743
|
declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.types' {
|
|
2495
2744
|
export type TGetVenueOptions = {
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
|
|
2508
|
-
|
|
2745
|
+
accessToken?: string;
|
|
2746
|
+
clientId?: string;
|
|
2747
|
+
clientSecret?: string;
|
|
2748
|
+
baseUrl?: string;
|
|
2749
|
+
includeHidden?: boolean;
|
|
2750
|
+
noAuth?: boolean;
|
|
2751
|
+
perspective?: string;
|
|
2752
|
+
language?: string;
|
|
2753
|
+
headers?: {
|
|
2754
|
+
[key in string]: string;
|
|
2755
|
+
};
|
|
2756
|
+
venue: string;
|
|
2757
|
+
things?: any;
|
|
2758
|
+
useDraftData?: boolean;
|
|
2759
|
+
platformString?: string;
|
|
2509
2760
|
};
|
|
2510
2761
|
export type TGetVenueOptionsInternal = {
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2762
|
+
baseUrl?: string;
|
|
2763
|
+
supplementaryUrl?: string;
|
|
2764
|
+
noAuth?: boolean;
|
|
2765
|
+
includeHidden?: boolean;
|
|
2766
|
+
apiGateway?: string;
|
|
2767
|
+
authorization?: string;
|
|
2768
|
+
/**
|
|
2769
|
+
* @deprecated 2D support will be removed in the future
|
|
2770
|
+
*/
|
|
2771
|
+
do2D?: boolean;
|
|
2772
|
+
things?: any;
|
|
2773
|
+
headers?: any;
|
|
2523
2774
|
};
|
|
2775
|
+
export enum MAP_RENDER_MODE {
|
|
2776
|
+
/** Each polygon, its geometry and mesh are sent to the GPU every render frame.
|
|
2777
|
+
* This was the default rendering mode before 4.0.17
|
|
2778
|
+
*/
|
|
2779
|
+
MULTI_GEOMETRY = "MULTI_GEOMETRY",
|
|
2780
|
+
/** Polygons' geometries are grouped by material and merged together, resulting in far fewer
|
|
2781
|
+
* draw calls to the GPU. Default rendering mode since 4.0.17
|
|
2782
|
+
*/
|
|
2783
|
+
SINGLE_GEOMETRY = "SINGLE_GEOMETRY"
|
|
2784
|
+
}
|
|
2524
2785
|
}
|
|
2525
2786
|
|
|
2526
2787
|
declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin' {
|
|
2527
2788
|
import { Navigator } from '@mappedin/react-native-sdk/core/packages/navigator';
|
|
2789
|
+
import { MVFData } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.MVF.types';
|
|
2528
2790
|
import type { TGetVenueOptions, TGetVenueOptionsInternal } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.types';
|
|
2529
2791
|
import { MappedinCategory } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinCategory';
|
|
2530
2792
|
import { MappedinEvent } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinEvent';
|
|
@@ -2539,8 +2801,9 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin' {
|
|
|
2539
2801
|
import { MappedinTheme } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinTheme';
|
|
2540
2802
|
import { MappedinVenue } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinVenue';
|
|
2541
2803
|
import { MappedinVortex } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinVortex';
|
|
2804
|
+
import Analytics from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.Analytics';
|
|
2542
2805
|
export const defaultOptions: TGetVenueOptionsInternal & TGetVenueOptions;
|
|
2543
|
-
export enum
|
|
2806
|
+
export enum MappedinCollectionType {
|
|
2544
2807
|
CATEGORY = "categories",
|
|
2545
2808
|
EVENT = "events",
|
|
2546
2809
|
LOCATION = "locations",
|
|
@@ -2551,14 +2814,14 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin' {
|
|
|
2551
2814
|
VORTEX = "vortexes"
|
|
2552
2815
|
}
|
|
2553
2816
|
type TAccessors = {
|
|
2554
|
-
[
|
|
2555
|
-
[
|
|
2556
|
-
[
|
|
2557
|
-
[
|
|
2558
|
-
[
|
|
2559
|
-
[
|
|
2560
|
-
[
|
|
2561
|
-
[
|
|
2817
|
+
[MappedinCollectionType.CATEGORY]: MappedinCategory;
|
|
2818
|
+
[MappedinCollectionType.EVENT]: MappedinEvent;
|
|
2819
|
+
[MappedinCollectionType.LOCATION]: MappedinLocation;
|
|
2820
|
+
[MappedinCollectionType.MAPGROUP]: MappedinMapGroup;
|
|
2821
|
+
[MappedinCollectionType.MAP]: MappedinMap;
|
|
2822
|
+
[MappedinCollectionType.NODE]: MappedinNode;
|
|
2823
|
+
[MappedinCollectionType.POLYGON]: MappedinPolygon;
|
|
2824
|
+
[MappedinCollectionType.VORTEX]: MappedinVortex;
|
|
2562
2825
|
};
|
|
2563
2826
|
const THINGS: {
|
|
2564
2827
|
categories: typeof MappedinCategory;
|
|
@@ -2754,6 +3017,11 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin' {
|
|
|
2754
3017
|
[id: string]: MappedinRankings;
|
|
2755
3018
|
};
|
|
2756
3019
|
getCollectionItemById<T extends keyof TAccessors, I extends string>(name: T, id: I): TAccessors[T] | null;
|
|
3020
|
+
/**
|
|
3021
|
+
* @hidden
|
|
3022
|
+
* @internal
|
|
3023
|
+
*/
|
|
3024
|
+
hydrateFromMVF(mvfData: MVFData): Promise<undefined>;
|
|
2757
3025
|
/**
|
|
2758
3026
|
*
|
|
2759
3027
|
* [experimental] Hydrate the Mappedin instance using a response from either {@link IMappedin.toString()}, {@link getVenueBundle} or by downloading the bundle manually
|
|
@@ -2762,9 +3030,11 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin' {
|
|
|
2762
3030
|
*/
|
|
2763
3031
|
hydrate(mappedinSerializableData: string | object, shouldPopulateBundledImagesAsBlobs?: boolean): Promise<undefined>;
|
|
2764
3032
|
images: any;
|
|
3033
|
+
imageBinaries?: Map<string, Uint8Array>;
|
|
2765
3034
|
scenes: any;
|
|
2766
3035
|
fetch(): Promise<void>;
|
|
2767
3036
|
constructor(options: TGetVenueOptionsInternal & TGetVenueOptions);
|
|
3037
|
+
analytics: Analytics;
|
|
2768
3038
|
/**
|
|
2769
3039
|
* @hidden
|
|
2770
3040
|
*/
|
|
@@ -2888,6 +3158,60 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinPolyg
|
|
|
2888
3158
|
export class MappedinPolygon extends MappedinNavigatable {
|
|
2889
3159
|
#private;
|
|
2890
3160
|
geometry: any;
|
|
3161
|
+
image?: {
|
|
3162
|
+
visible: boolean;
|
|
3163
|
+
url: string | Blob;
|
|
3164
|
+
original: string | Blob;
|
|
3165
|
+
useLocalScaling: boolean;
|
|
3166
|
+
viewBox: {
|
|
3167
|
+
width: number;
|
|
3168
|
+
height: number;
|
|
3169
|
+
};
|
|
3170
|
+
scale: {
|
|
3171
|
+
x: number;
|
|
3172
|
+
y: number;
|
|
3173
|
+
};
|
|
3174
|
+
fitToBounds: boolean;
|
|
3175
|
+
position: {
|
|
3176
|
+
x: number;
|
|
3177
|
+
y: number;
|
|
3178
|
+
z: number;
|
|
3179
|
+
};
|
|
3180
|
+
rotation: {
|
|
3181
|
+
x: number;
|
|
3182
|
+
y: number;
|
|
3183
|
+
z: number;
|
|
3184
|
+
};
|
|
3185
|
+
_isAbsolutelyPositioned?: boolean;
|
|
3186
|
+
};
|
|
3187
|
+
holes?: unknown[];
|
|
3188
|
+
textures?: {
|
|
3189
|
+
image: any;
|
|
3190
|
+
name: 'front' | 'side';
|
|
3191
|
+
useFrontFaceImage?: boolean;
|
|
3192
|
+
}[];
|
|
3193
|
+
material: {
|
|
3194
|
+
color: string;
|
|
3195
|
+
opacity?: number;
|
|
3196
|
+
};
|
|
3197
|
+
label?: {
|
|
3198
|
+
visible: boolean;
|
|
3199
|
+
text: string;
|
|
3200
|
+
align: string;
|
|
3201
|
+
position: {
|
|
3202
|
+
x: number;
|
|
3203
|
+
y: number;
|
|
3204
|
+
z: number;
|
|
3205
|
+
};
|
|
3206
|
+
rotation: {
|
|
3207
|
+
x: number;
|
|
3208
|
+
y: number;
|
|
3209
|
+
z: number;
|
|
3210
|
+
};
|
|
3211
|
+
fontFamily: string;
|
|
3212
|
+
fontSize: number;
|
|
3213
|
+
color: string;
|
|
3214
|
+
};
|
|
2891
3215
|
/**
|
|
2892
3216
|
* Node ID.
|
|
2893
3217
|
*
|
|
@@ -3074,6 +3398,7 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinMap'
|
|
|
3074
3398
|
import type { TGeoReference } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.API.types';
|
|
3075
3399
|
import type { MappedinMapGroup } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinMapGroup';
|
|
3076
3400
|
import { MappedinCoordinate } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinCoordinate';
|
|
3401
|
+
import { MappedinLocation } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
3077
3402
|
/**
|
|
3078
3403
|
* A {@link MappedinMap} belonging to a specific {@link MappedinVenue}. Typically represents a certain floor. Give this to a {@link MapView} to display to the user.
|
|
3079
3404
|
*
|
|
@@ -3100,6 +3425,11 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinMap'
|
|
|
3100
3425
|
shortName: string;
|
|
3101
3426
|
elevation: number;
|
|
3102
3427
|
scale?: number;
|
|
3428
|
+
layers: {
|
|
3429
|
+
visible: boolean;
|
|
3430
|
+
name: string;
|
|
3431
|
+
id: string;
|
|
3432
|
+
}[];
|
|
3103
3433
|
x_scale?: number;
|
|
3104
3434
|
perspectiveId?: string;
|
|
3105
3435
|
scene: any;
|
|
@@ -3114,6 +3444,11 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinMap'
|
|
|
3114
3444
|
* @property polygons {[MappedinPolygon]}
|
|
3115
3445
|
*/
|
|
3116
3446
|
get polygons(): MappedinPolygon[] | undefined;
|
|
3447
|
+
/**
|
|
3448
|
+
* Locations on this map
|
|
3449
|
+
*/
|
|
3450
|
+
get locations(): MappedinLocation[];
|
|
3451
|
+
get nodes(): import("./MappedinNode").MappedinNode[];
|
|
3117
3452
|
/**
|
|
3118
3453
|
* Map Group this map belongs to.
|
|
3119
3454
|
*
|
|
@@ -3151,28 +3486,56 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinEvent
|
|
|
3151
3486
|
import type { Mappedin } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin';
|
|
3152
3487
|
import type { MappedinLocation } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinLocation';
|
|
3153
3488
|
/**
|
|
3154
|
-
* An event.
|
|
3489
|
+
* An event such as a promotion attached to a location in a venue for a period of time. Events can be created in the Mappedin CMS.
|
|
3155
3490
|
*
|
|
3156
3491
|
* @class MappedinEvent
|
|
3157
3492
|
*/
|
|
3158
3493
|
export class MappedinEvent {
|
|
3159
3494
|
#private;
|
|
3495
|
+
/**
|
|
3496
|
+
* Unique id string of the event.
|
|
3497
|
+
*/
|
|
3160
3498
|
id: string;
|
|
3161
3499
|
type: string;
|
|
3500
|
+
/**
|
|
3501
|
+
* Event name
|
|
3502
|
+
*/
|
|
3162
3503
|
name: string;
|
|
3504
|
+
/**
|
|
3505
|
+
* Optional, longer description of the event.
|
|
3506
|
+
*/
|
|
3163
3507
|
description?: string | undefined;
|
|
3508
|
+
/**
|
|
3509
|
+
* Optional image to be used for displaying the event.
|
|
3510
|
+
*/
|
|
3164
3511
|
image?: TImage | undefined;
|
|
3512
|
+
/**
|
|
3513
|
+
* Start timestamp of the event. Javascript date in milliseconds since 1 January 1970 UTC.
|
|
3514
|
+
*/
|
|
3165
3515
|
startDate?: number | undefined;
|
|
3516
|
+
/**
|
|
3517
|
+
* Start timestamp of the event. Javascript date in milliseconds since 1 January 1970 UTC.
|
|
3518
|
+
*/
|
|
3166
3519
|
endDate?: number | undefined;
|
|
3520
|
+
/**
|
|
3521
|
+
* Timestamp when the event should be displayed. Javascript date in milliseconds since 1 January 1970 UTC.
|
|
3522
|
+
*/
|
|
3167
3523
|
showDate?: number | undefined;
|
|
3524
|
+
/**
|
|
3525
|
+
* @internal
|
|
3526
|
+
*/
|
|
3168
3527
|
constructor(mappedin: Mappedin, data: any);
|
|
3169
3528
|
/**
|
|
3170
|
-
* Location this
|
|
3171
|
-
*
|
|
3172
|
-
* @property location {MappedinLocation}
|
|
3529
|
+
* Location this event is occuring at.
|
|
3173
3530
|
*/
|
|
3174
3531
|
location(): MappedinLocation | undefined;
|
|
3532
|
+
/**
|
|
3533
|
+
* @internal
|
|
3534
|
+
*/
|
|
3175
3535
|
static hydrate(events: any, mappedin: Mappedin): MappedinEvent[];
|
|
3536
|
+
/**
|
|
3537
|
+
* @internal
|
|
3538
|
+
*/
|
|
3176
3539
|
static fetch(mappedin: Mappedin): Promise<MappedinEvent[]>;
|
|
3177
3540
|
toJSON(): any;
|
|
3178
3541
|
}
|
|
@@ -3245,9 +3608,10 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinVenue
|
|
|
3245
3608
|
tzidOverride: string;
|
|
3246
3609
|
utcOffset: string;
|
|
3247
3610
|
website: string;
|
|
3248
|
-
constructor(data: any);
|
|
3249
|
-
static hydrate(data: any): MappedinVenue;
|
|
3611
|
+
constructor(mappedin: Mappedin, data: any);
|
|
3612
|
+
static hydrate(data: any, mappedin: Mappedin): MappedinVenue;
|
|
3250
3613
|
static fetch(mappedin: Mappedin): Promise<MappedinVenue>;
|
|
3614
|
+
get isMultiBuilding(): any;
|
|
3251
3615
|
toJSON(): any;
|
|
3252
3616
|
}
|
|
3253
3617
|
}
|
|
@@ -3464,6 +3828,229 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinNavig
|
|
|
3464
3828
|
}
|
|
3465
3829
|
}
|
|
3466
3830
|
|
|
3831
|
+
declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.OfflineSearch' {
|
|
3832
|
+
import { Mappedin } from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin';
|
|
3833
|
+
import type { SearchOptions } from 'minisearch';
|
|
3834
|
+
import { MappedinLocation } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinLocation';
|
|
3835
|
+
import { MappedinCategory } from '@mappedin/react-native-sdk/core/packages/get-venue/MappedinCategory';
|
|
3836
|
+
export const removeAccents: (it: string) => string;
|
|
3837
|
+
export type { SearchOptions };
|
|
3838
|
+
/**
|
|
3839
|
+
* A {@link Mappedin.OfflineSearch} is an offline search module
|
|
3840
|
+
*
|
|
3841
|
+
*
|
|
3842
|
+
* @class Mappedin.OfflineSearch
|
|
3843
|
+
*/
|
|
3844
|
+
export type TMappedinOfflineSearchAllOptions = {
|
|
3845
|
+
/**
|
|
3846
|
+
* Array of stopwords to ignore when searching, default: english stopwords
|
|
3847
|
+
*/
|
|
3848
|
+
stopWords?: string[];
|
|
3849
|
+
/**
|
|
3850
|
+
* Index location tags - typically better to use either tags or descriptions, depending on what's available
|
|
3851
|
+
* @default true
|
|
3852
|
+
*/
|
|
3853
|
+
searchTags?: boolean;
|
|
3854
|
+
/**
|
|
3855
|
+
* Index location descriptions - typically better to use either tags or descriptions, depending on what's available
|
|
3856
|
+
* @default true
|
|
3857
|
+
*/
|
|
3858
|
+
searchDescriptions?: boolean;
|
|
3859
|
+
/**
|
|
3860
|
+
* Also index all tags for every location in every category (caution: this may slow down indexing and search)
|
|
3861
|
+
* @default false
|
|
3862
|
+
*/
|
|
3863
|
+
searchTagsInCategories?: boolean;
|
|
3864
|
+
/**
|
|
3865
|
+
* Also index all tags for every location in every category (caution: this may slow down indexing and search)
|
|
3866
|
+
* @default false
|
|
3867
|
+
*/
|
|
3868
|
+
searchDescriptionsInCategories?: boolean;
|
|
3869
|
+
/**
|
|
3870
|
+
* Initialize Search with a previously indexed JSON string (outputted by OfflineSearch.toJSON())
|
|
3871
|
+
*/
|
|
3872
|
+
jsonIndex?: string;
|
|
3873
|
+
/**
|
|
3874
|
+
* Use the location polygons' rank in weighing results
|
|
3875
|
+
*/
|
|
3876
|
+
useLocationRank?: boolean;
|
|
3877
|
+
/**
|
|
3878
|
+
* Emit Analytics events when doing search
|
|
3879
|
+
* @default true when running in production
|
|
3880
|
+
*/
|
|
3881
|
+
emitAnalyticsEvents?: boolean;
|
|
3882
|
+
/**
|
|
3883
|
+
* Fine tune search constants
|
|
3884
|
+
*/
|
|
3885
|
+
constants: {
|
|
3886
|
+
/**
|
|
3887
|
+
* Fuzziness index for location names and tags
|
|
3888
|
+
* @default 0.09
|
|
3889
|
+
*/
|
|
3890
|
+
PRIMARY_INDEX_FUZZYNESS: number;
|
|
3891
|
+
/**
|
|
3892
|
+
* Multiplier for location names (1 by default)
|
|
3893
|
+
* @default 1
|
|
3894
|
+
*/
|
|
3895
|
+
PRIMARY_INDEX_WEIGHT: number;
|
|
3896
|
+
/**
|
|
3897
|
+
* Multiplier for descriptions
|
|
3898
|
+
* @default 0.025
|
|
3899
|
+
*/
|
|
3900
|
+
SECONDARY_INDEX_WEIGHT: number;
|
|
3901
|
+
/**
|
|
3902
|
+
* Multiplier for location names
|
|
3903
|
+
* @default 1
|
|
3904
|
+
*/
|
|
3905
|
+
LOCATION_NAME_WEIGHT: number;
|
|
3906
|
+
/**
|
|
3907
|
+
* Multiplier for category names
|
|
3908
|
+
* @default 0.5
|
|
3909
|
+
*/
|
|
3910
|
+
CATEGORY_NAME_WEIGHT: number;
|
|
3911
|
+
/**
|
|
3912
|
+
* Multiplier for category locations' descriptions
|
|
3913
|
+
* @default 0.0005
|
|
3914
|
+
*/
|
|
3915
|
+
CATEGORY_LOCATION_DESCRIPTION_WEIGHT: number;
|
|
3916
|
+
/**
|
|
3917
|
+
* Multiplier for category locations' tags
|
|
3918
|
+
* @default 0.0005
|
|
3919
|
+
*/
|
|
3920
|
+
CATEGORY_LOCATION_TAGS_WEIGHT: number;
|
|
3921
|
+
/**
|
|
3922
|
+
* Multiplier for category locations' names
|
|
3923
|
+
* @default 0.01
|
|
3924
|
+
*/
|
|
3925
|
+
CATEGORY_LOCATION_NAME_WEIGHT: number;
|
|
3926
|
+
/**
|
|
3927
|
+
* Multiplier for location tags
|
|
3928
|
+
* @default 0.05
|
|
3929
|
+
*/
|
|
3930
|
+
PRIMARY_INDEX_TAGS_NAME_WEIGHT: number;
|
|
3931
|
+
/**
|
|
3932
|
+
* Default rank when one isn't available in the data, default = 1
|
|
3933
|
+
* @default 1
|
|
3934
|
+
*/
|
|
3935
|
+
LOCATION_DEFAULT_RANK: number;
|
|
3936
|
+
/**
|
|
3937
|
+
* Ratio of Fuzzy Searches of Location names and tags relative to exact
|
|
3938
|
+
* @default 0.01
|
|
3939
|
+
*/
|
|
3940
|
+
RATIO_OF_FUZZY_TO_EXACT: number;
|
|
3941
|
+
/**
|
|
3942
|
+
* Ratio of Prefix Searches of Location names and tags relative to exact
|
|
3943
|
+
* @default 0.2
|
|
3944
|
+
*/
|
|
3945
|
+
RATIO_OF_PREFIX_TO_EXACT: number;
|
|
3946
|
+
};
|
|
3947
|
+
};
|
|
3948
|
+
export type TMappedinOfflineAllSearchMatch = {
|
|
3949
|
+
/**
|
|
3950
|
+
* The term that was found
|
|
3951
|
+
*/
|
|
3952
|
+
term: string;
|
|
3953
|
+
/**
|
|
3954
|
+
* Term's weight
|
|
3955
|
+
*/
|
|
3956
|
+
weight: number;
|
|
3957
|
+
/**
|
|
3958
|
+
* What field the search matched on
|
|
3959
|
+
*/
|
|
3960
|
+
matchesOn: string;
|
|
3961
|
+
/**
|
|
3962
|
+
* The value of that field
|
|
3963
|
+
*/
|
|
3964
|
+
value?: string;
|
|
3965
|
+
};
|
|
3966
|
+
export type TMappedinOfflineSearchOptions = Partial<TMappedinOfflineSearchAllOptions>;
|
|
3967
|
+
export type TMappedinOfflineSearchResult = {
|
|
3968
|
+
/**
|
|
3969
|
+
* Type describing the object
|
|
3970
|
+
*/
|
|
3971
|
+
type: 'MappedinLocation' | 'MappedinCategory' | 'Custom';
|
|
3972
|
+
/**
|
|
3973
|
+
* Details on why the result was returned
|
|
3974
|
+
*/
|
|
3975
|
+
matches: TMappedinOfflineAllSearchMatch[];
|
|
3976
|
+
/**
|
|
3977
|
+
* Found object
|
|
3978
|
+
*/
|
|
3979
|
+
object: MappedinLocation | MappedinCategory | Record<string, unknown>;
|
|
3980
|
+
/**
|
|
3981
|
+
* Total score of the result
|
|
3982
|
+
*/
|
|
3983
|
+
score: number;
|
|
3984
|
+
};
|
|
3985
|
+
export type TMappedinOfflineSearchSuggestions = {
|
|
3986
|
+
/**
|
|
3987
|
+
* Total number of suggestions generated
|
|
3988
|
+
*/
|
|
3989
|
+
total: number;
|
|
3990
|
+
/**
|
|
3991
|
+
* List of suggestions
|
|
3992
|
+
*/
|
|
3993
|
+
hits: {
|
|
3994
|
+
/**
|
|
3995
|
+
* Suggestion text
|
|
3996
|
+
*/
|
|
3997
|
+
text: string;
|
|
3998
|
+
}[];
|
|
3999
|
+
};
|
|
4000
|
+
/**
|
|
4001
|
+
* A {@link OfflineSearch} is an offline search module. It can be initialized at any time by passing the {@link Mappedin} object and a set of {@link TMappedinOfflineSearchOptions} options.
|
|
4002
|
+
*
|
|
4003
|
+
*
|
|
4004
|
+
* @class Mappedin.OfflineSearch
|
|
4005
|
+
*/
|
|
4006
|
+
export class OfflineSearch {
|
|
4007
|
+
#private;
|
|
4008
|
+
constructor(
|
|
4009
|
+
/**
|
|
4010
|
+
* Mappedin Venue Object, typically returned by `getVenue`/`showVenue`
|
|
4011
|
+
*/
|
|
4012
|
+
mappedin: Mappedin, options?: TMappedinOfflineSearchOptions);
|
|
4013
|
+
/**
|
|
4014
|
+
* Get Suggestions for term
|
|
4015
|
+
*/
|
|
4016
|
+
suggest(
|
|
4017
|
+
/**
|
|
4018
|
+
* Search term
|
|
4019
|
+
*/
|
|
4020
|
+
term: string): Promise<TMappedinOfflineSearchSuggestions>;
|
|
4021
|
+
/**
|
|
4022
|
+
* Search for a term
|
|
4023
|
+
*/
|
|
4024
|
+
search(
|
|
4025
|
+
/**
|
|
4026
|
+
* Search term
|
|
4027
|
+
*/
|
|
4028
|
+
term: string): Promise<TMappedinOfflineSearchResult[]>;
|
|
4029
|
+
/**
|
|
4030
|
+
* Export search index to JSON for storage/caching - this would avoid having to re-index
|
|
4031
|
+
* on page reload
|
|
4032
|
+
*/
|
|
4033
|
+
toJSON(): Promise<string>;
|
|
4034
|
+
/**
|
|
4035
|
+
* Add a custom query to the search index
|
|
4036
|
+
*/
|
|
4037
|
+
addQuery(params: {
|
|
4038
|
+
/**
|
|
4039
|
+
* Query string to match for this object
|
|
4040
|
+
*/
|
|
4041
|
+
query: string;
|
|
4042
|
+
/**
|
|
4043
|
+
* Object that is returned when query matches
|
|
4044
|
+
*/
|
|
4045
|
+
object: MappedinLocation | MappedinCategory | Record<string, unknown>;
|
|
4046
|
+
/**
|
|
4047
|
+
* Optional weight to multiply by the score
|
|
4048
|
+
*/
|
|
4049
|
+
weight?: number;
|
|
4050
|
+
}): Promise<void>;
|
|
4051
|
+
}
|
|
4052
|
+
}
|
|
4053
|
+
|
|
3467
4054
|
declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.API.types' {
|
|
3468
4055
|
/**
|
|
3469
4056
|
* This file contains the API types for MappedinSDK - before they get turned into Classes
|
|
@@ -3579,9 +4166,6 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.API.
|
|
|
3579
4166
|
export type TMapGroup = {
|
|
3580
4167
|
name: string;
|
|
3581
4168
|
id: string;
|
|
3582
|
-
maps: {
|
|
3583
|
-
id: TMap['id'];
|
|
3584
|
-
}[];
|
|
3585
4169
|
};
|
|
3586
4170
|
export type TBuilding = TLocation & {
|
|
3587
4171
|
groupId: string;
|
|
@@ -3634,27 +4218,32 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.API.
|
|
|
3634
4218
|
entranceNodeId: string;
|
|
3635
4219
|
score: number;
|
|
3636
4220
|
};
|
|
3637
|
-
export type
|
|
3638
|
-
address: string;
|
|
3639
|
-
city: string;
|
|
3640
|
-
countrycode: string;
|
|
3641
|
-
defaultMap: string;
|
|
3642
|
-
externalId: string;
|
|
4221
|
+
export type TLocationState = {
|
|
3643
4222
|
id: string;
|
|
3644
|
-
latitude: number;
|
|
3645
|
-
logo: TLogo;
|
|
3646
|
-
longitude: number;
|
|
3647
|
-
metadata?: any;
|
|
3648
4223
|
name: string;
|
|
3649
|
-
|
|
3650
|
-
|
|
3651
|
-
|
|
3652
|
-
|
|
3653
|
-
|
|
3654
|
-
|
|
3655
|
-
|
|
3656
|
-
|
|
3657
|
-
|
|
4224
|
+
value: string;
|
|
4225
|
+
};
|
|
4226
|
+
export type TVenue = {
|
|
4227
|
+
address?: string;
|
|
4228
|
+
city?: string;
|
|
4229
|
+
countrycode?: string;
|
|
4230
|
+
defaultMap?: string;
|
|
4231
|
+
externalId?: string;
|
|
4232
|
+
id?: string;
|
|
4233
|
+
latitude?: number;
|
|
4234
|
+
logo?: TLogo;
|
|
4235
|
+
longitude?: number;
|
|
4236
|
+
metadata?: any;
|
|
4237
|
+
name?: string;
|
|
4238
|
+
operationHours?: TOpeningHours[];
|
|
4239
|
+
postal?: string;
|
|
4240
|
+
slug?: string;
|
|
4241
|
+
state?: string;
|
|
4242
|
+
telephone?: string;
|
|
4243
|
+
tzid?: string;
|
|
4244
|
+
tzidOverride?: string;
|
|
4245
|
+
utcOffset?: string;
|
|
4246
|
+
website?: string;
|
|
3658
4247
|
};
|
|
3659
4248
|
export type TMappedinAPI = {
|
|
3660
4249
|
nodes: TNode[];
|
|
@@ -3666,6 +4255,8 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.API.
|
|
|
3666
4255
|
themes: any;
|
|
3667
4256
|
venue: TVenue;
|
|
3668
4257
|
vortexes: TVortex[];
|
|
4258
|
+
locationStates?: TLocationState[];
|
|
4259
|
+
imageBinaries?: Map<string, Uint8Array>;
|
|
3669
4260
|
};
|
|
3670
4261
|
}
|
|
3671
4262
|
|
|
@@ -3804,6 +4395,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
3804
4395
|
RIGHT = "right"
|
|
3805
4396
|
}
|
|
3806
4397
|
class FloatingLabel extends BaseCollider implements ISmarterLabel {
|
|
4398
|
+
#private;
|
|
3807
4399
|
lines: number;
|
|
3808
4400
|
contextConfigured: boolean;
|
|
3809
4401
|
fillText: TDrawFn | undefined;
|
|
@@ -3813,11 +4405,10 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
3813
4405
|
clearColor: () => void;
|
|
3814
4406
|
zoomProportion: number;
|
|
3815
4407
|
_cache: {};
|
|
3816
|
-
_dirty: boolean;
|
|
3817
4408
|
appearance: TAppearanceFilledIn;
|
|
3818
4409
|
mapView: ICore;
|
|
3819
4410
|
constructor(options: TFloatingLabelOptionsInternal, mapView: ICore);
|
|
3820
|
-
enable(): void;
|
|
4411
|
+
enable(updateEngine?: boolean): void;
|
|
3821
4412
|
get strategies(): TColliderStrategy[];
|
|
3822
4413
|
getCachedSymbol(orientation: any, textAlign: any, xCoordinate: any): any;
|
|
3823
4414
|
colliderDidMount(): void;
|
|
@@ -3826,7 +4417,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
3826
4417
|
colliderDidUpdateVisiblity(): void;
|
|
3827
4418
|
colliderDidGoOutsideGrid(): void;
|
|
3828
4419
|
colliderDidNotFindAHome(): void;
|
|
3829
|
-
disable(): void;
|
|
4420
|
+
disable(updateEngine?: boolean): void;
|
|
3830
4421
|
draw(context: CanvasRenderingContext2D): void;
|
|
3831
4422
|
static original: FloatingLabel;
|
|
3832
4423
|
static clone(options: TFloatingLabelOptionsInternal, mapView: ICore): any;
|
|
@@ -3957,19 +4548,19 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
3957
4548
|
}
|
|
3958
4549
|
export type TBlueDotPositionUpdate = {
|
|
3959
4550
|
/**
|
|
3960
|
-
*
|
|
4551
|
+
* The {@link MappedinMap} Blue Dot position is on
|
|
3961
4552
|
*/
|
|
3962
4553
|
map?: MappedinMap;
|
|
3963
4554
|
/**
|
|
3964
|
-
* The nearest
|
|
4555
|
+
* The nearest {@link MappedinNode} to the Blue Dot position
|
|
3965
4556
|
*/
|
|
3966
4557
|
nearestNode?: MappedinNode;
|
|
3967
4558
|
/**
|
|
3968
|
-
* Actual position of
|
|
4559
|
+
* Actual position of Blue Dot (post smoothing, if smoothing is enabled)
|
|
3969
4560
|
*/
|
|
3970
4561
|
position?: TGeolocationObject;
|
|
3971
4562
|
/**
|
|
3972
|
-
* Current
|
|
4563
|
+
* Current Blue Dot bearing
|
|
3973
4564
|
*/
|
|
3974
4565
|
bearing?: number;
|
|
3975
4566
|
};
|
|
@@ -3979,11 +4570,11 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
3979
4570
|
*/
|
|
3980
4571
|
name: E_BLUEDOT_STATE;
|
|
3981
4572
|
/**
|
|
3982
|
-
* Visiblity
|
|
4573
|
+
* Visiblity state of the Blue Dot marker
|
|
3983
4574
|
*/
|
|
3984
4575
|
markerVisibility?: E_BLUEDOT_MARKER_STATE;
|
|
3985
4576
|
/**
|
|
3986
|
-
* Reason why
|
|
4577
|
+
* Reason why Blue Dot may be in the current state
|
|
3987
4578
|
*/
|
|
3988
4579
|
reason?: E_BLUEDOT_STATE_REASON;
|
|
3989
4580
|
/**
|
|
@@ -3991,6 +4582,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
3991
4582
|
*/
|
|
3992
4583
|
message?: GeolocationPositionError | string;
|
|
3993
4584
|
};
|
|
4585
|
+
export const FALLBACK_TO_GPS_TIMEOUT = 10000;
|
|
3994
4586
|
type TBlueDotProps = {
|
|
3995
4587
|
data: any;
|
|
3996
4588
|
mapView: MapView;
|
|
@@ -4003,80 +4595,84 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
4003
4595
|
FakeGeolocation: typeof FakeGeolocation;
|
|
4004
4596
|
};
|
|
4005
4597
|
export default BlueDot;
|
|
4006
|
-
}
|
|
4007
|
-
|
|
4008
|
-
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartTooltip' {
|
|
4009
|
-
import './Mappedin.SmartTooltip.scss';
|
|
4010
|
-
import { COLLISION_RANKING_TIERS } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums';
|
|
4011
|
-
import HTMLCollider, { IHTMLCollider } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.HTMLCollider';
|
|
4012
|
-
import { Vector3 } from 'three';
|
|
4013
|
-
import { TColliderStrategy } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartCollider';
|
|
4014
|
-
/**
|
|
4015
|
-
|
|
4016
|
-
|
|
4017
|
-
|
|
4018
|
-
|
|
4019
|
-
|
|
4020
|
-
|
|
4021
|
-
|
|
4022
|
-
|
|
4023
|
-
|
|
4024
|
-
|
|
4025
|
-
|
|
4026
|
-
|
|
4027
|
-
|
|
4028
|
-
|
|
4029
|
-
|
|
4030
|
-
|
|
4031
|
-
|
|
4032
|
-
|
|
4033
|
-
|
|
4034
|
-
|
|
4035
|
-
|
|
4036
|
-
|
|
4037
|
-
|
|
4598
|
+
}
|
|
4599
|
+
|
|
4600
|
+
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartTooltip' {
|
|
4601
|
+
import './Mappedin.SmartTooltip.scss';
|
|
4602
|
+
import { COLLISION_RANKING_TIERS } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums';
|
|
4603
|
+
import HTMLCollider, { IHTMLCollider } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.HTMLCollider';
|
|
4604
|
+
import { Vector3 } from 'three';
|
|
4605
|
+
import { TColliderStrategy } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartCollider';
|
|
4606
|
+
/**
|
|
4607
|
+
*
|
|
4608
|
+
* A Tooltip is an html element that attempts to orient itself around an anchor in 3D space. It will always maintain the same size on the screen, but will attempt to change its orientation based on other colliders in the scene.
|
|
4609
|
+
*
|
|
4610
|
+
* Make your own and add it directly to the map with {{#crossLink "MapView/createTooltip:method"}}{{/crossLink}}, or use the constructor and add it when you want.
|
|
4611
|
+
*
|
|
4612
|
+
* You will need to specify at least `options.position` and one of `options.html` and `options.selector` OR `options.contentHtml`.
|
|
4613
|
+
*
|
|
4614
|
+
*
|
|
4615
|
+
* @class Tooltip
|
|
4616
|
+
*
|
|
4617
|
+
* @constructor
|
|
4618
|
+
* @param options {Object} Passes on options (e.g. html, text, position, map, padding, defaultAnchorType, enabledAnchorTypes, collisionRank) to MapView.Tooltip's options argument.
|
|
4619
|
+
* @param [options.html] Pass in custom html for your marker, if using this method you must also pass in a selector for your content.
|
|
4620
|
+
* @param [options.selector] Used in conjuction with the html property to select the div for repositioning
|
|
4621
|
+
* @param [options.contentHtml] Use mappedin's default tooltip styling with custom inner html content
|
|
4622
|
+
* @param [options.text] Instead of passing html pass in plain text to be displayed in the tooltip
|
|
4623
|
+
* @param [options.position] should be something you got from {{#crossLink "MapView/getPositionPolygon:method"}}{{/crossLink}} or {{#crossLink "MapView/getPositionNode:method"}}{{/crossLink}}.
|
|
4624
|
+
* @param [options.map] The map ID where the tooltip should be displayed
|
|
4625
|
+
* @param [options.defaultAnchorType] The default orientation to place the tooltip.
|
|
4626
|
+
* @param [options.padding] The distance in pixel to offset the tooltip from the anchor point.
|
|
4627
|
+
* @param [options.enabledAnchorTypes] An object used to disable certain anchor positions from being used.
|
|
4628
|
+
* @param [options.collisionRank] The rank of the object used when comparing colliders to determine which should be shown.
|
|
4629
|
+
*/
|
|
4038
4630
|
export type TSmartTooltipOptions = {
|
|
4039
|
-
|
|
4040
|
-
|
|
4041
|
-
|
|
4042
|
-
|
|
4043
|
-
|
|
4044
|
-
|
|
4045
|
-
|
|
4046
|
-
|
|
4047
|
-
|
|
4048
|
-
|
|
4049
|
-
|
|
4050
|
-
|
|
4051
|
-
|
|
4631
|
+
html?: string;
|
|
4632
|
+
contentHtml?: string;
|
|
4633
|
+
text?: string;
|
|
4634
|
+
position: Vector3;
|
|
4635
|
+
selector?: string;
|
|
4636
|
+
map: string;
|
|
4637
|
+
padding?: number;
|
|
4638
|
+
alwaysVisible?: boolean;
|
|
4639
|
+
collisionRank?: COLLISION_RANKING_TIERS;
|
|
4640
|
+
defaultAnchorType?: string;
|
|
4641
|
+
enabledAnchorTypes?: {
|
|
4642
|
+
[type: string]: boolean;
|
|
4643
|
+
};
|
|
4052
4644
|
};
|
|
4053
4645
|
type TTooltipStyle = {
|
|
4054
|
-
|
|
4055
|
-
|
|
4646
|
+
top?: string;
|
|
4647
|
+
left?: string;
|
|
4056
4648
|
};
|
|
4057
4649
|
export type TOOLTIP_ANCHOR = {
|
|
4058
|
-
|
|
4059
|
-
|
|
4060
|
-
|
|
4061
|
-
|
|
4062
|
-
|
|
4063
|
-
|
|
4064
|
-
|
|
4065
|
-
|
|
4650
|
+
top?: boolean;
|
|
4651
|
+
left?: boolean;
|
|
4652
|
+
topLeft?: boolean;
|
|
4653
|
+
right?: boolean;
|
|
4654
|
+
topRight?: boolean;
|
|
4655
|
+
bottom?: boolean;
|
|
4656
|
+
bottomLeft?: boolean;
|
|
4657
|
+
bottomRight?: boolean;
|
|
4066
4658
|
};
|
|
4067
4659
|
class SmartTooltip extends HTMLCollider implements IHTMLCollider {
|
|
4068
|
-
|
|
4069
|
-
|
|
4070
|
-
|
|
4071
|
-
|
|
4072
|
-
|
|
4073
|
-
|
|
4074
|
-
|
|
4075
|
-
|
|
4076
|
-
|
|
4077
|
-
|
|
4078
|
-
|
|
4079
|
-
|
|
4660
|
+
#private;
|
|
4661
|
+
className: string;
|
|
4662
|
+
_el: Element | null;
|
|
4663
|
+
style: TTooltipStyle;
|
|
4664
|
+
constructor(options: TSmartTooltipOptions);
|
|
4665
|
+
updateClassName: (className: any) => void;
|
|
4666
|
+
get strategies(): TColliderStrategy[];
|
|
4667
|
+
colliderDidMount(): void;
|
|
4668
|
+
/**
|
|
4669
|
+
* @internal
|
|
4670
|
+
*/
|
|
4671
|
+
updateDimensionsImmediately(): void;
|
|
4672
|
+
setAction(action: any): void;
|
|
4673
|
+
colliderDidNotFindAHome(): void;
|
|
4674
|
+
colliderDidGoOffscreen(): void;
|
|
4675
|
+
colliderDidUpdateVisiblity(): void;
|
|
4080
4676
|
}
|
|
4081
4677
|
export default SmartTooltip;
|
|
4082
4678
|
}
|
|
@@ -4088,6 +4684,9 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/layers/BlueDot
|
|
|
4088
4684
|
import { TEnableBlueDotOptions } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.types';
|
|
4089
4685
|
import { PubSub } from '@mappedin/react-native-sdk/core/packages/renderer/internal/pub-sub.typed';
|
|
4090
4686
|
import EventSystemLayer from '@mappedin/react-native-sdk/core/packages/renderer/layers/EventSystem';
|
|
4687
|
+
/**
|
|
4688
|
+
* Blue Dot Layer used for controlling the Blue Dot and listening to Blue Dot state change and position update events. Use the {@link on}-method to set listeners for {@link TBlueDotStateChange} and {@link TBlueDotPositionUpdate} events.
|
|
4689
|
+
*/
|
|
4091
4690
|
class BlueDotLayer extends PubSub<E_BLUEDOT_EVENT_PAYLOAD, E_BLUEDOT_EVENT> {
|
|
4092
4691
|
#private;
|
|
4093
4692
|
/**
|
|
@@ -4099,7 +4698,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/layers/BlueDot
|
|
|
4099
4698
|
*/
|
|
4100
4699
|
enable(options?: TEnableBlueDotOptions): void;
|
|
4101
4700
|
/**
|
|
4102
|
-
*
|
|
4701
|
+
* Disables Blue Dot and stops emitting events.
|
|
4103
4702
|
*/
|
|
4104
4703
|
disable(): void;
|
|
4105
4704
|
}
|
|
@@ -4118,7 +4717,17 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/layers/Journey
|
|
|
4118
4717
|
*/
|
|
4119
4718
|
constructor(mapView: MapView, core: ICore);
|
|
4120
4719
|
/**
|
|
4121
|
-
* Draw a Journey
|
|
4720
|
+
* Draw a Journey based on directions. Example usage:
|
|
4721
|
+
*
|
|
4722
|
+
* ```typescript
|
|
4723
|
+
* const startLocation = venue.locations.find(location => location.name === "Cleo");
|
|
4724
|
+
* const endLocation = venue.locations.find(location => location.name === "American Eagle");
|
|
4725
|
+
*
|
|
4726
|
+
* const directions = startLocation.directionsTo(endLocation);
|
|
4727
|
+
* mapView.Journey.draw(directions);
|
|
4728
|
+
* ```
|
|
4729
|
+
*
|
|
4730
|
+
* Use options to set connection (such as elevators and escalators) HTML tooltip template, departure and destination marker templates, path style and polygon higlight color. If no options are set, sane defaults are used to draw markers, tooltips and polygon highlights.
|
|
4122
4731
|
*/
|
|
4123
4732
|
draw(directions: MappedinDirections | MappedinDirections[], options?: TJourneyOptions): Journey;
|
|
4124
4733
|
/**
|
|
@@ -4151,8 +4760,10 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
4151
4760
|
}
|
|
4152
4761
|
export class FlatLabel {
|
|
4153
4762
|
constructor(options: any, venue: any, mapObject: any, DEFAULT_FONT: any, polygonMeshesById: any, textLabelsByPolygonId: any, mapView: any, scope: any, atlas: any);
|
|
4763
|
+
id: any;
|
|
4154
4764
|
text: any;
|
|
4155
4765
|
stateText: string;
|
|
4766
|
+
fullText: any;
|
|
4156
4767
|
font: any;
|
|
4157
4768
|
atlas: any;
|
|
4158
4769
|
canvasBounds: any;
|
|
@@ -4166,8 +4777,8 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
4166
4777
|
polygonMeshesById: any;
|
|
4167
4778
|
polyId: any;
|
|
4168
4779
|
map: any;
|
|
4169
|
-
color:
|
|
4170
|
-
baseColor:
|
|
4780
|
+
color: any;
|
|
4781
|
+
baseColor: any;
|
|
4171
4782
|
hideOnCreate: boolean;
|
|
4172
4783
|
hoverLabelText: any;
|
|
4173
4784
|
fontSize: number;
|
|
@@ -4198,7 +4809,6 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
4198
4809
|
index: any;
|
|
4199
4810
|
layout(map: any, origin: any, size: any, rotation: any, uv: any, color: any): void;
|
|
4200
4811
|
}
|
|
4201
|
-
import { Color } from "three/src/math/Color";
|
|
4202
4812
|
export {};
|
|
4203
4813
|
}
|
|
4204
4814
|
|
|
@@ -4376,23 +4986,6 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/pub-s
|
|
|
4376
4986
|
}
|
|
4377
4987
|
}
|
|
4378
4988
|
|
|
4379
|
-
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.CameraControls' {
|
|
4380
|
-
export default CameraControls;
|
|
4381
|
-
/**
|
|
4382
|
-
* The advanced, manual camera controls for {{#crossLink "MapView"}}{{/crossLink}}. You probably don't need to use this at all, instead relying on the MapView's {{#crossLink "MapView/focusOn:method"}}{{/crossLink}}, {{#crossLink "MapView/resetCamera:method"}}{{/crossLink}} and built in touch/mouse controls.
|
|
4383
|
-
* This class will let you do things like change the min/max zoom, tilt, and pan, attach to camera events, and move/animate the camera to specifc points.
|
|
4384
|
-
*
|
|
4385
|
-
* The camera works by setting an anchor point on the scene at ground level and pointing the camera at it. {{#crossLink "CameraControls/zoom:method"}}{{/crossLink}} controls how far the camera is from the anchor, and {{#crossLink "CameraControls/tilt:method"}}{{/crossLink}}/{{#crossLink "CameraControls/rotate:method"}}{{/crossLink}} controls the angle the camera is rotated about it.
|
|
4386
|
-
* The camera will always be pointed directly at the anchor point. {{#crossLink "CameraControls/pan:method"}}{{/crossLink}} or {{#crossLink "CameraControls/setPosition:method"}}{{/crossLink}} will move that anchor around on the 2D ground plane.
|
|
4387
|
-
*
|
|
4388
|
-
* Created for you automatically with a MapView, don't re-create yourself.
|
|
4389
|
-
* @type {any}
|
|
4390
|
-
*
|
|
4391
|
-
* @class CameraControls
|
|
4392
|
-
*/
|
|
4393
|
-
let CameraControls: any;
|
|
4394
|
-
}
|
|
4395
|
-
|
|
4396
4989
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.RenderTasks' {
|
|
4397
4990
|
export default RENDER;
|
|
4398
4991
|
namespace RENDER {
|
|
@@ -4748,9 +5341,9 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/MapView' {
|
|
|
4748
5341
|
|
|
4749
5342
|
declare module '@mappedin/react-native-sdk/core/packages/renderer' {
|
|
4750
5343
|
import Search from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.Search';
|
|
4751
|
-
import Analytics from '@mappedin/react-native-sdk/core/packages/
|
|
5344
|
+
import Analytics from '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.Analytics';
|
|
4752
5345
|
import { MapView } from '@mappedin/react-native-sdk/core/packages/renderer/MapView';
|
|
4753
|
-
import { getVenue, getVenueBundle, Mappedin, downloadBundle, getVenueBundleURL, MappedinDestinationSet, MappedinMap, TGetVenueBundleOptions, TGetVenueOptions } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
5346
|
+
import { getVenue, getVenueBundle, Mappedin, downloadBundle, getVenueBundleURL, downloadVenueBundleMVF, MappedinDestinationSet, MappedinMap, TGetVenueBundleOptions, TGetVenueOptions } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
4754
5347
|
import { PositionUpdater } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.BlueDot/Mappedin.BlueDot.core';
|
|
4755
5348
|
import type { TMapViewOptions, TJourneyOptions } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.types';
|
|
4756
5349
|
import { labelThemes } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.types';
|
|
@@ -4781,9 +5374,9 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer' {
|
|
|
4781
5374
|
*/
|
|
4782
5375
|
function showVenue<T extends Mappedin>(el: HTMLElement, venue: T, options?: TMapViewOptions): Promise<MapView>;
|
|
4783
5376
|
export { COLLISION_RANKING_TIERS, STATE, E_SDK_EVENT, E_BLUEDOT_STATE_REASON, E_BLUEDOT_MARKER_STATE, E_BLUEDOT_EVENT, E_BLUEDOT_STATE, E_CAMERA_EVENT } from '@mappedin/react-native-sdk/core/packages/renderer/MapView.enums';
|
|
4784
|
-
export { Search, getVenue, getVenueBundle, showVenue, downloadBundle, getVenueBundleURL, PositionUpdater, Analytics, MappedinDestinationSet, MARKER_ANCHOR, labelThemes };
|
|
5377
|
+
export { Search, getVenue, getVenueBundle, showVenue, downloadBundle, getVenueBundleURL, downloadVenueBundleMVF, PositionUpdater, Analytics, MappedinDestinationSet, MARKER_ANCHOR, labelThemes };
|
|
4785
5378
|
import DefaultAssetManager from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.AssetManager';
|
|
4786
|
-
const setAssetManager: (am:
|
|
5379
|
+
const setAssetManager: <T extends DefaultAssetManager>(am: T) => void;
|
|
4787
5380
|
/**
|
|
4788
5381
|
* @internal
|
|
4789
5382
|
*/
|
|
@@ -4797,8 +5390,234 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer' {
|
|
|
4797
5390
|
export type { MapView } from '@mappedin/react-native-sdk/core/packages/renderer/MapView';
|
|
4798
5391
|
export type { TSafeAreaInsets, TFocusOnTargets, TFocusOnCameraOptions, TAnimatePositionOptions, TCameraAnimationOptions, TFocusOnOptions, default as Camera } from '@mappedin/react-native-sdk/core/packages/renderer/Camera';
|
|
4799
5392
|
export { SAFE_AREA_INSET_TYPE, ANIMATION_TWEENS, CAMERA_EASING_MODE } from '@mappedin/react-native-sdk/core/packages/renderer/Camera';
|
|
4800
|
-
export type { TGetVenueOptions,
|
|
4801
|
-
export { Mappedin, MappedinDirections } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
5393
|
+
export type { TGetVenueOptions, TShowVenueOptions, TMappedinOfflineSearchOptions, TMappedinOfflineSearchResult, TMappedinOfflineSearchSuggestions, TMappedinOfflineAllSearchMatch, TMappedinOfflineSearchAllOptions } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
5394
|
+
export { Mappedin, MappedinDirections, MappedinLocation, MappedinPolygon, MappedinNode, MappedinCategory, MappedinMap, MappedinEvent, MappedinMapGroup, MappedinVenue, MappedinVortex, MappedinNavigatable, MappedinCoordinate, OfflineSearch, MAP_RENDER_MODE, setFetchFn } from '@mappedin/react-native-sdk/core/packages/get-venue';
|
|
5395
|
+
export { BundleAssetManager } from '@mappedin/react-native-sdk/core/packages/renderer/bundle-asset-manager';
|
|
5396
|
+
}
|
|
5397
|
+
|
|
5398
|
+
declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.MVF.types' {
|
|
5399
|
+
import { FeatureCollection, Polygon, Point, MultiPolygon, Position } from 'geojson';
|
|
5400
|
+
type ManifestFile = {
|
|
5401
|
+
type: 'file';
|
|
5402
|
+
name: string;
|
|
5403
|
+
};
|
|
5404
|
+
type ManifestFolder = {
|
|
5405
|
+
type: 'folder';
|
|
5406
|
+
name: string;
|
|
5407
|
+
children: ManifestFile[];
|
|
5408
|
+
};
|
|
5409
|
+
type OpeningHours = {
|
|
5410
|
+
opens: string;
|
|
5411
|
+
closes: string;
|
|
5412
|
+
dayOfWeek: string;
|
|
5413
|
+
validFrom?: string;
|
|
5414
|
+
validThrough?: string;
|
|
5415
|
+
};
|
|
5416
|
+
type Image = {
|
|
5417
|
+
original?: string;
|
|
5418
|
+
xlarge?: string;
|
|
5419
|
+
xxlarge?: string;
|
|
5420
|
+
medium?: string;
|
|
5421
|
+
'140x140'?: string;
|
|
5422
|
+
xsmall?: string;
|
|
5423
|
+
xxsmall?: string;
|
|
5424
|
+
'66x66'?: string;
|
|
5425
|
+
small?: string;
|
|
5426
|
+
large?: string;
|
|
5427
|
+
};
|
|
5428
|
+
type PolygonImage = string;
|
|
5429
|
+
type Phone = {
|
|
5430
|
+
number: string;
|
|
5431
|
+
extension?: string;
|
|
5432
|
+
};
|
|
5433
|
+
type Link = {
|
|
5434
|
+
label: string;
|
|
5435
|
+
url: string;
|
|
5436
|
+
};
|
|
5437
|
+
type Social = {
|
|
5438
|
+
facebook?: string;
|
|
5439
|
+
twitter?: string;
|
|
5440
|
+
instagram?: string;
|
|
5441
|
+
website?: string;
|
|
5442
|
+
};
|
|
5443
|
+
type LocationState = {
|
|
5444
|
+
type: string;
|
|
5445
|
+
start?: string;
|
|
5446
|
+
end?: string;
|
|
5447
|
+
};
|
|
5448
|
+
type SiblingGroup = {
|
|
5449
|
+
label: string;
|
|
5450
|
+
siblings: string[];
|
|
5451
|
+
};
|
|
5452
|
+
export type MILocationProperties = {
|
|
5453
|
+
id: string;
|
|
5454
|
+
address?: string | null;
|
|
5455
|
+
categories: string[];
|
|
5456
|
+
description?: string | null;
|
|
5457
|
+
email?: string | null;
|
|
5458
|
+
externalId?: string | null;
|
|
5459
|
+
hours?: OpeningHours[] | null;
|
|
5460
|
+
links?: Link[] | null;
|
|
5461
|
+
logo?: Image | null;
|
|
5462
|
+
name: string;
|
|
5463
|
+
phone?: Phone | null;
|
|
5464
|
+
picture?: Image | null;
|
|
5465
|
+
services?: string | null;
|
|
5466
|
+
siblingGroups?: SiblingGroup[] | null;
|
|
5467
|
+
social?: Social | null;
|
|
5468
|
+
spaces?: TLocationSpaceReference[] | null;
|
|
5469
|
+
states?: LocationState[] | null;
|
|
5470
|
+
type: string;
|
|
5471
|
+
};
|
|
5472
|
+
export type MICategoryProperties = {
|
|
5473
|
+
id: string;
|
|
5474
|
+
name: string;
|
|
5475
|
+
picture?: Image;
|
|
5476
|
+
};
|
|
5477
|
+
export type MIBuildingProperties = {
|
|
5478
|
+
id: string;
|
|
5479
|
+
name: string;
|
|
5480
|
+
venue: string;
|
|
5481
|
+
};
|
|
5482
|
+
export type MILevelProperties = {
|
|
5483
|
+
id: string;
|
|
5484
|
+
abbreviation?: string;
|
|
5485
|
+
building?: string;
|
|
5486
|
+
elevation?: number;
|
|
5487
|
+
name: string;
|
|
5488
|
+
};
|
|
5489
|
+
export type MIPolygonlikeProperties = {
|
|
5490
|
+
id: string;
|
|
5491
|
+
altitude?: string;
|
|
5492
|
+
color?: string;
|
|
5493
|
+
externalId?: string | null;
|
|
5494
|
+
height?: string;
|
|
5495
|
+
layer?: string;
|
|
5496
|
+
level: string;
|
|
5497
|
+
parent?: string | null;
|
|
5498
|
+
};
|
|
5499
|
+
type TPseudoNodeSpaceReference = {
|
|
5500
|
+
node: string;
|
|
5501
|
+
map: string;
|
|
5502
|
+
};
|
|
5503
|
+
export type TRealSpaceReference = {
|
|
5504
|
+
id: string;
|
|
5505
|
+
map: string;
|
|
5506
|
+
};
|
|
5507
|
+
type TLocationSpaceReference = TPseudoNodeSpaceReference | TRealSpaceReference;
|
|
5508
|
+
export type TEntrances = {
|
|
5509
|
+
id: string;
|
|
5510
|
+
level: string;
|
|
5511
|
+
};
|
|
5512
|
+
export type MISpaceProperties = MIPolygonlikeProperties & {
|
|
5513
|
+
entrances: TEntrances[];
|
|
5514
|
+
};
|
|
5515
|
+
export type MIObstructionProperties = MIPolygonlikeProperties;
|
|
5516
|
+
export type MIConnectionProperties = {
|
|
5517
|
+
id: string;
|
|
5518
|
+
accessible: boolean;
|
|
5519
|
+
destinations: string[];
|
|
5520
|
+
level: string;
|
|
5521
|
+
multiplier: number;
|
|
5522
|
+
name: string;
|
|
5523
|
+
type: string;
|
|
5524
|
+
weight: number;
|
|
5525
|
+
};
|
|
5526
|
+
export type MINodeProperties = {
|
|
5527
|
+
id: string;
|
|
5528
|
+
accessible: boolean;
|
|
5529
|
+
externalId: string | null;
|
|
5530
|
+
level: string;
|
|
5531
|
+
multiplier: number;
|
|
5532
|
+
neighbors: string[];
|
|
5533
|
+
weight: number;
|
|
5534
|
+
};
|
|
5535
|
+
export type MIManifestProperties = {
|
|
5536
|
+
name: string;
|
|
5537
|
+
folder_struct: (ManifestFolder | ManifestFile)[];
|
|
5538
|
+
version: string;
|
|
5539
|
+
time: string;
|
|
5540
|
+
};
|
|
5541
|
+
export type MIStyle = {
|
|
5542
|
+
id: string;
|
|
5543
|
+
/** The altitude of the bottom of the geometry, in metres. */
|
|
5544
|
+
altitude: number;
|
|
5545
|
+
color: string;
|
|
5546
|
+
height: number;
|
|
5547
|
+
image?: PolygonImage;
|
|
5548
|
+
opacity: number;
|
|
5549
|
+
};
|
|
5550
|
+
export type MIImageInstance = {
|
|
5551
|
+
/** The local path or URL of the image. */
|
|
5552
|
+
path: string;
|
|
5553
|
+
/** The position of the centre of the image, in [long, lat] form. */
|
|
5554
|
+
position: Position;
|
|
5555
|
+
/** The altitude of the image, in metres. */
|
|
5556
|
+
altitude: number;
|
|
5557
|
+
/** Euler angles representing the rotation of the image, in degrees. Angles are in XYZ order. */
|
|
5558
|
+
rotation: {
|
|
5559
|
+
x: number;
|
|
5560
|
+
y: number;
|
|
5561
|
+
z: number;
|
|
5562
|
+
};
|
|
5563
|
+
/** The size of the image, in metres. */
|
|
5564
|
+
size: {
|
|
5565
|
+
x: number;
|
|
5566
|
+
y: number;
|
|
5567
|
+
};
|
|
5568
|
+
/** The portion of the image to display. */
|
|
5569
|
+
viewBox: {
|
|
5570
|
+
top: number;
|
|
5571
|
+
left: number;
|
|
5572
|
+
width: number;
|
|
5573
|
+
height: number;
|
|
5574
|
+
};
|
|
5575
|
+
/**
|
|
5576
|
+
* A space or obstruction to associate this image with. If provided,
|
|
5577
|
+
* changes to the polygon's visibility will affect this image.
|
|
5578
|
+
* */
|
|
5579
|
+
polygonId?: string;
|
|
5580
|
+
};
|
|
5581
|
+
export type MIGeoJSONManifestCollection = FeatureCollection<Point, MIManifestProperties>;
|
|
5582
|
+
export type MIGeoJSONBuildingCollection = FeatureCollection<Polygon, MIBuildingProperties>;
|
|
5583
|
+
export type MIGeoJSONConnectionCollection = FeatureCollection<Point, MIConnectionProperties>;
|
|
5584
|
+
export type MIGeoJSONLevelCollection = FeatureCollection<Polygon | MultiPolygon, MILevelProperties>;
|
|
5585
|
+
export type MIGeoJSONSpaceCollection = FeatureCollection<Polygon, MISpaceProperties>;
|
|
5586
|
+
export type MIGeoJSONObstructionCollection = FeatureCollection<Polygon, MIObstructionProperties>;
|
|
5587
|
+
export type MIGeoJSONNodeCollection = FeatureCollection<Point, MINodeProperties>;
|
|
5588
|
+
export type MIGeoJSONLocationCollection = FeatureCollection<null, MILocationProperties>;
|
|
5589
|
+
export type MIGeoJSONCategoryCollection = FeatureCollection<null, MICategoryProperties>;
|
|
5590
|
+
export type WithIDs<T> = Map<string, T>;
|
|
5591
|
+
export type MIStyleCollection = MIStyle[];
|
|
5592
|
+
/**
|
|
5593
|
+
* A mapping of polygon IDs to style IDs;
|
|
5594
|
+
*/
|
|
5595
|
+
export type MIPolygonStyle = {
|
|
5596
|
+
[key in string]: string;
|
|
5597
|
+
};
|
|
5598
|
+
export type MIImageInstanceCollection = MIImageInstance[];
|
|
5599
|
+
/**
|
|
5600
|
+
* The entire data collection for an MVF, in a single JSON collection.
|
|
5601
|
+
*
|
|
5602
|
+
*/
|
|
5603
|
+
export type MVFDataJSON = {
|
|
5604
|
+
connection: WithIDs<MIGeoJSONConnectionCollection>;
|
|
5605
|
+
level: WithIDs<MIGeoJSONLevelCollection>;
|
|
5606
|
+
node: WithIDs<MIGeoJSONNodeCollection>;
|
|
5607
|
+
obstruction: WithIDs<MIGeoJSONObstructionCollection>;
|
|
5608
|
+
space: WithIDs<MIGeoJSONSpaceCollection>;
|
|
5609
|
+
building: MIGeoJSONBuildingCollection;
|
|
5610
|
+
category: MIGeoJSONCategoryCollection;
|
|
5611
|
+
style: MIStyleCollection;
|
|
5612
|
+
polygonStyle: WithIDs<MIPolygonStyle>;
|
|
5613
|
+
imageInstance: WithIDs<MIImageInstanceCollection>;
|
|
5614
|
+
location: MIGeoJSONLocationCollection;
|
|
5615
|
+
manifest: MIGeoJSONManifestCollection;
|
|
5616
|
+
};
|
|
5617
|
+
export type MVFData = MVFDataJSON & {
|
|
5618
|
+
imageBinaries: WithIDs<Uint8Array>;
|
|
5619
|
+
};
|
|
5620
|
+
export {};
|
|
4802
5621
|
}
|
|
4803
5622
|
|
|
4804
5623
|
declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinLocationRankings' {
|
|
@@ -4850,9 +5669,95 @@ declare module '@mappedin/react-native-sdk/core/packages/get-venue/MappedinTheme
|
|
|
4850
5669
|
}
|
|
4851
5670
|
}
|
|
4852
5671
|
|
|
5672
|
+
declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.Analytics' {
|
|
5673
|
+
type AnalyticsOptions = {
|
|
5674
|
+
clientId?: string;
|
|
5675
|
+
clientSecret?: string;
|
|
5676
|
+
accessToken?: string;
|
|
5677
|
+
noAuth?: boolean;
|
|
5678
|
+
venue: string;
|
|
5679
|
+
testMode?: boolean | string;
|
|
5680
|
+
context?: string;
|
|
5681
|
+
platformString?: string;
|
|
5682
|
+
};
|
|
5683
|
+
/**
|
|
5684
|
+
* A class to access the Mappedin Analytics platform. Correct usage will improve Smart Search results, and lead to more accurate insights.
|
|
5685
|
+
* This will be created for you as part of Mappedin.{{#crossLink "Mappedin/initialize:method"}}{{/crossLink}}, but you can also create one manually. You are mostly going to use `locationSelected`.
|
|
5686
|
+
*
|
|
5687
|
+
* @type {any}
|
|
5688
|
+
*
|
|
5689
|
+
* @class Analytics
|
|
5690
|
+
* @param options {Object} A list of configuration options for the Analytics API.
|
|
5691
|
+
* @param [options.clientId] {String} The same key you are using for getVenue. Handled automatically in Mapview.initialize()
|
|
5692
|
+
* @param [options.clientSecret] {String} The same secret you are using for getVenue. Handled automatically in Mapview.initialize()
|
|
5693
|
+
* @param [options.venue] {String} The same venue slug you are using for getVenue. Handled automatically in MapView.initialize()
|
|
5694
|
+
* @param [options.context] {String} The context to pass with the analytics request. Defaults to "websdk".
|
|
5695
|
+
* @param [options.noAuth] {Boolean} Whether authentication should not be sent with analytics requests.
|
|
5696
|
+
* @param [options.testMode] {Boolean} Whether analytics events should be dropped because this is running in a test environment.
|
|
5697
|
+
*/
|
|
5698
|
+
class Analytics {
|
|
5699
|
+
#private;
|
|
5700
|
+
constructor(options: AnalyticsOptions);
|
|
5701
|
+
track(target: any, query: any): void;
|
|
5702
|
+
/**
|
|
5703
|
+
* Whenever a location is selected, you should fire this event. What "selected" means can vary by venue,
|
|
5704
|
+
* but a good rule of thumb is that you fire the event whenever you would show the location's details.
|
|
5705
|
+
* Typically this is when the user taps it's polygon on the map, picks it from search results or a category list.
|
|
5706
|
+
* or deep links directly into the map.
|
|
5707
|
+
* @method locationSelected
|
|
5708
|
+
* @param location {MappedinLocation} The location the user selected.
|
|
5709
|
+
*/
|
|
5710
|
+
locationSelected(location: any): void;
|
|
5711
|
+
/**
|
|
5712
|
+
* Whenever a category is selected, you should fire this event.
|
|
5713
|
+
* @method categorySelected
|
|
5714
|
+
* @param category {MappedinCategory} The category the user selected.
|
|
5715
|
+
*/
|
|
5716
|
+
categorySelected(category: any): void;
|
|
5717
|
+
mapViewLoaded(type: any, forced: any, benchmark: any, reason: any): void;
|
|
5718
|
+
/**
|
|
5719
|
+
* Whenever a user requests directions, you should fire this event.
|
|
5720
|
+
* @method getDirections
|
|
5721
|
+
* @param start {MappedinLocation} The start location for wayfinding.
|
|
5722
|
+
* @param end {MappedinLocation} The end location for wayfinding.
|
|
5723
|
+
*/
|
|
5724
|
+
getDirections(start: any, end: any): void;
|
|
5725
|
+
getSessionID(): string;
|
|
5726
|
+
getDeviceID(): string;
|
|
5727
|
+
/**
|
|
5728
|
+
* @param mode {Boolean} Indicates whether the user's geolocation is enabled.
|
|
5729
|
+
*/
|
|
5730
|
+
setGeolocationMode(mode: any): void;
|
|
5731
|
+
/**
|
|
5732
|
+
* Track an event.
|
|
5733
|
+
* @method trackBlueDotEvent
|
|
5734
|
+
* @param event {String}
|
|
5735
|
+
* event param should be a property of the {{#crossLink "Analytics/BLUEDOT_EVENT:property"}}{{/crossLink}} property.
|
|
5736
|
+
*/
|
|
5737
|
+
trackBlueDotEvent(blueDotEvent: any): void;
|
|
5738
|
+
trackSearch(searchAnalyticsObject: any): void;
|
|
5739
|
+
trackSearchSuggest(searchAnalyticsObject: any): void;
|
|
5740
|
+
/**
|
|
5741
|
+
* Enum of valid bluedot events.
|
|
5742
|
+
* Pass a property of this into the {{#crossLink "Analytics/trackBlueDotEvent:method"}}{{/crossLink}} method.
|
|
5743
|
+
* Valid properties are: ATTEMPT_BLUEDOT, FOUND_POSITION, FOUND_FLOOR.
|
|
5744
|
+
* @property BLUEDOT_EVENT {Object}
|
|
5745
|
+
* @example
|
|
5746
|
+
* Analytics.trackBlueDotEvent(Analytics.BLUEDOT_EVENT.ATTEMPT_BLUEDOT)
|
|
5747
|
+
*/
|
|
5748
|
+
static BLUEDOT_EVENT: {
|
|
5749
|
+
ATTEMPT_BLUEDOT: string;
|
|
5750
|
+
FOUND_POSITION: string;
|
|
5751
|
+
FOUND_FLOOR: string;
|
|
5752
|
+
};
|
|
5753
|
+
}
|
|
5754
|
+
export default Analytics;
|
|
5755
|
+
}
|
|
5756
|
+
|
|
4853
5757
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartCollider' {
|
|
4854
5758
|
import SmartCollisionEngine from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartCollisionEngine';
|
|
4855
5759
|
import { Vector3 } from 'three';
|
|
5760
|
+
import { Rectangle } from '@mappedin/react-native-sdk/core/packages/renderer/internal/quad-tree';
|
|
4856
5761
|
export type TRange = [number, number, number, number];
|
|
4857
5762
|
type TCustomCollider<T> = ICollider & T;
|
|
4858
5763
|
export type TColliderStrategyProps = {
|
|
@@ -4866,6 +5771,10 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
4866
5771
|
getBoundingBox: (TColliderStrategyProps: any) => TRange;
|
|
4867
5772
|
onStrategySelected: (collider: TCustomCollider<any>) => void;
|
|
4868
5773
|
};
|
|
5774
|
+
export type TGetBoundingBox = ({ x, y }: {
|
|
5775
|
+
x: any;
|
|
5776
|
+
y: any;
|
|
5777
|
+
}) => [number, number, number, number];
|
|
4869
5778
|
export type TDimensions = {
|
|
4870
5779
|
width: number;
|
|
4871
5780
|
height: number;
|
|
@@ -4878,13 +5787,19 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
4878
5787
|
export interface ICollider {
|
|
4879
5788
|
dimensions: TDimensions;
|
|
4880
5789
|
screenPosition: [number, number];
|
|
4881
|
-
|
|
5790
|
+
getBoundingBoxForCurrentStrategy?: TGetBoundingBox;
|
|
4882
5791
|
options?: Record<string, unknown>;
|
|
4883
5792
|
mapId: string;
|
|
4884
5793
|
visible: boolean;
|
|
4885
5794
|
rank: number;
|
|
4886
|
-
_dirty?: boolean;
|
|
4887
5795
|
id: string;
|
|
5796
|
+
_bboxes?: [
|
|
5797
|
+
string,
|
|
5798
|
+
Rectangle,
|
|
5799
|
+
(collider: TCustomCollider<any>) => void,
|
|
5800
|
+
TGetBoundingBox
|
|
5801
|
+
][];
|
|
5802
|
+
offscreen?: boolean;
|
|
4888
5803
|
setAction: (action: EColliderAction) => void;
|
|
4889
5804
|
action?: EColliderAction;
|
|
4890
5805
|
position: Vector3;
|
|
@@ -4908,15 +5823,16 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
4908
5823
|
__engine: any;
|
|
4909
5824
|
_initialRank: number;
|
|
4910
5825
|
screenPosition: [number, number];
|
|
4911
|
-
currentStrategyName: null;
|
|
4912
5826
|
enabled: boolean;
|
|
4913
5827
|
options: any;
|
|
4914
5828
|
mapId: string;
|
|
4915
5829
|
id: string;
|
|
4916
5830
|
action: EColliderAction;
|
|
5831
|
+
getBoundingBoxForCurrentStrategy: undefined;
|
|
4917
5832
|
rank: number;
|
|
4918
5833
|
visible: boolean;
|
|
4919
|
-
|
|
5834
|
+
offscreen: boolean;
|
|
5835
|
+
position: any;
|
|
4920
5836
|
dimensions: {
|
|
4921
5837
|
width: number;
|
|
4922
5838
|
height: number;
|
|
@@ -5176,11 +6092,11 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5176
6092
|
}
|
|
5177
6093
|
|
|
5178
6094
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/layers/EventSystem' {
|
|
5179
|
-
import { Object3D
|
|
6095
|
+
import { Object3D } from 'three';
|
|
5180
6096
|
import { MapView } from '@mappedin/react-native-sdk/core/packages/renderer';
|
|
5181
6097
|
import { ICore } from '@mappedin/react-native-sdk/core/packages/renderer/Core.interface';
|
|
5182
6098
|
import BlueDotManager from '@mappedin/react-native-sdk/core/packages/renderer/internal/blue-dot-manager';
|
|
5183
|
-
export const raycaster:
|
|
6099
|
+
export const raycaster: any;
|
|
5184
6100
|
class EventSystemLayer {
|
|
5185
6101
|
mapView: MapView;
|
|
5186
6102
|
core: ICore;
|
|
@@ -5223,7 +6139,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/layers/EventSy
|
|
|
5223
6139
|
};
|
|
5224
6140
|
hasTouched: boolean;
|
|
5225
6141
|
calculateMouseCoordinates: (event: any) => void;
|
|
5226
|
-
getMouseRayIntersects: (objects: Object3D | Object3D[]) =>
|
|
6142
|
+
getMouseRayIntersects: (objects: Object3D | Object3D[]) => any;
|
|
5227
6143
|
detectPolygonsUnderMouse: () => any[];
|
|
5228
6144
|
getMouseMapPosition: () => {
|
|
5229
6145
|
x: number;
|
|
@@ -5403,6 +6319,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5403
6319
|
get strategies(): TColliderStrategy[];
|
|
5404
6320
|
colliderDidMount(): void;
|
|
5405
6321
|
setAction(action: any): void;
|
|
6322
|
+
colliderDidNotFindAHome(): void;
|
|
5406
6323
|
colliderDidGoOffscreen(): void;
|
|
5407
6324
|
colliderDidUpdateVisiblity(): void;
|
|
5408
6325
|
}
|
|
@@ -5410,6 +6327,15 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5410
6327
|
}
|
|
5411
6328
|
|
|
5412
6329
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.MapObject' {
|
|
6330
|
+
export namespace TASK_PRIORITY {
|
|
6331
|
+
const VISIBLE_MAP_HIGH: number;
|
|
6332
|
+
const VISIBLE_MAP_LOW: number;
|
|
6333
|
+
const VISIBLE_MAP_MARKER: number;
|
|
6334
|
+
const ASYNC_MAP_HIGH: number;
|
|
6335
|
+
const ASYNC_MAP_LOW: number;
|
|
6336
|
+
const ASYNC_MAP_MARKER: number;
|
|
6337
|
+
const MAP_LOADED: number;
|
|
6338
|
+
}
|
|
5413
6339
|
export const SCENE_FROM_LIVE_JSON: false;
|
|
5414
6340
|
/**
|
|
5415
6341
|
* A handle to a 3D marker added to a map.
|
|
@@ -5439,10 +6365,11 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5439
6365
|
_started: boolean;
|
|
5440
6366
|
_loaderPromise: null;
|
|
5441
6367
|
_promiseResolve: null;
|
|
6368
|
+
hoverableMeshChildren: any[];
|
|
5442
6369
|
objectsDictionary: {};
|
|
5443
6370
|
north: null;
|
|
5444
6371
|
mapScale: null;
|
|
5445
|
-
object:
|
|
6372
|
+
object: any;
|
|
5446
6373
|
labels: Set<any>;
|
|
5447
6374
|
tooltips: Set<any>;
|
|
5448
6375
|
markers: Set<any>;
|
|
@@ -5459,6 +6386,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5459
6386
|
loadAsync: any;
|
|
5460
6387
|
_taskScheduler: any;
|
|
5461
6388
|
id: any;
|
|
6389
|
+
mapRenderingStrategy: any;
|
|
5462
6390
|
_highPriorityTasks: FrameTaskGroup;
|
|
5463
6391
|
_lowPriorityTasks: FrameTaskGroup;
|
|
5464
6392
|
_markerTasks: FrameTaskGroup;
|
|
@@ -5466,11 +6394,12 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5466
6394
|
_visibilityLatch: boolean | null;
|
|
5467
6395
|
_objLoadedComplete: boolean;
|
|
5468
6396
|
_objLoaded(object: any): any;
|
|
6397
|
+
_objLoadedMerged(object: any): void;
|
|
5469
6398
|
enableImageFlipping(polygonId: any, rotation: any): void;
|
|
5470
6399
|
elements: any;
|
|
5471
6400
|
boundingBox: {
|
|
5472
|
-
min:
|
|
5473
|
-
max:
|
|
6401
|
+
min: any;
|
|
6402
|
+
max: any;
|
|
5474
6403
|
} | undefined;
|
|
5475
6404
|
loadPolygonNow(polygonId: any): void;
|
|
5476
6405
|
_addElementToScene(element: any): void;
|
|
@@ -5547,10 +6476,10 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5547
6476
|
* @return {ThreeJSMarkerHandle} a unique identifier for the marker
|
|
5548
6477
|
*/
|
|
5549
6478
|
addThreeJSMarker(options: {
|
|
5550
|
-
object?:
|
|
5551
|
-
position?:
|
|
6479
|
+
object?: any;
|
|
6480
|
+
position?: any;
|
|
5552
6481
|
rotation?: any;
|
|
5553
|
-
scale?:
|
|
6482
|
+
scale?: any;
|
|
5554
6483
|
}): ThreeJSMarkerHandle;
|
|
5555
6484
|
/**
|
|
5556
6485
|
* Remove the given `ThreeJSMarker` from this map.
|
|
@@ -5582,9 +6511,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5582
6511
|
_popinChildObjects(): void;
|
|
5583
6512
|
}
|
|
5584
6513
|
import { PubSub } from "@mappedin/react-native-sdk/core/packages/renderer/internal/pub-sub";
|
|
5585
|
-
import {
|
|
5586
|
-
import { FrameTaskGroup } from "@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.TaskScheduler";
|
|
5587
|
-
import { Vector3 } from "three/src/math/Vector3";
|
|
6514
|
+
import { FrameTaskGroup } from "@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.TaskScheduler";
|
|
5588
6515
|
}
|
|
5589
6516
|
|
|
5590
6517
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.Search' {
|
|
@@ -5606,30 +6533,25 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5606
6533
|
let Search: any;
|
|
5607
6534
|
}
|
|
5608
6535
|
|
|
5609
|
-
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.Analytics' {
|
|
5610
|
-
export default Analytics;
|
|
5611
|
-
/**
|
|
5612
|
-
* A class to access the Mappedin Analytics platform. Correct usage will improve Smart Search results, and lead to more accurate insights.
|
|
5613
|
-
* This will be created for you as part of Mappedin.{{#crossLink "Mappedin/initialize:method"}}{{/crossLink}}, but you can also create one manually. You are mostly going to use `locationSelected`.
|
|
5614
|
-
*
|
|
5615
|
-
* @type {any}
|
|
5616
|
-
*
|
|
5617
|
-
* @class Analytics
|
|
5618
|
-
* @param options {Object} A list of configuration options for the Analytics API.
|
|
5619
|
-
* @param [options.key] {String} The same key you are using for getVenue. Handled automatically in Mapview.initialize()
|
|
5620
|
-
* @param [options.secret] {String} The same secret you are using for getVenue. Handled automatically in Mapview.initialize()
|
|
5621
|
-
* @param [options.venue] {String} The same venue slug you are using for getVenue. Handled automatically in MapView.initialize()
|
|
5622
|
-
*/
|
|
5623
|
-
var Analytics: any;
|
|
5624
|
-
}
|
|
5625
|
-
|
|
5626
6536
|
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.AssetManager' {
|
|
5627
|
-
import {
|
|
6537
|
+
import { Texture } from 'three';
|
|
5628
6538
|
import type { MappedinMap } from '@mappedin/react-native-sdk/core/packages/renderer';
|
|
5629
6539
|
export default class DefaultAssetManager {
|
|
5630
|
-
textureLoader:
|
|
6540
|
+
textureLoader: any;
|
|
5631
6541
|
loadMapPolygons(map: MappedinMap): Promise<any>;
|
|
5632
|
-
loadImage(url: string): Promise<
|
|
6542
|
+
loadImage(url: string): Promise<Texture>;
|
|
6543
|
+
}
|
|
6544
|
+
}
|
|
6545
|
+
|
|
6546
|
+
declare module '@mappedin/react-native-sdk/core/packages/renderer/bundle-asset-manager' {
|
|
6547
|
+
import type { Texture } from 'three';
|
|
6548
|
+
import { Mappedin, MappedinMap } from '@mappedin/react-native-sdk/core/packages/renderer';
|
|
6549
|
+
import AssetManager from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.AssetManager';
|
|
6550
|
+
export class BundleAssetManager extends AssetManager {
|
|
6551
|
+
venueData: Mappedin;
|
|
6552
|
+
constructor(venueData: Mappedin);
|
|
6553
|
+
loadMapPolygons(map: MappedinMap): Promise<Record<string, any>>;
|
|
6554
|
+
loadImage(url: string): Promise<Texture>;
|
|
5633
6555
|
}
|
|
5634
6556
|
}
|
|
5635
6557
|
|
|
@@ -5638,74 +6560,86 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5638
6560
|
import './Mappedin.SmartCollisionEngine.scss';
|
|
5639
6561
|
import { ICollider, TRange } from '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappedin.SmartCollider';
|
|
5640
6562
|
import { MappedinMap, MapView } from '@mappedin/react-native-sdk/core/packages/renderer';
|
|
6563
|
+
import { ICore } from '@mappedin/react-native-sdk/core/packages/renderer/Core.interface';
|
|
6564
|
+
import { Rectangle, QuadTree } from '@mappedin/react-native-sdk/core/packages/renderer/internal/quad-tree';
|
|
5641
6565
|
export const COLLIDER_STRATEGY_LOW_PRIORITY = "LOW_PRIORITY";
|
|
5642
6566
|
class SmartCollisionEngine {
|
|
5643
|
-
|
|
5644
|
-
|
|
5645
|
-
|
|
5646
|
-
|
|
5647
|
-
|
|
5648
|
-
|
|
5649
|
-
|
|
5650
|
-
|
|
5651
|
-
|
|
5652
|
-
|
|
5653
|
-
|
|
5654
|
-
|
|
5655
|
-
|
|
5656
|
-
|
|
5657
|
-
|
|
5658
|
-
|
|
5659
|
-
|
|
5660
|
-
|
|
5661
|
-
|
|
5662
|
-
|
|
5663
|
-
|
|
5664
|
-
|
|
5665
|
-
|
|
5666
|
-
|
|
5667
|
-
|
|
5668
|
-
|
|
5669
|
-
|
|
5670
|
-
|
|
5671
|
-
|
|
5672
|
-
|
|
5673
|
-
|
|
5674
|
-
|
|
5675
|
-
|
|
5676
|
-
|
|
5677
|
-
|
|
5678
|
-
/**
|
|
5679
|
-
* Allow to throttle making collders dirty. This is useful for things like BlueDot follow mode,
|
|
5680
|
-
* As we follow the BlueDot, colliders will overlap, but constantly updating their visiblity makes
|
|
5681
|
-
* for a bad experience
|
|
5682
|
-
*/
|
|
5683
|
-
makeCollidersDirtyThrottled: (time: any) => void;
|
|
5684
|
-
resize: (container: any) => void;
|
|
5685
|
-
update: () => void;
|
|
5686
|
-
destroy: () => void;
|
|
6567
|
+
#private;
|
|
6568
|
+
colliderCanvas: HTMLCanvasElement;
|
|
6569
|
+
debugCanvas: HTMLCanvasElement;
|
|
6570
|
+
colliderCanvasContext: CanvasRenderingContext2D;
|
|
6571
|
+
debugCanvasContext: CanvasRenderingContext2D;
|
|
6572
|
+
collisionEngineContainerEl: HTMLDivElement;
|
|
6573
|
+
stepsX: any;
|
|
6574
|
+
stepsY: any;
|
|
6575
|
+
totalWidth: any;
|
|
6576
|
+
totalHeight: any;
|
|
6577
|
+
project: any;
|
|
6578
|
+
colliders: Map<string, ICollider>;
|
|
6579
|
+
offscreenRanges: TRange[];
|
|
6580
|
+
get sortedColliders(): ICollider[];
|
|
6581
|
+
initialized: boolean;
|
|
6582
|
+
mapView: MapView;
|
|
6583
|
+
core: ICore;
|
|
6584
|
+
screen: Rectangle;
|
|
6585
|
+
constructor(mapView: any, core: ICore);
|
|
6586
|
+
init: (container: HTMLDivElement, projectFn: ({ position, mapId }: {
|
|
6587
|
+
position: any;
|
|
6588
|
+
mapId: MappedinMap['id'];
|
|
6589
|
+
}) => {
|
|
6590
|
+
x: number;
|
|
6591
|
+
y: number;
|
|
6592
|
+
}) => void;
|
|
6593
|
+
qtree: QuadTree;
|
|
6594
|
+
recompute: () => void;
|
|
6595
|
+
draw: () => void;
|
|
6596
|
+
reposition: () => void;
|
|
6597
|
+
add: (colliderId: string, collider: ICollider) => void;
|
|
6598
|
+
remove: (colliderId: string) => void;
|
|
6599
|
+
update: () => void;
|
|
6600
|
+
resize: (container: any) => void;
|
|
6601
|
+
destroy: () => void;
|
|
5687
6602
|
}
|
|
5688
6603
|
export default SmartCollisionEngine;
|
|
5689
6604
|
}
|
|
5690
6605
|
|
|
5691
|
-
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/
|
|
5692
|
-
export
|
|
5693
|
-
|
|
5694
|
-
|
|
5695
|
-
|
|
5696
|
-
|
|
5697
|
-
|
|
5698
|
-
|
|
6606
|
+
declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/quad-tree' {
|
|
6607
|
+
export function contains(rect1: Rectangle, rect2: Rectangle): boolean;
|
|
6608
|
+
export function intersects(rect1: Rectangle, rect2: Rectangle): boolean;
|
|
6609
|
+
class Rectangle {
|
|
6610
|
+
x: number;
|
|
6611
|
+
y: number;
|
|
6612
|
+
w: number;
|
|
6613
|
+
h: number;
|
|
6614
|
+
userData?: any;
|
|
6615
|
+
constructor(x: number, y: number, w: number, h: number, userData?: any);
|
|
6616
|
+
contains(rectangle: Rectangle): boolean;
|
|
6617
|
+
intersects(rectangle: Rectangle): boolean;
|
|
6618
|
+
draw(context: CanvasRenderingContext2D): void;
|
|
5699
6619
|
}
|
|
5700
|
-
|
|
5701
|
-
|
|
5702
|
-
|
|
5703
|
-
|
|
5704
|
-
|
|
5705
|
-
|
|
5706
|
-
|
|
5707
|
-
|
|
6620
|
+
class QuadTree {
|
|
6621
|
+
#private;
|
|
6622
|
+
boundary: Rectangle;
|
|
6623
|
+
capacity: number;
|
|
6624
|
+
objects: Rectangle[];
|
|
6625
|
+
topLeft: QuadTree;
|
|
6626
|
+
topRight: QuadTree;
|
|
6627
|
+
bottomLeft: QuadTree;
|
|
6628
|
+
bottomRight: QuadTree;
|
|
6629
|
+
divided: boolean;
|
|
6630
|
+
parent?: QuadTree;
|
|
6631
|
+
getSize(): any;
|
|
6632
|
+
constructor(boundary: Rectangle, parent?: QuadTree);
|
|
6633
|
+
subdivide(): void;
|
|
6634
|
+
query(rectangle: Rectangle): Rectangle[];
|
|
6635
|
+
insert(rectangle: Rectangle): boolean;
|
|
6636
|
+
drawObjects(context: CanvasRenderingContext2D): void;
|
|
6637
|
+
draw(context: CanvasRenderingContext2D): void;
|
|
5708
6638
|
}
|
|
6639
|
+
export { QuadTree, Rectangle };
|
|
6640
|
+
}
|
|
6641
|
+
|
|
6642
|
+
declare module '@mappedin/react-native-sdk/core/packages/get-venue/Mappedin.TaskScheduler' {
|
|
5709
6643
|
/**
|
|
5710
6644
|
* A function that can be submitted to the Task Scheduler to run each frame for
|
|
5711
6645
|
* some provided number of frames. A single update can be repeatedly submitted;
|
|
@@ -5739,22 +6673,22 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5739
6673
|
* @param [options.userdata] {Any}
|
|
5740
6674
|
* Arbitrary data that you can store along with this update.
|
|
5741
6675
|
*/
|
|
5742
|
-
constructor(options
|
|
5743
|
-
callback
|
|
5744
|
-
frameCount?: number
|
|
5745
|
-
ordering?: number
|
|
5746
|
-
supersededBy?:
|
|
5747
|
-
name
|
|
5748
|
-
userdata?: any
|
|
5749
|
-
}
|
|
5750
|
-
_callback: Function
|
|
6676
|
+
constructor(options: {
|
|
6677
|
+
callback: Function;
|
|
6678
|
+
frameCount?: number;
|
|
6679
|
+
ordering?: number;
|
|
6680
|
+
supersededBy?: Set<never>;
|
|
6681
|
+
name: string;
|
|
6682
|
+
userdata?: Record<string, any>;
|
|
6683
|
+
});
|
|
6684
|
+
_callback: Function;
|
|
5751
6685
|
_frameCount: number;
|
|
5752
6686
|
_ordering: number;
|
|
5753
|
-
_supersededBy: Set<
|
|
5754
|
-
name: string
|
|
5755
|
-
userdata: any;
|
|
6687
|
+
_supersededBy: Set<never>;
|
|
6688
|
+
name: string;
|
|
5756
6689
|
_remainingFrameCount: number;
|
|
5757
6690
|
_lastFrameTime: number;
|
|
6691
|
+
userdata?: Record<string, any>;
|
|
5758
6692
|
/**
|
|
5759
6693
|
* Return the amount of time that this frame update took to execute during
|
|
5760
6694
|
* its most recent execution, in milliseconds. If called during this frame
|
|
@@ -5794,24 +6728,25 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5794
6728
|
* @param [options.userdata] {Any}
|
|
5795
6729
|
* Arbitrary data that you can store along with this task.
|
|
5796
6730
|
*/
|
|
5797
|
-
constructor(options
|
|
5798
|
-
|
|
5799
|
-
|
|
5800
|
-
|
|
5801
|
-
postponeOnAdd
|
|
5802
|
-
name
|
|
5803
|
-
|
|
5804
|
-
|
|
5805
|
-
|
|
5806
|
-
_group: FrameTaskGroup | null;
|
|
5807
|
-
_priority: number;
|
|
6731
|
+
constructor(options: {
|
|
6732
|
+
userdata: Record<string, any>;
|
|
6733
|
+
priority: number;
|
|
6734
|
+
group?: FrameTaskGroup;
|
|
6735
|
+
postponeOnAdd: number | boolean;
|
|
6736
|
+
name: string;
|
|
6737
|
+
lastFrameTime: number;
|
|
6738
|
+
callback: Function;
|
|
6739
|
+
});
|
|
5808
6740
|
_postponed: number | boolean;
|
|
5809
|
-
|
|
5810
|
-
|
|
6741
|
+
userdata: Record<string, any>;
|
|
6742
|
+
_priority: number;
|
|
6743
|
+
_group: FrameTaskGroup | null;
|
|
6744
|
+
name: string;
|
|
6745
|
+
_lastFrameTime: number;
|
|
6746
|
+
_callback: Function;
|
|
5811
6747
|
_complete: boolean;
|
|
5812
6748
|
_scheduled: boolean;
|
|
5813
6749
|
_cancelled: boolean;
|
|
5814
|
-
_lastFrameTime: number;
|
|
5815
6750
|
/**
|
|
5816
6751
|
* Return true if this task has been run at least once.
|
|
5817
6752
|
*
|
|
@@ -5858,18 +6793,18 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5858
6793
|
* @param [options.userdata] {Any}
|
|
5859
6794
|
* Arbitrary data that you can store along with this task group.
|
|
5860
6795
|
*/
|
|
5861
|
-
constructor(options
|
|
5862
|
-
onComplete?: Function
|
|
5863
|
-
priority?: number
|
|
5864
|
-
|
|
5865
|
-
|
|
5866
|
-
|
|
5867
|
-
}
|
|
6796
|
+
constructor(options: {
|
|
6797
|
+
onComplete?: Function;
|
|
6798
|
+
priority?: number;
|
|
6799
|
+
userdata: Record<string, any>;
|
|
6800
|
+
postponeOnAdd: number | boolean;
|
|
6801
|
+
name: string;
|
|
6802
|
+
});
|
|
6803
|
+
_postponed: number | boolean;
|
|
5868
6804
|
_onComplete: Function;
|
|
5869
6805
|
_priority: number;
|
|
5870
|
-
|
|
5871
|
-
name: string
|
|
5872
|
-
userdata: any;
|
|
6806
|
+
userdata: Record<string, any>;
|
|
6807
|
+
name: string;
|
|
5873
6808
|
_tasks: Set<any>;
|
|
5874
6809
|
_scheduledTasks: Set<any>;
|
|
5875
6810
|
_scheduled: boolean;
|
|
@@ -5888,13 +6823,22 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5888
6823
|
* @method tasks
|
|
5889
6824
|
* @return {[FrameTask]} list of tasks in this group
|
|
5890
6825
|
*/
|
|
5891
|
-
getTasks(): [
|
|
6826
|
+
getTasks(): any[];
|
|
5892
6827
|
/**
|
|
5893
6828
|
* Empty this task group. This will trivially satisfy `isComplete`.
|
|
5894
6829
|
*
|
|
5895
6830
|
* @method clear
|
|
5896
6831
|
*/
|
|
5897
6832
|
clear(): void;
|
|
6833
|
+
/**
|
|
6834
|
+
* Return one arbitrary incomplete task from this group, or undefined if
|
|
6835
|
+
* there are none.
|
|
6836
|
+
*
|
|
6837
|
+
* @method _popTask
|
|
6838
|
+
* @return {FrameTask} arbitrary scheduled task
|
|
6839
|
+
* @private
|
|
6840
|
+
*/
|
|
6841
|
+
_popTask(): any;
|
|
5898
6842
|
}
|
|
5899
6843
|
/**
|
|
5900
6844
|
* A timer for the task scheduler that uses real wall-time to determine if there's
|
|
@@ -5904,6 +6848,8 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5904
6848
|
* @private
|
|
5905
6849
|
*/
|
|
5906
6850
|
export class RealTimeTimer {
|
|
6851
|
+
_maxMillisecondsPerFrame: number;
|
|
6852
|
+
_time: number;
|
|
5907
6853
|
/**
|
|
5908
6854
|
* @constructor
|
|
5909
6855
|
* @param [options] {Object} Options for the timer
|
|
@@ -5912,10 +6858,8 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5912
6858
|
* or equal to this value, then another task may be executed
|
|
5913
6859
|
*/
|
|
5914
6860
|
constructor(options?: {
|
|
5915
|
-
maxMillisecondsPerFrame?:
|
|
5916
|
-
}
|
|
5917
|
-
_maxMillisecondsPerFrame: any;
|
|
5918
|
-
_time: any;
|
|
6861
|
+
maxMillisecondsPerFrame?: number;
|
|
6862
|
+
});
|
|
5919
6863
|
/**
|
|
5920
6864
|
* Begin timing a frame.
|
|
5921
6865
|
*
|
|
@@ -5937,6 +6881,8 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5937
6881
|
* @private
|
|
5938
6882
|
*/
|
|
5939
6883
|
export class FixedTimer {
|
|
6884
|
+
_ticks: number;
|
|
6885
|
+
maxTasksPerFrame: number;
|
|
5940
6886
|
/**
|
|
5941
6887
|
* @constructor
|
|
5942
6888
|
* @param [options] {Object} Options for the timer
|
|
@@ -5945,10 +6891,8 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5945
6891
|
* Can be modified as the `maxTasksPerFrame` property on this boject.
|
|
5946
6892
|
*/
|
|
5947
6893
|
constructor(options?: {
|
|
5948
|
-
maxTasksPerFrame?:
|
|
5949
|
-
}
|
|
5950
|
-
maxTasksPerFrame: any;
|
|
5951
|
-
_ticks: number;
|
|
6894
|
+
maxTasksPerFrame?: number;
|
|
6895
|
+
});
|
|
5952
6896
|
/**
|
|
5953
6897
|
* Begin timing a frame.
|
|
5954
6898
|
*
|
|
@@ -5992,11 +6936,11 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
5992
6936
|
* performance information.
|
|
5993
6937
|
*/
|
|
5994
6938
|
constructor(options?: {
|
|
5995
|
-
timer?:
|
|
5996
|
-
performance?:
|
|
5997
|
-
}
|
|
5998
|
-
_timer:
|
|
5999
|
-
_performance:
|
|
6939
|
+
timer?: RealTimeTimer;
|
|
6940
|
+
performance?: boolean;
|
|
6941
|
+
});
|
|
6942
|
+
_timer: RealTimeTimer;
|
|
6943
|
+
_performance: boolean;
|
|
6000
6944
|
_scheduledUpdatesByOrdering: Multimap;
|
|
6001
6945
|
_scheduledTasksByPriority: Multimap;
|
|
6002
6946
|
_postponedTasks: Set<any>;
|
|
@@ -6004,18 +6948,6 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6004
6948
|
_updatesToRunThisFrame: any[];
|
|
6005
6949
|
_lastFrameTime: number;
|
|
6006
6950
|
_updatesRunLastFrame: Set<any>;
|
|
6007
|
-
/**
|
|
6008
|
-
* Run all scheduled updates, and re-schedule another animation frame if any
|
|
6009
|
-
* scheduled updates still exist. If any scheduled update specifies
|
|
6010
|
-
* `shouldRunTasksAfterCompletion`, this will also run queued tasks until the
|
|
6011
|
-
* frame time runs out.
|
|
6012
|
-
*
|
|
6013
|
-
* @method update
|
|
6014
|
-
* @param timestamp {number} the current animation time, as returned from
|
|
6015
|
-
* `performance.now()`; will be automatically filled in by
|
|
6016
|
-
* `requestAnimationFrame` when it triggers this as a callback
|
|
6017
|
-
*/
|
|
6018
|
-
update(timestamp: number): void;
|
|
6019
6951
|
/**
|
|
6020
6952
|
* Empty the task scheduler's queue. All tasks in it will be cancelled.
|
|
6021
6953
|
*
|
|
@@ -6035,6 +6967,18 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6035
6967
|
* @method requestAnimationFrame
|
|
6036
6968
|
*/
|
|
6037
6969
|
requestAnimationFrame(): void;
|
|
6970
|
+
/**
|
|
6971
|
+
* Run all scheduled updates, and re-schedule another animation frame if any
|
|
6972
|
+
* scheduled updates still exist. If any scheduled update specifies
|
|
6973
|
+
* `shouldRunTasksAfterCompletion`, this will also run queued tasks until the
|
|
6974
|
+
* frame time runs out.
|
|
6975
|
+
*
|
|
6976
|
+
* @method update
|
|
6977
|
+
* @param timestamp {number} the current animation time, as returned from
|
|
6978
|
+
* `performance.now()`; will be automatically filled in by
|
|
6979
|
+
* `requestAnimationFrame` when it triggers this as a callback
|
|
6980
|
+
*/
|
|
6981
|
+
update(timestamp: number): void;
|
|
6038
6982
|
/**
|
|
6039
6983
|
* Execute all tasks that are currently pending, without regard for the
|
|
6040
6984
|
* available frame time.
|
|
@@ -6059,7 +7003,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6059
7003
|
* has not yet been run or if the scheduler has been cleared.
|
|
6060
7004
|
*/
|
|
6061
7005
|
getUpdatesRunLastFrame(): Set<any>;
|
|
6062
|
-
_executeOneTask(timestamp:
|
|
7006
|
+
_executeOneTask(timestamp: number): void;
|
|
6063
7007
|
/**
|
|
6064
7008
|
* Schedule an update to be run for the next `update.frameCount` frames. If
|
|
6065
7009
|
* the update already exists in the scheduler, the update's frame count will
|
|
@@ -6069,7 +7013,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6069
7013
|
* @method scheduleUpdate
|
|
6070
7014
|
* @param task {FrameUpdate} the update to schedule
|
|
6071
7015
|
*/
|
|
6072
|
-
scheduleUpdate(update:
|
|
7016
|
+
scheduleUpdate(update: FrameUpdate): void;
|
|
6073
7017
|
/**
|
|
6074
7018
|
* Schedule a task to be run during a frame update. This will also schedule
|
|
6075
7019
|
* an animation frame to begin processing the task queue.
|
|
@@ -6084,7 +7028,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6084
7028
|
* @method cancelUpdate
|
|
6085
7029
|
* @param task {FrameUpdate} the update to cancel
|
|
6086
7030
|
*/
|
|
6087
|
-
cancelUpdate(update:
|
|
7031
|
+
cancelUpdate(update: FrameUpdate): void;
|
|
6088
7032
|
/**
|
|
6089
7033
|
* If the given task or group is in the queue, remove it. Cancelling a
|
|
6090
7034
|
* completed task is a no-op.
|
|
@@ -6095,7 +7039,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6095
7039
|
* @method cancelTask
|
|
6096
7040
|
* @param task {FrameTask or FrameTaskGroup} the task to cancel
|
|
6097
7041
|
*/
|
|
6098
|
-
cancelTask(task: FrameTask): void;
|
|
7042
|
+
cancelTask(task: FrameTask | FrameTaskGroup): void;
|
|
6099
7043
|
/**
|
|
6100
7044
|
* Set the provided task or group not to run, until it's resumed using `resumeTask`.
|
|
6101
7045
|
*
|
|
@@ -6105,7 +7049,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6105
7049
|
* @method postponeTask
|
|
6106
7050
|
* @param task {FrameTask or FrameTaskGroup} the task to postpone
|
|
6107
7051
|
*/
|
|
6108
|
-
postponeTask(task: FrameTask): void;
|
|
7052
|
+
postponeTask(task: FrameTask | FrameTaskGroup): void;
|
|
6109
7053
|
/**
|
|
6110
7054
|
* Allow a postponed task or task group to resume processing. This will also
|
|
6111
7055
|
* request an animation frame to allow the resumed task to be processed.
|
|
@@ -6116,7 +7060,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6116
7060
|
* @method resumeTask
|
|
6117
7061
|
* @param task {FrameTask or FrameTaskGroup} the task to resume
|
|
6118
7062
|
*/
|
|
6119
|
-
resumeTask(task: FrameTask): void;
|
|
7063
|
+
resumeTask(task: FrameTask | FrameTaskGroup): void;
|
|
6120
7064
|
/**
|
|
6121
7065
|
* Change the priority of the given scheduled task or task group.
|
|
6122
7066
|
*
|
|
@@ -6124,7 +7068,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6124
7068
|
* @param task {FrameTask or FrameTaskGroup} the task whose priority will be changed
|
|
6125
7069
|
* @param priority {number} the priority to assign the task
|
|
6126
7070
|
*/
|
|
6127
|
-
setTaskPriority(task: FrameTask, priority: number): void;
|
|
7071
|
+
setTaskPriority(task: FrameTask | FrameTaskGroup, priority: number): void;
|
|
6128
7072
|
}
|
|
6129
7073
|
/**
|
|
6130
7074
|
* A map that maps a numeric key to a set of values.
|
|
@@ -6135,6 +7079,10 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6135
7079
|
* @private
|
|
6136
7080
|
*/
|
|
6137
7081
|
class Multimap {
|
|
7082
|
+
/**
|
|
7083
|
+
* @method constructor
|
|
7084
|
+
*/
|
|
7085
|
+
constructor();
|
|
6138
7086
|
_map: Map<any, any>;
|
|
6139
7087
|
_size: number;
|
|
6140
7088
|
_sortedKeys: any[];
|
|
@@ -6194,7 +7142,10 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6194
7142
|
* @method values
|
|
6195
7143
|
* @return {Iterator} iterator over the values in the map
|
|
6196
7144
|
*/
|
|
6197
|
-
values():
|
|
7145
|
+
values(): {
|
|
7146
|
+
[Symbol.iterator]: () => any;
|
|
7147
|
+
next: () => any;
|
|
7148
|
+
};
|
|
6198
7149
|
/**
|
|
6199
7150
|
* A list of keys in this set, sorted by numeric value. Not cloned,
|
|
6200
7151
|
* for efficiency's sake, so please don't mutate it.
|
|
@@ -6202,7 +7153,7 @@ declare module '@mappedin/react-native-sdk/core/packages/renderer/internal/Mappe
|
|
|
6202
7153
|
* @method keys
|
|
6203
7154
|
* @return {[number]} sorted list of numeric keys in the map
|
|
6204
7155
|
*/
|
|
6205
|
-
keys(): [
|
|
7156
|
+
keys(): any[];
|
|
6206
7157
|
/**
|
|
6207
7158
|
* The number of elements in this multimap, equal to the sum of the sizes
|
|
6208
7159
|
* of each key's set of values.
|