@nextgis/ngw-map 3.0.0-alpha.3 → 3.0.0-alpha.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.
@@ -1,4 +1,4 @@
1
- /** Bundle of @nextgis/ngw-map; version: 3.0.0-alpha.3; author: NextGIS */
1
+ /** Bundle of @nextgis/ngw-map; version: 3.0.0-alpha.4; author: NextGIS */
2
2
  var domain;
3
3
 
4
4
  // This constructor is used to store event handlers. Instantiating this is
@@ -824,12 +824,12 @@ function fixUrlStr(url) {
824
824
  return url.replace(/([^:]\/)\/+/g, "$1");
825
825
  }
826
826
 
827
- var __defProp$K = Object.defineProperty;
828
- var __defNormalProp$K = (obj, key, value) => key in obj ? __defProp$K(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
829
- var __publicField$v = (obj, key, value) => __defNormalProp$K(obj, typeof key !== "symbol" ? key + "" : key, value);
827
+ var __defProp$L = Object.defineProperty;
828
+ var __defNormalProp$L = (obj, key, value) => key in obj ? __defProp$L(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
829
+ var __publicField$w = (obj, key, value) => __defNormalProp$L(obj, typeof key !== "symbol" ? key + "" : key, value);
830
830
  const _Cache = class _Cache {
831
831
  constructor(options = {}) {
832
- __publicField$v(this, "cache", []);
832
+ __publicField$w(this, "cache", []);
833
833
  var _a;
834
834
  const namespace = (_a = options.namespace) != null ? _a : "default";
835
835
  if (_Cache.instance[namespace]) {
@@ -935,12 +935,12 @@ const _Cache = class _Cache {
935
935
  return objectDeepEqual(itemProps || {}, objectRemoveEmpty(props));
936
936
  }
937
937
  };
938
- __publicField$v(_Cache, "instance", {});
938
+ __publicField$w(_Cache, "instance", {});
939
939
  let Cache = _Cache;
940
940
 
941
941
  var pkg = {
942
942
  name: "@nextgis/ngw-connector",
943
- version: "3.0.0-alpha.3",
943
+ version: "3.0.0-alpha.4",
944
944
  _priority: 12,
945
945
  description: "A lightweight HTTP client optimized for use with NextGIS Web API",
946
946
  main: "index.js",
@@ -949,9 +949,9 @@ var pkg = {
949
949
  jsdelivr: "lib/ngw-connector.global.prod.js",
950
950
  types: "lib/index.d.ts",
951
951
  dependencies: {
952
- "@nextgis/cache": "^3.0.0-alpha.3",
952
+ "@nextgis/cache": "^3.0.0-alpha.4",
953
953
  "@nextgis/cancelable-promise": "^3.0.0-alpha.3",
954
- "@nextgis/utils": "^3.0.0-alpha.3",
954
+ "@nextgis/utils": "^3.0.0-alpha.4",
955
955
  "@types/events": "^3.0.0",
956
956
  events: "*",
957
957
  "form-data": "^4.0.0"
@@ -994,33 +994,33 @@ var pkg = {
994
994
  gitHead: "edc68033f914f6c95c4125b9738bba6d36e990b4"
995
995
  };
996
996
 
997
- var __defProp$J = Object.defineProperty;
998
- var __defNormalProp$J = (obj, key, value) => key in obj ? __defProp$J(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
999
- var __publicField$u = (obj, key, value) => __defNormalProp$J(obj, typeof key !== "symbol" ? key + "" : key, value);
997
+ var __defProp$K = Object.defineProperty;
998
+ var __defNormalProp$K = (obj, key, value) => key in obj ? __defProp$K(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
999
+ var __publicField$v = (obj, key, value) => __defNormalProp$K(obj, typeof key !== "symbol" ? key + "" : key, value);
1000
1000
  class NgwError extends Error {
1001
1001
  constructor(er) {
1002
1002
  super();
1003
- __publicField$u(this, "name", "NgwError");
1004
- __publicField$u(this, "title");
1005
- __publicField$u(this, "message");
1006
- __publicField$u(this, "detail");
1007
- __publicField$u(this, "exception");
1008
- __publicField$u(this, "status_code");
1009
- __publicField$u(this, "data");
1010
- __publicField$u(this, "guru_meditation");
1003
+ __publicField$v(this, "name", "NgwError");
1004
+ __publicField$v(this, "title");
1005
+ __publicField$v(this, "message");
1006
+ __publicField$v(this, "detail");
1007
+ __publicField$v(this, "exception");
1008
+ __publicField$v(this, "status_code");
1009
+ __publicField$v(this, "data");
1010
+ __publicField$v(this, "guru_meditation");
1011
1011
  Object.assign(this, er);
1012
1012
  Object.setPrototypeOf(this, NgwError.prototype);
1013
1013
  }
1014
1014
  }
1015
1015
 
1016
- var __defProp$I = Object.defineProperty;
1017
- var __defNormalProp$I = (obj, key, value) => key in obj ? __defProp$I(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1018
- var __publicField$t = (obj, key, value) => __defNormalProp$I(obj, typeof key !== "symbol" ? key + "" : key, value);
1016
+ var __defProp$J = Object.defineProperty;
1017
+ var __defNormalProp$J = (obj, key, value) => key in obj ? __defProp$J(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1018
+ var __publicField$u = (obj, key, value) => __defNormalProp$J(obj, typeof key !== "symbol" ? key + "" : key, value);
1019
1019
  class ResourceNotFoundError extends NgwError {
1020
1020
  constructor(obj) {
1021
1021
  super(obj);
1022
- __publicField$t(this, "name", "ResourceNotFoundError");
1023
- __publicField$t(this, "exception", "nextgisweb.resource.exception.ResourceNotFound");
1022
+ __publicField$u(this, "name", "ResourceNotFoundError");
1023
+ __publicField$u(this, "exception", "nextgisweb.resource.exception.ResourceNotFound");
1024
1024
  Object.setPrototypeOf(this, ResourceNotFoundError.prototype);
1025
1025
  }
1026
1026
  }
@@ -1054,23 +1054,23 @@ function resourceToQuery(resource, prefix = "") {
1054
1054
  return query;
1055
1055
  }
1056
1056
 
1057
- var __defProp$H = Object.defineProperty;
1057
+ var __defProp$I = Object.defineProperty;
1058
1058
  var __getOwnPropSymbols$w = Object.getOwnPropertySymbols;
1059
1059
  var __hasOwnProp$w = Object.prototype.hasOwnProperty;
1060
1060
  var __propIsEnum$w = Object.prototype.propertyIsEnumerable;
1061
- var __defNormalProp$H = (obj, key, value) => key in obj ? __defProp$H(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1061
+ var __defNormalProp$I = (obj, key, value) => key in obj ? __defProp$I(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1062
1062
  var __spreadValues$v = (a, b) => {
1063
1063
  for (var prop in b || (b = {}))
1064
1064
  if (__hasOwnProp$w.call(b, prop))
1065
- __defNormalProp$H(a, prop, b[prop]);
1065
+ __defNormalProp$I(a, prop, b[prop]);
1066
1066
  if (__getOwnPropSymbols$w)
1067
1067
  for (var prop of __getOwnPropSymbols$w(b)) {
1068
1068
  if (__propIsEnum$w.call(b, prop))
1069
- __defNormalProp$H(a, prop, b[prop]);
1069
+ __defNormalProp$I(a, prop, b[prop]);
1070
1070
  }
1071
1071
  return a;
1072
1072
  };
1073
- var __publicField$s = (obj, key, value) => __defNormalProp$H(obj, typeof key !== "symbol" ? key + "" : key, value);
1073
+ var __publicField$t = (obj, key, value) => __defNormalProp$I(obj, typeof key !== "symbol" ? key + "" : key, value);
1074
1074
  var __async$s = (__this, __arguments, generator) => {
1075
1075
  return new Promise((resolve, reject) => {
1076
1076
  var fulfilled = (value) => {
@@ -1096,8 +1096,8 @@ class ResourcesControl {
1096
1096
  connector,
1097
1097
  cacheId
1098
1098
  }) {
1099
- __publicField$s(this, "cache");
1100
- __publicField$s(this, "connector");
1099
+ __publicField$t(this, "cache");
1100
+ __publicField$t(this, "connector");
1101
1101
  this.connector = connector;
1102
1102
  this.cache = new Cache({ namespace: cacheId });
1103
1103
  }
@@ -1350,14 +1350,14 @@ class AbortError extends Error {
1350
1350
  }
1351
1351
  }
1352
1352
 
1353
- var __defProp$G = Object.defineProperty;
1354
- var __defNormalProp$G = (obj, key, value) => key in obj ? __defProp$G(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1355
- var __publicField$r = (obj, key, value) => __defNormalProp$G(obj, typeof key !== "symbol" ? key + "" : key, value);
1353
+ var __defProp$H = Object.defineProperty;
1354
+ var __defNormalProp$H = (obj, key, value) => key in obj ? __defProp$H(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1355
+ var __publicField$s = (obj, key, value) => __defNormalProp$H(obj, typeof key !== "symbol" ? key + "" : key, value);
1356
1356
  class InsufficientPermissionsError extends NgwError {
1357
1357
  constructor(obj) {
1358
1358
  super(obj);
1359
- __publicField$r(this, "name", "InsufficientPermissionsError");
1360
- __publicField$r(this, "exception", "nextgisweb.core.exception.InsufficientPermissions");
1359
+ __publicField$s(this, "name", "InsufficientPermissionsError");
1360
+ __publicField$s(this, "exception", "nextgisweb.core.exception.InsufficientPermissions");
1361
1361
  Object.setPrototypeOf(this, InsufficientPermissionsError.prototype);
1362
1362
  }
1363
1363
  }
@@ -1375,19 +1375,19 @@ function template(str, data) {
1375
1375
  });
1376
1376
  }
1377
1377
 
1378
- var __defProp$F = Object.defineProperty;
1378
+ var __defProp$G = Object.defineProperty;
1379
1379
  var __getOwnPropSymbols$v = Object.getOwnPropertySymbols;
1380
1380
  var __hasOwnProp$v = Object.prototype.hasOwnProperty;
1381
1381
  var __propIsEnum$v = Object.prototype.propertyIsEnumerable;
1382
- var __defNormalProp$F = (obj, key, value) => key in obj ? __defProp$F(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1382
+ var __defNormalProp$G = (obj, key, value) => key in obj ? __defProp$G(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1383
1383
  var __spreadValues$u = (a, b) => {
1384
1384
  for (var prop in b || (b = {}))
1385
1385
  if (__hasOwnProp$v.call(b, prop))
1386
- __defNormalProp$F(a, prop, b[prop]);
1386
+ __defNormalProp$G(a, prop, b[prop]);
1387
1387
  if (__getOwnPropSymbols$v)
1388
1388
  for (var prop of __getOwnPropSymbols$v(b)) {
1389
1389
  if (__propIsEnum$v.call(b, prop))
1390
- __defNormalProp$F(a, prop, b[prop]);
1390
+ __defNormalProp$G(a, prop, b[prop]);
1391
1391
  }
1392
1392
  return a;
1393
1393
  };
@@ -1462,13 +1462,13 @@ function apiRequest(opt) {
1462
1462
  });
1463
1463
  }
1464
1464
 
1465
- var __defProp$E = Object.defineProperty;
1466
- var __defNormalProp$E = (obj, key, value) => key in obj ? __defProp$E(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1467
- var __publicField$q = (obj, key, value) => __defNormalProp$E(obj, key + "" , value);
1465
+ var __defProp$F = Object.defineProperty;
1466
+ var __defNormalProp$F = (obj, key, value) => key in obj ? __defProp$F(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1467
+ var __publicField$r = (obj, key, value) => __defNormalProp$F(obj, key + "" , value);
1468
1468
  class NetworkError extends Error {
1469
1469
  constructor(url) {
1470
1470
  super();
1471
- __publicField$q(this, "name", "NetworkError");
1471
+ __publicField$r(this, "name", "NetworkError");
1472
1472
  Object.setPrototypeOf(this, NetworkError.prototype);
1473
1473
  this.message = `Unable to request ${url}.
1474
1474
  Possibly invalid NGW URL entered or CORS not configured to get request from ${location.origin}`;
@@ -1557,26 +1557,26 @@ let loadData;
1557
1557
  };
1558
1558
  }
1559
1559
 
1560
- var __defProp$D = Object.defineProperty;
1561
- var __defProps$f = Object.defineProperties;
1562
- var __getOwnPropDescs$f = Object.getOwnPropertyDescriptors;
1560
+ var __defProp$E = Object.defineProperty;
1561
+ var __defProps$g = Object.defineProperties;
1562
+ var __getOwnPropDescs$g = Object.getOwnPropertyDescriptors;
1563
1563
  var __getOwnPropSymbols$u = Object.getOwnPropertySymbols;
1564
1564
  var __hasOwnProp$u = Object.prototype.hasOwnProperty;
1565
1565
  var __propIsEnum$u = Object.prototype.propertyIsEnumerable;
1566
- var __defNormalProp$D = (obj, key, value) => key in obj ? __defProp$D(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1566
+ var __defNormalProp$E = (obj, key, value) => key in obj ? __defProp$E(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
1567
1567
  var __spreadValues$t = (a, b) => {
1568
1568
  for (var prop in b || (b = {}))
1569
1569
  if (__hasOwnProp$u.call(b, prop))
1570
- __defNormalProp$D(a, prop, b[prop]);
1570
+ __defNormalProp$E(a, prop, b[prop]);
1571
1571
  if (__getOwnPropSymbols$u)
1572
1572
  for (var prop of __getOwnPropSymbols$u(b)) {
1573
1573
  if (__propIsEnum$u.call(b, prop))
1574
- __defNormalProp$D(a, prop, b[prop]);
1574
+ __defNormalProp$E(a, prop, b[prop]);
1575
1575
  }
1576
1576
  return a;
1577
1577
  };
1578
- var __spreadProps$f = (a, b) => __defProps$f(a, __getOwnPropDescs$f(b));
1579
- var __objRest$2 = (source, exclude) => {
1578
+ var __spreadProps$g = (a, b) => __defProps$g(a, __getOwnPropDescs$g(b));
1579
+ var __objRest$3 = (source, exclude) => {
1580
1580
  var target = {};
1581
1581
  for (var prop in source)
1582
1582
  if (__hasOwnProp$u.call(source, prop) && exclude.indexOf(prop) < 0)
@@ -1588,7 +1588,7 @@ var __objRest$2 = (source, exclude) => {
1588
1588
  }
1589
1589
  return target;
1590
1590
  };
1591
- var __publicField$p = (obj, key, value) => __defNormalProp$D(obj, typeof key !== "symbol" ? key + "" : key, value);
1591
+ var __publicField$q = (obj, key, value) => __defNormalProp$E(obj, typeof key !== "symbol" ? key + "" : key, value);
1592
1592
  var __async$q = (__this, __arguments, generator) => {
1593
1593
  return new Promise((resolve, reject) => {
1594
1594
  var fulfilled = (value) => {
@@ -1614,16 +1614,16 @@ let REQUEST_ID = 0;
1614
1614
  class NgwConnector {
1615
1615
  constructor(options) {
1616
1616
  this.options = options;
1617
- __publicField$p(this, "id", ID$2++);
1618
- __publicField$p(this, "emitter", new EventEmitter());
1619
- __publicField$p(this, "user");
1620
- __publicField$p(this, "resources");
1621
- __publicField$p(this, "cache");
1622
- __publicField$p(this, "withCredentials");
1623
- __publicField$p(this, "client", `NextGIS-NGW-Connector/${pkg.version}`);
1624
- __publicField$p(this, "routeStr", "/api/component/pyramid/route");
1625
- __publicField$p(this, "activeRequests", {});
1626
- __publicField$p(this, "requestTransform");
1617
+ __publicField$q(this, "id", ID$2++);
1618
+ __publicField$q(this, "emitter", new EventEmitter());
1619
+ __publicField$q(this, "user");
1620
+ __publicField$q(this, "resources");
1621
+ __publicField$q(this, "cache");
1622
+ __publicField$q(this, "withCredentials");
1623
+ __publicField$q(this, "client", `NextGIS-NGW-Connector/${pkg.version}`);
1624
+ __publicField$q(this, "routeStr", "/api/component/pyramid/route");
1625
+ __publicField$q(this, "activeRequests", {});
1626
+ __publicField$q(this, "requestTransform");
1627
1627
  const exist = findConnector(options);
1628
1628
  this.cache = new Cache({ namespace: options.cacheId });
1629
1629
  if (exist) {
@@ -1907,7 +1907,7 @@ class NgwConnector {
1907
1907
  throw new Error("Empty `url` not allowed");
1908
1908
  }
1909
1909
  if (params) {
1910
- const _a = params, restParams = __objRest$2(_a, ["paramList"]);
1910
+ const _a = params, restParams = __objRest$3(_a, ["paramList"]);
1911
1911
  url = template(url, restParams);
1912
1912
  }
1913
1913
  url = encodeURI(fixUrlStr(url));
@@ -1943,7 +1943,7 @@ class NgwConnector {
1943
1943
  }
1944
1944
  });
1945
1945
  if (cache && method === "GET") {
1946
- const cacheOptions = cacheProps ? cacheProps : __spreadProps$f(__spreadValues$t({}, objectRemoveEmpty({
1946
+ const cacheOptions = cacheProps ? cacheProps : __spreadProps$g(__spreadValues$t({}, objectRemoveEmpty({
1947
1947
  headers,
1948
1948
  withCredentials,
1949
1949
  responseType,
@@ -2105,24 +2105,24 @@ class NgwConnector {
2105
2105
  return er;
2106
2106
  }
2107
2107
  }
2108
- __publicField$p(NgwConnector, "errors", {
2108
+ __publicField$q(NgwConnector, "errors", {
2109
2109
  NgwError,
2110
2110
  ResourceNotFoundError
2111
2111
  });
2112
2112
 
2113
- var __defProp$C = Object.defineProperty;
2113
+ var __defProp$D = Object.defineProperty;
2114
2114
  var __getOwnPropSymbols$t = Object.getOwnPropertySymbols;
2115
2115
  var __hasOwnProp$t = Object.prototype.hasOwnProperty;
2116
2116
  var __propIsEnum$t = Object.prototype.propertyIsEnumerable;
2117
- var __defNormalProp$C = (obj, key, value) => key in obj ? __defProp$C(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2117
+ var __defNormalProp$D = (obj, key, value) => key in obj ? __defProp$D(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2118
2118
  var __spreadValues$s = (a, b) => {
2119
2119
  for (var prop in b || (b = {}))
2120
2120
  if (__hasOwnProp$t.call(b, prop))
2121
- __defNormalProp$C(a, prop, b[prop]);
2121
+ __defNormalProp$D(a, prop, b[prop]);
2122
2122
  if (__getOwnPropSymbols$t)
2123
2123
  for (var prop of __getOwnPropSymbols$t(b)) {
2124
2124
  if (__propIsEnum$t.call(b, prop))
2125
- __defNormalProp$C(a, prop, b[prop]);
2125
+ __defNormalProp$D(a, prop, b[prop]);
2126
2126
  }
2127
2127
  return a;
2128
2128
  };
@@ -2204,25 +2204,25 @@ function propertiesFilter(properties, filters) {
2204
2204
  return logic === "any" ? filters_.some(filterFunction) : filters_.every(filterFunction);
2205
2205
  }
2206
2206
 
2207
- var __defProp$B = Object.defineProperty;
2208
- var __defProps$e = Object.defineProperties;
2209
- var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
2207
+ var __defProp$C = Object.defineProperty;
2208
+ var __defProps$f = Object.defineProperties;
2209
+ var __getOwnPropDescs$f = Object.getOwnPropertyDescriptors;
2210
2210
  var __getOwnPropSymbols$s = Object.getOwnPropertySymbols;
2211
2211
  var __hasOwnProp$s = Object.prototype.hasOwnProperty;
2212
2212
  var __propIsEnum$s = Object.prototype.propertyIsEnumerable;
2213
- var __defNormalProp$B = (obj, key, value) => key in obj ? __defProp$B(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2213
+ var __defNormalProp$C = (obj, key, value) => key in obj ? __defProp$C(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2214
2214
  var __spreadValues$r = (a, b) => {
2215
2215
  for (var prop in b || (b = {}))
2216
2216
  if (__hasOwnProp$s.call(b, prop))
2217
- __defNormalProp$B(a, prop, b[prop]);
2217
+ __defNormalProp$C(a, prop, b[prop]);
2218
2218
  if (__getOwnPropSymbols$s)
2219
2219
  for (var prop of __getOwnPropSymbols$s(b)) {
2220
2220
  if (__propIsEnum$s.call(b, prop))
2221
- __defNormalProp$B(a, prop, b[prop]);
2221
+ __defNormalProp$C(a, prop, b[prop]);
2222
2222
  }
2223
2223
  return a;
2224
2224
  };
2225
- var __spreadProps$e = (a, b) => __defProps$e(a, __getOwnPropDescs$e(b));
2225
+ var __spreadProps$f = (a, b) => __defProps$f(a, __getOwnPropDescs$f(b));
2226
2226
  var __async$p = (__this, __arguments, generator) => {
2227
2227
  return new Promise((resolve, reject) => {
2228
2228
  var fulfilled = (value) => {
@@ -2327,13 +2327,13 @@ function getQueries(opt, _queries = [], _parentAllParams = []) {
2327
2327
  for (const f of filters_) {
2328
2328
  if (isPropertyFilter(f)) {
2329
2329
  _queries.push(
2330
- fetchNgwLayerItemsRequest(__spreadProps$e(__spreadValues$r({}, opt), {
2330
+ fetchNgwLayerItemsRequest(__spreadProps$f(__spreadValues$r({}, opt), {
2331
2331
  paramList: [..._parentAllParams, ...paramList, createParam(f)]
2332
2332
  }))
2333
2333
  );
2334
2334
  } else {
2335
2335
  getQueries(
2336
- __spreadProps$e(__spreadValues$r({}, opt), {
2336
+ __spreadProps$f(__spreadValues$r({}, opt), {
2337
2337
  filters: f
2338
2338
  }),
2339
2339
  _queries,
@@ -2354,7 +2354,7 @@ function getQueries(opt, _queries = [], _parentAllParams = []) {
2354
2354
  if (propertiesFilterList.length) {
2355
2355
  for (const x of propertiesFilterList) {
2356
2356
  getQueries(
2357
- __spreadProps$e(__spreadValues$r({}, opt), {
2357
+ __spreadProps$f(__spreadValues$r({}, opt), {
2358
2358
  filters: x
2359
2359
  }),
2360
2360
  _queries,
@@ -2363,7 +2363,7 @@ function getQueries(opt, _queries = [], _parentAllParams = []) {
2363
2363
  }
2364
2364
  } else {
2365
2365
  _queries.push(
2366
- fetchNgwLayerItemsRequest(__spreadProps$e(__spreadValues$r({}, opt), {
2366
+ fetchNgwLayerItemsRequest(__spreadProps$f(__spreadValues$r({}, opt), {
2367
2367
  paramList: [..._parentAllParams, ...paramList, ...filters2]
2368
2368
  }))
2369
2369
  );
@@ -2428,25 +2428,25 @@ function fetchNgwLayerItemsRequest(options) {
2428
2428
  );
2429
2429
  }
2430
2430
 
2431
- var __defProp$A = Object.defineProperty;
2432
- var __defProps$d = Object.defineProperties;
2433
- var __getOwnPropDescs$d = Object.getOwnPropertyDescriptors;
2431
+ var __defProp$B = Object.defineProperty;
2432
+ var __defProps$e = Object.defineProperties;
2433
+ var __getOwnPropDescs$e = Object.getOwnPropertyDescriptors;
2434
2434
  var __getOwnPropSymbols$r = Object.getOwnPropertySymbols;
2435
2435
  var __hasOwnProp$r = Object.prototype.hasOwnProperty;
2436
2436
  var __propIsEnum$r = Object.prototype.propertyIsEnumerable;
2437
- var __defNormalProp$A = (obj, key, value) => key in obj ? __defProp$A(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2437
+ var __defNormalProp$B = (obj, key, value) => key in obj ? __defProp$B(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2438
2438
  var __spreadValues$q = (a, b) => {
2439
2439
  for (var prop in b || (b = {}))
2440
2440
  if (__hasOwnProp$r.call(b, prop))
2441
- __defNormalProp$A(a, prop, b[prop]);
2441
+ __defNormalProp$B(a, prop, b[prop]);
2442
2442
  if (__getOwnPropSymbols$r)
2443
2443
  for (var prop of __getOwnPropSymbols$r(b)) {
2444
2444
  if (__propIsEnum$r.call(b, prop))
2445
- __defNormalProp$A(a, prop, b[prop]);
2445
+ __defNormalProp$B(a, prop, b[prop]);
2446
2446
  }
2447
2447
  return a;
2448
2448
  };
2449
- var __spreadProps$d = (a, b) => __defProps$d(a, __getOwnPropDescs$d(b));
2449
+ var __spreadProps$e = (a, b) => __defProps$e(a, __getOwnPropDescs$e(b));
2450
2450
  var __async$o = (__this, __arguments, generator) => {
2451
2451
  return new Promise((resolve, reject) => {
2452
2452
  var fulfilled = (value) => {
@@ -2484,45 +2484,45 @@ function fetchNgwLayerItem(options) {
2484
2484
  if (resp.geom) {
2485
2485
  return createGeoJsonFeature(resp);
2486
2486
  } else {
2487
- const onlyGeomItem = yield fetchNgwLayerItem(__spreadProps$d(__spreadValues$q({}, options), {
2487
+ const onlyGeomItem = yield fetchNgwLayerItem(__spreadProps$e(__spreadValues$q({}, options), {
2488
2488
  geom: true,
2489
2489
  fields: null,
2490
2490
  extensions: null
2491
2491
  }));
2492
2492
  const geom = onlyGeomItem.geom;
2493
- return createGeoJsonFeature(__spreadProps$d(__spreadValues$q({}, resp), { geom }));
2493
+ return createGeoJsonFeature(__spreadProps$e(__spreadValues$q({}, resp), { geom }));
2494
2494
  }
2495
2495
  });
2496
- return __spreadProps$d(__spreadValues$q({}, resp), {
2496
+ return __spreadProps$e(__spreadValues$q({}, resp), {
2497
2497
  toGeojson
2498
2498
  });
2499
2499
  });
2500
2500
  }
2501
2501
 
2502
- var __defProp$z = Object.defineProperty;
2502
+ var __defProp$A = Object.defineProperty;
2503
2503
  var __getOwnPropSymbols$q = Object.getOwnPropertySymbols;
2504
2504
  var __hasOwnProp$q = Object.prototype.hasOwnProperty;
2505
2505
  var __propIsEnum$q = Object.prototype.propertyIsEnumerable;
2506
- var __defNormalProp$z = (obj, key, value) => key in obj ? __defProp$z(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2506
+ var __defNormalProp$A = (obj, key, value) => key in obj ? __defProp$A(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2507
2507
  var __spreadValues$p = (a, b) => {
2508
2508
  for (var prop in b || (b = {}))
2509
2509
  if (__hasOwnProp$q.call(b, prop))
2510
- __defNormalProp$z(a, prop, b[prop]);
2510
+ __defNormalProp$A(a, prop, b[prop]);
2511
2511
  if (__getOwnPropSymbols$q)
2512
2512
  for (var prop of __getOwnPropSymbols$q(b)) {
2513
2513
  if (__propIsEnum$q.call(b, prop))
2514
- __defNormalProp$z(a, prop, b[prop]);
2514
+ __defNormalProp$A(a, prop, b[prop]);
2515
2515
  }
2516
2516
  return a;
2517
2517
  };
2518
- var __publicField$o = (obj, key, value) => __defNormalProp$z(obj, typeof key !== "symbol" ? key + "" : key, value);
2518
+ var __publicField$p = (obj, key, value) => __defNormalProp$A(obj, typeof key !== "symbol" ? key + "" : key, value);
2519
2519
  class BookmarkItem {
2520
2520
  constructor(options) {
2521
2521
  this.options = options;
2522
- __publicField$o(this, "name");
2523
- __publicField$o(this, "resourceId");
2524
- __publicField$o(this, "item");
2525
- __publicField$o(this, "_extent");
2522
+ __publicField$p(this, "name");
2523
+ __publicField$p(this, "resourceId");
2524
+ __publicField$p(this, "item");
2525
+ __publicField$p(this, "_extent");
2526
2526
  this.resourceId = options.resourceId;
2527
2527
  const item = options.item;
2528
2528
  this.item = item;
@@ -2668,14 +2668,14 @@ function treeEvery_(item, filterFunc = (x) => !!x, relation, _filtered = []) {
2668
2668
  return true;
2669
2669
  }
2670
2670
 
2671
- var __defProp$y = Object.defineProperty;
2672
- var __defNormalProp$y = (obj, key, value) => key in obj ? __defProp$y(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2673
- var __publicField$n = (obj, key, value) => __defNormalProp$y(obj, typeof key !== "symbol" ? key + "" : key, value);
2671
+ var __defProp$z = Object.defineProperty;
2672
+ var __defNormalProp$z = (obj, key, value) => key in obj ? __defProp$z(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2673
+ var __publicField$o = (obj, key, value) => __defNormalProp$z(obj, typeof key !== "symbol" ? key + "" : key, value);
2674
2674
  class TreeHelper {
2675
2675
  constructor(item) {
2676
- __publicField$n(this, "item");
2677
- __publicField$n(this, "_children", []);
2678
- __publicField$n(this, "_parent");
2676
+ __publicField$o(this, "item");
2677
+ __publicField$o(this, "_children", []);
2678
+ __publicField$o(this, "_parent");
2679
2679
  this.item = item;
2680
2680
  }
2681
2681
  setParent(parent) {
@@ -2738,19 +2738,19 @@ class TreeHelper {
2738
2738
  }
2739
2739
  }
2740
2740
 
2741
- var __defProp$x = Object.defineProperty;
2742
- var __defNormalProp$x = (obj, key, value) => key in obj ? __defProp$x(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2743
- var __publicField$m = (obj, key, value) => __defNormalProp$x(obj, typeof key !== "symbol" ? key + "" : key, value);
2741
+ var __defProp$y = Object.defineProperty;
2742
+ var __defNormalProp$y = (obj, key, value) => key in obj ? __defProp$y(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2743
+ var __publicField$n = (obj, key, value) => __defNormalProp$y(obj, typeof key !== "symbol" ? key + "" : key, value);
2744
2744
  class BaseProperty {
2745
2745
  constructor(name, item, options) {
2746
- __publicField$m(this, "options");
2747
- __publicField$m(this, "emitter", new EventEmitter());
2748
- __publicField$m(this, "name");
2749
- __publicField$m(this, "item");
2750
- __publicField$m(this, "_blocked", false);
2751
- __publicField$m(this, "_container");
2752
- __publicField$m(this, "_value");
2753
- __publicField$m(this, "_removeEventsListener");
2746
+ __publicField$n(this, "options");
2747
+ __publicField$n(this, "emitter", new EventEmitter());
2748
+ __publicField$n(this, "name");
2749
+ __publicField$n(this, "item");
2750
+ __publicField$n(this, "_blocked", false);
2751
+ __publicField$n(this, "_container");
2752
+ __publicField$n(this, "_value");
2753
+ __publicField$n(this, "_removeEventsListener");
2754
2754
  this.item = item;
2755
2755
  this.options = Object.assign({}, options);
2756
2756
  this.name = name;
@@ -2847,23 +2847,23 @@ class BaseProperty {
2847
2847
  }
2848
2848
  }
2849
2849
 
2850
- var __defProp$w = Object.defineProperty;
2850
+ var __defProp$x = Object.defineProperty;
2851
2851
  var __getOwnPropSymbols$p = Object.getOwnPropertySymbols;
2852
2852
  var __hasOwnProp$p = Object.prototype.hasOwnProperty;
2853
2853
  var __propIsEnum$p = Object.prototype.propertyIsEnumerable;
2854
- var __defNormalProp$w = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2854
+ var __defNormalProp$x = (obj, key, value) => key in obj ? __defProp$x(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2855
2855
  var __spreadValues$o = (a, b) => {
2856
2856
  for (var prop in b || (b = {}))
2857
2857
  if (__hasOwnProp$p.call(b, prop))
2858
- __defNormalProp$w(a, prop, b[prop]);
2858
+ __defNormalProp$x(a, prop, b[prop]);
2859
2859
  if (__getOwnPropSymbols$p)
2860
2860
  for (var prop of __getOwnPropSymbols$p(b)) {
2861
2861
  if (__propIsEnum$p.call(b, prop))
2862
- __defNormalProp$w(a, prop, b[prop]);
2862
+ __defNormalProp$x(a, prop, b[prop]);
2863
2863
  }
2864
2864
  return a;
2865
2865
  };
2866
- var __publicField$l = (obj, key, value) => __defNormalProp$w(obj, key + "" , value);
2866
+ var __publicField$m = (obj, key, value) => __defNormalProp$x(obj, key + "" , value);
2867
2867
  const _CheckProperty = class _CheckProperty extends BaseProperty {
2868
2868
  constructor(name, item, options) {
2869
2869
  super(name, item, __spreadValues$o(__spreadValues$o({}, _CheckProperty.options), options));
@@ -2971,7 +2971,7 @@ const _CheckProperty = class _CheckProperty extends BaseProperty {
2971
2971
  }
2972
2972
  }
2973
2973
  };
2974
- __publicField$l(_CheckProperty, "options", {
2974
+ __publicField$m(_CheckProperty, "options", {
2975
2975
  hierarchy: true,
2976
2976
  bubble: false,
2977
2977
  propagation: false,
@@ -2980,31 +2980,31 @@ __publicField$l(_CheckProperty, "options", {
2980
2980
  });
2981
2981
  let CheckProperty = _CheckProperty;
2982
2982
 
2983
- var __defProp$v = Object.defineProperty;
2983
+ var __defProp$w = Object.defineProperty;
2984
2984
  var __getOwnPropSymbols$o = Object.getOwnPropertySymbols;
2985
2985
  var __hasOwnProp$o = Object.prototype.hasOwnProperty;
2986
2986
  var __propIsEnum$o = Object.prototype.propertyIsEnumerable;
2987
- var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2987
+ var __defNormalProp$w = (obj, key, value) => key in obj ? __defProp$w(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
2988
2988
  var __spreadValues$n = (a, b) => {
2989
2989
  for (var prop in b || (b = {}))
2990
2990
  if (__hasOwnProp$o.call(b, prop))
2991
- __defNormalProp$v(a, prop, b[prop]);
2991
+ __defNormalProp$w(a, prop, b[prop]);
2992
2992
  if (__getOwnPropSymbols$o)
2993
2993
  for (var prop of __getOwnPropSymbols$o(b)) {
2994
2994
  if (__propIsEnum$o.call(b, prop))
2995
- __defNormalProp$v(a, prop, b[prop]);
2995
+ __defNormalProp$w(a, prop, b[prop]);
2996
2996
  }
2997
2997
  return a;
2998
2998
  };
2999
- var __publicField$k = (obj, key, value) => __defNormalProp$v(obj, typeof key !== "symbol" ? key + "" : key, value);
2999
+ var __publicField$l = (obj, key, value) => __defNormalProp$w(obj, typeof key !== "symbol" ? key + "" : key, value);
3000
3000
  const BOOLEAN_TYPE = "boolean";
3001
3001
  const STRING_TYPE = "string";
3002
3002
  const _ItemProperties = class _ItemProperties {
3003
3003
  constructor(item, propertiesList) {
3004
3004
  this.item = item;
3005
- __publicField$k(this, "options", {});
3006
- __publicField$k(this, "_properties", {});
3007
- __publicField$k(this, "_propertiesList", []);
3005
+ __publicField$l(this, "options", {});
3006
+ __publicField$l(this, "_properties", {});
3007
+ __publicField$l(this, "_propertiesList", []);
3008
3008
  if (propertiesList) {
3009
3009
  propertiesList.forEach(this._setPropertyHandler.bind(this));
3010
3010
  }
@@ -3067,35 +3067,35 @@ const _ItemProperties = class _ItemProperties {
3067
3067
  return Handler;
3068
3068
  }
3069
3069
  };
3070
- __publicField$k(_ItemProperties, "handlers", {
3070
+ __publicField$l(_ItemProperties, "handlers", {
3071
3071
  CheckProperty
3072
3072
  });
3073
3073
  let ItemProperties = _ItemProperties;
3074
3074
 
3075
- var __defProp$u = Object.defineProperty;
3075
+ var __defProp$v = Object.defineProperty;
3076
3076
  var __getOwnPropSymbols$n = Object.getOwnPropertySymbols;
3077
3077
  var __hasOwnProp$n = Object.prototype.hasOwnProperty;
3078
3078
  var __propIsEnum$n = Object.prototype.propertyIsEnumerable;
3079
- var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3079
+ var __defNormalProp$v = (obj, key, value) => key in obj ? __defProp$v(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3080
3080
  var __spreadValues$m = (a, b) => {
3081
3081
  for (var prop in b || (b = {}))
3082
3082
  if (__hasOwnProp$n.call(b, prop))
3083
- __defNormalProp$u(a, prop, b[prop]);
3083
+ __defNormalProp$v(a, prop, b[prop]);
3084
3084
  if (__getOwnPropSymbols$n)
3085
3085
  for (var prop of __getOwnPropSymbols$n(b)) {
3086
3086
  if (__propIsEnum$n.call(b, prop))
3087
- __defNormalProp$u(a, prop, b[prop]);
3087
+ __defNormalProp$v(a, prop, b[prop]);
3088
3088
  }
3089
3089
  return a;
3090
3090
  };
3091
- var __publicField$j = (obj, key, value) => __defNormalProp$u(obj, typeof key !== "symbol" ? key + "" : key, value);
3091
+ var __publicField$k = (obj, key, value) => __defNormalProp$v(obj, typeof key !== "symbol" ? key + "" : key, value);
3092
3092
  let ID$1 = 0;
3093
3093
  class Item {
3094
3094
  constructor(options) {
3095
- __publicField$j(this, "options", {});
3096
- __publicField$j(this, "properties");
3097
- __publicField$j(this, "tree");
3098
- __publicField$j(this, "id", ID$1);
3095
+ __publicField$k(this, "options", {});
3096
+ __publicField$k(this, "properties");
3097
+ __publicField$k(this, "tree");
3098
+ __publicField$k(this, "id", ID$1);
3099
3099
  ID$1 += 1;
3100
3100
  this.options = __spreadValues$m({}, options);
3101
3101
  this.tree = new TreeHelper(this);
@@ -3149,25 +3149,25 @@ class WebmapLayerOpacityPropertyHandler extends BaseProperty {
3149
3149
  }
3150
3150
  }
3151
3151
 
3152
- var __defProp$t = Object.defineProperty;
3153
- var __defProps$c = Object.defineProperties;
3154
- var __getOwnPropDescs$c = Object.getOwnPropertyDescriptors;
3152
+ var __defProp$u = Object.defineProperty;
3153
+ var __defProps$d = Object.defineProperties;
3154
+ var __getOwnPropDescs$d = Object.getOwnPropertyDescriptors;
3155
3155
  var __getOwnPropSymbols$m = Object.getOwnPropertySymbols;
3156
3156
  var __hasOwnProp$m = Object.prototype.hasOwnProperty;
3157
3157
  var __propIsEnum$m = Object.prototype.propertyIsEnumerable;
3158
- var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3158
+ var __defNormalProp$u = (obj, key, value) => key in obj ? __defProp$u(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3159
3159
  var __spreadValues$l = (a, b) => {
3160
3160
  for (var prop in b || (b = {}))
3161
3161
  if (__hasOwnProp$m.call(b, prop))
3162
- __defNormalProp$t(a, prop, b[prop]);
3162
+ __defNormalProp$u(a, prop, b[prop]);
3163
3163
  if (__getOwnPropSymbols$m)
3164
3164
  for (var prop of __getOwnPropSymbols$m(b)) {
3165
3165
  if (__propIsEnum$m.call(b, prop))
3166
- __defNormalProp$t(a, prop, b[prop]);
3166
+ __defNormalProp$u(a, prop, b[prop]);
3167
3167
  }
3168
3168
  return a;
3169
3169
  };
3170
- var __spreadProps$c = (a, b) => __defProps$c(a, __getOwnPropDescs$c(b));
3170
+ var __spreadProps$d = (a, b) => __defProps$d(a, __getOwnPropDescs$d(b));
3171
3171
  function getNgwWebmapExtent(webmap) {
3172
3172
  const bottom = webmap["extent_bottom"];
3173
3173
  const left = webmap["extent_left"];
@@ -3235,14 +3235,14 @@ function fetchNgwResourceExtent(item, connector, options) {
3235
3235
  if (resource.cls && resource.cls.indexOf("style") !== -1) {
3236
3236
  return connector.getResource(resource.parent.id, options).then((res) => {
3237
3237
  if (res) {
3238
- return fetchNgwLayerExtent(__spreadProps$c(__spreadValues$l({}, options), {
3238
+ return fetchNgwLayerExtent(__spreadProps$d(__spreadValues$l({}, options), {
3239
3239
  resourceId: res.resource.id,
3240
3240
  connector
3241
3241
  }));
3242
3242
  }
3243
3243
  });
3244
3244
  } else {
3245
- return fetchNgwLayerExtent(__spreadProps$c(__spreadValues$l({}, options), {
3245
+ return fetchNgwLayerExtent(__spreadProps$d(__spreadValues$l({}, options), {
3246
3246
  resourceId: resource.id,
3247
3247
  connector
3248
3248
  }));
@@ -3250,9 +3250,9 @@ function fetchNgwResourceExtent(item, connector, options) {
3250
3250
  }
3251
3251
  }
3252
3252
 
3253
- var __defProp$s = Object.defineProperty;
3254
- var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3255
- var __publicField$i = (obj, key, value) => __defNormalProp$s(obj, typeof key !== "symbol" ? key + "" : key, value);
3253
+ var __defProp$t = Object.defineProperty;
3254
+ var __defNormalProp$t = (obj, key, value) => key in obj ? __defProp$t(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3255
+ var __publicField$j = (obj, key, value) => __defNormalProp$t(obj, typeof key !== "symbol" ? key + "" : key, value);
3256
3256
  var __async$n = (__this, __arguments, generator) => {
3257
3257
  return new Promise((resolve, reject) => {
3258
3258
  var fulfilled = (value) => {
@@ -3275,9 +3275,9 @@ var __async$n = (__this, __arguments, generator) => {
3275
3275
  };
3276
3276
  class NgwResource {
3277
3277
  constructor() {
3278
- __publicField$i(this, "item");
3279
- __publicField$i(this, "connector");
3280
- __publicField$i(this, "_extent");
3278
+ __publicField$j(this, "item");
3279
+ __publicField$j(this, "connector");
3280
+ __publicField$j(this, "_extent");
3281
3281
  }
3282
3282
  /** @deprecated use {@link NgwResource.getBounds} instead */
3283
3283
  getExtent() {
@@ -3396,23 +3396,23 @@ function updateQmsOptions(qms) {
3396
3396
  };
3397
3397
  }
3398
3398
 
3399
- var __defProp$r = Object.defineProperty;
3399
+ var __defProp$s = Object.defineProperty;
3400
3400
  var __getOwnPropSymbols$l = Object.getOwnPropertySymbols;
3401
3401
  var __hasOwnProp$l = Object.prototype.hasOwnProperty;
3402
3402
  var __propIsEnum$l = Object.prototype.propertyIsEnumerable;
3403
- var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3403
+ var __defNormalProp$s = (obj, key, value) => key in obj ? __defProp$s(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3404
3404
  var __spreadValues$k = (a, b) => {
3405
3405
  for (var prop in b || (b = {}))
3406
3406
  if (__hasOwnProp$l.call(b, prop))
3407
- __defNormalProp$r(a, prop, b[prop]);
3407
+ __defNormalProp$s(a, prop, b[prop]);
3408
3408
  if (__getOwnPropSymbols$l)
3409
3409
  for (var prop of __getOwnPropSymbols$l(b)) {
3410
3410
  if (__propIsEnum$l.call(b, prop))
3411
- __defNormalProp$r(a, prop, b[prop]);
3411
+ __defNormalProp$s(a, prop, b[prop]);
3412
3412
  }
3413
3413
  return a;
3414
3414
  };
3415
- var __objRest$1 = (source, exclude) => {
3415
+ var __objRest$2 = (source, exclude) => {
3416
3416
  var target = {};
3417
3417
  for (var prop in source)
3418
3418
  if (__hasOwnProp$l.call(source, prop) && exclude.indexOf(prop) < 0)
@@ -3424,7 +3424,7 @@ var __objRest$1 = (source, exclude) => {
3424
3424
  }
3425
3425
  return target;
3426
3426
  };
3427
- var __publicField$h = (obj, key, value) => __defNormalProp$r(obj, typeof key !== "symbol" ? key + "" : key, value);
3427
+ var __publicField$i = (obj, key, value) => __defNormalProp$s(obj, typeof key !== "symbol" ? key + "" : key, value);
3428
3428
  var __async$l = (__this, __arguments, generator) => {
3429
3429
  return new Promise((resolve, reject) => {
3430
3430
  var fulfilled = (value) => {
@@ -3449,7 +3449,7 @@ const URL = "https://qms.nextgis.com";
3449
3449
  function createQmsAdapter(webMapOrOptions, url = URL, createOpt = {}) {
3450
3450
  let webMap;
3451
3451
  if ("webMap" in webMapOrOptions) {
3452
- const _a = webMapOrOptions, { webMap: webMap_, url: url_ } = _a, adapterOptions = __objRest$1(_a, ["webMap", "url"]);
3452
+ const _a = webMapOrOptions, { webMap: webMap_, url: url_ } = _a, adapterOptions = __objRest$2(_a, ["webMap", "url"]);
3453
3453
  webMap = webMap_;
3454
3454
  if (url_) {
3455
3455
  url = url_;
@@ -3465,9 +3465,9 @@ function createQmsAdapter(webMapOrOptions, url = URL, createOpt = {}) {
3465
3465
  }
3466
3466
  class QmsAdapter {
3467
3467
  constructor(map, options) {
3468
- __publicField$h(this, "qms");
3469
- __publicField$h(this, "options");
3470
- __publicField$h(this, "map");
3468
+ __publicField$i(this, "qms");
3469
+ __publicField$i(this, "options");
3470
+ __publicField$i(this, "map");
3471
3471
  this.map = map;
3472
3472
  const opt = __spreadValues$k(__spreadValues$k({}, createOpt), options);
3473
3473
  this.options = opt;
@@ -3521,29 +3521,29 @@ function createQmsAdapter(webMapOrOptions, url = URL, createOpt = {}) {
3521
3521
  return QmsAdapter;
3522
3522
  }
3523
3523
 
3524
- var __defProp$q = Object.defineProperty;
3524
+ var __defProp$r = Object.defineProperty;
3525
3525
  var __getOwnPropSymbols$k = Object.getOwnPropertySymbols;
3526
3526
  var __hasOwnProp$k = Object.prototype.hasOwnProperty;
3527
3527
  var __propIsEnum$k = Object.prototype.propertyIsEnumerable;
3528
- var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3528
+ var __defNormalProp$r = (obj, key, value) => key in obj ? __defProp$r(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3529
3529
  var __spreadValues$j = (a, b) => {
3530
3530
  for (var prop in b || (b = {}))
3531
3531
  if (__hasOwnProp$k.call(b, prop))
3532
- __defNormalProp$q(a, prop, b[prop]);
3532
+ __defNormalProp$r(a, prop, b[prop]);
3533
3533
  if (__getOwnPropSymbols$k)
3534
3534
  for (var prop of __getOwnPropSymbols$k(b)) {
3535
3535
  if (__propIsEnum$k.call(b, prop))
3536
- __defNormalProp$q(a, prop, b[prop]);
3536
+ __defNormalProp$r(a, prop, b[prop]);
3537
3537
  }
3538
3538
  return a;
3539
3539
  };
3540
- var __publicField$g = (obj, key, value) => __defNormalProp$q(obj, typeof key !== "symbol" ? key + "" : key, value);
3540
+ var __publicField$h = (obj, key, value) => __defNormalProp$r(obj, typeof key !== "symbol" ? key + "" : key, value);
3541
3541
  class QmsKit {
3542
3542
  constructor(options) {
3543
- __publicField$g(this, "options", {
3543
+ __publicField$h(this, "options", {
3544
3544
  url: "https://qms.nextgis.com"
3545
3545
  });
3546
- __publicField$g(this, "url");
3546
+ __publicField$h(this, "url");
3547
3547
  this.options = __spreadValues$j(__spreadValues$j({}, this.options), options);
3548
3548
  this.url = this.options.url;
3549
3549
  }
@@ -3559,31 +3559,31 @@ class QmsKit {
3559
3559
  return createQmsAdapter({ webMap, url: this.url });
3560
3560
  }
3561
3561
  }
3562
- __publicField$g(QmsKit, "utils", {
3562
+ __publicField$h(QmsKit, "utils", {
3563
3563
  createQmsAdapter
3564
3564
  });
3565
3565
 
3566
- var __defProp$p = Object.defineProperty;
3567
- var __defProps$b = Object.defineProperties;
3568
- var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;
3566
+ var __defProp$q = Object.defineProperty;
3567
+ var __defProps$c = Object.defineProperties;
3568
+ var __getOwnPropDescs$c = Object.getOwnPropertyDescriptors;
3569
3569
  var __getOwnPropSymbols$j = Object.getOwnPropertySymbols;
3570
3570
  var __getProtoOf$2 = Object.getPrototypeOf;
3571
3571
  var __hasOwnProp$j = Object.prototype.hasOwnProperty;
3572
3572
  var __propIsEnum$j = Object.prototype.propertyIsEnumerable;
3573
3573
  var __reflectGet$2 = Reflect.get;
3574
- var __defNormalProp$p = (obj, key, value) => key in obj ? __defProp$p(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3574
+ var __defNormalProp$q = (obj, key, value) => key in obj ? __defProp$q(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3575
3575
  var __spreadValues$i = (a, b) => {
3576
3576
  for (var prop in b || (b = {}))
3577
3577
  if (__hasOwnProp$j.call(b, prop))
3578
- __defNormalProp$p(a, prop, b[prop]);
3578
+ __defNormalProp$q(a, prop, b[prop]);
3579
3579
  if (__getOwnPropSymbols$j)
3580
3580
  for (var prop of __getOwnPropSymbols$j(b)) {
3581
3581
  if (__propIsEnum$j.call(b, prop))
3582
- __defNormalProp$p(a, prop, b[prop]);
3582
+ __defNormalProp$q(a, prop, b[prop]);
3583
3583
  }
3584
3584
  return a;
3585
3585
  };
3586
- var __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));
3586
+ var __spreadProps$c = (a, b) => __defProps$c(a, __getOwnPropDescs$c(b));
3587
3587
  var __superGet$2 = (cls, obj, key) => __reflectGet$2(__getProtoOf$2(cls), key, obj);
3588
3588
  var __async$k = (__this, __arguments, generator) => {
3589
3589
  return new Promise((resolve, reject) => {
@@ -3628,7 +3628,7 @@ function createBasemapLayerAdapter(_0) {
3628
3628
  class BasemapTileAdapter extends TileAdapter {
3629
3629
  addLayer(opt) {
3630
3630
  return __async$k(this, null, function* () {
3631
- return __superGet$2(BasemapTileAdapter.prototype, this, "addLayer").call(this, __spreadProps$b(__spreadValues$i({}, opt), { url }));
3631
+ return __superGet$2(BasemapTileAdapter.prototype, this, "addLayer").call(this, __spreadProps$c(__spreadValues$i({}, opt), { url }));
3632
3632
  });
3633
3633
  }
3634
3634
  }
@@ -3707,25 +3707,25 @@ function prepareNgwFieldsToPropertiesFilter(fields) {
3707
3707
  return fields;
3708
3708
  }
3709
3709
 
3710
- var __defProp$o = Object.defineProperty;
3711
- var __defProps$a = Object.defineProperties;
3712
- var __getOwnPropDescs$a = Object.getOwnPropertyDescriptors;
3710
+ var __defProp$p = Object.defineProperty;
3711
+ var __defProps$b = Object.defineProperties;
3712
+ var __getOwnPropDescs$b = Object.getOwnPropertyDescriptors;
3713
3713
  var __getOwnPropSymbols$i = Object.getOwnPropertySymbols;
3714
3714
  var __hasOwnProp$i = Object.prototype.hasOwnProperty;
3715
3715
  var __propIsEnum$i = Object.prototype.propertyIsEnumerable;
3716
- var __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3716
+ var __defNormalProp$p = (obj, key, value) => key in obj ? __defProp$p(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3717
3717
  var __spreadValues$h = (a, b) => {
3718
3718
  for (var prop in b || (b = {}))
3719
3719
  if (__hasOwnProp$i.call(b, prop))
3720
- __defNormalProp$o(a, prop, b[prop]);
3720
+ __defNormalProp$p(a, prop, b[prop]);
3721
3721
  if (__getOwnPropSymbols$i)
3722
3722
  for (var prop of __getOwnPropSymbols$i(b)) {
3723
3723
  if (__propIsEnum$i.call(b, prop))
3724
- __defNormalProp$o(a, prop, b[prop]);
3724
+ __defNormalProp$p(a, prop, b[prop]);
3725
3725
  }
3726
3726
  return a;
3727
3727
  };
3728
- var __spreadProps$a = (a, b) => __defProps$a(a, __getOwnPropDescs$a(b));
3728
+ var __spreadProps$b = (a, b) => __defProps$b(a, __getOwnPropDescs$b(b));
3729
3729
  var __async$j = (__this, __arguments, generator) => {
3730
3730
  return new Promise((resolve, reject) => {
3731
3731
  var fulfilled = (value) => {
@@ -3751,13 +3751,13 @@ function fetchNgwLayerItems(options) {
3751
3751
  var _a;
3752
3752
  const filters = options.filters;
3753
3753
  if (filters) {
3754
- let data = yield createFeatureFieldFilterQueries(__spreadProps$a(__spreadValues$h({}, options), {
3754
+ let data = yield createFeatureFieldFilterQueries(__spreadProps$b(__spreadValues$h({}, options), {
3755
3755
  filters
3756
3756
  }));
3757
3757
  const clientFilterValidate = (_a = options.clientFilterValidate) != null ? _a : isFilterWithAnyCase(filters);
3758
3758
  if (clientFilterValidate) {
3759
3759
  data = data.filter((y) => {
3760
- const fields = prepareNgwFieldsToPropertiesFilter(__spreadProps$a(__spreadValues$h({}, y.fields), {
3760
+ const fields = prepareNgwFieldsToPropertiesFilter(__spreadProps$b(__spreadValues$h({}, y.fields), {
3761
3761
  id: y.id
3762
3762
  }));
3763
3763
  const result = propertiesFilter(fields, filters);
@@ -3845,28 +3845,28 @@ function getLayerFilterOptions(options) {
3845
3845
  return filterOptions;
3846
3846
  }
3847
3847
 
3848
- var __defProp$n = Object.defineProperty;
3849
- var __defProps$9 = Object.defineProperties;
3850
- var __getOwnPropDescs$9 = Object.getOwnPropertyDescriptors;
3848
+ var __defProp$o = Object.defineProperty;
3849
+ var __defProps$a = Object.defineProperties;
3850
+ var __getOwnPropDescs$a = Object.getOwnPropertyDescriptors;
3851
3851
  var __getOwnPropSymbols$h = Object.getOwnPropertySymbols;
3852
3852
  var __getProtoOf$1 = Object.getPrototypeOf;
3853
3853
  var __hasOwnProp$h = Object.prototype.hasOwnProperty;
3854
3854
  var __propIsEnum$h = Object.prototype.propertyIsEnumerable;
3855
3855
  var __reflectGet$1 = Reflect.get;
3856
- var __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3856
+ var __defNormalProp$o = (obj, key, value) => key in obj ? __defProp$o(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
3857
3857
  var __spreadValues$g = (a, b) => {
3858
3858
  for (var prop in b || (b = {}))
3859
3859
  if (__hasOwnProp$h.call(b, prop))
3860
- __defNormalProp$n(a, prop, b[prop]);
3860
+ __defNormalProp$o(a, prop, b[prop]);
3861
3861
  if (__getOwnPropSymbols$h)
3862
3862
  for (var prop of __getOwnPropSymbols$h(b)) {
3863
3863
  if (__propIsEnum$h.call(b, prop))
3864
- __defNormalProp$n(a, prop, b[prop]);
3864
+ __defNormalProp$o(a, prop, b[prop]);
3865
3865
  }
3866
3866
  return a;
3867
3867
  };
3868
- var __spreadProps$9 = (a, b) => __defProps$9(a, __getOwnPropDescs$9(b));
3869
- var __publicField$f = (obj, key, value) => __defNormalProp$n(obj, typeof key !== "symbol" ? key + "" : key, value);
3868
+ var __spreadProps$a = (a, b) => __defProps$a(a, __getOwnPropDescs$a(b));
3869
+ var __publicField$g = (obj, key, value) => __defNormalProp$o(obj, typeof key !== "symbol" ? key + "" : key, value);
3870
3870
  var __superGet$1 = (cls, obj, key) => __reflectGet$1(__getProtoOf$1(cls), key, obj);
3871
3871
  var __async$h = (__this, __arguments, generator) => {
3872
3872
  return new Promise((resolve, reject) => {
@@ -3939,11 +3939,11 @@ function createGeoJsonAdapter(props) {
3939
3939
  class NgwGeoJsonAdapter extends GeoJsonAdapter {
3940
3940
  constructor() {
3941
3941
  super(...arguments);
3942
- __publicField$f(this, "emitter", new EventEmitter());
3943
- __publicField$f(this, "__onMapMove");
3944
- __publicField$f(this, "__onMapMoveStart");
3945
- __publicField$f(this, "__enableMapMoveListener");
3946
- __publicField$f(this, "__disableMapMoveListener");
3942
+ __publicField$g(this, "emitter", new EventEmitter());
3943
+ __publicField$g(this, "__onMapMove");
3944
+ __publicField$g(this, "__onMapMoveStart");
3945
+ __publicField$g(this, "__enableMapMoveListener");
3946
+ __publicField$g(this, "__disableMapMoveListener");
3947
3947
  }
3948
3948
  addLayer(opt) {
3949
3949
  return __async$h(this, null, function* () {
@@ -4016,10 +4016,10 @@ function createGeoJsonAdapter(props) {
4016
4016
  getCount() {
4017
4017
  return fetchNgwLayerCount({ connector, resourceId, cache: true });
4018
4018
  }
4019
- updateLayer(filterArgs) {
4019
+ updateLayer(opt) {
4020
4020
  return __async$h(this, null, function* () {
4021
4021
  var _a2;
4022
- filterArgs = filterArgs || _lastFilterArgs || {};
4022
+ const filterArgs = opt || _lastFilterArgs || {};
4023
4023
  if ((_a2 = this.options.strategy) == null ? void 0 : _a2.startsWith("BBOX")) {
4024
4024
  yield webMap.onLoad("create");
4025
4025
  filterArgs.options = filterArgs.options || {};
@@ -4044,7 +4044,7 @@ function createGeoJsonAdapter(props) {
4044
4044
  try {
4045
4045
  this.emitter.emit("preupdate", filterArgs);
4046
4046
  webMap._emitLayerEvent("layer:preupdate", options.id || "", filterArgs);
4047
- const data = yield getData(filterArgs.filters, __spreadProps$9(__spreadValues$g({}, filterArgs.options), {
4047
+ const data = yield getData(filterArgs.filters, __spreadProps$a(__spreadValues$g({}, filterArgs.options), {
4048
4048
  srs: this.options.srs
4049
4049
  }));
4050
4050
  let newData = data;
@@ -4097,7 +4097,7 @@ function createGeoJsonAdapter(props) {
4097
4097
  if (this.clearLayer) {
4098
4098
  this.clearLayer();
4099
4099
  }
4100
- const data = yield getData(filters, __spreadProps$9(__spreadValues$g({}, opt), {
4100
+ const data = yield getData(filters, __spreadProps$a(__spreadValues$g({}, opt), {
4101
4101
  srs: this.options.srs
4102
4102
  }));
4103
4103
  this.setData(data);
@@ -4286,26 +4286,26 @@ function ngwApiToAdapterOptions({
4286
4286
  }
4287
4287
  }
4288
4288
 
4289
- var __defProp$m = Object.defineProperty;
4290
- var __defProps$8 = Object.defineProperties;
4291
- var __getOwnPropDescs$8 = Object.getOwnPropertyDescriptors;
4289
+ var __defProp$n = Object.defineProperty;
4290
+ var __defProps$9 = Object.defineProperties;
4291
+ var __getOwnPropDescs$9 = Object.getOwnPropertyDescriptors;
4292
4292
  var __getOwnPropSymbols$g = Object.getOwnPropertySymbols;
4293
4293
  var __hasOwnProp$g = Object.prototype.hasOwnProperty;
4294
4294
  var __propIsEnum$g = Object.prototype.propertyIsEnumerable;
4295
- var __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4295
+ var __defNormalProp$n = (obj, key, value) => key in obj ? __defProp$n(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4296
4296
  var __spreadValues$f = (a, b) => {
4297
4297
  for (var prop in b || (b = {}))
4298
4298
  if (__hasOwnProp$g.call(b, prop))
4299
- __defNormalProp$m(a, prop, b[prop]);
4299
+ __defNormalProp$n(a, prop, b[prop]);
4300
4300
  if (__getOwnPropSymbols$g)
4301
4301
  for (var prop of __getOwnPropSymbols$g(b)) {
4302
4302
  if (__propIsEnum$g.call(b, prop))
4303
- __defNormalProp$m(a, prop, b[prop]);
4303
+ __defNormalProp$n(a, prop, b[prop]);
4304
4304
  }
4305
4305
  return a;
4306
4306
  };
4307
- var __spreadProps$8 = (a, b) => __defProps$8(a, __getOwnPropDescs$8(b));
4308
- var __publicField$e = (obj, key, value) => __defNormalProp$m(obj, typeof key !== "symbol" ? key + "" : key, value);
4307
+ var __spreadProps$9 = (a, b) => __defProps$9(a, __getOwnPropDescs$9(b));
4308
+ var __publicField$f = (obj, key, value) => __defNormalProp$n(obj, typeof key !== "symbol" ? key + "" : key, value);
4309
4309
  var __async$f = (__this, __arguments, generator) => {
4310
4310
  return new Promise((resolve, reject) => {
4311
4311
  var fulfilled = (value) => {
@@ -4326,11 +4326,47 @@ var __async$f = (__this, __arguments, generator) => {
4326
4326
  step((generator = generator.apply(__this, __arguments)).next());
4327
4327
  });
4328
4328
  };
4329
+ class Legend {
4330
+ constructor({
4331
+ layerId,
4332
+ legend,
4333
+ onSymbolRenderChange
4334
+ }) {
4335
+ __publicField$f(this, "layerId");
4336
+ __publicField$f(this, "legend");
4337
+ __publicField$f(this, "onSymbolRenderChange");
4338
+ this.layerId = layerId;
4339
+ this.legend = this.createLegend(legend);
4340
+ this.onSymbolRenderChange = onSymbolRenderChange;
4341
+ }
4342
+ createLegend(items) {
4343
+ return items.map((params) => __spreadProps$9(__spreadValues$f({}, params), {
4344
+ /** @deprecated use display_name instead */
4345
+ name: params.display_name,
4346
+ /** @deprecated use icon instead */
4347
+ symbol: params.icon
4348
+ }));
4349
+ }
4350
+ setSymbolRender(symbolIndex, status) {
4351
+ const legendItem = this.legend.find((l) => l.index === symbolIndex);
4352
+ if (legendItem) {
4353
+ const render = legendItem.render;
4354
+ if (render !== status) {
4355
+ legendItem.render = status;
4356
+ if (this.onSymbolRenderChange) {
4357
+ this.onSymbolRenderChange(
4358
+ this.legend.filter((l) => l.render).map((l) => l.index)
4359
+ );
4360
+ }
4361
+ }
4362
+ }
4363
+ }
4364
+ }
4329
4365
  function createRasterAdapter(_0) {
4330
4366
  return __async$f(this, arguments, function* ({
4331
4367
  layerOptions,
4332
- webMap,
4333
4368
  connector,
4369
+ webMap,
4334
4370
  item
4335
4371
  }) {
4336
4372
  const resourceCls = item.resource.cls;
@@ -4359,16 +4395,17 @@ function createRasterAdapter(_0) {
4359
4395
  constructor(map, _options) {
4360
4396
  super(map, _options);
4361
4397
  this.map = map;
4362
- // options = {};
4363
- __publicField$e(this, "item", item);
4364
- __publicField$e(this, "resourceId", resourceId);
4398
+ __publicField$f(this, "item", item);
4399
+ __publicField$f(this, "resourceId", resourceId);
4400
+ __publicField$f(this, "_blocked", false);
4401
+ __publicField$f(this, "_layerVisibility");
4365
4402
  const opt = ngwApiToAdapterOptions({
4366
4403
  options: layerOptions,
4367
4404
  webMap,
4368
4405
  baseUrl: connector.options.baseUrl || ""
4369
4406
  });
4370
4407
  if (opt) {
4371
- const layerAdapterOptions = __spreadProps$8(__spreadValues$f(__spreadValues$f({}, opt), layerOptions.adapterOptions), {
4408
+ const layerAdapterOptions = __spreadProps$9(__spreadValues$f(__spreadValues$f({}, opt), layerOptions.adapterOptions), {
4372
4409
  params: { resource: resourceId },
4373
4410
  layers: opt.layers || String(resourceId),
4374
4411
  resourceId
@@ -4382,25 +4419,19 @@ function createRasterAdapter(_0) {
4382
4419
  addLayer(addOptions) {
4383
4420
  return super.addLayer(__spreadValues$f(__spreadValues$f({}, this.options), addOptions));
4384
4421
  }
4385
- getLegend(options) {
4386
- return __async$f(this, null, function* () {
4387
- const ngwLegend = yield connector.get("render.legend_symbols", __spreadValues$f({
4388
- params: { id: resourceId },
4389
- cache: true
4390
- }, options));
4391
- const id = this.options.id;
4392
- if (id !== void 0) {
4393
- const legend = {
4394
- layerId: id,
4395
- legend: ngwLegend.map(({ display_name, icon }) => ({
4396
- name: display_name,
4397
- symbol: icon
4398
- }))
4399
- };
4400
- return [legend];
4422
+ showLayer() {
4423
+ this._layerVisibility = true;
4424
+ if (this.layer) {
4425
+ if (!this._blocked) {
4426
+ webMap.mapAdapter.showLayer(this.layer);
4401
4427
  }
4402
- return [];
4403
- });
4428
+ }
4429
+ }
4430
+ hideLayer() {
4431
+ this._layerVisibility = false;
4432
+ if (this.layer) {
4433
+ webMap.mapAdapter.hideLayer(this.layer);
4434
+ }
4404
4435
  }
4405
4436
  getIdentificationIds() {
4406
4437
  return __async$f(this, null, function* () {
@@ -4416,8 +4447,69 @@ function createRasterAdapter(_0) {
4416
4447
  return [];
4417
4448
  });
4418
4449
  }
4419
- // beforeRemove() {
4420
- // }
4450
+ getLegend(options) {
4451
+ return __async$f(this, null, function* () {
4452
+ const id = this.options.id;
4453
+ if (id !== void 0) {
4454
+ const ngwLegend = yield connector.get("render.legend_symbols", __spreadValues$f({
4455
+ params: { id: resourceId },
4456
+ cache: true
4457
+ }, options));
4458
+ const legend = new Legend({
4459
+ layerId: id,
4460
+ legend: ngwLegend,
4461
+ onSymbolRenderChange: this._setLegendSymbol.bind(this)
4462
+ });
4463
+ return [legend];
4464
+ }
4465
+ return [];
4466
+ });
4467
+ }
4468
+ _hideLayer() {
4469
+ if (this.options.id) {
4470
+ webMap.mapAdapter.hideLayer(this.layer);
4471
+ }
4472
+ }
4473
+ _showLayer() {
4474
+ if (this.options.id) {
4475
+ if (this._layerVisibility) {
4476
+ webMap.showLayer(this.options.id, { silent: true });
4477
+ }
4478
+ }
4479
+ }
4480
+ _setLegendSymbol(renderIndexes) {
4481
+ const intervals = this._consolidateIntervals(renderIndexes);
4482
+ if (!intervals.length) {
4483
+ this._hideLayer();
4484
+ this._blocked = true;
4485
+ } else {
4486
+ this._blocked = false;
4487
+ this._showLayer();
4488
+ }
4489
+ if (this.updateLayer) {
4490
+ this.updateLayer({
4491
+ params: {
4492
+ [`symbols[${resourceId}]`]: intervals.join(",") || void 0
4493
+ }
4494
+ });
4495
+ }
4496
+ }
4497
+ _consolidateIntervals(symbols) {
4498
+ const sortedSymbols = symbols.slice().sort((a, b) => a - b);
4499
+ const intervals = [];
4500
+ let start = sortedSymbols[0];
4501
+ let end = start;
4502
+ for (let i = 1; i <= sortedSymbols.length; i++) {
4503
+ if (sortedSymbols[i] === end + 1) {
4504
+ end = sortedSymbols[i];
4505
+ } else {
4506
+ intervals.push(start === end ? `${start}` : `${start}-${end}`);
4507
+ start = sortedSymbols[i];
4508
+ end = start;
4509
+ }
4510
+ }
4511
+ return intervals;
4512
+ }
4421
4513
  };
4422
4514
  } else {
4423
4515
  throw new Error(adapter + " not supported yet. Only TILE");
@@ -4425,25 +4517,25 @@ function createRasterAdapter(_0) {
4425
4517
  });
4426
4518
  }
4427
4519
 
4428
- var __defProp$l = Object.defineProperty;
4429
- var __defProps$7 = Object.defineProperties;
4430
- var __getOwnPropDescs$7 = Object.getOwnPropertyDescriptors;
4520
+ var __defProp$m = Object.defineProperty;
4521
+ var __defProps$8 = Object.defineProperties;
4522
+ var __getOwnPropDescs$8 = Object.getOwnPropertyDescriptors;
4431
4523
  var __getOwnPropSymbols$f = Object.getOwnPropertySymbols;
4432
4524
  var __hasOwnProp$f = Object.prototype.hasOwnProperty;
4433
4525
  var __propIsEnum$f = Object.prototype.propertyIsEnumerable;
4434
- var __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4526
+ var __defNormalProp$m = (obj, key, value) => key in obj ? __defProp$m(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4435
4527
  var __spreadValues$e = (a, b) => {
4436
4528
  for (var prop in b || (b = {}))
4437
4529
  if (__hasOwnProp$f.call(b, prop))
4438
- __defNormalProp$l(a, prop, b[prop]);
4530
+ __defNormalProp$m(a, prop, b[prop]);
4439
4531
  if (__getOwnPropSymbols$f)
4440
4532
  for (var prop of __getOwnPropSymbols$f(b)) {
4441
4533
  if (__propIsEnum$f.call(b, prop))
4442
- __defNormalProp$l(a, prop, b[prop]);
4534
+ __defNormalProp$m(a, prop, b[prop]);
4443
4535
  }
4444
4536
  return a;
4445
4537
  };
4446
- var __spreadProps$7 = (a, b) => __defProps$7(a, __getOwnPropDescs$7(b));
4538
+ var __spreadProps$8 = (a, b) => __defProps$8(a, __getOwnPropDescs$8(b));
4447
4539
  var __async$e = (__this, __arguments, generator) => {
4448
4540
  return new Promise((resolve, reject) => {
4449
4541
  var fulfilled = (value) => {
@@ -4491,7 +4583,7 @@ function createAdapterFromFirstStyle(_0) {
4491
4583
  const firstStyle = childrenStyles && childrenStyles[0];
4492
4584
  if (firstStyle) {
4493
4585
  return createAsyncAdapter(
4494
- __spreadProps$7(__spreadValues$e({}, layerOptions), { resource: firstStyle.resource.id }),
4586
+ __spreadProps$8(__spreadValues$e({}, layerOptions), { resource: firstStyle.resource.id }),
4495
4587
  webMap,
4496
4588
  connector
4497
4589
  );
@@ -4514,7 +4606,7 @@ function createAsyncAdapter(options, webMap, connector) {
4514
4606
  }
4515
4607
  if (item) {
4516
4608
  const cls = item.resource.cls;
4517
- const layerOptions = __spreadProps$7(__spreadValues$e({}, options), {
4609
+ const layerOptions = __spreadProps$8(__spreadValues$e({}, options), {
4518
4610
  resource: resourceId
4519
4611
  });
4520
4612
  const adapterOptions = {
@@ -4551,10 +4643,10 @@ function createAsyncAdapter(options, webMap, connector) {
4551
4643
  item.resource.parent.id
4552
4644
  );
4553
4645
  if (parentItem) {
4554
- const parentOptions = __spreadProps$7(__spreadValues$e({}, options), {
4646
+ const parentOptions = __spreadProps$8(__spreadValues$e({}, options), {
4555
4647
  resource: item.resource.parent.id
4556
4648
  });
4557
- adapter = createGeoJsonAdapter(__spreadProps$7(__spreadValues$e({}, adapterOptions), {
4649
+ adapter = createGeoJsonAdapter(__spreadProps$8(__spreadValues$e({}, adapterOptions), {
4558
4650
  item: parentItem,
4559
4651
  layerOptions: parentOptions
4560
4652
  }));
@@ -4598,31 +4690,46 @@ function createAsyncAdapter(options, webMap, connector) {
4598
4690
  });
4599
4691
  }
4600
4692
 
4601
- var __defProp$k = Object.defineProperty;
4693
+ var __defProp$l = Object.defineProperty;
4694
+ var __defProps$7 = Object.defineProperties;
4695
+ var __getOwnPropDescs$7 = Object.getOwnPropertyDescriptors;
4602
4696
  var __getOwnPropSymbols$e = Object.getOwnPropertySymbols;
4603
4697
  var __hasOwnProp$e = Object.prototype.hasOwnProperty;
4604
4698
  var __propIsEnum$e = Object.prototype.propertyIsEnumerable;
4605
- var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4699
+ var __defNormalProp$l = (obj, key, value) => key in obj ? __defProp$l(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4606
4700
  var __spreadValues$d = (a, b) => {
4607
4701
  for (var prop in b || (b = {}))
4608
4702
  if (__hasOwnProp$e.call(b, prop))
4609
- __defNormalProp$k(a, prop, b[prop]);
4703
+ __defNormalProp$l(a, prop, b[prop]);
4610
4704
  if (__getOwnPropSymbols$e)
4611
4705
  for (var prop of __getOwnPropSymbols$e(b)) {
4612
4706
  if (__propIsEnum$e.call(b, prop))
4613
- __defNormalProp$k(a, prop, b[prop]);
4707
+ __defNormalProp$l(a, prop, b[prop]);
4614
4708
  }
4615
4709
  return a;
4616
4710
  };
4711
+ var __spreadProps$7 = (a, b) => __defProps$7(a, __getOwnPropDescs$7(b));
4712
+ var __objRest$1 = (source, exclude) => {
4713
+ var target = {};
4714
+ for (var prop in source)
4715
+ if (__hasOwnProp$e.call(source, prop) && exclude.indexOf(prop) < 0)
4716
+ target[prop] = source[prop];
4717
+ if (source != null && __getOwnPropSymbols$e)
4718
+ for (var prop of __getOwnPropSymbols$e(source)) {
4719
+ if (exclude.indexOf(prop) < 0 && __propIsEnum$e.call(source, prop))
4720
+ target[prop] = source[prop];
4721
+ }
4722
+ return target;
4723
+ };
4617
4724
  function updateImageParams(params, resourceId) {
4618
- const { bbox, width, height, nd } = params;
4619
- return {
4725
+ const _a = params, { bbox, width, height, nd } = _a, rest = __objRest$1(_a, ["bbox", "width", "height", "nd"]);
4726
+ return __spreadProps$7(__spreadValues$d({}, rest), {
4620
4727
  resource: Array.isArray(resourceId) ? resourceId.join(",") : resourceId,
4621
4728
  extent: bbox,
4622
4729
  size: width + "," + height,
4623
4730
  timestamp: Date.now(),
4624
4731
  nd: nd != null ? nd : 200
4625
- };
4732
+ });
4626
4733
  }
4627
4734
  const vectorLayerGeomToPaintTypeAlias = {
4628
4735
  POINT: "point",
@@ -4682,26 +4789,26 @@ function setScaleRatio(scale, lat = 0) {
4682
4789
  return zoom;
4683
4790
  }
4684
4791
 
4685
- var __defProp$j = Object.defineProperty;
4792
+ var __defProp$k = Object.defineProperty;
4686
4793
  var __defProps$6 = Object.defineProperties;
4687
4794
  var __getOwnPropDescs$6 = Object.getOwnPropertyDescriptors;
4688
4795
  var __getOwnPropSymbols$d = Object.getOwnPropertySymbols;
4689
4796
  var __hasOwnProp$d = Object.prototype.hasOwnProperty;
4690
4797
  var __propIsEnum$d = Object.prototype.propertyIsEnumerable;
4691
- var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4798
+ var __defNormalProp$k = (obj, key, value) => key in obj ? __defProp$k(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4692
4799
  var __spreadValues$c = (a, b) => {
4693
4800
  for (var prop in b || (b = {}))
4694
4801
  if (__hasOwnProp$d.call(b, prop))
4695
- __defNormalProp$j(a, prop, b[prop]);
4802
+ __defNormalProp$k(a, prop, b[prop]);
4696
4803
  if (__getOwnPropSymbols$d)
4697
4804
  for (var prop of __getOwnPropSymbols$d(b)) {
4698
4805
  if (__propIsEnum$d.call(b, prop))
4699
- __defNormalProp$j(a, prop, b[prop]);
4806
+ __defNormalProp$k(a, prop, b[prop]);
4700
4807
  }
4701
4808
  return a;
4702
4809
  };
4703
4810
  var __spreadProps$6 = (a, b) => __defProps$6(a, __getOwnPropDescs$6(b));
4704
- var __publicField$d = (obj, key, value) => __defNormalProp$j(obj, typeof key !== "symbol" ? key + "" : key, value);
4811
+ var __publicField$e = (obj, key, value) => __defNormalProp$k(obj, typeof key !== "symbol" ? key + "" : key, value);
4705
4812
  var __async$d = (__this, __arguments, generator) => {
4706
4813
  return new Promise((resolve, reject) => {
4707
4814
  var fulfilled = (value) => {
@@ -4726,11 +4833,11 @@ const _NgwWebmapItem = class _NgwWebmapItem extends Item {
4726
4833
  constructor(webMap, item, options, connector, parent, noInit) {
4727
4834
  super(__spreadValues$c(__spreadValues$c({}, _NgwWebmapItem.options), options));
4728
4835
  this.webMap = webMap;
4729
- __publicField$d(this, "item");
4730
- __publicField$d(this, "connector");
4731
- __publicField$d(this, "layer");
4732
- __publicField$d(this, "emitter", new EventEmitter());
4733
- __publicField$d(this, "_rootDescendantsCount", 0);
4836
+ __publicField$e(this, "item");
4837
+ __publicField$e(this, "connector");
4838
+ __publicField$e(this, "layer");
4839
+ __publicField$e(this, "emitter", new EventEmitter());
4840
+ __publicField$e(this, "_rootDescendantsCount", 0);
4734
4841
  if (connector) {
4735
4842
  this.connector = connector;
4736
4843
  }
@@ -4792,10 +4899,12 @@ const _NgwWebmapItem = class _NgwWebmapItem extends Item {
4792
4899
  }, options));
4793
4900
  const legend = {
4794
4901
  layerId: id,
4795
- legend: ngwLegend.map(({ display_name, icon }) => ({
4796
- name: display_name,
4797
- symbol: icon
4798
- }))
4902
+ legend: ngwLegend.map((legend2) => __spreadValues$c({
4903
+ /** @deprecated use display_name instead */
4904
+ name: legend2.display_name,
4905
+ /** @deprecated use icon instead */
4906
+ symbol: legend2.icon
4907
+ }, legend2))
4799
4908
  };
4800
4909
  return [legend];
4801
4910
  }
@@ -4918,8 +5027,8 @@ const _NgwWebmapItem = class _NgwWebmapItem extends Item {
4918
5027
  return totalValue;
4919
5028
  }
4920
5029
  };
4921
- __publicField$d(_NgwWebmapItem, "GetAdapterFromLayerType", {});
4922
- __publicField$d(_NgwWebmapItem, "options", {
5030
+ __publicField$e(_NgwWebmapItem, "GetAdapterFromLayerType", {});
5031
+ __publicField$e(_NgwWebmapItem, "options", {
4923
5032
  properties: [
4924
5033
  {
4925
5034
  type: "boolean",
@@ -4959,23 +5068,23 @@ __publicField$d(_NgwWebmapItem, "options", {
4959
5068
  });
4960
5069
  let NgwWebmapItem = _NgwWebmapItem;
4961
5070
 
4962
- var __defProp$i = Object.defineProperty;
5071
+ var __defProp$j = Object.defineProperty;
4963
5072
  var __getOwnPropSymbols$c = Object.getOwnPropertySymbols;
4964
5073
  var __hasOwnProp$c = Object.prototype.hasOwnProperty;
4965
5074
  var __propIsEnum$c = Object.prototype.propertyIsEnumerable;
4966
- var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5075
+ var __defNormalProp$j = (obj, key, value) => key in obj ? __defProp$j(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
4967
5076
  var __spreadValues$b = (a, b) => {
4968
5077
  for (var prop in b || (b = {}))
4969
5078
  if (__hasOwnProp$c.call(b, prop))
4970
- __defNormalProp$i(a, prop, b[prop]);
5079
+ __defNormalProp$j(a, prop, b[prop]);
4971
5080
  if (__getOwnPropSymbols$c)
4972
5081
  for (var prop of __getOwnPropSymbols$c(b)) {
4973
5082
  if (__propIsEnum$c.call(b, prop))
4974
- __defNormalProp$i(a, prop, b[prop]);
5083
+ __defNormalProp$j(a, prop, b[prop]);
4975
5084
  }
4976
5085
  return a;
4977
5086
  };
4978
- var __publicField$c = (obj, key, value) => __defNormalProp$i(obj, typeof key !== "symbol" ? key + "" : key, value);
5087
+ var __publicField$d = (obj, key, value) => __defNormalProp$j(obj, typeof key !== "symbol" ? key + "" : key, value);
4979
5088
  var __async$c = (__this, __arguments, generator) => {
4980
5089
  return new Promise((resolve, reject) => {
4981
5090
  var fulfilled = (value) => {
@@ -5005,10 +5114,10 @@ function createOnFirstShowAdapter(_0) {
5005
5114
  }) {
5006
5115
  class OnFirstShowAdapter {
5007
5116
  constructor() {
5008
- __publicField$c(this, "options", {});
5009
- __publicField$c(this, "layer", []);
5010
- __publicField$c(this, "_removed", false);
5011
- __publicField$c(this, "_creatingInProgress", false);
5117
+ __publicField$d(this, "options", {});
5118
+ __publicField$d(this, "layer", []);
5119
+ __publicField$d(this, "_removed", false);
5120
+ __publicField$d(this, "_creatingInProgress", false);
5012
5121
  }
5013
5122
  addLayer() {
5014
5123
  return this.layer;
@@ -5136,26 +5245,26 @@ function createOnFirstShowNgwAdapter(_0) {
5136
5245
 
5137
5246
  const WEBMAP_BASELAYER_ID_PREFIX = "webmap-baselayer";
5138
5247
 
5139
- var __defProp$h = Object.defineProperty;
5248
+ var __defProp$i = Object.defineProperty;
5140
5249
  var __defProps$5 = Object.defineProperties;
5141
5250
  var __getOwnPropDescs$5 = Object.getOwnPropertyDescriptors;
5142
5251
  var __getOwnPropSymbols$b = Object.getOwnPropertySymbols;
5143
5252
  var __hasOwnProp$b = Object.prototype.hasOwnProperty;
5144
5253
  var __propIsEnum$b = Object.prototype.propertyIsEnumerable;
5145
- var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5254
+ var __defNormalProp$i = (obj, key, value) => key in obj ? __defProp$i(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5146
5255
  var __spreadValues$a = (a, b) => {
5147
5256
  for (var prop in b || (b = {}))
5148
5257
  if (__hasOwnProp$b.call(b, prop))
5149
- __defNormalProp$h(a, prop, b[prop]);
5258
+ __defNormalProp$i(a, prop, b[prop]);
5150
5259
  if (__getOwnPropSymbols$b)
5151
5260
  for (var prop of __getOwnPropSymbols$b(b)) {
5152
5261
  if (__propIsEnum$b.call(b, prop))
5153
- __defNormalProp$h(a, prop, b[prop]);
5262
+ __defNormalProp$i(a, prop, b[prop]);
5154
5263
  }
5155
5264
  return a;
5156
5265
  };
5157
5266
  var __spreadProps$5 = (a, b) => __defProps$5(a, __getOwnPropDescs$5(b));
5158
- var __publicField$b = (obj, key, value) => __defNormalProp$h(obj, typeof key !== "symbol" ? key + "" : key, value);
5267
+ var __publicField$c = (obj, key, value) => __defNormalProp$i(obj, typeof key !== "symbol" ? key + "" : key, value);
5159
5268
  var __async$a = (__this, __arguments, generator) => {
5160
5269
  return new Promise((resolve, reject) => {
5161
5270
  var fulfilled = (value) => {
@@ -5180,21 +5289,21 @@ class NgwWebmapLayerAdapter {
5180
5289
  constructor(map, options) {
5181
5290
  this.map = map;
5182
5291
  this.options = options;
5183
- __publicField$b(this, "layer");
5184
- __publicField$b(this, "NgwWebmapItem", NgwWebmapItem);
5292
+ __publicField$c(this, "layer");
5293
+ __publicField$c(this, "NgwWebmapItem", NgwWebmapItem);
5185
5294
  /**
5186
5295
  * Radius for searching objects in pixels
5187
5296
  */
5188
- __publicField$b(this, "pixelRadius", 10);
5297
+ __publicField$c(this, "pixelRadius", 10);
5189
5298
  // webmapSettings.identify_radius,
5190
- __publicField$b(this, "resourceId");
5191
- __publicField$b(this, "webmapClassName", "webmap");
5192
- __publicField$b(this, "emitter", new EventEmitter());
5193
- __publicField$b(this, "_extent");
5194
- __publicField$b(this, "response");
5195
- __publicField$b(this, "_webmapLayersIds");
5196
- __publicField$b(this, "_webmapBaselayersIds", []);
5197
- __publicField$b(this, "_lastActiveBaselayer");
5299
+ __publicField$c(this, "resourceId");
5300
+ __publicField$c(this, "webmapClassName", "webmap");
5301
+ __publicField$c(this, "emitter", new EventEmitter());
5302
+ __publicField$c(this, "_extent");
5303
+ __publicField$c(this, "response");
5304
+ __publicField$c(this, "_webmapLayersIds");
5305
+ __publicField$c(this, "_webmapBaselayersIds", []);
5306
+ __publicField$c(this, "_lastActiveBaselayer");
5198
5307
  const r = options.resourceId;
5199
5308
  if (Array.isArray(r)) {
5200
5309
  this.resourceId = r[0];
@@ -5503,23 +5612,23 @@ class NgwWebmapLayerAdapter {
5503
5612
  }
5504
5613
  }
5505
5614
 
5506
- var __defProp$g = Object.defineProperty;
5615
+ var __defProp$h = Object.defineProperty;
5507
5616
  var __getOwnPropSymbols$a = Object.getOwnPropertySymbols;
5508
5617
  var __hasOwnProp$a = Object.prototype.hasOwnProperty;
5509
5618
  var __propIsEnum$a = Object.prototype.propertyIsEnumerable;
5510
- var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5619
+ var __defNormalProp$h = (obj, key, value) => key in obj ? __defProp$h(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5511
5620
  var __spreadValues$9 = (a, b) => {
5512
5621
  for (var prop in b || (b = {}))
5513
5622
  if (__hasOwnProp$a.call(b, prop))
5514
- __defNormalProp$g(a, prop, b[prop]);
5623
+ __defNormalProp$h(a, prop, b[prop]);
5515
5624
  if (__getOwnPropSymbols$a)
5516
5625
  for (var prop of __getOwnPropSymbols$a(b)) {
5517
5626
  if (__propIsEnum$a.call(b, prop))
5518
- __defNormalProp$g(a, prop, b[prop]);
5627
+ __defNormalProp$h(a, prop, b[prop]);
5519
5628
  }
5520
5629
  return a;
5521
5630
  };
5522
- var __publicField$a = (obj, key, value) => __defNormalProp$g(obj, typeof key !== "symbol" ? key + "" : key, value);
5631
+ var __publicField$b = (obj, key, value) => __defNormalProp$h(obj, typeof key !== "symbol" ? key + "" : key, value);
5523
5632
  var __async$9 = (__this, __arguments, generator) => {
5524
5633
  return new Promise((resolve, reject) => {
5525
5634
  var fulfilled = (value) => {
@@ -5543,9 +5652,9 @@ var __async$9 = (__this, __arguments, generator) => {
5543
5652
  class NgwKit {
5544
5653
  constructor(options) {
5545
5654
  this.options = options;
5546
- __publicField$a(this, "url");
5547
- __publicField$a(this, "connector");
5548
- __publicField$a(this, "webMap");
5655
+ __publicField$b(this, "url");
5656
+ __publicField$b(this, "connector");
5657
+ __publicField$b(this, "webMap");
5549
5658
  if (this.options.connector) {
5550
5659
  this.url = this.options.connector.options.baseUrl || "";
5551
5660
  this.connector = this.options.connector;
@@ -5606,37 +5715,37 @@ class NgwKit {
5606
5715
  }
5607
5716
  }
5608
5717
 
5609
- var __defProp$f = Object.defineProperty;
5718
+ var __defProp$g = Object.defineProperty;
5610
5719
  var __getOwnPropSymbols$9 = Object.getOwnPropertySymbols;
5611
5720
  var __hasOwnProp$9 = Object.prototype.hasOwnProperty;
5612
5721
  var __propIsEnum$9 = Object.prototype.propertyIsEnumerable;
5613
- var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5722
+ var __defNormalProp$g = (obj, key, value) => key in obj ? __defProp$g(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5614
5723
  var __spreadValues$8 = (a, b) => {
5615
5724
  for (var prop in b || (b = {}))
5616
5725
  if (__hasOwnProp$9.call(b, prop))
5617
- __defNormalProp$f(a, prop, b[prop]);
5726
+ __defNormalProp$g(a, prop, b[prop]);
5618
5727
  if (__getOwnPropSymbols$9)
5619
5728
  for (var prop of __getOwnPropSymbols$9(b)) {
5620
5729
  if (__propIsEnum$9.call(b, prop))
5621
- __defNormalProp$f(a, prop, b[prop]);
5730
+ __defNormalProp$g(a, prop, b[prop]);
5622
5731
  }
5623
5732
  return a;
5624
5733
  };
5625
- var __publicField$9 = (obj, key, value) => __defNormalProp$f(obj, typeof key !== "symbol" ? key + "" : key, value);
5734
+ var __publicField$a = (obj, key, value) => __defNormalProp$g(obj, typeof key !== "symbol" ? key + "" : key, value);
5626
5735
  class IdentifyItem {
5627
5736
  constructor(options) {
5628
- __publicField$9(this, "id");
5629
- __publicField$9(this, "label");
5630
- __publicField$9(this, "layerId");
5631
- __publicField$9(this, "parent");
5632
- __publicField$9(this, "fields");
5633
- __publicField$9(this, "geom");
5634
- __publicField$9(this, "extensions");
5635
- __publicField$9(this, "connector");
5636
- __publicField$9(this, "_item");
5637
- __publicField$9(this, "_geojson");
5638
- __publicField$9(this, "_resource");
5639
- __publicField$9(this, "_extent");
5737
+ __publicField$a(this, "id");
5738
+ __publicField$a(this, "label");
5739
+ __publicField$a(this, "layerId");
5740
+ __publicField$a(this, "parent");
5741
+ __publicField$a(this, "fields");
5742
+ __publicField$a(this, "geom");
5743
+ __publicField$a(this, "extensions");
5744
+ __publicField$a(this, "connector");
5745
+ __publicField$a(this, "_item");
5746
+ __publicField$a(this, "_geojson");
5747
+ __publicField$a(this, "_resource");
5748
+ __publicField$a(this, "_extent");
5640
5749
  const f = options.feature;
5641
5750
  this.id = f.id;
5642
5751
  this.geom = f.geom;
@@ -5722,21 +5831,21 @@ function fetchNgwLayerFeature(options) {
5722
5831
  });
5723
5832
  }
5724
5833
 
5725
- var __defProp$e = Object.defineProperty;
5834
+ var __defProp$f = Object.defineProperty;
5726
5835
  var __defProps$4 = Object.defineProperties;
5727
5836
  var __getOwnPropDescs$4 = Object.getOwnPropertyDescriptors;
5728
5837
  var __getOwnPropSymbols$8 = Object.getOwnPropertySymbols;
5729
5838
  var __hasOwnProp$8 = Object.prototype.hasOwnProperty;
5730
5839
  var __propIsEnum$8 = Object.prototype.propertyIsEnumerable;
5731
- var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5840
+ var __defNormalProp$f = (obj, key, value) => key in obj ? __defProp$f(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
5732
5841
  var __spreadValues$7 = (a, b) => {
5733
5842
  for (var prop in b || (b = {}))
5734
5843
  if (__hasOwnProp$8.call(b, prop))
5735
- __defNormalProp$e(a, prop, b[prop]);
5844
+ __defNormalProp$f(a, prop, b[prop]);
5736
5845
  if (__getOwnPropSymbols$8)
5737
5846
  for (var prop of __getOwnPropSymbols$8(b)) {
5738
5847
  if (__propIsEnum$8.call(b, prop))
5739
- __defNormalProp$e(a, prop, b[prop]);
5848
+ __defNormalProp$f(a, prop, b[prop]);
5740
5849
  }
5741
5850
  return a;
5742
5851
  };
@@ -6580,19 +6689,19 @@ const typeExpressions = {
6580
6689
  typeof: evaluateArgs(([arg]) => typeOfValue(arg))
6581
6690
  };
6582
6691
 
6583
- var __defProp$d = Object.defineProperty;
6692
+ var __defProp$e = Object.defineProperty;
6584
6693
  var __getOwnPropSymbols$7 = Object.getOwnPropertySymbols;
6585
6694
  var __hasOwnProp$7 = Object.prototype.hasOwnProperty;
6586
6695
  var __propIsEnum$7 = Object.prototype.propertyIsEnumerable;
6587
- var __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$d(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6696
+ var __defNormalProp$e = (obj, key, value) => key in obj ? __defProp$e(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6588
6697
  var __spreadValues$6 = (a, b) => {
6589
6698
  for (var prop in b || (b = {}))
6590
6699
  if (__hasOwnProp$7.call(b, prop))
6591
- __defNormalProp$d(a, prop, b[prop]);
6700
+ __defNormalProp$e(a, prop, b[prop]);
6592
6701
  if (__getOwnPropSymbols$7)
6593
6702
  for (var prop of __getOwnPropSymbols$7(b)) {
6594
6703
  if (__propIsEnum$7.call(b, prop))
6595
- __defNormalProp$d(a, prop, b[prop]);
6704
+ __defNormalProp$e(a, prop, b[prop]);
6596
6705
  }
6597
6706
  return a;
6598
6707
  };
@@ -6617,19 +6726,19 @@ function evaluate(expression, data = {}) {
6617
6726
  throw new Error(`Expression "${name}" is not supported.`);
6618
6727
  }
6619
6728
 
6620
- var __defProp$c = Object.defineProperty;
6729
+ var __defProp$d = Object.defineProperty;
6621
6730
  var __getOwnPropSymbols$6 = Object.getOwnPropertySymbols;
6622
6731
  var __hasOwnProp$6 = Object.prototype.hasOwnProperty;
6623
6732
  var __propIsEnum$6 = Object.prototype.propertyIsEnumerable;
6624
- var __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$c(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6733
+ var __defNormalProp$d = (obj, key, value) => key in obj ? __defProp$d(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6625
6734
  var __spreadValues$5 = (a, b) => {
6626
6735
  for (var prop in b || (b = {}))
6627
6736
  if (__hasOwnProp$6.call(b, prop))
6628
- __defNormalProp$c(a, prop, b[prop]);
6737
+ __defNormalProp$d(a, prop, b[prop]);
6629
6738
  if (__getOwnPropSymbols$6)
6630
6739
  for (var prop of __getOwnPropSymbols$6(b)) {
6631
6740
  if (__propIsEnum$6.call(b, prop))
6632
- __defNormalProp$c(a, prop, b[prop]);
6741
+ __defNormalProp$d(a, prop, b[prop]);
6633
6742
  }
6634
6743
  return a;
6635
6744
  };
@@ -6668,19 +6777,19 @@ function createExpressionCallback(paint) {
6668
6777
  return;
6669
6778
  }
6670
6779
 
6671
- var __defProp$b = Object.defineProperty;
6780
+ var __defProp$c = Object.defineProperty;
6672
6781
  var __getOwnPropSymbols$5 = Object.getOwnPropertySymbols;
6673
6782
  var __hasOwnProp$5 = Object.prototype.hasOwnProperty;
6674
6783
  var __propIsEnum$5 = Object.prototype.propertyIsEnumerable;
6675
- var __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$b(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6784
+ var __defNormalProp$c = (obj, key, value) => key in obj ? __defProp$c(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6676
6785
  var __spreadValues$4 = (a, b) => {
6677
6786
  for (var prop in b || (b = {}))
6678
6787
  if (__hasOwnProp$5.call(b, prop))
6679
- __defNormalProp$b(a, prop, b[prop]);
6788
+ __defNormalProp$c(a, prop, b[prop]);
6680
6789
  if (__getOwnPropSymbols$5)
6681
6790
  for (var prop of __getOwnPropSymbols$5(b)) {
6682
6791
  if (__propIsEnum$5.call(b, prop))
6683
- __defNormalProp$b(a, prop, b[prop]);
6792
+ __defNormalProp$c(a, prop, b[prop]);
6684
6793
  }
6685
6794
  return a;
6686
6795
  };
@@ -6804,95 +6913,95 @@ function preparePaint({
6804
6913
  return newPaint;
6805
6914
  }
6806
6915
 
6807
- var __defProp$a = Object.defineProperty;
6808
- var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6809
- var __publicField$8 = (obj, key, value) => __defNormalProp$a(obj, typeof key !== "symbol" ? key + "" : key, value);
6916
+ var __defProp$b = Object.defineProperty;
6917
+ var __defNormalProp$b = (obj, key, value) => key in obj ? __defProp$b(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6918
+ var __publicField$9 = (obj, key, value) => __defNormalProp$b(obj, typeof key !== "symbol" ? key + "" : key, value);
6810
6919
  class KeyCodes {
6811
6920
  constructor() {
6812
- __publicField$8(this, "backspace", 8);
6813
- __publicField$8(this, "tab", 9);
6814
- __publicField$8(this, "enter", 13);
6815
- __publicField$8(this, "shift", 16);
6816
- __publicField$8(this, "ctrl", 17);
6817
- __publicField$8(this, "alt", 18);
6818
- __publicField$8(this, "pause/break", 19);
6819
- __publicField$8(this, "caps_lock", 20);
6820
- __publicField$8(this, "escape", 27);
6821
- __publicField$8(this, "page_up", 33);
6822
- __publicField$8(this, "page_down", 34);
6823
- __publicField$8(this, "end", 35);
6824
- __publicField$8(this, "home", 36);
6825
- __publicField$8(this, "left_arrow", 37);
6826
- __publicField$8(this, "up_arrow", 38);
6827
- __publicField$8(this, "right_arrow", 39);
6828
- __publicField$8(this, "down_arrow", 40);
6829
- __publicField$8(this, "insert", 45);
6830
- __publicField$8(this, "delete", 46);
6831
- __publicField$8(this, "left_window_key", 91);
6832
- __publicField$8(this, "right_window_key", 92);
6833
- __publicField$8(this, "select_key", 93);
6834
- __publicField$8(this, "numpad_0", 96);
6835
- __publicField$8(this, "numpad_1", 97);
6836
- __publicField$8(this, "numpad_2", 98);
6837
- __publicField$8(this, "numpad_3", 99);
6838
- __publicField$8(this, "numpad_4", 100);
6839
- __publicField$8(this, "numpad_5", 101);
6840
- __publicField$8(this, "numpad_6", 102);
6841
- __publicField$8(this, "numpad_7", 103);
6842
- __publicField$8(this, "numpad_8", 104);
6843
- __publicField$8(this, "numpad_9", 105);
6844
- __publicField$8(this, "multiply", 106);
6845
- __publicField$8(this, "add", 107);
6846
- __publicField$8(this, "subtract", 109);
6847
- __publicField$8(this, "decimal_point", 110);
6848
- __publicField$8(this, "divide", 111);
6849
- __publicField$8(this, "f1", 112);
6850
- __publicField$8(this, "f2", 113);
6851
- __publicField$8(this, "f3", 114);
6852
- __publicField$8(this, "f4", 115);
6853
- __publicField$8(this, "f5", 116);
6854
- __publicField$8(this, "f6", 117);
6855
- __publicField$8(this, "f7", 118);
6856
- __publicField$8(this, "f8", 119);
6857
- __publicField$8(this, "f9", 120);
6858
- __publicField$8(this, "f10", 121);
6859
- __publicField$8(this, "f11", 122);
6860
- __publicField$8(this, "f12", 123);
6861
- __publicField$8(this, "num_lock", 144);
6862
- __publicField$8(this, "scroll_lock", 145);
6863
- __publicField$8(this, "semi-colon", 186);
6864
- __publicField$8(this, "equal_sign", 187);
6865
- __publicField$8(this, ",", 188);
6921
+ __publicField$9(this, "backspace", 8);
6922
+ __publicField$9(this, "tab", 9);
6923
+ __publicField$9(this, "enter", 13);
6924
+ __publicField$9(this, "shift", 16);
6925
+ __publicField$9(this, "ctrl", 17);
6926
+ __publicField$9(this, "alt", 18);
6927
+ __publicField$9(this, "pause/break", 19);
6928
+ __publicField$9(this, "caps_lock", 20);
6929
+ __publicField$9(this, "escape", 27);
6930
+ __publicField$9(this, "page_up", 33);
6931
+ __publicField$9(this, "page_down", 34);
6932
+ __publicField$9(this, "end", 35);
6933
+ __publicField$9(this, "home", 36);
6934
+ __publicField$9(this, "left_arrow", 37);
6935
+ __publicField$9(this, "up_arrow", 38);
6936
+ __publicField$9(this, "right_arrow", 39);
6937
+ __publicField$9(this, "down_arrow", 40);
6938
+ __publicField$9(this, "insert", 45);
6939
+ __publicField$9(this, "delete", 46);
6940
+ __publicField$9(this, "left_window_key", 91);
6941
+ __publicField$9(this, "right_window_key", 92);
6942
+ __publicField$9(this, "select_key", 93);
6943
+ __publicField$9(this, "numpad_0", 96);
6944
+ __publicField$9(this, "numpad_1", 97);
6945
+ __publicField$9(this, "numpad_2", 98);
6946
+ __publicField$9(this, "numpad_3", 99);
6947
+ __publicField$9(this, "numpad_4", 100);
6948
+ __publicField$9(this, "numpad_5", 101);
6949
+ __publicField$9(this, "numpad_6", 102);
6950
+ __publicField$9(this, "numpad_7", 103);
6951
+ __publicField$9(this, "numpad_8", 104);
6952
+ __publicField$9(this, "numpad_9", 105);
6953
+ __publicField$9(this, "multiply", 106);
6954
+ __publicField$9(this, "add", 107);
6955
+ __publicField$9(this, "subtract", 109);
6956
+ __publicField$9(this, "decimal_point", 110);
6957
+ __publicField$9(this, "divide", 111);
6958
+ __publicField$9(this, "f1", 112);
6959
+ __publicField$9(this, "f2", 113);
6960
+ __publicField$9(this, "f3", 114);
6961
+ __publicField$9(this, "f4", 115);
6962
+ __publicField$9(this, "f5", 116);
6963
+ __publicField$9(this, "f6", 117);
6964
+ __publicField$9(this, "f7", 118);
6965
+ __publicField$9(this, "f8", 119);
6966
+ __publicField$9(this, "f9", 120);
6967
+ __publicField$9(this, "f10", 121);
6968
+ __publicField$9(this, "f11", 122);
6969
+ __publicField$9(this, "f12", 123);
6970
+ __publicField$9(this, "num_lock", 144);
6971
+ __publicField$9(this, "scroll_lock", 145);
6972
+ __publicField$9(this, "semi-colon", 186);
6973
+ __publicField$9(this, "equal_sign", 187);
6974
+ __publicField$9(this, ",", 188);
6866
6975
  // "comma";
6867
- __publicField$8(this, "-", 189);
6976
+ __publicField$9(this, "-", 189);
6868
6977
  // "dash";
6869
- __publicField$8(this, ".", 190);
6978
+ __publicField$9(this, ".", 190);
6870
6979
  // "period";
6871
- __publicField$8(this, "/", 191);
6980
+ __publicField$9(this, "/", 191);
6872
6981
  // "forward slash";
6873
- __publicField$8(this, "`", 192);
6982
+ __publicField$9(this, "`", 192);
6874
6983
  // "grave accent";
6875
- __publicField$8(this, "[", 219);
6984
+ __publicField$9(this, "[", 219);
6876
6985
  // "open bracket";
6877
- __publicField$8(this, "\\", 220);
6986
+ __publicField$9(this, "\\", 220);
6878
6987
  // "back slash";
6879
- __publicField$8(this, "]", 221);
6988
+ __publicField$9(this, "]", 221);
6880
6989
  // "close braket";
6881
- __publicField$8(this, "'", 222);
6990
+ __publicField$9(this, "'", 222);
6882
6991
  }
6883
6992
  // "single quote"
6884
6993
  }
6885
6994
 
6886
- var __defProp$9 = Object.defineProperty;
6887
- var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6888
- var __publicField$7 = (obj, key, value) => __defNormalProp$9(obj, typeof key !== "symbol" ? key + "" : key, value);
6995
+ var __defProp$a = Object.defineProperty;
6996
+ var __defNormalProp$a = (obj, key, value) => key in obj ? __defProp$a(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6997
+ var __publicField$8 = (obj, key, value) => __defNormalProp$a(obj, typeof key !== "symbol" ? key + "" : key, value);
6889
6998
  class Keys {
6890
6999
  constructor() {
6891
- __publicField$7(this, "keyCodeAlias", new KeyCodes());
6892
- __publicField$7(this, "keys", {});
6893
- __publicField$7(this, "_windowOnFocus");
6894
- __publicField$7(this, "_keysPressed");
6895
- __publicField$7(this, "_keysReleased");
7000
+ __publicField$8(this, "keyCodeAlias", new KeyCodes());
7001
+ __publicField$8(this, "keys", {});
7002
+ __publicField$8(this, "_windowOnFocus");
7003
+ __publicField$8(this, "_keysPressed");
7004
+ __publicField$8(this, "_keysReleased");
6896
7005
  this._windowOnFocus = this.windowOnFocus.bind(this);
6897
7006
  this._keysPressed = this.keysPressed.bind(this);
6898
7007
  this._keysReleased = this.keysReleased.bind(this);
@@ -6931,15 +7040,15 @@ class Keys {
6931
7040
  }
6932
7041
  }
6933
7042
 
6934
- var __defProp$8 = Object.defineProperty;
6935
- var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6936
- var __publicField$6 = (obj, key, value) => __defNormalProp$8(obj, typeof key !== "symbol" ? key + "" : key, value);
7043
+ var __defProp$9 = Object.defineProperty;
7044
+ var __defNormalProp$9 = (obj, key, value) => key in obj ? __defProp$9(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
7045
+ var __publicField$7 = (obj, key, value) => __defNormalProp$9(obj, typeof key !== "symbol" ? key + "" : key, value);
6937
7046
  class StateItem {
6938
7047
  constructor(webMap, opt) {
6939
7048
  this.webMap = webMap;
6940
- __publicField$6(this, "name");
6941
- __publicField$6(this, "event");
6942
- __publicField$6(this, "value");
7049
+ __publicField$7(this, "name");
7050
+ __publicField$7(this, "event");
7051
+ __publicField$7(this, "value");
6943
7052
  if (opt) {
6944
7053
  if (opt.value) {
6945
7054
  this.setValue(opt.value);
@@ -6948,7 +7057,11 @@ class StateItem {
6948
7057
  this.name = opt.name;
6949
7058
  }
6950
7059
  if (opt.event) {
6951
- this.event = opt.event;
7060
+ if (typeof opt.event === "string") {
7061
+ this.event = [opt.event];
7062
+ } else {
7063
+ this.event = opt.event;
7064
+ }
6952
7065
  }
6953
7066
  }
6954
7067
  }
@@ -6960,6 +7073,34 @@ class StateItem {
6960
7073
  }
6961
7074
  }
6962
7075
 
7076
+ var __defProp$8 = Object.defineProperty;
7077
+ var __defNormalProp$8 = (obj, key, value) => key in obj ? __defProp$8(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
7078
+ var __publicField$6 = (obj, key, value) => __defNormalProp$8(obj, typeof key !== "symbol" ? key + "" : key, value);
7079
+ class BoundState extends StateItem {
7080
+ constructor() {
7081
+ super(...arguments);
7082
+ __publicField$6(this, "name", "bounds");
7083
+ __publicField$6(this, "event", ["moveend"]);
7084
+ }
7085
+ getValue() {
7086
+ return this.webMap.getBounds();
7087
+ }
7088
+ setValue(bounds) {
7089
+ this.webMap.setView({ bounds });
7090
+ }
7091
+ toString() {
7092
+ const data = this.getValue();
7093
+ if (data) {
7094
+ return data.slice(0, 4).map((x) => x.toFixed(5)).join("_");
7095
+ }
7096
+ return void 0;
7097
+ }
7098
+ parse(str) {
7099
+ const lngLat = str.split("_").map(Number);
7100
+ return lngLat;
7101
+ }
7102
+ }
7103
+
6963
7104
  var __defProp$7 = Object.defineProperty;
6964
7105
  var __defNormalProp$7 = (obj, key, value) => key in obj ? __defProp$7(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
6965
7106
  var __publicField$5 = (obj, key, value) => __defNormalProp$7(obj, typeof key !== "symbol" ? key + "" : key, value);
@@ -6967,7 +7108,7 @@ class CenterState extends StateItem {
6967
7108
  constructor() {
6968
7109
  super(...arguments);
6969
7110
  __publicField$5(this, "name", "center");
6970
- __publicField$5(this, "event", "moveend");
7111
+ __publicField$5(this, "event", ["moveend"]);
6971
7112
  }
6972
7113
  getValue() {
6973
7114
  return this.webMap.getCenter();
@@ -6975,9 +7116,13 @@ class CenterState extends StateItem {
6975
7116
  setValue(val) {
6976
7117
  this.webMap.setCenter(val);
6977
7118
  }
6978
- toString(data) {
6979
- const d = data.map((x) => x.toFixed(5));
6980
- return d[0] + "_" + d[1];
7119
+ toString() {
7120
+ const data = this.getValue();
7121
+ if (data) {
7122
+ const d = data.map((x) => x.toFixed(5));
7123
+ return d[0] + "_" + d[1];
7124
+ }
7125
+ return "";
6981
7126
  }
6982
7127
  parse(str) {
6983
7128
  const lngLat = str.split("_").map(Number);
@@ -6992,7 +7137,7 @@ class ZoomState extends StateItem {
6992
7137
  constructor() {
6993
7138
  super(...arguments);
6994
7139
  __publicField$4(this, "name", "zoom");
6995
- __publicField$4(this, "event", "zoomend");
7140
+ __publicField$4(this, "event", ["zoomend"]);
6996
7141
  }
6997
7142
  getValue() {
6998
7143
  const zoom = this.webMap.getZoom();
@@ -7001,8 +7146,8 @@ class ZoomState extends StateItem {
7001
7146
  setValue(val) {
7002
7147
  this.webMap.setZoom(val);
7003
7148
  }
7004
- toString(val) {
7005
- return String(val);
7149
+ toString() {
7150
+ return String(this.getValue());
7006
7151
  }
7007
7152
  parse(str) {
7008
7153
  return Number(str);
@@ -7071,14 +7216,14 @@ const _WebMapMain = class _WebMapMain {
7071
7216
  __publicField$3(this, "mapAdapter");
7072
7217
  __publicField$3(this, "runtimeParams", []);
7073
7218
  __publicField$3(this, "getPaintFunctions", _WebMapMain.getPaintFunctions);
7074
- __publicField$3(this, "mapState", [CenterState, ZoomState]);
7219
+ __publicField$3(this, "mapStateItems", [CenterState, ZoomState, BoundState]);
7075
7220
  __publicField$3(this, "id", ID++);
7076
7221
  /**
7077
7222
  * From runtime params
7078
7223
  */
7224
+ __publicField$3(this, "mapState", []);
7079
7225
  __publicField$3(this, "_initMapState", {});
7080
7226
  __publicField$3(this, "_starterKits");
7081
- __publicField$3(this, "_mapState", []);
7082
7227
  __publicField$3(this, "_extent");
7083
7228
  __publicField$3(this, "_eventsStatus", {});
7084
7229
  __publicField$3(this, "_coordFromMapClickAbort");
@@ -7113,7 +7258,7 @@ const _WebMapMain = class _WebMapMain {
7113
7258
  create() {
7114
7259
  return __async$6(this, null, function* () {
7115
7260
  if (!this.getEventStatus("create")) {
7116
- yield this._setInitMapState(this.mapState);
7261
+ yield this._setInitMapState(this.mapStateItems);
7117
7262
  yield this._setupMap();
7118
7263
  this._emitStatusEvent("create", this);
7119
7264
  }
@@ -7133,16 +7278,22 @@ const _WebMapMain = class _WebMapMain {
7133
7278
  this.mapAdapter.destroy();
7134
7279
  }
7135
7280
  }
7136
- getState() {
7281
+ mapStateWithFunc(func) {
7137
7282
  const state = {};
7138
- this._mapState.forEach((x) => {
7139
- state[x.name] = x.getValue();
7283
+ this.mapState.forEach((x) => {
7284
+ state[x.name] = func(x);
7140
7285
  });
7141
7286
  return state;
7142
7287
  }
7288
+ getStateAsString() {
7289
+ return this.mapStateWithFunc((x) => x.toString());
7290
+ }
7291
+ getState() {
7292
+ return this.mapStateWithFunc((x) => x.getValue());
7293
+ }
7143
7294
  getRuntimeParams() {
7144
7295
  const state = {};
7145
- this._mapState.forEach((x) => {
7296
+ this.mapState.forEach((x) => {
7146
7297
  for (const r of this.runtimeParams) {
7147
7298
  const val = r.get(x.name);
7148
7299
  if (val !== void 0) {
@@ -7484,7 +7635,7 @@ const _WebMapMain = class _WebMapMain {
7484
7635
  _setInitMapState(states) {
7485
7636
  for (const X of states) {
7486
7637
  const state = new X(this);
7487
- this._mapState.push(state);
7638
+ this.mapState.push(state);
7488
7639
  for (const r of this.runtimeParams) {
7489
7640
  const str = r.get(state.name);
7490
7641
  if (str !== void 0) {
@@ -7520,13 +7671,15 @@ const _WebMapMain = class _WebMapMain {
7520
7671
  events.forEach((x) => {
7521
7672
  this._mapEvents[x] = (data) => {
7522
7673
  if (this.runtimeParams.length) {
7523
- const mapStatusEvent = this._mapState.find((y) => y.event === x);
7524
- if (mapStatusEvent) {
7525
- const value = mapStatusEvent.toString(mapStatusEvent.getValue());
7674
+ const mapStatusEvents = this.mapState.filter(
7675
+ (y) => y.event.includes(x)
7676
+ );
7677
+ mapStatusEvents.forEach((mapStatusEvent) => {
7678
+ const value = mapStatusEvent.toString();
7526
7679
  this.runtimeParams.forEach((r) => {
7527
7680
  r.set(mapStatusEvent.name, value);
7528
7681
  });
7529
- }
7682
+ });
7530
7683
  }
7531
7684
  if (this._eventsStatus) {
7532
7685
  this.emitter.emit(x, data);
@@ -8102,11 +8255,11 @@ class WebMapLayers extends WebMapMain {
8102
8255
  }
8103
8256
  return Promise.resolve();
8104
8257
  }
8105
- updateLayer(layerDef) {
8258
+ updateLayer(layerDef, options) {
8106
8259
  const layer = this.getLayer(layerDef);
8107
8260
  if (layer) {
8108
8261
  if (layer.updateLayer) {
8109
- return Promise.resolve(layer.updateLayer());
8262
+ return Promise.resolve(layer.updateLayer(options));
8110
8263
  } else if (this.isLayerVisible(layer)) {
8111
8264
  return this.hideLayer(layer, { silent: true }).then(() => {
8112
8265
  return this.showLayer(layer, { silent: true });