azure-maps-control 3.0.0-preview.3 → 3.0.0-preview.4
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 +3 -3
- package/dist/atlas-core-bare-snr-min.js +1 -1
- package/dist/atlas-core-bare-snr.js +744 -312
- package/dist/atlas-core-bare.js +968 -407
- package/dist/atlas-core-bare.min.js +1 -1
- package/dist/atlas-core-snr.js +744 -312
- package/dist/atlas-core.js +968 -407
- package/dist/atlas-core.min.js +1 -1
- package/dist/atlas.css +4 -28
- package/dist/atlas.js +968 -407
- package/dist/atlas.min.css +1 -1
- package/dist/atlas.min.js +1 -1
- package/package.json +1 -1
- package/typings/index.d.ts +26 -4
package/dist/atlas-core.js
CHANGED
|
@@ -46563,7 +46563,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
46563
46563
|
return Url;
|
|
46564
46564
|
}());
|
|
46565
46565
|
|
|
46566
|
-
var version = "3.0.0-preview.
|
|
46566
|
+
var version = "3.0.0-preview.4";
|
|
46567
46567
|
|
|
46568
46568
|
/**
|
|
46569
46569
|
* A helper class that provides methods for getting various forms of the map controls current version.
|
|
@@ -46604,27 +46604,6 @@ uniform ${precision} ${type} u_${name};
|
|
|
46604
46604
|
var tooltipContent = document.createElement("span");
|
|
46605
46605
|
tooltipContent.innerText = name;
|
|
46606
46606
|
tooltipContent.classList.add('tooltiptext');
|
|
46607
|
-
// mimics default edge tooltip theming
|
|
46608
|
-
if (window.matchMedia && window.matchMedia('(prefers-color-scheme: dark)').matches) {
|
|
46609
|
-
tooltipContent.classList.add('dark');
|
|
46610
|
-
}
|
|
46611
|
-
var themeQuery = window.matchMedia('(prefers-color-scheme: dark)');
|
|
46612
|
-
var onThemeChange = function (e) {
|
|
46613
|
-
var isDark = e.matches;
|
|
46614
|
-
if (isDark && !tooltipContent.classList.contains('dark')) {
|
|
46615
|
-
tooltipContent.classList.add('dark');
|
|
46616
|
-
}
|
|
46617
|
-
else if (!isDark && tooltipContent.classList.contains('dark')) {
|
|
46618
|
-
tooltipContent.classList.remove('dark');
|
|
46619
|
-
}
|
|
46620
|
-
};
|
|
46621
|
-
// compensate for browsers where MediaQueryList is not derived from EventTarget (pre iOS13 Safari)
|
|
46622
|
-
if (typeof themeQuery.addEventListener === 'function') {
|
|
46623
|
-
themeQuery.addEventListener('change', function (e) { return onThemeChange(e); });
|
|
46624
|
-
}
|
|
46625
|
-
else if (typeof themeQuery.addListener === 'function') {
|
|
46626
|
-
themeQuery.addListener(function (e) { return onThemeChange(e); });
|
|
46627
|
-
}
|
|
46628
46607
|
if (navigator.userAgent.indexOf('Edg') != -1) {
|
|
46629
46608
|
tooltipContent.classList.add('edge');
|
|
46630
46609
|
}
|
|
@@ -50794,6 +50773,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
50794
50773
|
}
|
|
50795
50774
|
});
|
|
50796
50775
|
container.addEventListener("focusout", function (event) {
|
|
50776
|
+
if (event.target === currStyleButton) {
|
|
50777
|
+
// on focusout from reveal button -> reset the tabIndex on the styleOpsGrid elements that could have been set to -1 on esc key press
|
|
50778
|
+
Array.from(styleOpsGrid.children).forEach(function (e) { return e.removeAttribute('tabIndex'); });
|
|
50779
|
+
}
|
|
50797
50780
|
if (!(event.relatedTarget instanceof Node && container.contains(event.relatedTarget))) {
|
|
50798
50781
|
_this.hasFocus = false;
|
|
50799
50782
|
if (!_this.hasMouse) {
|
|
@@ -50808,6 +50791,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
50808
50791
|
if (event.keyCode === 27) {
|
|
50809
50792
|
event.stopPropagation();
|
|
50810
50793
|
currStyleButton.focus();
|
|
50794
|
+
Array.from(styleOpsGrid.children).forEach(function (e) { return e.setAttribute('tabIndex', "-1"); });
|
|
50811
50795
|
if (container.classList.contains(StyleControl.Css.inUse)) {
|
|
50812
50796
|
container.classList.remove(StyleControl.Css.inUse);
|
|
50813
50797
|
styleOpsGrid.classList.add("hidden-accessible-element");
|
|
@@ -51073,8 +51057,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
51073
51057
|
* The type of traffic flow to display:
|
|
51074
51058
|
* <p>"none" is to display no traffic flow data</p>
|
|
51075
51059
|
* <p>"relative" is the speed of the road relative to free-flow</p>
|
|
51076
|
-
* <p
|
|
51077
|
-
* <p
|
|
51060
|
+
* <p>@deprecated "absolute" is the absolute speed of the road</p>
|
|
51061
|
+
* <p>@deprecated "relative-delay" displays relative speed only where they differ from free-flow;
|
|
51078
51062
|
* false to stop displaying the traffic flow.</p>
|
|
51079
51063
|
* default `"none"``
|
|
51080
51064
|
* @default "none"
|
|
@@ -56474,6 +56458,23 @@ uniform ${precision} ${type} u_${name};
|
|
|
56474
56458
|
* @default 0.375
|
|
56475
56459
|
*/
|
|
56476
56460
|
_this.tolerance = 0.375;
|
|
56461
|
+
/**
|
|
56462
|
+
* Minimum number of points necessary to form a cluster if clustering is enabled.
|
|
56463
|
+
* @default 2
|
|
56464
|
+
*/
|
|
56465
|
+
_this.clusterMinPoints = 2;
|
|
56466
|
+
/**
|
|
56467
|
+
* Whether to generate ids for the geojson features. When enabled, the feature.id property will be auto assigned based on its index in the features array, over-writing any previous values.
|
|
56468
|
+
*/
|
|
56469
|
+
_this.generateId = false;
|
|
56470
|
+
/**
|
|
56471
|
+
* A property to use as a feature id (for feature state). Either a property name, or an object of the form {<sourceLayer>: <propertyName>}.
|
|
56472
|
+
*/
|
|
56473
|
+
_this.promoteId = undefined;
|
|
56474
|
+
/**
|
|
56475
|
+
* An expression for filtering features prior to processing them for rendering.
|
|
56476
|
+
*/
|
|
56477
|
+
_this.filter = undefined;
|
|
56477
56478
|
return _this;
|
|
56478
56479
|
}
|
|
56479
56480
|
return DataSourceOptions;
|
|
@@ -56515,19 +56516,24 @@ uniform ${precision} ${type} u_${name};
|
|
|
56515
56516
|
* Get reference to Mapbox Map
|
|
56516
56517
|
* @internal
|
|
56517
56518
|
*/
|
|
56518
|
-
Source.prototype._setMap = function (map) {
|
|
56519
|
+
Source.prototype._setMap = function (map, shouldInvokeEvent) {
|
|
56520
|
+
if (shouldInvokeEvent === void 0) { shouldInvokeEvent = true; }
|
|
56519
56521
|
if (map == null || map === undefined) {
|
|
56520
56522
|
var temp = this.map;
|
|
56521
56523
|
delete this.map;
|
|
56522
|
-
|
|
56523
|
-
|
|
56524
|
-
temp
|
|
56524
|
+
if (shouldInvokeEvent) {
|
|
56525
|
+
this._invokeEvent("sourceremoved", this);
|
|
56526
|
+
if (temp) {
|
|
56527
|
+
temp.events.invoke("sourceremoved", this);
|
|
56528
|
+
}
|
|
56525
56529
|
}
|
|
56526
56530
|
}
|
|
56527
56531
|
else {
|
|
56528
56532
|
this.map = map;
|
|
56529
|
-
|
|
56530
|
-
|
|
56533
|
+
if (shouldInvokeEvent) {
|
|
56534
|
+
this._invokeEvent("sourceadded", this);
|
|
56535
|
+
this.map.events.invoke("sourceadded", this);
|
|
56536
|
+
}
|
|
56531
56537
|
}
|
|
56532
56538
|
};
|
|
56533
56539
|
return Source;
|
|
@@ -56841,13 +56847,38 @@ uniform ${precision} ${type} u_${name};
|
|
|
56841
56847
|
tolerance: this.options.tolerance,
|
|
56842
56848
|
lineMetrics: this.options.lineMetrics,
|
|
56843
56849
|
clusterProperties: this.options.clusterProperties,
|
|
56844
|
-
buffer: this.options.buffer
|
|
56850
|
+
buffer: this.options.buffer,
|
|
56851
|
+
clusterMinPoints: this.options.clusterMinPoints,
|
|
56852
|
+
generateId: this.options.generateId,
|
|
56853
|
+
promoteId: this.options.promoteId,
|
|
56854
|
+
filter: this.options.filter
|
|
56845
56855
|
};
|
|
56846
56856
|
if (typeof this.options.clusterMaxZoom === "number") {
|
|
56847
56857
|
geoJsonSource.clusterMaxZoom = this.options.clusterMaxZoom;
|
|
56848
56858
|
}
|
|
56849
56859
|
return geoJsonSource;
|
|
56850
56860
|
};
|
|
56861
|
+
DataSource.prototype._isDeepEqual = function (other) {
|
|
56862
|
+
if (this.constructor !== other.constructor) {
|
|
56863
|
+
return false;
|
|
56864
|
+
}
|
|
56865
|
+
var source = this._buildSource();
|
|
56866
|
+
var otherSource = other._buildSource();
|
|
56867
|
+
return source.type === otherSource.type &&
|
|
56868
|
+
// no data comparison since it is costly and not needed. If geojson data is different, but other source properties are same, we treat it as an update.
|
|
56869
|
+
//source.data === otherSource.data &&
|
|
56870
|
+
source.maxzoom === otherSource.maxzoom &&
|
|
56871
|
+
source.cluster === otherSource.cluster &&
|
|
56872
|
+
source.clusterRadius === otherSource.clusterRadius &&
|
|
56873
|
+
source.tolerance === otherSource.tolerance &&
|
|
56874
|
+
source.lineMetrics === otherSource.lineMetrics &&
|
|
56875
|
+
JSON.stringify(source.clusterProperties) === JSON.stringify(otherSource.clusterProperties) &&
|
|
56876
|
+
source.buffer === otherSource.buffer &&
|
|
56877
|
+
source.clusterMinPoints === otherSource.clusterMinPoints &&
|
|
56878
|
+
source.generateId === otherSource.generateId &&
|
|
56879
|
+
source.promoteId === otherSource.promoteId &&
|
|
56880
|
+
source.filter === otherSource.filter;
|
|
56881
|
+
};
|
|
56851
56882
|
/**
|
|
56852
56883
|
* @internal
|
|
56853
56884
|
*/
|
|
@@ -57129,19 +57160,262 @@ uniform ${precision} ${type} u_${name};
|
|
|
57129
57160
|
}
|
|
57130
57161
|
return vectorSource;
|
|
57131
57162
|
};
|
|
57163
|
+
/**
|
|
57164
|
+
* @internal
|
|
57165
|
+
*/
|
|
57166
|
+
VectorTileSource.prototype._isDeepEqual = function (other) {
|
|
57167
|
+
if (this.constructor !== other.constructor) {
|
|
57168
|
+
return false;
|
|
57169
|
+
}
|
|
57170
|
+
var source = this._buildSource();
|
|
57171
|
+
var otherSource = other._buildSource();
|
|
57172
|
+
return source.type === otherSource.type &&
|
|
57173
|
+
source.url === otherSource.url &&
|
|
57174
|
+
((source.tiles === undefined && otherSource.tiles === undefined) ||
|
|
57175
|
+
(source.tiles && otherSource.tiles && source.tiles.length === otherSource.tiles.length && source.tiles.every(function (value, idx) { return value === otherSource.tiles[idx]; }))) &&
|
|
57176
|
+
source.minzoom === otherSource.minzoom &&
|
|
57177
|
+
source.maxzoom === otherSource.maxzoom &&
|
|
57178
|
+
source.bounds === otherSource.bounds &&
|
|
57179
|
+
source.attribution === otherSource.attribution &&
|
|
57180
|
+
source.promoteId === otherSource.promoteId &&
|
|
57181
|
+
source.scheme === otherSource.scheme;
|
|
57182
|
+
};
|
|
57132
57183
|
return VectorTileSource;
|
|
57133
57184
|
}(Source));
|
|
57134
57185
|
|
|
57186
|
+
var __extends$p = (window && window.__extends) || (function () {
|
|
57187
|
+
var extendStatics = function (d, b) {
|
|
57188
|
+
extendStatics = Object.setPrototypeOf ||
|
|
57189
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
57190
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
57191
|
+
return extendStatics(d, b);
|
|
57192
|
+
};
|
|
57193
|
+
return function (d, b) {
|
|
57194
|
+
if (typeof b !== "function" && b !== null)
|
|
57195
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
57196
|
+
extendStatics(d, b);
|
|
57197
|
+
function __() { this.constructor = d; }
|
|
57198
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
57199
|
+
};
|
|
57200
|
+
})();
|
|
57201
|
+
/**
|
|
57202
|
+
* Used to represent the canvas source wrapper.
|
|
57203
|
+
* This is not meant to be exposed publicly yet
|
|
57204
|
+
* @private
|
|
57205
|
+
*/
|
|
57206
|
+
var CanvasSource = /** @class */ (function (_super) {
|
|
57207
|
+
__extends$p(CanvasSource, _super);
|
|
57208
|
+
/**
|
|
57209
|
+
* Constructs a source from the contents of a layer resource file.
|
|
57210
|
+
* @param id The source's id.
|
|
57211
|
+
* @param sourceDef Canvas source specification.
|
|
57212
|
+
* @param options Unused for now
|
|
57213
|
+
*/
|
|
57214
|
+
function CanvasSource(id, sourceDef, options) {
|
|
57215
|
+
var _this = _super.call(this, id) || this;
|
|
57216
|
+
_this.source = sourceDef;
|
|
57217
|
+
return _this;
|
|
57218
|
+
}
|
|
57219
|
+
/**
|
|
57220
|
+
* @internal
|
|
57221
|
+
*/
|
|
57222
|
+
CanvasSource.prototype._isDeepEqual = function (other) {
|
|
57223
|
+
if (this.constructor !== other.constructor) {
|
|
57224
|
+
return false;
|
|
57225
|
+
}
|
|
57226
|
+
var source = this.source;
|
|
57227
|
+
var otherSource = other.source;
|
|
57228
|
+
return source.type === otherSource.type
|
|
57229
|
+
&& source.canvas === otherSource.canvas
|
|
57230
|
+
&& JSON.stringify(source.coordinates) === JSON.stringify(otherSource.coordinates)
|
|
57231
|
+
&& source.animate === otherSource.animate;
|
|
57232
|
+
};
|
|
57233
|
+
/**
|
|
57234
|
+
* @internal
|
|
57235
|
+
*/
|
|
57236
|
+
CanvasSource.prototype._buildSource = function () {
|
|
57237
|
+
return this.source;
|
|
57238
|
+
};
|
|
57239
|
+
return CanvasSource;
|
|
57240
|
+
}(Source));
|
|
57241
|
+
|
|
57242
|
+
var __extends$q = (window && window.__extends) || (function () {
|
|
57243
|
+
var extendStatics = function (d, b) {
|
|
57244
|
+
extendStatics = Object.setPrototypeOf ||
|
|
57245
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
57246
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
57247
|
+
return extendStatics(d, b);
|
|
57248
|
+
};
|
|
57249
|
+
return function (d, b) {
|
|
57250
|
+
if (typeof b !== "function" && b !== null)
|
|
57251
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
57252
|
+
extendStatics(d, b);
|
|
57253
|
+
function __() { this.constructor = d; }
|
|
57254
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
57255
|
+
};
|
|
57256
|
+
})();
|
|
57257
|
+
/**
|
|
57258
|
+
* Used to represent an unkown source wrapper.
|
|
57259
|
+
* This is not meant to be exposed publicly yet
|
|
57260
|
+
* @private
|
|
57261
|
+
*/
|
|
57262
|
+
var UnknownSource = /** @class */ (function (_super) {
|
|
57263
|
+
__extends$q(UnknownSource, _super);
|
|
57264
|
+
/**
|
|
57265
|
+
* Constructs a source from the contents of a layer resource file.
|
|
57266
|
+
* @param id The source's id.
|
|
57267
|
+
* @param sourceDef source specification.
|
|
57268
|
+
* @param options Unused for now
|
|
57269
|
+
*/
|
|
57270
|
+
function UnknownSource(id, sourceDef, options) {
|
|
57271
|
+
var _this = _super.call(this, id) || this;
|
|
57272
|
+
_this.source = sourceDef;
|
|
57273
|
+
return _this;
|
|
57274
|
+
}
|
|
57275
|
+
/**
|
|
57276
|
+
* @internal
|
|
57277
|
+
*/
|
|
57278
|
+
UnknownSource.prototype._isDeepEqual = function (other) {
|
|
57279
|
+
if (this.constructor !== other.constructor) {
|
|
57280
|
+
return false;
|
|
57281
|
+
}
|
|
57282
|
+
var source = this.source;
|
|
57283
|
+
var otherSource = other.source;
|
|
57284
|
+
return source.type === otherSource.type;
|
|
57285
|
+
};
|
|
57286
|
+
/**
|
|
57287
|
+
* @internal
|
|
57288
|
+
*/
|
|
57289
|
+
UnknownSource.prototype._buildSource = function () {
|
|
57290
|
+
return this.source;
|
|
57291
|
+
};
|
|
57292
|
+
return UnknownSource;
|
|
57293
|
+
}(Source));
|
|
57294
|
+
|
|
57295
|
+
var __extends$r = (window && window.__extends) || (function () {
|
|
57296
|
+
var extendStatics = function (d, b) {
|
|
57297
|
+
extendStatics = Object.setPrototypeOf ||
|
|
57298
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
57299
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
57300
|
+
return extendStatics(d, b);
|
|
57301
|
+
};
|
|
57302
|
+
return function (d, b) {
|
|
57303
|
+
if (typeof b !== "function" && b !== null)
|
|
57304
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
57305
|
+
extendStatics(d, b);
|
|
57306
|
+
function __() { this.constructor = d; }
|
|
57307
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
57308
|
+
};
|
|
57309
|
+
})();
|
|
57310
|
+
/**
|
|
57311
|
+
* Used to represent the image source wrapper.
|
|
57312
|
+
* This is not meant to be exposed publicly yet
|
|
57313
|
+
* @private
|
|
57314
|
+
*/
|
|
57315
|
+
var ImageSource = /** @class */ (function (_super) {
|
|
57316
|
+
__extends$r(ImageSource, _super);
|
|
57317
|
+
/**
|
|
57318
|
+
* Constructs a source from the contents of a layer resource file.
|
|
57319
|
+
* @param id The source's id.
|
|
57320
|
+
* @param sourceDef Image source specification.
|
|
57321
|
+
* @param options Unused for now
|
|
57322
|
+
*/
|
|
57323
|
+
function ImageSource(id, sourceDef, options) {
|
|
57324
|
+
var _this = _super.call(this, id) || this;
|
|
57325
|
+
_this.source = sourceDef;
|
|
57326
|
+
return _this;
|
|
57327
|
+
}
|
|
57328
|
+
/**
|
|
57329
|
+
* @internal
|
|
57330
|
+
*/
|
|
57331
|
+
ImageSource.prototype._isDeepEqual = function (other) {
|
|
57332
|
+
if (this.constructor !== other.constructor) {
|
|
57333
|
+
return false;
|
|
57334
|
+
}
|
|
57335
|
+
var source = this.source;
|
|
57336
|
+
var otherSource = other.source;
|
|
57337
|
+
return source.type === otherSource.type
|
|
57338
|
+
&& JSON.stringify(source.coordinates) === JSON.stringify(otherSource.coordinates)
|
|
57339
|
+
&& source.url === otherSource.url;
|
|
57340
|
+
};
|
|
57341
|
+
/**
|
|
57342
|
+
* @internal
|
|
57343
|
+
*/
|
|
57344
|
+
ImageSource.prototype._buildSource = function () {
|
|
57345
|
+
return this.source;
|
|
57346
|
+
};
|
|
57347
|
+
return ImageSource;
|
|
57348
|
+
}(Source));
|
|
57349
|
+
|
|
57350
|
+
var __extends$s = (window && window.__extends) || (function () {
|
|
57351
|
+
var extendStatics = function (d, b) {
|
|
57352
|
+
extendStatics = Object.setPrototypeOf ||
|
|
57353
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
57354
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
57355
|
+
return extendStatics(d, b);
|
|
57356
|
+
};
|
|
57357
|
+
return function (d, b) {
|
|
57358
|
+
if (typeof b !== "function" && b !== null)
|
|
57359
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
57360
|
+
extendStatics(d, b);
|
|
57361
|
+
function __() { this.constructor = d; }
|
|
57362
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
57363
|
+
};
|
|
57364
|
+
})();
|
|
57365
|
+
/**
|
|
57366
|
+
* Used to represent the video source wrapper.
|
|
57367
|
+
* This is not meant to be exposed publicly yet
|
|
57368
|
+
* @private
|
|
57369
|
+
*/
|
|
57370
|
+
var VideoSource = /** @class */ (function (_super) {
|
|
57371
|
+
__extends$s(VideoSource, _super);
|
|
57372
|
+
/**
|
|
57373
|
+
* Constructs a source from the contents of a layer resource file.
|
|
57374
|
+
* @param id The source's id.
|
|
57375
|
+
* @param sourceDef Video source specification.
|
|
57376
|
+
* @param options Unused for now
|
|
57377
|
+
*/
|
|
57378
|
+
function VideoSource(id, sourceDef, options) {
|
|
57379
|
+
var _this = _super.call(this, id) || this;
|
|
57380
|
+
_this.source = sourceDef;
|
|
57381
|
+
return _this;
|
|
57382
|
+
}
|
|
57383
|
+
/**
|
|
57384
|
+
* @internal
|
|
57385
|
+
*/
|
|
57386
|
+
VideoSource.prototype._isDeepEqual = function (other) {
|
|
57387
|
+
if (this.constructor !== other.constructor) {
|
|
57388
|
+
return false;
|
|
57389
|
+
}
|
|
57390
|
+
var source = this.source;
|
|
57391
|
+
var otherSource = other.source;
|
|
57392
|
+
return source.type === otherSource.type
|
|
57393
|
+
&& JSON.stringify(source.coordinates) === JSON.stringify(otherSource.coordinates)
|
|
57394
|
+
&& source.urls === otherSource.urls;
|
|
57395
|
+
};
|
|
57396
|
+
/**
|
|
57397
|
+
* @internal
|
|
57398
|
+
*/
|
|
57399
|
+
VideoSource.prototype._buildSource = function () {
|
|
57400
|
+
return this.source;
|
|
57401
|
+
};
|
|
57402
|
+
return VideoSource;
|
|
57403
|
+
}(Source));
|
|
57404
|
+
|
|
57135
57405
|
|
|
57136
57406
|
|
|
57137
57407
|
var index$4 = /*#__PURE__*/Object.freeze({
|
|
57138
57408
|
__proto__: null,
|
|
57139
57409
|
Source: Source,
|
|
57140
57410
|
DataSource: DataSource,
|
|
57141
|
-
VectorTileSource: VectorTileSource
|
|
57411
|
+
VectorTileSource: VectorTileSource,
|
|
57412
|
+
CanvasSource: CanvasSource,
|
|
57413
|
+
ImageSource: ImageSource,
|
|
57414
|
+
VideoSource: VideoSource,
|
|
57415
|
+
UnknownSource: UnknownSource
|
|
57142
57416
|
});
|
|
57143
57417
|
|
|
57144
|
-
var __extends$
|
|
57418
|
+
var __extends$t = (window && window.__extends) || (function () {
|
|
57145
57419
|
var extendStatics = function (d, b) {
|
|
57146
57420
|
extendStatics = Object.setPrototypeOf ||
|
|
57147
57421
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57160,7 +57434,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57160
57434
|
* Abstract class for other layer classes to extend.
|
|
57161
57435
|
*/
|
|
57162
57436
|
var Layer = /** @class */ (function (_super) {
|
|
57163
|
-
__extends$
|
|
57437
|
+
__extends$t(Layer, _super);
|
|
57164
57438
|
function Layer(id) {
|
|
57165
57439
|
var _this =
|
|
57166
57440
|
// Assign an random id using a UUID if none was specified.
|
|
@@ -57265,7 +57539,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57265
57539
|
return Layer;
|
|
57266
57540
|
}(EventEmitter));
|
|
57267
57541
|
|
|
57268
|
-
var __extends$
|
|
57542
|
+
var __extends$u = (window && window.__extends) || (function () {
|
|
57269
57543
|
var extendStatics = function (d, b) {
|
|
57270
57544
|
extendStatics = Object.setPrototypeOf ||
|
|
57271
57545
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57284,7 +57558,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57284
57558
|
* A base class which all other layer options inherit from.
|
|
57285
57559
|
*/
|
|
57286
57560
|
var LayerOptions = /** @class */ (function (_super) {
|
|
57287
|
-
__extends$
|
|
57561
|
+
__extends$u(LayerOptions, _super);
|
|
57288
57562
|
function LayerOptions() {
|
|
57289
57563
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
57290
57564
|
/**
|
|
@@ -57331,7 +57605,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57331
57605
|
return LayerOptions;
|
|
57332
57606
|
}(Options));
|
|
57333
57607
|
|
|
57334
|
-
var __extends$
|
|
57608
|
+
var __extends$v = (window && window.__extends) || (function () {
|
|
57335
57609
|
var extendStatics = function (d, b) {
|
|
57336
57610
|
extendStatics = Object.setPrototypeOf ||
|
|
57337
57611
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57350,7 +57624,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57350
57624
|
* Options used when rendering Point objects in a BubbleLayer.
|
|
57351
57625
|
*/
|
|
57352
57626
|
var BubbleLayerOptions = /** @class */ (function (_super) {
|
|
57353
|
-
__extends$
|
|
57627
|
+
__extends$v(BubbleLayerOptions, _super);
|
|
57354
57628
|
function BubbleLayerOptions() {
|
|
57355
57629
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
57356
57630
|
/**
|
|
@@ -57420,7 +57694,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57420
57694
|
return BubbleLayerOptions;
|
|
57421
57695
|
}(LayerOptions));
|
|
57422
57696
|
|
|
57423
|
-
var __extends$
|
|
57697
|
+
var __extends$w = (window && window.__extends) || (function () {
|
|
57424
57698
|
var extendStatics = function (d, b) {
|
|
57425
57699
|
extendStatics = Object.setPrototypeOf ||
|
|
57426
57700
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57439,7 +57713,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57439
57713
|
* Renders Point objects as scalable circles (bubbles).
|
|
57440
57714
|
*/
|
|
57441
57715
|
var BubbleLayer = /** @class */ (function (_super) {
|
|
57442
|
-
__extends$
|
|
57716
|
+
__extends$w(BubbleLayer, _super);
|
|
57443
57717
|
/**
|
|
57444
57718
|
* Constructs a new BubbleLayer.
|
|
57445
57719
|
* @param source The id or instance of a data source which the layer will render.
|
|
@@ -57549,7 +57823,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57549
57823
|
return BubbleLayer;
|
|
57550
57824
|
}(Layer));
|
|
57551
57825
|
|
|
57552
|
-
var __extends$
|
|
57826
|
+
var __extends$x = (window && window.__extends) || (function () {
|
|
57553
57827
|
var extendStatics = function (d, b) {
|
|
57554
57828
|
extendStatics = Object.setPrototypeOf ||
|
|
57555
57829
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57568,7 +57842,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57568
57842
|
* Options used when rendering Point objects in a HeatMapLayer.
|
|
57569
57843
|
*/
|
|
57570
57844
|
var HeatMapLayerOptions = /** @class */ (function (_super) {
|
|
57571
|
-
__extends$
|
|
57845
|
+
__extends$x(HeatMapLayerOptions, _super);
|
|
57572
57846
|
function HeatMapLayerOptions() {
|
|
57573
57847
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
57574
57848
|
/**
|
|
@@ -57635,7 +57909,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57635
57909
|
return HeatMapLayerOptions;
|
|
57636
57910
|
}(LayerOptions));
|
|
57637
57911
|
|
|
57638
|
-
var __extends$
|
|
57912
|
+
var __extends$y = (window && window.__extends) || (function () {
|
|
57639
57913
|
var extendStatics = function (d, b) {
|
|
57640
57914
|
extendStatics = Object.setPrototypeOf ||
|
|
57641
57915
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57654,7 +57928,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57654
57928
|
* Represent the density of data using different colors (HeatMap).
|
|
57655
57929
|
*/
|
|
57656
57930
|
var HeatMapLayer = /** @class */ (function (_super) {
|
|
57657
|
-
__extends$
|
|
57931
|
+
__extends$y(HeatMapLayer, _super);
|
|
57658
57932
|
/**
|
|
57659
57933
|
* Constructs a new HeatMapLayer.
|
|
57660
57934
|
* @param source The id or instance of a data source which the layer will render.
|
|
@@ -57758,7 +58032,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57758
58032
|
return HeatMapLayer;
|
|
57759
58033
|
}(Layer));
|
|
57760
58034
|
|
|
57761
|
-
var __extends$
|
|
58035
|
+
var __extends$z = (window && window.__extends) || (function () {
|
|
57762
58036
|
var extendStatics = function (d, b) {
|
|
57763
58037
|
extendStatics = Object.setPrototypeOf ||
|
|
57764
58038
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57777,7 +58051,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57777
58051
|
* Options used when rendering canvas, image, raster tile, and video layers
|
|
57778
58052
|
*/
|
|
57779
58053
|
var MediaLayerOptions = /** @class */ (function (_super) {
|
|
57780
|
-
__extends$
|
|
58054
|
+
__extends$z(MediaLayerOptions, _super);
|
|
57781
58055
|
function MediaLayerOptions() {
|
|
57782
58056
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
57783
58057
|
/**
|
|
@@ -57829,7 +58103,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57829
58103
|
return MediaLayerOptions;
|
|
57830
58104
|
}(LayerOptions));
|
|
57831
58105
|
|
|
57832
|
-
var __extends$
|
|
58106
|
+
var __extends$A = (window && window.__extends) || (function () {
|
|
57833
58107
|
var extendStatics = function (d, b) {
|
|
57834
58108
|
extendStatics = Object.setPrototypeOf ||
|
|
57835
58109
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57848,7 +58122,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57848
58122
|
* Options used when rendering Point objects in a ImageLayer.
|
|
57849
58123
|
*/
|
|
57850
58124
|
var ImageLayerOptions = /** @class */ (function (_super) {
|
|
57851
|
-
__extends$
|
|
58125
|
+
__extends$A(ImageLayerOptions, _super);
|
|
57852
58126
|
function ImageLayerOptions() {
|
|
57853
58127
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
57854
58128
|
/**
|
|
@@ -57878,7 +58152,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57878
58152
|
return ImageLayerOptions;
|
|
57879
58153
|
}(MediaLayerOptions));
|
|
57880
58154
|
|
|
57881
|
-
var __extends$
|
|
58155
|
+
var __extends$B = (window && window.__extends) || (function () {
|
|
57882
58156
|
var extendStatics = function (d, b) {
|
|
57883
58157
|
extendStatics = Object.setPrototypeOf ||
|
|
57884
58158
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57898,7 +58172,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57898
58172
|
* @internal
|
|
57899
58173
|
*/
|
|
57900
58174
|
var SourceBuildingLayer = /** @class */ (function (_super) {
|
|
57901
|
-
__extends$
|
|
58175
|
+
__extends$B(SourceBuildingLayer, _super);
|
|
57902
58176
|
function SourceBuildingLayer() {
|
|
57903
58177
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
57904
58178
|
}
|
|
@@ -57910,10 +58184,13 @@ uniform ${precision} ${type} u_${name};
|
|
|
57910
58184
|
ids.add(this._getSourceId());
|
|
57911
58185
|
return ids;
|
|
57912
58186
|
};
|
|
58187
|
+
SourceBuildingLayer.prototype.onAdd = function (map) {
|
|
58188
|
+
_super.prototype.onAdd.call(this, map);
|
|
58189
|
+
};
|
|
57913
58190
|
return SourceBuildingLayer;
|
|
57914
58191
|
}(Layer));
|
|
57915
58192
|
|
|
57916
|
-
var __extends$
|
|
58193
|
+
var __extends$C = (window && window.__extends) || (function () {
|
|
57917
58194
|
var extendStatics = function (d, b) {
|
|
57918
58195
|
extendStatics = Object.setPrototypeOf ||
|
|
57919
58196
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57932,7 +58209,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57932
58209
|
* Overlays an image on the map with each corner anchored to a coordinate on the map. Also known as a ground or image overlay.
|
|
57933
58210
|
*/
|
|
57934
58211
|
var ImageLayer = /** @class */ (function (_super) {
|
|
57935
|
-
__extends$
|
|
58212
|
+
__extends$C(ImageLayer, _super);
|
|
57936
58213
|
/**
|
|
57937
58214
|
* Constructs a new ImageLayer.
|
|
57938
58215
|
* @param id The id of the layer. If not specified a random one will be generated.
|
|
@@ -58132,10 +58409,15 @@ uniform ${precision} ${type} u_${name};
|
|
|
58132
58409
|
this.transform = Promise.resolve(new AffineTransform(corners, this.options.coordinates));
|
|
58133
58410
|
}
|
|
58134
58411
|
};
|
|
58412
|
+
ImageLayer.prototype._getSourceWrapper = function () {
|
|
58413
|
+
var sourceId = this._getSourceId();
|
|
58414
|
+
var source = this._buildSource();
|
|
58415
|
+
return new ImageSource(sourceId, source);
|
|
58416
|
+
};
|
|
58135
58417
|
return ImageLayer;
|
|
58136
58418
|
}(SourceBuildingLayer));
|
|
58137
58419
|
|
|
58138
|
-
var __extends$
|
|
58420
|
+
var __extends$D = (window && window.__extends) || (function () {
|
|
58139
58421
|
var extendStatics = function (d, b) {
|
|
58140
58422
|
extendStatics = Object.setPrototypeOf ||
|
|
58141
58423
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58155,7 +58437,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58155
58437
|
* LineString, MultiLineString, Polygon, and MultiPolygon objects in a line layer.
|
|
58156
58438
|
*/
|
|
58157
58439
|
var LineLayerOptions = /** @class */ (function (_super) {
|
|
58158
|
-
__extends$
|
|
58440
|
+
__extends$D(LineLayerOptions, _super);
|
|
58159
58441
|
function LineLayerOptions() {
|
|
58160
58442
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
58161
58443
|
/**
|
|
@@ -58255,7 +58537,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58255
58537
|
return LineLayerOptions;
|
|
58256
58538
|
}(LayerOptions));
|
|
58257
58539
|
|
|
58258
|
-
var __extends$
|
|
58540
|
+
var __extends$E = (window && window.__extends) || (function () {
|
|
58259
58541
|
var extendStatics = function (d, b) {
|
|
58260
58542
|
extendStatics = Object.setPrototypeOf ||
|
|
58261
58543
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58286,7 +58568,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58286
58568
|
* CirclePolygon, LineString, MultiLineString, Polygon, and MultiPolygon objects.
|
|
58287
58569
|
*/
|
|
58288
58570
|
var LineLayer = /** @class */ (function (_super) {
|
|
58289
|
-
__extends$
|
|
58571
|
+
__extends$E(LineLayer, _super);
|
|
58290
58572
|
/**
|
|
58291
58573
|
* Constructs a new LineLayer.
|
|
58292
58574
|
* @param source The id or instance of a data source which the layer will render.
|
|
@@ -58377,7 +58659,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58377
58659
|
return LineLayer;
|
|
58378
58660
|
}(Layer));
|
|
58379
58661
|
|
|
58380
|
-
var __extends$
|
|
58662
|
+
var __extends$F = (window && window.__extends) || (function () {
|
|
58381
58663
|
var extendStatics = function (d, b) {
|
|
58382
58664
|
extendStatics = Object.setPrototypeOf ||
|
|
58383
58665
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58396,7 +58678,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58396
58678
|
* Options used when rendering `Polygon` and `MultiPolygon` objects in a `PolygonExtrusionLayer`.
|
|
58397
58679
|
*/
|
|
58398
58680
|
var PolygonExtrusionLayerOptions = /** @class */ (function (_super) {
|
|
58399
|
-
__extends$
|
|
58681
|
+
__extends$F(PolygonExtrusionLayerOptions, _super);
|
|
58400
58682
|
function PolygonExtrusionLayerOptions() {
|
|
58401
58683
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
58402
58684
|
/**
|
|
@@ -58469,7 +58751,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58469
58751
|
return PolygonExtrusionLayerOptions;
|
|
58470
58752
|
}(LayerOptions));
|
|
58471
58753
|
|
|
58472
|
-
var __extends$
|
|
58754
|
+
var __extends$G = (window && window.__extends) || (function () {
|
|
58473
58755
|
var extendStatics = function (d, b) {
|
|
58474
58756
|
extendStatics = Object.setPrototypeOf ||
|
|
58475
58757
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58499,7 +58781,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58499
58781
|
* Renders extruded filled `Polygon` and `MultiPolygon` objects on the map.
|
|
58500
58782
|
*/
|
|
58501
58783
|
var PolygonExtrusionLayer = /** @class */ (function (_super) {
|
|
58502
|
-
__extends$
|
|
58784
|
+
__extends$G(PolygonExtrusionLayer, _super);
|
|
58503
58785
|
/**
|
|
58504
58786
|
* Constructs a new PolygonExtrusionLayer.
|
|
58505
58787
|
* @param source The id or instance of a data source which the layer will render.
|
|
@@ -58587,7 +58869,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58587
58869
|
return PolygonExtrusionLayer;
|
|
58588
58870
|
}(Layer));
|
|
58589
58871
|
|
|
58590
|
-
var __extends$
|
|
58872
|
+
var __extends$H = (window && window.__extends) || (function () {
|
|
58591
58873
|
var extendStatics = function (d, b) {
|
|
58592
58874
|
extendStatics = Object.setPrototypeOf ||
|
|
58593
58875
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58638,7 +58920,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58638
58920
|
* Options used when rendering Polygon and MultiPolygon objects in a PolygonLayer.
|
|
58639
58921
|
*/
|
|
58640
58922
|
var PolygonLayerOptions = /** @class */ (function (_super) {
|
|
58641
|
-
__extends$
|
|
58923
|
+
__extends$H(PolygonLayerOptions, _super);
|
|
58642
58924
|
function PolygonLayerOptions() {
|
|
58643
58925
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
58644
58926
|
/**
|
|
@@ -58716,7 +58998,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58716
58998
|
return PolygonLayerOptions;
|
|
58717
58999
|
}(LayerOptions));
|
|
58718
59000
|
|
|
58719
|
-
var __extends$
|
|
59001
|
+
var __extends$I = (window && window.__extends) || (function () {
|
|
58720
59002
|
var extendStatics = function (d, b) {
|
|
58721
59003
|
extendStatics = Object.setPrototypeOf ||
|
|
58722
59004
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58735,7 +59017,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58735
59017
|
* Renders filled Polygon and MultiPolygon objects on the map.
|
|
58736
59018
|
*/
|
|
58737
59019
|
var PolygonLayer = /** @class */ (function (_super) {
|
|
58738
|
-
__extends$
|
|
59020
|
+
__extends$I(PolygonLayer, _super);
|
|
58739
59021
|
/**
|
|
58740
59022
|
* Constructs a new PolygonLayer.
|
|
58741
59023
|
* @param source The id or instance of a data source which the layer will render.
|
|
@@ -58841,7 +59123,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58841
59123
|
return PolygonLayer;
|
|
58842
59124
|
}(Layer));
|
|
58843
59125
|
|
|
58844
|
-
var __extends$
|
|
59126
|
+
var __extends$J = (window && window.__extends) || (function () {
|
|
58845
59127
|
var extendStatics = function (d, b) {
|
|
58846
59128
|
extendStatics = Object.setPrototypeOf ||
|
|
58847
59129
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58860,7 +59142,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58860
59142
|
* Options used to customize the icons in a SymbolLayer
|
|
58861
59143
|
*/
|
|
58862
59144
|
var IconOptions = /** @class */ (function (_super) {
|
|
58863
|
-
__extends$
|
|
59145
|
+
__extends$J(IconOptions, _super);
|
|
58864
59146
|
function IconOptions() {
|
|
58865
59147
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
58866
59148
|
/**
|
|
@@ -58970,7 +59252,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58970
59252
|
return IconOptions;
|
|
58971
59253
|
}(Options));
|
|
58972
59254
|
|
|
58973
|
-
var __extends$
|
|
59255
|
+
var __extends$K = (window && window.__extends) || (function () {
|
|
58974
59256
|
var extendStatics = function (d, b) {
|
|
58975
59257
|
extendStatics = Object.setPrototypeOf ||
|
|
58976
59258
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58989,7 +59271,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58989
59271
|
* Options used to customize the text in a SymbolLayer
|
|
58990
59272
|
*/
|
|
58991
59273
|
var TextOptions = /** @class */ (function (_super) {
|
|
58992
|
-
__extends$
|
|
59274
|
+
__extends$K(TextOptions, _super);
|
|
58993
59275
|
function TextOptions() {
|
|
58994
59276
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
58995
59277
|
/**
|
|
@@ -59143,7 +59425,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59143
59425
|
return TextOptions;
|
|
59144
59426
|
}(Options));
|
|
59145
59427
|
|
|
59146
|
-
var __extends$
|
|
59428
|
+
var __extends$L = (window && window.__extends) || (function () {
|
|
59147
59429
|
var extendStatics = function (d, b) {
|
|
59148
59430
|
extendStatics = Object.setPrototypeOf ||
|
|
59149
59431
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59162,7 +59444,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59162
59444
|
* Options used when rendering geometries in a SymbolLayer.
|
|
59163
59445
|
*/
|
|
59164
59446
|
var SymbolLayerOptions = /** @class */ (function (_super) {
|
|
59165
|
-
__extends$
|
|
59447
|
+
__extends$L(SymbolLayerOptions, _super);
|
|
59166
59448
|
function SymbolLayerOptions() {
|
|
59167
59449
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
59168
59450
|
/**
|
|
@@ -59220,7 +59502,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59220
59502
|
return SymbolLayerOptions;
|
|
59221
59503
|
}(LayerOptions));
|
|
59222
59504
|
|
|
59223
|
-
var __extends$
|
|
59505
|
+
var __extends$M = (window && window.__extends) || (function () {
|
|
59224
59506
|
var extendStatics = function (d, b) {
|
|
59225
59507
|
extendStatics = Object.setPrototypeOf ||
|
|
59226
59508
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59251,7 +59533,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59251
59533
|
* Symbols can also be created for line and polygon data as well.
|
|
59252
59534
|
*/
|
|
59253
59535
|
var SymbolLayer = /** @class */ (function (_super) {
|
|
59254
|
-
__extends$
|
|
59536
|
+
__extends$M(SymbolLayer, _super);
|
|
59255
59537
|
/**
|
|
59256
59538
|
* Constructs a new SymbolLayer.
|
|
59257
59539
|
* @param source The id or instance of a data source which the layer will render.
|
|
@@ -59393,7 +59675,124 @@ uniform ${precision} ${type} u_${name};
|
|
|
59393
59675
|
return SymbolLayer;
|
|
59394
59676
|
}(Layer));
|
|
59395
59677
|
|
|
59396
|
-
var __extends$
|
|
59678
|
+
var __extends$N = (window && window.__extends) || (function () {
|
|
59679
|
+
var extendStatics = function (d, b) {
|
|
59680
|
+
extendStatics = Object.setPrototypeOf ||
|
|
59681
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
59682
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
59683
|
+
return extendStatics(d, b);
|
|
59684
|
+
};
|
|
59685
|
+
return function (d, b) {
|
|
59686
|
+
if (typeof b !== "function" && b !== null)
|
|
59687
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
59688
|
+
extendStatics(d, b);
|
|
59689
|
+
function __() { this.constructor = d; }
|
|
59690
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
59691
|
+
};
|
|
59692
|
+
})();
|
|
59693
|
+
var __assign$3 = (window && window.__assign) || function () {
|
|
59694
|
+
__assign$3 = Object.assign || function(t) {
|
|
59695
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
59696
|
+
s = arguments[i];
|
|
59697
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
59698
|
+
t[p] = s[p];
|
|
59699
|
+
}
|
|
59700
|
+
return t;
|
|
59701
|
+
};
|
|
59702
|
+
return __assign$3.apply(this, arguments);
|
|
59703
|
+
};
|
|
59704
|
+
/**
|
|
59705
|
+
* Used to represent the fundamental map source.
|
|
59706
|
+
* @private
|
|
59707
|
+
*/
|
|
59708
|
+
var FundamentalMapSource = /** @class */ (function (_super) {
|
|
59709
|
+
__extends$N(FundamentalMapSource, _super);
|
|
59710
|
+
/**
|
|
59711
|
+
* Constructs a source from the contents of a layer resource file.
|
|
59712
|
+
* @param id The source's id.
|
|
59713
|
+
* @param sourceDef The sources entry of the resource file.
|
|
59714
|
+
* @param options The query parameters to add to the urls listed in the resource file.
|
|
59715
|
+
*/
|
|
59716
|
+
function FundamentalMapSource(id, sourceDef, options) {
|
|
59717
|
+
var _this = _super.call(this, id) || this;
|
|
59718
|
+
_this.source = _this._modifySource(sourceDef, options);
|
|
59719
|
+
return _this;
|
|
59720
|
+
}
|
|
59721
|
+
/**
|
|
59722
|
+
* @internal
|
|
59723
|
+
*/
|
|
59724
|
+
FundamentalMapSource.prototype._buildSource = function () {
|
|
59725
|
+
return this.source;
|
|
59726
|
+
};
|
|
59727
|
+
/**
|
|
59728
|
+
* @internal
|
|
59729
|
+
*/
|
|
59730
|
+
FundamentalMapSource.prototype._isDeepEqual = function (other) {
|
|
59731
|
+
if (this.constructor !== other.constructor) {
|
|
59732
|
+
return false;
|
|
59733
|
+
}
|
|
59734
|
+
var source = this.source;
|
|
59735
|
+
var otherSource = other.source;
|
|
59736
|
+
var baseEqual = source.type === otherSource.type &&
|
|
59737
|
+
source.url === otherSource.url
|
|
59738
|
+
&& ((source.tiles === undefined && otherSource.tiles === undefined) ||
|
|
59739
|
+
(source.tiles && otherSource.tiles && source.tiles.length === otherSource.tiles.length && source.tiles.every(function (value, idx) { return value === otherSource.tiles[idx]; })))
|
|
59740
|
+
&& source.minzoom === otherSource.minzoom
|
|
59741
|
+
&& source.maxzoom === otherSource.maxzoom
|
|
59742
|
+
&& source.bounds === otherSource.bounds
|
|
59743
|
+
&& source.attribution === otherSource.attribution;
|
|
59744
|
+
var rasterEqual = source.type !== "raster" || (source.type === "raster"
|
|
59745
|
+
&& source.type === otherSource.type
|
|
59746
|
+
&& source.tileSize === otherSource.tileSize
|
|
59747
|
+
&& source.scheme === otherSource.scheme);
|
|
59748
|
+
var rasterDemEqual = source.type !== "raster-dem" || (source.type === "raster-dem"
|
|
59749
|
+
&& source.type === otherSource.type
|
|
59750
|
+
&& source.tileSize === otherSource.tileSize
|
|
59751
|
+
&& source.encoding === otherSource.encoding);
|
|
59752
|
+
var vectorEqual = source.type !== "vector" || (source.type === "vector"
|
|
59753
|
+
&& source.type === otherSource.type
|
|
59754
|
+
&& source.promoteId === otherSource.promoteId
|
|
59755
|
+
&& source.scheme === otherSource.scheme);
|
|
59756
|
+
return baseEqual && rasterEqual && rasterDemEqual && vectorEqual;
|
|
59757
|
+
};
|
|
59758
|
+
/**
|
|
59759
|
+
* Updates the source info to convert the tiles to url strings.
|
|
59760
|
+
* @param sourceDef The original source info.
|
|
59761
|
+
* @param options The query parameters to add to the tile urls.
|
|
59762
|
+
*/
|
|
59763
|
+
FundamentalMapSource.prototype._modifySource = function (sourceDef, options) {
|
|
59764
|
+
if (sourceDef.tiles) {
|
|
59765
|
+
var tileStrings = sourceDef.tiles.map(function (tile) {
|
|
59766
|
+
if (typeof tile === "string") {
|
|
59767
|
+
return tile;
|
|
59768
|
+
}
|
|
59769
|
+
var tileUrl = new Url({
|
|
59770
|
+
domain: constants.domainPlaceHolder,
|
|
59771
|
+
path: tile.path,
|
|
59772
|
+
queryParams: __assign$3(__assign$3({}, options), tile.queryParams)
|
|
59773
|
+
});
|
|
59774
|
+
return tileUrl.toString();
|
|
59775
|
+
});
|
|
59776
|
+
sourceDef.tiles = tileStrings;
|
|
59777
|
+
}
|
|
59778
|
+
else if (sourceDef.url) {
|
|
59779
|
+
sourceDef.url = (typeof sourceDef.url === "string") ?
|
|
59780
|
+
sourceDef.url :
|
|
59781
|
+
new Url({
|
|
59782
|
+
domain: constants.domainPlaceHolder,
|
|
59783
|
+
path: sourceDef.url.path,
|
|
59784
|
+
queryParams: __assign$3(__assign$3({}, options), sourceDef.url.queryParams)
|
|
59785
|
+
}).toString();
|
|
59786
|
+
}
|
|
59787
|
+
else {
|
|
59788
|
+
throw new Error("Source definition must define a TileJSON 'url' or a 'tiles' array.");
|
|
59789
|
+
}
|
|
59790
|
+
return sourceDef;
|
|
59791
|
+
};
|
|
59792
|
+
return FundamentalMapSource;
|
|
59793
|
+
}(Source));
|
|
59794
|
+
|
|
59795
|
+
var __extends$O = (window && window.__extends) || (function () {
|
|
59397
59796
|
var extendStatics = function (d, b) {
|
|
59398
59797
|
extendStatics = Object.setPrototypeOf ||
|
|
59399
59798
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59412,7 +59811,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59412
59811
|
* Options used when rendering raster tiled images in a TileLayer.
|
|
59413
59812
|
*/
|
|
59414
59813
|
var TileLayerOptions = /** @class */ (function (_super) {
|
|
59415
|
-
__extends$
|
|
59814
|
+
__extends$O(TileLayerOptions, _super);
|
|
59416
59815
|
function TileLayerOptions() {
|
|
59417
59816
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
59418
59817
|
/**
|
|
@@ -59468,7 +59867,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59468
59867
|
return TileLayerOptions;
|
|
59469
59868
|
}(MediaLayerOptions));
|
|
59470
59869
|
|
|
59471
|
-
var __extends$
|
|
59870
|
+
var __extends$P = (window && window.__extends) || (function () {
|
|
59472
59871
|
var extendStatics = function (d, b) {
|
|
59473
59872
|
extendStatics = Object.setPrototypeOf ||
|
|
59474
59873
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59483,8 +59882,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
59483
59882
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
59484
59883
|
};
|
|
59485
59884
|
})();
|
|
59486
|
-
var __assign$
|
|
59487
|
-
__assign$
|
|
59885
|
+
var __assign$4 = (window && window.__assign) || function () {
|
|
59886
|
+
__assign$4 = Object.assign || function(t) {
|
|
59488
59887
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
59489
59888
|
s = arguments[i];
|
|
59490
59889
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
@@ -59492,7 +59891,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59492
59891
|
}
|
|
59493
59892
|
return t;
|
|
59494
59893
|
};
|
|
59495
|
-
return __assign$
|
|
59894
|
+
return __assign$4.apply(this, arguments);
|
|
59496
59895
|
};
|
|
59497
59896
|
var __values$8 = (window && window.__values) || function(o) {
|
|
59498
59897
|
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
@@ -59509,7 +59908,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59509
59908
|
* Renders raster tiled images on top of the map tiles.
|
|
59510
59909
|
*/
|
|
59511
59910
|
var TileLayer = /** @class */ (function (_super) {
|
|
59512
|
-
__extends$
|
|
59911
|
+
__extends$P(TileLayer, _super);
|
|
59513
59912
|
/**
|
|
59514
59913
|
* Constructs a new TileLayer.
|
|
59515
59914
|
* @param options The options for the tile layer.
|
|
@@ -59571,7 +59970,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59571
59970
|
* @internal
|
|
59572
59971
|
*/
|
|
59573
59972
|
TileLayer.prototype._buildLayers = function () {
|
|
59574
|
-
var layer = __assign$
|
|
59973
|
+
var layer = __assign$4(__assign$4({ id: this.id, type: "raster", source: this._getSourceId(), layout: {
|
|
59575
59974
|
visibility: this.options.visible ? "visible" : "none"
|
|
59576
59975
|
}, paint: {
|
|
59577
59976
|
"raster-contrast": this.options.contrast,
|
|
@@ -59640,7 +60039,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59640
60039
|
};
|
|
59641
60040
|
}
|
|
59642
60041
|
}
|
|
59643
|
-
return __assign$
|
|
60042
|
+
return __assign$4({ type: "raster", bounds: this.options.bounds, maxzoom: this.options.maxSourceZoom, minzoom: this.options.minSourceZoom, scheme: this.options.isTMS ? "tms" : "xyz", tileSize: this.options.tileSize }, (tiles && { tiles: tiles }));
|
|
59644
60043
|
};
|
|
59645
60044
|
/**
|
|
59646
60045
|
* Gets the id of the source to be paired with this layer.
|
|
@@ -59649,10 +60048,20 @@ uniform ${precision} ${type} u_${name};
|
|
|
59649
60048
|
TileLayer.prototype._getSourceId = function () {
|
|
59650
60049
|
return this.getId() + "-RasterSource";
|
|
59651
60050
|
};
|
|
60051
|
+
TileLayer.prototype._getSourceWrapper = function () {
|
|
60052
|
+
var sourceId = this._getSourceId();
|
|
60053
|
+
var source = this._buildSource();
|
|
60054
|
+
return new FundamentalMapSource(sourceId, {
|
|
60055
|
+
name: sourceId,
|
|
60056
|
+
tiles: source.tiles,
|
|
60057
|
+
type: source.type,
|
|
60058
|
+
url: source.url
|
|
60059
|
+
});
|
|
60060
|
+
};
|
|
59652
60061
|
return TileLayer;
|
|
59653
60062
|
}(SourceBuildingLayer));
|
|
59654
60063
|
|
|
59655
|
-
var __extends$
|
|
60064
|
+
var __extends$Q = (window && window.__extends) || (function () {
|
|
59656
60065
|
var extendStatics = function (d, b) {
|
|
59657
60066
|
extendStatics = Object.setPrototypeOf ||
|
|
59658
60067
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59671,7 +60080,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59671
60080
|
* Options used to render graphics in a WebGLLayer.
|
|
59672
60081
|
*/
|
|
59673
60082
|
var WebGLLayerOptions = /** @class */ (function (_super) {
|
|
59674
|
-
__extends$
|
|
60083
|
+
__extends$Q(WebGLLayerOptions, _super);
|
|
59675
60084
|
function WebGLLayerOptions() {
|
|
59676
60085
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
59677
60086
|
/**
|
|
@@ -59683,7 +60092,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59683
60092
|
return WebGLLayerOptions;
|
|
59684
60093
|
}(LayerOptions));
|
|
59685
60094
|
|
|
59686
|
-
var __extends$
|
|
60095
|
+
var __extends$R = (window && window.__extends) || (function () {
|
|
59687
60096
|
var extendStatics = function (d, b) {
|
|
59688
60097
|
extendStatics = Object.setPrototypeOf ||
|
|
59689
60098
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59702,7 +60111,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59702
60111
|
* Enables custom rendering logic with access to the WebGL context of the map.
|
|
59703
60112
|
*/
|
|
59704
60113
|
var WebGLLayer = /** @class */ (function (_super) {
|
|
59705
|
-
__extends$
|
|
60114
|
+
__extends$R(WebGLLayer, _super);
|
|
59706
60115
|
/**
|
|
59707
60116
|
* Constructs a new WebGLLayer.
|
|
59708
60117
|
* @param id The id of the layer. If not specified a random one will be generated.
|
|
@@ -59932,7 +60341,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59932
60341
|
|
|
59933
60342
|
var isElement_1 = isElement;
|
|
59934
60343
|
|
|
59935
|
-
var __extends$
|
|
60344
|
+
var __extends$S = (window && window.__extends) || (function () {
|
|
59936
60345
|
var extendStatics = function (d, b) {
|
|
59937
60346
|
extendStatics = Object.setPrototypeOf ||
|
|
59938
60347
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59951,7 +60360,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59951
60360
|
* The options for a popup.
|
|
59952
60361
|
*/
|
|
59953
60362
|
var PopupOptions = /** @class */ (function (_super) {
|
|
59954
|
-
__extends$
|
|
60363
|
+
__extends$S(PopupOptions, _super);
|
|
59955
60364
|
function PopupOptions() {
|
|
59956
60365
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
59957
60366
|
/**
|
|
@@ -60020,7 +60429,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
60020
60429
|
return PopupOptions;
|
|
60021
60430
|
}(Options));
|
|
60022
60431
|
|
|
60023
|
-
var __extends$
|
|
60432
|
+
var __extends$T = (window && window.__extends) || (function () {
|
|
60024
60433
|
var extendStatics = function (d, b) {
|
|
60025
60434
|
extendStatics = Object.setPrototypeOf ||
|
|
60026
60435
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -60055,7 +60464,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
60055
60464
|
* An information window anchored at a specified position on a map.
|
|
60056
60465
|
*/
|
|
60057
60466
|
var Popup = /** @class */ (function (_super) {
|
|
60058
|
-
__extends$
|
|
60467
|
+
__extends$T(Popup, _super);
|
|
60059
60468
|
/**
|
|
60060
60469
|
* Constructs a Popup object and initializes it with the specified options.
|
|
60061
60470
|
* @param options The options for the popup.
|
|
@@ -60526,7 +60935,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
60526
60935
|
return Popup;
|
|
60527
60936
|
}(EventEmitter));
|
|
60528
60937
|
|
|
60529
|
-
var __extends$
|
|
60938
|
+
var __extends$U = (window && window.__extends) || (function () {
|
|
60530
60939
|
var extendStatics = function (d, b) {
|
|
60531
60940
|
extendStatics = Object.setPrototypeOf ||
|
|
60532
60941
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -60545,7 +60954,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
60545
60954
|
* Options for rendering an HtmlMarker object
|
|
60546
60955
|
*/
|
|
60547
60956
|
var HtmlMarkerOptions = /** @class */ (function (_super) {
|
|
60548
|
-
__extends$
|
|
60957
|
+
__extends$U(HtmlMarkerOptions, _super);
|
|
60549
60958
|
function HtmlMarkerOptions() {
|
|
60550
60959
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
60551
60960
|
/**
|
|
@@ -60623,7 +61032,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
60623
61032
|
return HtmlMarkerOptions;
|
|
60624
61033
|
}(Options));
|
|
60625
61034
|
|
|
60626
|
-
var __extends$
|
|
61035
|
+
var __extends$V = (window && window.__extends) || (function () {
|
|
60627
61036
|
var extendStatics = function (d, b) {
|
|
60628
61037
|
extendStatics = Object.setPrototypeOf ||
|
|
60629
61038
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -60642,7 +61051,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
60642
61051
|
* This class wraps an HTML element that can be displayed on the map.
|
|
60643
61052
|
*/
|
|
60644
61053
|
var HtmlMarker = /** @class */ (function (_super) {
|
|
60645
|
-
__extends$
|
|
61054
|
+
__extends$V(HtmlMarker, _super);
|
|
60646
61055
|
/**
|
|
60647
61056
|
* Constructs a new HtmlMarker.
|
|
60648
61057
|
* @param options The options for the HtmlMarker.
|
|
@@ -61367,7 +61776,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61367
61776
|
return UserAgent;
|
|
61368
61777
|
}());
|
|
61369
61778
|
|
|
61370
|
-
var __extends$
|
|
61779
|
+
var __extends$W = (window && window.__extends) || (function () {
|
|
61371
61780
|
var extendStatics = function (d, b) {
|
|
61372
61781
|
extendStatics = Object.setPrototypeOf ||
|
|
61373
61782
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -61433,7 +61842,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61433
61842
|
* Options for specifying how the map control should authenticate with the Azure Maps services.
|
|
61434
61843
|
*/
|
|
61435
61844
|
var AuthenticationOptions = /** @class */ (function (_super) {
|
|
61436
|
-
__extends$
|
|
61845
|
+
__extends$W(AuthenticationOptions, _super);
|
|
61437
61846
|
function AuthenticationOptions() {
|
|
61438
61847
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
61439
61848
|
/**
|
|
@@ -62034,7 +62443,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62034
62443
|
return Media;
|
|
62035
62444
|
}());
|
|
62036
62445
|
|
|
62037
|
-
var __extends$
|
|
62446
|
+
var __extends$X = (window && window.__extends) || (function () {
|
|
62038
62447
|
var extendStatics = function (d, b) {
|
|
62039
62448
|
extendStatics = Object.setPrototypeOf ||
|
|
62040
62449
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -62053,7 +62462,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62053
62462
|
* The options for a CopyrightControl object.
|
|
62054
62463
|
*/
|
|
62055
62464
|
var CopyrightControlOptions = /** @class */ (function (_super) {
|
|
62056
|
-
__extends$
|
|
62465
|
+
__extends$X(CopyrightControlOptions, _super);
|
|
62057
62466
|
function CopyrightControlOptions() {
|
|
62058
62467
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
62059
62468
|
/**
|
|
@@ -62082,7 +62491,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62082
62491
|
return CopyrightControlOptions;
|
|
62083
62492
|
}(Options));
|
|
62084
62493
|
|
|
62085
|
-
var __extends$
|
|
62494
|
+
var __extends$Y = (window && window.__extends) || (function () {
|
|
62086
62495
|
var extendStatics = function (d, b) {
|
|
62087
62496
|
extendStatics = Object.setPrototypeOf ||
|
|
62088
62497
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -62101,7 +62510,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62101
62510
|
* @private
|
|
62102
62511
|
*/
|
|
62103
62512
|
var CopyrightControl = /** @class */ (function (_super) {
|
|
62104
|
-
__extends$
|
|
62513
|
+
__extends$Y(CopyrightControl, _super);
|
|
62105
62514
|
function CopyrightControl(options) {
|
|
62106
62515
|
var _this = _super.call(this) || this;
|
|
62107
62516
|
_this.textAttribution = function (options) {
|
|
@@ -62289,8 +62698,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
62289
62698
|
return ErrorHandler;
|
|
62290
62699
|
}());
|
|
62291
62700
|
|
|
62292
|
-
var __assign$
|
|
62293
|
-
__assign$
|
|
62701
|
+
var __assign$5 = (window && window.__assign) || function () {
|
|
62702
|
+
__assign$5 = Object.assign || function(t) {
|
|
62294
62703
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
62295
62704
|
s = arguments[i];
|
|
62296
62705
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
@@ -62298,7 +62707,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62298
62707
|
}
|
|
62299
62708
|
return t;
|
|
62300
62709
|
};
|
|
62301
|
-
return __assign$
|
|
62710
|
+
return __assign$5.apply(this, arguments);
|
|
62302
62711
|
};
|
|
62303
62712
|
/**
|
|
62304
62713
|
* @private
|
|
@@ -62313,7 +62722,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62313
62722
|
var urlOptions = {
|
|
62314
62723
|
domain: domain,
|
|
62315
62724
|
path: "search/address/reverse/json",
|
|
62316
|
-
queryParams: __assign$
|
|
62725
|
+
queryParams: __assign$5({ "api-version": "1.0", "language": options.style.language, "limit": 1, "query": normalizeLatitude(options.position[1]) + "," + normalizeLongitude(options.position[0]) }, (options.style.view && { view: options.style.view }))
|
|
62317
62726
|
};
|
|
62318
62727
|
return new Url(((_a = this.map.authentication) === null || _a === void 0 ? void 0 : _a.signRequest(urlOptions)) || urlOptions).get();
|
|
62319
62728
|
};
|
|
@@ -62391,11 +62800,11 @@ uniform ${precision} ${type} u_${name};
|
|
|
62391
62800
|
// Translations for oceans: https://en.wikipedia.org/wiki/List_of_alternative_names_for_oceans
|
|
62392
62801
|
this._preloadedCache.add(lang);
|
|
62393
62802
|
var oceanConfig = {
|
|
62394
|
-
source: [
|
|
62803
|
+
source: [],
|
|
62395
62804
|
labelType: "water",
|
|
62396
62805
|
minZoom: 0,
|
|
62397
62806
|
radius: 3950000,
|
|
62398
|
-
polygonSources: [
|
|
62807
|
+
polygonSources: [] // doesn't affect the cache key
|
|
62399
62808
|
};
|
|
62400
62809
|
var shortLang = lang;
|
|
62401
62810
|
var index = shortLang.indexOf("-");
|
|
@@ -62491,6 +62900,11 @@ uniform ${precision} ${type} u_${name};
|
|
|
62491
62900
|
}
|
|
62492
62901
|
return ar;
|
|
62493
62902
|
};
|
|
62903
|
+
var __spreadArray$2 = (window && window.__spreadArray) || function (to, from) {
|
|
62904
|
+
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
62905
|
+
to[j] = from[i];
|
|
62906
|
+
return to;
|
|
62907
|
+
};
|
|
62494
62908
|
/**
|
|
62495
62909
|
* This class analyizes the current view of a map and provides a description for use by accessibilty tools.
|
|
62496
62910
|
* TODO: Use services when in GeoPol regions. (Kasmir) or when user region sensitive.
|
|
@@ -62549,7 +62963,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62549
62963
|
* Vector Tile source layers: https://developer.tomtom.com/maps-api/maps-api-documentation-vector/tile
|
|
62550
62964
|
*/
|
|
62551
62965
|
// Configuration for label extraction.
|
|
62552
|
-
this.
|
|
62966
|
+
this._labelConfig = [
|
|
62553
62967
|
// Water labels
|
|
62554
62968
|
{
|
|
62555
62969
|
source: ["Ocean label", "Ocean name"],
|
|
@@ -62683,10 +63097,6 @@ uniform ${precision} ${type} u_${name};
|
|
|
62683
63097
|
polygonSources: ["Reservation"]
|
|
62684
63098
|
}
|
|
62685
63099
|
];
|
|
62686
|
-
// Name of all polygon layers in which we want to do an intersection test with.
|
|
62687
|
-
this._polygonStyleLayer = ["National or state park", "National park", "Reservation", "Airport",
|
|
62688
|
-
"Runway", "Stadium", "University", "Zoo", "Shopping", "Hospital", "Amusement park", "Ocean", "Sea",
|
|
62689
|
-
"Ocean or sea"];
|
|
62690
63100
|
// Name of all label types to cache.
|
|
62691
63101
|
this._labelCache = new Set(["city", "state", "country", "water", "majorPoi"]);
|
|
62692
63102
|
// Name of all road source layers.
|
|
@@ -62950,6 +63360,18 @@ uniform ${precision} ${type} u_${name};
|
|
|
62950
63360
|
_this._updateCam(true);
|
|
62951
63361
|
// Find the id of the vector tile source being used.
|
|
62952
63362
|
_this._baseVectorTileSourceId = MapViewDescriptor._baseVectorTileSourceIds.find(function (id) { return _this._map.sources.getById(id); });
|
|
63363
|
+
// Set the label config based on the vector tile source.
|
|
63364
|
+
if (_this._baseVectorTileSourceId === "bing-mvt") {
|
|
63365
|
+
_this._labelConfig = MapViewDescriptor._labelConfigBing;
|
|
63366
|
+
_this._roadLayers = MapViewDescriptor._roadLayersBing;
|
|
63367
|
+
}
|
|
63368
|
+
// Derive polygon layers from the label config.
|
|
63369
|
+
_this._polygonStyleLayer = _this._labelConfig.reduce(function (acc, cur) {
|
|
63370
|
+
if (cur.polygonSources) {
|
|
63371
|
+
acc.push.apply(acc, __spreadArray$2([], __read$6(cur.polygonSources)));
|
|
63372
|
+
}
|
|
63373
|
+
return acc;
|
|
63374
|
+
}, []);
|
|
62953
63375
|
// Add event listeners directly to mapbox because we will be using custom event data.
|
|
62954
63376
|
// We don't automatically forward all properties of a mapbox event, so the custom data would be lost.
|
|
62955
63377
|
var baseMap = _this._map._getMap();
|
|
@@ -63059,8 +63481,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
63059
63481
|
}
|
|
63060
63482
|
intersectingType_1 = null;
|
|
63061
63483
|
// Loop through each label config and try and retireve details about the map view.
|
|
63062
|
-
for (i = 0, cnt = this.
|
|
63063
|
-
layerInfo = this.
|
|
63484
|
+
for (i = 0, cnt = this._labelConfig.length; i < cnt; i++) {
|
|
63485
|
+
layerInfo = this._labelConfig[i];
|
|
63064
63486
|
if (cam.zoom >= layerInfo.minZoom) {
|
|
63065
63487
|
// If the layer info has polygons defined, do an intersection test for matching.
|
|
63066
63488
|
if (layerInfo.polygonSources) {
|
|
@@ -63160,7 +63582,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
63160
63582
|
// Loop through the label sources.
|
|
63161
63583
|
for (var i = 0, len = layerInfo.source.length; i < len; i++) {
|
|
63162
63584
|
var params = {
|
|
63163
|
-
sourceLayer: layerInfo.source[i]
|
|
63585
|
+
sourceLayer: layerInfo.source[i],
|
|
63586
|
+
filter: ["has", "name"]
|
|
63164
63587
|
};
|
|
63165
63588
|
var labels = this._map._getMap().querySourceFeatures(this._baseVectorTileSourceId, params);
|
|
63166
63589
|
var closest = null;
|
|
@@ -63237,21 +63660,22 @@ uniform ${precision} ${type} u_${name};
|
|
|
63237
63660
|
}
|
|
63238
63661
|
if (closestRoad) {
|
|
63239
63662
|
// Capture state and country codes from the closest road to ensure we have the most accurate values.
|
|
63240
|
-
|
|
63663
|
+
// Note: bing tiles do not have country_code and country_subdivision in road features.
|
|
63664
|
+
if (!info.country && closestRoad.properties.country_code) {
|
|
63241
63665
|
info.country = closestRoad.properties.country_code;
|
|
63242
63666
|
info.countryDis = 0;
|
|
63243
63667
|
MapViewDescriptor._labelCache.cache(info.country, {
|
|
63244
|
-
source: [
|
|
63668
|
+
source: [],
|
|
63245
63669
|
labelType: "country",
|
|
63246
63670
|
radius: 5000,
|
|
63247
63671
|
minZoom: 0
|
|
63248
63672
|
}, cPoint.geometry.coordinates, lang);
|
|
63249
63673
|
}
|
|
63250
|
-
if (!info.state) {
|
|
63674
|
+
if (!info.state && closestRoad.properties.country_subdivision) {
|
|
63251
63675
|
info.state = closestRoad.properties.country_subdivision;
|
|
63252
63676
|
info.stateDis = 0;
|
|
63253
63677
|
MapViewDescriptor._labelCache.cache(info.state, {
|
|
63254
|
-
source: [
|
|
63678
|
+
source: [],
|
|
63255
63679
|
labelType: "state",
|
|
63256
63680
|
radius: 5000,
|
|
63257
63681
|
minZoom: 4
|
|
@@ -63506,7 +63930,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63506
63930
|
if (a.country) {
|
|
63507
63931
|
info.country = a.country;
|
|
63508
63932
|
MapViewDescriptor._labelCache.cache(info.country, {
|
|
63509
|
-
source: [
|
|
63933
|
+
source: [],
|
|
63510
63934
|
labelType: "country",
|
|
63511
63935
|
radius: 5000,
|
|
63512
63936
|
minZoom: 0
|
|
@@ -63515,7 +63939,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63515
63939
|
if (a.countrySubdivision) {
|
|
63516
63940
|
info.state = a.countrySubdivision;
|
|
63517
63941
|
MapViewDescriptor._labelCache.cache(info.state, {
|
|
63518
|
-
source: [
|
|
63942
|
+
source: [],
|
|
63519
63943
|
labelType: "state",
|
|
63520
63944
|
radius: 5000,
|
|
63521
63945
|
minZoom: 4
|
|
@@ -63524,7 +63948,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63524
63948
|
if (a.municipality) {
|
|
63525
63949
|
info.city = a.municipality;
|
|
63526
63950
|
MapViewDescriptor._labelCache.cache(info.state, {
|
|
63527
|
-
source: [
|
|
63951
|
+
source: [],
|
|
63528
63952
|
labelType: "city",
|
|
63529
63953
|
radius: 1000,
|
|
63530
63954
|
minZoom: 10
|
|
@@ -63559,6 +63983,116 @@ uniform ${precision} ${type} u_${name};
|
|
|
63559
63983
|
};
|
|
63560
63984
|
// Ids of vector tile sources for different style APIs.
|
|
63561
63985
|
MapViewDescriptor._baseVectorTileSourceIds = ["microsoft.base", "vectorTiles", "bing-mvt"];
|
|
63986
|
+
// Configuration for label extraction of Bing tiles.
|
|
63987
|
+
MapViewDescriptor._labelConfigBing = [
|
|
63988
|
+
// Water labels
|
|
63989
|
+
{
|
|
63990
|
+
source: ["water_feature"],
|
|
63991
|
+
labelType: "water",
|
|
63992
|
+
minZoom: 0,
|
|
63993
|
+
radius: 3950000,
|
|
63994
|
+
polygonSources: ["generic_water_fill"]
|
|
63995
|
+
},
|
|
63996
|
+
{
|
|
63997
|
+
source: ["water_feature"],
|
|
63998
|
+
labelType: "water",
|
|
63999
|
+
minZoom: 3,
|
|
64000
|
+
radius: 1000000,
|
|
64001
|
+
polygonSources: ["generic_water_fill"]
|
|
64002
|
+
},
|
|
64003
|
+
// Country labels
|
|
64004
|
+
{
|
|
64005
|
+
source: ["country_region"],
|
|
64006
|
+
labelType: "country",
|
|
64007
|
+
minZoom: 0,
|
|
64008
|
+
maxZoom: 5,
|
|
64009
|
+
radius: 300000
|
|
64010
|
+
},
|
|
64011
|
+
// State labels
|
|
64012
|
+
{
|
|
64013
|
+
source: ["admin_division1"],
|
|
64014
|
+
labelType: "state",
|
|
64015
|
+
minZoom: 4,
|
|
64016
|
+
maxZoom: 7,
|
|
64017
|
+
radius: 300000
|
|
64018
|
+
},
|
|
64019
|
+
// City labels
|
|
64020
|
+
{
|
|
64021
|
+
source: ["populated_place"],
|
|
64022
|
+
labelType: "city",
|
|
64023
|
+
minZoom: 8,
|
|
64024
|
+
radius: 40000
|
|
64025
|
+
},
|
|
64026
|
+
// Neighbourhood labels
|
|
64027
|
+
{
|
|
64028
|
+
source: ["neighborhood"],
|
|
64029
|
+
labelType: "neighbourhood",
|
|
64030
|
+
minZoom: 12,
|
|
64031
|
+
radius: 6000
|
|
64032
|
+
},
|
|
64033
|
+
// POI labels
|
|
64034
|
+
{
|
|
64035
|
+
source: ["amusement_park"],
|
|
64036
|
+
labelType: "poi",
|
|
64037
|
+
minZoom: 14,
|
|
64038
|
+
radius: 2000,
|
|
64039
|
+
polygonSources: ["amusement_park_fill"]
|
|
64040
|
+
},
|
|
64041
|
+
{
|
|
64042
|
+
source: ["hospital"],
|
|
64043
|
+
labelType: "poi",
|
|
64044
|
+
minZoom: 14,
|
|
64045
|
+
radius: 1000,
|
|
64046
|
+
polygonSources: ["hospital_fill"]
|
|
64047
|
+
},
|
|
64048
|
+
{
|
|
64049
|
+
source: ["shopping_center"],
|
|
64050
|
+
labelType: "poi",
|
|
64051
|
+
minZoom: 14,
|
|
64052
|
+
radius: 1000,
|
|
64053
|
+
polygonSources: ["shopping_center_fill"]
|
|
64054
|
+
},
|
|
64055
|
+
{
|
|
64056
|
+
source: ["stadium"],
|
|
64057
|
+
labelType: "poi",
|
|
64058
|
+
minZoom: 14,
|
|
64059
|
+
radius: 1000,
|
|
64060
|
+
polygonSources: ["stadium_fill"]
|
|
64061
|
+
},
|
|
64062
|
+
{
|
|
64063
|
+
source: ["higher_education_facility", "school"],
|
|
64064
|
+
labelType: "poi",
|
|
64065
|
+
minZoom: 14,
|
|
64066
|
+
radius: 1000,
|
|
64067
|
+
polygonSources: ["higher_education_facility_fill", "school_fill"]
|
|
64068
|
+
},
|
|
64069
|
+
{
|
|
64070
|
+
source: ["zoo"],
|
|
64071
|
+
labelType: "poi",
|
|
64072
|
+
minZoom: 14,
|
|
64073
|
+
radius: 1000,
|
|
64074
|
+
polygonSources: ["zoo_fill"]
|
|
64075
|
+
},
|
|
64076
|
+
// Major Poi labels
|
|
64077
|
+
{
|
|
64078
|
+
source: ["airport", "airport_terminal"],
|
|
64079
|
+
labelType: "majorPoi",
|
|
64080
|
+
minZoom: 11,
|
|
64081
|
+
radius: 3000,
|
|
64082
|
+
polygonSources: ["airport_terminal_fill", "airport_fill-merged7", "airport_runway_fill"]
|
|
64083
|
+
},
|
|
64084
|
+
{
|
|
64085
|
+
source: ["reserve"],
|
|
64086
|
+
labelType: "majorPoi",
|
|
64087
|
+
minZoom: 7,
|
|
64088
|
+
radius: 15000,
|
|
64089
|
+
polygonSources: ["generic_reserve_fill", "land_cover_forest_fill"]
|
|
64090
|
+
}
|
|
64091
|
+
];
|
|
64092
|
+
// Name of all road source layers of Bing tiles.
|
|
64093
|
+
MapViewDescriptor._roadLayersBing = new Set([
|
|
64094
|
+
"road"
|
|
64095
|
+
]);
|
|
63562
64096
|
return MapViewDescriptor;
|
|
63563
64097
|
}());
|
|
63564
64098
|
|
|
@@ -63733,7 +64267,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63733
64267
|
return FlowServiceDelegate;
|
|
63734
64268
|
}());
|
|
63735
64269
|
|
|
63736
|
-
var __extends$
|
|
64270
|
+
var __extends$Z = (window && window.__extends) || (function () {
|
|
63737
64271
|
var extendStatics = function (d, b) {
|
|
63738
64272
|
extendStatics = Object.setPrototypeOf ||
|
|
63739
64273
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -63752,7 +64286,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63752
64286
|
* @private
|
|
63753
64287
|
*/
|
|
63754
64288
|
var Incident = /** @class */ (function (_super) {
|
|
63755
|
-
__extends$
|
|
64289
|
+
__extends$Z(Incident, _super);
|
|
63756
64290
|
function Incident(data, point, localizedStrings) {
|
|
63757
64291
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1;
|
|
63758
64292
|
var _this = this;
|
|
@@ -64247,7 +64781,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
64247
64781
|
return IncidentServiceDelegate;
|
|
64248
64782
|
}());
|
|
64249
64783
|
|
|
64250
|
-
var __extends$
|
|
64784
|
+
var __extends$_ = (window && window.__extends) || (function () {
|
|
64251
64785
|
var extendStatics = function (d, b) {
|
|
64252
64786
|
extendStatics = Object.setPrototypeOf ||
|
|
64253
64787
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -64266,7 +64800,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
64266
64800
|
* The options for enabling/disabling user interaction with the map.
|
|
64267
64801
|
*/
|
|
64268
64802
|
var UserInteractionOptions = /** @class */ (function (_super) {
|
|
64269
|
-
__extends$
|
|
64803
|
+
__extends$_(UserInteractionOptions, _super);
|
|
64270
64804
|
function UserInteractionOptions() {
|
|
64271
64805
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
64272
64806
|
/**
|
|
@@ -67317,7 +67851,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
67317
67851
|
}
|
|
67318
67852
|
return ar;
|
|
67319
67853
|
};
|
|
67320
|
-
var __spreadArray$
|
|
67854
|
+
var __spreadArray$3 = (window && window.__spreadArray) || function (to, from) {
|
|
67321
67855
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
67322
67856
|
to[j] = from[i];
|
|
67323
67857
|
return to;
|
|
@@ -67335,7 +67869,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
67335
67869
|
'data-azure-maps-attribution-order',
|
|
67336
67870
|
'data-azure-maps-attribution-dynamic'
|
|
67337
67871
|
];
|
|
67338
|
-
var allowedAttributionAttributes = __spreadArray$
|
|
67872
|
+
var allowedAttributionAttributes = __spreadArray$3([
|
|
67339
67873
|
'href'
|
|
67340
67874
|
], __read$7(attributionRuleAttributes));
|
|
67341
67875
|
var AttributionRuleProxy = /** @class */ (function () {
|
|
@@ -67560,7 +68094,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
67560
68094
|
};
|
|
67561
68095
|
AttributionRuleProxy.prototype.applyAttributionResponse = function (attributions) {
|
|
67562
68096
|
var _this = this;
|
|
67563
|
-
var copyrights = attributions.map(function (resp) { return resp.copyrights || []; }).reduce(function (flat, copyrights) { return __spreadArray$
|
|
68097
|
+
var copyrights = attributions.map(function (resp) { return resp.copyrights || []; }).reduce(function (flat, copyrights) { return __spreadArray$3(__spreadArray$3([], __read$7(flat)), __read$7(copyrights)); }, []);
|
|
67564
68098
|
if (copyrights.length == 0) {
|
|
67565
68099
|
// no attribution for a provided tileset/bbox/z
|
|
67566
68100
|
return;
|
|
@@ -67625,7 +68159,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
67625
68159
|
}
|
|
67626
68160
|
return ar;
|
|
67627
68161
|
};
|
|
67628
|
-
var __spreadArray$
|
|
68162
|
+
var __spreadArray$4 = (window && window.__spreadArray) || function (to, from) {
|
|
67629
68163
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
67630
68164
|
to[j] = from[i];
|
|
67631
68165
|
return to;
|
|
@@ -67746,10 +68280,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
67746
68280
|
}, function () { return document.createElement('span'); });
|
|
67747
68281
|
});
|
|
67748
68282
|
var registeredRuleSet = new Set(Object.values(registeredRules));
|
|
67749
|
-
var redundantRules = new Set(__spreadArray$
|
|
67750
|
-
var redundantElements = new Set(__spreadArray$
|
|
68283
|
+
var redundantRules = new Set(__spreadArray$4([], __read$8(allRules)).filter(function (rule) { return !registeredRuleSet.has(rule); }));
|
|
68284
|
+
var redundantElements = new Set(__spreadArray$4([], __read$8(redundantRules)).map(function (rule) { return rule.getElement(); }));
|
|
67751
68285
|
// eject redundant rules associated elements altogether
|
|
67752
|
-
__spreadArray$
|
|
68286
|
+
__spreadArray$4([], __read$8(redundantElements)).filter(function (elem) { return elem.parentElement !== null; })
|
|
67753
68287
|
.forEach(function (elem) { return elem.parentElement.removeChild(elem); });
|
|
67754
68288
|
_this.rules = Object.values(registeredRules);
|
|
67755
68289
|
var attributionsToApply = attributions
|
|
@@ -67785,7 +68319,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
67785
68319
|
var visibleTextNodes = function (elem) {
|
|
67786
68320
|
return Array.from(elem.style.display != 'none' ? elem.children : [])
|
|
67787
68321
|
.map(function (elem) { return visibleTextNodes(elem); })
|
|
67788
|
-
.reduce(function (flattened, nodes) { return __spreadArray$
|
|
68322
|
+
.reduce(function (flattened, nodes) { return __spreadArray$4(__spreadArray$4([], __read$8(flattened)), __read$8(nodes)); }, Array.from(elem.style.display != 'none' ? elem.childNodes : []).filter(function (node) { return node.nodeType == node.TEXT_NODE; }));
|
|
67789
68323
|
};
|
|
67790
68324
|
var newRenderContext = _this.virtualContext.cloneNode(true);
|
|
67791
68325
|
var visibleNodes = visibleTextNodes(newRenderContext);
|
|
@@ -67800,7 +68334,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
67800
68334
|
// }
|
|
67801
68335
|
// });
|
|
67802
68336
|
// strip all predefined keywords
|
|
67803
|
-
visibleNodes.forEach(function (node) { return node.textContent = __spreadArray$
|
|
68337
|
+
visibleNodes.forEach(function (node) { return node.textContent = __spreadArray$4([], __read$8(attributionFilters)).reduce(function (target, filter) { return target.replace(filter, '').trim(); }, node.textContent); });
|
|
67804
68338
|
// strip year from each node
|
|
67805
68339
|
// visibleNodes.forEach(node => node.textContent = node.textContent.replace(copyrightYearPattern, '').trim());
|
|
67806
68340
|
// deduplicate attribution text
|
|
@@ -67889,21 +68423,21 @@ uniform ${precision} ${type} u_${name};
|
|
|
67889
68423
|
return extendStatics(d, b);
|
|
67890
68424
|
};
|
|
67891
68425
|
|
|
67892
|
-
function __extends
|
|
68426
|
+
function __extends$$(d, b) {
|
|
67893
68427
|
extendStatics(d, b);
|
|
67894
68428
|
function __() { this.constructor = d; }
|
|
67895
68429
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
67896
68430
|
}
|
|
67897
68431
|
|
|
67898
|
-
var __assign$
|
|
67899
|
-
__assign$
|
|
68432
|
+
var __assign$6 = function() {
|
|
68433
|
+
__assign$6 = Object.assign || function __assign(t) {
|
|
67900
68434
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
67901
68435
|
s = arguments[i];
|
|
67902
68436
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
67903
68437
|
}
|
|
67904
68438
|
return t;
|
|
67905
68439
|
};
|
|
67906
|
-
return __assign$
|
|
68440
|
+
return __assign$6.apply(this, arguments);
|
|
67907
68441
|
};
|
|
67908
68442
|
|
|
67909
68443
|
function __rest(s, e) {
|
|
@@ -68003,21 +68537,21 @@ uniform ${precision} ${type} u_${name};
|
|
|
68003
68537
|
return extendStatics$1(d, b);
|
|
68004
68538
|
};
|
|
68005
68539
|
|
|
68006
|
-
function __extends$
|
|
68540
|
+
function __extends$10(d, b) {
|
|
68007
68541
|
extendStatics$1(d, b);
|
|
68008
68542
|
function __() { this.constructor = d; }
|
|
68009
68543
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
68010
68544
|
}
|
|
68011
68545
|
|
|
68012
|
-
var __assign$
|
|
68013
|
-
__assign$
|
|
68546
|
+
var __assign$7 = function() {
|
|
68547
|
+
__assign$7 = Object.assign || function __assign(t) {
|
|
68014
68548
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
68015
68549
|
s = arguments[i];
|
|
68016
68550
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
68017
68551
|
}
|
|
68018
68552
|
return t;
|
|
68019
68553
|
};
|
|
68020
|
-
return __assign$
|
|
68554
|
+
return __assign$7.apply(this, arguments);
|
|
68021
68555
|
};
|
|
68022
68556
|
|
|
68023
68557
|
function __awaiter$4(thisArg, _arguments, P, generator) {
|
|
@@ -68472,7 +69006,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
68472
69006
|
* General error class thrown by the MSAL.js library.
|
|
68473
69007
|
*/
|
|
68474
69008
|
var AuthError = /** @class */ (function (_super) {
|
|
68475
|
-
__extends$
|
|
69009
|
+
__extends$10(AuthError, _super);
|
|
68476
69010
|
function AuthError(errorCode, errorMessage, suberror) {
|
|
68477
69011
|
var _this = this;
|
|
68478
69012
|
var errorString = errorMessage ? errorCode + ": " + errorMessage : errorCode;
|
|
@@ -68790,7 +69324,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
68790
69324
|
* Error thrown when there is an error in the client code running on the browser.
|
|
68791
69325
|
*/
|
|
68792
69326
|
var ClientAuthError = /** @class */ (function (_super) {
|
|
68793
|
-
__extends$
|
|
69327
|
+
__extends$10(ClientAuthError, _super);
|
|
68794
69328
|
function ClientAuthError(errorCode, errorMessage) {
|
|
68795
69329
|
var _this = _super.call(this, errorCode, errorMessage) || this;
|
|
68796
69330
|
_this.name = "ClientAuthError";
|
|
@@ -69672,7 +70206,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
69672
70206
|
* Error thrown when there is an error in configuration of the MSAL.js library.
|
|
69673
70207
|
*/
|
|
69674
70208
|
var ClientConfigurationError = /** @class */ (function (_super) {
|
|
69675
|
-
__extends$
|
|
70209
|
+
__extends$10(ClientConfigurationError, _super);
|
|
69676
70210
|
function ClientConfigurationError(errorCode, errorMessage) {
|
|
69677
70211
|
var _this = _super.call(this, errorCode, errorMessage) || this;
|
|
69678
70212
|
_this.name = "ClientConfigurationError";
|
|
@@ -71127,7 +71661,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
71127
71661
|
return CacheManager;
|
|
71128
71662
|
}());
|
|
71129
71663
|
var DefaultStorageClass = /** @class */ (function (_super) {
|
|
71130
|
-
__extends$
|
|
71664
|
+
__extends$10(DefaultStorageClass, _super);
|
|
71131
71665
|
function DefaultStorageClass() {
|
|
71132
71666
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
71133
71667
|
}
|
|
@@ -71297,17 +71831,17 @@ uniform ${precision} ${type} u_${name};
|
|
|
71297
71831
|
*/
|
|
71298
71832
|
function buildClientConfiguration(_a) {
|
|
71299
71833
|
var userAuthOptions = _a.authOptions, userSystemOptions = _a.systemOptions, userLoggerOption = _a.loggerOptions, storageImplementation = _a.storageInterface, networkImplementation = _a.networkInterface, cryptoImplementation = _a.cryptoInterface, clientCredentials = _a.clientCredentials, libraryInfo = _a.libraryInfo, telemetry = _a.telemetry, serverTelemetryManager = _a.serverTelemetryManager, persistencePlugin = _a.persistencePlugin, serializableCache = _a.serializableCache;
|
|
71300
|
-
var loggerOptions = __assign$
|
|
71834
|
+
var loggerOptions = __assign$7(__assign$7({}, DEFAULT_LOGGER_IMPLEMENTATION), userLoggerOption);
|
|
71301
71835
|
return {
|
|
71302
71836
|
authOptions: buildAuthOptions(userAuthOptions),
|
|
71303
|
-
systemOptions: __assign$
|
|
71837
|
+
systemOptions: __assign$7(__assign$7({}, DEFAULT_SYSTEM_OPTIONS), userSystemOptions),
|
|
71304
71838
|
loggerOptions: loggerOptions,
|
|
71305
71839
|
storageInterface: storageImplementation || new DefaultStorageClass(userAuthOptions.clientId, DEFAULT_CRYPTO_IMPLEMENTATION),
|
|
71306
71840
|
networkInterface: networkImplementation || DEFAULT_NETWORK_IMPLEMENTATION,
|
|
71307
71841
|
cryptoInterface: cryptoImplementation || DEFAULT_CRYPTO_IMPLEMENTATION,
|
|
71308
71842
|
clientCredentials: clientCredentials || DEFAULT_CLIENT_CREDENTIALS,
|
|
71309
|
-
libraryInfo: __assign$
|
|
71310
|
-
telemetry: __assign$
|
|
71843
|
+
libraryInfo: __assign$7(__assign$7({}, DEFAULT_LIBRARY_INFO), libraryInfo),
|
|
71844
|
+
telemetry: __assign$7(__assign$7({}, DEFAULT_TELEMETRY_OPTIONS), telemetry),
|
|
71311
71845
|
serverTelemetryManager: serverTelemetryManager || null,
|
|
71312
71846
|
persistencePlugin: persistencePlugin || null,
|
|
71313
71847
|
serializableCache: serializableCache || null,
|
|
@@ -71318,7 +71852,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
71318
71852
|
* @param authOptions
|
|
71319
71853
|
*/
|
|
71320
71854
|
function buildAuthOptions(authOptions) {
|
|
71321
|
-
return __assign$
|
|
71855
|
+
return __assign$7({ clientCapabilities: [], azureCloudOptions: DEFAULT_AZURE_CLOUD_OPTIONS, skipAuthorityMetadataCache: false }, authOptions);
|
|
71322
71856
|
}
|
|
71323
71857
|
|
|
71324
71858
|
/*! @azure/msal-common v9.0.1 2022-12-07 */
|
|
@@ -71331,7 +71865,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
71331
71865
|
* Error thrown when there is an error with the server code, for example, unavailability.
|
|
71332
71866
|
*/
|
|
71333
71867
|
var ServerError = /** @class */ (function (_super) {
|
|
71334
|
-
__extends$
|
|
71868
|
+
__extends$10(ServerError, _super);
|
|
71335
71869
|
function ServerError(errorCode, errorMessage, subError) {
|
|
71336
71870
|
var _this = _super.call(this, errorCode, errorMessage, subError) || this;
|
|
71337
71871
|
_this.name = "ServerError";
|
|
@@ -72076,7 +72610,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
72076
72610
|
* }
|
|
72077
72611
|
*/
|
|
72078
72612
|
var IdTokenEntity = /** @class */ (function (_super) {
|
|
72079
|
-
__extends$
|
|
72613
|
+
__extends$10(IdTokenEntity, _super);
|
|
72080
72614
|
function IdTokenEntity() {
|
|
72081
72615
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
72082
72616
|
}
|
|
@@ -72197,7 +72731,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
72197
72731
|
* }
|
|
72198
72732
|
*/
|
|
72199
72733
|
var AccessTokenEntity = /** @class */ (function (_super) {
|
|
72200
|
-
__extends$
|
|
72734
|
+
__extends$10(AccessTokenEntity, _super);
|
|
72201
72735
|
function AccessTokenEntity() {
|
|
72202
72736
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
72203
72737
|
}
|
|
@@ -72306,7 +72840,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
72306
72840
|
* }
|
|
72307
72841
|
*/
|
|
72308
72842
|
var RefreshTokenEntity = /** @class */ (function (_super) {
|
|
72309
|
-
__extends$
|
|
72843
|
+
__extends$10(RefreshTokenEntity, _super);
|
|
72310
72844
|
function RefreshTokenEntity() {
|
|
72311
72845
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
72312
72846
|
}
|
|
@@ -72385,7 +72919,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
72385
72919
|
* Error thrown when user interaction is required.
|
|
72386
72920
|
*/
|
|
72387
72921
|
var InteractionRequiredAuthError = /** @class */ (function (_super) {
|
|
72388
|
-
__extends$
|
|
72922
|
+
__extends$10(InteractionRequiredAuthError, _super);
|
|
72389
72923
|
function InteractionRequiredAuthError(errorCode, errorMessage, subError) {
|
|
72390
72924
|
var _this = _super.call(this, errorCode, errorMessage, subError) || this;
|
|
72391
72925
|
_this.name = "InteractionRequiredAuthError";
|
|
@@ -72835,7 +73369,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
72835
73369
|
resourceRequestMethod = request.resourceRequestMethod, resourceRequestUri = request.resourceRequestUri, shrClaims = request.shrClaims, shrNonce = request.shrNonce;
|
|
72836
73370
|
resourceUrlString = (resourceRequestUri) ? new UrlString(resourceRequestUri) : undefined;
|
|
72837
73371
|
resourceUrlComponents = resourceUrlString === null || resourceUrlString === void 0 ? void 0 : resourceUrlString.getUrlComponents();
|
|
72838
|
-
return [4 /*yield*/, this.cryptoUtils.signJwt(__assign$
|
|
73372
|
+
return [4 /*yield*/, this.cryptoUtils.signJwt(__assign$7({ at: payload, ts: TimeUtils.nowSeconds(), m: resourceRequestMethod === null || resourceRequestMethod === void 0 ? void 0 : resourceRequestMethod.toUpperCase(), u: resourceUrlComponents === null || resourceUrlComponents === void 0 ? void 0 : resourceUrlComponents.HostNameAndPort, nonce: shrNonce || this.cryptoUtils.createNewGuid(), p: resourceUrlComponents === null || resourceUrlComponents === void 0 ? void 0 : resourceUrlComponents.AbsolutePath, q: (resourceUrlComponents === null || resourceUrlComponents === void 0 ? void 0 : resourceUrlComponents.QueryString) ? [[], resourceUrlComponents.QueryString] : undefined, client_claims: shrClaims || undefined }, claims), keyId, request.correlationId)];
|
|
72839
73373
|
case 1: return [2 /*return*/, _a.sent()];
|
|
72840
73374
|
}
|
|
72841
73375
|
});
|
|
@@ -73240,7 +73774,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
73240
73774
|
* Oauth2.0 Authorization Code client
|
|
73241
73775
|
*/
|
|
73242
73776
|
var AuthorizationCodeClient = /** @class */ (function (_super) {
|
|
73243
|
-
__extends$
|
|
73777
|
+
__extends$10(AuthorizationCodeClient, _super);
|
|
73244
73778
|
function AuthorizationCodeClient(configuration) {
|
|
73245
73779
|
var _this = _super.call(this, configuration) || this;
|
|
73246
73780
|
// Flag to indicate if client is for hybrid spa auth code redemption
|
|
@@ -73318,7 +73852,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
73318
73852
|
if (!serverParams.code) {
|
|
73319
73853
|
throw ClientAuthError.createNoAuthCodeInServerResponseError();
|
|
73320
73854
|
}
|
|
73321
|
-
return __assign$
|
|
73855
|
+
return __assign$7(__assign$7({}, serverParams), {
|
|
73322
73856
|
// Code param is optional in ServerAuthorizationCodeResponse but required in AuthorizationCodePaylod
|
|
73323
73857
|
code: serverParams.code });
|
|
73324
73858
|
};
|
|
@@ -73818,7 +74352,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
73818
74352
|
* OAuth2.0 refresh token client
|
|
73819
74353
|
*/
|
|
73820
74354
|
var RefreshTokenClient = /** @class */ (function (_super) {
|
|
73821
|
-
__extends$
|
|
74355
|
+
__extends$10(RefreshTokenClient, _super);
|
|
73822
74356
|
function RefreshTokenClient(configuration, performanceClient) {
|
|
73823
74357
|
return _super.call(this, configuration, performanceClient) || this;
|
|
73824
74358
|
}
|
|
@@ -73921,7 +74455,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
73921
74455
|
atsMeasurement === null || atsMeasurement === void 0 ? void 0 : atsMeasurement.endMeasurement({
|
|
73922
74456
|
success: true
|
|
73923
74457
|
});
|
|
73924
|
-
refreshTokenRequest = __assign$
|
|
74458
|
+
refreshTokenRequest = __assign$7(__assign$7({}, request), { refreshToken: refreshToken.secret, authenticationScheme: request.authenticationScheme || AuthenticationScheme.BEARER, ccsCredential: {
|
|
73925
74459
|
credential: request.account.homeAccountId,
|
|
73926
74460
|
type: CcsCredentialType.HOME_ACCOUNT_ID
|
|
73927
74461
|
} });
|
|
@@ -74080,7 +74614,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
74080
74614
|
* Licensed under the MIT License.
|
|
74081
74615
|
*/
|
|
74082
74616
|
var SilentFlowClient = /** @class */ (function (_super) {
|
|
74083
|
-
__extends$
|
|
74617
|
+
__extends$10(SilentFlowClient, _super);
|
|
74084
74618
|
function SilentFlowClient(configuration, performanceClient) {
|
|
74085
74619
|
return _super.call(this, configuration, performanceClient) || this;
|
|
74086
74620
|
}
|
|
@@ -75149,7 +75683,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
75149
75683
|
hostNameAndPort = region + "." + Constants.REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX;
|
|
75150
75684
|
}
|
|
75151
75685
|
// Include the query string portion of the url
|
|
75152
|
-
var url = UrlString.constructAuthorityUriFromObject(__assign$
|
|
75686
|
+
var url = UrlString.constructAuthorityUriFromObject(__assign$7(__assign$7({}, authorityUrlInstance.getUrlComponents()), { HostNameAndPort: hostNameAndPort })).urlString;
|
|
75153
75687
|
// Add the query string if a query string was provided
|
|
75154
75688
|
if (queryString)
|
|
75155
75689
|
return url + "?" + queryString;
|
|
@@ -75333,7 +75867,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
75333
75867
|
* Error thrown when there is an error in the client code running on the browser.
|
|
75334
75868
|
*/
|
|
75335
75869
|
var JoseHeaderError = /** @class */ (function (_super) {
|
|
75336
|
-
__extends$
|
|
75870
|
+
__extends$10(JoseHeaderError, _super);
|
|
75337
75871
|
function JoseHeaderError(errorCode, errorMessage) {
|
|
75338
75872
|
var _this = _super.call(this, errorCode, errorMessage) || this;
|
|
75339
75873
|
_this.name = "JoseHeaderError";
|
|
@@ -75627,7 +76161,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
75627
76161
|
// Return the event and functions the caller can use to properly end/flush the measurement
|
|
75628
76162
|
return {
|
|
75629
76163
|
endMeasurement: function (event) {
|
|
75630
|
-
var completedEvent = _this.endMeasurement(__assign$
|
|
76164
|
+
var completedEvent = _this.endMeasurement(__assign$7(__assign$7({}, inProgressEvent), event));
|
|
75631
76165
|
if (completedEvent) {
|
|
75632
76166
|
// Cache event so that submeasurements can be added downstream
|
|
75633
76167
|
_this.cacheEventByCorrelationId(completedEvent);
|
|
@@ -75664,7 +76198,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
75664
76198
|
// null indicates no measurement was taken (e.g. needed performance APIs not present)
|
|
75665
76199
|
if (durationMs !== null) {
|
|
75666
76200
|
this.logger.trace("PerformanceClient: Performance measurement ended for " + event.name + ": " + durationMs + " ms", event.correlationId);
|
|
75667
|
-
var completedEvent = __assign$
|
|
76201
|
+
var completedEvent = __assign$7(__assign$7({
|
|
75668
76202
|
// Allow duration to be overwritten when event ends (e.g. testing), but not status
|
|
75669
76203
|
durationMs: Math.round(durationMs) }, event), { status: PerformanceEventStatus.Completed });
|
|
75670
76204
|
return completedEvent;
|
|
@@ -75687,7 +76221,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
75687
76221
|
var existingStaticFields = this.staticFieldsByCorrelationId.get(correlationId);
|
|
75688
76222
|
if (existingStaticFields) {
|
|
75689
76223
|
this.logger.trace("PerformanceClient: Updating static fields");
|
|
75690
|
-
this.staticFieldsByCorrelationId.set(correlationId, __assign$
|
|
76224
|
+
this.staticFieldsByCorrelationId.set(correlationId, __assign$7(__assign$7({}, existingStaticFields), fields));
|
|
75691
76225
|
}
|
|
75692
76226
|
else {
|
|
75693
76227
|
this.logger.trace("PerformanceClient: Adding static fields");
|
|
@@ -75787,7 +76321,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
75787
76321
|
return previous;
|
|
75788
76322
|
}, topLevelEvent);
|
|
75789
76323
|
var staticFields = this.staticFieldsByCorrelationId.get(correlationId);
|
|
75790
|
-
var finalEvent = __assign$
|
|
76324
|
+
var finalEvent = __assign$7(__assign$7({}, eventToEmit), staticFields);
|
|
75791
76325
|
this.emitEvents([finalEvent], eventToEmit.correlationId);
|
|
75792
76326
|
}
|
|
75793
76327
|
else {
|
|
@@ -75871,7 +76405,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
75871
76405
|
return StubPerformanceMeasurement;
|
|
75872
76406
|
}());
|
|
75873
76407
|
var StubPerformanceClient = /** @class */ (function (_super) {
|
|
75874
|
-
__extends$
|
|
76408
|
+
__extends$10(StubPerformanceClient, _super);
|
|
75875
76409
|
function StubPerformanceClient() {
|
|
75876
76410
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
75877
76411
|
}
|
|
@@ -76075,7 +76609,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
76075
76609
|
* Browser library error class thrown by the MSAL.js library for SPAs
|
|
76076
76610
|
*/
|
|
76077
76611
|
var BrowserAuthError = /** @class */ (function (_super) {
|
|
76078
|
-
__extends
|
|
76612
|
+
__extends$$(BrowserAuthError, _super);
|
|
76079
76613
|
function BrowserAuthError(errorCode, errorMessage) {
|
|
76080
76614
|
var _this = _super.call(this, errorCode, errorMessage) || this;
|
|
76081
76615
|
Object.setPrototypeOf(_this, BrowserAuthError.prototype);
|
|
@@ -76622,7 +77156,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
76622
77156
|
* Browser library error class thrown by the MSAL.js library for SPAs
|
|
76623
77157
|
*/
|
|
76624
77158
|
var BrowserConfigurationAuthError = /** @class */ (function (_super) {
|
|
76625
|
-
__extends
|
|
77159
|
+
__extends$$(BrowserConfigurationAuthError, _super);
|
|
76626
77160
|
function BrowserConfigurationAuthError(errorCode, errorMessage) {
|
|
76627
77161
|
var _this = _super.call(this, errorCode, errorMessage) || this;
|
|
76628
77162
|
_this.name = "BrowserConfigurationAuthError";
|
|
@@ -76799,7 +77333,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
76799
77333
|
* parameters such as state and nonce, generally.
|
|
76800
77334
|
*/
|
|
76801
77335
|
var BrowserCacheManager = /** @class */ (function (_super) {
|
|
76802
|
-
__extends
|
|
77336
|
+
__extends$$(BrowserCacheManager, _super);
|
|
76803
77337
|
function BrowserCacheManager(clientId, cacheConfig, cryptoImpl, logger) {
|
|
76804
77338
|
var _this = _super.call(this, clientId, cryptoImpl) || this;
|
|
76805
77339
|
// Cookie life calculation (hours * minutes * seconds * ms)
|
|
@@ -78236,7 +78770,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
78236
78770
|
this.logger.verbose("Initializing BaseAuthRequest");
|
|
78237
78771
|
authority = request.authority || this.config.auth.authority;
|
|
78238
78772
|
scopes = __spread(((request && request.scopes) || []));
|
|
78239
|
-
validatedRequest = __assign$
|
|
78773
|
+
validatedRequest = __assign$6(__assign$6({}, request), { correlationId: this.correlationId, authority: authority,
|
|
78240
78774
|
scopes: scopes });
|
|
78241
78775
|
// Set authenticationScheme to BEARER if not explicitly set in the request
|
|
78242
78776
|
if (!validatedRequest.authenticationScheme) {
|
|
@@ -78338,7 +78872,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
78338
78872
|
* Defines the class structure and helper functions used by the "standard", non-brokered auth flows (popup, redirect, silent (RT), silent (iframe))
|
|
78339
78873
|
*/
|
|
78340
78874
|
var StandardInteractionClient = /** @class */ (function (_super) {
|
|
78341
|
-
__extends
|
|
78875
|
+
__extends$$(StandardInteractionClient, _super);
|
|
78342
78876
|
function StandardInteractionClient() {
|
|
78343
78877
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
78344
78878
|
}
|
|
@@ -78356,7 +78890,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
78356
78890
|
return [4 /*yield*/, this.browserCrypto.generatePkceCodes()];
|
|
78357
78891
|
case 1:
|
|
78358
78892
|
generatedPkceParams = _a.sent();
|
|
78359
|
-
authCodeRequest = __assign$
|
|
78893
|
+
authCodeRequest = __assign$6(__assign$6({}, request), { redirectUri: request.redirectUri, code: Constants.EMPTY_STRING, codeVerifier: generatedPkceParams.verifier });
|
|
78360
78894
|
request.codeChallenge = generatedPkceParams.challenge;
|
|
78361
78895
|
request.codeChallengeMethod = Constants.S256_CODE_CHALLENGE_METHOD;
|
|
78362
78896
|
return [2 /*return*/, authCodeRequest];
|
|
@@ -78370,7 +78904,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
78370
78904
|
*/
|
|
78371
78905
|
StandardInteractionClient.prototype.initializeLogoutRequest = function (logoutRequest) {
|
|
78372
78906
|
this.logger.verbose("initializeLogoutRequest called", logoutRequest === null || logoutRequest === void 0 ? void 0 : logoutRequest.correlationId);
|
|
78373
|
-
var validLogoutRequest = __assign$
|
|
78907
|
+
var validLogoutRequest = __assign$6({ correlationId: this.correlationId || this.browserCrypto.createNewGuid() }, logoutRequest);
|
|
78374
78908
|
/**
|
|
78375
78909
|
* Set logout_hint to be login_hint from ID Token Claims if present
|
|
78376
78910
|
* and logoutHint attribute wasn't manually set in logout request
|
|
@@ -78590,7 +79124,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
78590
79124
|
_a = [{}];
|
|
78591
79125
|
return [4 /*yield*/, this.initializeBaseRequest(request)];
|
|
78592
79126
|
case 1:
|
|
78593
|
-
validatedRequest = __assign$
|
|
79127
|
+
validatedRequest = __assign$6.apply(void 0, [__assign$6.apply(void 0, _a.concat([_b.sent()])), { redirectUri: redirectUri, state: state, nonce: request.nonce || this.browserCrypto.createNewGuid(), responseMode: ResponseMode.FRAGMENT }]);
|
|
78594
79128
|
account = request.account || this.browserStorage.getActiveAccount();
|
|
78595
79129
|
if (account) {
|
|
78596
79130
|
this.logger.verbose("Setting validated request account", this.correlationId);
|
|
@@ -78766,7 +79300,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
78766
79300
|
* Licensed under the MIT License.
|
|
78767
79301
|
*/
|
|
78768
79302
|
var RedirectHandler = /** @class */ (function (_super) {
|
|
78769
|
-
__extends
|
|
79303
|
+
__extends$$(RedirectHandler, _super);
|
|
78770
79304
|
function RedirectHandler(authCodeModule, storageImpl, authCodeRequest, logger, browserCrypto) {
|
|
78771
79305
|
var _this = _super.call(this, authCodeModule, storageImpl, authCodeRequest, logger) || this;
|
|
78772
79306
|
_this.browserCrypto = browserCrypto;
|
|
@@ -78959,7 +79493,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
78959
79493
|
}
|
|
78960
79494
|
};
|
|
78961
79495
|
var NativeAuthError = /** @class */ (function (_super) {
|
|
78962
|
-
__extends
|
|
79496
|
+
__extends$$(NativeAuthError, _super);
|
|
78963
79497
|
function NativeAuthError(errorCode, description, ext) {
|
|
78964
79498
|
var _this = _super.call(this, errorCode, description) || this;
|
|
78965
79499
|
Object.setPrototypeOf(_this, NativeAuthError.prototype);
|
|
@@ -79027,7 +79561,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
79027
79561
|
* Licensed under the MIT License.
|
|
79028
79562
|
*/
|
|
79029
79563
|
var SilentCacheClient = /** @class */ (function (_super) {
|
|
79030
|
-
__extends
|
|
79564
|
+
__extends$$(SilentCacheClient, _super);
|
|
79031
79565
|
function SilentCacheClient() {
|
|
79032
79566
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
79033
79567
|
}
|
|
@@ -79105,9 +79639,9 @@ uniform ${precision} ${type} u_${name};
|
|
|
79105
79639
|
return __generator$3(this, function (_b) {
|
|
79106
79640
|
switch (_b.label) {
|
|
79107
79641
|
case 0:
|
|
79108
|
-
_a = [__assign$
|
|
79642
|
+
_a = [__assign$6({}, request)];
|
|
79109
79643
|
return [4 /*yield*/, this.initializeBaseRequest(request)];
|
|
79110
|
-
case 1: return [2 /*return*/, __assign$
|
|
79644
|
+
case 1: return [2 /*return*/, __assign$6.apply(void 0, [__assign$6.apply(void 0, _a.concat([_b.sent()])), { account: account, forceRefresh: request.forceRefresh || false }])];
|
|
79111
79645
|
}
|
|
79112
79646
|
});
|
|
79113
79647
|
});
|
|
@@ -79122,7 +79656,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
79122
79656
|
* Licensed under the MIT License.
|
|
79123
79657
|
*/
|
|
79124
79658
|
var NativeInteractionClient = /** @class */ (function (_super) {
|
|
79125
|
-
__extends
|
|
79659
|
+
__extends$$(NativeInteractionClient, _super);
|
|
79126
79660
|
function NativeInteractionClient(config, browserStorage, browserCrypto, logger, eventHandler, navigationClient, apiId, performanceClient, provider, accountId, nativeStorageImpl, correlationId) {
|
|
79127
79661
|
var _this = _super.call(this, config, browserStorage, browserCrypto, logger, eventHandler, navigationClient, performanceClient, provider, correlationId) || this;
|
|
79128
79662
|
_this.apiId = apiId;
|
|
@@ -79560,7 +80094,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
79560
80094
|
throw BrowserAuthError.createNativePromptParameterNotSupportedError();
|
|
79561
80095
|
}
|
|
79562
80096
|
};
|
|
79563
|
-
validatedRequest = __assign$
|
|
80097
|
+
validatedRequest = __assign$6(__assign$6({}, remainingProperties), { accountId: this.accountId, clientId: this.config.auth.clientId, authority: canonicalAuthority.urlString, scope: scopeSet.printScopes(), redirectUri: this.getRedirectUri(request.redirectUri), prompt: getPrompt(), correlationId: this.correlationId, tokenType: request.authenticationScheme, windowTitleSubstring: document.title, extraParameters: __assign$6(__assign$6(__assign$6({}, request.extraQueryParameters), request.tokenQueryParameters), { telemetry: NativeConstants.MATS_TELEMETRY }), extendedExpiryToken: false // Make this configurable?
|
|
79564
80098
|
});
|
|
79565
80099
|
if (!(request.authenticationScheme === AuthenticationScheme.POP)) return [3 /*break*/, 2];
|
|
79566
80100
|
shrParameters = {
|
|
@@ -79845,7 +80379,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
79845
80379
|
* Licensed under the MIT License.
|
|
79846
80380
|
*/
|
|
79847
80381
|
var RedirectClient = /** @class */ (function (_super) {
|
|
79848
|
-
__extends
|
|
80382
|
+
__extends$$(RedirectClient, _super);
|
|
79849
80383
|
function RedirectClient(config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, performanceClient, nativeStorageImpl, nativeMessageHandler, correlationId) {
|
|
79850
80384
|
var _this = _super.call(this, config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, performanceClient, nativeMessageHandler, correlationId) || this;
|
|
79851
80385
|
_this.nativeStorage = nativeStorageImpl;
|
|
@@ -79884,7 +80418,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
79884
80418
|
authClient = _a.sent();
|
|
79885
80419
|
this.logger.verbose("Auth code client created");
|
|
79886
80420
|
interactionHandler = new RedirectHandler(authClient, this.browserStorage, authCodeRequest, this.logger, this.browserCrypto);
|
|
79887
|
-
return [4 /*yield*/, authClient.getAuthCodeUrl(__assign$
|
|
80421
|
+
return [4 /*yield*/, authClient.getAuthCodeUrl(__assign$6(__assign$6({}, validRequest), { nativeBroker: NativeMessageHandler.isNativeAvailable(this.config, this.logger, this.nativeMessageHandler, request.authenticationScheme) }))];
|
|
79888
80422
|
case 5:
|
|
79889
80423
|
navigateUrl = _a.sent();
|
|
79890
80424
|
redirectStartPage = this.getRedirectStartPage(request.redirectStartPage);
|
|
@@ -80060,7 +80594,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80060
80594
|
}
|
|
80061
80595
|
nativeInteractionClient = new NativeInteractionClient(this.config, this.browserStorage, this.browserCrypto, this.logger, this.eventHandler, this.navigationClient, ApiId.acquireTokenPopup, this.performanceClient, this.nativeMessageHandler, serverParams.accountId, this.browserStorage, cachedRequest.correlationId);
|
|
80062
80596
|
userRequestState = ProtocolUtils.parseRequestState(this.browserCrypto, state).userRequestState;
|
|
80063
|
-
return [2 /*return*/, nativeInteractionClient.acquireToken(__assign$
|
|
80597
|
+
return [2 /*return*/, nativeInteractionClient.acquireToken(__assign$6(__assign$6({}, cachedRequest), { state: userRequestState, prompt: undefined // Server should handle the prompt, ideally native broker can do this part silently
|
|
80064
80598
|
})).finally(function () {
|
|
80065
80599
|
_this.browserStorage.cleanRequestByState(state);
|
|
80066
80600
|
})];
|
|
@@ -80177,7 +80711,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80177
80711
|
* Licensed under the MIT License.
|
|
80178
80712
|
*/
|
|
80179
80713
|
var PopupClient = /** @class */ (function (_super) {
|
|
80180
|
-
__extends
|
|
80714
|
+
__extends$$(PopupClient, _super);
|
|
80181
80715
|
function PopupClient(config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, performanceClient, nativeStorageImpl, nativeMessageHandler, correlationId) {
|
|
80182
80716
|
var _this = _super.call(this, config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, performanceClient, nativeMessageHandler, correlationId) || this;
|
|
80183
80717
|
// Properly sets this reference for the unload event.
|
|
@@ -80277,7 +80811,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80277
80811
|
if (isNativeBroker) {
|
|
80278
80812
|
fetchNativeAccountIdMeasurement = this.performanceClient.startMeasurement(PerformanceEvents.FetchAccountIdWithNativeBroker, request.correlationId);
|
|
80279
80813
|
}
|
|
80280
|
-
return [4 /*yield*/, authClient.getAuthCodeUrl(__assign$
|
|
80814
|
+
return [4 /*yield*/, authClient.getAuthCodeUrl(__assign$6(__assign$6({}, validRequest), { nativeBroker: isNativeBroker }))];
|
|
80281
80815
|
case 5:
|
|
80282
80816
|
navigateUrl = _a.sent();
|
|
80283
80817
|
interactionHandler = new InteractionHandler(authClient, this.browserStorage, authCodeRequest, this.logger);
|
|
@@ -80309,7 +80843,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80309
80843
|
}
|
|
80310
80844
|
nativeInteractionClient = new NativeInteractionClient(this.config, this.browserStorage, this.browserCrypto, this.logger, this.eventHandler, this.navigationClient, ApiId.acquireTokenPopup, this.performanceClient, this.nativeMessageHandler, serverParams.accountId, this.nativeStorage, validRequest.correlationId);
|
|
80311
80845
|
userRequestState = ProtocolUtils.parseRequestState(this.browserCrypto, state_1).userRequestState;
|
|
80312
|
-
return [2 /*return*/, nativeInteractionClient.acquireToken(__assign$
|
|
80846
|
+
return [2 /*return*/, nativeInteractionClient.acquireToken(__assign$6(__assign$6({}, validRequest), { state: userRequestState, prompt: undefined // Server should handle the prompt, ideally native broker can do this part silently
|
|
80313
80847
|
})).finally(function () {
|
|
80314
80848
|
_this.browserStorage.cleanRequestByState(state_1);
|
|
80315
80849
|
})];
|
|
@@ -80762,7 +81296,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80762
81296
|
piiLoggingEnabled: false
|
|
80763
81297
|
};
|
|
80764
81298
|
// Default system options for browser
|
|
80765
|
-
var DEFAULT_BROWSER_SYSTEM_OPTIONS = __assign$
|
|
81299
|
+
var DEFAULT_BROWSER_SYSTEM_OPTIONS = __assign$6(__assign$6({}, DEFAULT_SYSTEM_OPTIONS), { loggerOptions: DEFAULT_LOGGER_OPTIONS, networkClient: isBrowserEnvironment ? BrowserUtils.getBrowserNetworkClient() : StubbedNetworkModule, navigationClient: new NavigationClient(), loadFrameTimeout: 0,
|
|
80766
81300
|
// If loadFrameTimeout is provided, use that as default.
|
|
80767
81301
|
windowHashTimeout: (userInputSystem === null || userInputSystem === void 0 ? void 0 : userInputSystem.loadFrameTimeout) || DEFAULT_POPUP_TIMEOUT_MS, iframeHashTimeout: (userInputSystem === null || userInputSystem === void 0 ? void 0 : userInputSystem.loadFrameTimeout) || DEFAULT_IFRAME_TIMEOUT_MS, navigateFrameWait: isBrowserEnvironment && BrowserUtils.detectIEOrEdge() ? 500 : 0, redirectNavigationTimeout: DEFAULT_REDIRECT_TIMEOUT_MS, asyncPopups: false, allowRedirectInIframe: false, allowNativeBroker: false, nativeBrokerHandshakeTimeout: (userInputSystem === null || userInputSystem === void 0 ? void 0 : userInputSystem.nativeBrokerHandshakeTimeout) || DEFAULT_NATIVE_BROKER_HANDSHAKE_TIMEOUT_MS, pollIntervalMilliseconds: BrowserConstants.DEFAULT_POLL_INTERVAL_MS, cryptoOptions: {
|
|
80768
81302
|
useMsrCrypto: false,
|
|
@@ -80775,10 +81309,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
80775
81309
|
}
|
|
80776
81310
|
};
|
|
80777
81311
|
var overlayedConfig = {
|
|
80778
|
-
auth: __assign$
|
|
80779
|
-
cache: __assign$
|
|
80780
|
-
system: __assign$
|
|
80781
|
-
telemetry: __assign$
|
|
81312
|
+
auth: __assign$6(__assign$6({}, DEFAULT_AUTH_OPTIONS), userInputAuth),
|
|
81313
|
+
cache: __assign$6(__assign$6({}, DEFAULT_CACHE_OPTIONS), userInputCache),
|
|
81314
|
+
system: __assign$6(__assign$6({}, DEFAULT_BROWSER_SYSTEM_OPTIONS), userInputSystem),
|
|
81315
|
+
telemetry: __assign$6(__assign$6({}, DEFAULT_TELEMETRY_OPTIONS), userInputTelemetry)
|
|
80782
81316
|
};
|
|
80783
81317
|
return overlayedConfig;
|
|
80784
81318
|
}
|
|
@@ -80790,7 +81324,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80790
81324
|
* Licensed under the MIT License.
|
|
80791
81325
|
*/
|
|
80792
81326
|
var SilentHandler = /** @class */ (function (_super) {
|
|
80793
|
-
__extends
|
|
81327
|
+
__extends$$(SilentHandler, _super);
|
|
80794
81328
|
function SilentHandler(authCodeModule, storageImpl, authCodeRequest, logger, systemOptions) {
|
|
80795
81329
|
var _this = _super.call(this, authCodeModule, storageImpl, authCodeRequest, logger) || this;
|
|
80796
81330
|
_this.navigateFrameWait = systemOptions.navigateFrameWait;
|
|
@@ -80945,7 +81479,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80945
81479
|
* Licensed under the MIT License.
|
|
80946
81480
|
*/
|
|
80947
81481
|
var SilentIframeClient = /** @class */ (function (_super) {
|
|
80948
|
-
__extends
|
|
81482
|
+
__extends$$(SilentIframeClient, _super);
|
|
80949
81483
|
function SilentIframeClient(config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, apiId, performanceClient, nativeStorageImpl, nativeMessageHandler, correlationId) {
|
|
80950
81484
|
var _this = _super.call(this, config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, performanceClient, nativeMessageHandler, correlationId) || this;
|
|
80951
81485
|
_this.apiId = apiId;
|
|
@@ -80975,7 +81509,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
80975
81509
|
});
|
|
80976
81510
|
throw BrowserAuthError.createSilentPromptValueError(request.prompt);
|
|
80977
81511
|
}
|
|
80978
|
-
return [4 /*yield*/, this.initializeAuthorizationRequest(__assign$
|
|
81512
|
+
return [4 /*yield*/, this.initializeAuthorizationRequest(__assign$6(__assign$6({}, request), { prompt: request.prompt || PromptValue.NONE }), InteractionType.Silent)];
|
|
80979
81513
|
case 1:
|
|
80980
81514
|
silentRequest = _a.sent();
|
|
80981
81515
|
this.browserStorage.updateCacheEntries(silentRequest.state, silentRequest.nonce, silentRequest.authority, silentRequest.loginHint || Constants.EMPTY_STRING, silentRequest.account || null);
|
|
@@ -81036,7 +81570,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
81036
81570
|
case 0: return [4 /*yield*/, this.initializeAuthorizationCodeRequest(silentRequest)];
|
|
81037
81571
|
case 1:
|
|
81038
81572
|
authCodeRequest = _a.sent();
|
|
81039
|
-
return [4 /*yield*/, authClient.getAuthCodeUrl(__assign$
|
|
81573
|
+
return [4 /*yield*/, authClient.getAuthCodeUrl(__assign$6(__assign$6({}, silentRequest), { nativeBroker: NativeMessageHandler.isNativeAvailable(this.config, this.logger, this.nativeMessageHandler, silentRequest.authenticationScheme) }))];
|
|
81040
81574
|
case 2:
|
|
81041
81575
|
navigateUrl = _a.sent();
|
|
81042
81576
|
silentHandler = new SilentHandler(authClient, this.browserStorage, authCodeRequest, this.logger, this.config.system);
|
|
@@ -81055,7 +81589,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
81055
81589
|
}
|
|
81056
81590
|
nativeInteractionClient = new NativeInteractionClient(this.config, this.browserStorage, this.browserCrypto, this.logger, this.eventHandler, this.navigationClient, this.apiId, this.performanceClient, this.nativeMessageHandler, serverParams.accountId, this.browserStorage, this.correlationId);
|
|
81057
81591
|
userRequestState = ProtocolUtils.parseRequestState(this.browserCrypto, state).userRequestState;
|
|
81058
|
-
return [2 /*return*/, nativeInteractionClient.acquireToken(__assign$
|
|
81592
|
+
return [2 /*return*/, nativeInteractionClient.acquireToken(__assign$6(__assign$6({}, silentRequest), { state: userRequestState, prompt: silentRequest.prompt || PromptValue.NONE })).finally(function () {
|
|
81059
81593
|
_this.browserStorage.cleanRequestByState(state);
|
|
81060
81594
|
})];
|
|
81061
81595
|
}
|
|
@@ -81075,7 +81609,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
81075
81609
|
* Licensed under the MIT License.
|
|
81076
81610
|
*/
|
|
81077
81611
|
var SilentRefreshClient = /** @class */ (function (_super) {
|
|
81078
|
-
__extends
|
|
81612
|
+
__extends$$(SilentRefreshClient, _super);
|
|
81079
81613
|
function SilentRefreshClient() {
|
|
81080
81614
|
return _super !== null && _super.apply(this, arguments) || this;
|
|
81081
81615
|
}
|
|
@@ -81090,10 +81624,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
81090
81624
|
return __generator$3(this, function (_b) {
|
|
81091
81625
|
switch (_b.label) {
|
|
81092
81626
|
case 0:
|
|
81093
|
-
_a = [__assign$
|
|
81627
|
+
_a = [__assign$6({}, request)];
|
|
81094
81628
|
return [4 /*yield*/, this.initializeBaseRequest(request)];
|
|
81095
81629
|
case 1:
|
|
81096
|
-
silentRequest = __assign$
|
|
81630
|
+
silentRequest = __assign$6.apply(void 0, _a.concat([_b.sent()]));
|
|
81097
81631
|
acquireTokenMeasurement = this.performanceClient.startMeasurement(PerformanceEvents.SilentRefreshClientAcquireToken, silentRequest.correlationId);
|
|
81098
81632
|
serverTelemetryManager = this.initializeServerTelemetryManager(ApiId.acquireTokenSilent_silentFlow);
|
|
81099
81633
|
return [4 /*yield*/, this.createRefreshTokenClient(serverTelemetryManager, silentRequest.authority, silentRequest.azureCloudOptions)];
|
|
@@ -83066,7 +83600,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
83066
83600
|
* Licensed under the MIT License.
|
|
83067
83601
|
*/
|
|
83068
83602
|
var HybridSpaAuthorizationCodeClient = /** @class */ (function (_super) {
|
|
83069
|
-
__extends
|
|
83603
|
+
__extends$$(HybridSpaAuthorizationCodeClient, _super);
|
|
83070
83604
|
function HybridSpaAuthorizationCodeClient(config) {
|
|
83071
83605
|
var _this = _super.call(this, config) || this;
|
|
83072
83606
|
_this.includeRedirectUri = false;
|
|
@@ -83082,7 +83616,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
83082
83616
|
* Licensed under the MIT License.
|
|
83083
83617
|
*/
|
|
83084
83618
|
var SilentAuthCodeClient = /** @class */ (function (_super) {
|
|
83085
|
-
__extends
|
|
83619
|
+
__extends$$(SilentAuthCodeClient, _super);
|
|
83086
83620
|
function SilentAuthCodeClient(config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, apiId, performanceClient, nativeMessageHandler, correlationId) {
|
|
83087
83621
|
var _this = _super.call(this, config, storageImpl, browserCrypto, logger, eventHandler, navigationClient, performanceClient, nativeMessageHandler, correlationId) || this;
|
|
83088
83622
|
_this.apiId = apiId;
|
|
@@ -83111,7 +83645,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
83111
83645
|
_a.label = 2;
|
|
83112
83646
|
case 2:
|
|
83113
83647
|
_a.trys.push([2, 4, , 5]);
|
|
83114
|
-
authCodeRequest = __assign$
|
|
83648
|
+
authCodeRequest = __assign$6(__assign$6({}, silentRequest), { code: request.code });
|
|
83115
83649
|
return [4 /*yield*/, this.getClientConfiguration(serverTelemetryManager, silentRequest.authority)];
|
|
83116
83650
|
case 3:
|
|
83117
83651
|
clientConfig = _a.sent();
|
|
@@ -83218,7 +83752,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
83218
83752
|
* Licensed under the MIT License.
|
|
83219
83753
|
*/
|
|
83220
83754
|
var BrowserPerformanceClient = /** @class */ (function (_super) {
|
|
83221
|
-
__extends
|
|
83755
|
+
__extends$$(BrowserPerformanceClient, _super);
|
|
83222
83756
|
function BrowserPerformanceClient(clientId, authority, logger, libraryName, libraryVersion, applicationTelemetry, cryptoOptions) {
|
|
83223
83757
|
var _this = _super.call(this, clientId, authority, logger, libraryName, libraryVersion, applicationTelemetry) || this;
|
|
83224
83758
|
_this.browserCrypto = new BrowserCrypto(_this.logger, cryptoOptions);
|
|
@@ -83248,8 +83782,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
83248
83782
|
// Capture page visibilityState and then invoke start/end measurement
|
|
83249
83783
|
var startPageVisibility = this.getPageVisibility();
|
|
83250
83784
|
var inProgressEvent = _super.prototype.startMeasurement.call(this, measureName, correlationId);
|
|
83251
|
-
return __assign$
|
|
83252
|
-
return inProgressEvent.endMeasurement(__assign$
|
|
83785
|
+
return __assign$6(__assign$6({}, inProgressEvent), { endMeasurement: function (event) {
|
|
83786
|
+
return inProgressEvent.endMeasurement(__assign$6({ startPageVisibility: startPageVisibility, endPageVisibility: _this.getPageVisibility() }, event));
|
|
83253
83787
|
} });
|
|
83254
83788
|
};
|
|
83255
83789
|
return BrowserPerformanceClient;
|
|
@@ -83612,7 +84146,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
83612
84146
|
var _this = this;
|
|
83613
84147
|
return __generator$3(this, function (_a) {
|
|
83614
84148
|
correlationId = this.getRequestCorrelationId(request);
|
|
83615
|
-
validRequest = __assign$
|
|
84149
|
+
validRequest = __assign$6(__assign$6({}, request), {
|
|
83616
84150
|
// will be PromptValue.NONE or PromptValue.NO_SESSION
|
|
83617
84151
|
prompt: request.prompt, correlationId: correlationId });
|
|
83618
84152
|
this.preflightBrowserEnvironmentCheck(InteractionType.Silent);
|
|
@@ -83686,7 +84220,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
83686
84220
|
response = this.hybridAuthCodeResponses.get(hybridAuthCode_1);
|
|
83687
84221
|
if (!response) {
|
|
83688
84222
|
this.logger.verbose("Initiating new acquireTokenByCode request", correlationId);
|
|
83689
|
-
response = this.acquireTokenByCodeAsync(__assign$
|
|
84223
|
+
response = this.acquireTokenByCodeAsync(__assign$6(__assign$6({}, request), { correlationId: correlationId }))
|
|
83690
84224
|
.then(function (result) {
|
|
83691
84225
|
_this.eventHandler.emitEvent(EventType.ACQUIRE_TOKEN_BY_CODE_SUCCESS, InteractionType.Silent, result);
|
|
83692
84226
|
_this.hybridAuthCodeResponses.delete(hybridAuthCode_1);
|
|
@@ -83849,7 +84383,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
83849
84383
|
return __generator$3(this, function (_a) {
|
|
83850
84384
|
correlationId = this.getRequestCorrelationId(logoutRequest);
|
|
83851
84385
|
this.logger.warning("logout API is deprecated and will be removed in msal-browser v3.0.0. Use logoutRedirect instead.", correlationId);
|
|
83852
|
-
return [2 /*return*/, this.logoutRedirect(__assign$
|
|
84386
|
+
return [2 /*return*/, this.logoutRedirect(__assign$6({ correlationId: correlationId }, logoutRequest))];
|
|
83853
84387
|
});
|
|
83854
84388
|
});
|
|
83855
84389
|
};
|
|
@@ -84227,7 +84761,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
84227
84761
|
* to obtain JWT tokens as described in the OAuth 2.0 Authorization Code Flow with PKCE specification.
|
|
84228
84762
|
*/
|
|
84229
84763
|
var PublicClientApplication = /** @class */ (function (_super) {
|
|
84230
|
-
__extends
|
|
84764
|
+
__extends$$(PublicClientApplication, _super);
|
|
84231
84765
|
/**
|
|
84232
84766
|
* @constructor
|
|
84233
84767
|
* Constructor for the PublicClientApplication used to instantiate the PublicClientApplication object
|
|
@@ -84269,7 +84803,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
84269
84803
|
return __generator$3(this, function (_a) {
|
|
84270
84804
|
correlationId = this.getRequestCorrelationId(request);
|
|
84271
84805
|
this.logger.verbose("loginRedirect called", correlationId);
|
|
84272
|
-
return [2 /*return*/, this.acquireTokenRedirect(__assign$
|
|
84806
|
+
return [2 /*return*/, this.acquireTokenRedirect(__assign$6({ correlationId: correlationId }, (request || DEFAULT_REQUEST)))];
|
|
84273
84807
|
});
|
|
84274
84808
|
});
|
|
84275
84809
|
};
|
|
@@ -84283,7 +84817,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
84283
84817
|
PublicClientApplication.prototype.loginPopup = function (request) {
|
|
84284
84818
|
var correlationId = this.getRequestCorrelationId(request);
|
|
84285
84819
|
this.logger.verbose("loginPopup called", correlationId);
|
|
84286
|
-
return this.acquireTokenPopup(__assign$
|
|
84820
|
+
return this.acquireTokenPopup(__assign$6({ correlationId: correlationId }, (request || DEFAULT_REQUEST)));
|
|
84287
84821
|
};
|
|
84288
84822
|
/**
|
|
84289
84823
|
* Silently acquire an access token for a given set of scopes. Returns currently processing promise if parallel requests are made.
|
|
@@ -84323,7 +84857,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
84323
84857
|
cachedResponse = this.activeSilentTokenRequests.get(silentRequestKey);
|
|
84324
84858
|
if (typeof cachedResponse === "undefined") {
|
|
84325
84859
|
this.logger.verbose("acquireTokenSilent called for the first time, storing active request", correlationId);
|
|
84326
|
-
response = this.acquireTokenSilentAsync(__assign$
|
|
84860
|
+
response = this.acquireTokenSilentAsync(__assign$6(__assign$6({}, request), { correlationId: correlationId }), account)
|
|
84327
84861
|
.then(function (result) {
|
|
84328
84862
|
_this.activeSilentTokenRequests.delete(silentRequestKey);
|
|
84329
84863
|
atsMeasurement.addStaticFields({
|
|
@@ -84381,7 +84915,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
84381
84915
|
astsAsyncMeasurement = this.performanceClient.startMeasurement(PerformanceEvents.AcquireTokenSilentAsync, request.correlationId);
|
|
84382
84916
|
if (!(NativeMessageHandler.isNativeAvailable(this.config, this.logger, this.nativeExtensionProvider, request.authenticationScheme) && account.nativeAccountId)) return [3 /*break*/, 1];
|
|
84383
84917
|
this.logger.verbose("acquireTokenSilent - attempting to acquire token from native platform");
|
|
84384
|
-
silentRequest = __assign$
|
|
84918
|
+
silentRequest = __assign$6(__assign$6({}, request), { account: account });
|
|
84385
84919
|
result = this.acquireTokenNative(silentRequest, ApiId.acquireTokenSilent_silentFlow).catch(function (e) { return __awaiter$3(_this, void 0, void 0, function () {
|
|
84386
84920
|
var silentIframeClient;
|
|
84387
84921
|
return __generator$3(this, function (_a) {
|
|
@@ -84402,7 +84936,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
84402
84936
|
return [4 /*yield*/, silentCacheClient.initializeSilentRequest(request, account)];
|
|
84403
84937
|
case 2:
|
|
84404
84938
|
silentRequest_1 = _a.sent();
|
|
84405
|
-
requestWithCLP_1 = __assign$
|
|
84939
|
+
requestWithCLP_1 = __assign$6(__assign$6({}, request), {
|
|
84406
84940
|
// set the request's CacheLookupPolicy to Default if it was not optionally passed in
|
|
84407
84941
|
cacheLookupPolicy: request.cacheLookupPolicy || CacheLookupPolicy.Default });
|
|
84408
84942
|
result = this.acquireTokenFromCache(silentCacheClient, silentRequest_1, requestWithCLP_1).catch(function (cacheError) {
|
|
@@ -84575,6 +85109,15 @@ uniform ${precision} ${type} u_${name};
|
|
|
84575
85109
|
}
|
|
84576
85110
|
return this.initPromise;
|
|
84577
85111
|
};
|
|
85112
|
+
/**
|
|
85113
|
+
* Cleans up any resources used by the authentication manager.
|
|
85114
|
+
*/
|
|
85115
|
+
AuthenticationManager.prototype.dispose = function () {
|
|
85116
|
+
if (this.tokenTimeOutHandle) {
|
|
85117
|
+
clearTimeout(this.tokenTimeOutHandle);
|
|
85118
|
+
this.tokenTimeOutHandle = null;
|
|
85119
|
+
}
|
|
85120
|
+
};
|
|
84578
85121
|
/**
|
|
84579
85122
|
* Gets the default auth context to be shared between maps without one specified to them.
|
|
84580
85123
|
*/
|
|
@@ -84982,8 +85525,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
84982
85525
|
return ControlManager;
|
|
84983
85526
|
}());
|
|
84984
85527
|
|
|
84985
|
-
var __assign$
|
|
84986
|
-
__assign$
|
|
85528
|
+
var __assign$8 = (window && window.__assign) || function () {
|
|
85529
|
+
__assign$8 = Object.assign || function(t) {
|
|
84987
85530
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
84988
85531
|
s = arguments[i];
|
|
84989
85532
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
@@ -84991,7 +85534,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
84991
85534
|
}
|
|
84992
85535
|
return t;
|
|
84993
85536
|
};
|
|
84994
|
-
return __assign$
|
|
85537
|
+
return __assign$8.apply(this, arguments);
|
|
84995
85538
|
};
|
|
84996
85539
|
/**
|
|
84997
85540
|
* @private
|
|
@@ -85035,7 +85578,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
85035
85578
|
case "sourcedata":
|
|
85036
85579
|
case "styledata":
|
|
85037
85580
|
modifiedCallback = function (data) {
|
|
85038
|
-
var mapEventData = __assign$
|
|
85581
|
+
var mapEventData = __assign$8(__assign$8({ dataType: data.dataType }, (data.dataType === "source" && __assign$8(__assign$8(__assign$8({ isSourceLoaded: data.isSourceLoaded }, (data.sourceDataType && { sourceDataType: data.sourceDataType })), { source: _this.map.sources.getById(data.sourceId) }), (data.tile && {
|
|
85039
85582
|
tile: {
|
|
85040
85583
|
id: {
|
|
85041
85584
|
x: data.tile.tileID.canonical.x,
|
|
@@ -85920,7 +86463,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
85920
86463
|
return ImageSpriteManager;
|
|
85921
86464
|
}());
|
|
85922
86465
|
|
|
85923
|
-
var __extends$
|
|
86466
|
+
var __extends$11 = (window && window.__extends) || (function () {
|
|
85924
86467
|
var extendStatics = function (d, b) {
|
|
85925
86468
|
extendStatics = Object.setPrototypeOf ||
|
|
85926
86469
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -85952,7 +86495,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
85952
86495
|
* @private
|
|
85953
86496
|
*/
|
|
85954
86497
|
var FundamentalMapLayer = /** @class */ (function (_super) {
|
|
85955
|
-
__extends$
|
|
86498
|
+
__extends$11(FundamentalMapLayer, _super);
|
|
85956
86499
|
/**
|
|
85957
86500
|
* Constructs a base layer used to represent the base, transit, and labels layers.
|
|
85958
86501
|
* @param mbLayers The stylesheet used to define the style sources and style layers.
|
|
@@ -86041,7 +86584,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
86041
86584
|
}
|
|
86042
86585
|
return ar;
|
|
86043
86586
|
};
|
|
86044
|
-
var __spreadArray$
|
|
86587
|
+
var __spreadArray$5 = (window && window.__spreadArray) || function (to, from) {
|
|
86045
86588
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
86046
86589
|
to[j] = from[i];
|
|
86047
86590
|
return to;
|
|
@@ -86179,6 +86722,8 @@ uniform ${precision} ${type} u_${name};
|
|
|
86179
86722
|
// If adding a SourceBuildingLayer the source associated must also be added.
|
|
86180
86723
|
if (layer instanceof SourceBuildingLayer) {
|
|
86181
86724
|
this.map._getMap().addSource(layer._getSourceId(), layer._buildSource());
|
|
86725
|
+
// we also need the abstraction for those source building layers added to the map if it is not already there
|
|
86726
|
+
this.map.sources.setSourceState(layer._getSourceWrapper());
|
|
86182
86727
|
}
|
|
86183
86728
|
var mbBefore = this._getMapboxBefore(before);
|
|
86184
86729
|
try {
|
|
@@ -86477,7 +87022,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
86477
87022
|
// If a specified layer hasn't been added to the map throw an error.
|
|
86478
87023
|
var index = this_1.layerIndex.findIndex(function (l) { return l.getId() === layerId; });
|
|
86479
87024
|
if (index > -1) {
|
|
86480
|
-
layerIds.push.apply(layerIds, __spreadArray$
|
|
87025
|
+
layerIds.push.apply(layerIds, __spreadArray$5([], __read$b(this_1.layerIndex[index]._getLayerIds()
|
|
86481
87026
|
.filter(function (id) { return !!_this.map._getMap().getLayer(id); }))));
|
|
86482
87027
|
}
|
|
86483
87028
|
else {
|
|
@@ -86547,6 +87092,9 @@ uniform ${precision} ${type} u_${name};
|
|
|
86547
87092
|
if (userLayerIndex != -1) {
|
|
86548
87093
|
this.userLayers.splice(userLayerIndex, 1);
|
|
86549
87094
|
}
|
|
87095
|
+
if (layer instanceof SourceBuildingLayer) {
|
|
87096
|
+
this.map.sources.unsetSourceState(layer._getSourceId());
|
|
87097
|
+
}
|
|
86550
87098
|
tempLayer.onRemove();
|
|
86551
87099
|
};
|
|
86552
87100
|
return LayerManager;
|
|
@@ -86717,92 +87265,6 @@ uniform ${precision} ${type} u_${name};
|
|
|
86717
87265
|
return PopupManager;
|
|
86718
87266
|
}());
|
|
86719
87267
|
|
|
86720
|
-
var __extends$Z = (window && window.__extends) || (function () {
|
|
86721
|
-
var extendStatics = function (d, b) {
|
|
86722
|
-
extendStatics = Object.setPrototypeOf ||
|
|
86723
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
86724
|
-
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
86725
|
-
return extendStatics(d, b);
|
|
86726
|
-
};
|
|
86727
|
-
return function (d, b) {
|
|
86728
|
-
if (typeof b !== "function" && b !== null)
|
|
86729
|
-
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
86730
|
-
extendStatics(d, b);
|
|
86731
|
-
function __() { this.constructor = d; }
|
|
86732
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
86733
|
-
};
|
|
86734
|
-
})();
|
|
86735
|
-
var __assign$8 = (window && window.__assign) || function () {
|
|
86736
|
-
__assign$8 = Object.assign || function(t) {
|
|
86737
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
86738
|
-
s = arguments[i];
|
|
86739
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
86740
|
-
t[p] = s[p];
|
|
86741
|
-
}
|
|
86742
|
-
return t;
|
|
86743
|
-
};
|
|
86744
|
-
return __assign$8.apply(this, arguments);
|
|
86745
|
-
};
|
|
86746
|
-
/**
|
|
86747
|
-
* Used to represent the fundamental map source.
|
|
86748
|
-
* @private
|
|
86749
|
-
*/
|
|
86750
|
-
var FundamentalMapSource = /** @class */ (function (_super) {
|
|
86751
|
-
__extends$Z(FundamentalMapSource, _super);
|
|
86752
|
-
/**
|
|
86753
|
-
* Constructs a source from the contents of a layer resource file.
|
|
86754
|
-
* @param id The source's id.
|
|
86755
|
-
* @param sourceDef The sources entry of the resource file.
|
|
86756
|
-
* @param options The query parameters to add to the urls listed in the resource file.
|
|
86757
|
-
*/
|
|
86758
|
-
function FundamentalMapSource(id, sourceDef, options) {
|
|
86759
|
-
var _this = _super.call(this, id) || this;
|
|
86760
|
-
_this.source = _this._modifySource(sourceDef, options);
|
|
86761
|
-
return _this;
|
|
86762
|
-
}
|
|
86763
|
-
/**
|
|
86764
|
-
* @internal
|
|
86765
|
-
*/
|
|
86766
|
-
FundamentalMapSource.prototype._buildSource = function () {
|
|
86767
|
-
return this.source;
|
|
86768
|
-
};
|
|
86769
|
-
/**
|
|
86770
|
-
* Updates the source info to convert the tiles to url strings.
|
|
86771
|
-
* @param sourceDef The original source info.
|
|
86772
|
-
* @param options The query parameters to add to the tile urls.
|
|
86773
|
-
*/
|
|
86774
|
-
FundamentalMapSource.prototype._modifySource = function (sourceDef, options) {
|
|
86775
|
-
if (sourceDef.tiles) {
|
|
86776
|
-
var tileStrings = sourceDef.tiles.map(function (tile) {
|
|
86777
|
-
if (typeof tile === "string") {
|
|
86778
|
-
return tile;
|
|
86779
|
-
}
|
|
86780
|
-
var tileUrl = new Url({
|
|
86781
|
-
domain: constants.domainPlaceHolder,
|
|
86782
|
-
path: tile.path,
|
|
86783
|
-
queryParams: __assign$8(__assign$8({}, options), tile.queryParams)
|
|
86784
|
-
});
|
|
86785
|
-
return tileUrl.toString();
|
|
86786
|
-
});
|
|
86787
|
-
sourceDef.tiles = tileStrings;
|
|
86788
|
-
}
|
|
86789
|
-
else if (sourceDef.url) {
|
|
86790
|
-
sourceDef.url = (typeof sourceDef.url === "string") ?
|
|
86791
|
-
sourceDef.url :
|
|
86792
|
-
new Url({
|
|
86793
|
-
domain: constants.domainPlaceHolder,
|
|
86794
|
-
path: sourceDef.url.path,
|
|
86795
|
-
queryParams: __assign$8(__assign$8({}, options), sourceDef.url.queryParams)
|
|
86796
|
-
}).toString();
|
|
86797
|
-
}
|
|
86798
|
-
else {
|
|
86799
|
-
throw new Error("Source definition must define a TileJSON 'url' or a 'tiles' array.");
|
|
86800
|
-
}
|
|
86801
|
-
return sourceDef;
|
|
86802
|
-
};
|
|
86803
|
-
return FundamentalMapSource;
|
|
86804
|
-
}(Source));
|
|
86805
|
-
|
|
86806
87268
|
var __values$f = (window && window.__values) || function(o) {
|
|
86807
87269
|
var s = typeof Symbol === "function" && Symbol.iterator, m = s && o[s], i = 0;
|
|
86808
87270
|
if (m) return m.call(o);
|
|
@@ -86975,6 +87437,23 @@ uniform ${precision} ${type} u_${name};
|
|
|
86975
87437
|
this._removeSource(source, update);
|
|
86976
87438
|
}
|
|
86977
87439
|
};
|
|
87440
|
+
/**
|
|
87441
|
+
* @internal
|
|
87442
|
+
*/
|
|
87443
|
+
SourceManager.prototype.setSourceState = function (newSource, shouldInvokeAddEvent) {
|
|
87444
|
+
if (shouldInvokeAddEvent === void 0) { shouldInvokeAddEvent = true; }
|
|
87445
|
+
this.sources.set(newSource.getId(), newSource);
|
|
87446
|
+
newSource._setMap(this.map, shouldInvokeAddEvent);
|
|
87447
|
+
};
|
|
87448
|
+
/**
|
|
87449
|
+
* @internal
|
|
87450
|
+
*/
|
|
87451
|
+
SourceManager.prototype.unsetSourceState = function (id) {
|
|
87452
|
+
if (this.sources.has(id)) {
|
|
87453
|
+
this.sources.get(id)._setMap(null);
|
|
87454
|
+
this.sources.delete(id);
|
|
87455
|
+
}
|
|
87456
|
+
};
|
|
86978
87457
|
SourceManager.prototype._removeSource = function (source, update) {
|
|
86979
87458
|
var id = source instanceof Source ? source.getId() : source;
|
|
86980
87459
|
if (this.sources.has(id)) {
|
|
@@ -86982,8 +87461,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
86982
87461
|
this.map._getMap().removeSource(id);
|
|
86983
87462
|
}
|
|
86984
87463
|
if (!this.map._getMap().getSource(id) || !update) {
|
|
86985
|
-
this.
|
|
86986
|
-
this.sources.delete(id);
|
|
87464
|
+
this.unsetSourceState(id);
|
|
86987
87465
|
}
|
|
86988
87466
|
else {
|
|
86989
87467
|
throw new Error("One or more layers have a dependency on the source '" + id + "'");
|
|
@@ -87000,8 +87478,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87000
87478
|
throw new Error("'" + source.getId() + "' is already added to the map");
|
|
87001
87479
|
}
|
|
87002
87480
|
else {
|
|
87003
|
-
this.
|
|
87004
|
-
this.sources.delete(source.getId());
|
|
87481
|
+
this.unsetSourceState(source.getId());
|
|
87005
87482
|
}
|
|
87006
87483
|
}
|
|
87007
87484
|
if (update) {
|
|
@@ -87013,8 +87490,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87013
87490
|
}
|
|
87014
87491
|
this.map._getMap().addSource(source.getId(), source._buildSource());
|
|
87015
87492
|
}
|
|
87016
|
-
this.
|
|
87017
|
-
source._setMap(this.map);
|
|
87493
|
+
this.setSourceState(source);
|
|
87018
87494
|
};
|
|
87019
87495
|
/**
|
|
87020
87496
|
* Converts an array of features as returned by one of Mapbox's query*Features(...) function
|
|
@@ -87056,51 +87532,90 @@ uniform ${precision} ${type} u_${name};
|
|
|
87056
87532
|
};
|
|
87057
87533
|
/**
|
|
87058
87534
|
* Sync SourceManager with mapbox sources.
|
|
87535
|
+
* This function is responsible for creating wrappers for mapbox sources
|
|
87536
|
+
* and setting the approperiate sourceManager state with them
|
|
87059
87537
|
* @internal
|
|
87060
87538
|
*/
|
|
87061
87539
|
SourceManager.prototype._syncSources = function (sources) {
|
|
87062
87540
|
var _this = this;
|
|
87063
|
-
if (sources) {
|
|
87064
|
-
|
|
87065
|
-
|
|
87066
|
-
|
|
87067
|
-
|
|
87068
|
-
|
|
87069
|
-
|
|
87070
|
-
|
|
87071
|
-
|
|
87072
|
-
|
|
87073
|
-
|
|
87074
|
-
|
|
87075
|
-
|
|
87076
|
-
|
|
87077
|
-
|
|
87078
|
-
|
|
87079
|
-
|
|
87080
|
-
|
|
87081
|
-
|
|
87082
|
-
|
|
87083
|
-
|
|
87084
|
-
|
|
87085
|
-
|
|
87086
|
-
|
|
87087
|
-
|
|
87088
|
-
|
|
87541
|
+
if (!sources) {
|
|
87542
|
+
console.warn('syncSources called with no style sources which is unexpected.');
|
|
87543
|
+
return;
|
|
87544
|
+
}
|
|
87545
|
+
// 1. add / update the source wrappers
|
|
87546
|
+
Object.keys(sources)
|
|
87547
|
+
.map(function (sourceId) {
|
|
87548
|
+
var sourceToAdd = sources[sourceId];
|
|
87549
|
+
var newSource;
|
|
87550
|
+
switch (sourceToAdd.type) {
|
|
87551
|
+
case 'vector':
|
|
87552
|
+
case 'raster':
|
|
87553
|
+
case 'raster-dem': {
|
|
87554
|
+
newSource = new FundamentalMapSource(sourceId, {
|
|
87555
|
+
name: sourceId,
|
|
87556
|
+
tiles: sourceToAdd.tiles,
|
|
87557
|
+
type: sourceToAdd.type,
|
|
87558
|
+
url: sourceToAdd.url,
|
|
87559
|
+
tileSize: 'tileSize' in sourceToAdd ? sourceToAdd.tileSize : undefined
|
|
87560
|
+
});
|
|
87561
|
+
break;
|
|
87562
|
+
}
|
|
87563
|
+
case 'canvas': {
|
|
87564
|
+
newSource = new CanvasSource(sourceId, sourceToAdd);
|
|
87565
|
+
break;
|
|
87566
|
+
}
|
|
87567
|
+
case 'geojson': {
|
|
87568
|
+
var dataSource = new DataSource(sourceId, {
|
|
87569
|
+
maxZoom: sourceToAdd.maxzoom,
|
|
87570
|
+
cluster: sourceToAdd.cluster,
|
|
87571
|
+
clusterRadius: sourceToAdd.clusterRadius,
|
|
87572
|
+
tolerance: sourceToAdd.tolerance,
|
|
87573
|
+
lineMetrics: sourceToAdd.lineMetrics,
|
|
87574
|
+
clusterProperties: sourceToAdd.clusterProperties,
|
|
87575
|
+
buffer: sourceToAdd.buffer,
|
|
87576
|
+
clusterMinPoints: sourceToAdd.clusterMinPoints,
|
|
87577
|
+
generateId: sourceToAdd.generateId,
|
|
87578
|
+
promoteId: sourceToAdd.promoteId,
|
|
87579
|
+
filter: sourceToAdd.filter,
|
|
87580
|
+
// attribution?: sourceToAdd.attribution
|
|
87581
|
+
});
|
|
87582
|
+
if (typeof sourceToAdd.data !== 'string' && sourceToAdd.data !== undefined) {
|
|
87583
|
+
dataSource._addNoUpdate(sourceToAdd.data);
|
|
87089
87584
|
}
|
|
87585
|
+
newSource = dataSource;
|
|
87586
|
+
break;
|
|
87090
87587
|
}
|
|
87091
|
-
|
|
87092
|
-
|
|
87093
|
-
|
|
87094
|
-
_this.sources.get(sourceId)._setMap(null);
|
|
87095
|
-
_this.sources.delete(sourceId);
|
|
87588
|
+
case 'image': {
|
|
87589
|
+
newSource = new ImageSource(sourceId, sourceToAdd);
|
|
87590
|
+
break;
|
|
87096
87591
|
}
|
|
87097
|
-
|
|
87098
|
-
|
|
87592
|
+
case 'video': {
|
|
87593
|
+
newSource = new VideoSource(sourceId, sourceToAdd);
|
|
87594
|
+
break;
|
|
87595
|
+
}
|
|
87596
|
+
default: {
|
|
87597
|
+
newSource = new UnknownSource(sourceId, sourceToAdd);
|
|
87598
|
+
}
|
|
87599
|
+
}
|
|
87600
|
+
return newSource;
|
|
87601
|
+
}).forEach(function (newSource) {
|
|
87602
|
+
// use deep equality of underlying maplibre sources to determine if the source has been updated or overriden on style update
|
|
87603
|
+
var existing = _this.sources.get(newSource.getId());
|
|
87604
|
+
var isUpdate = existing && newSource._isDeepEqual(existing);
|
|
87605
|
+
if (!isUpdate && existing) {
|
|
87606
|
+
_this.unsetSourceState(existing.getId());
|
|
87607
|
+
}
|
|
87608
|
+
_this.setSourceState(newSource, !isUpdate);
|
|
87609
|
+
});
|
|
87610
|
+
// 2. remove the source wrappers that are not in the style
|
|
87611
|
+
Array.from(this.sources.keys())
|
|
87612
|
+
.filter(function (sourceId) { return !(sourceId in sources); })
|
|
87613
|
+
.forEach(function (sourceId) { return _this.unsetSourceState(sourceId); });
|
|
87099
87614
|
};
|
|
87100
87615
|
return SourceManager;
|
|
87101
87616
|
}());
|
|
87102
87617
|
|
|
87103
|
-
var __extends$
|
|
87618
|
+
var __extends$12 = (window && window.__extends) || (function () {
|
|
87104
87619
|
var extendStatics = function (d, b) {
|
|
87105
87620
|
extendStatics = Object.setPrototypeOf ||
|
|
87106
87621
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87119,7 +87634,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87119
87634
|
* The options for animating changes to the map control's camera.
|
|
87120
87635
|
*/
|
|
87121
87636
|
var AnimationOptions = /** @class */ (function (_super) {
|
|
87122
|
-
__extends$
|
|
87637
|
+
__extends$12(AnimationOptions, _super);
|
|
87123
87638
|
function AnimationOptions() {
|
|
87124
87639
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87125
87640
|
/**
|
|
@@ -87143,7 +87658,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87143
87658
|
return AnimationOptions;
|
|
87144
87659
|
}(Options));
|
|
87145
87660
|
|
|
87146
|
-
var __extends
|
|
87661
|
+
var __extends$13 = (window && window.__extends) || (function () {
|
|
87147
87662
|
var extendStatics = function (d, b) {
|
|
87148
87663
|
extendStatics = Object.setPrototypeOf ||
|
|
87149
87664
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87162,7 +87677,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87162
87677
|
* Represent the amount of padding in pixels to add to the side of a BoundingBox when setting the camera of a map.
|
|
87163
87678
|
*/
|
|
87164
87679
|
var Padding = /** @class */ (function (_super) {
|
|
87165
|
-
__extends
|
|
87680
|
+
__extends$13(Padding, _super);
|
|
87166
87681
|
function Padding() {
|
|
87167
87682
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87168
87683
|
/**
|
|
@@ -87194,7 +87709,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87194
87709
|
return Padding;
|
|
87195
87710
|
}(Options));
|
|
87196
87711
|
|
|
87197
|
-
var __extends$
|
|
87712
|
+
var __extends$14 = (window && window.__extends) || (function () {
|
|
87198
87713
|
var extendStatics = function (d, b) {
|
|
87199
87714
|
extendStatics = Object.setPrototypeOf ||
|
|
87200
87715
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87236,7 +87751,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87236
87751
|
}
|
|
87237
87752
|
return ar;
|
|
87238
87753
|
};
|
|
87239
|
-
var __spreadArray$
|
|
87754
|
+
var __spreadArray$6 = (window && window.__spreadArray) || function (to, from) {
|
|
87240
87755
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
87241
87756
|
to[j] = from[i];
|
|
87242
87757
|
return to;
|
|
@@ -87245,7 +87760,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87245
87760
|
* The options for setting the bounds of the map control's camera.
|
|
87246
87761
|
*/
|
|
87247
87762
|
var CameraBoundsOptions = /** @class */ (function (_super) {
|
|
87248
|
-
__extends$
|
|
87763
|
+
__extends$14(CameraBoundsOptions, _super);
|
|
87249
87764
|
function CameraBoundsOptions() {
|
|
87250
87765
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87251
87766
|
/**
|
|
@@ -87311,12 +87826,12 @@ uniform ${precision} ${type} u_${name};
|
|
|
87311
87826
|
}
|
|
87312
87827
|
finally { if (e_1) throw e_1.error; }
|
|
87313
87828
|
}
|
|
87314
|
-
return _super.prototype.merge.apply(this, __spreadArray$
|
|
87829
|
+
return _super.prototype.merge.apply(this, __spreadArray$6([], __read$c(valuesList)));
|
|
87315
87830
|
};
|
|
87316
87831
|
return CameraBoundsOptions;
|
|
87317
87832
|
}(Options));
|
|
87318
87833
|
|
|
87319
|
-
var __extends$
|
|
87834
|
+
var __extends$15 = (window && window.__extends) || (function () {
|
|
87320
87835
|
var extendStatics = function (d, b) {
|
|
87321
87836
|
extendStatics = Object.setPrototypeOf ||
|
|
87322
87837
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87335,7 +87850,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87335
87850
|
* The options for setting the map control's camera.
|
|
87336
87851
|
*/
|
|
87337
87852
|
var CameraOptions = /** @class */ (function (_super) {
|
|
87338
|
-
__extends$
|
|
87853
|
+
__extends$15(CameraOptions, _super);
|
|
87339
87854
|
function CameraOptions() {
|
|
87340
87855
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87341
87856
|
/**
|
|
@@ -87394,7 +87909,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87394
87909
|
return CameraOptions;
|
|
87395
87910
|
}(Options));
|
|
87396
87911
|
|
|
87397
|
-
var __extends$
|
|
87912
|
+
var __extends$16 = (window && window.__extends) || (function () {
|
|
87398
87913
|
var extendStatics = function (d, b) {
|
|
87399
87914
|
extendStatics = Object.setPrototypeOf ||
|
|
87400
87915
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87413,7 +87928,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87413
87928
|
* The options for a layer of the map.
|
|
87414
87929
|
*/
|
|
87415
87930
|
var LayerOptions$1 = /** @class */ (function (_super) {
|
|
87416
|
-
__extends$
|
|
87931
|
+
__extends$16(LayerOptions, _super);
|
|
87417
87932
|
function LayerOptions() {
|
|
87418
87933
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87419
87934
|
/**
|
|
@@ -87446,7 +87961,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87446
87961
|
return LayerOptions;
|
|
87447
87962
|
}(Options));
|
|
87448
87963
|
|
|
87449
|
-
var __extends$
|
|
87964
|
+
var __extends$17 = (window && window.__extends) || (function () {
|
|
87450
87965
|
var extendStatics = function (d, b) {
|
|
87451
87966
|
extendStatics = Object.setPrototypeOf ||
|
|
87452
87967
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87466,7 +87981,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87466
87981
|
* @deprecated Use BubbleLayerOptions with atlas.layer.BubbleLayer instead.
|
|
87467
87982
|
*/
|
|
87468
87983
|
var CircleLayerOptions = /** @class */ (function (_super) {
|
|
87469
|
-
__extends$
|
|
87984
|
+
__extends$17(CircleLayerOptions, _super);
|
|
87470
87985
|
function CircleLayerOptions() {
|
|
87471
87986
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87472
87987
|
/**
|
|
@@ -87498,7 +88013,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87498
88013
|
return CircleLayerOptions;
|
|
87499
88014
|
}(LayerOptions$1));
|
|
87500
88015
|
|
|
87501
|
-
var __extends$
|
|
88016
|
+
var __extends$18 = (window && window.__extends) || (function () {
|
|
87502
88017
|
var extendStatics = function (d, b) {
|
|
87503
88018
|
extendStatics = Object.setPrototypeOf ||
|
|
87504
88019
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87518,7 +88033,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87518
88033
|
* @deprecated Use LineLayerOptions with atlas.layer.LineLayer instead.
|
|
87519
88034
|
*/
|
|
87520
88035
|
var LinestringLayerOptions = /** @class */ (function (_super) {
|
|
87521
|
-
__extends$
|
|
88036
|
+
__extends$18(LinestringLayerOptions, _super);
|
|
87522
88037
|
function LinestringLayerOptions() {
|
|
87523
88038
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87524
88039
|
/**
|
|
@@ -87554,7 +88069,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87554
88069
|
return LinestringLayerOptions;
|
|
87555
88070
|
}(LayerOptions$1));
|
|
87556
88071
|
|
|
87557
|
-
var __extends$
|
|
88072
|
+
var __extends$19 = (window && window.__extends) || (function () {
|
|
87558
88073
|
var extendStatics = function (d, b) {
|
|
87559
88074
|
extendStatics = Object.setPrototypeOf ||
|
|
87560
88075
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87574,7 +88089,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87574
88089
|
* @deprecated Use SymbolLayerOptions with atlas.layer.SymbolLayer instead.
|
|
87575
88090
|
*/
|
|
87576
88091
|
var PinLayerOptions = /** @class */ (function (_super) {
|
|
87577
|
-
__extends$
|
|
88092
|
+
__extends$19(PinLayerOptions, _super);
|
|
87578
88093
|
function PinLayerOptions() {
|
|
87579
88094
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87580
88095
|
/**
|
|
@@ -87624,7 +88139,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87624
88139
|
return PinLayerOptions;
|
|
87625
88140
|
}(LayerOptions$1));
|
|
87626
88141
|
|
|
87627
|
-
var __extends$
|
|
88142
|
+
var __extends$1a = (window && window.__extends) || (function () {
|
|
87628
88143
|
var extendStatics = function (d, b) {
|
|
87629
88144
|
extendStatics = Object.setPrototypeOf ||
|
|
87630
88145
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87644,7 +88159,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87644
88159
|
* @deprecated Use new PolygonLayerOptions with atlas.layer.PolygonLayer instead.
|
|
87645
88160
|
*/
|
|
87646
88161
|
var PolygonLayerOptions$1 = /** @class */ (function (_super) {
|
|
87647
|
-
__extends$
|
|
88162
|
+
__extends$1a(PolygonLayerOptions, _super);
|
|
87648
88163
|
function PolygonLayerOptions() {
|
|
87649
88164
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87650
88165
|
/**
|
|
@@ -87667,7 +88182,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87667
88182
|
return PolygonLayerOptions;
|
|
87668
88183
|
}(LayerOptions$1));
|
|
87669
88184
|
|
|
87670
|
-
var __extends$
|
|
88185
|
+
var __extends$1b = (window && window.__extends) || (function () {
|
|
87671
88186
|
var extendStatics = function (d, b) {
|
|
87672
88187
|
extendStatics = Object.setPrototypeOf ||
|
|
87673
88188
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87687,7 +88202,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87687
88202
|
* @deprecated Use TileLayerOptions with atlas.layer.TileLayer instead.
|
|
87688
88203
|
*/
|
|
87689
88204
|
var RasterLayerOptions = /** @class */ (function (_super) {
|
|
87690
|
-
__extends$
|
|
88205
|
+
__extends$1b(RasterLayerOptions, _super);
|
|
87691
88206
|
function RasterLayerOptions() {
|
|
87692
88207
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87693
88208
|
/**
|
|
@@ -87699,7 +88214,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87699
88214
|
return RasterLayerOptions;
|
|
87700
88215
|
}(LayerOptions$1));
|
|
87701
88216
|
|
|
87702
|
-
var __extends$
|
|
88217
|
+
var __extends$1c = (window && window.__extends) || (function () {
|
|
87703
88218
|
var extendStatics = function (d, b) {
|
|
87704
88219
|
extendStatics = Object.setPrototypeOf ||
|
|
87705
88220
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87718,7 +88233,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87718
88233
|
* The options for the map's lighting.
|
|
87719
88234
|
*/
|
|
87720
88235
|
var LightOptions = /** @class */ (function (_super) {
|
|
87721
|
-
__extends$
|
|
88236
|
+
__extends$1c(LightOptions, _super);
|
|
87722
88237
|
function LightOptions() {
|
|
87723
88238
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87724
88239
|
/**
|
|
@@ -87758,7 +88273,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87758
88273
|
return LightOptions;
|
|
87759
88274
|
}(Options));
|
|
87760
88275
|
|
|
87761
|
-
var __extends$
|
|
88276
|
+
var __extends$1d = (window && window.__extends) || (function () {
|
|
87762
88277
|
var extendStatics = function (d, b) {
|
|
87763
88278
|
extendStatics = Object.setPrototypeOf ||
|
|
87764
88279
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -87800,7 +88315,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87800
88315
|
}
|
|
87801
88316
|
return ar;
|
|
87802
88317
|
};
|
|
87803
|
-
var __spreadArray$
|
|
88318
|
+
var __spreadArray$7 = (window && window.__spreadArray) || function (to, from) {
|
|
87804
88319
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
87805
88320
|
to[j] = from[i];
|
|
87806
88321
|
return to;
|
|
@@ -87809,7 +88324,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87809
88324
|
* The options for the map's style.
|
|
87810
88325
|
*/
|
|
87811
88326
|
var StyleOptions = /** @class */ (function (_super) {
|
|
87812
|
-
__extends$
|
|
88327
|
+
__extends$1d(StyleOptions, _super);
|
|
87813
88328
|
function StyleOptions() {
|
|
87814
88329
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
87815
88330
|
/**
|
|
@@ -87866,6 +88381,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
87866
88381
|
* If false all buildings will be rendered as just their footprints.
|
|
87867
88382
|
* Default `false`
|
|
87868
88383
|
* @default false
|
|
88384
|
+
* @deprecated
|
|
87869
88385
|
*/
|
|
87870
88386
|
_this.showBuildingModels = false;
|
|
87871
88387
|
/**
|
|
@@ -87959,12 +88475,12 @@ uniform ${precision} ${type} u_${name};
|
|
|
87959
88475
|
finally { if (e_1) throw e_1.error; }
|
|
87960
88476
|
}
|
|
87961
88477
|
// Then execute the standard merge behavior.
|
|
87962
|
-
return _super.prototype.merge.apply(this, __spreadArray$
|
|
88478
|
+
return _super.prototype.merge.apply(this, __spreadArray$7([], __read$d(valueList)));
|
|
87963
88479
|
};
|
|
87964
88480
|
return StyleOptions;
|
|
87965
88481
|
}(Options));
|
|
87966
88482
|
|
|
87967
|
-
var __extends$
|
|
88483
|
+
var __extends$1e = (window && window.__extends) || (function () {
|
|
87968
88484
|
var extendStatics = function (d, b) {
|
|
87969
88485
|
extendStatics = Object.setPrototypeOf ||
|
|
87970
88486
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -88017,7 +88533,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
88017
88533
|
}
|
|
88018
88534
|
return ar;
|
|
88019
88535
|
};
|
|
88020
|
-
var __spreadArray$
|
|
88536
|
+
var __spreadArray$8 = (window && window.__spreadArray) || function (to, from) {
|
|
88021
88537
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
88022
88538
|
to[j] = from[i];
|
|
88023
88539
|
return to;
|
|
@@ -88034,7 +88550,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
88034
88550
|
* Global properties used in all atlas service requests.
|
|
88035
88551
|
*/
|
|
88036
88552
|
var ServiceOptions = /** @class */ (function (_super) {
|
|
88037
|
-
__extends$
|
|
88553
|
+
__extends$1e(ServiceOptions, _super);
|
|
88038
88554
|
function ServiceOptions() {
|
|
88039
88555
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
88040
88556
|
/**
|
|
@@ -88252,10 +88768,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
88252
88768
|
// won't change default behavior in Options as usually that's what desired
|
|
88253
88769
|
// instead capture it here and reassign.
|
|
88254
88770
|
var currentTransforms = this._transformers;
|
|
88255
|
-
var transformersToMerge = valueList ? valueList.filter(function (value) { return value !== undefined; }).reduce(function (flattened, value) { return __spreadArray$
|
|
88771
|
+
var transformersToMerge = valueList ? valueList.filter(function (value) { return value !== undefined; }).reduce(function (flattened, value) { return __spreadArray$8(__spreadArray$8([], __read$e(flattened)), __read$e(value._transformers || [])); }, []) : [];
|
|
88256
88772
|
// Then execute the standard merge behavior.
|
|
88257
88773
|
// If subscription key auth method isn't being used then the subscription key property should be undefined.
|
|
88258
|
-
var merged = _super.prototype.merge.apply(this, __spreadArray$
|
|
88774
|
+
var merged = _super.prototype.merge.apply(this, __spreadArray$8([], __read$e(valueList)));
|
|
88259
88775
|
if (merged.authOptions.authType !== exports.AuthenticationType.subscriptionKey) {
|
|
88260
88776
|
merged["subscription-key"] = merged.subscriptionKey = undefined;
|
|
88261
88777
|
}
|
|
@@ -88267,7 +88783,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
88267
88783
|
if (merged.mapConfiguration && typeof merged.mapConfiguration !== 'string') {
|
|
88268
88784
|
merged.mapConfiguration = __assign$9(__assign$9({}, merged.mapConfiguration), { defaultConfiguration: merged.mapConfiguration.defaultConfiguration || merged.mapConfiguration['defaultStyle'], configurations: merged.mapConfiguration.configurations || merged.mapConfiguration['styles'] });
|
|
88269
88785
|
}
|
|
88270
|
-
this._transformers = __spreadArray$
|
|
88786
|
+
this._transformers = __spreadArray$8(__spreadArray$8([], __read$e(currentTransforms || [])), __read$e(transformersToMerge.filter(function (toMerge) { return !currentTransforms.includes(toMerge); })));
|
|
88271
88787
|
if (this.transformRequest && !this._transformers.includes(this.transformRequest)) {
|
|
88272
88788
|
this._transformers.push(this.transformRequest);
|
|
88273
88789
|
}
|
|
@@ -88516,7 +89032,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
88516
89032
|
}
|
|
88517
89033
|
return ar;
|
|
88518
89034
|
};
|
|
88519
|
-
var __spreadArray$
|
|
89035
|
+
var __spreadArray$9 = (window && window.__spreadArray) || function (to, from) {
|
|
88520
89036
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
88521
89037
|
to[j] = from[i];
|
|
88522
89038
|
return to;
|
|
@@ -88569,7 +89085,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
88569
89085
|
var deferredLayers = Object.entries(layerGroupLayers).reduce(function (deferred, _a) {
|
|
88570
89086
|
var _b = __read$f(_a, 2), groupName = _b[0], layers = _b[1];
|
|
88571
89087
|
var isInInitialLayerGroup = validInitLayerGroups.includes(groupName);
|
|
88572
|
-
return __spreadArray$
|
|
89088
|
+
return __spreadArray$9(__spreadArray$9([], __read$f(deferred)), __read$f(layers.filter(function (layer) {
|
|
88573
89089
|
var _a;
|
|
88574
89090
|
// Exclude custom layers
|
|
88575
89091
|
if (layer.type === 'custom')
|
|
@@ -88761,7 +89277,12 @@ uniform ${precision} ${type} u_${name};
|
|
|
88761
89277
|
domain: _this.serviceOptions.staticAssetsDomain,
|
|
88762
89278
|
path: constants.stylePath + "/" + constants.styleResourcePath + "/" + style.name,
|
|
88763
89279
|
queryParams: {
|
|
88764
|
-
|
|
89280
|
+
// Use the style version from the API response if it's available,
|
|
89281
|
+
// otherwise fallback to the version specified in the serviceOptions.
|
|
89282
|
+
// This is needed for flight testing the 2023-01-01 style version.
|
|
89283
|
+
styleVersion: definitions.version !== undefined && definitions.version !== null
|
|
89284
|
+
? definitions.version
|
|
89285
|
+
: _this.serviceOptions.styleDefinitionsVersion
|
|
88765
89286
|
// thus far we don't need to differentiate based on parameter here, as stylePatch will be called on cached styles as well
|
|
88766
89287
|
//language: styleOptions.language
|
|
88767
89288
|
},
|
|
@@ -88898,8 +89419,21 @@ uniform ${precision} ${type} u_${name};
|
|
|
88898
89419
|
diff: diff,
|
|
88899
89420
|
validate: this.serviceOptions.validateStyle,
|
|
88900
89421
|
transformStyle: function (previousStyle, style) {
|
|
88901
|
-
|
|
88902
|
-
var
|
|
89422
|
+
var nextStyle = style;
|
|
89423
|
+
var shouldProgressiveLoading = (styleOptions.progressiveLoading &&
|
|
89424
|
+
// The feature only effective at the initial load.
|
|
89425
|
+
!_this.map._isLoaded());
|
|
89426
|
+
// Shallow-clone the style object and duplicate layer.layout properties to avoid side-effects.
|
|
89427
|
+
if (shouldProgressiveLoading && Array.isArray(style === null || style === void 0 ? void 0 : style.layers)) {
|
|
89428
|
+
nextStyle = __assign$a({}, style);
|
|
89429
|
+
nextStyle.layers = nextStyle.layers.map(function (layer) {
|
|
89430
|
+
var nextLayer = __assign$a({}, layer);
|
|
89431
|
+
if (layer.layout) {
|
|
89432
|
+
nextLayer.layout = __assign$a({}, layer.layout);
|
|
89433
|
+
}
|
|
89434
|
+
return nextLayer;
|
|
89435
|
+
});
|
|
89436
|
+
}
|
|
88903
89437
|
// 1. derive the base new style (without user layers)
|
|
88904
89438
|
var targetStyle = _this.deriveNewStyle(previousStyle, nextStyle);
|
|
88905
89439
|
// 2. derive layer groups for the new style
|
|
@@ -88912,12 +89446,9 @@ uniform ${precision} ${type} u_${name};
|
|
|
88912
89446
|
.reduce(function (layerGroupLayers, _a) {
|
|
88913
89447
|
var _b;
|
|
88914
89448
|
var nextLayer = _a.nextLayer, layerGroup = _a.layerGroup;
|
|
88915
|
-
return (__assign$a(__assign$a({}, layerGroupLayers), (_b = {}, _b[layerGroup] = layerGroup in layerGroupLayers ? __spreadArray$
|
|
89449
|
+
return (__assign$a(__assign$a({}, layerGroupLayers), (_b = {}, _b[layerGroup] = layerGroup in layerGroupLayers ? __spreadArray$9(__spreadArray$9([], __read$f(layerGroupLayers[layerGroup])), [nextLayer]) : [nextLayer], _b)));
|
|
88916
89450
|
}, {});
|
|
88917
89451
|
// 3. side effect: progressively render map layers to the canvas to shorten the time to the first meaningful render.
|
|
88918
|
-
var shouldProgressiveLoading = (styleOptions.progressiveLoading &&
|
|
88919
|
-
// The feature only effective at the initial load.
|
|
88920
|
-
!_this.map._isLoaded());
|
|
88921
89452
|
if (shouldProgressiveLoading) {
|
|
88922
89453
|
var initLayerGroups = styleOptions.progressiveLoadingInitialLayerGroups;
|
|
88923
89454
|
if (Array.isArray(initLayerGroups) && initLayerGroups.length > 0) {
|
|
@@ -89062,27 +89593,30 @@ uniform ${precision} ${type} u_${name};
|
|
|
89062
89593
|
* Fetches a json resource at the specified domain and path.
|
|
89063
89594
|
*/
|
|
89064
89595
|
StyleManager.prototype._request = function (domain, path, resourceType, customQueryParams) {
|
|
89065
|
-
var _a;
|
|
89596
|
+
var _a, _b;
|
|
89066
89597
|
if (customQueryParams === void 0) { customQueryParams = {}; }
|
|
89067
89598
|
return __awaiter$5(this, void 0, void 0, function () {
|
|
89068
89599
|
var requestParams, fetchOptions;
|
|
89069
|
-
var
|
|
89070
|
-
return __generator$5(this, function (
|
|
89071
|
-
switch (
|
|
89600
|
+
var _c;
|
|
89601
|
+
return __generator$5(this, function (_d) {
|
|
89602
|
+
switch (_d.label) {
|
|
89072
89603
|
case 0:
|
|
89073
89604
|
requestParams = {
|
|
89074
89605
|
url: new Url({
|
|
89075
89606
|
protocol: "https",
|
|
89076
89607
|
domain: domain,
|
|
89077
89608
|
path: path,
|
|
89078
|
-
queryParams: __assign$a((
|
|
89609
|
+
queryParams: __assign$a((_c = {}, _c[constants.apiVersionQueryParameter] = this.serviceOptions.styleAPIVersion,
|
|
89610
|
+
// Generate a hash code to avoid cache conflict
|
|
89611
|
+
// TODO: Remove this once style version 2023-01-01 is publicly available
|
|
89612
|
+
_c.hash = StyleManager._hashCode((_a = this.map.authentication) === null || _a === void 0 ? void 0 : _a.getToken()), _c), customQueryParams)
|
|
89079
89613
|
}).toString()
|
|
89080
89614
|
};
|
|
89081
89615
|
if (typeof this.serviceOptions.transformRequest === "function" && resourceType) {
|
|
89082
89616
|
// If a transformRequest(...) was specified use it.
|
|
89083
89617
|
requestParams = this.serviceOptions.transformRequest(requestParams.url, resourceType);
|
|
89084
89618
|
}
|
|
89085
|
-
(
|
|
89619
|
+
(_b = this.map.authentication) === null || _b === void 0 ? void 0 : _b.signRequest(requestParams);
|
|
89086
89620
|
fetchOptions = {
|
|
89087
89621
|
method: "GET",
|
|
89088
89622
|
mode: "cors",
|
|
@@ -89099,11 +89633,26 @@ uniform ${precision} ${type} u_${name};
|
|
|
89099
89633
|
throw new Error("HTTP " + response.status + ": " + response.statusText + " ");
|
|
89100
89634
|
}
|
|
89101
89635
|
})];
|
|
89102
|
-
case 1: return [2 /*return*/,
|
|
89636
|
+
case 1: return [2 /*return*/, _d.sent()];
|
|
89103
89637
|
}
|
|
89104
89638
|
});
|
|
89105
89639
|
});
|
|
89106
89640
|
};
|
|
89641
|
+
/**
|
|
89642
|
+
* A basic helper function to generate a hash from an input string.
|
|
89643
|
+
*/
|
|
89644
|
+
StyleManager._hashCode = function (str) {
|
|
89645
|
+
if (str === void 0) { str = ""; }
|
|
89646
|
+
var chr, hash = 0;
|
|
89647
|
+
if (!str)
|
|
89648
|
+
return hash;
|
|
89649
|
+
for (var i = 0; i < str.length; i++) {
|
|
89650
|
+
chr = str.charCodeAt(i);
|
|
89651
|
+
hash = (hash << 5) - hash + chr;
|
|
89652
|
+
hash |= 0; // Convert to 32bit integer
|
|
89653
|
+
}
|
|
89654
|
+
return hash;
|
|
89655
|
+
};
|
|
89107
89656
|
return StyleManager;
|
|
89108
89657
|
}());
|
|
89109
89658
|
|
|
@@ -89112,7 +89661,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
89112
89661
|
*/
|
|
89113
89662
|
var isHMREnabled = function () { return 'ENVIRONMENT' in window && !!window['ENVIRONMENT']['hmr']; };
|
|
89114
89663
|
|
|
89115
|
-
var __extends$
|
|
89664
|
+
var __extends$1f = (window && window.__extends) || (function () {
|
|
89116
89665
|
var extendStatics = function (d, b) {
|
|
89117
89666
|
extendStatics = Object.setPrototypeOf ||
|
|
89118
89667
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -89190,7 +89739,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
89190
89739
|
}
|
|
89191
89740
|
return ar;
|
|
89192
89741
|
};
|
|
89193
|
-
var __spreadArray$
|
|
89742
|
+
var __spreadArray$a = (window && window.__spreadArray) || function (to, from) {
|
|
89194
89743
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
89195
89744
|
to[j] = from[i];
|
|
89196
89745
|
return to;
|
|
@@ -89210,7 +89759,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
89210
89759
|
* The control for a visual and interactive web map.
|
|
89211
89760
|
*/
|
|
89212
89761
|
var Map$2 = /** @class */ (function (_super) {
|
|
89213
|
-
__extends$
|
|
89762
|
+
__extends$1f(Map, _super);
|
|
89214
89763
|
/**
|
|
89215
89764
|
* Displays a map in the specified container.
|
|
89216
89765
|
* @param container The id of the element where the map should be displayed.
|
|
@@ -89378,7 +89927,9 @@ uniform ${precision} ${type} u_${name};
|
|
|
89378
89927
|
_this.events.invoke("error", errorData);
|
|
89379
89928
|
});
|
|
89380
89929
|
// --> Set initial camera state of map
|
|
89381
|
-
_this.setCamera(__assign$b(__assign$b({
|
|
89930
|
+
_this.setCamera(__assign$b(__assign$b({
|
|
89931
|
+
// Default minZoom to ensure the map doesn't zoom out to unsupported zoom levels.
|
|
89932
|
+
minZoom: 1 }, options), { type: "jump", duration: 0 }));
|
|
89382
89933
|
// Add delegates to map
|
|
89383
89934
|
{
|
|
89384
89935
|
_this.incidentDelegate = new IncidentServiceDelegate(_this);
|
|
@@ -89609,6 +90160,9 @@ uniform ${precision} ${type} u_${name};
|
|
|
89609
90160
|
if (newOptions.showTileBoundaries !== this.styleOptions.showTileBoundaries) {
|
|
89610
90161
|
this.map.showTileBoundaries = newOptions.showTileBoundaries;
|
|
89611
90162
|
}
|
|
90163
|
+
if (newOptions.showBuildingModels) {
|
|
90164
|
+
console.warn("showBuildingModels is deprecated.");
|
|
90165
|
+
}
|
|
89612
90166
|
// Some delegates may rely on a styledata event to know when to check if the language changes.
|
|
89613
90167
|
// If this function is restructured such that a styledata event won't always trigger
|
|
89614
90168
|
// if the language is changed, then either those delegates need changed
|
|
@@ -90006,7 +90560,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
90006
90560
|
urls = layer.getOptions().subdomains || [];
|
|
90007
90561
|
}
|
|
90008
90562
|
// Add the tile urls to the layer, but don't update the map yet.
|
|
90009
|
-
urls.push.apply(urls, __spreadArray$
|
|
90563
|
+
urls.push.apply(urls, __spreadArray$a([], __read$g(tileSources)));
|
|
90010
90564
|
layer._setOptionsNoUpdate({
|
|
90011
90565
|
subdomains: urls
|
|
90012
90566
|
});
|
|
@@ -90133,6 +90687,9 @@ uniform ${precision} ${type} u_${name};
|
|
|
90133
90687
|
}
|
|
90134
90688
|
}
|
|
90135
90689
|
if (this.trafficOptions.flow && this.trafficOptions.flow !== "none") {
|
|
90690
|
+
if (["absolute", "relative-delay"].includes(this.trafficOptions.flow)) {
|
|
90691
|
+
console.warn("The 'absolute' and 'relative-delay' flow options are deprecated. Please use 'relative' instead.");
|
|
90692
|
+
}
|
|
90136
90693
|
try {
|
|
90137
90694
|
if (this.trafficOptions.flow !== previousFlowOption) {
|
|
90138
90695
|
this.flowDelegate.addToMap();
|
|
@@ -90175,9 +90732,13 @@ uniform ${precision} ${type} u_${name};
|
|
|
90175
90732
|
* Clean up the map's resources. Map will not function correctly after calling this method.
|
|
90176
90733
|
*/
|
|
90177
90734
|
Map.prototype.dispose = function () {
|
|
90735
|
+
var _a;
|
|
90178
90736
|
this.clear();
|
|
90179
90737
|
this.map.remove();
|
|
90738
|
+
(_a = this.authentication) === null || _a === void 0 ? void 0 : _a.dispose();
|
|
90180
90739
|
this.removed = true;
|
|
90740
|
+
// Remove event listeners
|
|
90741
|
+
window.removeEventListener("resize", this._windowResizeCallback);
|
|
90181
90742
|
while (this.getMapContainer().firstChild) {
|
|
90182
90743
|
var currChild = this.getMapContainer().firstChild;
|
|
90183
90744
|
this.getMapContainer().removeChild(currChild);
|
|
@@ -90522,7 +91083,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
90522
91083
|
}
|
|
90523
91084
|
return ar;
|
|
90524
91085
|
};
|
|
90525
|
-
var __spreadArray$
|
|
91086
|
+
var __spreadArray$b = (window && window.__spreadArray) || function (to, from) {
|
|
90526
91087
|
for (var i = 0, il = from.length, j = to.length; i < il; i++, j++)
|
|
90527
91088
|
to[j] = from[i];
|
|
90528
91089
|
return to;
|
|
@@ -90668,7 +91229,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
90668
91229
|
lineLength = 50;
|
|
90669
91230
|
}
|
|
90670
91231
|
var lines = c.split(/<(tr|div|br|li|h[0-9]|p>)/);
|
|
90671
|
-
longestStringLength = Math.max.apply(Math, __spreadArray$
|
|
91232
|
+
longestStringLength = Math.max.apply(Math, __spreadArray$b([], __read$h((lines.map(function (el) { return el.replace(/<[a-zA-Z0-9\s=\/]+>/g, "").length; }))))) - 1;
|
|
90672
91233
|
var w = Math.ceil(longestStringLength * 3.5);
|
|
90673
91234
|
if (w < width) {
|
|
90674
91235
|
width = w;
|