@eeacms/volto-clms-theme 1.1.167 → 1.1.168
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,11 +4,15 @@ 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.168](https://github.com/eea/volto-clms-theme/compare/1.1.167...1.1.168) - 16 July 2024
|
|
8
|
+
|
|
9
|
+
#### :hammer_and_wrench: Others
|
|
10
|
+
|
|
11
|
+
- Refs #271716 - Restore login modal for Go to download by area button. [GhitaB - [`ea95221`](https://github.com/eea/volto-clms-theme/commit/ea95221ba53bce6040ab5035786dc1e0db5314ba)]
|
|
7
12
|
### [1.1.167](https://github.com/eea/volto-clms-theme/compare/1.1.166...1.1.167) - 11 July 2024
|
|
8
13
|
|
|
9
14
|
#### :hammer_and_wrench: Others
|
|
10
15
|
|
|
11
|
-
- Refs #271716 - Delay EU Login one step for a dataset's Download page. [GhitaB - [`58df691`](https://github.com/eea/volto-clms-theme/commit/58df6915878c9c82b7b90c3ed37327f00581c24a)]
|
|
12
16
|
- Bump version number for clms-utils [Tiberiu Ichim - [`06aac6d`](https://github.com/eea/volto-clms-theme/commit/06aac6d40bc086269f1300f695ff447f3f89c7da)]
|
|
13
17
|
### [1.1.166](https://github.com/eea/volto-clms-theme/compare/1.1.165...1.1.166) - 3 July 2024
|
|
14
18
|
|
package/package.json
CHANGED
|
@@ -1,14 +1,17 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { FormattedMessage } from 'react-intl';
|
|
2
3
|
import { useSelector } from 'react-redux';
|
|
3
4
|
|
|
4
5
|
import CclButton from '@eeacms/volto-clms-theme/components/CclButton/CclButton';
|
|
5
6
|
import CclDownloadTable from '@eeacms/volto-clms-theme/components/CclDownloadTable/CclDownloadTable';
|
|
7
|
+
import CclLoginModal from '@eeacms/volto-clms-theme/components/CclLoginModal/CclLoginModal';
|
|
6
8
|
import {
|
|
7
9
|
StringToHTML,
|
|
8
10
|
sanitizedHTML,
|
|
9
11
|
} from '@eeacms/volto-clms-theme/components/CclUtils';
|
|
10
12
|
|
|
11
13
|
const DownloadDataSetContent = (data, token) => {
|
|
14
|
+
const user = useSelector((state) => state?.users?.user);
|
|
12
15
|
const locale = useSelector((state) => state?.intl?.locale);
|
|
13
16
|
let download_other_ways_access_dataset = sanitizedHTML(
|
|
14
17
|
data.download_other_ways_access_dataset?.data,
|
|
@@ -42,15 +45,36 @@ const DownloadDataSetContent = (data, token) => {
|
|
|
42
45
|
</p>
|
|
43
46
|
</>
|
|
44
47
|
)}
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
48
|
+
|
|
49
|
+
{user?.['@id'] ? (
|
|
50
|
+
data.mapviewer_istimeseries ||
|
|
51
|
+
data.download_show_auxiliary_calendar ? (
|
|
52
|
+
<CclButton
|
|
53
|
+
url={'/' + locale + '/map-viewer?dataset=' + data?.UID}
|
|
54
|
+
>
|
|
55
|
+
Go to download by area and time
|
|
56
|
+
</CclButton>
|
|
57
|
+
) : (
|
|
58
|
+
<CclButton
|
|
59
|
+
url={'/' + locale + '/map-viewer?dataset=' + data?.UID}
|
|
60
|
+
>
|
|
61
|
+
Go to download by area
|
|
62
|
+
</CclButton>
|
|
63
|
+
)
|
|
50
64
|
) : (
|
|
51
|
-
<
|
|
52
|
-
|
|
53
|
-
|
|
65
|
+
<CclLoginModal
|
|
66
|
+
triggerComponent={() => (
|
|
67
|
+
<CclButton
|
|
68
|
+
isButton={true}
|
|
69
|
+
className={'ccl-button ccl-button--default'}
|
|
70
|
+
>
|
|
71
|
+
<FormattedMessage
|
|
72
|
+
id="downloadByArea"
|
|
73
|
+
defaultMessage="Go to download by area"
|
|
74
|
+
/>
|
|
75
|
+
</CclButton>
|
|
76
|
+
)}
|
|
77
|
+
/>
|
|
54
78
|
)}
|
|
55
79
|
</div>
|
|
56
80
|
)}
|