@eeacms/volto-marine-policy 2.0.32 → 2.0.34
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/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,14 @@ All notable changes to this project will be documented in this file. Dates are d
|
|
|
4
4
|
|
|
5
5
|
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
6
6
|
|
|
7
|
+
### [2.0.34](https://github.com/eea/volto-marine-policy/compare/2.0.33...2.0.34) - 29 October 2025
|
|
8
|
+
|
|
9
|
+
#### :bug: Bug Fixes
|
|
10
|
+
|
|
11
|
+
- fix: fix demo sites explorer base layer [laszlocseh - [`567da96`](https://github.com/eea/volto-marine-policy/commit/567da96a3ca7dd017467de768d4068919eb813a8)]
|
|
12
|
+
|
|
13
|
+
### [2.0.33](https://github.com/eea/volto-marine-policy/compare/2.0.32...2.0.33) - 22 October 2025
|
|
14
|
+
|
|
7
15
|
### [2.0.32](https://github.com/eea/volto-marine-policy/compare/2.0.31...2.0.32) - 21 October 2025
|
|
8
16
|
|
|
9
17
|
#### :rocket: New Features
|
package/package.json
CHANGED
|
@@ -62,7 +62,6 @@ function DemoSitesMap(props) {
|
|
|
62
62
|
// LAYERS: 'OSMBlossomComposite', OSMCartoComposite, OSMPositronComposite
|
|
63
63
|
LAYERS: 'OSMPositronComposite',
|
|
64
64
|
TILED: true,
|
|
65
|
-
DPI: 192,
|
|
66
65
|
},
|
|
67
66
|
serverType: 'geoserver',
|
|
68
67
|
transition: 0,
|
|
@@ -136,8 +135,8 @@ function DemoSitesMap(props) {
|
|
|
136
135
|
}, [map, selectedCase, resetMapButtonClass, setResetMapButtonClass, ol]);
|
|
137
136
|
|
|
138
137
|
const clusterStyle = React.useMemo(
|
|
139
|
-
() => selectedClusterStyle({ selectedCase, ol }),
|
|
140
|
-
[selectedCase, ol],
|
|
138
|
+
() => selectedClusterStyle({ selectedCase, ol, enableMarineMO }),
|
|
139
|
+
[selectedCase, ol, enableMarineMO],
|
|
141
140
|
);
|
|
142
141
|
|
|
143
142
|
const MapWithSelection = React.useMemo(() => Map, []);
|
|
@@ -151,6 +150,7 @@ function DemoSitesMap(props) {
|
|
|
151
150
|
showFullExtent: true,
|
|
152
151
|
zoom: 3.4,
|
|
153
152
|
}}
|
|
153
|
+
pixelRatio={1}
|
|
154
154
|
// pixelRatio={window.devicePixelRatio || 1}
|
|
155
155
|
// controls={ol.control.defaults({ attribution: false })}
|
|
156
156
|
>
|
|
@@ -209,7 +209,7 @@ function DemoSitesMap(props) {
|
|
|
209
209
|
) : null;
|
|
210
210
|
}
|
|
211
211
|
|
|
212
|
-
const selectedClusterStyle = ({ selectedFeature, ol }) => {
|
|
212
|
+
const selectedClusterStyle = ({ selectedFeature, ol, enableMarineMO }) => {
|
|
213
213
|
function _clusterStyle(feature, selectedFeature) {
|
|
214
214
|
const size = feature.get('features').length;
|
|
215
215
|
let clusterStyle = styleCache[size];
|
|
@@ -237,25 +237,38 @@ const selectedClusterStyle = ({ selectedFeature, ol }) => {
|
|
|
237
237
|
}
|
|
238
238
|
// set size === 1 to enable clusterization
|
|
239
239
|
if (size) {
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
radius: radius,
|
|
250
|
-
fill: new ol.style.Fill({
|
|
251
|
-
color: '#fff',
|
|
240
|
+
if (enableMarineMO) {
|
|
241
|
+
return new ol.style.Style({
|
|
242
|
+
image: new ol.style.Icon({
|
|
243
|
+
anchor: [0.5, 1],
|
|
244
|
+
// size: [52, 52],
|
|
245
|
+
// offset: [52, 0],
|
|
246
|
+
// opacity: 1,
|
|
247
|
+
scale: 0.8,
|
|
248
|
+
src: '/marine/europe-seas/eu-mission-restore-our-oceans-and-water/icon-point.png/@@images/image/tiny',
|
|
252
249
|
}),
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
250
|
+
});
|
|
251
|
+
} else {
|
|
252
|
+
// let color = feature.values_.features[0].values_['color'];
|
|
253
|
+
let color = '#0179cf';
|
|
254
|
+
let width = feature.values_.features[0].values_['width'];
|
|
255
|
+
let radius = feature.values_.features[0].values_['radius'];
|
|
256
|
+
// console.log(color)
|
|
257
|
+
// let color = '#0083E0'; // #0083E0 #50B0A4
|
|
258
|
+
|
|
259
|
+
return new ol.style.Style({
|
|
260
|
+
image: new ol.style.Circle({
|
|
261
|
+
radius: radius,
|
|
262
|
+
fill: new ol.style.Fill({
|
|
263
|
+
color: '#fff',
|
|
264
|
+
}),
|
|
265
|
+
stroke: new ol.style.Stroke({
|
|
266
|
+
color: color,
|
|
267
|
+
width: width,
|
|
268
|
+
}),
|
|
256
269
|
}),
|
|
257
|
-
})
|
|
258
|
-
}
|
|
270
|
+
});
|
|
271
|
+
}
|
|
259
272
|
} else {
|
|
260
273
|
return clusterStyle;
|
|
261
274
|
}
|