@opengeoweb/webmap 12.1.1 → 12.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.esm.js CHANGED
@@ -37,14 +37,14 @@ function _asyncToGenerator(n) {
37
37
  function _createForOfIteratorHelperLoose(r, e) {
38
38
  var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
39
39
  if (t) return (t = t.call(r)).next.bind(t);
40
- if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e ) {
40
+ if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e) {
41
41
  t && (r = t);
42
42
  var o = 0;
43
43
  return function () {
44
44
  return o >= r.length ? {
45
- done: !0
45
+ done: true
46
46
  } : {
47
- done: !1,
47
+ done: false,
48
48
  value: r[o++]
49
49
  };
50
50
  };
@@ -55,7 +55,7 @@ function _objectWithoutPropertiesLoose(r, e) {
55
55
  if (null == r) return {};
56
56
  var t = {};
57
57
  for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
58
- if (e.indexOf(n) >= 0) continue;
58
+ if (-1 !== e.indexOf(n)) continue;
59
59
  t[n] = r[n];
60
60
  }
61
61
  return t;
@@ -78,9 +78,9 @@ function _regeneratorRuntime() {
78
78
  function define(t, e, r) {
79
79
  return Object.defineProperty(t, e, {
80
80
  value: r,
81
- enumerable: !0,
82
- configurable: !0,
83
- writable: !0
81
+ enumerable: true,
82
+ configurable: true,
83
+ writable: true
84
84
  }), t[e];
85
85
  }
86
86
  try {
@@ -173,7 +173,7 @@ function _regeneratorRuntime() {
173
173
  if ("throw" === i) throw a;
174
174
  return {
175
175
  value: t,
176
- done: !0
176
+ done: true
177
177
  };
178
178
  }
179
179
  for (n.method = i, n.arg = a;;) {
@@ -224,7 +224,7 @@ function _regeneratorRuntime() {
224
224
  function Context(t) {
225
225
  this.tryEntries = [{
226
226
  tryLoc: "root"
227
- }], t.forEach(pushTryEntry, this), this.reset(!0);
227
+ }], t.forEach(pushTryEntry, this), this.reset(true);
228
228
  }
229
229
  function values(e) {
230
230
  if (e || "" === e) {
@@ -234,8 +234,8 @@ function _regeneratorRuntime() {
234
234
  if (!isNaN(e.length)) {
235
235
  var o = -1,
236
236
  i = function next() {
237
- for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
238
- return next.value = t, next.done = !0, next;
237
+ for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = false, next;
238
+ return next.value = t, next.done = true, next;
239
239
  };
240
240
  return i.next = i;
241
241
  }
@@ -244,10 +244,10 @@ function _regeneratorRuntime() {
244
244
  }
245
245
  return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
246
246
  value: GeneratorFunctionPrototype,
247
- configurable: !0
247
+ configurable: true
248
248
  }), o(GeneratorFunctionPrototype, "constructor", {
249
249
  value: GeneratorFunction,
250
- configurable: !0
250
+ configurable: true
251
251
  }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
252
252
  var e = "function" == typeof t && t.constructor;
253
253
  return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
@@ -276,17 +276,17 @@ function _regeneratorRuntime() {
276
276
  return r.reverse(), function next() {
277
277
  for (; r.length;) {
278
278
  var t = r.pop();
279
- if (t in e) return next.value = t, next.done = !1, next;
279
+ if (t in e) return next.value = t, next.done = false, next;
280
280
  }
281
- return next.done = !0, next;
281
+ return next.done = true, next;
282
282
  };
283
283
  }, e.values = values, Context.prototype = {
284
284
  constructor: Context,
285
285
  reset: function (e) {
286
- if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
286
+ if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = false, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
287
287
  },
288
288
  stop: function () {
289
- this.done = !0;
289
+ this.done = true;
290
290
  var t = this.tryEntries[0].completion;
291
291
  if ("throw" === t.type) throw t.arg;
292
292
  return this.rval;
@@ -305,10 +305,10 @@ function _regeneratorRuntime() {
305
305
  var c = n.call(i, "catchLoc"),
306
306
  u = n.call(i, "finallyLoc");
307
307
  if (c && u) {
308
- if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
308
+ if (this.prev < i.catchLoc) return handle(i.catchLoc, true);
309
309
  if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
310
310
  } else if (c) {
311
- if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
311
+ if (this.prev < i.catchLoc) return handle(i.catchLoc, true);
312
312
  } else {
313
313
  if (!u) throw Error("try statement without catch or finally");
314
314
  if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
@@ -365,7 +365,7 @@ function _toPrimitive(t, r) {
365
365
  if ("object" != typeof t || !t) return t;
366
366
  var e = t[Symbol.toPrimitive];
367
367
  if (void 0 !== e) {
368
- var i = e.call(t, r );
368
+ var i = e.call(t, r);
369
369
  if ("object" != typeof i) return i;
370
370
  throw new TypeError("@@toPrimitive must return a primitive value.");
371
371
  }
@@ -3381,10 +3381,7 @@ var getWMSGetFeatureInfoRequestURL = function getWMSGetFeatureInfoRequestURL(lay
3381
3381
  request += "&QUERY_LAYERS=" + URLEncode(layer.name);
3382
3382
  request += "&" + getBBOXandProjString(layer, {
3383
3383
  bbox: bbox,
3384
- srs: srs,
3385
- width: width,
3386
- height: height
3387
- });
3384
+ srs: srs});
3388
3385
  request += "WIDTH=" + width;
3389
3386
  request += "&HEIGHT=" + height;
3390
3387
  if (layer.version === WMSVersion.version100 || layer.version === WMSVersion.version111) {
@@ -4701,6 +4698,17 @@ var WMJSDimension = /*#__PURE__*/function () {
4701
4698
  }
4702
4699
  return null;
4703
4700
  }
4701
+ /**
4702
+ * Get value for index in as epoch time in milliseconds
4703
+ * @param index
4704
+ * @returns
4705
+ */;
4706
+ _proto.getValueForIndexAsTime = function getValueForIndexAsTime(index) {
4707
+ if (Number.isNaN(index)) {
4708
+ return NaN;
4709
+ }
4710
+ return dateUtils.parseISO(handleDateUtilsISOString(this.getValueForIndex(index))).getTime();
4711
+ }
4704
4712
  /**
4705
4713
  * Hint about the timestep size / time resolution of this dimension.
4706
4714
  * @returns The dimTimeInterval
@@ -5399,8 +5407,8 @@ var WMJSMap = /*#__PURE__*/function () {
5399
5407
  this._mouseWheelEventBBOXNew = new WMBBOX();
5400
5408
  this._mouseX = 0;
5401
5409
  this._mouseY = 0;
5402
- this._mouseDownX = -10000;
5403
- this._mouseDownY = -10000;
5410
+ this._mouseDownX = -1e4;
5411
+ this._mouseDownY = -1e4;
5404
5412
  this.mouseUpX = 10000;
5405
5413
  this.mouseUpY = 10000;
5406
5414
  this.mouseDragging = 0;
@@ -10170,7 +10178,6 @@ var mockGetLayersFlattenedFromService = /*#__PURE__*/function () {
10170
10178
  };
10171
10179
  }();
10172
10180
  var mockServiceFromStore = {
10173
- id: 'serviceid_1',
10174
10181
  title: 'Service test title',
10175
10182
  "abstract": 'Service Abstract'
10176
10183
  };
@@ -10594,7 +10601,7 @@ var tilesettings = {
10594
10601
  home: 'https://geoweb-maps-assets.pmc.knmi.cloud/OSM_Antarctica/EPSG3412/',
10595
10602
  minLevel: 1,
10596
10603
  maxLevel: 7,
10597
- origX: -3000000,
10604
+ origX: -3e6,
10598
10605
  origY: 3000000,
10599
10606
  resolution: 23437.5,
10600
10607
  tileServerType: 'osm',
@@ -10667,7 +10674,7 @@ var tilesettings = {
10667
10674
  home: 'https://geoweb-maps-assets.pmc.knmi.cloud/NaturalEarth2/EPSG3411/',
10668
10675
  minLevel: 1,
10669
10676
  maxLevel: 6,
10670
- origX: -12400000,
10677
+ origX: -124e5,
10671
10678
  origY: 12400000,
10672
10679
  resolution: 96875,
10673
10680
  tileServerType: 'wmst',
@@ -10677,7 +10684,7 @@ var tilesettings = {
10677
10684
  home: 'https://geoweb-maps-assets.pmc.knmi.cloud/NaturalEarth2/EPSG3412/',
10678
10685
  minLevel: 1,
10679
10686
  maxLevel: 6,
10680
- origX: -12400000,
10687
+ origX: -124e5,
10681
10688
  origY: 12400000,
10682
10689
  resolution: 96875,
10683
10690
  tileServerType: 'wmst',
@@ -10687,7 +10694,7 @@ var tilesettings = {
10687
10694
  home: 'https://geoweb-maps-assets.pmc.knmi.cloud/NaturalEarth2/EPSG3575/',
10688
10695
  minLevel: 1,
10689
10696
  maxLevel: 6,
10690
- origX: -13000000,
10697
+ origX: -13e6,
10691
10698
  origY: 13000000,
10692
10699
  resolution: 101562.5,
10693
10700
  tileServerType: 'wmst',
@@ -10724,7 +10731,7 @@ var tilesettings = {
10724
10731
  home: 'https://geoweb-maps-assets.pmc.knmi.cloud/NaturalEarth2/EPSG28992/',
10725
10732
  minLevel: 1,
10726
10733
  maxLevel: 5,
10727
- origX: -2999000,
10734
+ origX: -2999e3,
10728
10735
  origY: 2995500,
10729
10736
  resolution: 23437,
10730
10737
  tileServerType: 'wmst',
@@ -10734,7 +10741,7 @@ var tilesettings = {
10734
10741
  home: 'https://geoweb-maps-assets.pmc.knmi.cloud/NaturalEarth2/EPSG32661/',
10735
10742
  minLevel: 1,
10736
10743
  maxLevel: 7,
10737
- origX: -5000000,
10744
+ origX: -5e6,
10738
10745
  origY: 4000000,
10739
10746
  resolution: 58593.75,
10740
10747
  tileServerType: 'wmst',
@@ -10744,7 +10751,7 @@ var tilesettings = {
10744
10751
  home: 'https://geoweb-maps-assets.pmc.knmi.cloud/NaturalEarth2/EPSG54030/',
10745
10752
  minLevel: 1,
10746
10753
  maxLevel: 7,
10747
- origX: -17000000,
10754
+ origX: -17e6,
10748
10755
  origY: 8625830,
10749
10756
  resolution: 132812.5,
10750
10757
  tileServerType: 'wmst',
@@ -10941,9 +10948,9 @@ var crsListForRADNL25PCPCMLayer = [{
10941
10948
  }, {
10942
10949
  name: 'EPSG:50001',
10943
10950
  bbox: {
10944
- left: -2000000,
10951
+ left: -2e6,
10945
10952
  right: 10000000,
10946
- bottom: -2000000,
10953
+ bottom: -2e6,
10947
10954
  top: 8500000
10948
10955
  }
10949
10956
  }, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opengeoweb/webmap",
3
- "version": "12.1.1",
3
+ "version": "12.2.0",
4
4
  "description": "GeoWeb webmap library for the opengeoweb project",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -8,8 +8,8 @@
8
8
  "url": "git@gitlab.com:opengeoweb/opengeoweb.git"
9
9
  },
10
10
  "dependencies": {
11
- "@opengeoweb/shared": "12.1.1",
12
- "@tanstack/query-core": "^5.61.5",
11
+ "@opengeoweb/shared": "12.2.0",
12
+ "@tanstack/query-core": "^5.69.2",
13
13
  "proj4": "^2.9.2",
14
14
  "lodash": "^4.17.21",
15
15
  "i18next": "^23.11.5"
@@ -77,6 +77,12 @@ export default class WMJSDimension implements Dimension {
77
77
  * Get dimension value for specified index
78
78
  */
79
79
  getValueForIndex(index: number): string | CustomDate;
80
+ /**
81
+ * Get value for index in as epoch time in milliseconds
82
+ * @param index
83
+ * @returns
84
+ */
85
+ getValueForIndexAsTime(index: number): number;
80
86
  /**
81
87
  * Hint about the timestep size / time resolution of this dimension.
82
88
  * @returns The dimTimeInterval