@opengeoweb/webmap 9.25.2 → 9.26.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
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compact, range, isEqual } from 'lodash';
|
|
2
|
-
import { dateUtils, defaultDelay as defaultDelay$1 } from '@opengeoweb/shared';
|
|
2
|
+
import { PROJECTION, dateUtils, defaultDelay as defaultDelay$1 } from '@opengeoweb/shared';
|
|
3
3
|
import { debounce, throttle } from 'throttle-debounce';
|
|
4
4
|
import proj4 from 'proj4';
|
|
5
5
|
|
|
@@ -5136,6 +5136,7 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
|
|
|
5136
5136
|
*
|
|
5137
5137
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5138
5138
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5139
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5139
5140
|
* */
|
|
5140
5141
|
const WMEmptyLayerName = 'empty_layer';
|
|
5141
5142
|
const WMEmptyLayerTitle = 'empty layer';
|
|
@@ -5149,28 +5150,13 @@ const WMSVersion = {
|
|
|
5149
5150
|
version111: '1.1.1',
|
|
5150
5151
|
version130: '1.3.0'
|
|
5151
5152
|
};
|
|
5152
|
-
const WMProj4Defs = [[
|
|
5153
|
-
const epsgDescriptionLookup = {
|
|
5154
|
-
'EPSG:3411': 'NSIDC Sea Ice Polar Stereographic North',
|
|
5155
|
-
'EPSG:3412': 'NSIDC Sea Ice Polar Stereographic South',
|
|
5156
|
-
'EPSG:3575': 'Lambert azimuthal equal-area projection Europe',
|
|
5157
|
-
'EPSG:3785': 'Mercator (deprecated)',
|
|
5158
|
-
'EPSG:3857': 'Mercator',
|
|
5159
|
-
'EPSG:4258': 'ETRS89',
|
|
5160
|
-
'EPSG:4326': 'World Lat lon WGS84',
|
|
5161
|
-
'CRS:84': 'World Lat lon WGS84',
|
|
5162
|
-
'EPSG:25831': 'ETRS89 / UTM zone 31N',
|
|
5163
|
-
'EPSG:25832': 'ETRS89 / UTM zone 32N',
|
|
5164
|
-
'EPSG:28992': 'Dutch Amersfoort / RD New',
|
|
5165
|
-
'EPSG:32661': 'Polar Stereographic WGS 84 / UPS North',
|
|
5166
|
-
'EPSG:3067': 'ETRS89 / TM35FIN(E,N) -- Finland'
|
|
5167
|
-
};
|
|
5153
|
+
const WMProj4Defs = [[PROJECTION.EPSG_4326.value, '+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees'], [PROJECTION.EPSG_4269.value, '+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees'], [PROJECTION.EPSG_3575.value, '+proj=laea +lat_0=90 +lon_0=10 +x_0=0 +y_0=0 +ellps=WGS84 +datum=WGS84 +units=m +no_defs'], [PROJECTION.EPSG_3785.value, '+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs'], [PROJECTION.EPSG_3857.value, '+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs'], [PROJECTION.EPSG_3411.value, '+proj=stere +lat_0=90 +lat_ts=70 +lon_0=-45 +k=1 +x_0=0 +y_0=0 +a=6378273 +b=6356889.449 +units=m +no_defs'], [PROJECTION.EPSG_3412.value, '+proj=stere +lat_0=-90 +lat_ts=-70 +lon_0=0 +k=1 +x_0=0 +y_0=0 +a=6378273 +b=6356889.449 +units=m +no_defs'], [PROJECTION.EPSG_28992.value, '+proj=sterea +lat_0=52.15616055555555 +lon_0=5.38763888888889 +k=0.9999079 +x_0=155000 +y_0=463000 +ellps=bessel +units=m +no_defs <>'], [PROJECTION.EPSG_32661.value, '+proj=stere +lat_0=90 +lat_ts=90 +lon_0=0 +k=0.994 +x_0=2000000 +y_0=2000000 +ellps=WGS84 +datum=WGS84 +units=m +no_defs'], [PROJECTION.EPSG_102100.value, '+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs'], [PROJECTION.EPSG_3067.value, '+proj=utm +zone=35 +ellps=GRS80 +towgs84=0,0,0,0,0,0,0 +units=m +no_defs +type=crs']];
|
|
5168
5154
|
const mapImageStoreLength = 1000;
|
|
5169
5155
|
const bgImageStoreLength = 360;
|
|
5170
5156
|
const legendImageStoreLength = 500;
|
|
5171
5157
|
const EVENT_GETCAPABILITIES_START = 'onstartgetcapabilities';
|
|
5172
5158
|
const EVENT_GETCAPABILITIES_READY = 'onreadygetcapabilities';
|
|
5173
|
-
const WMJSMAP_LONLAT_EPSGCODE =
|
|
5159
|
+
const WMJSMAP_LONLAT_EPSGCODE = PROJECTION.EPSG_4326.value;
|
|
5174
5160
|
|
|
5175
5161
|
/* debug helper */
|
|
5176
5162
|
const enableConsoleDebugging = false;
|
|
@@ -5528,6 +5514,7 @@ const flattenLayerTree = layerTree => {
|
|
|
5528
5514
|
* @returns
|
|
5529
5515
|
*/
|
|
5530
5516
|
const makeNodeLayerFromWMSGetCapabilityLayer = (layer, path = [], isleaf = false, nestedLayerPath = []) => {
|
|
5517
|
+
var _a, _b;
|
|
5531
5518
|
const geographicBoundingBox = nestedLayerPath.reverse().reduce((p, c) => {
|
|
5532
5519
|
return p || c.geographicBoundingBox;
|
|
5533
5520
|
}, addBoundingBoxForLayer(layer));
|
|
@@ -5566,7 +5553,7 @@ const makeNodeLayerFromWMSGetCapabilityLayer = (layer, path = [], isleaf = false
|
|
|
5566
5553
|
title: layerTitle || 'Layer',
|
|
5567
5554
|
leaf: isleaf,
|
|
5568
5555
|
path,
|
|
5569
|
-
keywords: toArray(layer.KeywordList
|
|
5556
|
+
keywords: toArray((_b = (_a = layer.KeywordList) === null || _a === void 0 ? void 0 : _a.Keyword) !== null && _b !== void 0 ? _b : []).map(keyword => keyword.value).filter(Boolean),
|
|
5570
5557
|
abstract: layer.Abstract ? layer.Abstract.value : undefined,
|
|
5571
5558
|
styles,
|
|
5572
5559
|
dimensions,
|
|
@@ -5613,6 +5600,7 @@ const buildLayerTreeFromNestedWMSLayer = (wmsLayer, nestedPath = [], nestedLayer
|
|
|
5613
5600
|
*
|
|
5614
5601
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5615
5602
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5603
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5616
5604
|
* */
|
|
5617
5605
|
/**
|
|
5618
5606
|
* Global service store for re-use of services
|
|
@@ -6620,6 +6608,7 @@ $$b({ target: 'String', proto: true, forced: !MDN_POLYFILL_BUG && !CORRECT_IS_RE
|
|
|
6620
6608
|
*
|
|
6621
6609
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6622
6610
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
6611
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6623
6612
|
* */
|
|
6624
6613
|
var I18n = {
|
|
6625
6614
|
delete: {
|
|
@@ -7219,6 +7208,7 @@ $$9({ target: 'String', proto: true, forced: !correctIsRegExpLogic('includes') }
|
|
|
7219
7208
|
*
|
|
7220
7209
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
7221
7210
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
7211
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
7222
7212
|
* */
|
|
7223
7213
|
const WMXMLStringToXMLDocument = xmlString => {
|
|
7224
7214
|
const xmlData = new DOMParser().parseFromString(xmlString, 'text/xml');
|
|
@@ -10442,6 +10432,7 @@ setToStringTag(getBuiltIn(DOM_EXCEPTION), DOM_EXCEPTION);
|
|
|
10442
10432
|
*
|
|
10443
10433
|
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
10444
10434
|
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
10435
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
10445
10436
|
* */
|
|
10446
10437
|
const fakeMaxAgeResponsesByLayer = {
|
|
10447
10438
|
'observation:wis2_air_temperature': 600,
|
|
@@ -11145,6 +11136,7 @@ $({ target: 'Number', proto: true, forced: FORCED }, {
|
|
|
11145
11136
|
*
|
|
11146
11137
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
11147
11138
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
11139
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
11148
11140
|
* */
|
|
11149
11141
|
class WMBBOX {
|
|
11150
11142
|
constructor(left, bottom, right, top) {
|
|
@@ -11722,7 +11714,7 @@ const getBBOXandProjString = (layer, projection) => {
|
|
|
11722
11714
|
}
|
|
11723
11715
|
if (layer.version === WMSVersion.version130) {
|
|
11724
11716
|
request += `CRS=${URLEncode(srs)}&`;
|
|
11725
|
-
if (srs ===
|
|
11717
|
+
if (srs === PROJECTION.EPSG_4326.value && layer.wms130bboxcompatibilitymode === false) {
|
|
11726
11718
|
request += `BBOX=${bbox.bottom},${bbox.left},${bbox.top},${bbox.right}&`;
|
|
11727
11719
|
} else {
|
|
11728
11720
|
request += `BBOX=${bbox.left},${bbox.bottom},${bbox.right},${bbox.top}&`;
|
|
@@ -12169,6 +12161,7 @@ function prefetchImagesForNonAnimation(wmMap, maxImagesToPrefetch = MAX_IMAGES_T
|
|
|
12169
12161
|
*
|
|
12170
12162
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
12171
12163
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
12164
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
12172
12165
|
* */
|
|
12173
12166
|
/**
|
|
12174
12167
|
* Set the length of the timer, in milli seconds, after time has elapsed function is called
|
|
@@ -12205,6 +12198,7 @@ class WMTimer {
|
|
|
12205
12198
|
*
|
|
12206
12199
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
12207
12200
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
12201
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
12208
12202
|
* */
|
|
12209
12203
|
var _WMJSAnimate_instances, _WMJSAnimate_animate;
|
|
12210
12204
|
class WMJSAnimate {
|
|
@@ -12523,7 +12517,7 @@ class WMTileRenderer {
|
|
|
12523
12517
|
}
|
|
12524
12518
|
}
|
|
12525
12519
|
};
|
|
12526
|
-
if (srs ===
|
|
12520
|
+
if (srs === PROJECTION.EPSG_4326.value || srs === PROJECTION.EPSG_4258.value) {
|
|
12527
12521
|
numTilesAtLevelX *= 2;
|
|
12528
12522
|
}
|
|
12529
12523
|
if (tilenbottom < 1) {
|
|
@@ -13207,6 +13201,7 @@ class WMJSDimension {
|
|
|
13207
13201
|
*
|
|
13208
13202
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
13209
13203
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
13204
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
13210
13205
|
* */
|
|
13211
13206
|
const WMDrawMarker = (context, coordx, coordy, fillColor = '#FFF') => {
|
|
13212
13207
|
const ctx = context;
|
|
@@ -13316,22 +13311,6 @@ class MapPin {
|
|
|
13316
13311
|
}
|
|
13317
13312
|
}
|
|
13318
13313
|
|
|
13319
|
-
/* *
|
|
13320
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
13321
|
-
* you may not use this file except in compliance with the License.
|
|
13322
|
-
* You may obtain a copy of the License at
|
|
13323
|
-
*
|
|
13324
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13325
|
-
*
|
|
13326
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
13327
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
13328
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13329
|
-
* See the License for the specific language governing permissions and
|
|
13330
|
-
* limitations under the License.
|
|
13331
|
-
*
|
|
13332
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
13333
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
13334
|
-
* */
|
|
13335
13314
|
/* eslint-disable no-param-reassign */
|
|
13336
13315
|
const drawTextBG = (ctx, txt, x, y, fontSize) => {
|
|
13337
13316
|
ctx.textBaseline = 'top';
|
|
@@ -13441,31 +13420,31 @@ const drawScaleBar = (scaleBarProps, ctx) => {
|
|
|
13441
13420
|
ctx.moveTo(offsetX + scaleBarProps.width * 2 + 1, scaleBarHeight - 2 + offsetY);
|
|
13442
13421
|
ctx.lineTo(offsetX + scaleBarProps.width * 2 + 1, scaleBarHeight - 2 - 7 + offsetY);
|
|
13443
13422
|
let units = '';
|
|
13444
|
-
if (srs ===
|
|
13423
|
+
if (srs === PROJECTION.EPSG_3411.value) {
|
|
13445
13424
|
units = 'meter';
|
|
13446
13425
|
}
|
|
13447
|
-
if (srs ===
|
|
13426
|
+
if (srs === PROJECTION.EPSG_3412.value) {
|
|
13448
13427
|
units = 'meter';
|
|
13449
13428
|
}
|
|
13450
|
-
if (srs ===
|
|
13429
|
+
if (srs === PROJECTION.EPSG_3575.value) {
|
|
13451
13430
|
units = 'meter';
|
|
13452
13431
|
}
|
|
13453
|
-
if (srs ===
|
|
13432
|
+
if (srs === PROJECTION.EPSG_4326.value) {
|
|
13454
13433
|
units = 'degrees';
|
|
13455
13434
|
}
|
|
13456
|
-
if (srs ===
|
|
13435
|
+
if (srs === PROJECTION.EPSG_28992.value) {
|
|
13457
13436
|
units = 'meter';
|
|
13458
13437
|
}
|
|
13459
|
-
if (srs ===
|
|
13438
|
+
if (srs === PROJECTION.EPSG_32661.value) {
|
|
13460
13439
|
units = 'meter';
|
|
13461
13440
|
}
|
|
13462
|
-
if (srs ===
|
|
13441
|
+
if (srs === PROJECTION.EPSG_3857.value) {
|
|
13463
13442
|
units = 'meter';
|
|
13464
13443
|
}
|
|
13465
|
-
if (srs ===
|
|
13444
|
+
if (srs === PROJECTION.EPSG_900913.value) {
|
|
13466
13445
|
units = 'meter';
|
|
13467
13446
|
}
|
|
13468
|
-
if (srs ===
|
|
13447
|
+
if (srs === PROJECTION.EPSG_102100.value) {
|
|
13469
13448
|
units = 'meter';
|
|
13470
13449
|
}
|
|
13471
13450
|
if (units === 'meter') {
|
|
@@ -13500,6 +13479,7 @@ const drawScaleBar = (scaleBarProps, ctx) => {
|
|
|
13500
13479
|
*
|
|
13501
13480
|
* Copyright 2021 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
13502
13481
|
* Copyright 2021 - Finnish Meteorological Institute (FMI)
|
|
13482
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
13503
13483
|
* */
|
|
13504
13484
|
const SCALE_DELAY = 10;
|
|
13505
13485
|
const ZOOMED_CALLBACK_DELAY = 500;
|
|
@@ -13751,7 +13731,7 @@ class WMJSMap {
|
|
|
13751
13731
|
const xText = Math.round(this.mouseGeoCoordXY.x * roundingFactor) / roundingFactor;
|
|
13752
13732
|
const yText = Math.round(this.mouseGeoCoordXY.y * roundingFactor) / roundingFactor;
|
|
13753
13733
|
let units = '';
|
|
13754
|
-
if (this._srs ===
|
|
13734
|
+
if (this._srs === PROJECTION.EPSG_3857.value) {
|
|
13755
13735
|
units = 'meter';
|
|
13756
13736
|
}
|
|
13757
13737
|
ctx.fillText(`CoordYX: (${yText}, ${xText}) ${units}`, 5, this._height - 50);
|
|
@@ -13881,7 +13861,7 @@ class WMJSMap {
|
|
|
13881
13861
|
this._bbox.bottom = -90;
|
|
13882
13862
|
this._bbox.right = 180;
|
|
13883
13863
|
this._bbox.top = 90;
|
|
13884
|
-
this._srs =
|
|
13864
|
+
this._srs = PROJECTION.EPSG_4326.value;
|
|
13885
13865
|
// IMAGE buffer
|
|
13886
13866
|
this.canvasLayerBuffer = new WMCanvasBuffer(this, this._width, this._height, {
|
|
13887
13867
|
beforecanvasstartdraw: this._adagucBeforeDraw,
|
|
@@ -13985,7 +13965,7 @@ class WMJSMap {
|
|
|
13985
13965
|
}
|
|
13986
13966
|
if (!projinfo.srs || !projinfo.bbox) {
|
|
13987
13967
|
debugLogger(DebugType.Error);
|
|
13988
|
-
projinfo.srs =
|
|
13968
|
+
projinfo.srs = PROJECTION.EPSG_4326.value;
|
|
13989
13969
|
projinfo.bbox.left = -180;
|
|
13990
13970
|
projinfo.bbox.bottom = -90;
|
|
13991
13971
|
projinfo.bbox.right = 180;
|
|
@@ -14975,14 +14955,14 @@ class WMJSMap {
|
|
|
14975
14955
|
*/
|
|
14976
14956
|
setProjection(_srs, _bbox) {
|
|
14977
14957
|
if (!_srs) {
|
|
14978
|
-
_srs =
|
|
14958
|
+
_srs = PROJECTION.EPSG_4326.value;
|
|
14979
14959
|
}
|
|
14980
14960
|
if (typeof _srs === 'object') {
|
|
14981
14961
|
_bbox = new WMBBOX(_srs.bbox);
|
|
14982
14962
|
_srs = _srs.srs;
|
|
14983
14963
|
}
|
|
14984
14964
|
if (!_srs) {
|
|
14985
|
-
_srs =
|
|
14965
|
+
_srs = PROJECTION.EPSG_4326.value;
|
|
14986
14966
|
}
|
|
14987
14967
|
if (this._srs !== _srs) {
|
|
14988
14968
|
this._defaultBBOX.setBBOX(_bbox);
|
|
@@ -15662,6 +15642,7 @@ class WMJSMap {
|
|
|
15662
15642
|
*
|
|
15663
15643
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
15664
15644
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
15645
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
15665
15646
|
* */
|
|
15666
15647
|
/**
|
|
15667
15648
|
* WMProjection Class
|
|
@@ -15670,7 +15651,7 @@ class WMJSMap {
|
|
|
15670
15651
|
class WMProjection {
|
|
15671
15652
|
constructor() {
|
|
15672
15653
|
this.bbox = new WMBBOX();
|
|
15673
|
-
this.srs =
|
|
15654
|
+
this.srs = PROJECTION.EPSG_4326.value;
|
|
15674
15655
|
}
|
|
15675
15656
|
}
|
|
15676
15657
|
|
|
@@ -16132,7 +16113,7 @@ class WMLayer {
|
|
|
16132
16113
|
const wmProjection = new WMProjection();
|
|
16133
16114
|
wmProjection.srs = p.name || '';
|
|
16134
16115
|
if (p.bbox) {
|
|
16135
|
-
const swapBBOX = this.version === WMSVersion.version130 && wmProjection.srs ===
|
|
16116
|
+
const swapBBOX = this.version === WMSVersion.version130 && wmProjection.srs === PROJECTION.EPSG_4326.value && this.wms130bboxcompatibilitymode === false;
|
|
16136
16117
|
if (swapBBOX) {
|
|
16137
16118
|
wmProjection.bbox.setBBOX(p.bbox.bottom, p.bbox.left, p.bbox.top, p.bbox.right);
|
|
16138
16119
|
} else {
|
|
@@ -16416,6 +16397,7 @@ class WMLayer {
|
|
|
16416
16397
|
*
|
|
16417
16398
|
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
16418
16399
|
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
16400
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
16419
16401
|
* */
|
|
16420
16402
|
const defaultAnimationDelayAtStart = 250;
|
|
16421
16403
|
const defaultDelay = 1000; // [ms]
|
|
@@ -16449,6 +16431,7 @@ var mapConstants = /*#__PURE__*/Object.freeze({
|
|
|
16449
16431
|
*
|
|
16450
16432
|
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
16451
16433
|
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
16434
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
16452
16435
|
* */
|
|
16453
16436
|
let generatedLayerIds = 0;
|
|
16454
16437
|
const generateLayerId = () => {
|
|
@@ -16642,6 +16625,7 @@ var utils = /*#__PURE__*/Object.freeze({
|
|
|
16642
16625
|
*
|
|
16643
16626
|
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
16644
16627
|
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
16628
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
16645
16629
|
* */
|
|
16646
16630
|
const defaultReduxLayerRadarColor = {
|
|
16647
16631
|
service: 'https://testservice',
|
|
@@ -17031,21 +17015,8 @@ var testSettings = /*#__PURE__*/Object.freeze({
|
|
|
17031
17015
|
*
|
|
17032
17016
|
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
17033
17017
|
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
17018
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
17034
17019
|
* */
|
|
17035
|
-
var EPSGCode;
|
|
17036
|
-
(function (EPSGCode) {
|
|
17037
|
-
EPSGCode["EPSG3857"] = "EPSG:3857";
|
|
17038
|
-
EPSGCode["EPSG28992"] = "EPSG:28992";
|
|
17039
|
-
EPSGCode["TODO_EPSG4326"] = "TODO__EPSG:4326";
|
|
17040
|
-
EPSGCode["EPSG3411"] = "EPSG:3411";
|
|
17041
|
-
EPSGCode["EPSG32661"] = "EPSG:32661";
|
|
17042
|
-
EPSGCode["EPSG54030"] = "EPSG:54030";
|
|
17043
|
-
EPSGCode["EPSG4326"] = "EPSG:4326";
|
|
17044
|
-
EPSGCode["EPSG4258"] = "EPSG:4258";
|
|
17045
|
-
EPSGCode["EPSG3412"] = "EPSG:3412";
|
|
17046
|
-
EPSGCode["EPSG3575"] = "EPSG:3575";
|
|
17047
|
-
EPSGCode["EPSG3067"] = "EPSG:3067";
|
|
17048
|
-
})(EPSGCode || (EPSGCode = {}));
|
|
17049
17020
|
const tilesettings = {
|
|
17050
17021
|
WorldMap_Light_Grey_Canvas: {
|
|
17051
17022
|
'EPSG:3857': {
|
|
@@ -17141,16 +17112,17 @@ const tilesettings = {
|
|
|
17141
17112
|
tileServerType: 'osm',
|
|
17142
17113
|
copyRight: 'Natural Earth II | Ingmapping'
|
|
17143
17114
|
},
|
|
17144
|
-
|
|
17145
|
-
|
|
17146
|
-
|
|
17147
|
-
|
|
17148
|
-
|
|
17149
|
-
|
|
17150
|
-
|
|
17151
|
-
|
|
17152
|
-
|
|
17153
|
-
|
|
17115
|
+
/* TODO
|
|
17116
|
+
'EPSG:4326': {
|
|
17117
|
+
home: 'https://geoweb-maps-assets.pmc.knmi.cloud/WorldMap/EPSG4326/',
|
|
17118
|
+
minLevel: 0,
|
|
17119
|
+
maxLevel: 9,
|
|
17120
|
+
origX: -180,
|
|
17121
|
+
origY: 90,
|
|
17122
|
+
resolution: 1.422222,
|
|
17123
|
+
tileServerType: 'osm',
|
|
17124
|
+
copyRight: 'Natural Earth II | Ingmapping',
|
|
17125
|
+
}, */
|
|
17154
17126
|
'EPSG:3411': {
|
|
17155
17127
|
home: 'https://geoweb-maps-assets.pmc.knmi.cloud/WorldMap/EPSG3411/',
|
|
17156
17128
|
minLevel: 3,
|
|
@@ -17410,6 +17382,7 @@ const tilesettings = {
|
|
|
17410
17382
|
*
|
|
17411
17383
|
* Copyright 2021 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
17412
17384
|
* Copyright 2021 - Finnish Meteorological Institute (FMI)
|
|
17385
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
17413
17386
|
* */
|
|
17414
17387
|
const defaultReduxLayerRadarKNMI = {
|
|
17415
17388
|
service: 'https://testservice',
|
|
@@ -17465,6 +17438,7 @@ const multiDimensionLayer = {
|
|
|
17465
17438
|
*
|
|
17466
17439
|
* Copyright 2021 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
17467
17440
|
* Copyright 2021 - Finnish Meteorological Institute (FMI)
|
|
17441
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
17468
17442
|
* */
|
|
17469
17443
|
const WMS111GetCapabilitiesGeoServicesRADAR = `<?xml version="1.0" encoding="UTF-8"?>
|
|
17470
17444
|
<!DOCTYPE WMT_MS_Capabilities SYSTEM "http://schemas.opengis.net/wms/1.1.1/WMS_MS_Capabilities.dtd" [
|
|
@@ -17937,4 +17911,4 @@ var getCapabilities = /*#__PURE__*/Object.freeze({
|
|
|
17937
17911
|
recurseNodes: recurseNodes
|
|
17938
17912
|
});
|
|
17939
17913
|
|
|
17940
|
-
export { DateInterval, DebugType,
|
|
17914
|
+
export { DateInterval, DebugType, EVENT_GETCAPABILITIES_READY, EVENT_GETCAPABILITIES_START, I18n, LayerType, ParseISOTimeRangeDuration, URLDecode, URLEncode, WMBBOX, WMDateOutSideRange, WMDateTooEarlyString, WMDateTooLateString, WMEmptyLayerName, WMEmptyLayerTitle, WMGetServiceFromStore, WMImage, WMImageEventType, WMJSDimension, WMJSMAP_LONLAT_EPSGCODE, WMJSMap, WMJSService, WMJScheckURL, WMLayer, WMListener, WMProj4Defs, WMProjection, WMSJSMAP_MINIMUM_MAP_HEIGHT, WMSJSMAP_MINIMUM_MAP_WIDTH, WMSVersion, bgImageStoreLength, buildMapLayerDims, buildWMSGetMapRequest, clearImageCacheForAllMaps, debugLogger, defaultReduxLayerRadarKNMI, detectLeftButton, detectRightButton, drawScaleBar, drawTextBG, generateLayerId, generateMapId, generateTimesliderId, getBBOXandProjString, getCapabilities, getErrorsToDisplay, getGeoCoordFromLatLong, getGeoCoordFromPixelCoord, getLatLongFromPixelCoord, getLayerIndex, getLegendGraphicURLForLayer, getPixelCoordFromGeoCoord, getPixelCoordFromLatLong, getScaleBarProperties, getSpeedDelay, getUriWithParam, getWMJSDimensionForLayerAndDimension, getWMJSMapById, getWMJSMapIds, getWMJSTimeDimensionForLayerId, getWMLayerById, getWMSGetFeatureInfoRequestURL, getWMSRequests, handleDateUtilsISOString, isDefined, isProjectionSupported, legendImageStore, legendImageStoreLength, mapConstants, mapImageStoreLength, mockGetCapabilities, multiDimensionLayer, parseISO8601DateToDate, parseISO8601IntervalToDateInterval, registerWMJSMap, registerWMLayer, roundWithTimeStep, speedFactors, tilesettings, toArray, unRegisterAllWMJSLayersAndMaps, unRegisterWMJSLayer, unRegisterWMJSMap, testSettings as webmapTestSettings, utils as webmapUtils, wmServiceListener };
|
package/package.json
CHANGED
|
@@ -11,24 +11,9 @@ export declare const WMSVersion: {
|
|
|
11
11
|
version130: string;
|
|
12
12
|
};
|
|
13
13
|
export declare const WMProj4Defs: string[][];
|
|
14
|
-
export declare const epsgDescriptionLookup: {
|
|
15
|
-
'EPSG:3411': string;
|
|
16
|
-
'EPSG:3412': string;
|
|
17
|
-
'EPSG:3575': string;
|
|
18
|
-
'EPSG:3785': string;
|
|
19
|
-
'EPSG:3857': string;
|
|
20
|
-
'EPSG:4258': string;
|
|
21
|
-
'EPSG:4326': string;
|
|
22
|
-
'CRS:84': string;
|
|
23
|
-
'EPSG:25831': string;
|
|
24
|
-
'EPSG:25832': string;
|
|
25
|
-
'EPSG:28992': string;
|
|
26
|
-
'EPSG:32661': string;
|
|
27
|
-
'EPSG:3067': string;
|
|
28
|
-
};
|
|
29
14
|
export declare const mapImageStoreLength = 1000;
|
|
30
15
|
export declare const bgImageStoreLength = 360;
|
|
31
16
|
export declare const legendImageStoreLength = 500;
|
|
32
17
|
export declare const EVENT_GETCAPABILITIES_START = "onstartgetcapabilities";
|
|
33
18
|
export declare const EVENT_GETCAPABILITIES_READY = "onreadygetcapabilities";
|
|
34
|
-
export declare const WMJSMAP_LONLAT_EPSGCODE
|
|
19
|
+
export declare const WMJSMAP_LONLAT_EPSGCODE: "EPSG:4326";
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { EPSGCode } from '@opengeoweb/shared';
|
|
2
|
+
import type { TileServerMap, TileSettings } from '../utils';
|
|
2
3
|
import WMBBOX from './WMBBOX';
|
|
3
4
|
import WMImageStore from './WMImageStore';
|
|
4
5
|
export default class WMTileRenderer {
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { EPSGCode } from '@opengeoweb/shared';
|
|
1
2
|
export interface TileSettings {
|
|
2
3
|
home: string;
|
|
3
4
|
minLevel: number;
|
|
@@ -12,21 +13,8 @@ export interface TileSettings {
|
|
|
12
13
|
tileServerFormat?: string;
|
|
13
14
|
tms?: boolean;
|
|
14
15
|
}
|
|
15
|
-
export declare enum EPSGCode {
|
|
16
|
-
EPSG3857 = "EPSG:3857",
|
|
17
|
-
EPSG28992 = "EPSG:28992",
|
|
18
|
-
TODO_EPSG4326 = "TODO__EPSG:4326",
|
|
19
|
-
EPSG3411 = "EPSG:3411",
|
|
20
|
-
EPSG32661 = "EPSG:32661",
|
|
21
|
-
EPSG54030 = "EPSG:54030",
|
|
22
|
-
EPSG4326 = "EPSG:4326",
|
|
23
|
-
EPSG4258 = "EPSG:4258",
|
|
24
|
-
EPSG3412 = "EPSG:3412",
|
|
25
|
-
EPSG3575 = "EPSG:3575",
|
|
26
|
-
EPSG3067 = "EPSG:3067"
|
|
27
|
-
}
|
|
28
16
|
export type TileSettingPerProjection = {
|
|
29
|
-
[
|
|
17
|
+
[key in EPSGCode]?: TileSettings;
|
|
30
18
|
};
|
|
31
19
|
export interface Title {
|
|
32
20
|
title?: string;
|