@mapxus/mapxus-map-jp 9.3.0 → 10.0.1
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 +13 -13
- package/dist/index.css +1 -1
- package/dist/index.umd.js +2 -19
- package/dist/mapxus-map-10.0.1-jp.css +0 -0
- package/dist/mapxus-map-10.0.1-jp.js +0 -0
- package/dist/utils.cjs +1 -13
- package/es/index.d.ts +1121 -1167
- package/es/index.mjs +2320 -4472
- package/es/languages-D7yV3lDz.mjs +110 -0
- package/es/style.d.ts +1 -1
- package/es/utils/index.d.ts +0 -53
- package/es/utils/index.mjs +17 -33
- package/package.json +3 -6
- package/es/context-DqAvnxfX.mjs +0 -8301
package/es/index.d.ts
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
// Generated by dts-bundle-generator v9.5.1
|
|
2
2
|
|
|
3
|
-
import { AxiosPromise } from 'axios';
|
|
4
3
|
import { GeoJsonProperties, LineString, Point } from 'geojson';
|
|
5
4
|
import maplibregl$1 from 'maplibre-gl';
|
|
6
5
|
import { ControlPosition, ExpressionSpecification, FilterSpecification, IControl, LngLat, LngLatBoundsLike, LngLatLike, MapGeoJSONFeature, MapLayerEventType, PaddingOptions, PointLike } from 'maplibre-gl';
|
|
7
6
|
import { TinyEmitter } from 'tiny-emitter';
|
|
8
7
|
|
|
8
|
+
export declare enum FloorSwitchScope {
|
|
9
|
+
VENUE = 0,
|
|
10
|
+
GLOBAL = 1
|
|
11
|
+
}
|
|
9
12
|
export declare enum PresetLanguage {
|
|
10
13
|
ENGLISH = "en",
|
|
11
14
|
CHINESE_SIMPLIFIED = "zh-Hans",
|
|
@@ -20,45 +23,6 @@ export declare enum PresetLanguage {
|
|
|
20
23
|
VIETNAMESE = "vi",
|
|
21
24
|
ARABIC = "ar"
|
|
22
25
|
}
|
|
23
|
-
export declare enum ThemeType {
|
|
24
|
-
/** @deprecated **/
|
|
25
|
-
CHRISTMAS = "christmas_mims2_v1",
|
|
26
|
-
/** @deprecated **/
|
|
27
|
-
HALLOWEEN = "halloween_mims2_v1",
|
|
28
|
-
/** @deprecated **/
|
|
29
|
-
MAPPY_BEE = "mappybee_mims2_v2",
|
|
30
|
-
/** @deprecated **/
|
|
31
|
-
MAPXUS = "mapxus_mims2_v1",
|
|
32
|
-
/** @deprecated **/
|
|
33
|
-
LANDS_D = "lands_d_mims2_v1",
|
|
34
|
-
/** @deprecated **/
|
|
35
|
-
COMMON = "common_mims2_v1",
|
|
36
|
-
/** @deprecated MAPXUS_V2 will be removed soon, please use MAPXUS_DEFAULT instead. */
|
|
37
|
-
MAPXUS_V2 = "mapxus_v2",
|
|
38
|
-
MAPXUS_DEFAULT = "mapxus_v8",
|
|
39
|
-
ROSE_TEA = "rose_tea",
|
|
40
|
-
PEAR_SORBET = "pear_sorbet",
|
|
41
|
-
CITY_WALK = "city_walk",
|
|
42
|
-
MOCHA_MOUSSE = "mocha_mousse",
|
|
43
|
-
SECTION_DISPLAY_BY_COLOR = "mapxus_v7_with_section_v2",
|
|
44
|
-
SECTION_DISPLAY_BY_CATEGORY = "mapxus_v7_with_section_v3"
|
|
45
|
-
}
|
|
46
|
-
export declare enum FloorSwitchScope {
|
|
47
|
-
VENUE = 0,
|
|
48
|
-
GLOBAL = 1
|
|
49
|
-
}
|
|
50
|
-
export declare enum AccessControlOrigin {
|
|
51
|
-
Access = "access_control",
|
|
52
|
-
Map = "map"
|
|
53
|
-
}
|
|
54
|
-
export interface IBbox {
|
|
55
|
-
maxLat: number;
|
|
56
|
-
maxLon: number;
|
|
57
|
-
minLat: number;
|
|
58
|
-
minLon: number;
|
|
59
|
-
}
|
|
60
|
-
export type TPointFeature = GeoJSON.Feature<Point, GeoJsonProperties>;
|
|
61
|
-
export type TLineStringFeature = GeoJSON.Feature<LineString, GeoJsonProperties>;
|
|
62
26
|
export type TMultilingualString = Partial<Record<PresetLanguage, string>>;
|
|
63
27
|
export interface IMultilingualName extends TMultilingualString {
|
|
64
28
|
default: string;
|
|
@@ -73,756 +37,479 @@ export interface ISharedFloor {
|
|
|
73
37
|
ordinal: string;
|
|
74
38
|
name: IMultilingualName;
|
|
75
39
|
}
|
|
76
|
-
export interface
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
itemSize?: number;
|
|
82
|
-
itemCount?: number;
|
|
83
|
-
defaultFolded?: boolean;
|
|
84
|
-
}
|
|
85
|
-
export interface ILocation {
|
|
86
|
-
lat: number;
|
|
87
|
-
lon: number;
|
|
88
|
-
}
|
|
89
|
-
export type TResponseResult<T> = AxiosPromise<{
|
|
90
|
-
code: number;
|
|
91
|
-
message: string;
|
|
92
|
-
result: T;
|
|
93
|
-
}>;
|
|
94
|
-
export type IMultilingualAddress = Record<keyof IMultilingualName, {
|
|
95
|
-
housenumber: string;
|
|
96
|
-
street: string;
|
|
97
|
-
}>;
|
|
98
|
-
export interface IBuildingBasicInfo {
|
|
99
|
-
address: IMultilingualAddress;
|
|
100
|
-
bbox: IBbox;
|
|
101
|
-
city?: string;
|
|
102
|
-
country: string;
|
|
103
|
-
description: TMultilingualString;
|
|
104
|
-
labelCenter: ILocation;
|
|
105
|
-
name: IMultilingualName;
|
|
106
|
-
region: string;
|
|
107
|
-
type: string;
|
|
108
|
-
}
|
|
109
|
-
export interface IBusinessInfo {
|
|
110
|
-
appUrl?: {
|
|
111
|
-
android?: string;
|
|
112
|
-
ios?: string;
|
|
113
|
-
};
|
|
114
|
-
businessStatus?: {
|
|
115
|
-
status: "OPEN" | "TEMPORARILY_CLOSED";
|
|
116
|
-
};
|
|
117
|
-
email?: string;
|
|
118
|
-
icon?: string;
|
|
119
|
-
openingHours?: string;
|
|
120
|
-
phone?: string;
|
|
121
|
-
photos?: Array<IPhotoSpec>;
|
|
122
|
-
publicData?: string[];
|
|
123
|
-
totalPhotoCount?: number;
|
|
124
|
-
website?: string;
|
|
125
|
-
}
|
|
126
|
-
export interface IMapServices {
|
|
127
|
-
signalMap: boolean;
|
|
128
|
-
visualMap: boolean;
|
|
129
|
-
}
|
|
130
|
-
export interface IFloorBase {
|
|
131
|
-
id: string;
|
|
132
|
-
ordinal: number;
|
|
133
|
-
}
|
|
134
|
-
export interface IBuildingInlineFloor extends IFloorBase, IMapServices {
|
|
135
|
-
code: string;
|
|
136
|
-
}
|
|
137
|
-
export interface IBuilding extends IBuildingBasicInfo, IBusinessInfo, IMapServices {
|
|
138
|
-
buildingId: string;
|
|
139
|
-
buildingName: IMultilingualName;
|
|
140
|
-
buildingOutlineId: number;
|
|
141
|
-
defaultFloor?: string;
|
|
142
|
-
floors: IBuildingInlineFloor[];
|
|
143
|
-
groundFloor: string;
|
|
144
|
-
isPrivate: "yes" | "no";
|
|
145
|
-
organization: string;
|
|
146
|
-
venueId: string;
|
|
147
|
-
venueName: IMultilingualName;
|
|
148
|
-
}
|
|
149
|
-
export interface IResponseBuildings {
|
|
150
|
-
buildings: IBuilding[];
|
|
151
|
-
total: number;
|
|
152
|
-
}
|
|
153
|
-
export type TPromiseBuildings = TResponseResult<IResponseBuildings>;
|
|
154
|
-
export declare enum DistanceSearchType {
|
|
155
|
-
POINT = "Point",
|
|
156
|
-
POLYGON = "Polygon"
|
|
157
|
-
}
|
|
158
|
-
export declare enum OrientationDistanceSearchType {
|
|
159
|
-
POINT = "Point",
|
|
160
|
-
POLYGON = "Polygon",
|
|
161
|
-
GATE = "Gate"
|
|
162
|
-
}
|
|
163
|
-
export declare enum PoisOrderBy {
|
|
164
|
-
DEFAULT_NAME = "DefaultName"
|
|
165
|
-
}
|
|
166
|
-
export declare enum PoisSortBy {
|
|
167
|
-
ABSOLUTE_DISTANCE = "AbsoluteDistance",
|
|
168
|
-
ACTUAL_DISTANCE = "ActualDistance"
|
|
40
|
+
export interface ISelectedHighlightStyle {
|
|
41
|
+
lineWidth?: number;
|
|
42
|
+
lineColor?: string;
|
|
43
|
+
lineOpacity?: number;
|
|
44
|
+
lineOffset?: number;
|
|
169
45
|
}
|
|
170
|
-
export
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
46
|
+
export type TSelectedIndoorData = {
|
|
47
|
+
venue: MapGeoJSONFeature;
|
|
48
|
+
building: MapGeoJSONFeature;
|
|
49
|
+
floor?: IFloor;
|
|
50
|
+
} | {
|
|
51
|
+
sharedFloor: ISharedFloor;
|
|
52
|
+
venue: MapGeoJSONFeature;
|
|
53
|
+
} | null;
|
|
54
|
+
export type TFeatureMap = Map<string, MapGeoJSONFeature>;
|
|
55
|
+
export interface ILayeredOptions {
|
|
56
|
+
selectedVenueId: string | null;
|
|
57
|
+
venueMap: TFeatureMap;
|
|
58
|
+
buildingMap: TFeatureMap;
|
|
59
|
+
sharedFloorMap: TFeatureMap;
|
|
175
60
|
}
|
|
176
|
-
export interface
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
descriptions: IMultilingualName;
|
|
180
|
-
distance?: number;
|
|
181
|
-
id: string;
|
|
182
|
-
location: ILocation;
|
|
183
|
-
name: IMultilingualName;
|
|
184
|
-
osmRefId: number;
|
|
185
|
-
poiId: string;
|
|
186
|
-
sections?: ISection[];
|
|
61
|
+
export interface IDisplayedLevel {
|
|
62
|
+
level: string;
|
|
63
|
+
overlap: string[] | null;
|
|
187
64
|
venueId: string;
|
|
188
65
|
}
|
|
189
|
-
export interface
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
sharedFloorNames: IMultilingualName;
|
|
196
|
-
}
|
|
197
|
-
export type TSizes = "original" | "thumbnail" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
|
|
198
|
-
export type TPhotoSizeSpec = Partial<Record<TSizes, {
|
|
199
|
-
pixelWidth: number;
|
|
200
|
-
pixelHeight: number;
|
|
201
|
-
url: string;
|
|
202
|
-
}>>;
|
|
203
|
-
export interface IPhotoSpec {
|
|
204
|
-
aspectRatio: string;
|
|
205
|
-
coordinates: {
|
|
206
|
-
longitude: number;
|
|
207
|
-
latitude: number;
|
|
208
|
-
};
|
|
209
|
-
dateAdded: string;
|
|
210
|
-
id: string;
|
|
211
|
-
photoBy: string;
|
|
212
|
-
photoSizes: TPhotoSizeSpec;
|
|
213
|
-
source: string;
|
|
214
|
-
type: string;
|
|
215
|
-
}
|
|
216
|
-
export interface IPoi extends IPoiFloor, IPoiCommonOptions, IBusinessInfo {
|
|
217
|
-
buildingId: string;
|
|
218
|
-
}
|
|
219
|
-
export interface ISharedPoi extends ISharedPoiFloor, IPoiCommonOptions {
|
|
220
|
-
}
|
|
221
|
-
export type TPromisePois<T> = TResponseResult<{
|
|
222
|
-
pois: T[];
|
|
223
|
-
total: number;
|
|
224
|
-
}>;
|
|
225
|
-
/** poi categories from searchCategories() */
|
|
226
|
-
export interface IPoiCategory {
|
|
227
|
-
category: string;
|
|
228
|
-
description: string | null;
|
|
229
|
-
id: string;
|
|
230
|
-
title: TMultilingualString;
|
|
231
|
-
}
|
|
232
|
-
export interface ICategoryGroupItem extends IPoiCategory {
|
|
233
|
-
count: number;
|
|
234
|
-
featureType: string;
|
|
235
|
-
parents: string[];
|
|
236
|
-
venueId: string;
|
|
237
|
-
venueName: TMultilingualString;
|
|
66
|
+
export interface ILayeredData {
|
|
67
|
+
displayedLevels: IDisplayedLevel[];
|
|
68
|
+
selectedLevelIds: string[];
|
|
69
|
+
alwaysDisplayedSharedLevelIds: string[];
|
|
70
|
+
maskBuildingIds: string[];
|
|
71
|
+
maskSharedFloorIds: string[];
|
|
238
72
|
}
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
73
|
+
declare class FloorsLayeredHandler {
|
|
74
|
+
private _isMaskMode;
|
|
75
|
+
private _hiddenBuildings;
|
|
76
|
+
private _history;
|
|
77
|
+
constructor(maskMode: boolean);
|
|
78
|
+
getLayeredData(options: ILayeredOptions): ILayeredData;
|
|
79
|
+
getHiddenBuildings(): string[];
|
|
242
80
|
}
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
81
|
+
declare class DragPanHandler {
|
|
82
|
+
private _maplibre;
|
|
83
|
+
private _isAnimated;
|
|
84
|
+
private _bounds;
|
|
85
|
+
private _boundsPadding;
|
|
86
|
+
private _center;
|
|
87
|
+
private _fitBoundsTimer;
|
|
88
|
+
constructor(maplibre: maplibregl$1.Map, padding: number | PaddingOptions);
|
|
89
|
+
setAnimated(animated: boolean): void;
|
|
90
|
+
setBounds(bounds: LngLatBoundsLike | null): void;
|
|
91
|
+
getBounds(): LngLatBoundsLike | null;
|
|
92
|
+
setCenter(lnglat: LngLatLike | null): void;
|
|
93
|
+
fitBounds(): Promise<unknown>;
|
|
94
|
+
panToCenter(): void;
|
|
256
95
|
}
|
|
257
|
-
export
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
* 'venueId', 'buildingId', 'floorId', 'poiId' are mutually exclusive,
|
|
318
|
-
* the priority is: poiId > floorId > buildingId > venueId.
|
|
319
|
-
*/
|
|
320
|
-
buildingId?: string;
|
|
321
|
-
/**
|
|
322
|
-
* 'venueId', 'buildingId', 'floorId', 'poiId' are mutually exclusive,
|
|
323
|
-
* the priority is: poiId > floorId > buildingId > venueId.
|
|
324
|
-
*/
|
|
325
|
-
floorId?: string;
|
|
326
|
-
sharedFloorId?: string;
|
|
327
|
-
/**
|
|
328
|
-
* Initialize the map with POI as the center point, use it with maplibregl.Map 'zoom' option.
|
|
329
|
-
* 'venueId', 'buildingId', 'floorId', 'poiId' are mutually exclusive,
|
|
330
|
-
* the priority is: poiId > floorId > buildingId > venueId.
|
|
331
|
-
*/
|
|
332
|
-
poiId?: string;
|
|
333
|
-
outdoorMapShown?: boolean;
|
|
334
|
-
theme?: ThemeType | string;
|
|
335
|
-
/** @deprecated 'collapseCopyright' will be removed soon. You'd not use it. */
|
|
336
|
-
collapseCopyright?: boolean;
|
|
337
|
-
selectedHighlightStyle?: ISelectedHighlightStyle;
|
|
338
|
-
floorSelectorStyle?: IFloorSelectorStyle;
|
|
339
|
-
/**
|
|
340
|
-
* Whether unselected buildings are masked, default is false.
|
|
341
|
-
*/
|
|
342
|
-
maskNonSelectedAreas?: boolean;
|
|
343
|
-
/**
|
|
344
|
-
* @deprecated use "fitBounds" instead.
|
|
345
|
-
* Whether the boundary of the selected building fits the screen, default is false.
|
|
346
|
-
* Can only be used for 'floorId', 'buildingId' and 'venueId' initialization, not for 'poiId'.
|
|
347
|
-
* When it is true, the 'boundsPadding' option is valid, and the 'zoom' option of maplibregl.Map is invalid.
|
|
348
|
-
*/
|
|
349
|
-
fitBuildingBounds?: boolean;
|
|
350
|
-
fitBounds?: boolean;
|
|
351
|
-
/**
|
|
352
|
-
* The amount of padding in pixels to add to the given bounds, default is 30.
|
|
353
|
-
* Requires 'fitBuildingBounds' to be 'true'.
|
|
354
|
-
* Parameter value ref to: https://maplibre.org/maplibre-gl-js/docs/API/types/maplibregl.PaddingOptions/
|
|
355
|
-
*/
|
|
356
|
-
boundsPadding?: number | maplibregl$1.PaddingOptions;
|
|
357
|
-
language?: PresetLanguage;
|
|
358
|
-
/** Auto Select Building by panning building to map center, default is false. */
|
|
359
|
-
autoSelectBuilding?: boolean;
|
|
360
|
-
transformRequest?: maplibregl$1.RequestTransformFunction | null;
|
|
361
|
-
mapxusLogoEnabled?: boolean;
|
|
362
|
-
enableIndoorClickSelection?: boolean;
|
|
363
|
-
enableOutdoorClickSelection?: boolean;
|
|
364
|
-
floorSwitchScope?: FloorSwitchScope;
|
|
365
|
-
}
|
|
366
|
-
export interface IMapAccessWithAppId {
|
|
367
|
-
appId: string;
|
|
368
|
-
secret: string;
|
|
369
|
-
/**
|
|
370
|
-
* get accessToken of the specific platform(ios or android), optional, default is web
|
|
371
|
-
* @private
|
|
372
|
-
*/
|
|
373
|
-
platform?: TPlatform;
|
|
374
|
-
}
|
|
375
|
-
export interface ITokenResponse {
|
|
376
|
-
accessToken: string;
|
|
377
|
-
/** timestamp */
|
|
378
|
-
expiredTime: number;
|
|
379
|
-
identifier?: string;
|
|
380
|
-
sdkVersion?: string;
|
|
381
|
-
}
|
|
382
|
-
export type TAccessTokenGetter = () => Promise<ITokenResponse>;
|
|
383
|
-
export interface IMapAccessWithToken {
|
|
384
|
-
getTokenAsync: TAccessTokenGetter;
|
|
385
|
-
}
|
|
386
|
-
export type TMapKeys = IMapAccessWithAppId | IMapAccessWithToken;
|
|
387
|
-
export type IMapOption = IMapOtherOptions & TMapKeys;
|
|
388
|
-
export type TAnchorPosition = "center" | "left" | "right" | "top" | "bottom" | "top-left" | "top-right" | "bottom-left" | "bottom-right";
|
|
389
|
-
export interface IMarkerOptions {
|
|
390
|
-
lngLat: [
|
|
391
|
-
number,
|
|
392
|
-
number
|
|
393
|
-
];
|
|
394
|
-
properties?: {
|
|
395
|
-
[k: string]: string;
|
|
396
|
-
};
|
|
397
|
-
}
|
|
398
|
-
export interface IMarkerOptionsWithFeatureId extends IMarkerOptions {
|
|
399
|
-
featureId: number;
|
|
400
|
-
}
|
|
401
|
-
export interface ITokenInfo {
|
|
402
|
-
"app:name": string;
|
|
403
|
-
auth_time: number;
|
|
404
|
-
"cognito:username": string;
|
|
405
|
-
"custom:organization": string;
|
|
406
|
-
exp: number;
|
|
407
|
-
iat: number;
|
|
408
|
-
organization: string;
|
|
409
|
-
"organization:name": string;
|
|
410
|
-
privatization_type: string;
|
|
411
|
-
username: string;
|
|
412
|
-
}
|
|
413
|
-
export declare enum VehicleType {
|
|
414
|
-
FOOT = "foot",
|
|
415
|
-
WHEELCHAIR = "wheelchair",
|
|
416
|
-
ESCALATOR = "escalator",
|
|
417
|
-
EMERGENCY = "emergency"
|
|
418
|
-
}
|
|
419
|
-
export interface IRouteInfo {
|
|
420
|
-
copyrights: string[];
|
|
421
|
-
took: number;
|
|
422
|
-
}
|
|
423
|
-
export interface IInstruction {
|
|
424
|
-
building_id: string;
|
|
425
|
-
distance: number;
|
|
426
|
-
floor_id: string;
|
|
427
|
-
heading: number;
|
|
428
|
-
interval: [
|
|
429
|
-
number,
|
|
430
|
-
number
|
|
431
|
-
];
|
|
432
|
-
on_shared_floor: boolean;
|
|
433
|
-
ordinal: number;
|
|
434
|
-
sign: number;
|
|
435
|
-
street_name: string;
|
|
436
|
-
text: string;
|
|
437
|
-
time: number;
|
|
438
|
-
type: string | null;
|
|
439
|
-
venue_id: string;
|
|
440
|
-
}
|
|
441
|
-
export interface IRoutePath {
|
|
442
|
-
bbox: [
|
|
443
|
-
number,
|
|
444
|
-
number,
|
|
445
|
-
number,
|
|
446
|
-
number
|
|
447
|
-
];
|
|
448
|
-
distance: number;
|
|
449
|
-
instructions: IInstruction[];
|
|
450
|
-
points: {
|
|
451
|
-
coordinates: Array<[
|
|
452
|
-
number,
|
|
453
|
-
number
|
|
454
|
-
]>;
|
|
455
|
-
type: string;
|
|
456
|
-
};
|
|
457
|
-
snapped_waypoints: {
|
|
458
|
-
coordinates: Array<[
|
|
459
|
-
number,
|
|
460
|
-
number
|
|
461
|
-
]>;
|
|
462
|
-
type: string;
|
|
463
|
-
};
|
|
464
|
-
time: number;
|
|
465
|
-
}
|
|
466
|
-
export interface IResponseRoute {
|
|
467
|
-
infos: IRouteInfo | null;
|
|
468
|
-
paths: IRoutePath[];
|
|
469
|
-
}
|
|
470
|
-
export type TPromiseRoute = TResponseResult<IResponseRoute>;
|
|
471
|
-
export interface IRoutePoint {
|
|
472
|
-
lat: number;
|
|
473
|
-
lon: number;
|
|
474
|
-
floorId?: string;
|
|
475
|
-
}
|
|
476
|
-
export interface IRouteSearchOptions {
|
|
477
|
-
/**
|
|
478
|
-
* Points are in order, from -> stops -> to.
|
|
479
|
-
* The length of points must be: 1 < {points.length} < 6.
|
|
480
|
-
*/
|
|
481
|
-
points: IRoutePoint[];
|
|
482
|
-
/**
|
|
483
|
-
* Default is "foot".
|
|
484
|
-
*/
|
|
485
|
-
vehicle?: VehicleType;
|
|
486
|
-
/**
|
|
487
|
-
* Language-specific response. Default is "en".
|
|
488
|
-
*/
|
|
489
|
-
locale?: PresetLanguage;
|
|
490
|
-
}
|
|
491
|
-
export interface IRouteMarkers {
|
|
492
|
-
from: string | null;
|
|
493
|
-
to: string | null;
|
|
494
|
-
stops: Array<string | null> | null;
|
|
495
|
-
}
|
|
496
|
-
export interface IRouteStyle<T> {
|
|
497
|
-
indoorLineColor?: string | ExpressionSpecification;
|
|
498
|
-
outdoorLineColor?: string | ExpressionSpecification;
|
|
499
|
-
dashedLineColor?: string | ExpressionSpecification;
|
|
500
|
-
shuttleBusLineColor?: string | ExpressionSpecification;
|
|
501
|
-
lineWidth?: number | ExpressionSpecification;
|
|
502
|
-
dashedLineWidth?: number | ExpressionSpecification;
|
|
503
|
-
disableDashedLine?: boolean;
|
|
504
|
-
/** Optional number in range [0, 1]. Defaults to 0.5. "inactiveRouteOpacity" will be 1 if the parameter is greater than 1, and it will be 0 if the parameter is less than 0. */
|
|
505
|
-
inactiveRouteOpacity?: number;
|
|
506
|
-
/** Optional number in range [0, 1]. Defaults to 1. "outdoorLineOpacity" will be 1 if the parameter is greater than 1, and it will be 0 if the parameter is less than 0. */
|
|
507
|
-
outdoorLineOpacity?: number;
|
|
508
|
-
markers?: T;
|
|
509
|
-
markerIconSize?: number | ExpressionSpecification;
|
|
510
|
-
lineSymbol?: {
|
|
511
|
-
/**
|
|
512
|
-
* Icon url or sprite name.
|
|
513
|
-
*/
|
|
514
|
-
image?: string | null;
|
|
515
|
-
size?: number | ExpressionSpecification;
|
|
516
|
-
spacing?: number | ExpressionSpecification;
|
|
517
|
-
};
|
|
518
|
-
}
|
|
519
|
-
export type TRouteStyleOptions = IRouteStyle<Partial<IRouteMarkers> | Array<string | null>>;
|
|
520
|
-
export declare class RoutePainter {
|
|
521
|
-
private readonly _maplibreMap;
|
|
522
|
-
private _routeStyle;
|
|
523
|
-
private _styleDiffs;
|
|
524
|
-
private _filterBy;
|
|
525
|
-
private _curVenue;
|
|
526
|
-
private _curBuilding;
|
|
527
|
-
private _curOrdinal;
|
|
528
|
-
private _renderBoundaryLayer;
|
|
529
|
-
constructor(maplibreMap: maplibregl$1.Map, routeStyle?: TRouteStyleOptions);
|
|
96
|
+
export declare class Indoor extends TinyEmitter {
|
|
97
|
+
private _map;
|
|
98
|
+
private _features;
|
|
99
|
+
private _allVenuesMap;
|
|
100
|
+
private _allBuildingsMap;
|
|
101
|
+
private _allSharedLevelsMap;
|
|
102
|
+
private _curBuildingId;
|
|
103
|
+
private _curBuildingFeature;
|
|
104
|
+
private _curSharedLevelId;
|
|
105
|
+
private _floor;
|
|
106
|
+
private _sharedFloor;
|
|
107
|
+
private _outdoorMapShown;
|
|
108
|
+
private _originIndoorLayers;
|
|
109
|
+
private _outdoorLayers;
|
|
110
|
+
private _curVenueId;
|
|
111
|
+
private _curVenueFeature;
|
|
112
|
+
private _selectedHighlightStyle;
|
|
113
|
+
private _upperLayers;
|
|
114
|
+
private _commonPoiLayers;
|
|
115
|
+
private _sectionFillLineLayers;
|
|
116
|
+
private _sectionSymbolLayers;
|
|
117
|
+
private _middleLayers;
|
|
118
|
+
private _lowerLayers;
|
|
119
|
+
private _excludedPoisInMiddle;
|
|
120
|
+
private _dispatch;
|
|
121
|
+
private readonly _startWithIndoorView;
|
|
122
|
+
private _indoorMapLoaded;
|
|
123
|
+
private _isSelectSharedFloor;
|
|
124
|
+
private readonly _isMaskMode;
|
|
125
|
+
private _upperLevels;
|
|
126
|
+
private _middleLevels;
|
|
127
|
+
private _lowerLevels;
|
|
128
|
+
private _featureIncomplete;
|
|
129
|
+
private _fitBounds;
|
|
130
|
+
private _dragPan;
|
|
131
|
+
private _history;
|
|
132
|
+
private _maskBuildings;
|
|
133
|
+
private _maskSharedFloors;
|
|
134
|
+
private _enableIndoorClickSelection;
|
|
135
|
+
private _enableOutdoorClickSelection;
|
|
136
|
+
private _zIndexHistory;
|
|
137
|
+
private _floorSwitchScope;
|
|
138
|
+
private _isDestroyed;
|
|
139
|
+
private _abortQueryFeature;
|
|
140
|
+
private _debounceRendering;
|
|
141
|
+
layeredHandler: FloorsLayeredHandler;
|
|
142
|
+
dragPanHandler: DragPanHandler;
|
|
143
|
+
constructor(props: {
|
|
144
|
+
map: maplibregl$1.Map;
|
|
145
|
+
fitBounds: boolean;
|
|
146
|
+
boundsPadding: number | PaddingOptions;
|
|
147
|
+
maskNonSelectedAreas: boolean;
|
|
148
|
+
startWithIndoorView: boolean;
|
|
149
|
+
outdoorMapShown: boolean;
|
|
150
|
+
enableIndoorClickSelection: boolean;
|
|
151
|
+
enableOutdoorClickSelection: boolean;
|
|
152
|
+
floorSwitchScope: FloorSwitchScope;
|
|
153
|
+
selectedHighlightStyle?: ISelectedHighlightStyle;
|
|
154
|
+
});
|
|
155
|
+
destroy(): void;
|
|
530
156
|
/**
|
|
531
|
-
*
|
|
532
|
-
*
|
|
157
|
+
* @deprecated
|
|
158
|
+
* Set whether to allow exiting building.
|
|
159
|
+
* @param allow
|
|
533
160
|
*/
|
|
534
|
-
|
|
161
|
+
setAllowOutdoorSwitch(allow: boolean): this;
|
|
535
162
|
/**
|
|
536
|
-
* @deprecated
|
|
537
|
-
* Set
|
|
538
|
-
* @param
|
|
539
|
-
* Markers use images in order of icons array.
|
|
540
|
-
* First is as from-marker, last is as to-marker, the middles are as stop-markers.
|
|
541
|
-
* If icons array has only one element, all stop markers use this image.
|
|
542
|
-
* Image file must be in png, webp, or jpg format.
|
|
543
|
-
* Null means none image.
|
|
163
|
+
* @deprecated
|
|
164
|
+
* Set whether to allow switching building.
|
|
165
|
+
* @param allow
|
|
544
166
|
*/
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
}): Promise<void>;
|
|
167
|
+
setAllowBuildingSwitch(allow: boolean): this;
|
|
168
|
+
setAllowIndoorClickSelect(allow: boolean): void;
|
|
169
|
+
setAllowOutdoorClickSelect(allow: boolean): void;
|
|
170
|
+
setFloorSwitchScope(scope: FloorSwitchScope): void;
|
|
550
171
|
/**
|
|
551
|
-
*
|
|
552
|
-
* Set all icons scale.
|
|
553
|
-
* @param size number in range [0, ∞), default is 1.
|
|
172
|
+
* Get the current floor's information.
|
|
554
173
|
*/
|
|
555
|
-
|
|
174
|
+
get floor(): IFloor | ISharedFloor | null;
|
|
556
175
|
/**
|
|
557
|
-
*
|
|
558
|
-
*
|
|
559
|
-
* @param color The color type is a color in the sRGB color space.
|
|
560
|
-
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
561
|
-
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
176
|
+
* Get the current building's information.
|
|
177
|
+
* @returns {MapGeoJSONFeature | null}
|
|
562
178
|
*/
|
|
563
|
-
|
|
179
|
+
get building(): MapGeoJSONFeature | null;
|
|
564
180
|
/**
|
|
565
|
-
*
|
|
566
|
-
*
|
|
567
|
-
* @param color The color type is a color in the sRGB color space.
|
|
568
|
-
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
569
|
-
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
181
|
+
* Get the current venue's information.
|
|
182
|
+
* @returns {MapGeoJSONFeature | null}
|
|
570
183
|
*/
|
|
571
|
-
|
|
184
|
+
get venue(): MapGeoJSONFeature | null;
|
|
572
185
|
/**
|
|
573
|
-
*
|
|
574
|
-
* Set color of dashed lines which connected the start and end markers.
|
|
575
|
-
* @param color The color type is a color in the sRGB color space.
|
|
576
|
-
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
577
|
-
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
186
|
+
* Get the geo features of bbox.
|
|
578
187
|
*/
|
|
579
|
-
|
|
188
|
+
get features(): MapGeoJSONFeature[];
|
|
580
189
|
/**
|
|
581
|
-
*
|
|
582
|
-
*
|
|
583
|
-
* @param
|
|
584
|
-
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
585
|
-
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
190
|
+
* Get features from bbox by id.
|
|
191
|
+
* @param id
|
|
192
|
+
* @param options
|
|
586
193
|
*/
|
|
587
|
-
|
|
194
|
+
getFeaturesById(id: string, options?: {
|
|
195
|
+
layerIds?: string[];
|
|
196
|
+
filter?: (feature: MapGeoJSONFeature) => boolean;
|
|
197
|
+
}): MapGeoJSONFeature[];
|
|
588
198
|
/**
|
|
589
|
-
*
|
|
590
|
-
* @param
|
|
591
|
-
* @param markerLocations Coordinate([lng, lat]) array of markers, order from beginning to end.
|
|
199
|
+
* Switch floor by ordinal.
|
|
200
|
+
* @param ordinal
|
|
592
201
|
*/
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
number
|
|
596
|
-
]>): void;
|
|
202
|
+
switchFloorByOrdinal(ordinal: string | null): Promise<void>;
|
|
203
|
+
setOutdoorMapShown(shown: boolean): void;
|
|
597
204
|
/**
|
|
598
|
-
*
|
|
205
|
+
* Set the style of the selected floor border. If set to null, the border will be invisible.
|
|
206
|
+
* @param style {ISelectedHighlightStyle | null}
|
|
599
207
|
*/
|
|
600
|
-
|
|
208
|
+
setSelectedHighlightStyle(style: ISelectedHighlightStyle | null): void;
|
|
601
209
|
/**
|
|
602
|
-
*
|
|
603
|
-
* @param
|
|
604
|
-
* @param ordinal {string | null | undefined}
|
|
210
|
+
* Listen for the indoor map state, including the changes of venue, building and floor.
|
|
211
|
+
* @param listener
|
|
605
212
|
*/
|
|
606
|
-
|
|
213
|
+
onMapChange(listener: (params: {
|
|
214
|
+
venue: MapGeoJSONFeature | null;
|
|
215
|
+
building: MapGeoJSONFeature | null;
|
|
216
|
+
floor: IFloor;
|
|
217
|
+
}) => void): {
|
|
218
|
+
unsubscribe: VoidFunction;
|
|
219
|
+
};
|
|
607
220
|
/**
|
|
608
|
-
*
|
|
609
|
-
* @param
|
|
610
|
-
* @param
|
|
221
|
+
* Select a building feature
|
|
222
|
+
* @param feature {MapGeoJSONFeature | null}
|
|
223
|
+
* @param options {floorId?: string, dragPan?: boolean}
|
|
611
224
|
*/
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
private
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
225
|
+
selectBuilding(feature: MapGeoJSONFeature | null, options?: {
|
|
226
|
+
floorId?: string;
|
|
227
|
+
featureIncomplete?: boolean;
|
|
228
|
+
}): Promise<void>;
|
|
229
|
+
selectSharedFloor(sharedFloor: ISharedFloor, venue: MapGeoJSONFeature, options?: {
|
|
230
|
+
featureIncomplete?: boolean;
|
|
231
|
+
}): Promise<void>;
|
|
232
|
+
updateCustomLayers(): void;
|
|
233
|
+
updateRendering(): void;
|
|
234
|
+
panToBuildingCenter(): Promise<void>;
|
|
235
|
+
panToVenueCenter(): Promise<void>;
|
|
236
|
+
private _waitForFeatureLoaded;
|
|
237
|
+
setDragPan(dragPan: boolean | "restrict"): void;
|
|
238
|
+
setFitBounds(fitBounds: boolean): void;
|
|
239
|
+
queryIndoorFeaturesByClickPoint(point: PointLike): Promise<TSelectedIndoorData>;
|
|
240
|
+
selectByClickMap(data: TSelectedIndoorData): Promise<void>;
|
|
241
|
+
private _bindMaplibreEventListeners;
|
|
242
|
+
private _clear;
|
|
243
|
+
private _getIndoorFeatures;
|
|
244
|
+
private _getBuildingFloorByOrdinal;
|
|
245
|
+
private _isCurrentFeature;
|
|
246
|
+
private _setOutdoorVisibility;
|
|
247
|
+
private _addReserveFloorLayers;
|
|
248
|
+
private _addBuildingMaskLayer;
|
|
249
|
+
private _updateUnselectedMask;
|
|
250
|
+
private _addSelectedHighlightLayers;
|
|
251
|
+
private _filterSelectedHighlight;
|
|
252
|
+
private _copyOverlapLayers;
|
|
253
|
+
private _copySharedFloorBackgroundLayers;
|
|
254
|
+
private _updateFeatures;
|
|
255
|
+
private _calExcludedPoisInMiddle;
|
|
256
|
+
private _updateSelectedFeatures;
|
|
257
|
+
private _layerFloors;
|
|
258
|
+
private _layerSelectedLevels;
|
|
259
|
+
private _layerUnselectedLevels;
|
|
260
|
+
private _filterLayers;
|
|
261
|
+
private _filterIndoorLayers;
|
|
262
|
+
private _queryVenueFeature;
|
|
263
|
+
private _getBuildingDisplayedOrdinal;
|
|
264
|
+
private _updateFloorState;
|
|
265
|
+
private _checkAndPanToBuilding;
|
|
266
|
+
private _queryVisibleFeature;
|
|
267
|
+
private _queryRenderedFeatures;
|
|
268
|
+
private _dispatchIndoorMapLoaded;
|
|
269
|
+
private _changeOtherVenuesHistory;
|
|
270
|
+
}
|
|
271
|
+
export interface ILocation {
|
|
272
|
+
lat: number;
|
|
273
|
+
lon: number;
|
|
274
|
+
}
|
|
275
|
+
export interface IResponse<T> {
|
|
276
|
+
code: number;
|
|
277
|
+
message: string;
|
|
278
|
+
result: T;
|
|
279
|
+
}
|
|
280
|
+
export type IMultilingualAddress = Record<keyof IMultilingualName, {
|
|
281
|
+
housenumber: string;
|
|
282
|
+
street: string;
|
|
283
|
+
}>;
|
|
284
|
+
export interface IBbox {
|
|
285
|
+
maxLat: number;
|
|
286
|
+
maxLon: number;
|
|
287
|
+
minLat: number;
|
|
288
|
+
minLon: number;
|
|
289
|
+
}
|
|
290
|
+
export interface IBuildingBasicInfo {
|
|
291
|
+
address: IMultilingualAddress;
|
|
292
|
+
bbox: IBbox;
|
|
293
|
+
city?: string;
|
|
294
|
+
country: string;
|
|
295
|
+
description: TMultilingualString;
|
|
296
|
+
labelCenter: ILocation;
|
|
297
|
+
name: IMultilingualName;
|
|
298
|
+
region: string;
|
|
299
|
+
type: string;
|
|
300
|
+
}
|
|
301
|
+
export declare const omittedBuildingProps: readonly [
|
|
302
|
+
"specialHours",
|
|
303
|
+
"businessStatus",
|
|
304
|
+
"serviceHours",
|
|
305
|
+
"keywords",
|
|
306
|
+
"siteCode",
|
|
307
|
+
"refPhotoId",
|
|
308
|
+
"totalPhotoCount",
|
|
309
|
+
"photos",
|
|
310
|
+
"description"
|
|
311
|
+
];
|
|
312
|
+
export type TOmittedBuildingKeys = (typeof omittedBuildingProps)[number];
|
|
313
|
+
export type TSizes = "original" | "thumbnail" | "small" | "medium" | "large" | "xlarge" | "xxlarge";
|
|
314
|
+
export type TPhotoSizeSpec = Partial<Record<TSizes, {
|
|
315
|
+
pixelWidth: number;
|
|
316
|
+
pixelHeight: number;
|
|
317
|
+
url: string;
|
|
318
|
+
}>>;
|
|
319
|
+
export interface IPhotoSpec {
|
|
320
|
+
aspectRatio: string;
|
|
321
|
+
coordinates: {
|
|
322
|
+
longitude: number;
|
|
323
|
+
latitude: number;
|
|
324
|
+
};
|
|
325
|
+
dateAdded: string;
|
|
326
|
+
id: string;
|
|
327
|
+
photoBy: string;
|
|
328
|
+
photoSizes: TPhotoSizeSpec;
|
|
329
|
+
source: string;
|
|
330
|
+
type: string;
|
|
331
|
+
}
|
|
332
|
+
export interface IBusinessInfo {
|
|
333
|
+
appUrl?: {
|
|
334
|
+
android?: string;
|
|
335
|
+
ios?: string;
|
|
336
|
+
};
|
|
337
|
+
email?: string;
|
|
338
|
+
openingHours?: string;
|
|
339
|
+
phone?: string;
|
|
340
|
+
publicData?: string[];
|
|
341
|
+
website?: string;
|
|
342
|
+
specialHours?: string;
|
|
343
|
+
businessStatus?: {
|
|
344
|
+
status: "OPEN" | "TEMPORARILY_CLOSED";
|
|
345
|
+
};
|
|
346
|
+
serviceHours?: string;
|
|
347
|
+
keywords?: string;
|
|
348
|
+
siteCode?: string;
|
|
349
|
+
refPhotoId?: string;
|
|
350
|
+
totalPhotoCount?: number;
|
|
351
|
+
photos?: Array<IPhotoSpec>;
|
|
352
|
+
icon?: string;
|
|
353
|
+
opening_hours?: string;
|
|
354
|
+
appURL?: string;
|
|
628
355
|
}
|
|
629
|
-
export interface
|
|
630
|
-
|
|
631
|
-
|
|
356
|
+
export interface IMapServices {
|
|
357
|
+
signalMap: boolean;
|
|
358
|
+
visualMap: boolean;
|
|
632
359
|
}
|
|
633
|
-
export interface
|
|
360
|
+
export interface IFloorBase {
|
|
361
|
+
id: string;
|
|
362
|
+
ordinal: number;
|
|
363
|
+
}
|
|
364
|
+
export interface IBuildingInlineFloor extends IFloorBase, IMapServices {
|
|
365
|
+
code: string;
|
|
366
|
+
}
|
|
367
|
+
export interface IBuildingInternal extends IBuildingBasicInfo, IBusinessInfo, IMapServices {
|
|
368
|
+
buildingId: string;
|
|
634
369
|
buildingName: IMultilingualName;
|
|
635
370
|
buildingOutlineId: number;
|
|
636
371
|
defaultFloor?: string;
|
|
637
372
|
floors: IBuildingInlineFloor[];
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
number,
|
|
644
|
-
number
|
|
645
|
-
];
|
|
646
|
-
};
|
|
647
|
-
}
|
|
648
|
-
export interface IVenue extends IBuildingBasicInfo, IBusinessInfo, IMapServices {
|
|
649
|
-
buildings: IVenueInlineBuilding[];
|
|
650
|
-
defaultBuilding?: string;
|
|
651
|
-
id: string;
|
|
652
|
-
organization: string[];
|
|
653
|
-
owner: string;
|
|
654
|
-
restricted: boolean;
|
|
655
|
-
sharedFloors: IVenueInlineSharedFloor[];
|
|
656
|
-
venueOutlineId: number;
|
|
373
|
+
groundFloor: string;
|
|
374
|
+
isPrivate: "yes" | "no";
|
|
375
|
+
organization: string;
|
|
376
|
+
venueId: string;
|
|
377
|
+
venueName: IMultilingualName;
|
|
657
378
|
}
|
|
658
|
-
export
|
|
659
|
-
|
|
379
|
+
export type TBuilding = Omit<IBuildingInternal, TOmittedBuildingKeys>;
|
|
380
|
+
export type TBuildingResponse<T> = IResponse<{
|
|
381
|
+
buildings: T[];
|
|
660
382
|
total: number;
|
|
383
|
+
}>;
|
|
384
|
+
export declare enum DistanceSearchType {
|
|
385
|
+
POINT = "Point",
|
|
386
|
+
POLYGON = "Polygon"
|
|
661
387
|
}
|
|
662
|
-
export
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
*/
|
|
667
|
-
offset?: number;
|
|
668
|
-
/**
|
|
669
|
-
* Results for specified page number. Default is 1.
|
|
670
|
-
*/
|
|
671
|
-
page?: number;
|
|
672
|
-
}
|
|
673
|
-
export interface IDistanceSpec {
|
|
674
|
-
/**
|
|
675
|
-
* The center of searching range, [lng, lat].
|
|
676
|
-
*/
|
|
677
|
-
center: [
|
|
678
|
-
number,
|
|
679
|
-
number
|
|
680
|
-
];
|
|
681
|
-
/**
|
|
682
|
-
* Radius from center, unit: meter for POIs, kilometers for buildings and venues, cannot exceed 10,000.
|
|
683
|
-
*/
|
|
684
|
-
distance: number;
|
|
685
|
-
}
|
|
686
|
-
export interface IOrientationSpec {
|
|
687
|
-
/**
|
|
688
|
-
* User's position, [lng, lat].
|
|
689
|
-
*/
|
|
690
|
-
center: [
|
|
691
|
-
number,
|
|
692
|
-
number
|
|
693
|
-
];
|
|
694
|
-
/**
|
|
695
|
-
* The angle between the user's orientation and true north.
|
|
696
|
-
*/
|
|
697
|
-
angle: number;
|
|
698
|
-
/**
|
|
699
|
-
* The radius with 'center' as the center of the circle.
|
|
700
|
-
*/
|
|
701
|
-
distance: number;
|
|
702
|
-
}
|
|
703
|
-
export interface IBoundsSpec {
|
|
704
|
-
/** An array of LngLat coordinates in [sw, ne] order */
|
|
705
|
-
bounds: [
|
|
706
|
-
[
|
|
707
|
-
number,
|
|
708
|
-
number
|
|
709
|
-
],
|
|
710
|
-
[
|
|
711
|
-
number,
|
|
712
|
-
number
|
|
713
|
-
]
|
|
714
|
-
];
|
|
388
|
+
export declare enum OrientationDistanceSearchType {
|
|
389
|
+
POINT = "Point",
|
|
390
|
+
POLYGON = "Polygon",
|
|
391
|
+
GATE = "Gate"
|
|
715
392
|
}
|
|
716
|
-
export
|
|
717
|
-
|
|
393
|
+
export declare enum PoisOrderBy {
|
|
394
|
+
DEFAULT_NAME = "DefaultName"
|
|
718
395
|
}
|
|
719
|
-
export
|
|
720
|
-
|
|
396
|
+
export declare enum PoisSortBy {
|
|
397
|
+
ABSOLUTE_DISTANCE = "AbsoluteDistance",
|
|
398
|
+
ACTUAL_DISTANCE = "ActualDistance"
|
|
721
399
|
}
|
|
722
|
-
export interface
|
|
723
|
-
|
|
400
|
+
export interface ISection {
|
|
401
|
+
category: string;
|
|
402
|
+
id: string;
|
|
403
|
+
sectionName: IMultilingualName;
|
|
404
|
+
correlationId?: string;
|
|
724
405
|
}
|
|
725
|
-
export interface
|
|
406
|
+
export interface IPoiCommonOptions {
|
|
407
|
+
accessibilityDetail: IMultilingualName;
|
|
408
|
+
category: string[];
|
|
409
|
+
descriptions: IMultilingualName;
|
|
410
|
+
distance?: number;
|
|
411
|
+
id: string;
|
|
412
|
+
location: ILocation;
|
|
413
|
+
name: IMultilingualName;
|
|
414
|
+
osmRefId: number;
|
|
415
|
+
poiId: string;
|
|
416
|
+
sections?: ISection[];
|
|
726
417
|
venueId: string;
|
|
727
418
|
}
|
|
728
|
-
export interface
|
|
419
|
+
export interface IPoiFloor {
|
|
420
|
+
floor: string;
|
|
729
421
|
floorId: string;
|
|
730
422
|
}
|
|
731
|
-
export interface
|
|
423
|
+
export interface ISharedPoiFloor {
|
|
732
424
|
sharedFloorId: string;
|
|
425
|
+
sharedFloorNames: IMultilingualName;
|
|
733
426
|
}
|
|
734
|
-
export interface
|
|
735
|
-
|
|
736
|
-
}
|
|
737
|
-
export interface IOrientationSearchTypeSpec {
|
|
738
|
-
/** The type of POI, default is 'Point' */
|
|
739
|
-
distanceSearchType?: OrientationDistanceSearchType;
|
|
740
|
-
}
|
|
741
|
-
/** common search */
|
|
742
|
-
export interface ISearchByKeywordsOptions extends IKeywordSpec, IQuantitySpec {
|
|
743
|
-
}
|
|
744
|
-
export interface ISearchByDistanceOptions extends IDistanceSpec, ISearchByKeywordsOptions {
|
|
745
|
-
}
|
|
746
|
-
export interface ISearchByBoundsOptions extends IBoundsSpec, ISearchByKeywordsOptions {
|
|
747
|
-
}
|
|
748
|
-
/** building/venue search */
|
|
749
|
-
export interface IBuildingSearchCustomizedOptions {
|
|
750
|
-
bounds?: [
|
|
751
|
-
[
|
|
752
|
-
number,
|
|
753
|
-
number
|
|
754
|
-
],
|
|
755
|
-
[
|
|
756
|
-
number,
|
|
757
|
-
number
|
|
758
|
-
]
|
|
759
|
-
];
|
|
760
|
-
center?: [
|
|
761
|
-
number,
|
|
762
|
-
number
|
|
763
|
-
];
|
|
764
|
-
distance?: number;
|
|
765
|
-
keywords?: string;
|
|
766
|
-
signal?: boolean;
|
|
767
|
-
visual?: boolean;
|
|
768
|
-
offset?: number;
|
|
769
|
-
page?: number;
|
|
770
|
-
}
|
|
771
|
-
export interface IVenueSearchCustomizedOptions extends IBuildingSearchCustomizedOptions {
|
|
427
|
+
export interface IPoiInternal extends IPoiFloor, IPoiCommonOptions, IBusinessInfo {
|
|
428
|
+
buildingId: string;
|
|
772
429
|
}
|
|
773
|
-
|
|
774
|
-
|
|
430
|
+
export interface ISharedPoiInternal extends ISharedPoiFloor, IPoiCommonOptions, IBusinessInfo {
|
|
431
|
+
}
|
|
432
|
+
export declare const omittedPoiProps: readonly [
|
|
433
|
+
"specialHours",
|
|
434
|
+
"businessStatus",
|
|
435
|
+
"serviceHours",
|
|
436
|
+
"keywords",
|
|
437
|
+
"siteCode",
|
|
438
|
+
"refPhotoId",
|
|
439
|
+
"totalPhotoCount",
|
|
440
|
+
"photos",
|
|
441
|
+
"icon"
|
|
442
|
+
];
|
|
443
|
+
export type TOmittedKeys = (typeof omittedPoiProps)[number];
|
|
444
|
+
export type TPoi = Omit<IPoiInternal, TOmittedKeys>;
|
|
445
|
+
export type TSharedPoi = Omit<ISharedPoiInternal, TOmittedKeys>;
|
|
446
|
+
export type TPoiResponse<T> = IResponse<{
|
|
447
|
+
pois: T[];
|
|
448
|
+
total: number;
|
|
449
|
+
}>;
|
|
450
|
+
/** poi categories from searchCategories() */
|
|
451
|
+
export interface IPoiCategory {
|
|
775
452
|
category: string;
|
|
453
|
+
description: string | null;
|
|
454
|
+
id: string;
|
|
455
|
+
title: TMultilingualString;
|
|
776
456
|
}
|
|
777
|
-
export interface
|
|
778
|
-
|
|
457
|
+
export interface ICategoryGroupItem extends IPoiCategory {
|
|
458
|
+
count: number;
|
|
459
|
+
featureType: string;
|
|
460
|
+
parents: string[];
|
|
461
|
+
venueId: string;
|
|
462
|
+
venueName: TMultilingualString;
|
|
779
463
|
}
|
|
780
|
-
export
|
|
781
|
-
|
|
464
|
+
export interface ICategoriesGroup {
|
|
465
|
+
categoryGroups: ICategoryGroupItem[];
|
|
466
|
+
total: number;
|
|
782
467
|
}
|
|
783
|
-
export
|
|
468
|
+
export type TCategoriesResponse = IResponse<ICategoriesGroup>;
|
|
469
|
+
/** pois response from searchByOrientation() */
|
|
470
|
+
export interface IOrientationPoiCommonOptions {
|
|
471
|
+
angle: number;
|
|
472
|
+
category: string[];
|
|
473
|
+
descriptions: IMultilingualName;
|
|
474
|
+
distance: number;
|
|
475
|
+
distanceSource: string;
|
|
476
|
+
id: string;
|
|
477
|
+
location: ILocation;
|
|
478
|
+
name: IMultilingualName;
|
|
479
|
+
osmRefId: number;
|
|
480
|
+
poiId: string;
|
|
784
481
|
}
|
|
785
|
-
export interface
|
|
482
|
+
export interface IOrientationNormalPoi extends IPoiFloor, IOrientationPoiCommonOptions, IBusinessInfo {
|
|
483
|
+
buildingId: string;
|
|
484
|
+
/** @deprecated "description" will be removed soon, use "descriptions" instead */
|
|
485
|
+
description?: string;
|
|
786
486
|
}
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
export type
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
excludedCategories?: string | string[];
|
|
814
|
-
/** @deprecated */
|
|
815
|
-
floorId?: string;
|
|
816
|
-
floorIds?: string[];
|
|
817
|
-
sharedFloorIds?: string[];
|
|
818
|
-
buildingId?: string;
|
|
819
|
-
venueId?: string;
|
|
820
|
-
keywords?: string;
|
|
821
|
-
orderBy?: PoisOrderBy;
|
|
822
|
-
sort?: PoisSortBy;
|
|
823
|
-
distanceSearchType?: DistanceSearchType;
|
|
824
|
-
offset?: number;
|
|
825
|
-
page?: number;
|
|
487
|
+
export interface IOrientationSharedPoi extends ISharedPoiFloor, IOrientationPoiCommonOptions {
|
|
488
|
+
}
|
|
489
|
+
export type TOrientationPoi = IOrientationNormalPoi | IOrientationSharedPoi;
|
|
490
|
+
export type TOrientationPoisResponse = IResponse<TOrientationPoi[]>;
|
|
491
|
+
export interface IMapClickEvent {
|
|
492
|
+
coordinate: LngLat;
|
|
493
|
+
building: MapGeoJSONFeature | null;
|
|
494
|
+
venue: MapGeoJSONFeature | null;
|
|
495
|
+
floor: IFloor | ISharedFloor | null;
|
|
496
|
+
}
|
|
497
|
+
export interface IPoiClickEvent {
|
|
498
|
+
coordinate: LngLat;
|
|
499
|
+
poi: MapGeoJSONFeature;
|
|
500
|
+
venue: MapGeoJSONFeature | null;
|
|
501
|
+
floor: IFloor | ISharedFloor | null;
|
|
502
|
+
building?: MapGeoJSONFeature | null;
|
|
503
|
+
sections?: ISection[];
|
|
504
|
+
}
|
|
505
|
+
export interface IPointClickEvent {
|
|
506
|
+
coordinate: LngLat;
|
|
507
|
+
point: PointLike;
|
|
508
|
+
}
|
|
509
|
+
export interface IMapChangeEvent {
|
|
510
|
+
venue: MapGeoJSONFeature | null;
|
|
511
|
+
building: MapGeoJSONFeature | null;
|
|
512
|
+
floor: IFloor | ISharedFloor | null;
|
|
826
513
|
}
|
|
827
514
|
export declare class BuildingFilterControl implements IControl {
|
|
828
515
|
private _map;
|
|
@@ -881,6 +568,15 @@ export declare class BuildingSelectorHandler {
|
|
|
881
568
|
get isEnabled(): boolean;
|
|
882
569
|
get position(): ControlPosition;
|
|
883
570
|
}
|
|
571
|
+
export interface IFloorSelectorStyle {
|
|
572
|
+
fontColor?: string;
|
|
573
|
+
activeFontColor?: string;
|
|
574
|
+
backgroundColor?: string;
|
|
575
|
+
activeBackgroundColor?: string;
|
|
576
|
+
itemSize?: number;
|
|
577
|
+
itemCount?: number;
|
|
578
|
+
defaultFolded?: boolean;
|
|
579
|
+
}
|
|
884
580
|
export interface IFloorSelectorOptions {
|
|
885
581
|
language: PresetLanguage;
|
|
886
582
|
style?: IFloorSelectorStyle;
|
|
@@ -970,38 +666,6 @@ export declare class FloorSelectorHandler {
|
|
|
970
666
|
get isEnabled(): boolean;
|
|
971
667
|
get position(): ControlPosition;
|
|
972
668
|
}
|
|
973
|
-
export declare class SwitchBuildingHandler {
|
|
974
|
-
private _indoor;
|
|
975
|
-
private _isEnabled;
|
|
976
|
-
constructor(indoor: Indoor);
|
|
977
|
-
enable(): void;
|
|
978
|
-
disable(): void;
|
|
979
|
-
get isEnabled(): boolean;
|
|
980
|
-
}
|
|
981
|
-
export declare class SwitchOutdoorHandler {
|
|
982
|
-
private _indoor;
|
|
983
|
-
private _isEnabled;
|
|
984
|
-
constructor(indoor: Indoor);
|
|
985
|
-
enable(): void;
|
|
986
|
-
disable(): void;
|
|
987
|
-
get isEnabled(): boolean;
|
|
988
|
-
}
|
|
989
|
-
export declare class IndoorClickSelection {
|
|
990
|
-
private _indoor;
|
|
991
|
-
private _isEnabled;
|
|
992
|
-
constructor(indoor: Indoor);
|
|
993
|
-
enable(): void;
|
|
994
|
-
disable(): void;
|
|
995
|
-
get isEnabled(): boolean;
|
|
996
|
-
}
|
|
997
|
-
export declare class OutdoorClickSelection {
|
|
998
|
-
private _indoor;
|
|
999
|
-
private _isEnabled;
|
|
1000
|
-
constructor(indoor: Indoor);
|
|
1001
|
-
enable(): void;
|
|
1002
|
-
disable(): void;
|
|
1003
|
-
get isEnabled(): boolean;
|
|
1004
|
-
}
|
|
1005
669
|
export interface IPanToOptions {
|
|
1006
670
|
dragPan?: boolean;
|
|
1007
671
|
animate?: boolean;
|
|
@@ -1060,230 +724,119 @@ export interface IMapxusMap {
|
|
|
1060
724
|
unsubscribe: VoidFunction;
|
|
1061
725
|
};
|
|
1062
726
|
}
|
|
1063
|
-
export
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
selectedLevelIds: string[];
|
|
1086
|
-
alwaysDisplayedSharedLevelIds: string[];
|
|
1087
|
-
maskBuildingIds: string[];
|
|
1088
|
-
maskSharedFloorIds: string[];
|
|
1089
|
-
}
|
|
1090
|
-
declare class FloorsLayeredHandler {
|
|
1091
|
-
private _isMaskMode;
|
|
1092
|
-
private _hiddenBuildings;
|
|
1093
|
-
private _history;
|
|
1094
|
-
constructor(maskMode: boolean);
|
|
1095
|
-
getLayeredData(options: ILayeredOptions): ILayeredData;
|
|
1096
|
-
getHiddenBuildings(): string[];
|
|
1097
|
-
}
|
|
1098
|
-
declare class DragPanHandler {
|
|
1099
|
-
private _maplibre;
|
|
1100
|
-
private _isAnimated;
|
|
1101
|
-
private _bounds;
|
|
1102
|
-
private _boundsPadding;
|
|
1103
|
-
private _center;
|
|
1104
|
-
private _fitBoundsTimer;
|
|
1105
|
-
constructor(maplibre: maplibregl$1.Map, padding: number | PaddingOptions);
|
|
1106
|
-
setAnimated(animated: boolean): void;
|
|
1107
|
-
setBounds(bounds: LngLatBoundsLike | null): void;
|
|
1108
|
-
getBounds(): LngLatBoundsLike | null;
|
|
1109
|
-
setCenter(lnglat: LngLatLike | null): void;
|
|
1110
|
-
fitBounds(): Promise<unknown>;
|
|
1111
|
-
panToCenter(): void;
|
|
727
|
+
export declare enum ThemeType {
|
|
728
|
+
/** @deprecated **/
|
|
729
|
+
CHRISTMAS = "christmas_mims2_v1",
|
|
730
|
+
/** @deprecated **/
|
|
731
|
+
HALLOWEEN = "halloween_mims2_v1",
|
|
732
|
+
/** @deprecated **/
|
|
733
|
+
MAPPY_BEE = "mappybee_mims2_v2",
|
|
734
|
+
/** @deprecated **/
|
|
735
|
+
MAPXUS = "mapxus_mims2_v1",
|
|
736
|
+
/** @deprecated **/
|
|
737
|
+
LANDS_D = "lands_d_mims2_v1",
|
|
738
|
+
/** @deprecated **/
|
|
739
|
+
COMMON = "common_mims2_v1",
|
|
740
|
+
/** @deprecated MAPXUS_V2 will be removed soon, please use MAPXUS_DEFAULT instead. */
|
|
741
|
+
MAPXUS_V2 = "mapxus_v2",
|
|
742
|
+
MAPXUS_DEFAULT = "mapxus_v8",
|
|
743
|
+
ROSE_TEA = "rose_tea",
|
|
744
|
+
PEAR_SORBET = "pear_sorbet",
|
|
745
|
+
CITY_WALK = "city_walk",
|
|
746
|
+
MOCHA_MOUSSE = "mocha_mousse",
|
|
747
|
+
SECTION_DISPLAY_BY_COLOR = "mapxus_v7_with_section_v2",
|
|
748
|
+
SECTION_DISPLAY_BY_CATEGORY = "mapxus_v7_with_section_v3"
|
|
1112
749
|
}
|
|
1113
|
-
export
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
private _allBuildingsMap;
|
|
1118
|
-
private _allSharedLevelsMap;
|
|
1119
|
-
private _curBuildingId;
|
|
1120
|
-
private _curBuildingFeature;
|
|
1121
|
-
private _curSharedLevelId;
|
|
1122
|
-
private _floor;
|
|
1123
|
-
private _sharedFloor;
|
|
1124
|
-
private _outdoorMapShown;
|
|
1125
|
-
private _originIndoorLayers;
|
|
1126
|
-
private _outdoorLayers;
|
|
1127
|
-
private _curVenueId;
|
|
1128
|
-
private _curVenueFeature;
|
|
1129
|
-
private _selectedHighlightStyle;
|
|
1130
|
-
private _upperLayers;
|
|
1131
|
-
private _commonPoiLayers;
|
|
1132
|
-
private _sectionFillLineLayers;
|
|
1133
|
-
private _sectionSymbolLayers;
|
|
1134
|
-
private _middleLayers;
|
|
1135
|
-
private _lowerLayers;
|
|
1136
|
-
private _excludedPoisInMiddle;
|
|
1137
|
-
private _dispatch;
|
|
1138
|
-
private readonly _startWithIndoorView;
|
|
1139
|
-
private _indoorMapLoaded;
|
|
1140
|
-
private _isSelectSharedFloor;
|
|
1141
|
-
private readonly _isMaskMode;
|
|
1142
|
-
private _upperLevels;
|
|
1143
|
-
private _middleLevels;
|
|
1144
|
-
private _lowerLevels;
|
|
1145
|
-
private _featureIncomplete;
|
|
1146
|
-
private _fitBounds;
|
|
1147
|
-
private _dragPan;
|
|
1148
|
-
private _history;
|
|
1149
|
-
private _maskBuildings;
|
|
1150
|
-
private _maskSharedFloors;
|
|
1151
|
-
private _enableIndoorClickSelection;
|
|
1152
|
-
private _enableOutdoorClickSelection;
|
|
1153
|
-
private _zIndexHistory;
|
|
1154
|
-
private _floorSwitchScope;
|
|
1155
|
-
private _isDestroyed;
|
|
1156
|
-
private _abortQueryFeature;
|
|
1157
|
-
private _debounceRendering;
|
|
1158
|
-
layeredHandler: FloorsLayeredHandler;
|
|
1159
|
-
dragPanHandler: DragPanHandler;
|
|
1160
|
-
constructor(props: {
|
|
1161
|
-
map: maplibregl$1.Map;
|
|
1162
|
-
fitBounds: boolean;
|
|
1163
|
-
boundsPadding: number | PaddingOptions;
|
|
1164
|
-
maskNonSelectedAreas: boolean;
|
|
1165
|
-
startWithIndoorView: boolean;
|
|
1166
|
-
outdoorMapShown: boolean;
|
|
1167
|
-
enableIndoorClickSelection: boolean;
|
|
1168
|
-
enableOutdoorClickSelection: boolean;
|
|
1169
|
-
floorSwitchScope: FloorSwitchScope;
|
|
1170
|
-
selectedHighlightStyle?: ISelectedHighlightStyle;
|
|
1171
|
-
});
|
|
1172
|
-
destroy(): void;
|
|
1173
|
-
/**
|
|
1174
|
-
* @deprecated
|
|
1175
|
-
* Set whether to allow exiting building.
|
|
1176
|
-
* @param allow
|
|
1177
|
-
*/
|
|
1178
|
-
setAllowOutdoorSwitch(allow: boolean): this;
|
|
1179
|
-
/**
|
|
1180
|
-
* @deprecated
|
|
1181
|
-
* Set whether to allow switching building.
|
|
1182
|
-
* @param allow
|
|
1183
|
-
*/
|
|
1184
|
-
setAllowBuildingSwitch(allow: boolean): this;
|
|
1185
|
-
setAllowIndoorClickSelect(allow: boolean): void;
|
|
1186
|
-
setAllowOutdoorClickSelect(allow: boolean): void;
|
|
1187
|
-
setFloorSwitchScope(scope: FloorSwitchScope): void;
|
|
1188
|
-
/**
|
|
1189
|
-
* Get the current floor's information.
|
|
1190
|
-
*/
|
|
1191
|
-
get floor(): IFloor | ISharedFloor | null;
|
|
1192
|
-
/**
|
|
1193
|
-
* Get the current building's information.
|
|
1194
|
-
* @returns {MapGeoJSONFeature | null}
|
|
1195
|
-
*/
|
|
1196
|
-
get building(): MapGeoJSONFeature | null;
|
|
750
|
+
export interface IMapOption {
|
|
751
|
+
map: maplibregl$1.Map;
|
|
752
|
+
floorSelectorEnabled?: boolean;
|
|
753
|
+
buildingSelectorEnabled?: boolean;
|
|
1197
754
|
/**
|
|
1198
|
-
*
|
|
1199
|
-
*
|
|
755
|
+
* 'venueId', 'buildingId', 'floorId', 'poiId' are mutually exclusive,
|
|
756
|
+
* the priority is: poiId > floorId > buildingId > venueId.
|
|
1200
757
|
*/
|
|
1201
|
-
|
|
758
|
+
venueId?: string;
|
|
1202
759
|
/**
|
|
1203
|
-
*
|
|
760
|
+
* 'venueId', 'buildingId', 'floorId', 'poiId' are mutually exclusive,
|
|
761
|
+
* the priority is: poiId > floorId > buildingId > venueId.
|
|
1204
762
|
*/
|
|
1205
|
-
|
|
763
|
+
buildingId?: string;
|
|
1206
764
|
/**
|
|
1207
|
-
*
|
|
1208
|
-
*
|
|
1209
|
-
* @param options
|
|
765
|
+
* 'venueId', 'buildingId', 'floorId', 'poiId' are mutually exclusive,
|
|
766
|
+
* the priority is: poiId > floorId > buildingId > venueId.
|
|
1210
767
|
*/
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
filter?: (feature: MapGeoJSONFeature) => boolean;
|
|
1214
|
-
}): MapGeoJSONFeature[];
|
|
768
|
+
floorId?: string;
|
|
769
|
+
sharedFloorId?: string;
|
|
1215
770
|
/**
|
|
1216
|
-
*
|
|
1217
|
-
*
|
|
771
|
+
* Initialize the map with POI as the center point, use it with maplibregl.Map 'zoom' option.
|
|
772
|
+
* 'venueId', 'buildingId', 'floorId', 'poiId' are mutually exclusive,
|
|
773
|
+
* the priority is: poiId > floorId > buildingId > venueId.
|
|
1218
774
|
*/
|
|
1219
|
-
|
|
1220
|
-
|
|
775
|
+
poiId?: string;
|
|
776
|
+
outdoorMapShown?: boolean;
|
|
777
|
+
theme?: ThemeType | string;
|
|
778
|
+
/** @deprecated 'collapseCopyright' will be removed soon. You'd not use it. */
|
|
779
|
+
collapseCopyright?: boolean;
|
|
780
|
+
selectedHighlightStyle?: ISelectedHighlightStyle;
|
|
781
|
+
floorSelectorStyle?: IFloorSelectorStyle;
|
|
1221
782
|
/**
|
|
1222
|
-
*
|
|
1223
|
-
* @param style {ISelectedHighlightStyle | null}
|
|
783
|
+
* Whether unselected buildings are masked, default is false.
|
|
1224
784
|
*/
|
|
1225
|
-
|
|
785
|
+
maskNonSelectedAreas?: boolean;
|
|
1226
786
|
/**
|
|
1227
|
-
*
|
|
1228
|
-
*
|
|
787
|
+
* @deprecated use "fitBounds" instead.
|
|
788
|
+
* Whether the boundary of the selected building fits the screen, default is false.
|
|
789
|
+
* Can only be used for 'floorId', 'buildingId' and 'venueId' initialization, not for 'poiId'.
|
|
790
|
+
* When it is true, the 'boundsPadding' option is valid, and the 'zoom' option of maplibregl.Map is invalid.
|
|
1229
791
|
*/
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
building: MapGeoJSONFeature | null;
|
|
1233
|
-
floor: IFloor;
|
|
1234
|
-
}) => void): {
|
|
1235
|
-
unsubscribe: VoidFunction;
|
|
1236
|
-
};
|
|
792
|
+
fitBuildingBounds?: boolean;
|
|
793
|
+
fitBounds?: boolean;
|
|
1237
794
|
/**
|
|
1238
|
-
*
|
|
1239
|
-
*
|
|
1240
|
-
*
|
|
795
|
+
* The amount of padding in pixels to add to the given bounds, default is 30.
|
|
796
|
+
* Requires 'fitBuildingBounds' to be 'true'.
|
|
797
|
+
* Parameter value ref to: https://maplibre.org/maplibre-gl-js/docs/API/types/maplibregl.PaddingOptions/
|
|
1241
798
|
*/
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
private
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
private
|
|
1262
|
-
private
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
private
|
|
1270
|
-
private
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
private
|
|
1278
|
-
private
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
private _queryVisibleFeature;
|
|
1284
|
-
private _queryRenderedFeatures;
|
|
1285
|
-
private _dispatchIndoorMapLoaded;
|
|
1286
|
-
private _changeOtherVenuesHistory;
|
|
799
|
+
boundsPadding?: number | maplibregl$1.PaddingOptions;
|
|
800
|
+
language?: PresetLanguage;
|
|
801
|
+
/** Auto Select Building by panning building to map center, default is false. */
|
|
802
|
+
autoSelectBuilding?: boolean;
|
|
803
|
+
transformRequest?: maplibregl$1.RequestTransformFunction | null;
|
|
804
|
+
mapxusLogoEnabled?: boolean;
|
|
805
|
+
enableIndoorClickSelection?: boolean;
|
|
806
|
+
enableOutdoorClickSelection?: boolean;
|
|
807
|
+
floorSwitchScope?: FloorSwitchScope;
|
|
808
|
+
}
|
|
809
|
+
export declare class SwitchBuildingHandler {
|
|
810
|
+
private _indoor;
|
|
811
|
+
private _isEnabled;
|
|
812
|
+
constructor(indoor: Indoor);
|
|
813
|
+
enable(): void;
|
|
814
|
+
disable(): void;
|
|
815
|
+
get isEnabled(): boolean;
|
|
816
|
+
}
|
|
817
|
+
export declare class SwitchOutdoorHandler {
|
|
818
|
+
private _indoor;
|
|
819
|
+
private _isEnabled;
|
|
820
|
+
constructor(indoor: Indoor);
|
|
821
|
+
enable(): void;
|
|
822
|
+
disable(): void;
|
|
823
|
+
get isEnabled(): boolean;
|
|
824
|
+
}
|
|
825
|
+
export declare class IndoorClickSelection {
|
|
826
|
+
private _indoor;
|
|
827
|
+
private _isEnabled;
|
|
828
|
+
constructor(indoor: Indoor);
|
|
829
|
+
enable(): void;
|
|
830
|
+
disable(): void;
|
|
831
|
+
get isEnabled(): boolean;
|
|
832
|
+
}
|
|
833
|
+
export declare class OutdoorClickSelection {
|
|
834
|
+
private _indoor;
|
|
835
|
+
private _isEnabled;
|
|
836
|
+
constructor(indoor: Indoor);
|
|
837
|
+
enable(): void;
|
|
838
|
+
disable(): void;
|
|
839
|
+
get isEnabled(): boolean;
|
|
1287
840
|
}
|
|
1288
841
|
declare class Map$1 implements IMapxusMap {
|
|
1289
842
|
private _map;
|
|
@@ -1296,11 +849,7 @@ declare class Map$1 implements IMapxusMap {
|
|
|
1296
849
|
private _dispatch;
|
|
1297
850
|
private _fitBounds;
|
|
1298
851
|
private _history;
|
|
1299
|
-
private _debounceHTTPErrorHandler;
|
|
1300
852
|
private _transformRequestHandler;
|
|
1301
|
-
private _tokenRefreshingPromise;
|
|
1302
|
-
private _request;
|
|
1303
|
-
private _cancelTokenChangedListener;
|
|
1304
853
|
isDestroyed: boolean;
|
|
1305
854
|
/** @deprecated Use "outdoorClickSelection" instead */
|
|
1306
855
|
switchOutdoor: SwitchOutdoorHandler;
|
|
@@ -1312,13 +861,17 @@ declare class Map$1 implements IMapxusMap {
|
|
|
1312
861
|
floorSelector: FloorSelectorHandler;
|
|
1313
862
|
constructor(options: IMapOption);
|
|
1314
863
|
/**
|
|
1315
|
-
*
|
|
864
|
+
* Set a callback that fires once indoor map has finished rendering.
|
|
1316
865
|
* @param callback
|
|
1317
866
|
*/
|
|
1318
867
|
renderComplete(callback: VoidFunction): void;
|
|
868
|
+
/**
|
|
869
|
+
* Set a callback that fires once map instance is destroyed.
|
|
870
|
+
* @param callback
|
|
871
|
+
*/
|
|
1319
872
|
destroyed(callback: VoidFunction): void;
|
|
1320
873
|
/**
|
|
1321
|
-
*
|
|
874
|
+
* Transform the request options of style resources.
|
|
1322
875
|
* @param handler {maplibregl.RequestTransformFunction}
|
|
1323
876
|
*/
|
|
1324
877
|
setTransformRequest(handler: maplibregl$1.RequestTransformFunction): void;
|
|
@@ -1326,153 +879,606 @@ declare class Map$1 implements IMapxusMap {
|
|
|
1326
879
|
* Get map indoor instance.
|
|
1327
880
|
* @deprecated indoor instance won't be provided publicly in the future.
|
|
1328
881
|
*/
|
|
1329
|
-
getIndoor(): Indoor;
|
|
882
|
+
getIndoor(): Indoor;
|
|
883
|
+
/**
|
|
884
|
+
* Get maplibre map instance.
|
|
885
|
+
*/
|
|
886
|
+
getMaplibre(): maplibregl$1.Map;
|
|
887
|
+
/**
|
|
888
|
+
* Get current selected floor info.
|
|
889
|
+
* @return {IFloor | ISharedFloor | null}
|
|
890
|
+
*/
|
|
891
|
+
get floor(): IFloor | ISharedFloor | null;
|
|
892
|
+
/**
|
|
893
|
+
* Get current selected building info.
|
|
894
|
+
* @return {MapGeoJSONFeature | null}
|
|
895
|
+
*/
|
|
896
|
+
get building(): MapGeoJSONFeature | null;
|
|
897
|
+
/**
|
|
898
|
+
* Get current selected venue info.
|
|
899
|
+
* @return {MapGeoJSONFeature | null}
|
|
900
|
+
*/
|
|
901
|
+
get venue(): MapGeoJSONFeature | null;
|
|
902
|
+
/**
|
|
903
|
+
* Set map language.
|
|
904
|
+
* @param language {PresetLanguage} convertBrowserLangToPresetLang(Window.navigator.language).
|
|
905
|
+
*/
|
|
906
|
+
setLanguage(language: PresetLanguage): void;
|
|
907
|
+
/**
|
|
908
|
+
* Get map language.
|
|
909
|
+
* @return {PresetLanguage}
|
|
910
|
+
*/
|
|
911
|
+
getLanguage(): PresetLanguage;
|
|
912
|
+
/**
|
|
913
|
+
* Set outdoor map to be shown or hidden.
|
|
914
|
+
* @param shown
|
|
915
|
+
*/
|
|
916
|
+
setOutdoorMapShown(shown: boolean): void;
|
|
917
|
+
/**
|
|
918
|
+
* Query indoor features by screen point({x, y}).
|
|
919
|
+
* @param point
|
|
920
|
+
* @returns
|
|
921
|
+
*/
|
|
922
|
+
queryIndoorFeaturesByPoint(point: IScreenPoint): INormalLevelIndoorFeatures | ISharedLevelIndoorFeatures | null;
|
|
923
|
+
/**
|
|
924
|
+
* Get features from bbox by coordinates [and ordinal].
|
|
925
|
+
* @deprecated Use "queryIndoorFeaturesByPoint()" instead.
|
|
926
|
+
* @param coordinates
|
|
927
|
+
* @param ordinal
|
|
928
|
+
*/
|
|
929
|
+
getIndoorFeaturesByCoordinates(coordinates: {
|
|
930
|
+
lng: number;
|
|
931
|
+
lat: number;
|
|
932
|
+
}, ordinal?: number): {
|
|
933
|
+
venue: MapGeoJSONFeature | null;
|
|
934
|
+
building: MapGeoJSONFeature | null;
|
|
935
|
+
level: MapGeoJSONFeature | null;
|
|
936
|
+
};
|
|
937
|
+
/**
|
|
938
|
+
* Query rendered features from bbox by id. One id may correspond to multiple features,
|
|
939
|
+
* coz of a feature may be multi-polygon(feature collection).
|
|
940
|
+
* @param id
|
|
941
|
+
* @param options {layerIds: string[], filter: (feature: MapGeoJSONFeature) => boolean}
|
|
942
|
+
*/
|
|
943
|
+
getFeaturesById(id: string, options?: IFeaturesFilterOptions): MapGeoJSONFeature[];
|
|
944
|
+
/**
|
|
945
|
+
* Switch floor by ordinal of current selected building.
|
|
946
|
+
* @param ordinal {string | null} The ordinal of the target floor.
|
|
947
|
+
* If ordinal is null, the map will exit indoor view.
|
|
948
|
+
* If current selected building has no the target ordinal, there's an error will be thrown.
|
|
949
|
+
*/
|
|
950
|
+
switchFloorByOrdinal(ordinal: string | null): Promise<void>;
|
|
951
|
+
/**
|
|
952
|
+
* Select indoor by locating the target floor.
|
|
953
|
+
* @param floorId
|
|
954
|
+
* @param options {dragPan: boolean} Set dragPan to be false, the map will not pan to the building center.
|
|
955
|
+
* Default is true.
|
|
956
|
+
*/
|
|
957
|
+
selectFloorById(floorId: string, options?: IPanToOptions): Promise<void>;
|
|
958
|
+
selectSharedFloorById(sharedFloorId: string, options?: IPanToOptions): Promise<void>;
|
|
959
|
+
/**
|
|
960
|
+
* Select indoor by locating the target building.
|
|
961
|
+
* @param buildingId
|
|
962
|
+
* @param options {dragPan: boolean} Set dragPan to be false, the map will not pan to the building center.
|
|
963
|
+
* Default is true.
|
|
964
|
+
*/
|
|
965
|
+
selectBuildingById(buildingId: string, options?: IPanToOptions): Promise<void>;
|
|
966
|
+
/**
|
|
967
|
+
* Select indoor by locating the target venue.
|
|
968
|
+
* @param venueId 'venueId' can be string or null. Exit indoors if venueId is null.
|
|
969
|
+
* @param options {dragPan: boolean} Set dragPan to be false, the map will not pan to the building center.
|
|
970
|
+
* Default is true.
|
|
971
|
+
*/
|
|
972
|
+
selectVenueById(venueId: string | null, options?: IPanToOptions): Promise<void>;
|
|
973
|
+
/**
|
|
974
|
+
* Listen for mouse click events on the map.
|
|
975
|
+
* @param listener
|
|
976
|
+
*/
|
|
977
|
+
onMapClickListener(listener: (param: IMapClickEvent) => void): {
|
|
978
|
+
unsubscribe: VoidFunction;
|
|
979
|
+
};
|
|
980
|
+
/**
|
|
981
|
+
* Listen for mouse click events on indoor POI
|
|
982
|
+
* @param listener
|
|
983
|
+
*/
|
|
984
|
+
onPoiClickListener(listener: (param: IPoiClickEvent) => void): {
|
|
985
|
+
unsubscribe: VoidFunction;
|
|
986
|
+
};
|
|
987
|
+
/**
|
|
988
|
+
* Listen for mouse click events at a point.
|
|
989
|
+
* @param listener
|
|
990
|
+
*/
|
|
991
|
+
onPointClickListener(listener: (param: IPointClickEvent) => void): {
|
|
992
|
+
unsubscribe: VoidFunction;
|
|
993
|
+
};
|
|
994
|
+
/**
|
|
995
|
+
* Listen for the indoor map status, including the changes of venue, building and floor.
|
|
996
|
+
* @param listener
|
|
997
|
+
*/
|
|
998
|
+
onMapChangeListener(listener: (param: IMapChangeEvent) => void): {
|
|
999
|
+
unsubscribe: VoidFunction;
|
|
1000
|
+
};
|
|
1001
|
+
/**
|
|
1002
|
+
* @deprecated Use "setTheme()" instead.
|
|
1003
|
+
* Switch the map style
|
|
1004
|
+
* @param theme ThemeType | string(customized map style file name)
|
|
1005
|
+
*/
|
|
1006
|
+
switchTheme(theme: string): void;
|
|
1007
|
+
setTheme(theme: ThemeType | string): void;
|
|
1008
|
+
/**
|
|
1009
|
+
* @deprecated Use 'setSelectedHighlightStyle' instead.
|
|
1010
|
+
* Set the SelectedBuildingBorder's style. If set to null, the border will be invisible.
|
|
1011
|
+
* @param style {ISelectedHighlightStyle | null}
|
|
1012
|
+
*/
|
|
1013
|
+
setSelectedBuildingBorderStyle(style: ISelectedHighlightStyle | null): this;
|
|
1014
|
+
setSelectedHighlightStyle(style: ISelectedHighlightStyle | null): this;
|
|
1015
|
+
setFloorSwitchScope(scope: FloorSwitchScope): void;
|
|
1016
|
+
private _setup;
|
|
1017
|
+
private _setStyle;
|
|
1018
|
+
private _addControl;
|
|
1019
|
+
private _selectPoiById;
|
|
1020
|
+
private _resourceRequestTransform;
|
|
1021
|
+
private _checkMapZoom;
|
|
1022
|
+
private _updatePermission;
|
|
1023
|
+
private _selectCenterBuilding;
|
|
1024
|
+
/**
|
|
1025
|
+
* Query building features within the center rectangle(width: 1/2 width of map view, height: 1/2 height of map view) of map.
|
|
1026
|
+
* @returns Map<buildingId, buildingFeature>
|
|
1027
|
+
*/
|
|
1028
|
+
private _getCenterBuildingUnitsMap;
|
|
1029
|
+
private _bindMapClickListener;
|
|
1030
|
+
private _dispatchErrorGlobal;
|
|
1031
|
+
private _installRtlTextPlugin;
|
|
1032
|
+
private _permissionCheck;
|
|
1033
|
+
private _destroy;
|
|
1034
|
+
}
|
|
1035
|
+
export type TPointFeature = GeoJSON.Feature<Point, GeoJsonProperties>;
|
|
1036
|
+
export type TLineStringFeature = GeoJSON.Feature<LineString, GeoJsonProperties>;
|
|
1037
|
+
export type TAnchorPosition = "center" | "left" | "right" | "top" | "bottom" | "top-left" | "top-right" | "bottom-left" | "bottom-right";
|
|
1038
|
+
export interface IMarkerOptions {
|
|
1039
|
+
lngLat: [
|
|
1040
|
+
number,
|
|
1041
|
+
number
|
|
1042
|
+
];
|
|
1043
|
+
properties?: {
|
|
1044
|
+
[k: string]: string;
|
|
1045
|
+
};
|
|
1046
|
+
}
|
|
1047
|
+
export interface IMarkerOptionsWithFeatureId extends IMarkerOptions {
|
|
1048
|
+
featureId: number;
|
|
1049
|
+
}
|
|
1050
|
+
export interface ITokenInfo {
|
|
1051
|
+
"app:name": string;
|
|
1052
|
+
auth_time: number;
|
|
1053
|
+
"cognito:username": string;
|
|
1054
|
+
"custom:organization": string;
|
|
1055
|
+
exp: number;
|
|
1056
|
+
iat: number;
|
|
1057
|
+
organization: string;
|
|
1058
|
+
"organization:name": string;
|
|
1059
|
+
privatization_type: string;
|
|
1060
|
+
username: string;
|
|
1061
|
+
}
|
|
1062
|
+
export declare enum VehicleType {
|
|
1063
|
+
FOOT = "foot",
|
|
1064
|
+
WHEELCHAIR = "wheelchair",
|
|
1065
|
+
ESCALATOR = "escalator",
|
|
1066
|
+
EMERGENCY = "emergency"
|
|
1067
|
+
}
|
|
1068
|
+
export interface IRouteInfo {
|
|
1069
|
+
copyrights: string[];
|
|
1070
|
+
took: number;
|
|
1071
|
+
}
|
|
1072
|
+
export interface IInstruction {
|
|
1073
|
+
building_id: string;
|
|
1074
|
+
distance: number;
|
|
1075
|
+
floor_id: string;
|
|
1076
|
+
heading: number;
|
|
1077
|
+
interval: [
|
|
1078
|
+
number,
|
|
1079
|
+
number
|
|
1080
|
+
];
|
|
1081
|
+
on_shared_floor: boolean;
|
|
1082
|
+
ordinal: number;
|
|
1083
|
+
sign: number;
|
|
1084
|
+
street_name: string;
|
|
1085
|
+
text: string;
|
|
1086
|
+
time: number;
|
|
1087
|
+
type: string | null;
|
|
1088
|
+
venue_id: string;
|
|
1089
|
+
}
|
|
1090
|
+
export interface IRoutePath {
|
|
1091
|
+
bbox: [
|
|
1092
|
+
number,
|
|
1093
|
+
number,
|
|
1094
|
+
number,
|
|
1095
|
+
number
|
|
1096
|
+
];
|
|
1097
|
+
distance: number;
|
|
1098
|
+
instructions: IInstruction[];
|
|
1099
|
+
points: {
|
|
1100
|
+
coordinates: Array<[
|
|
1101
|
+
number,
|
|
1102
|
+
number
|
|
1103
|
+
]>;
|
|
1104
|
+
type: string;
|
|
1105
|
+
};
|
|
1106
|
+
snapped_waypoints: {
|
|
1107
|
+
coordinates: Array<[
|
|
1108
|
+
number,
|
|
1109
|
+
number
|
|
1110
|
+
]>;
|
|
1111
|
+
type: string;
|
|
1112
|
+
};
|
|
1113
|
+
time: number;
|
|
1114
|
+
}
|
|
1115
|
+
export interface IResponseRoute {
|
|
1116
|
+
infos: IRouteInfo | null;
|
|
1117
|
+
paths: IRoutePath[];
|
|
1118
|
+
}
|
|
1119
|
+
export interface IRoutePoint {
|
|
1120
|
+
lat: number;
|
|
1121
|
+
lon: number;
|
|
1122
|
+
floorId?: string;
|
|
1123
|
+
}
|
|
1124
|
+
export interface IRouteSearchOptions {
|
|
1330
1125
|
/**
|
|
1331
|
-
*
|
|
1126
|
+
* Points are in order, from -> stops -> to.
|
|
1127
|
+
* The length of points must be: 1 < {points.length} < 6.
|
|
1332
1128
|
*/
|
|
1333
|
-
|
|
1129
|
+
points: IRoutePoint[];
|
|
1334
1130
|
/**
|
|
1335
|
-
*
|
|
1336
|
-
* @return {IFloor | ISharedFloor | null}
|
|
1131
|
+
* Default is "foot".
|
|
1337
1132
|
*/
|
|
1338
|
-
|
|
1133
|
+
vehicle?: VehicleType;
|
|
1339
1134
|
/**
|
|
1340
|
-
*
|
|
1341
|
-
* @return {MapGeoJSONFeature | null}
|
|
1135
|
+
* Language-specific response. Default is "en".
|
|
1342
1136
|
*/
|
|
1343
|
-
|
|
1137
|
+
locale?: PresetLanguage;
|
|
1138
|
+
}
|
|
1139
|
+
export interface IRouteMarkers {
|
|
1140
|
+
from: string | null;
|
|
1141
|
+
to: string | null;
|
|
1142
|
+
stops: Array<string | null> | null;
|
|
1143
|
+
}
|
|
1144
|
+
export interface IRouteStyle<T> {
|
|
1145
|
+
indoorLineColor?: string | ExpressionSpecification;
|
|
1146
|
+
outdoorLineColor?: string | ExpressionSpecification;
|
|
1147
|
+
dashedLineColor?: string | ExpressionSpecification;
|
|
1148
|
+
shuttleBusLineColor?: string | ExpressionSpecification;
|
|
1149
|
+
lineWidth?: number | ExpressionSpecification;
|
|
1150
|
+
dashedLineWidth?: number | ExpressionSpecification;
|
|
1151
|
+
disableDashedLine?: boolean;
|
|
1152
|
+
/** Optional number in range [0, 1]. Defaults to 0.5. "inactiveRouteOpacity" will be 1 if the parameter is greater than 1, and it will be 0 if the parameter is less than 0. */
|
|
1153
|
+
inactiveRouteOpacity?: number;
|
|
1154
|
+
/** Optional number in range [0, 1]. Defaults to 1. "outdoorLineOpacity" will be 1 if the parameter is greater than 1, and it will be 0 if the parameter is less than 0. */
|
|
1155
|
+
outdoorLineOpacity?: number;
|
|
1156
|
+
markers?: T;
|
|
1157
|
+
markerIconSize?: number | ExpressionSpecification;
|
|
1158
|
+
lineSymbol?: {
|
|
1159
|
+
/**
|
|
1160
|
+
* Icon url or sprite name.
|
|
1161
|
+
*/
|
|
1162
|
+
image?: string | null;
|
|
1163
|
+
size?: number | ExpressionSpecification;
|
|
1164
|
+
spacing?: number | ExpressionSpecification;
|
|
1165
|
+
};
|
|
1166
|
+
}
|
|
1167
|
+
export type TRouteStyleOptions = IRouteStyle<Partial<IRouteMarkers> | Array<string | null>>;
|
|
1168
|
+
export declare class RoutePainter {
|
|
1169
|
+
private readonly _maplibreMap;
|
|
1170
|
+
private _routeStyle;
|
|
1171
|
+
private _styleDiffs;
|
|
1172
|
+
private _filterBy;
|
|
1173
|
+
private _curVenue;
|
|
1174
|
+
private _curBuilding;
|
|
1175
|
+
private _curOrdinal;
|
|
1176
|
+
private _renderBoundaryLayer;
|
|
1177
|
+
constructor(maplibreMap: maplibregl$1.Map, routeStyle?: TRouteStyleOptions);
|
|
1344
1178
|
/**
|
|
1345
|
-
*
|
|
1346
|
-
* @
|
|
1179
|
+
* Set the style of the route.
|
|
1180
|
+
* @param routeStyle {TRouteStyleOptions | null} When null, reset to the initial style.
|
|
1347
1181
|
*/
|
|
1348
|
-
|
|
1182
|
+
setStyle(routeStyle: TRouteStyleOptions | null): Promise<void>;
|
|
1349
1183
|
/**
|
|
1350
|
-
*
|
|
1351
|
-
*
|
|
1184
|
+
* @deprecated Use 'setStyle' instead.
|
|
1185
|
+
* Set image[s] of the stop marker[s].
|
|
1186
|
+
* @param icons Array of sprite names or URLs, or the object with specifying icon.
|
|
1187
|
+
* Markers use images in order of icons array.
|
|
1188
|
+
* First is as from-marker, last is as to-marker, the middles are as stop-markers.
|
|
1189
|
+
* If icons array has only one element, all stop markers use this image.
|
|
1190
|
+
* Image file must be in png, webp, or jpg format.
|
|
1191
|
+
* Null means none image.
|
|
1352
1192
|
*/
|
|
1353
|
-
|
|
1193
|
+
setMarkerIcons(icons: Array<string | null> | {
|
|
1194
|
+
from?: string | null;
|
|
1195
|
+
to?: string | null;
|
|
1196
|
+
stops?: Array<string | null> | null;
|
|
1197
|
+
}): Promise<void>;
|
|
1354
1198
|
/**
|
|
1355
|
-
*
|
|
1356
|
-
*
|
|
1199
|
+
* @deprecated Use 'setStyle' instead.
|
|
1200
|
+
* Set all icons scale.
|
|
1201
|
+
* @param size number in range [0, ∞), default is 1.
|
|
1357
1202
|
*/
|
|
1358
|
-
|
|
1203
|
+
setMarkerIconSize(size: number): this;
|
|
1359
1204
|
/**
|
|
1360
|
-
*
|
|
1361
|
-
*
|
|
1205
|
+
* @deprecated Use 'setStyle' instead.
|
|
1206
|
+
* Set the route color of the indoor part.
|
|
1207
|
+
* @param color The color type is a color in the sRGB color space.
|
|
1208
|
+
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
1209
|
+
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
1362
1210
|
*/
|
|
1363
|
-
|
|
1364
|
-
queryIndoorFeaturesByPoint(point: IScreenPoint): INormalLevelIndoorFeatures | ISharedLevelIndoorFeatures | null;
|
|
1211
|
+
setIndoorLineColor(color: string): this;
|
|
1365
1212
|
/**
|
|
1366
|
-
*
|
|
1367
|
-
*
|
|
1368
|
-
* @param
|
|
1369
|
-
*
|
|
1213
|
+
* @deprecated Use 'setStyle' instead.
|
|
1214
|
+
* Set the route color of the outdoor part.
|
|
1215
|
+
* @param color The color type is a color in the sRGB color space.
|
|
1216
|
+
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
1217
|
+
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
1370
1218
|
*/
|
|
1371
|
-
|
|
1372
|
-
lng: number;
|
|
1373
|
-
lat: number;
|
|
1374
|
-
}, ordinal?: number): {
|
|
1375
|
-
venue: MapGeoJSONFeature | null;
|
|
1376
|
-
building: MapGeoJSONFeature | null;
|
|
1377
|
-
level: MapGeoJSONFeature | null;
|
|
1378
|
-
};
|
|
1219
|
+
setOutdoorLineColor(color: string): this;
|
|
1379
1220
|
/**
|
|
1380
|
-
*
|
|
1381
|
-
*
|
|
1382
|
-
* @param
|
|
1383
|
-
*
|
|
1221
|
+
* @deprecated Use 'setStyle' instead.
|
|
1222
|
+
* Set color of dashed lines which connected the start and end markers.
|
|
1223
|
+
* @param color The color type is a color in the sRGB color space.
|
|
1224
|
+
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
1225
|
+
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
1384
1226
|
*/
|
|
1385
|
-
|
|
1227
|
+
setDashedLineColor(color: string): this;
|
|
1386
1228
|
/**
|
|
1387
|
-
*
|
|
1388
|
-
*
|
|
1389
|
-
*
|
|
1390
|
-
*
|
|
1229
|
+
* @deprecated Use 'setStyle' instead.
|
|
1230
|
+
* Set color of shuttle bus line.
|
|
1231
|
+
* @param color The color type is a color in the sRGB color space.
|
|
1232
|
+
* Formats: HTML-style hex values, RGB, RGBA, HSL, and HSLA.
|
|
1233
|
+
* Predefined HTML colors names, like yellow and blue, are also permitted.
|
|
1391
1234
|
*/
|
|
1392
|
-
|
|
1235
|
+
setBusLineColor(color: string): this;
|
|
1393
1236
|
/**
|
|
1394
|
-
*
|
|
1395
|
-
* @param
|
|
1396
|
-
* @param
|
|
1397
|
-
* Default is true.
|
|
1237
|
+
* Render route on the map.
|
|
1238
|
+
* @param path Route path from RouteService.search response.
|
|
1239
|
+
* @param markerLocations Coordinate([lng, lat]) array of markers, order from beginning to end.
|
|
1398
1240
|
*/
|
|
1399
|
-
|
|
1400
|
-
|
|
1241
|
+
render(path: IRoutePath, markerLocations: Array<[
|
|
1242
|
+
number,
|
|
1243
|
+
number
|
|
1244
|
+
]>): void;
|
|
1401
1245
|
/**
|
|
1402
|
-
*
|
|
1403
|
-
* @param buildingId
|
|
1404
|
-
* @param options {dragPan: boolean} Set dragPan to be false, the map will not pan to the building center.
|
|
1405
|
-
* Default is true.
|
|
1246
|
+
* Remove route from the map.
|
|
1406
1247
|
*/
|
|
1407
|
-
|
|
1248
|
+
remove(): void;
|
|
1408
1249
|
/**
|
|
1409
|
-
*
|
|
1410
|
-
* @param venueId
|
|
1411
|
-
* @param
|
|
1412
|
-
* Default is true.
|
|
1250
|
+
* Filter paths' opacity by venue and ordinal.
|
|
1251
|
+
* @param venueId {string | null | undefined}
|
|
1252
|
+
* @param ordinal {string | null | undefined}
|
|
1413
1253
|
*/
|
|
1414
|
-
|
|
1254
|
+
setFilterByVenue(venueId: string | null | undefined, ordinal: string | null | undefined): void;
|
|
1415
1255
|
/**
|
|
1416
|
-
*
|
|
1417
|
-
* @param
|
|
1256
|
+
* Filter paths' opacity by building and ordinal.
|
|
1257
|
+
* @param buildingId {string | null | undefined}
|
|
1258
|
+
* @param ordinal {string | null | undefined}
|
|
1418
1259
|
*/
|
|
1419
|
-
|
|
1420
|
-
|
|
1260
|
+
setFilterByBuilding(buildingId: string | null | undefined, ordinal: string | null | undefined): void;
|
|
1261
|
+
private _classifyFeatures;
|
|
1262
|
+
private _createLineFeature;
|
|
1263
|
+
private _createIconFeature;
|
|
1264
|
+
private _renderSolidLines;
|
|
1265
|
+
private _renderDashedLines;
|
|
1266
|
+
private _renderConnectors;
|
|
1267
|
+
private _renderMarkers;
|
|
1268
|
+
private _addCollectionSource;
|
|
1269
|
+
private _addLineLayer;
|
|
1270
|
+
private _renderLineSymbols;
|
|
1271
|
+
private _addIconLayer;
|
|
1272
|
+
private _updateStyleProperties;
|
|
1273
|
+
private _loadMarkerIcons;
|
|
1274
|
+
private _updateLayers;
|
|
1275
|
+
private _filterRouteOpacity;
|
|
1276
|
+
}
|
|
1277
|
+
export interface IVenueInlineSharedFloor extends IFloorBase, IMapServices {
|
|
1278
|
+
name: IMultilingualName;
|
|
1279
|
+
refBuilding: Array<string>;
|
|
1280
|
+
}
|
|
1281
|
+
export interface IVenueInlineBuilding extends IMapServices {
|
|
1282
|
+
buildingName: IMultilingualName;
|
|
1283
|
+
buildingOutlineId: number;
|
|
1284
|
+
defaultFloor?: string;
|
|
1285
|
+
floors: IBuildingInlineFloor[];
|
|
1286
|
+
id: string;
|
|
1287
|
+
name: IMultilingualName;
|
|
1288
|
+
point: {
|
|
1289
|
+
type: string;
|
|
1290
|
+
coordinates: [
|
|
1291
|
+
number,
|
|
1292
|
+
number
|
|
1293
|
+
];
|
|
1421
1294
|
};
|
|
1295
|
+
}
|
|
1296
|
+
export interface IVenueInternal extends IBuildingBasicInfo, IBusinessInfo, IMapServices {
|
|
1297
|
+
buildings: IVenueInlineBuilding[];
|
|
1298
|
+
defaultBuilding?: string;
|
|
1299
|
+
id: string;
|
|
1300
|
+
organization: string[];
|
|
1301
|
+
owner: string;
|
|
1302
|
+
restricted: boolean;
|
|
1303
|
+
sharedFloors: IVenueInlineSharedFloor[];
|
|
1304
|
+
venueOutlineId: number;
|
|
1305
|
+
}
|
|
1306
|
+
export declare const omittedVenueKeys: readonly [
|
|
1307
|
+
"opening_hours",
|
|
1308
|
+
"description",
|
|
1309
|
+
"phone",
|
|
1310
|
+
"website",
|
|
1311
|
+
"email",
|
|
1312
|
+
"appURL",
|
|
1313
|
+
"icon"
|
|
1314
|
+
];
|
|
1315
|
+
export type TOmittedVenueKeys = (typeof omittedVenueKeys)[number];
|
|
1316
|
+
export type TVenue = Omit<IVenueInternal, TOmittedVenueKeys>;
|
|
1317
|
+
export type TVenueResponse<T> = IResponse<{
|
|
1318
|
+
venues: T[];
|
|
1319
|
+
total: number;
|
|
1320
|
+
}>;
|
|
1321
|
+
export interface IQuantitySpec {
|
|
1422
1322
|
/**
|
|
1423
|
-
*
|
|
1424
|
-
* @param listener
|
|
1323
|
+
* The maximum value is 100, default is 10.
|
|
1425
1324
|
*/
|
|
1426
|
-
|
|
1427
|
-
unsubscribe: VoidFunction;
|
|
1428
|
-
};
|
|
1325
|
+
offset?: number;
|
|
1429
1326
|
/**
|
|
1430
|
-
*
|
|
1431
|
-
* @param listener
|
|
1327
|
+
* Results for specified page number. Default is 1.
|
|
1432
1328
|
*/
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1329
|
+
page?: number;
|
|
1330
|
+
}
|
|
1331
|
+
export interface IDistanceSpec {
|
|
1436
1332
|
/**
|
|
1437
|
-
*
|
|
1438
|
-
* @param listener
|
|
1333
|
+
* The center of searching range, [lng, lat].
|
|
1439
1334
|
*/
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1335
|
+
center: [
|
|
1336
|
+
number,
|
|
1337
|
+
number
|
|
1338
|
+
];
|
|
1443
1339
|
/**
|
|
1444
|
-
*
|
|
1445
|
-
* Switch the map style
|
|
1446
|
-
* @param theme ThemeType | string(customized map style file name)
|
|
1340
|
+
* Radius from center, unit: meter for POIs, kilometers for buildings and venues, cannot exceed 10,000.
|
|
1447
1341
|
*/
|
|
1448
|
-
|
|
1449
|
-
|
|
1342
|
+
distance: number;
|
|
1343
|
+
}
|
|
1344
|
+
export interface IOrientationSpec {
|
|
1450
1345
|
/**
|
|
1451
|
-
*
|
|
1452
|
-
* Set the SelectedBuildingBorder's style. If set to null, the border will be invisible.
|
|
1453
|
-
* @param style {ISelectedHighlightStyle | null}
|
|
1346
|
+
* User's position, [lng, lat].
|
|
1454
1347
|
*/
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
private _setStyle;
|
|
1460
|
-
private _addControl;
|
|
1461
|
-
private _selectPoiById;
|
|
1462
|
-
private _resourceRequestTransform;
|
|
1463
|
-
private _checkMapZoom;
|
|
1464
|
-
private _updatePermission;
|
|
1465
|
-
private _selectCenterBuilding;
|
|
1348
|
+
center: [
|
|
1349
|
+
number,
|
|
1350
|
+
number
|
|
1351
|
+
];
|
|
1466
1352
|
/**
|
|
1467
|
-
*
|
|
1468
|
-
* @returns Map<buildingId, buildingFeature>
|
|
1353
|
+
* The angle between the user's orientation and true north.
|
|
1469
1354
|
*/
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1355
|
+
angle: number;
|
|
1356
|
+
/**
|
|
1357
|
+
* The radius with 'center' as the center of the circle.
|
|
1358
|
+
*/
|
|
1359
|
+
distance: number;
|
|
1360
|
+
}
|
|
1361
|
+
export interface IBoundsSpec {
|
|
1362
|
+
/** An array of LngLat coordinates in [sw, ne] order */
|
|
1363
|
+
bounds: [
|
|
1364
|
+
[
|
|
1365
|
+
number,
|
|
1366
|
+
number
|
|
1367
|
+
],
|
|
1368
|
+
[
|
|
1369
|
+
number,
|
|
1370
|
+
number
|
|
1371
|
+
]
|
|
1372
|
+
];
|
|
1373
|
+
}
|
|
1374
|
+
export interface IKeywordSpec {
|
|
1375
|
+
keywords?: string;
|
|
1376
|
+
}
|
|
1377
|
+
export interface IOrderSpec {
|
|
1378
|
+
orderBy?: PoisOrderBy;
|
|
1379
|
+
}
|
|
1380
|
+
export interface IBuildingSpec {
|
|
1381
|
+
buildingId: string;
|
|
1382
|
+
}
|
|
1383
|
+
export interface IVenueSpec {
|
|
1384
|
+
venueId: string;
|
|
1385
|
+
}
|
|
1386
|
+
export interface IFloorSpec {
|
|
1387
|
+
floorId: string;
|
|
1388
|
+
}
|
|
1389
|
+
export interface ISharedFloorSpec {
|
|
1390
|
+
sharedFloorId: string;
|
|
1391
|
+
}
|
|
1392
|
+
export interface IOrdinalSpec {
|
|
1393
|
+
ordinal: string;
|
|
1394
|
+
}
|
|
1395
|
+
export interface IOrientationSearchTypeSpec {
|
|
1396
|
+
/** The type of POI, default is 'Point' */
|
|
1397
|
+
distanceSearchType?: OrientationDistanceSearchType;
|
|
1398
|
+
}
|
|
1399
|
+
/** common search */
|
|
1400
|
+
export interface ISearchByKeywordsOptions extends IKeywordSpec, IQuantitySpec {
|
|
1401
|
+
}
|
|
1402
|
+
export interface ISearchByDistanceOptions extends IDistanceSpec, ISearchByKeywordsOptions {
|
|
1403
|
+
}
|
|
1404
|
+
export interface ISearchByBoundsOptions extends IBoundsSpec, ISearchByKeywordsOptions {
|
|
1405
|
+
}
|
|
1406
|
+
/** building/venue search */
|
|
1407
|
+
export interface IBuildingSearchCustomizedOptions {
|
|
1408
|
+
bounds?: [
|
|
1409
|
+
[
|
|
1410
|
+
number,
|
|
1411
|
+
number
|
|
1412
|
+
],
|
|
1413
|
+
[
|
|
1414
|
+
number,
|
|
1415
|
+
number
|
|
1416
|
+
]
|
|
1417
|
+
];
|
|
1418
|
+
center?: [
|
|
1419
|
+
number,
|
|
1420
|
+
number
|
|
1421
|
+
];
|
|
1422
|
+
distance?: number;
|
|
1423
|
+
keywords?: string;
|
|
1424
|
+
signal?: boolean;
|
|
1425
|
+
visual?: boolean;
|
|
1426
|
+
offset?: number;
|
|
1427
|
+
page?: number;
|
|
1428
|
+
}
|
|
1429
|
+
export interface IVenueSearchCustomizedOptions extends IBuildingSearchCustomizedOptions {
|
|
1430
|
+
}
|
|
1431
|
+
/** poi search */
|
|
1432
|
+
export interface ISearchByCategoryOptions extends IDistanceSpec, IQuantitySpec {
|
|
1433
|
+
category: string;
|
|
1434
|
+
}
|
|
1435
|
+
export interface ISearchByExcludedCategoriesOptions extends IDistanceSpec, IQuantitySpec {
|
|
1436
|
+
excludedCategories: string | string[];
|
|
1437
|
+
}
|
|
1438
|
+
export type TSearchByCategoryOptions = ISearchByCategoryOptions | ISearchByExcludedCategoriesOptions;
|
|
1439
|
+
export interface IPoiSearchByBoundsOptions extends ISearchByBoundsOptions, IOrderSpec {
|
|
1440
|
+
}
|
|
1441
|
+
export interface ISearchByBuildingOptions extends IBuildingSpec, ISearchByKeywordsOptions, IOrderSpec {
|
|
1442
|
+
}
|
|
1443
|
+
export interface ISearchByVenueOptions extends IVenueSpec, ISearchByKeywordsOptions, IOrderSpec {
|
|
1444
|
+
}
|
|
1445
|
+
export type TSearchByFloorsOptions = ({
|
|
1446
|
+
floorIds: string[];
|
|
1447
|
+
} & ISearchByKeywordsOptions & IOrderSpec) | ({
|
|
1448
|
+
sharedFloorIds: string[];
|
|
1449
|
+
} & ISearchByKeywordsOptions & IOrderSpec);
|
|
1450
|
+
export type TSearchByOrientationOptions = (IOrdinalSpec & IOrientationSpec & IQuantitySpec & IOrientationSearchTypeSpec) | (IFloorSpec & IOrientationSpec & IQuantitySpec & IOrientationSearchTypeSpec) | (IBuildingSpec & IOrientationSpec & IQuantitySpec & IOrientationSearchTypeSpec);
|
|
1451
|
+
export type TSearchCategoriesOptions = IVenueSpec | IBuildingSpec | IFloorSpec | ISharedFloorSpec | (IBoundsSpec & IKeywordSpec);
|
|
1452
|
+
export interface IPoiSearchCustomizedOptions {
|
|
1453
|
+
bounds?: [
|
|
1454
|
+
[
|
|
1455
|
+
number,
|
|
1456
|
+
number
|
|
1457
|
+
],
|
|
1458
|
+
[
|
|
1459
|
+
number,
|
|
1460
|
+
number
|
|
1461
|
+
]
|
|
1462
|
+
];
|
|
1463
|
+
center?: [
|
|
1464
|
+
number,
|
|
1465
|
+
number
|
|
1466
|
+
];
|
|
1467
|
+
distance?: number;
|
|
1468
|
+
category?: string;
|
|
1469
|
+
excludedCategories?: string | string[];
|
|
1470
|
+
/** @deprecated */
|
|
1471
|
+
floorId?: string;
|
|
1472
|
+
floorIds?: string[];
|
|
1473
|
+
sharedFloorIds?: string[];
|
|
1474
|
+
buildingId?: string;
|
|
1475
|
+
venueId?: string;
|
|
1476
|
+
keywords?: string;
|
|
1477
|
+
orderBy?: PoisOrderBy;
|
|
1478
|
+
sort?: PoisSortBy;
|
|
1479
|
+
distanceSearchType?: DistanceSearchType;
|
|
1480
|
+
offset?: number;
|
|
1481
|
+
page?: number;
|
|
1476
1482
|
}
|
|
1477
1483
|
export declare class Marker {
|
|
1478
1484
|
private readonly _maplibreMap;
|
|
@@ -1490,7 +1496,7 @@ export declare class Marker {
|
|
|
1490
1496
|
setIcon(icon: string): Promise<void>;
|
|
1491
1497
|
/**
|
|
1492
1498
|
* Set marker image size.
|
|
1493
|
-
* @param imageScale Default is
|
|
1499
|
+
* @param imageScale Default is 0.75
|
|
1494
1500
|
*/
|
|
1495
1501
|
setIconSize(imageScale: number): void;
|
|
1496
1502
|
/**
|
|
@@ -1611,173 +1617,123 @@ export declare class Poi {
|
|
|
1611
1617
|
private _queryIndoorFeaturesBySharedFloor;
|
|
1612
1618
|
private _queryIndoorFeaturesByFloor;
|
|
1613
1619
|
}
|
|
1614
|
-
/**
|
|
1615
|
-
* AccessControl class, for providing token and managing token lifecycle.
|
|
1616
|
-
* Three events are emitted:
|
|
1617
|
-
* - "updated": Emitted when the token is updated. Usage: accessControl.on("updated", ({ appId, token }) => {});
|
|
1618
|
-
* - "error": Emitted when an error occurs during token update. Usage: accessControl.on("error", (error) => {});
|
|
1619
|
-
* - "closed": Emitted when the access control is closed. Usage: accessControl.on("closed", () => {});
|
|
1620
|
-
*/
|
|
1621
|
-
export declare class AccessControl extends TinyEmitter {
|
|
1622
|
-
private readonly _appId;
|
|
1623
|
-
private readonly _secret;
|
|
1624
|
-
isClosed: boolean;
|
|
1625
|
-
private _timeoutId;
|
|
1626
|
-
private _isInitialized;
|
|
1627
|
-
private _initializationPromise;
|
|
1628
|
-
private _tokenManager;
|
|
1629
|
-
private readonly _from;
|
|
1630
|
-
constructor(appId: string, secret: string, origin?: AccessControlOrigin);
|
|
1631
|
-
ready(): Promise<void>;
|
|
1632
|
-
get appId(): string;
|
|
1633
|
-
/**
|
|
1634
|
-
* Get the token which is kept up-to-date automatically.
|
|
1635
|
-
*/
|
|
1636
|
-
get token(): string;
|
|
1637
|
-
/**
|
|
1638
|
-
* Destroy the access_control instance, stop updating token.
|
|
1639
|
-
*/
|
|
1640
|
-
close(): void;
|
|
1641
|
-
/**
|
|
1642
|
-
* For machine sleep for a long time, timer doesn't work, the token may be expired, so you can force update the token.
|
|
1643
|
-
*/
|
|
1644
|
-
forceUpdateToken(): void;
|
|
1645
|
-
private _initToken;
|
|
1646
|
-
private _loopUpdateToken;
|
|
1647
|
-
}
|
|
1648
1620
|
export declare class VenuesService {
|
|
1649
|
-
private _api;
|
|
1650
|
-
private _request;
|
|
1651
1621
|
constructor();
|
|
1652
1622
|
/**
|
|
1653
1623
|
* Search venues by ids.
|
|
1654
1624
|
* @param ids Single id string or string ids in array. The number of IDs cannot exceed 10.
|
|
1655
1625
|
*/
|
|
1656
|
-
searchByIds(ids: string | string[]):
|
|
1626
|
+
searchByIds(ids: string | string[]): Promise<TVenueResponse<TVenue>>;
|
|
1657
1627
|
/**
|
|
1658
1628
|
* Search venues by center and distance.
|
|
1659
1629
|
* @param {ISearchByDistanceOptions} options
|
|
1660
1630
|
*/
|
|
1661
|
-
searchByDistance(options: ISearchByDistanceOptions):
|
|
1631
|
+
searchByDistance(options: ISearchByDistanceOptions): Promise<TVenueResponse<TVenue>>;
|
|
1662
1632
|
/**
|
|
1663
1633
|
* Search venues in a rectangular area.
|
|
1664
1634
|
* @param {ISearchByBoundsOptions} options
|
|
1665
1635
|
*/
|
|
1666
|
-
searchByBounds(options: ISearchByBoundsOptions):
|
|
1636
|
+
searchByBounds(options: ISearchByBoundsOptions): Promise<TVenueResponse<TVenue>>;
|
|
1667
1637
|
/**
|
|
1668
1638
|
* Search venues by global.
|
|
1669
1639
|
* @param {ISearchByKeywordsOptions} options
|
|
1670
1640
|
*/
|
|
1671
|
-
searchByGlobal(options: ISearchByKeywordsOptions):
|
|
1672
|
-
searchBySharedFloorId(sharedFloorId: string):
|
|
1673
|
-
search(options: IVenueSearchCustomizedOptions):
|
|
1674
|
-
private
|
|
1641
|
+
searchByGlobal(options: ISearchByKeywordsOptions): Promise<TVenueResponse<TVenue>>;
|
|
1642
|
+
searchBySharedFloorId(sharedFloorId: string): Promise<TVenueResponse<TVenue>>;
|
|
1643
|
+
search(options: IVenueSearchCustomizedOptions): Promise<TVenueResponse<TVenue>>;
|
|
1644
|
+
private _filterVenueProperties;
|
|
1675
1645
|
}
|
|
1676
1646
|
export declare class BuildingsService {
|
|
1677
|
-
private _api;
|
|
1678
|
-
private _request;
|
|
1679
1647
|
constructor();
|
|
1680
1648
|
/**
|
|
1681
1649
|
* Search buildings by id[s].
|
|
1682
1650
|
* @param ids Single id string or string ids in array. The number of IDs cannot exceed 10.
|
|
1683
1651
|
*/
|
|
1684
|
-
searchByIds(ids: string | string[]):
|
|
1652
|
+
searchByIds(ids: string | string[]): Promise<TBuildingResponse<TBuilding>>;
|
|
1685
1653
|
/**
|
|
1686
1654
|
* Search buildings by center and distance.
|
|
1687
1655
|
* @param {ISearchByDistanceOptions} options
|
|
1688
1656
|
*/
|
|
1689
|
-
searchByDistance(options: ISearchByDistanceOptions):
|
|
1657
|
+
searchByDistance(options: ISearchByDistanceOptions): Promise<TBuildingResponse<TBuilding>>;
|
|
1690
1658
|
/**
|
|
1691
1659
|
* Search buildings in a rectangular area.
|
|
1692
1660
|
* @param {ISearchByBoundsOptions} options
|
|
1693
1661
|
*/
|
|
1694
|
-
searchByBounds(options: ISearchByBoundsOptions):
|
|
1662
|
+
searchByBounds(options: ISearchByBoundsOptions): Promise<TBuildingResponse<TBuilding>>;
|
|
1695
1663
|
/**
|
|
1696
1664
|
* Search buildings global.
|
|
1697
1665
|
* @param {ISearchByKeywordsOptions} options
|
|
1698
1666
|
*/
|
|
1699
|
-
searchByGlobal(options: ISearchByKeywordsOptions):
|
|
1667
|
+
searchByGlobal(options: ISearchByKeywordsOptions): Promise<TBuildingResponse<TBuilding>>;
|
|
1700
1668
|
/**
|
|
1701
1669
|
* Search building by floor id.
|
|
1702
1670
|
* @param floorId
|
|
1703
1671
|
*/
|
|
1704
|
-
searchByFloorId(floorId: string):
|
|
1705
|
-
search(options: IBuildingSearchCustomizedOptions):
|
|
1706
|
-
private
|
|
1672
|
+
searchByFloorId(floorId: string): Promise<TBuildingResponse<TBuilding>>;
|
|
1673
|
+
search(options: IBuildingSearchCustomizedOptions): Promise<TBuildingResponse<TBuilding>>;
|
|
1674
|
+
private _filterBuildingProperties;
|
|
1707
1675
|
}
|
|
1708
1676
|
export declare class PoisService {
|
|
1709
|
-
private _poisApi;
|
|
1710
|
-
private _categoriesGroupApi;
|
|
1711
|
-
private _request;
|
|
1712
1677
|
constructor();
|
|
1713
1678
|
/**
|
|
1714
1679
|
* Search POIs by id[s].
|
|
1715
1680
|
* @param ids Single id string or string ids in array. The number of IDs cannot exceed 100.
|
|
1716
1681
|
*/
|
|
1717
|
-
searchByIds(ids: string | string[]):
|
|
1682
|
+
searchByIds(ids: string | string[]): Promise<TPoiResponse<TPoi | TSharedPoi>>;
|
|
1718
1683
|
/**
|
|
1719
1684
|
* Search POIs by radius distance of the center point.
|
|
1720
1685
|
* @param options {ISearchByDistanceOptions}
|
|
1721
1686
|
*/
|
|
1722
|
-
searchByDistance(options: ISearchByDistanceOptions):
|
|
1687
|
+
searchByDistance(options: ISearchByDistanceOptions): Promise<TPoiResponse<TPoi | TSharedPoi>>;
|
|
1723
1688
|
/**
|
|
1724
1689
|
* Search POIs in a rectangular area.
|
|
1725
1690
|
* @param options {IPoiSearchByBoundsOptions}
|
|
1726
1691
|
* 'orderBy' cannot be used with 'keywords'.
|
|
1727
1692
|
*/
|
|
1728
|
-
searchByBounds(options: IPoiSearchByBoundsOptions):
|
|
1693
|
+
searchByBounds(options: IPoiSearchByBoundsOptions): Promise<TPoiResponse<TPoi | TSharedPoi>>;
|
|
1729
1694
|
/**
|
|
1730
1695
|
* Search POIs of a building.
|
|
1731
1696
|
* @param options {ISearchByBuildingOptions}
|
|
1732
1697
|
* 'orderBy' cannot be used with 'keywords'.
|
|
1733
1698
|
*/
|
|
1734
|
-
searchByBuilding(options: ISearchByBuildingOptions):
|
|
1699
|
+
searchByBuilding(options: ISearchByBuildingOptions): Promise<TPoiResponse<TPoi>>;
|
|
1735
1700
|
/**
|
|
1736
1701
|
* Search POIs of a venue.
|
|
1737
1702
|
* @param options {ISearchByVenueOptions}
|
|
1738
1703
|
* 'orderBy' cannot be used with 'keywords'.
|
|
1739
1704
|
*/
|
|
1740
|
-
searchByVenue(options: ISearchByVenueOptions):
|
|
1741
|
-
/**
|
|
1742
|
-
* @deprecated Use 'searchByFloors()' instead.
|
|
1743
|
-
* Search POIs of a floor.
|
|
1744
|
-
* @param options {TSearchByFloorOptions}
|
|
1745
|
-
* 'orderBy' cannot be used with 'keywords'.
|
|
1746
|
-
*/
|
|
1747
|
-
searchByFloor(options: TSearchByFloorOptions): TPromisePois<IPoi | ISharedPoi>;
|
|
1705
|
+
searchByVenue(options: ISearchByVenueOptions): Promise<TPoiResponse<TPoi | TSharedPoi>>;
|
|
1748
1706
|
/**
|
|
1749
1707
|
* Search POIs of floors.
|
|
1750
1708
|
* @param options {TSearchByFloorsOptions}
|
|
1751
1709
|
* 'orderBy' cannot be used with 'keywords'.
|
|
1752
1710
|
*/
|
|
1753
|
-
searchByFloors(options: TSearchByFloorsOptions):
|
|
1711
|
+
searchByFloors(options: TSearchByFloorsOptions): Promise<TPoiResponse<TPoi | TSharedPoi>>;
|
|
1754
1712
|
/**
|
|
1755
1713
|
* Search surrounding POIs based on the user's location and orientation.
|
|
1756
1714
|
* @param {TSearchByOrientationOptions} options
|
|
1757
1715
|
*/
|
|
1758
|
-
searchByOrientation(options: TSearchByOrientationOptions):
|
|
1716
|
+
searchByOrientation(options: TSearchByOrientationOptions): Promise<TOrientationPoisResponse>;
|
|
1759
1717
|
/**
|
|
1760
1718
|
* Search POIs by category or excluded categories.
|
|
1761
1719
|
* @param {TSearchByCategoryOptions} options
|
|
1762
1720
|
*/
|
|
1763
|
-
searchByCategory(options: TSearchByCategoryOptions):
|
|
1721
|
+
searchByCategory(options: TSearchByCategoryOptions): Promise<TPoiResponse<TPoi | TSharedPoi>>;
|
|
1764
1722
|
/**
|
|
1765
1723
|
* Search poi categories by venue id, building id, or floor id.
|
|
1766
1724
|
* @param {TSearchCategoriesOptions} options
|
|
1767
1725
|
*/
|
|
1768
|
-
searchCategories(options: TSearchCategoriesOptions):
|
|
1769
|
-
search(options: IPoiSearchCustomizedOptions):
|
|
1770
|
-
private
|
|
1726
|
+
searchCategories(options: TSearchCategoriesOptions): Promise<TCategoriesResponse>;
|
|
1727
|
+
search(options: IPoiSearchCustomizedOptions): Promise<TPoiResponse<TPoi | TSharedPoi>>;
|
|
1728
|
+
private _filterPoiProperties;
|
|
1771
1729
|
}
|
|
1772
1730
|
export declare class RouteService {
|
|
1773
|
-
private _api;
|
|
1774
|
-
private _request;
|
|
1775
1731
|
constructor();
|
|
1776
1732
|
/**
|
|
1777
1733
|
* Search the route of two or more points.
|
|
1778
1734
|
* @param options {IRouteSearchOptions}
|
|
1779
1735
|
*/
|
|
1780
|
-
search(options: IRouteSearchOptions):
|
|
1736
|
+
search(options: IRouteSearchOptions): Promise<IResponse<IResponseRoute>>;
|
|
1781
1737
|
}
|
|
1782
1738
|
export interface IMapxusLib {
|
|
1783
1739
|
Map: typeof Map$1;
|
|
@@ -1787,8 +1743,6 @@ export interface IMapxusLib {
|
|
|
1787
1743
|
Poi: typeof Poi;
|
|
1788
1744
|
RoutePainter: typeof RoutePainter;
|
|
1789
1745
|
/** @deprecated */
|
|
1790
|
-
AccessControl: typeof AccessControl;
|
|
1791
|
-
/** @deprecated */
|
|
1792
1746
|
BuildingFilterControl: typeof BuildingFilterControl;
|
|
1793
1747
|
BuildingSelectorHandler: typeof BuildingSelectorHandler;
|
|
1794
1748
|
/** @deprecated */
|