Skip to content

Commit

Permalink
Merge pull request #10 from eea/develop
Browse files Browse the repository at this point in the history
Release
  • Loading branch information
avoinea committed Jun 12, 2023
2 parents 5614176 + a021eac commit 4bbc72c
Show file tree
Hide file tree
Showing 8 changed files with 90 additions and 34 deletions.
25 changes: 24 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,38 @@ All notable changes to this project will be documented in this file. Dates are d

Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).

### [1.1.1](https://github.com/eea/volto-timeline-block/compare/1.1.0...1.1.1) - 12 June 2023

#### :hammer_and_wrench: Others

- test: jest should look for addons in node_modules Refs #253277 [valentinab25 - [`9e46798`](https://github.com/eea/volto-timeline-block/commit/9e46798e251fba50d9ef8756f3f72de4684f6c44)]
- test: Add cypress test for basic functionality and demo gif to README - refs #253277 [ana-oprea - [`5afd16a`](https://github.com/eea/volto-timeline-block/commit/5afd16ab58e0a4f6b4d303f61c54ea3ed3a7baf7)]
- test: Fix test config, coverage Refs #253277 [valentinab25 - [`66e4928`](https://github.com/eea/volto-timeline-block/commit/66e4928bc2d940a81ad73ce27107ad0d1d471135)]
- Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`c0c83df`](https://github.com/eea/volto-timeline-block/commit/c0c83dff921bf4e4c4d81f60754c9f928aa5ce79)]
- Add Sonarqube tag using industry-frontend addons list [EEA Jenkins - [`90db0d4`](https://github.com/eea/volto-timeline-block/commit/90db0d4c8df4925a23fae6a55443ced5c256c645)]
### [1.1.0](https://github.com/eea/volto-timeline-block/compare/1.0.1...1.1.0) - 27 March 2023

#### :hammer_and_wrench: Others

- Release 1.1.0 [Alin Voinea - [`a667b7d`](https://github.com/eea/volto-timeline-block/commit/a667b7d7a42504ce81c0718ee00b768212f7a6dd)]
- Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`33e1837`](https://github.com/eea/volto-timeline-block/commit/33e183750b62be6c1fcfbdb8dad10db469169266)]
- Add Sonarqube tag using ims-frontend addons list [EEA Jenkins - [`41833c2`](https://github.com/eea/volto-timeline-block/commit/41833c236ec95bd60a693d5394c8c128e30f4ecf)]
- Add Sonarqube tag using advisory-board-frontend addons list [EEA Jenkins - [`5c12df2`](https://github.com/eea/volto-timeline-block/commit/5c12df222354499cbffe93e34c3c6a31f9f52124)]
- Add Sonarqube tag using advisory-board-frontend addons list [EEA Jenkins - [`abc6930`](https://github.com/eea/volto-timeline-block/commit/abc693081a2ed229adf27dbe0315c44a6735c28e)]
- Add Sonarqube tag using climate-energy-frontend addons list [EEA Jenkins - [`ed6e2b0`](https://github.com/eea/volto-timeline-block/commit/ed6e2b0b15a2437f456a227fdefe2336aeda98b2)]
- test(Jenkins): Run tests and cypress with latest canary @plone/volto [Alin Voinea - [`ff4d170`](https://github.com/eea/volto-timeline-block/commit/ff4d1705b90bbffcc54f7182e6799a8fac303104)]
- Add Sonarqube tag using cca-frontend addons list [EEA Jenkins - [`4ed90fb`](https://github.com/eea/volto-timeline-block/commit/4ed90fb54c0aec76c8f2287a83a14c8acc8c1ca8)]
- Add Sonarqube tag using bise-frontend addons list [EEA Jenkins - [`01e1ac8`](https://github.com/eea/volto-timeline-block/commit/01e1ac8bf4cc04713c643ef30f5dfa8d628b6e2b)]
- yarn 3 [Alin Voinea - [`a234a4c`](https://github.com/eea/volto-timeline-block/commit/a234a4c8d1717cf9039195e7246a07265a6b8b49)]
- Add Sonarqube tag using marine-frontend addons list [EEA Jenkins - [`4a25463`](https://github.com/eea/volto-timeline-block/commit/4a25463070164b31656e20c5ace164da225fd3fb)]
- Add Sonarqube tag using clms-frontend addons list [EEA Jenkins - [`5b687d5`](https://github.com/eea/volto-timeline-block/commit/5b687d5a91c4cc566e4428084c9d1d78df2de676)]
- Add Sonarqube tag using demo-kitkat-frontend addons list [EEA Jenkins - [`c9e0a49`](https://github.com/eea/volto-timeline-block/commit/c9e0a49e8a3c291833bb6c002441907b74df0875)]
- Add Sonarqube tag using forests-frontend addons list [EEA Jenkins - [`25df72a`](https://github.com/eea/volto-timeline-block/commit/25df72a779fd975ab4e42c39cfdc6968f7f04945)]
### [1.0.1](https://github.com/eea/volto-timeline-block/compare/1.0.0...1.0.1) - 16 November 2022

#### :hammer_and_wrench: Others

- test(estlint): Fix .project.eslintrc.js [Alin Voinea - [`742fb19`](https://github.com/eea/volto-timeline-block/commit/742fb1986b76ed5b775a7895aa91df452bf601e6)]
- Add Sonarqube tag using circularity-frontend addons list [EEA Jenkins - [`c4e6e36`](https://github.com/eea/volto-timeline-block/commit/c4e6e36aaabb02bea84695411cfb2d3ca586b210)]
## [1.0.0](https://github.com/eea/volto-timeline-block/compare/0.2.3...1.0.0) - 28 October 2022

#### :nail_care: Enhancements
Expand All @@ -27,6 +48,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
- test(cypress): Cypress 10 / Razzle 4 [Alin Voinea - [`ca50ec9`](https://github.com/eea/volto-timeline-block/commit/ca50ec9a9ab4db0faf0b33fa250814d788741478)]
- Cleanup [Alin Voinea - [`28c2444`](https://github.com/eea/volto-timeline-block/commit/28c244491045ca3ba6a3c182818364f73951f765)]
- Update dependencies [Alin Voinea - [`ab59000`](https://github.com/eea/volto-timeline-block/commit/ab590002fdef3c95d4580893b6e407b51746a290)]
- Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`bfa44a6`](https://github.com/eea/volto-timeline-block/commit/bfa44a64c026b2a5f9f22fbfcb3119f60c78d461)]
### [0.2.3](https://github.com/eea/volto-timeline-block/compare/0.2.2...0.2.3) - 30 June 2022

### [0.2.2](https://github.com/eea/volto-timeline-block/compare/0.2.1...0.2.2) - 8 June 2022
Expand All @@ -42,6 +64,7 @@ Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).

#### :hammer_and_wrench: Others

- Add Sonarqube tag using eea-website-frontend addons list [EEA Jenkins - [`21fea4e`](https://github.com/eea/volto-timeline-block/commit/21fea4edb8da738f81c12ca1f70696b63581159b)]
### [0.2.0](https://github.com/eea/volto-timeline-block/compare/0.1.0...0.2.0) - 29 March 2022

#### :hammer_and_wrench: Others
Expand Down
3 changes: 2 additions & 1 deletion Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ pipeline {
environment {
GIT_NAME = "volto-timeline-block"
NAMESPACE = "@eeacms"
SONARQUBE_TAGS = "volto.eea.europa.eu,demo-www.eea.europa.eu,prod-www.eea.europa.eu,circularity.eea.europa.eu,forest.eea.europa.eu,demo-kitkat.dev2aws.eea.europa.eu,clmsdemo.devel6cph.eea.europa.eu,water.europa.eu-marine,biodiversity.europa.eu,climate-adapt.eea.europa.eu,climate-energy.eea.europa.eu,climate-advisory-board.devel4cph.eea.europa.eu,climate-advisory-board.europa.eu,www.eea.europa.eu-ims,www.eea.europa.eu-en"
SONARQUBE_TAGS = "volto.eea.europa.eu,demo-www.eea.europa.eu,forest.eea.europa.eu,clmsdemo.devel6cph.eea.europa.eu,water.europa.eu-marine,biodiversity.europa.eu,climate-adapt.eea.europa.eu,climate-energy.eea.europa.eu,climate-advisory-board.devel4cph.eea.europa.eu,climate-advisory-board.europa.eu,www.eea.europa.eu-ims,www.eea.europa.eu-en,industry.eea.europa.eu"
DEPENDENCIES = ""
VOLTO = ""
}
Expand Down Expand Up @@ -188,6 +188,7 @@ pipeline {
def nodeJS = tool 'NodeJS';
withSonarQubeEnv('Sonarqube') {
sh '''sed -i "s#/opt/frontend/my-volto-project/src/addons/${GIT_NAME}/##g" xunit-reports/coverage/lcov.info'''
sh '''sed -i "s#src/addons/${GIT_NAME}/##g" xunit-reports/coverage/lcov.info'''
sh "export PATH=${scannerHome}/bin:${nodeJS}/bin:$PATH; sonar-scanner -Dsonar.javascript.lcov.reportPaths=./xunit-reports/coverage/lcov.info,./cypress-coverage/coverage/lcov.info -Dsonar.sources=./src -Dsonar.projectKey=$GIT_NAME-$BRANCH_NAME -Dsonar.projectVersion=$BRANCH_NAME-$BUILD_NUMBER"
sh '''try=2; while [ \$try -gt 0 ]; do curl -s -XPOST -u "${SONAR_AUTH_TOKEN}:" "${SONAR_HOST_URL}api/project_tags/set?project=${GIT_NAME}-${BRANCH_NAME}&tags=${SONARQUBE_TAGS},${BRANCH_NAME}" > set_tags_result; if [ \$(grep -ic error set_tags_result ) -eq 0 ]; then try=0; else cat set_tags_result; echo "... Will retry"; sleep 60; try=\$(( \$try - 1 )); fi; done'''
}
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
## Features

![Timeline Block](https://github.com/eea/volto-timeline-block/raw/develop/docs/timeline-block.png)
![Timeline Block Demo](https://github.com/eea/volto-timeline-block/raw/docs/docs/volto-timeline.gif)


## Getting started

Expand Down
29 changes: 0 additions & 29 deletions cypress/e2e/01-block-basics.cy.js

This file was deleted.

59 changes: 59 additions & 0 deletions cypress/e2e/01-timeline-block-basics.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
import { slateBeforeEach, slateAfterEach } from '../support/e2e';

describe('Blocks Tests', () => {
beforeEach(slateBeforeEach);
afterEach(slateAfterEach);

it('Add Block: Timeline', () => {
// Change page title
cy.clearSlateTitle();
cy.getSlateTitle().type('Volto Timeline Block Demo');

cy.get('.documentFirstHeading').contains('Volto Timeline Block Demo');

cy.getSlate().click();

// Add block
cy.get('.ui.basic.icon.button.block-add-button').first().click();
cy.get('.blocks-chooser .title').contains('Common').click({ force: true });
cy.get('.content.active.common .button.timeline_block')
.contains('Timeline')
.click({ force: true });

// Add timeline item
cy.get('.button').contains('Add Timeline item').click();
cy.get('.DateInput.DateInput_1 input[name="datetime-0-items-0-date"]').type(
'05/19/2023',
);
cy.get('input#field-title-1-items-0').type('Test Title');
cy.get('input#field-description-2-items-0').type('Test Description');
cy.get('div#field-color-4-items-0').click();
cy.get('div#field-color-4-items-0').contains('Orange').click();
cy.get('label[for="field-hideTime"]').click();

// Add another timeline item
cy.get('.button').contains('Add Timeline item').click();
cy.get('.DateInput.DateInput_1 input[name="datetime-0-items-1-date"]').type(
'05/22/2023',
);
cy.get('input#field-title-1-items-1').type('Test Title 2');
cy.get('input#field-description-2-items-1').type('Test Description 2');
cy.get('div#field-color-4-items-1').click();
cy.get('div#field-color-4-items-1').contains('Yellow').click();

// Save
cy.get('#toolbar-save').click();
cy.url().should('eq', Cypress.config().baseUrl + '/cypress/my-page');

// then the page view should contain our changes
cy.contains('Volto Timeline Block Demo');
cy.get('.timeline');
cy.get('.timeline .header').contains('Test Title');
cy.get('.timeline .description').contains('Test Description');
cy.get('.timeline .content .orange').contains('May 19, 2023');

cy.get('.timeline .header').contains('Test Title 2');
cy.get('.timeline .description').contains('Test Description 2');
cy.get('.timeline .content .yellow').contains('May 22, 2023');
});
});
Binary file added docs/volto-timeline.gif
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions jest-addon.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,19 @@ module.exports = {
'!src/**/*.d.ts',
],
moduleNameMapper: {
'\\.(css|less|scss|sass)$': 'identity-obj-proxy',
'@plone/volto/cypress': '<rootDir>/node_modules/@plone/volto/cypress',
'@plone/volto/babel': '<rootDir>/node_modules/@plone/volto/babel',
'@plone/volto/(.*)$': '<rootDir>/node_modules/@plone/volto/src/$1',
'@package/(.*)$': '<rootDir>/src/$1',
'@root/(.*)$': '<rootDir>/src/$1',
'@plone/volto-quanta/(.*)$': '<rootDir>/src/addons/volto-quanta/src/$1',
'@eeacms/(.*?)/(.*)$': '<rootDir>/src/addons/$1/src/$2',
'@eeacms/(.*?)/(.*)$': '<rootDir>/node_modules/@eeacms/$1/src/$2',
'@plone/volto-slate':
'<rootDir>/node_modules/@plone/volto/packages/volto-slate/src',
'~/(.*)$': '<rootDir>/src/$1',
'load-volto-addons':
'<rootDir>/node_modules/@plone/volto/jest-addons-loader.js',
'\\.(css|less|scss|sass)$': 'identity-obj-proxy',
},
transform: {
'^.+\\.js(x)?$': 'babel-jest',
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@eeacms/volto-timeline-block",
"version": "1.1.0",
"version": "1.1.1",
"description": "@eeacms/volto-timeline-block: Volto add-on",
"main": "src/index.js",
"author": "European Environment Agency: IDM2 A-Team",
Expand Down

0 comments on commit 4bbc72c

Please sign in to comment.