@eeacms/volto-clms-theme 1.1.88 → 1.1.89
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 +12 -0
- package/package.json +1 -2
- package/src/components/CLMSDatasetDetailView/DownloadDataSetContent.jsx +5 -7
- package/src/components/CLMSDownloadCartView/AreaNaming.jsx +2 -53
- package/src/components/CLMSDownloadCartView/CLMSCartContent.jsx +3 -2
- package/src/components/CLMSDownloadCartView/cart-table.less +1 -36
- package/src/components/CLMSMapViewerView/CLMSMapViewerView.jsx +54 -57
- package/src/components/CLMSTechnicalLibraryAdminInfo/CLMSTechnicalLibraryAdminInfo.jsx +1 -3
- package/src/components/CclModal/CclModal.jsx +0 -1
- package/theme/clms/img/lat_lon.png +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,18 @@ 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
|
+
### [1.1.89](https://github.com/eea/volto-clms-theme/compare/1.1.88...1.1.89) - 1 December 2023
|
|
8
|
+
|
|
9
|
+
#### :hammer_and_wrench: Others
|
|
10
|
+
|
|
11
|
+
- Revert "cart modal created" [Mikel Larreategi - [`30c4ede`](https://github.com/eea/volto-clms-theme/commit/30c4edef70c5af090591afdb4b9c75465b07179c)]
|
|
12
|
+
- Revert "style fixes in cart modal" [Mikel Larreategi - [`96f91e5`](https://github.com/eea/volto-clms-theme/commit/96f91e572010aee49611bc0aec3157c20862eddd)]
|
|
13
|
+
- Revert "fix: CLMS-2458 last style fixes" [Mikel Larreategi - [`2f77987`](https://github.com/eea/volto-clms-theme/commit/2f779878ed90a4de604f8651868533ba952b5c80)]
|
|
14
|
+
- Revert "trigger color" [Mikel Larreategi - [`609fbe8`](https://github.com/eea/volto-clms-theme/commit/609fbe810c137be11e0d56b16c868cc36bd91e61)]
|
|
15
|
+
- Revert "zoom in cart modal" [Mikel Larreategi - [`99cc45b`](https://github.com/eea/volto-clms-theme/commit/99cc45b91c52d0dae180d616c4a4b8d5a10b733a)]
|
|
16
|
+
- Revert "do not show Categorization text if no item inside" [Mikel Larreategi - [`d9c51dc`](https://github.com/eea/volto-clms-theme/commit/d9c51dc43aaf791eeee7c6d7da1837eaa95c22d4)]
|
|
17
|
+
- Revert "fix: CLMS-2833" [Mikel Larreategi - [`ed36231`](https://github.com/eea/volto-clms-theme/commit/ed36231bad2a268a7655767bc887bb7e52187418)]
|
|
18
|
+
- Revert "fix: remove cart length comparation to copmose the correct cart data" [Mikel Larreategi - [`f089ddf`](https://github.com/eea/volto-clms-theme/commit/f089ddf10bc01cafc4d87a963eb1567513844079)]
|
|
7
19
|
### [1.1.88](https://github.com/eea/volto-clms-theme/compare/1.1.87...1.1.88) - 1 December 2023
|
|
8
20
|
|
|
9
21
|
#### :bug: Bug Fixes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eeacms/volto-clms-theme",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.89",
|
|
4
4
|
"description": "volto-clms-theme: Volto theme for CLMS site",
|
|
5
5
|
"main": "src/index.js",
|
|
6
6
|
"author": "CodeSyntax for the European Environment Agency",
|
|
@@ -61,7 +61,6 @@
|
|
|
61
61
|
"react-native-mime-types": "2.3.0",
|
|
62
62
|
"react-slick": "0.28.1",
|
|
63
63
|
"react-svg": "14.0.4",
|
|
64
|
-
"react-zoom-pan-pinch": "3.3.0",
|
|
65
64
|
"slick-carousel": "1.8.1",
|
|
66
65
|
"validator": "13.7.0",
|
|
67
66
|
"volto-cookie-banner": "2.1.0",
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { FormattedMessage } from 'react-intl';
|
|
3
3
|
import { useSelector } from 'react-redux';
|
|
4
|
+
import { useLocation } from 'react-router-dom';
|
|
4
5
|
|
|
5
6
|
import CclButton from '@eeacms/volto-clms-theme/components/CclButton/CclButton';
|
|
6
7
|
import CclDownloadTable from '@eeacms/volto-clms-theme/components/CclDownloadTable/CclDownloadTable';
|
|
@@ -8,8 +9,9 @@ import CclLoginModal from '@eeacms/volto-clms-theme/components/CclLoginModal/Ccl
|
|
|
8
9
|
import { StringToHTML } from '@eeacms/volto-clms-theme/components/CclUtils';
|
|
9
10
|
|
|
10
11
|
const DownloadDataSetContent = (data, token) => {
|
|
12
|
+
const location = useLocation();
|
|
13
|
+
|
|
11
14
|
const user = useSelector((state) => state?.users?.user);
|
|
12
|
-
const locale = useSelector((state) => state?.intl?.locale);
|
|
13
15
|
|
|
14
16
|
return (
|
|
15
17
|
<div>
|
|
@@ -34,15 +36,11 @@ const DownloadDataSetContent = (data, token) => {
|
|
|
34
36
|
)}
|
|
35
37
|
{user?.['@id'] ? (
|
|
36
38
|
data.mapviewer_istimeseries === true ? (
|
|
37
|
-
<CclButton
|
|
38
|
-
url={'/' + locale + '/map-viewer?dataset=' + data?.UID}
|
|
39
|
-
>
|
|
39
|
+
<CclButton url={location.pathname + '/download-by-area'}>
|
|
40
40
|
Go to download by area and time
|
|
41
41
|
</CclButton>
|
|
42
42
|
) : (
|
|
43
|
-
<CclButton
|
|
44
|
-
url={'/' + locale + '/map-viewer?dataset=' + data?.UID}
|
|
45
|
-
>
|
|
43
|
+
<CclButton url={location.pathname + '/download-by-area'}>
|
|
46
44
|
Go to download by area
|
|
47
45
|
</CclButton>
|
|
48
46
|
)
|
|
@@ -1,63 +1,12 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { TransformWrapper, TransformComponent } from 'react-zoom-pan-pinch';
|
|
3
1
|
import { Label } from 'semantic-ui-react';
|
|
4
|
-
|
|
5
|
-
import LatLonImg from '@eeacms/volto-clms-theme/../theme/clms/img/lat_lon.png';
|
|
6
|
-
import CclModal from '@eeacms/volto-clms-theme/components/CclModal/CclModal';
|
|
7
|
-
|
|
8
2
|
export const AreaNaming = (areaProps) => {
|
|
9
3
|
const { item } = areaProps;
|
|
10
4
|
switch (item?.area?.type) {
|
|
11
5
|
case 'polygon':
|
|
12
6
|
return (
|
|
13
7
|
<>
|
|
14
|
-
<
|
|
15
|
-
|
|
16
|
-
trigger={<span className="cart-modal-trigger">Bounding Box</span>}
|
|
17
|
-
size={'medium'}
|
|
18
|
-
>
|
|
19
|
-
<div className="image-modal">
|
|
20
|
-
<TransformWrapper>
|
|
21
|
-
{({ zoomIn, zoomOut, resetTransform, ...rest }) => (
|
|
22
|
-
<React.Fragment>
|
|
23
|
-
<div className="tools">
|
|
24
|
-
<button
|
|
25
|
-
className="ccl-button ccl-button--default"
|
|
26
|
-
onClick={() => zoomIn()}
|
|
27
|
-
>
|
|
28
|
-
Zoom in
|
|
29
|
-
</button>
|
|
30
|
-
<button
|
|
31
|
-
className="ccl-button ccl-button--default"
|
|
32
|
-
onClick={() => zoomOut()}
|
|
33
|
-
>
|
|
34
|
-
Zoom out
|
|
35
|
-
</button>
|
|
36
|
-
<button
|
|
37
|
-
className="ccl-button ccl-button--default"
|
|
38
|
-
onClick={() => resetTransform()}
|
|
39
|
-
>
|
|
40
|
-
Reset zoom
|
|
41
|
-
</button>
|
|
42
|
-
</div>
|
|
43
|
-
<TransformComponent>
|
|
44
|
-
<img src={LatLonImg} alt={'Lat Lon World'} />
|
|
45
|
-
</TransformComponent>
|
|
46
|
-
</React.Fragment>
|
|
47
|
-
)}
|
|
48
|
-
</TransformWrapper>
|
|
49
|
-
<span className="modal-cart-bounding-boxes">
|
|
50
|
-
<span className="cart-bounding-box-row">
|
|
51
|
-
<Label>{`N: ${item?.area.value[1].toFixed(1)}º`}</Label>
|
|
52
|
-
<Label>{`E: ${item?.area.value[2].toFixed(1)}º`}</Label>
|
|
53
|
-
{/* </span>
|
|
54
|
-
<span className="cart-bounding-box-row"> */}
|
|
55
|
-
<Label>{`S: ${item?.area.value[3].toFixed(1)}º`}</Label>
|
|
56
|
-
<Label>{`W: ${item?.area.value[0].toFixed(1)}º`}</Label>
|
|
57
|
-
</span>
|
|
58
|
-
</span>
|
|
59
|
-
</div>
|
|
60
|
-
</CclModal>
|
|
8
|
+
<span>Bounding Box</span>
|
|
9
|
+
<br />
|
|
61
10
|
<span className="cart-bounding-boxes">
|
|
62
11
|
<span className="cart-bounding-box-row">
|
|
63
12
|
<Label>{`N: ${item?.area.value[1].toFixed(1)}º`}</Label>
|
|
@@ -102,6 +102,7 @@ const CLMSCartContent = (props) => {
|
|
|
102
102
|
if (
|
|
103
103
|
datasets_items?.length > 0 &&
|
|
104
104
|
cart.length > 0 &&
|
|
105
|
+
cart.length !== newCart.length &&
|
|
105
106
|
((localsessionNutsIDList.length > 0 && nutsnames.loaded) ||
|
|
106
107
|
!nutsnames.loading)
|
|
107
108
|
) {
|
|
@@ -322,8 +323,8 @@ const CLMSCartContent = (props) => {
|
|
|
322
323
|
<strong>Source: </strong>
|
|
323
324
|
{contentOrDash(item?.source)}
|
|
324
325
|
</div>
|
|
325
|
-
<div className="mb-2
|
|
326
|
-
<strong
|
|
326
|
+
<div className="mb-2">
|
|
327
|
+
<strong>Area: </strong>
|
|
327
328
|
<AreaNaming item={item} />
|
|
328
329
|
</div>
|
|
329
330
|
|
|
@@ -9,8 +9,7 @@ td li {
|
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
.cart-bounding-boxes {
|
|
12
|
-
margin-top:
|
|
13
|
-
margin-left: -8.7rem;
|
|
12
|
+
margin-top: 0.8rem;
|
|
14
13
|
}
|
|
15
14
|
|
|
16
15
|
.cart-bounding-boxes .ui.label {
|
|
@@ -19,17 +18,6 @@ td li {
|
|
|
19
18
|
color: #273b4b;
|
|
20
19
|
}
|
|
21
20
|
|
|
22
|
-
.modal-cart-bounding-boxes .ui.label {
|
|
23
|
-
padding: 0;
|
|
24
|
-
background-color: transparent;
|
|
25
|
-
color: #273b4b;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.modal-cart-bounding-boxes {
|
|
29
|
-
display: flex;
|
|
30
|
-
justify-content: center;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
21
|
.ui.selection.dropdown {
|
|
34
22
|
width: 95%;
|
|
35
23
|
min-height: 1.3rem !important;
|
|
@@ -83,26 +71,3 @@ div.mb-2 {
|
|
|
83
71
|
.ui.table td.table-td-timeseries {
|
|
84
72
|
text-align: center;
|
|
85
73
|
}
|
|
86
|
-
|
|
87
|
-
.cart-modal-trigger {
|
|
88
|
-
border-color: #a0b128;
|
|
89
|
-
color: #a0b128;
|
|
90
|
-
cursor: pointer;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
.cart-area {
|
|
94
|
-
display: flex;
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
.modal-trigger {
|
|
98
|
-
margin: 0 !important;
|
|
99
|
-
}
|
|
100
|
-
|
|
101
|
-
.cart-area-text {
|
|
102
|
-
margin-right: 0.2rem;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
.tools {
|
|
106
|
-
margin-bottom: 1.5rem;
|
|
107
|
-
margin-inline: 6rem;
|
|
108
|
-
}
|
|
@@ -3,12 +3,11 @@ import { defineMessages, useIntl } from 'react-intl';
|
|
|
3
3
|
import { useDispatch, useSelector } from 'react-redux';
|
|
4
4
|
|
|
5
5
|
import { Forbidden, Unauthorized } from '@plone/volto/components';
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
import { Helmet, getBaseUrl } from '@plone/volto/helpers';
|
|
7
|
+
import { MapViewer } from '@eeacms/volto-arcgis-block/components';
|
|
8
|
+
import config from '@eeacms/volto-arcgis-block/components/MapViewer/config';
|
|
9
|
+
import { helmetTitle } from '@eeacms/volto-clms-theme/components/CclUtils';
|
|
10
10
|
import useCartState from '@eeacms/volto-clms-utils/cart/useCartState';
|
|
11
|
-
import { Redirect } from 'react-router-dom';
|
|
12
11
|
|
|
13
12
|
import { getExtraBreadcrumbItems } from '../../actions';
|
|
14
13
|
|
|
@@ -21,7 +20,6 @@ const CLMSMapViewerView = (props) => {
|
|
|
21
20
|
const dispatch = useDispatch();
|
|
22
21
|
const { isLoggedIn } = useCartState();
|
|
23
22
|
const content = useSelector((state) => state.content.data);
|
|
24
|
-
const locale = useSelector((state) => state?.intl?.locale);
|
|
25
23
|
|
|
26
24
|
const { formatMessage } = useIntl();
|
|
27
25
|
const messages = defineMessages({
|
|
@@ -52,45 +50,45 @@ const CLMSMapViewerView = (props) => {
|
|
|
52
50
|
props.location.pathname,
|
|
53
51
|
]);
|
|
54
52
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
53
|
+
const config_by_area = {
|
|
54
|
+
...config,
|
|
55
|
+
DownloadByArea: true,
|
|
56
|
+
Components: [
|
|
57
|
+
// Area Information
|
|
58
|
+
{
|
|
59
|
+
ComponentTitle: 'Custom detail element',
|
|
60
|
+
Products: [
|
|
61
|
+
{
|
|
62
|
+
ProductTitle: 'Test detail',
|
|
63
|
+
Datasets: [
|
|
64
|
+
{
|
|
65
|
+
DatasetId: 'copernicus_v_3035_10_m_cz-2012_p_2010-2014_v01_r00',
|
|
66
|
+
DatasetTitle: 'Coastal Zones 2012',
|
|
67
|
+
DatasetDescription:
|
|
68
|
+
'The Coastal Zones (CZ) LC/LU product for 2012 is providing a detailed Land Cover / Land Use (LC/ LU) dataset for areas along the coastline of the EEA38 countries and the United Kingdom, with reference year 2012 for the classification. This product monitors landscape dynamics in European coastal territory to an inland depth of 10 km with a total area of approximately 730,000 km², with all the relevant areas (estuaries, coastal lowlands, nature reserves). The production of the coastal zone layers was coordinated by the European Environment Agency (EEA) in the frame of the EU Copernicus programme, as part of the Copernicus Land Monitoring Service (CLMS) Local Component.The Coastal Zones product covers a buffer zone of coastline derived from EU-Hydro v1.1. Land Cover/Land Use (LC/LU) layer is extracted from Very High Resolution (VHR) satellite data and other available data. The class definitions follow the pre-defined nomenclature on the basis of Mapping and Assessment of Ecosystems and their Services (MAES) typology of ecosystems (Level 1 to Level 4) and CORINE Land Cover adapted to the specific characteristics of coastal zones. The classification provides 71 distinct thematic classes with a Minimum Mapping Unit (MMU) of 0.5 ha and a Minimum Mapping Width (MMW) of 10 m. The product is available for the 2012 and 2018 reference year including change mapping.This CZ dataset is distributed in vector format, in a single OGC GeoPackage SQLite file covering the area of interest.',
|
|
69
|
+
ViewService:
|
|
70
|
+
'https://image.discomap.eea.europa.eu/arcgis/services/CoastalZones/CZ_CoastalZones_2012/MapServer/WmsServer?',
|
|
71
|
+
Layer: [
|
|
72
|
+
{
|
|
73
|
+
LayerId: 'Coastal_Zones_2012_vector53031',
|
|
74
|
+
Title: 'Coastal Zones 2012 vector',
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
LayerId: 'Coastal_Zones_2012_raster55645',
|
|
78
|
+
Title: 'Coastal Zones 2012 raster',
|
|
79
|
+
},
|
|
80
|
+
],
|
|
81
|
+
DownloadService: 'EEA',
|
|
82
|
+
DownloadType: 'ESRI REST service',
|
|
83
|
+
IsTimeSeries: false,
|
|
84
|
+
TimeSeriesService: '',
|
|
85
|
+
},
|
|
86
|
+
],
|
|
87
|
+
},
|
|
88
|
+
],
|
|
89
|
+
},
|
|
90
|
+
],
|
|
91
|
+
};
|
|
94
92
|
|
|
95
93
|
return (
|
|
96
94
|
<div>
|
|
@@ -110,18 +108,17 @@ const CLMSMapViewerView = (props) => {
|
|
|
110
108
|
</>
|
|
111
109
|
)}
|
|
112
110
|
{isLoggedIn && (
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
// </>
|
|
111
|
+
<>
|
|
112
|
+
<Helmet
|
|
113
|
+
title={helmetTitle(formatMessage(messages.DownloadByArea), content)}
|
|
114
|
+
/>
|
|
115
|
+
<MapViewer
|
|
116
|
+
cfg={config_by_area}
|
|
117
|
+
url={getBaseUrl(props.location.pathname)}
|
|
118
|
+
customClass={'land'}
|
|
119
|
+
id={props.location.pathname}
|
|
120
|
+
></MapViewer>
|
|
121
|
+
</>
|
|
125
122
|
)}
|
|
126
123
|
</div>
|
|
127
124
|
);
|
|
@@ -28,9 +28,7 @@ const CLMSTechnicalLibraryAdminInfo = (props) => {
|
|
|
28
28
|
Hide
|
|
29
29
|
</Button>
|
|
30
30
|
<br />
|
|
31
|
-
|
|
32
|
-
<strong>Categorization</strong>
|
|
33
|
-
)}{' '}
|
|
31
|
+
<strong>Categorization</strong>
|
|
34
32
|
<ul>
|
|
35
33
|
{item?.taxonomy_technical_library_categorization?.map((item) => (
|
|
36
34
|
<li>{item.title}</li>
|
|
Binary file
|