@mappedin/mappedin-js 6.0.1-alpha.2 → 6.0.1-alpha.20
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 +1 -1
- package/lib/esm/GLTFExporter-IBAAOJ4H.js +1 -0
- package/lib/esm/GLTFLoader-FBORQT4E.js +1 -0
- package/lib/esm/{PerformanceController-VMCH7DPO.js → PerformanceController-PUREED36.js} +1 -1
- package/lib/esm/{browser-G6HNHS3R.js → browser-RXOYKN3J.js} +1 -1
- package/lib/esm/chunk-R63UENRP.js +1 -0
- package/lib/esm/chunk-UEIQBALU.js +1 -0
- package/lib/esm/chunk-Y63ELNYD.js +1 -0
- package/lib/esm/index.css +1 -1
- package/lib/esm/index.d.ts +1324 -804
- package/lib/esm/index.js +1 -1
- package/lib/esm/outdoor-context-TTUIGEFF.js +1 -0
- package/lib/index.css +1 -1
- package/package.json +10 -5
- package/CHANGELOG.md +0 -54
- package/lib/esm/GLTFExporter-6MY3TTW5.js +0 -1
- package/lib/esm/chunk-ISNJUESV.js +0 -1
- package/lib/esm/chunk-SVP2SCIT.js +0 -1
- package/lib/esm/chunk-VSBVGSLC.js +0 -1
- package/lib/esm/outdoor-context-HUI6WIRE.js +0 -1
package/lib/esm/index.d.ts
CHANGED
|
@@ -18,6 +18,7 @@ declare module '@mappedin/mappedin-js' {
|
|
|
18
18
|
import { Floor } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
19
19
|
import type { ParsedMVF as TMVF } from '@mappedin/mvf';
|
|
20
20
|
import { TShowWatermarkOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/WatermarkController';
|
|
21
|
+
import { MapViewGeoJson } from '@mappedin/mappedin-js/maker/src/map-view-geojson';
|
|
21
22
|
/**
|
|
22
23
|
* Represents all the available antialiasing options.
|
|
23
24
|
*/
|
|
@@ -222,6 +223,8 @@ declare module '@mappedin/mappedin-js' {
|
|
|
222
223
|
* const mapContainer = document.getQuerySelector('body');
|
|
223
224
|
* const map = await show3dMap(mapContainer, mapData, { auto: true });
|
|
224
225
|
*/
|
|
226
|
+
export const show3dMapCms: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
|
|
227
|
+
export const show3dMapGeojson: (el: HTMLElement, mapData: MapData) => Promise<MapViewGeoJson>;
|
|
225
228
|
export const show3dMap: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
|
|
226
229
|
export { parseMVF, unzipMVF };
|
|
227
230
|
export type { MapView, MapData, TEvents, TShow3DMapOptions, TGetMapDataOptions, TAmbientOcclusionOptions, TAntialiasingOptions, TMVF, };
|
|
@@ -240,6 +243,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view' {
|
|
|
240
243
|
import MapData from '@mappedin/mappedin-js/maker/src/map-data';
|
|
241
244
|
import { ICamera, ILabels, IMapView, IMarkers, IPaths, TUpdateState, TNavigationTarget, TGetDirectionsOptions, INavigation } from '@mappedin/mappedin-js/maker/src/map-view-interface';
|
|
242
245
|
import { Directions, Label } from '@mappedin/mappedin-js/maker/src/map-view-objects';
|
|
246
|
+
import { Exporter } from '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Exporter';
|
|
243
247
|
/**
|
|
244
248
|
* Represents a map with all the interactive features, controls, and actions.
|
|
245
249
|
*/
|
|
@@ -270,6 +274,10 @@ declare module '@mappedin/mappedin-js/maker/src/map-view' {
|
|
|
270
274
|
* @type {INavigation}
|
|
271
275
|
*/
|
|
272
276
|
Navigation: INavigation;
|
|
277
|
+
/**
|
|
278
|
+
* Export controller for the map.
|
|
279
|
+
*/
|
|
280
|
+
Exporter: Exporter;
|
|
273
281
|
/**
|
|
274
282
|
* Constructs a {@link MapView} instance
|
|
275
283
|
*
|
|
@@ -285,7 +293,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view' {
|
|
|
285
293
|
/**
|
|
286
294
|
* @internal - unused until we use GeoJSON API underneath
|
|
287
295
|
*/
|
|
288
|
-
addMap(mapData: MapData)
|
|
296
|
+
addMap: (mapData: MapData) => Promise<MapData>;
|
|
289
297
|
/**
|
|
290
298
|
* Updates the state {@link TUpdateState} of a given target on the map.
|
|
291
299
|
*
|
|
@@ -326,6 +334,9 @@ declare module '@mappedin/mappedin-js/maker/src/map-view' {
|
|
|
326
334
|
* const floor = map.currentFloor;
|
|
327
335
|
*/
|
|
328
336
|
get currentFloor(): Floor;
|
|
337
|
+
get mapData(): {
|
|
338
|
+
[key: string]: MapData;
|
|
339
|
+
};
|
|
329
340
|
/**
|
|
330
341
|
* Sets the current floor of the map.
|
|
331
342
|
*/
|
|
@@ -485,10 +496,20 @@ declare module '@mappedin/mappedin-js/maker/src/events' {
|
|
|
485
496
|
*/
|
|
486
497
|
'user-interaction-end': undefined;
|
|
487
498
|
};
|
|
499
|
+
export type GeoJSONTEvents = TEvents & {
|
|
500
|
+
hover: {
|
|
501
|
+
coordinate: Coordinate;
|
|
502
|
+
spaces: Space[];
|
|
503
|
+
objects: MapObject[];
|
|
504
|
+
markers: Marker[];
|
|
505
|
+
labels: Label[];
|
|
506
|
+
floors: Floor[];
|
|
507
|
+
};
|
|
508
|
+
};
|
|
488
509
|
}
|
|
489
510
|
|
|
490
511
|
declare module '@mappedin/mappedin-js/packages/get-venue' {
|
|
491
|
-
import type { TGetVenueOptions, TGetVenueOptionsInternal, TVenueMetadata } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.types';
|
|
512
|
+
import type { TAllGetVenueOptions, TGetVenueOptions, TGetVenueOptionsInternal, TVenueMetadata, ThingsOption } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.types';
|
|
492
513
|
import { Mappedin } from '@mappedin/mappedin-js/packages/get-venue/Mappedin';
|
|
493
514
|
import { defaultThings } from '@mappedin/mappedin-js/packages/get-venue/default-things';
|
|
494
515
|
import { GET_VENUE_EVENT } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
@@ -526,6 +547,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue' {
|
|
|
526
547
|
export type { TOperationHoursMap } from '@mappedin/mappedin-js/packages/get-venue/MappedinLocation';
|
|
527
548
|
export type { TMappedinCoordinateOptions } from '@mappedin/mappedin-js/packages/get-venue/MappedinCoordinate';
|
|
528
549
|
export type { TDirectionToOptions, TTHINGS, TAccessors } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
550
|
+
export type { ThingsOption };
|
|
529
551
|
export { OfflineSearch } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.OfflineSearch';
|
|
530
552
|
export type { TMappedinOfflineSearchOptions, TMappedinOfflineSearchResult, TMappedinOfflineSearchSuggestions, TMappedinOfflineAllSearchMatch, TMappedinOfflineSearchAllOptions, } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.OfflineSearch';
|
|
531
553
|
export { defaultThings };
|
|
@@ -535,7 +557,10 @@ declare module '@mappedin/mappedin-js/packages/get-venue' {
|
|
|
535
557
|
import { MAP_RENDER_MODE } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.types';
|
|
536
558
|
import { ParsedMVF } from '@mappedin/mvf';
|
|
537
559
|
export { MAP_RENDER_MODE, GET_VENUE_EVENT };
|
|
538
|
-
|
|
560
|
+
/**
|
|
561
|
+
* @internal
|
|
562
|
+
*/
|
|
563
|
+
export function parseOptions<T extends TAllGetVenueOptions>(options: T): TGetVenueOptionsInternal<T>;
|
|
539
564
|
/**
|
|
540
565
|
* @internal
|
|
541
566
|
*/
|
|
@@ -637,7 +662,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue' {
|
|
|
637
662
|
* Download a bundle and return a Mappedin instance
|
|
638
663
|
* @internal
|
|
639
664
|
*/
|
|
640
|
-
export function downloadBundle(userOptions:
|
|
665
|
+
export function downloadBundle(userOptions: TGetVenueBundleOptions, { url, updated_at }: {
|
|
641
666
|
url: any;
|
|
642
667
|
updated_at: any;
|
|
643
668
|
}): Promise<Mappedin>;
|
|
@@ -688,7 +713,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue' {
|
|
|
688
713
|
}
|
|
689
714
|
|
|
690
715
|
declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF' {
|
|
691
|
-
import { Connections, Map as MVFMap, NodeCollection, ObstructionCollection, ParsedMVF, RawMVF, SpaceCollection } from '@mappedin/mvf';
|
|
716
|
+
import { Connections, Map as MVFMap, NodeCollection, ObstructionCollection, ParsedMVF, RawMVF, SpaceCollection, StyleCollection } from '@mappedin/mvf';
|
|
692
717
|
import { Position } from 'geojson';
|
|
693
718
|
import { TCategory, TLocation, TMap, TMappedinAPI, TNode, TPolygon, TVortex } from '@mappedin/mappedin-js/packages/get-venue';
|
|
694
719
|
import { MVFv1ConnectionCollection, MVFv1LevelCollection, MVFv1NodeCollection, ParsedMVFv1, RawMVFv1, WithIDs, MVFStyle } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF.types';
|
|
@@ -755,7 +780,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF' {
|
|
|
755
780
|
};
|
|
756
781
|
}[];
|
|
757
782
|
}
|
|
758
|
-
export function convertNodes(
|
|
783
|
+
export function convertNodes(nodesById: WithIDs<NodeCollection['features'][number]>, converters: Map<string, CoordinateConverter>): TNode[];
|
|
759
784
|
export function convertNodes_MVFv1(node: MVFv1NodeCollection, map: string, converter: CoordinateConverter): TNode[];
|
|
760
785
|
type MapExtent = {
|
|
761
786
|
minLat: number;
|
|
@@ -763,8 +788,8 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF' {
|
|
|
763
788
|
maxLat: number;
|
|
764
789
|
maxLong: number;
|
|
765
790
|
};
|
|
766
|
-
export function convertPolygons(map: string, mvfObstructions: ObstructionCollection, mvfSpaces: SpaceCollection, deskEntrances: Map<string, TPolygon['entrances']>, styles: WithIDs<MVFStyle>, converter: CoordinateConverter): TPolygon[];
|
|
767
|
-
export function convertVortexes(mvfConnections: Connections): TVortex[];
|
|
791
|
+
export function convertPolygons(map: string, mvfObstructions: ObstructionCollection, mvfSpaces: SpaceCollection, deskEntrances: Map<string, TPolygon['entrances']>, styles: WithIDs<MVFStyle>, layerStyles: StyleCollection, converter: CoordinateConverter): TPolygon[];
|
|
792
|
+
export function convertVortexes(mvfConnections: Connections, nodesById: WithIDs<NodeCollection['features'][number]>): TVortex[];
|
|
768
793
|
export function convertVortexes_MVFv1(mvfConnections: MVFv1ConnectionCollection): TVortex[];
|
|
769
794
|
export function overrideMVF(mvf: ParsedMVF, override?: Partial<Pick<ParsedMVF, 'styles.json'>>): ParsedMVF;
|
|
770
795
|
/**
|
|
@@ -938,25 +963,183 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
938
963
|
import { Sprite } from 'three';
|
|
939
964
|
type TPosition = 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right' | 'center' | 'top' | 'bottom' | 'left' | 'right';
|
|
940
965
|
export type TShowWatermarkOptions = {
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
966
|
+
/**
|
|
967
|
+
* Padding in pixels. Can be a number or an object with top, right, bottom, and left properties.
|
|
968
|
+
* @default 16
|
|
969
|
+
* @example
|
|
970
|
+
* ```ts
|
|
971
|
+
* // Watermark with 20 pixels of padding on all sides
|
|
972
|
+
* __showWatermark({
|
|
973
|
+
* padding: 20,
|
|
974
|
+
* });
|
|
975
|
+
* ```
|
|
976
|
+
* @example
|
|
977
|
+
* ```ts
|
|
978
|
+
* // Watermark with unique top, right, bottom, left padding
|
|
979
|
+
* __showWatermark({
|
|
980
|
+
* padding: {
|
|
981
|
+
* top: 10,
|
|
982
|
+
* right: 20,
|
|
983
|
+
* bottom: 30,
|
|
984
|
+
* left: 40,
|
|
985
|
+
* },
|
|
986
|
+
* });
|
|
987
|
+
* ```
|
|
988
|
+
*/
|
|
989
|
+
padding?: number | {
|
|
990
|
+
top?: number;
|
|
991
|
+
right?: number;
|
|
992
|
+
bottom?: number;
|
|
993
|
+
left?: number;
|
|
994
|
+
};
|
|
995
|
+
/**
|
|
996
|
+
* Position of the watermark on the screen.
|
|
997
|
+
* @default 'bottom-left'
|
|
998
|
+
*/
|
|
999
|
+
position?: TPosition;
|
|
1000
|
+
/**
|
|
1001
|
+
* Show only the Mappedin icon without text.
|
|
1002
|
+
* @default false
|
|
1003
|
+
*/
|
|
1004
|
+
iconOnly?: boolean;
|
|
1005
|
+
/**
|
|
1006
|
+
* Scale of the watermark between 0.5 and 1.5.
|
|
1007
|
+
* @default 1
|
|
1008
|
+
*/
|
|
1009
|
+
scale?: number;
|
|
1010
|
+
/**
|
|
1011
|
+
* Callback when the watermark is clicked.
|
|
1012
|
+
*/
|
|
1013
|
+
onClick?: () => void;
|
|
946
1014
|
};
|
|
947
1015
|
class WatermarkController {
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
954
|
-
|
|
955
|
-
|
|
1016
|
+
#private;
|
|
1017
|
+
static ENABLED: boolean;
|
|
1018
|
+
static OPTIONS: Required<TShowWatermarkOptions>;
|
|
1019
|
+
object?: Sprite;
|
|
1020
|
+
constructor(core: ICore);
|
|
1021
|
+
show: () => void;
|
|
1022
|
+
hide: () => void;
|
|
1023
|
+
resize: () => void;
|
|
956
1024
|
}
|
|
957
1025
|
export default WatermarkController;
|
|
958
1026
|
}
|
|
959
1027
|
|
|
1028
|
+
declare module '@mappedin/mappedin-js/maker/src/map-view-geojson' {
|
|
1029
|
+
import { PubSub } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
1030
|
+
import { GeoJSONTEvents as TEvents } from '@mappedin/mappedin-js/maker/src/events';
|
|
1031
|
+
import { Floor, MapObject, Space } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
1032
|
+
import MapData from '@mappedin/mappedin-js/maker/src/map-data';
|
|
1033
|
+
import { ICamera, ILabels, IMapView, IMarkers, IPaths, TUpdateState, INavigation, TNavigationTarget, TGetDirectionsOptions } from '@mappedin/mappedin-js/maker/src/map-view-interface';
|
|
1034
|
+
import { Directions, Label } from '@mappedin/mappedin-js/maker/src/map-view-objects';
|
|
1035
|
+
/**
|
|
1036
|
+
* Represents a map with all the interactive features, controls, and actions.
|
|
1037
|
+
*/
|
|
1038
|
+
export class MapViewGeoJson extends PubSub<TEvents> implements IMapView {
|
|
1039
|
+
#private;
|
|
1040
|
+
/**
|
|
1041
|
+
* Controls for the map's labels *{@link ILabels}).
|
|
1042
|
+
* @type {ILabels}
|
|
1043
|
+
*/
|
|
1044
|
+
Labels: ILabels;
|
|
1045
|
+
/**
|
|
1046
|
+
* Controls for the map's markers ({@link IMarkers}).
|
|
1047
|
+
* @type {IMarkers}
|
|
1048
|
+
*/
|
|
1049
|
+
Markers: IMarkers;
|
|
1050
|
+
/**
|
|
1051
|
+
* Camera ({@link ICamera}) controls for the map.
|
|
1052
|
+
* @type {ICamera}
|
|
1053
|
+
*/
|
|
1054
|
+
Camera: ICamera;
|
|
1055
|
+
/**
|
|
1056
|
+
* Controls for the map's ({@link IPaths}).
|
|
1057
|
+
* @type {IPaths}
|
|
1058
|
+
*/
|
|
1059
|
+
Paths: IPaths;
|
|
1060
|
+
/**
|
|
1061
|
+
* Navigation ({@link INavigation}) controls for the map.
|
|
1062
|
+
* @type {INavigation}
|
|
1063
|
+
*/
|
|
1064
|
+
Navigation: INavigation;
|
|
1065
|
+
/**
|
|
1066
|
+
* Constructs a {@link MapView} instance
|
|
1067
|
+
*
|
|
1068
|
+
* @param el The HTMLElement where the map will be rendered.
|
|
1069
|
+
* @param options The options to customize the map display.
|
|
1070
|
+
* @internal
|
|
1071
|
+
*/
|
|
1072
|
+
constructor(el: HTMLElement, options?: any);
|
|
1073
|
+
/**
|
|
1074
|
+
* @internal - unused until we use GeoJSON API underneath
|
|
1075
|
+
*/
|
|
1076
|
+
addMap(mapData: MapData): Promise<MapData>;
|
|
1077
|
+
/**
|
|
1078
|
+
* Updates the state {@link TUpdateState} of a given target on the map.
|
|
1079
|
+
*
|
|
1080
|
+
* The following table maps targets to states.
|
|
1081
|
+
*
|
|
1082
|
+
* | target | state |
|
|
1083
|
+
* |-----------|----------------|
|
|
1084
|
+
* | {@link Label} | {@link TLabelState} |
|
|
1085
|
+
* | {@link MapObject} | {@link TGeometryState} |
|
|
1086
|
+
* | {@link Space} | {@link TGeometryState} |
|
|
1087
|
+
*
|
|
1088
|
+
* @param target The target to update.
|
|
1089
|
+
* @param state The new state to apply to the target.
|
|
1090
|
+
* @example
|
|
1091
|
+
* // Update the color of a space to red.
|
|
1092
|
+
* map.updateState(space, { color: 'red' });
|
|
1093
|
+
*/
|
|
1094
|
+
updateState<T extends Space | MapObject | Label>(target: T, state: TUpdateState<T>): void;
|
|
1095
|
+
setHoverColor(c: string): void;
|
|
1096
|
+
getHoverColor(): string | undefined;
|
|
1097
|
+
getState(target: Space | Label | MapObject): {
|
|
1098
|
+
appearance: import("../../geojson/src/components/label").LabelAppearance | undefined;
|
|
1099
|
+
interactive: boolean | undefined;
|
|
1100
|
+
opacity: number;
|
|
1101
|
+
color?: undefined;
|
|
1102
|
+
} | {
|
|
1103
|
+
interactive: boolean | undefined;
|
|
1104
|
+
color: string;
|
|
1105
|
+
opacity: number;
|
|
1106
|
+
appearance?: undefined;
|
|
1107
|
+
} | undefined;
|
|
1108
|
+
/**
|
|
1109
|
+
* Retrieves the current floor of the map.
|
|
1110
|
+
*
|
|
1111
|
+
* @returns The current floor of the map.
|
|
1112
|
+
* @example
|
|
1113
|
+
* // Get the current floor of the map.
|
|
1114
|
+
* const floor = map.currentFloor;
|
|
1115
|
+
*/
|
|
1116
|
+
get currentFloor(): Floor;
|
|
1117
|
+
get mapData(): {
|
|
1118
|
+
[key: string]: MapData;
|
|
1119
|
+
};
|
|
1120
|
+
/**
|
|
1121
|
+
* Sets the current floor of the map.
|
|
1122
|
+
*/
|
|
1123
|
+
setFloor(floor: Floor | string): void;
|
|
1124
|
+
/**
|
|
1125
|
+
* Retrieves {@link Directions} from one navigatable point {@link TNavigationTarget} to another
|
|
1126
|
+
* {@link TNavigationTarget} on the map.
|
|
1127
|
+
*
|
|
1128
|
+
* @param from The starting point for navigation.
|
|
1129
|
+
* @param to The destination point.
|
|
1130
|
+
* @param options Optional parameters for getting directions.
|
|
1131
|
+
* @returns Directions from the start to the destination point.
|
|
1132
|
+
* @example
|
|
1133
|
+
* // Get directions from space1 to space2.
|
|
1134
|
+
* const directions = await map.getDirections(space1, space2);
|
|
1135
|
+
*/
|
|
1136
|
+
getDirections(from: TNavigationTarget | TNavigationTarget[], to: TNavigationTarget | TNavigationTarget[], options?: TGetDirectionsOptions): Directions | undefined;
|
|
1137
|
+
Outdoor: {
|
|
1138
|
+
setStyle: (style: any) => void;
|
|
1139
|
+
};
|
|
1140
|
+
}
|
|
1141
|
+
}
|
|
1142
|
+
|
|
960
1143
|
declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
961
1144
|
import type { Coordinate, Floor, Door, Space, MapObject, PointOfInterest, Connection } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
962
1145
|
import { Label, Marker, Path, Directions } from '@mappedin/mappedin-js/maker/src/map-view-objects';
|
|
@@ -1110,15 +1293,15 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1110
1293
|
*/
|
|
1111
1294
|
export type TGeometryState = {
|
|
1112
1295
|
/**
|
|
1113
|
-
* Color of the geometry element.
|
|
1296
|
+
* Color of the geometry element. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1114
1297
|
*/
|
|
1115
1298
|
color: string | 'initial';
|
|
1116
1299
|
/**
|
|
1117
|
-
* Color of the geometry element when hovered over.
|
|
1300
|
+
* Color of the geometry element when hovered over. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1118
1301
|
*/
|
|
1119
1302
|
hoverColor: string | 'initial';
|
|
1120
1303
|
/**
|
|
1121
|
-
* Indicates if the geometry element is interactive.
|
|
1304
|
+
* Indicates if the geometry element is interactive. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1122
1305
|
*/
|
|
1123
1306
|
interactive: boolean;
|
|
1124
1307
|
};
|
|
@@ -1314,6 +1497,11 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1314
1497
|
* @internal
|
|
1315
1498
|
*/
|
|
1316
1499
|
auto(): void;
|
|
1500
|
+
/**
|
|
1501
|
+
* Get the current floor
|
|
1502
|
+
*/
|
|
1503
|
+
currentFloor: Floor;
|
|
1504
|
+
setFloor(floor: Floor): void;
|
|
1317
1505
|
/**
|
|
1318
1506
|
* @internal - unused until we use GeoJSON API underneath
|
|
1319
1507
|
*/
|
|
@@ -1340,7 +1528,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1340
1528
|
* // Update the color of a space to red.
|
|
1341
1529
|
* map.updateState(space, { color: 'red' });
|
|
1342
1530
|
*/
|
|
1343
|
-
updateState: <T extends Space | Label>(object: T, state: TUpdateState<T>) => void;
|
|
1531
|
+
updateState: <T extends Space | MapObject | Label>(object: T, state: TUpdateState<T>) => void;
|
|
1344
1532
|
/**
|
|
1345
1533
|
* Retrieves {@link Directions} from one navigation point {@link TNavigationTarget} to another
|
|
1346
1534
|
* {@link TNavigationTarget} on the map.
|
|
@@ -1352,80 +1540,80 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1352
1540
|
* // Get directions from space1 to space2.
|
|
1353
1541
|
* const directions = await map.getDirections(space1, space2);
|
|
1354
1542
|
*/
|
|
1355
|
-
getDirections: (from: TNavigationTarget, to: TNavigationTarget) =>
|
|
1543
|
+
getDirections: (from: TNavigationTarget | TNavigationTarget[], to: TNavigationTarget | TNavigationTarget[], options?: TGetDirectionsOptions) => Directions | undefined;
|
|
1356
1544
|
}
|
|
1357
1545
|
/**
|
|
1358
1546
|
* Options for controlling the behavior of a {@link Path}.
|
|
1359
1547
|
*/
|
|
1360
1548
|
export type TAddPathOptions = {
|
|
1361
1549
|
/**
|
|
1362
|
-
* Path Colour
|
|
1550
|
+
* Path Colour. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1363
1551
|
*
|
|
1364
1552
|
* @defaultValue #4b90e2
|
|
1365
1553
|
*/
|
|
1366
1554
|
color?: string;
|
|
1367
1555
|
/**
|
|
1368
|
-
* Colour of path pulse
|
|
1556
|
+
* Colour of path pulse. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1369
1557
|
*
|
|
1370
1558
|
* @defaultValue '#ffffff'
|
|
1371
1559
|
*/
|
|
1372
1560
|
pulseColor?: string;
|
|
1373
1561
|
/**
|
|
1374
|
-
* Number of iterations to pulse to indicate direction
|
|
1562
|
+
* Number of iterations to pulse to indicate direction.
|
|
1375
1563
|
*
|
|
1376
1564
|
* @defaultValue 1
|
|
1377
1565
|
*/
|
|
1378
1566
|
pulseIterations?: number;
|
|
1379
1567
|
/**
|
|
1380
|
-
* How many milliseconds to wait before starting the next pulse after the current pulse travels the entirety of the path
|
|
1568
|
+
* How many milliseconds to wait before starting the next pulse after the current pulse travels the entirety of the path.
|
|
1381
1569
|
*
|
|
1382
1570
|
* @defaultValue 750
|
|
1383
1571
|
*/
|
|
1384
1572
|
pulsePauseDuration?: number;
|
|
1385
1573
|
/**
|
|
1386
|
-
* Radius of path at nearest zoom, in metres
|
|
1574
|
+
* Radius of path at nearest zoom, in metres.
|
|
1387
1575
|
*
|
|
1388
1576
|
* @defaultValue 1.8
|
|
1389
1577
|
*/
|
|
1390
1578
|
nearRadius?: number;
|
|
1391
1579
|
/**
|
|
1392
|
-
* Radius of path at furthest zoom, in metres
|
|
1580
|
+
* Radius of path at furthest zoom, in metres.
|
|
1393
1581
|
*
|
|
1394
1582
|
* @defaultValue 2.3 times nearRadius
|
|
1395
1583
|
*/
|
|
1396
1584
|
farRadius?: number;
|
|
1397
1585
|
/**
|
|
1398
|
-
* Zoom level in meters where the path size is `nearRadius
|
|
1586
|
+
* Zoom level in meters where the path size is `nearRadius`.
|
|
1399
1587
|
*
|
|
1400
1588
|
* @defaultValue 375
|
|
1401
1589
|
*/
|
|
1402
1590
|
nearZoom?: number;
|
|
1403
1591
|
/**
|
|
1404
|
-
* Zoom level in meters where the path size is `farRadius
|
|
1592
|
+
* Zoom level in meters where the path size is `farRadius`.
|
|
1405
1593
|
*
|
|
1406
1594
|
* @defaultValue 10000
|
|
1407
1595
|
*/
|
|
1408
1596
|
farZoom?: number;
|
|
1409
1597
|
/**
|
|
1410
|
-
* Duration of path drawing
|
|
1598
|
+
* Duration of path drawing in milliseconds.
|
|
1411
1599
|
*
|
|
1412
1600
|
* @defaultValue 1500
|
|
1413
1601
|
*/
|
|
1414
1602
|
drawDuration?: number;
|
|
1415
1603
|
/**
|
|
1416
|
-
* Show arrows on path
|
|
1604
|
+
* Show arrows on path.
|
|
1417
1605
|
*
|
|
1418
1606
|
* @defaultValue false
|
|
1419
1607
|
*/
|
|
1420
1608
|
displayArrowsOnPath?: boolean;
|
|
1421
1609
|
/**
|
|
1422
|
-
* Animate arrows on path
|
|
1610
|
+
* Animate arrows on path.
|
|
1423
1611
|
*
|
|
1424
1612
|
* @defaultValue true
|
|
1425
1613
|
*/
|
|
1426
1614
|
animateArrowsOnPath?: boolean;
|
|
1427
1615
|
/**
|
|
1428
|
-
* Flatten the path to a 2D line
|
|
1616
|
+
* Flatten the path to a 2D line.
|
|
1429
1617
|
*
|
|
1430
1618
|
* @defaultValue false
|
|
1431
1619
|
*/
|
|
@@ -1449,21 +1637,21 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1449
1637
|
*/
|
|
1450
1638
|
interactive?: boolean;
|
|
1451
1639
|
/**
|
|
1452
|
-
* The path will be adjusted vertically to the tallest
|
|
1640
|
+
* The path will be adjusted vertically to the tallest altitude along the path.
|
|
1453
1641
|
* The altitude is in meters.
|
|
1454
1642
|
*
|
|
1455
1643
|
* @defaultValue false
|
|
1456
1644
|
*/
|
|
1457
1645
|
adjustedAltitude?: boolean;
|
|
1458
1646
|
/**
|
|
1459
|
-
* The maximum altitude of the path in meters
|
|
1647
|
+
* The maximum altitude of the path in meters.
|
|
1460
1648
|
* The altitude is in meters.
|
|
1461
1649
|
*
|
|
1462
1650
|
* @defaultValue Infinite
|
|
1463
1651
|
*/
|
|
1464
1652
|
maxAdjustedAltitude?: number;
|
|
1465
1653
|
/**
|
|
1466
|
-
* The minimum altitude of the path in meters
|
|
1654
|
+
* The minimum altitude of the path in meters.
|
|
1467
1655
|
* The altitude is in meters.
|
|
1468
1656
|
*
|
|
1469
1657
|
* @defaultValue -Infinite
|
|
@@ -1481,7 +1669,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1481
1669
|
margin?: number;
|
|
1482
1670
|
text?: {
|
|
1483
1671
|
/**
|
|
1484
|
-
* Number of lines to display when text spans multiple lines
|
|
1672
|
+
* Number of lines to display when text spans multiple lines.
|
|
1485
1673
|
*/
|
|
1486
1674
|
numLines?: number;
|
|
1487
1675
|
/**
|
|
@@ -1489,21 +1677,21 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1489
1677
|
*/
|
|
1490
1678
|
size?: number;
|
|
1491
1679
|
/**
|
|
1492
|
-
* Maxiumum width of text in pixels
|
|
1680
|
+
* Maxiumum width of text in pixels.
|
|
1493
1681
|
*/
|
|
1494
1682
|
maxWidth?: number;
|
|
1495
1683
|
/**
|
|
1496
|
-
* Line height sets the height of a line box. It's commonly used to set the distance between lines of text
|
|
1684
|
+
* Line height sets the height of a line box. It's commonly used to set the distance between lines of text.
|
|
1497
1685
|
*
|
|
1498
1686
|
* @default 1.2
|
|
1499
1687
|
*/
|
|
1500
1688
|
lineHeight?: number;
|
|
1501
1689
|
/**
|
|
1502
|
-
* Text foreground color
|
|
1690
|
+
* Text foreground color. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1503
1691
|
*/
|
|
1504
1692
|
foregroundColor?: string;
|
|
1505
1693
|
/**
|
|
1506
|
-
* Text background color
|
|
1694
|
+
* Text background color. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1507
1695
|
*/
|
|
1508
1696
|
backgroundColor?: string;
|
|
1509
1697
|
};
|
|
@@ -1515,39 +1703,66 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1515
1703
|
size?: number;
|
|
1516
1704
|
foregroundColor?: {
|
|
1517
1705
|
/**
|
|
1518
|
-
* Foreground color of the marker
|
|
1706
|
+
* Foreground color of the marker when it is active. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1519
1707
|
*/
|
|
1520
1708
|
active?: string;
|
|
1521
1709
|
/**
|
|
1522
|
-
* Foreground color of the marker
|
|
1710
|
+
* Foreground color of the marker when it is inactive (grayed out due to being outranked by other labels around). Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1523
1711
|
*/
|
|
1524
1712
|
inactive?: string;
|
|
1525
1713
|
};
|
|
1526
1714
|
backgroundColor?: {
|
|
1527
1715
|
/**
|
|
1528
|
-
* Background color of the marker
|
|
1716
|
+
* Background color of the marker when it is active. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1529
1717
|
*/
|
|
1530
1718
|
active?: string;
|
|
1531
1719
|
/**
|
|
1532
|
-
* Background color of the marker
|
|
1720
|
+
* Background color of the marker when it is inactive (grayed out due to being outranked by other labels around). Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1533
1721
|
*/
|
|
1534
1722
|
inactive?: string;
|
|
1535
1723
|
};
|
|
1536
1724
|
/**
|
|
1537
|
-
* Size of bounding box of
|
|
1725
|
+
* Size of bounding box of the icon in pixels
|
|
1726
|
+
* @default 10
|
|
1538
1727
|
*/
|
|
1539
1728
|
iconSize?: number;
|
|
1540
1729
|
/**
|
|
1541
|
-
* SVG
|
|
1730
|
+
* Icon to be placed inside label. Supports SVG or a URL to png or jpeg.
|
|
1731
|
+
*
|
|
1732
|
+
* @example
|
|
1733
|
+
* ```ts
|
|
1734
|
+
* // SVG
|
|
1735
|
+
* mapView.Labels.add(space, space.name, {
|
|
1736
|
+
* appearance: {
|
|
1737
|
+
* icon: `<svg>...</svg>`
|
|
1738
|
+
* },
|
|
1739
|
+
* });
|
|
1740
|
+
* ```
|
|
1542
1741
|
*
|
|
1543
1742
|
* @example
|
|
1544
|
-
*
|
|
1545
|
-
*
|
|
1546
|
-
*
|
|
1547
|
-
*
|
|
1548
|
-
*
|
|
1743
|
+
* ```ts
|
|
1744
|
+
* // Image URL
|
|
1745
|
+
* mapView.Labels.add(space, space.name, {
|
|
1746
|
+
* appearance: {
|
|
1747
|
+
* icon: 'https://example.com/icon.png',
|
|
1748
|
+
* },
|
|
1749
|
+
* });
|
|
1750
|
+
* ```
|
|
1549
1751
|
*/
|
|
1550
1752
|
icon?: string;
|
|
1753
|
+
/**
|
|
1754
|
+
* How the icon should fit inside the marker.
|
|
1755
|
+
* - `fill` will stretch the icon to fill the marker.
|
|
1756
|
+
* - `cover` will maintain aspect ratio and fill the marker.
|
|
1757
|
+
* - `contain` will maintain aspect ratio and fit the icon inside the marker.
|
|
1758
|
+
* @default 'fill'
|
|
1759
|
+
*/
|
|
1760
|
+
iconFit?: 'contain' | 'fill' | 'cover';
|
|
1761
|
+
/**
|
|
1762
|
+
* Padding around the icon, in pixels.
|
|
1763
|
+
* @default 4
|
|
1764
|
+
*/
|
|
1765
|
+
iconPadding?: number;
|
|
1551
1766
|
/**
|
|
1552
1767
|
* Defines when the icon becomes visible relative to the current zoom level
|
|
1553
1768
|
* anything below 0 will result in icons never showing up
|
|
@@ -1593,11 +1808,27 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1593
1808
|
*/
|
|
1594
1809
|
accessible?: boolean;
|
|
1595
1810
|
/**
|
|
1596
|
-
* Enable or disable
|
|
1811
|
+
* Enable or disable line-of-sight directions smoothing.
|
|
1812
|
+
* With this option enabled, the directions will be simplified to provide a more visually appealing path and shorter instructions.
|
|
1813
|
+
*
|
|
1814
|
+
* Can be a boolean to enable or disable smoothing, or an object with a radius property to specify the line of sight radius in metres.
|
|
1597
1815
|
*
|
|
1598
1816
|
* @default true
|
|
1817
|
+
*
|
|
1818
|
+
* @example
|
|
1819
|
+
* ```ts
|
|
1820
|
+
* // Enable smoothing with a radius of 3 metres
|
|
1821
|
+
* mapView.getDirections(firstSpace, secondSpace, {
|
|
1822
|
+
* smoothing: {
|
|
1823
|
+
* radius: 3,
|
|
1824
|
+
* }
|
|
1825
|
+
* })
|
|
1826
|
+
* ```
|
|
1599
1827
|
*/
|
|
1600
|
-
smoothing?: boolean
|
|
1828
|
+
smoothing?: boolean | {
|
|
1829
|
+
enabled?: boolean;
|
|
1830
|
+
radius: number;
|
|
1831
|
+
};
|
|
1601
1832
|
};
|
|
1602
1833
|
/**
|
|
1603
1834
|
* Options for controlling the behavior of a {@link Marker}.
|
|
@@ -1699,8 +1930,8 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-interface' {
|
|
|
1699
1930
|
*/
|
|
1700
1931
|
export type TDrawNavigationOptions = {
|
|
1701
1932
|
/**
|
|
1702
|
-
*
|
|
1703
|
-
* Pass false to disable
|
|
1933
|
+
* Color to highlight departure and destination spaces. Color can be set using CSS colors names `DarkGoldenRod`, as Hex strings `#0000FF` or the rgb values `rgb(255,0,0)`.
|
|
1934
|
+
* Pass false to disable.
|
|
1704
1935
|
* @default '#7babc8'
|
|
1705
1936
|
*/
|
|
1706
1937
|
polygonHighlightColor?: string | false;
|
|
@@ -1750,6 +1981,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-objects' {
|
|
|
1750
1981
|
|
|
1751
1982
|
declare module '@mappedin/mappedin-js/maker/src/navigation' {
|
|
1752
1983
|
import type { MapView, Directions } from '@mappedin/mappedin-js/maker/src';
|
|
1984
|
+
import { INavigation } from '@mappedin/mappedin-js/maker/src/map-view-interface';
|
|
1753
1985
|
const defaultOptions: {
|
|
1754
1986
|
createMarkers: {
|
|
1755
1987
|
departure: boolean;
|
|
@@ -1791,7 +2023,7 @@ declare module '@mappedin/mappedin-js/maker/src/navigation' {
|
|
|
1791
2023
|
};
|
|
1792
2024
|
};
|
|
1793
2025
|
constructor(mapView: MapView);
|
|
1794
|
-
draw:
|
|
2026
|
+
draw: INavigation['draw'];
|
|
1795
2027
|
clear: () => void;
|
|
1796
2028
|
}
|
|
1797
2029
|
export {};
|
|
@@ -1806,6 +2038,7 @@ declare module '@mappedin/mappedin-js/maker/src' {
|
|
|
1806
2038
|
import { Floor } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
1807
2039
|
import type { ParsedMVF as TMVF } from '@mappedin/mvf';
|
|
1808
2040
|
import { TShowWatermarkOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/WatermarkController';
|
|
2041
|
+
import { MapViewGeoJson } from '@mappedin/mappedin-js/maker/src/map-view-geojson';
|
|
1809
2042
|
/**
|
|
1810
2043
|
* Represents all the available antialiasing options.
|
|
1811
2044
|
*/
|
|
@@ -2010,6 +2243,8 @@ declare module '@mappedin/mappedin-js/maker/src' {
|
|
|
2010
2243
|
* const mapContainer = document.getQuerySelector('body');
|
|
2011
2244
|
* const map = await show3dMap(mapContainer, mapData, { auto: true });
|
|
2012
2245
|
*/
|
|
2246
|
+
export const show3dMapCms: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
|
|
2247
|
+
export const show3dMapGeojson: (el: HTMLElement, mapData: MapData) => Promise<MapViewGeoJson>;
|
|
2013
2248
|
export const show3dMap: (el: HTMLElement, mapData: MapData, options?: TShow3DMapOptions) => Promise<MapView>;
|
|
2014
2249
|
export { parseMVF, unzipMVF };
|
|
2015
2250
|
export type { MapView, MapData, TEvents, TShow3DMapOptions, TGetMapDataOptions, TAmbientOcclusionOptions, TAntialiasingOptions, TMVF, };
|
|
@@ -2207,6 +2442,37 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal' {
|
|
|
2207
2442
|
export { setAssetManager };
|
|
2208
2443
|
}
|
|
2209
2444
|
|
|
2445
|
+
declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Exporter' {
|
|
2446
|
+
import { ExportController } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
2447
|
+
/**
|
|
2448
|
+
* @hidden
|
|
2449
|
+
*/
|
|
2450
|
+
export type TGLTFExportOptions = {
|
|
2451
|
+
onlyVisible?: boolean;
|
|
2452
|
+
binary?: boolean;
|
|
2453
|
+
scale?: number;
|
|
2454
|
+
};
|
|
2455
|
+
/**
|
|
2456
|
+
* API to export the scene.
|
|
2457
|
+
*
|
|
2458
|
+
* @hidden
|
|
2459
|
+
*/
|
|
2460
|
+
export class Exporter {
|
|
2461
|
+
#private;
|
|
2462
|
+
/**
|
|
2463
|
+
* @hidden
|
|
2464
|
+
* @internal
|
|
2465
|
+
*/
|
|
2466
|
+
constructor(controller: ExportController);
|
|
2467
|
+
/**
|
|
2468
|
+
* Exports the current scene as a GLTF file.
|
|
2469
|
+
*
|
|
2470
|
+
* @hidden
|
|
2471
|
+
*/
|
|
2472
|
+
getCurrentSceneGLTF(userOptions: TGLTFExportOptions): Promise<Blob>;
|
|
2473
|
+
}
|
|
2474
|
+
}
|
|
2475
|
+
|
|
2210
2476
|
declare module '@mappedin/mappedin-js/maker/src/map-data-interace' {
|
|
2211
2477
|
import type { Annotation, Connection, Coordinate, Door, Floor, MapObject, PointOfInterest, Space } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
2212
2478
|
/**
|
|
@@ -2285,6 +2551,14 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-objects/camera-transfor
|
|
|
2285
2551
|
}
|
|
2286
2552
|
|
|
2287
2553
|
declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.types' {
|
|
2554
|
+
import type { TGetVenueMVFOptions, TGetVenueMakerOptions } from '@mappedin/mappedin-js/packages/get-venue';
|
|
2555
|
+
import type { DefaultThings } from '@mappedin/mappedin-js/packages/get-venue/default-things';
|
|
2556
|
+
export type MergedThings = {
|
|
2557
|
+
[key in keyof DefaultThings]: string[];
|
|
2558
|
+
} & {
|
|
2559
|
+
[k: string]: string[];
|
|
2560
|
+
};
|
|
2561
|
+
export type ThingsOption = Partial<MergedThings>;
|
|
2288
2562
|
export type TGetVenueOptions = {
|
|
2289
2563
|
accessToken?: string;
|
|
2290
2564
|
clientId?: string;
|
|
@@ -2298,22 +2572,45 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.types' {
|
|
|
2298
2572
|
[key in string]: string;
|
|
2299
2573
|
};
|
|
2300
2574
|
venue: string;
|
|
2301
|
-
|
|
2575
|
+
/**
|
|
2576
|
+
* An object specifying additional properties to fetch for each data item.
|
|
2577
|
+
* Each key represents a data item (e.g., 'locations', 'nodes'), and the value is an array of strings indicating extra properties to be included.
|
|
2578
|
+
* @example
|
|
2579
|
+
* For example:
|
|
2580
|
+
* ```
|
|
2581
|
+
* getVenue({
|
|
2582
|
+
* venue: 'some-venue',
|
|
2583
|
+
* things: { vortexes: [ 'material' ]
|
|
2584
|
+
* }})
|
|
2585
|
+
* ```
|
|
2586
|
+
*/
|
|
2587
|
+
things?: ThingsOption;
|
|
2302
2588
|
useDraftData?: boolean;
|
|
2303
2589
|
platformString?: string;
|
|
2304
2590
|
emitAnalyticsEvents?: boolean;
|
|
2305
2591
|
secure?: boolean;
|
|
2306
2592
|
preloadMapGeometry?: boolean;
|
|
2307
2593
|
};
|
|
2308
|
-
export type
|
|
2594
|
+
export type TProcessedMVFOptions = TGetVenueMakerOptions & {
|
|
2595
|
+
emitAnalyticsEvents: boolean;
|
|
2596
|
+
clientId: string;
|
|
2597
|
+
clientSecret: string;
|
|
2598
|
+
venue: string;
|
|
2599
|
+
accessToken: string;
|
|
2600
|
+
};
|
|
2601
|
+
export type TAllGetVenueOptions = TGetVenueOptions | TGetVenueMVFOptions | (TProcessedMVFOptions & {
|
|
2602
|
+
perspective?: string;
|
|
2603
|
+
});
|
|
2604
|
+
export type TGetVenueOptionsInternal<T extends TAllGetVenueOptions> = Omit<T & {
|
|
2309
2605
|
baseUrl?: string;
|
|
2310
2606
|
supplementaryUrl?: string;
|
|
2311
2607
|
noAuth?: boolean;
|
|
2312
2608
|
includeHidden?: boolean;
|
|
2313
2609
|
apiGateway?: string;
|
|
2314
2610
|
authorization?: string;
|
|
2315
|
-
things?: any;
|
|
2316
2611
|
headers?: any;
|
|
2612
|
+
}, 'things'> & {
|
|
2613
|
+
things?: MergedThings;
|
|
2317
2614
|
};
|
|
2318
2615
|
export type TVenueMetadata = {
|
|
2319
2616
|
languages: {
|
|
@@ -2336,14 +2633,14 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.types' {
|
|
|
2336
2633
|
|
|
2337
2634
|
declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin' {
|
|
2338
2635
|
import { Navigator } from '@mappedin/mappedin-js/packages/navigator';
|
|
2339
|
-
import type { TGetVenueOptions, TGetVenueOptionsInternal } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.types';
|
|
2636
|
+
import type { TAllGetVenueOptions, TGetVenueOptions, TGetVenueOptionsInternal } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.types';
|
|
2340
2637
|
import type { MappedinNode, MappedinPolygon, MappedinLocation, MappedinCategory, MappedinVortex, MappedinVenue, MappedinTheme, MappedinRankings, MappedinLocationRankings, MappedinEvent, MappedinLocationState, MappedinMap, MappedinMapGroup, GET_VENUE_PAYLOAD } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
2341
2638
|
import { TAccessors, GET_VENUE_EVENT } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
2342
2639
|
import { IAnalytics } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.CustomerAnalytics';
|
|
2343
2640
|
import { ParsedMVF } from '@mappedin/mvf';
|
|
2344
2641
|
import { ParsedMVFv1 } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF.types';
|
|
2345
2642
|
import { PubSub } from '@mappedin/mappedin-js/packages/get-venue/pub-sub.typed';
|
|
2346
|
-
export const defaultOptions: TGetVenueOptionsInternal
|
|
2643
|
+
export const defaultOptions: TGetVenueOptionsInternal<TGetVenueOptions>;
|
|
2347
2644
|
export class Mappedin extends PubSub<GET_VENUE_PAYLOAD, GET_VENUE_EVENT> {
|
|
2348
2645
|
#private;
|
|
2349
2646
|
perspective: any;
|
|
@@ -2567,15 +2864,15 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin' {
|
|
|
2567
2864
|
* @param mappedinSerializableData Mappedin data that was serialized or exported as JSON
|
|
2568
2865
|
* @param shouldPopulateBundledImagesAsBlobs Takes the scenes and images from a bundle and maps them as blobs to where they exist as URLs in the bundle. False by default
|
|
2569
2866
|
*/
|
|
2570
|
-
hydrate(mappedinSerializableData: string | Record<string, unknown>, shouldPopulateBundledImagesAsBlobs?: boolean): Promise<undefined>;
|
|
2867
|
+
hydrate(mappedinSerializableData: string | Record<string, unknown>, shouldPopulateBundledImagesAsBlobs?: boolean, updateInPlace?: boolean): Promise<undefined>;
|
|
2571
2868
|
images: any;
|
|
2572
2869
|
imageBinaries?: Map<string, Uint8Array>;
|
|
2573
2870
|
scenes: any;
|
|
2574
|
-
fetch(): Promise<void>;
|
|
2871
|
+
fetch(updateInPlace?: boolean): Promise<void>;
|
|
2575
2872
|
/**
|
|
2576
2873
|
* @deprecated Use {@link hydrateVenue} instead
|
|
2577
2874
|
*/
|
|
2578
|
-
constructor(options: TGetVenueOptionsInternal
|
|
2875
|
+
constructor(options: TGetVenueOptionsInternal<TAllGetVenueOptions>);
|
|
2579
2876
|
analytics: IAnalytics;
|
|
2580
2877
|
/**
|
|
2581
2878
|
* @hidden
|
|
@@ -2605,6 +2902,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/default-things' {
|
|
|
2605
2902
|
themes: string[];
|
|
2606
2903
|
rankings: string[];
|
|
2607
2904
|
};
|
|
2905
|
+
export type DefaultThings = typeof defaultThings;
|
|
2608
2906
|
}
|
|
2609
2907
|
|
|
2610
2908
|
declare module '@mappedin/mappedin-js/packages/get-venue/internal' {
|
|
@@ -2946,6 +3244,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinLocation' {
|
|
|
2946
3244
|
siblingGroups?: TSiblingGroup[] | undefined;
|
|
2947
3245
|
gallery?: TGalleryImage[] | undefined;
|
|
2948
3246
|
amenity?: string | undefined;
|
|
3247
|
+
filterFlags?: string[];
|
|
2949
3248
|
constructor(mappedin: Mappedin, data: any);
|
|
2950
3249
|
/**
|
|
2951
3250
|
* Polygons this Location is attached to.
|
|
@@ -2982,6 +3281,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinLocation' {
|
|
|
2982
3281
|
clone(): MappedinLocation;
|
|
2983
3282
|
get nodeOperationHours(): TOperationHoursMap;
|
|
2984
3283
|
static hydrate(locations: any, mappedin: Mappedin): MappedinLocation[];
|
|
3284
|
+
static updateInPlace(mappedin: Mappedin, hydrateData?: any): Promise<void>;
|
|
2985
3285
|
static fetch(mappedin: Mappedin): Promise<MappedinLocation[]>;
|
|
2986
3286
|
/**
|
|
2987
3287
|
*
|
|
@@ -2999,8 +3299,8 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinLocation' {
|
|
|
2999
3299
|
}
|
|
3000
3300
|
|
|
3001
3301
|
declare module '@mappedin/mappedin-js/packages/get-venue/MappedinCoordinate' {
|
|
3002
|
-
import { MappedinNode, Mappedin } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
3003
3302
|
import type { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
3303
|
+
import { Mappedin, MappedinNode } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
3004
3304
|
export type TMappedinCoordinateOptions = {
|
|
3005
3305
|
map: MappedinMap;
|
|
3006
3306
|
mappedin: Mappedin;
|
|
@@ -3063,6 +3363,11 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinCoordinate' {
|
|
|
3063
3363
|
* Get Nearest Node to Coordinate, which can then be used for navigation
|
|
3064
3364
|
*/
|
|
3065
3365
|
get nearestNode(): MappedinNode;
|
|
3366
|
+
/**
|
|
3367
|
+
* Get the {@link MappedinNode}s within a radius of the {@link MappedinCoordinate}.
|
|
3368
|
+
* @param radius - The radius in metres.
|
|
3369
|
+
*/
|
|
3370
|
+
nodesInRadius(radius: number): MappedinNode[];
|
|
3066
3371
|
toJSON(): {
|
|
3067
3372
|
x: number;
|
|
3068
3373
|
y: number;
|
|
@@ -3732,7 +4037,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF.types' {
|
|
|
3732
4037
|
}
|
|
3733
4038
|
|
|
3734
4039
|
declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF.utils' {
|
|
3735
|
-
import { Feature, LineString, Polygon } from '@turf/turf';
|
|
4040
|
+
import type { Feature, LineString, Polygon } from '@turf/turf';
|
|
3736
4041
|
import { EntranceCollection, ObstructionCollection, EntranceProperties, ObstructionProperties, StyleCollection, PolygonStyle, LineStringStyle } from '@mappedin/mvf';
|
|
3737
4042
|
import { MVFStyle, WithIDs } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF.types';
|
|
3738
4043
|
export const Z_FIGHTING_ADJUSTMENT_HORIZONTAL_FACTOR = 0.2;
|
|
@@ -3746,7 +4051,8 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.MVF.utils' {
|
|
|
3746
4051
|
*/
|
|
3747
4052
|
export const STATIC_MVF_FILES: readonly ["connection.json", "manifest.geojson", "map.geojson", "node.geojson", "styles.json", "mapstack.geojson"];
|
|
3748
4053
|
export type TStaticMVFFiles = (typeof STATIC_MVF_FILES)[number];
|
|
3749
|
-
export function processObstructions(obstructionCollection: ObstructionCollection, entrances: EntranceCollection
|
|
4054
|
+
export function processObstructions(obstructionCollection: ObstructionCollection, entrances: EntranceCollection): ObstructionCollection;
|
|
4055
|
+
export function splitObstructionByAllEntrances(wall: ObstructionWallFeature, entrances: EntranceFeature[]): ObstructionWallFeature[];
|
|
3750
4056
|
export function isPolygonStyle(style: PolygonStyle | LineStringStyle | undefined): style is PolygonStyle & LineStringStyle;
|
|
3751
4057
|
export function getStylesMap(styles: StyleCollection): WithIDs<MVFStyle>;
|
|
3752
4058
|
}
|
|
@@ -3833,7 +4139,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/node' {
|
|
|
3833
4139
|
}
|
|
3834
4140
|
|
|
3835
4141
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/door' {
|
|
3836
|
-
import { EntranceCollection,
|
|
4142
|
+
import { EntranceCollection, Image } from '@mappedin/mvf';
|
|
3837
4143
|
import Coordinate from '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate';
|
|
3838
4144
|
import type Floor from '@mappedin/mappedin-js/maker/src/map-data-objects/floor';
|
|
3839
4145
|
import type { MapDataInternal } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
@@ -3874,7 +4180,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/door' {
|
|
|
3874
4180
|
*/
|
|
3875
4181
|
get name(): string;
|
|
3876
4182
|
get description(): string;
|
|
3877
|
-
get links(): Hyperlink[];
|
|
3878
4183
|
get images(): Image[];
|
|
3879
4184
|
/**
|
|
3880
4185
|
* Gets the {@link Floor} object associated with the door.
|
|
@@ -3919,7 +4224,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/door' {
|
|
|
3919
4224
|
}
|
|
3920
4225
|
|
|
3921
4226
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/space' {
|
|
3922
|
-
import {
|
|
4227
|
+
import { Image, SpaceCollection } from '@mappedin/mvf';
|
|
3923
4228
|
import Coordinate from '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate';
|
|
3924
4229
|
import type { MapDataInternal } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
3925
4230
|
import type Floor from '@mappedin/mappedin-js/maker/src/map-data-objects/floor';
|
|
@@ -3977,7 +4282,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/space' {
|
|
|
3977
4282
|
*/
|
|
3978
4283
|
get type(): TSpaceType;
|
|
3979
4284
|
get description(): string;
|
|
3980
|
-
get links(): Hyperlink[];
|
|
3981
4285
|
get images(): Image[];
|
|
3982
4286
|
/**
|
|
3983
4287
|
* Gets the {@link Floor} object associated with the space.
|
|
@@ -4130,9 +4434,9 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/floor' {
|
|
|
4130
4434
|
}
|
|
4131
4435
|
|
|
4132
4436
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/connection' {
|
|
4133
|
-
import { FeatureCollection,
|
|
4437
|
+
import { FeatureCollection, Image, Point, SpaceProperties } from '@mappedin/mvf';
|
|
4134
4438
|
import Coordinate from '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate';
|
|
4135
|
-
import type { MapDataInternal } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
4439
|
+
import type { Floor, MapDataInternal } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
4136
4440
|
import BaseMapData from '@mappedin/mappedin-js/maker/src/map-data-objects/base-object';
|
|
4137
4441
|
/**
|
|
4138
4442
|
* A class representing connection data within the map.
|
|
@@ -4169,7 +4473,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/connection' {
|
|
|
4169
4473
|
*/
|
|
4170
4474
|
get name(): string;
|
|
4171
4475
|
get description(): string;
|
|
4172
|
-
get links(): Hyperlink[];
|
|
4173
4476
|
get images(): Image[];
|
|
4174
4477
|
/**
|
|
4175
4478
|
* Gets the type of the connection.
|
|
@@ -4188,7 +4491,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/connection' {
|
|
|
4188
4491
|
*
|
|
4189
4492
|
* @returns {Floor[]} An array of floors for the connection.
|
|
4190
4493
|
*/
|
|
4191
|
-
get floors():
|
|
4494
|
+
get floors(): Floor[];
|
|
4192
4495
|
/**
|
|
4193
4496
|
* Serializes the connection data to JSON.
|
|
4194
4497
|
*
|
|
@@ -4216,7 +4519,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/connection' {
|
|
|
4216
4519
|
}
|
|
4217
4520
|
|
|
4218
4521
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/object' {
|
|
4219
|
-
import {
|
|
4522
|
+
import { Image, ObstructionCollection } from '@mappedin/mvf';
|
|
4220
4523
|
import Coordinate from '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate';
|
|
4221
4524
|
import type { MapDataInternal } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
4222
4525
|
import type Floor from '@mappedin/mappedin-js/maker/src/map-data-objects/floor';
|
|
@@ -4257,7 +4560,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/object' {
|
|
|
4257
4560
|
*/
|
|
4258
4561
|
get name(): string;
|
|
4259
4562
|
get description(): string;
|
|
4260
|
-
get links(): Hyperlink[];
|
|
4261
4563
|
get images(): Image[];
|
|
4262
4564
|
/**
|
|
4263
4565
|
* Gets the type of the MapObject.
|
|
@@ -4305,8 +4607,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/object' {
|
|
|
4305
4607
|
}
|
|
4306
4608
|
|
|
4307
4609
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate' {
|
|
4308
|
-
import type { MapDataInternal } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
4309
|
-
import type Floor from '@mappedin/mappedin-js/maker/src/map-data-objects/floor';
|
|
4310
4610
|
/**
|
|
4311
4611
|
* Class representing a pseudo-mercator coordinate.
|
|
4312
4612
|
*
|
|
@@ -4316,7 +4616,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate' {
|
|
|
4316
4616
|
* which is commonly used in marine navigation.
|
|
4317
4617
|
*/
|
|
4318
4618
|
class Coordinate {
|
|
4319
|
-
#private;
|
|
4320
4619
|
/**
|
|
4321
4620
|
* @internal
|
|
4322
4621
|
*/
|
|
@@ -4336,6 +4635,10 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate' {
|
|
|
4336
4635
|
* @type {number}
|
|
4337
4636
|
*/
|
|
4338
4637
|
readonly longitude: number;
|
|
4638
|
+
/**
|
|
4639
|
+
* The floor ID of the coordinate.
|
|
4640
|
+
*/
|
|
4641
|
+
readonly floorId?: string;
|
|
4339
4642
|
/**
|
|
4340
4643
|
* Checks if the provided instance is of type Coordinate.
|
|
4341
4644
|
*
|
|
@@ -4346,11 +4649,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate' {
|
|
|
4346
4649
|
/**
|
|
4347
4650
|
* @internal
|
|
4348
4651
|
*/
|
|
4349
|
-
constructor(
|
|
4350
|
-
latitude: number;
|
|
4351
|
-
longitude: number;
|
|
4352
|
-
floorId?: string;
|
|
4353
|
-
});
|
|
4652
|
+
constructor(latitude: number, longitude: number, floorId?: string);
|
|
4354
4653
|
/**
|
|
4355
4654
|
* Checks if this coordinate is equal to another coordinate.
|
|
4356
4655
|
*
|
|
@@ -4358,13 +4657,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate' {
|
|
|
4358
4657
|
* @returns {boolean} True if coordinates are equal, false otherwise.
|
|
4359
4658
|
*/
|
|
4360
4659
|
isEqual(coordinate: Coordinate): boolean;
|
|
4361
|
-
/**
|
|
4362
|
-
* Gets the {@link Floor} associated with the coordinate.
|
|
4363
|
-
*
|
|
4364
|
-
* @returns {Floor | undefined} The {@link Floor} object if available.
|
|
4365
|
-
* @throws Will throw an error if the floor is not found.
|
|
4366
|
-
*/
|
|
4367
|
-
get floor(): Floor | undefined;
|
|
4368
4660
|
/**
|
|
4369
4661
|
* Serializes the coordinate data to JSON.
|
|
4370
4662
|
*
|
|
@@ -4390,7 +4682,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/poi' {
|
|
|
4390
4682
|
import type { Floor, MapDataInternal } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
4391
4683
|
import Coordinate from '@mappedin/mappedin-js/maker/src/map-data-objects/coordinate';
|
|
4392
4684
|
import BaseMapData from '@mappedin/mappedin-js/maker/src/map-data-objects/base-object';
|
|
4393
|
-
import Hyperlink from '@mappedin/mappedin-js/maker/src/map-data-objects/hyperlink';
|
|
4394
4685
|
import Image from '@mappedin/mappedin-js/maker/src/map-data-objects/image';
|
|
4395
4686
|
/**
|
|
4396
4687
|
* A class representing point of interest data within the map.
|
|
@@ -4434,12 +4725,6 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/poi' {
|
|
|
4434
4725
|
* @returns {string} The description of the POI.
|
|
4435
4726
|
*/
|
|
4436
4727
|
get description(): string;
|
|
4437
|
-
/**
|
|
4438
|
-
* Gets the links associated with the POI.
|
|
4439
|
-
*
|
|
4440
|
-
* @returns {Hyperlink[]} The links associated with the POI.
|
|
4441
|
-
*/
|
|
4442
|
-
get links(): Hyperlink[];
|
|
4443
4728
|
/**
|
|
4444
4729
|
* Gets the images associated with the POI.
|
|
4445
4730
|
*
|
|
@@ -4571,11 +4856,11 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/annotation' {
|
|
|
4571
4856
|
|
|
4572
4857
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/hyperlink' {
|
|
4573
4858
|
import { Hyperlink as MVFHyperlink } from '@mappedin/mvf';
|
|
4574
|
-
import
|
|
4859
|
+
import BaseMetaData from '@mappedin/mappedin-js/maker/src/map-data-objects/base-metadata-object';
|
|
4575
4860
|
/**
|
|
4576
4861
|
* A class representing hyperlink link data within the map.
|
|
4577
4862
|
*/
|
|
4578
|
-
class Hyperlink extends
|
|
4863
|
+
class Hyperlink extends BaseMetaData {
|
|
4579
4864
|
#private;
|
|
4580
4865
|
/**
|
|
4581
4866
|
* @internal
|
|
@@ -4628,11 +4913,11 @@ declare module '@mappedin/mappedin-js/maker/src/map-data-objects/hyperlink' {
|
|
|
4628
4913
|
|
|
4629
4914
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/image' {
|
|
4630
4915
|
import { Image as MVFImage } from '@mappedin/mvf';
|
|
4631
|
-
import
|
|
4916
|
+
import BaseMetaData from '@mappedin/mappedin-js/maker/src/map-data-objects/base-metadata-object';
|
|
4632
4917
|
/**
|
|
4633
4918
|
* A class representing image link data within the map.
|
|
4634
4919
|
*/
|
|
4635
|
-
class Image extends
|
|
4920
|
+
class Image extends BaseMetaData {
|
|
4636
4921
|
#private;
|
|
4637
4922
|
/**
|
|
4638
4923
|
* @internal
|
|
@@ -4910,7 +5195,10 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/Core.inte
|
|
|
4910
5195
|
* An object containing all outlined polygons.
|
|
4911
5196
|
*/
|
|
4912
5197
|
outlinedPolygons: Map<string, MappedinPolygon>;
|
|
4913
|
-
|
|
5198
|
+
/**
|
|
5199
|
+
* A plane that is parallel to the ground and is used for raycasting.
|
|
5200
|
+
*/
|
|
5201
|
+
worldPlane: Mesh;
|
|
4914
5202
|
getPositionLatLon(lat: number, lon: number, map?: MappedinMap | string | null): Vector3;
|
|
4915
5203
|
currentScale: number;
|
|
4916
5204
|
getPositionPolygon(polygon: MappedinPolygon | string): Vector3;
|
|
@@ -4971,7 +5259,7 @@ declare module '@mappedin/mappedin-js/maker/src/map-view-objects/label' {
|
|
|
4971
5259
|
* Labels are used to provide additional information on the map.
|
|
4972
5260
|
*/
|
|
4973
5261
|
export class Label implements ILabel {
|
|
4974
|
-
id: string;
|
|
5262
|
+
readonly id: string;
|
|
4975
5263
|
readonly text: any;
|
|
4976
5264
|
/**
|
|
4977
5265
|
* @internal
|
|
@@ -5381,15 +5669,15 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/MapView.enums' {
|
|
|
5381
5669
|
}
|
|
5382
5670
|
|
|
5383
5671
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types' {
|
|
5384
|
-
import type { Mappedin, MappedinCoordinate, MappedinLocation, MappedinMap, MappedinNode, MappedinPolygon } from '@mappedin/mappedin-js/packages/get-venue';
|
|
5672
|
+
import type { Mappedin, MappedinCoordinate, MappedinLocation, MappedinMap, MappedinNode, MappedinPolygon, ThingsOption } from '@mappedin/mappedin-js/packages/get-venue';
|
|
5385
5673
|
import type { TFloatingLabelAppearance } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.FloatingLabel';
|
|
5386
5674
|
import type { TEnableBlueDotOptions, TBlueDotPositionUpdate, TBlueDotStateChange } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.BlueDot/Mappedin.BlueDot.core';
|
|
5387
5675
|
import type { Euler, Object3D, Vector3 } from 'three';
|
|
5388
5676
|
import type { Path } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/PathsController';
|
|
5389
5677
|
import { TOOLTIP_ANCHOR } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.SmartTooltip';
|
|
5390
5678
|
import { GEOLOCATION_STATUS, COLLISION_RANKING_TIERS, STATE, MARKER_ANCHOR, E_SDK_EVENT, E_BLUEDOT_EVENT, E_CAMERA_EVENT, MAP_RENDER_MODE, CAMERA_EASING_MODE, E_MAP_CHANGED_REASON } from '@mappedin/mappedin-js/packages/legacy-renderer/MapView.enums';
|
|
5391
|
-
import {
|
|
5392
|
-
export type { TEnableBlueDotOptions, TFloatingLabelAppearance };
|
|
5679
|
+
import { TOutdoorViewOptions, TOutdoorViewOptionsWithHeaders, TOutdoorViewOptionsWithAuthURL } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/OutdoorViewController';
|
|
5680
|
+
export type { TEnableBlueDotOptions, TFloatingLabelAppearance, ThingsOption };
|
|
5393
5681
|
/** @internal */
|
|
5394
5682
|
export type Without<T, U> = {
|
|
5395
5683
|
[P in Exclude<keyof T, keyof U>]?: never;
|
|
@@ -5881,6 +6169,13 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types' {
|
|
|
5881
6169
|
outdoorGeometryLayers?: string[];
|
|
5882
6170
|
/**
|
|
5883
6171
|
* Use the current polygon objects directly rather than what is stored when rendering the map in CMS.
|
|
6172
|
+
*
|
|
6173
|
+
* Important Considerations:
|
|
6174
|
+
* - When this flag is set to true, the application will use live polygon data, which might not include certain enhancements such as 3D text annotations or automatically generated infill patterns. These features typically depend on the CMS's Render capabilities.
|
|
6175
|
+
* - Opting for live polygons means the system will not utilize the pre-processed optimized polygon data that is available through the CMS's rendering pipeline.
|
|
6176
|
+
* - This option is useful for applications requiring the most up-to-date representation of polygon data but may result in a less detailed visual representation due to the absence of certain rendered features.
|
|
6177
|
+
*
|
|
6178
|
+
* Use this option with caution, understanding the trade-offs between real-time update and visual detail.
|
|
5884
6179
|
*/
|
|
5885
6180
|
useLivePolygons?: boolean;
|
|
5886
6181
|
};
|
|
@@ -5889,7 +6184,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types' {
|
|
|
5889
6184
|
* Requires `multiBufferRendering` to be enabled.
|
|
5890
6185
|
* @experimental
|
|
5891
6186
|
*/
|
|
5892
|
-
outdoorView?:
|
|
6187
|
+
outdoorView?: TOutdoorViewOptions & {
|
|
5893
6188
|
enabled?: boolean;
|
|
5894
6189
|
};
|
|
5895
6190
|
/**
|
|
@@ -6026,6 +6321,10 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types' {
|
|
|
6026
6321
|
onWebGLRendererError?: () => void;
|
|
6027
6322
|
};
|
|
6028
6323
|
export type TShowVenueOptions = {
|
|
6324
|
+
/**
|
|
6325
|
+
* Enable shading of bottoms of geometry along with outlines to make geometry stand out.
|
|
6326
|
+
*/
|
|
6327
|
+
shadingAndOutlines?: boolean;
|
|
6029
6328
|
/**
|
|
6030
6329
|
* @experimental
|
|
6031
6330
|
*
|
|
@@ -6083,7 +6382,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types' {
|
|
|
6083
6382
|
* @experimental
|
|
6084
6383
|
* Enable outdoor view. Requires multi-buffer rendering to be enabled
|
|
6085
6384
|
*/
|
|
6086
|
-
outdoorView?:
|
|
6385
|
+
outdoorView?: TOutdoorViewOptions & {
|
|
6087
6386
|
enabled?: boolean;
|
|
6088
6387
|
};
|
|
6089
6388
|
/**
|
|
@@ -6588,11 +6887,30 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types' {
|
|
|
6588
6887
|
*/
|
|
6589
6888
|
[E_CAMERA_EVENT.TILT_CHANGED]: number;
|
|
6590
6889
|
};
|
|
6890
|
+
export type { TOutdoorViewOptions, TOutdoorViewOptionsWithHeaders, TOutdoorViewOptionsWithAuthURL };
|
|
6591
6891
|
export type { default as BlueDotController } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/BlueDotController';
|
|
6592
6892
|
export type { default as Journey } from '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Journey';
|
|
6593
|
-
|
|
6594
|
-
|
|
6893
|
+
export type TStackedMapsOptions = {
|
|
6894
|
+
/**
|
|
6895
|
+
* The vertical distance between maps in overview, in metres.
|
|
6896
|
+
* @default 50
|
|
6897
|
+
*/
|
|
6898
|
+
verticalDistanceBetweenMaps?: number;
|
|
6899
|
+
/**
|
|
6900
|
+
* Whether to show map level labels in overview.
|
|
6901
|
+
* @default true
|
|
6902
|
+
*/
|
|
6903
|
+
mapLabels?: boolean;
|
|
6904
|
+
/**
|
|
6905
|
+
* Whether to show only Journey maps in the stack if a Journey is active and the current map is part of the Journey.
|
|
6906
|
+
* @default true
|
|
6907
|
+
*/
|
|
6908
|
+
prioritizeJourneyMaps?: boolean;
|
|
6909
|
+
};
|
|
6910
|
+
}
|
|
6911
|
+
|
|
6595
6912
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/json-scene-loader' {
|
|
6913
|
+
import { Group } from 'three';
|
|
6596
6914
|
import { Element } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
6597
6915
|
import DefaultAssetManager from '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.AssetManager';
|
|
6598
6916
|
import { MappedinMap, MappedinPolygon } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
@@ -6612,12 +6930,12 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/json-sce
|
|
|
6612
6930
|
on it, or a string URL to fetch those polygons from.
|
|
6613
6931
|
**/
|
|
6614
6932
|
load(polygons: string | MappedinPolygon[], mapClass: MappedinMap, mapLoadingStrategy?: MAP_RENDER_MODE): Promise<{
|
|
6615
|
-
container:
|
|
6933
|
+
container: Group<import("three").Object3DEventMap>;
|
|
6616
6934
|
elements: (Element | null)[];
|
|
6617
6935
|
visibleLayers: Set<unknown>;
|
|
6618
6936
|
}>;
|
|
6619
6937
|
_build(polygons: MappedinPolygon[], mapClass: MappedinMap, mapLoadingStrategy?: MAP_RENDER_MODE): Promise<{
|
|
6620
|
-
container:
|
|
6938
|
+
container: Group<import("three").Object3DEventMap>;
|
|
6621
6939
|
elements: (Element | null)[];
|
|
6622
6940
|
visibleLayers: Set<unknown>;
|
|
6623
6941
|
}>;
|
|
@@ -7246,7 +7564,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/pub-sub.typed' {
|
|
|
7246
7564
|
* @template EVENT_PAYLOAD - The type of the event payload.
|
|
7247
7565
|
* @template EVENT - The type of the event.
|
|
7248
7566
|
*/
|
|
7249
|
-
export class PubSub<EVENT_PAYLOAD, EVENT extends keyof EVENT_PAYLOAD> {
|
|
7567
|
+
export class PubSub<EVENT_PAYLOAD, EVENT extends keyof EVENT_PAYLOAD = keyof EVENT_PAYLOAD> {
|
|
7250
7568
|
/**
|
|
7251
7569
|
* @private
|
|
7252
7570
|
* @internal
|
|
@@ -7300,7 +7618,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/pub-sub.typed' {
|
|
|
7300
7618
|
}
|
|
7301
7619
|
|
|
7302
7620
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.MapObject' {
|
|
7303
|
-
import {
|
|
7621
|
+
import { Box3, Mesh, MeshLambertMaterial, Object3D, Vector3, BufferGeometry } from 'three';
|
|
7304
7622
|
import { FrameTaskGroup } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.TaskScheduler';
|
|
7305
7623
|
import { Element, FlippableImage, MappedinMap, TaskScheduler, FlatLabel, SmartTooltip, ICore, InternalFloatingLabel, TCreateThreeDMarkerOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
7306
7624
|
import { PubSub } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/pub-sub';
|
|
@@ -7326,14 +7644,15 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
7326
7644
|
export const SCENE_FROM_LIVE_JSON = false;
|
|
7327
7645
|
type InterpolationFunctionType = (zoomLevel: number) => any;
|
|
7328
7646
|
export class LayerGroup {
|
|
7329
|
-
mergedObjectsGroup:
|
|
7330
|
-
hoverObjectsGroup:
|
|
7647
|
+
mergedObjectsGroup: any;
|
|
7648
|
+
hoverObjectsGroup: any;
|
|
7331
7649
|
objectsByMaterials: Map<MeshLambertMaterial, Element[]>;
|
|
7332
|
-
hoverableMeshChildren: Mesh;
|
|
7650
|
+
hoverableMeshChildren: Mesh<BufferGeometry, MeshLambertMaterial>[];
|
|
7333
7651
|
_isVisible: boolean;
|
|
7334
7652
|
needsUpdate: boolean;
|
|
7335
7653
|
userData: any;
|
|
7336
7654
|
opacity: number;
|
|
7655
|
+
outlineDarkeningFactor: number;
|
|
7337
7656
|
core: ICore;
|
|
7338
7657
|
mapObject: MapObject;
|
|
7339
7658
|
name: string;
|
|
@@ -7351,6 +7670,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
7351
7670
|
constructor(mapObject: MapObject, name: string, layers: string[], visible: boolean);
|
|
7352
7671
|
dispose(): void;
|
|
7353
7672
|
setOpacity(opacity: any): void;
|
|
7673
|
+
setOutlineDarkeningFactor(factor: number): void;
|
|
7354
7674
|
}
|
|
7355
7675
|
export interface LoadOptions {
|
|
7356
7676
|
async?: boolean;
|
|
@@ -7441,8 +7761,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
7441
7761
|
processLayers(allLayers: string[], include?: string[], exclude?: string[]): string[];
|
|
7442
7762
|
processLayerGroup(name?: string, include?: string[], exclude?: string[], visible?: boolean, elements?: Element[], defaultRenderOrder?: number): LayerGroup;
|
|
7443
7763
|
get hoverableMeshChildren(): Mesh[];
|
|
7444
|
-
_objLoadedMerged(object:
|
|
7445
|
-
_objLoaded(object:
|
|
7764
|
+
_objLoadedMerged(object: any): Promise<void>;
|
|
7765
|
+
_objLoaded(object: any): void;
|
|
7446
7766
|
loadPolygonNow(polygonId: string): void;
|
|
7447
7767
|
_addElementToScene(element: Element): void;
|
|
7448
7768
|
/** *
|
|
@@ -7598,13 +7918,13 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
7598
7918
|
}
|
|
7599
7919
|
|
|
7600
7920
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.AssetManager' {
|
|
7601
|
-
import { Texture } from 'three';
|
|
7921
|
+
import { Texture, TextureLoader } from 'three';
|
|
7602
7922
|
import type { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
7603
7923
|
/**
|
|
7604
7924
|
* @internal
|
|
7605
7925
|
*/
|
|
7606
7926
|
export default class DefaultAssetManager {
|
|
7607
|
-
textureLoader:
|
|
7927
|
+
textureLoader: TextureLoader;
|
|
7608
7928
|
loadMapPolygons(map: MappedinMap): Promise<any>;
|
|
7609
7929
|
loadImage(url: string): Promise<Texture>;
|
|
7610
7930
|
}
|
|
@@ -7830,13 +8150,49 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
7830
8150
|
inactive?: string;
|
|
7831
8151
|
};
|
|
7832
8152
|
/**
|
|
7833
|
-
* Size of bounding box of
|
|
8153
|
+
* Size of bounding box of the icon
|
|
8154
|
+
* @default 10
|
|
7834
8155
|
*/
|
|
7835
8156
|
iconSize?: number;
|
|
7836
8157
|
/**
|
|
7837
|
-
*
|
|
8158
|
+
* Icon to be placed inside the Floating Label marker. Supports SVG or a URL to png or jpeg.
|
|
8159
|
+
* @example
|
|
8160
|
+
* ```ts
|
|
8161
|
+
* // SVG
|
|
8162
|
+
* mapView.FloatingLabels.add(polygon, "Label", {
|
|
8163
|
+
* appearance: {
|
|
8164
|
+
* marker: {
|
|
8165
|
+
* icon: `<svg>...</svg>`,
|
|
8166
|
+
* },
|
|
8167
|
+
* },
|
|
8168
|
+
* });
|
|
8169
|
+
* ```
|
|
8170
|
+
*
|
|
8171
|
+
* @example
|
|
8172
|
+
* ```ts
|
|
8173
|
+
* // Image URL
|
|
8174
|
+
* mapView.FloatingLabels.add(polygon, "Label", {
|
|
8175
|
+
* appearance: {
|
|
8176
|
+
* marker: {
|
|
8177
|
+
* icon: 'https://example.com/icon.png',
|
|
8178
|
+
* },
|
|
8179
|
+
* },
|
|
8180
|
+
* });
|
|
8181
|
+
* ```
|
|
7838
8182
|
*/
|
|
7839
8183
|
icon?: string;
|
|
8184
|
+
/**
|
|
8185
|
+
* How the icon should fit inside the marker. By default, this is not set and the icon will be centered inside the marker.
|
|
8186
|
+
* - `fill` will stretch the icon to fill the marker.
|
|
8187
|
+
* - `cover` will maintain aspect ratio and fill the marker.
|
|
8188
|
+
* - `contain` will maintain aspect ratio and fit the icon inside the marker.
|
|
8189
|
+
*/
|
|
8190
|
+
iconFit?: 'contain' | 'fill' | 'cover';
|
|
8191
|
+
/**
|
|
8192
|
+
* Padding around the icon, in pixels.
|
|
8193
|
+
* @default 4
|
|
8194
|
+
*/
|
|
8195
|
+
iconPadding?: number;
|
|
7840
8196
|
/**
|
|
7841
8197
|
* Defines when the icon becomes visible relative to the current zoom level
|
|
7842
8198
|
* anything below 0 will result in icons never showing up
|
|
@@ -7868,6 +8224,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
7868
8224
|
};
|
|
7869
8225
|
iconSize?: number;
|
|
7870
8226
|
icon?: string;
|
|
8227
|
+
iconFit?: 'fill' | 'cover' | 'contain';
|
|
8228
|
+
iconPadding: number;
|
|
7871
8229
|
iconVisibilityThreshold?: number;
|
|
7872
8230
|
};
|
|
7873
8231
|
};
|
|
@@ -7934,6 +8292,12 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
7934
8292
|
static imagePromiseCache: {
|
|
7935
8293
|
[key in number]?: Promise<HTMLImageElement>;
|
|
7936
8294
|
};
|
|
8295
|
+
static imageDimensionsCache: {
|
|
8296
|
+
[key in number]: {
|
|
8297
|
+
width: number;
|
|
8298
|
+
height: number;
|
|
8299
|
+
};
|
|
8300
|
+
};
|
|
7937
8301
|
get pinCanvasSize(): number;
|
|
7938
8302
|
draw(context: CanvasRenderingContext2D): void;
|
|
7939
8303
|
}
|
|
@@ -8209,6 +8573,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
8209
8573
|
}
|
|
8210
8574
|
|
|
8211
8575
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-manager/MapView.Scene' {
|
|
8576
|
+
import { Object3D } from 'three';
|
|
8212
8577
|
import { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
8213
8578
|
import type { ICore, SceneManager, TSceneTransitionOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
8214
8579
|
import { MapObject } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
@@ -8217,7 +8582,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8217
8582
|
maps: MappedinMap[];
|
|
8218
8583
|
mapObjectsArray: MapObject[];
|
|
8219
8584
|
transitionOptions: TSceneTransitionOptions | undefined;
|
|
8220
|
-
object:
|
|
8585
|
+
object: Object3D<import("three").Object3DEventMap>;
|
|
8221
8586
|
currentMap: MappedinMap;
|
|
8222
8587
|
mapObjects: Map<MappedinMap['id'], MapObject>;
|
|
8223
8588
|
constructor(maps: MappedinMap[], core: ICore);
|
|
@@ -8228,7 +8593,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8228
8593
|
* Determine each maps position and rotation relative to the refernce map
|
|
8229
8594
|
*/
|
|
8230
8595
|
determineMapPositionAndRotation(map: MappedinMap): {
|
|
8231
|
-
position:
|
|
8596
|
+
position: number[];
|
|
8232
8597
|
scale: number[];
|
|
8233
8598
|
rotation: number[];
|
|
8234
8599
|
};
|
|
@@ -8252,7 +8617,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8252
8617
|
}
|
|
8253
8618
|
|
|
8254
8619
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-manager/MapView.StackScene' {
|
|
8255
|
-
import { Box3,
|
|
8620
|
+
import { Box3, Mesh } from 'three';
|
|
8256
8621
|
import { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
8257
8622
|
import type { ICore, SceneManager, TSceneTransitionOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
8258
8623
|
import { MapObject, MapViewScene } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
@@ -8260,13 +8625,13 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8260
8625
|
class MapViewStackScene extends MapViewScene {
|
|
8261
8626
|
#private;
|
|
8262
8627
|
containerBoxHelper: Box3;
|
|
8263
|
-
viewportBox:
|
|
8264
|
-
currentMapWrapperMesh:
|
|
8265
|
-
currentMapWrapperBoxHelper:
|
|
8266
|
-
viewportMesh:
|
|
8267
|
-
stackContainerMesh:
|
|
8628
|
+
viewportBox: any;
|
|
8629
|
+
currentMapWrapperMesh: any;
|
|
8630
|
+
currentMapWrapperBoxHelper: any;
|
|
8631
|
+
viewportMesh: any;
|
|
8632
|
+
stackContainerMesh: any;
|
|
8268
8633
|
currentMinTilt: number;
|
|
8269
|
-
constructor(maps: MappedinMap[], core: ICore);
|
|
8634
|
+
constructor(maps: MappedinMap[], core: ICore, mapLabels?: boolean);
|
|
8270
8635
|
lockControls(): void;
|
|
8271
8636
|
unlockControls(): void;
|
|
8272
8637
|
createStackBoundingBox(): void;
|
|
@@ -8293,7 +8658,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8293
8658
|
}
|
|
8294
8659
|
|
|
8295
8660
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.Element' {
|
|
8296
|
-
import { MeshLambertMaterial, Mesh, ExtrudeGeometry, Group } from 'three';
|
|
8661
|
+
import { MeshLambertMaterial, Mesh, ExtrudeGeometry, Vector3, Texture, Group } from 'three';
|
|
8297
8662
|
import { PubSub } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/pub-sub';
|
|
8298
8663
|
import { AssetManager, MappedinMap, MappedinPolygon } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
8299
8664
|
import { MAP_RENDER_MODE } from '@mappedin/mappedin-js/packages/legacy-renderer/MapView.enums';
|
|
@@ -8304,29 +8669,25 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
8304
8669
|
visible: boolean;
|
|
8305
8670
|
mode: MAP_RENDER_MODE;
|
|
8306
8671
|
static defaultMaterial: MeshLambertMaterial;
|
|
8307
|
-
static hoverMeshMaterial:
|
|
8672
|
+
static hoverMeshMaterial: MeshLambertMaterial;
|
|
8308
8673
|
assetManager: AssetManager;
|
|
8309
8674
|
imageVisible: boolean;
|
|
8310
8675
|
labelVisible: boolean;
|
|
8311
|
-
boundingBox: {
|
|
8312
|
-
min: {
|
|
8313
|
-
x: number;
|
|
8314
|
-
y: number;
|
|
8315
|
-
z: number;
|
|
8316
|
-
};
|
|
8317
|
-
max: {
|
|
8318
|
-
x: number;
|
|
8319
|
-
y: number;
|
|
8320
|
-
z: number;
|
|
8321
|
-
};
|
|
8322
|
-
};
|
|
8323
8676
|
polygonHeight: number;
|
|
8324
8677
|
geometry: ExtrudeGeometry;
|
|
8325
8678
|
mesh: Mesh;
|
|
8326
8679
|
material: MeshLambertMaterial | MeshLambertMaterial[];
|
|
8327
8680
|
labelMesh?: Mesh;
|
|
8328
8681
|
imageMesh?: Mesh;
|
|
8682
|
+
/**
|
|
8683
|
+
* For the time being we indicate inflated walls so they don't add to ray casting. Since these are walls it's a good optimization
|
|
8684
|
+
*/
|
|
8685
|
+
isInflated: boolean;
|
|
8329
8686
|
sortScore: number | null;
|
|
8687
|
+
boundingBox?: {
|
|
8688
|
+
min: Vector3;
|
|
8689
|
+
max: Vector3;
|
|
8690
|
+
};
|
|
8330
8691
|
static materials: {
|
|
8331
8692
|
[key in string]: MeshLambertMaterial | MeshLambertMaterial[];
|
|
8332
8693
|
};
|
|
@@ -8342,20 +8703,13 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
8342
8703
|
x: number;
|
|
8343
8704
|
y: number;
|
|
8344
8705
|
};
|
|
8345
|
-
static _makeFromCoords(className: any, coords: any, mapClass: any): any;
|
|
8706
|
+
static _makeFromCoords(className: any, coords: any, mapClass: any, element: any): any;
|
|
8707
|
+
static _inflate(coords: any, width: any): any;
|
|
8346
8708
|
static _setPolygonDefaults(poly: any): any;
|
|
8347
8709
|
constructor(poly: MappedinPolygon, mapClass: MappedinMap, container: Group, assetManager: any, mapLoadingStrategy?: MAP_RENDER_MODE);
|
|
8348
8710
|
getBoundingBox(): {
|
|
8349
|
-
min:
|
|
8350
|
-
|
|
8351
|
-
y: number;
|
|
8352
|
-
z: number;
|
|
8353
|
-
};
|
|
8354
|
-
max: {
|
|
8355
|
-
x: number;
|
|
8356
|
-
y: number;
|
|
8357
|
-
z: number;
|
|
8358
|
-
};
|
|
8711
|
+
min: Vector3;
|
|
8712
|
+
max: Vector3;
|
|
8359
8713
|
};
|
|
8360
8714
|
load(): Promise<this>;
|
|
8361
8715
|
_addLabel(poly: MappedinPolygon, mapClass: MappedinMap): void;
|
|
@@ -8427,7 +8781,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8427
8781
|
}
|
|
8428
8782
|
|
|
8429
8783
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-manager/dynamic-focus-scene-manager/dynamic-focus-scene' {
|
|
8430
|
-
import { Object3D
|
|
8784
|
+
import { Object3D } from 'three';
|
|
8431
8785
|
import { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
8432
8786
|
import type { ICore, MapObject } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
8433
8787
|
import { Building } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
@@ -8435,10 +8789,10 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8435
8789
|
class DynamicFocusScene {
|
|
8436
8790
|
buildings: Building[];
|
|
8437
8791
|
object: Object3D;
|
|
8438
|
-
panBounds:
|
|
8792
|
+
panBounds: any;
|
|
8439
8793
|
loaded: boolean;
|
|
8440
8794
|
baseMapObject: MapObject;
|
|
8441
|
-
raycasters:
|
|
8795
|
+
raycasters: any;
|
|
8442
8796
|
baseMap: MappedinMap;
|
|
8443
8797
|
options: {
|
|
8444
8798
|
indoorsFullyVisibleZoomLevel: number;
|
|
@@ -8473,6 +8827,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
8473
8827
|
}
|
|
8474
8828
|
|
|
8475
8829
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/PathsController' {
|
|
8830
|
+
import { Group } from 'three';
|
|
8476
8831
|
import { MappedinNode, MappedinCoordinate } from '@mappedin/mappedin-js/packages/get-venue';
|
|
8477
8832
|
import type { ICore, TPathOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
8478
8833
|
import { ANIMATION_TWEENS } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
@@ -8553,7 +8908,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
8553
8908
|
path: Path;
|
|
8554
8909
|
internalPath: InternalPath;
|
|
8555
8910
|
}>;
|
|
8556
|
-
connectionsPathMeshes:
|
|
8911
|
+
connectionsPathMeshes: Group<import("three").Object3DEventMap>;
|
|
8557
8912
|
getPathLength(path: any): number;
|
|
8558
8913
|
/**
|
|
8559
8914
|
* Draws path in 3D space
|
|
@@ -8674,8 +9029,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
8674
9029
|
}
|
|
8675
9030
|
|
|
8676
9031
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/FlatLabelsController' {
|
|
8677
|
-
import { TAddFlatLabelOptions, TFlatLabelAllLocationsOptions, TFlatLabelAppearance, ICore } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
8678
|
-
import { FlatLabel } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
9032
|
+
import { TAddFlatLabelOptions, TFlatLabelAllLocationsOptions, TFlatLabelAppearance, ICore, FlatLabel } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
8679
9033
|
import { MappedinPolygon } from '@mappedin/mappedin-js/packages/get-venue';
|
|
8680
9034
|
export const LABEL_ALL_LOCATIONS_WARNING = "Adding or removing individual labels after calling labelAllLocations() may cause unexpected behaviour. We recommend adding all labels individually if more specific control is desired. https://developer.mappedin.com/web-sdk-api/v5/latest/classes/flatlabels#add";
|
|
8681
9035
|
export type FlatLabelRenderObject = TAddFlatLabelOptions & {
|
|
@@ -8940,15 +9294,15 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/blue-dot
|
|
|
8940
9294
|
}): void;
|
|
8941
9295
|
blueDots: {
|
|
8942
9296
|
handle: any;
|
|
8943
|
-
radius:
|
|
8944
|
-
dotObject:
|
|
8945
|
-
bearing: any
|
|
9297
|
+
radius: import("three").Mesh<import("three").CylinderGeometry, import("three").MeshBasicMaterial, import("three").Object3DEventMap> | undefined;
|
|
9298
|
+
dotObject: import("three").Object3D<import("three").Object3DEventMap>;
|
|
9299
|
+
bearing: import("three").Mesh<import("three").ExtrudeGeometry, any, import("three").Object3DEventMap>;
|
|
8946
9300
|
}[] | undefined;
|
|
8947
9301
|
positionTween: any;
|
|
8948
9302
|
currentPositionLatLon: any;
|
|
8949
9303
|
animateBearing(fromBearing: any, toBearing: any): void;
|
|
8950
9304
|
setBearing(bearing: any): void;
|
|
8951
|
-
getBlueDotForMap(mapOrMapId: any):
|
|
9305
|
+
getBlueDotForMap(mapOrMapId: any): import("three").Object3D<import("three").Object3DEventMap> | undefined;
|
|
8952
9306
|
/**
|
|
8953
9307
|
* Remove the 3D blue dot from the maps.
|
|
8954
9308
|
*
|
|
@@ -9124,73 +9478,76 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
9124
9478
|
import type { ICore, MappedinPolygon, Collider } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
9125
9479
|
import { BlueDotManager, Path } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
9126
9480
|
class EventSystem {
|
|
9127
|
-
|
|
9128
|
-
|
|
9129
|
-
|
|
9130
|
-
|
|
9131
|
-
|
|
9132
|
-
|
|
9133
|
-
|
|
9134
|
-
|
|
9135
|
-
|
|
9136
|
-
|
|
9137
|
-
|
|
9138
|
-
|
|
9139
|
-
|
|
9140
|
-
|
|
9141
|
-
|
|
9142
|
-
|
|
9143
|
-
|
|
9144
|
-
|
|
9145
|
-
|
|
9146
|
-
|
|
9147
|
-
|
|
9148
|
-
|
|
9149
|
-
|
|
9150
|
-
|
|
9151
|
-
|
|
9152
|
-
|
|
9153
|
-
|
|
9154
|
-
|
|
9155
|
-
|
|
9156
|
-
|
|
9157
|
-
|
|
9158
|
-
|
|
9159
|
-
|
|
9160
|
-
|
|
9161
|
-
|
|
9162
|
-
|
|
9163
|
-
|
|
9164
|
-
|
|
9165
|
-
|
|
9166
|
-
|
|
9167
|
-
|
|
9168
|
-
|
|
9169
|
-
|
|
9170
|
-
|
|
9171
|
-
|
|
9172
|
-
|
|
9173
|
-
|
|
9174
|
-
|
|
9175
|
-
|
|
9176
|
-
|
|
9177
|
-
|
|
9178
|
-
|
|
9179
|
-
|
|
9180
|
-
|
|
9181
|
-
|
|
9182
|
-
|
|
9183
|
-
|
|
9184
|
-
|
|
9185
|
-
|
|
9186
|
-
|
|
9187
|
-
|
|
9188
|
-
|
|
9189
|
-
|
|
9190
|
-
|
|
9191
|
-
|
|
9192
|
-
|
|
9193
|
-
|
|
9481
|
+
core: ICore;
|
|
9482
|
+
blueDotManager?: BlueDotManager;
|
|
9483
|
+
rendererDomElement: any;
|
|
9484
|
+
currentHover: string | null;
|
|
9485
|
+
hoverLabel: any;
|
|
9486
|
+
hoverColor: Color;
|
|
9487
|
+
options: {
|
|
9488
|
+
disableHover: boolean;
|
|
9489
|
+
};
|
|
9490
|
+
constructor(core: ICore);
|
|
9491
|
+
setBlueDotManager: (blueDotManager: any) => void;
|
|
9492
|
+
touchCount: number;
|
|
9493
|
+
zoomOut(): void;
|
|
9494
|
+
zoomIn(event: any): void;
|
|
9495
|
+
onPointerMove: (event: any) => void;
|
|
9496
|
+
onPointerUp: (event: any) => void;
|
|
9497
|
+
/**
|
|
9498
|
+
* We've confirmed that a map click has occured, so handle that here
|
|
9499
|
+
*/
|
|
9500
|
+
handleMapClick(event: any): void;
|
|
9501
|
+
onPointerDown: (event: any) => void;
|
|
9502
|
+
incrementTouches: (event: any) => void;
|
|
9503
|
+
decrementTouches: (event: any) => void;
|
|
9504
|
+
clearMouse: () => void;
|
|
9505
|
+
getMousePos: (event: any) => {
|
|
9506
|
+
x: any;
|
|
9507
|
+
y: any;
|
|
9508
|
+
};
|
|
9509
|
+
getScaledMousePos: (event: any) => {
|
|
9510
|
+
x: number;
|
|
9511
|
+
y: number;
|
|
9512
|
+
};
|
|
9513
|
+
cursorPos: {
|
|
9514
|
+
x: number;
|
|
9515
|
+
y: number;
|
|
9516
|
+
};
|
|
9517
|
+
mouse: {
|
|
9518
|
+
x: number;
|
|
9519
|
+
y: number;
|
|
9520
|
+
};
|
|
9521
|
+
mouseDownStart: {
|
|
9522
|
+
time: number;
|
|
9523
|
+
clientX: number;
|
|
9524
|
+
clientY: number;
|
|
9525
|
+
};
|
|
9526
|
+
scaledCursorPos: {
|
|
9527
|
+
x: number;
|
|
9528
|
+
y: number;
|
|
9529
|
+
};
|
|
9530
|
+
hasTouched: boolean;
|
|
9531
|
+
calculateMouseCoordinates: (event: any) => void;
|
|
9532
|
+
getMouseRayIntersects: (objects: Object3D | Object3D[]) => import("three").Intersection<Object3D<import("three").Object3DEventMap>>[];
|
|
9533
|
+
detectCollidersUnderMouse: () => Collider[];
|
|
9534
|
+
detectPolygonsUnderMouse: () => string[];
|
|
9535
|
+
detectPathsUnderMouse: () => Path[];
|
|
9536
|
+
detectWatermarkUnderMouse: () => boolean;
|
|
9537
|
+
detectMapsUnderMouse: () => (import("../../internal").MappedinMap | null)[];
|
|
9538
|
+
/**
|
|
9539
|
+
* Gets mouse click position in x y map coordinates
|
|
9540
|
+
*/
|
|
9541
|
+
getMouseMapPosition: () => {
|
|
9542
|
+
x: number;
|
|
9543
|
+
y: number;
|
|
9544
|
+
};
|
|
9545
|
+
checkMouseIntersectsBlueDot: () => boolean;
|
|
9546
|
+
doHoverEffect: () => void;
|
|
9547
|
+
onPolygonHoverOut: (polygonId: string) => false | undefined;
|
|
9548
|
+
onPolygonHoverOver: (polygon: MappedinPolygon | string) => false | undefined;
|
|
9549
|
+
setHoverColor: (color: string) => void;
|
|
9550
|
+
destroy(): void;
|
|
9194
9551
|
}
|
|
9195
9552
|
export default EventSystem;
|
|
9196
9553
|
}
|
|
@@ -9206,7 +9563,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9206
9563
|
scene: any;
|
|
9207
9564
|
getPolygonMeshFromId: any;
|
|
9208
9565
|
tryRendering: any;
|
|
9209
|
-
stencilSheet:
|
|
9566
|
+
stencilSheet: Mesh<PlaneGeometry, ShaderMaterial, import("three").Object3DEventMap> | null;
|
|
9210
9567
|
polygonsMarkedAsClosed: {};
|
|
9211
9568
|
onMapChanged(map: any): void;
|
|
9212
9569
|
currentMap: any;
|
|
@@ -9215,17 +9572,20 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9215
9572
|
markPolygonAsOpen(polygonId: any): void;
|
|
9216
9573
|
markAllPolygonsAsOpen(): void;
|
|
9217
9574
|
}
|
|
9575
|
+
import { PlaneGeometry } from 'three';
|
|
9576
|
+
import { ShaderMaterial } from 'three';
|
|
9577
|
+
import { Mesh } from 'three';
|
|
9218
9578
|
}
|
|
9219
9579
|
|
|
9220
9580
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.BinaryAssetManager' {
|
|
9221
|
-
import { Texture } from 'three';
|
|
9581
|
+
import { Texture, TextureLoader } from 'three';
|
|
9222
9582
|
/**
|
|
9223
9583
|
* This asset manager is used when loading a venue from MVF.
|
|
9224
9584
|
* It requires the MVF's image and model binaries to be passed in upon instantiation.
|
|
9225
9585
|
* This allows delaying the creation of Blobs and Object URLs until loading the map.
|
|
9226
9586
|
*/
|
|
9227
9587
|
export default class BinaryAssetManager {
|
|
9228
|
-
textureLoader:
|
|
9588
|
+
textureLoader: TextureLoader;
|
|
9229
9589
|
data: Map<string, Uint8Array>;
|
|
9230
9590
|
constructor(data: Map<string, Uint8Array>);
|
|
9231
9591
|
/**
|
|
@@ -9327,12 +9687,14 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
9327
9687
|
import { MappedinDirections, MappedinMap, MappedinNode } from '@mappedin/mappedin-js/packages/get-venue';
|
|
9328
9688
|
import { STACKED_MAPS_STATE, MapViewScene, MapViewStackScene, CAMERA_EASING_MODE } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
9329
9689
|
import type { ICore, TCameraTransform } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
9690
|
+
import { TStackedMapsOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types';
|
|
9330
9691
|
enum ACTION {
|
|
9331
9692
|
enable = "enable",
|
|
9332
9693
|
disable = "disable",
|
|
9333
9694
|
showOverview = "showOverview",
|
|
9334
9695
|
zoomInToMap = "zoomInToMap",
|
|
9335
|
-
scrollToMap = "scrollToMap"
|
|
9696
|
+
scrollToMap = "scrollToMap",
|
|
9697
|
+
restack = "restack"
|
|
9336
9698
|
}
|
|
9337
9699
|
type TTargetTransitionFunction = ((options: TParams) => () => Promise<void>) | ((options: TParams) => void);
|
|
9338
9700
|
type TParams = {
|
|
@@ -9369,16 +9731,13 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
9369
9731
|
};
|
|
9370
9732
|
class StackedMapsController {
|
|
9371
9733
|
#private;
|
|
9372
|
-
options:
|
|
9373
|
-
verticalDistanceBetweenMaps?: number;
|
|
9374
|
-
};
|
|
9734
|
+
options: TStackedMapsOptions;
|
|
9375
9735
|
enabled: boolean;
|
|
9376
9736
|
stackScene: MapViewStackScene;
|
|
9377
|
-
directions: MappedinDirections | MappedinDirections[];
|
|
9378
9737
|
constructor(core: ICore);
|
|
9379
9738
|
needsUpdate: boolean;
|
|
9380
9739
|
currentState: STACKED_MAPS_STATE;
|
|
9381
|
-
|
|
9740
|
+
mapsInStack: MappedinMap[];
|
|
9382
9741
|
getZoomIntoMapOptions: (params: TParams) => (MapViewScene | {
|
|
9383
9742
|
activeMap: MappedinMap;
|
|
9384
9743
|
focusOn: {
|
|
@@ -9419,22 +9778,33 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
9419
9778
|
};
|
|
9420
9779
|
activeMap: MappedinMap;
|
|
9421
9780
|
})[] | undefined;
|
|
9422
|
-
|
|
9781
|
+
getRestackOptions: (params: TParams) => (MapViewStackScene | {
|
|
9782
|
+
activeMap: MappedinMap;
|
|
9783
|
+
focusOn: {
|
|
9784
|
+
options: {
|
|
9785
|
+
tilt: number;
|
|
9786
|
+
duration: number;
|
|
9787
|
+
};
|
|
9788
|
+
};
|
|
9789
|
+
verticalDistanceBetweenMaps: number | undefined;
|
|
9790
|
+
})[] | undefined;
|
|
9791
|
+
getEnableOptions: () => void;
|
|
9423
9792
|
getShowOverviewTransition: (options: any, inTransit?: boolean) => () => Promise<void>;
|
|
9424
9793
|
getZoomInToMapTransition: (options: any) => () => Promise<void>;
|
|
9425
9794
|
getScrollToMapTransition: (options: any, inTransit?: boolean) => () => Promise<void>;
|
|
9795
|
+
getRestackTransition: (options: any, inTransit?: boolean) => () => Promise<void>;
|
|
9426
9796
|
getDisableTransition: (options: any) => () => Promise<void>;
|
|
9427
9797
|
getEnableTransition: () => () => void;
|
|
9428
9798
|
states: TState;
|
|
9799
|
+
get determineMapStack(): MappedinMap[];
|
|
9429
9800
|
transition(currentState: STACKED_MAPS_STATE, actionName: ACTION): TTargetTransitionFunction[] | void;
|
|
9430
9801
|
exec(transitions: TTargetTransitionFunction[] | void, params: TParams): Promise<void>;
|
|
9431
9802
|
disable: () => Promise<void>;
|
|
9432
|
-
enable: (opts?:
|
|
9433
|
-
|
|
9434
|
-
}) => Promise<void>;
|
|
9435
|
-
get nodesInJourney(): MappedinNode[];
|
|
9803
|
+
enable: (opts?: TStackedMapsOptions) => Promise<void>;
|
|
9804
|
+
get nodesInJourneyOrMap(): any[];
|
|
9436
9805
|
showOverview: () => Promise<void>;
|
|
9437
9806
|
scrollToMap: (map: MappedinMap) => Promise<void>;
|
|
9807
|
+
restack: (options?: TStackedMapsOptions) => Promise<void>;
|
|
9438
9808
|
zoomInToMap: (map: MappedinMap, cameraTransform?: TCameraTransform) => Promise<void>;
|
|
9439
9809
|
get currentMap(): MappedinMap;
|
|
9440
9810
|
}
|
|
@@ -9479,9 +9849,9 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9479
9849
|
onWebGLContextCreationError: any;
|
|
9480
9850
|
onWebGLContextLost: any;
|
|
9481
9851
|
onWebGLContextRestored: any;
|
|
9482
|
-
webGLContextCreationErrorListener:
|
|
9483
|
-
webGLContextLostListener:
|
|
9484
|
-
webGLContextRestoredListener:
|
|
9852
|
+
webGLContextCreationErrorListener: void;
|
|
9853
|
+
webGLContextLostListener: void;
|
|
9854
|
+
webGLContextRestoredListener: void;
|
|
9485
9855
|
shouldConsiderAlpha: any;
|
|
9486
9856
|
antialias: any;
|
|
9487
9857
|
/**
|
|
@@ -9540,7 +9910,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9540
9910
|
* @param height {number}
|
|
9541
9911
|
*/
|
|
9542
9912
|
setBufferSize(width: number, height: number): void;
|
|
9543
|
-
get backgroundColor():
|
|
9913
|
+
get backgroundColor(): Color | undefined;
|
|
9544
9914
|
get backgroundAlpha(): number | undefined;
|
|
9545
9915
|
/**
|
|
9546
9916
|
* Set the color and opacity that will be drawn behind the scene.
|
|
@@ -9558,7 +9928,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9558
9928
|
* @param {MapboxOutdoorContext} mapboxOutdoorContext context to draw
|
|
9559
9929
|
*/
|
|
9560
9930
|
setMapboxOutdoorContext(mapboxOutdoorContext: MapboxOutdoorContext): void;
|
|
9561
|
-
domElement():
|
|
9931
|
+
domElement(): HTMLCanvasElement;
|
|
9562
9932
|
isAvailable(): boolean;
|
|
9563
9933
|
disposeOfRenderLists(): void;
|
|
9564
9934
|
reportWebGlContextCreationError(e: any): void;
|
|
@@ -9600,9 +9970,9 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9600
9970
|
constructor(renderOptions: any, targetWebGLVersion?: number);
|
|
9601
9971
|
options: any;
|
|
9602
9972
|
core: any;
|
|
9603
|
-
renderer:
|
|
9973
|
+
renderer: WebGLRenderer | undefined;
|
|
9604
9974
|
effectComposer: EffectComposer | undefined;
|
|
9605
|
-
backgroundColor:
|
|
9975
|
+
backgroundColor: Color;
|
|
9606
9976
|
backgroundAlpha: number;
|
|
9607
9977
|
mapboxOutdoorContext: any;
|
|
9608
9978
|
/**
|
|
@@ -9666,19 +10036,19 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9666
10036
|
effectComposer: null;
|
|
9667
10037
|
outdoorsVisible: boolean;
|
|
9668
10038
|
options: any;
|
|
9669
|
-
renderer:
|
|
10039
|
+
renderer: WebGLRenderer | undefined;
|
|
9670
10040
|
core: any;
|
|
9671
10041
|
journeyOpacity: number | undefined;
|
|
9672
|
-
backgroundColor:
|
|
10042
|
+
backgroundColor: Color | undefined;
|
|
9673
10043
|
backgroundAlpha: number | undefined;
|
|
9674
10044
|
mapboxOutdoorContext: any;
|
|
9675
|
-
staticSceneRenderTarget:
|
|
9676
|
-
animatedSceneRenderTarget:
|
|
9677
|
-
alwaysOnTopSceneRenderTarget:
|
|
9678
|
-
outdoorViewRenderTarget:
|
|
10045
|
+
staticSceneRenderTarget: WebGLRenderTarget<Texture> | undefined;
|
|
10046
|
+
animatedSceneRenderTarget: WebGLRenderTarget<Texture> | undefined;
|
|
10047
|
+
alwaysOnTopSceneRenderTarget: WebGLRenderTarget<Texture> | undefined;
|
|
10048
|
+
outdoorViewRenderTarget: WebGLRenderTarget<Texture> | undefined;
|
|
9679
10049
|
populateRenderTarget(renderTarget: any): void;
|
|
9680
10050
|
createOutdoorViewTexture(): void;
|
|
9681
|
-
outdoorViewTexture:
|
|
10051
|
+
outdoorViewTexture: Texture | undefined;
|
|
9682
10052
|
outdoorViewTextureProps: any;
|
|
9683
10053
|
setupEffectComposer(): void;
|
|
9684
10054
|
setOutdoorViewTexture(texture: any): void;
|
|
@@ -9755,7 +10125,14 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9755
10125
|
toggleOutdoorViewVisiblity(visible: any): void;
|
|
9756
10126
|
}
|
|
9757
10127
|
import { RENDER } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
10128
|
+
import { Scene } from 'three';
|
|
10129
|
+
import { Camera } from 'three';
|
|
10130
|
+
import { Vector2 } from 'three';
|
|
10131
|
+
import { Texture } from 'three';
|
|
10132
|
+
import { Color } from 'three';
|
|
10133
|
+
import { WebGLRenderer } from 'three';
|
|
9758
10134
|
import { EffectComposer } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.EffectComposer';
|
|
10135
|
+
import { WebGLRenderTarget } from 'three';
|
|
9759
10136
|
export {};
|
|
9760
10137
|
}
|
|
9761
10138
|
|
|
@@ -9801,45 +10178,97 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
9801
10178
|
import './OutdoorViewController.scss';
|
|
9802
10179
|
import type { ICore } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
9803
10180
|
import { XOR } from '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types';
|
|
10181
|
+
/**
|
|
10182
|
+
* Represents the possible positions for map attribution.
|
|
10183
|
+
*/
|
|
9804
10184
|
export type TAttributionPosition = 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
9805
|
-
|
|
9806
|
-
|
|
9807
|
-
|
|
9808
|
-
|
|
9809
|
-
|
|
9810
|
-
|
|
9811
|
-
|
|
10185
|
+
/**
|
|
10186
|
+
* Defines the options for an Outdoor View when initialized with headers for authentication.
|
|
10187
|
+
*/
|
|
10188
|
+
export type TOutdoorViewOptionsWithHeaders = {
|
|
10189
|
+
/**
|
|
10190
|
+
* The URL to the map style file.
|
|
10191
|
+
* @see https://github.com/maplibre/maplibre-style-spec/
|
|
10192
|
+
*/
|
|
10193
|
+
url?: string;
|
|
10194
|
+
/**
|
|
10195
|
+
* The position on the map where the attribution should be displayed.
|
|
10196
|
+
* @default 'bottom-right'
|
|
10197
|
+
*/
|
|
10198
|
+
attributionPosition?: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
10199
|
+
/**
|
|
10200
|
+
* Custom text or an array of texts to be used for the map attribution.
|
|
10201
|
+
*/
|
|
10202
|
+
customAttribution?: string | string[];
|
|
10203
|
+
/**
|
|
10204
|
+
* An object containing HTTP headers for authentication purposes.
|
|
10205
|
+
* */
|
|
10206
|
+
headers: {
|
|
10207
|
+
[key: string]: string | null;
|
|
10208
|
+
};
|
|
9812
10209
|
};
|
|
9813
|
-
|
|
9814
|
-
|
|
9815
|
-
|
|
9816
|
-
|
|
9817
|
-
|
|
10210
|
+
/**
|
|
10211
|
+
* Defines the options for an Outdoor View when initialized with a URL for authentication.
|
|
10212
|
+
*/
|
|
10213
|
+
export type TOutdoorViewOptionsWithAuthURL = {
|
|
10214
|
+
/**
|
|
10215
|
+
* The URL to the map style file.
|
|
10216
|
+
* @see https://github.com/maplibre/maplibre-style-spec/
|
|
10217
|
+
*/
|
|
10218
|
+
url?: string;
|
|
10219
|
+
/**
|
|
10220
|
+
* The URL to obtain an authentication token.
|
|
10221
|
+
*/
|
|
10222
|
+
authURL?: string;
|
|
10223
|
+
/**
|
|
10224
|
+
* Custom text or an array of texts to be used for the map attribution.
|
|
10225
|
+
*/
|
|
10226
|
+
customAttribution?: string | string[];
|
|
10227
|
+
/**
|
|
10228
|
+
* The position on the map where the attribution should be displayed.
|
|
10229
|
+
* @default 'bottom-right'
|
|
10230
|
+
*/
|
|
10231
|
+
attributionPosition?: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
9818
10232
|
};
|
|
9819
|
-
|
|
10233
|
+
/**
|
|
10234
|
+
* Defines the options for initializing an Outdoor View.
|
|
10235
|
+
* This is a union type that requires exclusive or logic,
|
|
10236
|
+
* ensuring that an instance can either have headers or
|
|
10237
|
+
* an authentication URL, but not both.
|
|
10238
|
+
*
|
|
10239
|
+
* Note: It isn't permitted to use `.headers` and `.authURL` options simultaneously.
|
|
10240
|
+
*
|
|
10241
|
+
* @property {string} [url] - The URL to the map style file.
|
|
10242
|
+
* @property {TAttributionPosition} [attributionPosition='bottom-right'] - The position on the map where the attribution should be displayed.
|
|
10243
|
+
* @property {string | string[]} [customAttribution] - Custom text or an array of texts to be used for the map attribution.
|
|
10244
|
+
* @property {Object.<string, string | null>} [headers] - An object containing HTTP headers for authentication purposes. It isn't permitted to use `.headers` and `.authURL` options simultaneously.
|
|
10245
|
+
* @property {string} [authURL] - The URL to obtain an authentication token. It isn't permitted to use `.headers` and `.authURL` options simultaneously.
|
|
10246
|
+
* @interface
|
|
10247
|
+
*/
|
|
10248
|
+
export type TOutdoorViewOptions = XOR<TOutdoorViewOptionsWithHeaders, TOutdoorViewOptionsWithAuthURL>;
|
|
9820
10249
|
class OutdoorViewController {
|
|
9821
|
-
|
|
9822
|
-
|
|
9823
|
-
|
|
9824
|
-
|
|
9825
|
-
|
|
9826
|
-
|
|
9827
|
-
|
|
9828
|
-
|
|
9829
|
-
|
|
9830
|
-
|
|
9831
|
-
|
|
9832
|
-
|
|
9833
|
-
|
|
9834
|
-
|
|
9835
|
-
|
|
9836
|
-
|
|
9837
|
-
|
|
9838
|
-
|
|
9839
|
-
|
|
9840
|
-
|
|
9841
|
-
|
|
9842
|
-
|
|
10250
|
+
_attribution: any;
|
|
10251
|
+
core: ICore;
|
|
10252
|
+
map: any;
|
|
10253
|
+
enabled: boolean;
|
|
10254
|
+
hidden: boolean;
|
|
10255
|
+
url: string;
|
|
10256
|
+
authURL: string;
|
|
10257
|
+
headers?: TOutdoorViewOptions['headers'];
|
|
10258
|
+
customAttribution?: string | string[];
|
|
10259
|
+
attributionPosition?: TAttributionPosition;
|
|
10260
|
+
loaded: boolean;
|
|
10261
|
+
constructor(core: ICore, options?: TOutdoorViewOptions);
|
|
10262
|
+
module: any;
|
|
10263
|
+
load(): Promise<void>;
|
|
10264
|
+
get attributions(): any;
|
|
10265
|
+
hide(): void;
|
|
10266
|
+
show(): void;
|
|
10267
|
+
resize(): void;
|
|
10268
|
+
getRequestHeaders: () => Promise<TOutdoorViewOptions['headers']>;
|
|
10269
|
+
render(): void;
|
|
10270
|
+
setStyle(style: any): void;
|
|
10271
|
+
setAttributionPosition(position: TAttributionPosition): void;
|
|
9843
10272
|
}
|
|
9844
10273
|
export default OutdoorViewController;
|
|
9845
10274
|
}
|
|
@@ -9867,7 +10296,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
9867
10296
|
/**
|
|
9868
10297
|
* Exports the current scene as a GLTF file.
|
|
9869
10298
|
*/
|
|
9870
|
-
getCurrentSceneGLTF(userOptions: TGLTFExportOptions)
|
|
10299
|
+
getCurrentSceneGLTF: (userOptions: TGLTFExportOptions) => Promise<Blob>;
|
|
9871
10300
|
}
|
|
9872
10301
|
}
|
|
9873
10302
|
|
|
@@ -9891,6 +10320,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/controlle
|
|
|
9891
10320
|
*/
|
|
9892
10321
|
getVisibleLayersForLoadedMap(map: MappedinMap): string[] | undefined;
|
|
9893
10322
|
addGeoJSONLayer(layerName: string, featureOrFeatureCollection: Feature<Polygon, GeoJsonProperties | null> | FeatureCollection<Polygon, GeoJsonProperties | null>): Promise<void>;
|
|
10323
|
+
removeGeoJSONLayer(layerName: string): Promise<void>;
|
|
9894
10324
|
}
|
|
9895
10325
|
export default LayerController;
|
|
9896
10326
|
}
|
|
@@ -9970,7 +10400,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9970
10400
|
map: MappedinMap | null;
|
|
9971
10401
|
bearing: any;
|
|
9972
10402
|
nearestNode: any;
|
|
9973
|
-
|
|
10403
|
+
hasEverReceivedFloorLevel: boolean;
|
|
9974
10404
|
};
|
|
9975
10405
|
export interface IBlueDotCore extends IPubSub {
|
|
9976
10406
|
positionUpdater: IPositionUpdater | null;
|
|
@@ -9986,6 +10416,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
9986
10416
|
Whether blue dot should be allowed with missing floor level information.
|
|
9987
10417
|
*/
|
|
9988
10418
|
forceBlueDot: boolean;
|
|
10419
|
+
/** Whether we have received floorLevel data and are on a floorLevel supported device */
|
|
10420
|
+
hasEverReceivedFloorLevel: boolean;
|
|
9989
10421
|
/**
|
|
9990
10422
|
The state machine for the current state of the blue dot.
|
|
9991
10423
|
*/
|
|
@@ -10096,158 +10528,9 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
10096
10528
|
}
|
|
10097
10529
|
|
|
10098
10530
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/utils' {
|
|
10099
|
-
|
|
10100
|
-
|
|
10101
|
-
|
|
10102
|
-
/**
|
|
10103
|
-
* Utils function listing
|
|
10104
|
-
*
|
|
10105
|
-
* - scrubMaterial
|
|
10106
|
-
* - getObjectID
|
|
10107
|
-
* - getObject
|
|
10108
|
-
* - getBoundingBox
|
|
10109
|
-
* - getBiggestBoundingBox
|
|
10110
|
-
* - upackBoundingBox
|
|
10111
|
-
* - getMapScale
|
|
10112
|
-
* - throttle -> taken from lodash.js
|
|
10113
|
-
* - getProjectionScaleFactor
|
|
10114
|
-
* - getZoom
|
|
10115
|
-
*/
|
|
10116
|
-
export function isGatewayKey(key: string): boolean;
|
|
10117
|
-
export function getCombinedBoundingBox(objects: Object3D[]): Box3;
|
|
10118
|
-
export function getMapsBoundingBox(maps: MapObject[], mapPadding: number): Box3;
|
|
10119
|
-
export function scrubMaterial(material: Material): void;
|
|
10120
|
-
/**
|
|
10121
|
-
* Takes a Mappedin Object or id and returns the ID, so our functions can take bottomRight
|
|
10122
|
-
* @template T extends string | {id: string}
|
|
10123
|
-
* @param {T} object - input can be object containing id or the id itself
|
|
10124
|
-
* @return {string}
|
|
10125
|
-
*/
|
|
10126
|
-
export function getObjectId(object: any): string;
|
|
10127
|
-
/**
|
|
10128
|
-
* Takes a Mappedin object or ID and the array to look in and retuns the Object, so our functions can take both
|
|
10129
|
-
*/
|
|
10130
|
-
export function getObject<K extends {
|
|
10131
|
-
id: string;
|
|
10132
|
-
}, T extends K | string>(obj: T, array: K[] | undefined): K | undefined;
|
|
10133
|
-
export function getBoundingBox(object: Object3D): Box3;
|
|
10134
|
-
/**
|
|
10135
|
-
* Function pushes the items of the second array onto the first array (inplace).
|
|
10136
|
-
* @template T
|
|
10137
|
-
* @param {Array.<T>} arr1 - base array
|
|
10138
|
-
* @param {Array.<T>} arr2 - array which items will be pushed to arr1
|
|
10139
|
-
*/
|
|
10140
|
-
export function appendItems<T>(arr1: T[], arr2: T[]): void;
|
|
10141
|
-
export function getBiggestBoundingBox(objects: Object3D[]): {
|
|
10142
|
-
min: any;
|
|
10143
|
-
max: any;
|
|
10144
|
-
};
|
|
10145
|
-
export function unpackBoundingBox(boundingBox: Box3): Vector3[];
|
|
10146
|
-
export function getMapScale(map: MappedinMap): number;
|
|
10147
|
-
export function getNorth(map: MappedinMap): number;
|
|
10148
|
-
export function throttle<T>(func: () => void, wait: number, options?: any): () => void;
|
|
10149
|
-
export function debounce<T>(func: () => void, wait: number, immediate?: boolean): () => void;
|
|
10150
|
-
export function flatten(list: any[]): any[];
|
|
10151
|
-
export function uniq(arr: any[]): any[];
|
|
10152
|
-
export function toStyleString(styles: Record<string, string>): string;
|
|
10153
|
-
/**
|
|
10154
|
-
/* getProjectionScaleFactor()
|
|
10155
|
-
/* finds the scale ratio between screen coordinates and 3D coordinates (in X-Z plane)
|
|
10156
|
-
/*
|
|
10157
|
-
* R
|
|
10158
|
-
* /|
|
|
10159
|
-
* C : Camera / |
|
|
10160
|
-
* PQ : Projection Plane / |
|
|
10161
|
-
* OR : Origin / |
|
|
10162
|
-
* F : FOV / |
|
|
10163
|
-
* Q / |
|
|
10164
|
-
* /| |
|
|
10165
|
-
* / | |
|
|
10166
|
-
* / | |
|
|
10167
|
-
* / | |
|
|
10168
|
-
* / | |
|
|
10169
|
-
* / F/2 | |
|
|
10170
|
-
* C ------------P------------ O
|
|
10171
|
-
*
|
|
10172
|
-
*
|
|
10173
|
-
* ProjectionScaleFactor = ( OR / PQ )
|
|
10174
|
-
* PQ = canvasHeight / 2
|
|
10175
|
-
* CQ = zoom
|
|
10176
|
-
*
|
|
10177
|
-
* OR / C0 = tan(F/2)
|
|
10178
|
-
* so OR = CO * tan(F/2)
|
|
10179
|
-
*/
|
|
10180
|
-
export function getProjectionScaleFactor(FOV: number, canvasHeight: number, zoom: number): number;
|
|
10181
|
-
/** getZoom
|
|
10182
|
-
*
|
|
10183
|
-
* C - Camera, OP -- picture plane (canvas), S - origin,
|
|
10184
|
-
* QR - front side of maps Bounding Box, F: FOV
|
|
10185
|
-
*
|
|
10186
|
-
* Z-axis
|
|
10187
|
-
* R_____|______
|
|
10188
|
-
* /| | |
|
|
10189
|
-
* / | | |
|
|
10190
|
-
* P/ | | | maps BB
|
|
10191
|
-
* /| | | |
|
|
10192
|
-
* / | | | |
|
|
10193
|
-
* / | | | |
|
|
10194
|
-
* / F |E |T |S |
|
|
10195
|
-
* C /--------|-----|-----|-----|------ orthogonal to Y axis, midpoint of focus maps
|
|
10196
|
-
* \ | | | |
|
|
10197
|
-
* \ | | | |
|
|
10198
|
-
* \ | | | |
|
|
10199
|
-
* \ | | | |
|
|
10200
|
-
* \| | | |
|
|
10201
|
-
* O\ | | |
|
|
10202
|
-
* \ | | |
|
|
10203
|
-
* \|_____|_____|
|
|
10204
|
-
* Q
|
|
10205
|
-
*
|
|
10206
|
-
*
|
|
10207
|
-
* We want to get CS, which is the camera zoom
|
|
10208
|
-
*
|
|
10209
|
-
*/
|
|
10210
|
-
export function getZoom(focusBox: Box3, focusBoxHeight: number, FOV: number): number;
|
|
10211
|
-
interface CalculateTwoDProjectionsParams {
|
|
10212
|
-
maps: MapObject[];
|
|
10213
|
-
width: number;
|
|
10214
|
-
height: number;
|
|
10215
|
-
camera: Camera;
|
|
10216
|
-
}
|
|
10217
|
-
export function calculateTwoDProjections({ maps, width, height, camera }: CalculateTwoDProjectionsParams): {
|
|
10218
|
-
min: {
|
|
10219
|
-
x: number;
|
|
10220
|
-
y: number;
|
|
10221
|
-
};
|
|
10222
|
-
max: {
|
|
10223
|
-
x: number;
|
|
10224
|
-
y: number;
|
|
10225
|
-
};
|
|
10226
|
-
}[];
|
|
10227
|
-
export function splitLine(startNode: Vector3, endNode: Vector3, segments: number): Vector3[];
|
|
10228
|
-
export function isObject(item: any): boolean;
|
|
10229
|
-
export const determineStartingMap: (venue: Mappedin, options: TMapViewOptions) => MappedinMap;
|
|
10230
|
-
export function cyrb53(str: string, seed?: number): number;
|
|
10231
|
-
export function addMarginMultiplierToBoundingBox(bbox: Box3, multiplier: number): Box3;
|
|
10232
|
-
export function tweenPromise({ from, to, duration, easing, delay, onUpdate, onStart, onComplete, }: {
|
|
10233
|
-
from: any;
|
|
10234
|
-
to: any;
|
|
10235
|
-
duration?: number | undefined;
|
|
10236
|
-
easing?: any;
|
|
10237
|
-
delay?: number | undefined;
|
|
10238
|
-
onUpdate?: ((_: any) => void) | undefined;
|
|
10239
|
-
onStart?: (() => void) | undefined;
|
|
10240
|
-
onComplete?: (() => void) | undefined;
|
|
10241
|
-
}): {
|
|
10242
|
-
start(core: any): Promise<void>;
|
|
10243
|
-
};
|
|
10244
|
-
export const linearEase: (t: number) => number;
|
|
10245
|
-
export const quadEaseIn: (t: number) => number;
|
|
10246
|
-
export const quadEaseOut: (t: number) => number;
|
|
10247
|
-
export function interpolate(value: number, inputMin: number, inputMax: number, outputMin: number, outputMax: number, easeFunc?: (t: number) => number): number;
|
|
10248
|
-
export function interpolateMulti(value: number, inputRange: number[], outputRange: number[], easeFunc?: (t: number) => number): number;
|
|
10249
|
-
export function checkWritableBeforeWrite(obj: any, key: string, value: any): void;
|
|
10250
|
-
export {};
|
|
10531
|
+
export * from '@mappedin/mappedin-js/packages/legacy-renderer/internal/utils/utils';
|
|
10532
|
+
export { shouldDisableOffscreenCanvas } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/utils/browser';
|
|
10533
|
+
export { throttle, debounce } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/utils/async';
|
|
10251
10534
|
}
|
|
10252
10535
|
|
|
10253
10536
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.MapManager' {
|
|
@@ -10256,7 +10539,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
10256
10539
|
constructor(polygonMeshesById: any, renderer: any, core: any, taskScheduler: any, loadOptions?: {});
|
|
10257
10540
|
mapObjects: Map<any, any>;
|
|
10258
10541
|
currentMap: undefined;
|
|
10259
|
-
object:
|
|
10542
|
+
object: Object3D<import("three").Object3DEventMap>;
|
|
10260
10543
|
_showCount: number;
|
|
10261
10544
|
_mapObjectsSortedByElevationDirty: boolean;
|
|
10262
10545
|
expanded: boolean;
|
|
@@ -10364,6 +10647,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
10364
10647
|
resize(): void;
|
|
10365
10648
|
}
|
|
10366
10649
|
import { PubSub } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/pub-sub';
|
|
10650
|
+
import { Object3D } from 'three';
|
|
10651
|
+
import { Vector3 } from 'three';
|
|
10367
10652
|
import MultiFloorView from '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.MultiFloorView';
|
|
10368
10653
|
}
|
|
10369
10654
|
|
|
@@ -11365,10 +11650,8 @@ declare module '@mappedin/mappedin-js/packages/common/Mappedin.Logger' {
|
|
|
11365
11650
|
}
|
|
11366
11651
|
|
|
11367
11652
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-context/Mappedin.TileManager' {
|
|
11368
|
-
import { Box3 } from 'three';
|
|
11369
11653
|
import type { ICore } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
11370
11654
|
import { MappedinCoordinate, MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
11371
|
-
import Object3D from '@mappedin/mappedin-js/packages/legacy-renderer/internal/object3D.destroy';
|
|
11372
11655
|
import { Tile } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-context/Mappedin.Tile';
|
|
11373
11656
|
import { IOutdoorContextProvider } from '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-context/Outdoor-Context.provider';
|
|
11374
11657
|
/**
|
|
@@ -11411,9 +11694,9 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-
|
|
|
11411
11694
|
fadeIn(): Promise<void>;
|
|
11412
11695
|
fetchTiles(): void;
|
|
11413
11696
|
zoomLevelToAltitudeMap: number[][];
|
|
11414
|
-
plane:
|
|
11697
|
+
plane: any;
|
|
11415
11698
|
tiles: Tile[];
|
|
11416
|
-
maskMeshBoundingBox
|
|
11699
|
+
maskMeshBoundingBox?: any;
|
|
11417
11700
|
fetchTilesForZoomLevel(zoomLevel: number): Promise<void>;
|
|
11418
11701
|
/**
|
|
11419
11702
|
* This function populates a layer of tiles starting from the center clockwise
|
|
@@ -11433,14 +11716,14 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-
|
|
|
11433
11716
|
|
|
11434
11717
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/Core' {
|
|
11435
11718
|
import '../internal/externals/globalThisPolyfill';
|
|
11436
|
-
import { Color, Mesh, PerspectiveCamera, Scene, Vector2 } from 'three';
|
|
11719
|
+
import { Color, Mesh, PerspectiveCamera, Scene, Vector2, Vector3, Raycaster } from 'three';
|
|
11437
11720
|
import '../internal/object3D.destroy';
|
|
11438
11721
|
import type { TGetPolygonsAtCoordinateOptions, TMapViewOptions, TPadding, MappedinPolygon } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
11439
11722
|
import { Renderer, TaskScheduler, MapManager, FlatLabel, SmartCollisionEngine, PubSub, INTERNAL_EVENT, INTERNAL_EVENT_PAYLOAD, MapView, STATE, MapObject, SceneManager, TileManager, PathsController, FloatingLabelsController, FlatLabelsController, PolygonColorsController, MarkersController, PolygonInteractionController, TooltipsController, PolygonStatesController, PolygonImagesController, ThreeDMarkersController, EventSystem, BlueDotController, CameraController, BillboardManager, StackedMapsController, OutdoorViewController, WatermarkController, PolygonHoverColorsController, ExportController, LayerController } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
11440
11723
|
import { Mappedin as IMappedin, MappedinCoordinate, MappedinMap, MappedinNode } from '@mappedin/mappedin-js/packages/get-venue';
|
|
11441
11724
|
import { E_MAP_CHANGED_REASON } from '@mappedin/mappedin-js/packages/legacy-renderer/MapView.enums';
|
|
11442
11725
|
import type { PerformanceController } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/PerformanceController';
|
|
11443
|
-
export const raycaster:
|
|
11726
|
+
export const raycaster: Raycaster;
|
|
11444
11727
|
let Mappedin: any;
|
|
11445
11728
|
/**
|
|
11446
11729
|
* Some preset orderings for updates.
|
|
@@ -11518,9 +11801,9 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/Core' {
|
|
|
11518
11801
|
referenceMap: MappedinMap;
|
|
11519
11802
|
currentInteractionEvent: INTERNAL_EVENT | undefined;
|
|
11520
11803
|
resolution: Vector2;
|
|
11521
|
-
cameraParameters:
|
|
11804
|
+
cameraParameters: any;
|
|
11522
11805
|
controls: typeof Mappedin.CameraControls;
|
|
11523
|
-
|
|
11806
|
+
worldPlane: Mesh;
|
|
11524
11807
|
canvasWidth: number;
|
|
11525
11808
|
canvasHeight: number;
|
|
11526
11809
|
cachedPadding: TPadding;
|
|
@@ -11572,17 +11855,17 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/Core' {
|
|
|
11572
11855
|
* @param longitude {Number} Longitude of position
|
|
11573
11856
|
* @returns A position you can use with a Marker either initially or to update later when the user (for example) moves
|
|
11574
11857
|
*/
|
|
11575
|
-
getPositionLatLon: (lat: number, lon: number, map?: string | MappedinMap | null) =>
|
|
11858
|
+
getPositionLatLon: (lat: number, lon: number, map?: string | MappedinMap | null) => Vector3 | undefined;
|
|
11576
11859
|
lockNorth: (element: any, offset?: number) => void;
|
|
11577
11860
|
unlockNorth: (element: any) => void;
|
|
11578
|
-
convertTo3DMapPosition: (nodeOrCoordinate: MappedinNode | MappedinCoordinate) =>
|
|
11861
|
+
convertTo3DMapPosition: (nodeOrCoordinate: MappedinNode | MappedinCoordinate) => Vector3 | undefined;
|
|
11579
11862
|
/**
|
|
11580
11863
|
* Converts a 2D x,y screen position into a 3D MappedinCoordinate using projection
|
|
11581
11864
|
*/
|
|
11582
11865
|
convertScreenCoordinateToMapCoordinate: (x: number, y: number, map: MappedinMap) => MappedinCoordinate | undefined;
|
|
11583
11866
|
convert3DMapPositionToCoordinate: (coord: any, mapClass?: MappedinMap | null | undefined) => MappedinCoordinate | undefined;
|
|
11584
|
-
getPositionPolygon: (polygon: any) =>
|
|
11585
|
-
getPositionNode: (node: any) =>
|
|
11867
|
+
getPositionPolygon: (polygon: any) => Vector3 | null;
|
|
11868
|
+
getPositionNode: (node: any) => Vector3 | undefined;
|
|
11586
11869
|
hideAllLabels: () => void;
|
|
11587
11870
|
setBackgroundColor: (color: any, alpha: any) => void;
|
|
11588
11871
|
setSize: (width: any, height: any) => void;
|
|
@@ -11615,8 +11898,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/Core' {
|
|
|
11615
11898
|
mapSetResolved: any;
|
|
11616
11899
|
setMap: (map: string | MappedinMap) => Promise<null>;
|
|
11617
11900
|
setMapWithReason: (map: string | MappedinMap, reason: E_MAP_CHANGED_REASON) => Promise<null>;
|
|
11618
|
-
getPolygonsAtScreenCoordinate: (x: number, y: number, options?: TGetPolygonsAtCoordinateOptions) =>
|
|
11619
|
-
getPolygonsAtCoordinate: (coordinate: MappedinCoordinate, options?: TGetPolygonsAtCoordinateOptions) =>
|
|
11901
|
+
getPolygonsAtScreenCoordinate: (x: number, y: number, options?: TGetPolygonsAtCoordinateOptions) => MappedinPolygon[];
|
|
11902
|
+
getPolygonsAtCoordinate: (coordinate: MappedinCoordinate, options?: TGetPolygonsAtCoordinateOptions) => MappedinPolygon[];
|
|
11620
11903
|
getNearestNodeByScreenCoordinate(x: number, y: number, mapOrMapId?: MappedinMap | MappedinMap['id']): MappedinNode;
|
|
11621
11904
|
/**
|
|
11622
11905
|
* Destroys instance and frees resources
|
|
@@ -11646,6 +11929,10 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinNavigatable' {
|
|
|
11646
11929
|
* Exclude all the vortexes matching the given IDs
|
|
11647
11930
|
*/
|
|
11648
11931
|
excludedVortexIds?: string[];
|
|
11932
|
+
/**
|
|
11933
|
+
* Exclude all the nodes matching the given IDs
|
|
11934
|
+
*/
|
|
11935
|
+
excludedNodeIds?: string[];
|
|
11649
11936
|
/**
|
|
11650
11937
|
* @experimental
|
|
11651
11938
|
* Apply line-of-sight simplifying to directions. This will attempt to remove unnecessary nodes between turns.
|
|
@@ -11952,6 +12239,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinCategory' {
|
|
|
11952
12239
|
*/
|
|
11953
12240
|
get children(): MappedinCategory[];
|
|
11954
12241
|
static hydrate(categories: any, mappedin: Mappedin): MappedinCategory[];
|
|
12242
|
+
static updateInPlace(mappedin: Mappedin, hydrateData?: any): Promise<void>;
|
|
11955
12243
|
static fetch(mappedin: Mappedin): Promise<MappedinCategory[]>;
|
|
11956
12244
|
toJSON(): any;
|
|
11957
12245
|
}
|
|
@@ -11988,6 +12276,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinVortex' {
|
|
|
11988
12276
|
weight?: number;
|
|
11989
12277
|
multiplier?: number;
|
|
11990
12278
|
nodes?: string[];
|
|
12279
|
+
filterFlags?: string[];
|
|
11991
12280
|
constructor(data: any);
|
|
11992
12281
|
static hydrate(vortexes: any): MappedinVortex[];
|
|
11993
12282
|
static fetch(mappedin: Mappedin): Promise<MappedinVortex[]>;
|
|
@@ -11999,60 +12288,73 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinVenue' {
|
|
|
11999
12288
|
import type { Mappedin } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
12000
12289
|
import type { TLogo, TOpeningHours } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.API.types';
|
|
12001
12290
|
/**
|
|
12002
|
-
|
|
12003
|
-
|
|
12004
|
-
|
|
12005
|
-
|
|
12006
|
-
|
|
12007
|
-
|
|
12008
|
-
|
|
12009
|
-
|
|
12010
|
-
|
|
12011
|
-
|
|
12012
|
-
|
|
12013
|
-
|
|
12014
|
-
|
|
12015
|
-
|
|
12016
|
-
|
|
12017
|
-
|
|
12291
|
+
* A {@link MappedinVenue} is a specific place (like a mall) with one or more Maps (typically representing different floors) and Locations (stores, washrooms, elevators, etc).
|
|
12292
|
+
*
|
|
12293
|
+
* A Venue can have more properties such as 'name' and 'slug'. The {@link Mappedin} 'things' object is where you would specify what properties you want to download for Venues. Only specify what you will actually use, to minmimze transfer time. Work with your Mappedin developer relations contact to set up any custom properties you need.
|
|
12294
|
+
*
|
|
12295
|
+
* See below for an example a 'things' object with available Venue properties specified:
|
|
12296
|
+
*
|
|
12297
|
+
* things: {
|
|
12298
|
+
* venue: ['slug', 'name', 'language', 'address', 'city', 'state', 'postal', 'telephone', 'latitude', 'longitude', 'website', 'operationHours'],
|
|
12299
|
+
* locations: [],
|
|
12300
|
+
* categories: [],
|
|
12301
|
+
* maps: []
|
|
12302
|
+
* }
|
|
12303
|
+
*
|
|
12304
|
+
*
|
|
12305
|
+
* @class MappedinVenue
|
|
12306
|
+
*/
|
|
12018
12307
|
export class MappedinVenue {
|
|
12019
|
-
|
|
12020
|
-
|
|
12021
|
-
|
|
12022
|
-
|
|
12023
|
-
|
|
12024
|
-
|
|
12025
|
-
|
|
12026
|
-
|
|
12027
|
-
|
|
12028
|
-
|
|
12029
|
-
name: string;
|
|
12030
|
-
operationHours?: TOpeningHours[];
|
|
12031
|
-
postal: string;
|
|
12032
|
-
slug: string;
|
|
12033
|
-
state: string;
|
|
12034
|
-
telephone: string;
|
|
12035
|
-
tzid: string;
|
|
12036
|
-
tzidOverride: string;
|
|
12037
|
-
utcOffset: string;
|
|
12038
|
-
website: string;
|
|
12039
|
-
secureContentStorage: boolean;
|
|
12040
|
-
defaultLanguage: {
|
|
12041
|
-
code: string;
|
|
12042
|
-
name: string;
|
|
12043
|
-
};
|
|
12044
|
-
languages: {
|
|
12308
|
+
#private;
|
|
12309
|
+
defaultMap: string;
|
|
12310
|
+
address: string;
|
|
12311
|
+
city: string;
|
|
12312
|
+
countrycode: string;
|
|
12313
|
+
externalId: string;
|
|
12314
|
+
id: string;
|
|
12315
|
+
latitude?: number;
|
|
12316
|
+
logo?: TLogo;
|
|
12317
|
+
longitude?: number;
|
|
12045
12318
|
name: string;
|
|
12046
|
-
|
|
12047
|
-
|
|
12048
|
-
|
|
12049
|
-
|
|
12050
|
-
|
|
12051
|
-
|
|
12052
|
-
|
|
12053
|
-
|
|
12054
|
-
|
|
12055
|
-
|
|
12319
|
+
operationHours?: TOpeningHours[];
|
|
12320
|
+
postal: string;
|
|
12321
|
+
slug: string;
|
|
12322
|
+
state: string;
|
|
12323
|
+
telephone: string;
|
|
12324
|
+
tzid: string;
|
|
12325
|
+
tzidOverride: string;
|
|
12326
|
+
utcOffset: string;
|
|
12327
|
+
website: string;
|
|
12328
|
+
secureContentStorage: boolean;
|
|
12329
|
+
defaultLanguage: {
|
|
12330
|
+
code: string;
|
|
12331
|
+
name: string;
|
|
12332
|
+
};
|
|
12333
|
+
languages: {
|
|
12334
|
+
name: string;
|
|
12335
|
+
code: string;
|
|
12336
|
+
}[];
|
|
12337
|
+
topLocations?: string[];
|
|
12338
|
+
/**
|
|
12339
|
+
* Venue render options provided by the server.
|
|
12340
|
+
*/
|
|
12341
|
+
renderOptions: {
|
|
12342
|
+
/**
|
|
12343
|
+
* Whether the venue should use perspectives to render the map or {@link Mappedin.polygons}.
|
|
12344
|
+
*/
|
|
12345
|
+
useLivePolygons: boolean;
|
|
12346
|
+
/**
|
|
12347
|
+
* Whether the venue should automatically apply {@link TDirectionToOptions} `simplify: { enabled: true }` to all directions.
|
|
12348
|
+
*/
|
|
12349
|
+
simplifyDirections: boolean;
|
|
12350
|
+
};
|
|
12351
|
+
constructor(mappedin: Mappedin, data: any);
|
|
12352
|
+
get metadata(): any;
|
|
12353
|
+
set metadata(value: any);
|
|
12354
|
+
static hydrate(data: any, mappedin: Mappedin): MappedinVenue;
|
|
12355
|
+
static fetch(mappedin: Mappedin): Promise<MappedinVenue>;
|
|
12356
|
+
get isMultiBuilding(): any;
|
|
12357
|
+
toJSON(): any;
|
|
12056
12358
|
}
|
|
12057
12359
|
}
|
|
12058
12360
|
|
|
@@ -12172,6 +12474,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinEvent' {
|
|
|
12172
12474
|
* @internal
|
|
12173
12475
|
*/
|
|
12174
12476
|
static hydrate(events: any, mappedin: Mappedin): MappedinEvent[];
|
|
12477
|
+
static updateInPlace(mappedin: Mappedin, hydrateData?: any): Promise<void>;
|
|
12175
12478
|
/**
|
|
12176
12479
|
* @internal
|
|
12177
12480
|
*/
|
|
@@ -12196,6 +12499,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinLocationState'
|
|
|
12196
12499
|
* @internal
|
|
12197
12500
|
*/
|
|
12198
12501
|
static hydrate(locationStates: any): MappedinLocationState[];
|
|
12502
|
+
static updateInPlace(mappedin: Mappedin, hydrateData?: any): Promise<void>;
|
|
12199
12503
|
id: string;
|
|
12200
12504
|
name: string;
|
|
12201
12505
|
value: string;
|
|
@@ -12289,6 +12593,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinMap' {
|
|
|
12289
12593
|
*/
|
|
12290
12594
|
getNorth(): any;
|
|
12291
12595
|
static hydrate(maps: any, mappedin: Mappedin): MappedinMap[];
|
|
12596
|
+
static updateInPlace(mappedin: Mappedin, hydrateData?: any): Promise<void>;
|
|
12292
12597
|
static fetch(mappedin: Mappedin): Promise<MappedinMap[]>;
|
|
12293
12598
|
get center(): any;
|
|
12294
12599
|
toJSON(): any;
|
|
@@ -12314,18 +12619,19 @@ declare module '@mappedin/mappedin-js/packages/get-venue/MappedinMapGroup' {
|
|
|
12314
12619
|
*/
|
|
12315
12620
|
get maps(): MappedinMap[];
|
|
12316
12621
|
static hydrate(mapGroups: any, mappedin: Mappedin): MappedinMapGroup[];
|
|
12622
|
+
static updateInPlace(mappedin: Mappedin, hydrateData?: any): Promise<void>;
|
|
12317
12623
|
static fetch(mappedin: Mappedin): Promise<MappedinMapGroup[]>;
|
|
12318
12624
|
toJSON(): any;
|
|
12319
12625
|
}
|
|
12320
12626
|
}
|
|
12321
12627
|
|
|
12322
12628
|
declare module '@mappedin/mappedin-js/packages/get-venue/utils' {
|
|
12323
|
-
import type { TGetVenueOptions, TGetVenueOptionsInternal } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.types';
|
|
12629
|
+
import type { MergedThings, TGetVenueOptions, TGetVenueOptionsInternal, ThingsOption } from '@mappedin/mappedin-js/packages/get-venue/Mappedin.types';
|
|
12324
12630
|
import type { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
12325
12631
|
import { Mappedin, MappedinNavigatable, MappedinNode, MappedinPolygon, MappedinLocation, MappedinCoordinate } from '@mappedin/mappedin-js/packages/get-venue/internal';
|
|
12326
12632
|
export function isGatewayKey(key: string): boolean;
|
|
12327
12633
|
export function stringifyQuery(query: any, gateway?: boolean): string;
|
|
12328
|
-
export function buildUrl(options: TGetVenueOptionsInternal
|
|
12634
|
+
export function buildUrl(options: TGetVenueOptionsInternal<TGetVenueOptions>, pathname: string, query: any, supplementary?: boolean): string;
|
|
12329
12635
|
/**
|
|
12330
12636
|
* Make a network request to the Mappedin API to fetch an array of objects.
|
|
12331
12637
|
* @param options options from getVenue- baseUrl and supplementaryUrl are used
|
|
@@ -12334,7 +12640,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/utils' {
|
|
|
12334
12640
|
* @param supplementary whether to use the supplementaryUrl when sending the request
|
|
12335
12641
|
* @returns the result json
|
|
12336
12642
|
*/
|
|
12337
|
-
export function getArray(options: TGetVenueOptionsInternal
|
|
12643
|
+
export function getArray(options: TGetVenueOptionsInternal<TGetVenueOptions>, pathname: string, query: any, supplementary?: boolean): Promise<any>;
|
|
12338
12644
|
/**
|
|
12339
12645
|
* Make a network request to the Mappedin API to fetch an object.
|
|
12340
12646
|
* @param options options from getVenue- baseUrl and supplementaryUrl are used
|
|
@@ -12344,21 +12650,21 @@ declare module '@mappedin/mappedin-js/packages/get-venue/utils' {
|
|
|
12344
12650
|
* @param isExpectingArray whether the endpoint returns an array
|
|
12345
12651
|
* @returns the result json
|
|
12346
12652
|
*/
|
|
12347
|
-
export function getObject(options: TGetVenueOptionsInternal
|
|
12653
|
+
export function getObject(options: TGetVenueOptionsInternal<TGetVenueOptions>, pathname: string, query: any, supplementary?: boolean, isExpectingArray?: boolean): Promise<any>;
|
|
12348
12654
|
/**
|
|
12349
12655
|
* Prepares the request and URL fields to pass into generateAPIRequest
|
|
12350
12656
|
* @param options options from getVenue- baseUrl and supplementaryUrl are used
|
|
12351
12657
|
* @param url string describing the url corresponding to the client's request
|
|
12352
12658
|
* @param supplementary whether to use the supplementaryUrl when sending the request
|
|
12353
12659
|
*/
|
|
12354
|
-
export function constructParamsForRequest(options: TGetVenueOptionsInternal
|
|
12660
|
+
export function constructParamsForRequest(options: TGetVenueOptionsInternal<TGetVenueOptions>, url: string, supplementary?: boolean): {
|
|
12355
12661
|
req: {
|
|
12356
12662
|
method: string;
|
|
12357
12663
|
headers: any;
|
|
12358
12664
|
};
|
|
12359
12665
|
url: string;
|
|
12360
12666
|
};
|
|
12361
|
-
export function generateAPIRequest(options: TGetVenueOptionsInternal
|
|
12667
|
+
export function generateAPIRequest(options: TGetVenueOptionsInternal<TGetVenueOptions>, url: string, supplementary?: boolean): Promise<any>;
|
|
12362
12668
|
export function addToSet(array: any, value: any): void;
|
|
12363
12669
|
export function getDistanceBetweenLatLon([lat1, lon1]: [number, number], [lat2, lon2]: [number, number]): any;
|
|
12364
12670
|
export function getMapScale(map: MappedinMap): any;
|
|
@@ -12392,6 +12698,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/utils' {
|
|
|
12392
12698
|
* @return {MappedinLocation}
|
|
12393
12699
|
*/
|
|
12394
12700
|
export const getPrimaryLocationForPolygon: (polygon: MappedinPolygon | string | undefined, venue: Mappedin) => MappedinLocation | null;
|
|
12701
|
+
export function mergeThings(thingsOption: ThingsOption | undefined): MergedThings;
|
|
12395
12702
|
}
|
|
12396
12703
|
|
|
12397
12704
|
declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.cache' {
|
|
@@ -12440,6 +12747,7 @@ declare module '@mappedin/mappedin-js/packages/get-venue/Mappedin.cache' {
|
|
|
12440
12747
|
get polygonsByMapId(): Map<string, MappedinPolygon[]>;
|
|
12441
12748
|
get nodesByMapId(): Map<string, MappedinNode[]>;
|
|
12442
12749
|
findNearestNodeOnMap(mapId: string, coordinate: MappedinCoordinate): MappedinNode;
|
|
12750
|
+
findNodeWithinRadiusOnMap(mapId: string, coordinate: MappedinCoordinate, radius: number): MappedinNode[];
|
|
12443
12751
|
get locationsByMapId(): Map<string, MappedinLocation[]>;
|
|
12444
12752
|
static instances: Map<Mappedin, MappedinCache>;
|
|
12445
12753
|
static create(mappedin: Mappedin): MappedinCache;
|
|
@@ -12546,13 +12854,15 @@ declare module '@mappedin/mappedin-js/packages/navigator/NavigationGraph' {
|
|
|
12546
12854
|
* @param accessible boolean - optional, if true directions will only take accessible route, defaults to false
|
|
12547
12855
|
* @param includedVortexIds set - optional, exclude all the vertexes matching the given IDs
|
|
12548
12856
|
* @param excludedVortexIds set - optional, exclude all the vertexes matching the given IDs
|
|
12857
|
+
* @param excludedNodeIds set - optional, exclude all the nodes matching the given IDs
|
|
12549
12858
|
*/
|
|
12550
|
-
aStar({ originIds, destinationNodeIds, accessible, includedVortexIds, excludedVortexIds, }: {
|
|
12859
|
+
aStar({ originIds, destinationNodeIds, accessible, includedVortexIds, excludedVortexIds, excludedNodeIds, }: {
|
|
12551
12860
|
originIds: string[];
|
|
12552
12861
|
destinationNodeIds: string[];
|
|
12553
12862
|
accessible: boolean;
|
|
12554
12863
|
includedVortexIds?: Set<string>;
|
|
12555
12864
|
excludedVortexIds?: Set<string>;
|
|
12865
|
+
excludedNodeIds?: Set<string>;
|
|
12556
12866
|
}): Edge[];
|
|
12557
12867
|
getDistance(origin: INode, destination: INode): number;
|
|
12558
12868
|
getShortestEuclideanDistance(origin: INode, destinations: INode[]): number;
|
|
@@ -12619,10 +12929,11 @@ declare module '@mappedin/mappedin-js/packages/navigator/Navigator' {
|
|
|
12619
12929
|
* @param includedVortexIds set - optional, exclude all the vertexes matching the given IDs
|
|
12620
12930
|
* @param excludedVortexIds set - optional, exclude all the vertexes matching the given IDs
|
|
12621
12931
|
*/
|
|
12622
|
-
getDirections({ originIds, destinationNodeIds, accessible, departFrom, arriveAt, includedVortexIds, excludedVortexIds, simplify, }: {
|
|
12932
|
+
getDirections({ originIds, destinationNodeIds, accessible, departFrom, arriveAt, includedVortexIds, excludedVortexIds, excludedNodeIds, simplify, }: {
|
|
12623
12933
|
originIds: string[];
|
|
12624
12934
|
includedVortexIds?: Set<string>;
|
|
12625
12935
|
excludedVortexIds?: Set<string>;
|
|
12936
|
+
excludedNodeIds?: Set<string>;
|
|
12626
12937
|
destinationNodeIds: string[];
|
|
12627
12938
|
accessible: boolean;
|
|
12628
12939
|
departFrom?: ILocation;
|
|
@@ -12639,7 +12950,25 @@ declare module '@mappedin/mappedin-js/packages/navigator/Navigator' {
|
|
|
12639
12950
|
}
|
|
12640
12951
|
|
|
12641
12952
|
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/base-object' {
|
|
12953
|
+
import Hyperlink from '@mappedin/mappedin-js/maker/src/map-data-objects/hyperlink';
|
|
12954
|
+
import { Details } from '@mappedin/mvf';
|
|
12642
12955
|
export default abstract class BaseMapData {
|
|
12956
|
+
/**
|
|
12957
|
+
* identity of the map object
|
|
12958
|
+
*/
|
|
12959
|
+
readonly id: string;
|
|
12960
|
+
constructor(id: string, details?: Details);
|
|
12961
|
+
/**
|
|
12962
|
+
* Gets the links associated with this data type.
|
|
12963
|
+
*
|
|
12964
|
+
* @returns {Hyperlink[]} The links associated with this data type
|
|
12965
|
+
*/
|
|
12966
|
+
links: Hyperlink[];
|
|
12967
|
+
}
|
|
12968
|
+
}
|
|
12969
|
+
|
|
12970
|
+
declare module '@mappedin/mappedin-js/maker/src/map-data-objects/base-metadata-object' {
|
|
12971
|
+
export default abstract class BaseMetaData {
|
|
12643
12972
|
/**
|
|
12644
12973
|
* identity of the map object
|
|
12645
12974
|
*/
|
|
@@ -12652,15 +12981,14 @@ declare module '@mappedin/mappedin-js/maker/src/api-cms/api-cms' {
|
|
|
12652
12981
|
import { MapData, TShow3DMapOptions } from '@mappedin/mappedin-js/maker/src';
|
|
12653
12982
|
import { IDirectionsResult, MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
12654
12983
|
import { FloatingLabel, Marker as LegacyMarker } from '@mappedin/mappedin-js/cms/src';
|
|
12655
|
-
import { JourneyController } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
12984
|
+
import { ExportController, JourneyController } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
12656
12985
|
import Core from '@mappedin/mappedin-js/packages/legacy-renderer/private/Core';
|
|
12657
|
-
import { Coordinate,
|
|
12986
|
+
import { Coordinate, Floor, MapDataInternal, MapObject, Space } from '@mappedin/mappedin-js/maker/src/map-data-objects';
|
|
12658
12987
|
import { MapView } from '@mappedin/mappedin-js/maker/src/map-view';
|
|
12659
12988
|
import { IMapView, ILabels, TUpdateState, IMarkers, ICamera, TNavigationTarget, IPaths, TGetDirectionsOptions } from '@mappedin/mappedin-js/maker/src/map-view-interface';
|
|
12660
12989
|
import { Marker, Directions, Label } from '@mappedin/mappedin-js/maker/src/map-view-objects';
|
|
12661
12990
|
import { DefaultTheme } from '@mappedin/mappedin-js/maker/src/themes/default';
|
|
12662
12991
|
import { Navigation } from '@mappedin/mappedin-js/maker/src/navigation';
|
|
12663
|
-
export function getCoordinateFromStuffs(thing: Space | Door | Coordinate | MapObject | PointOfInterest): Coordinate | undefined;
|
|
12664
12992
|
export function getMappedinCoordinate(coordinate: Coordinate, mvCore: Core): import("../../../packages/get-venue").MappedinCoordinate;
|
|
12665
12993
|
export class CMSAPI implements IMapView {
|
|
12666
12994
|
mvCore: Core;
|
|
@@ -12677,6 +13005,7 @@ declare module '@mappedin/mappedin-js/maker/src/api-cms/api-cms' {
|
|
|
12677
13005
|
journey?: JourneyController;
|
|
12678
13006
|
Navigation: Navigation;
|
|
12679
13007
|
auto: DefaultTheme['auto'];
|
|
13008
|
+
exportController?: ExportController;
|
|
12680
13009
|
constructor(el: HTMLElement, mapView: MapView, optionsWithDefaults: TShow3DMapOptions);
|
|
12681
13010
|
get currentFloor(): Floor;
|
|
12682
13011
|
setFloor(floor: Floor | string): void;
|
|
@@ -12859,7 +13188,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/quad-tre
|
|
|
12859
13188
|
}
|
|
12860
13189
|
|
|
12861
13190
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/shave-text' {
|
|
12862
|
-
export type TDrawFn = (ctx: CanvasRenderingContext2D, x: number, y: number) => void;
|
|
13191
|
+
export type TDrawFn = (ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, x: number, y: number) => void;
|
|
12863
13192
|
type TShave = (str: string, size: number, maxWidth: number, maxLines?: number, lineHeight?: number, options?: {
|
|
12864
13193
|
strokeText: boolean;
|
|
12865
13194
|
}) => {
|
|
@@ -12880,7 +13209,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/private/scene-man
|
|
|
12880
13209
|
import { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
12881
13210
|
import type { ICore } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
12882
13211
|
export function determineMapPositionAndRotation(map: MappedinMap, core: ICore): {
|
|
12883
|
-
position:
|
|
13212
|
+
position: number[];
|
|
12884
13213
|
scale: number[];
|
|
12885
13214
|
rotation: number[];
|
|
12886
13215
|
};
|
|
@@ -12956,8 +13285,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
12956
13285
|
options: TPostProcessingOptions & Required<Pick<TPostProcessingOptions, 'antialias' | 'antialiasQuality' | 'aoEnabled' | 'aoQuality' | 'aoResolution'>>;
|
|
12957
13286
|
isWebGL2: boolean;
|
|
12958
13287
|
effectComposer: PPEffectComposer;
|
|
12959
|
-
scene: Scene;
|
|
12960
|
-
camera: PerspectiveCamera;
|
|
13288
|
+
scene: Scene | null;
|
|
13289
|
+
camera: PerspectiveCamera | null;
|
|
12961
13290
|
depthTexture?: Texture;
|
|
12962
13291
|
renderer: any;
|
|
12963
13292
|
constructor(renderer: any, options: TPostProcessingOptions);
|
|
@@ -13078,242 +13407,201 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
13078
13407
|
}
|
|
13079
13408
|
}
|
|
13080
13409
|
|
|
13081
|
-
declare module '@mappedin/mappedin-js/packages/legacy-renderer/
|
|
13082
|
-
import {
|
|
13083
|
-
import
|
|
13410
|
+
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/utils/utils' {
|
|
13411
|
+
import { Box3, Vector3, Object3D } from 'three';
|
|
13412
|
+
import { Mappedin, MapObject, MappedinMap, TMapViewOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
13413
|
+
import { Camera } from '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Camera';
|
|
13084
13414
|
/**
|
|
13085
|
-
*
|
|
13415
|
+
* Utils function listing
|
|
13416
|
+
*
|
|
13417
|
+
* - scrubMaterial
|
|
13418
|
+
* - getObjectID
|
|
13419
|
+
* - getObject
|
|
13420
|
+
* - getBoundingBox
|
|
13421
|
+
* - getBiggestBoundingBox
|
|
13422
|
+
* - upackBoundingBox
|
|
13423
|
+
* - getMapScale
|
|
13424
|
+
* - throttle -> taken from lodash.js
|
|
13425
|
+
* - getProjectionScaleFactor
|
|
13426
|
+
* - getZoom
|
|
13086
13427
|
*/
|
|
13087
|
-
export
|
|
13088
|
-
|
|
13089
|
-
|
|
13090
|
-
|
|
13091
|
-
|
|
13092
|
-
|
|
13093
|
-
|
|
13094
|
-
|
|
13095
|
-
|
|
13096
|
-
|
|
13097
|
-
|
|
13098
|
-
|
|
13099
|
-
|
|
13100
|
-
|
|
13101
|
-
|
|
13102
|
-
|
|
13103
|
-
|
|
13104
|
-
|
|
13105
|
-
|
|
13106
|
-
|
|
13107
|
-
|
|
13108
|
-
|
|
13109
|
-
|
|
13110
|
-
|
|
13111
|
-
|
|
13112
|
-
|
|
13113
|
-
|
|
13114
|
-
|
|
13428
|
+
export function isGatewayKey(key: string): boolean;
|
|
13429
|
+
export function getCombinedBoundingBox(objects: Object3D[]): Box3;
|
|
13430
|
+
export function getMapsBoundingBox(maps: MapObject[], mapPadding: number): Box3;
|
|
13431
|
+
export function scrubMaterial(material: any): void;
|
|
13432
|
+
/**
|
|
13433
|
+
* Takes a Mappedin Object or id and returns the ID, so our functions can take bottomRight
|
|
13434
|
+
* @template T extends string | {id: string}
|
|
13435
|
+
* @param {T} object - input can be object containing id or the id itself
|
|
13436
|
+
* @return {string}
|
|
13437
|
+
*/
|
|
13438
|
+
export function getObjectId(object: any): string;
|
|
13439
|
+
/**
|
|
13440
|
+
* Takes a Mappedin object or ID and the array to look in and retuns the Object, so our functions can take both
|
|
13441
|
+
*/
|
|
13442
|
+
export function getObject<K extends {
|
|
13443
|
+
id: string;
|
|
13444
|
+
}, T extends K | string>(obj: T, array: K[] | undefined): K | undefined;
|
|
13445
|
+
export function getBoundingBox(object: Object3D): Box3;
|
|
13446
|
+
/**
|
|
13447
|
+
* Function pushes the items of the second array onto the first array (inplace).
|
|
13448
|
+
* @template T
|
|
13449
|
+
* @param {Array.<T>} arr1 - base array
|
|
13450
|
+
* @param {Array.<T>} arr2 - array which items will be pushed to arr1
|
|
13451
|
+
*/
|
|
13452
|
+
export function appendItems<T>(arr1: T[], arr2: T[]): void;
|
|
13453
|
+
export function getBiggestBoundingBox(objects: Object3D[]): {
|
|
13454
|
+
min: Vector3;
|
|
13455
|
+
max: Vector3;
|
|
13456
|
+
};
|
|
13457
|
+
export function unpackBoundingBox(boundingBox: Box3): Vector3[];
|
|
13458
|
+
export function getMapScale(map: MappedinMap): number;
|
|
13459
|
+
export function getNorth(map: MappedinMap): number;
|
|
13460
|
+
export function flatten(list: any[]): any[];
|
|
13461
|
+
export function uniq(arr: any[]): any[];
|
|
13462
|
+
export function toStyleString(styles: Record<string, string>): string;
|
|
13463
|
+
/**
|
|
13464
|
+
/* getProjectionScaleFactor()
|
|
13465
|
+
/* finds the scale ratio between screen coordinates and 3D coordinates (in X-Z plane)
|
|
13466
|
+
/*
|
|
13467
|
+
* R
|
|
13468
|
+
* /|
|
|
13469
|
+
* C : Camera / |
|
|
13470
|
+
* PQ : Projection Plane / |
|
|
13471
|
+
* OR : Origin / |
|
|
13472
|
+
* F : FOV / |
|
|
13473
|
+
* Q / |
|
|
13474
|
+
* /| |
|
|
13475
|
+
* / | |
|
|
13476
|
+
* / | |
|
|
13477
|
+
* / | |
|
|
13478
|
+
* / | |
|
|
13479
|
+
* / F/2 | |
|
|
13480
|
+
* C ------------P------------ O
|
|
13115
13481
|
*
|
|
13116
|
-
* // Something changed and I no longer want this event to fire
|
|
13117
|
-
* mapView.Camera.off(E_CAMERA_EVENT.CHANGED, cameraChangedHandler);
|
|
13118
|
-
* ```
|
|
13119
13482
|
*
|
|
13120
|
-
*
|
|
13121
|
-
*
|
|
13122
|
-
*
|
|
13123
|
-
*/
|
|
13124
|
-
off: CameraController['off'];
|
|
13125
|
-
/**
|
|
13126
|
-
* The current camera animation, if any. Resolves when the animation finishes.
|
|
13127
|
-
*/
|
|
13128
|
-
get currentAnimation(): Promise<undefined> | undefined;
|
|
13129
|
-
/**
|
|
13130
|
-
* Current Camera zoom (in meters)
|
|
13131
|
-
*/
|
|
13132
|
-
get zoom(): number;
|
|
13133
|
-
/**
|
|
13134
|
-
* Current Camera rotation (in radians) from north
|
|
13135
|
-
*/
|
|
13136
|
-
get rotation(): number;
|
|
13137
|
-
/**
|
|
13138
|
-
* Current camera tilt angle (in radians), relative to a top-down view.
|
|
13483
|
+
* ProjectionScaleFactor = ( OR / PQ )
|
|
13484
|
+
* PQ = canvasHeight / 2
|
|
13485
|
+
* CQ = zoom
|
|
13139
13486
|
*
|
|
13140
|
-
*
|
|
13141
|
-
*
|
|
13142
|
-
*/
|
|
13143
|
-
get tilt(): number;
|
|
13144
|
-
/**
|
|
13145
|
-
* Get the minimum distance (in meters) the camera is allowed to get to the ground.
|
|
13146
|
-
*/
|
|
13147
|
-
get minZoom(): number;
|
|
13148
|
-
/**
|
|
13149
|
-
* Set the minimum distance (in meters) the camera is allowed to get to the ground.
|
|
13150
|
-
*/
|
|
13151
|
-
set minZoom(meters: number);
|
|
13152
|
-
/**
|
|
13153
|
-
* Get the maximum distance (in meters) the camera is allowed to get from the ground.
|
|
13487
|
+
* OR / C0 = tan(F/2)
|
|
13488
|
+
* so OR = CO * tan(F/2)
|
|
13154
13489
|
*/
|
|
13155
|
-
|
|
13156
|
-
|
|
13157
|
-
|
|
13158
|
-
|
|
13159
|
-
|
|
13160
|
-
|
|
13161
|
-
|
|
13162
|
-
|
|
13163
|
-
|
|
13164
|
-
|
|
13165
|
-
|
|
13166
|
-
|
|
13167
|
-
|
|
13168
|
-
|
|
13169
|
-
|
|
13170
|
-
|
|
13171
|
-
|
|
13172
|
-
|
|
13173
|
-
|
|
13174
|
-
|
|
13175
|
-
|
|
13176
|
-
|
|
13177
|
-
|
|
13178
|
-
|
|
13179
|
-
|
|
13180
|
-
|
|
13181
|
-
|
|
13182
|
-
|
|
13183
|
-
|
|
13184
|
-
|
|
13185
|
-
|
|
13186
|
-
|
|
13187
|
-
|
|
13188
|
-
|
|
13189
|
-
|
|
13190
|
-
|
|
13191
|
-
interactions: {
|
|
13192
|
-
/**
|
|
13193
|
-
* Enable or disable specific user interactions.
|
|
13194
|
-
*
|
|
13195
|
-
* ```ts
|
|
13196
|
-
* mapView.Camera.interactions.set({ zoom: false });
|
|
13197
|
-
* ```
|
|
13198
|
-
*
|
|
13199
|
-
* @param options An object defining the interactions to switch on or off.
|
|
13200
|
-
*
|
|
13201
|
-
*/
|
|
13202
|
-
set: (options: TCameraInteractionsSetOptions) => void;
|
|
13203
|
-
/**
|
|
13204
|
-
* Enable all user interactions.
|
|
13205
|
-
*/
|
|
13206
|
-
enable: () => void;
|
|
13207
|
-
/**
|
|
13208
|
-
* Disable all user interactions.
|
|
13209
|
-
*/
|
|
13210
|
-
disable: () => void;
|
|
13211
|
-
};
|
|
13212
|
-
/**
|
|
13213
|
-
* Define an area of the screen that is safe for the camera. Anything outside the safe area is
|
|
13214
|
-
* assumed to be covered in some way (e.g. by UI) meaning the camera will not place
|
|
13215
|
-
* any map elements there when calling {@link focusOn}.
|
|
13216
|
-
*
|
|
13217
|
-
* ```ts
|
|
13218
|
-
* // The top 100px of the canvas are covered by a UI element
|
|
13219
|
-
* mapView.Camera.setSafeAreaInsets({ top: 100, left: 0, bottom: 0, right: 0});
|
|
13220
|
-
* mapView.Camera.focusOn({ nodes });
|
|
13221
|
-
* ```
|
|
13222
|
-
*
|
|
13223
|
-
* @param insets An object defining a number of pixels from the top, left, bottom, and right of
|
|
13224
|
-
* the screen. Only the area within the padding defined by these pixels is considered safe.
|
|
13225
|
-
*/
|
|
13226
|
-
setSafeAreaInsets(insets: {
|
|
13227
|
-
top: number;
|
|
13228
|
-
left: number;
|
|
13229
|
-
bottom: number;
|
|
13230
|
-
right: number;
|
|
13231
|
-
}): void;
|
|
13232
|
-
/**
|
|
13233
|
-
* Retrieve the values previously set by {@link setSafeAreaInsets}.
|
|
13234
|
-
*
|
|
13235
|
-
* @returns An object defining a number of pixels from the top, left, bottom, and right of
|
|
13236
|
-
* the screen.
|
|
13237
|
-
*/
|
|
13238
|
-
getSafeAreaInsets(): import("../../MapView.types").TPadding;
|
|
13239
|
-
/**
|
|
13240
|
-
* Animate the camera to focus on a collection of targets. To control where the targets should
|
|
13241
|
-
* be placed on screen, either specify `safeAreaInsets` on the {@link TFocusOnCameraOptions}
|
|
13242
|
-
* or call {@link setSafeAreaInsets}.
|
|
13243
|
-
*
|
|
13244
|
-
* ```ts
|
|
13245
|
-
* const location = mapView.venue.locations.find((l) => l.name === "My Location")!;
|
|
13246
|
-
*
|
|
13247
|
-
* mapView.Camera.focusOn({
|
|
13248
|
-
* polygons: location.polygons,
|
|
13249
|
-
* nodes: location.nodes,
|
|
13250
|
-
* });
|
|
13251
|
-
* ```
|
|
13252
|
-
*
|
|
13253
|
-
* @param targets A collection of things that the camera will place into view at the end of the
|
|
13254
|
-
* animation.
|
|
13255
|
-
* @param options
|
|
13256
|
-
* @returns a Promise that resolves when the animation finishes, or rejects when it is cancelled.
|
|
13257
|
-
*/
|
|
13258
|
-
focusOn(targets: TCameraTargets, options?: TFocusOnCameraOptions & TCameraAnimationOptions): Promise<any>;
|
|
13259
|
-
/**
|
|
13260
|
-
* Instantaneously set the camera's transform to be in a new configuration. See also {@link animate}.
|
|
13261
|
-
*
|
|
13262
|
-
* ```ts
|
|
13263
|
-
* const coord = mapView.venue.maps[0].createCoordinate(33.66107, 31.83911);
|
|
13264
|
-
*
|
|
13265
|
-
* // Place the camera top-down at a specified coordinate
|
|
13266
|
-
* mapView.Camera.set({
|
|
13267
|
-
* tilt: 0,
|
|
13268
|
-
* position: coord,
|
|
13269
|
-
* });
|
|
13270
|
-
* ```
|
|
13271
|
-
*
|
|
13272
|
-
* @param transform The new transform of the camera.
|
|
13273
|
-
*/
|
|
13274
|
-
set(transform: TCameraTransform): void;
|
|
13275
|
-
/**
|
|
13276
|
-
* Convert a Mercator Zoom Level to altitude, which can be used in the Camera APIs
|
|
13277
|
-
*/
|
|
13278
|
-
convertZoomLevelToAltitude(zoomLevel: number): any;
|
|
13279
|
-
/**
|
|
13280
|
-
* Convert the altitude returned by getZoom into Mercator Zoom level
|
|
13281
|
-
*/
|
|
13282
|
-
convertAltitudeToZoomLevel(altitude: number): any;
|
|
13283
|
-
/**
|
|
13284
|
-
* Smoothly transition the camera's transform to be in a new configuration. See also {@link set}.
|
|
13285
|
-
*
|
|
13286
|
-
* ```ts
|
|
13287
|
-
* const coord = mapView.venue.maps[0].createCoordinate(33.66107, 31.83911);
|
|
13288
|
-
*
|
|
13289
|
-
* // Animate the camera to be top-down at a specified coordinate
|
|
13290
|
-
* mapView.Camera.animate({
|
|
13291
|
-
* tilt: 0,
|
|
13292
|
-
* position: coord,
|
|
13293
|
-
* });
|
|
13294
|
-
* ```
|
|
13295
|
-
*
|
|
13296
|
-
* @param transform The new transform of the camera.
|
|
13297
|
-
* @param options
|
|
13298
|
-
* @returns a Promise that resolves when the animation finishes, or rejects when it is cancelled.
|
|
13299
|
-
*/
|
|
13300
|
-
animate(transform: TCameraTransform, options?: TCameraAnimationOptions): Promise<undefined>;
|
|
13301
|
-
/**
|
|
13302
|
-
* Moves the Camera view in a relative direction by a given distance in meters.
|
|
13303
|
-
*
|
|
13304
|
-
* ```ts
|
|
13305
|
-
* // Move the camera 50 meters up relative to the camera frame
|
|
13306
|
-
* mapView.Camera.translate(E_CAMERA_DIRECTION.UP, 50);
|
|
13307
|
-
* ```
|
|
13308
|
-
*
|
|
13309
|
-
* @returns a Promise that resolves when the translation animation finishes, or rejects when it is cancelled.
|
|
13310
|
-
*/
|
|
13311
|
-
translate(direction: E_CAMERA_DIRECTION, distance: number, options?: TCameraAnimationOptions): Promise<unknown>;
|
|
13312
|
-
/**
|
|
13313
|
-
* Cancel the currently active Camera animation.
|
|
13314
|
-
*/
|
|
13315
|
-
cancelAnimation(): void;
|
|
13490
|
+
export function getProjectionScaleFactor(FOV: number, canvasHeight: number, zoom: number): number;
|
|
13491
|
+
/** getZoom
|
|
13492
|
+
*
|
|
13493
|
+
* C - Camera, OP -- picture plane (canvas), S - origin,
|
|
13494
|
+
* QR - front side of maps Bounding Box, F: FOV
|
|
13495
|
+
*
|
|
13496
|
+
* Z-axis
|
|
13497
|
+
* R_____|______
|
|
13498
|
+
* /| | |
|
|
13499
|
+
* / | | |
|
|
13500
|
+
* P/ | | | maps BB
|
|
13501
|
+
* /| | | |
|
|
13502
|
+
* / | | | |
|
|
13503
|
+
* / | | | |
|
|
13504
|
+
* / F |E |T |S |
|
|
13505
|
+
* C /--------|-----|-----|-----|------ orthogonal to Y axis, midpoint of focus maps
|
|
13506
|
+
* \ | | | |
|
|
13507
|
+
* \ | | | |
|
|
13508
|
+
* \ | | | |
|
|
13509
|
+
* \ | | | |
|
|
13510
|
+
* \| | | |
|
|
13511
|
+
* O\ | | |
|
|
13512
|
+
* \ | | |
|
|
13513
|
+
* \|_____|_____|
|
|
13514
|
+
* Q
|
|
13515
|
+
*
|
|
13516
|
+
*
|
|
13517
|
+
* We want to get CS, which is the camera zoom
|
|
13518
|
+
*
|
|
13519
|
+
*/
|
|
13520
|
+
export function getZoom(focusBox: Box3, focusBoxHeight: number, FOV: number): number;
|
|
13521
|
+
interface CalculateTwoDProjectionsParams {
|
|
13522
|
+
maps: MapObject[];
|
|
13523
|
+
width: number;
|
|
13524
|
+
height: number;
|
|
13525
|
+
camera: Camera;
|
|
13316
13526
|
}
|
|
13527
|
+
export function calculateTwoDProjections({ maps, width, height, camera }: CalculateTwoDProjectionsParams): {
|
|
13528
|
+
min: {
|
|
13529
|
+
x: number;
|
|
13530
|
+
y: number;
|
|
13531
|
+
};
|
|
13532
|
+
max: {
|
|
13533
|
+
x: number;
|
|
13534
|
+
y: number;
|
|
13535
|
+
};
|
|
13536
|
+
}[];
|
|
13537
|
+
export function splitLine(startNode: Vector3, endNode: Vector3, segments: number): Vector3[];
|
|
13538
|
+
export function isObject(item: any): boolean;
|
|
13539
|
+
export const determineStartingMap: (venue: Mappedin, options: TMapViewOptions) => MappedinMap;
|
|
13540
|
+
export function cyrb53(str: string, seed?: number): number;
|
|
13541
|
+
export function addMarginMultiplierToBoundingBox(bbox: Box3, multiplier: number): Box3;
|
|
13542
|
+
export function tweenPromise({ from, to, duration, easing, delay, onUpdate, onStart, onComplete, }: {
|
|
13543
|
+
from: any;
|
|
13544
|
+
to: any;
|
|
13545
|
+
duration?: number | undefined;
|
|
13546
|
+
easing?: any;
|
|
13547
|
+
delay?: number | undefined;
|
|
13548
|
+
onUpdate?: ((_: any) => void) | undefined;
|
|
13549
|
+
onStart?: (() => void) | undefined;
|
|
13550
|
+
onComplete?: (() => void) | undefined;
|
|
13551
|
+
}): {
|
|
13552
|
+
start(core: any): Promise<void>;
|
|
13553
|
+
};
|
|
13554
|
+
export const linearEase: (t: number) => number;
|
|
13555
|
+
export const quadEaseIn: (t: number) => number;
|
|
13556
|
+
export const quadEaseOut: (t: number) => number;
|
|
13557
|
+
export function interpolate(value: number, inputMin: number, inputMax: number, outputMin: number, outputMax: number, easeFunc?: (t: number) => number): number;
|
|
13558
|
+
export function interpolateMulti(value: number, inputRange: number[], outputRange: number[], easeFunc?: (t: number) => number): number;
|
|
13559
|
+
export function checkWritableBeforeWrite(obj: any, key: string, value: any): void;
|
|
13560
|
+
export {};
|
|
13561
|
+
}
|
|
13562
|
+
|
|
13563
|
+
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/utils/browser' {
|
|
13564
|
+
type DeviceType = {
|
|
13565
|
+
isIpad: boolean;
|
|
13566
|
+
isMobile: boolean;
|
|
13567
|
+
isSafari12: boolean;
|
|
13568
|
+
isFirefox: boolean;
|
|
13569
|
+
isWindows: boolean;
|
|
13570
|
+
};
|
|
13571
|
+
/**
|
|
13572
|
+
* Get device OS info
|
|
13573
|
+
* export for testing purpose
|
|
13574
|
+
* @returns DeviceType
|
|
13575
|
+
*/
|
|
13576
|
+
export const _deviceTypeControl: {
|
|
13577
|
+
getDeviceType(): DeviceType;
|
|
13578
|
+
_reset(): void;
|
|
13579
|
+
};
|
|
13580
|
+
export const getDeviceType: () => DeviceType;
|
|
13581
|
+
/**
|
|
13582
|
+
* Creates a closure encapsulating the logic of getting device GPU info.
|
|
13583
|
+
* inspired by https://github.com/pmndrs/detect-gpu
|
|
13584
|
+
* export for testing
|
|
13585
|
+
*/
|
|
13586
|
+
export const _gpuInfoControl: {
|
|
13587
|
+
getInfo: () => string | undefined;
|
|
13588
|
+
shouldDisableOffscreenCanvas: () => boolean;
|
|
13589
|
+
_setCanvas(c: HTMLCanvasElement): void;
|
|
13590
|
+
};
|
|
13591
|
+
export const getGPUInfo: () => string | undefined;
|
|
13592
|
+
/**
|
|
13593
|
+
* Check if device is certain intel integrated GPU.
|
|
13594
|
+
* This is for implementing workaround - https://issues.chromium.org/issues/40251953
|
|
13595
|
+
* The reason we want to disable OffscreenCanvas at all is due to `willReadFrequently` flag only works in FF.
|
|
13596
|
+
* In order to ensure the integrated intel GPU render text correctly
|
|
13597
|
+
*/
|
|
13598
|
+
export const shouldDisableOffscreenCanvas: () => boolean;
|
|
13599
|
+
export {};
|
|
13600
|
+
}
|
|
13601
|
+
|
|
13602
|
+
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/utils/async' {
|
|
13603
|
+
export function throttle<T>(func: () => void, wait: number, options?: any): () => void;
|
|
13604
|
+
export function debounce<T>(func: () => void, wait: number, immediate?: boolean): () => void;
|
|
13317
13605
|
}
|
|
13318
13606
|
|
|
13319
13607
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin.MultiFloorView' {
|
|
@@ -13337,7 +13625,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
13337
13625
|
_focusMapsLen: number;
|
|
13338
13626
|
_focusAnimCurve: any;
|
|
13339
13627
|
_focusAnimDuration: number;
|
|
13340
|
-
rotationAxis:
|
|
13628
|
+
rotationAxis: Vector3;
|
|
13341
13629
|
mapBoundingBoxes: any[];
|
|
13342
13630
|
_helperBoundingBoxes: any[];
|
|
13343
13631
|
mapAxesHelpers: any[];
|
|
@@ -13394,11 +13682,11 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
13394
13682
|
*/
|
|
13395
13683
|
get projections(): any[];
|
|
13396
13684
|
tiltMaps(tiltRad: any): void;
|
|
13397
|
-
_focusBox:
|
|
13685
|
+
_focusBox: Box3 | undefined;
|
|
13398
13686
|
_scrollWindow: number | undefined;
|
|
13399
13687
|
tween: any;
|
|
13400
13688
|
getFocusMaps(start: any, dir: any, len: any): any;
|
|
13401
|
-
getFocusBox():
|
|
13689
|
+
getFocusBox(): Box3;
|
|
13402
13690
|
getVisibleMaps(): any;
|
|
13403
13691
|
getVisibleMapIds(): any;
|
|
13404
13692
|
getVisibleMapIndices(): number[];
|
|
@@ -13409,6 +13697,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/Mappedin
|
|
|
13409
13697
|
scrollMapsDown(): Promise<any>;
|
|
13410
13698
|
destroy(): void;
|
|
13411
13699
|
}
|
|
13700
|
+
import { Vector3 } from 'three';
|
|
13701
|
+
import { Box3 } from 'three';
|
|
13412
13702
|
}
|
|
13413
13703
|
|
|
13414
13704
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/FlatLabels' {
|
|
@@ -13909,39 +14199,247 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/BlueDo
|
|
|
13909
14199
|
}
|
|
13910
14200
|
}
|
|
13911
14201
|
|
|
13912
|
-
declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/
|
|
13913
|
-
import {
|
|
13914
|
-
|
|
13915
|
-
* @hidden
|
|
13916
|
-
*/
|
|
13917
|
-
export type TGLTFExportOptions = {
|
|
13918
|
-
onlyVisible?: boolean;
|
|
13919
|
-
binary?: boolean;
|
|
13920
|
-
scale?: number;
|
|
13921
|
-
};
|
|
14202
|
+
declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Camera' {
|
|
14203
|
+
import { E_CAMERA_DIRECTION } from '@mappedin/mappedin-js/packages/legacy-renderer/MapView.enums';
|
|
14204
|
+
import CameraController, { TCameraAnimationOptions, TCameraInteractionsSetOptions, TCameraTargets, TCameraTransform, TFocusOnCameraOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/private/controllers/CameraController';
|
|
13922
14205
|
/**
|
|
13923
|
-
* API to
|
|
13924
|
-
*
|
|
13925
|
-
* @hidden
|
|
14206
|
+
* API to control and respond to the state of the camera within the scene.
|
|
13926
14207
|
*/
|
|
13927
|
-
export class
|
|
14208
|
+
export class Camera {
|
|
13928
14209
|
#private;
|
|
13929
14210
|
/**
|
|
13930
14211
|
* @hidden
|
|
13931
|
-
* @internal
|
|
13932
14212
|
*/
|
|
13933
|
-
constructor(controller:
|
|
14213
|
+
constructor(controller: CameraController);
|
|
13934
14214
|
/**
|
|
13935
|
-
*
|
|
14215
|
+
* Subscribe a function to be called when an {@link E_CAMERA_EVENT} is fired.
|
|
13936
14216
|
*
|
|
13937
|
-
*
|
|
14217
|
+
* ```ts
|
|
14218
|
+
* const cameraChangedHandler = ({ tilt, position, zoom, rotation }) => {
|
|
14219
|
+
* // Do something with the new values
|
|
14220
|
+
* };
|
|
14221
|
+
* mapView.Camera.on(E_CAMERA_EVENT.CHANGED, cameraChangedHandler);
|
|
14222
|
+
* ```
|
|
14223
|
+
*
|
|
14224
|
+
* @param eventName An {@link E_CAMERA_EVENT} that is fired when the camera changes.
|
|
14225
|
+
* @param fn A callback that gets called when the corresponding event is fired. The
|
|
14226
|
+
* callback will get passed an argument with a type that's one of {@link CAMERA_EVENT_PAYLOAD}.
|
|
13938
14227
|
*/
|
|
13939
|
-
|
|
14228
|
+
on: CameraController['on'];
|
|
14229
|
+
/**
|
|
14230
|
+
* Unsubscribe a function that was previously subscribed with {@link on}.
|
|
14231
|
+
*
|
|
14232
|
+
* ```ts
|
|
14233
|
+
* mapView.Camera.on(E_CAMERA_EVENT.CHANGED, cameraChangedHandler);
|
|
14234
|
+
*
|
|
14235
|
+
* ...
|
|
14236
|
+
*
|
|
14237
|
+
* // Something changed and I no longer want this event to fire
|
|
14238
|
+
* mapView.Camera.off(E_CAMERA_EVENT.CHANGED, cameraChangedHandler);
|
|
14239
|
+
* ```
|
|
14240
|
+
*
|
|
14241
|
+
* @param eventName An {@link E_CAMERA_EVENT} that is fired when the camera changes.
|
|
14242
|
+
* @param fn A function that was previously passed to {@link on}. The function must
|
|
14243
|
+
* have the same reference as the function that was subscribed.
|
|
14244
|
+
*/
|
|
14245
|
+
off: CameraController['off'];
|
|
14246
|
+
/**
|
|
14247
|
+
* The current camera animation, if any. Resolves when the animation finishes.
|
|
14248
|
+
*/
|
|
14249
|
+
get currentAnimation(): Promise<undefined> | undefined;
|
|
14250
|
+
/**
|
|
14251
|
+
* Current Camera zoom (in meters)
|
|
14252
|
+
*/
|
|
14253
|
+
get zoom(): number;
|
|
14254
|
+
/**
|
|
14255
|
+
* Current Camera rotation (in radians) from north
|
|
14256
|
+
*/
|
|
14257
|
+
get rotation(): number;
|
|
14258
|
+
/**
|
|
14259
|
+
* Current camera tilt angle (in radians), relative to a top-down view.
|
|
14260
|
+
*
|
|
14261
|
+
* ex: 0 means the camera is facing top-down, π/2 means the camera is
|
|
14262
|
+
* facing directly from the side.
|
|
14263
|
+
*/
|
|
14264
|
+
get tilt(): number;
|
|
14265
|
+
/**
|
|
14266
|
+
* Get the minimum distance (in meters) the camera is allowed to get to the ground.
|
|
14267
|
+
*/
|
|
14268
|
+
get minZoom(): number;
|
|
14269
|
+
/**
|
|
14270
|
+
* Set the minimum distance (in meters) the camera is allowed to get to the ground.
|
|
14271
|
+
*/
|
|
14272
|
+
set minZoom(meters: number);
|
|
14273
|
+
/**
|
|
14274
|
+
* Get the maximum distance (in meters) the camera is allowed to get from the ground.
|
|
14275
|
+
*/
|
|
14276
|
+
get maxZoom(): number;
|
|
14277
|
+
/**
|
|
14278
|
+
* Set the maximum distance (in meters) the camera is allowed to get from the ground.
|
|
14279
|
+
*/
|
|
14280
|
+
set maxZoom(meters: number);
|
|
14281
|
+
/**
|
|
14282
|
+
* Get the current maximum tilt angle (in radians) the camera is allowed to use.
|
|
14283
|
+
*/
|
|
14284
|
+
get maxTilt(): number;
|
|
14285
|
+
/**
|
|
14286
|
+
* Sets the maximum tilt angle (in radians) the camera is allowed to use.
|
|
14287
|
+
*
|
|
14288
|
+
* Tilt angle must be between 0 and π/2 radians. It will be clamped within
|
|
14289
|
+
* this range if it exceeds it on either end.
|
|
14290
|
+
*
|
|
14291
|
+
* As tilt angle approaches π/2 radians, this will impact overall touch controls
|
|
14292
|
+
* and should be used sparingly.
|
|
14293
|
+
*/
|
|
14294
|
+
set maxTilt(radians: number);
|
|
14295
|
+
/**
|
|
14296
|
+
* Get the current camera position, which is at the center of the map.
|
|
14297
|
+
* @returns the position as a coordinate
|
|
14298
|
+
*/
|
|
14299
|
+
get position(): import("../../index.rn").MappedinCoordinate;
|
|
14300
|
+
/**
|
|
14301
|
+
* Enable or disable the ability for the user to interact with the camera (e.g. pan, zoom, tilt, etc).
|
|
14302
|
+
* This does not affect programmatic camera controls, such as {@link set} and {@link focusOn}.
|
|
14303
|
+
*
|
|
14304
|
+
* ```ts
|
|
14305
|
+
* // The user can no longer interact to move the camera
|
|
14306
|
+
* mapView.Camera.interactions.disable();
|
|
14307
|
+
*
|
|
14308
|
+
* // The user can now interact to move the camera again
|
|
14309
|
+
* mapView.Camera.interactions.enable();
|
|
14310
|
+
* ```
|
|
14311
|
+
*/
|
|
14312
|
+
interactions: {
|
|
14313
|
+
/**
|
|
14314
|
+
* Enable or disable specific user interactions.
|
|
14315
|
+
*
|
|
14316
|
+
* ```ts
|
|
14317
|
+
* mapView.Camera.interactions.set({ zoom: false });
|
|
14318
|
+
* ```
|
|
14319
|
+
*
|
|
14320
|
+
* @param options An object defining the interactions to switch on or off.
|
|
14321
|
+
*
|
|
14322
|
+
*/
|
|
14323
|
+
set: (options: TCameraInteractionsSetOptions) => void;
|
|
14324
|
+
/**
|
|
14325
|
+
* Enable all user interactions.
|
|
14326
|
+
*/
|
|
14327
|
+
enable: () => void;
|
|
14328
|
+
/**
|
|
14329
|
+
* Disable all user interactions.
|
|
14330
|
+
*/
|
|
14331
|
+
disable: () => void;
|
|
14332
|
+
};
|
|
14333
|
+
/**
|
|
14334
|
+
* Define an area of the screen that is safe for the camera. Anything outside the safe area is
|
|
14335
|
+
* assumed to be covered in some way (e.g. by UI) meaning the camera will not place
|
|
14336
|
+
* any map elements there when calling {@link focusOn}.
|
|
14337
|
+
*
|
|
14338
|
+
* ```ts
|
|
14339
|
+
* // The top 100px of the canvas are covered by a UI element
|
|
14340
|
+
* mapView.Camera.setSafeAreaInsets({ top: 100, left: 0, bottom: 0, right: 0});
|
|
14341
|
+
* mapView.Camera.focusOn({ nodes });
|
|
14342
|
+
* ```
|
|
14343
|
+
*
|
|
14344
|
+
* @param insets An object defining a number of pixels from the top, left, bottom, and right of
|
|
14345
|
+
* the screen. Only the area within the padding defined by these pixels is considered safe.
|
|
14346
|
+
*/
|
|
14347
|
+
setSafeAreaInsets(insets: {
|
|
14348
|
+
top: number;
|
|
14349
|
+
left: number;
|
|
14350
|
+
bottom: number;
|
|
14351
|
+
right: number;
|
|
14352
|
+
}): void;
|
|
14353
|
+
/**
|
|
14354
|
+
* Retrieve the values previously set by {@link setSafeAreaInsets}.
|
|
14355
|
+
*
|
|
14356
|
+
* @returns An object defining a number of pixels from the top, left, bottom, and right of
|
|
14357
|
+
* the screen.
|
|
14358
|
+
*/
|
|
14359
|
+
getSafeAreaInsets(): import("../../MapView.types").TPadding;
|
|
14360
|
+
/**
|
|
14361
|
+
* Animate the camera to focus on a collection of targets. To control where the targets should
|
|
14362
|
+
* be placed on screen, either specify `safeAreaInsets` on the {@link TFocusOnCameraOptions}
|
|
14363
|
+
* or call {@link setSafeAreaInsets}.
|
|
14364
|
+
*
|
|
14365
|
+
* ```ts
|
|
14366
|
+
* const location = mapView.venue.locations.find((l) => l.name === "My Location")!;
|
|
14367
|
+
*
|
|
14368
|
+
* mapView.Camera.focusOn({
|
|
14369
|
+
* polygons: location.polygons,
|
|
14370
|
+
* nodes: location.nodes,
|
|
14371
|
+
* });
|
|
14372
|
+
* ```
|
|
14373
|
+
*
|
|
14374
|
+
* @param targets A collection of things that the camera will place into view at the end of the
|
|
14375
|
+
* animation.
|
|
14376
|
+
* @param options
|
|
14377
|
+
* @returns a Promise that resolves when the animation finishes, or rejects when it is cancelled.
|
|
14378
|
+
*/
|
|
14379
|
+
focusOn(targets: TCameraTargets, options?: TFocusOnCameraOptions & TCameraAnimationOptions): Promise<any>;
|
|
14380
|
+
/**
|
|
14381
|
+
* Instantaneously set the camera's transform to be in a new configuration. See also {@link animate}.
|
|
14382
|
+
*
|
|
14383
|
+
* ```ts
|
|
14384
|
+
* const coord = mapView.venue.maps[0].createCoordinate(33.66107, 31.83911);
|
|
14385
|
+
*
|
|
14386
|
+
* // Place the camera top-down at a specified coordinate
|
|
14387
|
+
* mapView.Camera.set({
|
|
14388
|
+
* tilt: 0,
|
|
14389
|
+
* position: coord,
|
|
14390
|
+
* });
|
|
14391
|
+
* ```
|
|
14392
|
+
*
|
|
14393
|
+
* @param transform The new transform of the camera.
|
|
14394
|
+
*/
|
|
14395
|
+
set(transform: TCameraTransform): void;
|
|
14396
|
+
/**
|
|
14397
|
+
* Convert a Mercator Zoom Level to altitude, which can be used in the Camera APIs
|
|
14398
|
+
*/
|
|
14399
|
+
convertZoomLevelToAltitude(zoomLevel: number): any;
|
|
14400
|
+
/**
|
|
14401
|
+
* Convert the altitude returned by getZoom into Mercator Zoom level
|
|
14402
|
+
*/
|
|
14403
|
+
convertAltitudeToZoomLevel(altitude: number): any;
|
|
14404
|
+
/**
|
|
14405
|
+
* Smoothly transition the camera's transform to be in a new configuration. See also {@link set}.
|
|
14406
|
+
*
|
|
14407
|
+
* ```ts
|
|
14408
|
+
* const coord = mapView.venue.maps[0].createCoordinate(33.66107, 31.83911);
|
|
14409
|
+
*
|
|
14410
|
+
* // Animate the camera to be top-down at a specified coordinate
|
|
14411
|
+
* mapView.Camera.animate({
|
|
14412
|
+
* tilt: 0,
|
|
14413
|
+
* position: coord,
|
|
14414
|
+
* });
|
|
14415
|
+
* ```
|
|
14416
|
+
*
|
|
14417
|
+
* @param transform The new transform of the camera.
|
|
14418
|
+
* @param options
|
|
14419
|
+
* @returns a Promise that resolves when the animation finishes, or rejects when it is cancelled.
|
|
14420
|
+
*/
|
|
14421
|
+
animate(transform: TCameraTransform, options?: TCameraAnimationOptions): Promise<undefined>;
|
|
14422
|
+
/**
|
|
14423
|
+
* Moves the Camera view in a relative direction by a given distance in meters.
|
|
14424
|
+
*
|
|
14425
|
+
* ```ts
|
|
14426
|
+
* // Move the camera 50 meters up relative to the camera frame
|
|
14427
|
+
* mapView.Camera.translate(E_CAMERA_DIRECTION.UP, 50);
|
|
14428
|
+
* ```
|
|
14429
|
+
*
|
|
14430
|
+
* @returns a Promise that resolves when the translation animation finishes, or rejects when it is cancelled.
|
|
14431
|
+
*/
|
|
14432
|
+
translate(direction: E_CAMERA_DIRECTION, distance: number, options?: TCameraAnimationOptions): Promise<unknown>;
|
|
14433
|
+
/**
|
|
14434
|
+
* Cancel the currently active Camera animation.
|
|
14435
|
+
*/
|
|
14436
|
+
cancelAnimation(): void;
|
|
13940
14437
|
}
|
|
13941
14438
|
}
|
|
13942
14439
|
|
|
13943
14440
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/StackedMaps' {
|
|
13944
14441
|
import { MappedinMap } from '@mappedin/mappedin-js/packages/get-venue';
|
|
14442
|
+
import { TStackedMapsOptions } from '@mappedin/mappedin-js/packages/legacy-renderer/MapView.types';
|
|
13945
14443
|
import { STACKED_MAPS_STATE, StackedMapsController, TCameraTransform } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
13946
14444
|
/**
|
|
13947
14445
|
* @experimental
|
|
@@ -13955,7 +14453,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Stacke
|
|
|
13955
14453
|
constructor(markersController: StackedMapsController);
|
|
13956
14454
|
/**
|
|
13957
14455
|
* @experimental
|
|
13958
|
-
* Enable Stacked Maps.
|
|
14456
|
+
* Enable Stacked Maps. If a {@link Journey} is drawn beforehand the default behaviour is to only display the floors that are part of the journey.
|
|
14457
|
+
* {@link TStackedMapsOptions} can be used to enabling display of all maps including those that are not part of the journey.
|
|
13959
14458
|
* Use {@link showOverview} to expand the maps vertically after enabling.
|
|
13960
14459
|
*
|
|
13961
14460
|
* Upon enabling, map state will become {@link STATE.STACKED | STACKED} and Stacked Maps state will become {@link STACKED_MAPS_STATE.ACTIVE | ACTIVE}.
|
|
@@ -13976,9 +14475,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Stacke
|
|
|
13976
14475
|
*
|
|
13977
14476
|
* @returns Promise when all animations are complete.
|
|
13978
14477
|
*/
|
|
13979
|
-
enable: (opts?:
|
|
13980
|
-
verticalDistanceBetweenMaps?: number;
|
|
13981
|
-
}) => Promise<void>;
|
|
14478
|
+
enable: (opts?: TStackedMapsOptions) => Promise<void>;
|
|
13982
14479
|
/**
|
|
13983
14480
|
* @experimental
|
|
13984
14481
|
*
|
|
@@ -13995,7 +14492,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Stacke
|
|
|
13995
14492
|
/**
|
|
13996
14493
|
* @experimental
|
|
13997
14494
|
*
|
|
13998
|
-
* Expand
|
|
14495
|
+
* Expand and display all maps in the current {@link MapGroup}. If a {@link Journey} has been drawn, vertical paths between connections are displayed.
|
|
13999
14496
|
* Stacked Maps must be enabled beforehand and state will become {@link STACKED_MAPS_STATE.OVERVIEW | OVERVIEW}.
|
|
14000
14497
|
*
|
|
14001
14498
|
* @example
|
|
@@ -14046,6 +14543,27 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Stacke
|
|
|
14046
14543
|
* @returns Promise when all animations are complete.
|
|
14047
14544
|
*/
|
|
14048
14545
|
zoomInToMap: (map: MappedinMap, cameraTransform?: TCameraTransform) => Promise<void>;
|
|
14546
|
+
/**
|
|
14547
|
+
* @experimental
|
|
14548
|
+
*
|
|
14549
|
+
* Used when in {@link STACKED_MAPS_STATE.OVERVIEW | OVERVIEW} state to replace the maps in the
|
|
14550
|
+
* current stack after clearing or creating a {@link Journey}.
|
|
14551
|
+
* Use this to hide maps that are not part of the journey or to display all maps in the {@link MapGroup}.
|
|
14552
|
+
*
|
|
14553
|
+
* @param options - Options to adjust the overview. Each option defaults to the setting passed in {@link enable}, unless provided.
|
|
14554
|
+
*
|
|
14555
|
+
* @example
|
|
14556
|
+
* ```ts
|
|
14557
|
+
* mapView.Journey.draw(...);
|
|
14558
|
+
* mapView.StackedMaps.enable();
|
|
14559
|
+
* mapView.StackedMaps.showOverview();
|
|
14560
|
+
* mapView.Journey.clear();
|
|
14561
|
+
* mapView.StackedMaps.restack();
|
|
14562
|
+
* ```
|
|
14563
|
+
*
|
|
14564
|
+
* @returns Promise when all animations are complete.
|
|
14565
|
+
*/
|
|
14566
|
+
restack: (options?: TStackedMapsOptions) => Promise<void>;
|
|
14049
14567
|
/**
|
|
14050
14568
|
* @experimental
|
|
14051
14569
|
*
|
|
@@ -14137,6 +14655,12 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Layers
|
|
|
14137
14655
|
* Adds a GeoJSON Feature or FeatureCollection to the map as a layer. The layer name must be unique
|
|
14138
14656
|
*/
|
|
14139
14657
|
addGeoJSONLayer(layerName: string, featureOrFeatureCollection: Feature<Polygon, GeoJsonProperties | null> | FeatureCollection<Polygon, GeoJsonProperties | null>): Promise<void> | undefined;
|
|
14658
|
+
/**
|
|
14659
|
+
* @experimental
|
|
14660
|
+
* Hides a GeoJSON layer from the map and removes it from the list of layers.
|
|
14661
|
+
* It will not appear in {@link getAllLayersForMap} afterwards and can be overwritten by a new layer with the same name.
|
|
14662
|
+
*/
|
|
14663
|
+
removeGeoJSONLayer(layerName: string): Promise<void> | undefined;
|
|
14140
14664
|
}
|
|
14141
14665
|
export default LayerController;
|
|
14142
14666
|
}
|
|
@@ -14214,10 +14738,6 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/public/api/Dynami
|
|
|
14214
14738
|
export { DynamicFocus };
|
|
14215
14739
|
}
|
|
14216
14740
|
|
|
14217
|
-
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/object3D.destroy' {
|
|
14218
|
-
export default Object3D;
|
|
14219
|
-
}
|
|
14220
|
-
|
|
14221
14741
|
declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-context/Mappedin.Tile' {
|
|
14222
14742
|
import { Texture, Mesh, MeshBasicMaterial } from 'three';
|
|
14223
14743
|
import type { ICore } from '@mappedin/mappedin-js/packages/legacy-renderer/internal';
|
|
@@ -14228,8 +14748,8 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-
|
|
|
14228
14748
|
center: MappedinCoordinate;
|
|
14229
14749
|
zoomLevel: number;
|
|
14230
14750
|
mesh: Mesh;
|
|
14231
|
-
material
|
|
14232
|
-
texture
|
|
14751
|
+
material?: MeshBasicMaterial;
|
|
14752
|
+
texture?: Texture;
|
|
14233
14753
|
cache: {
|
|
14234
14754
|
tileXY?: {
|
|
14235
14755
|
tileX: number;
|
|
@@ -14246,7 +14766,7 @@ declare module '@mappedin/mappedin-js/packages/legacy-renderer/internal/outdoor-
|
|
|
14246
14766
|
rendered: boolean;
|
|
14247
14767
|
discardTexture(): void;
|
|
14248
14768
|
applyTexture(): void;
|
|
14249
|
-
render(metersPerTile: number, referenceMap: MappedinMap): Mesh
|
|
14769
|
+
render(metersPerTile: number, referenceMap: MappedinMap): Mesh<import("three").BufferGeometry<import("three").NormalBufferAttributes>, import("three").Material | import("three").Material[], import("three").Object3DEventMap>;
|
|
14250
14770
|
}
|
|
14251
14771
|
}
|
|
14252
14772
|
|