azure-maps-control 3.4.0 → 3.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/atlas-core-bare-snr-min.js +1 -1
- package/dist/atlas-core-bare-snr.js +260 -65
- package/dist/atlas-core-bare.js +260 -65
- package/dist/atlas-core-bare.min.js +1 -1
- package/dist/atlas-core-snr.js +260 -65
- package/dist/atlas-core.js +260 -65
- package/dist/atlas-core.min.js +1 -1
- package/dist/atlas-esm.js +260 -65
- package/dist/atlas-esm.min.js +1 -1
- package/dist/atlas.css +23 -3
- package/dist/atlas.js +260 -65
- package/dist/atlas.min.css +1 -1
- package/dist/atlas.min.js +1 -1
- package/package.json +8 -8
- package/thirdpartynotices.txt +0 -0
- package/typings/index.d.ts +123 -4
package/dist/atlas-core.js
CHANGED
|
@@ -51655,7 +51655,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
51655
51655
|
return Options;
|
|
51656
51656
|
}());
|
|
51657
51657
|
|
|
51658
|
-
var __extends$
|
|
51658
|
+
var __extends$1n = (window && window.__extends) || (function () {
|
|
51659
51659
|
var extendStatics = function (d, b) {
|
|
51660
51660
|
extendStatics = Object.setPrototypeOf ||
|
|
51661
51661
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -51690,7 +51690,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
51690
51690
|
* @private
|
|
51691
51691
|
*/
|
|
51692
51692
|
var UrlOptions = /** @class */ (function (_super) {
|
|
51693
|
-
__extends$
|
|
51693
|
+
__extends$1n(UrlOptions, _super);
|
|
51694
51694
|
function UrlOptions() {
|
|
51695
51695
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
51696
51696
|
_this.domain = undefined;
|
|
@@ -52094,6 +52094,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
52094
52094
|
* @param locale The requested culture code.
|
|
52095
52095
|
*/
|
|
52096
52096
|
Localizer.getCode = function (locale) {
|
|
52097
|
+
// If locale is set to 'auto', use the browser's configured language.
|
|
52098
|
+
if (locale.localeCompare("auto", undefined, { sensitivity: "base" }) === 0) {
|
|
52099
|
+
locale = navigator.language;
|
|
52100
|
+
}
|
|
52097
52101
|
var code = CultureCode.parse(locale);
|
|
52098
52102
|
// If the requested culture code includes a sensitive region simply return the original code.
|
|
52099
52103
|
// This is to hopefully reduce the risk or providing bad content to users in a sensitive region.
|
|
@@ -52217,7 +52221,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
52217
52221
|
return UserAgent;
|
|
52218
52222
|
}());
|
|
52219
52223
|
|
|
52220
|
-
var version$2 = "3.
|
|
52224
|
+
var version$2 = "3.6.0";
|
|
52221
52225
|
|
|
52222
52226
|
/**
|
|
52223
52227
|
* A helper class that provides methods for getting various forms of the map controls current version.
|
|
@@ -52249,7 +52253,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
52249
52253
|
return Version;
|
|
52250
52254
|
}());
|
|
52251
52255
|
|
|
52252
|
-
var __extends$
|
|
52256
|
+
var __extends$1m = (window && window.__extends) || (function () {
|
|
52253
52257
|
var extendStatics = function (d, b) {
|
|
52254
52258
|
extendStatics = Object.setPrototypeOf ||
|
|
52255
52259
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -52323,7 +52327,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
52323
52327
|
* Options for specifying how the map control should authenticate with the Azure Maps services.
|
|
52324
52328
|
*/
|
|
52325
52329
|
var AuthenticationOptions = /** @class */ (function (_super) {
|
|
52326
|
-
__extends$
|
|
52330
|
+
__extends$1m(AuthenticationOptions, _super);
|
|
52327
52331
|
function AuthenticationOptions() {
|
|
52328
52332
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
52329
52333
|
/**
|
|
@@ -52822,10 +52826,9 @@ uniform ${precision} ${type} u_${name};
|
|
|
52822
52826
|
* language is explicitly specified when using those parts of the API.
|
|
52823
52827
|
* If a Map is initialized with the language explicitly defined and
|
|
52824
52828
|
* setLanguage hasn't previously been called it will automatically be called by the Map constructor.
|
|
52825
|
-
* @param language The new default language.
|
|
52829
|
+
* @param language The new default language. If set to "auto", the browser's configured language will be used.
|
|
52826
52830
|
*/
|
|
52827
52831
|
function setLanguage(language) {
|
|
52828
|
-
// Find the best fit supported language.
|
|
52829
52832
|
defaultLanguage = Localizer.getCode(language);
|
|
52830
52833
|
hasSetLanguage = true;
|
|
52831
52834
|
}
|
|
@@ -53179,7 +53182,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53179
53182
|
eventTarget.addEventListener("keydown", dismissTooltip);
|
|
53180
53183
|
};
|
|
53181
53184
|
|
|
53182
|
-
var __extends$
|
|
53185
|
+
var __extends$1l = (window && window.__extends) || (function () {
|
|
53183
53186
|
var extendStatics = function (d, b) {
|
|
53184
53187
|
extendStatics = Object.setPrototypeOf ||
|
|
53185
53188
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -53229,7 +53232,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53229
53232
|
* The options for adding a control to the map.
|
|
53230
53233
|
*/
|
|
53231
53234
|
var ControlOptions = /** @class */ (function (_super) {
|
|
53232
|
-
__extends$
|
|
53235
|
+
__extends$1l(ControlOptions, _super);
|
|
53233
53236
|
function ControlOptions() {
|
|
53234
53237
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
53235
53238
|
/**
|
|
@@ -53373,7 +53376,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53373
53376
|
EventEmitter: EventEmitter
|
|
53374
53377
|
});
|
|
53375
53378
|
|
|
53376
|
-
var __extends$
|
|
53379
|
+
var __extends$1k = (window && window.__extends) || (function () {
|
|
53377
53380
|
var extendStatics = function (d, b) {
|
|
53378
53381
|
extendStatics = Object.setPrototypeOf ||
|
|
53379
53382
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -53393,7 +53396,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53393
53396
|
* Implements control interface and provides support for automatic styling based on the map style.
|
|
53394
53397
|
*/
|
|
53395
53398
|
var ControlBase = /** @class */ (function (_super) {
|
|
53396
|
-
__extends$
|
|
53399
|
+
__extends$1k(ControlBase, _super);
|
|
53397
53400
|
function ControlBase() {
|
|
53398
53401
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
53399
53402
|
/**
|
|
@@ -53495,7 +53498,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53495
53498
|
return ControlBase;
|
|
53496
53499
|
}(EventEmitter));
|
|
53497
53500
|
|
|
53498
|
-
var __extends$
|
|
53501
|
+
var __extends$1j = (window && window.__extends) || (function () {
|
|
53499
53502
|
var extendStatics = function (d, b) {
|
|
53500
53503
|
extendStatics = Object.setPrototypeOf ||
|
|
53501
53504
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -53514,7 +53517,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53514
53517
|
* The options for a CompassControl object.
|
|
53515
53518
|
*/
|
|
53516
53519
|
var CompassControlOptions = /** @class */ (function (_super) {
|
|
53517
|
-
__extends$
|
|
53520
|
+
__extends$1j(CompassControlOptions, _super);
|
|
53518
53521
|
function CompassControlOptions() {
|
|
53519
53522
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
53520
53523
|
/**
|
|
@@ -53539,7 +53542,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53539
53542
|
return CompassControlOptions;
|
|
53540
53543
|
}(Options));
|
|
53541
53544
|
|
|
53542
|
-
var __extends$
|
|
53545
|
+
var __extends$1i = (window && window.__extends) || (function () {
|
|
53543
53546
|
var extendStatics = function (d, b) {
|
|
53544
53547
|
extendStatics = Object.setPrototypeOf ||
|
|
53545
53548
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -53558,7 +53561,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53558
53561
|
* A control for changing the rotation of the map.
|
|
53559
53562
|
*/
|
|
53560
53563
|
var CompassControl = /** @class */ (function (_super) {
|
|
53561
|
-
__extends$
|
|
53564
|
+
__extends$1i(CompassControl, _super);
|
|
53562
53565
|
/**
|
|
53563
53566
|
* Constructs a CompassControl.
|
|
53564
53567
|
* @param options The options for the control.
|
|
@@ -53585,12 +53588,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
53585
53588
|
var expandGrid = function (expanded) {
|
|
53586
53589
|
if (expanded) {
|
|
53587
53590
|
container.classList.add("in-use");
|
|
53588
|
-
grid.setAttribute("aria-hidden", "false");
|
|
53589
53591
|
grid.classList.remove("hidden-accessible-element");
|
|
53590
53592
|
}
|
|
53591
53593
|
else {
|
|
53592
53594
|
container.classList.remove("in-use");
|
|
53593
|
-
grid.setAttribute("aria-hidden", "true");
|
|
53594
53595
|
grid.classList.add("hidden-accessible-element");
|
|
53595
53596
|
}
|
|
53596
53597
|
};
|
|
@@ -53657,7 +53658,6 @@ uniform ${precision} ${type} u_${name};
|
|
|
53657
53658
|
var grid = document.createElement("div");
|
|
53658
53659
|
grid.classList.add("sub-container");
|
|
53659
53660
|
grid.classList.add("hidden-accessible-element");
|
|
53660
|
-
grid.setAttribute("aria-hidden", "true");
|
|
53661
53661
|
var rotationRightButton = this.constructRightRotationButton(map);
|
|
53662
53662
|
var rotationLeftButton = this.constructLeftRotationButton(map);
|
|
53663
53663
|
var tooltipLeft = buildAccessibleTooltip("Rotate Left");
|
|
@@ -53743,7 +53743,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53743
53743
|
return CompassControl;
|
|
53744
53744
|
}(ControlBase));
|
|
53745
53745
|
|
|
53746
|
-
var __extends$
|
|
53746
|
+
var __extends$1h = (window && window.__extends) || (function () {
|
|
53747
53747
|
var extendStatics = function (d, b) {
|
|
53748
53748
|
extendStatics = Object.setPrototypeOf ||
|
|
53749
53749
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -53762,7 +53762,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53762
53762
|
* The options for a PitchControl object.
|
|
53763
53763
|
*/
|
|
53764
53764
|
var PitchControlOptions = /** @class */ (function (_super) {
|
|
53765
|
-
__extends$
|
|
53765
|
+
__extends$1h(PitchControlOptions, _super);
|
|
53766
53766
|
function PitchControlOptions() {
|
|
53767
53767
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
53768
53768
|
/**
|
|
@@ -53787,7 +53787,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53787
53787
|
return PitchControlOptions;
|
|
53788
53788
|
}(Options));
|
|
53789
53789
|
|
|
53790
|
-
var __extends$
|
|
53790
|
+
var __extends$1g = (window && window.__extends) || (function () {
|
|
53791
53791
|
var extendStatics = function (d, b) {
|
|
53792
53792
|
extendStatics = Object.setPrototypeOf ||
|
|
53793
53793
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -53806,7 +53806,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
53806
53806
|
* A control for changing the pitch of the map.
|
|
53807
53807
|
*/
|
|
53808
53808
|
var PitchControl = /** @class */ (function (_super) {
|
|
53809
|
-
__extends$
|
|
53809
|
+
__extends$1g(PitchControl, _super);
|
|
53810
53810
|
/**
|
|
53811
53811
|
* Constructs a PitchControl.
|
|
53812
53812
|
* @param options The options for the control.
|
|
@@ -53863,12 +53863,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
53863
53863
|
var expandGrid = function (expanded) {
|
|
53864
53864
|
if (expanded) {
|
|
53865
53865
|
container.classList.add("in-use");
|
|
53866
|
-
grid.setAttribute("aria-hidden", "false");
|
|
53867
53866
|
grid.classList.remove("hidden-accessible-element");
|
|
53868
53867
|
}
|
|
53869
53868
|
else {
|
|
53870
53869
|
container.classList.remove("in-use");
|
|
53871
|
-
grid.setAttribute("aria-hidden", "true");
|
|
53872
53870
|
grid.classList.add("hidden-accessible-element");
|
|
53873
53871
|
}
|
|
53874
53872
|
};
|
|
@@ -53953,7 +53951,6 @@ uniform ${precision} ${type} u_${name};
|
|
|
53953
53951
|
var grid = document.createElement("div");
|
|
53954
53952
|
grid.classList.add("sub-container");
|
|
53955
53953
|
grid.classList.add("hidden-accessible-element");
|
|
53956
|
-
grid.setAttribute("aria-hidden", "true");
|
|
53957
53954
|
this.pitchIncrementButton = this.constructPitchIncrementButton(map);
|
|
53958
53955
|
this.pitchDecrementButton = this.constructPitchDecrementButton(map);
|
|
53959
53956
|
var tooltipIncrement = buildAccessibleTooltip("Increase Pitch");
|
|
@@ -54034,7 +54031,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
54034
54031
|
return PitchControl;
|
|
54035
54032
|
}(ControlBase));
|
|
54036
54033
|
|
|
54037
|
-
var __extends$
|
|
54034
|
+
var __extends$1f = (window && window.__extends) || (function () {
|
|
54038
54035
|
var extendStatics = function (d, b) {
|
|
54039
54036
|
extendStatics = Object.setPrototypeOf ||
|
|
54040
54037
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -54053,7 +54050,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
54053
54050
|
* A control to display a scale bar on the map.
|
|
54054
54051
|
*/
|
|
54055
54052
|
var ScaleControl = /** @class */ (function (_super) {
|
|
54056
|
-
__extends$
|
|
54053
|
+
__extends$1f(ScaleControl, _super);
|
|
54057
54054
|
/**
|
|
54058
54055
|
* A control to displays a scale bar relative to the pixel resolution at the center of the map.
|
|
54059
54056
|
* @param options Options for defining how the control is rendered and functions.
|
|
@@ -57571,7 +57568,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57571
57568
|
|
|
57572
57569
|
var merge$1 = /*@__PURE__*/getDefaultExportFromCjs(merge_1);
|
|
57573
57570
|
|
|
57574
|
-
var __extends$
|
|
57571
|
+
var __extends$1e = (window && window.__extends) || (function () {
|
|
57575
57572
|
var extendStatics = function (d, b) {
|
|
57576
57573
|
extendStatics = Object.setPrototypeOf ||
|
|
57577
57574
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57590,7 +57587,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57590
57587
|
* The options for a StyleControl object.
|
|
57591
57588
|
*/
|
|
57592
57589
|
var StyleControlOptions = /** @class */ (function (_super) {
|
|
57593
|
-
__extends$
|
|
57590
|
+
__extends$1e(StyleControlOptions, _super);
|
|
57594
57591
|
function StyleControlOptions() {
|
|
57595
57592
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
57596
57593
|
/**
|
|
@@ -57635,7 +57632,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57635
57632
|
return StyleControlOptions;
|
|
57636
57633
|
}(Options));
|
|
57637
57634
|
|
|
57638
|
-
var __extends$
|
|
57635
|
+
var __extends$1d = (window && window.__extends) || (function () {
|
|
57639
57636
|
var extendStatics = function (d, b) {
|
|
57640
57637
|
extendStatics = Object.setPrototypeOf ||
|
|
57641
57638
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -57706,7 +57703,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
57706
57703
|
* A control for changing the style of the map.
|
|
57707
57704
|
*/
|
|
57708
57705
|
var StyleControl = /** @class */ (function (_super) {
|
|
57709
|
-
__extends$
|
|
57706
|
+
__extends$1d(StyleControl, _super);
|
|
57710
57707
|
/**
|
|
57711
57708
|
* Constructs a StyleControl.
|
|
57712
57709
|
* @param options The options for the control.
|
|
@@ -57770,12 +57767,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
57770
57767
|
var expandGrid = function (expanded) {
|
|
57771
57768
|
if (expanded) {
|
|
57772
57769
|
container.classList.add(StyleControl.Css.inUse);
|
|
57773
|
-
styleOpsGrid.setAttribute("aria-hidden", "false");
|
|
57774
57770
|
styleOpsGrid.classList.remove("hidden-accessible-element");
|
|
57775
57771
|
}
|
|
57776
57772
|
else {
|
|
57777
57773
|
container.classList.remove(StyleControl.Css.inUse);
|
|
57778
|
-
styleOpsGrid.setAttribute("aria-hidden", "true");
|
|
57779
57774
|
styleOpsGrid.classList.add("hidden-accessible-element");
|
|
57780
57775
|
}
|
|
57781
57776
|
};
|
|
@@ -58001,7 +57996,6 @@ uniform ${precision} ${type} u_${name};
|
|
|
58001
57996
|
}
|
|
58002
57997
|
styleOpsGrid.setAttribute("aria-label", "Style Options");
|
|
58003
57998
|
styleOpsGrid.classList.add("hidden-accessible-element");
|
|
58004
|
-
styleOpsGrid.setAttribute("aria-hidden", "true");
|
|
58005
57999
|
// Once the map's style definition is initialized create a map between style names and icons.
|
|
58006
58000
|
// If a style is one of those to be shown by the style picker also create it's element.
|
|
58007
58001
|
this.map.styles.definitions().then(function (definitions) { return __awaiter$7(_this, void 0, void 0, function () {
|
|
@@ -58071,7 +58065,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58071
58065
|
return StyleControl;
|
|
58072
58066
|
}(ControlBase));
|
|
58073
58067
|
|
|
58074
|
-
var __extends$
|
|
58068
|
+
var __extends$1c = (window && window.__extends) || (function () {
|
|
58075
58069
|
var extendStatics = function (d, b) {
|
|
58076
58070
|
extendStatics = Object.setPrototypeOf ||
|
|
58077
58071
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58090,7 +58084,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58090
58084
|
* The options for setting traffic on the map.
|
|
58091
58085
|
*/
|
|
58092
58086
|
var TrafficOptions = /** @class */ (function (_super) {
|
|
58093
|
-
__extends$
|
|
58087
|
+
__extends$1c(TrafficOptions, _super);
|
|
58094
58088
|
function TrafficOptions() {
|
|
58095
58089
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
58096
58090
|
/**
|
|
@@ -58115,7 +58109,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58115
58109
|
return TrafficOptions;
|
|
58116
58110
|
}(Options));
|
|
58117
58111
|
|
|
58118
|
-
var __extends$
|
|
58112
|
+
var __extends$1b = (window && window.__extends) || (function () {
|
|
58119
58113
|
var extendStatics = function (d, b) {
|
|
58120
58114
|
extendStatics = Object.setPrototypeOf ||
|
|
58121
58115
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58134,7 +58128,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58134
58128
|
* The options for a TrafficControl object.
|
|
58135
58129
|
*/
|
|
58136
58130
|
var TrafficControlOptions = /** @class */ (function (_super) {
|
|
58137
|
-
__extends$
|
|
58131
|
+
__extends$1b(TrafficControlOptions, _super);
|
|
58138
58132
|
function TrafficControlOptions() {
|
|
58139
58133
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
58140
58134
|
/**
|
|
@@ -58154,7 +58148,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58154
58148
|
return TrafficControlOptions;
|
|
58155
58149
|
}(TrafficOptions));
|
|
58156
58150
|
|
|
58157
|
-
var __extends$
|
|
58151
|
+
var __extends$1a = (window && window.__extends) || (function () {
|
|
58158
58152
|
var extendStatics = function (d, b) {
|
|
58159
58153
|
extendStatics = Object.setPrototypeOf ||
|
|
58160
58154
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58173,7 +58167,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58173
58167
|
* A control that toggles traffic data on the map.
|
|
58174
58168
|
*/
|
|
58175
58169
|
var TrafficControl = /** @class */ (function (_super) {
|
|
58176
|
-
__extends$
|
|
58170
|
+
__extends$1a(TrafficControl, _super);
|
|
58177
58171
|
/**
|
|
58178
58172
|
* Constructs a TrafficControl
|
|
58179
58173
|
* @param options The options for the control.
|
|
@@ -58300,7 +58294,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58300
58294
|
return TrafficControl;
|
|
58301
58295
|
}(ControlBase));
|
|
58302
58296
|
|
|
58303
|
-
var __extends$
|
|
58297
|
+
var __extends$19 = (window && window.__extends) || (function () {
|
|
58304
58298
|
var extendStatics = function (d, b) {
|
|
58305
58299
|
extendStatics = Object.setPrototypeOf ||
|
|
58306
58300
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -58330,7 +58324,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
58330
58324
|
* A control that display traffic legend on the map.
|
|
58331
58325
|
*/
|
|
58332
58326
|
var TrafficLegendControl = /** @class */ (function (_super) {
|
|
58333
|
-
__extends$
|
|
58327
|
+
__extends$19(TrafficLegendControl, _super);
|
|
58334
58328
|
/**
|
|
58335
58329
|
* Construct a traffic legend control
|
|
58336
58330
|
*/
|
|
@@ -59064,7 +59058,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59064
59058
|
return Feature;
|
|
59065
59059
|
}());
|
|
59066
59060
|
|
|
59067
|
-
var __extends$
|
|
59061
|
+
var __extends$18 = (window && window.__extends) || (function () {
|
|
59068
59062
|
var extendStatics = function (d, b) {
|
|
59069
59063
|
extendStatics = Object.setPrototypeOf ||
|
|
59070
59064
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -59083,7 +59077,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
59083
59077
|
* Represent a pixel coordinate or offset. Extends an array of [x, y].
|
|
59084
59078
|
*/
|
|
59085
59079
|
var Pixel = /** @class */ (function (_super) {
|
|
59086
|
-
__extends$
|
|
59080
|
+
__extends$18(Pixel, _super);
|
|
59087
59081
|
/**
|
|
59088
59082
|
* Constructs a Pixel object and initializes it with the specified x and y coordinates.
|
|
59089
59083
|
* @param x The horizontal pixel offset.
|
|
@@ -61303,7 +61297,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61303
61297
|
return result;
|
|
61304
61298
|
}
|
|
61305
61299
|
|
|
61306
|
-
var __extends$
|
|
61300
|
+
var __extends$17 = (window && window.__extends) || (function () {
|
|
61307
61301
|
var extendStatics = function (d, b) {
|
|
61308
61302
|
extendStatics = Object.setPrototypeOf ||
|
|
61309
61303
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -61323,7 +61317,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61323
61317
|
* full description is detailed in [RFC 7946]{@link https://tools.ietf.org/html/rfc7946#section-3.1.1}.
|
|
61324
61318
|
*/
|
|
61325
61319
|
var Position = /** @class */ (function (_super) {
|
|
61326
|
-
__extends$
|
|
61320
|
+
__extends$17(Position, _super);
|
|
61327
61321
|
/**
|
|
61328
61322
|
* Constructs a Position.
|
|
61329
61323
|
* @param longitude The position's longitude.
|
|
@@ -61515,7 +61509,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61515
61509
|
return Polygon;
|
|
61516
61510
|
}());
|
|
61517
61511
|
|
|
61518
|
-
var __extends$
|
|
61512
|
+
var __extends$16 = (window && window.__extends) || (function () {
|
|
61519
61513
|
var extendStatics = function (d, b) {
|
|
61520
61514
|
extendStatics = Object.setPrototypeOf ||
|
|
61521
61515
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -61545,7 +61539,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61545
61539
|
* A helper class that wraps a Geometry or Feature and makes it easy to update and maintain.
|
|
61546
61540
|
*/
|
|
61547
61541
|
var Shape = /** @class */ (function (_super) {
|
|
61548
|
-
__extends$
|
|
61542
|
+
__extends$16(Shape, _super);
|
|
61549
61543
|
function Shape(data, id, properties) {
|
|
61550
61544
|
var _this = _super.call(this) || this;
|
|
61551
61545
|
var geometry;
|
|
@@ -61841,7 +61835,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61841
61835
|
return Shape;
|
|
61842
61836
|
}(EventEmitter));
|
|
61843
61837
|
|
|
61844
|
-
var __extends$
|
|
61838
|
+
var __extends$15 = (window && window.__extends) || (function () {
|
|
61845
61839
|
var extendStatics = function (d, b) {
|
|
61846
61840
|
extendStatics = Object.setPrototypeOf ||
|
|
61847
61841
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -61874,7 +61868,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
61874
61868
|
* [RFC 7946]{@link https://tools.ietf.org/html/rfc7946#section-5}.
|
|
61875
61869
|
*/
|
|
61876
61870
|
var BoundingBox = /** @class */ (function (_super) {
|
|
61877
|
-
__extends$
|
|
61871
|
+
__extends$15(BoundingBox, _super);
|
|
61878
61872
|
function BoundingBox(southwestPositionOrPositions, northeastPosition) {
|
|
61879
61873
|
var _this = this;
|
|
61880
61874
|
if (southwestPositionOrPositions && northeastPosition) {
|
|
@@ -62591,7 +62585,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62591
62585
|
return MultiPolygon;
|
|
62592
62586
|
}());
|
|
62593
62587
|
|
|
62594
|
-
var __extends$
|
|
62588
|
+
var __extends$14 = (window && window.__extends) || (function () {
|
|
62595
62589
|
var extendStatics = function (d, b) {
|
|
62596
62590
|
extendStatics = Object.setPrototypeOf ||
|
|
62597
62591
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -62622,7 +62616,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
62622
62616
|
* The `z` dimension of `MercatorPoint` is conformal. A cube in the mercator coordinate space would be rendered as a cube.
|
|
62623
62617
|
*/
|
|
62624
62618
|
var MercatorPoint = /** @class */ (function (_super) {
|
|
62625
|
-
__extends$
|
|
62619
|
+
__extends$14(MercatorPoint, _super);
|
|
62626
62620
|
/**
|
|
62627
62621
|
* Constructs a MercatorPoint.
|
|
62628
62622
|
* @param x A points x position in mercator units.
|
|
@@ -63111,7 +63105,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63111
63105
|
simplify: simplify
|
|
63112
63106
|
});
|
|
63113
63107
|
|
|
63114
|
-
var __extends$
|
|
63108
|
+
var __extends$13 = (window && window.__extends) || (function () {
|
|
63115
63109
|
var extendStatics = function (d, b) {
|
|
63116
63110
|
extendStatics = Object.setPrototypeOf ||
|
|
63117
63111
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -63130,7 +63124,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63130
63124
|
* The options for a ZoomControl object.
|
|
63131
63125
|
*/
|
|
63132
63126
|
var ZoomControlOptions = /** @class */ (function (_super) {
|
|
63133
|
-
__extends$
|
|
63127
|
+
__extends$13(ZoomControlOptions, _super);
|
|
63134
63128
|
function ZoomControlOptions() {
|
|
63135
63129
|
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
63136
63130
|
/**
|
|
@@ -63150,7 +63144,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63150
63144
|
return ZoomControlOptions;
|
|
63151
63145
|
}(Options));
|
|
63152
63146
|
|
|
63153
|
-
var __extends$
|
|
63147
|
+
var __extends$12 = (window && window.__extends) || (function () {
|
|
63154
63148
|
var extendStatics = function (d, b) {
|
|
63155
63149
|
extendStatics = Object.setPrototypeOf ||
|
|
63156
63150
|
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
@@ -63169,7 +63163,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
63169
63163
|
* A control for changing the zoom of the map.
|
|
63170
63164
|
*/
|
|
63171
63165
|
var ZoomControl = /** @class */ (function (_super) {
|
|
63172
|
-
__extends$
|
|
63166
|
+
__extends$12(ZoomControl, _super);
|
|
63173
63167
|
/**
|
|
63174
63168
|
* Constructs a ZoomControl.
|
|
63175
63169
|
* @param options The options for the control.
|
|
@@ -63283,10 +63277,169 @@ uniform ${precision} ${type} u_${name};
|
|
|
63283
63277
|
return ZoomControl;
|
|
63284
63278
|
}(ControlBase));
|
|
63285
63279
|
|
|
63280
|
+
var __extends$11 = (window && window.__extends) || (function () {
|
|
63281
|
+
var extendStatics = function (d, b) {
|
|
63282
|
+
extendStatics = Object.setPrototypeOf ||
|
|
63283
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
63284
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
63285
|
+
return extendStatics(d, b);
|
|
63286
|
+
};
|
|
63287
|
+
return function (d, b) {
|
|
63288
|
+
if (typeof b !== "function" && b !== null)
|
|
63289
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
63290
|
+
extendStatics(d, b);
|
|
63291
|
+
function __() { this.constructor = d; }
|
|
63292
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
63293
|
+
};
|
|
63294
|
+
})();
|
|
63295
|
+
/**
|
|
63296
|
+
* The options for a FullscreenControl object.
|
|
63297
|
+
*/
|
|
63298
|
+
var FullscreenControlOptions = /** @class */ (function (_super) {
|
|
63299
|
+
__extends$11(FullscreenControlOptions, _super);
|
|
63300
|
+
function FullscreenControlOptions() {
|
|
63301
|
+
var _this = _super !== null && _super.apply(this, arguments) || this;
|
|
63302
|
+
/**
|
|
63303
|
+
* The style of the control.
|
|
63304
|
+
* Default `ControlStyle.light`
|
|
63305
|
+
* @default ControlStyle.light
|
|
63306
|
+
*/
|
|
63307
|
+
_this.style = exports.ControlStyle.light;
|
|
63308
|
+
/**
|
|
63309
|
+
* Indicates if the control should be hidden if the browser does not support fullscreen mode.
|
|
63310
|
+
* Default `false`
|
|
63311
|
+
* @default false
|
|
63312
|
+
*/
|
|
63313
|
+
_this.hideIfUnsupported = false;
|
|
63314
|
+
/**
|
|
63315
|
+
* The HTML element which should be made full screen.
|
|
63316
|
+
* If not specified, the map container element will be used.
|
|
63317
|
+
*/
|
|
63318
|
+
_this.container = undefined;
|
|
63319
|
+
return _this;
|
|
63320
|
+
}
|
|
63321
|
+
return FullscreenControlOptions;
|
|
63322
|
+
}(Options));
|
|
63323
|
+
|
|
63324
|
+
var __extends$10 = (window && window.__extends) || (function () {
|
|
63325
|
+
var extendStatics = function (d, b) {
|
|
63326
|
+
extendStatics = Object.setPrototypeOf ||
|
|
63327
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
63328
|
+
function (d, b) { for (var p in b) if (Object.prototype.hasOwnProperty.call(b, p)) d[p] = b[p]; };
|
|
63329
|
+
return extendStatics(d, b);
|
|
63330
|
+
};
|
|
63331
|
+
return function (d, b) {
|
|
63332
|
+
if (typeof b !== "function" && b !== null)
|
|
63333
|
+
throw new TypeError("Class extends value " + String(b) + " is not a constructor or null");
|
|
63334
|
+
extendStatics(d, b);
|
|
63335
|
+
function __() { this.constructor = d; }
|
|
63336
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
63337
|
+
};
|
|
63338
|
+
})();
|
|
63339
|
+
/**
|
|
63340
|
+
* A control to make the map or a specified element fullscreen.
|
|
63341
|
+
*/
|
|
63342
|
+
var FullscreenControl = /** @class */ (function (_super) {
|
|
63343
|
+
__extends$10(FullscreenControl, _super);
|
|
63344
|
+
/**
|
|
63345
|
+
* A control to make the map or a specified element fullscreen.
|
|
63346
|
+
* @param options Options for defining how the control is rendered and the container to be made fullscreen.
|
|
63347
|
+
*/
|
|
63348
|
+
function FullscreenControl(options) {
|
|
63349
|
+
var _this = _super.call(this) || this;
|
|
63350
|
+
_this.map = null;
|
|
63351
|
+
_this.isFullscreenState = false;
|
|
63352
|
+
_this.options = new FullscreenControlOptions().merge(options);
|
|
63353
|
+
_this.control = new maplibregl.FullscreenControl({
|
|
63354
|
+
container: _this.options.container,
|
|
63355
|
+
});
|
|
63356
|
+
return _this;
|
|
63357
|
+
}
|
|
63358
|
+
/**
|
|
63359
|
+
* Initialization method for the control which is called when added to the map.
|
|
63360
|
+
* @param map The map that the control will be added to.
|
|
63361
|
+
* @param options The ControlOptions for this control.
|
|
63362
|
+
* @return An HTMLElement to be placed on the map for the control.
|
|
63363
|
+
*/
|
|
63364
|
+
FullscreenControl.prototype.onAdd = function (map) {
|
|
63365
|
+
var _this = this;
|
|
63366
|
+
var _a, _b;
|
|
63367
|
+
this.map = map;
|
|
63368
|
+
(_b = (_a = this.map) === null || _a === void 0 ? void 0 : _a._getMap()) === null || _b === void 0 ? void 0 : _b.addControl(this.control);
|
|
63369
|
+
var container = this.buildContainer(map, this.options.style, "Fullscreen Control");
|
|
63370
|
+
var fullscreenButton = this.control._fullscreenButton;
|
|
63371
|
+
if (fullscreenButton) {
|
|
63372
|
+
var icon_1 = fullscreenButton.querySelector("span");
|
|
63373
|
+
if (icon_1) {
|
|
63374
|
+
var tooltip_1 = buildAccessibleTooltip("Enter Fullscreen");
|
|
63375
|
+
container.appendChild(fullscreenButton);
|
|
63376
|
+
// Add classes for styling.
|
|
63377
|
+
fullscreenButton.classList.add("azure-maps-control-button", "fullscreen");
|
|
63378
|
+
icon_1.classList.add("fullscreen-icon", "fullscreen-end");
|
|
63379
|
+
// Add the tooltip and prevent the default one set by Maplibre.
|
|
63380
|
+
fullscreenButton.removeAttribute("title"); // A title attribute will be converted to a tooltip by the browser.
|
|
63381
|
+
container.appendChild(tooltip_1);
|
|
63382
|
+
positionTooltip(tooltip_1, fullscreenButton);
|
|
63383
|
+
// Update the icon and the tooltip based on the fullscreen state.
|
|
63384
|
+
this.control.on("fullscreenstart", function () {
|
|
63385
|
+
// Remove the title attribute added automatically whenever fullscreen event is fired
|
|
63386
|
+
fullscreenButton.removeAttribute("title");
|
|
63387
|
+
icon_1.classList.remove("fullscreen-end");
|
|
63388
|
+
icon_1.classList.add("fullscreen-start");
|
|
63389
|
+
tooltip_1.innerText = "Exit Fullscreen";
|
|
63390
|
+
_this.isFullscreenState = true;
|
|
63391
|
+
});
|
|
63392
|
+
this.control.on("fullscreenend", function () {
|
|
63393
|
+
fullscreenButton.removeAttribute("title");
|
|
63394
|
+
icon_1.classList.remove("fullscreen-start");
|
|
63395
|
+
icon_1.classList.add("fullscreen-end");
|
|
63396
|
+
tooltip_1.innerText = "Enter Fullscreen";
|
|
63397
|
+
_this.isFullscreenState = false;
|
|
63398
|
+
});
|
|
63399
|
+
}
|
|
63400
|
+
}
|
|
63401
|
+
// Invisiblize the control if the browser does not support fullscreen mode.
|
|
63402
|
+
if (this.options.hideIfUnsupported && !FullscreenControl.isSupported()) {
|
|
63403
|
+
container.style.display = "none";
|
|
63404
|
+
}
|
|
63405
|
+
return container;
|
|
63406
|
+
};
|
|
63407
|
+
/**
|
|
63408
|
+
* Method that is called when the control is removed from the map. Should perform any necessary cleanup for the
|
|
63409
|
+
* control.
|
|
63410
|
+
*/
|
|
63411
|
+
FullscreenControl.prototype.onRemove = function () {
|
|
63412
|
+
var _a, _b;
|
|
63413
|
+
_super.prototype.onRemove.call(this);
|
|
63414
|
+
(_b = (_a = this.map) === null || _a === void 0 ? void 0 : _a._getMap()) === null || _b === void 0 ? void 0 : _b.removeControl(this.control);
|
|
63415
|
+
this.map = null;
|
|
63416
|
+
};
|
|
63417
|
+
/**
|
|
63418
|
+
* Gets the current fullscreen state of the map.
|
|
63419
|
+
* @returns A boolean indicating if the map is in fullscreen mode.
|
|
63420
|
+
*/
|
|
63421
|
+
FullscreenControl.prototype.isFullscreen = function () {
|
|
63422
|
+
return this.isFullscreenState;
|
|
63423
|
+
};
|
|
63424
|
+
/**
|
|
63425
|
+
* Checks to see if the browser supports going into fullscreen mode.
|
|
63426
|
+
* @returns A boolean indicating if the browser supports fullscreen mode.
|
|
63427
|
+
*/
|
|
63428
|
+
FullscreenControl.isSupported = function () {
|
|
63429
|
+
var d = document;
|
|
63430
|
+
return d['fullscreenEnabled'] ||
|
|
63431
|
+
d['msFullscreenEnabled'] ||
|
|
63432
|
+
d['mozFullScreenEnabled'] ||
|
|
63433
|
+
d['webkitFullscreenEnabled'];
|
|
63434
|
+
};
|
|
63435
|
+
return FullscreenControl;
|
|
63436
|
+
}(ControlBase));
|
|
63437
|
+
|
|
63286
63438
|
var index$2 = /*#__PURE__*/Object.freeze({
|
|
63287
63439
|
__proto__: null,
|
|
63288
63440
|
CompassControl: CompassControl,
|
|
63289
63441
|
ControlBase: ControlBase,
|
|
63442
|
+
FullscreenControl: FullscreenControl,
|
|
63290
63443
|
PitchControl: PitchControl,
|
|
63291
63444
|
ScaleControl: ScaleControl,
|
|
63292
63445
|
StyleControl: StyleControl,
|
|
@@ -65649,7 +65802,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
65649
65802
|
*/
|
|
65650
65803
|
ImageLayer.prototype.setOptions = function (options) {
|
|
65651
65804
|
var newOptions = new ImageLayerOptions().merge(this.options, cloneDeepWith$1(options, ImageLayerOptions._cloneCustomizer));
|
|
65652
|
-
var
|
|
65805
|
+
var reloadImage = (typeof options.url === "string" && options.url !== this.getOptions().url);
|
|
65653
65806
|
var coordChanged = (typeof options.coordinates !== "undefined" && options.coordinates !== this.getOptions().coordinates);
|
|
65654
65807
|
if (this.map) {
|
|
65655
65808
|
this._updateBaseProperties(newOptions, this.options);
|
|
@@ -65659,16 +65812,17 @@ uniform ${precision} ${type} u_${name};
|
|
|
65659
65812
|
this._updatePaintProperty("raster-brightness-max", newOptions.maxBrightness, this.options.maxBrightness);
|
|
65660
65813
|
this._updatePaintProperty("raster-opacity", newOptions.opacity, this.options.opacity);
|
|
65661
65814
|
this._updatePaintProperty("raster-saturation", newOptions.saturation, this.options.saturation);
|
|
65662
|
-
//
|
|
65663
|
-
// update "as any" to "as maplibregl.ImageSource" after the typing file is updated
|
|
65815
|
+
// Get the image source
|
|
65664
65816
|
var source = this.map._getMap().getSource(this._getSourceId());
|
|
65665
|
-
if
|
|
65817
|
+
// Check if the source exists and if we need to reload the image or if coordinates have changed
|
|
65818
|
+
if (source && (reloadImage || coordChanged)) {
|
|
65819
|
+
// Update the image with the new options
|
|
65666
65820
|
source.updateImage(newOptions);
|
|
65667
65821
|
}
|
|
65668
65822
|
}
|
|
65669
65823
|
this.options = newOptions;
|
|
65670
65824
|
// Modified to update transform if image url or coordinates change
|
|
65671
|
-
if (
|
|
65825
|
+
if (reloadImage) {
|
|
65672
65826
|
this.reloadImage();
|
|
65673
65827
|
}
|
|
65674
65828
|
else if (coordChanged) {
|
|
@@ -68200,6 +68354,7 @@ uniform ${precision} ${type} u_${name};
|
|
|
68200
68354
|
ele.addEventListener("click", this.close);
|
|
68201
68355
|
ele.classList.add(Popup.Css.close);
|
|
68202
68356
|
ele.setAttribute("aria-label", "close");
|
|
68357
|
+
ele.setAttribute("type", "button");
|
|
68203
68358
|
ele.setAttribute("tabindex", "0");
|
|
68204
68359
|
ele.innerHTML = "×";
|
|
68205
68360
|
return ele;
|
|
@@ -96314,6 +96469,12 @@ uniform ${precision} ${type} u_${name};
|
|
|
96314
96469
|
* @deprecated use `view` instead.
|
|
96315
96470
|
*/
|
|
96316
96471
|
_this.userRegion = _this.view;
|
|
96472
|
+
/**
|
|
96473
|
+
* Override the default styles for the map elements.
|
|
96474
|
+
* Default `undefined`
|
|
96475
|
+
* @default undefined
|
|
96476
|
+
*/
|
|
96477
|
+
_this.styleOverrides = undefined;
|
|
96317
96478
|
/**
|
|
96318
96479
|
* allows substituting a default MapControl's style transformer with custom one
|
|
96319
96480
|
* Default style transformer is meant to update the incoming fetched style to desired state, as well as to synchronize the SDK state with style state
|
|
@@ -96451,10 +96612,10 @@ uniform ${precision} ${type} u_${name};
|
|
|
96451
96612
|
/**
|
|
96452
96613
|
* Disable telemetry collection
|
|
96453
96614
|
* This option may only be set when initializing the map.
|
|
96454
|
-
* default:
|
|
96455
|
-
* @default
|
|
96615
|
+
* default: true
|
|
96616
|
+
* @default true
|
|
96456
96617
|
*/
|
|
96457
|
-
_this.disableTelemetry =
|
|
96618
|
+
_this.disableTelemetry = true;
|
|
96458
96619
|
/**
|
|
96459
96620
|
* Disable telemetry collection
|
|
96460
96621
|
* This option may only be set when initializing the map.
|
|
@@ -96947,6 +97108,16 @@ uniform ${precision} ${type} u_${name};
|
|
|
96947
97108
|
};
|
|
96948
97109
|
throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
|
|
96949
97110
|
};
|
|
97111
|
+
/**
|
|
97112
|
+
* Mapping of styleOverrides options to style parameter values.
|
|
97113
|
+
*/
|
|
97114
|
+
var styleOverridesMapping = {
|
|
97115
|
+
countryRegion: "cr|bv:0",
|
|
97116
|
+
adminDistrict: "ad|bv:0",
|
|
97117
|
+
adminDistrict2: "ds|bv:0",
|
|
97118
|
+
buildingFootprint: "bld|v:0_adr|lv:0",
|
|
97119
|
+
roadDetails: "g|rasterDetailsVisible:0"
|
|
97120
|
+
};
|
|
96950
97121
|
/**
|
|
96951
97122
|
* @private
|
|
96952
97123
|
*/
|
|
@@ -97457,7 +97628,31 @@ uniform ${precision} ${type} u_${name};
|
|
|
97457
97628
|
return targetStyleWithUserLayers;
|
|
97458
97629
|
};
|
|
97459
97630
|
}
|
|
97460
|
-
|
|
97631
|
+
var styleUrl = targetDefinition.url;
|
|
97632
|
+
if (styleUrl && (styleOptions === null || styleOptions === void 0 ? void 0 : styleOptions.styleOverrides)) {
|
|
97633
|
+
// Append the st parameter in the url with the mapped value.
|
|
97634
|
+
// We loop through the styleOverrides and join the corresponding st parameter with "_".
|
|
97635
|
+
var url = new URL(styleUrl);
|
|
97636
|
+
var params = new URLSearchParams(url.search);
|
|
97637
|
+
var stParams = Object.entries(styleOptions === null || styleOptions === void 0 ? void 0 : styleOptions.styleOverrides)
|
|
97638
|
+
.filter(function (_a) {
|
|
97639
|
+
var _b = __read$2(_a, 2), key = _b[0], value = _b[1];
|
|
97640
|
+
return key in styleOverridesMapping &&
|
|
97641
|
+
( // bv stands for borderVisible
|
|
97642
|
+
(styleOverridesMapping[key].includes('bv') && (value === null || value === void 0 ? void 0 : value.borderVisible) === false) ||
|
|
97643
|
+
(!styleOverridesMapping[key].includes('bv') && (value === null || value === void 0 ? void 0 : value.visible) === false));
|
|
97644
|
+
})
|
|
97645
|
+
.map(function (_a) {
|
|
97646
|
+
var _b = __read$2(_a, 2), key = _b[0]; _b[1];
|
|
97647
|
+
return styleOverridesMapping[key];
|
|
97648
|
+
});
|
|
97649
|
+
if (stParams.length > 0) {
|
|
97650
|
+
params.set("st", stParams.join("_"));
|
|
97651
|
+
url.search = params.toString();
|
|
97652
|
+
styleUrl = url.toString();
|
|
97653
|
+
}
|
|
97654
|
+
}
|
|
97655
|
+
this.map._getMap().setStyle(styleUrl || targetDefinition.style, {
|
|
97461
97656
|
diff: diff,
|
|
97462
97657
|
validate: this.serviceOptions.validateStyle,
|
|
97463
97658
|
transformStyle: transformStyleFunc
|