@eeacms/volto-n2k 0.1.4 → 0.1.7

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,12 +4,32 @@ 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.1.7](https://github.com/eea/volto-n2k/compare/0.1.6...0.1.7)
8
+
9
+ - Update toolkit link [`d791e63`](https://github.com/eea/volto-n2k/commit/d791e63603d750afbead921f1cebbf90902dc8e2)
10
+ - Change link for natura2000 [`98fb51c`](https://github.com/eea/volto-n2k/commit/98fb51c76320ac47e6bbeb0e4012cc49932c17d2)
11
+
12
+ #### [0.1.6](https://github.com/eea/volto-n2k/compare/0.1.5...0.1.6)
13
+
14
+ > 3 August 2022
15
+
16
+ - Add toolkit in landing page [`#7`](https://github.com/eea/volto-n2k/pull/7)
17
+
18
+ #### [0.1.5](https://github.com/eea/volto-n2k/compare/0.1.4...0.1.5)
19
+
20
+ > 28 July 2022
21
+
22
+ - Show language native name [`#6`](https://github.com/eea/volto-n2k/pull/6)
23
+ - Use volto 16 for cypress tests [`dfb57d1`](https://github.com/eea/volto-n2k/commit/dfb57d12d37dbeb1aa8c0d87cf8cc950cdf27d13)
24
+
7
25
  #### [0.1.4](https://github.com/eea/volto-n2k/compare/0.1.3...0.1.4)
8
26
 
27
+ > 15 July 2022
28
+
29
+ - Lazy load d3 [`#5`](https://github.com/eea/volto-n2k/pull/5)
9
30
  - Prettier [`43c0a09`](https://github.com/eea/volto-n2k/commit/43c0a090f481f81e7cadcfcda59b5dcc02dd8f1a)
10
31
  - Prettier [`553c35b`](https://github.com/eea/volto-n2k/commit/553c35b2c9b34adb8fb630f2ec41f2ffd2cf22b0)
11
32
  - Prettier fix [`47619cb`](https://github.com/eea/volto-n2k/commit/47619cb286ff939df397c483c18cc532c58b7547)
12
- - Lazy load d3 [`874e88c`](https://github.com/eea/volto-n2k/commit/874e88c48f3af2f1c01f5818971248c2f19b6789)
13
33
 
14
34
  #### [0.1.3](https://github.com/eea/volto-n2k/compare/0.1.2...0.1.3)
15
35
 
package/Jenkinsfile CHANGED
@@ -6,7 +6,7 @@ pipeline {
6
6
  NAMESPACE = "@eeacms"
7
7
  SONARQUBE_TAGS = "volto.eea.europa.eu,biodiversity.europa.eu"
8
8
  DEPENDENCIES = "volto-slate @eeacms/volto-datablocks"
9
- VOLTO = "alpha"
9
+ VOLTO = "16.0.0-alpha.14"
10
10
  }
11
11
 
12
12
  stages {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eeacms/volto-n2k",
3
- "version": "0.1.4",
3
+ "version": "0.1.7",
4
4
  "description": "volto-n2k: Volto add-on",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: IDM2 A-Team",
@@ -6,7 +6,7 @@ import forests from './images/forests.webp';
6
6
  import mountains from './images/mountains.webp';
7
7
  import grasslands from './images/grasslands.webp';
8
8
  import rivers from './images/rivers.webp';
9
- import islands from './images/islands.webp';
9
+ import toolkit from './images/toolkit_icon.webp';
10
10
  import peatlands from './images/peatlands.webp';
11
11
  import natura2000 from './images/natura2000.webp';
12
12
 
@@ -54,10 +54,10 @@ export const tiles = [
54
54
  link: '/natura2000/:lang/rivers-and-lakes',
55
55
  },
56
56
  {
57
- image: islands,
58
- title: 'Islands',
59
- description: 'ISLANDS',
60
- link: '/natura2000/:lang/islands',
57
+ image: toolkit,
58
+ title: 'Toolkit',
59
+ description: 'TOOLKIT',
60
+ link: 'https://europa.eu/youth/year-of-youth/eu_initiative/pdf/32289_en',
61
61
  },
62
62
  ];
63
63
 
@@ -123,7 +123,7 @@ const CopyPaste = (props) => {
123
123
  onMouseEnter={(e) => {
124
124
  if (
125
125
  e.altKey &&
126
- e.ctrlKey &&
126
+ e.shiftKey &&
127
127
  toolbar.current &&
128
128
  !toolbar.current.classList.contains('__dev_on')
129
129
  ) {
@@ -6,7 +6,7 @@
6
6
  import React from 'react';
7
7
  import { withRouter, matchPath, generatePath } from 'react-router';
8
8
  import { useSelector } from 'react-redux';
9
- // import langmap from 'langmap';
9
+ import { langmap } from '@plone/volto/helpers';
10
10
  import { flattenToAppURL } from '@plone/volto/helpers';
11
11
  import { Dropdown } from 'semantic-ui-react';
12
12
  import config from '@plone/volto/registry';
@@ -15,32 +15,32 @@ import { getN2kItems, pathExists } from '@eeacms/volto-n2k/helpers';
15
15
  import './styles.less';
16
16
 
17
17
  const LanguageSelector = (props) => {
18
+ const { settings } = config;
18
19
  const content = useSelector((state) => state.content);
19
20
  const n2kItems = getN2kItems(props.navigation.items);
20
21
  const localStorage = props.localStorage;
21
22
  const pathname = props.location.pathname;
22
23
  const currentLang = localStorage.get('N2K_LANGUAGE');
23
24
  const match = matchPath(pathname, {
24
- path: config.settings.multilingualPath,
25
+ path: settings.multilingualPath,
25
26
  exact: true,
26
27
  strict: false,
27
28
  });
28
29
  const hasMultilingualSupport =
29
- match && config.settings.supportedLanguages.includes(match.params.lang);
30
+ match && settings.supportedLanguages.includes(match.params.lang);
30
31
  const translations = hasMultilingualSupport
31
- ? config.settings.supportedLanguages.map((lang) => ({
32
- path: generatePath(config.settings.multilingualPath, {
32
+ ? settings.supportedLanguages.map((lang) => ({
33
+ path: generatePath(settings.multilingualPath, {
33
34
  ...match.params,
34
35
  lang,
35
36
  }),
36
37
  lang,
37
38
  }))
38
39
  : [];
39
- const { settings } = config;
40
40
  const supportedLanguagesOptions = settings.supportedLanguages.map((lang) => ({
41
41
  key: lang,
42
42
  value: lang,
43
- text: lang,
43
+ text: langmap[lang].nativeName,
44
44
  }));
45
45
 
46
46
  return (