@eeacms/volto-globalsearch 2.1.2 → 4.0.0

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.
Files changed (40) hide show
  1. package/CHANGELOG.md +22 -20
  2. package/DEVELOP.md +19 -17
  3. package/README.md +33 -19
  4. package/docker-compose.yml +1 -1
  5. package/jest-addon.config.js +11 -4
  6. package/locales/bg/LC_MESSAGES/volto.po +7 -7
  7. package/locales/cs/LC_MESSAGES/volto.po +7 -7
  8. package/locales/de/LC_MESSAGES/volto.po +7 -7
  9. package/locales/en/LC_MESSAGES/volto.po +7 -7
  10. package/locales/es/LC_MESSAGES/volto.po +7 -7
  11. package/locales/et/LC_MESSAGES/volto.po +7 -7
  12. package/locales/fi/LC_MESSAGES/volto.po +7 -7
  13. package/locales/fr/LC_MESSAGES/volto.po +7 -7
  14. package/locales/ga/LC_MESSAGES/volto.po +7 -7
  15. package/locales/hr/LC_MESSAGES/volto.po +7 -7
  16. package/locales/hu/LC_MESSAGES/volto.po +7 -7
  17. package/locales/it/LC_MESSAGES/volto.po +7 -7
  18. package/locales/lt/LC_MESSAGES/volto.po +7 -7
  19. package/locales/nl/LC_MESSAGES/volto.po +7 -7
  20. package/locales/pl/LC_MESSAGES/volto.po +7 -7
  21. package/locales/pt/LC_MESSAGES/volto.po +7 -7
  22. package/locales/ro/LC_MESSAGES/volto.po +7 -7
  23. package/locales/sl/LC_MESSAGES/volto.po +7 -7
  24. package/locales/volto.pot +9 -9
  25. package/package.json +2 -1
  26. package/src/components/MasonryLandingPage.test.jsx +1 -1
  27. package/src/config/clusters.test.js +221 -0
  28. package/src/config/filters.test.js +67 -0
  29. package/src/config/healthcheck.js +10 -60
  30. package/src/config/healthcheck.test.js +18 -13
  31. package/src/config/healthcheck_queries/failed_scheduled_atempts_since_last_started.json +1 -2
  32. package/src/config/healthcheck_queries/last_scheduled_started_indexing.json +1 -2
  33. package/src/config/healthcheck_queries/last_sync_task_since_last_start.json +1 -2
  34. package/src/config/healthcheck_queries/latest_tasks_for_site.json +1 -2
  35. package/src/config/healthcheck_queries/started_or_finished_site_since_last_started.json +1 -2
  36. package/src/config/index.test.js +1 -1
  37. package/src/config/query.test.js +64 -0
  38. package/src/config/vocabulary.test.js +92 -0
  39. package/src/index.test.js +74 -0
  40. package/src/utils.test.js +1 -1
package/CHANGELOG.md CHANGED
@@ -4,11 +4,31 @@ 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
- ### [2.1.2](https://github.com/eea/volto-globalsearch/compare/2.1.1...2.1.2) - 15 May 2025
7
+ ### [4.0.0](https://github.com/eea/volto-globalsearch/compare/3.0.0...4.0.0) - 25 March 2026
8
+
9
+ #### :rocket: New Features
10
+
11
+ - feat: Volto 18 support - refs #287700 [Alin Voinea - [`8374dee`](https://github.com/eea/volto-globalsearch/commit/8374deef42598555b7b83df4446a1431ca1aa0af)]
12
+
13
+ #### :house: Internal changes
14
+
8
15
 
9
16
  #### :hammer_and_wrench: Others
10
17
 
11
- - Remove tweak for pngs [Tiberiu Ichim - [`e50f9eb`](https://github.com/eea/volto-globalsearch/commit/e50f9eb600a482ce7847f8847366277ce7c775e4)]
18
+ - tests: Fix Sonar Qube tags - refs #297339 [Alin Voinea - [`e08a2b9`](https://github.com/eea/volto-globalsearch/commit/e08a2b96d9871526d0483e9ef643f7bdd3555bd6)]
19
+ ## [3.0.0](https://github.com/eea/volto-globalsearch/compare/2.1.2...3.0.0) - 26 January 2026
20
+
21
+ #### :house: Internal changes
22
+
23
+ - style: Automated code fix [eea-jenkins - [`6a780cc`](https://github.com/eea/volto-globalsearch/commit/6a780cc4c5a78f60754e0a9d17551104b68f258d)]
24
+
25
+ #### :hammer_and_wrench: Others
26
+
27
+ - Prepare major release 3.0.0 [Miu Razvan - [`afe6005`](https://github.com/eea/volto-globalsearch/commit/afe6005abc2d747a1cb4a27ff5757f095102d050)]
28
+ - clean up [Miu Razvan - [`a09c03a`](https://github.com/eea/volto-globalsearch/commit/a09c03a34832bc3ea07905e420fab41c0430f911)]
29
+ - increase tests coverage [Miu Razvan - [`aa568dc`](https://github.com/eea/volto-globalsearch/commit/aa568dc329d58b2a399783bd8a02cec49ed260eb)]
30
+ ### [2.1.2](https://github.com/eea/volto-globalsearch/compare/2.1.1...2.1.2) - 15 May 2025
31
+
12
32
  ### [2.1.1](https://github.com/eea/volto-globalsearch/compare/2.1.0...2.1.1) - 14 May 2025
13
33
 
14
34
  #### :hammer_and_wrench: Others
@@ -23,7 +43,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
23
43
  #### :hammer_and_wrench: Others
24
44
 
25
45
  - Update package.json [Krisztina Elekes - [`37141a6`](https://github.com/eea/volto-globalsearch/commit/37141a6d38c96f87ce0c6b443b476739b728797f)]
26
- - Add Sonarqube tag using fise-frontend addons list [EEA Jenkins - [`661bae3`](https://github.com/eea/volto-globalsearch/commit/661bae385546a308e2b44389ec734be80a6fc916)]
27
46
  ### [2.0.9](https://github.com/eea/volto-globalsearch/compare/2.0.8...2.0.9) - 6 March 2025
28
47
 
29
48
  #### :hammer_and_wrench: Others
@@ -69,7 +88,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
69
88
 
70
89
  - added logo for copernicus insitu [Zoltan Szabo - [`b6b00ea`](https://github.com/eea/volto-globalsearch/commit/b6b00eacaf5fd798426fd5cf0af50858f8be79ef)]
71
90
  - added copernicus in situ [Zoltan Szabo - [`54e3657`](https://github.com/eea/volto-globalsearch/commit/54e3657c28f8aa5a839952e83f9fbdb238e99ff0)]
72
- - Add Sonarqube tag using bise-frontend addons list [EEA Jenkins - [`173f015`](https://github.com/eea/volto-globalsearch/commit/173f015579c8e334c853238d9fbf39261ced1cb4)]
73
91
  ### [2.0.2](https://github.com/eea/volto-globalsearch/compare/2.0.1...2.0.2) - 16 December 2024
74
92
 
75
93
  #### :house: Internal changes
@@ -78,7 +96,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
78
96
 
79
97
  #### :hammer_and_wrench: Others
80
98
 
81
- - Add Sonarqube tag using insitu-frontend addons list [EEA Jenkins - [`5c6aa68`](https://github.com/eea/volto-globalsearch/commit/5c6aa68b0677dca98776114e69275ade89dcdf25)]
82
99
  ### [2.0.1](https://github.com/eea/volto-globalsearch/compare/2.0.0...2.0.1) - 14 October 2024
83
100
 
84
101
  ## [2.0.0](https://github.com/eea/volto-globalsearch/compare/1.1.0...2.0.0) - 22 April 2024
@@ -90,7 +107,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
90
107
 
91
108
  #### :hammer_and_wrench: Others
92
109
 
93
- - Add Sonarqube tag using freshwater-frontend addons list [EEA Jenkins - [`d37a6cb`](https://github.com/eea/volto-globalsearch/commit/d37a6cbbe18e53abed600c082d7d23f8907fd7d3)]
94
110
  ### [1.1.0](https://github.com/eea/volto-globalsearch/compare/1.0.22...1.1.0) - 16 January 2024
95
111
 
96
112
  #### :hammer_and_wrench: Others
@@ -104,7 +120,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
104
120
 
105
121
  #### :house: Internal changes
106
122
 
107
- - chore: [JENKINS] Refactor automated testing [valentinab25 - [`af030b5`](https://github.com/eea/volto-globalsearch/commit/af030b5cc8780353dd67f30857fd20edf746d5a0)]
108
123
  - chore: husky, lint-staged use fixed versions [valentinab25 - [`866609d`](https://github.com/eea/volto-globalsearch/commit/866609d540bd0efe4bab088305bb2127105d8df7)]
109
124
  - chore:volto 16 in tests, update docs, fix stylelint overrides [valentinab25 - [`e09f5e2`](https://github.com/eea/volto-globalsearch/commit/e09f5e2c1161b4b867c04eb1c0421274bd6c7110)]
110
125
 
@@ -112,11 +127,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
112
127
 
113
128
  - removed try/catch [Zoltan Szabo - [`86cec5d`](https://github.com/eea/volto-globalsearch/commit/86cec5d49d06d41541dc6d42464e9b95769da745)]
114
129
  - avoid async promise executor functions [Zoltan Szabo - [`61012e3`](https://github.com/eea/volto-globalsearch/commit/61012e331776fadaa9eafe9f7667b18d08b2351a)]
115
- - test: [JENKINS] Use java17 for sonarqube scanner [valentinab25 - [`693b9c7`](https://github.com/eea/volto-globalsearch/commit/693b9c7f8c9d96533f04f5ae165e7e63b753222d)]
116
- - test: [JENKINS] Run cypress in started frontend container [valentinab25 - [`66db063`](https://github.com/eea/volto-globalsearch/commit/66db0635134d95f57c913c400902096980f2b66b)]
117
- - test: [JENKINS] Add cpu limit on cypress docker [valentinab25 - [`4b8920b`](https://github.com/eea/volto-globalsearch/commit/4b8920b5456e5a7f0ef355a0aa208267b50d395f)]
118
- - test: [JENKINS] Increase shm-size to cypress docker [valentinab25 - [`5ea9790`](https://github.com/eea/volto-globalsearch/commit/5ea97905931323146c33be941646fab45643b18b)]
119
- - test: [JENKINS] Improve cypress time [valentinab25 - [`1b94a8c`](https://github.com/eea/volto-globalsearch/commit/1b94a8c137d6c4961f811bbc4596da93d2b588bd)]
120
130
  ### [1.0.21](https://github.com/eea/volto-globalsearch/compare/1.0.20...1.0.21) - 29 September 2023
121
131
 
122
132
  #### :house: Internal changes
@@ -179,13 +189,11 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
179
189
 
180
190
  #### :house: Internal changes
181
191
 
182
- - chore: [JENKINS] Deprecate circularity website [valentinab25 - [`ae6efed`](https://github.com/eea/volto-globalsearch/commit/ae6efed386f8fd053972a388a3f8714ff36cf575)]
183
192
 
184
193
  #### :hammer_and_wrench: Others
185
194
 
186
195
  - added missing logo [Zoltan Szabo - [`94684b9`](https://github.com/eea/volto-globalsearch/commit/94684b979698c47de353ecc2a9014a8f70d7ecc1)]
187
196
  - updated frontend with configuration for 'Climate Advisory Board' [Zoltan Szabo - [`28cf22c`](https://github.com/eea/volto-globalsearch/commit/28cf22c93237226c3957223b497a33ab3cb73623)]
188
- - Add Sonarqube tag using cca-frontend addons list [EEA Jenkins - [`b655d51`](https://github.com/eea/volto-globalsearch/commit/b655d51fa3631ae42c89eb85bdcc850f70d9c72c)]
189
197
  ### [1.0.15](https://github.com/eea/volto-globalsearch/compare/1.0.14...1.0.15) - 14 March 2023
190
198
 
191
199
  #### :hammer_and_wrench: Others
@@ -205,7 +213,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
205
213
  #### :hammer_and_wrench: Others
206
214
 
207
215
  - set the middleware proxy address for globalsearchbase [Zoltan Szabo - [`d0a0802`](https://github.com/eea/volto-globalsearch/commit/d0a08026fa73ce8fd15b666c922e7db71104a5d1)]
208
- - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`b710a4f`](https://github.com/eea/volto-globalsearch/commit/b710a4f73f61e164ecf502a83e7f07d0daf578b3)]
209
216
  ### [1.0.12](https://github.com/eea/volto-globalsearch/compare/1.0.11...1.0.12) - 1 March 2023
210
217
 
211
218
  #### :hammer_and_wrench: Others
@@ -273,14 +280,12 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
273
280
  - Make last 2 years default [Tiberiu Ichim - [`ff765e2`](https://github.com/eea/volto-globalsearch/commit/ff765e24a1d93c60f091aeffa7c3156d8fb98e49)]
274
281
  - Add compact listing, placeholder for now [Tiberiu Ichim - [`3f6104f`](https://github.com/eea/volto-globalsearch/commit/3f6104fb1725f7e3c22736a30629f64e4882242a)]
275
282
  - test(Jenkins): Run tests and cypress with latest canary @plone/volto [Alin Voinea - [`8120264`](https://github.com/eea/volto-globalsearch/commit/812026495c31b272e6ae6415642cf1a6b2f783cf)]
276
- - yarn 3 [Alin Voinea - [`b61ad50`](https://github.com/eea/volto-globalsearch/commit/b61ad5075a79bebfce1044a6cd4978c92d98fbdc)]
277
283
  ### [1.0.1](https://github.com/eea/volto-globalsearch/compare/1.0.0...1.0.1) - 16 November 2022
278
284
 
279
285
  #### :hammer_and_wrench: Others
280
286
 
281
287
  - Fix eslint [Tiberiu Ichim - [`cf2886b`](https://github.com/eea/volto-globalsearch/commit/cf2886b412013f9427cf5d39cdf00004bdd9f80b)]
282
288
  - test(estlint): Fix .project.eslintrc.js [Alin Voinea - [`40c08d2`](https://github.com/eea/volto-globalsearch/commit/40c08d2d4eda81ce306225a81f09e0bcfe6794eb)]
283
- - Add Sonarqube tag using circularity-frontend addons list [EEA Jenkins - [`af6e020`](https://github.com/eea/volto-globalsearch/commit/af6e020794798c1f69fee8c08bdf71fc3992230a)]
284
289
  ## [1.0.0](https://github.com/eea/volto-globalsearch/compare/0.1.7...1.0.0) - 28 October 2022
285
290
 
286
291
  #### :nail_care: Enhancements
@@ -299,7 +304,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
299
304
  #### :hammer_and_wrench: Others
300
305
 
301
306
  - Fix dependencies [kreafox - [`50ad307`](https://github.com/eea/volto-globalsearch/commit/50ad307d64140c43df9dded27c0b532923885764)]
302
- - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`c2d848e`](https://github.com/eea/volto-globalsearch/commit/c2d848e1efa456f53d883c50769882101e1ce19f)]
303
307
  ### [0.1.5](https://github.com/eea/volto-globalsearch/compare/0.1.4...0.1.5) - 28 July 2022
304
308
 
305
309
  #### :hammer_and_wrench: Others
@@ -312,7 +316,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
312
316
 
313
317
  #### :hammer_and_wrench: Others
314
318
 
315
- - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`5dce07b`](https://github.com/eea/volto-globalsearch/commit/5dce07ba7d1e82776a426e9746d5dab1b0acf738)]
316
319
  ### [0.1.3](https://github.com/eea/volto-globalsearch/compare/0.1.2...0.1.3) - 10 June 2022
317
320
 
318
321
  ### [0.1.2](https://github.com/eea/volto-globalsearch/compare/0.1.1...0.1.2) - 10 June 2022
@@ -335,7 +338,6 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
335
338
  - ignore eslint for *.json files [Zoltan Szabo - [`e18919e`](https://github.com/eea/volto-globalsearch/commit/e18919e1255818c5cf33bf769cca078d75ca3422)]
336
339
  - formatting [Zoltan Szabo - [`18282ed`](https://github.com/eea/volto-globalsearch/commit/18282ed159865bcbc50e2fd17417cf6d90d3e593)]
337
340
  - updated dependencies [Zoltan Szabo - [`cfcf46e`](https://github.com/eea/volto-globalsearch/commit/cfcf46ee33b23bb31f76955c12a857411f042daf)]
338
- - [JENKINSFILE] fix after bootstrap [valentinab25 - [`61c8c46`](https://github.com/eea/volto-globalsearch/commit/61c8c46891edf3b52768f12cf7505c034ef7bb89)]
339
341
  ### 0.0.1 - 19 May 2022
340
342
 
341
343
  #### :hammer_and_wrench: Others
package/DEVELOP.md CHANGED
@@ -26,21 +26,20 @@
26
26
 
27
27
  ### Or add @eeacms/volto-globalsearch to your Volto project
28
28
 
29
- Before starting make sure your development environment is properly set. See [Volto Developer Documentation](https://docs.voltocms.com/getting-started/install/)
29
+ Before starting make sure your development environment is properly set. See the official Plone documentation for [creating a project with Cookieplone](https://6.docs.plone.org/install/create-project-cookieplone.html) and [installing an add-on in development mode in Volto 18 and 19](https://6.docs.plone.org/volto/development/add-ons/install-an-add-on-dev-18.html).
30
30
 
31
- 1. Make sure you have installed `yo`, `@plone/generator-volto` and `mrs-developer`
31
+ For new Volto 18+ projects, use Cookieplone. It includes `mrs-developer` by default.
32
32
 
33
- npm install -g yo @plone/generator-volto mrs-developer
33
+ 1. Create a new Volto project with Cookieplone
34
34
 
35
- 1. Create new volto app
36
-
37
- yo @plone/volto my-volto-project --addon @eeacms/volto-globalsearch --skip-install
38
- cd my-volto-project
35
+ uvx cookieplone project
36
+ cd project-title
39
37
 
40
38
  1. Add the following to `mrs.developer.json`:
41
39
 
42
40
  {
43
41
  "volto-globalsearch": {
42
+ "output": "packages",
44
43
  "url": "https://github.com/eea/volto-globalsearch.git",
45
44
  "package": "@eeacms/volto-globalsearch",
46
45
  "branch": "develop",
@@ -48,28 +47,31 @@ Before starting make sure your development environment is properly set. See [Vol
48
47
  }
49
48
  }
50
49
 
51
- 1. Install
50
+ 1. Add `@eeacms/volto-globalsearch` to the `addons` key in your project `volto.config.js`
51
+
52
+ 1. Install or refresh the project setup
52
53
 
53
- make develop
54
- yarn
54
+ make install
55
55
 
56
- 1. Start backend
56
+ 1. Start backend in one terminal
57
57
 
58
- docker run --pull always -it --rm --name plone -p 8080:8080 -e SITE=Plone plone/plone-backend
58
+ make backend-start
59
59
 
60
- ...wait for backend to setup and start - `Ready to handle requests`:
60
+ ...wait for backend to setup and start, ending with `Ready to handle requests`
61
61
 
62
62
  ...you can also check http://localhost:8080/Plone
63
63
 
64
- 1. Start frontend
64
+ 1. Start frontend in a second terminal
65
65
 
66
- yarn start
66
+ make frontend-start
67
67
 
68
68
  1. Go to http://localhost:3000
69
69
 
70
70
  1. Happy hacking!
71
71
 
72
- cd src/addons/volto-globalsearch/
72
+ cd packages/volto-globalsearch
73
+
74
+ For legacy Volto 17 projects, keep using the yarn-based workflow from the Volto 17 documentation.
73
75
 
74
76
  ## Cypress
75
77
 
@@ -81,7 +83,7 @@ project where you added `volto-globalsearch` to `mrs.developer.json`
81
83
  Go to:
82
84
 
83
85
  ```BASH
84
- cd src/addons/volto-globalsearch/
86
+ cd packages/volto-globalsearch/
85
87
  ```
86
88
 
87
89
  Start:
package/README.md CHANGED
@@ -3,16 +3,16 @@
3
3
  [![Releases](https://img.shields.io/github/v/release/eea/volto-globalsearch)](https://github.com/eea/volto-globalsearch/releases)
4
4
 
5
5
  [![Pipeline](https://ci.eionet.europa.eu/buildStatus/icon?job=volto-addons%2Fvolto-globalsearch%2Fmaster&subject=master)](https://ci.eionet.europa.eu/view/Github/job/volto-addons/job/volto-globalsearch/job/master/display/redirect)
6
- [![Lines of Code](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-master&metric=ncloc)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-master)
7
- [![Coverage](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-master&metric=coverage)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-master)
8
- [![Bugs](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-master&metric=bugs)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-master)
9
- [![Duplicated Lines (%)](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-master&metric=duplicated_lines_density)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-master)
6
+ [![Lines of Code](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&metric=ncloc)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch)
7
+ [![Coverage](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&metric=coverage)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch)
8
+ [![Bugs](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&metric=bugs)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch)
9
+ [![Duplicated Lines (%)](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&metric=duplicated_lines_density)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch)
10
10
 
11
11
  [![Pipeline](https://ci.eionet.europa.eu/buildStatus/icon?job=volto-addons%2Fvolto-globalsearch%2Fdevelop&subject=develop)](https://ci.eionet.europa.eu/view/Github/job/volto-addons/job/volto-globalsearch/job/develop/display/redirect)
12
- [![Lines of Code](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-develop&metric=ncloc)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-develop)
13
- [![Coverage](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-develop&metric=coverage)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-develop)
14
- [![Bugs](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-develop&metric=bugs)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-develop)
15
- [![Duplicated Lines (%)](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch-develop&metric=duplicated_lines_density)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch-develop)
12
+ [![Lines of Code](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&branch=develop&metric=ncloc)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch&branch=develop)
13
+ [![Coverage](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&branch=develop&metric=coverage)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch&branch=develop)
14
+ [![Bugs](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&branch=develop&metric=bugs)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch&branch=develop)
15
+ [![Duplicated Lines (%)](https://sonarqube.eea.europa.eu/api/project_badges/measure?project=volto-globalsearch&branch=develop&metric=duplicated_lines_density)](https://sonarqube.eea.europa.eu/dashboard?id=volto-globalsearch&branch=develop)
16
16
 
17
17
  EEA Elastic Search Block with NLP integration [Volto](https://github.com/plone/volto) add-on
18
18
 
@@ -35,6 +35,11 @@ EEA Elastic Search Block with NLP integration [Volto](https://github.com/plone/v
35
35
 
36
36
  Go to http://localhost:3000
37
37
 
38
+ `make start` now defaults to Volto 18. To run the same setup against Volto 17, use:
39
+
40
+ VOLTO_VERSION=17 make
41
+ VOLTO_VERSION=17 make start
42
+
38
43
  ### Add volto-globalsearch to your Volto project
39
44
 
40
45
  1. Make sure you have a [Plone backend](https://plone.org/download) up-and-running at http://localhost:8080/Plone
@@ -48,30 +53,39 @@ Go to http://localhost:3000
48
53
  * If you already have a volto project, just update `package.json`:
49
54
 
50
55
  ```JSON
51
- "addons": [
52
- "@eeacms/volto-globalsearch"
53
- ],
54
-
55
56
  "dependencies": {
56
57
  "@eeacms/volto-globalsearch": "*"
57
58
  }
58
59
  ```
59
60
 
60
- * If not, create one:
61
+ and `volto.config.js`:
62
+
63
+ ```JavaScript
64
+ const addons = ['@eeacms/volto-globalsearch'];
65
+ ```
66
+
67
+ * If not, create one with Cookieplone, as recommended by the official Plone documentation for Volto 18+:
61
68
 
62
69
  ```
63
- npm install -g yo @plone/generator-volto
64
- yo @plone/volto my-volto-project --canary --addon @eeacms/volto-globalsearch
65
- cd my-volto-project
70
+ uvx cookieplone project
71
+ cd project-title
66
72
  ```
67
73
 
68
- 1. Install new add-ons and restart Volto:
74
+ 1. Install or update dependencies, then start the project:
69
75
 
70
76
  ```
71
- yarn
72
- yarn start
77
+ make install
73
78
  ```
74
79
 
80
+ For a Cookieplone project, start the backend and frontend in separate terminals:
81
+
82
+ ```
83
+ make backend-start
84
+ make frontend-start
85
+ ```
86
+
87
+ For a legacy Volto 17 project, install the package with `yarn` and restart the frontend as usual.
88
+
75
89
  1. Go to http://localhost:3000
76
90
 
77
91
  1. Happy editing!
@@ -15,7 +15,7 @@ services:
15
15
  args:
16
16
  ADDON_NAME: "${ADDON_NAME}"
17
17
  ADDON_PATH: "${ADDON_PATH}"
18
- VOLTO_VERSION: ${VOLTO_VERSION:-16}
18
+ VOLTO_VERSION: ${VOLTO_VERSION:-18-yarn}
19
19
  ports:
20
20
  - "3000:3000"
21
21
  - "3001:3001"
@@ -1,5 +1,14 @@
1
1
  require('dotenv').config({ path: __dirname + '/.env' });
2
2
 
3
+ const fs = require('fs');
4
+ const path = require('path');
5
+
6
+ const voltoSlatePath = fs.existsSync(
7
+ path.join(__dirname, '../../../node_modules/@plone/volto-slate/src'),
8
+ )
9
+ ? '<rootDir>/node_modules/@plone/volto-slate/src'
10
+ : '<rootDir>/node_modules/@plone/volto/packages/volto-slate/src';
11
+
3
12
  module.exports = {
4
13
  testMatch: ['**/src/addons/**/?(*.)+(spec|test).[jt]s?(x)'],
5
14
  collectCoverageFrom: [
@@ -18,10 +27,8 @@ module.exports = {
18
27
  '<rootDir>/node_modules/@eeacms/volto-searchlib/src/$1',
19
28
  '@eeacms/search': '<rootDir>/node_modules/@eeacms/volto-searchlib/src',
20
29
  '@eeacms/(.*?)/(.*)$': '<rootDir>/node_modules/@eeacms/$1/src/$2',
21
- '@plone/volto-slate$':
22
- '<rootDir>/node_modules/@plone/volto/packages/volto-slate/src',
23
- '@plone/volto-slate/(.*)$':
24
- '<rootDir>/node_modules/@plone/volto/packages/volto-slate/src/$1',
30
+ '@plone/volto-slate$': voltoSlatePath,
31
+ '@plone/volto-slate/(.*)$': `${voltoSlatePath}/$1`,
25
32
  '~/(.*)$': '<rootDir>/src/$1',
26
33
  'load-volto-addons':
27
34
  '<rootDir>/node_modules/@plone/volto/jest-addons-loader.js',
@@ -11,37 +11,37 @@ msgstr ""
11
11
  "Content-Transfer-Encoding: \n"
12
12
  "Plural-Forms: \n"
13
13
 
14
+ #. Default: "Include archived content"
14
15
  #: config/facets
15
- # defaultMessage: Include archived content
16
16
  msgid "Include archived content"
17
17
  msgstr "Включете архивирано съдържание"
18
18
 
19
+ #. Default: "Language"
19
20
  #: config/facets
20
- # defaultMessage: Language
21
21
  msgid "Language"
22
22
  msgstr "език"
23
23
 
24
+ #. Default: "Newest"
24
25
  #: config/global-search-base-config
25
- # defaultMessage: Newest
26
26
  msgid "Newest"
27
27
  msgstr "Най-новите"
28
28
 
29
+ #. Default: "Oldest"
29
30
  #: config/global-search-base-config
30
- # defaultMessage: Oldest
31
31
  msgid "Oldest"
32
32
  msgstr "Най-старият"
33
33
 
34
+ #. Default: "Relevance"
34
35
  #: config/global-search-base-config
35
- # defaultMessage: Relevance
36
36
  msgid "Relevance"
37
37
  msgstr "Уместност"
38
38
 
39
+ #. Default: "Title a-z"
39
40
  #: config/global-search-base-config
40
- # defaultMessage: Title a-z
41
41
  msgid "Title a-z"
42
42
  msgstr "Заглавие a-z"
43
43
 
44
+ #. Default: "Title z-a"
44
45
  #: config/global-search-base-config
45
- # defaultMessage: Title z-a
46
46
  msgid "Title z-a"
47
47
  msgstr "Заглавие z-a"
@@ -11,37 +11,37 @@ msgstr ""
11
11
  "Content-Transfer-Encoding: \n"
12
12
  "Plural-Forms: \n"
13
13
 
14
+ #. Default: "Include archived content"
14
15
  #: config/facets
15
- # defaultMessage: Include archived content
16
16
  msgid "Include archived content"
17
17
  msgstr "Zahrnout archivovaný obsah"
18
18
 
19
+ #. Default: "Language"
19
20
  #: config/facets
20
- # defaultMessage: Language
21
21
  msgid "Language"
22
22
  msgstr "Jazyk"
23
23
 
24
+ #. Default: "Newest"
24
25
  #: config/global-search-base-config
25
- # defaultMessage: Newest
26
26
  msgid "Newest"
27
27
  msgstr "Nejnovější"
28
28
 
29
+ #. Default: "Oldest"
29
30
  #: config/global-search-base-config
30
- # defaultMessage: Oldest
31
31
  msgid "Oldest"
32
32
  msgstr "Nejstarší"
33
33
 
34
+ #. Default: "Relevance"
34
35
  #: config/global-search-base-config
35
- # defaultMessage: Relevance
36
36
  msgid "Relevance"
37
37
  msgstr "Relevance"
38
38
 
39
+ #. Default: "Title a-z"
39
40
  #: config/global-search-base-config
40
- # defaultMessage: Title a-z
41
41
  msgid "Title a-z"
42
42
  msgstr "Titul a-z"
43
43
 
44
+ #. Default: "Title z-a"
44
45
  #: config/global-search-base-config
45
- # defaultMessage: Title z-a
46
46
  msgid "Title z-a"
47
47
  msgstr "Titul z-a"
@@ -11,37 +11,37 @@ msgstr ""
11
11
  "Content-Transfer-Encoding: \n"
12
12
  "Plural-Forms: \n"
13
13
 
14
+ #. Default: "Include archived content"
14
15
  #: config/facets
15
- # defaultMessage: Include archived content
16
16
  msgid "Include archived content"
17
17
  msgstr "Archivierte Inhalte einbeziehen"
18
18
 
19
+ #. Default: "Language"
19
20
  #: config/facets
20
- # defaultMessage: Language
21
21
  msgid "Language"
22
22
  msgstr "Sprache"
23
23
 
24
+ #. Default: "Newest"
24
25
  #: config/global-search-base-config
25
- # defaultMessage: Newest
26
26
  msgid "Newest"
27
27
  msgstr "Neueste"
28
28
 
29
+ #. Default: "Oldest"
29
30
  #: config/global-search-base-config
30
- # defaultMessage: Oldest
31
31
  msgid "Oldest"
32
32
  msgstr "Älteste"
33
33
 
34
+ #. Default: "Relevance"
34
35
  #: config/global-search-base-config
35
- # defaultMessage: Relevance
36
36
  msgid "Relevance"
37
37
  msgstr "Relevanz"
38
38
 
39
+ #. Default: "Title a-z"
39
40
  #: config/global-search-base-config
40
- # defaultMessage: Title a-z
41
41
  msgid "Title a-z"
42
42
  msgstr "Titel a-z"
43
43
 
44
+ #. Default: "Title z-a"
44
45
  #: config/global-search-base-config
45
- # defaultMessage: Title z-a
46
46
  msgid "Title z-a"
47
47
  msgstr "Titel z-a"
@@ -11,37 +11,37 @@ msgstr ""
11
11
  "Content-Transfer-Encoding: \n"
12
12
  "Plural-Forms: \n"
13
13
 
14
+ #. Default: "Include archived content"
14
15
  #: config/facets
15
- # defaultMessage: Include archived content
16
16
  msgid "Include archived content"
17
17
  msgstr ""
18
18
 
19
+ #. Default: "Language"
19
20
  #: config/facets
20
- # defaultMessage: Language
21
21
  msgid "Language"
22
22
  msgstr ""
23
23
 
24
+ #. Default: "Newest"
24
25
  #: config/global-search-base-config
25
- # defaultMessage: Newest
26
26
  msgid "Newest"
27
27
  msgstr ""
28
28
 
29
+ #. Default: "Oldest"
29
30
  #: config/global-search-base-config
30
- # defaultMessage: Oldest
31
31
  msgid "Oldest"
32
32
  msgstr ""
33
33
 
34
+ #. Default: "Relevance"
34
35
  #: config/global-search-base-config
35
- # defaultMessage: Relevance
36
36
  msgid "Relevance"
37
37
  msgstr ""
38
38
 
39
+ #. Default: "Title a-z"
39
40
  #: config/global-search-base-config
40
- # defaultMessage: Title a-z
41
41
  msgid "Title a-z"
42
42
  msgstr ""
43
43
 
44
+ #. Default: "Title z-a"
44
45
  #: config/global-search-base-config
45
- # defaultMessage: Title z-a
46
46
  msgid "Title z-a"
47
47
  msgstr ""
@@ -11,37 +11,37 @@ msgstr ""
11
11
  "Content-Transfer-Encoding: \n"
12
12
  "Plural-Forms: \n"
13
13
 
14
+ #. Default: "Include archived content"
14
15
  #: config/facets
15
- # defaultMessage: Include archived content
16
16
  msgid "Include archived content"
17
17
  msgstr "Incluir contenido archivado"
18
18
 
19
+ #. Default: "Language"
19
20
  #: config/facets
20
- # defaultMessage: Language
21
21
  msgid "Language"
22
22
  msgstr "Idioma"
23
23
 
24
+ #. Default: "Newest"
24
25
  #: config/global-search-base-config
25
- # defaultMessage: Newest
26
26
  msgid "Newest"
27
27
  msgstr "El más nuevo"
28
28
 
29
+ #. Default: "Oldest"
29
30
  #: config/global-search-base-config
30
- # defaultMessage: Oldest
31
31
  msgid "Oldest"
32
32
  msgstr "Más antiguo"
33
33
 
34
+ #. Default: "Relevance"
34
35
  #: config/global-search-base-config
35
- # defaultMessage: Relevance
36
36
  msgid "Relevance"
37
37
  msgstr "Pertinencia"
38
38
 
39
+ #. Default: "Title a-z"
39
40
  #: config/global-search-base-config
40
- # defaultMessage: Title a-z
41
41
  msgid "Title a-z"
42
42
  msgstr "Título a-z"
43
43
 
44
+ #. Default: "Title z-a"
44
45
  #: config/global-search-base-config
45
- # defaultMessage: Title z-a
46
46
  msgid "Title z-a"
47
47
  msgstr "Título z-a"
@@ -11,37 +11,37 @@ msgstr ""
11
11
  "Content-Transfer-Encoding: \n"
12
12
  "Plural-Forms: \n"
13
13
 
14
+ #. Default: "Include archived content"
14
15
  #: config/facets
15
- # defaultMessage: Include archived content
16
16
  msgid "Include archived content"
17
17
  msgstr "Kaasake arhiveeritud sisu"
18
18
 
19
+ #. Default: "Language"
19
20
  #: config/facets
20
- # defaultMessage: Language
21
21
  msgid "Language"
22
22
  msgstr "Keel"
23
23
 
24
+ #. Default: "Newest"
24
25
  #: config/global-search-base-config
25
- # defaultMessage: Newest
26
26
  msgid "Newest"
27
27
  msgstr "Uusim"
28
28
 
29
+ #. Default: "Oldest"
29
30
  #: config/global-search-base-config
30
- # defaultMessage: Oldest
31
31
  msgid "Oldest"
32
32
  msgstr "Vanim"
33
33
 
34
+ #. Default: "Relevance"
34
35
  #: config/global-search-base-config
35
- # defaultMessage: Relevance
36
36
  msgid "Relevance"
37
37
  msgstr "Asjakohasus"
38
38
 
39
+ #. Default: "Title a-z"
39
40
  #: config/global-search-base-config
40
- # defaultMessage: Title a-z
41
41
  msgid "Title a-z"
42
42
  msgstr "Pealkiri a-z"
43
43
 
44
+ #. Default: "Title z-a"
44
45
  #: config/global-search-base-config
45
- # defaultMessage: Title z-a
46
46
  msgid "Title z-a"
47
47
  msgstr "Pealkiri z-a"