@eeacms/volto-cca-policy 0.3.92 → 0.3.94
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 +40 -2
- package/package.json +1 -1
- package/src/components/theme/MissionSignatoryProfile/MissionSignatoryProfileView.jsx +2 -8
- package/src/components/theme/MissionSignatoryProfile/TabSections/AssessmentTab.jsx +0 -16
- package/src/components/theme/MissionSignatoryProfile/TabSections/AssessmentTab.test.jsx +1 -12
- package/src/index.js +5 -0
- package/theme/globals/blocks.less +109 -1
- package/theme/globals/mission.less +0 -8
- package/theme/globals/views.less +0 -5
package/CHANGELOG.md
CHANGED
|
@@ -4,7 +4,7 @@ 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
|
-
### [0.3.
|
|
7
|
+
### [0.3.94](https://github.com/eea/volto-cca-policy/compare/1.0.0-alpha.1...0.3.94) - 18 December 2025
|
|
8
8
|
|
|
9
9
|
#### :rocket: Dependency updates
|
|
10
10
|
|
|
@@ -14,6 +14,8 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
|
14
14
|
|
|
15
15
|
#### :bug: Bug Fixes
|
|
16
16
|
|
|
17
|
+
- fix: update comments [kreafox - [`1219fcc`](https://github.com/eea/volto-cca-policy/commit/1219fccab92e59428eccf6b05e600df5878dfe48)]
|
|
18
|
+
- fix: test [kreafox - [`9d687b6`](https://github.com/eea/volto-cca-policy/commit/9d687b68e7a461ad41c48258ba63651de8a0a2fb)]
|
|
17
19
|
- fix: url instead of link in footer config - refs #293707 [kreafox - [`00e3489`](https://github.com/eea/volto-cca-policy/commit/00e3489e6855024ab8186e042d250b5529bea0e4)]
|
|
18
20
|
- fix(tests): increase code coverage [kreafox - [`66cd2b3`](https://github.com/eea/volto-cca-policy/commit/66cd2b39a9b7b026c171d99e2bf3b8a47b7cddd2)]
|
|
19
21
|
- fix(tests): update hyperlink text in PlanningTab [kreafox - [`05080e0`](https://github.com/eea/volto-cca-policy/commit/05080e0727730a5fe7c67d884ad6453eaf82081a)]
|
|
@@ -26,6 +28,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
|
26
28
|
|
|
27
29
|
#### :nail_care: Enhancements
|
|
28
30
|
|
|
31
|
+
- change(mission): code cleanup [kreafox - [`dfa082b`](https://github.com/eea/volto-cca-policy/commit/dfa082b1dbb3480532a6787bf08f96b2af91e265)]
|
|
29
32
|
- change: code cleanup, add customization comments [kreafox - [`4418a01`](https://github.com/eea/volto-cca-policy/commit/4418a0157df75b4588956b15e1a0950bbd1f504c)]
|
|
30
33
|
- change: add 301/302 redirect handling [kreafox - [`1125c61`](https://github.com/eea/volto-cca-policy/commit/1125c61f8b963a1f49bb6f7672b68bed03e559f9)]
|
|
31
34
|
- change: update volto customizations [kreafox - [`a712c5d`](https://github.com/eea/volto-cca-policy/commit/a712c5da2f949262dc82b0526d3623c31a1ee105)]
|
|
@@ -46,6 +49,9 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
|
46
49
|
|
|
47
50
|
#### :house: Internal changes
|
|
48
51
|
|
|
52
|
+
- style: small css update [kreafox - [`160de16`](https://github.com/eea/volto-cca-policy/commit/160de1685a55ac0fe41f97d0886d2356f412104f)]
|
|
53
|
+
- style: add green theme on blocks - refs #295162 [kreafox - [`27747fd`](https://github.com/eea/volto-cca-policy/commit/27747fd3e67800dd5553d3b9366a79b457cfdd18)]
|
|
54
|
+
- style: add EEA green color as theme color - refs #295162 [kreafox - [`0073837`](https://github.com/eea/volto-cca-policy/commit/00738375afe1d0047b6ef2009a45d46fb37a8be6)]
|
|
49
55
|
- style: improve organisation cards [kreafox - [`6ddd344`](https://github.com/eea/volto-cca-policy/commit/6ddd344ec2486355c15866e51fd33fc4e00c3ba9)]
|
|
50
56
|
- style: Automated code fix [eea-jenkins - [`ef718da`](https://github.com/eea/volto-cca-policy/commit/ef718da674d72d1f3614593f7381fb422792eece)]
|
|
51
57
|
- style: cleanup [kreafox - [`142f706`](https://github.com/eea/volto-cca-policy/commit/142f7069f84d1b8460cc6b133e0864f85ad6bc41)]
|
|
@@ -58,9 +64,11 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
|
58
64
|
|
|
59
65
|
#### :hammer_and_wrench: Others
|
|
60
66
|
|
|
67
|
+
- resolve conflicts [Teodor - [`28f6d21`](https://github.com/eea/volto-cca-policy/commit/28f6d2127a1d2fa8c38d4a5d1f235916892774c8)]
|
|
61
68
|
- code cleanup [kreafox - [`5eb537f`](https://github.com/eea/volto-cca-policy/commit/5eb537f30bfc867e460fd46a145e0f7069b2c6f7)]
|
|
62
69
|
- Refs #290863 - update message key [iugin - [`871b61c`](https://github.com/eea/volto-cca-policy/commit/871b61cea7070ff5ca6d303dcf5ecaf2fdd4e965)]
|
|
63
70
|
- Refs #290863 - add translations [iugin - [`63dfc08`](https://github.com/eea/volto-cca-policy/commit/63dfc08243aa19dec5c92d800b22ed739f2f0f75)]
|
|
71
|
+
- code cleanup [Teodor - [`74dea17`](https://github.com/eea/volto-cca-policy/commit/74dea17652897c2f9e5524ea473e9250953ec614)]
|
|
64
72
|
- test: try to use specific version for plone-backend [kreafox - [`79c542e`](https://github.com/eea/volto-cca-policy/commit/79c542e8d55d2f1663b768c555880599634ae527)]
|
|
65
73
|
- test(mission): add unit tests for NoDataReported and StatisticSection components [kreafox - [`36c6e36`](https://github.com/eea/volto-cca-policy/commit/36c6e36278124759240c896786f2ac0c20674730)]
|
|
66
74
|
- test: resolve Jest errors in component tests [kreafox - [`6dbb735`](https://github.com/eea/volto-cca-policy/commit/6dbb73540e8301fcb42a4d52db7004f5a42db4d8)]
|
|
@@ -151,8 +159,38 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
|
|
|
151
159
|
- Add some loadable for components [Tiberiu Ichim - [`1793962`](https://github.com/eea/volto-cca-policy/commit/179396211c66a6a2465b2d1b6c0f2afc40fc7189)]
|
|
152
160
|
- Refs #284961 - test [Tripon Eugen - [`c989f1f`](https://github.com/eea/volto-cca-policy/commit/c989f1f8638c0c5233c5c49f8673c9a2cdc7937e)]
|
|
153
161
|
- Refs #284961 - add translations [Tripon Eugen - [`04ee988`](https://github.com/eea/volto-cca-policy/commit/04ee988c086d393b9b37ce1ea8d24f5e84f266aa)]
|
|
154
|
-
### [1.0.0-alpha.0](https://github.com/eea/volto-cca-policy/compare/0.3.
|
|
162
|
+
### [1.0.0-alpha.0](https://github.com/eea/volto-cca-policy/compare/0.3.93...1.0.0-alpha.0) - 15 July 2025
|
|
155
163
|
|
|
164
|
+
### [0.3.93](https://github.com/eea/volto-cca-policy/compare/0.3.92...0.3.93) - 17 December 2025
|
|
165
|
+
|
|
166
|
+
#### :bug: Bug Fixes
|
|
167
|
+
|
|
168
|
+
- fix: update comments [kreafox - [`1219fcc`](https://github.com/eea/volto-cca-policy/commit/1219fccab92e59428eccf6b05e600df5878dfe48)]
|
|
169
|
+
- fix: test [kreafox - [`9d687b6`](https://github.com/eea/volto-cca-policy/commit/9d687b68e7a461ad41c48258ba63651de8a0a2fb)]
|
|
170
|
+
|
|
171
|
+
#### :nail_care: Enhancements
|
|
172
|
+
|
|
173
|
+
- change(mission): code cleanup [kreafox - [`dfa082b`](https://github.com/eea/volto-cca-policy/commit/dfa082b1dbb3480532a6787bf08f96b2af91e265)]
|
|
174
|
+
|
|
175
|
+
#### :house: Internal changes
|
|
176
|
+
|
|
177
|
+
- style: add EEA green color as theme color - refs #295162 [kreafox - [`0073837`](https://github.com/eea/volto-cca-policy/commit/00738375afe1d0047b6ef2009a45d46fb37a8be6)]
|
|
178
|
+
|
|
179
|
+
#### :hammer_and_wrench: Others
|
|
180
|
+
|
|
181
|
+
- resolve conflicts [Teodor - [`28f6d21`](https://github.com/eea/volto-cca-policy/commit/28f6d2127a1d2fa8c38d4a5d1f235916892774c8)]
|
|
182
|
+
- code cleanup [Teodor - [`74dea17`](https://github.com/eea/volto-cca-policy/commit/74dea17652897c2f9e5524ea473e9250953ec614)]
|
|
183
|
+
### [0.3.92](https://github.com/eea/volto-cca-policy/compare/0.3.91...0.3.92) - 8 December 2025
|
|
184
|
+
|
|
185
|
+
#### :nail_care: Enhancements
|
|
186
|
+
|
|
187
|
+
- change: code cleanup, add customization comments [kreafox - [`4418a01`](https://github.com/eea/volto-cca-policy/commit/4418a0157df75b4588956b15e1a0950bbd1f504c)]
|
|
188
|
+
- change: add 301/302 redirect handling [kreafox - [`1125c61`](https://github.com/eea/volto-cca-policy/commit/1125c61f8b963a1f49bb6f7672b68bed03e559f9)]
|
|
189
|
+
- change: update volto customizations [kreafox - [`a712c5d`](https://github.com/eea/volto-cca-policy/commit/a712c5da2f949262dc82b0526d3623c31a1ee105)]
|
|
190
|
+
|
|
191
|
+
#### :hammer_and_wrench: Others
|
|
192
|
+
|
|
193
|
+
- code cleanup [kreafox - [`5eb537f`](https://github.com/eea/volto-cca-policy/commit/5eb537f30bfc867e460fd46a145e0f7069b2c6f7)]
|
|
156
194
|
### [0.3.91](https://github.com/eea/volto-cca-policy/compare/0.3.90...0.3.91) - 4 December 2025
|
|
157
195
|
|
|
158
196
|
#### :hammer_and_wrench: Others
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Link
|
|
2
|
+
import { Link } from 'react-router-dom';
|
|
3
3
|
import { Tab, Container, Divider, Button, Icon } from 'semantic-ui-react';
|
|
4
4
|
import { formatTextToHTML } from '@eeacms/volto-cca-policy/utils';
|
|
5
5
|
import { BannerTitle, HTMLField } from '@eeacms/volto-cca-policy/helpers';
|
|
@@ -18,14 +18,8 @@ const tabRenderers = {
|
|
|
18
18
|
};
|
|
19
19
|
|
|
20
20
|
const MissionSignatoryProfileView = ({ content }) => {
|
|
21
|
-
const location = useLocation();
|
|
22
|
-
const isSandbox = location.pathname.includes(
|
|
23
|
-
'/mission/sandbox/eea-sandbox/signatory-reporting',
|
|
24
|
-
);
|
|
25
21
|
const signatoryData =
|
|
26
|
-
content?.['@components']?.missionsignatoryprofile?.
|
|
27
|
-
isSandbox ? 'result_beta' : 'result'
|
|
28
|
-
] || {};
|
|
22
|
+
content?.['@components']?.missionsignatoryprofile?.result || {};
|
|
29
23
|
|
|
30
24
|
const {
|
|
31
25
|
governance = [{}],
|
|
@@ -113,7 +113,6 @@ const AssessmentTab = ({ result, general_text }) => {
|
|
|
113
113
|
{assessment_hazards_sectors?.length > 0 && (
|
|
114
114
|
<AccordionList
|
|
115
115
|
accordions={assessment_hazards_sectors.flatMap((item) => {
|
|
116
|
-
// Beta data (Category > Hazards > Sectors)
|
|
117
116
|
if (item.Category && Array.isArray(item.Hazards)) {
|
|
118
117
|
return [
|
|
119
118
|
{
|
|
@@ -139,21 +138,6 @@ const AssessmentTab = ({ result, general_text }) => {
|
|
|
139
138
|
];
|
|
140
139
|
}
|
|
141
140
|
|
|
142
|
-
// Production data (Category=null but has Hazards array)
|
|
143
|
-
if (item.Category === null && Array.isArray(item.Hazards)) {
|
|
144
|
-
return item.Hazards.map((hazard) => ({
|
|
145
|
-
title: hazard.Hazard,
|
|
146
|
-
content: (
|
|
147
|
-
<ul>
|
|
148
|
-
{Array.isArray(hazard.Sectors) &&
|
|
149
|
-
hazard.Sectors.map((sector, index) => (
|
|
150
|
-
<li key={index}>{sector}</li>
|
|
151
|
-
))}
|
|
152
|
-
</ul>
|
|
153
|
-
),
|
|
154
|
-
}));
|
|
155
|
-
}
|
|
156
|
-
|
|
157
141
|
return [];
|
|
158
142
|
})}
|
|
159
143
|
/>
|
|
@@ -98,28 +98,17 @@ describe('AssessmentTab', () => {
|
|
|
98
98
|
expect(link).toHaveAttribute('href', 'https://example.com');
|
|
99
99
|
});
|
|
100
100
|
|
|
101
|
-
it('renders
|
|
101
|
+
it('renders hazards (Category > Hazard > Sector)', () => {
|
|
102
102
|
render(<AssessmentTab result={mockData} />);
|
|
103
103
|
|
|
104
104
|
expect(screen.getByText('Water Management')).toBeInTheDocument();
|
|
105
105
|
expect(screen.getByText('Flooding')).toBeInTheDocument();
|
|
106
106
|
expect(screen.getByText('Drought')).toBeInTheDocument();
|
|
107
|
-
|
|
108
107
|
expect(screen.getByText('Agriculture')).toBeInTheDocument();
|
|
109
108
|
expect(screen.getAllByText('Health').length).toBeGreaterThanOrEqual(1);
|
|
110
109
|
expect(screen.getByText('Energy')).toBeInTheDocument();
|
|
111
110
|
});
|
|
112
111
|
|
|
113
|
-
it('renders production-style hazards (Hazard > Sectors)', () => {
|
|
114
|
-
render(<AssessmentTab result={mockData} />);
|
|
115
|
-
|
|
116
|
-
expect(screen.getByText('Storms')).toBeInTheDocument();
|
|
117
|
-
expect(screen.getByText('Heatwaves')).toBeInTheDocument();
|
|
118
|
-
expect(screen.getByText('Transport')).toBeInTheDocument();
|
|
119
|
-
expect(screen.getByText('Tourism')).toBeInTheDocument();
|
|
120
|
-
expect(screen.getAllByText('Health').length).toBeGreaterThanOrEqual(1);
|
|
121
|
-
});
|
|
122
|
-
|
|
123
112
|
it('renders NoDataReported when no data available', () => {
|
|
124
113
|
render(
|
|
125
114
|
<AssessmentTab
|
package/src/index.js
CHANGED
|
@@ -570,6 +570,11 @@ const applyConfig = (config) => {
|
|
|
570
570
|
config.widgets.vocabulary['plone.app.vocabularies.Users'] =
|
|
571
571
|
SelectAutoCompleteWidget;
|
|
572
572
|
|
|
573
|
+
config.settings.themeColors = [
|
|
574
|
+
...config.settings.themeColors,
|
|
575
|
+
{ value: 'green', title: 'EEA Green' },
|
|
576
|
+
];
|
|
577
|
+
|
|
573
578
|
config.settings.matomoTrackerIdFn = (pathname) => {
|
|
574
579
|
return pathname.split('/')[2] === 'mission'
|
|
575
580
|
? {
|
|
@@ -92,4 +92,112 @@
|
|
|
92
92
|
|
|
93
93
|
.ui.items > .item > img + .content {
|
|
94
94
|
padding-left: 1rem;
|
|
95
|
-
}
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/* Mobile responsive fixes for tabs block */
|
|
98
|
+
@media only screen and (max-width: 480px) {
|
|
99
|
+
.tabs-block .ui.vertical.menu .item .menu-item-text {
|
|
100
|
+
white-space: normal;
|
|
101
|
+
overflow-wrap: break-word;
|
|
102
|
+
word-break: keep-all;
|
|
103
|
+
font-size: 0.8rem;
|
|
104
|
+
line-height: 1.3;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
@media only screen and (max-width: 380px) {
|
|
109
|
+
.tabs-block .ui.vertical.menu .item .asset-position .menu-item-text {
|
|
110
|
+
font-size: 0.7rem;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
@media only screen and (max-width: 345px) {
|
|
115
|
+
.tabs-block .ui.vertical.menu .item .asset-position .menu-item-text {
|
|
116
|
+
font-size: 0.65rem;
|
|
117
|
+
}
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
/* (EEA) Green theme */
|
|
121
|
+
.green,
|
|
122
|
+
.has--theme--green {
|
|
123
|
+
/* Accordion */
|
|
124
|
+
.ui.accordion.green > .active.title,
|
|
125
|
+
.ui.accordion.green.inverted > .title,
|
|
126
|
+
.ui.accordion.green > .filter,
|
|
127
|
+
.ui.accordion.secondary.green > .active.title,
|
|
128
|
+
.ui.accordion.secondary.green.inverted > .title,
|
|
129
|
+
.ui.accordion.secondary.green > .filter {
|
|
130
|
+
--bg-color: @green;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.ui.accordion.green > .active.title,
|
|
134
|
+
.ui.accordion.green.inverted > .title,
|
|
135
|
+
.ui.accordion.green.inverted > .icon,
|
|
136
|
+
.ui.accordion.green > .filter {
|
|
137
|
+
--text-color-hover: white;
|
|
138
|
+
--text-color: white;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
/* Table */
|
|
142
|
+
.ui.table {
|
|
143
|
+
tr th {
|
|
144
|
+
border-bottom: 1px solid @green;
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.ui.celled.table tr th,
|
|
149
|
+
.ui.celled.table tr td {
|
|
150
|
+
border-left: 1px solid @green;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
/* Callout */
|
|
154
|
+
.eea.callout {
|
|
155
|
+
border-color: @green;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/* Statistics */
|
|
159
|
+
.ui.statistics:not(.inverted) .ui.statistic .value {
|
|
160
|
+
color: @green !important;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
.color-bg-primary {
|
|
164
|
+
background-color: @green !important;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/* Divider */
|
|
168
|
+
.ui.divider.green,
|
|
169
|
+
.ui.divider.green:not(.vertical):not(.horizontal) {
|
|
170
|
+
border-top-color: @green;
|
|
171
|
+
color: @green;
|
|
172
|
+
}
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
/* Hero */
|
|
176
|
+
.color-bg-green {
|
|
177
|
+
background-color: @green;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
/* Listing cards */
|
|
181
|
+
.ui.card.green {
|
|
182
|
+
box-shadow: none !important;
|
|
183
|
+
border: none;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.ui.card.green {
|
|
187
|
+
--card-text-color: white;
|
|
188
|
+
--card-background-color: @green;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
.card.green.inverted,
|
|
192
|
+
.cardsVisualization .ui.card.green {
|
|
193
|
+
--card-background-color: white;
|
|
194
|
+
--card-text-color: @green !important;
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
.cardsVisualization {
|
|
198
|
+
.ui.cards {
|
|
199
|
+
.ui.card.green::before {
|
|
200
|
+
background-color: @green;
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
@@ -27,10 +27,6 @@ body.subsite-mkh {
|
|
|
27
27
|
--text-color-secondary: @pineGreen;
|
|
28
28
|
--border-color-secondary: @pineGreen;
|
|
29
29
|
|
|
30
|
-
.column > .ui.segment {
|
|
31
|
-
background-color: transparent;
|
|
32
|
-
}
|
|
33
|
-
|
|
34
30
|
&.subsite-root {
|
|
35
31
|
.content-area {
|
|
36
32
|
padding: 0 !important;
|
|
@@ -157,10 +153,6 @@ body.subsite-mkh {
|
|
|
157
153
|
}
|
|
158
154
|
}
|
|
159
155
|
|
|
160
|
-
.column > .ui.segment {
|
|
161
|
-
background-color: #fff !important;
|
|
162
|
-
}
|
|
163
|
-
|
|
164
156
|
.funding-sources {
|
|
165
157
|
span {
|
|
166
158
|
float: left;
|