@opengeoweb/webmap-react 19.3.0 → 19.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +7 -1
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -7486,12 +7486,18 @@ var TimeAwareWMTSLayer = function TimeAwareWMTSLayer(_ref) {
|
|
|
7486
7486
|
map.addLayer(layer);
|
|
7487
7487
|
setLayer(layer);
|
|
7488
7488
|
setSource(source);
|
|
7489
|
+
if (wmLayer) {
|
|
7490
|
+
wmLayer.olSource = source;
|
|
7491
|
+
}
|
|
7489
7492
|
return function () {
|
|
7490
7493
|
map.removeLayer(layer);
|
|
7491
7494
|
setLayer(undefined);
|
|
7495
|
+
if (wmLayer) {
|
|
7496
|
+
wmLayer.olSource = null;
|
|
7497
|
+
}
|
|
7492
7498
|
};
|
|
7493
7499
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
7494
|
-
}, [map, TimeAwareWMTSLayer]);
|
|
7500
|
+
}, [map, TimeAwareWMTSLayer, wmLayer]);
|
|
7495
7501
|
useEffect(function () {
|
|
7496
7502
|
if (dimensions) {
|
|
7497
7503
|
source === null || source === void 0 || source.updateDimensions(WMTSDimensionsFromDimensions(dimensions));
|