@eeacms/volto-tableau 5.0.0 → 5.0.2

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.
@@ -0,0 +1,2 @@
1
+ [ -n "$CI" ] && exit 0
2
+ yarn lint-staged
package/CHANGELOG.md CHANGED
@@ -4,7 +4,60 @@ 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
- ### [5.0.0](https://github.com/eea/volto-tableau/compare/4.1.1...5.0.0) - 25 July 2023
7
+ ### [5.0.2](https://github.com/eea/volto-tableau/compare/5.0.1...5.0.2) - 23 October 2023
8
+
9
+ #### :rocket: New Features
10
+
11
+ - feat: share option, design improvements [dana-cfc4 - [`a8d7ba1`](https://github.com/eea/volto-tableau/commit/a8d7ba18753451e2d9aaff3ecb3704a92e47681f)]
12
+ - feat: redesign download options [dana-cfc4 - [`96f2f3a`](https://github.com/eea/volto-tableau/commit/96f2f3adbdccf3629f95a5222ebfd2eaf3bc1b5c)]
13
+
14
+ #### :bug: Bug Fixes
15
+
16
+ - fix: format variables [dana-cfc4 - [`d9a6b41`](https://github.com/eea/volto-tableau/commit/d9a6b41ab532772c23d2df45dca8fb60f40df9d8)]
17
+ - fix: define @grey-1 less variable [dana-cfc4 - [`048c3a3`](https://github.com/eea/volto-tableau/commit/048c3a375923e6a34fa00ccdc63c59040850b5b8)]
18
+ - fix: align sources with other viz [dana-cfc4 - [`b0e38bd`](https://github.com/eea/volto-tableau/commit/b0e38bd2d83e1148e4f706cc9448ec9361bfae6c)]
19
+ - fix: same background colour for popups, remove background color for embed tableau [dana-cfc4 - [`bb73a31`](https://github.com/eea/volto-tableau/commit/bb73a310311882cdd82c9a7d22c57374d563557b)]
20
+ - fix: fix case when notes don't exist [dana-cfc4 - [`a204dc3`](https://github.com/eea/volto-tableau/commit/a204dc31f8b69f92885ae0056ea8596c32ae315e)]
21
+ - fix: volto version 16 [dana-cfc4 - [`b079f47`](https://github.com/eea/volto-tableau/commit/b079f47b94cb23d366f972096ecca645e26463bb)]
22
+ - fix: display message when notes don't exist [dana-cfc4 - [`c8943db`](https://github.com/eea/volto-tableau/commit/c8943db5b7c01d4a71ec65d9953cb1755046edc3)]
23
+ - fix: display figure note [dana-cfc4 - [`f8b4e6d`](https://github.com/eea/volto-tableau/commit/f8b4e6dd257aa64956f7e01a70c10a95eb48546d)]
24
+ - fix: lint [dana-cfc4 - [`7ec0cd1`](https://github.com/eea/volto-tableau/commit/7ec0cd134ef66ee58e532b987900c7c43f5aae1c)]
25
+ - fix: fix stylelint [dana-cfc4 - [`1b39f16`](https://github.com/eea/volto-tableau/commit/1b39f160b3b82716b7c568811ecd243bc35dc982)]
26
+
27
+ #### :house: Internal changes
28
+
29
+ - chore: husky, lint-staged use fixed versions [valentinab25 - [`f7ea803`](https://github.com/eea/volto-tableau/commit/f7ea803e032e27eab2193c4424d05afbca5fb6bc)]
30
+ - chore: display sources for block [dana-cfc4 - [`d064508`](https://github.com/eea/volto-tableau/commit/d0645087ecf79af73b3e69d9263229b82e339b37)]
31
+ - chore: display figureNote, add more tests [dana-cfc4 - [`7c8deb9`](https://github.com/eea/volto-tableau/commit/7c8deb94f721f2efe9a1373e162831a791cedf88)]
32
+ - chore: add more tests [dana-cfc4 - [`bf463a9`](https://github.com/eea/volto-tableau/commit/bf463a9223748506ed77d4e632d8a7a2b4eb5a13)]
33
+ - chore: add tests [dana-cfc4 - [`28cad5a`](https://github.com/eea/volto-tableau/commit/28cad5afebef69f8bf2c01531d4cae0ee7260b2f)]
34
+ - chore: add notes and more info, remove sources and share -refs#257682 [dana-cfc4 - [`23127dc`](https://github.com/eea/volto-tableau/commit/23127dcb1a9d682920f1fd8e24fd0f494f7aa8d1)]
35
+
36
+ #### :hammer_and_wrench: Others
37
+
38
+ - Fix maxVizResizeAttempts error [laszlocseh - [`66fa0e2`](https://github.com/eea/volto-tableau/commit/66fa0e2c9d4860373af107470158b68df4fd793f)]
39
+ ### [5.0.1](https://github.com/eea/volto-tableau/compare/5.0.0...5.0.1) - 12 October 2023
40
+
41
+ #### :house: Internal changes
42
+
43
+ - chore:volto 16 in tests, update docs, fix stylelint overrides [valentinab25 - [`b59b145`](https://github.com/eea/volto-tableau/commit/b59b14508c169c364d4b2fd79f670b275bb41ae2)]
44
+ - style: lint-staged reorder in package.json [Alin Voinea - [`8d49c01`](https://github.com/eea/volto-tableau/commit/8d49c0133bfa06699f6d4260784ba483d04f3dd1)]
45
+
46
+ #### :house: Documentation changes
47
+
48
+ - docs: Update README and DEVELOP [Alin Voinea - [`354dc34`](https://github.com/eea/volto-tableau/commit/354dc3468a9ae124398710af6e61f11382f61607)]
49
+ - docs: Update README and DEVELOP [Alin Voinea - [`6104ff9`](https://github.com/eea/volto-tableau/commit/6104ff9978abe872bcffbc9257173887b622d533)]
50
+ - docs: Cleanup Makefile, update DEVELOP documentation, i18n - refs #254894 [valentinab25 - [`8f58341`](https://github.com/eea/volto-tableau/commit/8f58341dcccabde9e605a6b3abace49e1a1e31b3)]
51
+
52
+ #### :hammer_and_wrench: Others
53
+
54
+ - test: change volto version in Jenkinsfile [ana-oprea - [`347aceb`](https://github.com/eea/volto-tableau/commit/347aceb07d152fddeebbf3a7e7a6ac9c55dc21ba)]
55
+ - test: increase cypress timeout [ana-oprea - [`bdf4408`](https://github.com/eea/volto-tableau/commit/bdf44083cd84c96b4914d3f8a3bb17c5187f191c)]
56
+ - test: EN locales, pre-commit fix, feature PRs checks Refs #257193 [valentinab25 - [`caff974`](https://github.com/eea/volto-tableau/commit/caff9742a703b224133a8dd2a969629e70c9fd33)]
57
+ - test: Fix eslint and yarn i18n [Alin Voinea - [`b8be7fb`](https://github.com/eea/volto-tableau/commit/b8be7fb9ab10faed0a1be8ce7e3d4e7c78ebe020)]
58
+ - i18n: Add en [Alin Voinea - [`c5e20dd`](https://github.com/eea/volto-tableau/commit/c5e20ddea25c830ac80665ee9a71e557e8cd117d)]
59
+ - test: Update Makefile and docker-compose to align it with Jenkinsfile [valentinab25 - [`2116ff9`](https://github.com/eea/volto-tableau/commit/2116ff95c6454e813bdca44e6c3aa81fa0a916b8)]
60
+ ## [5.0.0](https://github.com/eea/volto-tableau/compare/4.1.1...5.0.0) - 25 July 2023
8
61
 
9
62
  #### :nail_care: Enhancements
10
63
 
@@ -13,17 +66,21 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
13
66
  #### :hammer_and_wrench: Others
14
67
 
15
68
  - Release 5.0.0 [Alin Voinea - [`97c98e9`](https://github.com/eea/volto-tableau/commit/97c98e98b1295a4ad45756326dc20cd59517515f)]
69
+ - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`2acb3a5`](https://github.com/eea/volto-tableau/commit/2acb3a5490f62ce0a95ebbd03c32874ac3a42603)]
16
70
  ### [4.1.1](https://github.com/eea/volto-tableau/compare/4.1.0...4.1.1) - 21 July 2023
17
71
 
18
72
  #### :hammer_and_wrench: Others
19
73
 
20
74
  - Add VisualizationViewWidget [Tiberiu Ichim - [`fa881cb`](https://github.com/eea/volto-tableau/commit/fa881cbc3643a46697fb16d1c86ada1d4121a46a)]
75
+ - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`cbcbad2`](https://github.com/eea/volto-tableau/commit/cbcbad26f7aa3683122199c8d5cbd142903df93b)]
76
+ - Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`51abe6d`](https://github.com/eea/volto-tableau/commit/51abe6d4db80825fe2e396e04c7003c6ad79b480)]
21
77
  ### [4.1.0](https://github.com/eea/volto-tableau/compare/4.0.0...4.1.0) - 15 June 2023
22
78
 
23
79
  ## [4.0.0](https://github.com/eea/volto-tableau/compare/3.0.8...4.0.0) - 13 June 2023
24
80
 
25
81
  #### :house: Internal changes
26
82
 
83
+ - chore: [JENKINS] Remove alpha testing version [valentinab25 - [`e33bb21`](https://github.com/eea/volto-tableau/commit/e33bb21eb429c33e3a15d771487a1c9af8ccb0d5)]
27
84
 
28
85
  #### :hammer_and_wrench: Others
29
86
 
@@ -55,6 +112,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
55
112
 
56
113
  #### :hammer_and_wrench: Others
57
114
 
115
+ - Add Sonarqube tag using industry-frontend addons list [EEA Jenkins - [`f5deccd`](https://github.com/eea/volto-tableau/commit/f5deccd84372752908b300c5cfd78134818e5ce4)]
58
116
  ### [3.0.6](https://github.com/eea/volto-tableau/compare/3.0.5...3.0.6) - 30 January 2023
59
117
 
60
118
  ### [3.0.5](https://github.com/eea/volto-tableau/compare/3.0.4...3.0.5) - 26 January 2023
@@ -126,6 +184,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
126
184
  - Update commands.js [Nilesh - [`7c48437`](https://github.com/eea/volto-tableau/commit/7c4843780efb9b85a4728de73c00d831c1d8fdcf)]
127
185
  - Update e2e.js [Nilesh - [`f67b45c`](https://github.com/eea/volto-tableau/commit/f67b45c170f58f8d0301192994226f173e4cb00a)]
128
186
  - latest volto compatibility refs #154757 [nileshgulia1 - [`881ba48`](https://github.com/eea/volto-tableau/commit/881ba482dc9b82e7fdac16549d41e80a6d26b3de)]
187
+ - Add Sonarqube tag using marine-frontend addons list [EEA Jenkins - [`58e25df`](https://github.com/eea/volto-tableau/commit/58e25df2291add09670143bee54cde103ee835b9)]
129
188
  ### [1.3.0](https://github.com/eea/volto-tableau/compare/1.2.5...1.3.0) - 28 September 2022
130
189
 
131
190
  #### :hammer_and_wrench: Others
@@ -139,11 +198,15 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
139
198
  - Use volto 16 alpha 14 [Miu Razvan - [`93641be`](https://github.com/eea/volto-tableau/commit/93641be4c2393f49008aff789400cf7c947949fd)]
140
199
  - Revert volto-tableau group to common [Andrei Grigore - [`9d24c6d`](https://github.com/eea/volto-tableau/commit/9d24c6d2767fed6a840cddaee55dbd5cecb544b5)]
141
200
  - Tableaugroup typo fix [Andrei Grigore - [`b0b5378`](https://github.com/eea/volto-tableau/commit/b0b5378a437043120a96c9e5e8802584145daa22)]
201
+ - Add Sonarqube tag using freshwater-frontend addons list [EEA Jenkins - [`3234347`](https://github.com/eea/volto-tableau/commit/3234347e524cc0ed4918242f503fe9e7dba266b2)]
142
202
  - Refs #142010 - Optimize Volto-addons gitflow pipelines [valentinab25 - [`d237e1c`](https://github.com/eea/volto-tableau/commit/d237e1c72817d7e68a3eb698563674d1514db24f)]
143
203
  ### [1.2.4](https://github.com/eea/volto-tableau/compare/1.2.3...1.2.4) - 25 October 2021
144
204
 
145
205
  #### :hammer_and_wrench: Others
146
206
 
207
+ - Add Sonarqube tag using frontend addons list [EEA Jenkins - [`2b19679`](https://github.com/eea/volto-tableau/commit/2b19679e2c7bcdc83082d1c73a595eea8b86d14f)]
208
+ - Add Sonarqube tag using frontend addons list [EEA Jenkins - [`384ccae`](https://github.com/eea/volto-tableau/commit/384ccaebed8c414a5c90eb96c6ce0a2b091f249c)]
209
+ - Add Sonarqube tag using frontend addons list [EEA Jenkins - [`589258e`](https://github.com/eea/volto-tableau/commit/589258e9b3cbba9cee37c57bb85ca5b707bc65d7)]
147
210
  ### [1.2.3](https://github.com/eea/volto-tableau/compare/1.2.2...1.2.3) - 14 June 2021
148
211
 
149
212
  #### :hammer_and_wrench: Others
package/DEVELOP.md CHANGED
@@ -2,6 +2,30 @@
2
2
 
3
3
  ## Develop
4
4
 
5
+ 1. Make sure you have `docker` and `docker compose` installed and running on your machine:
6
+
7
+ ```Bash
8
+ git clone https://github.com/eea/volto-tableau.git
9
+ cd volto-tableau
10
+ git checkout -b bugfix-123456 develop
11
+ make
12
+ make start
13
+ ```
14
+
15
+ 1. Wait for `Volto started at 0.0.0.0:3000` meesage
16
+
17
+ 1. Go to http://localhost:3000
18
+
19
+ 1. Initialize git hooks
20
+
21
+ ```Bash
22
+ yarn prepare
23
+ ```
24
+
25
+ 1. Happy hacking!
26
+
27
+ ### Or add @eeacms/volto-tableau to your Volto project
28
+
5
29
  Before starting make sure your development environment is properly set. See [Volto Developer Documentation](https://docs.voltocms.com/getting-started/install/)
6
30
 
7
31
  1. Make sure you have installed `yo`, `@plone/generator-volto` and `mrs-developer`
@@ -26,18 +50,15 @@ Before starting make sure your development environment is properly set. See [Vol
26
50
 
27
51
  1. Install
28
52
 
29
- yarn develop
53
+ make develop
30
54
  yarn
31
55
 
32
56
  1. Start backend
33
57
 
34
- docker pull plone
35
- docker run -d --name plone -p 8080:8080 -e SITE=Plone -e PROFILES="profile-plone.restapi:blocks" plone
58
+ docker run --pull always -it --rm --name plone -p 8080:8080 -e SITE=Plone plone/plone-backend
36
59
 
37
60
  ...wait for backend to setup and start - `Ready to handle requests`:
38
61
 
39
- docker logs -f plone
40
-
41
62
  ...you can also check http://localhost:8080/Plone
42
63
 
43
64
  1. Start frontend
@@ -48,4 +69,38 @@ Before starting make sure your development environment is properly set. See [Vol
48
69
 
49
70
  1. Happy hacking!
50
71
 
51
- cd src/addons/volto-tableau/
72
+ cd src/addons/volto-tableau/
73
+
74
+ ## Cypress
75
+
76
+ To run cypress locally, first make sure you don't have any Volto/Plone running on ports `8080` and `3000`.
77
+
78
+ You don't have to be in a `clean-volto-project`, you can be in any Volto Frontend
79
+ project where you added `volto-tableau` to `mrs.developer.json`
80
+
81
+ Go to:
82
+
83
+ ```BASH
84
+ cd src/addons/volto-tableau/
85
+ ```
86
+
87
+ Start:
88
+
89
+ ```Bash
90
+ make
91
+ make start
92
+ ```
93
+
94
+ This will build and start with Docker a clean `Plone backend` and `Volto Frontend` with `volto-tableau` block installed.
95
+
96
+ Open Cypress Interface:
97
+
98
+ ```Bash
99
+ make cypress-open
100
+ ```
101
+
102
+ Or run it:
103
+
104
+ ```Bash
105
+ make cypress-run
106
+ ```
package/Dockerfile ADDED
@@ -0,0 +1,14 @@
1
+ # syntax=docker/dockerfile:1
2
+ ARG VOLTO_VERSION
3
+ FROM plone/frontend-builder:${VOLTO_VERSION}
4
+
5
+ ARG ADDON_NAME
6
+ ARG ADDON_PATH
7
+
8
+ COPY --chown=node:node ./ /app/src/addons/${ADDON_PATH}/
9
+
10
+ RUN /setupAddon
11
+ RUN yarn install
12
+
13
+ ENTRYPOINT ["yarn"]
14
+ CMD ["start"]
package/Jenkinsfile CHANGED
@@ -6,7 +6,7 @@ pipeline {
6
6
  NAMESPACE = "@eeacms"
7
7
  SONARQUBE_TAGS = "volto.eea.europa.eu,climate-energy.eea.europa.eu,forest.eea.europa.eu,biodiversity.europa.eu,water.europa.eu-freshwater,water.europa.eu-marine,industry.eea.europa.eu,demo-www.eea.europa.eu,www.eea.europa.eu-en"
8
8
  DEPENDENCIES = ""
9
- VOLTO = ""
9
+ VOLTO = "16"
10
10
  }
11
11
 
12
12
  stages {
@@ -62,11 +62,17 @@ pipeline {
62
62
 
63
63
  stage('Tests') {
64
64
  when {
65
- allOf {
66
- environment name: 'CHANGE_ID', value: ''
67
- anyOf {
68
- not { changelog '.*^Automated release [0-9\\.]+$' }
69
- branch 'master'
65
+ anyOf {
66
+ allOf {
67
+ not { environment name: 'CHANGE_ID', value: '' }
68
+ environment name: 'CHANGE_TARGET', value: 'develop'
69
+ }
70
+ allOf {
71
+ environment name: 'CHANGE_ID', value: ''
72
+ anyOf {
73
+ not { changelog '.*^Automated release [0-9\\.]+$' }
74
+ branch 'master'
75
+ }
70
76
  }
71
77
  }
72
78
  }
@@ -110,11 +116,17 @@ pipeline {
110
116
 
111
117
  stage('Integration tests') {
112
118
  when {
113
- allOf {
114
- environment name: 'CHANGE_ID', value: ''
115
- anyOf {
116
- not { changelog '.*^Automated release [0-9\\.]+$' }
117
- branch 'master'
119
+ anyOf {
120
+ allOf {
121
+ not { environment name: 'CHANGE_ID', value: '' }
122
+ environment name: 'CHANGE_TARGET', value: 'develop'
123
+ }
124
+ allOf {
125
+ environment name: 'CHANGE_ID', value: ''
126
+ anyOf {
127
+ not { changelog '.*^Automated release [0-9\\.]+$' }
128
+ branch 'master'
129
+ }
118
130
  }
119
131
  }
120
132
  }
@@ -167,13 +179,19 @@ pipeline {
167
179
 
168
180
  stage('Report to SonarQube') {
169
181
  when {
170
- allOf {
171
- environment name: 'CHANGE_ID', value: ''
172
- anyOf {
173
- branch 'master'
174
- allOf {
175
- branch 'develop'
176
- not { changelog '.*^Automated release [0-9\\.]+$' }
182
+ anyOf {
183
+ allOf {
184
+ not { environment name: 'CHANGE_ID', value: '' }
185
+ environment name: 'CHANGE_TARGET', value: 'develop'
186
+ }
187
+ allOf {
188
+ environment name: 'CHANGE_ID', value: ''
189
+ anyOf {
190
+ allOf {
191
+ branch 'develop'
192
+ not { changelog '.*^Automated release [0-9\\.]+$' }
193
+ }
194
+ branch 'master'
177
195
  }
178
196
  }
179
197
  }
@@ -197,6 +215,37 @@ pipeline {
197
215
  }
198
216
  }
199
217
 
218
+ stage('SonarQube compare to master') {
219
+ when {
220
+ anyOf {
221
+ allOf {
222
+ not { environment name: 'CHANGE_ID', value: '' }
223
+ environment name: 'CHANGE_TARGET', value: 'develop'
224
+ }
225
+ allOf {
226
+ environment name: 'CHANGE_ID', value: ''
227
+ branch 'develop'
228
+ not { changelog '.*^Automated release [0-9\\.]+$' }
229
+ }
230
+ }
231
+ }
232
+ steps {
233
+ node(label: 'docker') {
234
+ script {
235
+ sh '''docker pull eeacms/gitflow'''
236
+ sh '''echo "Error" > checkresult.txt'''
237
+ catchError(buildResult: 'FAILURE', stageResult: 'FAILURE') {
238
+ sh '''set -o pipefail; docker run -i --rm --name="$BUILD_TAG-gitflow-sn" -e GIT_BRANCH="$BRANCH_NAME" -e GIT_NAME="$GIT_NAME" eeacms/gitflow /checkSonarqubemaster.sh | grep -v "Found script" | tee checkresult.txt'''
239
+ }
240
+
241
+ publishChecks name: 'SonarQube', title: 'Sonarqube Code Quality Check', summary: "Quality check on the SonarQube metrics from branch develop, comparing it with the ones from master branch. No bugs are allowed",
242
+ text: readFile(file: 'checkresult.txt'), conclusion: "${currentBuild.currentResult}",
243
+ detailsURL: "${env.BUILD_URL}display/redirect"
244
+ }
245
+ }
246
+ }
247
+ }
248
+
200
249
  stage('Pull Request') {
201
250
  when {
202
251
  not {
package/Makefile ADDED
@@ -0,0 +1,131 @@
1
+ ##############################################################################
2
+ # Run:
3
+ # make
4
+ # make start
5
+ #
6
+ # Go to:
7
+ #
8
+ # http://localhost:3000
9
+ #
10
+ # Cypress:
11
+ #
12
+ # make cypress-open
13
+ #
14
+ ##############################################################################
15
+ # SETUP MAKE
16
+ #
17
+ ## Defensive settings for make: https://tech.davis-hansson.com/p/make/
18
+ SHELL:=bash
19
+ .ONESHELL:
20
+ # for Makefile debugging purposes add -x to the .SHELLFLAGS
21
+ .SHELLFLAGS:=-eu -o pipefail -O inherit_errexit -c
22
+ .SILENT:
23
+ .DELETE_ON_ERROR:
24
+ MAKEFLAGS+=--warn-undefined-variables
25
+ MAKEFLAGS+=--no-builtin-rules
26
+
27
+ # Colors
28
+ # OK=Green, warn=yellow, error=red
29
+ ifeq ($(TERM),)
30
+ # no colors if not in terminal
31
+ MARK_COLOR=
32
+ OK_COLOR=
33
+ WARN_COLOR=
34
+ ERROR_COLOR=
35
+ NO_COLOR=
36
+ else
37
+ MARK_COLOR=`tput setaf 6`
38
+ OK_COLOR=`tput setaf 2`
39
+ WARN_COLOR=`tput setaf 3`
40
+ ERROR_COLOR=`tput setaf 1`
41
+ NO_COLOR=`tput sgr0`
42
+ endif
43
+
44
+ ##############################################################################
45
+ # SETTINGS AND VARIABLE
46
+ DIR=$(shell basename $$(pwd))
47
+ NODE_MODULES?="../../../node_modules"
48
+ PLONE_VERSION?=6
49
+ VOLTO_VERSION?=16
50
+ ADDON_PATH="${DIR}"
51
+ ADDON_NAME="@eeacms/${ADDON_PATH}"
52
+ DOCKER_COMPOSE=PLONE_VERSION=${PLONE_VERSION} VOLTO_VERSION=${VOLTO_VERSION} ADDON_NAME=${ADDON_NAME} ADDON_PATH=${ADDON_PATH} docker compose
53
+
54
+ # Top-level targets
55
+ .PHONY: all
56
+ all: clean install
57
+
58
+ .PHONY: clean
59
+ clean: ## Cleanup development environment
60
+ ${DOCKER_COMPOSE} down --volumes --remove-orphans
61
+
62
+ .PHONY: install
63
+ install: ## Build and install development environment
64
+ echo "Running: ${DOCKER_COMPOSE} build"
65
+ ${DOCKER_COMPOSE} pull
66
+ ${DOCKER_COMPOSE} build
67
+
68
+ .PHONY: start
69
+ start: ## Start development environment
70
+ echo "Running: ${DOCKER_COMPOSE} up"
71
+ ${DOCKER_COMPOSE} up
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
+
78
+ .PHONY: cypress-open
79
+ cypress-open: ## Open cypress integration tests
80
+ NODE_ENV=development $(NODE_MODULES)/cypress/bin/cypress open
81
+
82
+ .PHONY: cypress-run
83
+ cypress-run: ## Run cypress integration tests
84
+ NODE_ENV=development $(NODE_MODULES)/cypress/bin/cypress run
85
+
86
+ .PHONY: test
87
+ test: ## Run jest tests
88
+ ${DOCKER_COMPOSE} run -e CI=1 frontend test
89
+
90
+ .PHONY: test-update
91
+ test-update: ## Update jest tests snapshots
92
+ ${DOCKER_COMPOSE} run -e CI=1 frontend test -u
93
+
94
+ .PHONY: stylelint
95
+ stylelint: ## Stylelint
96
+ $(NODE_MODULES)/stylelint/bin/stylelint.js --allow-empty-input 'src/**/*.{css,less}'
97
+
98
+ .PHONY: stylelint-overrides
99
+ stylelint-overrides:
100
+ $(NODE_MODULES)/.bin/stylelint --custom-syntax less --allow-empty-input 'theme/**/*.overrides' 'src/**/*.overrides'
101
+
102
+ .PHONY: stylelint-fix
103
+ stylelint-fix: ## Fix stylelint
104
+ $(NODE_MODULES)/stylelint/bin/stylelint.js --allow-empty-input 'src/**/*.{css,less}' --fix
105
+ $(NODE_MODULES)/.bin/stylelint --custom-syntax less --allow-empty-input 'theme/**/*.overrides' 'src/**/*.overrides' --fix
106
+
107
+ .PHONY: prettier
108
+ prettier: ## Prettier
109
+ $(NODE_MODULES)/.bin/prettier --single-quote --check 'src/**/*.{js,jsx,json,css,less,md}'
110
+
111
+ .PHONY: prettier-fix
112
+ prettier-fix: ## Fix prettier
113
+ $(NODE_MODULES)/.bin/prettier --single-quote --write 'src/**/*.{js,jsx,json,css,less,md}'
114
+
115
+ .PHONY: lint
116
+ lint: ## ES Lint
117
+ $(NODE_MODULES)/eslint/bin/eslint.js --max-warnings=0 'src/**/*.{js,jsx}'
118
+
119
+ .PHONY: lint-fix
120
+ lint-fix: ## Fix ES Lint
121
+ $(NODE_MODULES)/eslint/bin/eslint.js --fix 'src/**/*.{js,jsx}'
122
+
123
+ .PHONY: i18n
124
+ i18n: ## i18n
125
+ rm -rf build/messages
126
+ NODE_ENV=development $(NODE_MODULES)/.bin/i18n --addon
127
+
128
+ .PHONY: help
129
+ help: ## Show this help.
130
+ @echo -e "$$(grep -hE '^\S+:.*##' $(MAKEFILE_LIST) | sed -e 's/:.*##\s*/:/' -e 's/^\(.\+\):\(.*\)/\\x1b[36m\1\\x1b[m:\2/' | column -c2 -t -s :)"
131
+ head -n 14 Makefile
package/README.md CHANGED
@@ -20,38 +20,25 @@
20
20
 
21
21
  Registers a VisualizationView component for a content type named 'tableau_visualization'.
22
22
 
23
- ## Features
24
-
25
- Demo GIF
26
-
27
23
  ## Getting started
28
24
 
29
25
  ### Try volto-tableau with Docker
30
26
 
31
- 1. Get the latest Docker images
32
-
33
- ```
34
- docker pull plone
35
- docker pull plone/volto
36
- ```
37
-
38
- 1. Start Plone backend
39
- ```
40
- docker run -d --name plone -p 8080:8080 -e SITE=Plone -e PROFILES="profile-plone.restapi:blocks" plone
41
- ```
42
-
43
- 1. Start Volto frontend
27
+ git clone https://github.com/eea/volto-tableau.git
28
+ cd volto-tableau
29
+ make
30
+ make start
44
31
 
45
- ```
46
- docker run -it --rm -p 3000:3000 --link plone -e ADDONS="@eeacms/volto-tableau" plone/volto
47
- ```
48
-
49
- 1. Go to http://localhost:3000
32
+ Go to http://localhost:3000
50
33
 
51
34
  ### Add volto-tableau to your Volto project
52
35
 
53
36
  1. Make sure you have a [Plone backend](https://plone.org/download) up-and-running at http://localhost:8080/Plone
54
37
 
38
+ ```Bash
39
+ docker compose up backend
40
+ ```
41
+
55
42
  1. Start Volto frontend
56
43
 
57
44
  * If you already have a volto project, just update `package.json`:
@@ -62,7 +49,7 @@ Demo GIF
62
49
  ],
63
50
 
64
51
  "dependencies": {
65
- "@eeacms/volto-tableau": "github:eea/volto-tableau#1.1.0"
52
+ "@eeacms/volto-tableau": "*"
66
53
  }
67
54
  ```
68
55
 
@@ -70,7 +57,7 @@ Demo GIF
70
57
 
71
58
  ```
72
59
  npm install -g yo @plone/generator-volto
73
- yo @plone/volto my-volto-project --addon @eeacms/volto-tableau
60
+ yo @plone/volto my-volto-project --canary --addon @eeacms/volto-tableau
74
61
  cd my-volto-project
75
62
  ```
76
63
 
@@ -87,95 +74,7 @@ Demo GIF
87
74
 
88
75
  ## Release
89
76
 
90
- ### Automatic release using Jenkins
91
-
92
- * The automatic release is started by creating a [Pull Request](../../compare/master...develop) from `develop` to `master`. The pull request status checks correlated to the branch and PR Jenkins jobs need to be processed successfully. 1 review from a github user with rights is mandatory.
93
- * It runs on every commit on `master` branch, which is protected from direct commits, only allowing pull request merge commits.
94
- * The automatic release is done by [Jenkins](https://ci.eionet.europa.eu). The status of the release job can be seen both in the Readme.md badges and the green check/red cross/yellow circle near the last commit information. If you click on the icon, you will have the list of checks that were run. The `continuous-integration/jenkins/branch` link goes to the Jenkins job execution webpage.
95
- * Automated release scripts are located in the `eeacms/gitflow` docker image, specifically [js-release.sh](https://github.com/eea/eea.docker.gitflow/blob/master/src/js-release.sh) script. It uses the `release-it` tool.
96
- * As long as a PR request is open from develop to master, the PR Jenkins job will automatically re-create the CHANGELOG.md and package.json files to be production-ready.
97
- * The version format must be MAJOR.MINOR.PATCH. By default, next release is set to next minor version (with patch 0).
98
- * You can manually change the version in `package.json`. The new version must not be already present in the tags/releases of the repository, otherwise it will be automatically increased by the script. Any changes to the version will trigger a `CHANGELOG.md` re-generation.
99
- * Automated commits and commits with [JENKINS] or [YARN] in the commit log are excluded from `CHANGELOG.md` file.
100
-
101
- ### Manual release from the develop branch ( beta release )
102
-
103
- #### Installation and configuration of release-it
104
-
105
- You need to first install the [release-it](https://github.com/release-it/release-it) client.
106
-
107
- ```
108
- npm install -g release-it
109
- ```
110
-
111
- Release-it uses the configuration written in the [`.release-it.json`](./.release-it.json) file located in the root of the repository.
112
-
113
- Release-it is a tool that automates 4 important steps in the release process:
114
-
115
- 1. Version increase in `package.json` ( increased from the current version in `package.json`)
116
- 2. `CHANGELOG.md` automatic generation from commit messages ( grouped by releases )
117
- 3. GitHub release on the commit with the changelog and package.json modification on the develop branch
118
- 4. NPM release ( by default it's disabled, but can be enabled in the configuration file )
119
-
120
- To configure the authentification, you need to export GITHUB_TOKEN for [GitHub](https://github.com/settings/tokens)
121
-
122
- ```
123
- export GITHUB_TOKEN=XXX-XXXXXXXXXXXXXXXXXXXXXX
124
- ```
125
-
126
- To configure npm, you can use the `npm login` command or use a configuration file with a TOKEN :
127
-
128
- ```
129
- echo "//registry.npmjs.org/:_authToken=YYYYYYYYYYYYYYYYYYYYYYYYYYYYYY" > .npmrc
130
- ```
131
-
132
- #### Using release-it tool
133
-
134
- There are 3 yarn scripts that can be run to do the release
135
-
136
- ##### yarn release-beta
137
-
138
- Automatically calculates and presents 3 beta versions - patch, minor and major for you to choose ( or Other for manual input).
139
-
140
- ```
141
- ? Select increment (next version):
142
- ❯ prepatch (0.1.1-beta.0)
143
- preminor (0.2.0-beta.0)
144
- premajor (1.0.0-beta.0)
145
- Other, please specify...
146
- ```
147
-
148
- ##### yarn release-major-beta
149
-
150
- Same as `yarn release-beta`, but with premajor version pre-selected.
151
-
152
- ##### yarn release
153
-
154
- Generic command, does not automatically add the `beta` to version, but you can still manually write it if you choose Other.
155
-
156
- #### Important notes
157
-
158
- > Do not use release-it tool on master branch, the commit on CHANGELOG.md file and the version increase in the package.json file can't be done without a PULL REQUEST.
159
-
160
- > Do not keep Pull Requests from develop to master branches open when you are doing beta releases from the develop branch. As long as a PR to master is open, an automatic script will run on every commit and will update both the version and the changelog to a production-ready state - ( MAJOR.MINOR.PATCH mandatory format for version).
161
-
162
- ## Enable Sources
163
-
164
- https://github.com/eea/eea.coremetadata EEA Core Metadata addon is needed.
165
-
166
- Sources (Data provenance) should be set on the visualization. To enable this, "EEA Core Metadata" should be checked as behavior on the visualization content-type.
167
-
168
- controlpanel/dexterity-types/tableau_visualization
169
-
170
- After this, sources can be added from the visualization edit interface. "EEA core metadata" tab => "Add source"
171
-
172
-
173
- ## Add a Tableau Visualization
174
-
175
- 1. Add the corresponding content-type. Project should also contain https://github.com/eea/eea.api.dataconnector which hosts the content-type.
176
- 2. Fill in the mandatory fields
177
- 3. "Tableau Widget" section => "Open Tableau Editor"
178
- 4. Provide the necessary settings to create the visualization
77
+ See [RELEASE.md](https://github.com/eea/volto-tableau/blob/master/RELEASE.md).
179
78
 
180
79
  ## How to contribute
181
80