@eeacms/volto-arcgis-block 0.1.184 → 0.1.185

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
+ ### [0.1.185](https://github.com/eea/volto-arcgis-block/compare/0.1.184...0.1.185) - 23 August 2023
8
+
9
+ #### :hammer_and_wrench: Others
10
+
11
+ - test: Update Makefile and docker-compose to align it with Jenkinsfile [valentinab25 - [`6eca911`](https://github.com/eea/volto-arcgis-block/commit/6eca911654c9b73edda8556ce3ad8f94f09dccb7)]
7
12
  ### [0.1.184](https://github.com/eea/volto-arcgis-block/compare/0.1.183...0.1.184) - 21 August 2023
8
13
 
9
14
  #### :hammer_and_wrench: Others
package/Makefile CHANGED
@@ -70,6 +70,11 @@ start: ## Start development environment
70
70
  echo "Running: ${DOCKER_COMPOSE} up"
71
71
  ${DOCKER_COMPOSE} up
72
72
 
73
+ .PHONY: shell
74
+ shell: ## Start a shell in the frontend container
75
+ echo "Running: ${DOCKER_COMPOSE} run frontend bash"
76
+ ${DOCKER_COMPOSE} run --entrypoint=bash frontend
77
+
73
78
  .PHONY: cypress-open
74
79
  cypress-open: ## Open cypress integration tests
75
80
  NODE_ENV=development $(NODE_MODULES)/cypress/bin/cypress open
@@ -1,11 +1,12 @@
1
1
  version: "3"
2
2
  services:
3
3
  backend:
4
- image: plone/plone-backend:${PLONE_VERSION:-6}
4
+ image: eeacms/plone-backend
5
5
  ports:
6
6
  - "8080:8080"
7
7
  environment:
8
8
  SITE: "Plone"
9
+ PROFILES: "eea.kitkat:testing"
9
10
 
10
11
  frontend:
11
12
  build:
@@ -23,6 +24,9 @@ services:
23
24
  volumes:
24
25
  - ./:/app/src/addons/${ADDON_PATH}
25
26
  environment:
27
+ CI: "true"
28
+ NODE_ENV: "development"
29
+ RAZZLE_JEST_CONFIG: "src/addons/${ADDON_PATH}/jest-addon.config.js"
26
30
  RAZZLE_INTERNAL_API_PATH: "http://backend:8080/Plone"
27
31
  RAZZLE_DEV_PROXY_API_PATH: "http://backend:8080/Plone"
28
32
  HOST: "0.0.0.0"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@eeacms/volto-arcgis-block",
3
- "version": "0.1.184",
3
+ "version": "0.1.185",
4
4
  "description": "volto-arcgis-block: Volto add-on",
5
5
  "main": "src/index.js",
6
6
  "author": "European Environment Agency: CodeSyntax",
@@ -92,12 +92,16 @@ class BookmarkWidget extends React.Component {
92
92
 
93
93
  this.Bookmarks.when(() => {
94
94
  this.Bookmarks.bookmarks.on('change', () => {
95
- if (this.userID != null) {
95
+ localStorage.setItem(
96
+ BOOKMARK_SESSION_KEY + '_' + this.userID,
97
+ JSON.stringify(this.Bookmarks.bookmarks.items),
98
+ );
99
+ /*if (this.userID != null) {
96
100
  localStorage.setItem(
97
101
  BOOKMARK_SESSION_KEY + '_' + this.userID,
98
102
  JSON.stringify(this.Bookmarks.bookmarks.items),
99
103
  );
100
- }
104
+ }*/
101
105
  });
102
106
  this.Bookmarks.on('bookmark-edit', () => {
103
107
  if (this.userID != null) {
@@ -416,34 +416,19 @@ export const CheckLogin = ({ reference }) => {
416
416
  );
417
417
  };
418
418
  export const CheckUserID = ({ reference }) => {
419
- let { user_id, isLoggedIn } = useCartState();
420
- if (isLoggedIn) {
421
- return (
422
- <>
423
- {
424
- <BookmarkWidget
425
- view={reference.view}
426
- map={reference.map}
427
- mapViewer={reference}
428
- userID={user_id}
429
- />
430
- }
431
- </>
432
- );
433
- } else {
434
- return (
435
- <>
436
- {
437
- <BookmarkWidget
438
- view={reference.view}
439
- map={reference.map}
440
- mapViewer={reference}
441
- userID={null}
442
- />
443
- }
444
- </>
445
- );
446
- }
419
+ let { user_id } = useCartState();
420
+ return (
421
+ <>
422
+ {
423
+ <BookmarkWidget
424
+ view={reference.view}
425
+ map={reference.map}
426
+ mapViewer={reference}
427
+ userID={user_id}
428
+ />
429
+ }
430
+ </>
431
+ );
447
432
  };
448
433
 
449
434
  export default compose(