@eeacms/volto-eea-website-policy 1.6.0 → 1.6.1

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,11 @@ 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.6.1](https://github.com/eea/volto-eea-website-policy/compare/1.6.0...1.6.1) - 23 May 2023
8
+
9
+ #### :hammer_and_wrench: Others
10
+
11
+ - other: restrict volto-datablocks blocks [Miu Razvan - [`6f39568`](https://github.com/eea/volto-eea-website-policy/commit/6f39568c8f53ce46707279715e57ee50c897d49f)]
7
12
  ### [1.6.0](https://github.com/eea/volto-eea-website-policy/compare/1.5.0...1.6.0) - 22 May 2023
8
13
 
9
14
  #### :nail_care: Enhancements
@@ -32,6 +37,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
32
37
 
33
38
  - Release 1.5.0 [Alin Voinea - [`a3dea8e`](https://github.com/eea/volto-eea-website-policy/commit/a3dea8ea15cb8d2a876dc10da926ece3a5707ea9)]
34
39
  - test(Jenkinsfile): Use latest stable volto for testing [Alin Voinea - [`a8f7123`](https://github.com/eea/volto-eea-website-policy/commit/a8f712364187f9638886667c249fa102cb49b5c0)]
40
+ - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`124a8f8`](https://github.com/eea/volto-eea-website-policy/commit/124a8f8ad4ced507aeec27012d725f2e2b977e08)]
35
41
  ### [1.4.0](https://github.com/eea/volto-eea-website-policy/compare/1.3.4...1.4.0) - 21 February 2023
36
42
 
37
43
  #### :rocket: New Features
@@ -111,6 +117,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
111
117
  #### :hammer_and_wrench: Others
112
118
 
113
119
  - Release 1.1.0 [Alin Voinea - [`0291b3b`](https://github.com/eea/volto-eea-website-policy/commit/0291b3bb7b4c6ab09ca98728885cea4051eac8e3)]
120
+ - yarn 3 [Alin Voinea - [`593aa58`](https://github.com/eea/volto-eea-website-policy/commit/593aa58eaa4d28aced0603b7f7dd125c857a6f54)]
114
121
  ### [1.0.4](https://github.com/eea/volto-eea-website-policy/compare/1.0.3...1.0.4) - 22 November 2022
115
122
 
116
123
  #### :nail_care: Enhancements
@@ -156,6 +163,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
156
163
 
157
164
  #### :hammer_and_wrench: Others
158
165
 
166
+ - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`d153f54`](https://github.com/eea/volto-eea-website-policy/commit/d153f54e55e918fa4746e05488c734624eaf14a9)]
159
167
  ### [0.4.0](https://github.com/eea/volto-eea-website-policy/compare/0.3.3...0.4.0) - 19 September 2022
160
168
 
161
169
  #### :hammer_and_wrench: Others
@@ -231,6 +239,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
231
239
  - format index.js [Andrei Grigore - [`db4481a`](https://github.com/eea/volto-eea-website-policy/commit/db4481aeeba59a769272659f33278c902fc69bec)]
232
240
  - Update index.js [Alexandru Ghica - [`dc09886`](https://github.com/eea/volto-eea-website-policy/commit/dc0988640a76a9914381b120f58bb61a9ab1eb39)]
233
241
  - Added externalRoutes [Alexandru Ghica - [`b68135b`](https://github.com/eea/volto-eea-website-policy/commit/b68135b013fafa93a41ea602ea2fad30879abe0f)]
242
+ - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`575cca6`](https://github.com/eea/volto-eea-website-policy/commit/575cca674602ca2e1c2a41300c47ba594ff49aa0)]
234
243
  ### [0.1.1](https://github.com/eea/volto-eea-website-policy/compare/0.1.0...0.1.1) - 4 March 2022
235
244
 
236
245
  #### :hammer_and_wrench: Others
@@ -243,4 +252,5 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
243
252
 
244
253
  #### :hammer_and_wrench: Others
245
254
 
255
+ - yarn bootstrap [Alin Voinea - [`9b4d197`](https://github.com/eea/volto-eea-website-policy/commit/9b4d197cbc7992566cb36524d190078d5ad21a44)]
246
256
  - Initial commit [Alin Voinea - [`3800692`](https://github.com/eea/volto-eea-website-policy/commit/3800692f7a4de6460815bd6061facacb986cbef0)]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eeacms/volto-eea-website-policy",
3
- "version": "1.6.0",
3
+ "version": "1.6.1",
4
4
  "description": "@eeacms/volto-eea-website-policy: Volto add-on",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: IDM2 A-Team",
package/src/index.js CHANGED
@@ -1,6 +1,20 @@
1
1
  import { runtimeConfig } from '@plone/volto/runtime_config';
2
2
  import installContextNavigationBlock from '@eeacms/volto-eea-website-policy/components/Blocks/ContextNavigation';
3
3
 
4
+ const restrictedBlocks = [
5
+ 'imagecards',
6
+ 'embed_eea_tableau_block',
7
+ 'embed_eea_map_block',
8
+ // TODO: use what is needed from volto-datablocks after clean-up
9
+ 'conditionalDataBlock',
10
+ 'countryFlag',
11
+ 'custom_connected_block',
12
+ 'data_connected_embed',
13
+ 'dataqueryfilter',
14
+ 'dottedTableChart',
15
+ 'simpleDataConnectedTable',
16
+ ];
17
+
4
18
  const applyConfig = (config) => {
5
19
  // #158717#note-25 any path that isn't static, en or controlpanel is treated as external
6
20
  const notInEN = /^(?!.*(#|\/en|\/static|\/controlpanel|\/cypress|\/login|\/logout|\/contact-form)).*$/;
@@ -65,16 +79,11 @@ const applyConfig = (config) => {
65
79
  );
66
80
 
67
81
  // Disable some blocks
68
- if (config.blocks.blocksConfig.imagecards) {
69
- config.blocks.blocksConfig.imagecards.restricted = true;
70
- }
71
-
72
- if (config.blocks.blocksConfig.embed_eea_tableau_block) {
73
- config.blocks.blocksConfig.embed_eea_tableau_block.restricted = true;
74
- }
75
- if (config.blocks.blocksConfig.embed_eea_map_block) {
76
- config.blocks.blocksConfig.embed_eea_map_block.restricted = true;
77
- }
82
+ restrictedBlocks.forEach((block) => {
83
+ if (config.blocks.blocksConfig[block]) {
84
+ config.blocks.blocksConfig[block].restricted = true;
85
+ }
86
+ });
78
87
 
79
88
  config.settings.apiExpanders = [
80
89
  ...config.settings.apiExpanders,