@opengeoweb/store 9.28.1 → 9.29.1
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 +1377 -1377
- package/package.json +1 -1
- package/src/index.d.ts +1 -1
- package/src/store/coreModuleConfig.d.ts +1 -1
- package/src/store/drawingtool/config.d.ts +4 -4
- package/src/store/drawingtool/index.d.ts +6 -6
- package/src/store/drawingtool/listener.d.ts +3 -3
- package/src/store/drawingtool/listener.spec.d.ts +1 -1
- package/src/store/drawingtool/reducer.d.ts +46 -46
- package/src/store/drawingtool/reducer.spec.d.ts +4 -4
- package/src/store/drawingtool/selectors.d.ts +43 -43
- package/src/store/drawingtool/selectors.spec.d.ts +1 -1
- package/src/store/drawingtool/testUtils.d.ts +1 -1
- package/src/store/drawingtool/utils.d.ts +1 -1
- package/src/store/drawingtool/utils.spec.d.ts +1 -1
- package/src/store/generic/actions.d.ts +28 -28
- package/src/store/generic/config.d.ts +5 -5
- package/src/store/generic/index.d.ts +17 -17
- package/src/store/generic/listener.d.ts +2 -2
- package/src/store/generic/listener.spec.d.ts +1 -1
- package/src/store/generic/loadingIndicator/constants.d.ts +1 -1
- package/src/store/generic/loadingIndicator/index.d.ts +3 -3
- package/src/store/generic/loadingIndicator/reducer.d.ts +13 -13
- package/src/store/generic/loadingIndicator/reducer.spec.d.ts +1 -1
- package/src/store/generic/loadingIndicator/selectors.d.ts +22 -22
- package/src/store/generic/loadingIndicator/selectors.spec.d.ts +1 -1
- package/src/store/generic/loadingIndicator/types.d.ts +22 -22
- package/src/store/generic/selectors.d.ts +12 -12
- package/src/store/generic/selectors.spec.d.ts +1 -1
- package/src/store/generic/synchronizationActions/actions.d.ts +11 -11
- package/src/store/generic/synchronizationActions/types.d.ts +34 -34
- package/src/store/generic/synchronizationGroups/__mocks__/mockState.d.ts +2 -2
- package/src/store/generic/synchronizationGroups/constants.d.ts +4 -4
- package/src/store/generic/synchronizationGroups/index.d.ts +6 -6
- package/src/store/generic/synchronizationGroups/listener.d.ts +2 -2
- package/src/store/generic/synchronizationGroups/listener.spec.d.ts +1 -1
- package/src/store/generic/synchronizationGroups/reducer.d.ts +26 -26
- package/src/store/generic/synchronizationGroups/reducer.spec.d.ts +1 -1
- package/src/store/generic/synchronizationGroups/selector.d.ts +13 -13
- package/src/store/generic/synchronizationGroups/selectors.d.ts +64 -64
- package/src/store/generic/synchronizationGroups/selectors.spec.d.ts +1 -1
- package/src/store/generic/synchronizationGroups/types.d.ts +100 -100
- package/src/store/generic/synchronizationGroups/utils.d.ts +76 -76
- package/src/store/generic/synchronizationGroups/utils.spec.d.ts +1 -1
- package/src/store/generic/types.d.ts +23 -23
- package/src/store/generic/utils.d.ts +9 -9
- package/src/store/generic/utils.spec.d.ts +1 -1
- package/src/store/index.d.ts +14 -14
- package/src/store/mapStore/config.d.ts +9 -9
- package/src/store/mapStore/index.d.ts +96 -96
- package/src/store/mapStore/layers/index.d.ts +5 -5
- package/src/store/mapStore/layers/listeners.d.ts +2 -2
- package/src/store/mapStore/layers/listeners.spec.d.ts +1 -1
- package/src/store/mapStore/layers/reducer.d.ts +87 -87
- package/src/store/mapStore/layers/reducer.spec.d.ts +1 -1
- package/src/store/mapStore/layers/selectors.d.ts +380 -380
- package/src/store/mapStore/layers/selectors.spec.d.ts +1 -1
- package/src/store/mapStore/layers/types.d.ts +166 -166
- package/src/store/mapStore/layers/utils.d.ts +23 -23
- package/src/store/mapStore/layers/utils.spec.d.ts +1 -1
- package/src/store/mapStore/map/actions.d.ts +9 -9
- package/src/store/mapStore/map/constants.d.ts +1 -1
- package/src/store/mapStore/map/enums.d.ts +3 -3
- package/src/store/mapStore/map/filterLayers.d.ts +10 -10
- package/src/store/mapStore/map/filterLayers.spec.d.ts +1 -1
- package/src/store/mapStore/map/index.d.ts +25 -25
- package/src/store/mapStore/map/listener.d.ts +4 -4
- package/src/store/mapStore/map/listener.spec.d.ts +1 -1
- package/src/store/mapStore/map/mapListenerAnimationUtils.d.ts +38 -38
- package/src/store/mapStore/map/mapListenerAnimationUtils.spec.d.ts +1 -1
- package/src/store/mapStore/map/mapUiListener.d.ts +2 -2
- package/src/store/mapStore/map/mapUiListener.spec.d.ts +1 -1
- package/src/store/mapStore/map/metronomeListener.d.ts +2 -2
- package/src/store/mapStore/map/reducer.d.ts +109 -109
- package/src/store/mapStore/map/reducer.spec.d.ts +1 -1
- package/src/store/mapStore/map/replaceLayerIdsToEnsureUniqueLayerIdsInStore.d.ts +7 -7
- package/src/store/mapStore/map/replaceLayerIdsToEnsureUniqueLayerIdsInStore.spec.d.ts +1 -1
- package/src/store/mapStore/map/selectors.d.ts +733 -733
- package/src/store/mapStore/map/selectors.spec.d.ts +1 -1
- package/src/store/mapStore/map/types.d.ts +233 -233
- package/src/store/mapStore/map/utils.d.ts +85 -85
- package/src/store/mapStore/map/utils.spec.d.ts +1 -1
- package/src/store/mapStore/service/WMS111GetCapabilitiesGeoServicesRADAR.d.ts +2 -2
- package/src/store/mapStore/service/index.d.ts +4 -4
- package/src/store/mapStore/service/listener.d.ts +5 -5
- package/src/store/mapStore/service/listener.spec.d.ts +1 -1
- package/src/store/mapStore/service/localStorage.d.ts +3 -3
- package/src/store/mapStore/service/localStorage.spec.d.ts +1 -1
- package/src/store/mapStore/service/reducer.d.ts +11 -11
- package/src/store/mapStore/service/reducer.spec.d.ts +1 -1
- package/src/store/mapStore/service/selectors.d.ts +80 -80
- package/src/store/mapStore/service/selectors.spec.d.ts +1 -1
- package/src/store/mapStore/service/types.d.ts +50 -50
- package/src/store/mapStore/storeTestSettings.d.ts +7 -7
- package/src/store/mapStore/storeTestUtils.d.ts +17 -17
- package/src/store/mapStore/types.d.ts +11 -11
- package/src/store/router/config.d.ts +4 -4
- package/src/store/router/index.d.ts +3 -3
- package/src/store/router/listener.d.ts +2 -2
- package/src/store/router/listener.spec.d.ts +1 -1
- package/src/store/router/reducer.d.ts +9 -9
- package/src/store/router/reducer.spec.d.ts +1 -1
- package/src/store/router/types.d.ts +6 -6
- package/src/store/router/utils.d.ts +3 -3
- package/src/store/testUtils/Providers.d.ts +13 -13
- package/src/store/types.d.ts +7 -7
- package/src/store/ui/config.d.ts +4 -4
- package/src/store/ui/index.d.ts +4 -4
- package/src/store/ui/reducer.d.ts +33 -33
- package/src/store/ui/reducer.spec.d.ts +1 -1
- package/src/store/ui/selectors.d.ts +102 -102
- package/src/store/ui/selectors.spec.d.ts +1 -1
- package/src/store/ui/types.d.ts +78 -78
- package/src/store/ui/useSetupDialog.d.ts +11 -11
- package/src/store/ui/useSetupDialog.spec.d.ts +1 -1
- package/src/store/utils.d.ts +6 -6
package/index.esm.js
CHANGED
|
@@ -1971,22 +1971,22 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
|
|
|
1971
1971
|
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
1972
1972
|
};
|
|
1973
1973
|
|
|
1974
|
-
/* *
|
|
1975
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1976
|
-
* you may not use this file except in compliance with the License.
|
|
1977
|
-
* You may obtain a copy of the License at
|
|
1978
|
-
*
|
|
1979
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1980
|
-
*
|
|
1981
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
1982
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1983
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1984
|
-
* See the License for the specific language governing permissions and
|
|
1985
|
-
* limitations under the License.
|
|
1986
|
-
*
|
|
1987
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1988
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
1989
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1974
|
+
/* *
|
|
1975
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
1976
|
+
* you may not use this file except in compliance with the License.
|
|
1977
|
+
* You may obtain a copy of the License at
|
|
1978
|
+
*
|
|
1979
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
1980
|
+
*
|
|
1981
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
1982
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
1983
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
1984
|
+
* See the License for the specific language governing permissions and
|
|
1985
|
+
* limitations under the License.
|
|
1986
|
+
*
|
|
1987
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
1988
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
1989
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
1990
1990
|
* */
|
|
1991
1991
|
var LayerStatus;
|
|
1992
1992
|
(function (LayerStatus) {
|
|
@@ -2160,11 +2160,11 @@ const checkValidLayersPayload = (layers, mapId) => {
|
|
|
2160
2160
|
}
|
|
2161
2161
|
return true;
|
|
2162
2162
|
};
|
|
2163
|
-
/**
|
|
2164
|
-
* This will get the map from the map draftstate.
|
|
2165
|
-
* If the mapId is not found, it registers one and returns it.
|
|
2166
|
-
* @param mapId The mapID
|
|
2167
|
-
* @param draft Draft map state
|
|
2163
|
+
/**
|
|
2164
|
+
* This will get the map from the map draftstate.
|
|
2165
|
+
* If the mapId is not found, it registers one and returns it.
|
|
2166
|
+
* @param mapId The mapID
|
|
2167
|
+
* @param draft Draft map state
|
|
2168
2168
|
*/
|
|
2169
2169
|
const getDraftMapById = (mapId, draft) => {
|
|
2170
2170
|
const map = draft.byId[mapId];
|
|
@@ -2179,14 +2179,14 @@ const getDraftMapById = (mapId, draft) => {
|
|
|
2179
2179
|
}
|
|
2180
2180
|
return draft.byId[mapId];
|
|
2181
2181
|
};
|
|
2182
|
-
/**
|
|
2183
|
-
* Sets the map dimension in the state.
|
|
2184
|
-
* It will add dimensions to the map if they are missing.
|
|
2185
|
-
* If will update the existing dimensions if overwriteCurrentValue is set to true
|
|
2186
|
-
* @param draft The map draft state
|
|
2187
|
-
* @param mapId The mapId to update the dimensions for
|
|
2188
|
-
* @param dimensionFromAction The dimension from the action
|
|
2189
|
-
* @param overwriteCurrentValue True to overwrite existing value. False to add a new dimension if one is not there yet.
|
|
2182
|
+
/**
|
|
2183
|
+
* Sets the map dimension in the state.
|
|
2184
|
+
* It will add dimensions to the map if they are missing.
|
|
2185
|
+
* If will update the existing dimensions if overwriteCurrentValue is set to true
|
|
2186
|
+
* @param draft The map draft state
|
|
2187
|
+
* @param mapId The mapId to update the dimensions for
|
|
2188
|
+
* @param dimensionFromAction The dimension from the action
|
|
2189
|
+
* @param overwriteCurrentValue True to overwrite existing value. False to add a new dimension if one is not there yet.
|
|
2190
2190
|
*/
|
|
2191
2191
|
const produceDraftStateSetWebMapDimension = (draft, mapId, dimensionFromAction, overwriteCurrentValue) => {
|
|
2192
2192
|
const map = getDraftMapById(mapId, draft);
|
|
@@ -2210,10 +2210,10 @@ const produceDraftStateSetWebMapDimension = (draft, mapId, dimensionFromAction,
|
|
|
2210
2210
|
}
|
|
2211
2211
|
}
|
|
2212
2212
|
};
|
|
2213
|
-
/**
|
|
2214
|
-
* Find the mapId belonging to a layerId
|
|
2215
|
-
* @param draft The WebMapState containing the state of all maps.
|
|
2216
|
-
* @param layerId The layer Id to find in the maps
|
|
2213
|
+
/**
|
|
2214
|
+
* Find the mapId belonging to a layerId
|
|
2215
|
+
* @param draft The WebMapState containing the state of all maps.
|
|
2216
|
+
* @param layerId The layer Id to find in the maps
|
|
2217
2217
|
*/
|
|
2218
2218
|
const findMapIdFromLayerId = (mapState, layerId) => {
|
|
2219
2219
|
if (!mapState || !layerId) {
|
|
@@ -2224,9 +2224,9 @@ const findMapIdFromLayerId = (mapState, layerId) => {
|
|
|
2224
2224
|
});
|
|
2225
2225
|
return result === undefined ? null : result;
|
|
2226
2226
|
};
|
|
2227
|
-
/*
|
|
2228
|
-
When a layer dimension is changed, it can affect the map dimension if the layer dimension is linked with the map.
|
|
2229
|
-
We need to find out from the layerId to which map it is coupled, and then adjust the map dimension
|
|
2227
|
+
/*
|
|
2228
|
+
When a layer dimension is changed, it can affect the map dimension if the layer dimension is linked with the map.
|
|
2229
|
+
We need to find out from the layerId to which map it is coupled, and then adjust the map dimension
|
|
2230
2230
|
*/
|
|
2231
2231
|
const produceDraftStateSetMapDimensionFromLayerChangeDimension = (draft, layerId, dimension) => {
|
|
2232
2232
|
const wmjsDimension = webmapUtils.getWMJSDimensionForLayerAndDimension(layerId, dimension.name);
|
|
@@ -2243,11 +2243,11 @@ const produceDraftStateSetMapDimensionFromLayerChangeDimension = (draft, layerId
|
|
|
2243
2243
|
}
|
|
2244
2244
|
produceDraftStateSetWebMapDimension(draft, mapId, dimension, true);
|
|
2245
2245
|
};
|
|
2246
|
-
/**
|
|
2247
|
-
* Returns array with new order of swapped elements
|
|
2248
|
-
* @param array Array with ids
|
|
2249
|
-
* @param oldIndex Old index of element in array
|
|
2250
|
-
* @param newIndex New index of element in array
|
|
2246
|
+
/**
|
|
2247
|
+
* Returns array with new order of swapped elements
|
|
2248
|
+
* @param array Array with ids
|
|
2249
|
+
* @param oldIndex Old index of element in array
|
|
2250
|
+
* @param newIndex New index of element in array
|
|
2251
2251
|
*/
|
|
2252
2252
|
function moveArrayElements(array, oldIndex, newIndex) {
|
|
2253
2253
|
const newArray = [...array];
|
|
@@ -2287,11 +2287,11 @@ const getSpeedFactor = speedDelay => {
|
|
|
2287
2287
|
return defaultDelay / speedDelay;
|
|
2288
2288
|
};
|
|
2289
2289
|
const getAnimationDuration = (animationEndTime, animationStartTime) => animationEndTime && animationStartTime ? dateUtils.differenceInMinutes(new Date(animationEndTime), new Date(animationStartTime)) : 0;
|
|
2290
|
-
/**
|
|
2291
|
-
* @param animationStart
|
|
2292
|
-
* @param animationEnd
|
|
2293
|
-
* @param iso8601Intervals
|
|
2294
|
-
* @returns WebMapAnimationList with time points
|
|
2290
|
+
/**
|
|
2291
|
+
* @param animationStart
|
|
2292
|
+
* @param animationEnd
|
|
2293
|
+
* @param iso8601Intervals
|
|
2294
|
+
* @returns WebMapAnimationList with time points
|
|
2295
2295
|
*/
|
|
2296
2296
|
const generateAnimationList = (unixAnimationStart, unixAnimationEnd, timeValues) => {
|
|
2297
2297
|
if (!unixAnimationStart || !unixAnimationEnd || !timeValues) {
|
|
@@ -2342,10 +2342,10 @@ const generateAnimationList = (unixAnimationStart, unixAnimationEnd, timeValues)
|
|
|
2342
2342
|
});
|
|
2343
2343
|
return animationList;
|
|
2344
2344
|
};
|
|
2345
|
-
/**
|
|
2346
|
-
* Parses the time dimension values string to an array of ISO8601 intervals
|
|
2347
|
-
* @param timeInterval
|
|
2348
|
-
* @returns An array of ISO8601 intervals
|
|
2345
|
+
/**
|
|
2346
|
+
* Parses the time dimension values string to an array of ISO8601 intervals
|
|
2347
|
+
* @param timeInterval
|
|
2348
|
+
* @returns An array of ISO8601 intervals
|
|
2349
2349
|
*/
|
|
2350
2350
|
const parseTimeDimToISO8601Interval = timeInterval => {
|
|
2351
2351
|
if (!timeInterval || !timeInterval.includes('/')) {
|
|
@@ -2380,11 +2380,11 @@ var utils$3 = /*#__PURE__*/Object.freeze({
|
|
|
2380
2380
|
produceDraftStateSetWebMapDimension: produceDraftStateSetWebMapDimension
|
|
2381
2381
|
});
|
|
2382
2382
|
|
|
2383
|
-
/**
|
|
2384
|
-
* Sets a dimension value for a layer in the state. If the dimension does not exist it is added to the layer.
|
|
2385
|
-
* @param draft The draft layerstate
|
|
2386
|
-
* @param layerId The layerId
|
|
2387
|
-
* @param dimensionValueToUpdate The dimension with values to update in the layer.
|
|
2383
|
+
/**
|
|
2384
|
+
* Sets a dimension value for a layer in the state. If the dimension does not exist it is added to the layer.
|
|
2385
|
+
* @param draft The draft layerstate
|
|
2386
|
+
* @param layerId The layerId
|
|
2387
|
+
* @param dimensionValueToUpdate The dimension with values to update in the layer.
|
|
2388
2388
|
*/
|
|
2389
2389
|
const produceLayerDimensionDraftState = (draft, layerId, dimensionValueToUpdate) => {
|
|
2390
2390
|
const layer = draft.byId[layerId];
|
|
@@ -2439,11 +2439,11 @@ const produceDimensionActionForMapLayer = (layerDim, wmjsDimension, newDimension
|
|
|
2439
2439
|
validSyncSelection: true
|
|
2440
2440
|
});
|
|
2441
2441
|
};
|
|
2442
|
-
/**
|
|
2443
|
-
* For the given dimension, it creates a new draft state for all other (linked or synced) layers inside the map.
|
|
2444
|
-
* @param draft
|
|
2445
|
-
* @param dimension
|
|
2446
|
-
* @param mapId
|
|
2442
|
+
/**
|
|
2443
|
+
* For the given dimension, it creates a new draft state for all other (linked or synced) layers inside the map.
|
|
2444
|
+
* @param draft
|
|
2445
|
+
* @param dimension
|
|
2446
|
+
* @param mapId
|
|
2447
2447
|
*/
|
|
2448
2448
|
const produceDraftStateForAllLayersForDimensionWithinMap = (draft, dimension, mapId, layerIdFromAction /* Layer ID or null if not known */) => {
|
|
2449
2449
|
if (!mapId) {
|
|
@@ -2488,17 +2488,17 @@ const produceDraftStateForAllLayersForDimensionWithinMap = (draft, dimension, ma
|
|
|
2488
2488
|
}
|
|
2489
2489
|
});
|
|
2490
2490
|
};
|
|
2491
|
-
/**
|
|
2492
|
-
* Returns the list of dimensions without the time dimension
|
|
2493
|
-
* @param dimensions Dimension[]
|
|
2491
|
+
/**
|
|
2492
|
+
* Returns the list of dimensions without the time dimension
|
|
2493
|
+
* @param dimensions Dimension[]
|
|
2494
2494
|
*/
|
|
2495
2495
|
const filterNonTimeDimensions = dimensions => {
|
|
2496
2496
|
var _a;
|
|
2497
2497
|
return (_a = dimensions === null || dimensions === void 0 ? void 0 : dimensions.filter(dim => dim.name !== 'time')) !== null && _a !== void 0 ? _a : [];
|
|
2498
2498
|
};
|
|
2499
|
-
/**
|
|
2500
|
-
* Returns the list of dimensions without the time dimension
|
|
2501
|
-
* @param dimensions Dimension[]
|
|
2499
|
+
/**
|
|
2500
|
+
* Returns the list of dimensions without the time dimension
|
|
2501
|
+
* @param dimensions Dimension[]
|
|
2502
2502
|
*/
|
|
2503
2503
|
const filterCurrentValueFromDimensions = dimensions => {
|
|
2504
2504
|
var _a;
|
|
@@ -2518,97 +2518,97 @@ var utils$2 = /*#__PURE__*/Object.freeze({
|
|
|
2518
2518
|
produceDraftStateForAllLayersForDimensionWithinMap: produceDraftStateForAllLayersForDimensionWithinMap
|
|
2519
2519
|
});
|
|
2520
2520
|
|
|
2521
|
-
/* *
|
|
2522
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2523
|
-
* you may not use this file except in compliance with the License.
|
|
2524
|
-
* You may obtain a copy of the License at
|
|
2525
|
-
*
|
|
2526
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2527
|
-
*
|
|
2528
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
2529
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2530
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2531
|
-
* See the License for the specific language governing permissions and
|
|
2532
|
-
* limitations under the License.
|
|
2533
|
-
*
|
|
2534
|
-
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2535
|
-
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
2536
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2521
|
+
/* *
|
|
2522
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2523
|
+
* you may not use this file except in compliance with the License.
|
|
2524
|
+
* You may obtain a copy of the License at
|
|
2525
|
+
*
|
|
2526
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2527
|
+
*
|
|
2528
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
2529
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2530
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2531
|
+
* See the License for the specific language governing permissions and
|
|
2532
|
+
* limitations under the License.
|
|
2533
|
+
*
|
|
2534
|
+
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2535
|
+
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
2536
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2537
2537
|
* */
|
|
2538
|
-
/**
|
|
2539
|
-
* These actions causes circular dependency if they are defined in the reducer.ts file.
|
|
2540
|
-
* Therefor they are instead added to this file
|
|
2541
|
-
* https://redux-toolkit.js.org/usage/usage-guide#exporting-and-using-slices
|
|
2538
|
+
/**
|
|
2539
|
+
* These actions causes circular dependency if they are defined in the reducer.ts file.
|
|
2540
|
+
* Therefor they are instead added to this file
|
|
2541
|
+
* https://redux-toolkit.js.org/usage/usage-guide#exporting-and-using-slices
|
|
2542
2542
|
*/
|
|
2543
2543
|
const mapChangeDimension = createAction('MAP_CHANGE_DIMENSION');
|
|
2544
2544
|
const setMapPreset = createAction('SET_MAP_PRESET');
|
|
2545
2545
|
|
|
2546
|
-
/* *
|
|
2547
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2548
|
-
* you may not use this file except in compliance with the License.
|
|
2549
|
-
* You may obtain a copy of the License at
|
|
2550
|
-
*
|
|
2551
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2552
|
-
*
|
|
2553
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
2554
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2555
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2556
|
-
* See the License for the specific language governing permissions and
|
|
2557
|
-
* limitations under the License.
|
|
2558
|
-
*
|
|
2559
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2560
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
2561
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2546
|
+
/* *
|
|
2547
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2548
|
+
* you may not use this file except in compliance with the License.
|
|
2549
|
+
* You may obtain a copy of the License at
|
|
2550
|
+
*
|
|
2551
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2552
|
+
*
|
|
2553
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
2554
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2555
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2556
|
+
* See the License for the specific language governing permissions and
|
|
2557
|
+
* limitations under the License.
|
|
2558
|
+
*
|
|
2559
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2560
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
2561
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2562
2562
|
* */
|
|
2563
|
-
/**
|
|
2564
|
-
* Generic action to set the time.
|
|
2565
|
-
*
|
|
2566
|
-
* @param payload: SetTimePayload;
|
|
2567
|
-
* {
|
|
2568
|
-
* sourceId: string; // Source where the new time value originates from
|
|
2569
|
-
* value: string; // ISO 8601 string time value like "2010-10-01T00:00:00Z"
|
|
2570
|
-
* }
|
|
2563
|
+
/**
|
|
2564
|
+
* Generic action to set the time.
|
|
2565
|
+
*
|
|
2566
|
+
* @param payload: SetTimePayload;
|
|
2567
|
+
* {
|
|
2568
|
+
* sourceId: string; // Source where the new time value originates from
|
|
2569
|
+
* value: string; // ISO 8601 string time value like "2010-10-01T00:00:00Z"
|
|
2570
|
+
* }
|
|
2571
2571
|
*/
|
|
2572
2572
|
const setTime = createAction('GENERIC_SETTIME');
|
|
2573
|
-
/**
|
|
2574
|
-
* Generic action to set the bounding box.
|
|
2575
|
-
*
|
|
2576
|
-
* @param payload: SetBboxPayload;
|
|
2577
|
-
*
|
|
2578
|
-
* {
|
|
2579
|
-
* sourceId: string; // Source where the new time value originates from
|
|
2580
|
-
* bbox: { // Bbbox object
|
|
2581
|
-
* left: number;
|
|
2582
|
-
* bottom: number;
|
|
2583
|
-
* right: number;
|
|
2584
|
-
* top: number;
|
|
2585
|
-
* };
|
|
2586
|
-
* srs: string; // Projection string according to EPSG, e.g. (EPSG:3857 == Mercator)
|
|
2587
|
-
* }
|
|
2573
|
+
/**
|
|
2574
|
+
* Generic action to set the bounding box.
|
|
2575
|
+
*
|
|
2576
|
+
* @param payload: SetBboxPayload;
|
|
2577
|
+
*
|
|
2578
|
+
* {
|
|
2579
|
+
* sourceId: string; // Source where the new time value originates from
|
|
2580
|
+
* bbox: { // Bbbox object
|
|
2581
|
+
* left: number;
|
|
2582
|
+
* bottom: number;
|
|
2583
|
+
* right: number;
|
|
2584
|
+
* top: number;
|
|
2585
|
+
* };
|
|
2586
|
+
* srs: string; // Projection string according to EPSG, e.g. (EPSG:3857 == Mercator)
|
|
2587
|
+
* }
|
|
2588
2588
|
*/
|
|
2589
2589
|
const setBbox = createAction('GENERIC_SETBBOX');
|
|
2590
2590
|
|
|
2591
|
-
/* *
|
|
2592
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2593
|
-
* you may not use this file except in compliance with the License.
|
|
2594
|
-
* You may obtain a copy of the License at
|
|
2595
|
-
*
|
|
2596
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2597
|
-
*
|
|
2598
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
2599
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2600
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2601
|
-
* See the License for the specific language governing permissions and
|
|
2602
|
-
* limitations under the License.
|
|
2603
|
-
*
|
|
2604
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2605
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
2606
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2591
|
+
/* *
|
|
2592
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
2593
|
+
* you may not use this file except in compliance with the License.
|
|
2594
|
+
* You may obtain a copy of the License at
|
|
2595
|
+
*
|
|
2596
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
2597
|
+
*
|
|
2598
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
2599
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
2600
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
2601
|
+
* See the License for the specific language governing permissions and
|
|
2602
|
+
* limitations under the License.
|
|
2603
|
+
*
|
|
2604
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
2605
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
2606
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
2607
2607
|
* */
|
|
2608
|
-
/**
|
|
2609
|
-
* These actions are fired by the generic/listener.ts, based on generic actions and the synchronizationGroup state.
|
|
2610
|
-
*
|
|
2611
|
-
* These actions should not be used by components directly. Components should only use the generic actions.
|
|
2608
|
+
/**
|
|
2609
|
+
* These actions are fired by the generic/listener.ts, based on generic actions and the synchronizationGroup state.
|
|
2610
|
+
*
|
|
2611
|
+
* These actions should not be used by components directly. Components should only use the generic actions.
|
|
2612
2612
|
*/
|
|
2613
2613
|
const setTimeSync = createAction('GENERIC_SYNC_SETTIME', (setTimePayload, targets, groups) => {
|
|
2614
2614
|
return {
|
|
@@ -2828,10 +2828,10 @@ const slice$7 = createSlice({
|
|
|
2828
2828
|
if (!checkValidLayersPayload(layers, mapId)) {
|
|
2829
2829
|
return;
|
|
2830
2830
|
}
|
|
2831
|
-
/*
|
|
2832
|
-
All layer id's for the specified mapId should be removed.
|
|
2833
|
-
This is done by filtering the allId array. Keeping only the layer id's which don't exist in the byId object
|
|
2834
|
-
At the same time the byId object is synchronized.
|
|
2831
|
+
/*
|
|
2832
|
+
All layer id's for the specified mapId should be removed.
|
|
2833
|
+
This is done by filtering the allId array. Keeping only the layer id's which don't exist in the byId object
|
|
2834
|
+
At the same time the byId object is synchronized.
|
|
2835
2835
|
*/
|
|
2836
2836
|
draft.allIds = draft.allIds.filter(layerId => {
|
|
2837
2837
|
if (draft.byId[layerId] && draft.byId[layerId].layerType !== LayerType.baseLayer && draft.byId[layerId].layerType !== LayerType.overLayer && draft.byId[layerId].mapId === mapId) {
|
|
@@ -2840,8 +2840,8 @@ const slice$7 = createSlice({
|
|
|
2840
2840
|
}
|
|
2841
2841
|
return true;
|
|
2842
2842
|
});
|
|
2843
|
-
/*
|
|
2844
|
-
Here we set the layers for the mapId from the action. byId and allIds is updated.
|
|
2843
|
+
/*
|
|
2844
|
+
Here we set the layers for the mapId from the action. byId and allIds is updated.
|
|
2845
2845
|
*/
|
|
2846
2846
|
layers.forEach(layer => {
|
|
2847
2847
|
draft.byId[layer.id] = createLayer(Object.assign({
|
|
@@ -3192,11 +3192,11 @@ const slice$7 = createSlice({
|
|
|
3192
3192
|
produceDraftStateForAllLayersForDimensionWithinMap(draft, dimension, targetId, null);
|
|
3193
3193
|
});
|
|
3194
3194
|
}).addCase(setLayerActionSync, (draft, action) => {
|
|
3195
|
-
/*
|
|
3196
|
-
* This GENERIC_SYNC_SETLAYERACTIONS action is generated by the syncgroup listener.
|
|
3197
|
-
* It has multiple targets (Layers) in its payload.
|
|
3198
|
-
* These targets can be used as payloads in new Layer actions.
|
|
3199
|
-
* These actions are here handled via the layer reducer, as it is the same logic
|
|
3195
|
+
/*
|
|
3196
|
+
* This GENERIC_SYNC_SETLAYERACTIONS action is generated by the syncgroup listener.
|
|
3197
|
+
* It has multiple targets (Layers) in its payload.
|
|
3198
|
+
* These targets can be used as payloads in new Layer actions.
|
|
3199
|
+
* These actions are here handled via the layer reducer, as it is the same logic
|
|
3200
3200
|
*/
|
|
3201
3201
|
const {
|
|
3202
3202
|
targets,
|
|
@@ -3233,22 +3233,22 @@ const {
|
|
|
3233
3233
|
} = slice$7;
|
|
3234
3234
|
const layerActions = slice$7.actions;
|
|
3235
3235
|
|
|
3236
|
-
/* *
|
|
3237
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3238
|
-
* you may not use this file except in compliance with the License.
|
|
3239
|
-
* You may obtain a copy of the License at
|
|
3240
|
-
*
|
|
3241
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3242
|
-
*
|
|
3243
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
3244
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3245
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3246
|
-
* See the License for the specific language governing permissions and
|
|
3247
|
-
* limitations under the License.
|
|
3248
|
-
*
|
|
3249
|
-
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3250
|
-
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
3251
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3236
|
+
/* *
|
|
3237
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3238
|
+
* you may not use this file except in compliance with the License.
|
|
3239
|
+
* You may obtain a copy of the License at
|
|
3240
|
+
*
|
|
3241
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3242
|
+
*
|
|
3243
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
3244
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3245
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3246
|
+
* See the License for the specific language governing permissions and
|
|
3247
|
+
* limitations under the License.
|
|
3248
|
+
*
|
|
3249
|
+
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3250
|
+
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
3251
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3252
3252
|
* */
|
|
3253
3253
|
const selectorMemoizationOptions = {
|
|
3254
3254
|
memoizeOptions: {
|
|
@@ -3263,24 +3263,24 @@ var utils$1 = /*#__PURE__*/Object.freeze({
|
|
|
3263
3263
|
});
|
|
3264
3264
|
|
|
3265
3265
|
const layerStore = store => store === null || store === void 0 ? void 0 : store.layers;
|
|
3266
|
-
/**
|
|
3267
|
-
* Gets a layer from the layers part of the store by its Id
|
|
3268
|
-
*
|
|
3269
|
-
* Example: layer = getLayerById(store, 'layerId')
|
|
3270
|
-
* @param {object} store object from which the layer state will be extracted
|
|
3271
|
-
* @param {string} layerId Id of the layer
|
|
3272
|
-
* @returns {object} object containing layer information (service, name, style, enabled etc.)
|
|
3266
|
+
/**
|
|
3267
|
+
* Gets a layer from the layers part of the store by its Id
|
|
3268
|
+
*
|
|
3269
|
+
* Example: layer = getLayerById(store, 'layerId')
|
|
3270
|
+
* @param {object} store object from which the layer state will be extracted
|
|
3271
|
+
* @param {string} layerId Id of the layer
|
|
3272
|
+
* @returns {object} object containing layer information (service, name, style, enabled etc.)
|
|
3273
3273
|
*/
|
|
3274
3274
|
const getLayerById = createSelector([layerStore, (layerStore, layerId) => layerId], (layerState, layerId) => {
|
|
3275
3275
|
return layerState && layerState.byId && layerState.byId[layerId];
|
|
3276
3276
|
}, selectorMemoizationOptions);
|
|
3277
|
-
/**
|
|
3278
|
-
* Gets a layer from the layers part of the store by its Id, but without the time dimension. (All other dimensions are still included)
|
|
3279
|
-
*
|
|
3280
|
-
* Example: layer = getLayerByIdWithoutTimeDimension(store, 'layerId')
|
|
3281
|
-
* @param {object} store object from which the layer state will be extracted
|
|
3282
|
-
* @param {string} layerId Id of the layer
|
|
3283
|
-
* @returns {object} object containing layer information (service, name, style, enabled etc.)
|
|
3277
|
+
/**
|
|
3278
|
+
* Gets a layer from the layers part of the store by its Id, but without the time dimension. (All other dimensions are still included)
|
|
3279
|
+
*
|
|
3280
|
+
* Example: layer = getLayerByIdWithoutTimeDimension(store, 'layerId')
|
|
3281
|
+
* @param {object} store object from which the layer state will be extracted
|
|
3282
|
+
* @param {string} layerId Id of the layer
|
|
3283
|
+
* @returns {object} object containing layer information (service, name, style, enabled etc.)
|
|
3284
3284
|
*/
|
|
3285
3285
|
const getLayerByIdWithoutTimeDimension = createSelector([layerStore, (layerStore, layerId) => layerId], (layerState, layerId) => {
|
|
3286
3286
|
const layer = layerState && layerState.byId && layerState.byId[layerId];
|
|
@@ -3289,193 +3289,193 @@ const getLayerByIdWithoutTimeDimension = createSelector([layerStore, (layerStore
|
|
|
3289
3289
|
return draftLayer;
|
|
3290
3290
|
}) : undefined;
|
|
3291
3291
|
}, selectorMemoizationOptions);
|
|
3292
|
-
/**
|
|
3293
|
-
* Retrieves all layers indexed by layerId
|
|
3294
|
-
*
|
|
3295
|
-
* Example: layers = getLayersById(store)
|
|
3296
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3297
|
-
* @returns {object} returnType: object - an object of all layers containing layer information (service, name, style, enabled etc.) indexed by layerId
|
|
3292
|
+
/**
|
|
3293
|
+
* Retrieves all layers indexed by layerId
|
|
3294
|
+
*
|
|
3295
|
+
* Example: layers = getLayersById(store)
|
|
3296
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3297
|
+
* @returns {object} returnType: object - an object of all layers containing layer information (service, name, style, enabled etc.) indexed by layerId
|
|
3298
3298
|
*/
|
|
3299
3299
|
const getLayersById = createSelector(layerStore, store => {
|
|
3300
3300
|
var _a;
|
|
3301
3301
|
return (_a = store === null || store === void 0 ? void 0 : store.byId) !== null && _a !== void 0 ? _a : null;
|
|
3302
3302
|
}, selectorMemoizationOptions);
|
|
3303
|
-
/**
|
|
3304
|
-
* Retrieves all layerIds
|
|
3305
|
-
*
|
|
3306
|
-
* Example: layerIds = getLayersIds(store)
|
|
3307
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3308
|
-
* @returns {array} returnType: array - an array of all layerIds
|
|
3303
|
+
/**
|
|
3304
|
+
* Retrieves all layerIds
|
|
3305
|
+
*
|
|
3306
|
+
* Example: layerIds = getLayersIds(store)
|
|
3307
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3308
|
+
* @returns {array} returnType: array - an array of all layerIds
|
|
3309
3309
|
*/
|
|
3310
3310
|
const getLayersIds = createSelector(layerStore, store => store ? store.allIds : [], selectorMemoizationOptions);
|
|
3311
|
-
/**
|
|
3312
|
-
* Retrieves all layers (including base layers and overlayers)
|
|
3313
|
-
*
|
|
3314
|
-
* Example: layers = getAllLayers(store)
|
|
3315
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3316
|
-
* @returns {array} returnType: array - an array of all layers containing layer information (service, name, style, enabled etc.)
|
|
3311
|
+
/**
|
|
3312
|
+
* Retrieves all layers (including base layers and overlayers)
|
|
3313
|
+
*
|
|
3314
|
+
* Example: layers = getAllLayers(store)
|
|
3315
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3316
|
+
* @returns {array} returnType: array - an array of all layers containing layer information (service, name, style, enabled etc.)
|
|
3317
3317
|
*/
|
|
3318
3318
|
const getAllLayers = createSelector(getLayersIds, getLayersById, (ids, layers) => ids.map(layerId => layers[layerId]), selectorMemoizationOptions);
|
|
3319
|
-
/**
|
|
3320
|
-
* Retrieves all layers (including base layers and overlayers) for the given mapId
|
|
3321
|
-
*
|
|
3322
|
-
* Example: layers = getLayersByMapId(store, mapId)
|
|
3323
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3324
|
-
* @param {string} mapId mapId: string - mapId
|
|
3325
|
-
* @returns {array} returnType: ReduxLayer[] - an array of all layers containing layer information (service, name, style, enabled etc.)
|
|
3319
|
+
/**
|
|
3320
|
+
* Retrieves all layers (including base layers and overlayers) for the given mapId
|
|
3321
|
+
*
|
|
3322
|
+
* Example: layers = getLayersByMapId(store, mapId)
|
|
3323
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3324
|
+
* @param {string} mapId mapId: string - mapId
|
|
3325
|
+
* @returns {array} returnType: ReduxLayer[] - an array of all layers containing layer information (service, name, style, enabled etc.)
|
|
3326
3326
|
*/
|
|
3327
3327
|
const getLayersByMapId = createSelector(getAllLayers, (_store, _mapId) => _mapId, (layers, mapId) => {
|
|
3328
3328
|
return layers.filter(layer => layer.mapId === mapId);
|
|
3329
3329
|
}, selectorMemoizationOptions);
|
|
3330
|
-
/**
|
|
3331
|
-
* Retrieves all layers that aren't base layers and aren't overlayers
|
|
3332
|
-
*
|
|
3333
|
-
* Example: layers = getLayers(store)
|
|
3334
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3335
|
-
* @returns {array} returnType: array - an array of all non-baselayers containing layer information (service, name, style, enabled etc.)
|
|
3330
|
+
/**
|
|
3331
|
+
* Retrieves all layers that aren't base layers and aren't overlayers
|
|
3332
|
+
*
|
|
3333
|
+
* Example: layers = getLayers(store)
|
|
3334
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3335
|
+
* @returns {array} returnType: array - an array of all non-baselayers containing layer information (service, name, style, enabled etc.)
|
|
3336
3336
|
*/
|
|
3337
3337
|
const getLayers = createSelector(getAllLayers, layers => layers.filter(layer => layer.layerType !== LayerType.baseLayer && layer.layerType !== LayerType.overLayer), selectorMemoizationOptions);
|
|
3338
|
-
/**
|
|
3339
|
-
* Retrieves all baselayers
|
|
3340
|
-
*
|
|
3341
|
-
* Example: layers = getBaseLayers(store)
|
|
3342
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3343
|
-
* @returns {array} returnType: array - an array of all baselayers containing layer information (service, name, style, enabled etc.)
|
|
3338
|
+
/**
|
|
3339
|
+
* Retrieves all baselayers
|
|
3340
|
+
*
|
|
3341
|
+
* Example: layers = getBaseLayers(store)
|
|
3342
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3343
|
+
* @returns {array} returnType: array - an array of all baselayers containing layer information (service, name, style, enabled etc.)
|
|
3344
3344
|
*/
|
|
3345
3345
|
const getBaseLayers = createSelector(getAllLayers, layers => layers.filter(layer => layer.layerType === LayerType.baseLayer), selectorMemoizationOptions);
|
|
3346
|
-
/**
|
|
3347
|
-
* Retrieves all overLayers
|
|
3348
|
-
*
|
|
3349
|
-
* Example: layers = getOverLayers(store)
|
|
3350
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3351
|
-
* @returns {array} returnType: array - an array of all overLayers containing layer information (service, name, style, enabled etc.)
|
|
3346
|
+
/**
|
|
3347
|
+
* Retrieves all overLayers
|
|
3348
|
+
*
|
|
3349
|
+
* Example: layers = getOverLayers(store)
|
|
3350
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3351
|
+
* @returns {array} returnType: array - an array of all overLayers containing layer information (service, name, style, enabled etc.)
|
|
3352
3352
|
*/
|
|
3353
3353
|
const getOverLayers = createSelector(getAllLayers, layers => layers.filter(layer => layer.layerType === LayerType.overLayer), selectorMemoizationOptions);
|
|
3354
|
-
/**
|
|
3355
|
-
* Retrieves all featureLayers
|
|
3356
|
-
*
|
|
3357
|
-
* Example: layers = getFeatureLayers(store)
|
|
3358
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3359
|
-
* @returns {array} returnType: array - an array of all featureLayers
|
|
3354
|
+
/**
|
|
3355
|
+
* Retrieves all featureLayers
|
|
3356
|
+
*
|
|
3357
|
+
* Example: layers = getFeatureLayers(store)
|
|
3358
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3359
|
+
* @returns {array} returnType: array - an array of all featureLayers
|
|
3360
3360
|
*/
|
|
3361
3361
|
const getFeatureLayers = createSelector(getAllLayers, layers => layers.filter(layer => layer.layerType === LayerType.featureLayer), selectorMemoizationOptions);
|
|
3362
|
-
/**
|
|
3363
|
-
* Gets dimensions of the passed layer
|
|
3364
|
-
*
|
|
3365
|
-
* Example: layerDimensions = getLayerDimensions(store, 'layerId_1')
|
|
3366
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3367
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3368
|
-
* @returns {array} returnType: Dimension[] - array containing layer dimensions
|
|
3362
|
+
/**
|
|
3363
|
+
* Gets dimensions of the passed layer
|
|
3364
|
+
*
|
|
3365
|
+
* Example: layerDimensions = getLayerDimensions(store, 'layerId_1')
|
|
3366
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3367
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3368
|
+
* @returns {array} returnType: Dimension[] - array containing layer dimensions
|
|
3369
3369
|
*/
|
|
3370
3370
|
const getLayerDimensions = createSelector(getLayerById, layer => {
|
|
3371
3371
|
var _a;
|
|
3372
3372
|
return (_a = layer === null || layer === void 0 ? void 0 : layer.dimensions) !== null && _a !== void 0 ? _a : [];
|
|
3373
3373
|
}, selectorMemoizationOptions);
|
|
3374
|
-
/**
|
|
3375
|
-
* Gets dimensions of the passed layer, excluding the time dimension
|
|
3376
|
-
*
|
|
3377
|
-
* Example: layerNonTimeDimensions = getLayerNonTimeDimensions(store, 'layerId_1')
|
|
3378
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3379
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3380
|
-
* @returns {array} returnType: Dimension[] - array containing layer dimensions, excluding the time dimension
|
|
3374
|
+
/**
|
|
3375
|
+
* Gets dimensions of the passed layer, excluding the time dimension
|
|
3376
|
+
*
|
|
3377
|
+
* Example: layerNonTimeDimensions = getLayerNonTimeDimensions(store, 'layerId_1')
|
|
3378
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3379
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3380
|
+
* @returns {array} returnType: Dimension[] - array containing layer dimensions, excluding the time dimension
|
|
3381
3381
|
*/
|
|
3382
3382
|
const getLayerNonTimeDimensions = createSelector(getLayerDimensions, dimensions => filterNonTimeDimensions(dimensions), selectorMemoizationOptions);
|
|
3383
|
-
/**
|
|
3384
|
-
* Gets time dimension of the passed layer
|
|
3385
|
-
*
|
|
3386
|
-
* Example: timeDimension = getLayerTimeDimension(store, 'layerId_1')
|
|
3387
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3388
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3389
|
-
* @returns {object} returnType: object - object of layer time dimension
|
|
3383
|
+
/**
|
|
3384
|
+
* Gets time dimension of the passed layer
|
|
3385
|
+
*
|
|
3386
|
+
* Example: timeDimension = getLayerTimeDimension(store, 'layerId_1')
|
|
3387
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3388
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3389
|
+
* @returns {object} returnType: object - object of layer time dimension
|
|
3390
3390
|
*/
|
|
3391
3391
|
const getLayerTimeDimension = createSelector(getLayerDimensions, dimensions => dimensions === null || dimensions === void 0 ? void 0 : dimensions.find(dimension => dimension.name === 'time'), selectorMemoizationOptions);
|
|
3392
|
-
/**
|
|
3393
|
-
* Returns a boolean indicating whether the layer has a time dimension
|
|
3394
|
-
*
|
|
3395
|
-
* Example: layerHasTimeDimension = getLayerHasTimeDimension(store, 'layerId_1')
|
|
3396
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3397
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3398
|
-
* @returns {boolean} returnType: boolean - boolean indicating whether the layer has a time dimension
|
|
3392
|
+
/**
|
|
3393
|
+
* Returns a boolean indicating whether the layer has a time dimension
|
|
3394
|
+
*
|
|
3395
|
+
* Example: layerHasTimeDimension = getLayerHasTimeDimension(store, 'layerId_1')
|
|
3396
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3397
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3398
|
+
* @returns {boolean} returnType: boolean - boolean indicating whether the layer has a time dimension
|
|
3399
3399
|
*/
|
|
3400
3400
|
const getLayerHasTimeDimension = createSelector(getLayerTimeDimension, timeDimension => !!timeDimension, selectorMemoizationOptions);
|
|
3401
3401
|
const getLayerCurrentTime = createSelector(getLayerTimeDimension, dimension => dimension === null || dimension === void 0 ? void 0 : dimension.currentValue, selectorMemoizationOptions);
|
|
3402
|
-
/**
|
|
3403
|
-
* Gets specified dimension of the passed layer
|
|
3404
|
-
*
|
|
3405
|
-
* Example: dimension = getLayerDimension(store, 'layerId_1', 'elevation')
|
|
3406
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3407
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3408
|
-
* @param {string} dimensionName dimensionName: string - name of dimension you want to retrieve the dimension data for
|
|
3409
|
-
* @returns {object} returnType: object - object of layer dimension
|
|
3402
|
+
/**
|
|
3403
|
+
* Gets specified dimension of the passed layer
|
|
3404
|
+
*
|
|
3405
|
+
* Example: dimension = getLayerDimension(store, 'layerId_1', 'elevation')
|
|
3406
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3407
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3408
|
+
* @param {string} dimensionName dimensionName: string - name of dimension you want to retrieve the dimension data for
|
|
3409
|
+
* @returns {object} returnType: object - object of layer dimension
|
|
3410
3410
|
*/
|
|
3411
3411
|
const getLayerDimension = createSelector(getLayerDimensions, (_store, _layerId, dimensionName) => dimensionName, (dimensions, dimensionName) => dimensions === null || dimensions === void 0 ? void 0 : dimensions.find(dimension => dimension.name === dimensionName), selectorMemoizationOptions);
|
|
3412
|
-
/**
|
|
3413
|
-
* Gets opacity of the passed layer
|
|
3414
|
-
*
|
|
3415
|
-
* Example: layerOpacity = getLayerOpacity(store, 'layerId_1')
|
|
3416
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3417
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3418
|
-
* @returns {number} returnType: number - opacity as a number (between 0 and 1)
|
|
3412
|
+
/**
|
|
3413
|
+
* Gets opacity of the passed layer
|
|
3414
|
+
*
|
|
3415
|
+
* Example: layerOpacity = getLayerOpacity(store, 'layerId_1')
|
|
3416
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3417
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3418
|
+
* @returns {number} returnType: number - opacity as a number (between 0 and 1)
|
|
3419
3419
|
*/
|
|
3420
3420
|
const getLayerOpacity = createSelector(getLayerById, layer => layer && layer.opacity ? layer.opacity : 0, selectorMemoizationOptions);
|
|
3421
|
-
/**
|
|
3422
|
-
* Gets whether a layer is enabled or disabled
|
|
3423
|
-
*
|
|
3424
|
-
* Example: isLayerEnabled = getLayerEnabled(store, 'layerId_1')
|
|
3425
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3426
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3427
|
-
* @returns {boolean} returnType: boolean - true if enabled, false if disabled
|
|
3421
|
+
/**
|
|
3422
|
+
* Gets whether a layer is enabled or disabled
|
|
3423
|
+
*
|
|
3424
|
+
* Example: isLayerEnabled = getLayerEnabled(store, 'layerId_1')
|
|
3425
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3426
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3427
|
+
* @returns {boolean} returnType: boolean - true if enabled, false if disabled
|
|
3428
3428
|
*/
|
|
3429
3429
|
const getLayerEnabled = createSelector(getLayerById, layer => Boolean(layer === null || layer === void 0 ? void 0 : layer.enabled), selectorMemoizationOptions);
|
|
3430
|
-
/**
|
|
3431
|
-
* Gets layer name
|
|
3432
|
-
*
|
|
3433
|
-
* Example: layerName = getLayerName(store, 'layerId_1')
|
|
3434
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3435
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3436
|
-
* @returns {string} returnType: string - layer name
|
|
3430
|
+
/**
|
|
3431
|
+
* Gets layer name
|
|
3432
|
+
*
|
|
3433
|
+
* Example: layerName = getLayerName(store, 'layerId_1')
|
|
3434
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3435
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3436
|
+
* @returns {string} returnType: string - layer name
|
|
3437
3437
|
*/
|
|
3438
3438
|
const getLayerName = createSelector(getLayerById, layer => {
|
|
3439
3439
|
var _a;
|
|
3440
3440
|
return (_a = layer === null || layer === void 0 ? void 0 : layer.name) !== null && _a !== void 0 ? _a : '';
|
|
3441
3441
|
}, selectorMemoizationOptions);
|
|
3442
|
-
/**
|
|
3443
|
-
* Gets layer service
|
|
3444
|
-
*
|
|
3445
|
-
* Example: layerService = getLayerService(store, 'layerId_1')
|
|
3446
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3447
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3448
|
-
* @returns {string} returnType: string - layer service
|
|
3442
|
+
/**
|
|
3443
|
+
* Gets layer service
|
|
3444
|
+
*
|
|
3445
|
+
* Example: layerService = getLayerService(store, 'layerId_1')
|
|
3446
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3447
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3448
|
+
* @returns {string} returnType: string - layer service
|
|
3449
3449
|
*/
|
|
3450
3450
|
const getLayerService = createSelector(getLayerById, layer => {
|
|
3451
3451
|
var _a;
|
|
3452
3452
|
return (_a = layer === null || layer === void 0 ? void 0 : layer.service) !== null && _a !== void 0 ? _a : '';
|
|
3453
3453
|
}, selectorMemoizationOptions);
|
|
3454
|
-
/**
|
|
3455
|
-
* Gets selected style of the passed layer
|
|
3456
|
-
*
|
|
3457
|
-
* Example: layerStyle = getLayerStyle(store, 'layerId_1')
|
|
3458
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3459
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3460
|
-
* @returns {string} returnType: string - style that is currently selected
|
|
3454
|
+
/**
|
|
3455
|
+
* Gets selected style of the passed layer
|
|
3456
|
+
*
|
|
3457
|
+
* Example: layerStyle = getLayerStyle(store, 'layerId_1')
|
|
3458
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3459
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3460
|
+
* @returns {string} returnType: string - style that is currently selected
|
|
3461
3461
|
*/
|
|
3462
3462
|
const getLayerStyle = createSelector(getLayerById, layer => layer && layer.style ? layer.style : '', selectorMemoizationOptions);
|
|
3463
|
-
/**
|
|
3464
|
-
* Gets layer status
|
|
3465
|
-
*
|
|
3466
|
-
* Example: layerService = getLayerStatus(store, 'layerId_1')
|
|
3467
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3468
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
3469
|
-
* @returns {string} returnType: LayerStatus
|
|
3463
|
+
/**
|
|
3464
|
+
* Gets layer status
|
|
3465
|
+
*
|
|
3466
|
+
* Example: layerService = getLayerStatus(store, 'layerId_1')
|
|
3467
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3468
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
3469
|
+
* @returns {string} returnType: LayerStatus
|
|
3470
3470
|
*/
|
|
3471
3471
|
const getLayerStatus = createSelector(getLayerById, layer => layer && layer.status ? layer.status : LayerStatus.default, selectorMemoizationOptions);
|
|
3472
|
-
/**
|
|
3473
|
-
* Gets all available base layers for a map
|
|
3474
|
-
*
|
|
3475
|
-
* Example: availableBaseLayers = getAvailableBaseLayersForMap(store)
|
|
3476
|
-
* @param {object} store store: object - object from which the layer state will be extracted
|
|
3477
|
-
* @param {string} mapId mapId: string - Id of the map we want to retrieve the available baselayers for
|
|
3478
|
-
* @returns {array} returnType: array - array containing all available base layers
|
|
3472
|
+
/**
|
|
3473
|
+
* Gets all available base layers for a map
|
|
3474
|
+
*
|
|
3475
|
+
* Example: availableBaseLayers = getAvailableBaseLayersForMap(store)
|
|
3476
|
+
* @param {object} store store: object - object from which the layer state will be extracted
|
|
3477
|
+
* @param {string} mapId mapId: string - Id of the map we want to retrieve the available baselayers for
|
|
3478
|
+
* @returns {array} returnType: array - array containing all available base layers
|
|
3479
3479
|
*/
|
|
3480
3480
|
const getAvailableBaseLayersForMap = createSelector(layerStore, (_store, _mapId) => _mapId, (layerStore, mapId) => {
|
|
3481
3481
|
if (layerStore && layerStore.availableBaseLayers) {
|
|
@@ -3491,22 +3491,22 @@ const getAvailableBaseLayersForMap = createSelector(layerStore, (_store, _mapId)
|
|
|
3491
3491
|
}
|
|
3492
3492
|
return [];
|
|
3493
3493
|
}, selectorMemoizationOptions);
|
|
3494
|
-
/**
|
|
3495
|
-
* Returns the selected geojson feature for the given layer
|
|
3496
|
-
*
|
|
3497
|
-
* Example const selectedFeature = getSelectedFeature(store, 'layerId1')
|
|
3498
|
-
* @param {object} store store: object - store object
|
|
3499
|
-
* @param {string} mapId layerId: string - Id of the layer
|
|
3500
|
-
* @returns {number} selectedFeatureIndex: the index of the selected geojson feature
|
|
3494
|
+
/**
|
|
3495
|
+
* Returns the selected geojson feature for the given layer
|
|
3496
|
+
*
|
|
3497
|
+
* Example const selectedFeature = getSelectedFeature(store, 'layerId1')
|
|
3498
|
+
* @param {object} store store: object - store object
|
|
3499
|
+
* @param {string} mapId layerId: string - Id of the layer
|
|
3500
|
+
* @returns {number} selectedFeatureIndex: the index of the selected geojson feature
|
|
3501
3501
|
*/
|
|
3502
3502
|
const getSelectedFeatureIndex = createSelector(getLayerById, layer => layer === null || layer === void 0 ? void 0 : layer.selectedFeatureIndex, selectorMemoizationOptions);
|
|
3503
|
-
/**
|
|
3504
|
-
* Returns the layer is in edit mode
|
|
3505
|
-
*
|
|
3506
|
-
* Example const isLayerInEditMode = getIsLayerInEditMode(store, 'layerId1')
|
|
3507
|
-
* @param {object} store store: object - store object
|
|
3508
|
-
* @param {string} mapId layerId: string - Id of the layer
|
|
3509
|
-
* @returns {number} isLayerInEditMode: boolean - isInEditMode
|
|
3503
|
+
/**
|
|
3504
|
+
* Returns the layer is in edit mode
|
|
3505
|
+
*
|
|
3506
|
+
* Example const isLayerInEditMode = getIsLayerInEditMode(store, 'layerId1')
|
|
3507
|
+
* @param {object} store store: object - store object
|
|
3508
|
+
* @param {string} mapId layerId: string - Id of the layer
|
|
3509
|
+
* @returns {number} isLayerInEditMode: boolean - isInEditMode
|
|
3510
3510
|
*/
|
|
3511
3511
|
const getIsLayerInEditMode = createSelector(getLayerById, layer => (layer === null || layer === void 0 ? void 0 : layer.isInEditMode) || false, selectorMemoizationOptions);
|
|
3512
3512
|
const getFeatureLayerGeoJSON = createSelector(getLayerById, layer => (layer === null || layer === void 0 ? void 0 : layer.geojson) || undefined, selectorMemoizationOptions);
|
|
@@ -3515,13 +3515,13 @@ const getFeatureLayerGeoJSONProperties = createSelector(getLayerById, getSelecte
|
|
|
3515
3515
|
var _a, _b;
|
|
3516
3516
|
return ((_b = (_a = layer === null || layer === void 0 ? void 0 : layer.geojson) === null || _a === void 0 ? void 0 : _a.features[selecteFeatureIndex]) === null || _b === void 0 ? void 0 : _b.properties) || {};
|
|
3517
3517
|
}, selectorMemoizationOptions);
|
|
3518
|
-
/**
|
|
3519
|
-
* Gets layerIds that contain passed dimension
|
|
3520
|
-
*
|
|
3521
|
-
* Example: dimension = getDimensionLayerIds(store, 'elevation')
|
|
3522
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3523
|
-
* @param {string} dimensionName dimensionName: string - name of dimension you want to retrieve the dimension data for
|
|
3524
|
-
* @returns {string[]} returnType: string[] - layerIds
|
|
3518
|
+
/**
|
|
3519
|
+
* Gets layerIds that contain passed dimension
|
|
3520
|
+
*
|
|
3521
|
+
* Example: dimension = getDimensionLayerIds(store, 'elevation')
|
|
3522
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
3523
|
+
* @param {string} dimensionName dimensionName: string - name of dimension you want to retrieve the dimension data for
|
|
3524
|
+
* @returns {string[]} returnType: string[] - layerIds
|
|
3525
3525
|
*/
|
|
3526
3526
|
const getDimensionLayerIds = createSelector(getLayersIds, getLayersById, (_store, dimensionName) => dimensionName, (layerIds, layers, dimensionName) => {
|
|
3527
3527
|
return layerIds.reduce((list, layerId) => {
|
|
@@ -3558,8 +3558,8 @@ const getLayerIsInsideAcceptanceTime = createSelector(getAcceptanceTimeInMinutes
|
|
|
3558
3558
|
return 'inside';
|
|
3559
3559
|
}, selectorMemoizationOptions);
|
|
3560
3560
|
const getUseLatestReferenceTime = createSelector(getLayerById, layer => Boolean(layer === null || layer === void 0 ? void 0 : layer.useLatestReferenceTime), selectorMemoizationOptions);
|
|
3561
|
-
/**
|
|
3562
|
-
* Returns the timestep for this layerId in seconds, or undefined if it has no time dimension or timeinterval.
|
|
3561
|
+
/**
|
|
3562
|
+
* Returns the timestep for this layerId in seconds, or undefined if it has no time dimension or timeinterval.
|
|
3563
3563
|
*/
|
|
3564
3564
|
const getTimeStepForLayerId = createSelector(getLayerTimeDimension, timeDimension => {
|
|
3565
3565
|
if (!timeDimension) {
|
|
@@ -3629,22 +3629,22 @@ var selectors$7 = /*#__PURE__*/Object.freeze({
|
|
|
3629
3629
|
getUseLatestReferenceTime: getUseLatestReferenceTime
|
|
3630
3630
|
});
|
|
3631
3631
|
|
|
3632
|
-
/* *
|
|
3633
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3634
|
-
* you may not use this file except in compliance with the License.
|
|
3635
|
-
* You may obtain a copy of the License at
|
|
3636
|
-
*
|
|
3637
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3638
|
-
*
|
|
3639
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
3640
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3641
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3642
|
-
* See the License for the specific language governing permissions and
|
|
3643
|
-
* limitations under the License.
|
|
3644
|
-
*
|
|
3645
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3646
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
3647
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3632
|
+
/* *
|
|
3633
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
3634
|
+
* you may not use this file except in compliance with the License.
|
|
3635
|
+
* You may obtain a copy of the License at
|
|
3636
|
+
*
|
|
3637
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
3638
|
+
*
|
|
3639
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
3640
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
3641
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
3642
|
+
* See the License for the specific language governing permissions and
|
|
3643
|
+
* limitations under the License.
|
|
3644
|
+
*
|
|
3645
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
3646
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
3647
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
3648
3648
|
* */
|
|
3649
3649
|
var AnimationLength;
|
|
3650
3650
|
(function (AnimationLength) {
|
|
@@ -3915,11 +3915,11 @@ const {
|
|
|
3915
3915
|
} = slice$6;
|
|
3916
3916
|
const uiActions = slice$6.actions;
|
|
3917
3917
|
|
|
3918
|
-
/**
|
|
3919
|
-
* Checks if the layer id is already taken in one of the maps.
|
|
3920
|
-
* @param state The WebMapState
|
|
3921
|
-
* @param layerIdToCheck The layerId to check
|
|
3922
|
-
* @returns true if the layerId is already taken somewhere else.
|
|
3918
|
+
/**
|
|
3919
|
+
* Checks if the layer id is already taken in one of the maps.
|
|
3920
|
+
* @param state The WebMapState
|
|
3921
|
+
* @param layerIdToCheck The layerId to check
|
|
3922
|
+
* @returns true if the layerId is already taken somewhere else.
|
|
3923
3923
|
*/
|
|
3924
3924
|
const checkIfMapLayerIdIsAlreadyTaken = (state, layerId) => {
|
|
3925
3925
|
return state.allIds.some(mapId => {
|
|
@@ -3928,9 +3928,9 @@ const checkIfMapLayerIdIsAlreadyTaken = (state, layerId) => {
|
|
|
3928
3928
|
return doesLayeridExist(map.mapLayers) || doesLayeridExist(map.overLayers) || doesLayeridExist(map.baseLayers) || doesLayeridExist(map.featureLayers);
|
|
3929
3929
|
});
|
|
3930
3930
|
};
|
|
3931
|
-
/**
|
|
3932
|
-
* Addes id's to the layer object. All layers need to have an id for referring.
|
|
3933
|
-
* @param layers
|
|
3931
|
+
/**
|
|
3932
|
+
* Addes id's to the layer object. All layers need to have an id for referring.
|
|
3933
|
+
* @param layers
|
|
3934
3934
|
*/
|
|
3935
3935
|
const createLayersWithIds = (state, layers) => {
|
|
3936
3936
|
if (!layers) {
|
|
@@ -4541,11 +4541,11 @@ const slice$5 = createSlice({
|
|
|
4541
4541
|
}
|
|
4542
4542
|
});
|
|
4543
4543
|
}).addCase(setLayerActionSync, (draft, action) => {
|
|
4544
|
-
/*
|
|
4545
|
-
* This GENERIC_SYNC_SETLAYERACTIONS action is generated by the syncgroup listener.
|
|
4546
|
-
* It has multiple targets (Layers) in its payload.
|
|
4547
|
-
* These targets can be used as payloads in new Layer actions.
|
|
4548
|
-
* These actions are here handled via the layer reducer, as it is the same logic
|
|
4544
|
+
/*
|
|
4545
|
+
* This GENERIC_SYNC_SETLAYERACTIONS action is generated by the syncgroup listener.
|
|
4546
|
+
* It has multiple targets (Layers) in its payload.
|
|
4547
|
+
* These targets can be used as payloads in new Layer actions.
|
|
4548
|
+
* These actions are here handled via the layer reducer, as it is the same logic
|
|
4549
4549
|
*/
|
|
4550
4550
|
const {
|
|
4551
4551
|
targets,
|
|
@@ -4624,13 +4624,13 @@ const getUiStore = store => {
|
|
|
4624
4624
|
}
|
|
4625
4625
|
return null;
|
|
4626
4626
|
};
|
|
4627
|
-
/**
|
|
4628
|
-
* Gets the active map Id and wether a dialog is open or closed
|
|
4629
|
-
*
|
|
4630
|
-
* Example: getDialogDetailsByType(store, 'legend')
|
|
4631
|
-
* @param {object} store store object from which the ui state wll be extracted
|
|
4632
|
-
* @param {string} dialogType type of the dialog
|
|
4633
|
-
* @returns {array} [string, boolean] first element gives the active map id, second element whether the dialog is open
|
|
4627
|
+
/**
|
|
4628
|
+
* Gets the active map Id and wether a dialog is open or closed
|
|
4629
|
+
*
|
|
4630
|
+
* Example: getDialogDetailsByType(store, 'legend')
|
|
4631
|
+
* @param {object} store store object from which the ui state wll be extracted
|
|
4632
|
+
* @param {string} dialogType type of the dialog
|
|
4633
|
+
* @returns {array} [string, boolean] first element gives the active map id, second element whether the dialog is open
|
|
4634
4634
|
*/
|
|
4635
4635
|
const getDialogDetailsByType = (store, dialogType) => {
|
|
4636
4636
|
if (store && store.ui && store.ui.dialogs && store.ui.dialogs[dialogType]) {
|
|
@@ -4638,12 +4638,12 @@ const getDialogDetailsByType = (store, dialogType) => {
|
|
|
4638
4638
|
}
|
|
4639
4639
|
return null;
|
|
4640
4640
|
};
|
|
4641
|
-
/**
|
|
4642
|
-
* For a given ui component: gets wether the dialog is open or closed
|
|
4643
|
-
*
|
|
4644
|
-
* @param {object} store store object from which the ui state wll be extracted
|
|
4645
|
-
* @param {string} dialogType type of the dialog
|
|
4646
|
-
* @returns {boolean} returnType: boolean
|
|
4641
|
+
/**
|
|
4642
|
+
* For a given ui component: gets wether the dialog is open or closed
|
|
4643
|
+
*
|
|
4644
|
+
* @param {object} store store object from which the ui state wll be extracted
|
|
4645
|
+
* @param {string} dialogType type of the dialog
|
|
4646
|
+
* @returns {boolean} returnType: boolean
|
|
4647
4647
|
*/
|
|
4648
4648
|
const getisDialogOpen = createSelector(getDialogDetailsByType, details => {
|
|
4649
4649
|
if (details) {
|
|
@@ -4651,12 +4651,12 @@ const getisDialogOpen = createSelector(getDialogDetailsByType, details => {
|
|
|
4651
4651
|
}
|
|
4652
4652
|
return false;
|
|
4653
4653
|
}, selectorMemoizationOptions);
|
|
4654
|
-
/**
|
|
4655
|
-
*For a given ui component: gets the active map Id
|
|
4656
|
-
*
|
|
4657
|
-
* @param {object} store store object from which the ui state wll be extracted
|
|
4658
|
-
* @param {string} dialogType type of the dialog
|
|
4659
|
-
* @returns {string} returnType: string - the active map id
|
|
4654
|
+
/**
|
|
4655
|
+
*For a given ui component: gets the active map Id
|
|
4656
|
+
*
|
|
4657
|
+
* @param {object} store store object from which the ui state wll be extracted
|
|
4658
|
+
* @param {string} dialogType type of the dialog
|
|
4659
|
+
* @returns {string} returnType: string - the active map id
|
|
4660
4660
|
*/
|
|
4661
4661
|
const getDialogMapId = createSelector(getDialogDetailsByType, details => {
|
|
4662
4662
|
if (details) {
|
|
@@ -4664,12 +4664,12 @@ const getDialogMapId = createSelector(getDialogDetailsByType, details => {
|
|
|
4664
4664
|
}
|
|
4665
4665
|
return '';
|
|
4666
4666
|
}, selectorMemoizationOptions);
|
|
4667
|
-
/**
|
|
4668
|
-
*For a given ui component: gets the order of visible dialog
|
|
4669
|
-
*
|
|
4670
|
-
* @param {object} store store object from which the ui state wll be extracted
|
|
4671
|
-
* @param {DialogType} dialogType type of the dialog
|
|
4672
|
-
* @returns {number} the higher the order number the higher the zIndex
|
|
4667
|
+
/**
|
|
4668
|
+
*For a given ui component: gets the order of visible dialog
|
|
4669
|
+
*
|
|
4670
|
+
* @param {object} store store object from which the ui state wll be extracted
|
|
4671
|
+
* @param {DialogType} dialogType type of the dialog
|
|
4672
|
+
* @returns {number} the higher the order number the higher the zIndex
|
|
4673
4673
|
*/
|
|
4674
4674
|
const getDialogOrder = createSelector((store, dialogType) => {
|
|
4675
4675
|
if (store && store.ui && store.ui.order) {
|
|
@@ -4687,12 +4687,12 @@ const getDialogOrder = createSelector((store, dialogType) => {
|
|
|
4687
4687
|
}
|
|
4688
4688
|
return 0;
|
|
4689
4689
|
}, order => order, selectorMemoizationOptions);
|
|
4690
|
-
/**
|
|
4691
|
-
*For a given ui component: returns if ordered on top
|
|
4692
|
-
*
|
|
4693
|
-
* @param {object} store store object from which the ui state wll be extracted
|
|
4694
|
-
* @param {DialogType} dialogType type of the dialog
|
|
4695
|
-
* @returns {boolean}
|
|
4690
|
+
/**
|
|
4691
|
+
*For a given ui component: returns if ordered on top
|
|
4692
|
+
*
|
|
4693
|
+
* @param {object} store store object from which the ui state wll be extracted
|
|
4694
|
+
* @param {DialogType} dialogType type of the dialog
|
|
4695
|
+
* @returns {boolean}
|
|
4696
4696
|
*/
|
|
4697
4697
|
const getDialogIsOrderedOnTop = createSelector((store, dialogType) => {
|
|
4698
4698
|
if (store && store.ui && store.ui.order) {
|
|
@@ -4709,22 +4709,22 @@ const getDialogSource = createSelector(getDialogDetailsByType, details => {
|
|
|
4709
4709
|
}
|
|
4710
4710
|
return 'app';
|
|
4711
4711
|
}, selectorMemoizationOptions);
|
|
4712
|
-
/**
|
|
4713
|
-
* Get the active window that should receive keyboard shortcuts
|
|
4714
|
-
*
|
|
4715
|
-
* Example: getActiveWindowId(store)
|
|
4716
|
-
* @param {object} store store object from which the window state will be extracted
|
|
4717
|
-
* @returns {string} active window id
|
|
4712
|
+
/**
|
|
4713
|
+
* Get the active window that should receive keyboard shortcuts
|
|
4714
|
+
*
|
|
4715
|
+
* Example: getActiveWindowId(store)
|
|
4716
|
+
* @param {object} store store object from which the window state will be extracted
|
|
4717
|
+
* @returns {string} active window id
|
|
4718
4718
|
*/
|
|
4719
4719
|
const getActiveWindowId = createSelector(getUiStore, store => {
|
|
4720
4720
|
return store === null || store === void 0 ? void 0 : store.activeWindowId;
|
|
4721
4721
|
}, selectorMemoizationOptions);
|
|
4722
|
-
/**
|
|
4723
|
-
* Gets if this is the active window
|
|
4724
|
-
*
|
|
4725
|
-
* Example: getIsActiveWindowId(store, viewId)
|
|
4726
|
-
* @param {object} store store object from which the window state will be extracted
|
|
4727
|
-
* @returns {string} active window id
|
|
4722
|
+
/**
|
|
4723
|
+
* Gets if this is the active window
|
|
4724
|
+
*
|
|
4725
|
+
* Example: getIsActiveWindowId(store, viewId)
|
|
4726
|
+
* @param {object} store store object from which the window state will be extracted
|
|
4727
|
+
* @returns {string} active window id
|
|
4728
4728
|
*/
|
|
4729
4729
|
const getIsActiveWindowId = createSelector(getUiStore, (_store, viewId) => viewId, (store, viewId) => {
|
|
4730
4730
|
return viewId === (store === null || store === void 0 ? void 0 : store.activeWindowId);
|
|
@@ -4771,22 +4771,22 @@ var selectors$6 = /*#__PURE__*/Object.freeze({
|
|
|
4771
4771
|
useAppSelector: useAppSelector
|
|
4772
4772
|
});
|
|
4773
4773
|
|
|
4774
|
-
/* *
|
|
4775
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4776
|
-
* you may not use this file except in compliance with the License.
|
|
4777
|
-
* You may obtain a copy of the License at
|
|
4778
|
-
*
|
|
4779
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4780
|
-
*
|
|
4781
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
4782
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4783
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4784
|
-
* See the License for the specific language governing permissions and
|
|
4785
|
-
* limitations under the License.
|
|
4786
|
-
*
|
|
4787
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4788
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
4789
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4774
|
+
/* *
|
|
4775
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4776
|
+
* you may not use this file except in compliance with the License.
|
|
4777
|
+
* You may obtain a copy of the License at
|
|
4778
|
+
*
|
|
4779
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4780
|
+
*
|
|
4781
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
4782
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4783
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4784
|
+
* See the License for the specific language governing permissions and
|
|
4785
|
+
* limitations under the License.
|
|
4786
|
+
*
|
|
4787
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4788
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
4789
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4790
4790
|
* */
|
|
4791
4791
|
var DialogTypes;
|
|
4792
4792
|
(function (DialogTypes) {
|
|
@@ -4813,22 +4813,22 @@ var types$3 = /*#__PURE__*/Object.freeze({
|
|
|
4813
4813
|
get DialogTypes () { return DialogTypes; }
|
|
4814
4814
|
});
|
|
4815
4815
|
|
|
4816
|
-
/* *
|
|
4817
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4818
|
-
* you may not use this file except in compliance with the License.
|
|
4819
|
-
* You may obtain a copy of the License at
|
|
4820
|
-
*
|
|
4821
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4822
|
-
*
|
|
4823
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
4824
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4825
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4826
|
-
* See the License for the specific language governing permissions and
|
|
4827
|
-
* limitations under the License.
|
|
4828
|
-
*
|
|
4829
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4830
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
4831
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4816
|
+
/* *
|
|
4817
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4818
|
+
* you may not use this file except in compliance with the License.
|
|
4819
|
+
* You may obtain a copy of the License at
|
|
4820
|
+
*
|
|
4821
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4822
|
+
*
|
|
4823
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
4824
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4825
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4826
|
+
* See the License for the specific language governing permissions and
|
|
4827
|
+
* limitations under the License.
|
|
4828
|
+
*
|
|
4829
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4830
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
4831
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4832
4832
|
* */
|
|
4833
4833
|
const useSetupDialog = (dialogType, source = 'app') => {
|
|
4834
4834
|
const dispatch = useDispatch();
|
|
@@ -4882,22 +4882,22 @@ const useSetupDialog = (dialogType, source = 'app') => {
|
|
|
4882
4882
|
};
|
|
4883
4883
|
};
|
|
4884
4884
|
|
|
4885
|
-
/* *
|
|
4886
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4887
|
-
* you may not use this file except in compliance with the License.
|
|
4888
|
-
* You may obtain a copy of the License at
|
|
4889
|
-
*
|
|
4890
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4891
|
-
*
|
|
4892
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
4893
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4894
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4895
|
-
* See the License for the specific language governing permissions and
|
|
4896
|
-
* limitations under the License.
|
|
4897
|
-
*
|
|
4898
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4899
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
4900
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4885
|
+
/* *
|
|
4886
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4887
|
+
* you may not use this file except in compliance with the License.
|
|
4888
|
+
* You may obtain a copy of the License at
|
|
4889
|
+
*
|
|
4890
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4891
|
+
*
|
|
4892
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
4893
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4894
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4895
|
+
* See the License for the specific language governing permissions and
|
|
4896
|
+
* limitations under the License.
|
|
4897
|
+
*
|
|
4898
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4899
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
4900
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4901
4901
|
* */
|
|
4902
4902
|
/* Type constants */
|
|
4903
4903
|
const SYNCGROUPS_TYPE_SETTIME = 'SYNCGROUPS_TYPE_SETTIME';
|
|
@@ -4913,30 +4913,30 @@ var constants$1 = /*#__PURE__*/Object.freeze({
|
|
|
4913
4913
|
SYNCGROUPS_TYPE_SETTIME: SYNCGROUPS_TYPE_SETTIME
|
|
4914
4914
|
});
|
|
4915
4915
|
|
|
4916
|
-
/* *
|
|
4917
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4918
|
-
* you may not use this file except in compliance with the License.
|
|
4919
|
-
* You may obtain a copy of the License at
|
|
4920
|
-
*
|
|
4921
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4922
|
-
*
|
|
4923
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
4924
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4925
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4926
|
-
* See the License for the specific language governing permissions and
|
|
4927
|
-
* limitations under the License.
|
|
4928
|
-
*
|
|
4929
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4930
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
4931
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4916
|
+
/* *
|
|
4917
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
4918
|
+
* you may not use this file except in compliance with the License.
|
|
4919
|
+
* You may obtain a copy of the License at
|
|
4920
|
+
*
|
|
4921
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
4922
|
+
*
|
|
4923
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
4924
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
4925
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
4926
|
+
* See the License for the specific language governing permissions and
|
|
4927
|
+
* limitations under the License.
|
|
4928
|
+
*
|
|
4929
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
4930
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
4931
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
4932
4932
|
* */
|
|
4933
|
-
/**
|
|
4934
|
-
* The removeInPlace() method modifies an array in place, by removing elements that pass the test implemented by the provided function.
|
|
4935
|
-
*
|
|
4936
|
-
* NOTE: This should only be used on draft properties as provided by the immer produce library, as modifying elements in place is bad practice on non draft variables.
|
|
4937
|
-
*
|
|
4938
|
-
* @param inDraftArray The draft array to filter, will be modified in place.
|
|
4939
|
-
* @param condition Function to check each element in the array
|
|
4933
|
+
/**
|
|
4934
|
+
* The removeInPlace() method modifies an array in place, by removing elements that pass the test implemented by the provided function.
|
|
4935
|
+
*
|
|
4936
|
+
* NOTE: This should only be used on draft properties as provided by the immer produce library, as modifying elements in place is bad practice on non draft variables.
|
|
4937
|
+
*
|
|
4938
|
+
* @param inDraftArray The draft array to filter, will be modified in place.
|
|
4939
|
+
* @param condition Function to check each element in the array
|
|
4940
4940
|
*/
|
|
4941
4941
|
const removeInPlace = (inDraftArray, condition) => {
|
|
4942
4942
|
let j = 0;
|
|
@@ -5179,22 +5179,22 @@ const {
|
|
|
5179
5179
|
reducer: reducer$3
|
|
5180
5180
|
} = slice$4;
|
|
5181
5181
|
|
|
5182
|
-
/* *
|
|
5183
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5184
|
-
* you may not use this file except in compliance with the License.
|
|
5185
|
-
* You may obtain a copy of the License at
|
|
5186
|
-
*
|
|
5187
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5188
|
-
*
|
|
5189
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
5190
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5191
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5192
|
-
* See the License for the specific language governing permissions and
|
|
5193
|
-
* limitations under the License.
|
|
5194
|
-
*
|
|
5195
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5196
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5197
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5182
|
+
/* *
|
|
5183
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5184
|
+
* you may not use this file except in compliance with the License.
|
|
5185
|
+
* You may obtain a copy of the License at
|
|
5186
|
+
*
|
|
5187
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5188
|
+
*
|
|
5189
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
5190
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5191
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5192
|
+
* See the License for the specific language governing permissions and
|
|
5193
|
+
* limitations under the License.
|
|
5194
|
+
*
|
|
5195
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5196
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5197
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5198
5198
|
* */
|
|
5199
5199
|
const SyncGroupTypeList = [SYNCGROUPS_TYPE_SETBBOX, SYNCGROUPS_TYPE_SETTIME];
|
|
5200
5200
|
var SyncGroupActionOrigin;
|
|
@@ -5213,12 +5213,12 @@ var types$2 = /*#__PURE__*/Object.freeze({
|
|
|
5213
5213
|
});
|
|
5214
5214
|
|
|
5215
5215
|
const syncGroupStore = store => store.syncronizationGroupStore || null;
|
|
5216
|
-
/**
|
|
5217
|
-
* Gets synchronization group state
|
|
5218
|
-
*
|
|
5219
|
-
* Example: synchronizationGroupState = getSynchronizationGroupState(store)
|
|
5220
|
-
* @param {object} store store: object - Store object
|
|
5221
|
-
* @returns {object} returnType: SynchronizationGroupState
|
|
5216
|
+
/**
|
|
5217
|
+
* Gets synchronization group state
|
|
5218
|
+
*
|
|
5219
|
+
* Example: synchronizationGroupState = getSynchronizationGroupState(store)
|
|
5220
|
+
* @param {object} store store: object - Store object
|
|
5221
|
+
* @returns {object} returnType: SynchronizationGroupState
|
|
5222
5222
|
*/
|
|
5223
5223
|
const getSynchronizationGroupState = createSelector(syncGroupStore, store => store || null, selectorMemoizationOptions);
|
|
5224
5224
|
const getSynchronizationGroup = createSelector([syncGroupStore, (syncGroupStore, id) => id], (syncGroupState, id) => {
|
|
@@ -5360,18 +5360,18 @@ const groupTypes = [{
|
|
|
5360
5360
|
syncType: 'SYNCGROUPS_TYPE_SETBBOX',
|
|
5361
5361
|
groupType: 'zoompane'
|
|
5362
5362
|
}];
|
|
5363
|
-
/*
|
|
5364
|
-
_____ Creates viewState _____
|
|
5365
|
-
- Runs Each time viewState is created:
|
|
5366
|
-
- Fill arrays inside initialState with objects containing new values from Redux
|
|
5363
|
+
/*
|
|
5364
|
+
_____ Creates viewState _____
|
|
5365
|
+
- Runs Each time viewState is created:
|
|
5366
|
+
- Fill arrays inside initialState with objects containing new values from Redux
|
|
5367
5367
|
*/
|
|
5368
5368
|
const createSyncGroupViewState = (groups, sources) => {
|
|
5369
5369
|
const initialState = produce(emptyState, draft => {
|
|
5370
|
-
/*
|
|
5371
|
-
_____ 1. Fill groups _____
|
|
5372
|
-
1. Goes through all groups by ID
|
|
5373
|
-
2. Collects original timeslider or zoompane values into an array
|
|
5374
|
-
3. Sorts and adds selected sources to ViewState based on ID type
|
|
5370
|
+
/*
|
|
5371
|
+
_____ 1. Fill groups _____
|
|
5372
|
+
1. Goes through all groups by ID
|
|
5373
|
+
2. Collects original timeslider or zoompane values into an array
|
|
5374
|
+
3. Sorts and adds selected sources to ViewState based on ID type
|
|
5375
5375
|
*/
|
|
5376
5376
|
Object.keys(groups.byId).forEach(id => {
|
|
5377
5377
|
var _a;
|
|
@@ -5383,9 +5383,9 @@ const createSyncGroupViewState = (groups, sources) => {
|
|
|
5383
5383
|
});
|
|
5384
5384
|
}
|
|
5385
5385
|
});
|
|
5386
|
-
/*
|
|
5387
|
-
_____ 2. Fill sourcesById _____
|
|
5388
|
-
1. Loop though sources and add source to each group type
|
|
5386
|
+
/*
|
|
5387
|
+
_____ 2. Fill sourcesById _____
|
|
5388
|
+
1. Loop though sources and add source to each group type
|
|
5389
5389
|
*/
|
|
5390
5390
|
Object.keys(sources.byId).forEach(id => {
|
|
5391
5391
|
groupTypes.forEach(({
|
|
@@ -5414,29 +5414,29 @@ var selector = /*#__PURE__*/Object.freeze({
|
|
|
5414
5414
|
groupTypes: groupTypes
|
|
5415
5415
|
});
|
|
5416
5416
|
|
|
5417
|
-
/* *
|
|
5418
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5419
|
-
* you may not use this file except in compliance with the License.
|
|
5420
|
-
* You may obtain a copy of the License at
|
|
5421
|
-
*
|
|
5422
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5423
|
-
*
|
|
5424
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
5425
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5426
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5427
|
-
* See the License for the specific language governing permissions and
|
|
5428
|
-
* limitations under the License.
|
|
5429
|
-
*
|
|
5430
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5431
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5432
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5417
|
+
/* *
|
|
5418
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5419
|
+
* you may not use this file except in compliance with the License.
|
|
5420
|
+
* You may obtain a copy of the License at
|
|
5421
|
+
*
|
|
5422
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5423
|
+
*
|
|
5424
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
5425
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5426
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5427
|
+
* See the License for the specific language governing permissions and
|
|
5428
|
+
* limitations under the License.
|
|
5429
|
+
*
|
|
5430
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5431
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5432
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5433
5433
|
* */
|
|
5434
5434
|
const synchronizationGroupStore = store => store && store.syncronizationGroupStore ? store.syncronizationGroupStore : null;
|
|
5435
5435
|
const getSynchronizationGroupStore = createSelector(synchronizationGroupStore, store => store, selectorMemoizationOptions);
|
|
5436
|
-
/**
|
|
5437
|
-
* Returns the synchronization source by id
|
|
5438
|
-
* @param store The app store
|
|
5439
|
-
* @param id The source id to find
|
|
5436
|
+
/**
|
|
5437
|
+
* Returns the synchronization source by id
|
|
5438
|
+
* @param store The app store
|
|
5439
|
+
* @param id The source id to find
|
|
5440
5440
|
*/
|
|
5441
5441
|
const getSyncSourceBySourceId = (state, id) => {
|
|
5442
5442
|
if (state && state.sources) {
|
|
@@ -5457,44 +5457,44 @@ var selectors$4 = /*#__PURE__*/Object.freeze({
|
|
|
5457
5457
|
getTime: getTime
|
|
5458
5458
|
});
|
|
5459
5459
|
|
|
5460
|
-
/* *
|
|
5461
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5462
|
-
* you may not use this file except in compliance with the License.
|
|
5463
|
-
* You may obtain a copy of the License at
|
|
5464
|
-
*
|
|
5465
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5466
|
-
*
|
|
5467
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
5468
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5469
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5470
|
-
* See the License for the specific language governing permissions and
|
|
5471
|
-
* limitations under the License.
|
|
5472
|
-
*
|
|
5473
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5474
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5475
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5460
|
+
/* *
|
|
5461
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5462
|
+
* you may not use this file except in compliance with the License.
|
|
5463
|
+
* You may obtain a copy of the License at
|
|
5464
|
+
*
|
|
5465
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5466
|
+
*
|
|
5467
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
5468
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5469
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5470
|
+
* See the License for the specific language governing permissions and
|
|
5471
|
+
* limitations under the License.
|
|
5472
|
+
*
|
|
5473
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5474
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
5475
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5476
5476
|
* */
|
|
5477
5477
|
|
|
5478
5478
|
var types$1 = /*#__PURE__*/Object.freeze({
|
|
5479
5479
|
__proto__: null
|
|
5480
5480
|
});
|
|
5481
5481
|
|
|
5482
|
-
/* *
|
|
5483
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5484
|
-
* you may not use this file except in compliance with the License.
|
|
5485
|
-
* You may obtain a copy of the License at
|
|
5486
|
-
*
|
|
5487
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5488
|
-
*
|
|
5489
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
5490
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5491
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5492
|
-
* See the License for the specific language governing permissions and
|
|
5493
|
-
* limitations under the License.
|
|
5494
|
-
*
|
|
5495
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5496
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
5497
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5482
|
+
/* *
|
|
5483
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5484
|
+
* you may not use this file except in compliance with the License.
|
|
5485
|
+
* You may obtain a copy of the License at
|
|
5486
|
+
*
|
|
5487
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5488
|
+
*
|
|
5489
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
5490
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5491
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5492
|
+
* See the License for the specific language governing permissions and
|
|
5493
|
+
* limitations under the License.
|
|
5494
|
+
*
|
|
5495
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5496
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
5497
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5498
5498
|
* */
|
|
5499
5499
|
const ANY_EDR_SERVICE = 'any_edr';
|
|
5500
5500
|
|
|
@@ -5503,22 +5503,22 @@ var constants = /*#__PURE__*/Object.freeze({
|
|
|
5503
5503
|
ANY_EDR_SERVICE: ANY_EDR_SERVICE
|
|
5504
5504
|
});
|
|
5505
5505
|
|
|
5506
|
-
/* *
|
|
5507
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5508
|
-
* you may not use this file except in compliance with the License.
|
|
5509
|
-
* You may obtain a copy of the License at
|
|
5510
|
-
*
|
|
5511
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5512
|
-
*
|
|
5513
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
5514
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5515
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5516
|
-
* See the License for the specific language governing permissions and
|
|
5517
|
-
* limitations under the License.
|
|
5518
|
-
*
|
|
5519
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5520
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
5521
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5506
|
+
/* *
|
|
5507
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5508
|
+
* you may not use this file except in compliance with the License.
|
|
5509
|
+
* You may obtain a copy of the License at
|
|
5510
|
+
*
|
|
5511
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5512
|
+
*
|
|
5513
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
5514
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5515
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5516
|
+
* See the License for the specific language governing permissions and
|
|
5517
|
+
* limitations under the License.
|
|
5518
|
+
*
|
|
5519
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5520
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
5521
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5522
5522
|
* */
|
|
5523
5523
|
const loadingIndicatorAdapter = createEntityAdapter();
|
|
5524
5524
|
const initLoadingIndicatorStateForId = (draft, id) => {
|
|
@@ -5574,22 +5574,22 @@ const {
|
|
|
5574
5574
|
reducer: loadingIndicatorReducer
|
|
5575
5575
|
} = slice$3;
|
|
5576
5576
|
|
|
5577
|
-
/* *
|
|
5578
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5579
|
-
* you may not use this file except in compliance with the License.
|
|
5580
|
-
* You may obtain a copy of the License at
|
|
5581
|
-
*
|
|
5582
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5583
|
-
*
|
|
5584
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
5585
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5586
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5587
|
-
* See the License for the specific language governing permissions and
|
|
5588
|
-
* limitations under the License.
|
|
5589
|
-
*
|
|
5590
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5591
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
5592
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5577
|
+
/* *
|
|
5578
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5579
|
+
* you may not use this file except in compliance with the License.
|
|
5580
|
+
* You may obtain a copy of the License at
|
|
5581
|
+
*
|
|
5582
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
5583
|
+
*
|
|
5584
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
5585
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
5586
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
5587
|
+
* See the License for the specific language governing permissions and
|
|
5588
|
+
* limitations under the License.
|
|
5589
|
+
*
|
|
5590
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
5591
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
5592
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
5593
5593
|
* */
|
|
5594
5594
|
const {
|
|
5595
5595
|
selectById: selectLoadingIndicatorById
|
|
@@ -5630,13 +5630,13 @@ const genericActions = Object.assign(Object.assign({}, actions), {
|
|
|
5630
5630
|
});
|
|
5631
5631
|
|
|
5632
5632
|
const getMapStore = store => store && store.webmap;
|
|
5633
|
-
/**
|
|
5634
|
-
* Gets the map state by mapId
|
|
5635
|
-
*
|
|
5636
|
-
* Example: getMapById(store, 'mapid_1')
|
|
5637
|
-
* @param {object} store store object from which the map state wll be extracted
|
|
5638
|
-
* @param {string} mapId Id of the map
|
|
5639
|
-
* @returns {object} object containing map state (isAnimating, bbox, baseLayers, layers etc.)
|
|
5633
|
+
/**
|
|
5634
|
+
* Gets the map state by mapId
|
|
5635
|
+
*
|
|
5636
|
+
* Example: getMapById(store, 'mapid_1')
|
|
5637
|
+
* @param {object} store store object from which the map state wll be extracted
|
|
5638
|
+
* @param {string} mapId Id of the map
|
|
5639
|
+
* @returns {object} object containing map state (isAnimating, bbox, baseLayers, layers etc.)
|
|
5640
5640
|
*/
|
|
5641
5641
|
const getMapById = createSelector([getMapStore, (getMapStore, mapId) => mapId], (mapState, mapId) => {
|
|
5642
5642
|
return mapState && mapState.byId[mapId] ? mapState && mapState.byId[mapId] : undefined;
|
|
@@ -5644,72 +5644,72 @@ const getMapById = createSelector([getMapStore, (getMapStore, mapId) => mapId],
|
|
|
5644
5644
|
const getAllMapsByIds = createSelector(getMapStore, mapState => {
|
|
5645
5645
|
return mapState && mapState.byId ? mapState && mapState.byId : {};
|
|
5646
5646
|
}, selectorMemoizationOptions);
|
|
5647
|
-
/**
|
|
5648
|
-
* Gets all mapIds
|
|
5649
|
-
*
|
|
5650
|
-
* Example: getAllMapIds(store)
|
|
5651
|
-
* @param {object} store store object from which the map state wll be extracted
|
|
5652
|
-
* @returns {array} array containing all map ids
|
|
5647
|
+
/**
|
|
5648
|
+
* Gets all mapIds
|
|
5649
|
+
*
|
|
5650
|
+
* Example: getAllMapIds(store)
|
|
5651
|
+
* @param {object} store store object from which the map state wll be extracted
|
|
5652
|
+
* @returns {array} array containing all map ids
|
|
5653
5653
|
*/
|
|
5654
5654
|
const getAllMapIds = createSelector(getMapStore, mapState => mapState && mapState.allIds ? mapState.allIds : [], selectorMemoizationOptions);
|
|
5655
|
-
/**
|
|
5656
|
-
* Gets the map state of the first map in the store
|
|
5657
|
-
*
|
|
5658
|
-
* Example: getFirstMap(store)
|
|
5659
|
-
* @param {object} store store object from which the map state wll be extracted
|
|
5660
|
-
* @returns {object} object containing map state (isAnimating, bbox, baseLayers, layers etc.)
|
|
5655
|
+
/**
|
|
5656
|
+
* Gets the map state of the first map in the store
|
|
5657
|
+
*
|
|
5658
|
+
* Example: getFirstMap(store)
|
|
5659
|
+
* @param {object} store store object from which the map state wll be extracted
|
|
5660
|
+
* @returns {object} object containing map state (isAnimating, bbox, baseLayers, layers etc.)
|
|
5661
5661
|
*/
|
|
5662
5662
|
const getFirstMap = createSelector(getAllMapIds, getAllMapsByIds, (allMapIds, mapsById) => allMapIds[0] && mapsById[allMapIds[0]] ? mapsById[allMapIds[0]] : null, selectorMemoizationOptions);
|
|
5663
|
-
/**
|
|
5664
|
-
* Gets the id of first map in store
|
|
5665
|
-
*
|
|
5666
|
-
* Example: getFirstMapId(store)
|
|
5667
|
-
* @param {object} store store: object from which the map state wll be extracted
|
|
5668
|
-
* @returns {string} returnType:string - map id
|
|
5663
|
+
/**
|
|
5664
|
+
* Gets the id of first map in store
|
|
5665
|
+
*
|
|
5666
|
+
* Example: getFirstMapId(store)
|
|
5667
|
+
* @param {object} store store: object from which the map state wll be extracted
|
|
5668
|
+
* @returns {string} returnType:string - map id
|
|
5669
5669
|
*/
|
|
5670
5670
|
const getFirstMapId = createSelector(getFirstMap, map => map ? map.id : '', selectorMemoizationOptions);
|
|
5671
|
-
/**
|
|
5672
|
-
* Determines if map is present
|
|
5673
|
-
*
|
|
5674
|
-
* @param {object} store store: object - store object
|
|
5675
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5676
|
-
* @returns {boolean} returnType:boolean - true if map is present
|
|
5671
|
+
/**
|
|
5672
|
+
* Determines if map is present
|
|
5673
|
+
*
|
|
5674
|
+
* @param {object} store store: object - store object
|
|
5675
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5676
|
+
* @returns {boolean} returnType:boolean - true if map is present
|
|
5677
5677
|
*/
|
|
5678
5678
|
const getIsMapPresent = createSelector(getMapById, map => !!map, selectorMemoizationOptions);
|
|
5679
|
-
/**
|
|
5680
|
-
* Gets all layerIds for a map that aren't baselayers or overlayers
|
|
5681
|
-
*
|
|
5682
|
-
* Example: layerIds = getLayerIds(store, 'mapid_1')
|
|
5683
|
-
* @param {object} store store: object - store object
|
|
5684
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5685
|
-
* @returns {array} returnType: array - array containing all layerIds
|
|
5679
|
+
/**
|
|
5680
|
+
* Gets all layerIds for a map that aren't baselayers or overlayers
|
|
5681
|
+
*
|
|
5682
|
+
* Example: layerIds = getLayerIds(store, 'mapid_1')
|
|
5683
|
+
* @param {object} store store: object - store object
|
|
5684
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5685
|
+
* @returns {array} returnType: array - array containing all layerIds
|
|
5686
5686
|
*/
|
|
5687
5687
|
const getLayerIds = createSelector(getMapById, map => {
|
|
5688
5688
|
var _a;
|
|
5689
5689
|
return (_a = map === null || map === void 0 ? void 0 : map.mapLayers) !== null && _a !== void 0 ? _a : [];
|
|
5690
5690
|
}, selectorMemoizationOptions);
|
|
5691
|
-
/**
|
|
5692
|
-
* Gets all layer states for a map
|
|
5693
|
-
*
|
|
5694
|
-
* Example: layers = getMapLayers(store, 'mapid_1')
|
|
5695
|
-
* @param {object} store store: object - store object
|
|
5696
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5697
|
-
* @returns {array} returnType: array - array containing all layer states for the map
|
|
5691
|
+
/**
|
|
5692
|
+
* Gets all layer states for a map
|
|
5693
|
+
*
|
|
5694
|
+
* Example: layers = getMapLayers(store, 'mapid_1')
|
|
5695
|
+
* @param {object} store store: object - store object
|
|
5696
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5697
|
+
* @returns {array} returnType: array - array containing all layer states for the map
|
|
5698
5698
|
*/
|
|
5699
5699
|
const getMapLayers = createSelector(getLayerIds, getLayersById, (layerIdsInMap, allLayers) => {
|
|
5700
5700
|
const layersWithUndefined = layerIdsInMap.map(layerId => allLayers === null || allLayers === void 0 ? void 0 : allLayers[layerId]);
|
|
5701
5701
|
const layersWithoutUndefined = compact(layersWithUndefined);
|
|
5702
5702
|
return layersWithoutUndefined;
|
|
5703
5703
|
}, selectorMemoizationOptions);
|
|
5704
|
-
/**
|
|
5705
|
-
* Gets all layer states for a map, but where Dimensions have no currentValue set
|
|
5706
|
-
*
|
|
5707
|
-
* Use this instead of getMapLayers to prevent unnecessary re-renders
|
|
5708
|
-
*
|
|
5709
|
-
* Example: layers = getMapLayers(store, 'mapid_1')
|
|
5710
|
-
* @param {object} store store: object - store object
|
|
5711
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5712
|
-
* @returns {array} returnType: array - array containing all layer states for the map
|
|
5704
|
+
/**
|
|
5705
|
+
* Gets all layer states for a map, but where Dimensions have no currentValue set
|
|
5706
|
+
*
|
|
5707
|
+
* Use this instead of getMapLayers to prevent unnecessary re-renders
|
|
5708
|
+
*
|
|
5709
|
+
* Example: layers = getMapLayers(store, 'mapid_1')
|
|
5710
|
+
* @param {object} store store: object - store object
|
|
5711
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5712
|
+
* @returns {array} returnType: array - array containing all layer states for the map
|
|
5713
5713
|
*/
|
|
5714
5714
|
const getMapLayersWithoutDimensionCurrentValue = createSelector(getLayerIds, getLayersById, (layerIdsInMap, allLayers) => {
|
|
5715
5715
|
const layersWithUndefined = layerIdsInMap.map(layerId => allLayers === null || allLayers === void 0 ? void 0 : allLayers[layerId]);
|
|
@@ -5720,63 +5720,63 @@ const getMapLayersWithoutDimensionCurrentValue = createSelector(getLayerIds, get
|
|
|
5720
5720
|
}));
|
|
5721
5721
|
return layersWithoutTimeDim;
|
|
5722
5722
|
}, selectorMemoizationOptions);
|
|
5723
|
-
/**
|
|
5724
|
-
* Gets an array of baselayers ids for a map
|
|
5725
|
-
*
|
|
5726
|
-
* Example: baseLayersId = getMapBaseLayersIds(store, 'mapid_1')
|
|
5727
|
-
* @param {object} store store: object - store object
|
|
5728
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5729
|
-
* @returns {array} returnType: array - array containing an array of baselayers ids
|
|
5723
|
+
/**
|
|
5724
|
+
* Gets an array of baselayers ids for a map
|
|
5725
|
+
*
|
|
5726
|
+
* Example: baseLayersId = getMapBaseLayersIds(store, 'mapid_1')
|
|
5727
|
+
* @param {object} store store: object - store object
|
|
5728
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5729
|
+
* @returns {array} returnType: array - array containing an array of baselayers ids
|
|
5730
5730
|
*/
|
|
5731
5731
|
const getMapBaseLayersIds = createSelector(getMapById, store => store && store.baseLayers ? store.baseLayers : [], selectorMemoizationOptions);
|
|
5732
|
-
/**
|
|
5733
|
-
* Gets all baselayers for a map
|
|
5734
|
-
*
|
|
5735
|
-
* Example: baseLayers = getMapBaseLayers(store, 'mapid_1')
|
|
5736
|
-
* @param {object} store store: object - store object
|
|
5737
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5738
|
-
* @returns {array} returnType: array - array containing all baselayers for the map
|
|
5732
|
+
/**
|
|
5733
|
+
* Gets all baselayers for a map
|
|
5734
|
+
*
|
|
5735
|
+
* Example: baseLayers = getMapBaseLayers(store, 'mapid_1')
|
|
5736
|
+
* @param {object} store store: object - store object
|
|
5737
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5738
|
+
* @returns {array} returnType: array - array containing all baselayers for the map
|
|
5739
5739
|
*/
|
|
5740
5740
|
const getMapBaseLayers = createSelector(getMapBaseLayersIds, getLayersById, (layerIds, layers) => layerIds.map(layerId => layers[layerId]), selectorMemoizationOptions);
|
|
5741
|
-
/**
|
|
5742
|
-
* Gets and array of overLayers ids for a map
|
|
5743
|
-
*
|
|
5744
|
-
* Example: overLayersId = getMapOverLayersIds(store, 'mapid_1')
|
|
5745
|
-
* @param {object} store store: object - store object
|
|
5746
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5747
|
-
* @returns {array} returnType: array - array containing an array of overLayers ids
|
|
5741
|
+
/**
|
|
5742
|
+
* Gets and array of overLayers ids for a map
|
|
5743
|
+
*
|
|
5744
|
+
* Example: overLayersId = getMapOverLayersIds(store, 'mapid_1')
|
|
5745
|
+
* @param {object} store store: object - store object
|
|
5746
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5747
|
+
* @returns {array} returnType: array - array containing an array of overLayers ids
|
|
5748
5748
|
*/
|
|
5749
5749
|
const getMapOverLayersIds = createSelector(getMapById, store => store ? store.overLayers : [], selectorMemoizationOptions);
|
|
5750
5750
|
const getMapFeatureLayers = createSelector(getMapById, getFeatureLayers, (store, featureLayers) => {
|
|
5751
5751
|
const featureLayersOnMap = (store === null || store === void 0 ? void 0 : store.featureLayers) || [];
|
|
5752
5752
|
return featureLayers.filter(layer => featureLayersOnMap.indexOf(layer.id) !== -1);
|
|
5753
5753
|
}, selectorMemoizationOptions);
|
|
5754
|
-
/**
|
|
5755
|
-
* Gets all overLayers for a map
|
|
5756
|
-
*
|
|
5757
|
-
* Example: overLayers = getMapOverLayers(store, 'mapid_1')
|
|
5758
|
-
* @param {object} store store: object - store object
|
|
5759
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5760
|
-
* @returns {array} returnType: array - array containing all overLayers for the map
|
|
5754
|
+
/**
|
|
5755
|
+
* Gets all overLayers for a map
|
|
5756
|
+
*
|
|
5757
|
+
* Example: overLayers = getMapOverLayers(store, 'mapid_1')
|
|
5758
|
+
* @param {object} store store: object - store object
|
|
5759
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5760
|
+
* @returns {array} returnType: array - array containing all overLayers for the map
|
|
5761
5761
|
*/
|
|
5762
5762
|
const getMapOverLayers = createSelector(getMapOverLayersIds, getLayersById, (layerIds, layers) => layerIds.map(layerId => layers[layerId]), selectorMemoizationOptions);
|
|
5763
|
-
/**
|
|
5764
|
-
* Gets map dimensions
|
|
5765
|
-
*
|
|
5766
|
-
* Example: mapDimensions = getMapDimensions(store, 'mapid_1')
|
|
5767
|
-
* @param {object} store store: object - store object
|
|
5768
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5769
|
-
* @returns {array} returnType: array - array containing map dimensions
|
|
5763
|
+
/**
|
|
5764
|
+
* Gets map dimensions
|
|
5765
|
+
*
|
|
5766
|
+
* Example: mapDimensions = getMapDimensions(store, 'mapid_1')
|
|
5767
|
+
* @param {object} store store: object - store object
|
|
5768
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5769
|
+
* @returns {array} returnType: array - array containing map dimensions
|
|
5770
5770
|
*/
|
|
5771
5771
|
const getMapDimensions = createSelector(getMapById, webMap => webMap ? webMap.dimensions : [], selectorMemoizationOptions);
|
|
5772
|
-
/**
|
|
5773
|
-
* Gets the map dimension requested
|
|
5774
|
-
*
|
|
5775
|
-
* Example: mapDimensions = getMapDimension(store, 'mapid_1', 'elevation')
|
|
5776
|
-
* @param {object} store store: object - store object
|
|
5777
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5778
|
-
* @param {string} dimensionName dimensionName: string - name of the dimension
|
|
5779
|
-
* @returns {object} returnType: object - object containing the map dimension details
|
|
5772
|
+
/**
|
|
5773
|
+
* Gets the map dimension requested
|
|
5774
|
+
*
|
|
5775
|
+
* Example: mapDimensions = getMapDimension(store, 'mapid_1', 'elevation')
|
|
5776
|
+
* @param {object} store store: object - store object
|
|
5777
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5778
|
+
* @param {string} dimensionName dimensionName: string - name of the dimension
|
|
5779
|
+
* @returns {object} returnType: object - object containing the map dimension details
|
|
5780
5780
|
*/
|
|
5781
5781
|
const getMapDimension = createSelector([getMapById, (_store, mapId) => mapId, (_store, _mapId, dimensionName) => dimensionName], (mapState, _mapId, dimensionName) => {
|
|
5782
5782
|
if (mapState && mapState.dimensions) {
|
|
@@ -5784,12 +5784,12 @@ const getMapDimension = createSelector([getMapById, (_store, mapId) => mapId, (_
|
|
|
5784
5784
|
}
|
|
5785
5785
|
return undefined;
|
|
5786
5786
|
}, selectorMemoizationOptions);
|
|
5787
|
-
/**
|
|
5788
|
-
* Returns the current time in unix time for the given map
|
|
5789
|
-
*
|
|
5790
|
-
* @param {object} store store: object - store object
|
|
5791
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5792
|
-
* @returns {object} returnType: unix time as number
|
|
5787
|
+
/**
|
|
5788
|
+
* Returns the current time in unix time for the given map
|
|
5789
|
+
*
|
|
5790
|
+
* @param {object} store store: object - store object
|
|
5791
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5792
|
+
* @returns {object} returnType: unix time as number
|
|
5793
5793
|
*/
|
|
5794
5794
|
const getSelectedTime = createSelector((store, mapId) => getMapDimension(store, mapId, 'time'), timeDimension => {
|
|
5795
5795
|
const now = dateUtils.unix(new Date());
|
|
@@ -5814,45 +5814,45 @@ const getDataLimitsFromLayers = createSelector(getMapLayers, layers => layers.re
|
|
|
5814
5814
|
}
|
|
5815
5815
|
return [start, end];
|
|
5816
5816
|
},
|
|
5817
|
-
/* Using the maximum 32-bit value and 0 as starting points
|
|
5818
|
-
* bigger values like Number.MAX_VALUE or Number.MAX_SAFE_INTEGER
|
|
5819
|
-
* cause weird behaviour as timestamps break at 32bit limit (year 2038)
|
|
5817
|
+
/* Using the maximum 32-bit value and 0 as starting points
|
|
5818
|
+
* bigger values like Number.MAX_VALUE or Number.MAX_SAFE_INTEGER
|
|
5819
|
+
* cause weird behaviour as timestamps break at 32bit limit (year 2038)
|
|
5820
5820
|
*/
|
|
5821
5821
|
[2147483647, 0]), selectorMemoizationOptions);
|
|
5822
|
-
/**
|
|
5823
|
-
* Gets map srs
|
|
5824
|
-
*
|
|
5825
|
-
* Example: mapSrs = getSrs(store, 'mapid_1')
|
|
5826
|
-
* @param {object} store store: object - store object
|
|
5827
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5828
|
-
* @returns {string} returnType: string - string containing srs
|
|
5822
|
+
/**
|
|
5823
|
+
* Gets map srs
|
|
5824
|
+
*
|
|
5825
|
+
* Example: mapSrs = getSrs(store, 'mapid_1')
|
|
5826
|
+
* @param {object} store store: object - store object
|
|
5827
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5828
|
+
* @returns {string} returnType: string - string containing srs
|
|
5829
5829
|
*/
|
|
5830
5830
|
const getSrs = createSelector(getMapById, store => store ? store.srs : '', selectorMemoizationOptions);
|
|
5831
|
-
/**
|
|
5832
|
-
* Gets map bounding box
|
|
5833
|
-
*
|
|
5834
|
-
* Example: mapBbox = getBbox(store, 'mapid_1')
|
|
5835
|
-
* @param {object} store store: object - store object
|
|
5836
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5837
|
-
* @returns {object} returnType: object - boundingbox object {left: number, bottom: number, right:number, top: number}
|
|
5831
|
+
/**
|
|
5832
|
+
* Gets map bounding box
|
|
5833
|
+
*
|
|
5834
|
+
* Example: mapBbox = getBbox(store, 'mapid_1')
|
|
5835
|
+
* @param {object} store store: object - store object
|
|
5836
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5837
|
+
* @returns {object} returnType: object - boundingbox object {left: number, bottom: number, right:number, top: number}
|
|
5838
5838
|
*/
|
|
5839
5839
|
const getBbox = createSelector(getMapById, store => store ? store.bbox : {}, selectorMemoizationOptions);
|
|
5840
|
-
/**
|
|
5841
|
-
* Gets if map is animating
|
|
5842
|
-
*
|
|
5843
|
-
* Example: mapIsAnimating = isAnimating(store, 'mapid_1')
|
|
5844
|
-
* @param {object} store store: object - store object
|
|
5845
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5846
|
-
* @returns {boolean} returnType: boolean
|
|
5840
|
+
/**
|
|
5841
|
+
* Gets if map is animating
|
|
5842
|
+
*
|
|
5843
|
+
* Example: mapIsAnimating = isAnimating(store, 'mapid_1')
|
|
5844
|
+
* @param {object} store store: object - store object
|
|
5845
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5846
|
+
* @returns {boolean} returnType: boolean
|
|
5847
5847
|
*/
|
|
5848
5848
|
const isAnimating = createSelector(getMapById, store => store ? store.isAnimating : false);
|
|
5849
|
-
/**
|
|
5850
|
-
* Gets if any linked map is animating
|
|
5851
|
-
*
|
|
5852
|
-
* Example: linkedMapIsAnimating = linkedMapAnimationInfo(store, 'mapid_1')
|
|
5853
|
-
* @param {object} store store: object - store object
|
|
5854
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5855
|
-
* @returns {object} returnType: object - object containing isAnimating boolean and id string
|
|
5849
|
+
/**
|
|
5850
|
+
* Gets if any linked map is animating
|
|
5851
|
+
*
|
|
5852
|
+
* Example: linkedMapIsAnimating = linkedMapAnimationInfo(store, 'mapid_1')
|
|
5853
|
+
* @param {object} store store: object - store object
|
|
5854
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5855
|
+
* @returns {object} returnType: object - object containing isAnimating boolean and id string
|
|
5856
5856
|
*/
|
|
5857
5857
|
const linkedMapAnimationInfo = createSelector((store, mapId) => {
|
|
5858
5858
|
const animationInfo = {
|
|
@@ -5871,52 +5871,52 @@ const linkedMapAnimationInfo = createSelector((store, mapId) => {
|
|
|
5871
5871
|
});
|
|
5872
5872
|
return animationInfo;
|
|
5873
5873
|
}, animationInfo => animationInfo, selectorMemoizationOptions);
|
|
5874
|
-
/**
|
|
5875
|
-
* Gets start time of animation
|
|
5876
|
-
*
|
|
5877
|
-
* Example: endTimeOfAnimetion = getAnimationStartTime(store, 'mapid_1')
|
|
5878
|
-
* @param {object} store store: object - store object
|
|
5879
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5880
|
-
* @returns {string} returnType: string
|
|
5874
|
+
/**
|
|
5875
|
+
* Gets start time of animation
|
|
5876
|
+
*
|
|
5877
|
+
* Example: endTimeOfAnimetion = getAnimationStartTime(store, 'mapid_1')
|
|
5878
|
+
* @param {object} store store: object - store object
|
|
5879
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5880
|
+
* @returns {string} returnType: string
|
|
5881
5881
|
*/
|
|
5882
5882
|
const getAnimationStartTime = createSelector(getMapById, store => (store === null || store === void 0 ? void 0 : store.animationStartTime) ? store.animationStartTime : dateUtils.dateToString(dateUtils.sub(dateUtils.utc(), {
|
|
5883
5883
|
hours: 6
|
|
5884
5884
|
}), dateFormat), selectorMemoizationOptions);
|
|
5885
|
-
/**
|
|
5886
|
-
* Gets end time of animation
|
|
5887
|
-
*
|
|
5888
|
-
* Example: endTimeOfAnimation = getAnimationEndTime(store, 'mapid_1')
|
|
5889
|
-
* @param {object} store store: object - store object
|
|
5890
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5891
|
-
* @returns {string} returnType: string
|
|
5885
|
+
/**
|
|
5886
|
+
* Gets end time of animation
|
|
5887
|
+
*
|
|
5888
|
+
* Example: endTimeOfAnimation = getAnimationEndTime(store, 'mapid_1')
|
|
5889
|
+
* @param {object} store store: object - store object
|
|
5890
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5891
|
+
* @returns {string} returnType: string
|
|
5892
5892
|
*/
|
|
5893
5893
|
const getAnimationEndTime = createSelector(getMapById, store => (store === null || store === void 0 ? void 0 : store.animationEndTime) ? store.animationEndTime : dateUtils.dateToString(dateUtils.sub(dateUtils.utc(), {
|
|
5894
5894
|
minutes: 10
|
|
5895
5895
|
}), dateFormat), selectorMemoizationOptions);
|
|
5896
|
-
/**
|
|
5897
|
-
* Returns map is auto updating
|
|
5898
|
-
*
|
|
5899
|
-
* Example: isAutoUpdating = isAutoUpdating(store, 'mapid_1')
|
|
5900
|
-
* @param {object} store store: object - store object
|
|
5901
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5902
|
-
* @returns {boolean} returnType: boolean
|
|
5896
|
+
/**
|
|
5897
|
+
* Returns map is auto updating
|
|
5898
|
+
*
|
|
5899
|
+
* Example: isAutoUpdating = isAutoUpdating(store, 'mapid_1')
|
|
5900
|
+
* @param {object} store store: object - store object
|
|
5901
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5902
|
+
* @returns {boolean} returnType: boolean
|
|
5903
5903
|
*/
|
|
5904
5904
|
const isAutoUpdating = createSelector(getMapById, store => store ? store.isAutoUpdating : false, selectorMemoizationOptions);
|
|
5905
|
-
/**
|
|
5906
|
-
* Gets if endTime and duration of animationPayload are overriding maxValue and minValue of leading layer
|
|
5907
|
-
*
|
|
5908
|
-
* Example: shouldEndtimeOverride = shouldEndtimeOverride(store, 'mapid_1')
|
|
5909
|
-
* @param {object} store store: object - store object
|
|
5910
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5911
|
-
* @returns {boolean} returnType: boolean
|
|
5905
|
+
/**
|
|
5906
|
+
* Gets if endTime and duration of animationPayload are overriding maxValue and minValue of leading layer
|
|
5907
|
+
*
|
|
5908
|
+
* Example: shouldEndtimeOverride = shouldEndtimeOverride(store, 'mapid_1')
|
|
5909
|
+
* @param {object} store store: object - store object
|
|
5910
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5911
|
+
* @returns {boolean} returnType: boolean
|
|
5912
5912
|
*/
|
|
5913
5913
|
const shouldEndtimeOverride = createSelector(getMapById, store => store ? store.shouldEndtimeOverride : false, selectorMemoizationOptions);
|
|
5914
|
-
/**
|
|
5915
|
-
* Gets activeLayerId for map
|
|
5916
|
-
*
|
|
5917
|
-
* example: activeLayerId = getActiveLayerId(store, 'mapid_1')
|
|
5918
|
-
* @param {object} store store: object - store object
|
|
5919
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5914
|
+
/**
|
|
5915
|
+
* Gets activeLayerId for map
|
|
5916
|
+
*
|
|
5917
|
+
* example: activeLayerId = getActiveLayerId(store, 'mapid_1')
|
|
5918
|
+
* @param {object} store store: object - store object
|
|
5919
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5920
5920
|
*/
|
|
5921
5921
|
const getActiveLayerId = createSelector(getMapById, store => {
|
|
5922
5922
|
if ((store === null || store === void 0 ? void 0 : store.autoUpdateLayerId) && store.autoUpdateLayerId === store.autoTimeStepLayerId) {
|
|
@@ -5924,159 +5924,159 @@ const getActiveLayerId = createSelector(getMapById, store => {
|
|
|
5924
5924
|
}
|
|
5925
5925
|
return undefined;
|
|
5926
5926
|
}, selectorMemoizationOptions);
|
|
5927
|
-
/**
|
|
5928
|
-
* Gets autoUpdateLayerId for map
|
|
5929
|
-
*
|
|
5930
|
-
* example: autoUpdateLayerId = getAutoUpdateLayerId(store, 'mapid_1')
|
|
5931
|
-
* @param {object} store store: object - store object
|
|
5932
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5927
|
+
/**
|
|
5928
|
+
* Gets autoUpdateLayerId for map
|
|
5929
|
+
*
|
|
5930
|
+
* example: autoUpdateLayerId = getAutoUpdateLayerId(store, 'mapid_1')
|
|
5931
|
+
* @param {object} store store: object - store object
|
|
5932
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5933
5933
|
*/
|
|
5934
5934
|
const getAutoUpdateLayerId = createSelector(getMapById, store => store === null || store === void 0 ? void 0 : store.autoUpdateLayerId, selectorMemoizationOptions);
|
|
5935
|
-
/**
|
|
5936
|
-
* Gets autoUpdateLayerId for map
|
|
5937
|
-
*
|
|
5938
|
-
* example: autoUpdateLayerId = getAutoUpdateLayerId(store, 'mapid_1')
|
|
5939
|
-
* @param {object} store store: object - store object
|
|
5940
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5935
|
+
/**
|
|
5936
|
+
* Gets autoUpdateLayerId for map
|
|
5937
|
+
*
|
|
5938
|
+
* example: autoUpdateLayerId = getAutoUpdateLayerId(store, 'mapid_1')
|
|
5939
|
+
* @param {object} store store: object - store object
|
|
5940
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5941
5941
|
*/
|
|
5942
5942
|
const getAutoTimeStepLayerId = createSelector(getMapById, store => store === null || store === void 0 ? void 0 : store.autoTimeStepLayerId, selectorMemoizationOptions);
|
|
5943
|
-
/**
|
|
5944
|
-
* Gets span of a time slider of a map
|
|
5945
|
-
*
|
|
5946
|
-
* Example: span = getSpan(store, 'mapid_1')
|
|
5947
|
-
* @param {object} store store: object - store object
|
|
5948
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5949
|
-
* @returns {Span} returnType: Span - span as an enum
|
|
5943
|
+
/**
|
|
5944
|
+
* Gets span of a time slider of a map
|
|
5945
|
+
*
|
|
5946
|
+
* Example: span = getSpan(store, 'mapid_1')
|
|
5947
|
+
* @param {object} store store: object - store object
|
|
5948
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5949
|
+
* @returns {Span} returnType: Span - span as an enum
|
|
5950
5950
|
*/
|
|
5951
5951
|
const getMapTimeSliderSpan = createSelector(getMapById, store => store ? store.timeSliderSpan : defaultTimeSpan, selectorMemoizationOptions);
|
|
5952
|
-
/**
|
|
5953
|
-
* Gets time step of a map
|
|
5954
|
-
*
|
|
5955
|
-
* Example: timeStep = getTimeStep(store, 'mapid_1')
|
|
5956
|
-
* @param {object} store store: object - store object
|
|
5957
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5958
|
-
* @returns {number} returnType: number - time step as a number
|
|
5952
|
+
/**
|
|
5953
|
+
* Gets time step of a map
|
|
5954
|
+
*
|
|
5955
|
+
* Example: timeStep = getTimeStep(store, 'mapid_1')
|
|
5956
|
+
* @param {object} store store: object - store object
|
|
5957
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5958
|
+
* @returns {number} returnType: number - time step as a number
|
|
5959
5959
|
*/
|
|
5960
5960
|
const getMapTimeStep = createSelector(getMapById, store => {
|
|
5961
5961
|
var _a;
|
|
5962
5962
|
return (_a = store === null || store === void 0 ? void 0 : store.timeStep) !== null && _a !== void 0 ? _a : defaultTimeStep;
|
|
5963
5963
|
}, selectorMemoizationOptions);
|
|
5964
5964
|
const getMapTimeStepWithoutDefault = createSelector(getMapById, store => store === null || store === void 0 ? void 0 : store.timeStep, selectorMemoizationOptions);
|
|
5965
|
-
/**
|
|
5966
|
-
* Returns the speed of animation
|
|
5967
|
-
*
|
|
5968
|
-
* Example: speed = getSpeed(store, 'mapid_1')
|
|
5969
|
-
* @param {object} store store: object - store object
|
|
5970
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5971
|
-
* @returns {number} returnType: number - speed as a number
|
|
5965
|
+
/**
|
|
5966
|
+
* Returns the speed of animation
|
|
5967
|
+
*
|
|
5968
|
+
* Example: speed = getSpeed(store, 'mapid_1')
|
|
5969
|
+
* @param {object} store store: object - store object
|
|
5970
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5971
|
+
* @returns {number} returnType: number - speed as a number
|
|
5972
5972
|
*/
|
|
5973
5973
|
const getMapAnimationDelay = createSelector(getMapById, store => store ? store.animationDelay : defaultAnimationDelayAtStart, selectorMemoizationOptions);
|
|
5974
|
-
/**
|
|
5975
|
-
* Returns the width of time slider
|
|
5976
|
-
*
|
|
5977
|
-
* Example: timeSliderWith = getMapTimeSliderWidth(store, 'mapid_1')
|
|
5978
|
-
* @param {object} store store: object - store object
|
|
5979
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5980
|
-
* @returns {number} returnType: number - center time as a unix timestamp
|
|
5974
|
+
/**
|
|
5975
|
+
* Returns the width of time slider
|
|
5976
|
+
*
|
|
5977
|
+
* Example: timeSliderWith = getMapTimeSliderWidth(store, 'mapid_1')
|
|
5978
|
+
* @param {object} store store: object - store object
|
|
5979
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5980
|
+
* @returns {number} returnType: number - center time as a unix timestamp
|
|
5981
5981
|
*/
|
|
5982
5982
|
const getMapTimeSliderWidth = createSelector(getMapById, store => store ? store.timeSliderWidth : 0, selectorMemoizationOptions);
|
|
5983
|
-
/**
|
|
5984
|
-
* Returns the center time of time slider
|
|
5985
|
-
*
|
|
5986
|
-
* Example: centerTime = getCenterTime(store, 'mapid_1')
|
|
5987
|
-
* @param {object} store store: object - store object
|
|
5988
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5989
|
-
* @returns {number} returnType: number - center time as a unix timestamp
|
|
5983
|
+
/**
|
|
5984
|
+
* Returns the center time of time slider
|
|
5985
|
+
*
|
|
5986
|
+
* Example: centerTime = getCenterTime(store, 'mapid_1')
|
|
5987
|
+
* @param {object} store store: object - store object
|
|
5988
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5989
|
+
* @returns {number} returnType: number - center time as a unix timestamp
|
|
5990
5990
|
*/
|
|
5991
5991
|
const getMapTimeSliderCenterTime = createSelector(getMapById, store => store ? store.timeSliderCenterTime : dateUtils.unix(dateUtils.utc()), selectorMemoizationOptions);
|
|
5992
|
-
/**
|
|
5993
|
-
* Returns the number of seconds per pixel on the time slider
|
|
5994
|
-
*
|
|
5995
|
-
* Example: secondsPerPx = getSecondsPerPx(store, 'mapid_1')
|
|
5996
|
-
* @param {object} store store: object - store object
|
|
5997
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
5998
|
-
* @returns {number} returnType: number - the number of seconds per pixel
|
|
5992
|
+
/**
|
|
5993
|
+
* Returns the number of seconds per pixel on the time slider
|
|
5994
|
+
*
|
|
5995
|
+
* Example: secondsPerPx = getSecondsPerPx(store, 'mapid_1')
|
|
5996
|
+
* @param {object} store store: object - store object
|
|
5997
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
5998
|
+
* @returns {number} returnType: number - the number of seconds per pixel
|
|
5999
5999
|
*/
|
|
6000
6000
|
const getMapTimeSliderSecondsPerPx = createSelector(getMapById, store => store ? store.timeSliderSecondsPerPx : defaultSecondsPerPx, selectorMemoizationOptions);
|
|
6001
|
-
/**
|
|
6002
|
-
* Returns map is timestep auto
|
|
6003
|
-
*
|
|
6004
|
-
* Example: isTimestepAuto = isTimestepAuto(store, 'mapid_1')
|
|
6005
|
-
* @param {object} store store: object - store object
|
|
6006
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6007
|
-
* @returns {boolean} returnType: boolean
|
|
6001
|
+
/**
|
|
6002
|
+
* Returns map is timestep auto
|
|
6003
|
+
*
|
|
6004
|
+
* Example: isTimestepAuto = isTimestepAuto(store, 'mapid_1')
|
|
6005
|
+
* @param {object} store store: object - store object
|
|
6006
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6007
|
+
* @returns {boolean} returnType: boolean
|
|
6008
6008
|
*/
|
|
6009
6009
|
const isTimestepAuto = createSelector(getMapById, store => store ? store.isTimestepAuto : false, selectorMemoizationOptions);
|
|
6010
|
-
/**
|
|
6011
|
-
* Returns map is animation auto
|
|
6012
|
-
* @param {object} store store: object - store object
|
|
6013
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6014
|
-
* @returns {boolean} returnType: boolean
|
|
6010
|
+
/**
|
|
6011
|
+
* Returns map is animation auto
|
|
6012
|
+
* @param {object} store store: object - store object
|
|
6013
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6014
|
+
* @returns {boolean} returnType: boolean
|
|
6015
6015
|
*/
|
|
6016
6016
|
const isAnimationLengthAuto = createSelector(getMapById, store => (store === null || store === void 0 ? void 0 : store.isAnimationLengthAuto) || false, selectorMemoizationOptions);
|
|
6017
|
-
/**
|
|
6018
|
-
* Returns map is timespan auto
|
|
6019
|
-
*
|
|
6020
|
-
* Example: isTimeSpanAuto = isTimeSpanAuto(store, 'mapid_1')
|
|
6021
|
-
* @param {object} store store: object - store object
|
|
6022
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6023
|
-
* @returns {boolean} returnType: boolean
|
|
6017
|
+
/**
|
|
6018
|
+
* Returns map is timespan auto
|
|
6019
|
+
*
|
|
6020
|
+
* Example: isTimeSpanAuto = isTimeSpanAuto(store, 'mapid_1')
|
|
6021
|
+
* @param {object} store store: object - store object
|
|
6022
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6023
|
+
* @returns {boolean} returnType: boolean
|
|
6024
6024
|
*/
|
|
6025
6025
|
const isTimeSpanAuto = createSelector(getMapById, store => store ? store.isTimeSpanAuto : false, selectorMemoizationOptions);
|
|
6026
|
-
/**
|
|
6027
|
-
* Returns map is time slider hover
|
|
6028
|
-
*
|
|
6029
|
-
* Example: isTimeSliderHoverOn = isTimeSliderHoverOn(store, 'mapid_1')
|
|
6030
|
-
* @param {object} store store: object - store object
|
|
6031
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6032
|
-
* @returns {boolean} returnType: boolean
|
|
6026
|
+
/**
|
|
6027
|
+
* Returns map is time slider hover
|
|
6028
|
+
*
|
|
6029
|
+
* Example: isTimeSliderHoverOn = isTimeSliderHoverOn(store, 'mapid_1')
|
|
6030
|
+
* @param {object} store store: object - store object
|
|
6031
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6032
|
+
* @returns {boolean} returnType: boolean
|
|
6033
6033
|
*/
|
|
6034
6034
|
const isTimeSliderHoverOn = createSelector(getMapById, store => store ? store.isTimeSliderHoverOn : false, selectorMemoizationOptions);
|
|
6035
|
-
/**
|
|
6036
|
-
* Returns map if zoomcontrols are visible
|
|
6037
|
-
*
|
|
6038
|
-
* Example: isZoomControlsVisible = isZoomControlsVisible(store, 'mapid_1')
|
|
6039
|
-
* @param {object} store store: object - store object
|
|
6040
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6041
|
-
* @returns {boolean} returnType: boolean
|
|
6035
|
+
/**
|
|
6036
|
+
* Returns map if zoomcontrols are visible
|
|
6037
|
+
*
|
|
6038
|
+
* Example: isZoomControlsVisible = isZoomControlsVisible(store, 'mapid_1')
|
|
6039
|
+
* @param {object} store store: object - store object
|
|
6040
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6041
|
+
* @returns {boolean} returnType: boolean
|
|
6042
6042
|
*/
|
|
6043
6043
|
const isZoomControlsVisible = createSelector(getMapById, store => store ? store.shouldShowZoomControls : true, selectorMemoizationOptions);
|
|
6044
|
-
/**
|
|
6045
|
-
* Returns map is time slider visible
|
|
6046
|
-
*
|
|
6047
|
-
* Example: isTimeSliderHoverOn = isTimeSliderVisible(store, 'mapid_1')
|
|
6048
|
-
* @param {object} store store: object - store object
|
|
6049
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6050
|
-
* @returns {boolean} returnType: boolean
|
|
6044
|
+
/**
|
|
6045
|
+
* Returns map is time slider visible
|
|
6046
|
+
*
|
|
6047
|
+
* Example: isTimeSliderHoverOn = isTimeSliderVisible(store, 'mapid_1')
|
|
6048
|
+
* @param {object} store store: object - store object
|
|
6049
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6050
|
+
* @returns {boolean} returnType: boolean
|
|
6051
6051
|
*/
|
|
6052
6052
|
const isTimeSliderVisible = createSelector(getMapById, store => store ? store.isTimeSliderVisible : true, selectorMemoizationOptions);
|
|
6053
|
-
/**
|
|
6054
|
-
* Returns is layer is active layer
|
|
6055
|
-
*
|
|
6056
|
-
* Example: isLayerActiveLayer = getIsLayerActiveLayer(store, 'mapid_1', 'layer_1)
|
|
6057
|
-
* @param {object} store store: object - store object
|
|
6058
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6059
|
-
* @param {string} mapId layerId: string - Id of the layer
|
|
6060
|
-
* @returns {boolean} returnType: boolean
|
|
6053
|
+
/**
|
|
6054
|
+
* Returns is layer is active layer
|
|
6055
|
+
*
|
|
6056
|
+
* Example: isLayerActiveLayer = getIsLayerActiveLayer(store, 'mapid_1', 'layer_1)
|
|
6057
|
+
* @param {object} store store: object - store object
|
|
6058
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6059
|
+
* @param {string} mapId layerId: string - Id of the layer
|
|
6060
|
+
* @returns {boolean} returnType: boolean
|
|
6061
6061
|
*/
|
|
6062
6062
|
const getIsLayerActiveLayer = createSelector(getActiveLayerId, (_store, _mapId, layerId) => layerId, (activeLayerId, layerId) => activeLayerId === layerId, selectorMemoizationOptions);
|
|
6063
|
-
/**
|
|
6064
|
-
* Returns the mapId for given layerId
|
|
6065
|
-
*
|
|
6066
|
-
* Example const mapId = getMapIdFromLayerId(store 'layerId-A');
|
|
6067
|
-
* @param {object} store store: object - store object
|
|
6068
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
6069
|
-
* @returns {string} returnType: string - the mapId, or null if not found
|
|
6063
|
+
/**
|
|
6064
|
+
* Returns the mapId for given layerId
|
|
6065
|
+
*
|
|
6066
|
+
* Example const mapId = getMapIdFromLayerId(store 'layerId-A');
|
|
6067
|
+
* @param {object} store store: object - store object
|
|
6068
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
6069
|
+
* @returns {string} returnType: string - the mapId, or null if not found
|
|
6070
6070
|
*/
|
|
6071
6071
|
const getMapIdFromLayerId = createSelector(store => store === null || store === void 0 ? void 0 : store.webmap, (_store, layerId) => layerId, findMapIdFromLayerId, selectorMemoizationOptions);
|
|
6072
|
-
/**
|
|
6073
|
-
* Returns the layerId for given layerName
|
|
6074
|
-
*
|
|
6075
|
-
* Example const layerId = getLayerIdByLayerName(store, 'mapid-1', 'precipitation');
|
|
6076
|
-
* @param {object} store store: object - store object
|
|
6077
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6078
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
6079
|
-
* @returns {string} returnType: string - the layerId, or null if not found
|
|
6072
|
+
/**
|
|
6073
|
+
* Returns the layerId for given layerName
|
|
6074
|
+
*
|
|
6075
|
+
* Example const layerId = getLayerIdByLayerName(store, 'mapid-1', 'precipitation');
|
|
6076
|
+
* @param {object} store store: object - store object
|
|
6077
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6078
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
6079
|
+
* @returns {string} returnType: string - the layerId, or null if not found
|
|
6080
6080
|
*/
|
|
6081
6081
|
const getLayerIdByLayerName = createSelector(getMapLayers, (_store, _mapId, layerName) => layerName, (layers, layerName) => {
|
|
6082
6082
|
const layer = layers.find(layer => layer.name === layerName);
|
|
@@ -6085,26 +6085,26 @@ const getLayerIdByLayerName = createSelector(getMapLayers, (_store, _mapId, laye
|
|
|
6085
6085
|
}
|
|
6086
6086
|
return null;
|
|
6087
6087
|
}, selectorMemoizationOptions);
|
|
6088
|
-
/**
|
|
6089
|
-
* Returns the layerIndex in the map for given layerId
|
|
6090
|
-
*
|
|
6091
|
-
* Example const layerIndex = getLayerIndexByLayerId(store, 'mapid-1', 'precipitation');
|
|
6092
|
-
* @param {object} store store: object - store object
|
|
6093
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6094
|
-
* @param {string} layerId layerId: string - Id of the layer
|
|
6095
|
-
* @returns {number} returnType: index number or -1 if not found
|
|
6088
|
+
/**
|
|
6089
|
+
* Returns the layerIndex in the map for given layerId
|
|
6090
|
+
*
|
|
6091
|
+
* Example const layerIndex = getLayerIndexByLayerId(store, 'mapid-1', 'precipitation');
|
|
6092
|
+
* @param {object} store store: object - store object
|
|
6093
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6094
|
+
* @param {string} layerId layerId: string - Id of the layer
|
|
6095
|
+
* @returns {number} returnType: index number or -1 if not found
|
|
6096
6096
|
*/
|
|
6097
6097
|
const getLayerIndexByLayerId = createSelector(getMapLayers, (_store, _mapId, layerId) => layerId, (layers, layerId) => {
|
|
6098
6098
|
return layers.findIndex(layer => layer.id === layerId);
|
|
6099
6099
|
}, selectorMemoizationOptions);
|
|
6100
|
-
/**
|
|
6101
|
-
* Returns the Layer in the map for given layerIndex
|
|
6102
|
-
*
|
|
6103
|
-
* Example const layer = getLayerByLayerIndex(store, 'mapid-1', 0);
|
|
6104
|
-
* @param {object} store store: object - store object
|
|
6105
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6106
|
-
* @param {number} layerIndex layerId: number - Index of the layer in the map
|
|
6107
|
-
* @returns {object} returnType: layer, or null if not found
|
|
6100
|
+
/**
|
|
6101
|
+
* Returns the Layer in the map for given layerIndex
|
|
6102
|
+
*
|
|
6103
|
+
* Example const layer = getLayerByLayerIndex(store, 'mapid-1', 0);
|
|
6104
|
+
* @param {object} store store: object - store object
|
|
6105
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6106
|
+
* @param {number} layerIndex layerId: number - Index of the layer in the map
|
|
6107
|
+
* @returns {object} returnType: layer, or null if not found
|
|
6108
6108
|
*/
|
|
6109
6109
|
const getLayerByLayerIndex = createSelector(getMapLayers, (_store, _mapId, layerIndex) => layerIndex, (layers, layerIndex) => {
|
|
6110
6110
|
if (layerIndex >= 0 && layerIndex < layers.length) {
|
|
@@ -6112,12 +6112,12 @@ const getLayerByLayerIndex = createSelector(getMapLayers, (_store, _mapId, layer
|
|
|
6112
6112
|
}
|
|
6113
6113
|
return null;
|
|
6114
6114
|
}, selectorMemoizationOptions);
|
|
6115
|
-
/**
|
|
6116
|
-
* Returns name of all unique dimensions present in all maps
|
|
6117
|
-
*
|
|
6118
|
-
* Example getAllUniqueDimensions(store);
|
|
6119
|
-
* @param {object} store store: object - store object
|
|
6120
|
-
* @returns {array} returnType: array of dimension names
|
|
6115
|
+
/**
|
|
6116
|
+
* Returns name of all unique dimensions present in all maps
|
|
6117
|
+
*
|
|
6118
|
+
* Example getAllUniqueDimensions(store);
|
|
6119
|
+
* @param {object} store store: object - store object
|
|
6120
|
+
* @returns {array} returnType: array of dimension names
|
|
6121
6121
|
*/
|
|
6122
6122
|
const getAllUniqueDimensions = createSelector(getAllMapIds, store => store, (mapIds, store) => {
|
|
6123
6123
|
return mapIds.reduce((list, mapId) => {
|
|
@@ -6131,49 +6131,49 @@ const getAllUniqueDimensions = createSelector(getAllMapIds, store => store, (map
|
|
|
6131
6131
|
return uniqueMapDims;
|
|
6132
6132
|
}, []);
|
|
6133
6133
|
}, selectorMemoizationOptions);
|
|
6134
|
-
/**
|
|
6135
|
-
* Returns the mapPinLocation for the current map
|
|
6136
|
-
*
|
|
6137
|
-
* Example getPinLocation(store);
|
|
6138
|
-
* @param {object} store store: object - store object
|
|
6139
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6140
|
-
* @returns {object} returnType: latitude and longitude of pin
|
|
6134
|
+
/**
|
|
6135
|
+
* Returns the mapPinLocation for the current map
|
|
6136
|
+
*
|
|
6137
|
+
* Example getPinLocation(store);
|
|
6138
|
+
* @param {object} store store: object - store object
|
|
6139
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6140
|
+
* @returns {object} returnType: latitude and longitude of pin
|
|
6141
6141
|
*/
|
|
6142
6142
|
const getPinLocation = createSelector(getMapById, store => store === null || store === void 0 ? void 0 : store.mapPinLocation, selectorMemoizationOptions);
|
|
6143
|
-
/**
|
|
6144
|
-
* Returns the disable map pin boolean for the current map
|
|
6145
|
-
*
|
|
6146
|
-
* Example getDisableMapPin(store);
|
|
6147
|
-
* @param {object} store store: object - store object
|
|
6148
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6149
|
-
* @returns {boolean} returnType: boolean
|
|
6143
|
+
/**
|
|
6144
|
+
* Returns the disable map pin boolean for the current map
|
|
6145
|
+
*
|
|
6146
|
+
* Example getDisableMapPin(store);
|
|
6147
|
+
* @param {object} store store: object - store object
|
|
6148
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6149
|
+
* @returns {boolean} returnType: boolean
|
|
6150
6150
|
*/
|
|
6151
6151
|
const getDisableMapPin = createSelector(getMapById, store => store ? store.disableMapPin : false, selectorMemoizationOptions);
|
|
6152
|
-
/**
|
|
6153
|
-
* Returns the display map pin boolean for the current map
|
|
6154
|
-
*
|
|
6155
|
-
* Example getDisplayMapPin(store);
|
|
6156
|
-
* @param {object} store store: object - store object
|
|
6157
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6158
|
-
* @returns {boolean} returnType: boolean
|
|
6152
|
+
/**
|
|
6153
|
+
* Returns the display map pin boolean for the current map
|
|
6154
|
+
*
|
|
6155
|
+
* Example getDisplayMapPin(store);
|
|
6156
|
+
* @param {object} store store: object - store object
|
|
6157
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6158
|
+
* @returns {boolean} returnType: boolean
|
|
6159
6159
|
*/
|
|
6160
6160
|
const getDisplayMapPin = createSelector(getMapById, store => store ? store.displayMapPin : false, selectorMemoizationOptions);
|
|
6161
|
-
/**
|
|
6162
|
-
* Returns the legend id
|
|
6163
|
-
*
|
|
6164
|
-
* Example getLegendId(store, mapId);
|
|
6165
|
-
* @param {object} store store: object - store object
|
|
6166
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6167
|
-
* @returns {boolean} returnType: id or undefined
|
|
6161
|
+
/**
|
|
6162
|
+
* Returns the legend id
|
|
6163
|
+
*
|
|
6164
|
+
* Example getLegendId(store, mapId);
|
|
6165
|
+
* @param {object} store store: object - store object
|
|
6166
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6167
|
+
* @returns {boolean} returnType: id or undefined
|
|
6168
6168
|
*/
|
|
6169
6169
|
const getLegendId = createSelector(getMapById, store => store ? store.legendId : undefined, selectorMemoizationOptions);
|
|
6170
|
-
/**
|
|
6171
|
-
* Creates a MapPreset from mapId
|
|
6172
|
-
*
|
|
6173
|
-
* Example getMapPreset(store, mapId);
|
|
6174
|
-
* @param {object} store store: object - store object
|
|
6175
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6176
|
-
* @returns {MapPreset} returnType: MapPreset
|
|
6170
|
+
/**
|
|
6171
|
+
* Creates a MapPreset from mapId
|
|
6172
|
+
*
|
|
6173
|
+
* Example getMapPreset(store, mapId);
|
|
6174
|
+
* @param {object} store store: object - store object
|
|
6175
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6176
|
+
* @returns {MapPreset} returnType: MapPreset
|
|
6177
6177
|
*/
|
|
6178
6178
|
const getMapPreset = createSelector(getMapLayers, getMapBaseLayers, getMapOverLayers, getBbox, getSrs, getActiveLayerId, getAutoTimeStepLayerId, getAutoUpdateLayerId, isAnimating, isAutoUpdating, isTimeSliderVisible, getDisplayMapPin, isZoomControlsVisible, getMapTimeStep, getMapAnimationDelay, getAnimationStartTime, getAnimationEndTime, isTimestepAuto, getLegendId, getUiStore, (mapLayers, baseLayers, overLayers, bbox, srs, activeLayerId, autoUpdateLayerId, autoTimeStepLayerId, isAnimating, isAutoUpdating, isTimeSliderVisible, displayMapPin, isZoomControlsVisible, mapTimeStep, mapAnimationDelay, animationStartTime, animationEndTime, isTimestepAuto, legendId, uiStore) => {
|
|
6179
6179
|
var _a;
|
|
@@ -6214,13 +6214,13 @@ const getMapPreset = createSelector(getMapLayers, getMapBaseLayers, getMapOverLa
|
|
|
6214
6214
|
shouldShowLegend
|
|
6215
6215
|
});
|
|
6216
6216
|
}, selectorMemoizationOptions);
|
|
6217
|
-
/**
|
|
6218
|
-
* Gets all enabled layerIds for map
|
|
6219
|
-
*
|
|
6220
|
-
* Example: getMapLayerIdsEnabled = getLayerIdsEnabled(store, 'mapId_1')
|
|
6221
|
-
* @param {object} store store: object - store
|
|
6222
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6223
|
-
* @returns {string[]} returnType: string[] - array of enabled layerIds
|
|
6217
|
+
/**
|
|
6218
|
+
* Gets all enabled layerIds for map
|
|
6219
|
+
*
|
|
6220
|
+
* Example: getMapLayerIdsEnabled = getLayerIdsEnabled(store, 'mapId_1')
|
|
6221
|
+
* @param {object} store store: object - store
|
|
6222
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6223
|
+
* @returns {string[]} returnType: string[] - array of enabled layerIds
|
|
6224
6224
|
*/
|
|
6225
6225
|
const getMapLayerIdsEnabled = createSelector(getLayerIds, getLayersById, (mapLayerIds, layers) => mapLayerIds.reduce((list, layerId) => {
|
|
6226
6226
|
if (layers[layerId] && layers[layerId].enabled) {
|
|
@@ -6228,32 +6228,32 @@ const getMapLayerIdsEnabled = createSelector(getLayerIds, getLayersById, (mapLay
|
|
|
6228
6228
|
}
|
|
6229
6229
|
return list;
|
|
6230
6230
|
}, []), selectorMemoizationOptions);
|
|
6231
|
-
/**
|
|
6232
|
-
* Returns if a map dimension is used for any enabled layers on that map
|
|
6233
|
-
*
|
|
6234
|
-
* Example getIsEnabledLayersForMapDimension(store, mapId);
|
|
6235
|
-
* @param {object} store store: object - store object
|
|
6236
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6237
|
-
* @param {string} dimensionName dimensionName: string - name of the dimension
|
|
6238
|
-
* @returns {Boolean} returnType: boolean
|
|
6231
|
+
/**
|
|
6232
|
+
* Returns if a map dimension is used for any enabled layers on that map
|
|
6233
|
+
*
|
|
6234
|
+
* Example getIsEnabledLayersForMapDimension(store, mapId);
|
|
6235
|
+
* @param {object} store store: object - store object
|
|
6236
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6237
|
+
* @param {string} dimensionName dimensionName: string - name of the dimension
|
|
6238
|
+
* @returns {Boolean} returnType: boolean
|
|
6239
6239
|
*/
|
|
6240
6240
|
const getIsEnabledLayersForMapDimension = createSelector(getMapLayerIdsEnabled, (store, _mapId, dimensionName) => getDimensionLayerIds(store, dimensionName), (enabledMapLayerIds, dimensionLayerIds) => {
|
|
6241
6241
|
return dimensionLayerIds.some(layerId => enabledMapLayerIds.includes(layerId));
|
|
6242
6242
|
}, selectorMemoizationOptions);
|
|
6243
|
-
/**
|
|
6244
|
-
* Returns the dockedLayerManagerSize originally set in mapPresets
|
|
6245
|
-
*
|
|
6246
|
-
* Example getDockedLayerManagerSize(store);
|
|
6247
|
-
* @param {object} store store: object - store object
|
|
6248
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6249
|
-
* @returns {DockedLayerManagerSize} returnType: string
|
|
6243
|
+
/**
|
|
6244
|
+
* Returns the dockedLayerManagerSize originally set in mapPresets
|
|
6245
|
+
*
|
|
6246
|
+
* Example getDockedLayerManagerSize(store);
|
|
6247
|
+
* @param {object} store store: object - store object
|
|
6248
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6249
|
+
* @returns {DockedLayerManagerSize} returnType: string
|
|
6250
6250
|
*/
|
|
6251
6251
|
const getDockedLayerManagerSize = createSelector(getMapById, store => store ? store.dockedLayerManagerSize : 'sizeSmall', selectorMemoizationOptions);
|
|
6252
|
-
/**
|
|
6253
|
-
* Returns the animation list for given map id
|
|
6254
|
-
* @param {object} store store: object - store object
|
|
6255
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6256
|
-
* @returns {animationList} returnType: WebMapAnimationList, list of timesteps to animate for this map.
|
|
6252
|
+
/**
|
|
6253
|
+
* Returns the animation list for given map id
|
|
6254
|
+
* @param {object} store store: object - store object
|
|
6255
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6256
|
+
* @returns {animationList} returnType: WebMapAnimationList, list of timesteps to animate for this map.
|
|
6257
6257
|
*/
|
|
6258
6258
|
const getAnimationList = createSelector(getLayersById, getMapById, getAnimationStartTime, getAnimationEndTime, getMapTimeStep, (layers, mapStore, animationStart, animationEnd, animationInterval) => {
|
|
6259
6259
|
// Animation is defined by one of the following:
|
|
@@ -6286,10 +6286,10 @@ const getAnimationList = createSelector(getLayersById, getMapById, getAnimationS
|
|
|
6286
6286
|
}
|
|
6287
6287
|
return animationList;
|
|
6288
6288
|
}, selectorMemoizationOptions);
|
|
6289
|
-
/**
|
|
6290
|
-
* @param {object} store store: object - store object
|
|
6291
|
-
* @param {string} mapId mapId: string - Id of the map
|
|
6292
|
-
* @returns {object} Returns min and max value of time dimension of autoTimeStep-layer. If no autoTimeStep-layer it returns default start/end time from store.
|
|
6289
|
+
/**
|
|
6290
|
+
* @param {object} store store: object - store object
|
|
6291
|
+
* @param {string} mapId mapId: string - Id of the map
|
|
6292
|
+
* @returns {object} Returns min and max value of time dimension of autoTimeStep-layer. If no autoTimeStep-layer it returns default start/end time from store.
|
|
6293
6293
|
*/
|
|
6294
6294
|
const getAnimationRange = createSelector(getLayersById, getAutoTimeStepLayerId, getAnimationStartTime, getAnimationEndTime, isAnimationLengthAuto, (layers, autoTimeStepLayerId, startTime, endTime, isAnimationLengthAuto) => {
|
|
6295
6295
|
var _a, _b;
|
|
@@ -6369,22 +6369,22 @@ var selectors$2 = /*#__PURE__*/Object.freeze({
|
|
|
6369
6369
|
shouldEndtimeOverride: shouldEndtimeOverride
|
|
6370
6370
|
});
|
|
6371
6371
|
|
|
6372
|
-
/* *
|
|
6373
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6374
|
-
* you may not use this file except in compliance with the License.
|
|
6375
|
-
* You may obtain a copy of the License at
|
|
6376
|
-
*
|
|
6377
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6378
|
-
*
|
|
6379
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
6380
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6381
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6382
|
-
* See the License for the specific language governing permissions and
|
|
6383
|
-
* limitations under the License.
|
|
6384
|
-
*
|
|
6385
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6386
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6387
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6372
|
+
/* *
|
|
6373
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6374
|
+
* you may not use this file except in compliance with the License.
|
|
6375
|
+
* You may obtain a copy of the License at
|
|
6376
|
+
*
|
|
6377
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6378
|
+
*
|
|
6379
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
6380
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6381
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6382
|
+
* See the License for the specific language governing permissions and
|
|
6383
|
+
* limitations under the License.
|
|
6384
|
+
*
|
|
6385
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6386
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6387
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6388
6388
|
* */
|
|
6389
6389
|
var MapActionOrigin;
|
|
6390
6390
|
(function (MapActionOrigin) {
|
|
@@ -6396,22 +6396,22 @@ var enums = /*#__PURE__*/Object.freeze({
|
|
|
6396
6396
|
get MapActionOrigin () { return MapActionOrigin; }
|
|
6397
6397
|
});
|
|
6398
6398
|
|
|
6399
|
-
/* *
|
|
6400
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6401
|
-
* you may not use this file except in compliance with the License.
|
|
6402
|
-
* You may obtain a copy of the License at
|
|
6403
|
-
*
|
|
6404
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6405
|
-
*
|
|
6406
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
6407
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6408
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6409
|
-
* See the License for the specific language governing permissions and
|
|
6410
|
-
* limitations under the License.
|
|
6411
|
-
*
|
|
6412
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6413
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6414
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6399
|
+
/* *
|
|
6400
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6401
|
+
* you may not use this file except in compliance with the License.
|
|
6402
|
+
* You may obtain a copy of the License at
|
|
6403
|
+
*
|
|
6404
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6405
|
+
*
|
|
6406
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
6407
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6408
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6409
|
+
* See the License for the specific language governing permissions and
|
|
6410
|
+
* limitations under the License.
|
|
6411
|
+
*
|
|
6412
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6413
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6414
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6415
6415
|
* */
|
|
6416
6416
|
const IS_LEGEND_OPEN_BY_DEFAULT = false;
|
|
6417
6417
|
|
|
@@ -6510,52 +6510,52 @@ const {
|
|
|
6510
6510
|
} = slice$2;
|
|
6511
6511
|
const serviceActions = slice$2.actions;
|
|
6512
6512
|
|
|
6513
|
-
/* *
|
|
6514
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6515
|
-
* you may not use this file except in compliance with the License.
|
|
6516
|
-
* You may obtain a copy of the License at
|
|
6517
|
-
*
|
|
6518
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6519
|
-
*
|
|
6520
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
6521
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6522
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6523
|
-
* See the License for the specific language governing permissions and
|
|
6524
|
-
* limitations under the License.
|
|
6525
|
-
*
|
|
6526
|
-
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6527
|
-
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
6528
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6513
|
+
/* *
|
|
6514
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6515
|
+
* you may not use this file except in compliance with the License.
|
|
6516
|
+
* You may obtain a copy of the License at
|
|
6517
|
+
*
|
|
6518
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6519
|
+
*
|
|
6520
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
6521
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6522
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6523
|
+
* See the License for the specific language governing permissions and
|
|
6524
|
+
* limitations under the License.
|
|
6525
|
+
*
|
|
6526
|
+
* Copyright 2020 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6527
|
+
* Copyright 2020 - Finnish Meteorological Institute (FMI)
|
|
6528
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6529
6529
|
* */
|
|
6530
6530
|
const getServicesStore = store => store === null || store === void 0 ? void 0 : store.services;
|
|
6531
|
-
/**
|
|
6532
|
-
* Retrieves all serviceIds
|
|
6533
|
-
*
|
|
6534
|
-
* Example: serviceIds = getServiceIds(store)
|
|
6535
|
-
* @param {object} store store: object - object from which the service state will be extracted
|
|
6536
|
-
* @returns {array} returnType: array - an array of all serviceIds
|
|
6531
|
+
/**
|
|
6532
|
+
* Retrieves all serviceIds
|
|
6533
|
+
*
|
|
6534
|
+
* Example: serviceIds = getServiceIds(store)
|
|
6535
|
+
* @param {object} store store: object - object from which the service state will be extracted
|
|
6536
|
+
* @returns {array} returnType: array - an array of all serviceIds
|
|
6537
6537
|
*/
|
|
6538
6538
|
const getServiceIds = createSelector(getServicesStore, serviceState => {
|
|
6539
6539
|
var _a;
|
|
6540
6540
|
return (_a = serviceState === null || serviceState === void 0 ? void 0 : serviceState.allIds) !== null && _a !== void 0 ? _a : [];
|
|
6541
6541
|
}, selectorMemoizationOptions);
|
|
6542
|
-
/**
|
|
6543
|
-
* Gets map services
|
|
6544
|
-
*
|
|
6545
|
-
* Example: services = getServices(store)
|
|
6546
|
-
* @param {object} store store: object - Store object
|
|
6547
|
-
* @returns {object} returnType: ServiceState
|
|
6542
|
+
/**
|
|
6543
|
+
* Gets map services
|
|
6544
|
+
*
|
|
6545
|
+
* Example: services = getServices(store)
|
|
6546
|
+
* @param {object} store store: object - Store object
|
|
6547
|
+
* @returns {object} returnType: ServiceState
|
|
6548
6548
|
*/
|
|
6549
6549
|
const getServices = createSelector(getServicesStore, store => {
|
|
6550
6550
|
var _a;
|
|
6551
6551
|
return (_a = store === null || store === void 0 ? void 0 : store.byId) !== null && _a !== void 0 ? _a : {};
|
|
6552
6552
|
}, selectorMemoizationOptions);
|
|
6553
|
-
/**
|
|
6554
|
-
* Gets the service object by its url
|
|
6555
|
-
*
|
|
6556
|
-
* Example: service = getServiceByName(store, 'serviceName')
|
|
6557
|
-
* @param {object} store store: object - Store object
|
|
6558
|
-
* @returns {ReduxService} returnType: Service
|
|
6553
|
+
/**
|
|
6554
|
+
* Gets the service object by its url
|
|
6555
|
+
*
|
|
6556
|
+
* Example: service = getServiceByName(store, 'serviceName')
|
|
6557
|
+
* @param {object} store store: object - Store object
|
|
6558
|
+
* @returns {ReduxService} returnType: Service
|
|
6559
6559
|
*/
|
|
6560
6560
|
const getServiceByUrl = createSelector(getServicesStore, (state, serviceUrl) => serviceUrl, (serviceState, serviceUrl) => {
|
|
6561
6561
|
if (!serviceState) {
|
|
@@ -6563,26 +6563,26 @@ const getServiceByUrl = createSelector(getServicesStore, (state, serviceUrl) =>
|
|
|
6563
6563
|
}
|
|
6564
6564
|
return Object.values(serviceState.byId).find(service => service.serviceUrl === serviceUrl);
|
|
6565
6565
|
}, selectorMemoizationOptions);
|
|
6566
|
-
/**
|
|
6567
|
-
* Gets the layer from the store using the serviceUrl and layerName
|
|
6568
|
-
*
|
|
6569
|
-
* Example: layers = getLayersFromService(store, 'https://geoservices.knmi.nl/...')
|
|
6570
|
-
* @param {object} store store: object - object from which the layers state will be extracted
|
|
6571
|
-
* @param {string} serviceUrl serviceUrl: string - Url of the service where the layer belongs to
|
|
6572
|
-
* @returns {array} returnType: ServiceLayer[] - All layers within the service object.
|
|
6566
|
+
/**
|
|
6567
|
+
* Gets the layer from the store using the serviceUrl and layerName
|
|
6568
|
+
*
|
|
6569
|
+
* Example: layers = getLayersFromService(store, 'https://geoservices.knmi.nl/...')
|
|
6570
|
+
* @param {object} store store: object - object from which the layers state will be extracted
|
|
6571
|
+
* @param {string} serviceUrl serviceUrl: string - Url of the service where the layer belongs to
|
|
6572
|
+
* @returns {array} returnType: ServiceLayer[] - All layers within the service object.
|
|
6573
6573
|
*/
|
|
6574
6574
|
const getLayersFromServiceSelector = createSelector(getServiceByUrl, service => {
|
|
6575
6575
|
var _a;
|
|
6576
6576
|
return (_a = service === null || service === void 0 ? void 0 : service.layers) !== null && _a !== void 0 ? _a : [];
|
|
6577
6577
|
}, selectorMemoizationOptions);
|
|
6578
|
-
/**
|
|
6579
|
-
* Gets the layer from the store using the serviceUrl and layerName
|
|
6580
|
-
*
|
|
6581
|
-
* Example: layer = getLayerFromService(store, 'https://geoservices.knmi.nl/...', 'radar')
|
|
6582
|
-
* @param {object} store store: object - The application store
|
|
6583
|
-
* @param {string} serviceUrl serviceUrl: string - Url of the service where the layer belongs to
|
|
6584
|
-
* @param {string} layerName layerName: string - Name of the layer in the service
|
|
6585
|
-
* @returns {ServiceLayer} returnType: ServiceLayer - The layer from the service object.
|
|
6578
|
+
/**
|
|
6579
|
+
* Gets the layer from the store using the serviceUrl and layerName
|
|
6580
|
+
*
|
|
6581
|
+
* Example: layer = getLayerFromService(store, 'https://geoservices.knmi.nl/...', 'radar')
|
|
6582
|
+
* @param {object} store store: object - The application store
|
|
6583
|
+
* @param {string} serviceUrl serviceUrl: string - Url of the service where the layer belongs to
|
|
6584
|
+
* @param {string} layerName layerName: string - Name of the layer in the service
|
|
6585
|
+
* @returns {ServiceLayer} returnType: ServiceLayer - The layer from the service object.
|
|
6586
6586
|
*/
|
|
6587
6587
|
const getLayerFromService = createSelector(getLayersFromServiceSelector, (_store, _serviceUrl, layerName) => {
|
|
6588
6588
|
return layerName;
|
|
@@ -6591,14 +6591,14 @@ const getLayerFromService = createSelector(getLayersFromServiceSelector, (_store
|
|
|
6591
6591
|
return serviceLayer.name === layerName;
|
|
6592
6592
|
});
|
|
6593
6593
|
}, selectorMemoizationOptions);
|
|
6594
|
-
/**
|
|
6595
|
-
* Gets the layers stylelist from the servicestore using the serviceUrl and layerName
|
|
6596
|
-
*
|
|
6597
|
-
* Example: layerStyles = getLayerStyles(store, layerService, layerName);
|
|
6598
|
-
* @param {object} store store: object - store from which the layers state will be extracted
|
|
6599
|
-
* @param {string} serviceUrl serviceUrl: string - Url of the service where the layer belongs to
|
|
6600
|
-
* @param {string} layerName layerName: string - Name of the layer in the service
|
|
6601
|
-
* @returns {array} returnType: Style[] - array containing layer styles
|
|
6594
|
+
/**
|
|
6595
|
+
* Gets the layers stylelist from the servicestore using the serviceUrl and layerName
|
|
6596
|
+
*
|
|
6597
|
+
* Example: layerStyles = getLayerStyles(store, layerService, layerName);
|
|
6598
|
+
* @param {object} store store: object - store from which the layers state will be extracted
|
|
6599
|
+
* @param {string} serviceUrl serviceUrl: string - Url of the service where the layer belongs to
|
|
6600
|
+
* @param {string} layerName layerName: string - Name of the layer in the service
|
|
6601
|
+
* @returns {array} returnType: Style[] - array containing layer styles
|
|
6602
6602
|
*/
|
|
6603
6603
|
const getLayerStyles = createSelector(getLayerFromService, layer => {
|
|
6604
6604
|
var _a;
|
|
@@ -6615,22 +6615,22 @@ var selectors$1 = /*#__PURE__*/Object.freeze({
|
|
|
6615
6615
|
getServices: getServices
|
|
6616
6616
|
});
|
|
6617
6617
|
|
|
6618
|
-
/* *
|
|
6619
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6620
|
-
* you may not use this file except in compliance with the License.
|
|
6621
|
-
* You may obtain a copy of the License at
|
|
6622
|
-
*
|
|
6623
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6624
|
-
*
|
|
6625
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
6626
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6627
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6628
|
-
* See the License for the specific language governing permissions and
|
|
6629
|
-
* limitations under the License.
|
|
6630
|
-
*
|
|
6631
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6632
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6633
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6618
|
+
/* *
|
|
6619
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6620
|
+
* you may not use this file except in compliance with the License.
|
|
6621
|
+
* You may obtain a copy of the License at
|
|
6622
|
+
*
|
|
6623
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6624
|
+
*
|
|
6625
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
6626
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6627
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6628
|
+
* See the License for the specific language governing permissions and
|
|
6629
|
+
* limitations under the License.
|
|
6630
|
+
*
|
|
6631
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6632
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6633
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6634
6634
|
* */
|
|
6635
6635
|
|
|
6636
6636
|
var types = /*#__PURE__*/Object.freeze({
|
|
@@ -6755,22 +6755,22 @@ if ($stringify) {
|
|
|
6755
6755
|
});
|
|
6756
6756
|
}
|
|
6757
6757
|
|
|
6758
|
-
/* *
|
|
6759
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6760
|
-
* you may not use this file except in compliance with the License.
|
|
6761
|
-
* You may obtain a copy of the License at
|
|
6762
|
-
*
|
|
6763
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6764
|
-
*
|
|
6765
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
6766
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6767
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6768
|
-
* See the License for the specific language governing permissions and
|
|
6769
|
-
* limitations under the License.
|
|
6770
|
-
*
|
|
6771
|
-
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6772
|
-
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
6773
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6758
|
+
/* *
|
|
6759
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6760
|
+
* you may not use this file except in compliance with the License.
|
|
6761
|
+
* You may obtain a copy of the License at
|
|
6762
|
+
*
|
|
6763
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6764
|
+
*
|
|
6765
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
6766
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6767
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6768
|
+
* See the License for the specific language governing permissions and
|
|
6769
|
+
* limitations under the License.
|
|
6770
|
+
*
|
|
6771
|
+
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6772
|
+
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
6773
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6774
6774
|
* */
|
|
6775
6775
|
const getUserAddedServices = () => {
|
|
6776
6776
|
try {
|
|
@@ -6800,22 +6800,22 @@ const isNoIdService = param => {
|
|
|
6800
6800
|
return !!((serviceParam === null || serviceParam === void 0 ? void 0 : serviceParam.name) && (serviceParam === null || serviceParam === void 0 ? void 0 : serviceParam.url));
|
|
6801
6801
|
};
|
|
6802
6802
|
|
|
6803
|
-
/* *
|
|
6804
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6805
|
-
* you may not use this file except in compliance with the License.
|
|
6806
|
-
* You may obtain a copy of the License at
|
|
6807
|
-
*
|
|
6808
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6809
|
-
*
|
|
6810
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
6811
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6812
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6813
|
-
* See the License for the specific language governing permissions and
|
|
6814
|
-
* limitations under the License.
|
|
6815
|
-
*
|
|
6816
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6817
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6818
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6803
|
+
/* *
|
|
6804
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
6805
|
+
* you may not use this file except in compliance with the License.
|
|
6806
|
+
* You may obtain a copy of the License at
|
|
6807
|
+
*
|
|
6808
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
6809
|
+
*
|
|
6810
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
6811
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
6812
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
6813
|
+
* See the License for the specific language governing permissions and
|
|
6814
|
+
* limitations under the License.
|
|
6815
|
+
*
|
|
6816
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
6817
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
6818
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
6819
6819
|
* */
|
|
6820
6820
|
const {
|
|
6821
6821
|
WmLayerWithoutTimeDimension,
|
|
@@ -6981,12 +6981,12 @@ var storeTestSettings = /*#__PURE__*/Object.freeze({
|
|
|
6981
6981
|
const stepMap = new Map();
|
|
6982
6982
|
/* A map with a list of timers and their dwell */
|
|
6983
6983
|
const timerDwellMap = new Map();
|
|
6984
|
-
/**
|
|
6985
|
-
* Returns the next step for given timerId.
|
|
6986
|
-
* @param timerId The timer id
|
|
6987
|
-
* @param numberOfStepsInAnimation Animation length in steps
|
|
6988
|
-
* @param numStepsToGoForward Amount of steps to go forwards, defaults to 1. Can be positive and negative
|
|
6989
|
-
* @returns
|
|
6984
|
+
/**
|
|
6985
|
+
* Returns the next step for given timerId.
|
|
6986
|
+
* @param timerId The timer id
|
|
6987
|
+
* @param numberOfStepsInAnimation Animation length in steps
|
|
6988
|
+
* @param numStepsToGoForward Amount of steps to go forwards, defaults to 1. Can be positive and negative
|
|
6989
|
+
* @returns
|
|
6990
6990
|
*/
|
|
6991
6991
|
const getNextStep = (timerId, numberOfStepsInAnimation, numStepsToGoForward = 1) => {
|
|
6992
6992
|
const currentStep = getCurrentStep(timerId);
|
|
@@ -6994,12 +6994,12 @@ const getNextStep = (timerId, numberOfStepsInAnimation, numStepsToGoForward = 1)
|
|
|
6994
6994
|
const nextStepClipped = (nextStep % numberOfStepsInAnimation + numberOfStepsInAnimation) % numberOfStepsInAnimation;
|
|
6995
6995
|
return nextStepClipped;
|
|
6996
6996
|
};
|
|
6997
|
-
/**
|
|
6998
|
-
* Handles dwell at the end of the animation loop sequence. The number of steps to wait till proceed can be set by the dwell parameter.
|
|
6999
|
-
* @param timerId The timer id
|
|
7000
|
-
* @param numberOfStepsInAnimation Number of steps in the animation
|
|
7001
|
-
* @param dwell The number of steps to wait at the end of the animation sequence before to continue
|
|
7002
|
-
* @returns
|
|
6997
|
+
/**
|
|
6998
|
+
* Handles dwell at the end of the animation loop sequence. The number of steps to wait till proceed can be set by the dwell parameter.
|
|
6999
|
+
* @param timerId The timer id
|
|
7000
|
+
* @param numberOfStepsInAnimation Number of steps in the animation
|
|
7001
|
+
* @param dwell The number of steps to wait at the end of the animation sequence before to continue
|
|
7002
|
+
* @returns
|
|
7003
7003
|
*/
|
|
7004
7004
|
const handleTimerDwell = (timerId, numberOfStepsInAnimation, dwell = 8) => {
|
|
7005
7005
|
if (dwell > 0) {
|
|
@@ -7018,30 +7018,30 @@ const handleTimerDwell = (timerId, numberOfStepsInAnimation, dwell = 8) => {
|
|
|
7018
7018
|
}
|
|
7019
7019
|
return false;
|
|
7020
7020
|
};
|
|
7021
|
-
/**
|
|
7022
|
-
* Set step for the timerId
|
|
7023
|
-
* @param timerId
|
|
7024
|
-
* @param timerStep
|
|
7021
|
+
/**
|
|
7022
|
+
* Set step for the timerId
|
|
7023
|
+
* @param timerId
|
|
7024
|
+
* @param timerStep
|
|
7025
7025
|
*/
|
|
7026
7026
|
const setStep = (timerId, timerStep) => {
|
|
7027
7027
|
stepMap.set(timerId, timerStep);
|
|
7028
7028
|
};
|
|
7029
|
-
/**
|
|
7030
|
-
* Gets the current step for the timer
|
|
7031
|
-
* @param timerId
|
|
7032
|
-
* @returns
|
|
7029
|
+
/**
|
|
7030
|
+
* Gets the current step for the timer
|
|
7031
|
+
* @param timerId
|
|
7032
|
+
* @returns
|
|
7033
7033
|
*/
|
|
7034
7034
|
const getCurrentStep = timerId => {
|
|
7035
7035
|
return stepMap.get(timerId) || 0;
|
|
7036
7036
|
};
|
|
7037
7037
|
const MAX_NUMBER_STEPS_FORWARD_TO_PREFETCH = 2;
|
|
7038
7038
|
const MAX_NUMBER_OF_PARALLEL_LOADING_IMAGES = 8;
|
|
7039
|
-
/**
|
|
7040
|
-
* This prefetches all images connected to the same sync group as provided timerId
|
|
7041
|
-
* @param timerId The timerId
|
|
7042
|
-
* @param animationListValues List of animation steps in isostring to animate
|
|
7043
|
-
* @param targets List of targets to check
|
|
7044
|
-
* @returns True if all maps are ready to go forward, false if the map has no data to display yet.
|
|
7039
|
+
/**
|
|
7040
|
+
* This prefetches all images connected to the same sync group as provided timerId
|
|
7041
|
+
* @param timerId The timerId
|
|
7042
|
+
* @param animationListValues List of animation steps in isostring to animate
|
|
7043
|
+
* @param targets List of targets to check
|
|
7044
|
+
* @returns True if all maps are ready to go forward, false if the map has no data to display yet.
|
|
7045
7045
|
*/
|
|
7046
7046
|
const prefetchAnimationTargetsForMetronome = (timerId, animationListValues, targets) => {
|
|
7047
7047
|
let timerShouldStepForward = true;
|
|
@@ -7085,12 +7085,12 @@ const prefetchAnimationTargetsForMetronome = (timerId, animationListValues, targ
|
|
|
7085
7085
|
return timerShouldStepForward;
|
|
7086
7086
|
};
|
|
7087
7087
|
|
|
7088
|
-
/**
|
|
7089
|
-
* This handler is triggered by the metronome. An array of timerIds is given as argument.
|
|
7090
|
-
* It will update the animation loop of multiple maps and sliders
|
|
7091
|
-
* It will prefetch images for maps
|
|
7092
|
-
* @param timerIds string[] array of timerIds
|
|
7093
|
-
* @param listenerApi ListenerEffectAPI<CoreAppStore, Dispatch, unknown> listenerApi as received from listener
|
|
7088
|
+
/**
|
|
7089
|
+
* This handler is triggered by the metronome. An array of timerIds is given as argument.
|
|
7090
|
+
* It will update the animation loop of multiple maps and sliders
|
|
7091
|
+
* It will prefetch images for maps
|
|
7092
|
+
* @param timerIds string[] array of timerIds
|
|
7093
|
+
* @param listenerApi ListenerEffectAPI<CoreAppStore, Dispatch, unknown> listenerApi as received from listener
|
|
7094
7094
|
*/
|
|
7095
7095
|
const metronomeHandler = (timerIds, listenerApi) => {
|
|
7096
7096
|
const targetsWithUpdateValue = [];
|
|
@@ -7139,22 +7139,22 @@ metronomeListener.startListening({
|
|
|
7139
7139
|
})
|
|
7140
7140
|
});
|
|
7141
7141
|
|
|
7142
|
-
/* *
|
|
7143
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7144
|
-
* you may not use this file except in compliance with the License.
|
|
7145
|
-
* You may obtain a copy of the License at
|
|
7146
|
-
*
|
|
7147
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
7148
|
-
*
|
|
7149
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
7150
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
7151
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
7152
|
-
* See the License for the specific language governing permissions and
|
|
7153
|
-
* limitations under the License.
|
|
7154
|
-
*
|
|
7155
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
7156
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
7157
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
7142
|
+
/* *
|
|
7143
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
7144
|
+
* you may not use this file except in compliance with the License.
|
|
7145
|
+
* You may obtain a copy of the License at
|
|
7146
|
+
*
|
|
7147
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
7148
|
+
*
|
|
7149
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
7150
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
7151
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
7152
|
+
* See the License for the specific language governing permissions and
|
|
7153
|
+
* limitations under the License.
|
|
7154
|
+
*
|
|
7155
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
7156
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
7157
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
7158
7158
|
* */
|
|
7159
7159
|
const layersListener = createListenerMiddleware();
|
|
7160
7160
|
layersListener.startListening({
|
|
@@ -8619,13 +8619,13 @@ const mapStoreModuleConfig = {
|
|
|
8619
8619
|
|
|
8620
8620
|
const mapStoreActions = Object.assign(Object.assign(Object.assign({}, layerActions), mapActions), serviceActions);
|
|
8621
8621
|
|
|
8622
|
-
/**
|
|
8623
|
-
* Tries to find the layerId's in the other map based on the payload of the action. It works for all layer actions.
|
|
8624
|
-
* @param state
|
|
8625
|
-
* @param mapId
|
|
8626
|
-
* @param targetMapId
|
|
8627
|
-
* @param payload
|
|
8628
|
-
* @returns
|
|
8622
|
+
/**
|
|
8623
|
+
* Tries to find the layerId's in the other map based on the payload of the action. It works for all layer actions.
|
|
8624
|
+
* @param state
|
|
8625
|
+
* @param mapId
|
|
8626
|
+
* @param targetMapId
|
|
8627
|
+
* @param payload
|
|
8628
|
+
* @returns
|
|
8629
8629
|
*/
|
|
8630
8630
|
const getTargetLayerIdFromPayload = (state, mapId, targetMapId, payload) => {
|
|
8631
8631
|
if (!payload) {
|
|
@@ -8647,13 +8647,13 @@ const getTargetLayerIdFromPayload = (state, mapId, targetMapId, payload) => {
|
|
|
8647
8647
|
/* This payload probably does not reference to a layerId */
|
|
8648
8648
|
return null;
|
|
8649
8649
|
};
|
|
8650
|
-
/**
|
|
8651
|
-
* Local helper function used by getLayerDeleteActionsTargets, getLayerActionsTargets, getAddLayerActionsTargets, getTargetLayerIdFromPayload to find the targets
|
|
8652
|
-
* @param state
|
|
8653
|
-
* @param payload
|
|
8654
|
-
* @param actionType
|
|
8655
|
-
* @param sourceMapId
|
|
8656
|
-
* @returns The found targets
|
|
8650
|
+
/**
|
|
8651
|
+
* Local helper function used by getLayerDeleteActionsTargets, getLayerActionsTargets, getAddLayerActionsTargets, getTargetLayerIdFromPayload to find the targets
|
|
8652
|
+
* @param state
|
|
8653
|
+
* @param payload
|
|
8654
|
+
* @param actionType
|
|
8655
|
+
* @param sourceMapId
|
|
8656
|
+
* @returns The found targets
|
|
8657
8657
|
*/
|
|
8658
8658
|
const findTargets = (state, payload, actionType, sourceMapId) => {
|
|
8659
8659
|
const actionPayloads = [];
|
|
@@ -8686,12 +8686,12 @@ const findTargets = (state, payload, actionType, sourceMapId) => {
|
|
|
8686
8686
|
}
|
|
8687
8687
|
return actionPayloads;
|
|
8688
8688
|
};
|
|
8689
|
-
/**
|
|
8690
|
-
* These targets are found for layer actions that work with a layerId like: SetLayerName, SetLayerEnabled, SetLayerOpacity, SetLayerDimension and SetLayerStyle
|
|
8691
|
-
* @param state
|
|
8692
|
-
* @param payload
|
|
8693
|
-
* @param actionType
|
|
8694
|
-
* @returns
|
|
8689
|
+
/**
|
|
8690
|
+
* These targets are found for layer actions that work with a layerId like: SetLayerName, SetLayerEnabled, SetLayerOpacity, SetLayerDimension and SetLayerStyle
|
|
8691
|
+
* @param state
|
|
8692
|
+
* @param payload
|
|
8693
|
+
* @param actionType
|
|
8694
|
+
* @returns
|
|
8695
8695
|
*/
|
|
8696
8696
|
const getLayerActionsTargets = (state, payload, actionType) => {
|
|
8697
8697
|
const mapId = getMapIdFromLayerId(state, payload.layerId);
|
|
@@ -8710,12 +8710,12 @@ const getLayerActionsTargets = (state, payload, actionType) => {
|
|
|
8710
8710
|
});
|
|
8711
8711
|
});
|
|
8712
8712
|
};
|
|
8713
|
-
/**
|
|
8714
|
-
* These targets are found for the layer/map action AddLayer. AddLayer does not have a layerId (because it's new)
|
|
8715
|
-
* @param state
|
|
8716
|
-
* @param payload
|
|
8717
|
-
* @param actionType
|
|
8718
|
-
* @returns
|
|
8713
|
+
/**
|
|
8714
|
+
* These targets are found for the layer/map action AddLayer. AddLayer does not have a layerId (because it's new)
|
|
8715
|
+
* @param state
|
|
8716
|
+
* @param payload
|
|
8717
|
+
* @param actionType
|
|
8718
|
+
* @returns
|
|
8719
8719
|
*/
|
|
8720
8720
|
const getAddLayerActionsTargets = (state, payload, actionType) => {
|
|
8721
8721
|
const foundTargets = findTargets(state, payload, actionType, payload.mapId);
|
|
@@ -8736,12 +8736,12 @@ const getAddLayerActionsTargets = (state, payload, actionType) => {
|
|
|
8736
8736
|
});
|
|
8737
8737
|
});
|
|
8738
8738
|
};
|
|
8739
|
-
/**
|
|
8740
|
-
* These targets are found for the layer/map action DeleteLayer. The layer is already gone, so there is no layerId anymore. Using layerIndex instead.
|
|
8741
|
-
* @param state
|
|
8742
|
-
* @param payload
|
|
8743
|
-
* @param actionType
|
|
8744
|
-
* @returns
|
|
8739
|
+
/**
|
|
8740
|
+
* These targets are found for the layer/map action DeleteLayer. The layer is already gone, so there is no layerId anymore. Using layerIndex instead.
|
|
8741
|
+
* @param state
|
|
8742
|
+
* @param payload
|
|
8743
|
+
* @param actionType
|
|
8744
|
+
* @returns
|
|
8745
8745
|
*/
|
|
8746
8746
|
const getLayerDeleteActionsTargets = (state, payload, actionType) => {
|
|
8747
8747
|
const foundTargets = findTargets(state, payload, actionType, payload.mapId);
|
|
@@ -8753,12 +8753,12 @@ const getLayerDeleteActionsTargets = (state, payload, actionType) => {
|
|
|
8753
8753
|
});
|
|
8754
8754
|
});
|
|
8755
8755
|
};
|
|
8756
|
-
/**
|
|
8757
|
-
* These targets are found for the layer/map action MoveLayer. Here layers are referenced by newIndex and oldIndex.
|
|
8758
|
-
* @param state
|
|
8759
|
-
* @param payload
|
|
8760
|
-
* @param actionType
|
|
8761
|
-
* @returns
|
|
8756
|
+
/**
|
|
8757
|
+
* These targets are found for the layer/map action MoveLayer. Here layers are referenced by newIndex and oldIndex.
|
|
8758
|
+
* @param state
|
|
8759
|
+
* @param payload
|
|
8760
|
+
* @param actionType
|
|
8761
|
+
* @returns
|
|
8762
8762
|
*/
|
|
8763
8763
|
const getLayerMoveActionsTargets = (state, payload, actionType) => {
|
|
8764
8764
|
const foundTargets = findTargets(state, payload, actionType, payload.mapId);
|
|
@@ -8769,12 +8769,12 @@ const getLayerMoveActionsTargets = (state, payload, actionType) => {
|
|
|
8769
8769
|
});
|
|
8770
8770
|
});
|
|
8771
8771
|
};
|
|
8772
|
-
/**
|
|
8773
|
-
* These targets are found for the map action SetAutoLayerId. It needs both a target mapId and layerId
|
|
8774
|
-
* @param state
|
|
8775
|
-
* @param payload
|
|
8776
|
-
* @param actionType
|
|
8777
|
-
* @returns
|
|
8772
|
+
/**
|
|
8773
|
+
* These targets are found for the map action SetAutoLayerId. It needs both a target mapId and layerId
|
|
8774
|
+
* @param state
|
|
8775
|
+
* @param payload
|
|
8776
|
+
* @param actionType
|
|
8777
|
+
* @returns
|
|
8778
8778
|
*/
|
|
8779
8779
|
const getSetAutoLayerIdActionsTargets = (state, payload, actionType) => {
|
|
8780
8780
|
const payloadWithLayerId = Object.assign(Object.assign({}, payload), {
|
|
@@ -8789,12 +8789,12 @@ const getSetAutoLayerIdActionsTargets = (state, payload, actionType) => {
|
|
|
8789
8789
|
};
|
|
8790
8790
|
});
|
|
8791
8791
|
};
|
|
8792
|
-
/**
|
|
8793
|
-
* These targets are found for baselayer actions that work with a mapId like: setBaseLayers
|
|
8794
|
-
* @param state
|
|
8795
|
-
* @param payload
|
|
8796
|
-
* @param actionType
|
|
8797
|
-
* @returns
|
|
8792
|
+
/**
|
|
8793
|
+
* These targets are found for baselayer actions that work with a mapId like: setBaseLayers
|
|
8794
|
+
* @param state
|
|
8795
|
+
* @param payload
|
|
8796
|
+
* @param actionType
|
|
8797
|
+
* @returns
|
|
8798
8798
|
*/
|
|
8799
8799
|
const getMapBaseLayerActionsTargets = (state, payload, actionType) => {
|
|
8800
8800
|
const foundTargets = findTargets(state, payload, actionType, payload.mapId);
|
|
@@ -8961,22 +8961,22 @@ genericListener.startListening({
|
|
|
8961
8961
|
})
|
|
8962
8962
|
});
|
|
8963
8963
|
|
|
8964
|
-
/* *
|
|
8965
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
8966
|
-
* you may not use this file except in compliance with the License.
|
|
8967
|
-
* You may obtain a copy of the License at
|
|
8968
|
-
*
|
|
8969
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
8970
|
-
*
|
|
8971
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
8972
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
8973
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
8974
|
-
* See the License for the specific language governing permissions and
|
|
8975
|
-
* limitations under the License.
|
|
8976
|
-
*
|
|
8977
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
8978
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
8979
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
8964
|
+
/* *
|
|
8965
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
8966
|
+
* you may not use this file except in compliance with the License.
|
|
8967
|
+
* You may obtain a copy of the License at
|
|
8968
|
+
*
|
|
8969
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
8970
|
+
*
|
|
8971
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
8972
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
8973
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
8974
|
+
* See the License for the specific language governing permissions and
|
|
8975
|
+
* limitations under the License.
|
|
8976
|
+
*
|
|
8977
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
8978
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
8979
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
8980
8980
|
* */
|
|
8981
8981
|
const initialState$1 = {};
|
|
8982
8982
|
const slice$1 = createSlice({
|
|
@@ -8995,22 +8995,22 @@ const {
|
|
|
8995
8995
|
} = slice$1;
|
|
8996
8996
|
const routerActions = slice$1.actions;
|
|
8997
8997
|
|
|
8998
|
-
/* *
|
|
8999
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9000
|
-
* you may not use this file except in compliance with the License.
|
|
9001
|
-
* You may obtain a copy of the License at
|
|
9002
|
-
*
|
|
9003
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9004
|
-
*
|
|
9005
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9006
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9007
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9008
|
-
* See the License for the specific language governing permissions and
|
|
9009
|
-
* limitations under the License.
|
|
9010
|
-
*
|
|
9011
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9012
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9013
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
8998
|
+
/* *
|
|
8999
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9000
|
+
* you may not use this file except in compliance with the License.
|
|
9001
|
+
* You may obtain a copy of the License at
|
|
9002
|
+
*
|
|
9003
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9004
|
+
*
|
|
9005
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9006
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9007
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9008
|
+
* See the License for the specific language governing permissions and
|
|
9009
|
+
* limitations under the License.
|
|
9010
|
+
*
|
|
9011
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9012
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9013
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9014
9014
|
* */
|
|
9015
9015
|
// stores navigate hook method to object, so it can be used outside components
|
|
9016
9016
|
const historyDict = {
|
|
@@ -9023,22 +9023,22 @@ var utils = /*#__PURE__*/Object.freeze({
|
|
|
9023
9023
|
historyDict: historyDict
|
|
9024
9024
|
});
|
|
9025
9025
|
|
|
9026
|
-
/* *
|
|
9027
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9028
|
-
* you may not use this file except in compliance with the License.
|
|
9029
|
-
* You may obtain a copy of the License at
|
|
9030
|
-
*
|
|
9031
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9032
|
-
*
|
|
9033
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9034
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9035
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9036
|
-
* See the License for the specific language governing permissions and
|
|
9037
|
-
* limitations under the License.
|
|
9038
|
-
*
|
|
9039
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9040
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
9041
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9026
|
+
/* *
|
|
9027
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9028
|
+
* you may not use this file except in compliance with the License.
|
|
9029
|
+
* You may obtain a copy of the License at
|
|
9030
|
+
*
|
|
9031
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9032
|
+
*
|
|
9033
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9034
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9035
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9036
|
+
* See the License for the specific language governing permissions and
|
|
9037
|
+
* limitations under the License.
|
|
9038
|
+
*
|
|
9039
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9040
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
9041
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9042
9042
|
* */
|
|
9043
9043
|
const routerListener = createListenerMiddleware();
|
|
9044
9044
|
routerListener.startListening({
|
|
@@ -9051,22 +9051,22 @@ routerListener.startListening({
|
|
|
9051
9051
|
})
|
|
9052
9052
|
});
|
|
9053
9053
|
|
|
9054
|
-
/* *
|
|
9055
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9056
|
-
* you may not use this file except in compliance with the License.
|
|
9057
|
-
* You may obtain a copy of the License at
|
|
9058
|
-
*
|
|
9059
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9060
|
-
*
|
|
9061
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9062
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9063
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9064
|
-
* See the License for the specific language governing permissions and
|
|
9065
|
-
* limitations under the License.
|
|
9066
|
-
*
|
|
9067
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9068
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9069
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9054
|
+
/* *
|
|
9055
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9056
|
+
* you may not use this file except in compliance with the License.
|
|
9057
|
+
* You may obtain a copy of the License at
|
|
9058
|
+
*
|
|
9059
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9060
|
+
*
|
|
9061
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9062
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9063
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9064
|
+
* See the License for the specific language governing permissions and
|
|
9065
|
+
* limitations under the License.
|
|
9066
|
+
*
|
|
9067
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9068
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9069
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9070
9070
|
* */
|
|
9071
9071
|
const routerModuleConfig = {
|
|
9072
9072
|
id: 'router',
|
|
@@ -9236,22 +9236,22 @@ const {
|
|
|
9236
9236
|
} = slice;
|
|
9237
9237
|
const drawtoolActions = slice.actions;
|
|
9238
9238
|
|
|
9239
|
-
/* *
|
|
9240
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9241
|
-
* you may not use this file except in compliance with the License.
|
|
9242
|
-
* You may obtain a copy of the License at
|
|
9243
|
-
*
|
|
9244
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9245
|
-
*
|
|
9246
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9247
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9248
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9249
|
-
* See the License for the specific language governing permissions and
|
|
9250
|
-
* limitations under the License.
|
|
9251
|
-
*
|
|
9252
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9253
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9254
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9239
|
+
/* *
|
|
9240
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9241
|
+
* you may not use this file except in compliance with the License.
|
|
9242
|
+
* You may obtain a copy of the License at
|
|
9243
|
+
*
|
|
9244
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9245
|
+
*
|
|
9246
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9247
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9248
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9249
|
+
* See the License for the specific language governing permissions and
|
|
9250
|
+
* limitations under the License.
|
|
9251
|
+
*
|
|
9252
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9253
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9254
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9255
9255
|
* */
|
|
9256
9256
|
const getDrawingtoolStore = store => {
|
|
9257
9257
|
if (store && store.drawingtools) {
|
|
@@ -9507,22 +9507,22 @@ drawingToolListener.startListening({
|
|
|
9507
9507
|
})
|
|
9508
9508
|
});
|
|
9509
9509
|
|
|
9510
|
-
/* *
|
|
9511
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9512
|
-
* you may not use this file except in compliance with the License.
|
|
9513
|
-
* You may obtain a copy of the License at
|
|
9514
|
-
*
|
|
9515
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9516
|
-
*
|
|
9517
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9518
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9519
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9520
|
-
* See the License for the specific language governing permissions and
|
|
9521
|
-
* limitations under the License.
|
|
9522
|
-
*
|
|
9523
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9524
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9525
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9510
|
+
/* *
|
|
9511
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9512
|
+
* you may not use this file except in compliance with the License.
|
|
9513
|
+
* You may obtain a copy of the License at
|
|
9514
|
+
*
|
|
9515
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9516
|
+
*
|
|
9517
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9518
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9519
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9520
|
+
* See the License for the specific language governing permissions and
|
|
9521
|
+
* limitations under the License.
|
|
9522
|
+
*
|
|
9523
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9524
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9525
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9526
9526
|
* */
|
|
9527
9527
|
const drawtoolModuleConfig = {
|
|
9528
9528
|
id: 'drawtool-module',
|
|
@@ -9532,22 +9532,22 @@ const drawtoolModuleConfig = {
|
|
|
9532
9532
|
middlewares: [drawingToolListener.middleware]
|
|
9533
9533
|
};
|
|
9534
9534
|
|
|
9535
|
-
/* *
|
|
9536
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9537
|
-
* you may not use this file except in compliance with the License.
|
|
9538
|
-
* You may obtain a copy of the License at
|
|
9539
|
-
*
|
|
9540
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9541
|
-
*
|
|
9542
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9543
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9544
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9545
|
-
* See the License for the specific language governing permissions and
|
|
9546
|
-
* limitations under the License.
|
|
9547
|
-
*
|
|
9548
|
-
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9549
|
-
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9550
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9535
|
+
/* *
|
|
9536
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9537
|
+
* you may not use this file except in compliance with the License.
|
|
9538
|
+
* You may obtain a copy of the License at
|
|
9539
|
+
*
|
|
9540
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9541
|
+
*
|
|
9542
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9543
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9544
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9545
|
+
* See the License for the specific language governing permissions and
|
|
9546
|
+
* limitations under the License.
|
|
9547
|
+
*
|
|
9548
|
+
* Copyright 2023 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9549
|
+
* Copyright 2023 - Finnish Meteorological Institute (FMI)
|
|
9550
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9551
9551
|
* */
|
|
9552
9552
|
const getSingularDrawtoolDrawLayerId = mapId => `drawlayer-${mapId}`;
|
|
9553
9553
|
|
|
@@ -9818,22 +9818,22 @@ var storeTestUtils = /*#__PURE__*/Object.freeze({
|
|
|
9818
9818
|
webmapStateWithAddedLayer: webmapStateWithAddedLayer
|
|
9819
9819
|
});
|
|
9820
9820
|
|
|
9821
|
-
/* *
|
|
9822
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9823
|
-
* you may not use this file except in compliance with the License.
|
|
9824
|
-
* You may obtain a copy of the License at
|
|
9825
|
-
*
|
|
9826
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9827
|
-
*
|
|
9828
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9829
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9830
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9831
|
-
* See the License for the specific language governing permissions and
|
|
9832
|
-
* limitations under the License.
|
|
9833
|
-
*
|
|
9834
|
-
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9835
|
-
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
9836
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9821
|
+
/* *
|
|
9822
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9823
|
+
* you may not use this file except in compliance with the License.
|
|
9824
|
+
* You may obtain a copy of the License at
|
|
9825
|
+
*
|
|
9826
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9827
|
+
*
|
|
9828
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9829
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9830
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9831
|
+
* See the License for the specific language governing permissions and
|
|
9832
|
+
* limitations under the License.
|
|
9833
|
+
*
|
|
9834
|
+
* Copyright 2024 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9835
|
+
* Copyright 2024 - Finnish Meteorological Institute (FMI)
|
|
9836
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9837
9837
|
* */
|
|
9838
9838
|
const syncGroupsListener = createListenerMiddleware();
|
|
9839
9839
|
syncGroupsListener.startListening({
|
|
@@ -9893,22 +9893,22 @@ const synchronizationGroupConfig = {
|
|
|
9893
9893
|
middlewares: [genericListener.middleware, syncGroupsListener.middleware]
|
|
9894
9894
|
};
|
|
9895
9895
|
|
|
9896
|
-
/* *
|
|
9897
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9898
|
-
* you may not use this file except in compliance with the License.
|
|
9899
|
-
* You may obtain a copy of the License at
|
|
9900
|
-
*
|
|
9901
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9902
|
-
*
|
|
9903
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9904
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9905
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9906
|
-
* See the License for the specific language governing permissions and
|
|
9907
|
-
* limitations under the License.
|
|
9908
|
-
*
|
|
9909
|
-
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9910
|
-
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
9911
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9896
|
+
/* *
|
|
9897
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9898
|
+
* you may not use this file except in compliance with the License.
|
|
9899
|
+
* You may obtain a copy of the License at
|
|
9900
|
+
*
|
|
9901
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9902
|
+
*
|
|
9903
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9904
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9905
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9906
|
+
* See the License for the specific language governing permissions and
|
|
9907
|
+
* limitations under the License.
|
|
9908
|
+
*
|
|
9909
|
+
* Copyright 2022 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9910
|
+
* Copyright 2022 - Finnish Meteorological Institute (FMI)
|
|
9911
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9912
9912
|
* */
|
|
9913
9913
|
const uiModuleConfig = {
|
|
9914
9914
|
id: 'ui-module',
|
|
@@ -9917,22 +9917,22 @@ const uiModuleConfig = {
|
|
|
9917
9917
|
}
|
|
9918
9918
|
};
|
|
9919
9919
|
|
|
9920
|
-
/* *
|
|
9921
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9922
|
-
* you may not use this file except in compliance with the License.
|
|
9923
|
-
* You may obtain a copy of the License at
|
|
9924
|
-
*
|
|
9925
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9926
|
-
*
|
|
9927
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
9928
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9929
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9930
|
-
* See the License for the specific language governing permissions and
|
|
9931
|
-
* limitations under the License.
|
|
9932
|
-
*
|
|
9933
|
-
* Copyright 2021 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9934
|
-
* Copyright 2021 - Finnish Meteorological Institute (FMI)
|
|
9935
|
-
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9920
|
+
/* *
|
|
9921
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9922
|
+
* you may not use this file except in compliance with the License.
|
|
9923
|
+
* You may obtain a copy of the License at
|
|
9924
|
+
*
|
|
9925
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9926
|
+
*
|
|
9927
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
9928
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
9929
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
9930
|
+
* See the License for the specific language governing permissions and
|
|
9931
|
+
* limitations under the License.
|
|
9932
|
+
*
|
|
9933
|
+
* Copyright 2021 - Koninklijk Nederlands Meteorologisch Instituut (KNMI)
|
|
9934
|
+
* Copyright 2021 - Finnish Meteorological Institute (FMI)
|
|
9935
|
+
* Copyright 2024 - The Norwegian Meteorological Institute (MET Norway)
|
|
9936
9936
|
* */
|
|
9937
9937
|
const coreModuleConfig = [mapStoreModuleConfig, synchronizationGroupConfig, uiModuleConfig, drawtoolModuleConfig];
|
|
9938
9938
|
|
|
@@ -9940,11 +9940,11 @@ const createCustomStore = () => createStore();
|
|
|
9940
9940
|
const WrapperWithModules = withEggs(coreModuleConfig)(({
|
|
9941
9941
|
children
|
|
9942
9942
|
}) => children);
|
|
9943
|
-
/**
|
|
9944
|
-
* A Provider component which provides the GeoWeb theme and store for the core.
|
|
9945
|
-
* Note: Should only be used with core components, as the provided store is only for core.
|
|
9946
|
-
* @param children
|
|
9947
|
-
* @returns
|
|
9943
|
+
/**
|
|
9944
|
+
* A Provider component which provides the GeoWeb theme and store for the core.
|
|
9945
|
+
* Note: Should only be used with core components, as the provided store is only for core.
|
|
9946
|
+
* @param children
|
|
9947
|
+
* @returns
|
|
9948
9948
|
*/
|
|
9949
9949
|
const StoreProvider = ({
|
|
9950
9950
|
children,
|