@wemap/core 14.5.5 → 14.6.0-beta.0

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/dist/index.d.ts CHANGED
@@ -3,7 +3,9 @@
3
3
  */
4
4
  export * from './src/CoreConfig';
5
5
  export * from './src/services/LivemapService';
6
+ export * from './src/services/BuildingService';
6
7
  export * from './src/services/HttpClient';
7
8
  export type { LatLngLike } from './src/types/common';
9
+ export type { Building, IndoorLevel } from './src/types/indoor';
8
10
  export { latLngLikeToCoordinates } from './src/utils/map';
9
11
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,kBAAkB,CAAC;AACjC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,2BAA2B,CAAC;AAE1C,YAAY,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAErD,OAAO,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,cAAc,kBAAkB,CAAC;AACjC,cAAc,+BAA+B,CAAC;AAC9C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,2BAA2B,CAAC;AAE1C,YAAY,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AACrD,YAAY,EAAE,QAAQ,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEhE,OAAO,EAAE,uBAAuB,EAAE,MAAM,iBAAiB,CAAC"}
package/dist/index.js CHANGED
@@ -3,8 +3,8 @@ var HttpError = class extends Error {
3
3
  status;
4
4
  statusText;
5
5
  data;
6
- constructor(e, h, g, _) {
7
- super(_ || `HTTP Error ${e}: ${h}`), this.name = "HttpError", this.status = e, this.statusText = h, this.data = g;
6
+ constructor(e, _, v, y) {
7
+ super(y || `HTTP Error ${e}: ${_}`), this.name = "HttpError", this.status = e, this.statusText = _, this.data = v;
8
8
  }
9
9
  }, HttpClient = class {
10
10
  config;
@@ -23,27 +23,27 @@ var HttpError = class extends Error {
23
23
  ...e
24
24
  };
25
25
  }
26
- buildUrl(e, h) {
27
- let g = e.startsWith("http") ? e : `${this.config.baseUrl}${e.startsWith("/") ? e : `/${e}`}`;
28
- if (!h || Object.keys(h).length === 0) return g;
29
- let _ = new URLSearchParams();
30
- return Object.entries(h).forEach(([e, h]) => {
31
- h != null && _.append(e, String(h));
32
- }), `${g}${g.includes("?") ? "&" : "?"}${_.toString()}`;
26
+ buildUrl(e, _) {
27
+ let v = e.startsWith("http") ? e : `${this.config.baseUrl}${e.startsWith("/") ? e : `/${e}`}`;
28
+ if (!_ || Object.keys(_).length === 0) return v;
29
+ let y = new URLSearchParams();
30
+ return Object.entries(_).forEach(([e, _]) => {
31
+ _ != null && y.append(e, String(_));
32
+ }), `${v}${v.includes("?") ? "&" : "?"}${y.toString()}`;
33
33
  }
34
34
  mergeHeaders(e) {
35
- let h = new Headers();
36
- return this.config.defaultHeaders && Object.entries(this.config.defaultHeaders).forEach(([e, g]) => {
37
- h.set(e, g);
38
- }), e && Object.entries(e).forEach(([e, g]) => {
39
- h.set(e, g);
40
- }), h;
35
+ let _ = new Headers();
36
+ return this.config.defaultHeaders && Object.entries(this.config.defaultHeaders).forEach(([e, v]) => {
37
+ _.set(e, v);
38
+ }), e && Object.entries(e).forEach(([e, v]) => {
39
+ _.set(e, v);
40
+ }), _;
41
41
  }
42
42
  async parseResponse(e) {
43
- let h = e.headers.get("content-type") || "";
44
- if (h.includes("application/json")) return await e.json();
45
- if (h.includes("text/")) return await e.text();
46
- if (h.includes("application/octet-stream") || h.includes("application/pdf")) return await e.blob();
43
+ let _ = e.headers.get("content-type") || "";
44
+ if (_.includes("application/json")) return await e.json();
45
+ if (_.includes("text/")) return await e.text();
46
+ if (_.includes("application/octet-stream") || _.includes("application/pdf")) return await e.blob();
47
47
  try {
48
48
  return await e.json();
49
49
  } catch {
@@ -51,77 +51,77 @@ var HttpError = class extends Error {
51
51
  }
52
52
  }
53
53
  async handleError(e) {
54
- let h;
54
+ let _;
55
55
  try {
56
- h = await this.parseResponse(e);
56
+ _ = await this.parseResponse(e);
57
57
  } catch {
58
- h = await e.text().catch(() => null);
58
+ _ = await e.text().catch(() => null);
59
59
  }
60
- throw new HttpError(e.status, e.statusText, h, `HTTP ${e.status}: ${e.statusText}`);
60
+ throw new HttpError(e.status, e.statusText, _, `HTTP ${e.status}: ${e.statusText}`);
61
61
  }
62
62
  createAbortController(e) {
63
63
  if (!e && !this.config.timeout) return null;
64
- let h = new AbortController(), g = e || this.config.timeout || 3e4;
64
+ let _ = new AbortController(), v = e || this.config.timeout || 3e4;
65
65
  return setTimeout(() => {
66
- h.abort();
67
- }, g), h;
66
+ _.abort();
67
+ }, v), _;
68
68
  }
69
- async request(e, h = {}) {
70
- let { method: _ = "GET", headers: v, body: y, params: b, timeout: x } = h, S = this.buildUrl(e, b), C = this.mergeHeaders(v), w = this.createAbortController(x);
69
+ async request(e, _ = {}) {
70
+ let { method: y = "GET", headers: b, body: x, params: S, timeout: C } = _, w = this.buildUrl(e, S), T = this.mergeHeaders(b), E = this.createAbortController(C);
71
71
  try {
72
72
  let e = {
73
- method: _,
74
- headers: C,
75
- signal: w?.signal
73
+ method: y,
74
+ headers: T,
75
+ signal: E?.signal
76
76
  };
77
- if (y !== void 0 && _ !== "GET") if (typeof y == "string") e.body = y;
78
- else if (y instanceof FormData || y instanceof Blob) {
79
- if (e.body = y, y instanceof FormData) {
80
- let h = new Headers(C);
81
- h.delete("Content-Type"), e.headers = h;
77
+ if (x !== void 0 && y !== "GET") if (typeof x == "string") e.body = x;
78
+ else if (x instanceof FormData || x instanceof Blob) {
79
+ if (e.body = x, x instanceof FormData) {
80
+ let _ = new Headers(T);
81
+ _.delete("Content-Type"), e.headers = _;
82
82
  }
83
- } else e.body = JSON.stringify(y);
84
- let h = await fetch(S, e);
85
- return h.ok || await this.handleError(h), {
86
- data: await this.parseResponse(h),
87
- status: h.status,
88
- statusText: h.statusText,
89
- headers: h.headers
83
+ } else e.body = JSON.stringify(x);
84
+ let _ = await fetch(w, e);
85
+ return _.ok || await this.handleError(_), {
86
+ data: await this.parseResponse(_),
87
+ status: _.status,
88
+ statusText: _.statusText,
89
+ headers: _.headers
90
90
  };
91
91
  } catch (e) {
92
- throw e instanceof HttpError ? e : e instanceof Error && e.name === "AbortError" ? new HttpError(408, "Request Timeout", null, `Request timeout after ${x || this.config.timeout || 3e4}ms`) : new HttpError(0, "Network Error", null, e instanceof Error ? e.message : "Unknown error occurred");
92
+ throw e instanceof HttpError ? e : e instanceof Error && e.name === "AbortError" ? new HttpError(408, "Request Timeout", null, `Request timeout after ${C || this.config.timeout || 3e4}ms`) : new HttpError(0, "Network Error", null, e instanceof Error ? e.message : "Unknown error occurred");
93
93
  }
94
94
  }
95
- async get(e, h) {
95
+ async get(e, _) {
96
96
  return this.request(e, {
97
- ...h,
97
+ ..._,
98
98
  method: "GET"
99
99
  });
100
100
  }
101
- async post(e, h, g) {
101
+ async post(e, _, v) {
102
102
  return this.request(e, {
103
- ...g,
103
+ ...v,
104
104
  method: "POST",
105
- body: h
105
+ body: _
106
106
  });
107
107
  }
108
- async put(e, h, g) {
108
+ async put(e, _, v) {
109
109
  return this.request(e, {
110
- ...g,
110
+ ...v,
111
111
  method: "PUT",
112
- body: h
112
+ body: _
113
113
  });
114
114
  }
115
- async patch(e, h, g) {
115
+ async patch(e, _, v) {
116
116
  return this.request(e, {
117
- ...g,
117
+ ...v,
118
118
  method: "PATCH",
119
- body: h
119
+ body: _
120
120
  });
121
121
  }
122
- async delete(e, h) {
122
+ async delete(e, _) {
123
123
  return this.request(e, {
124
- ...h,
124
+ ..._,
125
125
  method: "DELETE"
126
126
  });
127
127
  }
@@ -133,49 +133,88 @@ var HttpError = class extends Error {
133
133
  async fetchLivemap(e) {
134
134
  return (await this.httpClient.get(`/livemaps/${e}`)).data;
135
135
  }
136
- }, livemap_snippet_default = {
136
+ }, BuildingService = class e {
137
+ static MIN_BBOX_SIZE = 3e3;
138
+ static PAGE_SIZE = 20;
139
+ http;
140
+ emmid;
141
+ buildings = /* @__PURE__ */ new Map();
142
+ cachedBbox = null;
143
+ constructor(e, _) {
144
+ this.http = new HttpClient({ baseUrl: e }), this.emmid = String(_);
145
+ }
146
+ async getBuildingsFromBbox(_) {
147
+ if (!(this.cachedBbox?.contains(_.getNorthWest()) && this.cachedBbox?.contains(_.getSouthEast()))) {
148
+ let v = e.MIN_BBOX_SIZE / 2, y = _.extend(_.center.destinationPoint(v, 0)).extend(_.center.destinationPoint(v, Math.PI / 2)).extend(_.center.destinationPoint(v, Math.PI)).extend(_.center.destinationPoint(v, 3 * Math.PI / 2));
149
+ for (let e of await this.fetchAll()) e.id != null && this.buildings.set(Number(e.id), e);
150
+ this.cachedBbox = y;
151
+ }
152
+ return this.intersecting(_);
153
+ }
154
+ intersecting(e) {
155
+ let _ = e.toArray(), v = [];
156
+ for (let e of this.buildings.values()) e.bbox && bboxIntersects(_, e.bbox) && v.push(e);
157
+ return v;
158
+ }
159
+ async fetchAll() {
160
+ let _ = [], v = 0, y = 0;
161
+ do {
162
+ let { data: b } = await this.http.get("/buildings/search", { params: {
163
+ livemap: this.emmid,
164
+ limit: e.PAGE_SIZE,
165
+ offset: y
166
+ } });
167
+ v ||= b.count, _.push(...b.results), y += e.PAGE_SIZE;
168
+ } while (_.length < v);
169
+ return _;
170
+ }
171
+ };
172
+ function bboxIntersects(e, _) {
173
+ return e[0] <= _[2] && e[2] >= _[0] && e[1] <= _[3] && e[3] >= _[1];
174
+ }
175
+ var livemap_snippet_default = {
137
176
  properties: /* @__PURE__ */ JSON.parse("{\"actionbuttons\":{\"default\":{\"withlabel\":false},\"description\":\"Configuration relative to the action buttons\",\"properties\":{\"withlabel\":{\"default\":false,\"description\":\"Enable label on action buttons\",\"type\":\"boolean\"}},\"type\":\"object\"},\"analytics\":{\"default\":null,\"description\":\"Parameters relative to analytics\",\"type\":\"object\",\"properties\":{\"gtagIDs\":{\"default\":[],\"description\":\"Gtag IDs to configure\",\"type\":\"array\",\"items\":{\"type\":\"string\"}}}},\"arnavigationdata\":{\"default\":{\"arRadius\":1000,\"audio\":false,\"maxDistanceNavigation\":10000,\"default\":\"outdoor\",\"cursorVisible\":true,\"cursorTimeout\":1000,\"mapFooter\":false,\"indoor\":{\"accuracyThreshold\":8,\"end\":{\"geofence\":5,\"visibleDistance\":200},\"instructions\":{\"geofence\":3,\"maxDistance\":10,\"minAlt\":1,\"opacityDistanceStart\":10,\"realSizeScale\":1,\"scale\":0.06,\"audioDistance\":10},\"itinerary\":{\"sampling\":1.6,\"opacityDistanceEnd\":15,\"arrowTargetDistance\":5},\"mapmatching\":{\"network\":null,\"maxAngleBearing\":30,\"maxDistance\":15,\"minDistance\":1,\"useItineraryStartAsPosition\":false,\"useOrientationMatching\":true,\"useStrict\":false,\"hugeJumpDistance\":3,\"minStepsBetweenOrientationMatching\":3,\"minStepsForOrientationMatching\":5,\"lastProjectionsWindowSize\":3,\"lastProjectionsEdgeAngleThreshold\":3,\"disableMMCloseToATurnDistance\":2},\"multilevel\":{\"geofenceDisableNav\":3},\"pinpoints\":{\"scale\":0.09,\"updateDistance\":30,\"minDistance\":1,\"overlap\":false,\"label\":true}},\"outdoor\":{\"accuracyThreshold\":25,\"end\":{\"geofence\":15,\"visibleDistance\":200},\"instructions\":{\"geofence\":10,\"maxDistance\":40,\"minAlt\":1.5,\"opacityDistanceStart\":20,\"realSizeScale\":3,\"scale\":0.03,\"audioDistance\":30},\"itinerary\":{\"sampling\":1.6,\"opacityDistanceEnd\":30,\"arrowTargetDistance\":10},\"mapmatching\":{\"network\":null,\"maxAngleBearing\":30,\"maxDistance\":50,\"minDistance\":0,\"useItineraryStartAsPosition\":false,\"useOrientationMatching\":true,\"useStrict\":false,\"hugeJumpDistance\":3,\"minStepsBetweenOrientationMatching\":3,\"minStepsForOrientationMatching\":5,\"lastProjectionsWindowSize\":3,\"lastProjectionsEdgeAngleThreshold\":3,\"disableMMCloseToATurnDistance\":2},\"multilevel\":{\"geofenceDisableNav\":3},\"pinpoints\":{\"scale\":0.09,\"updateDistance\":30,\"minDistance\":1,\"overlap\":false,\"label\":true}},\"providers\":{\"blacklist\":[],\"gnssWifi\":{\"discardPositionsAbove\":50,\"enableHighAccuracy\":true},\"polestarkey\":null,\"straightLineDetector\":{\"stepsConsideredForStraightLine\":2},\"stepDetector\":{\"algorithm\":\"minMaxPeaks2\",\"stepSizeMultiplier\":1,\"minMaxPeaks2\":null,\"minMaxPeaks3\":null},\"useMapMatching\":true,\"usePositionSmoother\":true,\"useAllAbsolutePositions\":false,\"vps\":null,\"whitelist\":[]},\"visibleTags\":[]},\"description\":\"Configuration relative to the AR navigation \",\"properties\":{\"arRadius\":{\"default\":1000,\"description\":\"Maximum distance for the displayed pinpoints in AR view (in meters)\",\"type\":\"integer\"},\"default\":{\"default\":\"outdoor\",\"description\":\"The default value for the ar navigation parameters\",\"type\":\"string\"},\"audio\":{\"default\":false,\"description\":\"If the user should be guided with audio\",\"type\":\"boolean\"},\"cursorVisible\":{\"default\":true,\"description\":\"If the cursor should be visible\",\"type\":\"boolean\"},\"cursorTimeout\":{\"default\":1000,\"description\":\"The timeout to open a pinpoint with the cursor\",\"type\":\"number\"},\"maxDistanceNavigation\":{\"default\":10000,\"description\":\"The max distance where the navigation is started directly\",\"type\":\"number\"},\"mapFooter\":{\"default\":false,\"description\":\"If the map should be shown at footer on navigation\",\"type\":\"boolean\"},\"indoor\":{\"default\":{\"accuracyThreshold\":8,\"end\":{\"geofence\":5,\"visibleDistance\":200},\"instructions\":{\"geofence\":3,\"maxDistance\":10,\"minAlt\":1,\"opacityDistanceStart\":10,\"realSizeScale\":1,\"scale\":0.06,\"audioDistance\":10},\"itinerary\":{\"sampling\":1.6,\"opacityDistanceEnd\":15,\"arrowTargetDistance\":5},\"mapmatching\":{\"network\":null,\"maxAngleBearing\":30,\"maxDistance\":15,\"minDistance\":1,\"useItineraryStartAsPosition\":false,\"useOrientationMatching\":true,\"useStrict\":false,\"hugeJumpDistance\":3,\"minStepsBetweenOrientationMatching\":3,\"minStepsForOrientationMatching\":5,\"lastProjectionsWindowSize\":3,\"lastProjectionsEdgeAngleThreshold\":3,\"disableMMCloseToATurnDistance\":2},\"multilevel\":{\"geofenceDisableNav\":3},\"pinpoints\":{\"scale\":0.09,\"updateDistance\":30,\"minDistance\":1,\"overlap\":false,\"label\":true}},\"properties\":{\"accuracyThreshold\":{\"default\":8,\"type\":\"integer\"},\"end\":{\"default\":{\"geofence\":5,\"visibleDistance\":200},\"type\":\"object\",\"properties\":{\"geofence\":{\"type\":\"integer\",\"default\":5},\"visibleDistance\":{\"type\":\"integer\",\"default\":200}}},\"instructions\":{\"default\":{\"geofence\":3,\"maxDistance\":10,\"minAlt\":1,\"opacityDistanceStart\":10,\"realSizeScale\":1,\"scale\":0.06,\"audioDistance\":10},\"type\":\"object\",\"properties\":{\"geofence\":{\"type\":\"integer\",\"default\":3},\"maxDistance\":{\"type\":\"integer\",\"description\":\"Distance from which the instruction will be display instead of banner with meters\",\"default\":10},\"minAlt\":{\"type\":\"integer\",\"default\":1},\"opacityDistanceStart\":{\"type\":\"integer\",\"default\":10},\"realSizeScale\":{\"type\":\"integer\",\"default\":1},\"scale\":{\"type\":\"number\",\"default\":0.06},\"audioDistance\":{\"type\":\"integer\",\"description\":\"Distance from which the audio will be triggered between 2 steps\",\"default\":10}}},\"itinerary\":{\"default\":{\"sampling\":1.6,\"opacityDistanceEnd\":15,\"arrowTargetDistance\":5},\"type\":\"object\",\"properties\":{\"sampling\":{\"type\":\"integer\",\"default\":1.6},\"opacityDistanceEnd\":{\"type\":\"integer\",\"default\":15},\"arrowTargetDistance\":{\"type\":\"integer\",\"default\":5}}},\"mapmatching\":{\"default\":{\"network\":null,\"maxAngleBearing\":30,\"maxDistance\":15,\"minDistance\":1,\"useItineraryStartAsPosition\":false,\"useOrientationMatching\":true,\"useStrict\":false,\"hugeJumpDistance\":3,\"minStepsBetweenOrientationMatching\":3,\"minStepsForOrientationMatching\":5,\"lastProjectionsWindowSize\":3,\"lastProjectionsEdgeAngleThreshold\":3,\"disableMMCloseToATurnDistance\":2},\"type\":\"object\",\"properties\":{\"network\":{\"type\":\"string\",\"description\":\"Network to use outside a navigation\",\"default\":null},\"maxAngleBearing\":{\"type\":\"integer\",\"default\":30},\"maxDistance\":{\"type\":\"integer\",\"default\":15},\"minDistance\":{\"type\":\"integer\",\"default\":1},\"useItineraryStartAsPosition\":{\"type\":\"boolean\",\"default\":false},\"useOrientationMatching\":{\"type\":\"boolean\",\"default\":true},\"useStrict\":{\"type\":\"boolean\",\"default\":false},\"hugeJumpDistance\":{\"type\":\"number\",\"default\":3},\"minStepsBetweenOrientationMatching\":{\"type\":\"number\",\"default\":3},\"minStepsForOrientationMatching\":{\"type\":\"number\",\"default\":5},\"lastProjectionsWindowSize\":{\"type\":\"number\",\"default\":3},\"lastProjectionsEdgeAngleThreshold\":{\"type\":\"number\",\"default\":3},\"disableMMCloseToATurnDistance\":{\"type\":\"number\",\"default\":2}}},\"multilevel\":{\"default\":{\"geofenceDisableNav\":3},\"type\":\"object\",\"properties\":{\"geofenceDisableNav\":{\"type\":\"integer\",\"default\":3}}},\"pinpoints\":{\"default\":{\"scale\":0.09,\"updateDistance\":30,\"minDistance\":1,\"overlap\":false,\"label\":true},\"type\":\"object\",\"properties\":{\"scale\":{\"type\":\"number\",\"default\":0.09},\"updateDistance\":{\"type\":\"integer\",\"default\":30},\"minDistance\":{\"type\":\"integer\",\"default\":1},\"overlap\":{\"default\":false,\"description\":\"If pinpoint shape in AR should overlap between each other\",\"type\":\"boolean\"},\"label\":{\"default\":true,\"description\":\"If pinpoint shape in AR should have label\",\"type\":\"boolean\"}}}},\"description\":\"The indoor set of parameters\",\"type\":\"object\"},\"outdoor\":{\"default\":{\"accuracyThreshold\":25,\"end\":{\"geofence\":15,\"visibleDistance\":200},\"instructions\":{\"maxDistance\":40,\"geofence\":10,\"minAlt\":1.5,\"opacityDistanceStart\":20,\"realSizeScale\":3,\"scale\":0.03,\"audioDistance\":30},\"itinerary\":{\"sampling\":1.6,\"opacityDistanceEnd\":30,\"arrowTargetDistance\":10},\"mapmatching\":{\"network\":null,\"maxAngleBearing\":30,\"maxDistance\":50,\"minDistance\":0,\"useItineraryStartAsPosition\":false,\"useOrientationMatching\":true,\"useStrict\":false,\"hugeJumpDistance\":3,\"minStepsBetweenOrientationMatching\":3,\"minStepsForOrientationMatching\":5,\"lastProjectionsWindowSize\":3,\"lastProjectionsEdgeAngleThreshold\":3,\"disableMMCloseToATurnDistance\":2},\"multilevel\":{\"geofenceDisableNav\":3},\"pinpoints\":{\"scale\":0.09,\"updateDistance\":30,\"minDistance\":1,\"overlap\":false,\"label\":true}},\"properties\":{\"accuracyThreshold\":{\"default\":25,\"type\":\"integer\"},\"end\":{\"default\":{\"geofence\":15,\"visibleDistance\":200},\"type\":\"object\",\"properties\":{\"geofence\":{\"type\":\"integer\",\"default\":15},\"visibleDistance\":{\"type\":\"integer\",\"default\":200}}},\"instructions\":{\"default\":{\"geofence\":10,\"maxDistance\":40,\"minAlt\":1.5,\"opacityDistanceStart\":20,\"realSizeScale\":3,\"scale\":0.03,\"audioDistance\":30},\"type\":\"object\",\"properties\":{\"geofence\":{\"type\":\"integer\",\"default\":10},\"maxDistance\":{\"type\":\"integer\",\"description\":\"Distance from which the instruction will be display instead of banner with meters\",\"default\":40},\"minAlt\":{\"type\":\"integer\",\"default\":1.5},\"opacityDistanceStart\":{\"type\":\"integer\",\"default\":20},\"realSizeScale\":{\"type\":\"integer\",\"default\":3},\"scale\":{\"type\":\"number\",\"default\":0.03},\"audioDistance\":{\"type\":\"integer\",\"description\":\"Distance from which the audio will be triggered between 2 instructions\",\"default\":30}}},\"itinerary\":{\"default\":{\"sampling\":1.6,\"opacityDistanceEnd\":30,\"arrowTargetDistance\":10},\"type\":\"object\",\"properties\":{\"sampling\":{\"type\":\"integer\",\"default\":1.6},\"opacityDistanceEnd\":{\"type\":\"integer\",\"default\":30},\"arrowTargetDistance\":{\"type\":\"integer\",\"default\":10}}},\"mapmatching\":{\"default\":{\"network\":null,\"maxAngleBearing\":30,\"maxDistance\":50,\"minDistance\":0,\"useItineraryStartAsPosition\":false,\"useOrientationMatching\":true,\"useStrict\":false,\"hugeJumpDistance\":3,\"minStepsBetweenOrientationMatching\":3,\"minStepsForOrientationMatching\":5,\"lastProjectionsWindowSize\":3,\"lastProjectionsEdgeAngleThreshold\":3,\"disableMMCloseToATurnDistance\":2},\"type\":\"object\",\"properties\":{\"useItineraryStartAsPosition\":{\"type\":\"boolean\",\"default\":false},\"network\":{\"type\":\"string\",\"description\":\"Network to use outside a navigation\",\"default\":null},\"maxAngleBearing\":{\"type\":\"number\",\"default\":30},\"maxDistance\":{\"type\":\"integer\",\"default\":50},\"minDistance\":{\"type\":\"integer\",\"default\":0},\"useOrientationMatching\":{\"type\":\"boolean\",\"default\":true},\"useStrict\":{\"type\":\"boolean\",\"default\":false},\"hugeJumpDistance\":{\"type\":\"number\",\"default\":3},\"minStepsBetweenOrientationMatching\":{\"type\":\"number\",\"default\":3},\"minStepsForOrientationMatching\":{\"type\":\"number\",\"default\":5},\"lastProjectionsWindowSize\":{\"type\":\"number\",\"default\":3},\"lastProjectionsEdgeAngleThreshold\":{\"type\":\"number\",\"default\":3},\"disableMMCloseToATurnDistance\":{\"type\":\"number\",\"default\":2}}},\"multilevel\":{\"default\":{\"geofenceDisableNav\":3},\"type\":\"object\",\"properties\":{\"geofenceDisableNav\":{\"type\":\"integer\",\"default\":3}}},\"pinpoints\":{\"default\":{\"scale\":0.09,\"updateDistance\":30,\"minDistance\":1,\"overlap\":false,\"label\":true},\"type\":\"object\",\"properties\":{\"scale\":{\"type\":\"number\",\"default\":0.09},\"updateDistance\":{\"type\":\"integer\",\"default\":30},\"minDistance\":{\"type\":\"integer\",\"default\":1},\"overlap\":{\"default\":false,\"description\":\"If pinpoint shape in AR should overlap between each other\",\"type\":\"boolean\"},\"label\":{\"default\":true,\"description\":\"If pinpoint shape in AR should have label\",\"type\":\"boolean\"}}}},\"description\":\"The outdoor set of parameters\",\"type\":\"object\"},\"providers\":{\"default\":{\"blacklist\":[],\"gnssWifi\":{\"discardPositionsAbove\":50,\"enableHighAccuracy\":true},\"polestarkey\":null,\"straightLineDetector\":{\"stepsConsideredForStraightLine\":2},\"stepDetector\":{\"algorithm\":\"minMaxPeaks2\",\"stepSizeMultiplier\":1,\"minMaxPeaks2\":null,\"minMaxPeaks3\":null},\"useMapMatching\":true,\"usePositionSmoother\":true,\"useAllAbsolutePositions\":false,\"vps\":null,\"whitelist\":[]},\"properties\":{\"blacklist\":{\"default\":[],\"type\":\"array\"},\"gnssWifi\":{\"default\":{\"discardPositionsAbove\":50,\"enableHighAccuracy\":true},\"properties\":{\"discardPositionsAbove\":{\"default\":50,\"type\":\"number\"},\"enableHighAccuracy\":{\"default\":true,\"type\":\"boolean\"}}},\"polestarkey\":{\"default\":null,\"type\":\"string\"},\"straightLineDetector\":{\"default\":{\"stepsConsideredForStraightLine\":2},\"properties\":{\"stepsConsideredForStraightLine\":{\"default\":2,\"type\":\"number\"}},\"type\":\"object\"},\"stepDetector\":{\"default\":{\"algorithm\":\"minMaxPeaks2\",\"stepSizeMultiplier\":1,\"minMaxPeaks2\":null,\"minMaxPeaks3\":null},\"properties\":{\"algorithm\":{\"default\":\"minMaxPeaks2\",\"enum\":[\"ladetto\",\"minMaxPeaks\",\"minMaxPeaks2\",\"minMaxPeaks3\"],\"type\":\"string\"},\"stepSizeMultiplier\":{\"default\":1,\"type\":\"number\"},\"minMaxPeaks2\":{\"default\":null,\"properties\":{\"windowTime\":{\"default\":0.3,\"type\":\"number\"},\"minTimeBetweenSteps\":{\"default\":0.4,\"type\":\"number\"},\"maxFrequency\":{\"default\":4,\"type\":\"number\"},\"minFrequency\":{\"default\":1,\"type\":\"number\"},\"verticalAccPositivePeakThreshold\":{\"default\":0.75,\"type\":\"number\"},\"verticalAccNegativePeakThreshold\":{\"default\":-0.3,\"type\":\"number\"}},\"type\":\"object\"},\"minMaxPeaks3\":{\"default\":null,\"properties\":{\"windowTime\":{\"default\":0.6,\"type\":\"number\"},\"minTimeBetweenSteps\":{\"default\":0.6,\"type\":\"number\"},\"maxFrequency\":{\"default\":4,\"type\":\"number\"},\"minFrequency\":{\"default\":1,\"type\":\"number\"},\"verticalAccPositivePeakThreshold\":{\"default\":0.2,\"type\":\"number\"},\"verticalAccNegativePeakThreshold\":{\"default\":-0.1,\"type\":\"number\"}},\"type\":\"object\"}},\"type\":\"object\"},\"useMapMatching\":{\"default\":true,\"type\":\"boolean\"},\"usePositionSmoother\":{\"default\":true,\"type\":\"boolean\"},\"useAllAbsolutePositions\":{\"default\":false,\"type\":\"boolean\"},\"vps\":{\"default\":null,\"properties\":{\"endpoint\":{\"default\":null,\"type\":\"string\"},\"minInclinationForRequest\":{\"default\":60,\"type\":\"number\"},\"useInclination\":{\"default\":true,\"type\":\"boolean\"},\"requestInterval\":{\"default\":null,\"type\":\"number\"},\"useCoarsePose\":{\"default\":true,\"type\":\"boolean\"},\"waitTimeMinInclinationForRequest\":{\"default\":200,\"type\":\"number\"}},\"type\":\"object\"},\"whitelist\":{\"default\":[],\"type\":\"array\"}},\"description\":\"Providers to use or not\",\"type\":\"object\"},\"visibleTags\":{\"default\":[],\"type\":\"array\",\"items\":{\"type\":\"string\"}}},\"type\":\"object\"},\"addcid\":{\"default\":false,\"description\":\"Double Click Publisher ID\",\"type\":\"string\"},\"addcslot\":{\"default\":false,\"description\":\"Double Click Ad Slot\",\"type\":\"string\"},\"addcsize\":{\"default\":false,\"description\":\"Double Click Size\",\"items\":{\"items\":{\"type\":\"integer\"},\"maxItems\":2,\"minItems\":2,\"type\":\"array\"},\"type\":\"array\"},\"addctarget\":{\"default\":false,\"description\":\"Double Click Target\",\"items\":{\"items\":{\"type\":\"string\"},\"maxItems\":2,\"minItems\":2,\"type\":\"array\"},\"type\":\"array\"},\"adheight\":{\"default\":false,\"description\":\"Ad display height options.\",\"type\":\"string\"},\"adsenseid\":{\"default\":false,\"description\":\"Adsense\",\"type\":\"integer\"},\"adsenseslot\":{\"default\":false,\"description\":\"Adsense\",\"type\":\"integer\"},\"adwidth\":{\"default\":false,\"description\":\"Ad display width options.\",\"type\":\"string\"},\"aroundme\":{\"default\":true,\"description\":\"Show around button in livemap.\",\"type\":\"boolean\"},\"arviewenabled\":{\"default\":false,\"description\":\"Enable the Wemap-AR view on compatible mobile devices.\",\"type\":\"boolean\"},\"arswitcherbutton\":{\"default\":false,\"description\":\"Use button instead of device inclination for switching AR/map\",\"type\":\"boolean\"},\"autocenter\":{\"default\":0,\"description\":\"Automatic centering on landing area when idle (in milliseconds).\",\"type\":\"integer\"},\"autologin\":{\"default\":true,\"description\":\"Use localStorage to login.\",\"type\":\"boolean\"},\"autoplay\":{\"default\":false,\"description\":\"Slideshow of pinpoints when map is idle.\",\"type\":[\"boolean\",\"object\"]},\"autoplayoverlay\":{\"default\":false,\"description\":\"If true, the autoplay will be locked with an overlay and no interaction will be available\",\"type\":\"boolean\"},\"autoplaytimeout\":{\"default\":5000,\"description\":\"How long until considering the map as idle (in milliseconds).\",\"type\":\"integer\"},\"bodyfullscreen\":{\"default\":false,\"description\":\"If body parent to livemap should be showned in fullscreen mode instead of livemap's container.\",\"type\":\"boolean\"},\"calendarfilterenabled\":{\"default\":false,\"description\":\"Force to enable calendar filter even if useevents is false.\",\"type\":\"boolean\"},\"calendarfiltermindate\":{\"default\":\"\",\"description\":\"Min date at ISO format for calendar filter (filters view & welcome card)\",\"type\":\"string\"},\"calendarfiltermaxdate\":{\"default\":\"\",\"description\":\"Max date at ISO format for calendar filter (filters view & welcome card)\",\"type\":\"string\"},\"cancomment\":{\"default\":true,\"description\":\"Ability to comment/contribute on pinpoints.\",\"type\":\"boolean\"},\"canopenpinpoint\":{\"default\":true,\"description\":\"Ability to open a marker on click.\",\"type\":\"boolean\"},\"clicktofullscreen\":{\"default\":false,\"description\":\"Click on the map to unlock and go fullscreen.\",\"type\":\"boolean\"},\"clicktofullscreendevices\":{\"default\":\"mobile\",\"description\":\"Click on the map to unlock and go fullscreen. Only for specified devices.\",\"enum\":[\"all\",\"mobile\"],\"type\":\"string\"},\"clicktonavigate\":{\"default\":false,\"description\":\"Click on the map to navigate to coordinates\",\"type\":\"boolean\"},\"clientname\":{\"default\":\"\",\"description\":\"Add an additional css class wemap-livemap-<clientname> to the main livemap's container Value can also describe a sub-client: client:sub-client. Eg: allow mcc components customization\",\"type\":\"string\"},\"clustercircle\":{\"default\":false,\"description\":\"Displays a simple circle instead of a cluster icon.\",\"type\":\"boolean\"},\"clustercolor\":{\"default\":\"#015697\",\"description\":\"Clusters icons color (requires clustercircle).\",\"type\":\"string\"},\"clustericon\":{\"default\":null,\"description\":\"Cluster icon image (ignored if clustercircle is set).\",\"type\":\"string\"},\"clustering\":{\"default\":true,\"description\":\"Enables front-end side clustering of pinpoints.\",\"type\":\"boolean\"},\"clustermethod\":{\"default\":\"supercluster\",\"description\":\"Algorithm used to group pinpoints into clusters.\",\"enum\":[\"hierarchy\",\"supercluster\"],\"type\":\"string\"},\"clusterplussign\":{\"default\":false,\"description\":\"Replaces the cluster count by a plus sign (requires clustercircle).\",\"type\":\"boolean\"},\"clusterradius\":{\"default\":80,\"description\":\"Configure the radius of the clustering algorithm (and multipoint search area).\",\"type\":\"integer\"},\"custompetals\":{\"type\":\"array\",\"description\":\"List of custom petals that will replace the classic ones.\",\"items\":{\"type\":\"object\",\"description\":\"A custom petal.\",\"properties\":{\"position\":{\"type\":\"integer\",\"description\":\"The position of the custom petal (between 1 and 5).\"},\"iconurl\":{\"type\":\"string\",\"description\":\"The url of the petal icon.\"},\"text\":{\"type\":\"string\",\"description\":\"The text that will be displayed when the petal is hovered.\"},\"actionname\":{\"type\":\"string\",\"description\":\"The action realized when the petal is clicked. The available actions are described in the documentation.\"},\"actionparameters\":{\"type\":\"object\",\"default\":{}}}},\"default\":[]},\"customshareurl\":{\"default\":null,\"description\":\"Custom url for pinpoint sharing.\",\"type\":\"string\"},\"dateonly\":{\"default\":false,\"description\":\"Do not display event hours\",\"type\":\"boolean\"},\"deeplinkingenabled\":{\"description\":\"Enable the update of the url hash when navigate through the application\",\"type\":\"boolean\",\"default\":true},\"displaypoorevent\":{\"default\":true,\"description\":\"Display event as poor event if they don't have description\",\"type\":\"boolean\"},\"dragging\":{\"default\":true,\"description\":\"Enable map dragging with mouse/touch.\",\"type\":\"boolean\"},\"enabledcontrols\":{\"default\":true,\"description\":\"Enable map controls.\",\"type\":\"boolean\"},\"enableembedshare\":{\"default\":true,\"description\":\"Enable/Disable EMBED share on the livemap.\",\"type\":\"boolean\"},\"enablelogin\":{\"default\":true,\"description\":\"Are users allowed to login.\",\"type\":\"boolean\"},\"enablepetals\":{\"default\":true,\"description\":\"Enable/Disable petals components on the livemap.\",\"type\":\"boolean\"},\"enablesidebar\":{\"default\":true,\"description\":\"Enable/Disable sidebar on the livemap.\",\"type\":\"boolean\"},\"expanddescription\":{\"default\":false,\"description\":\"Shows a Read more button at the bottom of pinpoint description.\",\"type\":\"boolean\"},\"externalcontent\":{\"default\":false,\"description\":\"Add HTML content to main container, permits to user to customize its map.\",\"items\":{\"type\":\"string\"},\"type\":\"array\"},\"externalscripts\":{\"default\":false,\"description\":\"External JavaScript defined by user, added as script tags into livemap's document header\",\"items\":{\"properties\":{\"content\":{\"description\":\"JavaScript code.\",\"type\":\"string\"},\"url\":{\"description\":\"The URL from which to fetch the JavaScript code.\",\"type\":\"string\"}},\"type\":\"object\"},\"type\":\"array\"},\"externalstyles\":{\"default\":false,\"description\":\"External stylesheets defined by user, added as style tags into livemap's document header. Could be used to override existent css rule\",\"items\":{\"properties\":{\"content\":{\"description\":\"CSS code.\",\"type\":[\"object\",\"string\"]},\"url\":{\"description\":\"The URL from which to fetch the CSS code.\",\"type\":\"string\"}},\"type\":\"object\"},\"type\":\"array\"},\"featuredlists\":{\"default\":false,\"description\":\"Add a new button with the livemap's title, on click it will open the right sidebar containing all the lists for this map.\",\"type\":\"boolean\"},\"featuretilesenabled\":{\"default\":false,\"description\":\"Enables server-side clustering.\",\"type\":\"boolean\"},\"floors\":{\"default\":[],\"description\":\"Floors for multi-levels maps.\",\"items\":{\"properties\":{\"maxaltitude\":{\"description\":\"The maximum altitude for the floor (exclusive).\",\"title\":\"Maximum altitude\",\"type\":\"number\"},\"minaltitude\":{\"description\":\"The minimum altitude for the floor (inclusive).\",\"title\":\"Minimum altitude\",\"type\":\"number\"},\"name\":{\"title\":\"Name\",\"type\":\"string\"}},\"required\":[\"name\",\"minaltitude\",\"maxaltitude\"],\"type\":\"object\"},\"type\":\"array\"},\"floorsminzoom\":{\"default\":null,\"description\":\"Min zoom to display the floors switcher\",\"type\":\"number\"},\"forcelittlescreenview\":{\"default\":false,\"description\":\"Force to use the 'little screen' display mode if not in mobile view.\",\"type\":\"boolean\"},\"forcemobileview\":{\"default\":false,\"description\":\"Force to add class 'mobile-view' to livemap container and add a class forced-mobileview to livemap container it will also force livemap state.\",\"type\":\"boolean\"},\"fullscreencontrol\":{\"default\":false,\"description\":\"Show/Hide burger menu item 'Goto Fullscreen'.\",\"type\":\"boolean\"},\"geoentities\":{\"default\":{\"hideOthersOnSelect\":true,\"strokeHighlightScale\":1.5},\"properties\":{\"hideOthersOnSelect\":{\"default\":true,\"description\":\"Hide other geoentities when one is selected.\",\"type\":\"boolean\"},\"strokeHighlightScale\":{\"default\":1.5,\"description\":\"Scale factor of stroke width on highlight\",\"type\":\"number\"}},\"description\":\"Enable/Disable geoentities components on the livemap.\",\"type\":\"object\"},\"handlebearing\":{\"default\":false,\"description\":\"Allow map to rotate depending on the device orientation.\",\"type\":\"boolean\"},\"hereandnowcontrol\":{\"default\":false,\"description\":\"Replace geolocate button by a button 'here and now' which also filter on current day.\",\"type\":\"boolean\"},\"homecontrol\":{\"default\":true,\"description\":\"Show/Hide menu item 'Back to first view'.\",\"type\":\"boolean\"},\"howtocontrol\":{\"default\":false,\"description\":\"Show/Hide menu item 'How to use this map'.\",\"type\":\"boolean\"},\"indoor\":{\"default\":{\"enable\":false,\"usePinpoints\":false,\"useLevelSearch\":false,\"limitOutdoorAtLevel\":null,\"highlightEnabled\":true,\"highlightColor\":null,\"highlightOnSearch\":false,\"minZoom\":17,\"enableInteraction\":true},\"properties\":{\"enable\":{\"default\":false,\"description\":\"Enable indoor mode.\",\"type\":\"boolean\"},\"enableInteraction\":{\"default\":true,\"description\":\"Enable/disable interaction with indoor features (hover, click)\",\"type\":\"boolean\"},\"highlightColor\":{\"default\":null,\"description\":\"Color for highlight feature\",\"type\":\"string\"},\"selectedColor\":{\"default\":null,\"description\":\"Color for selected feature\",\"type\":\"string\"},\"highlightEnabled\":{\"default\":true,\"description\":\"Enable/disable highlight feature on click\",\"type\":\"boolean\"},\"highlightOnSearch\":{\"default\":false,\"description\":\"Enable/disable highlight feature on search\",\"type\":\"boolean\"},\"limitOutdoorAtLevel\":{\"default\":null,\"description\":\"Define which level should show outdoor pinpoint. If null all levels will show outdoor pinpoint.\",\"type\":\"number\"},\"minZoom\":{\"default\":17,\"description\":\"Define the zoom level at which indoor mode will be enabled\",\"type\":\"number\"},\"usePinpoints\":{\"default\":false,\"description\":\"If pinpoint are linked to indoor feature. It will automatically open pinpoint on feature click and highlight feature on pinpoint open.\",\"type\":\"boolean\"},\"useLevelSearch\":{\"default\":false,\"description\":\"If pinpoint search is made on the current level. If not, it will search on all levels.\",\"type\":\"boolean\"}},\"description\":\"Configuration relative to indoor\",\"type\":\"object\"},\"initialbearing\":{\"default\":0,\"description\":\"Initial bearing of the map.\",\"type\":\"number\"},\"introcard\":{\"default\":null,\"description\":\"Shows an information popin on map load.\",\"properties\":{\"active\":{\"default\":true,\"description\":\"If not true, the welcomeCard won't be displayed.\",\"title\":\"Active\",\"type\":\"boolean\"},\"avatar\":{\"description\":\"Custom user's avatar image.\",\"title\":\"Avatar URL\",\"type\":\"string\"},\"background\":{\"description\":\"URL background image shown behind the user's avatar, default is user's background image.\",\"title\":\"Background URL\",\"type\":\"string\"},\"class\":{\"description\":\"Custom classnames for the popin.\",\"title\":\"CSS classname\",\"type\":\"string\"},\"enableAroundMe\":{\"default\":false,\"description\":\"Display the 'around me' button on welcome card.\",\"title\":\"Display 'Around me' button\",\"type\":\"boolean\"},\"aroundMeTitle\":{\"title\":\"Title of the around me filter.\",\"description\":\"Title of the around me filter.\",\"type\":\"string\"},\"aroundMeSubtitle\":{\"title\":\"Subtitle of the around me filter.\",\"description\":\"Subtitle of the around me filter.\",\"type\":\"string\"},\"filters\":{\"description\":\"Enable filters on WelcomeCard.\",\"items\":{\"properties\":{\"type\":{\"description\":\"Type of filter.\",\"enum\":[\"tag\",\"when\",\"where\"],\"title\":\"Type of filter\",\"type\":\"string\"},\"title\":{\"description\":\"Title of the filter.\",\"title\":\"Title of the filter.\",\"type\":\"string\"},\"subtitle\":{\"description\":\"Subtitle of the filter.\",\"title\":\"Subtitle of the filter.\",\"type\":\"string\"}},\"type\":\"object\"},\"required\":[\"type\"],\"type\":\"array\"},\"noBackground\":{\"default\":false,\"description\":\"Hide the user's background image.\",\"title\":\"Hide Backround\",\"type\":\"boolean\"},\"permanent\":{\"default\":true,\"description\":\"Show WelcomeCard everytime.\",\"title\":\"Permanent WelcomeCard\",\"type\":\"boolean\"},\"text\":{\"description\":\"Displayed under the title as HTML.\",\"title\":\"HTML Text\",\"type\":\"string\"},\"title\":{\"description\":\"Displayed under the user's avatar with bold font.\",\"title\":\"Title\",\"type\":\"string\"}},\"type\":\"object\"},\"iscontributive\":{\"default\":false,\"description\":\"Tell if the map is contributive or not.\",\"type\":\"boolean\"},\"kiosk\":{\"default\":null,\"description\":\"Kiosk parameters like the photosphere image or position\",\"properties\":{\"list\":{\"type\":\"array\",\"default\":[],\"items\":{\"type\":\"object\",\"default\":null,\"properties\":{\"photosphere\":{\"type\":\"object\",\"default\":null,\"properties\":{\"day\":{\"type\":\"string\"},\"night\":{\"type\":\"string\"}}},\"kioskid\":{\"type\":\"string\",\"default\":\"\"},\"accessibleheight\":{\"type\":\"string\",\"description\":\"Kiosk mode has a max height for interactive button for accessibility purpose\",\"default\":50},\"heading\":{\"description\":\"Heading is used to orient the photosphere according to the map (in degrees)\",\"type\":\"number\",\"default\":0},\"initialorientation\":{\"description\":\"Initial orientation of the view (in degrees)\",\"type\":\"number\",\"default\":0},\"position\":{\"properties\":{\"lat\":{\"description\":\"Latitude of position for photosphere.\",\"title\":\"Latitude\",\"type\":\"number\"},\"lng\":{\"description\":\"Longitude of position for photosphere.\",\"title\":\"Longitude\",\"type\":\"number\"},\"alt\":{\"description\":\"Altitude of position for photosphere.\",\"title\":\"Altitude\",\"type\":\"number\"},\"level\":{\"description\":\"Level of position for photosphere.\",\"title\":\"Level\",\"type\":\"number\"}},\"required\":[\"lat\",\"lng\"],\"type\":\"object\"},\"rotationduration\":{\"description\":\"Rotation of sphere. Number of seconds for a complete loop\",\"type\":\"number\",\"default\":35}}}},\"screensavertype\":{\"type\":\"string\",\"enum\":[\"auto\",null],\"default\":\"auto\"},\"timeoutscreensaver\":{\"type\":\"number\",\"default\":30000},\"type\":{\"type\":\"string\",\"default\":\"default\",\"enum\":[\"default\",\"desktop\"]},\"intro\":{\"type\":\"object\",\"default\":null,\"properties\":{\"text\":{\"type\":\"string\"},\"title\":{\"type\":\"string\"}}}},\"type\":\"object\"},\"kioskid\":{\"default\":null,\"type\":\"string\"},\"kiosk_viewer\":{\"default\":null,\"description\":\"Id of kiosk viewer map\",\"type\":\"string\"},\"layers\":{\"default\":[],\"description\":\"Additional feature layers.\",\"items\":{\"properties\":{\"altitude\":{\"description\":\"The altitude (in meters) of this layer, for multi-floor maps.\",\"title\":\"Altitude\",\"type\":\"number\"},\"clustering\":{\"default\":false,\"description\":\"Use this layer for front-end hierarchy clustering.\",\"title\":\"Clustering\",\"type\":\"boolean\"},\"coordinates\":{\"default\":null,\"description\":\"Coordinates of each corner of the image. It can only be used with layer type image. Represented by an array of coordinates array [lng, lat]\",\"items\":{\"items\":{\"type\":\"number\"},\"type\":\"array\"},\"type\":\"array\"},\"maxzoom\":{\"default\":18,\"description\":\"The maximum zoom at which the layer is visible (exclusive).\",\"minimum\":0,\"title\":\"Maximum zoom\",\"type\":\"integer\"},\"minzoom\":{\"default\":2,\"description\":\"The minimum zoom at which the layer is visible (inclusive).\",\"minimum\":0,\"title\":\"Minimum zoom\",\"type\":\"integer\"},\"onclick\":{\"default\":\"zoom\",\"enum\":[\"ignore\",\"popup\",\"tooltip\",\"zoom\"],\"title\":\"Action on click\",\"type\":\"string\"},\"onhover\":{\"default\":\"highlight\",\"enum\":[\"ignore\",\"highlight\"],\"title\":\"Action on hover\",\"type\":\"string\"},\"type\":{\"description\":\"The type of layer format (GeoJSON, vector tiles or image).\",\"enum\":[\"geojson\",\"image\",\"vector\"],\"title\":\"Type\",\"type\":\"string\"},\"url\":{\"description\":\"The URL from which to fetch the layer's data.\",\"title\":\"URL\",\"type\":\"string\"}},\"required\":[\"type\",\"url\"],\"type\":\"object\"},\"type\":\"array\"},\"limitperpage\":{\"default\":10,\"description\":\"Number of items per page in the livebar.\",\"type\":\"integer\"},\"linksenabled\":{\"default\":true,\"description\":\"Enable clicking on links (in pinpoint description or comments).\",\"type\":\"boolean\"},\"littlescreenthresholdwidth\":{\"default\":1030,\"description\":\"Max width before going to littleScreen mode.\",\"type\":\"integer\"},\"locked\":{\"default\":false,\"description\":\"Lock map, need to click it to unlock and use (no hover).\",\"type\":\"boolean\"},\"mapviewenabled\":{\"default\":true,\"description\":\"If false, hide the map and keep only the UI.\",\"type\":\"boolean\"},\"markersize\":{\"default\":100,\"type\":\"integer\",\"description\":\"Size of the map markers.\"},\"maxbounds\":{\"default\":null,\"description\":\"Restricts the map view to the given bounds.\",\"properties\":{\"_northEast\":{\"properties\":{\"lat\":{\"description\":\"Latitude of upper-right's corner (northEast).\",\"title\":\"NorthEast latitude\",\"type\":\"number\"},\"lng\":{\"description\":\"Longitude of upper-right's corner (northEast).\",\"title\":\"NorthEast longitude\",\"type\":\"number\"}},\"required\":[\"lat\",\"lng\"],\"type\":\"object\"},\"_southWest\":{\"properties\":{\"lat\":{\"description\":\"Latitude of bottom-left's corner (southWest).\",\"title\":\"SouthWest latitude\",\"type\":\"number\"},\"lng\":{\"description\":\"Longitude of bottom-left's corner (southWest).\",\"title\":\"SouthWest longitude\",\"type\":\"number\"}},\"required\":[\"lat\",\"lng\"],\"type\":\"object\"}},\"required\":[\"_northEast\",\"_southWest\"],\"type\":\"object\"},\"maximagewidth\":{\"default\":500,\"description\":\"Sets the maximum image width in sidebar. (in px)\",\"type\":\"integer\"},\"maxzoom\":{\"default\":18,\"description\":\"Maximum zoom level of the map.\",\"maximum\":24,\"minimum\":0,\"type\":\"integer\"},\"maxzoomcluster\":{\"default\":null,\"description\":\"Maximum zoom for clustering. Default will be maxzoom\",\"maximum\":24,\"minimum\":0,\"type\":\"integer\"},\"menuextensions\":{\"default\":false,\"description\":\"Add options to the livemap menu.\",\"items\":{\"properties\":{\"icon\":{\"description\":\"Name of Font-Awesome Icon.\",\"title\":\"Icon\",\"type\":\"string\"},\"text\":{\"description\":\"Label for custom button.\",\"title\":\"Button's Label\",\"type\":\"string\"},\"url\":{\"description\":\"URL to redirect from.\",\"title\":\"URL\",\"type\":\"string\"}},\"type\":\"object\"},\"type\":\"array\"},\"minzoom\":{\"default\":2,\"description\":\"Minimum zoom level of the map.\",\"maximum\":24,\"minimum\":0,\"type\":\"integer\"},\"mobilethresholdwidth\":{\"default\":630,\"description\":\"When to consider the map as small/mobile. (main application container will be prefixed by 'mobile-view' class)\",\"type\":\"integer\"},\"mode\":{\"default\":\"default\",\"description\":\"Define the mode of the livemap if it should be with AR, for navigation or kiosk. This will change the UI and features\",\"enum\":[\"default\",\"kiosk_map\",\"kiosk_viewer\",\"kiosk_screensaver_map\"],\"type\":\"string\"},\"models\":{\"default\":null,\"description\":\"Define the URL of the 3d models to load in the map.\",\"type\":\"array\",\"items\":{\"type\":\"object\",\"properties\":{\"id\":{\"type\":\"string\"},\"visible\":{\"default\":\"always\",\"enum\":[\"always\",\"3d\"]},\"url\":{\"type\":\"string\"},\"minzoom\":{\"default\":0,\"type\":\"number\"},\"maxzoom\":{\"default\":24,\"type\":\"number\"}}}},\"navigatefromposition\":{\"default\":true,\"description\":\"If it should use user location for itineraries\",\"type\":\"boolean\"},\"offline\":{\"default\":{\"blacklist\":[],\"enable\":false,\"tiles\":null},\"description\":\"Configuration relative to the offline.\",\"properties\":{\"blacklist\":{\"default\":[],\"description\":\"Array of list to not use for offline\",\"type\":\"array\"},\"enable\":{\"default\":false,\"description\":\"Enable the offline feature\",\"type\":\"boolean\"},\"tiles\":{\"default\":null,\"description\":\"Mbtiles file to load for offline tiles\",\"type\":\"string\"}},\"type\":\"object\"},\"openedsearch\":{\"default\":false,\"description\":\"Open search bar at startup (if not opened at startup it can opened on click on search button).\",\"type\":\"boolean\"},\"openeventinpinpoint\":{\"default\":false,\"description\":\"Open event inside the pinpoint view instead of opening new view\",\"type\":\"boolean\"},\"imageoperation\":{\"default\":{\"thumbnail\":\"fit\",\"sidebar\":\"fit\"},\"description\":\"Operation applied to the image by the backend\",\"properties\":{\"thumbnail\":{\"default\":\"fit\",\"description\":\"operation applied for images used in map thumbnails\",\"type\":\"string\",\"enum\":[\"contain\",\"fit\"]},\"sidebar\":{\"default\":\"fit\",\"description\":\"operation applied for images used in sidebar\",\"type\":\"string\",\"enum\":[\"contain\",\"fit\"]}},\"type\":\"object\"},\"openedsidebar\":{\"description\":\"Open sidebar by default on featured list or sources ('featured' or 'sources').\",\"enum\":[\"\",\"featured\",\"sources\"],\"default\":\"\",\"type\":\"string\"},\"pinpointopentype\":{\"description\":\"Defined how the pinpoint should be opened, if it opens from the sidebar or with a popin\",\"default\":\"sidebar\",\"enum\":[\"sidebar\",\"popin\"],\"type\":\"string\"},\"pitchenabled\":{\"description\":\"Allow user to pitching and bearing map\",\"type\":\"boolean\",\"default\":false},\"pitchstart\":{\"description\":\"initial pitch (tilt) of the map, measured in degrees away from the plane of the screen (0-60)\",\"type\":\"integer\",\"default\":0},\"pitchswitcherbutton\":{\"description\":\"Show a button to switch pitch\",\"type\":\"boolean\",\"default\":false},\"providersenabled\":{\"description\":\"Use providers to locate the user\",\"type\":\"boolean\",\"default\":true},\"metarouterurl\":{\"default\":null,\"description\":\"The meta router url to use\",\"type\":\"string\"},\"routingtype\":{\"default\":\"google\",\"description\":\"The provider to use for routing.\",\"enum\":[\"google\",\"deutsche-bahn\",\"osrm\",\"otp\",\"cityway\",\"idfm\",\"navitia\",\"tictactrip\"],\"type\":\"string\"},\"routingurl\":{\"default\":\"https://routing-osrm.getwemap.com\",\"description\":\"The root URL for the OSRM routing server.\",\"type\":\"string\"},\"routingmode\":{\"default\":\"driving\",\"description\":\"Mode of routing.\",\"enum\":[\"driving\",\"walking\",\"bike\",\"bus\",\"multi\"],\"type\":\"string\"},\"samewindow\":{\"default\":false,\"description\":\"Open links (from pinpoints descriptions or comments) in the same page.\",\"type\":\"boolean\"},\"scaninstructions\":{\"default\":\"\",\"description\":\"Instruction message displayed when the scan view is open.\",\"type\":\"string\"},\"scrollwheelzoom\":{\"default\":true,\"description\":\"Enable zoom using the scrollwheel.\",\"type\":\"boolean\"},\"searchcontrol\":{\"default\":true,\"description\":\"Show/hide search button.\",\"type\":\"boolean\"},\"searchparameters\":{\"default\":{\"geocoding\":true,\"region\":null,\"multilevel\":false,\"boundingbox\":null,\"extended\":false,\"sortbyname\":null,\"query_fields\":null,\"sortbydistance\":null},\"description\":\"Configuration relative to the search engine\",\"properties\":{\"extended\":{\"default\":false,\"description\":\"Extend search will search on bigger bounds even if results not empty\",\"type\":\"boolean\"},\"geocoding\":{\"default\":true,\"description\":\"Enable geocoding for search\",\"type\":\"boolean\"},\"multilevel\":{\"default\":false,\"description\":\"Enable search on all level instead of current level\",\"type\":\"boolean\"},\"region\":{\"default\":null,\"description\":\"Specify the region (country) in which the geocoding search should be done\",\"type\":\"string\"},\"sortbyname\":{\"default\":null,\"description\":\"Specify the sorting results method\",\"type\":\"string\",\"enum\":[\"ASC\",\"DESC\"]},\"query_fields\":{\"default\":null,\"description\":\"Specify fields to search on\",\"type\":\"string\"},\"sortbydistance\":{\"default\":false,\"description\":\"Specify the sorting results by distance\",\"type\":\"boolean\"},\"boundingbox\":{\"default\":null,\"description\":\"Limit results to only those contained within the supplied bounding box.\",\"properties\":{\"_northEast\":{\"properties\":{\"lat\":{\"description\":\"Latitude of upper-right's corner (northEast).\",\"title\":\"NorthEast latitude\",\"type\":\"number\"},\"lng\":{\"description\":\"Longitude of upper-right's corner (northEast).\",\"title\":\"NorthEast longitude\",\"type\":\"number\"}},\"required\":[\"lat\",\"lng\"],\"type\":\"object\"},\"_southWest\":{\"properties\":{\"lat\":{\"description\":\"Latitude of bottom-left's corner (southWest).\",\"title\":\"SouthWest latitude\",\"type\":\"number\"},\"lng\":{\"description\":\"Longitude of bottom-left's corner (southWest).\",\"title\":\"SouthWest longitude\",\"type\":\"number\"}},\"required\":[\"lat\",\"lng\"],\"type\":\"object\"}},\"required\":[\"_northEast\",\"_southWest\"],\"type\":\"object\"}},\"type\":\"object\"},\"searchplaceholder\":{\"default\":null,\"description\":\"Override search input placeholder.\",\"type\":\"object\"},\"searchclustertiles\":{\"default\":false,\"description\":\"If the search request should return clusters\",\"type\":\"boolean\"},\"seo\":{\"default\":null,\"description\":\"Configuration relative to the SEO.\",\"properties\":{\"bindPageTitleToOpenedEntity\":{\"default\":true,\"description\":\"Replace the page title by the name of the opened entity.\",\"type\":\"boolean\"},\"pageTitleBindingPrefix\":{\"default\":\"\",\"description\":\"When the page title is binded to the content, you can configure the base of the title with this parameter. The final page title will be the concatenation of this parameter and the opened entity name.\",\"type\":\"string\"},\"baseUrl\":{\"default\":\"\",\"description\":\"Base url for the SEO.\",\"type\":\"string\"},\"bindPageDescriptionToOpenedEntity\":{\"default\":true,\"description\":\"Replace the page description by the description of the opened entity.\",\"type\":\"boolean\"},\"bindSchemaToOpenedEntity\":{\"default\":true,\"description\":\"Generate the schema.org structure based on the opened content.\",\"type\":\"boolean\"}},\"type\":\"object\"},\"services\":{\"default\":{\"g7\":false,\"uber\":false,\"velib\":false},\"description\":\"Configuration relative to the external services.\",\"properties\":{\"g7\":{\"default\":false,\"description\":\"Use G7 services\",\"type\":\"boolean\"},\"uber\":{\"default\":false,\"description\":\"Use Uber services\",\"type\":\"boolean\"},\"velib\":{\"default\":false,\"description\":\"Use velib services\",\"type\":\"boolean\"}},\"type\":\"object\"},\"sharesnippet\":{\"default\":false,\"description\":\"Enables the sharing of livemaps (shows a button).\",\"type\":\"boolean\"},\"showaddress\":{\"default\":true,\"description\":\"Show pinpoint's address.\",\"type\":\"boolean\"},\"showauthor\":{\"default\":true,\"description\":\"Show pinpoint's author.\",\"type\":\"boolean\"},\"showfinishedeventscontrol\":{\"default\":true,\"description\":\"Display a checkbox to hide/show the finished events.\",\"type\":\"boolean\"},\"showmediainresults\":{\"default\":false,\"description\":\"Show/hide media in result list\",\"type\":\"boolean\"},\"showmultilevel\":{\"default\":{\"position\":false,\"itinerary\":false},\"description\":\"Show/hide element depending on current floor for a multilevel map\",\"properties\":{\"position\":{\"type\":\"boolean\",\"default\":false},\"itinerary\":{\"type\":\"boolean\",\"default\":false}},\"type\":\"object\"},\"showpinpointmedia\":{\"default\":true,\"description\":\"Show/hide media (picture or video) in pinpoint detailed description\",\"type\":\"boolean\"},\"showrelatedlists\":{\"default\":true,\"description\":\"Show the lists pinpoints belong to.\",\"type\":\"boolean\"},\"showrelativedate\":{\"default\":true,\"description\":\"Show pinpoint's relative creation date.\",\"type\":\"boolean\"},\"sidebarsforceopen\":{\"default\":[\"navigation\",\"direction\"],\"description\":\"Force sidebar to be opened even if parameter enablesidebar is set to false\",\"type\":\"array\",\"items\":{\"type\":\"string\",\"enum\":[\"pinpoint\",\"event\",\"lists\",\"multipoint\",\"sources\",\"navigation\"]}},\"stillswitch\":{\"default\":false,\"description\":\"Should the map stay still (in location) when switching emm ?\",\"type\":\"boolean\"},\"switcher\":{\"default\":null,\"description\":\"Switch between livemaps via theirs emmid.\",\"properties\":{\"direction\":{\"type\":\"string\"},\"items\":{\"items\":{\"properties\":{\"action\":{\"properties\":{\"type\":{\"emmid\":\"string\"}},\"type\":\"object\"},\"icon\":{\"properties\":{\"content\":{\"type\":\"string\"},\"place\":{\"type\":\"string\"},\"style\":{\"type\":\"object\"},\"type\":{\"type\":\"string\"}},\"type\":\"object\"},\"text\":{\"type\":\"string\"}},\"type\":\"object\"},\"type\":\"array\"},\"itemsStyle\":{\"type\":\"object\"},\"itemsStyleActive\":{\"type\":\"object\"},\"itemsStyleHover\":{\"type\":\"object\"},\"style\":{\"type\":\"object\"}},\"type\":\"object\"},\"tagsoverlap\":{\"default\":false,\"description\":\"Enable/disable OR/AND logic for tags filtering\",\"type\":\"boolean\"},\"tilesstyle\":{\"default\":\"https://tiles.getwemap.com/styles/wemap-v2-en/style.json\",\"description\":\"URL for the vector tiles style.\",\"type\":\"string\"},\"tilestoken\":{\"default\":null,\"description\":\"Token for the vector tiles style. (ex : using Mapbox Terrain, or Mapbox Satellite)\",\"type\":\"string\"},\"timecircle\":{\"default\":null,\"description\":\"Circle of distance to go in given time\",\"properties\":{\"type\":{\"type\":\"string\",\"default\":\"walk\"},\"time\":{\"type\":\"integer\",\"default\":300}},\"type\":\"object\"},\"uber\":{\"default\":false,\"description\":\"Add Uber to pinpoint petals.\",\"type\":\"boolean\"},\"useevents\":{\"default\":false,\"description\":\"Current map should use entities events or not.\",\"type\":\"boolean\"},\"usertour\":{\"type\":\"object\",\"default\":null,\"description\":\"Display a user tour at first start if enabled.\",\"properties\":{\"active\":{\"type\":\"boolean\",\"default\":true,\"description\":\"Enable or disable the user tour.\"},\"steps\":{\"type\":\"array\",\"default\":[],\"description\":\"Steps of the user tour.\",\"items\":{\"type\":\"object\",\"properties\":{\"type\":{\"type\":\"string\",\"description\":\"Type of the step\",\"enum\":[\"filterButton\",\"menuButton\",\"livebarButton\",\"pinpointPetals\",\"shareViewButton\",\"custom\"]},\"body\":{\"type\":\"string\",\"description\":\"Text of the step\"},\"selector\":{\"type\":\"string\",\"description\":\"Selector to get the element to point with this step.\"},\"routename\":{\"type\":\"string\",\"description\":\"Name of the route to navigate before displaying the step tooltip.\"},\"routeparams\":{\"type\":\"object\",\"description\":\"Parameters of the route to navigate before displaying the step tooltip.\",\"default\":{}},\"routequery\":{\"type\":\"object\",\"description\":\"Query of the route to navigate before displaying the step tooltip.\",\"default\":{}},\"maskstyle\":{\"type\":\"object\",\"description\":\"Inline CSS style to apply to the user tour mask when displaying this step.\"},\"visibility\":{\"type\":\"array\",\"items\":{\"type\":\"string\",\"enum\":[\"mobile\",\"desktop\",\"littlescreen\"]},\"default\":[\"mobile\",\"desktop\",\"littlescreen\"]}},\"required\":[\"type\"]}}}},\"tagrules\":{\"default\":[],\"description\":\"Rules to apply for tags\",\"items\":{\"type\":\"object\",\"properties\":{\"type\":{\"description\":\"Type of rule\",\"enum\":[\"search\",\"size\",\"featured-direction\"],\"type\":\"string\"},\"tags\":{\"description\":\"List of tags to apply the rule\",\"type\":\"array\",\"items\":{\"type\":\"string\"}},\"filteringLogic\":{\"description\":\"Logic to apply when filtering tags (OR or AND)\",\"type\":\"string\",\"enum\":[\"OR\",\"AND\"],\"default\":\"AND\"},\"minzoom\":{\"default\":null,\"description\":\"Min zoom to apply the rule\",\"type\":\"number\"},\"scale\":{\"default\":null,\"description\":\"Scale of pinpoint marker, use it with type 'size'\",\"type\":\"number\"},\"maxzoom\":{\"default\":null,\"description\":\"Max zoom to apply the rule\",\"type\":\"number\"}}},\"type\":\"array\"},\"usetags\":{\"anyOf\":[{\"type\":\"boolean\"},{\"properties\":{\"active\":{\"type\":\"boolean\"},\"filteringLogic\":{\"type\":\"string\",\"default\":\"DEFAULT\",\"enum\":[\"AND\",\"OR\",\"DEFAULT\"]},\"categories\":{\"items\":{\"properties\":{\"name\":{\"type\":\"string\"},\"slug\":{\"type\":\"string\"}},\"required\":[\"name\",\"slug\"],\"type\":\"object\"},\"type\":\"array\"},\"clickable\":{\"type\":\"boolean\"},\"tags\":{\"items\":{\"properties\":{\"category\":{\"type\":[\"boolean\",\"string\"]},\"name\":{\"type\":\"string\"},\"slug\":{\"type\":\"string\"},\"visibility\":{\"type\":\"string\"}},\"required\":[\"name\",\"slug\"],\"type\":\"object\"},\"type\":\"array\"}},\"type\":\"object\"}],\"description\":\"Show tags button in search bar, enable search by tags.\",\"type\":\"object\",\"default\":false},\"webgl\":{\"default\":true,\"description\":\"Force WEBGL livemap's rendering.\",\"type\":\"boolean\"},\"webworkerclustering\":{\"default\":false,\"description\":\"Process superclustering in a webworker\",\"type\":\"boolean\"},\"welcomebuttonlabel\":{\"default\":\"OK !\",\"description\":\"Welcome card button label.\",\"type\":\"string\"},\"zoomcontrol\":{\"default\":true,\"description\":\"Enable zoom control.\",\"type\":\"boolean\"}}"),
138
177
  type: "object"
139
178
  };
140
- const isString = (e) => typeof e == "string", isNumber = (e) => typeof e == "number", isDefinedStrict = (e) => e != null, isObjectType = (e) => typeof e == "object" && !!e, defaultBounds = new BoundingBox(new Coordinates(85, 170), new Coordinates(-85, -170)), correctBounds = (g) => {
141
- let _ = g.getSouthWest(), v = g.getNorthEast(), y = _.lat, b = _.lng, x = v.lat, S = v.lng;
142
- b > S && (b = -(180 - b + 180));
143
- let C = new Coordinates(0, 0);
144
- C.autoWrap = !1, C.lat = x, C.lng = S;
145
- let w = new Coordinates(0, 0);
146
- return w.autoWrap = !1, w.lat = y, w.lng = b, new BoundingBox(C, w);
147
- }, deltaToBounds = (g) => {
148
- if (!g) return defaultBounds;
149
- let _ = new Coordinates(Number(g.latitude) - Number(g.latitude_delta), Number(g.longitude) - Number(g.longitude_delta));
150
- return correctBounds(new BoundingBox(new Coordinates(Number(g.latitude) + Number(g.latitude_delta), Number(g.longitude) + Number(g.longitude_delta)), _));
179
+ const isString = (e) => typeof e == "string", isNumber = (e) => typeof e == "number", isDefinedStrict = (e) => e != null, isObjectType = (e) => typeof e == "object" && !!e, defaultBounds = new BoundingBox(new Coordinates(85, 170), new Coordinates(-85, -170)), correctBounds = (v) => {
180
+ let y = v.getSouthWest(), b = v.getNorthEast(), x = y.lat, S = y.lng, C = b.lat, w = b.lng;
181
+ S > w && (S = -(180 - S + 180));
182
+ let T = new Coordinates(0, 0);
183
+ T.autoWrap = !1, T.lat = C, T.lng = w;
184
+ let E = new Coordinates(0, 0);
185
+ return E.autoWrap = !1, E.lat = x, E.lng = S, new BoundingBox(T, E);
186
+ }, deltaToBounds = (v) => {
187
+ if (!v) return defaultBounds;
188
+ let y = new Coordinates(Number(v.latitude) - Number(v.latitude_delta), Number(v.longitude) - Number(v.longitude_delta));
189
+ return correctBounds(new BoundingBox(new Coordinates(Number(v.latitude) + Number(v.latitude_delta), Number(v.longitude) + Number(v.longitude_delta)), y));
151
190
  }, latLngLikeToCoordinates = (e) => {
152
191
  if (e instanceof Coordinates) return e;
153
192
  if (Array.isArray(e)) {
154
- let [g, _, v] = e;
155
- return new Coordinates(g, _, null, v);
193
+ let [v, y, b] = e;
194
+ return new Coordinates(v, y, null, b);
156
195
  }
157
- let g = "lat" in e ? e.lat : e.latitude, _ = "lng" in e ? e.lng : e.longitude, v = "level" in e ? e.level : null, y = "alt" in e ? e.alt : null;
158
- if ("altitude" in e && (y = e.altitude), !isNumber(g) || !isNumber(_)) throw Error("Cannot parse lat/lng in" + JSON.stringify(e));
159
- return new Coordinates(g, _, isNumber(y) ? y : null, isNumber(v) ? v : null);
196
+ let v = "lat" in e ? e.lat : e.latitude, y = "lng" in e ? e.lng : e.longitude, b = "level" in e ? e.level : null, x = "alt" in e ? e.alt : null;
197
+ if ("altitude" in e && (x = e.altitude), !isNumber(v) || !isNumber(y)) throw Error("Cannot parse lat/lng in" + JSON.stringify(e));
198
+ return new Coordinates(v, y, isNumber(x) ? x : null, isNumber(b) ? b : null);
160
199
  };
161
- var getArray = function(e, h) {
162
- let g = e;
163
- return isString(g) && (g = parseJSONSafely(g)), Array.isArray(g) ? g : h;
164
- }, getBoolean = function(e, h) {
165
- return isDefinedStrict(e) ? isString(e) && e.toLowerCase() === "true" : h;
166
- }, getInteger = function(e, h) {
167
- let g = Number(e);
168
- return isNaN(g) ? h : g;
169
- }, getFloat = function(e, h) {
170
- let g = Number(e);
171
- return isNaN(g) ? h : g;
200
+ var getArray = function(e, _) {
201
+ let v = e;
202
+ return isString(v) && (v = parseJSONSafely(v)), Array.isArray(v) ? v : _;
203
+ }, getBoolean = function(e, _) {
204
+ return isDefinedStrict(e) ? isString(e) ? (e = e.toLowerCase(), e === "true") : typeof e == "boolean" ? e : _ : _;
205
+ }, getInteger = function(e, _) {
206
+ let v = Number(e);
207
+ return isNaN(v) ? _ : v;
208
+ }, getFloat = function(e, _) {
209
+ let v = Number(e);
210
+ return isNaN(v) ? _ : v;
172
211
  }, getObject = function(e) {
173
- let h = livemap_snippet_default.properties[e], g = SnippetParser.snippet[e];
174
- return isDefinedStrict(g) ? (isString(g) && (g = parseJSONSafely(g)), isObjectType(g) || (g = {}), g = SnippetParser.fillEmptyByDefault(g, "properties" in h ? h.properties : {}), g) : h.default;
212
+ let _ = livemap_snippet_default.properties[e], v = SnippetParser.snippet[e];
213
+ return isDefinedStrict(v) ? (isString(v) && (v = parseJSONSafely(v)), isObjectType(v) || (v = {}), v = SnippetParser.fillEmptyByDefault(v, "properties" in _ ? _.properties : {}), v) : _.default;
175
214
  };
176
- function getMaxBounds(h, g) {
177
- let _ = parseJSONSafely(h);
178
- return _ ? new BoundingBox(latLngLikeToCoordinates(_._northEast), latLngLikeToCoordinates(_._southWest)) : g;
215
+ function getMaxBounds(_, v) {
216
+ let y = parseJSONSafely(_);
217
+ return y ? new BoundingBox(latLngLikeToCoordinates(y._northEast), latLngLikeToCoordinates(y._southWest)) : v;
179
218
  }
180
219
  var parseJSONSafely = function(e) {
181
220
  if (!isString(e) || e === null) return e;
@@ -188,31 +227,32 @@ var parseJSONSafely = function(e) {
188
227
  } catch {
189
228
  return null;
190
229
  }
191
- }, getString = function(e, h) {
192
- return e == null || typeof e != "string" ? h : e;
230
+ }, getString = function(e, _) {
231
+ return e == null || typeof e != "string" ? _ : e;
193
232
  }, SnippetParser = class e {
194
233
  static snippet = {};
195
234
  static mapObject;
196
- static getProperty(h) {
197
- let g = livemap_snippet_default.properties[h];
198
- return g.type === "array" ? getArray(e.snippet[h], g.default) : g.type === "boolean" ? getBoolean(e.snippet[h], g.default) : g.type === "integer" ? getInteger(e.snippet[h], g.default) : g.type === "number" ? getFloat(e.snippet[h], g.default) : g.type === "string" ? getString(e.snippet[h], g.default) : g.type === "object" ? getObject(h) : null;
199
- }
200
- static fillEmptyByDefault(h, g) {
201
- let _ = { ...h };
202
- return g && Object.keys(g).forEach((h) => {
203
- let v = g[h];
204
- _.hasOwnProperty(h) ? v.type === "object" ? _[h] = e.fillEmptyByDefault(_[h], v.properties) : v.type === "array" && v.hasOwnProperty("items") && v.items.hasOwnProperty("properties") && (_[h] = _[h].map((h) => e.fillEmptyByDefault(h, v.items.properties))) : v.hasOwnProperty("default") ? _[h] = v.default : v.type === "object" && (_[h] = e.fillEmptyByDefault(_[h], v.properties));
205
- }), _;
235
+ static getProperty(_) {
236
+ let v = livemap_snippet_default.properties[_];
237
+ return v.type === "array" ? getArray(e.snippet[_], v.default) : v.type === "boolean" ? getBoolean(e.snippet[_], v.default) : v.type === "integer" ? getInteger(e.snippet[_], v.default) : v.type === "number" ? getFloat(e.snippet[_], v.default) : v.type === "string" ? getString(e.snippet[_], v.default) : v.type === "object" ? getObject(_) : null;
238
+ }
239
+ static fillEmptyByDefault(_, v) {
240
+ let y = { ..._ };
241
+ return v && Object.keys(v).forEach((_) => {
242
+ let b = v[_];
243
+ y.hasOwnProperty(_) ? b.type === "object" ? y[_] = e.fillEmptyByDefault(y[_], b.properties) : b.type === "array" && b.hasOwnProperty("items") && b.items.hasOwnProperty("properties") && (y[_] = y[_].map((_) => e.fillEmptyByDefault(_, b.items.properties))) : b.hasOwnProperty("default") ? y[_] = b.default : b.type === "object" && (y[_] = e.fillEmptyByDefault(y[_], b.properties));
244
+ }), y;
206
245
  }
207
- static parse(h) {
208
- return e.mapObject = h, e.snippet = h.snippet, {
246
+ static parse(_) {
247
+ return e.mapObject = _, e.snippet = _.snippet, {
209
248
  arNavigationData: e.getProperty("arnavigationdata"),
210
249
  aroundme: !!e.getProperty("aroundme"),
211
250
  deepLinkingEnabled: e.getProperty("deeplinkingenabled"),
212
251
  dragging: e.getProperty("dragging"),
213
252
  emmid: Number(e.mapObject.id),
214
253
  handleBearing: e.getProperty("handlebearing"),
215
- initialBounds: deltaToBounds(h),
254
+ indoor: e.getProperty("indoor"),
255
+ initialBounds: deltaToBounds(_),
216
256
  initialBearing: e.getProperty("initialbearing"),
217
257
  limit: Number(e.mapObject.count),
218
258
  locked: e.getProperty("locked"),
@@ -238,12 +278,12 @@ var parseJSONSafely = function(e) {
238
278
  getBaseUrl() {
239
279
  return this.env === "production" ? "https://api.getwemap.com/v3.0" : "https://apidev.maaap.it/v3.0";
240
280
  }
241
- async init(h) {
242
- if (!h.emmid || !h.token) throw Error("emmid and token are required");
243
- this.env = h.env || "production", this.livemapService = new LivemapService(this.getBaseUrl());
281
+ async init(_) {
282
+ if (!_.emmid || !_.token) throw Error("emmid and token are required");
283
+ this.env = _.env || "production", this.livemapService = new LivemapService(this.getBaseUrl());
244
284
  try {
245
- let g = await this.livemapService.fetchLivemap(h.emmid);
246
- e.snippet = SnippetParser.parse(g);
285
+ let v = await this.livemapService.fetchLivemap(_.emmid);
286
+ e.snippet = SnippetParser.parse(v);
247
287
  } catch (e) {
248
288
  throw console.error("Failed to initialize Core SDK:", e), e;
249
289
  }
@@ -251,6 +291,34 @@ var parseJSONSafely = function(e) {
251
291
  static getConfig() {
252
292
  return e.snippet || {};
253
293
  }
294
+ static getIndoorOptions() {
295
+ let _ = e.getConfig().indoor;
296
+ return {
297
+ enabled: _?.enable ?? !1,
298
+ minZoom: _?.minZoom ?? 17
299
+ };
300
+ }
301
+ static getMapOptions() {
302
+ let _ = e.getConfig();
303
+ return {
304
+ style: _.tilesStyle,
305
+ bounds: _.initialBounds,
306
+ maxBounds: _.maxBounds,
307
+ minZoom: _.minZoom,
308
+ maxZoom: _.maxZoom,
309
+ bearing: _.initialBearing,
310
+ pitch: _.pitchStart,
311
+ dragPan: _.dragging,
312
+ dragRotate: _.pitchEnabled,
313
+ pitchWithRotate: _.pitchEnabled,
314
+ scrollZoom: _.scrollWheelZoom,
315
+ interactive: !_.locked
316
+ };
317
+ }
318
+ createBuildingProvider() {
319
+ let _ = new BuildingService(this.getBaseUrl(), e.getConfig().emmid);
320
+ return (e) => _.getBuildingsFromBbox(e);
321
+ }
254
322
  };
255
323
  const core = new CoreConfig();
256
- export { CoreConfig, HttpClient, HttpError, LivemapService, core, latLngLikeToCoordinates };
324
+ export { BuildingService, CoreConfig, HttpClient, HttpError, LivemapService, core, latLngLikeToCoordinates };
@@ -1,4 +1,6 @@
1
+ import { BoundingBox } from '../../geo';
1
2
  import { SnippetParser } from './helpers/SnippetParser';
3
+ import { Building } from './types/indoor';
2
4
  /**
3
5
  * Initialization options for the Core SDK
4
6
  */
@@ -11,6 +13,16 @@ export interface InitOptions {
11
13
  env?: 'production' | 'development';
12
14
  }
13
15
  type Snippet = ReturnType<typeof SnippetParser.parse>;
16
+ /** Indoor settings from the livemap snippet (`indoor.enable`, `indoor.minZoom`). */
17
+ export interface IndoorOptions {
18
+ /** Whether indoor building selection is active (`indoor.enable`). */
19
+ enabled: boolean;
20
+ /**
21
+ * Zoom threshold from `indoor.minZoom`. Below this level there is no current
22
+ * building.
23
+ */
24
+ minZoom: number;
25
+ }
14
26
  /**
15
27
  * Core configuration class for initializing the Wemap SDK
16
28
  *
@@ -82,6 +94,55 @@ export declare class CoreConfig {
82
94
  * ```
83
95
  */
84
96
  static getConfig(): Snippet;
97
+ /**
98
+ * Map-related parameters derived from the livemap snippet, shaped for direct
99
+ * use when creating a map (e.g. `@wemap/map`'s `WemapMap`).
100
+ *
101
+ * Translates livemap semantics into renderer options:
102
+ * - `tilesStyle` → `style`
103
+ * - `initialBounds` → `bounds` (initial view; takes precedence over center/zoom)
104
+ * - `maxBounds`, `minZoom`, `maxZoom` → same
105
+ * - `initialBearing` → `bearing`, `pitchStart` → `pitch`
106
+ * - `dragging` → `dragPan`, `pitchEnabled` → `dragRotate` / `pitchWithRotate`
107
+ * - `scrollWheelZoom` → `scrollZoom`, `locked` → `interactive` (negated)
108
+ *
109
+ * Applied automatically by `@wemap/map`'s `WemapMap` after `core.init()`;
110
+ * constructor options override these defaults.
111
+ *
112
+ * @returns The map parameters from the parsed snippet.
113
+ */
114
+ static getIndoorOptions(): IndoorOptions;
115
+ static getMapOptions(): {
116
+ style: any;
117
+ bounds: BoundingBox;
118
+ maxBounds: BoundingBox;
119
+ minZoom: any;
120
+ maxZoom: any;
121
+ bearing: any;
122
+ pitch: any;
123
+ dragPan: any;
124
+ dragRotate: any;
125
+ pitchWithRotate: any;
126
+ scrollZoom: any;
127
+ interactive: boolean;
128
+ };
129
+ /**
130
+ * Build a building provider for the initialized livemap: a function that
131
+ * returns the buildings whose bbox intersects a given viewport.
132
+ *
133
+ * This is the concrete data source `@wemap/map` uses for building selection
134
+ * when `indoor.enable` is set in the livemap snippet. Integrators normally
135
+ * don't call it directly.
136
+ *
137
+ * ```typescript
138
+ * await core.init({ emmid, token });
139
+ * const provider = core.createBuildingProvider();
140
+ * const buildings = await provider(map.getBounds());
141
+ * ```
142
+ *
143
+ * @returns A `(bbox) => Promise<Building[]>` bound to this livemap.
144
+ */
145
+ createBuildingProvider(): (bbox: BoundingBox) => Promise<Building[]>;
85
146
  }
86
147
  /**
87
148
  * Default instance of CoreConfig for convenience
@@ -1 +1 @@
1
- {"version":3,"file":"CoreConfig.d.ts","sourceRoot":"","sources":["../../src/CoreConfig.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AAExD;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,6BAA6B;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,2BAA2B;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,oDAAoD;IACpD,GAAG,CAAC,EAAE,YAAY,GAAG,aAAa,CAAC;CACpC;AAED,KAAK,OAAO,GAAG,UAAU,CAAC,OAAO,aAAa,CAAC,KAAK,CAAC,CAAC;AAEtD;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,qBAAa,UAAU;IACrB,OAAO,CAAC,MAAM,CAAC,OAAO,CAAU;IAChC,OAAO,CAAC,cAAc,CAA+B;IACrD,OAAO,CAAC,GAAG,CAA8C;IAGzD;;;;OAIG;;IAKH,OAAO,CAAC,UAAU;IAIlB;;;;;;;;;;;;;;;;;;;;OAoBG;IACG,IAAI,CAAC,WAAW,EAAE,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC;IAoBnD;;;;;;;;;;;;;;;OAeG;IACH,MAAM,CAAC,SAAS,IAAI,OAAO;CAG5B;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,IAAI,YAAmB,CAAC"}
1
+ {"version":3,"file":"CoreConfig.d.ts","sourceRoot":"","sources":["../../src/CoreConfig.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAG9C,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAC;AAE/C;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,6BAA6B;IAC7B,KAAK,EAAE,MAAM,CAAC;IACd,2BAA2B;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,oDAAoD;IACpD,GAAG,CAAC,EAAE,YAAY,GAAG,aAAa,CAAC;CACpC;AAED,KAAK,OAAO,GAAG,UAAU,CAAC,OAAO,aAAa,CAAC,KAAK,CAAC,CAAC;AAEtD,oFAAoF;AACpF,MAAM,WAAW,aAAa;IAC5B,qEAAqE;IACrE,OAAO,EAAE,OAAO,CAAC;IACjB;;;OAGG;IACH,OAAO,EAAE,MAAM,CAAC;CACjB;AAED;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,qBAAa,UAAU;IACrB,OAAO,CAAC,MAAM,CAAC,OAAO,CAAU;IAChC,OAAO,CAAC,cAAc,CAA+B;IACrD,OAAO,CAAC,GAAG,CAA8C;IAGzD;;;;OAIG;;IAKH,OAAO,CAAC,UAAU;IAIlB;;;;;;;;;;;;;;;;;;;;OAoBG;IACG,IAAI,CAAC,WAAW,EAAE,WAAW,GAAG,OAAO,CAAC,IAAI,CAAC;IAoBnD;;;;;;;;;;;;;;;OAeG;IACH,MAAM,CAAC,SAAS,IAAI,OAAO;IAI3B;;;;;;;;;;;;;;;;OAgBG;IACH,MAAM,CAAC,gBAAgB,IAAI,aAAa;IAUxC,MAAM,CAAC,aAAa;;;;;;;;;;;;;;IAmBpB;;;;;;;;;;;;;;;OAeG;IACH,sBAAsB,IAAI,CAAC,IAAI,EAAE,WAAW,KAAK,OAAO,CAAC,QAAQ,EAAE,CAAC;CAKrE;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,IAAI,YAAmB,CAAC"}
@@ -158,6 +158,18 @@ export declare class SnippetParser {
158
158
  readonly dragging: any;
159
159
  readonly emmid: number;
160
160
  readonly handleBearing: any;
161
+ readonly indoor: {
162
+ enable: any;
163
+ enableInteraction: any;
164
+ highlightColor: any;
165
+ selectedColor: any;
166
+ highlightEnabled: any;
167
+ highlightOnSearch: any;
168
+ limitOutdoorAtLevel: any;
169
+ minZoom: any;
170
+ usePinpoints: any;
171
+ useLevelSearch: any;
172
+ };
161
173
  readonly initialBounds: BoundingBox;
162
174
  readonly initialBearing: any;
163
175
  readonly limit: number;
@@ -1 +1 @@
1
- {"version":3,"file":"SnippetParser.d.ts","sourceRoot":"","sources":["../../../src/helpers/SnippetParser.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEjF,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAiGzC,qBAAa,aAAa;IACxB,MAAM,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAM;IACzC,MAAM,CAAC,SAAS,EAAE,aAAa,CAAC;IAEhC,MAAM,CAAC,WAAW,CAAC,CAAC,SAAS,SAAS,EAAE,IAAI,EAAE,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC;IAqBnE,MAAM,CAAC,kBAAkB,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;;;IAuBvF,MAAM,CAAC,KAAK,CAAC,SAAS,EAAE,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAyCtC"}
1
+ {"version":3,"file":"SnippetParser.d.ts","sourceRoot":"","sources":["../../../src/helpers/SnippetParser.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAEjF,OAAO,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AA4GzC,qBAAa,aAAa;IACxB,MAAM,CAAC,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAM;IACzC,MAAM,CAAC,SAAS,EAAE,aAAa,CAAC;IAEhC,MAAM,CAAC,WAAW,CAAC,CAAC,SAAS,SAAS,EAAE,IAAI,EAAE,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC;IAqBnE,MAAM,CAAC,kBAAkB,CAAC,MAAM,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,UAAU,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC;;;IAuBvF,MAAM,CAAC,KAAK,CAAC,SAAS,EAAE,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0CtC"}
@@ -0,0 +1,33 @@
1
+ import { BoundingBox } from '../../../geo';
2
+ import { Building } from '../types/indoor';
3
+ /**
4
+ * Fetches buildings of a livemap from the Wemap API, with bbox-based caching.
5
+ *
6
+ * Ported from livemap's `IndoorService`: the first lookup downloads every
7
+ * building of the livemap (paginated) and caches them against an expanded bbox;
8
+ * subsequent lookups whose viewport is still inside the cached bbox are served
9
+ * from memory. Each lookup returns only the buildings whose bbox intersects the
10
+ * requested viewport.
11
+ */
12
+ export declare class BuildingService {
13
+ /** Minimum bbox size (meters) the cache is expanded to, to limit API calls. */
14
+ static MIN_BBOX_SIZE: number;
15
+ private static PAGE_SIZE;
16
+ private readonly http;
17
+ private readonly emmid;
18
+ private readonly buildings;
19
+ private cachedBbox;
20
+ /**
21
+ * @param baseUrl - Base URL of the Wemap API (e.g. `https://api.getwemap.com/v3.0`).
22
+ * @param emmid - The livemap id whose buildings to fetch.
23
+ */
24
+ constructor(baseUrl: string, emmid: string | number);
25
+ /**
26
+ * Return the buildings whose bbox intersects `bbox`, fetching from the API
27
+ * when the cache does not already cover the requested viewport.
28
+ */
29
+ getBuildingsFromBbox(bbox: BoundingBox): Promise<Building[]>;
30
+ private intersecting;
31
+ private fetchAll;
32
+ }
33
+ //# sourceMappingURL=BuildingService.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BuildingService.d.ts","sourceRoot":"","sources":["../../../src/services/BuildingService.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9C,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAShD;;;;;;;;GAQG;AACH,qBAAa,eAAe;IAC1B,+EAA+E;IAC/E,MAAM,CAAC,aAAa,SAAQ;IAC5B,OAAO,CAAC,MAAM,CAAC,SAAS,CAAM;IAE9B,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAa;IAClC,OAAO,CAAC,QAAQ,CAAC,KAAK,CAAS;IAC/B,OAAO,CAAC,QAAQ,CAAC,SAAS,CAA+B;IACzD,OAAO,CAAC,UAAU,CAA4B;IAE9C;;;OAGG;gBACS,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM;IAKnD;;;OAGG;IACG,oBAAoB,CAAC,IAAI,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,EAAE,CAAC;IA0BlE,OAAO,CAAC,YAAY;YAaN,QAAQ;CAiBvB"}
@@ -0,0 +1,40 @@
1
+ import { Feature, MultiPolygon, Polygon } from 'geojson';
2
+ /**
3
+ * A single level (floor) of a building, as returned by the Wemap buildings API.
4
+ */
5
+ export interface IndoorLevel {
6
+ /** Unique level id. */
7
+ id: number;
8
+ /** Numeric level (floor). Ground floor is usually `0`. */
9
+ level: number;
10
+ /** Display name (e.g. `"Ground floor"`). */
11
+ name: string;
12
+ /** Short display name (e.g. `"0"`, `"RDC"`). */
13
+ short_name: string;
14
+ /** Minimum altitude of the level, in meters. */
15
+ min_altitude?: number;
16
+ /** Maximum altitude of the level, in meters. */
17
+ max_altitude?: number;
18
+ /** Footprint of the level, when provided. */
19
+ geometry?: Polygon | MultiPolygon;
20
+ }
21
+ /**
22
+ * A building, as returned by `GET /buildings/search`. It is a GeoJSON feature
23
+ * (with a `bbox`) augmented with indoor metadata.
24
+ *
25
+ * Data model: a livemap has many venues, a venue has many buildings, a building
26
+ * has many {@link IndoorLevel}s.
27
+ */
28
+ export type Building = Feature<Polygon | MultiPolygon> & {
29
+ /** Unique building id. */
30
+ id: number;
31
+ /** Building name. */
32
+ name: string;
33
+ /** Level shown by default when the building becomes active. */
34
+ default_level: number;
35
+ /** Parent venue id, or `null`. */
36
+ venue: number | null;
37
+ /** Levels (floors) of the building. */
38
+ levels: IndoorLevel[];
39
+ };
40
+ //# sourceMappingURL=indoor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"indoor.d.ts","sourceRoot":"","sources":["../../../src/types/indoor.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAE9D;;GAEG;AACH,MAAM,WAAW,WAAW;IAC1B,uBAAuB;IACvB,EAAE,EAAE,MAAM,CAAC;IACX,0DAA0D;IAC1D,KAAK,EAAE,MAAM,CAAC;IACd,4CAA4C;IAC5C,IAAI,EAAE,MAAM,CAAC;IACb,gDAAgD;IAChD,UAAU,EAAE,MAAM,CAAC;IACnB,gDAAgD;IAChD,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,gDAAgD;IAChD,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,6CAA6C;IAC7C,QAAQ,CAAC,EAAE,OAAO,GAAG,YAAY,CAAC;CACnC;AAED;;;;;;GAMG;AACH,MAAM,MAAM,QAAQ,GAAG,OAAO,CAAC,OAAO,GAAG,YAAY,CAAC,GAAG;IACvD,0BAA0B;IAC1B,EAAE,EAAE,MAAM,CAAC;IACX,qBAAqB;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,+DAA+D;IAC/D,aAAa,EAAE,MAAM,CAAC;IACtB,kCAAkC;IAClC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAC;IACrB,uCAAuC;IACvC,MAAM,EAAE,WAAW,EAAE,CAAC;CACvB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wemap/core",
3
- "version": "14.5.5",
3
+ "version": "14.6.0-beta.0",
4
4
  "type": "module",
5
5
  "private": false,
6
6
  "publishConfig": {
@@ -18,6 +18,7 @@
18
18
  "dist"
19
19
  ],
20
20
  "dependencies": {
21
- "@wemap/geo": "14.5.5"
21
+ "@wemap/geo": "14.6.0-beta.0",
22
+ "@types/geojson": "^7946.0.16"
22
23
  }
23
24
  }